Skip to content

Conversation

mathstuf
Copy link
Contributor

No description provided.

This is true because the code considers 3.29 in the next block. Of
particular importance, this sets CMP0115 which scans C++20 sources by
default. This allows tests to use `add_executable(t uses_module.cpp)`
without having to explicitly say "I want to use `import ctre;`".

In the non-module build, explicitly turn off scanning since it is not
used.
@mathstuf mathstuf force-pushed the cmake-module-behavior branch from a9f8f81 to 3b0298f Compare September 16, 2024 17:36
@hanickadot
Copy link
Owner

why is there maximum version of 3.29?

@mathstuf
Copy link
Contributor Author

That is not a "maximum version". It is a "maximum tested version". It is saying "CMake 3.14 is required, but the project has been tested against all new policy behaviors up to 3.29 and accepts the new behaviors".

@hanickadot hanickadot merged commit f3f5588 into hanickadot:main Sep 16, 2024
@hanickadot
Copy link
Owner

Thanks!

@billhoffman
Copy link

By setting the max version of cmake to 3.29 it changes the policy so that CXX_SCAN_FOR_MODULES is on by default which is important for modules.

@mathstuf mathstuf deleted the cmake-module-behavior branch September 16, 2024 20:01
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.

3 participants