File: rules

package info (click to toggle)
xmlelements 0.7.4-2
  • links: PTS, VCS
  • area: main
  • in suites: buster, sid
  • size: 144 kB
  • sloc: python: 1,101; makefile: 17
file content (26 lines) | stat: -rwxr-xr-x 652 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
#!/usr/bin/make -f

PY2_PACKAGE_NAME=python-xe

# Run setup.py with the default python and python3 last so that the scripts use
# #!/usr/bin/python and #!/usr/bin/python3 and not #!/usr/bin/python2.X and
# #!/usr/bin/python3.X.
PYDEFAULT  := $(shell pyversions -d)
PYVERS     := $(shell pyversions -r)
PYVERS     := $(filter-out $(PYDEFAULT),$(PYVERS)) python

override_dh_auto_build:
	set -xe; \
	for py in $(PYVERS); do \
		$$py setup.py build; \
	done

override_dh_auto_install:
	set -xe; \
	for py in $(PYVERS); do \
		$$py setup.py install --skip-build --root debian/$(PY2_PACKAGE_NAME) \
		--install-layout deb; \
	done

%:
	dh $@ --with=python2