#!/usr/bin/make -f

export DEB_BUILD_MAINT_OPTIONS = hardening=+all

# libkim-api-dev bakes the full path of the Fortran compiler that was used to
# build kim-api into /usr/share/cmake/kim-api-items/kim-api-items-macros.cmake
# and forces CMAKE_Fortran_COMPILER to it.  That path is version-qualified
# (currently /usr/bin/gfortran-15) and disappears as soon as the gcc default
# moves on, which makes the build fail in a minimal chroot that only has the
# gfortran we build-depend on.  KIM_API_CMAKE_Fortran_COMPILER is a plain
# (non-FORCE) cache variable, so pre-seeding it here wins.
override_dh_auto_configure:
	dh_auto_configure -- -DKIM_API_CMAKE_Fortran_COMPILER=/usr/bin/gfortran

%:
	dh $@
