]> git.k1024.org Git - debian-pylibacl.git/blob - debian/rules
Merge tag 'upstream/0.5.1'
[debian-pylibacl.git] / debian / rules
1 #!/usr/bin/make -f
2 # Sample debian/rules that uses debhelper.
3 # GNU copyright 1997 to 1999 by Joey Hess.
4 #
5 # Modified to make a template file for a multi-binary package with separated
6 # build-arch and build-indep targets  by Bill Allombert 2001
7
8 # Uncomment this to turn on verbose mode.
9 #export DH_VERBOSE=1
10
11 # This has to be exported to make some magic below work.
12 export DH_OPTIONS
13
14 PYVERS := $(shell pyversions -vr)
15
16 PKGROOT=debian/python-pylibacl
17 DBGROOT=debian/python-pylibacl-dbg
18
19 build: $(PYVERS:%=build-python%) build-indep
20         touch $@
21
22 build-python%:
23         python$* setup.py build
24         python$*-dbg setup.py build
25         touch $@
26
27 build-indep:
28         make doc
29         touch $@
30
31 clean:
32         dh_testdir
33         dh_testroot
34         rm -f build-arch-stamp build-indep #CONFIGURE-STAMP#
35         rm -rf build html
36         rm -f posix1e.so
37         rm -f $(PYVERS:%=build-python%)
38         dh_clean
39
40 install: build $(PYVERS:%=install-python%)
41         find $(DBGROOT) ! -type d ! -name '*_d.so' | xargs rm -f
42         find $(DBGROOT) -depth -empty -print0|xargs -r0 rmdir
43
44 install-python%:
45         python$* setup.py install --root $(PKGROOT) --install-layout=deb
46         python$*-dbg setup.py install --root $(DBGROOT) --install-layout=deb
47
48 # Build architecture-dependent files here.
49 binary-arch: build install
50         dh_testdir
51         dh_testroot
52         dh_installchangelogs
53         dh_installdocs
54         dh_strip -ppython-pylibacl --dbg-package=python-pylibacl-dbg
55         rm -rf $(DBGROOT)/usr/share/doc/python-pylibacl-dbg
56         ln -s python-pylibacl $(DBGROOT)/usr/share/doc/python-pylibacl-dbg
57         dh_compress -X.js
58         dh_fixperms
59         dh_pysupport
60         dh_installdeb
61         dh_shlibdeps
62         dh_gencontrol
63         dh_md5sums
64         dh_builddeb
65
66 # Build architecture independant packages here.
67 binary-indep: build install
68 # Nothing to do
69
70 binary: binary-arch binary-indep
71 .PHONY: build clean binary-indep binary-arch binary install install-indep install-arch configure