forked from qt-creator/qt-creator
QbsProjectManager: Do not try to call qbs if there is no executable
Otherwise, we'll get warnings from QProcess. Change-Id: Ibaa536729fa644583c8ddc7a2931ac0ee11c0c9e Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
This commit is contained in:
@@ -247,7 +247,10 @@ QString QbsProfileManager::runQbsConfig(QbsConfigOp op, const QString &key, cons
|
||||
args << "--unset" << key;
|
||||
break;
|
||||
}
|
||||
qbsConfig.start(QbsSettings::qbsExecutableFilePath().toString(), args);
|
||||
const Utils::FilePath qbsExe = QbsSettings::qbsExecutableFilePath();
|
||||
if (qbsExe.isEmpty() || !qbsExe.exists())
|
||||
return {};
|
||||
qbsConfig.start(qbsExe.toString(), args);
|
||||
if (!qbsConfig.waitForStarted(3000) || !qbsConfig.waitForFinished(5000)) {
|
||||
Core::MessageManager::write(tr("Failed run qbs config: %1").arg(qbsConfig.errorString()));
|
||||
} else if (qbsConfig.exitCode() != 0) {
|
||||
|
||||
Reference in New Issue
Block a user