Repository navigation
cmake: require CMake 3.16 (fixes #139) - #144
Conversation
|
An automated preview of the documentation is available at https://144.openmethod.prtest3.cppalliance.org/libs/openmethod/doc/html/index.html If more commits are pushed to the pull request, the docs will rebuild at the same URL. 2026-11-07 17:22:11 UTC |
The library declared cmake_minimum_required(VERSION 3.8...), but the tests use target_precompile_headers, which needs 3.16, so configuring the superproject with BUILD_TESTING=ON failed on CMake 3.8 to 3.15. 3.16 is the version that was actually tested: Boost.CI's minimum-CMake job ran 3.16 until it began deriving the version from this file. It is also what Ubuntu 20.04 ships, and every toolchain the library supports (gcc 10 or later) comes with it or newer. 3.8 dates from April 2017 and was never shipped by any Ubuntu release. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
aa04f4c to
d6f3929
Compare
|
@pdimov I have to wait Nov 12 (Boost 1.93.0 open for bug fixes) to merge into master, correct? And request permission from release managers? |
|
Blocked by boostorg/boost-ci#358 |
Correct. |
|
While this is the correct long term solution, I would prefer if we fix that now by checking the CMake version around the |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #144 +/- ##
========================================
Coverage 92.56% 92.57%
========================================
Files 29 29
Lines 2314 2316 +2
Branches 699 699
========================================
+ Hits 2142 2144 +2
Misses 111 111
Partials 61 61 Continue to review full report in Codecov by Harness.
🚀 New features to boost your workflow:
|
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
(Written by Claude Code, on behalf of @jll63.)
Fixes #139 (#139).
The library declared
cmake_minimum_required(VERSION 3.8...3.20), but the tests usetarget_precompile_headers, which needs CMake 3.16. As a result, configuring the superproject with-DBUILD_TESTING=ONfailed on CMake 3.8 through 3.15 (boostorg/cmake run 41556485068).This PR raises the declared minimum to 3.16 instead of making the tests work on older versions:
CMakeLists.txtboost-ci#355 (2026-11-05) made it read the version fromCMakeLists.txt. Since then it tries 3.8, which fails before reaching our code: CMake 4 refuses to build CMake 3.8, because CMake 3.8 declarescmake_minimum_required(VERSION 2.8.12.2).The change is two
cmake_minimum_requiredlines (root andtest/cmake_test).The failing Min. CMake job
The
Min. CMake, 3.16job fails, but not because of this change: it fails before configuring anything of ours. Sinceubuntu-latestmoved to ubuntu-26.04, the runner's CMake 4 cannot build CMake 3.16 from source either, because it rejects the oldcmake_minimum_requiredin 3.16'sSource/kwsys/CMakeLists.txt. The same job passed on develop on 2026-11-03, when it still ran on ubuntu-24.04. The CMake cache missed in both runs, so the image is the only thing that changed. Every library using the reusable workflow will hit this until Boost.CI adds-DCMAKE_POLICY_VERSION_MINIMUM=3.5to its CMake build flags.Testing
-DBUILD_TESTING=ON -DBOOST_INCLUDE_LIBRARIES=openmethod, Debug, PCH generated, 142/142 openmethod tests pass.🤖 Generated with Claude Code