[CMAKE] bump cmake minimum required version to 3.14#3349
[CMAKE] bump cmake minimum required version to 3.14#3349lalitb merged 18 commits intoopen-telemetry:mainfrom
Conversation
…including the min version. update the conan stable file to test older versions of benchmark and prometheus-cpp
✅ Deploy Preview for opentelemetry-cpp-api-docs canceled.
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #3349 +/- ##
=======================================
Coverage 89.56% 89.56%
=======================================
Files 210 210
Lines 6502 6502
=======================================
Hits 5823 5823
Misses 679 679 🚀 New features to boost your workflow:
|
…ake 3.15. Set the windows job to cmake 3.15
…iables. Remove legacy PROTOBUF_FOUND.
|
|
||
| ubuntu_2204_script_build_grpc_1_55_0: | ||
| name: Ubuntu 22.04 script grpc 1.55.0 cxx17 (static libs - shared libs) | ||
| ubuntu_2204_stable: |
There was a problem hiding this comment.
Q: CMAKE_VERSION specified for most jobs, except a this and macos_14_brew_packages. Any particular reason for that ?
There was a problem hiding this comment.
The setup_cmake* scripts default to cmake 3.31.6 now. The scripts in the main ci.yml workflow also use the default.
I'm not apposed to setting CMAKE_VERSION in every job explicitly if others feel strongly.
There was a problem hiding this comment.
The cmake version can be found in the ci logs at two places:
Verifying installed versions...
cmake version: 3.31.6 detected
ctest version: 3.31.6 detected
cpack version: 3.31.6 detected-- ---------------------------------------------
-- versions
-- ---------------------------------------------
-- CMake: 3.31.6
-- GTest: 1.16.0
-- benchmark: 1.9.2
-- Abseil: 20240722
-- Protobuf: 29.3.0
-- gRPC: 1.71.0
-- CURL: 8.6.0
-- ZLIB: 1.2.12
-- nlohmann-json: 3.11.3
-- prometheus-cpp: 1.3.0
-- ---------------------------------------------There was a problem hiding this comment.
I don't have a strong opinion on whether the version should be explicitly specified either, but if the version is only being specified on certain jobs due to some technical constraints (like CI fails if we the default cmake version is used), I do think it is worthwhile to document why the version is being explicitly mentioned on those jobs.
This would be helpful in the future if and when we re-visit this file to upgrade or modify the jobs.
I'm not an expert on CMake, so I'll defer the final decision to you though 👍🏻
There was a problem hiding this comment.
Thanks for the feedback. I've updated the cmake install test workflow to set the version explicitly for all jobs.
but if the version is only being specified on certain jobs due to some technical constraints (like CI fails if we the default cmake version is used), I do think it is worthwhile to document why the version is being explicitly mentioned on those jobs.
Great point. The only cases I'm aware of where ci fails based on the cmake version is windows with 3.14 (comment added to the CMake Install Test github workflow) and with cmake 4.0.0 (documented in #3334).
… error on protobuf version warning. Remove bzip2 as dependency for conan builds
…all test job. Add newline to the end of setup_cmake.ps1
…ommend cmake 3.15+ on windows.
…t failures with cmake 3.14
| # https://github.com/grpc/grpc/pull/33361 for more details. | ||
| include(CMakeFindDependencyMacro) | ||
|
|
||
| # Protobuf 3.22+ and depends on abseil-cpp and must be found using the CONFIG |
There was a problem hiding this comment.
| # Protobuf 3.22+ and depends on abseil-cpp and must be found using the CONFIG | |
| # Protobuf 3.22+ depends on abseil-cpp and must be found using the CONFIG |
There was a problem hiding this comment.
And what does it mean for "must be found using the CONFIG search mode"? Seems module mode is also tried.
There was a problem hiding this comment.
It is referencing the cmake find_package search modes. The module mode is also tried to ensure capability with protobuf packages that don't include the cmake config file (which enables the config search mode). For example the Ubuntu packages for libprotobuf must be found with the module search mode.
There was a problem hiding this comment.
Updated the comment to be clear this is the cmake find_package search mode.
| grpc/1.54.3 | ||
| nlohmann_json/3.10.5 | ||
| prometheus-cpp/1.3.0 | ||
| prometheus-cpp/1.2.4 |
There was a problem hiding this comment.
Why is version downgraded here?
There was a problem hiding this comment.
Is prometheus 1.2.4 support expected?
There was a problem hiding this comment.
Why is version downgraded here?
The conan based install tests have a "latest" and "stable" conanfile in install/conan. The conan file for "latest" includes prometheus-cpp/1.3.0. I downgraded prometheus-cpp version in the "stable" conan file to ensure the previous version was also tested.
Fixes #3348
Changes
For significant contributions please make sure you have completed the following items:
CHANGELOG.mdupdated for non-trivial changes