#!/usr/bin/make -f

export DEB_LDFLAGS_MAINT_APPEND := -Wl,-z,defs -Wl,-O1 -Wl,--as-needed

%:
	dh $@ --with autoreconf,gnome

override_dh_auto_configure:
	dh_auto_configure -- --libdir=$$\{prefix}/lib \
	--enable-ipv6 \
	--enable-suid=no

override_dh_installchangelogs:
	dh_installchangelogs ./NEWS

override_dh_installdocs:
	dh_installdocs -A ./AUTHORS

override_dh_strip:
	dh_strip --dbgsym-migration='gnome-applets-dbg (<< 3.20.0-1~)'

override_dh_auto_build:
	dh_auto_build
	docbook-to-man debian/cpufreq-selector.sgml > debian/cpufreq-selector.1

override_dh_install:
	rm -f debian/tmp/usr/lib/gnome-applets/*.la
	dh_install --list-missing

override_dh_auto_clean:
	rm -f debian/cpufreq-selector.1
