#!/usr/bin/make -f

#export DH_VERBOSE = 1
export QT_SELECT := qt5
DPKG_EXPORT_BUILDFLAGS = 1
export DEB_BUILD_MAINT_OPTIONS = hardening=+all
export DEB_CFLAGS_MAINT_APPEND  = -Wall -pedantic
export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed

include /usr/share/dpkg/pkg-info.mk

%:
	dh $@ --with kf5

override_dh_auto_configure:
	dh_auto_configure -Skf5 -- -DKDE_INSTALL_BINDIR=/usr/games -DQML_BOX2D_MODULE=disabled

override_dh_missing:
	dh_missing --fail-missing

override_dh_strip:
	dh_strip --dbgsym-migration='gcompris-qt-dbg (<< 0.81-1~)'

# Use an epoch for the transitional gcompris package, because of the break in
# numbering scheme introduced by the Qt rewrite
override_dh_gencontrol:
	dh_gencontrol -pgcompris -- -v1:$(DEB_VERSION)
	dh_gencontrol --remaining-packages

override_dh_auto_clean:
	dh_auto_clean
	find src -name '*.qrc' -delete
	rm -f src/activities/activities_out.txt
