#!/usr/bin/make -f
# -*- makefile -*-

PYVERS = $(shell pyversions -vr)
PYVER = $(shell pyversions -vd)

%:
	dh $@ --buildsystem=python_distutils

override_dh_clean:
	rm -rf *.egg-info
	dh_clean

override_dh_auto_test: ${PYVERS:%=python-test%}

python-test%:
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
	python$* setup.py nosetests;
else
	: # Skip unittests due to nocheck
endif


override_dh_installchangelogs:
	dh_installchangelogs CHANGES.rst
