| From 99617d7ab5b01c322b0f27d4aa0dd91c61793a5e Mon Sep 17 00:00:00 2001 |
| From: =?UTF-8?q?=C3=89rico=20Nogueira?= <erico.erc@gmail.com> |
| Date: Wed, 10 Nov 2021 21:17:48 -0300 |
| Subject: [PATCH] debuginfod: fix compilation on platforms without <error.h> |
| MIME-Version: 1.0 |
| Content-Type: text/plain; charset=UTF-8 |
| Content-Transfer-Encoding: 8bit |
| |
| "system.h" only declares the error() function, so it needs to be in an |
| 'extern "C"' block, otherwise linking fails. |
| |
| Since we are here, use quotes for "system.h" header, since it's a local |
| header, not a system one. |
| |
| Upstream-Status: Backport [https://sourceware.org/git/?p=elfutils.git;a=commit;h=90b9e91b961b794a4e58ab76d9191a5e7343584e] |
| Signed-off-by: Érico Nogueira <erico.erc@gmail.com> |
| Signed-off-by: Alexander Kanavin <alex@linutronix.de> |
| --- |
| debuginfod/ChangeLog | 4 ++++ |
| debuginfod/debuginfod.cxx | 2 +- |
| 2 files changed, 5 insertions(+), 1 deletion(-) |
| |
| diff --git a/debuginfod/ChangeLog b/debuginfod/ChangeLog |
| index f06d3ee..822bd63 100644 |
| --- a/debuginfod/ChangeLog |
| +++ b/debuginfod/ChangeLog |
| @@ -1,3 +1,7 @@ |
| +2021-11-10 Érico N. Rolim <erico.erc@gmail.com> |
| + |
| + * debuginfod.cxx: include "system.h" under 'extern "C"' block. |
| + |
| 2021-11-05 Frank Ch. Eigler <fche@redhat.com> |
| |
| PR28430 |
| diff --git a/debuginfod/debuginfod.cxx b/debuginfod/debuginfod.cxx |
| index 521cb52..764e7b9 100644 |
| --- a/debuginfod/debuginfod.cxx |
| +++ b/debuginfod/debuginfod.cxx |
| @@ -33,11 +33,11 @@ |
| |
| extern "C" { |
| #include "printversion.h" |
| +#include "system.h" |
| } |
| |
| #include "debuginfod.h" |
| #include <dwarf.h> |
| -#include <system.h> |
| |
| #include <argp.h> |
| #ifdef __GNUC__ |
| -- |
| 2.20.1 |
| |