#!/usr/bin/make -f

export DH_OPTIONS += --dbg-package=libaa1-dbg

override_dh_auto_configure:
	dh_auto_configure -- --with-curses-driver

override_dh_auto_build:
	${MAKE}
	${MAKE} -C doc

override_dh_installdocs:
	dh_installdocs --link-doc=libaa1

# Empty dependency_libs field http://wiki.debian.org/ReleaseGoals/LAFileRemoval
# fixes non-empty-dependency_libs-in-la-file
override_dh_install:
	dh_install
	sed -i "/dependency_libs/ s/'.*'/''/" debian/libaa1-dev/usr/lib/*/libaa.la

# Version 1.2 is not compatable with version 1.0, so override the
# shlibs to force a >= 1.2 dependency on packages built with aalib.
override_dh_makeshlibs:
	dh_makeshlibs -V 'libaa1 (>= 1.2)'

%:
	dh $@ --with autoreconf
