File: rules

package info (click to toggle)
jabber.py 0.5.0-1.6
  • links: PTS
  • area: main
  • in suites: buster, stretch
  • size: 564 kB
  • ctags: 1,096
  • sloc: python: 3,412; makefile: 60
file content (89 lines) | stat: -rwxr-xr-x 2,026 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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
#!/usr/bin/make -f
# Sample debian/rules that uses debhelper.
# GNU copyright 1997 to 1999 by Joey Hess.

# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1

# python version for which a pkg will be build
PYVERS:=$(shell pyversions -r)

ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS)))
	CFLAGS += -g
endif
ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
	INSTALL_PROGRAM += -s
endif

build: build-stamp
build-stamp:
	dh_testdir

	set -e; \
	for py in $(PYVERS); do \
	    $$py setup.py build; done
	
	#/usr/bin/docbook-to-man debian/python-jabber.sgml > python-jabber.1

	touch build-stamp jabber/__init__.py

clean:
	dh_testdir
	dh_testroot
	-for py in $(PYVERS); do \
	    $$py setup.py clean --all; done
	
	find $(CURDIR) -name \*.pyc -exec rm -f {} \;
	find $(CURDIR) -name \*.pyo -exec rm -f {} \;
	rm -f build-stamp jabber/__init__.py
	rm -rf docs

	dh_clean

install: build
	dh_testdir
	dh_testroot
	dh_clean -k
	dh_installdirs -v

	set -e; \
	for py in $(PYVERS); do                              	\
	    $$py setup.py install --root=debian/python-jabber; 	\
	done


# Build architecture-independent files here.
binary-indep: build install
# We have nothing to do by default.
	dh_testdir -i
	dh_testroot -i
	
	# Decode some imgs for html docs
	install -d $(CURDIR)/docs/img/
	install -d $(CURDIR)/docs/docs/
	uudecode -o $(CURDIR)/docs/img/logo-56-80.png \
		$(CURDIR)/debian/img/logo-56-80.png.b64
	uudecode -o $(CURDIR)/docs/img/jabber-powered-20.png \
		$(CURDIR)/debian/img/jabber-powered-20.png.b64
	install -m 0644 $(CURDIR)/debian/jabber.html \
		$(CURDIR)/debian/xmlstream.html \
		$(CURDIR)/docs/docs/
	
	dh_installdocs -i
	dh_installexamples -i
	dh_installchangelogs  -i
	dh_link -i 
	dh_compress -i -X.py -X.xpm
	dh_fixperms -i
	dh_python2 -i
	dh_installdeb -i
	dh_shlibdeps -i
	dh_gencontrol -i
	dh_md5sums -i
	dh_builddeb -i

# Build architecture-dependent files here.
binary-arch: build install

binary: binary-indep binary-arch
.PHONY: build clean binary-indep binary-arch binary install