gold regression vs BFD ld: __ehdr_start

Roland McGrath
Mon Mar 31 21:27:00 GMT 2014

On Mon, Mar 31, 2014 at 2:18 PM, Cary Coutant <> wrote:
> I thought about transforming the symbol into an undef so that the
> error would come from relocate_section(), but you'd also have to
> modify issue_undefined_symbol_error() to check for hidden symbols.
> Given your assertion that an early error was reasonable, it didn't
> seem worth the churn.

I was unclear.  In the case of a static link with a weak undefined
reference to __ehdr_start, that must resolve to 0 normally and not
generate an error.
The case I was talking about was under -shared, when the treatment of
an undefined symbol would normally be to generate a dynamic reloc.
In that case, I think it's acceptable to generate an error instead of
going back and resizing the dynamic sections and everything you'd have
to do.

More information about the Binutils mailing list