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

override_dh_auto_test:
ifeq (,$(findstring nocheck, $(DEB_BUILD_OPTIONS)))
	phpunit
	phpcs -s --extensions=php --standard=build/code-sniffer-ruleset.xml phpseclib
	phpcs -s --extensions=php --standard=build/code-sniffer-ruleset-tests.xml tests
else
	@echo "** tests disabled"
endif

override_dh_installdeb:
	mv $(CURDIR)/debian/php-seclib/usr/share/php/Crypt/Blowfish.php \
	   $(CURDIR)/debian/php-seclib/usr/share/php/Crypt/Blowfish-phpseclib.php
	dh_installdeb

get-orig-source:
	uscan --verbose --force --rename
