Skip to content
Snippets Groups Projects
Commit 51a25763 authored by Eike Ziller's avatar Eike Ziller Committed by hjk
Browse files

LLDB: Set environment for debugged process


Task-number: QTCREATORBUG-10030

Change-Id: Ib487cee704ea30f52c52f6f025823637fa4199eb
Reviewed-by: default avatarhjk <hjk121@nokiamail.com>
parent e7c51ebd
No related branches found
No related tags found
No related merge requests found
...@@ -692,6 +692,8 @@ class Dumper(DumperBase): ...@@ -692,6 +692,8 @@ class Dumper(DumperBase):
else: else:
launchInfo = lldb.SBLaunchInfo(self.processArgs_.split(' ')) launchInfo = lldb.SBLaunchInfo(self.processArgs_.split(' '))
launchInfo.SetWorkingDirectory(os.getcwd()) launchInfo.SetWorkingDirectory(os.getcwd())
environmentList = [key + "=" + value for key,value in os.environ.items()]
launchInfo.SetEnvironmentEntries(environmentList, False)
self.process = self.target.Launch(launchInfo, error) self.process = self.target.Launch(launchInfo, error)
self.report('pid="%s"' % self.process.GetProcessID()) self.report('pid="%s"' % self.process.GetProcessID())
......
...@@ -151,6 +151,8 @@ void LldbEngine::setupEngine() ...@@ -151,6 +151,8 @@ void LldbEngine::setupEngine()
args.append(Core::ICore::resourcePath() + _("/debugger/lldbbridge.py")); args.append(Core::ICore::resourcePath() + _("/debugger/lldbbridge.py"));
args.append(m_lldbCmd); args.append(m_lldbCmd);
showMessage(_("STARTING LLDB ") + args.join(QLatin1String(" "))); showMessage(_("STARTING LLDB ") + args.join(QLatin1String(" ")));
m_lldbProc.setEnvironment(startParameters().environment.toStringList());
m_lldbProc.start(_("python"), args); m_lldbProc.start(_("python"), args);
if (!m_lldbProc.waitForStarted()) { if (!m_lldbProc.waitForStarted()) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment