StanfordLegion / legion

The Legion Parallel Programming System
https://legion.stanford.edu
Apache License 2.0
675 stars 145 forks source link

cmake complains that gcc 12.2.0 doesn't support C++17 #1700

Closed jpietarilagraham closed 3 months ago

jpietarilagraham commented 3 months ago

Cmake identifies the compiler is gcc 12.2.0 but then erroneously claims the compiler doesn't support c++17.

spack-build-out.txt

elliottslaughter commented 3 months ago

You are explicitly passing C++ 11 to the CMake command line:

-DCMAKE_CXX_STANDARD:STRING=11
jpietarilagraham commented 3 months ago

This is off the master branch. 24.03.0 is fine.

elliottslaughter commented 3 months ago

This is a bug in the Legion Spack package, which apparently has not been updated. Legion now requires C++ 17.

Until the Spack package gets updated you would need to build with the variant cxxstd=17. Otherwise Spack explicitly builds for C++ 11 and Legion of course objects.

elliottslaughter commented 3 months ago

Potential fix posted to https://github.com/spack/spack/pull/44596

@jpietarilagraham If you'd like to test, I think you can clone my Spack fork (assuming you have no other local changes you need).

elliottslaughter commented 3 months ago

Fixed by https://github.com/spack/spack/pull/44596.