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
On Tue, Jan 30, 2018 at 7:48 PM, Alan Modra <amodra@gmail.com> wrote:
> On Tue, Jan 30, 2018 at 03:38:39PM -0800, H.J. Lu wrote:
>> On Tue, Jan 30, 2018 at 6:14 AM, H.J. Lu <hjl.tools@gmail.com> wrote:
>> The code looks odd, but works correctly since bfd_elf_define_start_stop
>> is called after all input objects have been seen. All def_dynamic have
>> been turned into ref_dynamic.
>
> Really? Where does that happen for __start/__stop symbols?
>
I was wrong on that one. But should we define __start/__stop symbols
when there are only definitions, def_dynamic, in shared object? If yes,
do we have a testcase for this behavior?
I think we should check ref_dynamic, not def_dynamic, for __start/__stiop
symbols.
--
H.J.