debuginfod-client: Add debuginfod_set_verbose_fd and DEBUGINFOD_VERBOSE
authorMark Wielaard <mark@klomp.org>
Tue, 10 Nov 2020 23:23:08 +0000 (00:23 +0100)
committerMark Wielaard <mark@klomp.org>
Mon, 23 Nov 2020 15:58:36 +0000 (16:58 +0100)
commit609053a588a3857bb74a342c8468db77c3af88d4
tree030ebe71f78690321a88c90afded6873d070e790
parent371a4f814875ff47c75a76ec57a7a9098f5ab512
debuginfod-client: Add debuginfod_set_verbose_fd and DEBUGINFOD_VERBOSE

Introduce a new function debuginfod_set_verbose_fd which will produce
verbose output on a given file descriptor (STDERR_FILENO if the
environment variable DEBUGINFOD_VERBOSE is set) showing how the search
for a particular client query is going.

Example output:

debuginfod_find_debuginfo 1234567890
server urls "https://debuginfod.elfutils.org/ http://dbgd.usersys.com:3632/"
checking build-id
checking cache dir /home/mark/.cache/debuginfod_client
using timeout 90
init server 0 https://debuginfod.elfutils.org/
url 0 https://debuginfod.elfutils.org/buildid/1234567890/debuginfo
init server 1 http://dbgd.usersys.com:3632/
url 1 http://dbgd.usersys.com:3632/buildid/1234567890/debuginfo
query 2 urls in parallel
server response HTTP response code said error
url 0 The requested URL returned error: 404 Not Found
server response HTTP response code said error
url 1 The requested URL returned error: 404 Not Found
not found No such file or directory (err=-2)

Signed-off-by: Mark Wielaard <mark@klomp.org>
debuginfod/ChangeLog
debuginfod/debuginfod-client.c
debuginfod/debuginfod-find.c
debuginfod/debuginfod.h
debuginfod/libdebuginfod.map
doc/ChangeLog
doc/debuginfod_find_debuginfo.3