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

# see EXAMPLES in dpkg-buildflags(1) and read /usr/share/dpkg/*
DPKG_EXPORT_BUILDFLAGS = 1
include /usr/share/dpkg/default.mk

# see FEATURE AREAS in dpkg-buildflags(1)
export DEB_BUILD_MAINT_OPTIONS = hardening=+all

# see ENVIRONMENT in dpkg-buildflags(1)
# package maintainers to append CFLAGS
export DEB_CFLAGS_MAINT_APPEND  = -Wall -pedantic
# package maintainers to append LDFLAGS
#export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed

%:
	dh $@

override_dh_auto_configure:
	-test -f final/font/fonts.alias && cp final/font/fonts.alias final/font/xfonts-finalcut-newfont.alias || true
	dh_auto_configure

override_dh_auto_clean:
	-test -f final/font/xfonts-finalcut-newfont.alias && rm final/font/xfonts-finalcut-newfont.alias
	dh_auto_clean

#override_dh_fixperms:
#	dh_fixperms
#	find debian/ -name 'COPYING*gz' -exec rm {} \;
#	cd debian/libfinal-examples/usr/share/doc/libfinal/examples && chmod +x 7segment background-color busy calculator checklist choice dialog event-log fullwidth-character hello input-dialog keyboard listbox listview mandelbrot menu mouse opti-move rotozoomer scrollview string-operations term-attributes termcap timer transparent treeview ui watch windows

#override_dh_strip:
#	dh_strip
#	cd debian/libfinal-examples/usr/share/doc/libfinal/examples && strip 7segment background-color busy calculator checklist choice dialog event-log fullwidth-character hello input-dialog keyboard listbox listview mandelbrot menu mouse opti-move rotozoomer scrollview string-operations term-attributes termcap timer transparent treeview ui watch windows

override_dh_missing:
	dh_missing --list-missing

override_dh_compress:
	dh_compress -X.cpp
# -X7segment -Xbackground-color -Xbusy -Xcalculator -Xchecklist -Xchoice -Xdialog -Xevent-log -Xfullwidth-character -Xhello -Xinput-dialog -Xkeyboard -Xlistbox -Xlistview -Xmandelbrot -Xmenu -Xmouse -Xopti-move -Xrotozoomer -Xscrollview -Xstring-operations -Xterm-attributes -Xtermcap -Xtimer -Xtransparent -Xtreeview -Xui -Xwatch -Xwindows
