[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCHv2,HURD] Add fork hooks for pthread_atfork
From: |
Samuel Thibault |
Subject: |
Re: [PATCHv2,HURD] Add fork hooks for pthread_atfork |
Date: |
Tue, 4 Mar 2014 02:40:12 +0100 |
User-agent: |
Mutt/1.5.21+34 (58baf7c9f32f) (2010-12-30) |
Roland McGrath, le Mon 03 Mar 2014 15:36:52 -0800, a écrit :
> > Roland McGrath, le Fri 20 Dec 2013 13:05:42 -0800, a ,Aicrit :
> > > The linker is supposed to define those symbols automagically.
> > > Did it break?
> >
> > We have been having
> >
> > $,1r|
> > checking for sufficient default -shared layout... no
>
> What does this have to do with anything?
It is what makes the Makefile choose between using the empty
shlib-lds/shlib-lds-flags or using the explicit shlib.lds file.
> Are you saying that the linker does not define __start_* and __stop_*
> symbols automagically when it's given a custom linker script?
It seems libc's __start_* and __stop_* symbols get defined automagically
indeed. This however doesn't happen for libpthread apparently:
/usr/src/eglibc-2.18/build-tree/hurd-i386-libc/libpthread/libpthread_pic.a(pt-initialize.os):
In function `__pthread_init':
/usr/src/eglibc-2.18/libpthread/./pthread/pt-initialize.c:77: undefined
reference to `__stop___pthread_init'
/usr/bin/ld.bfd.real:
/usr/src/eglibc-2.18/build-tree/hurd-i386-libc/libpthread/libpthread_pic.a(pt-initialize.os):
relocation R_386_GOTOFF against undefined hidden symbol
`__stop___pthread_init' can not be used when making a shared object
Now I'm wondering why for instance __start/stop___libc_atexit are
specified. This comes from Ulrich's “Place __libc_subfreeres,
__libc_atexit, and __libc_thread_subfreeres sections after .jcr
section.”. I don't know what this is really useful for.
Samuel