#
# Makefile rules for the NormalizInterface package
#
KEXT_NAME = NormalizInterface
KEXT_SOURCES = src/normaliz.cc

KEXT_CXXFLAGS = -I/build/gap/src/gap-4.11.0/pkg/NormalizInterface/NormalizInstallDir/include -std=c++11
KEXT_LDFLAGS = -lstdc++ -R/build/gap/src/gap-4.11.0/pkg/NormalizInterface/NormalizInstallDir/lib -L/build/gap/src/gap-4.11.0/pkg/NormalizInterface/NormalizInstallDir/lib -lnormaliz

KEXT_RECONF ?= ./config.status Makefile

# include shared GAP package build system
GAPPATH = /build/gap/src/gap-4.11.0
include Makefile.gappkg

# react to modifications of the build system
configure: configure.ac $(wildcard m4/*.m4)
	@if command -v autoconf >/dev/null 2>&1 ; then \
	   echo "running autoconf" ; \
	   autoconf ; \
	 else \
	   echo "autoconf not available, proceeding with stale configure" ; \
	 fi

# re-run configure if configure, Makefile.in or GAP itself changed
config.status: configure $(GAPPATH)/sysinfo.gap
	./config.status --recheck

Makefile: config.status
