summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMÃ¥rten Nordheim <marten.nordheim@qt.io>2022-01-24 16:01:17 +0100
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2022-01-25 08:59:25 +0000
commit9ef5cc08f78e1d2393b60a22eb4f4d14cf4b9bcb (patch)
tree5633dd9257a2fc26034a1c6a94e44f55138050eb
parentfa16f96850fef4c8af01af6c123be41bb0a6561d (diff)
QOperatingSystemVersion: fix #if check for macos version check
It would check the version regardless of OS, but this macro doesn't exist on non-darwin platforms. Amends 3446313c7a5cd6005089866a7b20c9f28e132a0a Change-Id: I7bdc302c85626d410e77bea1eb7aac7fbf1cb679 Reviewed-by: Marc Mutz <marc.mutz@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> (cherry picked from commit 4b6064aef434baf7e382b3994f046a2f96fa7111) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
-rw-r--r--src/corelib/global/qoperatingsystemversion.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/corelib/global/qoperatingsystemversion.h b/src/corelib/global/qoperatingsystemversion.h
index 2ab08a5427..07aae4d67f 100644
--- a/src/corelib/global/qoperatingsystemversion.h
+++ b/src/corelib/global/qoperatingsystemversion.h
@@ -201,7 +201,7 @@ public:
static constexpr QOperatingSystemVersionBase MacOSHighSierra { QOperatingSystemVersionBase::MacOS, 10, 13 };
static constexpr QOperatingSystemVersionBase MacOSMojave { QOperatingSystemVersionBase::MacOS, 10, 14 };
static constexpr QOperatingSystemVersionBase MacOSCatalina { QOperatingSystemVersionBase::MacOS, 10, 15 };
-#if QT_MACOS_PLATFORM_SDK_EQUAL_OR_ABOVE(__MAC_11_0)
+#if !defined(Q_OS_DARWIN) || QT_MACOS_PLATFORM_SDK_EQUAL_OR_ABOVE(__MAC_11_0)
static constexpr QOperatingSystemVersionBase MacOSBigSur = { QOperatingSystemVersionBase::MacOS, 11, 0 };
static constexpr QOperatingSystemVersionBase MacOSMonterey = { QOperatingSystemVersionBase::MacOS, 12, 0 };
#else // ### Qt 7: Verify the assumption