#!/usr/bin/make -f
%:
	dh $@

INC_DIR=$(CURDIR)/debian/tmp/usr/include
INC_DIR_ARCH=$(INC_DIR)/$(DEB_BUILD_MULTIARCH)

override_dh_auto_configure:
	dh_auto_configure -- --enable-doc --enable-tests

override_dh_auto_build:
	dh_auto_build
	$(MAKE) html

override_dh_auto_install:
	dh_auto_install
	mkdir -p $(INC_DIR_ARCH)
	mv $(INC_DIR)/spandsp.h $(INC_DIR_ARCH)/

override_dh_clean:
	$(RM) -rf doc/api/html/
	$(RM) -f doc/t38_manual/*.html
	dh_clean 

override_dh_changelogs:
	dh_installchangelogs ChangeLog

override_dh_link:
	$(RM) -f debian/libspandsp-doc/usr/share/doc/libspandsp-doc/api/html/jquery.js
	dh_link
