#!/usr/bin/make -f
export QT_SELECT=5

MAKE_OPTS  = QMAKE=qmake-qt5 LRELEASE=lrelease-qt5 QMAKE_OPTS="$(QMAKE_OPTS)"

override_dh_auto_clean:
	dh_auto_clean
	rm -f src/translations/*.qm

override_dh_auto_build:
	lrelease *.pro
	head -n1 debian/changelog | sed -e "s/.*(\([^(]*\)).*/#define VERSION \"\1\"/" > version.h
	dh_auto_build -- $(MAKE_OPTS)

override_dh_auto_install:
	dh_auto_install -- $(MAKE_OPTS)

override_dh_shlibdeps:
	dh_shlibdeps -- -xvirtualbox-guest-x11 --ignore-missing-info

%:
	dh $@ --no-automatic-dbgsym --parallel 
