#!/usr/bin/make -f

export DEB_BUILD_MAINT_OPTIONS=hardening=+all

LDFLAGS+=-Wl,--as-needed

%:
	dh $@ --parallel --with autoreconf

DH_AS_NEEDED=$(shell dpkg --compare-versions $$(dpkg --status dh-autoreconf | grep Version | cut -d' ' -f2) ge 6 && echo --as-needed)
override_dh_autoreconf:
	[ ! -x "./autogen.sh" ] || ./autogen.sh
	intltoolize --automake --copy --force
	dh_autoreconf $(DH_AS_NEEDED)

override_dh_auto_configure:
	dh_auto_configure -- --enable-notify
