5
0
mirror of git://git.proxmox.com/git/novnc-pve.git synced 2024-12-21 13:34:08 +03:00

change from tgz to submodule

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
This commit is contained in:
Dominik Csapak 2017-05-22 16:58:10 +02:00 committed by Wolfgang Bumiller
parent 104710c7f1
commit 339cafefa3
3 changed files with 30 additions and 24 deletions

3
.gitmodules vendored Normal file
View File

@ -0,0 +1,3 @@
[submodule "novnc"]
path = novnc
url = ../mirror_novnc

View File

@ -1,41 +1,39 @@
PACKAGE=novnc-pve PACKAGE=novnc-pve
VER=0.5
PKGREL=9 PKGREL=9
NOVNCDIR=novnc SRCDIR=novnc
NOVNCSRC=${NOVNCDIR}.tgz
NOVNCVER=0.5
ARCH:=$(shell dpkg-architecture -qDEB_BUILD_ARCH) ARCH:=$(shell dpkg-architecture -qDEB_BUILD_ARCH)
GITVERSION:=$(shell cat .git/refs/heads/master) GITVERSION:=$(shell cat .git/refs/heads/master)
DEB=${PACKAGE}_${NOVNCVER}-${PKGREL}_${ARCH}.deb DEB=${PACKAGE}_${VER}-${PKGREL}_${ARCH}.deb
all: deb all: ${DEB}
@echo ${DEB}
.PHONY: dinstall
dinstall: deb
dpkg -i ${DEB}
.PHONY: deb .PHONY: deb
deb: ${DEB} deb: ${DEB}
${DEB}: ${TARSRC} ${DEB}: | submodule
rm -rf ${NOVNCDIR} rm -rf ${SRCDIR}.tmp
tar xf ${NOVNCSRC} cp -rpa ${SRCDIR} ${SRCDIR}.tmp
cp -a debian ${NOVNCDIR}/debian cp -a debian ${SRCDIR}.tmp/debian
cp ${NOVNCDIR}/include/ui.js ${NOVNCDIR}/pveui.js cp ${SRCDIR}.tmp/include/ui.js ${SRCDIR}.tmp/pveui.js
cp ${NOVNCDIR}/vnc.html ${NOVNCDIR}/index.html.tpl cp ${SRCDIR}.tmp/vnc.html ${SRCDIR}.tmp/index.html.tpl
# fix file permissions # fix file permissions
chmod 0644 ${NOVNCDIR}/include/jsunzip.js chmod 0644 ${SRCDIR}.tmp/include/jsunzip.js
echo "git clone git://git.proxmox.com/git/novnc-pve.git\\ngit checkout ${GITVERSION}" > ${NOVNCDIR}/debian/SOURCE echo "git clone git://git.proxmox.com/git/novnc-pve.git\\ngit checkout ${GITVERSION}" > ${SRCDIR}.tmp/debian/SOURCE
cd ${NOVNCDIR}; dpkg-buildpackage -b -uc -us cd ${SRCDIR}.tmp; dpkg-buildpackage -rfakeroot -b -uc -us
lintian ${DEB} lintian ${DEB}
@echo ${DEB}
.PHONY: submodule
submodule:
test -f "${SRCDIR}/vnc.html" || git submodule update --init
.PHONY: download .PHONY: download
download: download ${SRCDIR}:
rm -rf ${NOVNCDIR} git submodule foreach 'git pull --ff-only origin master'
git clone git://github.com/kanaka/noVNC ${NOVNCDIR}
cd ${NOVNCDIR}; git checkout -b local a0e7ab43dca0ce11a713694ee4cf530bd3b17c5a
tar czf ${NOVNCSRC} ${NOVNCDIR}
.PHONY: upload .PHONY: upload
upload: ${DEB} upload: ${DEB}
@ -46,4 +44,8 @@ distclean: clean
.PHONY: clean .PHONY: clean
clean: clean:
rm -rf *~ debian/*~ *_${ARCH}.deb *_all.deb *.changes *.dsc novnc rm -rf *~ debian/*~ *_${ARCH}.deb ${SRCDIR}.tmp *_all.deb *.changes *.dsc *.buildinfo
.PHONY: dinstall
dinstall: deb
dpkg -i ${DEB}

1
novnc Submodule

@ -0,0 +1 @@
Subproject commit a0e7ab43dca0ce11a713694ee4cf530bd3b17c5a