#!/usr/bin/make -f
#export DH_VERBOSE=1

%:
	dh $@  --parallel --sourcedirectory=VolViewPlatformComplete

override_dh_auto_configure:
	dh_auto_configure -- -DCMAKE_BUILD_TYPE:STRING=RelWithDebInfo

override_dh_compress:
	dh_compress -X.pdf

override_dh_installdocs:
	# I could not figure out how to handle space in the filename with dh_installdocs
	#echo "$(DEB_BUILD_GNU_TYPE)"
	mkdir -p debian/volview/usr/share/doc/volview/
	mv "debian/volview/usr/doc/VolView 3 User Manual.pdf" debian/volview/usr/share/doc/volview/VolView3UserManual.pdf
	rmdir debian/volview/usr/doc
	dh_installdocs

override_dh_auto_install:
	dh_auto_install
	mv debian/volview/usr/bin/Plugins debian/volview/usr/lib/VolView
	mv debian/volview/usr/bin/VolView debian/volview/usr/lib/VolView

get-orig-source:
	./debian/get-orig-source
