From: "Frank Ch. Eigler" <fche@elastic.org>
To: elfutils-devel@sourceware.org
Subject: [patch] debuginfod.8
Date: Tue, 14 Nov 2023 14:13:20 -0500 [thread overview]
Message-ID: <ZVPG0PCKGgoTU5zO@elastic.org> (raw)
commit 06e0aacb4b288403bd02a0820dd0f87c7f017a2b (HEAD -> master)
Author: Frank Ch. Eigler <fche@redhat.com>
Date: Tue Nov 14 14:09:40 2023 -0500
doc/debuginfod.8: clarify source file handling
Added text about the archive common-prefix heuristic, mentioned
the new eu-srcfiles tool, and gave some extra debian advice.
Signed-off-by: Frank Ch. Eigler <fche@redhat.com>
diff --git a/doc/debuginfod.8 b/doc/debuginfod.8
index 4f1f04b386bd..d79a193c8d9e 100644
--- a/doc/debuginfod.8
+++ b/doc/debuginfod.8
@@ -48,16 +48,10 @@ file. Source files are matched with DWARF files based on the
source files listed in the DWARF may be a path \fIanywhere\fP in the
file system, and debuginfod will readily serve their content on
demand. (Imagine a doctored DWARF file that lists \fI/etc/passwd\fP
-as a source file.) If this is a concern, audit your binaries with
-tools such as:
+as a source file.) If this is a concern, audit your binaries:
.SAMPLE
-% eu-readelf -wline BINARY | sed -n '/^Directory.table/,/^File.name.table/p'
-or
-% eu-readelf -wline BINARY | sed -n '/^Directory.table/,/^Line.number/p'
-or even use debuginfod itself:
-% debuginfod -vvv -d :memory: -F BINARY 2>&1 | grep 'recorded.*source'
-^C
+% eu-srcfiles -e BINARY
.ESAMPLE
If any of the \fB\-R\fP, \fB-U\fP, or \fB-Z\fP options is given, each
@@ -65,12 +59,17 @@ file is scanned as an archive file that may contain ELF/DWARF/source
files. Archive files are recognized by extension. If \-R is given,
".rpm" files are scanned; if \-U is given, ".deb" and ".ddeb" files
are scanned; if \-Z is given, the listed extensions are scanned.
-Because of complications such as DWZ-compressed debuginfo, may require
-\fItwo\fP traversal passes to identify all source code. Source files
-for RPMs are only served from other RPMs, so the caution for \-F does
-not apply. Note that due to Debian/Ubuntu packaging policies &
-mechanisms, debuginfod cannot resolve source files for DEB/DDEB at
-all.
+
+Because of complications such as DWZ-compressed debuginfo, it may
+require \fItwo\fP traversal passes to identify all source code.
+Source files for binaries in archives are only served from archives,
+so the caution for \-F does not apply. If the same source file may be
+found in multiple different archives, a heuristic chooses the one
+closest to the archive holding the debuginfo. ("closest" means
+"longest common archive name prefix"). Note that due to Debian/Ubuntu
+packaging policies & mechanisms, debuginfod cannot resolve source
+files for DEB/DDEB at all. Consider using the
+\-\-disable\-source\-scan option.
If no PATH is listed, or none of the scanning options is given, then
\fBdebuginfod\fP will simply serve content that it accumulated into
reply other threads:[~2023-11-14 19:13 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ZVPG0PCKGgoTU5zO@elastic.org \
--to=fche@elastic.org \
--cc=elfutils-devel@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).