chiark / gitweb /
cleanup: All the whitespace fixes, all at once.
[mLib] / debian / rules
1 #! /usr/bin/make -f
2
3 export DH_COMPAT = 4
4
5 build:
6         rm -rf deb-build deb-noadns build; mkdir deb-build deb-noadns
7         cd deb-build; ../configure \
8                 --with-adns \
9                 --prefix=/usr \
10                 --mandir=/usr/share/man \
11                 --libexecdir=/usr/lib
12         make -C deb-build
13         make -C deb-build check
14         cd deb-noadns; ../configure \
15                 --without-adns \
16                 --prefix=/usr \
17                 --mandir=/usr/share/man \
18                 --libexecdir=/usr/lib
19         make -C deb-noadns
20         make -C deb-noadns check
21         touch build
22
23 clean:
24         dh_clean
25         rm -rf deb-build deb-noadns build
26
27 install: build
28         dh_clean
29         make -C deb-noadns install DESTDIR=`pwd`/debian/mlib2
30         mkdir -p debian/mlib-dev/usr/lib
31         mkdir -p debian/mlib-dev/usr/share/man
32         mkdir -p debian/mlib-dev/usr/bin
33         mv debian/mlib2/usr/bin/mLib-config debian/mlib-dev/usr/bin
34         mv debian/mlib2/usr/share/man/man3 debian/mlib-dev/usr/share/man
35         mv debian/mlib2/usr/lib/*.a debian/mlib-dev/usr/lib
36         mv debian/mlib2/usr/lib/*.so debian/mlib-dev/usr/lib
37         mv debian/mlib2/usr/lib/*.la debian/mlib-dev/usr/lib
38         mv debian/mlib2/usr/include debian/mlib-dev/usr
39         mkdir -p debian/mlib-bin/usr/share/man
40         mv debian/mlib2/usr/bin debian/mlib-bin/usr
41         mv debian/mlib2/usr/share/man/man1 debian/mlib-bin/usr/share/man
42         make -C deb-build install DESTDIR=`pwd`/debian/mlib2-adns
43         rmdir debian/mlib2-adns/usr/lib/mLib
44         rm -rf debian/mlib2-adns/usr/bin
45         rm -rf debian/mlib2-adns/usr/share/man
46         rm -rf debian/mlib2-adns/usr/include
47         rm debian/mlib2-adns/usr/lib/*.a
48         rm debian/mlib2-adns/usr/lib/*.so
49         rm debian/mlib2-adns/usr/lib/*.la
50         dh_strip -a
51
52 binary-indep:
53
54 binary-arch: install
55         dh_testdir -a
56         dh_testroot -a
57         dh_makeshlibs -a -V"mlib2 (>= 2.0.3) | mlib2-adns (>= 2.0.3)"
58         dh_installman -a
59         dh_compress -a
60         dh_installdocs -a
61         dh_strip -a
62         dh_shlibdeps -a
63         dh_gencontrol -a
64         dh_fixperms -a
65         dh_installdeb -a
66         dh_md5sums -a
67         dh_builddeb -a
68
69 binary: binary-indep binary-arch
70
71 source:
72         rm -rf deb-build/*.tar.gz deb-build/=deb=
73         make -C deb-build dist PACKAGE=mlib
74         mkdir deb-build/=deb=
75         cd deb-build/=deb=; tar xvfz ../*.tar.gz
76         d=`pwd`; cd ..; dpkg-source -i -b $$d/deb-build/=deb=/*
77         rm -rf deb-build/=deb=
78
79 .PHONY: binary binary-arch binary-indep clean install source