forked from qt-creator/qt-creator
CMakePM: Enable extra compilers only for files in the project
Qt Creator 4.15 added the "<File System>" project node containing all the files in the source directory. Qt Creator for its "find extra compilers" step needs only the files from the project and not all the files in the system. Task-number: QTCREATORBUG-25783 Change-Id: I5d33d5296f67ab3f321c232e5071f32e56d29101 Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
@@ -1142,7 +1142,7 @@ QList<ProjectExplorer::ExtraCompiler *> CMakeBuildSystem::findExtraCompilers()
|
||||
// Find all files generated by any of the extra compilers, in a rather crude way.
|
||||
Project *p = project();
|
||||
const FilePaths fileList = p->files([&fileExtensions](const Node *n) {
|
||||
if (!Project::SourceFiles(n))
|
||||
if (!Project::SourceFiles(n) || !n->isEnabled()) // isEnabled excludes nodes from the file system tree
|
||||
return false;
|
||||
const QString fp = n->filePath().toString();
|
||||
const int pos = fp.lastIndexOf('.');
|
||||
|
Reference in New Issue
Block a user