nlohmann / json

JSON for Modern C++
https://json.nlohmann.me
MIT License
41.46k stars 6.59k forks source link

Update minimum cmake version (#4076) #4080

Closed Nauroze closed 9 months ago

Nauroze commented 11 months ago

Resolves issue #4076 This commit updates the minimum cmake version 3.16, since 3.5 and below will be deprecated.

coveralls commented 11 months ago

Coverage Status

coverage: 100.0%. remained the same when pulling e68ffb66c01817dd2fe738ba9ec2075f8ca9e4f3 on Nauroze:update-min-cmake-version into 5d2754306d67d1e654a1a34e1d2e74439a9d53b3 on nlohmann:develop.

jmigual commented 11 months ago

So @nlohmann, I think this change is good enough and supports this CMake build script until CMake 3.27 is deprecated. Can this be merged?

t-b commented 11 months ago

I also think this PR is a pure improvement.

craigscott-crascit commented 11 months ago

The changes in this PR are insufficient, there are still various CMakeLists.txt files in the tests area which need updating as well. The shift all the way up to 3.27 also looks a bit risky to me to take as a single jump all at once. It would take a deeper analysis of all the policies between 3.1 and 3.27 to be sure none of them adversely affect the project.

I just open #4112 before seeing this PR here. My PR only lifts the upper range to CMake 3.14, but I did go through the project's CMake logic and I believe the policy changes are fine between 3.1 and 3.14. I also updated the tests area. Therefore, I recommend closing this PR here in favour of #4112, which is a safer, more complete change.

nlohmann commented 9 months ago

@Nauroze What do you think of #4112?

Nauroze commented 9 months ago

@Nauroze What do you think of #4112?

@nlohmann Yeah I'm good with that, it's more thorough as it is changing the CMakeLists.txt in the test directories as well.

Something to keep in mind: Since it uses 3.14 we have to look at changing this again in a few years if any future deprecation warnings come out. 3.27 would be a change for the long run. But I do understand picking 3.14 was a conservative choice and keeping it safe.

nlohmann commented 9 months ago

Closed in favor of #4112.