From 4245d89a67aadd50f6e27f667fe2abc8bee2693d Mon Sep 17 00:00:00 2001 From: hjk Date: Mon, 7 Jun 2021 12:33:45 +0200 Subject: [PATCH] ProjectExplorer: Show a verbose error message if available ... when a start failed, e.g. due to a inacessible working directory. Change-Id: Ibcec1c5323c37f1e8f6c9e55439439b24f3b40b1 Reviewed-by: Christian Kandeler --- src/plugins/projectexplorer/abstractprocessstep.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/plugins/projectexplorer/abstractprocessstep.cpp b/src/plugins/projectexplorer/abstractprocessstep.cpp index e73a6352282..6882fe14722 100644 --- a/src/plugins/projectexplorer/abstractprocessstep.cpp +++ b/src/plugins/projectexplorer/abstractprocessstep.cpp @@ -338,10 +338,14 @@ void AbstractProcessStep::processFinished(int exitCode, QProcess::ExitStatus sta void AbstractProcessStep::processStartupFailed() { - emit addOutput(tr("Could not start process \"%1\" %2") + emit addOutput(tr("Could not start process \"%1\" %2.") .arg(d->m_param.effectiveCommand().toUserOutput(), d->m_param.prettyArguments()), - BuildStep::OutputFormat::ErrorMessage); + OutputFormat::ErrorMessage); + + QString err = d->m_process ? d->m_process->errorString() : QString(); + if (!err.isEmpty()) + emit addOutput(err, OutputFormat::ErrorMessage); } /*!