CMake: Unify error reporting for builddirmanager's information retrieval

Use a dedicated errrorMessage out parameter for error reporting in
the builddirmanager methods related to information retrieval. Those are
called after the parsing has finished.

This frees the errrorOccured signal of the builddirmanager to be used only
when the parsing itself has failed.

Change-Id: Ieefc32c0386769479177a6bd4bc4a0e77df5db7b
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
This commit is contained in:
Tobias Hunger
2019-06-07 17:13:49 +02:00
parent 68bcaeff64
commit 65658f411b
9 changed files with 88 additions and 43 deletions

View File

@@ -81,6 +81,9 @@ public:
void clearCMakeCache();
bool mustUpdateCMakeStateBeforeBuild();
void checkAndReportError(QString &errorMessage) const;
void reportError(const QString &errorMessage) const;
protected:
RestoreResult fromMap(const QVariantMap &map, QString *errorMessage) final;
bool setupTarget(ProjectExplorer::Target *t) final;