[Bug debugedit/33823] debugedit fails to detect sources if DWARF contains relative, not absolute paths (empty debugsourcefiles.list)

mark at klomp dot org sourceware-bugzilla@sourceware.org
Tue Mar 17 20:47:09 GMT 2026


https://sourceware.org/bugzilla/show_bug.cgi?id=33823

Mark Wielaard <mark at klomp dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |mark at klomp dot org

--- Comment #4 from Mark Wielaard <mark at klomp dot org> ---
(In reply to Frank Ch. Eigler from comment #3)
> Why are these file-prefix-map options being used at all?  If absent,
> wouldn't the initial compiler-generated dwarf files get their normal
> absolute path names, which then debugedit could rename as usual?

I believe they are set in the upstream build system.
And yes, when removed debugedit would be able to handle the absolute path names
as usyal.

Question is what we want to do.
1) Detect and warn (or error) for any "relative" paths found
2) Detect and hopefully guess the correct absolute paths and process as if the
path names were absolute?

1) Is easy (just check the path does't start with '/'), but might not be super
useful. Except to make sure the packager removes the --file-prefix options from
the build.

2) Is slightly tricky since in theory an executable might be linked together
from different object files build in (or from) different directories, so the
paths might be relative to different directories per CU. Needs some
experimenting with different heuristics to make sure we get it correct most of
the time.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the Debugedit mailing list