]> git.k1024.org Git - debian-pylibacl.git/blob - debian/rules
Adapt to new upstream build
[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         $(MAKE) clean
36         rm -f $(PYVERS:%=build-python%)
37         dh_clean
38
39 install: build $(PYVERS:%=install-python%)
40         find $(DBGROOT) ! -type d ! -name '*_d.so' | xargs rm -f
41         find $(DBGROOT) -depth -empty -print0|xargs -r0 rmdir
42
43 install-python%:
44         python$* setup.py install --root $(PKGROOT) --install-layout=deb
45         python$*-dbg setup.py install --root $(DBGROOT) --install-layout=deb
46
47 # Build architecture-dependent files here.
48 binary-arch: build install
49         dh_testdir
50         dh_testroot
51         dh_installchangelogs
52         dh_installdocs
53         dh_strip -ppython-pylibacl --dbg-package=python-pylibacl-dbg
54         rm -rf $(DBGROOT)/usr/share/doc/python-pylibacl-dbg
55         ln -s python-pylibacl $(DBGROOT)/usr/share/doc/python-pylibacl-dbg
56         dh_compress -X.js
57         dh_fixperms
58         dh_pysupport
59         dh_installdeb
60         dh_shlibdeps
61         dh_gencontrol
62         dh_md5sums
63         dh_builddeb
64
65 # Build architecture independant packages here.
66 binary-indep: build install
67 # Nothing to do
68
69 binary: binary-arch binary-indep
70 .PHONY: build clean binary-indep binary-arch binary install install-indep install-arch configure