This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
[GOLD] --gc-sections deletes section referenced from .eh_frame
- From: Alan Modra <amodra at gmail dot com>
- To: binutils at sourceware dot org
- Date: Thu, 18 Oct 2012 00:56:07 +1030
- Subject: [GOLD] --gc-sections deletes section referenced from .eh_frame
Powerpc 32-bit happens to use a section that doesn't match any of
the existing hacks in is_section_name_included(). Details in the PR.
OK to apply?
PR gold/14727
* object.cc (Relobj::is_section_name_included): Also match
.sdata personality section.
Index: gold/object.cc
===================================================================
RCS file: /cvs/src/src/gold/object.cc,v
retrieving revision 1.160
diff -u -p -r1.160 object.cc
--- gold/object.cc 25 Sep 2012 00:59:25 -0000 1.160
+++ gold/object.cc 17 Oct 2012 11:59:14 -0000
@@ -331,7 +331,9 @@ Relobj::is_section_name_included(const c
|| (is_prefix_of(".text", name)
&& strstr(name, "personality"))
|| (is_prefix_of(".data", name)
- && strstr(name, "personality"))
+ && strstr(name, "personality"))
+ || (is_prefix_of(".sdata", name)
+ && strstr(name, "personality"))
|| (is_prefix_of(".gnu.linkonce.d", name)
&& strstr(name, "personality")))
{
--
Alan Modra
Australia Development Lab, IBM