File: rules

package info (click to toggle)
pastedeploy 2.0.1-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 396 kB
  • sloc: python: 1,278; makefile: 107
file content (27 lines) | stat: -rwxr-xr-x 897 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
#!/usr/bin/make -f
export PYBUILD_NAME=pastedeploy
export PYBUILD_AFTER_INSTALL=rm -rf {destdir}{install_dir}/paste/deploy/paster_templates;\
       			     rm {destdir}{install_dir}/*.pth;\
			     rm {destdir}{install_dir}/*/namespace_packages.txt

DOCS=$(shell cd docs &&\
     find ./ -maxdepth 1 -name "*.rst" -not -name "license.txt" -printf "%p " |\
     sed "s/.rst//g")

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

override_dh_installdocs:
	set -e; for NAME in $(DOCS); do \
	    rst2html --cloak-email-addresses --no-toc-backlinks "docs/$$NAME.rst" \
	      > "$(CURDIR)/debian/python-pastedeploy/usr/share/doc/python-pastedeploy/docs/$$NAME.html"; \
	done
	dh_installdocs

override_dh_installchangelogs:
	dh_installchangelogs $(CURDIR)/docs/news.rst

override_dh_auto_test:
	PYBUILD_SYSTEM=custom \
	    PYBUILD_TEST_ARGS="{interpreter} setup.py pytest" \
	    dh_auto_test