diff --git a/default.json b/default.json index 0870e3299..51dc0f0fe 100644 --- a/default.json +++ b/default.json @@ -26,7 +26,8 @@ "xplane": true, "fg": true }, - "profileRelease": true, + "releaseWithDebugInfo": true, + "profileRelease": false, "assertsInRelease": true, "allowNoisyWarnings": false, "packageInstaller": true, diff --git a/mkspecs/features/common_pre.prf b/mkspecs/features/common_pre.prf index ad9b59fd3..d0da0e10e 100644 --- a/mkspecs/features/common_pre.prf +++ b/mkspecs/features/common_pre.prf @@ -54,9 +54,19 @@ include(wordsize.pri) contains(TEMPLATE, "vc.*"): QMAKE_CXXFLAGS *= /MP ################################ -# Profile build +# Release build with debug info ################################ +swiftConfig(releaseWithDebugInfo):swiftConfig(profileRelease) { + error(releaseWithDebugInfo and profileRelease can not be enabled together,\ + as they require different PDB formats.) +} +swiftConfig(releaseWithDebugInfo) { + msvc { + QMAKE_CXXFLAGS_RELEASE *= /Z7 + QMAKE_LFLAGS_RELEASE *= /DEBUG /INCREMENTAL:NO /OPT:REF /OPT:ICF + } +} swiftConfig(profileRelease) { msvc { QMAKE_CXXFLAGS_RELEASE *= /Zi