#!/usr/bin/make -f

export DEB_BUILD_MAINT_OPTIONS=hardening=+all

%:
	dh $@ --with python3

override_dh_auto_build:
	dh_auto_build --sourcedirectory=figtoipe
	dh_auto_build --sourcedirectory=ipe5toxml
	dh_auto_build --sourcedirectory=pdftoipe

override_dh_install:
#	svgtoipe has no Makefile and the script is called svgtoipe.py
	install -D -p svgtoipe/svgtoipe.py $(CURDIR)/debian/svgtoipe/usr/bin/svgtoipe
#	install -D -p svgtoipe/svgtoipe.1 $(CURDIR)/debian/svgtoipe/usr/man/man1/svgtoipe.1

	dh_install

override_dh_auto_clean:
	$(MAKE) -C figtoipe clean
	$(MAKE) -C ipe5toxml clean
	$(MAKE) -C pdftoipe clean
