This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: The COFF patch causes testsuit failure on COFF
On Wed, Mar 28, 2001 at 02:22:45AM -0500, Nick Papadonis wrote:
> Nick Clifton <nickc@redhat.com> writes:
>
> > Hi H.J.
> >
> > > I tried. It didn't work for the m68k-coff test. This one seems to work.
> >
> > OK, if Nick confirms this, then please apply this version.
> >
> > Cheers
> > Nick
> >
>
> All set. Apply. Thanks, this has been bugging me for weeks.
>
I checked in this patch.
H.J.
----
2001-03-28 H.J. Lu <hjl@gnu.org>
* read.c (equals): Set to local for COFF only if it hasn't been
defined before.
Index: read.c
===================================================================
RCS file: /work/cvs/gnu/binutils/gas/read.c,v
retrieving revision 1.27
diff -u -p -r1.27 read.c
--- read.c 2001/03/27 23:56:21 1.27
+++ read.c 2001/03/28 02:34:47
@@ -4857,6 +4857,13 @@ equals (sym_name, reassign)
}
else
{
+#ifdef OBJ_COFF
+ int local;
+
+ symbolP = symbol_find (sym_name);
+ local = symbolP == NULL;
+ if (local)
+#endif /* OBJ_COFF */
symbolP = symbol_find_or_make (sym_name);
/* Permit register names to be redefined. */
if (!reassign
@@ -4866,7 +4873,8 @@ equals (sym_name, reassign)
#ifdef OBJ_COFF
/* "set" symbols are local unless otherwise specified. */
- SF_SET_LOCAL (symbolP);
+ if (local)
+ SF_SET_LOCAL (symbolP);
#endif /* OBJ_COFF */
pseudo_set (symbolP);