Why weak referencing pthread_equal() in k5-thread.h?
raeburn at MIT.EDU
Tue May 31 23:13:24 EDT 2005
>> If you're using netbsd-current and they've added a stub for
>> pthread_once to libc, I think that would explain the problem, and I'd
>> need to know the name of a function in libpthread that they didn't add
>> a stub for. I could use pthread_equal, or pthread_join, or ....
> On NetBSD 2.0, there is no pthread_*() stubs in libc. If we want to
> write a library which can be linked without libpthread, we need to
> include <threadlib.h> and use thr_once(), mutex_lock(), etc.
> (or use some magic like weak reference by the library itself).
> Recent NetBSD-current (and not-yet-released 3.0) have pthread stubs
> and don't have <threadlib.h> any more.
Hi. Could you please try out the attached patch and let me know if it
fixes the problem? (The patch is relative to the 1.4 branch, I can
send a patch based on the trunk if you prefer.)
It's probably overkill -- if a pthread_mutex_lock stub exists and does
nothing, it's probably fine to use it, but this patch will avoid it --
but I'd rather get something right now and optimized later...
-------------- next part --------------
More information about the krbdev