Skip to content

Commit 7c33927

Browse files
authored
dealii: use cmake option to set c++ standard (spack#1522)
* use cmake option to set c++ standard * use define_from_variant
1 parent b6fc100 commit 7c33927

File tree

1 file changed

+1
-2
lines changed
  • repos/spack_repo/builtin/packages/dealii

1 file changed

+1
-2
lines changed

repos/spack_repo/builtin/packages/dealii/package.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -498,8 +498,7 @@ def cmake_args(self):
498498

499499
# Enforce the specified C++ standard
500500
if spec.variants["cxxstd"].value != "default":
501-
cxxstd = spec.variants["cxxstd"].value
502-
cxx_flags.extend(["-std=c++{0}".format(cxxstd)])
501+
options.append(self.define_from_variant("CMAKE_CXX_STANDARD", "cxxstd"))
503502

504503
# Performance
505504
# Set recommended flags for maximum (matrix-free) performance, see

0 commit comments

Comments
 (0)