dealii - add platform-introspection variant (#37833)

This option is needed for DFT FE - or more accurately the check needs to
be checked off for a number of platforms or else the code doesn't work.

Signed-off-by: Howard Pritchard <howardp@lanl.gov>
This commit is contained in:
Howard Pritchard 2023-05-29 02:56:03 -06:00 committed by GitHub
parent 27c8135207
commit 783be9b350
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -105,6 +105,7 @@ class Dealii(CMakePackage, CudaPackage):
# (NB: only if tbb is removed in 9.3, as planned!!!)
variant("threads", default=True, description="Compile with multi-threading via TBB")
variant("trilinos", default=True, description="Compile with Trilinos (only with MPI)")
variant("platform-introspection", default=True, description="Enable platform introspection")
# Required dependencies: Light version
depends_on("blas")
@ -635,6 +636,12 @@ def cmake_args(self):
# See https://github.com/dealii/dealii/issues/9164
options.append(self.define("DEAL_II_CXX_FLAGS", os.environ["SPACK_TARGET_ARGS"]))
# platform introspection - needs to be disabled in some environments
if "+platform-introspection" in spec:
options.append(self.define("DEAL_II_ALLOW_PLATFORM_INTROSPECTION", True))
else:
options.append(self.define("DEAL_II_ALLOW_PLATFORM_INTROSPECTION", False))
return options
def setup_run_environment(self, env):