#!/usr/bin/make -f

%:
	dh $@

override_dh_auto_build:
	phpabtpl composer.json > debian/autoload.php.tpl
	phpab \
		--output lib/Doctrine/Common/Annotations/autoload.php \
		--template debian/autoload.php.tpl \
		lib/Doctrine/Common/Annotations
	mkdir --parents vendor
	phpabtpl \
		--require-file ../lib/Doctrine/Common/Annotations/autoload.php \
		--require doctrine/cache \
		--require symfony/cache \
		--require-file ../tests/Doctrine/Tests/Common/Annotations/Fixtures/functions.php \
		--require-file ../tests/Doctrine/Tests/Common/Annotations/Fixtures/SingleClassLOC1000.php \
		> debian/autoload.tests.php.tpl
	phpab \
		--output vendor/autoload.php \
		--template debian/autoload.tests.php.tpl \
		--exclude */ClassNoNamespaceNoComment.php \
		tests/Doctrine/Tests

override_dh_auto_test:
	phpunit --exclude-group nophpunit11
