#!/usr/bin/make -f
# -*- makefile -*-
# This code is released under the BSD-3 Clause
# Created by Eric Maeker, 2012 - 2014
# Modified by Stefan Ahlers, 2016

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

export DEB_BUILD_MAINT_OPTIONS = hardening=+bindnow

# Enable multiarch builds & prepare qmake vars
include /usr/share/dpkg/architecture.mk

%:
	dh $@

override_dh_auto_configure:
	dh_auto_configure -- \
		-DBUILD_WITH_QT4=OFF \
		-DLIB_SUFFIX=/$(DEB_HOST_MULTIARCH) \
		-DCMAKE_POLICY_VERSION_MINIMUM=3.5 \
		-DCMAKE_POSITION_INDEPENDENT_CODE=ON
	cp NEWS.txt NEWS

execute_after_dh_auto_build-indep:
	# build doc
	doxygen
	find doc/html -name "*.md5" -delete
