File: rules

package info (click to toggle)
py-radix 0.5-2
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 156 kB
  • ctags: 154
  • sloc: ansic: 1,526; python: 331; makefile: 36
file content (55 lines) | stat: -rwxr-xr-x 1,101 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
#!/usr/bin/make -f
#export DH_VERBOSE=1

include /usr/share/quilt/quilt.make

PYDEF=$(shell pyversions -d)
PYVERS=$(shell pyversions -r)

build build-indep build-arch: build-stamp
build-stamp: $(PYVERS:%=build-ext-%) patch
	touch $@

build-ext-%:
	# Building for $*
	dh_testdir
	$(subst $(PYDEF),python,$*) setup.py build
	touch $@
	# ... done

install-clean: build-stamp
	dh_clean -k

install: install-clean $(PYVERS:%=install-ext-%)

install-ext-%: install-clean
	# Installing for $*
	$(subst $(PYDEF),python,$*) setup.py install --root $(CURDIR)/debian/python-radix
	# ... done

binary-indep:

binary-arch: install
	# Building .deb
	dh_installchangelogs -a ChangeLog
	dh_installdocs -a README
	dh_installman -a
	dh_installexamples -a
	dh_strip -a
	dh_compress -a
	dh_pycentral -a
	dh_fixperms -a
	dh_shlibdeps -a
	dh_installdeb -a
	dh_gencontrol -a
	dh_md5sums -a
	dh_builddeb -a

binary: binary-indep binary-arch

clean: unpatch
	dh_testdir
	rm -rf build
	dh_clean build-stamp build-ext-*

.PHONY: build build-indep build-arch clean binary binary-indep binary-arch install configure patch unpatch