#!/usr/bin/make -f # DH_VERBOSE := 1 export LC_ALL=C.UTF-8 BUILT_USING_SECRECY = $(shell \ dpkg-query \ -f '$${source:Package} (= $${source:Version}), ' \ -W 'libsecrecy-dev' \ ) # include /usr/share/dpkg/default.mk # for hardening you might like to uncomment this: # export DEB_BUILD_MAINT_OPTIONS=hardening=+all %: dh $@ override_dh_install: dh_install # following override suggestion from suggestion of Andreas to Michael # to overcome d-shlibmove bug on Jan 4, 2019 d-shlibmove --commit \ --multiarch \ --devunversioned \ --exclude-la \ --override s/libdeflate0-dev/libdeflate-dev/ \ --override s/libmaus2_.*-dev/libmaus2-dev/ \ --override 's/libnettle.*-dev/nettle-dev/' \ --movedev debian/tmp/usr/include/* usr/include \ --movedev "debian/tmp/usr/lib/*/pkgconfig/*.pc" usr/lib/$(DEB_HOST_MULTIARCH)/pkgconfig \ debian/tmp/usr/lib/*/*.so # Remove unneeded options from *.pc files find debian -name "*.pc" -exec sed -i -e 's/-Wdate-time *//' -e 's/-D_FORTIFY_SOURCE=2 *//' \{\} \; # avoid noise from dh-missing by deleting unneeded files find debian/tmp -type f -name "*.la" -delete # Changelog is installed via dh_installchangelogs rm -f debian/tmp/usr/share/doc/libmaus2/changelog.gz override_dh_installchangelogs: dh_installchangelogs ChangeLog override_dh_gencontrol: dh_gencontrol -- -Vlibsecrecy:Built-Using="$(BUILT_USING_SECRECY)" ### When overriding auto_test make sure DEB_BUILD_OPTIONS will be respected #override_dh_auto_test: #ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS))) # do_stuff_for_testing #endif