#!/usr/bin/make -f
# -*- makefile -*-

export DEB_BUILD_MAINT_OPTIONS = hardening=+all

# Mir 1 is no longer available in recent Debian or Ubuntu
TRUST_STORE_MIR_AGENT_ENABLED = OFF
ifeq ($(shell dpkg-vendor --derives-from Ubuntu && echo yes),yes)
        TRUST_STORE_MIR_AGENT_ENABLED = OFF
endif

# The home directory of user buildd does not exist on the builders
export XDG_DATA_HOME=/tmp

%:
	dh $@

override_dh_auto_configure:
	dh_auto_configure -- \
		-DTRUST_STORE_MIR_AGENT_ENABLED=$(TRUST_STORE_MIR_AGENT_ENABLED) \
		-DTRUST_STORE_WAYLAND_AGENT_ENABLED=ON

override_dh_auto_test:
	DH_COMPAT=12 dh_auto_test --no-parallel

get-orig-source:
	uscan --noconf --force-download --rename --download-current-version --destdir=..
