I have started lldb-server on remote linux in the directory where my executable need to be debugged reside.
(lldb) platform select remote-linux
Platform: remote-linux
Connected: no
(lldb) platform connect connect://pi.local:9091
Platform: remote-linux
OS Version: 4.9.78 (4.9.78-v7+)
Kernel: #1084 SMP Thu Jan 25 18:05:49 GMT 2018
Hostname: pi
Connected: yes
WorkingDir: /Users/necktwi/Workspace/RemoteDebugTest/build
(lldb) file Test
Current executable set to ’Test’ (arm).
(lldb) run
error: process launch failed: Lost debug server connection
Why the process launch failing? The executable Test
takes parameters -s normal
. How to feed them in? Did the process failed because of not feeding its arguments?
https://lldb.llvm.org/remote.html explains how to debug a cross-built local executable on remote platform. But I am trying to debug the executable which was built on the remote.
Thank you.
… neckTwi

FYI - the color you picked for this makes it unreadable against a white background. I had to convert it to plain text to read it.
The error message “Lost debug server connection” occurs if the platform isn’t connected and it is not a host platform.
What do you get if you type “platform status” after “file Test”?
Is the remote-built executable available on your Mac? lldb will need it to be able to get symbols and debug info.
Ted

I’m getting same error even if I debug on the same device.
necktwi@pi:/home/necktwi/Workspace/RemoteDebugTest/build$ lldb-server-6.0 platform --listen “*:1234” --server
Connection established.
necktwi@pi:/home/necktwi/Workspace/RemoteDebugTest/build$ lldb-6.0
(lldb) platform select remote-linux
Platform: remote-linux
Connected: no
(lldb) platform connect connect://localhost:1234
Platform: remote-linux
OS Version: 4.9.78 (4.9.78-v7+)
Kernel: #1084 SMP Thu Jan 25 18:05:49 GMT 2018
Hostname: pi.RemoteDebugTest.com
Connected: yes
WorkingDir: /home/necktwi/Workspace/RemoteDebugTest/build
(lldb) file RemoteDebugTest
Current executable set to ‘RemoteDebugTest’ (arm).
(lldb) run
error: process launch failed: Lost debug server connection
(lldb)
I think it’s a bug. I tried to sign up for bugs-admin@lists.llvm.org but I didn’t get a reply though I’ve put a mail with my email-id and name.
… NeckTwi

You might not get a reply but usually the turnaround time is < 24 hours. If it’s not let me know and I’ll find out who to ask.
I haven’t got any reply from bugs-admin@lists.llvm.org. Please look into it.
… NeckTwi
