#!/usr/bin/make -f

#export DH_VERBOSE=1
PYBUILD_NAME=spyne

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

get-orig-source:
	uscan --force-download

#
# A bit of a kludge to work around upstream shipping spyne.egg-info, which
# is a work directory created by setup.py.  We have to preserve it, so that
# the source directory looks indentical once we are done.
#
override_dh_clean:
	dh_clean
	[ ! -d spyne.egg-info.orig ] || { rm -rf spyne.egg-info; mv spyne.egg-info.orig spyne.egg-info; }

override_dh_auto_install:
	[ ! -d spyne.egg-info -o -d spyne.egg-info.orig ] || mv spyne.egg-info spyne.egg-info.orig
	dh_auto_install
	# kill sort_wsdl
	rm -r debian/python-spyne/usr/bin


override_dh_auto_test:
	echo "Tests disabled because it requires pyparsing <= 1.99."
