summaryrefslogtreecommitdiffstats
path: root/mkspecs
diff options
context:
space:
mode:
Diffstat (limited to 'mkspecs')
-rw-r--r--mkspecs/features/mac/default_post.prf13
-rw-r--r--mkspecs/win32-clang-msvc/qmake.conf5
2 files changed, 16 insertions, 2 deletions
diff --git a/mkspecs/features/mac/default_post.prf b/mkspecs/features/mac/default_post.prf
index c46222debd..60b2eb2117 100644
--- a/mkspecs/features/mac/default_post.prf
+++ b/mkspecs/features/mac/default_post.prf
@@ -1,5 +1,9 @@
load(default_post)
+# Recompute SDK version in case the user set it explicitly
+sdk_version = $$QMAKE_MAC_SDK_VERSION
+QMAKE_MAC_SDK_VERSION = $$xcodeSDKInfo(SDKVersion)
+
contains(TEMPLATE, .*app) {
!macx-xcode:if(isEmpty(BUILDS)|build_pass) {
# Detect changes to the platform SDK
@@ -14,7 +18,7 @@ contains(TEMPLATE, .*app) {
!versionAtLeast(QMAKE_MAC_SDK_VERSION, $$QT_MAC_SDK_VERSION_MIN): \
warning("Qt requires at least version $$QT_MAC_SDK_VERSION_MIN of the platform SDK," \
- "you're using $${QMAKE_MAC_SDK_VERSION}. Please upgrade.")
+ "you're building against version $${QMAKE_MAC_SDK_VERSION}. Please upgrade.")
!isEmpty(QT_MAC_SDK_VERSION_MAX) {
# For Qt developers only
@@ -244,6 +248,11 @@ macx-xcode {
QMAKE_PCH_OUTPUT_EXT = _${QMAKE_PCH_ARCH}$${QMAKE_PCH_OUTPUT_EXT}
}
+!equals(sdk_version, $$QMAKE_MAC_SDK_VERSION) {
+ # Explicit SDK version has been set, respect that
+ QMAKE_LFLAGS += -Wl,-sdk_version -Wl,$$sdk_version
+}
+
cache(QMAKE_XCODE_DEVELOPER_PATH, stash)
!isEmpty(QMAKE_XCODE_VERSION): \
cache(QMAKE_XCODE_VERSION, stash)
@@ -261,7 +270,7 @@ xcode_product_bundle_identifier_setting.value = "$${xcode_product_bundle_identif
QMAKE_MAC_XCODE_SETTINGS += xcode_product_bundle_identifier_setting
!macx-xcode {
- generate_xcode_project.commands = @$(QMAKE) -spec macx-xcode $(EXPORT__PRO_FILE_)
+ generate_xcode_project.commands = @$(QMAKE) -spec macx-xcode $(EXPORT__PRO_FILE_) $$QMAKE_ARGS
generate_xcode_project.target = xcodeproj
QMAKE_EXTRA_VARIABLES += _PRO_FILE_
QMAKE_EXTRA_TARGETS += generate_xcode_project
diff --git a/mkspecs/win32-clang-msvc/qmake.conf b/mkspecs/win32-clang-msvc/qmake.conf
index 5da7e2d1b2..7279f77b40 100644
--- a/mkspecs/win32-clang-msvc/qmake.conf
+++ b/mkspecs/win32-clang-msvc/qmake.conf
@@ -39,6 +39,11 @@ QMAKE_CXXFLAGS += -Wno-microsoft-enum-value
QMAKE_LINK = lld-link
QMAKE_LIB = llvm-lib /NOLOGO
+QMAKE_CXXFLAGS_CXX11 = -std:c++11
+QMAKE_CXXFLAGS_CXX14 = -std:c++14
+QMAKE_CXXFLAGS_CXX1Z = -std:c++17
+QMAKE_CXXFLAGS_CXX2A = -std:c++latest
+
QMAKE_CFLAGS_LTCG = -flto=thin
QMAKE_CXXFLAGS_LTCG = $$QMAKE_CFLAGS_LTCG
QMAKE_CFLAGS_LTCG_FATOBJECTS = -flto