[lldb-dev] debug server help

Carlo Kok ck at remobjects.com
Fri Sep 14 02:03:19 PDT 2012

I'm having trouble using the LLDB apis to connect to a remote (OSX) 
debugserver. It connects, starts the process on the server, then it 
fails on this command in Process.cpp:
process_sp = Attach (attach_info, debugger, target, listener, error);

It tries to do a "qLaunchGDBServer" which returns an error.

Transcript of the traffic to/from the server:

I'm running debugserver on OSX using:

-g -v

Using the LLDB apis I'm calling:

m_arch = new ArchSpec("x86_64-apple-macosx");
m_debugger = Debugger::CreateInstance(DebuggerLog, this);
m_platform = PlatformSP(PlatformRemoteGDBServer::CreateInstance(true, 
m_debugger->GetPlatformList().Append(m_platform, true);
m_listener = ListenerSP(new Listener("<list>"));

ProcessLaunchInfo li;
li.SetExecutableFile(FileSpec("/Users/ck/a.out", false), true);
m_process = m_platform->DebugProcess(li, *m_debugger.get(), 
m_target.get(), *m_listener.get(), m_error);

What am I missing?

More information about the lldb-dev mailing list