#!/usr/bin/make -f

DEB_UPSTREAM_VERSION := \
	$(shell dpkg-parsechangelog | sed -ne 's/^Version: \(.*\)+dfsg-.*/\1/p')

%:
	dh --with javahelper $@

override_dh_auto_build:
	# this file was dropped by accident from the orig source tarball
	cp debian/api.css docs/api.css
	ant dist

override_dh_auto_clean:
	ant clean
	rm -f docs/api.css

get-orig-source:
	uscan \
		--verbose \
		--no-symlink \
		--upstream-version $(DEB_UPSTREAM_VERSION) \
		--download-version $(DEB_UPSTREAM_VERSION) \
		--force-download
