#!/usr/bin/make -f # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 export DEB_BUILD_MAINT_OPTIONS = hardening=+all export DEB_CFLAGS_MAINT_APPEND = -Wall -pedantic %: dh $@ override_dh_auto_build: dh_auto_build $@ $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) debian/setuidwrapper.c -o index.cgi pod2man --section=8 --center="BackupPC manual" doc/BackupPC.pod backuppc.8 perl -e "s/.IX Title.*/.SH NAME\nbackuppc \\- BackupPC manual/g" -p -i.tmp backuppc.8 override_dh_install: perl configure.pl --batch --no-fhs --hostname XXXXXX --uid-ignore \ --config-dir=/etc/backuppc --run-dir=/run/backuppc \ --install-dir /usr/share/backuppc --dest-dir $(CURDIR)/debian/backuppc/ \ --data-dir /var/lib/backuppc --cgi-dir /usr/share/backuppc/cgi-bin \ --html-dir /usr/share/backuppc/image --html-dir-url /backuppc/image \ --bin-path perl=/usr/bin/perl --bin-path tar=/bin/tar \ --bin-path smbclient=/usr/bin/smbclient \ --bin-path nmblookup=/usr/bin/nmblookup \ --bin-path rsync_bpc=/usr/libexec/backuppc-rsync/rsync_bpc \ --bin-path rsync=/usr/bin/rsync --bin-path ping=/bin/ping \ --bin-path df=/bin/df --bin-path ssh=/usr/bin/ssh \ --bin-path sendmail=/usr/sbin/sendmail \ --bin-path hostname=/bin/hostname --bin-path split=/usr/bin/split \ --bin-path par2=/usr/bin/par2 --bin-path cat=/bin/cat \ --bin-path gzip=/bin/gzip --bin-path bzip2=/bin/bzip2 \ --bin-path ping6=/bin/ping6 mv -f debian/backuppc/usr/share/backuppc/cgi-bin/* debian/backuppc/usr/share/backuppc/lib/realindex.cgi install --mode=755 index.cgi debian/backuppc/usr/lib/backuppc/cgi-bin install --mode=644 conf/hosts debian/backuppc/etc/backuppc install --mode=644 debian/localhost.pl debian/backuppc/etc/backuppc install --mode=644 debian/apache.conf debian/backuppc/etc/backuppc -rmdir debian/backuppc/var/lib/backuppc/conf/ (cd debian/backuppc/usr/share/backuppc/cgi-bin; ln -s ../image; ln -s /usr/lib/backuppc/cgi-bin/index.cgi ) patch --no-backup-if-mismatch -p0 < debian/config.pl.diff install --mode=644 debian/backuppc/etc/backuppc/config.pl debian/backuppc/usr/share/backuppc/conf rm -rf debian/backuppc/etc/backuppc/config.pl rm -rf debian/backuppc/run dh_install