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]

Re: PATCH: Fix gold problem with weak undefined symbols


"Cary Coutant" <ccoutant@google.com> writes:

> This patch fixes a problem in gold where it incorrectly generates a
> dynamic relocation for a reference to a weak undefined symbol, or for
> a reference to an absolute symbol.

Based on this discussion, I think we should go ahead and commit this
to gold.  It makes gold act like GNU ld.  Clearly more thought is
required before changing the linker behaviour in this area.


> 2008-03-31  Cary Coutant  <ccoutant@google.com>
>
> 	* symtab.h (Symbol::is_weak_undefined): New function.
> 	(Symbol::is_strong_undefined): New function.
> 	(Symbol::is_absolute): New function.
> 	(Symbol::needs_plt_entry): Exclude weak undefined symbols.
> 	(Symbol::needs_dynamic_reloc): Exclude weak undefined and
> 	absolute symbols.
> 	* testsuite/Makefile.am (check_PROGRAMS): Add weak_undef_test.
> 	(weak_undef_test): New target.
> 	* testsuite/Makefile.in: Rebuild.
> 	* testsuite/weak_undef_file1.cc: New file.
> 	* testsuite/weak_undef_file2.cc: New file.
> 	* testsuite/weak_undef_test.cc: New file.


> +// Copyright 2006, 2007, 2008 Free Software Foundation, Inc.

Change the copyright date to just 2008 for the new files.

This patch is OK with that change.

Thanks.

Ian


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