File: rules

package info (click to toggle)
python-bugzilla 2.2.0-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 480 kB
  • sloc: python: 4,268; makefile: 14
file content (24 lines) | stat: -rwxr-xr-x 756 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
#!/usr/bin/make -f

export PYBUILD_NAME = bugzilla
export PYBUILD_AFTER_INSTALL_python2 = $(RM) -rv {destdir}/usr/bin {destdir}/usr/share/man

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

override_dh_auto_test:
# Setting $HOME here is needed because some tests use
# 'os.path.expanduser'.
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
	set -ex; for py in $(shell pyversions -r) $(shell py3versions -r); do \
		HOME=/tmp/ $$py -m pytest; \
	done
endif

override_dh_install:
	dh_install
# We have a dedicated package for the CLI part of the package, so here
# we delete the files under /usr/bin.
	rm -rf debian/python3-bugzilla/usr/bin
# We also ship the CLI manpage within the appropriate package.
	rm -rf debian/python3-bugzilla/usr/share/man