d05f2fb2d5
If the application executable was built against a pre-macOS 11 SDK, macOS will report its version as 10.16 on every OS from macOS 11 and up, for compatibility reasons. From Qt 6.2 and up, we require at least Xcode 12 with the macOS 11 SDK to build Qt applications, so normally this should not be an issue, but in the case where the Qt 'app' is a plugin library hosted by a third party host application, the host application determines the behavior, and we might end up in the compatibility situation after all. However, since the Qt app was built against at least the macOS 11 SDK, we know that it can/should handle the new version number scheme, and we can resolve the real version number for QOperatingSystemVersion. We do that by launching the sysctl binary with the SYSTEM_VERSION_COMPAT environment variable set to 0, which is the supported way of disabling the compatibility mode. Now that we have the real version number we can use that for the deployment target check via qt_apple_check_os_version(), but we still need to account for possible failures in reading the plist file. We can also simplify the QOperatingSystemVersion::MacOSBigSur definition, now that we always know the app the should be able to handle major versions above 10. Pick-to: 6.5 6.4 6.2 Task-number: QTBUG-111114 Change-Id: I2a2756381c31b195f7b8800c5008a87b37114080 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> |
||
---|---|---|
.github/workflows | ||
bin | ||
cmake | ||
coin | ||
config.tests | ||
dist | ||
doc | ||
examples | ||
lib | ||
libexec | ||
LICENSES | ||
mkspecs | ||
qmake | ||
src | ||
tests | ||
util | ||
.cmake.conf | ||
.gitattributes | ||
.gitignore | ||
.lgtm.yml | ||
.tag | ||
CMakeLists.txt | ||
conanfile.py | ||
config_help.txt | ||
configure | ||
configure.bat | ||
configure.cmake | ||
dependencies.yaml | ||
qt_cmdline.cmake | ||
sync.profile |