Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

VS Code (Ubuntu) - miDebuggerPath is invalid. #5534

Closed
paxth opened this issue May 20, 2020 · 8 comments
Closed

VS Code (Ubuntu) - miDebuggerPath is invalid. #5534

paxth opened this issue May 20, 2020 · 8 comments
Assignees
Labels

Comments

@paxth
Copy link

@paxth paxth commented May 20, 2020

Type: Debugger

When I try to use my debugger, I get the error showing:
Unable to start debugging. The value of miDebuggerPath is invalid.
Screenshot from 2020-05-20 16-26-10

  • OS and Version: Ubuntu 20.04 LTS
  • VS Code Version: 1.45.1
  • C/C++ Extension Version: 0.28.0
  • Other extensions you installed (and if the issue persists after disabling them): C++ Intellisense 0.2.2

Here is my launch.json
Screenshot from 2020-05-20 16-59-18

Any idea how do i fix it?

@WardenGnaw
Copy link
Member

@WardenGnaw WardenGnaw commented May 20, 2020

Does /usr/bin/lldb-mi exist?

@WardenGnaw WardenGnaw self-assigned this May 20, 2020
@paxth
Copy link
Author

@paxth paxth commented May 21, 2020

I cant find that. Does that mean it's missing?

@sean-mcmanus
Copy link
Collaborator

@sean-mcmanus sean-mcmanus commented May 21, 2020

It hit the same issue with MIMode "gdb" -- installing gdb fixed it.

@WardenGnaw
Copy link
Member

@WardenGnaw WardenGnaw commented May 21, 2020

@paxth Are you looking to use clang/lldb for build and debugging on Ubuntu 20.04 LTS? You will need to downgrade to clang/lldb 9 in order to get lldb-mi.

lldb-mi has been removed from lldb and now Ubuntu will not build it independently and ship it: See #5415

If you can switch to g++/gdb, that will work in Linux scenarios.

@zipzit
Copy link

@zipzit zipzit commented May 22, 2020

 "MIMode": "gdb",
 . . .
  "preLaunchTask": "shell: g++ build active file",
            "miDebuggerPath": "/usr/bin/gdb"

this works for me...

@paxth
Copy link
Author

@paxth paxth commented May 22, 2020

 "MIMode": "gdb",
 . . .
  "preLaunchTask": "shell: g++ build active file",
            "miDebuggerPath": "/usr/bin/gdb"

this works for me...

Do i need to compile using gcc now or can i use clang too?

@sean-mcmanus
Copy link
Collaborator

@sean-mcmanus sean-mcmanus commented May 22, 2020

@paxth Debugging clang-built binaries with gdb works for me on Linux...that is with gcc's libstdc++ though and not LLVM's libc++ (not sure if that matters or if there are other special cases).

@paxth
Copy link
Author

@paxth paxth commented May 23, 2020

Thanks guys, got it working!

@paxth paxth closed this as completed May 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants