]> git.proxmox.com Git - vncterm.git/blobdiff - Makefile
d/control: add Architecture field
[vncterm.git] / Makefile
index 42f9df25252dc423f276cf8c8949687d622d7114..ab248a3061833ee98944ecbf7c82fccb1cde497e 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,7 +1,7 @@
 PACKAGE=vncterm
 # Note: also change version in debian/control and debian/changelog
-VERSION=1.4
-PACKAGERELEASE=2
+VERSION=1.5
+PACKAGERELEASE=3
 ARCH:=$(shell dpkg-architecture -qDEB_BUILD_ARCH)
 GITVERSION:=$(shell cat .git/refs/heads/master)
 CDATE:=$(shell date +%F)
@@ -15,6 +15,10 @@ VNCLIB=${VNCDIR}/libvncserver/.libs/libvncserver.a
 DEB=${PACKAGE}_${VERSION}-${PACKAGERELEASE}_${ARCH}.deb
 SNAP=${PACKAGE}-${VERSION}-${CDATE}.tar.gz
 
+CPPFLAGS += -O2 -g -Wall -Wno-deprecated-declarations -D_GNU_SOURCE -I $(VNCDIR)
+
+VNC_LIBS := -lnsl -lpthread -lz -ljpeg -lutil -lgnutls -lpng
+
 all: vncterm
 
 font.data: genfont2
@@ -34,8 +38,8 @@ ${VNCLIB}: ${VNCSRC}
        cd ${VNCDIR}; ./autogen.sh --without-ssl --without-websockets --without-tightvnc-filetransfer;
        cd ${VNCDIR}; $(MAKE)
 
-vncterm: vncterm.c ${VNCLIB} wchardata.c
-       gcc -O2 -g -o $@ vncterm.c wchardata.c -Wall -Wno-deprecated-declarations -D_GNU_SOURCE -I ${VNCDIR} ${VNCLIB} -lnsl -lpthread -lz -ljpeg -lutil -lgnutls -lpng
+vncterm: vncterm.c wchardata.c $(VNCLIB)
+       $(CC) $(CPPFLAGS) $(CFLAGS) -o $@ $^ $(VNC_LIBS)
 
 wchardata.c:
        cp /usr/share/unifont/$@ $@
@@ -64,7 +68,6 @@ deb: $(DEB)
 ${DEB}:
        $(MAKE) clean
        rsync -a . --exclude build build
-       echo "Architecture: ${ARCH}" >> build/debian/control
        echo "git clone git://git.proxmox.com/git/vncterm.git\\ngit checkout ${GIVERSION}" > build/debian/SOURCE
        cd build; dpkg-buildpackage -rfakeroot -b -us -uc
        lintian ${DEB}