]> git.proxmox.com Git - pve-xtermjs.git/blob - Makefile
update xterm.js sources to 3.13.2 and move away from tarballs
[pve-xtermjs.git] / Makefile
1 include /usr/share/dpkg/pkg-info.mk
2
3 PACKAGE=pve-xtermjs
4
5 export VERSION=${DEB_VERSION_UPSTREAM_REVISION}
6
7 XTERMJSVER=3.13.2
8 XTERMJSTGZ=xterm-${XTERMJSVER}.tgz
9
10 SRCDIR=src
11
12 GITVERSION:=$(shell cat .git/refs/heads/master)
13
14 DEB=${PACKAGE}_${VERSION}_all.deb
15
16 all: ${DEB}
17 @echo ${DEB}
18
19 .PHONY: deb
20 deb: ${DEB}
21 ${DEB}:
22 rm -rf ${SRCDIR}.tmp
23 cp -rpa ${SRCDIR} ${SRCDIR}.tmp
24 cp -a debian ${SRCDIR}.tmp/
25 echo "git clone git://git.proxmox.com/git/pve-xtermjs.git\\ngit checkout ${GITVERSION}" > ${SRCDIR}.tmp/debian/SOURCE
26 cd ${SRCDIR}.tmp; dpkg-buildpackage -b -uc -us
27 lintian ${DEB}
28 @echo ${DEB}
29
30
31 X_EXCLUSIONS=--exclude=addons/attach --exclude=addons/fullscreen --exclude=addons/search \
32 --exclude=addons/terminado --exclude=addons/webLinks --exclude=addons/zmodem
33 .PHONY: download
34 download:
35 wget https://registry.npmjs.org/xterm/-/${XTERMJSTGZ} -O ${XTERMJSTGZ}.tmp
36 mv ${XTERMJSTGZ}.tmp ${XTERMJSTGZ}
37 tar -C $(SRCDIR)/www -xf ${XTERMJSTGZ} package/dist --strip-components=2 ${X_EXCLUSIONS}
38 rm ${XTERMJSTGZ}
39
40 .PHONY: upload
41 upload: ${DEB}
42 tar cf - ${DEB}|ssh -X repoman@repo.proxmox.com -- upload --product pmg,pve --dist stretch
43
44 .PHONY: distclean
45 distclean: clean
46
47 .PHONY: clean
48 clean:
49 rm -rf *~ debian/*~ *_${ARCH}.deb ${SRCDIR}.tmp ${XTERMJSDIR} *_all.deb *.changes *.dsc *.buildinfo
50
51 .PHONY: dinstall
52 dinstall: deb
53 dpkg -i ${DEB}