You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by je...@apache.org on 2001/07/01 07:49:44 UTC
cvs commit: apr/include/arch/unix locks.h
jerenkrantz 01/06/30 22:49:44
Modified: . configure.in
build apr_common.m4
include apr.h.in
include/arch/unix locks.h
Log:
Cleanup the detection of pthread_rwlock_t. Let autoconf play with
the variables and set the APR_HAS_RWLOCK_SERIALIZE in apr.h rather
than in arch/unix/locks.h to be consistent with the rest of the
lock types.
Also, add struct to the types "known" by APR_IFALLYES.
Revision Changes Path
1.323 +2 -0 apr/configure.in
Index: configure.in
===================================================================
RCS file: /home/cvs/apr/configure.in,v
retrieving revision 1.322
retrieving revision 1.323
diff -u -r1.322 -r1.323
--- configure.in 2001/07/01 03:38:56 1.322
+++ configure.in 2001/07/01 05:49:43 1.323
@@ -969,6 +969,7 @@
APR_IFALLYES(func:flock define:LOCK_EX, hasflockser="1", hasflockser="0")
APR_IFALLYES(header:fcntl.h define:F_SETLK, hasfcntlser="1", hasfcntlser="0")
APR_IFALLYES(header:pthread.h define:PTHREAD_PROCESS_SHARED func:pthread_mutexattr_setpshared, hasprocpthreadser="1", hasprocpthreadser="0")
+APR_IFALLYES(struct:pthread_rw, hasrwlockser="1", hasrwlockser="0")
# See which lock mechanism we'll select by default on this system.
# The last APR_DECIDE to execute sets the default
@@ -1025,6 +1026,7 @@
AC_SUBST(hassysvser)
AC_SUBST(hasfcntlser)
AC_SUBST(hasprocpthreadser)
+AC_SUBST(hasrwlockser)
AC_SUBST(flockser)
AC_SUBST(sysvser)
AC_SUBST(fcntlser)
1.19 +1 -0 apr/build/apr_common.m4
Index: apr_common.m4
===================================================================
RCS file: /home/cvs/apr/build/apr_common.m4,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -r1.18 -r1.19
--- apr_common.m4 2001/05/11 03:59:03 1.18
+++ apr_common.m4 2001/07/01 05:49:44 1.19
@@ -239,6 +239,7 @@
ac_var="ac_cv_file_$ac_item"
;;
func ) ac_var="ac_cv_func_$ac_item" ;;
+ struct ) ac_var="ac_cv_struct_$ac_item" ;;
define ) ac_var="ac_cv_define_$ac_item" ;;
custom ) ac_var="$ac_item" ;;
esac
1.87 +1 -0 apr/include/apr.h.in
Index: apr.h.in
===================================================================
RCS file: /home/cvs/apr/include/apr.h.in,v
retrieving revision 1.86
retrieving revision 1.87
diff -u -r1.86 -r1.87
--- apr.h.in 2001/06/27 19:40:44 1.86
+++ apr.h.in 2001/07/01 05:49:44 1.87
@@ -68,6 +68,7 @@
#define APR_HAS_SYSVSEM_SERIALIZE @hassysvser@
#define APR_HAS_FCNTL_SERIALIZE @hasfcntlser@
#define APR_HAS_PROC_PTHREAD_SERIALIZE @hasprocpthreadser@
+#define APR_HAS_RWLOCK_SERIALIZE @hasrwlockser@
#define APR_HAS_LOCK_CREATE_NP @lockcreatenp@
1.35 +1 -5 apr/include/arch/unix/locks.h
Index: locks.h
===================================================================
RCS file: /home/cvs/apr/include/arch/unix/locks.h,v
retrieving revision 1.34
retrieving revision 1.35
diff -u -r1.34 -r1.35
--- locks.h 2001/06/29 17:53:27 1.34
+++ locks.h 2001/07/01 05:49:44 1.35
@@ -127,12 +127,8 @@
#if APR_HAS_PROC_PTHREAD_SERIALIZE
extern const apr_unix_lock_methods_t apr_unix_proc_pthread_methods;
#endif
-
-#if defined(HAVE_PTHREAD_RWLOCK_INIT)
-#define APR_HAS_RWLOCK_SERIALIZE 1
+#if APR_HAS_RWLOCK_SERIALIZE
extern const apr_unix_lock_methods_t apr_unix_rwlock_methods;
-#else
-#define APR_HAS_RWLOCK_SERIALIZE 0
#endif
#if !APR_HAVE_UNION_SEMUN && defined(APR_HAS_SYSVSEM_SERIALIZE)