#!/usr/bin/make -f

export DH_VERBOSE = 1

our_host_platform := $(shell $(CC) -dumpmachine || uname -p || arch)

%:
	exec dh $@ --parallel --builddirectory=build

override_dh_update_autotools_config:
	# Nope, do not touch config.sub or config.guess .

override_dh_auto_configure:
	# See redist-ppa.sh .
	exec dh_auto_configure -O--parallel -- \
	    --infodir=/usr/ia16-elf/info \
	    --target=ia16-elf --disable-gdb --disable-libdecnumber \
	    --disable-readline --disable-sim --disable-nls \
	    --with-system-zlib --disable-static --enable-shared

override_dh_auto_test:
	# Do not run the test suite at this stage.

override_dh_shlibdeps:
	exec dh_shlibdeps -O--parallel -O--builddirectory=build \
	    -l/usr/"$(our_host_platform)"/ia16-elf/lib
