gold/
authorRoland McGrath <roland@gnu.org>
Wed, 7 Nov 2012 17:34:23 +0000 (17:34 +0000)
committerRoland McGrath <roland@gnu.org>
Wed, 7 Nov 2012 17:34:23 +0000 (17:34 +0000)
* target.h (Sized_target::relocate_for_relocatable): Use Elf_Off
for offset_in_output_section parameter.
(Sized_target::relocate_special_relocatable): Likewise.
* arm.cc (Target_arm::relocate_for_relocatable): Likewise.
(Target_arm::relocate_special_relocatable): Likewise.
* i386.cc (Target_i386::relocate_for_relocatable): Likewise.
* powerpc.cc (Target_powerpc::relocate_for_relocatable): Likewise.
* sparc.cc (Target_sparc::relocate_for_relocatable): Likewise.
* target-reloc.h (relocate_for_relocatable): Likewise.
* testsuite/testfile.cc (Target_test): Likewise.
* tilegx.cc (Target_tilegx::relocate_for_relocatable): Likewise.
* x86_64.cc (Target_x86_64::relocate_for_relocatable): Likewise.

gold/ChangeLog
gold/arm.cc
gold/i386.cc
gold/powerpc.cc
gold/sparc.cc
gold/target-reloc.h
gold/target.h
gold/testsuite/testfile.cc
gold/x86_64.cc

index efe9e62..923de7e 100644 (file)
@@ -1,5 +1,18 @@
 2012-11-07  Roland McGrath  <mcgrathr@google.com>
 
+       * target.h (Sized_target::relocate_for_relocatable): Use Elf_Off
+       for offset_in_output_section parameter.
+       (Sized_target::relocate_special_relocatable): Likewise.
+       * arm.cc (Target_arm::relocate_for_relocatable): Likewise.
+       (Target_arm::relocate_special_relocatable): Likewise.
+       * i386.cc (Target_i386::relocate_for_relocatable): Likewise.
+       * powerpc.cc (Target_powerpc::relocate_for_relocatable): Likewise.
+       * sparc.cc (Target_sparc::relocate_for_relocatable): Likewise.
+       * target-reloc.h (relocate_for_relocatable): Likewise.
+       * testsuite/testfile.cc (Target_test): Likewise.
+       * tilegx.cc (Target_tilegx::relocate_for_relocatable): Likewise.
+       * x86_64.cc (Target_x86_64::relocate_for_relocatable): Likewise.
+
        * gold.h: Move inclusion of <clocale> to after <libintl.h> in
        [ENABLE_NLS] section, and separately at top of [!ENABLE_NLS] section.
 
index fa257a7..d434c9d 100644 (file)
@@ -2293,7 +2293,8 @@ class Target_arm : public Sized_target<32, big_endian>
                           const unsigned char* prelocs,
                           size_t reloc_count,
                           Output_section* output_section,
-                          off_t offset_in_output_section,
+                          typename elfcpp::Elf_types<32>::Elf_Off
+                             offset_in_output_section,
                           const Relocatable_relocs*,
                           unsigned char* view,
                           Arm_address view_address,
@@ -2309,7 +2310,8 @@ class Target_arm : public Sized_target<32, big_endian>
                               const unsigned char* preloc_in,
                               size_t relnum,
                               Output_section* output_section,
-                              off_t offset_in_output_section,
+                              typename elfcpp::Elf_types<32>::Elf_Off
+                                 offset_in_output_section,
                               unsigned char* view,
                               typename elfcpp::Elf_types<32>::Elf_Addr
                                 view_address,
@@ -9598,7 +9600,7 @@ Target_arm<big_endian>::relocate_for_relocatable(
     const unsigned char* prelocs,
     size_t reloc_count,
     Output_section* output_section,
-    off_t offset_in_output_section,
+    typename elfcpp::Elf_types<32>::Elf_Off offset_in_output_section,
     const Relocatable_relocs* rr,
     unsigned char* view,
     Arm_address view_address,
@@ -9633,7 +9635,7 @@ Target_arm<big_endian>::relocate_special_relocatable(
     const unsigned char* preloc_in,
     size_t relnum,
     Output_section* output_section,
-    off_t offset_in_output_section,
+    typename elfcpp::Elf_types<32>::Elf_Off offset_in_output_section,
     unsigned char* view,
     elfcpp::Elf_types<32>::Elf_Addr view_address,
     section_size_type,
index 47f33a0..4076960 100644 (file)
@@ -414,7 +414,8 @@ class Target_i386 : public Sized_target<32, false>
                           const unsigned char* prelocs,
                           size_t reloc_count,
                           Output_section* output_section,
-                          off_t offset_in_output_section,
+                           typename elfcpp::Elf_types<32>::Elf_Off
+                             offset_in_output_section,
                           const Relocatable_relocs*,
                           unsigned char* view,
                           elfcpp::Elf_types<32>::Elf_Addr view_address,
@@ -3611,7 +3612,7 @@ Target_i386::relocate_for_relocatable(
     const unsigned char* prelocs,
     size_t reloc_count,
     Output_section* output_section,
-    off_t offset_in_output_section,
+    typename elfcpp::Elf_types<32>::Elf_Off offset_in_output_section,
     const Relocatable_relocs* rr,
     unsigned char* view,
     elfcpp::Elf_types<32>::Elf_Addr view_address,
index d8e8b82..d813791 100644 (file)
@@ -134,7 +134,8 @@ class Target_powerpc : public Sized_target<size, big_endian>
                           const unsigned char* prelocs,
                           size_t reloc_count,
                           Output_section* output_section,
-                          off_t offset_in_output_section,
+                          typename elfcpp::Elf_types<size>::Elf_Off
+                             offset_in_output_section,
                           const Relocatable_relocs*,
                           unsigned char* view,
                           typename elfcpp::Elf_types<size>::Elf_Addr view_address,
@@ -2086,7 +2087,7 @@ Target_powerpc<size, big_endian>::relocate_for_relocatable(
     const unsigned char* prelocs,
     size_t reloc_count,
     Output_section* output_section,
-    off_t offset_in_output_section,
+    typename elfcpp::Elf_types<size>::Elf_Off offset_in_output_section,
     const Relocatable_relocs* rr,
     unsigned char* view,
     typename elfcpp::Elf_types<size>::Elf_Addr view_address,
index 7b78311..7bed538 100644 (file)
@@ -138,13 +138,15 @@ class Target_sparc : public Sized_target<size, big_endian>
                           const unsigned char* prelocs,
                           size_t reloc_count,
                           Output_section* output_section,
-                          off_t offset_in_output_section,
+                          typename elfcpp::Elf_types<size>::Elf_Off
+                             offset_in_output_section,
                           const Relocatable_relocs*,
                           unsigned char* view,
                           typename elfcpp::Elf_types<size>::Elf_Addr view_address,
                           section_size_type view_size,
                           unsigned char* reloc_view,
                           section_size_type reloc_view_size);
+
   // Return whether SYM is defined by the ABI.
   bool
   do_is_defined_by_abi(const Symbol* sym) const
@@ -4207,7 +4209,7 @@ Target_sparc<size, big_endian>::relocate_for_relocatable(
     const unsigned char* prelocs,
     size_t reloc_count,
     Output_section* output_section,
-    off_t offset_in_output_section,
+    typename elfcpp::Elf_types<size>::Elf_Off offset_in_output_section,
     const Relocatable_relocs* rr,
     unsigned char* view,
     typename elfcpp::Elf_types<size>::Elf_Addr view_address,
index 6efcdf4..1a58d07 100644 (file)
@@ -1,6 +1,7 @@
 // target-reloc.h -- target specific relocation support  -*- C++ -*-
 
-// Copyright 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc.
+// Copyright 2006, 2007, 2008, 2009, 2010, 2011, 2012
+// Free Software Foundation, Inc.
 // Written by Ian Lance Taylor <iant@google.com>.
 
 // This file is part of gold.
@@ -93,7 +94,7 @@ scan_relocs(
              //
              // FIXME: We should issue a warning if this is an
              // allocated section; is this the best place to do it?
-             // 
+             //
              // FIXME: The old GNU linker would in some cases look
              // for the linkonce section which caused this section to
              // be discarded, and, if the other section was the same
@@ -305,7 +306,7 @@ relocate_section(
           // If the local symbol belongs to a section we are discarding,
           // and that section is a debug section, try to find the
           // corresponding kept section and map this symbol to its
-          // counterpart in the kept section.  The symbol must not 
+          // counterpart in the kept section.  The symbol must not
           // correspond to a section we are folding.
          bool is_ordinary;
          shndx = psymval->input_shndx(&is_ordinary);
@@ -600,7 +601,7 @@ relocate_for_relocatable(
     const unsigned char* prelocs,
     size_t reloc_count,
     Output_section* output_section,
-    typename elfcpp::Elf_types<size>::Elf_Addr offset_in_output_section,
+    typename elfcpp::Elf_types<size>::Elf_Off offset_in_output_section,
     const Relocatable_relocs* rr,
     unsigned char* view,
     typename elfcpp::Elf_types<size>::Elf_Addr view_address,
index 81c8114..caebfc2 100644 (file)
@@ -796,7 +796,8 @@ class Sized_target : public Target
                           const unsigned char* prelocs,
                           size_t reloc_count,
                           Output_section* output_section,
-                          off_t offset_in_output_section,
+                          typename elfcpp::Elf_types<size>::Elf_Off
+                             offset_in_output_section,
                           const Relocatable_relocs*,
                           unsigned char* view,
                           typename elfcpp::Elf_types<size>::Elf_Addr
@@ -827,7 +828,8 @@ class Sized_target : public Target
                               const unsigned char* /* preloc_in */,
                               size_t /* relnum */,
                               Output_section* /* output_section */,
-                              off_t /* offset_in_output_section */,
+                              typename elfcpp::Elf_types<size>::Elf_Off
+                                 /* offset_in_output_section */,
                               unsigned char* /* view */,
                               typename elfcpp::Elf_types<size>::Elf_Addr
                                 /* view_address */,
index e963d4d..19da50b 100644 (file)
@@ -74,8 +74,9 @@ class Target_test : public Sized_target<size, big_endian>
   void
   relocate_for_relocatable(const Relocate_info<size, big_endian>*,
                           unsigned int, const unsigned char*, size_t,
-                          Output_section*, off_t, const Relocatable_relocs*,
-                          unsigned char*,
+                           Output_section*,
+                           typename elfcpp::Elf_types<size>::Elf_Off,
+                           const Relocatable_relocs*, unsigned char*,
                           typename elfcpp::Elf_types<size>::Elf_Addr,
                           section_size_type, unsigned char*,
                           section_size_type)
index 2ac29bf..b5b616f 100644 (file)
@@ -477,7 +477,7 @@ class Target_x86_64 : public Sized_target<size, false>
       const unsigned char* prelocs,
       size_t reloc_count,
       Output_section* output_section,
-      off_t offset_in_output_section,
+      typename elfcpp::Elf_types<size>::Elf_Off offset_in_output_section,
       const Relocatable_relocs*,
       unsigned char* view,
       typename elfcpp::Elf_types<size>::Elf_Addr view_address,
@@ -2299,7 +2299,7 @@ Target_x86_64<size>::Scan::local(Symbol_table* symtab,
          unsigned int r_sym = elfcpp::elf_r_sym<size>(reloc.get_r_info());
          Reloc_section* rela_dyn = target->rela_dyn_section(layout);
          rela_dyn->add_local_relative(object, r_sym,
-                                      (size == 32 
+                                      (size == 32
                                        ? elfcpp::R_X86_64_RELATIVE64
                                        : elfcpp::R_X86_64_RELATIVE),
                                       output_section, data_shndx,
@@ -4214,7 +4214,7 @@ Target_x86_64<size>::relocate_for_relocatable(
     const unsigned char* prelocs,
     size_t reloc_count,
     Output_section* output_section,
-    off_t offset_in_output_section,
+    typename elfcpp::Elf_types<size>::Elf_Off offset_in_output_section,
     const Relocatable_relocs* rr,
     unsigned char* view,
     typename elfcpp::Elf_types<size>::Elf_Addr view_address,