Commit d4cee56e authored by Friedemann Kleint's avatar Friedemann Kleint
Browse files

Symbian/Linux: Fix debugger

- Switch correctly on GnuPoc-toolchains
- Do not lock up on Gdb start.
parent f87f4210
......@@ -945,6 +945,8 @@ static IDebuggerEngine *debuggerEngineForToolChain(ProjectExplorer::ToolChain::T
case ProjectExplorer::ToolChain::GCCE:
case ProjectExplorer::ToolChain::RVCT_ARMV5:
case ProjectExplorer::ToolChain::RVCT_ARMV6:
case ProjectExplorer::ToolChain::RVCT_ARMV5_GNUPOC:
case ProjectExplorer::ToolChain::GCCE_GNUPOC:
rc = gdbEngine;
break;
case ProjectExplorer::ToolChain::OTHER:
......
......@@ -1645,6 +1645,8 @@ bool GdbEngine::checkConfiguration(int toolChain, QString *errorMessage, QString
case ProjectExplorer::ToolChain::GCCE:
case ProjectExplorer::ToolChain::RVCT_ARMV5:
case ProjectExplorer::ToolChain::RVCT_ARMV6:
case ProjectExplorer::ToolChain::RVCT_ARMV5_GNUPOC:
case ProjectExplorer::ToolChain::GCCE_GNUPOC:
if (!m_trkOptions->check(errorMessage)) {
if (settingsPage)
*settingsPage = TrkOptionsPage::settingsId();
......@@ -1663,6 +1665,8 @@ AbstractGdbAdapter *GdbEngine::createAdapter(const DebuggerStartParametersPtr &s
case ProjectExplorer::ToolChain::GCCE:
case ProjectExplorer::ToolChain::RVCT_ARMV5:
case ProjectExplorer::ToolChain::RVCT_ARMV6:
case ProjectExplorer::ToolChain::RVCT_ARMV5_GNUPOC:
case ProjectExplorer::ToolChain::GCCE_GNUPOC:
return new TrkGdbAdapter(this, m_trkOptions);
default:
break;
......
......@@ -1671,6 +1671,13 @@ void TrkGdbAdapter::handleTrkVersionsStartGdb(const TrkResult &result)
<< '.' << int(result.data.at(4));
}
logMessage(logMsg);
// As we are called from the TrkDevice handler, do not lock up when shutting
// down the device in case of gdb launch errors.
QTimer::singleShot(0, this, SLOT(slotStartGdb()));
}
void TrkGdbAdapter::slotStartGdb()
{
QStringList gdbArgs;
gdbArgs.append(QLatin1String("--nx")); // Do not read .gdbinit file
if (!m_engine->startGdb(gdbArgs, m_options->gdb, TrkOptionsPage::settingsId())) {
......
......@@ -213,6 +213,7 @@ private:
void handleStop(const TrkResult &result);
void handleSupportMask(const TrkResult &result);
void handleTrkVersionsStartGdb(const TrkResult &result);
Q_SLOT void slotStartGdb();
void handleDisconnect(const TrkResult &result);
void handleDeleteProcess(const TrkResult &result);
void handleDeleteProcess2(const TrkResult &result);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment