#!/usr/bin/make -f

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

export DEB_BUILD_MAINT_OPTIONS = hardening=+all
U=debian/uptimed

%:
	dh $@

override_dh_auto_install:
	dh_auto_install

	cp $(U)/etc/uptimed.conf-dist $(U)/etc/uptimed.conf
	cp libuptimed/urec.h $(U)/usr/include/uptimed.h

	dh_auto_install -Dlibuptimed

override_dh_auto_build:
	dh_auto_build
	cd debian && LC_ALL=C onsgmls uptimed.conf.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl
