I have cmake-tools
extension and I can run build from the extension tab in the right bar without problems. Clicking Launch button also starts my compiled program. But when I want to click debug, I get the popup shown above. This is what I see in the log:
[main] Building folder: MYPROJECT MY_PROGRAM
[build] Starting build
[proc] Executing command: /usr/bin/cmake --build /home/my_project_build_dir --config Debug --target MY_PROGRAM --
[build] [1/2 0% :: 0.000] Re-checking globbed directories...
[build] ninja: no work to do.
[driver] Build completed: 00:00:00.130
[build] Build finished with exit code 0
[proc] Executing command: /usr/bin/lldb-mi --version
[proc] The command: /usr/bin/lldb-mi --version exited with code: 127
[proc] Executing command: /usr/bin/gdb --version
[proc] Executing command: /usr/bin/gdb --version
This looks a lot like the CMake tools are checking for lldb
and gdb
versions, chose gdb
since lldb
is not installed and then the error occurs.
It is probably important to note that I am working remotelly over SSH using the ms-vscode-remote.remote-ssh
extension.
I have tried to change the launch.json
, but I don’t think that takes effect here. This affects the “Run and Debug” tab and I can get a similar popup that seems to output whatever was in the type
field in launch.json
.
I have tried to also configure some other debugging extension for launch.json
, but that failed because the extensions could’t trigger the cmake build first.