Skip to content

Enforce the CMake C++ standard requirement - #348

Open
masterleinad wants to merge 1 commit into
kokkos:developfrom
masterleinad:default_build_type
Open

masterleinad wants to merge 1 commit into
kokkos:developfrom
masterleinad:default_build_type

Conversation

@masterleinad

@masterleinad masterleinad commented Sep 15, 2026 •

Copy link
Copy Markdown
Contributor

Compiling with gcc-14 didn't work because we just used -std=c++1z and couldn't find the filesystem header.

Comment thread CMakeLists.txt
message(FATAL_ERROR "KokkosTools requires C++20")
endif()

set(CMAKE_CXX_STANDARD_REQUIRED ON)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not add CXX_STANDARD_REQUIRED to the Kokkos target?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Which target do you mean?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

kokkoscore

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We are only linking with Kokkos::kokkos in the tests; the tools libraries don't dependent on kokkoscore.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, I misunderstood the intend then

Comment thread CMakeLists.txt
message(FATAL_ERROR "KokkosTools requires C++20")
endif()

set(CMAKE_CXX_STANDARD_REQUIRED ON)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, I misunderstood the intend then

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants