From 065a2c74b5aa7c28709928ca57aa49c2fb507079 Mon Sep 17 00:00:00 2001 From: Pedro Alves Date: Sun, 22 Mar 2009 17:32:16 +0000 Subject: [PATCH] * symfile.c (symfile_relocate_debug_section): Remove check for SEC_DEBUGGING. --- gdb/ChangeLog | 5 +++++ gdb/symfile.c | 9 +++++---- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index e9b369538da..5f77b434d33 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2009-03-22 Pedro Alves + + * symfile.c (symfile_relocate_debug_section): Remove check for + SEC_DEBUGGING. + 2009-03-21 Jan Kratochvil Jim Blandy Thiago Jung Bauermann diff --git a/gdb/symfile.c b/gdb/symfile.c index 63b5c1d8444..f25c45ebc21 100644 --- a/gdb/symfile.c +++ b/gdb/symfile.c @@ -3940,17 +3940,18 @@ symfile_dummy_outputs (bfd *abfd, asection *sectp, void *dummy) one affected platform is PowerPC GNU/Linux, although it depends on the version of the linker in use). Also, ELF object files naturally have unresolved relocations for their debug sections. We need to apply - the relocations in order to get the locations of symbols correct. */ + the relocations in order to get the locations of symbols correct. + Another example that may require relocation processing, is the + DWARF-2 .eh_frame section in .o files, although it isn't strictly a + debug section. */ bfd_byte * symfile_relocate_debug_section (bfd *abfd, asection *sectp, bfd_byte *buf) { - /* We're only interested in debugging sections with relocation + /* We're only interested in sections with relocation information. */ if ((sectp->flags & SEC_RELOC) == 0) return NULL; - if ((sectp->flags & SEC_DEBUGGING) == 0) - return NULL; /* We will handle section offsets properly elsewhere, so relocate as if all sections begin at 0. */ -- 2.30.2