Skip Menu |
 

Subject: need more thorough testing for conditional pthread support
When the pthread support may or may not be linked in, either because
we're using weak symbols or because the system C library has stubs for
all the functions we use, we need to do a better job of testing for
*real* pthread support (i.e., not non-functional stubs).

Recommended approach: Test all the symbols we use (and maybe some others
we know of) for null addresses. Try using pthread_once and see if it
works. Only if all tests pass should we assume thread support is available.
From: raeburn@mit.edu
Subject: CVS Commit
* Makefile.in (test_getpw): Depend on, and link against, the support library.


To generate a diff of this commit:



cvs diff -r1.1 -r1.2 krb5/src/tests/misc/ChangeLog
krb5/src/tests/misc/Makefile.in
From: raeburn@mit.edu
Subject: CVS Commit
Add run-time determination of whether thread support is available in the
support library. Check lots of weak references, and call pthread_once a couple
of times, to distinguish a broken stub from the real thing.

* threads.c [HAVE_PRAGMA_WEAK_REF]: Declare pthread_{g,s}etspecific,
pthread_key_{create,delete}, pthread_{create,join} as weak references.
(krb5int_pthread_loaded, loaded_test_aux) [HAVE_PRAGMA_WEAK_REF]: New
functions.
(flag_pthread_loaded, loaded_test_once) [HAVE_PRAGMA_WEAK_REF]: New variables.
* libkrb5support.exports: Add krb5int_pthread_loaded.


To generate a diff of this commit:



cvs diff -r1.32 -r1.33 krb5/src/util/support/ChangeLog
cvs diff -r1.6 -r1.7 krb5/src/util/support/libkrb5support.exports
cvs diff -r1.19 -r1.20 krb5/src/util/support/threads.c
From: raeburn@mit.edu
Subject: CVS Commit
* k5-thread.h (krb5int_pthread_loaded) [HAVE_PRAGMA_WEAK_REF]: Declare.
(K5_PTHREADS_LOADED) [HAVE_PRAGMA_WEAK_REF]: Use it.


To generate a diff of this commit:



cvs diff -r1.502 -r1.503 krb5/src/include/ChangeLog
cvs diff -r1.28 -r1.29 krb5/src/include/k5-thread.h
KAMADA Ken'ichi confirms this fixes an initialization problem on NetBSD-current (3.99.5),
which has stubs for some pthread_* routines, which stubs weren't in NetBSD 2.0 that I'm
testing with.

Asked for confirmation from Albert Chin as to whether it fixes the same problem on HP-UX
11.
From: tlyu@mit.edu
Subject: CVS Commit
pullup from trunk


To generate a diff of this commit:



cvs diff -r1.471.2.13 -r1.471.2.14 krb5/src/include/ChangeLog
cvs diff -r1.22.2.2 -r1.22.2.3 krb5/src/include/k5-thread.h
cvs diff -r1.19.2.4 -r1.19.2.5 krb5/src/util/support/ChangeLog
cvs diff -r1.3 -r1.3.2.1
krb5/src/util/support/libkrb5support.exports
cvs diff -r1.11.4.3 -r1.11.4.4 krb5/src/util/support/threads.c