0

I am very new to coding and am trying to learn C with the use of CodeLite 17.0.0 on MacOS 12 Monterey 12.6.6

I followed the steps on the Debug Adapter Client page of CodeLite to download the llvm through brew but when I run lldb I get a time out error which, per the title, says:

"CodeLte - Debug Adapter Client Failed to Connect to DAP Server"

I have no clue how to fix this. I have redownloaded Codelite and made sure LLDB is up to date. My settings I believe are the same as shown here: https://docs.codelite.org/plugins/dap/#the-configuration-dialog
but I do not know where this error is being generated from and would love some help so I can use the compiler and continue on with the course I'm taking.

Thx

I was expecting the LLDB Debugger to run as shown in the class video but found I cannot get it to function.

1 Answers1

0

CodeLite does not invoke lldb directly, instead, it launches the dap client (Debug Adapter Protocol Client) - in your case, lldb-vscode.

You should install lldb-vscode as mentioned here: https://docs.codelite.org/plugins/dap/#lldb-vscode

Once installed, make sure CodeLite knows where to find it:

  • Open the Debug adapter client settings dialog (From the menu bar Settings -> Debug Adapter Client)
  • Make sure you have a tab with the title lldb-vscode exists
  • If the tab does not exist or it exists but points to a stale location, click on the magnifier (highlighted in the screenshot below) button and let CodeLite re-configure it (I added a screenshot that highlight what to check)

enter image description here

HTH

Eran
  • 2,310
  • 1
  • 13
  • 13
  • Hi, thanks for the reply. I have the debugger adapter client installed and have those settings engaged, but when I run the lldb debugger I get a message now saying: "Failed to launch debuggee: Could not create a target for a program '/Users/..../Debug/myprogram": unable to find executable for '/Users/.../Debug/myprogram'. How do I get the debugger to find the executable? I'm also trying on another machine to run 14.0.0 from the archive but it doesn't even see my having the LLDB debugger at all. It's not there so I would like to get 17.0.0 to run lldb. Thx – Matthew-Freedman Jul 12 '23 at 18:00
  • Its a bit confusing: when you say: "when I launch lldb" -> do you launch it from a terminal? or from within CodeLite? did you confirm that the executable (myprogram) exists? – Eran Jul 14 '23 at 08:21
  • Sorry, I'm very new to coding and its showing. I meant when I launch LLDB outside CodeLite via macs terminal it works, when I run codelites debugger with my settings set to LLDBvia llvm-vscode, I get an error saying "Failed to launch debuggee..." I also can't get the Codelite terminal to launch, just the mac native terminal. I don't know if they are related but since you are kind enough to respond I figured I would mention it. I have tried re-installing 17.0.0 on a few different machines running MacOS 12.6.6 and get the same error message on both when I set my debugger to lldb-vscode. – Matthew-Freedman Jul 14 '23 at 23:23