#!/usr/bin/make -f
# See debhelper(7) (uncomment to enable)
# output every command that modifies files on the build system.
#DH_VERBOSE = 1

# see EXAMPLES in dpkg-buildflags(1) and read /usr/share/dpkg/*
DPKG_EXPORT_BUILDFLAGS = 1
include /usr/share/dpkg/default.mk

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

override_dh_auto_configure:
	./configure \
	  --host=$(DEB_HOST_GNU_TYPE) \
	  --build=$(DEB_BUILD_GNU_TYPE) \
	  --prefix=/usr \
	  --sysconfdir=/etc/dnsdist \
	  --mandir=\$${prefix}/share/man \
	  --infodir=\$${prefix}/share/info \
	  --libdir='$${prefix}/lib/$(DEB_HOST_MULTIARCH)' \
	  --libexecdir='$${prefix}/lib' \
	  --enable-reproducible \
	  --enable-libsodium

override_dh_auto_build-arch:
	dh_auto_build -- V=1

override_dh_installinit:
	# do nothing here. avoids referencing a non-existant init script.

