#!/usr/bin/make -f

PYTHON2=$(shell pyversions -dv)
#PYTHON3=$(shell py3versions -sv)

# Prevent setuptools/distribute from accessing the internet.
export http_proxy = http://127.0.9.1:9

%:
	dh $@

override_dh_installdocs:
	python setup.py build_sphinx
	dh_installdocs build/sphinx/html

override_dh_installman:
	(cd debian/manpage; \
	 sphinx-build -b man -d _build/doctrees . _build/man)
	dh_installman debian/manpage/_build/man/tox.1

override_dh_installchangelogs:
	dh_installchangelogs CHANGELOG

override_dh_auto_clean:
	dh_auto_clean
	rm -rf build
	rm -rf *.egg-info
	rm -rf debian/manpage/_build

get-orig-source:
	uscan --noconf --force-download --repack --rename \
		--download-current-version --verbose
