static binary, dlopen, and ifunc

H.J. Lu hjl.tools@gmail.com
Fri Nov 13 15:10:54 GMT 2020


On Fri, Nov 13, 2020 at 7:01 AM Samuel Thibault <samuel.thibault@gnu.org> wrote:
>
> H.J. Lu via Libc-alpha, le ven. 13 nov. 2020 06:29:28 -0800, a ecrit:
> > On Fri, Nov 13, 2020 at 6:27 AM Samuel Thibault <samuel.thibault@gnu.org> wrote:
> > > We can as well avoid the problem entirely by introducing an actual
> > > __mig_stpncpy function that will not pose ifunc issues. But it really
> > > seems to me there can be something fishy here, not really specific to
> > > the Hurd.
> >
> > Functions used by init_cpu_features must not use IFUNC.
>
> ? That is unrelated.
>
> Here the problem is that when stpncpy_ifunc_selector gets called to
> relocate the stpncpy reference, _rtld_global_ro was not relocated yet,
> and thus 0.
>

ld.so.1 should be relocated first.  You need to find out why it isn't the
case on Hurd.

-- 
H.J.


More information about the Libc-alpha mailing list