[EMAIL PROTECTED] writes:
> Implement read write locks. This commit will support POSIX pthread
> rw locks on Unix platforms. This is based on earlier patches that I
> posted to apr-dev, but did not receive feedback from others on.
> Hence, I'm committing.
...
> Index: configure.in
> ===================================================================
> RCS file: /home/cvs/apr/configure.in,v
> retrieving revision 1.309
> retrieving revision 1.310
> diff -u -r1.309 -r1.310
> --- configure.in 2001/05/18 02:35:51 1.309
> +++ configure.in 2001/05/31 03:29:51 1.310
> @@ -280,7 +280,7 @@
> if test "$pthreadh" = "1"; then
> APR_CHECK_PTHREAD_GETSPECIFIC_TWO_ARGS
> APR_CHECK_PTHREAD_ATTR_GETDETACHSTATE_ONE_ARG
> - AC_CHECK_FUNCS(pthread_key_delete)
> + AC_CHECK_FUNCS(pthread_key_delete pthread_rwlock_init)
> fi
> fi
With RedHat 6.0, it seems that __USE_UNIX98 must be turned on in order
for the pthread_rwlock_t to be defined. I think more autoconf is
needed here. (If nobody else gets to it, I'll handle but no timeframe
promised :) I'm behind with too many promises already.)
> Index: locks.h
> ===================================================================
> RCS file: /home/cvs/apr/include/arch/unix/locks.h,v
> retrieving revision 1.26
> retrieving revision 1.27
> diff -u -r1.26 -r1.27
> --- locks.h 2001/02/25 20:39:32 1.26
> +++ locks.h 2001/05/31 03:29:54 1.27
> @@ -130,9 +130,12 @@
> #if APR_USE_PTHREAD_SERIALIZE
> pthread_mutex_t *intraproc;
> #endif
> +#ifdef HAVE_PTHREAD_RWLOCK_INIT
> + pthread_rwlock_t rwlock;
This is what fails to compile with RH 6.0. We found
pthread_rwlock_init() but didn't test for pthread_rwlock_t
without/with __USE_UNIX98.
--
Jeff Trawick | [EMAIL PROTECTED] | PGP public key at web site:
http://www.geocities.com/SiliconValley/Park/9289/
Born in Roswell... married an alien...