-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Upgrade build to use CMake 3.26 #120823
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
base: main
Are you sure you want to change the base?
Upgrade build to use CMake 3.26 #120823
Conversation
Co-authored-by: Alexander Köplinger <[email protected]>
…s from the RESCAN and WHOLE_ARCHIVE lists as they don't apply.
… same objects into singlefilehost directly (which is causing a conflict now)
|
Tagging subscribers to this area: @dotnet/runtime-infrastructure |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR upgrades the minimum required CMake version from 3.20 to 3.26 across the dotnet/runtime repository. This enables the use of newer CMake features and aligns with the project's infrastructure requirements for .NET 11, with the version constraint determined by RHEL9 compatibility.
Key changes include:
- Updating
cmake_minimum_requireddirectives throughout the codebase - Modernizing CMake syntax to use newer features available in 3.26
- Updating build infrastructure and documentation
Reviewed Changes
Copilot reviewed 36 out of 36 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| src/coreclr/CMakeLists.txt | Updated minimum CMake version to 3.26 |
| src/mono/CMakeLists.txt | Updated minimum CMake version and replaced /Zi with CMAKE_MSVC_DEBUG_INFORMATION_FORMAT |
| src/native/corehost/CMakeLists.txt | Updated minimum CMake version to 3.26 |
| src/native/libs/CMakeLists.txt | Updated minimum CMake version to 3.26 |
| src/tests/CMakeLists.txt | Updated minimum CMake version to 3.26 |
| eng/native/configurecompiler.cmake | Modernized linker option syntax and added support for newer CMake features |
| eng/native/configureplatform.cmake | Replaced manual Linux ID detection with cmake_host_system_information |
| eng/native/functions.cmake | Removed obsolete compile_asm function no longer needed with CMake 3.26 |
| src/coreclr/dlls/mscoree/coreclr/CMakeLists.txt | Replaced manual whole-archive handling with $<LINK_LIBRARY:WHOLE_ARCHIVE> |
| src/native/corehost/apphost/static/CMakeLists.txt | Replaced manual whole-archive handling with $<LINK_LIBRARY:WHOLE_ARCHIVE> |
| src/coreclr/ilasm/CMakeLists.txt | Replaced start/end group syntax with $<LINK_GROUP:RESCAN> |
| src/coreclr/ildasm/exe/CMakeLists.txt | Removed manual library group handling and updated linker options |
| src/coreclr/dlls/mscordac/CMakeLists.txt | Replaced start/end group syntax with $<LINK_GROUP:RESCAN> and $<LINK_LIBRARY:WHOLE_ARCHIVE> |
| src/coreclr/jit/CMakeLists.txt | Updated linker flag syntax to use add_link_options(LINKER:-Bsymbolic) |
| src/coreclr/vm/wks/CMakeLists.txt | Removed obsolete compile_asm calls for Visual Studio generator |
| src/coreclr/nativeaot/Runtime/Full/CMakeLists.txt | Removed obsolete compile_asm calls and introduced Runtime.AsmHelpers object library |
| src/coreclr/debug/ee/wks/CMakeLists.txt | Removed obsolete compile_asm calls and removed /Zi from ASM_OPTIONS |
| src/native/libs/System.Security.Cryptography.Native/CMakeLists.txt | Updated CMake version range upper bound to 3.26 |
| src/native/libs/System.Globalization.Native/CMakeLists.txt | Updated CMake version range upper bound to 3.26 |
| src/libraries/tests.proj | Updated generated CMakeLists.txt templates to require CMake 3.26 |
| docs/workflow/requirements/*.md | Updated documentation to reflect CMake 3.26 minimum requirement |
| eng/pipelines/common/*.yml | Updated container images to use Debian 13 with GCC 15 |
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Adeel Mujahid <[email protected]>
|
/ba-g ARM64 queue is on the floor. WBT failure unrelated. |
|
rescan and whole archive make sense - just need to get a build to make sure we don't regress this again. |
Continuation of #103088 for .NET 11 (because of RHEL9, our maximum CMake version is still 3.26)
Blocked on dotnet/dotnet-buildtools-prereqs-docker#1520