qdoc: warn if index file for dependency is not found

Output a warning for each doc dependency that qdoc cannot
locate an index file for.

The index files are loaded for both prepare and generate
phases. To avoid duplication, output warnings only when
in generate phase.

Change-Id: I74f9ba78e4b57cb1a62e0d1c2efda01ecc85c06d
Reviewed-by: Martin Smith <martin.smith@digia.com>
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
This commit is contained in:
Topi Reinio 2013-11-01 14:15:50 +01:00 committed by The Qt Project
parent 2ae4e180ac
commit 00b5dec9e6

View File

@ -218,8 +218,15 @@ static void loadIndexFiles(Config& config)
else if (foundIndices.size() == 1) {
indexToAdd = foundIndices[0].absoluteFilePath();
}
if (!indexToAdd.isEmpty() && !indexFiles.contains(indexToAdd))
indexFiles << indexToAdd;
if (!indexToAdd.isEmpty()) {
if (!indexFiles.contains(indexToAdd))
indexFiles << indexToAdd;
}
else if (Generator::runGenerateOnly()) {
qDebug() << "warning:" << config.getString(CONFIG_PROJECT)
<< "Cannot locate index file for dependency"
<< dependModules[i];
}
}
}
else {