Summary: | debuginfod symbols not retrieved with gdb 12 | ||
---|---|---|---|
Product: | [Applications] drkonqi | Reporter: | Antonio Rojas <arojas> |
Component: | general | Assignee: | Plasma Bugs List <plasma-bugs> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | bugseforuns, jkhsjdhjs, miaumiui, nate, putr4.s, sitter |
Priority: | NOR | ||
Version: | 5.24.90 | ||
Target Milestone: | --- | ||
Platform: | Other | ||
OS: | Linux | ||
See Also: | https://bugs.kde.org/show_bug.cgi?id=484974 | ||
Latest Commit: | https://invent.kde.org/plasma/drkonqi/commit/40f8c11579362755c5242f46ab2e257480d3d06e | Version Fixed In: | 5.26.1 |
Sentry Crash Report: |
Description
Antonio Rojas
2022-05-19 22:55:21 UTC
Please also file an upstream bug, it definitely shouldn't prompt in --batch mode I would think In point of fact I think the prompt gets in the way of actually operating in batch mode, the way I see it the entire preamble file is failing to execute :| (In reply to Harald Sitter from comment #1) > Please also file an upstream bug, it definitely shouldn't prompt in --batch > mode I would think I'm not sure if that's true, because the man page doesn't state that gdb doesn't prompt in --batch mode. I filed this as a bug upstream anyways, let's see what they say: https://sourceware.org/bugzilla/show_bug.cgi?id=29301 As a "workaround", `-iex 'set debuginfod enabled on'` can be passed as a parameter to gdb. Ah, there may have been a misunderstanding here: While gdb does prompt, it answers its own prompt automatically with N. gdb doesn't hang, it just doesn't download debug symbols via debuginfod. In the gdb issue Aaron Merey also confirmed that prompts (which are automatically answered with Y or N) are expected in --batch mode. So gdb seems to do everything correctly. At least I didn't experience any hangs with gdb. If none of your did either, I think the correct way to solve this would be to edit https://invent.kde.org/plasma/drkonqi/-/blob/7a514e37c19c93f63aee007f42bdff99c8437834/src/data/debuggers/internal/gdbrc such that gdb is ran with -iex 'set debuginfod enabled on'. (sorry for the double-post) Thanks. A possibly relevant merge request was started @ https://invent.kde.org/plasma/drkonqi/-/merge_requests/67 On Arch Linix running Plasma 5.26 beta gdb 12.1 crashes when drkonqi tries to generate the backtrace. Git commit 2d1f801ea4e164fa109269426311103f1af5ae13 by Harald Sitter. Committed on 18/10/2022 at 22:19. Pushed by sitter into branch 'master'. allow using debuginfod for symbol resolution with gdb12 gdb defaults to it being off. this adds a new cmake option WITH_GDB12 to be set by distros. when this is set (and the gdb debugger is used by drkonqi at runtime) then the install debug symbols button gets slightly refined behavior where instead of going to a separate tool to install symbols it will instead run gdb with a suitable cmdline to enable debuginfod. we still prefer the separate installer when also available. in particular the workflow here looks like this: - crash & user opens drkonqi - trace happens without debuginfod - if the trace is poor the install debug info button gets enabled - user clicks button - re-tracing with debuginfod enabled - trace is now amazing and can be reported M +1 -0 CMakeLists.txt M +2 -1 src/backtracegenerator.cpp M +5 -0 src/backtracegenerator.h M +2 -0 src/config-drkonqi.h.cmake M +3 -0 src/data/debuggers/internal/gdbrc M +17 -1 src/debugger.cpp M +7 -1 src/debugger.h M +13 -3 src/qml/DeveloperPage.qml https://invent.kde.org/plasma/drkonqi/commit/2d1f801ea4e164fa109269426311103f1af5ae13 Git commit 40f8c11579362755c5242f46ab2e257480d3d06e by Harald Sitter. Committed on 18/10/2022 at 22:23. Pushed by sitter into branch 'Plasma/5.26'. allow using debuginfod for symbol resolution with gdb12 gdb defaults to it being off. this adds a new cmake option WITH_GDB12 to be set by distros. when this is set (and the gdb debugger is used by drkonqi at runtime) then the install debug symbols button gets slightly refined behavior where instead of going to a separate tool to install symbols it will instead run gdb with a suitable cmdline to enable debuginfod. we still prefer the separate installer when also available. in particular the workflow here looks like this: - crash & user opens drkonqi - trace happens without debuginfod - if the trace is poor the install debug info button gets enabled - user clicks button - re-tracing with debuginfod enabled - trace is now amazing and can be reported (cherry picked from commit 2d1f801ea4e164fa109269426311103f1af5ae13) M +1 -0 CMakeLists.txt M +2 -1 src/backtracegenerator.cpp M +5 -0 src/backtracegenerator.h M +2 -0 src/config-drkonqi.h.cmake M +3 -0 src/data/debuggers/internal/gdbrc M +17 -1 src/debugger.cpp M +7 -1 src/debugger.h M +13 -3 src/qml/DeveloperPage.qml https://invent.kde.org/plasma/drkonqi/commit/40f8c11579362755c5242f46ab2e257480d3d06e |