Skip to content

Conversation

@cwsmith
Copy link
Contributor

@cwsmith cwsmith commented Oct 22, 2024

This PR adds a 'bob' cmake helper function to set the C++ standard. The modifications do not change the default behavior of using C++11. The user is given the ability to increase the standard to > C++11, or enable the use of extensions, by passing CMAKE_CXX_STANDARD and CMAKE_CXX_EXTENSIONS, respectively, to cmake.

Closes #448.

@cwsmith cwsmith changed the base branch from master to develop October 22, 2024 16:50
Added a 'bob' cmake helper function to set the C++ standard. The
modifications do not change the default behavior of using C++11. The
user is given the ability to increase the standard to > C++11, or enable
the use of extensions, by passing CMAKE_CXX_STANDARD and
CMAKE_CXX_EXTENSIONS, respectively, to cmake.

Following approach given in "Professional CMake: 19th Edition".
@cwsmith
Copy link
Contributor Author

cwsmith commented Oct 22, 2024

/runtests

@cwsmith cwsmith added the v2.2.9 label Oct 22, 2024
@github-actions
Copy link

Build Log
Simmetrix Test Result: success
Simmetrix + CGNS Test Result: failure

calling it more than once could be done if the standard was decreased, otherwise, the check against CMAKE_CXX_STANDARD will fail
@cwsmith
Copy link
Contributor Author

cwsmith commented Oct 22, 2024

/runtests

@github-actions
Copy link

Build Log
Simmetrix Test Result: success
Simmetrix + CGNS Test Result: success

@cwsmith cwsmith merged commit e39d19b into develop Oct 22, 2024
4 checks passed
@cwsmith cwsmith deleted the cws/cxx14cmake branch October 22, 2024 18:57
@cwsmith cwsmith mentioned this pull request Oct 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Use CMAKE_CXX_STANDARD to set C++14 standard

2 participants