#!/usr/bin/make -f

# DH_VERBOSE := 1

export DEB_BUILD_MAINT_OPTIONS = hardening=+all

DEBPKGNAME     := $(shell dpkg-parsechangelog | awk '/^Source:/ {print $$2}')

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

override_dh_auto_configure:
	dh_auto_configure -- LDFLAGS="$(LDFLAGS) -Wl,--as-needed" LIBS="$(LIBS) -latomic"

override_dh_install:
	dh_install
	# for the moment the role of these scripts is totally unknown but they do not seem to be necessary
	rm -f debian/$(DEBPKGNAME)/usr/bin/*.py
	rm -f debian/$(DEBPKGNAME)/usr/bin/validate_blat*
