[PATCH][RFC] Explicitly set ELF symbol size to zero for undefined symbols -- libbfd, gold
Ian Lance Taylor
iant@google.com
Mon Jul 21 15:50:00 GMT 2008
Simon Baldwin <simonb@google.com> writes:
> ! // Use a symbol size of zero for undefined symbols from shared libraries.
> ! if (shndx == elfcpp::SHN_UNDEF && sym->in_dyn())
> ! osym.put_st_size(0);
> ! else
> ! osym.put_st_size(sym->symsize());
This isn't quite the same for gold. in_dyn can mean that the symbol
is referenced but not defined in a dynamic object. If you change
in_dyn to is_from_dynobj, this patch is OK for gold when it is OK for
BFD. Thanks.
Ian
More information about the Binutils
mailing list