[Patch,AVR]: Fix PR13697: Wrong symbols with --gc-sections

Hans-Peter Nilsson hp@bitrange.com
Tue May 29 08:05:00 GMT 2012


On Tue, 29 May 2012, Georg-Johann Lay wrote:
> Hans-Peter Nilsson schrieb:
> > Try without --gc-sections and  gc:able .data.
>
> er... sorry, would you outline this? I searched for "gc:able"
> documentation but with no avail.

JFTR, I meant "add some unused (garbage-collectable) .data to
test if it's added twice when you don't use --gc-sections", but
Alan already pointed out that it isn't.

> > Though, adding a symbol should do it, at least for a corrected
> > linker.
>
> You mean adding a symbol to .data by letting the compiler add a symbol
> in .data for each module?

No, I mean add a symbol in the linker script, like
${RELOCATING+ ___data_start_reserved = .) ; }
(i.e. another one like there is, but without the PROVIDE decoration).

brgds, H-P



More information about the Binutils mailing list