CXX_STD = CXX17

# The C++ core is compiled directly into the package shared object. `configure`
# stages the required core sources under `core/` and generates the `OBJECTS`
# list below (models / stats / serialization / utils / strategies — the CLI,
# io, golden and test translation units are excluded, so `fmt`, `csv-parser`
# and CMake are not needed to build the R package). Eigen is provided by
# RcppEigen (see LinkingTo); nlohmann/json and pcg are vendored under
# `../inst/include`.
#
# Compiling every strategy object straight into the shared library (rather than
# linking a static archive) means the self-registering strategies cannot be
# dead-stripped — no whole-archive link trickery is required.

PKG_CPPFLAGS = -I../inst/include -Icore/include -Icore/src -DNDEBUG -DEIGEN_NO_DEBUG -DEIGEN_DONT_PARALLELIZE -DEIGEN_NO_AUTOMATIC_RESIZING -DEIGEN_PERMANENTLY_DISABLE_STUPID_WARNINGS
PKG_CXXFLAGS = $(SHLIB_OPENMP_CXXFLAGS) @DARWIN_OPENMP_CXXFLAGS@
PKG_LIBS = $(SHLIB_OPENMP_CXXFLAGS) @DARWIN_OPENMP_LIBS@

OBJECTS = @OBJECTS@
