#!/usr/bin/make -f

PACKAGE = $(shell dh_listpackages)
TMP     = $(CURDIR)/debian/$(PACKAGE)

%:
	dh $@

override_dh_clean:
	dh_clean
	rm -vrf $(CURDIR)/t/var/splat \
		$(CURDIR)/t/dist/MB/Build \
		$(CURDIR)/t/dist/MB/_build \
		$(CURDIR)/t/dist/MB/blib \
		$(CURDIR)/t/dist/EUMM/Makefile \
		$(CURDIR)/t/dist/EUMM/pm_to_blib \
		$(CURDIR)/t/dist/EUMM/blib

override_dh_auto_install:
	dh_auto_install
	# Remove installed /usr/share/perl5/POD2/DE/local/lib.pod
	rm $(TMP)/usr/share/perl5/POD2/DE/local/lib.pod
	rmdir --ignore-fail-on-non-empty --parents --verbose $(TMP)/usr/share/perl5/POD2/DE/local
