#!/usr/bin/make -f

DEB_DH_INSTALL_DIR=$(CURDIR)/debian/tmp

override_dh_auto_configure:
	dh_auto_configure

libpuzzle-build-stamp:
	dh_auto_build
	touch $@

override_dh_auto_build:
	pod2man --center "" --date "" --release "" --section=1 \
		debian/manpages/puzzle-diff.pod -o debian/puzzle-diff.1
	pod2man --center "" --date "" --release "" --section=3 \
		debian/manpages/libpuzzle.pod   -o debian/libpuzzle.3
	pod2man --center "" --date "" --release "" --section=3 \
		debian/manpages/puzzle_set.pod  -o debian/puzzle_set.3

override_dh_auto_install:
	dh_auto_install

override_dh_auto_clean:
	dh_auto_clean
	# Clean built manpages
	rm -f debian/puzzle-diff.1 debian/libpuzzle.3 debian/puzzle_set.3

%:
	dh $@ --with autoreconf
