#! /usr/bin/make -f include /usr/share/dpkg/pkg-info.mk %: dh $@ --buildsystem=phppear --with phppear SRCDIR = Crypt_GPG-$(DEB_VERSION_UPSTREAM) execute_before_dh_auto_configure: mkdir $(SRCDIR) ln -st $(SRCDIR) ../Crypt ../scripts ../tests ../LICENSE ../README.md override_dh_auto_test: # without --process-isolation there is a weird race condition # causing the tests to fails GnuPG when can't use /run/user/$UID as # socket directory (for instance because it's not there) and uses # its homedir as fallback -- removing the GNUPGHOME between each # test seems to cause problems when it contains the agent socket phpunit --include-path $(SRCDIR) ./$(SRCDIR)/tests \ --process-isolation --exclude-group write execute_after_dh_install: # not needed with gpg >=2.1.13 (Crypt_GPG uses `--pinentry-mode loopback` instead) rm $(CURDIR)/debian/php-crypt-gpg/usr/bin/crypt-gpg-pinentry rmdir --ignore-fail-on-non-empty $(CURDIR)/debian/php-crypt-gpg/usr/bin