summaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
authorjorton <jorton@13f79535-47bb-0310-9956-ffa450edef68>2004-03-13 00:32:43 +0000
committerjorton <jorton@13f79535-47bb-0310-9956-ffa450edef68>2004-03-13 00:32:43 +0000
commit4eee65febaa4e06c28bcd79efd1df21a07f516db (patch)
tree61549d32da02f7ea405ef34384660bf044b9e051 /configure.in
parentd723beaef7a2c733cf7a4d0e2efeb121881c3868 (diff)
downloadlibapr-4eee65febaa4e06c28bcd79efd1df21a07f516db.tar.gz
Stop messing around with _FOO_SOURCE things mid-configure: enable
_GNU_SOURCE for glibc-based systems in the platform hints. (and avoid jumping through hoops to define _{XOPEN,BSD,SVID}_SOURCE which are all implied by _GNU_SOURCE anyway) * build/apr_hints.m4: Define _GNU_SOURCE in CPPFLAGS for GNU/HURD and GNU/Linux. * build/apr_common.m4: Remove tricks to get glibc to expose crypt_r. * configure.in: Remove tricks to get glibc to expose pthread_rwlock_t. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@64972 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in18
1 files changed, 3 insertions, 15 deletions
diff --git a/configure.in b/configure.in
index 322843b40..4645e5339 100644
--- a/configure.in
+++ b/configure.in
@@ -526,25 +526,13 @@ else
if test "$ac_cv_func_pthread_rwlock_init" = "yes"; then
dnl ----------------------------- Checking for pthread_rwlock_t
- dnl Linux is silly as it has pthread_rwlock_init defined
- dnl but keeps the pthread_rwlock_t structure hidden unless
- dnl special things are defined.
AC_CACHE_CHECK([for pthread_rwlock_t], [apr_cv_type_rwlock_t],
AC_TRY_COMPILE([#include <sys/types.h>
#include <pthread.h>], [pthread_rwlock_t rwlock=PTHREAD_RWLOCK_INITIALIZER;],
- [apr_cv_type_rwlock_t=yes],
- [AC_TRY_COMPILE([#define _XOPEN_SOURCE 500
-#define _BSD_SOURCE
-#define _SVID_SOURCE
-#include <sys/types.h>
-#include <pthread.h>], [pthread_rwlock_t rwlock=PTHREAD_RWLOCK_INITIALIZER;],
- [apr_cv_type_rwlock_t=yes-with-XOPEN_SOURCE], [apr_cv_type_rwlock_t=no])],
+ [apr_cv_type_rwlock_t=yes], [apr_cv_type_rwlock_t=no],
[apr_cv_type_rwlock_t=no]))
- case $apr_cv_type_rwlock_t in
- yes*) AC_DEFINE(HAVE_PTHREAD_RWLOCKS, 1, [Define if pthread rwlocks are available]) ;;
- esac
- if test "$apr_cv_type_rwlock_t" = "yes-with-XOPEN_SOURCE"; then
- APR_ADDTO(CPPFLAGS, [-D_XOPEN_SOURCE=500 -D_BSD_SOURCE -D_SVID_SOURCE])
+ if test "$apr_cv_type_rwlock_t" = "yes"; then
+ AC_DEFINE(HAVE_PTHREAD_RWLOCKS, 1, [Define if pthread rwlocks are available])
fi
fi
fi