This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: Define __start/__stop symbols when there is only a dynamic def
- From: Nick Clifton <nickc at redhat dot com>
- To: Alan Modra <amodra at gmail dot com>, binutils at sourceware dot org
- Cc: Michael Matz <matz at suse dot de>
- Date: Fri, 26 Jan 2018 13:19:27 +0000
- Subject: Re: Define __start/__stop symbols when there is only a dynamic def
- Authentication-results: sourceware.org; auth=none
- References: <20180126052959.GB20622@bubble.grove.modra.org>
Hi Alan,
> This patch fixes a case where a user had a C-representable named
> section in both the executable and shared libraries, and of course
> wanted the size of the local section in the executable, not the
> dynamic section. It does mean that __start and __stop symbols don't
> behave exactly like PROVIDEd symbols, but I think that's a reasonable
> difference particularly since this is the way they used to behave.
Is this distinction now documented ? Ie can future users still be
confused by this behaviour ?
> Nick, I'd like to apply this to the branch. I think it should be
> quite safe.
>
> * elflink.c (bfd_elf_define_start_stop): Override symbols when
> they are defined dynamically.
Fair enough - please apply - although I do also like H.J.'s request
for a testcase...
Cheers
Nick