forked from qt-creator/qt-creator
Debugger: Rework dumper detection
Recent versions of GDB seem to require 'make install' to find their Python bits. Given that this is not really an option, check the usual suspects, too. Change-Id: I5217c0184681d4a86992fe0b8989498843b26cea Reviewed-by: David Schulz <david.schulz@digia.com> Reviewed-by: hjk <hjk121@nokiamail.com>
This commit is contained in:
@@ -4936,7 +4936,12 @@ void GdbEngine::tryLoadPythonDumpers()
|
||||
const QByteArray dumperSourcePath =
|
||||
Core::ICore::resourcePath().toLocal8Bit() + "/debugger/";
|
||||
|
||||
const QFileInfo gdbBinaryFile(m_gdb);
|
||||
const QByteArray uninstalledData = gdbBinaryFile.absolutePath().toLocal8Bit()
|
||||
+ "/data-directory/python";
|
||||
|
||||
postCommand("python sys.path.insert(1, '" + dumperSourcePath + "')", ConsoleCommand);
|
||||
postCommand("python sys.path.append('" + uninstalledData + "')", ConsoleCommand);
|
||||
postCommand("python from gdbbridge import *", ConsoleCommand, CB(handlePythonSetup));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user