From 40518ac11c549f34f711ce057822ac51fdb8c9b5 Mon Sep 17 00:00:00 2001
From: Daniel Molkentin <daniel.molkentin@nokia.com>
Date: Thu, 19 Nov 2009 19:43:18 +0100
Subject: [PATCH] gdb: On Windows, also substitute the debugging path for
 non-sdk Qt.

Reviewed-By: hjk
---
 src/plugins/debugger/gdb/gdbengine.cpp | 22 ++++++++++++----------
 1 file changed, 12 insertions(+), 10 deletions(-)

diff --git a/src/plugins/debugger/gdb/gdbengine.cpp b/src/plugins/debugger/gdb/gdbengine.cpp
index c0aa3ecd93a..900c131fe8a 100644
--- a/src/plugins/debugger/gdb/gdbengine.cpp
+++ b/src/plugins/debugger/gdb/gdbengine.cpp
@@ -4474,17 +4474,19 @@ void GdbEngine::handleInferiorPrepared()
 {
     const QString qtInstallPath = m_startParameters->qtInstallPath;
     if (!qtInstallPath.isEmpty()) {
-        QString qtBuildPath =
-        #if defined(Q_OS_WIN)
-            _("C:/qt-greenhouse/Trolltech/Code_less_create_more/Trolltech/Code_less_create_more/Troll/4.6/qt");
-        #elif defined(Q_OS_MAC)
-            QString();
-        #else    
-            _("/var/tmp/qt-x11-src-4.6.0");
-        #endif
-        if (!qtBuildPath.isEmpty())
+        QString qtBuildPath;
+#if defined(Q_OS_WIN)
+        qtBuildPath = _("C:/qt-greenhouse/Trolltech/Code_less_create_more/Trolltech/Code_less_create_more/Troll/4.6/qt");
         postCommand(_("set substitute-path %1 %2")
-            .arg(qtBuildPath).arg(qtInstallPath));
+                    .arg(qtBuildPath).arg(qtInstallPath));
+        qtBuildPath = _("C:/iwmake/build_mingw_opensource");
+        postCommand(_("set substitute-path %1 %2")
+                    .arg(qtBuildPath).arg(qtInstallPath));
+#elif defined(Q_OS_UNIX) && !defined (Q_OS_MAC)
+        qtBuildPath = _("/var/tmp/qt-x11-src-4.6.0");
+        postCommand(_("set substitute-path %1 %2")
+                    .arg(qtBuildPath).arg(qtInstallPath));
+#endif
     }
 
     // Initial attempt to set breakpoints
-- 
GitLab