#!/usr/bin/make -f
%:
	dh $@

override_dh_auto_build:
	phpabtpl composer.json > debian/autoload.php.tpl
	phpab \
		--output lib/Doctrine/Common/Collections/autoload.php \
		--template debian/autoload.php.tpl \
		lib/Doctrine/Common/Collections
	mkdir --parents vendor
	phpabtpl \
		--require doctrine/collections \
		> debian/autoload.tests.php.tpl
	phpab \
		--output vendor/autoload.php \
		--template debian/autoload.tests.php.tpl \
		tests/Doctrine/Tests

override_dh_auto_test:
	phpunit --include-path lib --bootstrap vendor/autoload.php

override_dh_installchangelogs:
	dh_installchangelogs -k README.md
