Pass ignored unresolved relocations to ld backend
authorH.J. Lu <hjl.tools@gmail.com>
Tue, 5 Nov 2013 18:29:44 +0000 (10:29 -0800)
committerH.J. Lu <hjl.tools@gmail.com>
Tue, 5 Nov 2013 18:29:44 +0000 (10:29 -0800)
bfd/

PR ld/4409
* elf-bfd.h (RELOC_FOR_GLOBAL_SYMBOL): Add an argument for
error ignored.
* elf-m10200.c (mn10200_elf_relocate_section): Updated.
* elf-m10300.c (mn10300_elf_relocate_section): Likewise.
* elf32-arm.c (elf32_arm_relocate_section): Likewise.
* elf32-avr.c (elf32_avr_relocate_section): Likewise.
* elf32-bfin.c (bfinfdpic_relocate_section): Likewise.
(bfin_relocate_section): Likewise.
* elf32-cr16.c (elf32_cr16_relocate_section): Likewise.
* elf32-cr16c.c (elf32_cr16c_relocate_section): Likewise.
* elf32-cris.c (cris_elf_relocate_section): Likewise.
* elf32-crx.c (elf32_crx_relocate_section): Likewise.
* elf32-d10v.c (elf32_d10v_relocate_section): Likewise.
* elf32-epiphany.c (epiphany_elf_relocate_section): Likewise.
* elf32-fr30.c (fr30_elf_relocate_section): Likewise.
* elf32-frv.c (elf32_frv_relocate_section): Likewise.
* elf32-h8300.c (elf32_h8_relocate_section): Likewise.
* elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
* elf32-i386.c (elf_i386_relocate_section): Likewise.
* elf32-i860.c (elf32_i860_relocate_section): Likewise.
* elf32-ip2k.c (ip2k_elf_relocate_section): Likewise.
* elf32-iq2000.c (iq2000_elf_relocate_section): Likewise.
* elf32-lm32.c (lm32_elf_relocate_section): Likewise.
* elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Likewise.
* elf32-m68k.c (elf_m68k_relocate_section): Likewise.
* elf32-metag.c (elf_metag_relocate_section): Likewise.
* elf32-microblaze.c (microblaze_elf_relocate_section): Likewise.
* elf32-mcore.c (mcore_elf_relocate_section): Likewise.
* elf32-mep.c (mep_elf_relocate_section): Likewise.
* elf32-moxie.c (moxie_elf_relocate_section): Likewise.
* elf32-msp430.c (elf32_msp430_relocate_section): Likewise.
* elf32-mt.c (mt_elf_relocate_section): Likewise.
* elf32-nios2.c (nios2_elf32_relocate_section): Likewise.
* elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
* elf32-ppc.c (ppc_elf_relocate_section): Likewise.
* elf32-rl78.c (rl78_elf_relocate_section): Likewise.
* elf32-rx.c (rx_elf_relocate_section): Likewise.
* elf32-tic6x.c (elf32_tic6x_relocate_section): Likewise.
* elf32-tilepro.c (tilepro_elf_relocate_section): Likewise.
* elf32-s390.c (elf_s390_relocate_section): Likewise.
* elf32-v850.c (v850_elf_relocate_section): Likewise.
* elf32-vax.c (elf_vax_relocate_section): Likewise.
* elf32-xc16x.c (elf32_xc16x_relocate_section): Likewise.
* elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
* elf32-xtensa.c (elf_xtensa_relocate_section): Likewise.
* elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
* elf64-ia64-vms.c (elf64_ia64_relocate_section): Likewise.
* elf64-mmix.c (mmix_elf_relocate_section): Likewise.
* elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
* elf64-s390.c (elf_s390_relocate_section): Likewise.
* elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
* elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Likewise.
* elfxx-tilegx.c (tilegx_elf_relocate_section): Likewise.
* elfnn-aarch64.c (elfNN_aarch64_relocate_section): Likewise.

* elfnn-ia64.c (elfNN_ia64_relocate_section): Skip if error
from RELOC_FOR_GLOBAL_SYMBOL in executable is ignored.

ld/testsuite/

PR ld/4409
* ld-ia64/error1.d: New file.
* ld-ia64/error1.s: Likewise.
* ld-ia64/error2.d: Likewise.
* ld-ia64/error3.d: Likewise.

59 files changed:
bfd/ChangeLog
bfd/elf-bfd.h
bfd/elf-m10200.c
bfd/elf-m10300.c
bfd/elf32-arm.c
bfd/elf32-avr.c
bfd/elf32-bfin.c
bfd/elf32-cr16.c
bfd/elf32-cr16c.c
bfd/elf32-cris.c
bfd/elf32-crx.c
bfd/elf32-d10v.c
bfd/elf32-epiphany.c
bfd/elf32-fr30.c
bfd/elf32-frv.c
bfd/elf32-h8300.c
bfd/elf32-hppa.c
bfd/elf32-i386.c
bfd/elf32-i860.c
bfd/elf32-ip2k.c
bfd/elf32-iq2000.c
bfd/elf32-lm32.c
bfd/elf32-m68hc1x.c
bfd/elf32-m68k.c
bfd/elf32-mcore.c
bfd/elf32-mep.c
bfd/elf32-metag.c
bfd/elf32-microblaze.c
bfd/elf32-moxie.c
bfd/elf32-msp430.c
bfd/elf32-mt.c
bfd/elf32-nios2.c
bfd/elf32-openrisc.c
bfd/elf32-ppc.c
bfd/elf32-rl78.c
bfd/elf32-rx.c
bfd/elf32-s390.c
bfd/elf32-tic6x.c
bfd/elf32-tilepro.c
bfd/elf32-v850.c
bfd/elf32-vax.c
bfd/elf32-xc16x.c
bfd/elf32-xstormy16.c
bfd/elf32-xtensa.c
bfd/elf64-alpha.c
bfd/elf64-ia64-vms.c
bfd/elf64-mmix.c
bfd/elf64-ppc.c
bfd/elf64-s390.c
bfd/elf64-x86-64.c
bfd/elfnn-aarch64.c
bfd/elfnn-ia64.c
bfd/elfxx-sparc.c
bfd/elfxx-tilegx.c
ld/testsuite/ChangeLog
ld/testsuite/ld-ia64/error1.d [new file with mode: 0644]
ld/testsuite/ld-ia64/error1.s [new file with mode: 0644]
ld/testsuite/ld-ia64/error2.d [new file with mode: 0644]
ld/testsuite/ld-ia64/error3.d [new file with mode: 0644]

index ac78036cbc37a3ef9a5624f63fd6e6b152848765..806519306bc441aa49b461a5dac0884cb3963766 100644 (file)
@@ -1,3 +1,65 @@
+2013-11-05  H.J. Lu  <hongjiu.lu@intel.com>
+           Bernhard Rosenkränzer <bernhard.rosenkranzer@linaro.org>
+
+       PR ld/4409
+       * elf-bfd.h (RELOC_FOR_GLOBAL_SYMBOL): Add an argument for
+       error ignored.
+       * elf-m10200.c (mn10200_elf_relocate_section): Updated.
+       * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
+       * elf32-arm.c (elf32_arm_relocate_section): Likewise.
+       * elf32-avr.c (elf32_avr_relocate_section): Likewise.
+       * elf32-bfin.c (bfinfdpic_relocate_section): Likewise.
+       (bfin_relocate_section): Likewise.
+       * elf32-cr16.c (elf32_cr16_relocate_section): Likewise.
+       * elf32-cr16c.c (elf32_cr16c_relocate_section): Likewise.
+       * elf32-cris.c (cris_elf_relocate_section): Likewise.
+       * elf32-crx.c (elf32_crx_relocate_section): Likewise.
+       * elf32-d10v.c (elf32_d10v_relocate_section): Likewise.
+       * elf32-epiphany.c (epiphany_elf_relocate_section): Likewise.
+       * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
+       * elf32-frv.c (elf32_frv_relocate_section): Likewise.
+       * elf32-h8300.c (elf32_h8_relocate_section): Likewise.
+       * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
+       * elf32-i386.c (elf_i386_relocate_section): Likewise.
+       * elf32-i860.c (elf32_i860_relocate_section): Likewise.
+       * elf32-ip2k.c (ip2k_elf_relocate_section): Likewise.
+       * elf32-iq2000.c (iq2000_elf_relocate_section): Likewise.
+       * elf32-lm32.c (lm32_elf_relocate_section): Likewise.
+       * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Likewise.
+       * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
+       * elf32-metag.c (elf_metag_relocate_section): Likewise.
+       * elf32-microblaze.c (microblaze_elf_relocate_section): Likewise.
+       * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
+       * elf32-mep.c (mep_elf_relocate_section): Likewise.
+       * elf32-moxie.c (moxie_elf_relocate_section): Likewise.
+       * elf32-msp430.c (elf32_msp430_relocate_section): Likewise.
+       * elf32-mt.c (mt_elf_relocate_section): Likewise.
+       * elf32-nios2.c (nios2_elf32_relocate_section): Likewise.
+       * elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
+       * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
+       * elf32-rl78.c (rl78_elf_relocate_section): Likewise.
+       * elf32-rx.c (rx_elf_relocate_section): Likewise.
+       * elf32-tic6x.c (elf32_tic6x_relocate_section): Likewise.
+       * elf32-tilepro.c (tilepro_elf_relocate_section): Likewise.
+       * elf32-s390.c (elf_s390_relocate_section): Likewise.
+       * elf32-v850.c (v850_elf_relocate_section): Likewise.
+       * elf32-vax.c (elf_vax_relocate_section): Likewise.
+       * elf32-xc16x.c (elf32_xc16x_relocate_section): Likewise.
+       * elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
+       * elf32-xtensa.c (elf_xtensa_relocate_section): Likewise.
+       * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
+       * elf64-ia64-vms.c (elf64_ia64_relocate_section): Likewise.
+       * elf64-mmix.c (mmix_elf_relocate_section): Likewise.
+       * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
+       * elf64-s390.c (elf_s390_relocate_section): Likewise.
+       * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
+       * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Likewise.
+       * elfxx-tilegx.c (tilegx_elf_relocate_section): Likewise.
+       * elfnn-aarch64.c (elfNN_aarch64_relocate_section): Likewise.
+
+       * elfnn-ia64.c (elfNN_ia64_relocate_section): Skip if error
+       from RELOC_FOR_GLOBAL_SYMBOL in executable is ignored.
+
 2013-11-05  Alan Modra  <amodra@gmail.com>
 
        * elf64-ppc.c (ppc64_elf_func_desc_adjust): Make .TOC. defined and
index add80b3c040625f9488bbd52bae01a9f67e10022..15dab945705883552537bda047214cf0f7063bc1 100644 (file)
@@ -2414,7 +2414,7 @@ extern asection _bfd_elf_large_com_section;
 #define RELOC_FOR_GLOBAL_SYMBOL(info, input_bfd, input_section, rel,   \
                                r_symndx, symtab_hdr, sym_hashes,       \
                                h, sec, relocation,                     \
-                               unresolved_reloc, warned)               \
+                               unresolved_reloc, warned, ignored)      \
   do                                                                   \
     {                                                                  \
       /* It seems this can happen with erroneous or unsupported                \
@@ -2429,6 +2429,7 @@ extern asection _bfd_elf_large_com_section;
        h = (struct elf_link_hash_entry *) h->root.u.i.link;            \
                                                                        \
       warned = FALSE;                                                  \
+      ignored = FALSE;                                                 \
       unresolved_reloc = FALSE;                                                \
       relocation = 0;                                                  \
       if (h->root.type == bfd_link_hash_defined                                \
@@ -2451,7 +2452,7 @@ extern asection _bfd_elf_large_com_section;
        ;                                                               \
       else if (info->unresolved_syms_in_objects == RM_IGNORE           \
               && ELF_ST_VISIBILITY (h->other) == STV_DEFAULT)          \
-       ;                                                               \
+       ignored = TRUE;                                                 \
       else if (!info->relocatable)                                     \
        {                                                               \
          bfd_boolean err;                                              \
@@ -2467,6 +2468,7 @@ extern asection _bfd_elf_large_com_section;
        }                                                               \
       (void) unresolved_reloc;                                         \
       (void) warned;                                                   \
+      (void) ignored;                                                  \
     }                                                                  \
   while (0)
 
index f427f97cbf9095cd3fdfb9a00c1cba733cb1d3bd..a7553f32b82d4b5748ecce93dd38c9c680515294 100644 (file)
@@ -373,12 +373,12 @@ mn10200_elf_relocate_section (bfd *output_bfd,
        }
       else
        {
-         bfd_boolean unresolved_reloc, warned;
+         bfd_boolean unresolved_reloc, warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
        }
 
       if (sec != NULL && discarded_section (sec))
index c0a9309b7fff2c1800890e2a6941ff06f049140c..bc3700de6012e33a39f39696ec02d38e6f1f3bdd 100644 (file)
@@ -2011,7 +2011,7 @@ mn10300_elf_relocate_section (bfd *output_bfd,
       bfd_reloc_status_type r;
       int tls_r_type;
       bfd_boolean unresolved_reloc = FALSE;
-      bfd_boolean warned;
+      bfd_boolean warned, ignored;
       struct elf_link_hash_entry * hh;
 
       relocation = 0;
@@ -2034,7 +2034,7 @@ mn10300_elf_relocate_section (bfd *output_bfd,
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   hh, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
        }
       h = elf_mn10300_hash_entry (hh);
 
index 5af1643bf506870e741ee4da7bd645083619e16d..e9c0d20aaf219f907663e6fa7c0299eeb112bf5a 100644 (file)
@@ -10510,12 +10510,12 @@ elf32_arm_relocate_section (bfd *                  output_bfd,
        }
       else
        {
-         bfd_boolean warned;
+         bfd_boolean warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
 
          sym_type = h->type;
        }
index 43100cd20fc0f48e26bdbd8c841c661f9c37c33f..b54b67fca12280e165d7c0950e169bdb9ff1464b 100644 (file)
@@ -1214,12 +1214,12 @@ elf32_avr_relocate_section (bfd *output_bfd ATTRIBUTE_UNUSED,
        }
       else
        {
-         bfd_boolean unresolved_reloc, warned;
+         bfd_boolean unresolved_reloc, warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
 
          name = h->root.root.string;
        }
index d3d0f1c86ddfd25eb7e0fa52ee65b69d2605db70..73d0d09f554e67359b0322724a174af3da250be3 100644 (file)
@@ -1444,12 +1444,12 @@ bfin_relocate_section (bfd * output_bfd,
        }
       else
        {
-         bfd_boolean warned;
+         bfd_boolean warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
        }
 
       if (sec != NULL && discarded_section (sec))
@@ -2662,13 +2662,13 @@ bfinfdpic_relocate_section (bfd * output_bfd,
        }
       else
        {
-         bfd_boolean warned;
+         bfd_boolean warned, ignored;
          bfd_boolean unresolved_reloc;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
          osec = sec;
        }
 
index 8ed5af1c1b575460b4a77dd1903546abccb1f550..af1cf7bb5794916f47534b81dbb0e0cfa0943685 100644 (file)
@@ -1425,12 +1425,12 @@ elf32_cr16_relocate_section (bfd *output_bfd, struct bfd_link_info *info,
         }
       else
         {
-          bfd_boolean unresolved_reloc, warned;
+          bfd_boolean unresolved_reloc, warned, ignored;
 
           RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                    r_symndx, symtab_hdr, sym_hashes,
                                    h, sec, relocation,
-                                   unresolved_reloc, warned);
+                                   unresolved_reloc, warned, ignored);
         }
 
       if (sec != NULL && discarded_section (sec))
index 4231a4291395c2ec8fea142054cb63b235afe9a7..27d8f801537fca0aef105fa0797f9c2bfa2a5c88 100644 (file)
@@ -715,12 +715,12 @@ elf32_cr16c_relocate_section (bfd *output_bfd,
        }
       else
        {
-         bfd_boolean unresolved_reloc, warned;
+         bfd_boolean unresolved_reloc, warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
        }
 
       if (sec != NULL && discarded_section (sec))
index f35292ed6245155b11f016594123a90101ea3832..ab7915121b9c2762fdf42fdf1676e33cdbb70751 100644 (file)
@@ -1040,13 +1040,13 @@ cris_elf_relocate_section (bfd *output_bfd ATTRIBUTE_UNUSED,
        }
       else
        {
-         bfd_boolean warned;
+         bfd_boolean warned, ignored;
          bfd_boolean unresolved_reloc;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
 
          symname = h->root.root.string;
 
index 601f715c03317f258d2eff81e6a78de746204d1c..f26c01edbe1f4148bb9baaef5e8f3724d099d4bb 100644 (file)
@@ -865,12 +865,12 @@ elf32_crx_relocate_section (bfd *output_bfd, struct bfd_link_info *info,
        }
       else
        {
-         bfd_boolean unresolved_reloc, warned;
+         bfd_boolean unresolved_reloc, warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
        }
 
       if (sec != NULL && discarded_section (sec))
index f75c16ae7eca9d2a403740997e76e21003642082..7963bba3cea17fc62bcb3f6a75ff8f6f1f9bb308 100644 (file)
@@ -459,12 +459,12 @@ elf32_d10v_relocate_section (bfd *output_bfd,
        }
       else
        {
-         bfd_boolean unresolved_reloc, warned;
+         bfd_boolean unresolved_reloc, warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
        }
 
       if (sec != NULL && discarded_section (sec))
index b427ef33e097982ff33fef891153c201d7f8896d..f796a67932aee02d5b13e46ee900380b978620e5 100644 (file)
@@ -515,11 +515,12 @@ epiphany_elf_relocate_section (bfd *output_bfd ATTRIBUTE_UNUSED,
        {
          bfd_boolean warned ATTRIBUTE_UNUSED;
          bfd_boolean unresolved_reloc ATTRIBUTE_UNUSED;
+         bfd_boolean ignored ATTRIBUTE_UNUSED;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
 
          name = h->root.root.string;
        }
index 3aed435dd951ed99fc85659a5dd20c8a724032ba..a6ffda31e9d95c7c04e3bc3d93346870293a6f71 100644 (file)
@@ -547,12 +547,12 @@ fr30_elf_relocate_section (bfd *output_bfd,
        }
       else
        {
-         bfd_boolean unresolved_reloc, warned;
+         bfd_boolean unresolved_reloc, warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
 
          name = h->root.root.string;
        }
index 788c2997e8deb07c06d2c0055b620d87ea039887..cf187acaddd2bbb386b1e457662888c8f0996701 100644 (file)
@@ -2735,13 +2735,13 @@ elf32_frv_relocate_section (bfd *output_bfd ATTRIBUTE_UNUSED,
        }
       else
        {
-         bfd_boolean warned;
+         bfd_boolean warned, ignored;
          bfd_boolean unresolved_reloc;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
          osec = sec;
          name = h->root.root.string;
        }
index 67bca3f57375bdeac432f8a5241b532f1e975e47..822d985f6e7ccb5f63c8fff1c41189ec88718811 100644 (file)
@@ -468,12 +468,12 @@ elf32_h8_relocate_section (bfd *output_bfd, struct bfd_link_info *info,
        }
       else
        {
-         bfd_boolean unresolved_reloc, warned;
+         bfd_boolean unresolved_reloc, warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
        }
 
       if (sec != NULL && discarded_section (sec))
index dfffbcba60bf0b12de8963cd99f4799056fb8906..7d1725fa067a8943b947bb15c5079fe08f256241 100644 (file)
@@ -3690,13 +3690,14 @@ elf32_hppa_relocate_section (bfd *output_bfd,
       else
        {
          struct elf_link_hash_entry *eh;
-         bfd_boolean unresolved_reloc;
+         bfd_boolean unresolved_reloc, ignored;
          struct elf_link_hash_entry **sym_hashes = elf_sym_hashes (input_bfd);
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rela,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   eh, sym_sec, relocation,
-                                  unresolved_reloc, warned_undef);
+                                  unresolved_reloc, warned_undef,
+                                  ignored);
 
          if (!info->relocatable
              && relocation == 0
index 560e05cc4f775d60f747c8ca900e79c3c838990f..070e4c45aa7c669e4aca7b52ca08780bb414fd49 100644 (file)
@@ -3311,11 +3311,12 @@ elf_i386_relocate_section (bfd *output_bfd,
       else
        {
          bfd_boolean warned ATTRIBUTE_UNUSED;
+         bfd_boolean ignored ATTRIBUTE_UNUSED;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
          st_size = h->size;
        }
 
index c7991bd82fbcda29aa816d333d1035706341d12b..5440c8b790286db5cf512f51372e7583d55c19e8 100644 (file)
@@ -1121,12 +1121,12 @@ elf32_i860_relocate_section (bfd *output_bfd ATTRIBUTE_UNUSED,
        }
       else
        {
-         bfd_boolean unresolved_reloc, warned;
+         bfd_boolean unresolved_reloc, warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
        }
 
       if (sec != NULL && discarded_section (sec))
index 3bbad147459d004331aee7f696d0395e8b7ab073..2ee907c16e164024c15146b57e037583f1ef3177 100644 (file)
@@ -1425,13 +1425,13 @@ ip2k_elf_relocate_section (bfd *output_bfd ATTRIBUTE_UNUSED,
        }
       else
        {
-         bfd_boolean warned;
+         bfd_boolean warned, ignored;
          bfd_boolean unresolved_reloc;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
 
          name = h->root.root.string;
        }
index 3a90a996982b9a297d55b810ba0996d9231bb25e..ff7ef4a3ea26ba76e7b901b1533ed4c1b57a289e 100644 (file)
@@ -627,12 +627,12 @@ iq2000_elf_relocate_section (bfd *                     output_bfd ATTRIBUTE_UNUSED,
       else
        {
          bfd_boolean unresolved_reloc;
-         bfd_boolean warned;
+         bfd_boolean warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
 
          name = h->root.root.string;
        }
index df6f346467d5f2507639f48db005ea67cb3c3de5..4ebe534ddf139aff6ba3f53e6ac1961b1db738ec 100644 (file)
@@ -875,12 +875,12 @@ lm32_elf_relocate_section (bfd *output_bfd,
         {
           /* It's a global symbol.  */
           bfd_boolean unresolved_reloc;
-         bfd_boolean warned;
+         bfd_boolean warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
          name = h->root.root.string;
         }
 
index 427e3cd2d93906136dfad7e41a3e25709bfda594..f5f68bc41bd10c847e071478ce78a7df5d630bcc 100644 (file)
@@ -979,12 +979,12 @@ elf32_m68hc11_relocate_section (bfd *output_bfd ATTRIBUTE_UNUSED,
        }
       else
        {
-         bfd_boolean unresolved_reloc, warned;
+         bfd_boolean unresolved_reloc, warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation, unresolved_reloc,
-                                  warned);
+                                  warned, ignored);
 
          is_far = (h && (h->other & STO_M68HC12_FAR));
          is_xgate_symbol = (h && (h->target_internal));
index f266d63a150d4f8e4327e00b15a6bd91e541ce5d..d8e3be1c35e66d91bab762b610e76ddafa98397e 100644 (file)
@@ -3669,12 +3669,12 @@ elf_m68k_relocate_section (bfd *output_bfd,
        }
       else
        {
-         bfd_boolean warned;
+         bfd_boolean warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
        }
 
       if (sec != NULL && discarded_section (sec))
index 28ee2c49cf532d76c325f04e797d9a4db603d807..8eb74c5acaa4f0bd6fd70adf1275700810f094bd 100644 (file)
@@ -458,12 +458,12 @@ mcore_elf_relocate_section (bfd * output_bfd,
        }
       else
        {
-         bfd_boolean unresolved_reloc, warned;
+         bfd_boolean unresolved_reloc, warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
        }
 
       if (sec != NULL && discarded_section (sec))
index f356fd06ffe0c2010a10f2b091ddf4bb7b059fce..2204488b554da0ca87e6ae8074ac6b2f0c4135b7 100644 (file)
@@ -490,12 +490,12 @@ mep_elf_relocate_section
        }
       else
        {
-         bfd_boolean warned, unresolved_reloc;
+         bfd_boolean warned, unresolved_reloc, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL(info, input_bfd, input_section, rel,
                                  r_symndx, symtab_hdr, sym_hashes,
                                  h, sec, relocation,
-                                 unresolved_reloc, warned);
+                                 unresolved_reloc, warned, ignored);
 
          name = h->root.root.string;
        }
index 8851845384b050a629935c00cc9e381e62d9e788..9c11dd3d2f1a532b5639ef0572bd8e7ab0e0810e 100644 (file)
@@ -1536,12 +1536,12 @@ elf_metag_relocate_section (bfd *output_bfd,
       else
        {
          struct elf_link_hash_entry *eh;
-         bfd_boolean unresolved_reloc, warned;
+         bfd_boolean unresolved_reloc, warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, eh_syms,
                                   eh, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
 
          name = eh->root.root.string;
          hh = (struct elf_metag_link_hash_entry *) eh;
index 4a5e80dd86debb87c64ad1670105a3684b6eff7c..d936c422d9045cb8a5d8c2faf01780e9d0408733 100644 (file)
@@ -1023,11 +1023,12 @@ microblaze_elf_relocate_section (bfd *output_bfd,
            {
              /* External symbol.  */
              bfd_boolean warned ATTRIBUTE_UNUSED;
+             bfd_boolean ignored ATTRIBUTE_UNUSED;
 
              RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                       r_symndx, symtab_hdr, sym_hashes,
                                       h, sec, relocation,
-                                      unresolved_reloc, warned);
+                                      unresolved_reloc, warned, ignored);
              sym_name = h->root.root.string;
            }
 
index d0cbb0fab43973aa8e53753ba3aba2ab87bb6ec0..a2215db142160bc992b8c32c2b76b36babcdcb91 100644 (file)
@@ -240,12 +240,12 @@ moxie_elf_relocate_section (bfd *output_bfd,
        }
       else
        {
-         bfd_boolean unresolved_reloc, warned;
+         bfd_boolean unresolved_reloc, warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
 
          name = h->root.root.string;
        }
index 2f7a3dad826782543afa688bf1f7712f77c1b5e4..533eea33eceee7e0f3968711950f3b61baf03403 100644 (file)
@@ -1276,12 +1276,12 @@ elf32_msp430_relocate_section (bfd * output_bfd ATTRIBUTE_UNUSED,
        }
       else
        {
-         bfd_boolean unresolved_reloc, warned;
+         bfd_boolean unresolved_reloc, warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
          name = h->root.root.string;
        }
 
index ea05c9117e4086eb321766a0941851f6e1819664..597665c1d56c33ac8d015062032aac2f54cc687c 100644 (file)
@@ -344,12 +344,12 @@ mt_elf_relocate_section
       else
        {
          bfd_boolean unresolved_reloc;
-         bfd_boolean warned;
+         bfd_boolean warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
 
          name = h->root.root.string;
        }
index ba89b94aefb788657a7aa803a1aaf6b17a45f1c7..82e55164c8b9d71c3c194961787028c43d68b969 100644 (file)
@@ -1717,12 +1717,12 @@ nios2_elf32_relocate_section (bfd *output_bfd,
        }
       else
        {
-         bfd_boolean warned;
+         bfd_boolean warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
        }
 
       if (sec && discarded_section (sec))
index 7abc938bc9792962c9698cb1db521696e14b786a..496d2637791e9580a1c899c3a160a1d0b7cb8d06 100644 (file)
@@ -365,12 +365,12 @@ openrisc_elf_relocate_section (bfd *output_bfd,
        }
       else
        {
-         bfd_boolean unresolved_reloc, warned;
+         bfd_boolean unresolved_reloc, warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
        }
 
       if (sec != NULL && discarded_section (sec))
index 63928dc099a5079e0d0575afcaa1ff1ff3db6c1c..47c92ba0b7e30254916eb911b2d309fa1154e601 100644 (file)
@@ -7493,10 +7493,12 @@ ppc_elf_relocate_section (bfd *output_bfd,
        }
       else
        {
+         bfd_boolean ignored;
+
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
 
          sym_name = h->root.root.string;
        }
index a8ee414f85e14ff9008d0558d854a889b5902f72..9060663490c83ddded38c6b5615fc8662d936722 100644 (file)
@@ -460,12 +460,13 @@ rl78_elf_relocate_section
        }
       else
        {
-         bfd_boolean warned;
+         bfd_boolean warned ATTRIBUTE_UNUSED;
+         bfd_boolean ignored ATTRIBUTE_UNUSED;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes, h,
                                   sec, relocation, unresolved_reloc,
-                                  warned);
+                                  warned, ignored);
 
          name = h->root.root.string;
        }
index af84e08f0630fcc222f553a43637366049ec0eb5..a1f29eb4b28e63a4c7175e90d64d5d9e87b34420 100644 (file)
@@ -510,12 +510,12 @@ rx_elf_relocate_section
        }
       else
        {
-         bfd_boolean warned;
+         bfd_boolean warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes, h,
                                   sec, relocation, unresolved_reloc,
-                                  warned);
+                                  warned, ignored);
 
          name = h->root.root.string;
        }
index 6467b03264149266ed2a138f278a89bad7dfc880..9827d46d1371f4427820f75b9e04ce9d7aaeb680 100644 (file)
@@ -2415,11 +2415,12 @@ elf_s390_relocate_section (bfd *output_bfd,
       else
        {
          bfd_boolean warned ATTRIBUTE_UNUSED;
+         bfd_boolean ignored ATTRIBUTE_UNUSED;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
        }
 
       if (sec != NULL && discarded_section (sec))
index 7ac6325f68cdcdba4701e18c04625075b019dd0b..92726b2af4410c4f24373b3e6ac02de9ed82f633 100644 (file)
@@ -2309,12 +2309,12 @@ elf32_tic6x_relocate_section (bfd *output_bfd,
        }
       else
        {
-         bfd_boolean warned;
+         bfd_boolean warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
        }
 
       if (sec != NULL && discarded_section (sec))
index c36da2bee24c01be46ebb1ec5fe1f9e8a7f7d9ee..0e808c4582e62bfd4218015caa81c67bbbb7b4f5 100644 (file)
@@ -2892,12 +2892,13 @@ tilepro_elf_relocate_section (bfd *output_bfd, struct bfd_link_info *info,
        }
       else
        {
-         bfd_boolean warned;
+         bfd_boolean warned ATTRIBUTE_UNUSED;
+         bfd_boolean ignored ATTRIBUTE_UNUSED;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
          if (warned)
            {
              /* To avoid generating warning messages about truncated
index 89724adef9318b9107628540c66cc3c8a4693a2c..6528dc18670f512856d36b3fe35e6a7e65af4f18 100644 (file)
@@ -2211,7 +2211,7 @@ v850_elf_relocate_section (bfd *output_bfd,
        }
       else
        {
-         bfd_boolean unresolved_reloc, warned;
+         bfd_boolean unresolved_reloc, warned, ignored;
 
          /* Note - this check is delayed until now as it is possible and
             valid to have a file without any symbols but with relocs that
@@ -2228,7 +2228,7 @@ v850_elf_relocate_section (bfd *output_bfd,
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
        }
 
       if (sec != NULL && discarded_section (sec))
index c6a8f8188b449252cf1016635f62459b7ede994a..d6ae14e132caa81c5b3e6f93e634ea794668902d 100644 (file)
@@ -1408,12 +1408,12 @@ elf_vax_relocate_section (bfd *output_bfd,
       else
        {
          bfd_boolean unresolved_reloc;
-         bfd_boolean warned;
+         bfd_boolean warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
 
          if ((h->root.type == bfd_link_hash_defined
              || h->root.type == bfd_link_hash_defweak)
index 9f285c7922d6a4b7c3b90d3811445df4f05d05ab..ec7e3da434cae35ab379a179e9af483d3e50a9b1 100644 (file)
@@ -373,12 +373,12 @@ elf32_xc16x_relocate_section (bfd *output_bfd,
        }
       else
        {
-         bfd_boolean unresolved_reloc, warned;
+         bfd_boolean unresolved_reloc, warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
        }
 
       if (sec != NULL && discarded_section (sec))
index 851ebbc631e06c8dfcfe1888d761d46b2d562d95..b5946b7176bde8e6260dd0d972b05b188d001b52 100644 (file)
@@ -818,12 +818,12 @@ xstormy16_elf_relocate_section (bfd *                   output_bfd ATTRIBUTE_UNU
        }
       else
        {
-         bfd_boolean unresolved_reloc, warned;
+         bfd_boolean unresolved_reloc, warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
        }
 
       if (sec != NULL && discarded_section (sec))
index 28ed9aa907d04f7fb62089c39850ef3f3e7ee44c..75ccefef0251cbe796e2b0f84a20344a9a2d37b1 100644 (file)
@@ -2638,10 +2638,12 @@ elf_xtensa_relocate_section (bfd *output_bfd,
        }
       else
        {
+         bfd_boolean ignored;
+
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
 
          if (relocation == 0
              && !unresolved_reloc
index 289164fd666a9931047ad8aa66ab2213398f982c..3dbdab73f36862651f16fe5fb23a3c5f1afee745 100644 (file)
@@ -4303,14 +4303,14 @@ elf64_alpha_relocate_section (bfd *output_bfd, struct bfd_link_info *info,
        }
       else
        {
-         bfd_boolean warned;
+         bfd_boolean warned, ignored;
          struct elf_link_hash_entry *hh;
          struct elf_link_hash_entry **sym_hashes = elf_sym_hashes (input_bfd);
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   hh, sec, value,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
 
          if (warned)
            continue;
index 102cdff8d97ebfc1a22363fd9acefa638e052c89..58a05af845b2852ed0aaf43f0a792ae4f8f93d4f 100644 (file)
@@ -3495,13 +3495,13 @@ elf64_ia64_relocate_section (bfd *output_bfd,
       else
        {
          bfd_boolean unresolved_reloc;
-         bfd_boolean warned;
+         bfd_boolean warned, ignored;
          struct elf_link_hash_entry **sym_hashes = elf_sym_hashes (input_bfd);
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sym_sec, value,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
 
          if (h->root.type == bfd_link_hash_undefweak)
            undef_weak_ref = TRUE;
index 499bcd609ad0089aff9604bb0e1647cdebd27c13..c7e1c250d9b74858dd2b3f2c977733c7863828db 100644 (file)
@@ -1413,12 +1413,13 @@ mmix_elf_relocate_section (bfd *output_bfd ATTRIBUTE_UNUSED,
        }
       else
        {
-         bfd_boolean unresolved_reloc;
+         bfd_boolean unresolved_reloc, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, undefined_signalled);
+                                  unresolved_reloc, undefined_signalled,
+                                  ignored);
          name = h->root.root.string;
        }
 
index 136887f25e2d7de673450f44a0ae3d065dd77d19..24c733e21dcd9f8b15cbe5725272be7c3bb5663d 100644 (file)
@@ -12973,10 +12973,12 @@ ppc64_elf_relocate_section (bfd *output_bfd,
        }
       else
        {
+         bfd_boolean ignored;
+
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h_elf, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
          sym_name = h_elf->root.root.string;
          sym_type = h_elf->type;
          if (sec != NULL
index 3aea98ce765f0cfba9d7437dc9f8644a7abaa897..601aa4374d54ea0a4f972949499576c86528b290 100644 (file)
@@ -2374,11 +2374,12 @@ elf_s390_relocate_section (bfd *output_bfd,
       else
        {
          bfd_boolean warned ATTRIBUTE_UNUSED;
+         bfd_boolean ignored ATTRIBUTE_UNUSED;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
        }
 
       if (sec != NULL && discarded_section (sec))
index f748641ea8d5fae8f2ba3b7d3cdae128397ba7ab..c95fdf5f9cb7afbb41be5df54b653a9fb167dcc6 100644 (file)
@@ -3298,11 +3298,12 @@ elf_x86_64_relocate_section (bfd *output_bfd,
       else
        {
          bfd_boolean warned ATTRIBUTE_UNUSED;
+         bfd_boolean ignored ATTRIBUTE_UNUSED;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
          st_size = h->size;
        }
 
index 8f0e71699fdc1626d674f06bc029c53410a8f6ea..3424ae2f8f723fad0982e02fc52ac363dab40caa 100644 (file)
@@ -4132,12 +4132,12 @@ elfNN_aarch64_relocate_section (bfd *output_bfd,
        }
       else
        {
-         bfd_boolean warned;
+         bfd_boolean warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
 
          sym_type = h->type;
        }
index 117b4c8c67168f249a65792d0b02bbcb8920453c..ef340cf9855a4f820dfe6aabe52f24ddf2407c62 100644 (file)
@@ -3902,17 +3902,17 @@ elfNN_ia64_relocate_section (bfd *output_bfd,
       else
        {
          bfd_boolean unresolved_reloc;
-         bfd_boolean warned;
+         bfd_boolean warned, ignored;
          struct elf_link_hash_entry **sym_hashes = elf_sym_hashes (input_bfd);
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sym_sec, value,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
 
          if (h->root.type == bfd_link_hash_undefweak)
            undef_weak_ref = TRUE;
-         else if (warned)
+         else if (warned || (ignored && info->executable))
            continue;
        }
 
index 94da3600a820696a58e475695347ba06df64ff5d..8250f840a13558da074662f97757479e6e35c8f0 100644 (file)
@@ -3019,12 +3019,12 @@ _bfd_sparc_elf_relocate_section (bfd *output_bfd,
        }
       else
        {
-         bfd_boolean warned;
+         bfd_boolean warned, ignored;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
          if (warned)
            {
              /* To avoid generating warning messages about truncated
index c57e38f3a719d8828ebbd72827144e22201692f3..594ee7998493ae2fc904285ef67fb648928eec0d 100644 (file)
@@ -3191,12 +3191,13 @@ tilegx_elf_relocate_section (bfd *output_bfd, struct bfd_link_info *info,
        }
       else
        {
-         bfd_boolean warned;
+         bfd_boolean warned ATTRIBUTE_UNUSED;
+         bfd_boolean ignored ATTRIBUTE_UNUSED;
 
          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
                                   r_symndx, symtab_hdr, sym_hashes,
                                   h, sec, relocation,
-                                  unresolved_reloc, warned);
+                                  unresolved_reloc, warned, ignored);
          if (warned)
            {
              /* To avoid generating warning messages about truncated
index 38192f2169a19cbd78cb2a647fb7c89a0c699eca..68360428dca58cbb742476f7f45bbc6a687b6a7f 100644 (file)
@@ -1,3 +1,11 @@
+2013-11-05  H.J. Lu  <hongjiu.lu@intel.com>
+
+       PR ld/4409
+       * ld-ia64/error1.d: New file.
+       * ld-ia64/error1.s: Likewise.
+       * ld-ia64/error2.d: Likewise.
+       * ld-ia64/error3.d: Likewise.
+
 2013-11-04  Alan Modra  <amodra@gmail.com>
 
        * ld-powerpc/elfv2exe.d: Adjust for non-PIC global entry.
diff --git a/ld/testsuite/ld-ia64/error1.d b/ld/testsuite/ld-ia64/error1.d
new file mode 100644 (file)
index 0000000..82142b6
--- /dev/null
@@ -0,0 +1,7 @@
+#source: error1.s
+#ld: -unresolved-symbols=ignore-all
+#readelf: -s
+
+#...
+[      ]+[0-9]+:[      ]+[0]+[         ]+0[    ]+NOTYPE[       ]+GLOBAL DEFAULT[       ]+UND[  ]+foo
+#pass
diff --git a/ld/testsuite/ld-ia64/error1.s b/ld/testsuite/ld-ia64/error1.s
new file mode 100644 (file)
index 0000000..fd48eae
--- /dev/null
@@ -0,0 +1,30 @@
+       .explicit
+       .pred.safe_across_calls p1-p5,p16-p63
+       .text
+       .align 16
+       .global _start#
+       .proc _start#
+_start:
+       .prologue 12, 32
+       .mii
+       .save ar.pfs, r33
+       alloc r33 = ar.pfs, 0, 3, 0, 0
+       .save rp, r32
+       mov r32 = b0
+       mov r34 = r1
+       .body
+       ;;
+       .bbb
+       nop 0
+       nop 0
+       br.call.sptk.many b0 = foo#
+       ;;
+       .mmi
+       nop 0
+       mov r1 = r34
+       mov b0 = r32
+       .mib
+       nop 0
+       mov ar.pfs = r33
+       br.ret.sptk.many b0
+       .endp _start#
diff --git a/ld/testsuite/ld-ia64/error2.d b/ld/testsuite/ld-ia64/error2.d
new file mode 100644 (file)
index 0000000..764ba66
--- /dev/null
@@ -0,0 +1,7 @@
+#source: error1.s
+#ld: -pie -unresolved-symbols=ignore-all
+#readelf: -s
+
+#...
+[      ]+[0-9]+:[      ]+[0]+[         ]+0[    ]+NOTYPE[       ]+GLOBAL DEFAULT[       ]+UND[  ]+foo
+#pass
diff --git a/ld/testsuite/ld-ia64/error3.d b/ld/testsuite/ld-ia64/error3.d
new file mode 100644 (file)
index 0000000..e14d451
--- /dev/null
@@ -0,0 +1,7 @@
+#source: error1.s
+#ld: -pie -shared
+#readelf: -s
+
+#...
+[      ]+[0-9]+:[      ]+[0]+[         ]+0[    ]+NOTYPE[       ]+GLOBAL DEFAULT[       ]+UND[  ]+foo
+#pass
This page took 0.099611 seconds and 4 git commands to generate.