forked from qt-creator/qt-creator
Merge remote-tracking branch 'origin/4.12'
Conflicts: src/plugins/cmakeprojectmanager/tealeafreader.cpp src/plugins/cmakeprojectmanager/tealeafreader.h src/plugins/projectexplorer/miniprojecttargetselector.cpp Change-Id: I88d85be3903f57a55fddb7901e771a4822db1b85
This commit is contained in:
@@ -168,6 +168,12 @@ static bool supportsNodeAction(ProjectAction action, const Node *node)
|
||||
return false;
|
||||
}
|
||||
|
||||
static QString buildKeyValue(const QJsonObject &product)
|
||||
{
|
||||
return product.value("name").toString() + '.'
|
||||
+ product.value("multiplex-configuration-id").toString();
|
||||
}
|
||||
|
||||
QbsBuildSystem::QbsBuildSystem(QbsBuildConfiguration *bc)
|
||||
: BuildSystem(bc->target()),
|
||||
m_session(new QbsSession(this)),
|
||||
@@ -692,13 +698,13 @@ void QbsBuildSystem::updateDocuments()
|
||||
OpTimer opTimer("updateDocuments");
|
||||
const FilePath buildDir = FilePath::fromString(
|
||||
m_projectData.value("build-directory").toString());
|
||||
const auto filePaths = transform<QVector<FilePath>>(
|
||||
const auto filePaths = transform<QSet<FilePath>>(
|
||||
m_projectData.value("build-system-files").toArray(),
|
||||
[](const QJsonValue &v) { return FilePath::fromString(v.toString()); });
|
||||
|
||||
// A changed qbs file (project, module etc) should trigger a re-parse, but not if
|
||||
// the file was generated by qbs itself, in which case that might cause an infinite loop.
|
||||
const QVector<FilePath> nonBuildDirFilePaths = filtered(filePaths,
|
||||
const QSet<FilePath> nonBuildDirFilePaths = filtered(filePaths,
|
||||
[buildDir](const FilePath &p) {
|
||||
return !p.isChildOf(buildDir);
|
||||
});
|
||||
@@ -905,7 +911,7 @@ static RawProjectParts generateProjectParts(
|
||||
rpp.setProjectFileLocation(location.value("file-path").toString(),
|
||||
location.value("line").toInt(),
|
||||
location.value("column").toInt());
|
||||
rpp.setBuildSystemTarget(productName);
|
||||
rpp.setBuildSystemTarget(buildKeyValue(prd));
|
||||
rpp.setBuildTargetType(prd.value("is-runnable").toBool()
|
||||
? BuildTargetType::Executable
|
||||
: BuildTargetType::Library);
|
||||
@@ -1067,8 +1073,7 @@ void QbsBuildSystem::updateApplicationTargets()
|
||||
}
|
||||
}
|
||||
BuildTargetInfo bti;
|
||||
bti.buildKey = productData.value("name").toString() + '.'
|
||||
+ productData.value("multiplex-configuration-id").toString();
|
||||
bti.buildKey = buildKeyValue(productData);
|
||||
bti.targetFilePath = FilePath::fromString(targetFile);
|
||||
bti.projectFilePath = FilePath::fromString(projectFile);
|
||||
bti.isQtcRunnable = isQtcRunnable; // Fixed up below.
|
||||
|
||||
Reference in New Issue
Block a user