#!/usr/bin/make -f
-include /usr/share/gnome-pkg-tools/1/rules/gnome-get-source.mk

export DEB_BUILD_MAINT_OPTIONS = hardening=+all
export DEB_LDFLAGS_MAINT_APPEND = -Wl,-z,defs -Wl,--as-needed

%:
	dh $@ --with gnome

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

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:
	find debian/tmp -name '*.la' -print -delete
	dh_install

override_dh_missing:
	dh_missing --fail-missing

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