forked from qt-creator/qt-creator
QbsProjectManager: Consider cpp.minimum*Version properties
... when setting up the code model for Darwin targets. Fixes: QTCREATORBUG-22355 Change-Id: I5cade8d3139dc3602298e9d4d056c9745b208489 Reviewed-by: Ivan Komissarov <ABBAPOH@gmail.com> Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
This commit is contained in:
@@ -864,6 +864,16 @@ static void getExpandedCompilerFlags(QStringList &cFlags, QStringList &cxxFlags,
|
|||||||
cFlags << "-std=c99";
|
cFlags << "-std=c99";
|
||||||
else if (!cLanguageVersion.isEmpty())
|
else if (!cLanguageVersion.isEmpty())
|
||||||
cFlags << ("-std=" + cLanguageVersion.first());
|
cFlags << ("-std=" + cLanguageVersion.first());
|
||||||
|
|
||||||
|
if (targetOS.contains("darwin")) {
|
||||||
|
const auto darwinVersion = getCppProp("minimumDarwinVersion").toString();
|
||||||
|
if (!darwinVersion.isEmpty()) {
|
||||||
|
const auto darwinVersionFlag = getCppProp("minimumDarwinVersionCompilerFlag")
|
||||||
|
.toString();
|
||||||
|
if (!darwinVersionFlag.isEmpty())
|
||||||
|
cxxFlags << (darwinVersionFlag + '=' + darwinVersion);
|
||||||
|
}
|
||||||
|
}
|
||||||
} else if (toolchain.contains("msvc")) {
|
} else if (toolchain.contains("msvc")) {
|
||||||
if (enableExceptions.toBool()) {
|
if (enableExceptions.toBool()) {
|
||||||
const QString exceptionModel = getCppProp("exceptionHandlingModel").toString();
|
const QString exceptionModel = getCppProp("exceptionHandlingModel").toString();
|
||||||
|
Reference in New Issue
Block a user