#! /usr/bin/make -f

export PYBUILD_NAME=hjson

%:
	dh $@ --buildsystem=pybuild

override_dh_auto_test:
	set -e; for build in .pybuild/cpython3_*_hjson/build; do \
		ln -sr hjson/tests/assets $$build/hjson/tests/; \
	done
	dh_auto_test
	rm .pybuild/cpython3_*_hjson/build/hjson/tests/assets

execute_after_dh_auto_install:
	# Drop the hjson tool as long as nobody asks for it
	rm \
		debian/python3-hjson/usr/bin/hjson \
		debian/python3-hjson/usr/bin/hjson.cmd
