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

fix xcoff absolute syms


Fixes xcoff ld testsuite failures.
binaix213/binutils/nm-new   tmpdir/def >tmpdir/nm.out
BFD: warning: tmpdir/def: local symbol `^X    t      ' has no section
BFD: warning: tmpdir/def: local symbol `p     204    ' has no section
ERROR: tmpdir/def: nm failed
UNRESOLVED: DEFINED (PRMS 5699)

	* xcofflink.c (xcoff_write_global_symbol): Set n_scnum for abs_section.

Index: bfd/xcofflink.c
===================================================================
RCS file: /cvs/src/src/bfd/xcofflink.c,v
retrieving revision 1.27
diff -u -p -r1.27 xcofflink.c
--- bfd/xcofflink.c	25 Jun 2002 06:21:54 -0000	1.27
+++ bfd/xcofflink.c	6 Aug 2002 08:13:21 -0000
@@ -5887,7 +5887,10 @@ xcoff_write_global_symbol (h, inf)
       isym.n_value = (h->root.u.def.section->output_section->vma
 		      + h->root.u.def.section->output_offset
 		      + h->root.u.def.value);
-      isym.n_scnum = h->root.u.def.section->output_section->target_index;
+      if (bfd_is_abs_section (h->root.u.def.section->output_section))
+	isym.n_scnum = N_ABS;
+      else
+	isym.n_scnum = h->root.u.def.section->output_section->target_index;
       isym.n_sclass = C_HIDEXT;
       aux.x_csect.x_smtyp = XTY_SD;
 

-- 
Alan Modra
IBM OzLabs - Linux Technology Centre


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