#!/usr/bin/make -f

export DEB_BUILD_MAINT_OPTIONS = hardening=+all

%:
	dh $@

override_dh_auto_clean:
	make clean || true
	rm -f ssrf-version.h
	rm -f subsurface
	rm -f Makefile

override_dh_auto_configure:
	qmake

override_dh_installchangelogs:
	dh_installchangelogs
	dh_installchangelogs ReleaseNotes.txt 
	txt2html Documentation/user-manual.txt > Documentation/user-manual.html
	cp Documentation/user-manual.txt debian/subsurface/usr/share/doc/subsurface/
	cp Documentation/user-manual.html debian/subsurface/usr/share/doc/subsurface/html
