| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
include /usr/share/dpkg/buildflags.mk |
| 7 |
|
| 8 |
DPKG_EXPORT_BUILDFLAGSscip-debian debian python-pyinstrument 5.1.2+ds-1 python-pyinstrument/rules/DPKG_EXPORT_BUILDFLAGS. = 1 |
| 9 |
export DEB_BUILD_MAINT_OPTIONSscip-debian debian python-pyinstrument 5.1.2+ds-1 python-pyinstrument/rules/DEB_BUILD_MAINT_OPTIONS. = hardening=+all |
| 10 |
export PYBUILD_NAMEscip-debian debian python-pyinstrument 5.1.2+ds-1 python-pyinstrument/rules/PYBUILD_NAME.=pyinstrument |
| 11 |
|
| 12 |
SPHINXOPTSscip-debian debian python-pyinstrument 5.1.2+ds-1 python-pyinstrument/rules/SPHINXOPTS. := -E -N |
| 13 |
|
| 14 |
%scip-debian debian python-pyinstrument 5.1.2+ds-1 python-pyinstrument/rules/`%`().: |
| 15 |
dh $@ --buildsystem=pybuild |
| 16 |
|
| 17 |
override_dh_auto_cleanscip-debian debian python-pyinstrument 5.1.2+ds-1 python-pyinstrument/rules/override_dh_auto_clean().: |
| 18 |
dh_auto_cleanscip-debian debian debhelper . dh_auto_clean(). |
| 19 |
rm -rf .mypy_cache .pytest_cache |
| 20 |
|
| 21 |
override_dh_sphinxdocscip-debian debian python-pyinstrument 5.1.2+ds-1 python-pyinstrument/rules/override_dh_sphinxdoc().: |
| 22 |
cd .pybuild && \ |
| 23 |
PYTHONPATH=$$PWD/`dirname $$(find . -type d -name "$(PYBUILD_NAMEscip-debian debian python-pyinstrument 5.1.2+ds-1 python-pyinstrument/rules/PYBUILD_NAME.)*dist-info" | sort | head -n1)` && \ |
| 24 |
PATH=$(shell realpath $$(find . -type d -name scripts | sort | head -n1)):$(PATHscip-debian debian python-pyinstrument 5.1.2+ds-1 python-pyinstrument/rules/PATH.) && \ |
| 25 |
export PYTHONPATH && \ |
| 26 |
export PATH && \ |
| 27 |
python3 -m sphinx -b man $(SPHINXOPTSscip-debian debian python-pyinstrument 5.1.2+ds-1 python-pyinstrument/rules/SPHINXOPTS.) ../docs $(CURDIRscip-debian debian python-pyinstrument 5.1.2+ds-1 python-pyinstrument/rules/CURDIR.)/debian |
| 28 |
ifeq (,$(findstringscip-debian debian python-pyinstrument 5.1.2+ds-1 python-pyinstrument/rules/findstring. nodoc, $(DEB_BUILD_OPTIONSscip-debian debian python-pyinstrument 5.1.2+ds-1 python-pyinstrument/rules/DEB_BUILD_OPTIONS.))) |
| 29 |
cd .pybuild && \ |
| 30 |
PYTHONPATH=$$PWD/`dirname $$(find . -type d -name "$(PYBUILD_NAME)*dist-info" | sort | head -n1)` && \ |
| 31 |
PATH=$(shell realpath $$(find . -type d -name scripts | sort | head -n1)):$(PATH) && \ |
| 32 |
export PYTHONPATH && \ |
| 33 |
export PATH && \ |
| 34 |
python3 -m sphinx -b html $(SPHINXOPTS) ../docs $(CURDIR)/debian/python-$(PYBUILD_NAME)-doc/usr/share/doc/python-$(PYBUILD_NAME)-doc/html |
| 35 |
rm -rf $(CURDIR)/debian/python-$(PYBUILD_NAME)-doc/usr/share/doc/python-$(PYBUILD_NAME)-doc/html/.doctree |
| 36 |
cp docs/img/screenshot.jpg $(CURDIR)/debian/python-$(PYBUILD_NAME)-doc/usr/share/doc/python-$(PYBUILD_NAME)-doc/html/_images |
| 37 |
sed -i -e 's,https:\/\/github.com\/joerick\/pyinstrument\/raw\/main\/docs\/img\/,file:\/\/\/usr\/share\/doc\/python-$(PYBUILD_NAME)-doc\/html\/_images\/,g' \ |
| 38 |
$(CURDIR)/debian/python-$(PYBUILD_NAME)-doc/usr/share/doc/python-$(PYBUILD_NAME)-doc/html/home.html |
| 39 |
endif |
| 40 |
dh_sphinxdocscip-debian debian debhelper . dh_sphinxdoc(). |
| 41 |
|
| 42 |
override_dh_fixpermsscip-debian debian python-pyinstrument 5.1.2+ds-1 python-pyinstrument/rules/override_dh_fixperms().: |
| 43 |
for FILE in `find $(CURDIRscip-debian debian python-pyinstrument 5.1.2+ds-1 python-pyinstrument/rules/CURDIR.)/debian/python3-$(PYBUILD_NAMEscip-debian debian python-pyinstrument 5.1.2+ds-1 python-pyinstrument/rules/PYBUILD_NAME.)/ -type f -name ".gitignore"`; do \ |
| 44 |
rm -rf $${FILE} ;\ |
| 45 |
done |
| 46 |
dh_fixpermsscip-debian debian debhelper . dh_fixperms(). |