Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmake: Raise min to 3.6 #4288

Merged
merged 1 commit into from
Jun 20, 2023
Merged

cmake: Raise min to 3.6 #4288

merged 1 commit into from
Jun 20, 2023

Conversation

juan-lunarg
Copy link
Contributor

From the CMake 3.27 release notes:
Compatibility with versions of CMake older than 3.5 is now deprecated and will be removed from a future version. Calls to cmake_minimum_required() or cmake_policy() that set the policy version to an older value now issue a deprecation diagnostic.

This PR also removes manually setting policy CMP0048. This is redundant since the CMake min is already 3.X

@google-cla
Copy link

google-cla bot commented Jun 19, 2023

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

Comment on lines -6 to -8
if (POLICY CMP0048)
cmake_policy(SET CMP0048 NEW)
endif (POLICY CMP0048)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Manually setting this policy is only necessary if the minimum is 2.X

It's safe to remove this code since the min is 3.6

https://cmake.org/cmake/help/latest/policy/CMP0048.html#policy:CMP0048

From the CMake 3.27 release notes:
Compatibility with versions of CMake older than 3.5 is now
deprecated and will be removed from a future version. Calls to
cmake_minimum_required() or cmake_policy() that set the policy
version to an older value now issue a deprecation diagnostic.

This PR also removes manually setting policy CMP0048. This is
redundant since the CMake min is already 3.X
@dinord dinord self-assigned this Jun 20, 2023
@copybara-service copybara-service bot merged commit 2983697 into google:main Jun 20, 2023
@juan-lunarg juan-lunarg deleted the juan/cmake_min_3_dot_6 branch June 20, 2023 15:24
@juan-lunarg
Copy link
Contributor Author

@dinord why was the min raised to 3.13?

I'm fine with raising the min to 3.13 just curious:

@dinord
Copy link
Collaborator

dinord commented Jun 20, 2023

We used your change to bump the min to 3.13 because that's the oldest officially supported version of CMake, as per https://opensource.google/documentation/policies/cplusplus-support.

@juan-lunarg
Copy link
Contributor Author

Cool beans 👍🏾

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