svn commit: trunk/uClibc/libc/misc/pthread
Joakim Tjernlund
joakim.tjernlund at transmode.se
Wed Dec 7 17:33:02 UTC 2005
>
> On Tue, 6 Dec 2005, Steven J. Hill wrote:
>
> > Mike Frysinger wrote:
> > >
> > > are these actually needed or are you just adding them for
> fun ? in
> > > other words, will libc itself utilize these functions ?
> > >
> > libc will not link without these because there are source
> units from
> > NPTL that actually get linked into libc.
> >
> > -Steve
> >
>
> Current svn (linuxthreads.old) does not build
> xorg-x11/libxml2 due to missing pthread_X where X could be
> (checked libxml2/threads.c) {once,key_create,equal,self}
> cond_{signal,wait,init} {g,s}etspecific
> mutex_{init,destroy,lock,unlock}
Seems like a few apps/libs expect to have a few pthread funs in libc. Not sure
if this is misuse or if its intended.
Adding them back again will won't be so easy, the only think I can think of
it to export some internal version from pthreads.
Something like this might work(assuming pthreads exports __pthread_mutex_init):
extern int weak __pthread_mutex_init();
int weak pthread_mutex_init() {
if (__pthread_mutex_init == NULL)
return 0;
__pthread_mutex_init();
}
Can't say I like it :(
Pehaps sjhill has figured out how this works in glibc?
Jocke
More information about the uClibc
mailing list