#!/usr/bin/make -f

export DEB_BUILD_MAINT_OPTIONS = hardening=+all

%:
	dh $@

override_dh_auto_configure:
	dh_auto_configure -- \
		--enable-unittest=$(if $(filter nocheck,$(DEB_BUILD_OPTIONS)),no,yes)

override_dh_installdocs:
	dh_installdocs --all AUTHORS NEWS README.md README-Adobe.md

override_dh_install:
	find debian/tmp -name '*.la' -print -delete
	dh_install

# s390x isn't a desktop arch so temporarily ignore test failures LP: #1988266
override_dh_auto_test:
ifeq ($(DEB_HOST_ARCH), s390x)
	dh_auto_test || true
else
	dh_auto_test
endif
