#!/usr/bin/make -f

#export DH_VERBOSE=1


export DEB_CFLAGS_MAINT_APPEND  := -pipe -Wall
export DEB_LDFLAGS_MAINT_APPEND := -Wl,--no-undefined


# export variables for autoreconf
export AUTOMAKE := automake --foreign


%:
	dh $@

override_dh_auto_configure:
	dh_auto_configure -- $(confflags)

override_dh_install:
        # copy files (modifying header includes) to install as examples in the
        # -dev package
	sed -e 's:"SDL.h":\<SDL.h\>:' -e 's:"SDL_ttf.h":\<SDL_ttf.h\>:' showfont.c > debian/showfont.c
	sed -e 's:"SDL.h":\<SDL.h\>:' -e 's:"SDL_ttf.h":\<SDL_ttf.h\>:' glfont.c > debian/glfont.c

	dh_install --fail-missing -XlibSDL_ttf.la

override_dh_auto_installchangelogs:
	dh_auto_installchangelogs -- CHANGES
