#!/usr/bin/make -f

# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1

export DEB_BUILD_MAINT_OPTIONS=hardening=+all
export DEB_LDFLAGS_MAINT_APPEND=-Wl,--as-needed
export DEB_BUILD_OPTIONS=parallel=$(shell grep processor /proc/cpuinfo | wc -l)

DEB_HOST_MULTIARCH?=$(shell dpkg-architecture -qDEB_HOST_MULTIARCH)

CONFIG=--prefix=/usr
INSTALLDIR=debian/tmp

override_dh_auto_configure:
	dh_auto_configure --parallel -- $(CONFIG)

override_dh_auto_install:
	dh_auto_install --parallel --destdir=$(CURDIR)/$(INSTALLDIR)

override_dh_installchangelogs:
	dh_installchangelogs ChangeLog

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

override_dh_builddeb:
	dh_builddeb -- -Z xz
