#!/usr/bin/make -f
# -*- makefile -*-

# Uncomment this to turn on verbose mode.
export DH_VERBOSE=1

# Path to package source directory. Needed so that we can call get-orig-source
# from within any working directory.
PKGDIR := $(dir $(firstword $(MAKEFILE_LIST)))..


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


override_dh_auto_build:
	dh_auto_build
	
	cd docs && a2x --xsltproc-opts=--nonet -f manpage gitinspector.txt
	cd docs && a2x --xsltproc-opts=--nonet -f xhtml gitinspector.txt


override_dh_auto_install:
	dh_auto_install
	# We don't need to install a copy of the GPL-3, we have it locally
	rm -f $(CURDIR)/debian/gitinspector/usr/share/doc/gitinspector/LICENSE.txt


override_dh_auto_clean:
	dh_auto_clean
	
	rm -f docs/gitinspector.xml
	rm -f docs/gitinspector.1
	rm -f docs/gitinspector.html
