]> git.proxmox.com Git - vncterm.git/blame - Makefile
buildsys: use gzip -n to disable timestamps
[vncterm.git] / Makefile
CommitLineData
c39031e8 1RELEASE=4.0
e6d0212c
DM
2
3PACKAGE=vncterm
4f21735d 4# Note: also change version in debian/control and debian/changelog
e20fdc6c 5VERSION=1.3
c39031e8 6PACKAGERELEASE=1
e6d0212c
DM
7ARCH:=$(shell dpkg-architecture -qDEB_BUILD_ARCH)
8CDATE:=$(shell date +%F)
9
536237ba
FG
10VNCVER=0.9.11
11VNCREL=LibVNCServer-${VNCVER}
12VNCDIR=libvncserver-${VNCREL}
13VNCSRC=${VNCREL}.tar.gz
e6d0212c
DM
14VNCLIB=${VNCDIR}/libvncserver/.libs/libvncserver.a
15
16TIGERVNCSRC=tigervnc-1.1.0.tgz
336e20e1 17#TIGERVNCSRC=tigervnc-1.2.0.tgz
e6d0212c
DM
18
19DEB=${PACKAGE}_${VERSION}-${PACKAGERELEASE}_${ARCH}.deb
20SNAP=${PACKAGE}-${VERSION}-${CDATE}.tar.gz
21
e0581694 22KEYSTORE=/home/dietmar/pve2-proxdev/proxmox-dev/comodo-for-java.keystore
e6d0212c
DM
23
24all: vncterm
25
26glyphs.h: genfont
d4dcc66e
FG
27 ./genfont > glyphs.h.tmp
28 mv glyphs.h.tmp glyphs.h
e6d0212c
DM
29
30genfont: genfont.c
31 gcc -g -O2 -o $@ genfont.c -Wall -D_GNU_SOURCE -lz
32
33.PHONY: vnc
34${VNCLIB} vnc: ${VNCSRC}
35 rm -rf ${VNCDIR}
36 tar xf ${VNCSRC}
37 ln -s ../vncpatches ${VNCDIR}/patches
38 cd ${VNCDIR}; quilt push -a
536237ba 39 cd ${VNCDIR}; ./autogen.sh --without-ssl --without-websockets --without-tightvnc-filetransfer;
e6d0212c
DM
40 cd ${VNCDIR}; make
41
42vncterm: vncterm.c glyphs.h ${VNCLIB}
536237ba 43 gcc -O2 -g -o $@ vncterm.c -Wall -Wno-deprecated-declarations -D_GNU_SOURCE -I ${VNCDIR} ${VNCLIB} -lnsl -lpthread -lz -ljpeg -lutil -lgnutls -lpng
e6d0212c
DM
44
45jar: tigervnc.org
085cabef 46 if test ! -f /usr/share/icedtea-web/plugin.jar; then echo "please install package icedtea-netx-common"; exit 1; fi
e6d0212c
DM
47 rm -rf tigervnc VncViewer.jar
48 rsync -av --exclude .svn --exclude .svnignore tigervnc.org/ tigervnc
49 ln -s ../tigerpatches tigervnc/patches
50 cd tigervnc; quilt push -a
51 cd tigervnc/java/src/com/tigervnc/vncviewer; make clean; make
11089334 52 jarsigner -keystore ${KEYSTORE} -signedjar VncViewer.jar tigervnc/java/src/com/tigervnc/vncviewer/VncViewer.jar "dc475d72-124a-11e4-a53f-005056c00008"
e0581694 53
336e20e1
DM
54# this is for version 1.2
55# ln -s ../newtigerpatches tigervnc/patches
56# cd tigervnc/java;cmake -G "Unix Makefiles"; make
57# jarsigner -keystore ${KEYSTORE} -signedjar VncViewer.jar tigervnc/java/VncViewer.jar proxmox
e6d0212c
DM
58
59tigervnc.org: ${TIGERVNCSRC}
60 rm -rf tigervnc.org
61 tar xf ${TIGERVNCSRC}
62
336e20e1 63download:
e6d0212c
DM
64 rm -rf tigervnc.org
65 svn co https://tigervnc.svn.sourceforge.net/svnroot/tigervnc/tags/1_1_0 tigervnc.org
66 tar cf ${TIGERVNCSRC} tigervnc.org
67
68.PHONY: install
69install: vncterm vncterm.1 VncViewer.jar
70 mkdir -p ${DESTDIR}/usr/share/doc/${PACKAGE}
71 mkdir -p ${DESTDIR}/usr/share/man/man1
72 mkdir -p ${DESTDIR}/usr/bin
73 install -s -m 0755 vncterm ${DESTDIR}/usr/bin
74 mkdir -p ${DESTDIR}/usr/share/vncterm/
75 install -m 0644 VncViewer.jar ${DESTDIR}/usr/share/vncterm/
76
77.PHONY: dinstall
78dinstall: ${DEB}
79 dpkg -i ${DEB}
80
81vncterm.1: vncterm.pod
82 rm -f $@
83 pod2man -n $< -s 1 -r ${VERSION} <$< >$@
84
85.PHONY: deb
c5ce64cf
WB
86deb: $(DEB)
87${DEB}:
e6d0212c
DM
88 make clean
89 rm -rf dest
90 mkdir dest
91 make DESTDIR=`pwd`/dest install
92 install -d -m 0755 dest/DEBIAN
93 install -m 0644 debian/control dest/DEBIAN
94 echo "Architecture: ${ARCH}" >>dest/DEBIAN/control
95 install -m 0644 debian/conffiles dest/DEBIAN
96 install -m 0644 copyright dest/usr/share/doc/${PACKAGE}
97 install -m 0644 vncterm.1 dest/usr/share/man/man1
98 install -m 0644 debian/changelog.Debian dest/usr/share/doc/${PACKAGE}
3c10a042
WB
99 gzip -n --best dest/usr/share/man/*/*
100 gzip -n --best dest/usr/share/doc/${PACKAGE}/changelog.Debian
e6d0212c
DM
101 dpkg-deb --build dest
102 mv dest.deb ${DEB}
103 rm -rf dest
104 lintian ${DEB}
105
106.PHONY: upload
107upload: ${DEB}
8530eb68 108 tar cf - ${DEB} | ssh repoman@repo.proxmox.com upload
e6d0212c
DM
109
110.PHONY: clean
111clean:
d4dcc66e 112 rm -rf vncterm vncterm.1 vncterm_*.deb tigervnc *~ ${VNCDIR} vncterm-*.tar.gz glyph.h.tmp
e6d0212c
DM
113
114.PHONY: distclean
115distclean: clean
116 rm -rf tigervnc.org
117
118.PHONY: dist
119${SNAP} dist: distclean
120 rm -rf ../${SNAP}
121 cd ..; tar cvzf ${SNAP} --exclude .svn ${PACKAGE}
122 mv ../${SNAP} ${SNAP}
123
124.PHONY: uploaddist
125uploaddist: ${SNAP}
c39031e8 126 scp ${SNAP} pve.proxmox.com:/home/ftp/sources/