123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869 |
- #!/usr/bin/make -f
- package=file
- build:
- $(checkdir)
- ./configure --prefix=/usr '--datadir=$${prefix}/share/misc' \
- '--mandir=$${prefix}/share/man'
- make
- touch build
- clean:
- $(checkdir)
- rm -f build changelog.tmp debian/copyright
- if [ -r Makefile ]; then \
- make distclean; \
- fi
- rm -f config.{log,cache,status} Makefile
- find . -name "*~" | xargs rm -f
- rm -rf debian/tmp debian/files* core debian/substvars
- dh_clean
- binary-indep: checkroot build
- $(checkdir)
- # There are no architecture-independent files to be uploaded
- # generated by this package. If there were any they would be
- # made here.
- binary-arch: checkroot build
- $(checkdir)
- rm -rf debian/tmp
- install -d debian/tmp/usr/bin debian/tmp/etc debian/tmp/usr/share/man/man1 debian/tmp/usr/share/man/man5
- make install prefix=`pwd`/debian/tmp/usr \
- INSTALL="/usr/bin/install -p" # DESTDIR=`pwd`/debian/tmp
- install -m644 -p magic.local `pwd`/debian/tmp/etc/magic
- cat debian/copyright-prolog LEGAL.NOTICE > debian/copyright
- dh_installdirs
- dh_installdocs README
- dh_installchangelogs patchlevel.h
- dh_installmanpages
- dh_strip
- dh_compress
- dh_fixperms
- dh_shlibdeps
- dh_gencontrol
- dh_installdeb
- dh_md5sums
- dh_builddeb
- rm -f debian/copyright
- define checkdir
- test -f debian/rules
- endef
- # Below here is fairly generic really
- binary: binary-indep binary-arch
- source diff:
- @echo >&2 'source and diff are obsolete - use dpkg-source -b'; false
- checkroot:
- $(checkdir)
- test root = "`whoami`"
- .PHONY: binary binary-arch binary-indep clean checkroot
|