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


include /usr/share/dpkg/pkg-info.mk

%:
	dh $@ --with python3 --buildsystem=pybuild

override_dh_auto_configure:
	pod2man --section=1 --release=$(DEB_SOURCE) --center "" doc/rapid-photo-downloader.1.pod > rapid-photo-downloader.1
	pod2man --section=1 --release=$(DEB_SOURCE) --center "" doc/analyze-pv-structure.1.pod > analyze-pv-structure.1

override_dh_auto_clean:
	-rm -f rapid-photo-downloader.1
	-rm -f analyze-pv-structure.1
	-rm -rf build/
	dh_auto_clean

override_dh_installchangelogs:
	dh_installchangelogs CHANGES.rst


# gir1.2-unity-5.0 is not in Debian yet
ifeq ($(shell dpkg-vendor --query vendor),Ubuntu)
override_dh_gencontrol:
	dh_gencontrol -- -Vrapid-photo-downloader:Depends='gir1.2-unity-5.0'
endif
