This is the mail archive of the binutils-cvs@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[binutils-gdb/binutils-2_25-branch] Downgrade linker error on protected symbols in .dynbss to a warning


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=e700dd4cc48839215235097c2468f5e1d46ef80c

commit e700dd4cc48839215235097c2468f5e1d46ef80c
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Apr 10 10:09:34 2015 +0930

    Downgrade linker error on protected symbols in .dynbss to a warning
    
    	PR ld/18222
    	* elflink.c (_bfd_elf_adjust_dynamic_copy): Don't report an error
    	on adding a protected visibility variable to .dynbss.

Diff:
---
 bfd/ChangeLog |  6 ++++++
 bfd/elflink.c | 10 +++-------
 2 files changed, 9 insertions(+), 7 deletions(-)

diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index 14aea85..2060e3c 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,5 +1,11 @@
 2015-04-10  Alan Modra  <amodra@gmail.com>
 
+	PR ld/18222
+	* elflink.c (_bfd_elf_adjust_dynamic_copy): Don't report an error
+	on adding a protected visibility variable to .dynbss.
+
+2015-04-10  Alan Modra  <amodra@gmail.com>
+
 	Revert 2015-03-06  H.J. Lu  <hongjiu.lu@intel.com>
 	PR ld/pr15228
 	PR ld/pr17709
diff --git a/bfd/elflink.c b/bfd/elflink.c
index 3d6d3ac..2c6b04b 100644
--- a/bfd/elflink.c
+++ b/bfd/elflink.c
@@ -2675,13 +2675,9 @@ _bfd_elf_adjust_dynamic_copy (struct bfd_link_info *info,
   dynbss->size += h->size;
 
   if (h->protected_def)
-    {
-      info->callbacks->einfo
-	(_("%P: copy reloc against protected `%T' is invalid\n"),
-	 h->root.root.string);
-      bfd_set_error (bfd_error_bad_value);
-      return FALSE;
-    }
+    info->callbacks->einfo
+      (_("%P: copy reloc against protected `%T' is dangerous\n"),
+       h->root.root.string);
 
   return TRUE;
 }


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]