Re: Weak symbols not being removed

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Thanks for the quick response and the suggestion.

Apparently, --gc-sections was commented out in my Makefile.
However, after enabling it, some weak symbols still aren't being removed.
I use "ld -r" to construct a combined object file in every directory.
Then, in the end I link all of those object files together.
Unfortunately, "ld -r" is removing sections created by -fdata-sections
and -ffunction-sections.
After retrying this for x86, it seems to work correctly, making me
believe the problem is with the avr linker.
I'll continue this on the binutils list, since this makes more sense there.

Thanks.




On Wed, Jul 31, 2013 at 4:13 AM, Andrew Haley <aph@xxxxxxxxxx> wrote:
> On 07/31/2013 06:25 AM, Asm Twiddler wrote:
>
>> I have recently noticed that my builds haven't been removing weak
>> symbols that are overridden by strong symbols.
>> More specifically, the symbol points to the strong object/function but
>> the weak symbol's data remains in the executable.
>
> Where is the strong object?  In a shared library?
>
> BTW, this is really a question for the binutils list.  GCC doesn't
> process weak symbols.  You'll get more knowledgeable people there.
>
> Andrew.
>




[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux