forked from qt-creator/qt-creator
QbsProjectManager: Fix compiler name setup for GCC-like toolchains
The mapping was not quite right. In particular, cpp.cCompilerName needs to be set if the compiler name is not the default. Task-number: QTCREATORBUG-19467 Change-Id: I6c190fdda98ff15dce6066bfb082d24853538a78 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
This commit is contained in:
@@ -296,8 +296,10 @@ QVariantMap DefaultPropertyProvider::autoGeneratedProperties(const ProjectExplor
|
||||
if (toolchain.contains(QLatin1String("msvc"))) {
|
||||
data.insert(QLatin1String(CPP_COMPILERNAME), mainCompilerName);
|
||||
} else {
|
||||
if (!mainCompilerName.isEmpty())
|
||||
data.insert(QLatin1String(CPP_COMPILERNAME), mainCompilerName);
|
||||
if (!cCompilerName.isEmpty())
|
||||
data.insert(QLatin1String(CPP_COMPILERNAME), cCompilerName);
|
||||
data.insert(QLatin1String(CPP_CCOMPILERNAME), cCompilerName);
|
||||
if (!cxxCompilerName.isEmpty())
|
||||
data.insert(QLatin1String(CPP_CXXCOMPILERNAME), cxxCompilerName);
|
||||
}
|
||||
|
||||
@@ -83,6 +83,7 @@ const char QBS_TOOLCHAIN[] = "qbs.toolchain";
|
||||
const char CPP_TOOLCHAINPATH[] = "cpp.toolchainInstallPath";
|
||||
const char CPP_TOOLCHAINPREFIX[] = "cpp.toolchainPrefix";
|
||||
const char CPP_COMPILERNAME[] = "cpp.compilerName";
|
||||
const char CPP_CCOMPILERNAME[] = "cpp.cCompilerName";
|
||||
const char CPP_CXXCOMPILERNAME[] = "cpp.cxxCompilerName";
|
||||
const char CPP_PLATFORMCOMMONCOMPILERFLAGS[] = "cpp.platformCommonCompilerFlags";
|
||||
const char CPP_PLATFORMLINKERFLAGS[] = "cpp.platformLinkerFlags";
|
||||
|
||||
Reference in New Issue
Block a user