]> git.proxmox.com Git - vncterm.git/blobdiff - Makefile
buildsys: cleanup
[vncterm.git] / Makefile
index 42f9df25252dc423f276cf8c8949687d622d7114..2318f0945e28b98f940ccd798fba8199a7774d8e 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/$@ $@