#!/usr/bin/make -f
export DEB_BUILD_MAINT_OPTIONS=hardening=+all

# testsuite assumes binaries to be tested are under build/
%:
	dh $@ --buildsystem=meson --builddir=build

override_dh_auto_test:
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
	mkdir -p test/bash-tap/
	ln -s -t test/bash-tap $(CURDIR)/debian/bash-tap/*
	mkdir -p test/test-simple-bash
	ln -s -t test/test-simple-bash $(CURDIR)/debian/test-simple-bash/*

	dh_auto_test -- -v --timeout-multiplier 100

	rm test/bash-tap/*
	rm test/test-simple-bash/*
endif
