0

The operating system I am currently using is Ubuntu 22.04 (Jammy Jellyfish).

I referred to Ubuntu's Service - Debuginfod official documentation, link: https://ubuntu.com/server/docs/service-debuginfod

And add export DEBUGINFOD_URLS="https://debuginfod.ubuntu.com" to .bashrc as described in the documentation.

Now I can use gdb gcc to get the relevant debuginfo prompt information, as shown below:

Reading symbols from gcc...
Reading symbols from /usr/lib/debug/.build-id/6d/b0b50ebf17b931988c0e36786507e5c58fe192.debug...

But when I use gdb gdb, I get No debugging symbols found in gdb. Does Ubuntu not yet provide debuginfo for gdb?

Thanks for any reply.

Artur Meinild
  • 26,018
  • Yes, I want to debug the debugger. – rocky rocky Sep 11 '23 at 08:20
  • If you inspect the package list located here, there is a package for gdb-dbgsym. So it should be available. – Artur Meinild Sep 11 '23 at 08:28
  • So is there some reason why gdb-dbgsym cannot correctly link to the Ubuntu Debuginfo server? Thanks for your reply. – rocky rocky Sep 11 '23 at 08:40
  • That I don't know.. – Artur Meinild Sep 11 '23 at 08:42
  • After adding the export statement to .bashrc, did you start a new shell? Or did you run the export statement in your current shell as well? – muru Sep 11 '23 at 08:43
  • Hi muru: I have used source .bashrc, and start a new bash – rocky rocky Sep 11 '23 at 09:02
  • 1
    Hmm, looking at https://packages.ubuntu.com/search?keywords=gdb, the original version packaged for gdb in jammy is 12.0.90-0ubuntu1, and it has since been superseded by 12.1-0ubuntu1~22.04 in jammy-updates. But the list given by @ArturMeinild specifies version 12.0.90-0ubuntu1. And if I downgrade using apt install gdb=12.0.90-0ubuntu1, gdb then shows: "Downloading 36.60 MB separate debug info for /usr/bin/gdb". Looks like the newer package doesn't have debug symbols published yet. – muru Sep 11 '23 at 09:10
  • I also successfully downloaded debuginfod after adjusting it to gdb-12.0.90-0ubuntu1. Thank muru's help. – rocky rocky Sep 11 '23 at 09:47

0 Answers0