#!/usr/bin/make -f

%:
	dh $@

PO_DIR = $(CURDIR)/debian/libpadre-plugin-css-perl/usr/share/perl5/auto/share/dist/Padre-Plugin-CSS/locale

override_dh_auto_test:
	mkdir -p tmp-home
	HOME="$(CURDIR)/tmp-home" xvfb-run -a dh_auto_test

override_dh_clean:
	dh_clean
	rm -rf "$(CURDIR)/tmp-home"

override_dh_auto_install:
	dh_auto_install
	rm $(PO_DIR)/*.mo
	for f in $(PO_DIR)/*.po; do \
	    msgfmt $$f -o $${f%.po}.mo ; \
	    rm $$f ;\
	    echo `basename $$f` ;\
	    done
	rm $(PO_DIR)/*.pot

