| 1 | #! /usr/bin/make -f |
| 2 | |
| 3 | export DH_COMPAT = 4 |
| 4 | |
| 5 | build: |
| 6 | rm -rf build deb-build |
| 7 | mkdir deb-build |
| 8 | cd deb-build; ../configure --prefix=/usr --mandir=/usr/share/man |
| 9 | make -C deb-build |
| 10 | make -C deb-build check |
| 11 | touch build |
| 12 | |
| 13 | clean: |
| 14 | dh_clean |
| 15 | rm -rf deb-build build |
| 16 | |
| 17 | install: build |
| 18 | dh_clean |
| 19 | make -C deb-build install DESTDIR=`pwd`/debian/catacomb2 |
| 20 | mkdir -p debian/catacomb-dev/usr |
| 21 | mv debian/catacomb2/usr/include debian/catacomb-dev/usr |
| 22 | mkdir -p debian/catacomb-dev/usr/lib |
| 23 | mv debian/catacomb2/usr/lib/catacomb debian/catacomb-dev/usr/lib |
| 24 | mv debian/catacomb2/usr/lib/*.a debian/catacomb-dev/usr/lib |
| 25 | mv debian/catacomb2/usr/lib/*.so debian/catacomb-dev/usr/lib |
| 26 | mv debian/catacomb2/usr/lib/*.la debian/catacomb-dev/usr/lib |
| 27 | mkdir -p debian/catacomb-bin/usr |
| 28 | mv debian/catacomb2/usr/bin debian/catacomb-bin/usr |
| 29 | mkdir -p debian/catacomb-bin/usr/share/man |
| 30 | mv debian/catacomb2/usr/share/man/man1 \ |
| 31 | debian/catacomb-bin/usr/share/man |
| 32 | |
| 33 | binary-indep: |
| 34 | |
| 35 | binary-arch: install |
| 36 | dh_testdir -a |
| 37 | dh_testroot -a |
| 38 | dh_compress -a |
| 39 | dh_installdocs -a |
| 40 | dh_strip -a |
| 41 | dh_makeshlibs -a -V |
| 42 | dh_undocumented -a |
| 43 | dh_shlibdeps -a |
| 44 | dh_installdebconf -a |
| 45 | dh_gencontrol -a |
| 46 | dh_fixperms -a |
| 47 | dh_installdeb -a |
| 48 | dh_md5sums -a |
| 49 | dh_builddeb -a |
| 50 | |
| 51 | binary: binary-indep binary-arch |
| 52 | |
| 53 | source: |
| 54 | rm -rf deb-build/*.tar.gz deb-build/=deb= |
| 55 | make -C deb-build dist |
| 56 | mkdir deb-build/=deb= |
| 57 | cd deb-build/=deb=; tar xvfz ../*.tar.gz |
| 58 | d=`pwd`; cd ..; dpkg-source -i -b $$d/deb-build/=deb=/* |
| 59 | rm -rf deb-build/=deb= |
| 60 | |
| 61 | .PHONY: binary binary-arch binary-indep clean install source |