question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Cannot debug on Ubuntu after update

See original GitHub issue

Brief Issue Summary

VSCode updated the plugin to the MS one

I tried launching the debugger. It fails with

[debugger] Unable to automatically determine debugger corresponding to compiler: {}

I tried this with gcc and clang. Same result

I tried manually setting the debugger:

    "cmake.debugConfig": {
        "type": "GDB",
        "debuggerPath": "/usr/bin/gdb"
    }

Same result

CMake Tools Log

2019-11-08T07:45:56.718Z [debug] [cache] Reading CMake cache file /home/bstanimirov/prj/my/app-server/build/CMakeCache.txt
2019-11-08T07:45:56.723Z [debug] [cache] Parsing CMake cache string
2019-11-08T07:45:56.732Z [warning] [debugger] Unable to automatically determine debugger corresponding to compiler: {}
2019-11-08T07:45:56.732Z [debug] [main] Debug configuration from cache: null
2019-11-08T07:45:56.732Z [error] [main] Failed to generate debugger configuration
2019-11-08T07:45:56.733Z [debug] [extension] [8248] cmake.debugTarget finished (returned null)
2019-11-08T07:45:56.746Z [debug] [cache] Reading CMake cache file /home/bstanimirov/prj/my/app-server/build/CMakeCache.txt
2019-11-08T07:45:56.747Z [debug] [cache] Parsing CMake cache string

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:2
  • Comments:11 (5 by maintainers)

github_iconTop GitHub Comments

6reactions
bobbrowcommented, Nov 8, 2019

I have a fix for this in PR. There was an update to the regular expression that mapped compilers to the debugger that caused this regression.

You can workaround this until we release an update by opening ~/.vscode/extensions/ms-vscode.cmake-tools-1.2.1/dist/main.js and replacing line 27378:

  const gcc_compiler_regex = /([cg]\+\+|g?cc)(?=\.exe$|$)/gi;

with

  const gcc_compiler_regex = /([cg]\+\+|g?cc)(?=[^\/\\]*$)/gi;
0reactions
andreeiscommented, Mar 1, 2021

I opened a new issue from your last comment. I have a suspicion in the implementation.

Read more comments on GitHub >

github_iconTop Results From Across the Web

after upgrade gdb won't attach to process - Ask Ubuntu
In Maverick Meerkat (10.10) Ubuntu introduced a patch to disallow ptracing of non-child processes by non-root users - ie. only a process ...
Read more >
DebuggingProcedures - Ubuntu Wiki
As part of triaging bug reports about specific packages or subsystems, bug triagers and developers have been writing debugging procedures ...
Read more >
DebuggingInstallationIssues - Ubuntu Wiki
This is due to a corrupted hint file. Workaround. To workaround it, open a terminal and run the following commands:.
Read more >
DebuggingUpdateManager - Ubuntu Wiki
Debugging Central. This page is part of the debugging series — pages with debugging details for a variety of Ubuntu packages.
Read more >
DebuggingPrintingProblems - Ubuntu Wiki
This page is part of the debugging series — pages with debugging details ... Note that problems cannot only caused by CUPS but...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found