#!/usr/bin/make -f
export PYTHONDONTWRITEBYTECODE=yes
export PYBUILD_NAME=axiom

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


override_dh_auto_test:
	PYBUILD_SYSTEM=custom \
	PYBUILD_TEST_ARGS="{interpreter} /usr/bin/trial axiom" \
	PYBUILD_AFTER_TEST="find {build_dir} -name dropin.cache -delete" \
	dh_auto_test


override_dh_installchangelogs:
# The upstream sdist lacks NEWS.txt, so we ship our own copy
# See: https://github.com/twisted/axiom/issues/75
	dh_installchangelogs debian/NEWS.txt


override_dh_clean:
	dh_clean
	rm -rf _trial_temp
