2 # See debhelper(7) (uncomment to enable)
3 # output every command that modifies files on the build system.
6 # see FEATURE AREAS in dpkg-buildflags(1)
7 export DEB_BUILD_MAINT_OPTIONS = hardening=+all
9 # see ENVIRONMENT in dpkg-buildflags(1)
10 # package maintainers to append CFLAGS
11 #export DEB_CFLAGS_MAINT_APPEND = -Wall -pedantic
12 # package maintainers to append LDFLAGS
13 #export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed
16 configure: configure-stamp
19 cd src && ./configure --no-manpage --prefix=/usr --sysconfdir=/etc --examplesdir=/usr/share/anytun/examples && cd ..
22 build: build-arch build-indep
24 build-arch: build-stamp
25 build-indep: build-stamp
27 build-stamp: configure-stamp
30 cd src && $(MAKE) && cd ..
37 rm -f build-stamp configure-stamp
39 # Add here commands to clean up after the build process.
40 $(MAKE) --directory=$(CURDIR)/src distclean
48 # Add here commands to install the package into debian/anytun.
49 cd src && $(MAKE) DESTDIR=$(CURDIR)/debian/anytun install && cd ..
51 mv debian/anytun/usr/share/anytun/examples/anytun debian/anytun/usr/share/anytun/examples/config
52 echo "example configurations can be found at /usr/share/anytun/examples/config" > debian/anytun/etc/anytun/README
54 # Build architecture-independent files here.
56 # We have nothing to do by default.
58 # Build architecture-dependent files here.
62 dh_installchangelogs ChangeLog
64 dh_installman doc/anytun.8 doc/anytun-config.8 doc/anytun-controld.8 doc/anytun-showtables.8
70 mkdir -p debian/anytun/usr/share/lintian/overrides/
71 cp -av debian/overrides debian/anytun/usr/share/lintian/overrides/anytun
73 find debian/anytun -type f -name config -exec chmod 600 {} \;
74 find debian/anytun -type f -name post-up.sh -exec chmod 755 {} \;
75 chmod 600 debian/anytun/usr/share/anytun/examples/config/server/conf.d/*
82 binary: binary-indep binary-arch
83 .PHONY: build clean binary-indep binary-arch binary install configure