2017-12-10 22:00:49 +00:00
|
|
|
From FEDORA_PATCHES Mon Sep 17 00:00:00 2001
|
2017-12-04 19:24:00 +00:00
|
|
|
From: Fedora GDB patches <invalid@email.com>
|
|
|
|
Date: Fri, 27 Oct 2017 21:07:50 +0200
|
|
|
|
Subject: gdb-6.5-bz203661-emit-relocs.patch
|
|
|
|
|
|
|
|
FileName: gdb-6.5-bz203661-emit-relocs.patch
|
|
|
|
|
2017-12-08 04:31:26 +00:00
|
|
|
;; Fix debuginfo addresses resolving for --emit-relocs Linux kernels (BZ 203661).
|
|
|
|
;;=push+jan: There was some mail thread about it, this patch may be a hack.
|
|
|
|
---
|
|
|
|
gdb/symfile.c | 6 ++++++
|
|
|
|
1 file changed, 6 insertions(+)
|
|
|
|
|
|
|
|
diff --git a/gdb/symfile.c b/gdb/symfile.c
|
|
|
|
index 8f45d45d85..37a31950a2 100644
|
|
|
|
--- a/gdb/symfile.c
|
|
|
|
+++ b/gdb/symfile.c
|
|
|
|
@@ -3634,6 +3634,12 @@ default_symfile_relocate (struct objfile *objfile, asection *sectp,
|
2012-06-03 17:40:44 +00:00
|
|
|
DWO file. */
|
|
|
|
bfd *abfd = sectp->owner;
|
2010-07-11 18:06:33 +00:00
|
|
|
|
2006-08-24 06:18:06 +00:00
|
|
|
+ /* Executable files have all the relocations already resolved.
|
2012-06-03 17:40:44 +00:00
|
|
|
+ Handle files linked with --emit-relocs.
|
|
|
|
+ http://sources.redhat.com/ml/gdb/2006-08/msg00137.html */
|
2006-08-24 06:18:06 +00:00
|
|
|
+ if ((abfd->flags & EXEC_P) != 0)
|
|
|
|
+ return NULL;
|
|
|
|
+
|
2009-08-04 05:37:29 +00:00
|
|
|
/* We're only interested in sections with relocation
|
2006-08-24 06:18:06 +00:00
|
|
|
information. */
|
|
|
|
if ((sectp->flags & SEC_RELOC) == 0)
|
2017-12-08 04:31:26 +00:00
|
|
|
--
|
|
|
|
2.14.3
|
|
|
|
|