[GOLD] --gc-sections deletes section referenced from .eh_frame

Alan Modra amodra@gmail.com
Wed Oct 17 14:26:00 GMT 2012


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



More information about the Binutils mailing list