This is the mail archive of the binutils@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]

[committed] Fix PR binutils/9921


This small change improves the behavior of .set and .equiv on the hppa
som target.  We weren't setting ST_ABSOLUTE for unknown symbols in the
absolute section.

Tested on hppa2.0w-hp-hpux11.11.

Dave
-- 
J. David Anglin                                  dave.anglin@nrc-cnrc.gc.ca
National Research Council of Canada              (613) 990-0752 (FAX: 952-6602)

2009-03-07  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>

	PR binutils/9921
	* som.c (som_bfd_derive_misc_symbol_info): Set symbol type ST_ABSOLUTE
	for unknown symbols in absolute section.

Index: som.c
===================================================================
RCS file: /cvs/src/src/bfd/som.c,v
retrieving revision 1.71
diff -u -3 -p -r1.71 som.c
--- som.c	28 Aug 2008 02:33:44 -0000	1.71
+++ som.c	7 Mar 2009 22:30:58 -0000
@@ -4015,7 +4015,9 @@ som_bfd_derive_misc_symbol_info (bfd *ab
 	 section (ST_DATA for DATA sections, ST_CODE for CODE sections).  */
       else if (som_symbol_data (sym)->som_type == SYMBOL_TYPE_UNKNOWN)
 	{
-	  if (sym->section->flags & SEC_CODE)
+	  if (bfd_is_abs_section (sym->section))
+	    info->symbol_type = ST_ABSOLUTE;
+	  else if (sym->section->flags & SEC_CODE)
 	    info->symbol_type = ST_CODE;
 	  else
 	    info->symbol_type = ST_DATA;


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