File: rules

package info (click to toggle)
sqlite-utils 3.38-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,544 kB
  • sloc: python: 14,245; makefile: 33; ansic: 26; javascript: 21; sh: 5
file content (26 lines) | stat: -rwxr-xr-x 617 bytes parent folder | download | duplicates (3)
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

export PYBUILD_NAME=sqlite-utils
%:
	dh $@ --buildsystem=pybuild

override_dh_auto_build:
	dh_auto_build $@ --buildsystem=pybuild
	cd docs; make man; LC_ALL=C.UTF-8 LANGUAGE=C.UTF-8 sphinx-build -bhtml . _build/html

override_dh_auto_test:
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
	$(eval BUILD_DIR=$(shell pybuild --print '{build_dir}'))
	for dir in $(BUILD_DIR); do \
		mkdir $$dir/docs; \
		cp docs/*.rst $$dir/docs ; \
	done
	dh_auto_test
	for dir in $(BUILD_DIR); do \
		rm -r $$dir/docs ; \
	done
endif

override_dh_auto_clean:
	dh_auto_clean
	rm -rf sqlite_utils.egg-info docs/_build