File: rules

package info (click to toggle)
python-pypump 0.7-1
  • links: PTS, VCS
  • area: main
  • in suites: buster, stretch
  • size: 524 kB
  • ctags: 536
  • sloc: python: 3,153; makefile: 147
file content (38 lines) | stat: -rwxr-xr-x 1,284 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
#!/usr/bin/make -f
PYTHONS:=$(shell pyversions -vr)
PYTHON3S:=$(shell py3versions -vr)

%:
	dh $@ --buildsystem=python_distutils --with python2,python3,sphinxdoc

override_dh_clean:
	dh_clean -O--buildsystem=python_distutils
	rm -rf build python-pypump.egg-info
	rm -rf docs/_build/

override_dh_auto_build:
	dh_auto_build
	make -C docs html

	# # This version pypump-shell needs the path $HOME/.config/
	# # to exist for it to build correctly, so I'm adding it
	# # manually for now.
	# help2man --no-info \
	# -n 'sets up an environment and oauth tokens and allows for interactive testing' \
	# --version-string=0.5.1 "/usr/bin/env python2.7 $(CURDIR)/pypump-shell" > $(CURDIR)/debian/pypump-shell.1

override_dh_auto_install:
	set -e && for pyvers in $(PYTHONS); do \
		python$$pyvers setup.py install --install-layout=deb \
			--root $(CURDIR)/debian/python-pypump; \
	done
	# Remove the python-shell script, since it gets installed in another package
	rm -r $(CURDIR)/debian/python-pypump/usr/bin/

	set -e && for pyvers in $(PYTHON3S); do \
	 	python$$pyvers setup.py install --install-layout=deb \
	 		--root $(CURDIR)/debian/python3-pypump; \
	done
	# Remove the python-shell script, since it gets installed in another package
	rm -r $(CURDIR)/debian/python3-pypump/usr/bin/