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

configure_flags +=  --prefix=/usr \
					--disable-pymod-checks \
					--enable-gtk-doc \
					--with-gconf-schema-file-dir=/etc/gconf/schemas


%:
	dh --with python2 $@

override_dh_auto_configure:
	dh_auto_configure -- 	$(configure_flags)

override_dh_strip:
	dh_strip --dbg-package=libawn1-dbg

override_dh_install:
	#Remove .la, .a, pyo and pyc files.
	find debian/tmp/usr/lib/ -name *.a |xargs rm
	find debian/tmp/usr/lib -name *.la |xargs rm
	find debian/tmp/usr/lib -name *.pyc |xargs rm
	find debian/tmp/usr/lib -name *.pyo |xargs rm
	dh_install --fail-missing

override_dh_auto_test:
	#Pass, tests don't pass for now.

override_dh_makeshlibs:
	dh_makeshlibs -pavant-window-navigator -a -n --exclude=*
	dh_makeshlibs -plibawn1  -V"libawn1 (>= 0.4.0)"

override_dh_python2:
	dh_python2 --no-guessing-versions
