#!/usr/bin/make -f

export DEB_BUILD_MAINT_OPTIONS = hardening=+all

export DEB_CXXFLAGS_MAINT_APPEND  = -flto -DUSE_LD
export DEB_LDFLAGS_MAINT_APPEND  = -flto

export PKG_CONFIG_PATH=/usr/lib/$(DEB_HOST_MULTIARCH)/pkgconfig/

%:
	dh $@ --buildsystem=cmake --sourcedirectory=. --builddirectory=build

# The soundtrack is only needed by the arch-independent data package:
# compress the 32-bit float WAV to FLAC, the intro reads it with libsndfile.
override_dh_install-indep:
	sox rel/adarkar_wastes.wav rel/adarkar_wastes.flac
	dh_install -i
