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 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42
|
#!/usr/bin/make -f
#export DH_VERBOSE=1
export PYBUILD_NAME=fdb
DOC_PACKAGE=python-$(PYBUILD_NAME)-doc
DOC_DIR=usr/share/doc/$(DOC_PACKAGE)/html
%:
#dh $@ -v --with python2,python3,sphinxdoc --buildsystem=pybuild
dh "$@" -v --with python2,python3 --buildsystem=pybuild
get-orig-source:
uscan --force-download
override_dh_auto_build:
dh_auto_build
rm -rf docs
$(MAKE) --directory sphinx html
rm -rf html
mv docs html
override_dh_installdocs:
dh_installdocs $(DH_INTERNAL_OPTIONS) --no-package=$(DOC_PACKAGE) README
dh_installdocs $(DH_INTERNAL_OPTIONS) --package=$(DOC_PACKAGE) html
dh_sphinxdoc $(DH_INTERNAL_OPTIONS) --package=$(DOC_PACKAGE) $(DOC_DIR)
debian/ras-sphinxdoc.sh $(DOC_PACKAGE)/$(DOC_DIR)
#
# A bit of a kludge to work around upstream shipping a prebuilt docs
# directory. We want to build our own so we can be 100% certain
# the shipped .js files come from Debian's python-sphinx's package.
#
override_dh_clean:
dh_clean $(DH_INTERNAL_OPTIONS)
[ ! -d $(PYBUILD_NAME).egg-info.orig ] || { rm -rf $(PYBUILD_NAME).egg-info; mv $(PYBUILD_NAME).egg-info.orig $(PYBUILD_NAME).egg-info; }
$(MAKE) --directory sphinx clean
rm -rf html debian/missing-sources
override_dh_auto_install:
[ ! -d $(PYBUILD_NAME).egg-info -o -d $(PYBUILD_NAME).egg-info.orig ] || mv $(PYBUILD_NAME).egg-info $(PYBUILD_NAME).egg-info.orig
dh_auto_install $(DH_INTERNAL_OPTIONS)
|