Bug 1970741

Summary: Empty DEBUGINFOD_URLS not the same as none
Product: [Fedora] Fedora Reporter: Milan Crha <mcrha>
Component: gdbAssignee: Kevin Buettner <kevinb>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 34CC: adscvr, aoliva, blarsen, fche, jakub, jan, jan.kratochvil, keiths, kevinb, mcermak, me, mjw, pmuldoon, sergiodj
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-11-05 12:36:55 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Milan Crha 2021-06-11 05:23:48 UTC
This is on Fedora 34 with elfutils-debuginfod-client-0.183-1.fc34.x86_64

In light of the bug #1970312 I wanted to be proactive and updated my .bashrc with:

   export DEBUGINFOD_URLS=

(it's an empty string), as indicated at [1]. Now, when I run gdb with some project, it claims:

Download failed: Function not implemented.  Continuing without debug info for /lib64/ld-linux-x86-64.so.2.
Download failed: Function not implemented.  Continuing without debug info for /data/develop/local/evolution-data-server/system-supplied DSO at 0x7ffff7fc9000.
Download failed: Function not implemented.  Continuing without debug info for /lib64/libc.so.6.
Download failed: Function not implemented.  Continuing without debug info for /lib64/libpthread.so.0.
.....

there are like 50+ lines with various libraries listed.

I thought, when I set the URLS to an empty value, it'll be the same as when it's not set. When I `unset DEBUGINFOD_URLS`, then the messages from gdb are gone.

The [1] is not clear how to opt out, it should ideally provide a command, rather than vague description. I also believe the debuginfod should distinguish between existing & filled and existing & empty environment variable.

[1] https://fedoraproject.org/wiki/Changes/DebuginfodByDefault

Comment 1 Mark Wielaard 2021-06-11 11:25:41 UTC
I think this is a GDB bug. GDB is trying to be helpful by reporting the ENOSYS from debuginfod_find_debuginfo. But that simply means DEBUGINFOD_URLS isn't set (or empty) as stated in debuginfod_find_debuginfo (3) under ERRORS

       ENOSYS $DEBUGINFOD_URLS is not defined.

Comment 2 Guinevere Larsen 2021-09-27 15:52:24 UTC
This issue was already fixed in upstream. We are now finishing work on backporting it to fedora 34

Comment 3 Guinevere Larsen 2021-11-05 12:36:55 UTC
Closing this bug as GDB 11.1 has just been released for fedora 34, with the fix