#!/usr/bin/make -f

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

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

%:
	dh $@ --parallel --dbg-package=libnetworkmanagerqt-dbg

override_dh_auto_configure:
	dh_auto_configure -- -DLIB_DESTINATION=/usr/lib/$(DEB_HOST_MULTIARCH)

run_dh_acc:
	# The package needs to be installed (@ in autopkgtest)
	for in_file in debian/*.acc.in; do \
	    out_file=$${in_file%.in}; \
	    sed 's/@DEB_HOST_MULTIARCH@/'"$(DEB_HOST_MULTIARCH)"'/' \
	        "$${in_file}" > "$${out_file}"; \
	done

	dh_acc
