#!/usr/bin/make -f

# The template generator is built outside maven-debian-helper, so it needs the
# Debian settings and the local repository populated by dh_auto_configure.
MVN = mvn --batch-mode --offline -s /etc/maven/settings-debian.xml \
          -Dmaven.repo.local=$(CURDIR)/debian/maven-repo

%:
	dh $@ --buildsystem=maven --with javahelper

override_dh_auto_clean:
	rm -rf debian/template-generator/target
	dh_auto_clean

override_dh_auto_build:
	(cd debian/template-generator && $(MVN) package)
	dh_auto_build
