Details
-
Suggestion
-
Resolution: Fixed
-
P2: Important
-
6.6
-
None
-
-
2802d1deb (dev), 45e3f4a6d (6.6), 9ef864f56 (dev), 87ccb0b48 (6.6)
Description
We currently require CMake 3.16 for shared builds, and 3.21 for static builds, both for building Qt and using Qt in user projects.
CMake 3.16 unfortunately doesn't have a feature we rely on on Apple platforms, finalizers (cmake_language(DEFER CALL) to be exact), requiring us to maintain additional APIs for users to manually finalize their projects, with caveats and sharp corners.
We would like to bump the minimum CMake version to 3.21 for apple platforms, for both shared and static builds.
In reality this would only affect macOS shared Qt builds, and user projects using such a Qt, because all static builds already require 3.21.
This will allow us provide a cleaner and more robust API for user projects, with potential for more to come due to the availability of new CMake features.
Bumping the minimum should not be a problem, because most macOS developers get their CMake from homebrew, which ships the latest available version.
From the technical side, we should ensure:
- all documentation is up-to-date
- our internal and public api that check for the minimum cmake version should be adjusted to the new version.
this might require some extra code, and not just be a version bump, to be investigated.
Relevant documentation locations:
https://doc.qt.io/qt-6/cmake-get-started.html
https://doc.qt.io/qt-6/macos-building.html
https://doc.qt.io/qt-6/qt6-buildsystem.html
https://code.qt.io/cgit/qt/qt5.git/tree/README.md
https://wiki.qt.io/Building_Qt_6_from_Git