Debian Codegraph @

debian/rules

raw
1 #!/usr/bin/make -f
2
3 include /usr/share/dpkg/pkg-info.mk
4
5 REPORTBUG_VERSION := $(shell python3 -c "import reportbug; print(reportbug.VERSION_NUMBER)")
6 PEP440_DEB_VERSION := $(shell debian/make_pep440_compliant "$(DEB_VERSION)")
7
8 %:
9 dh $@ --with=python3
10
11 override_dh_auto_build:
12 # Test if versions are synchronized (only if releasing); this will bomb if not synced
13 if [ "$(DEB_DISTRIBUTION)" != "UNRELEASED" -a "$(REPORTBUG_VERSION)" != "$(PEP440_DEB_VERSION)" ] ; \
14 then \
15 echo 'Please update VERSION_NUMBER variable in reportbug/__init__.py to $(PEP440_DEB_VERSION)'; exit 1 ; \
16 fi
17
18 $(MAKE) convert-data
19 python3 setup.py build
20
21 override_dh_auto_install:
22 python3 setup.py install --root $(CURDIR)/debian/reportbug --install-layout=deb
23 mv $(CURDIR)/debian/reportbug/usr/lib $(CURDIR)/debian/python3-reportbug/usr
24 chmod 0755 $(CURDIR)/debian/reportbug/usr/bin/*
25 cp -p conf/reportbug.conf $(CURDIR)/debian/reportbug/etc
26
27 override_dh_installman:
28 dh_installman man/*