This is the mail archive of the
mailing list for the elfutils project.
[Bug debuginfod/25548] New: also support canonicalized source-file name lookups in webapi
- From: "fche at redhat dot com" <sourceware-bugzilla at sourceware dot org>
- To: elfutils-devel at sourceware dot org
- Date: Thu, 13 Feb 2020 15:02:20 +0000
- Subject: [Bug debuginfod/25548] New: also support canonicalized source-file name lookups in webapi
- Auto-submitted: auto-generated
Bug ID: 25548
Summary: also support canonicalized source-file name lookups in
Assignee: unassigned at sourceware dot org
Reporter: fche at redhat dot com
CC: elfutils-devel at sourceware dot org,
jan.kratochvil at redhat dot com, kkleine at redhat dot com
Target Milestone: ---
It turns out that some debuginfo consumers canonicalize source-code file names
by the time they get the convenient chance to fall back to debuginfod. This
means that path substrings that POSIX defines as no-ops are lost. debuginfod
should extend a gracious embrace to these tools by also permitting such paths
to be used during the /buildid/hexcode/source/PATH webapi.
Implementing this should not be too hard. The dwarf_extract_source_paths could
add both waldo and a new canonicalize_posix_path(waldo) to the returned
debug_sourcefiles set. That's it.
The canonicalize_posix_path() function would perform these textual rewrites,
repeating until convergence:
/./ -> /
/FOO/../ -> / # NB: FOO must not be . or .. because /../../ != /
// -> /
(realpath(3) is not helpful because it looks at the host filesystem to do
resolution, which we cannot when dealing with archive-resident file names.)
You are receiving this mail because:
You are on the CC list for the bug.