#!/usr/bin/make -f
# -*- makefile -*-

CMAKE_EXTRA_FLAGS := -DBUILD_EXPERIMENTAL:BOOL=OFF
CMAKE_EXTRA_FLAGS += -DENABLE_FINAL:BOOL=ON
CMAKE_EXTRA_FLAGS += -DCMAKE_EXE_LINKER_FLAGS:STRING="$(LDFLAGS) -Wl,--as-needed"
CMAKE_EXTRA_FLAGS += -DCMAKE_SHARED_LINKER_FLAGS:STRING="$(LDFLAGS) -Wl,--as-needed"

%:
	dh $@

get-orig-source:
	uscan --verbose --force-download

override_dh_auto_configure:
	dh_auto_configure -- $(CMAKE_EXTRA_FLAGS)

override_dh_strip:
	dh_strip -a --dbg-package=s3d-dbg

override_dh_installdocs:
	dh_installdocs -A README Documentation/RelNotes*

.PHONY: get-orig-source
