#!/usr/bin/make -f #export DH_VERBOSE=1 export PYBUILD_NAME=astroquery export PYBUILD_TEST_PYTEST=1 export PYBUILD_TEST_ARGS=../../../astroquery export http_proxy=127.0.0.1:9 export HOME=$(shell mktemp -d) BUILD_DATE = $(shell LC_ALL=C date -u "+%B %d, %Y" -d "@$(SOURCE_DATE_EPOCH)") SPHINXOPTS := -D html_last_updated_fmt="$(BUILD_DATE)" -D html_show_copyright=0 %: dh $@ --with python3,sphinxdoc --buildsystem=pybuild override_dh_auto_build: dh_auto_build # remove references to build or temporary directories in the doc cp astroquery/hitran/core.py hitran.old sed -i "s#FORMATFILE = .*#FORMATFILE = ''#" astroquery/hitran/core.py cp astroquery/vamdc/__init__.py vamdc.old sed -i "s#cache_location = .*#cache_location = ''#" astroquery/vamdc/__init__.py # build doc PYTHONPATH=. sphinx-build $(SPHINXOPTS) -N -bhtml docs/ build/html # HTML generator # restore original files mv hitran.old astroquery/hitran/core.py mv vamdc.old astroquery/vamdc/__init__.py override_dh_sphinxdoc: dh_sphinxdoc rm -rf debian/python-astroquery-doc/usr/share/doc/python-astroquery-doc/html/_sources/license.rst.txt override_dh_auto_clean: dh_auto_clean rm -f astroquery/version.py rm -rf api rm -rf .cache rm -rf astroquery.egg-info override_dh_auto_install: dh_auto_install rm -rf debian/python3-astroquery/usr/astroquery.splatalogue override_dh_fixperms: dh_fixperms chmod a+x debian/python3-astroquery/usr/lib/python3/dist-packages/astroquery/alma/tests/data/downloadRequest*