Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/gnu/dist/toolchain/bfd Correct resolution of R_ARM_REL32 rel...



details:   https://anonhg.NetBSD.org/src/rev/df485069fd90
branches:  trunk
changeset: 513521:df485069fd90
user:      bjh21 <bjh21%NetBSD.org@localhost>
date:      Thu Aug 02 23:35:00 2001 +0000

description:
Correct resolution of R_ARM_REL32 relocations.  They were being resolved
relative to the start of the section rather than the location of the
relocation.  This made differences of two symbols in different files stop
working.

I believe GCC never generates this kind of relocation, which is why this bug
hasn't surfaced before.

This patch has been sent to <bug-gnu-utils%gnu.org@localhost>.

diffstat:

 gnu/dist/toolchain/bfd/elf32-arm.h |  2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diffs (12 lines):

diff -r 87ed8ba75fbf -r df485069fd90 gnu/dist/toolchain/bfd/elf32-arm.h
--- a/gnu/dist/toolchain/bfd/elf32-arm.h        Thu Aug 02 22:41:32 2001 +0000
+++ b/gnu/dist/toolchain/bfd/elf32-arm.h        Thu Aug 02 23:35:00 2001 +0000
@@ -1283,7 +1283,7 @@
 
        case R_ARM_REL32:
          value -= (input_section->output_section->vma
-                   + input_section->output_offset);
+                   + input_section->output_offset + rel->r_offset);
          value += addend;
          break;
        }



Home | Main Index | Thread Index | Old Index