#!/usr/bin/make -f
	
export PYBUILD_NAME=flask
export PYBUILD_AFTER_INSTALL=rm -rf '{destdir}/{install_dir}/site_egg'

%:
	dh $@ --with python2,python3,sphinxdoc --buildsystem pybuild

override_dh_auto_test:
	LC_ALL=C.UTF-8 http_proxy='' dh_auto_test

override_dh_install:
	dh_install

	rm $(CURDIR)/debian/python-flask/usr/bin/flask

override_dh_sphinxdoc:
ifeq (,$(findstring nodocs, $(DEB_BUILD_OPTIONS)))
	http_proxy='http://127.0.0.1:9/' PYTHONPATH=. sphinx-build -N -q -E -b html docs/ debian/python-flask-doc/usr/share/doc/python-flask-doc/html/
	dh_sphinxdoc
endif
