1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57
|
#!/usr/bin/make -f
destd=$(CURDIR)/debian/storebackup/
base_shared=usr/share/storebackup/
base_bin=usr/bin/
shared=$(destd)/$(base_shared)
bin=$(destd)/$(base_bin)
CMD=$(shell echo $@ | sed 's/^override_//')
%:
dh $@
clean:
dh $@
rm -fr debian/man/
override_dh_install:
$(CMD)
for file in $(shared)/bin/*; \
do chmod 755 $$file; \
mv $$file $(shared)/bin/`basename $$file .pl`; \
dh_link $(base_shared)/bin/`basename $$file .pl` $(base_bin)/`basename $$file .pl`; \
done
rm -f $(bin)/multitail
chmod 644 $(shared)/lib/*
for file in $(shared)/lib/*; do \
if head -1 $$file | grep -q "#!"; then \
chmod +x $$file; \
fi \
done
override_dh_installchangelogs:
$(CMD) doc/ChangeLog
override_dh_installexamples:
[ ! -f storeBackup_example ] || rm -f storeBackup_example
/usr/bin/perl bin/storeBackup.pl -g storeBackup_example
$(CMD)
override_dh_installcron:
[ -f debian/storebackup.cron.daily ] || cp cron-storebackup debian/storebackup.cron.daily
$(CMD)
override_dh_compres:
$(CMD) -X storeBackup_example
override_dh_installman:
rm -fr debian/man
mkdir -p debian/man
for file in $(bin)/*; do \
file=$$(basename $$file); \
pod2man $(bin)/$$file > debian/man/$$file.1; \
done
$(CMD)
|