trawick 2002/10/16 04:36:33
Modified: . CHANGES configure.in
build apr_common.m4
Log:
Don't use whitespace before preprocessor directives in the configure
logic. Such whitespace breaks with some older preprocessors; a
particularly nasty break occurs on Tru64 4.0f where APR_CHECK_DEFINE
will always suceed.
Submitted by: Joe Orton <[EMAIL PROTECTED]>
Reviewed by: Jeff Trawick
Revision Changes Path
1.343 +5 -0 apr/CHANGES
Index: CHANGES
===================================================================
RCS file: /home/cvs/apr/CHANGES,v
retrieving revision 1.342
retrieving revision 1.343
diff -u -r1.342 -r1.343
--- CHANGES 11 Oct 2002 20:41:22 -0000 1.342
+++ CHANGES 16 Oct 2002 11:36:32 -0000 1.343
@@ -1,5 +1,10 @@
Changes with APR 0.9.2
+ *) Don't use whitespace before preprocessor directives in the configure
+ logic. Such whitespace breaks with some older preprocessors; a
+ particularly nasty break occurs on Tru64 4.0f where APR_CHECK_DEFINE
+ will always suceed. [Joe Orton <[EMAIL PROTECTED]>]
+
*) Add APR_IPV4_ADDR_OK flag to apr_sockaddr_info_get() to allow
apps to avoid lookup of IPv6 address if IPv4 address is sufficient.
(New APR_IPV6_ADDR_OK flag is similar.) [Jeff Trawick]
1.486 +13 -13 apr/configure.in
Index: configure.in
===================================================================
RCS file: /home/cvs/apr/configure.in,v
retrieving revision 1.485
retrieving revision 1.486
diff -u -r1.485 -r1.486
--- configure.in 15 Oct 2002 20:47:11 -0000 1.485
+++ configure.in 16 Oct 2002 11:36:33 -0000 1.486
@@ -542,15 +542,15 @@
dnl # but keeps the pthread_rwlock_t structure hidden unless
dnl # special things are defined.
AC_TRY_COMPILE([#include <sys/types.h>
- #include <pthread.h>],
+#include <pthread.h>],
[pthread_rwlock_t rwlock=PTHREAD_RWLOCK_INITIALIZER;],
ac_cv_struct_pthread_rw=yes, ac_cv_struct_pthread_rw=no)
if test "$ac_cv_struct_pthread_rw" = "no"; then
AC_TRY_COMPILE([#define _XOPEN_SOURCE 500
- #define _BSD_SOURCE
- #define _SVID_SOURCE
- #include <sys/types.h>
- #include <pthread.h>],
+#define _BSD_SOURCE
+#define _SVID_SOURCE
+#include <sys/types.h>
+#include <pthread.h>],
[pthread_rwlock_t rwlock=PTHREAD_RWLOCK_INITIALIZER;],
ac_cv_struct_pthread_rw=yes, ac_cv_struct_pthread_rw=no)
if test "$ac_cv_struct_pthread_rw" = "yes"; then
@@ -1411,8 +1411,8 @@
dnl Linux and older versions of AIX have this problem.
APR_IFALLYES(header:pthread.h define:PTHREAD_PROCESS_SHARED
func:pthread_mutexattr_setpshared,
AC_TRY_RUN([
- #include <sys/types.h>
- #include <pthread.h>
+#include <sys/types.h>
+#include <pthread.h>
int main()
{
pthread_mutex_t mutex;
@@ -1434,8 +1434,8 @@
AC_CHECK_FUNCS(pthread_mutexattr_setrobust_np)
if test "$ac_cv_func_pthread_mutexattr_setrobust_np" = "no"; then
AC_TRY_COMPILE([#define _POSIX_THREAD_PRIO_INHERIT
- #include <sys/types.h>
- #include <pthread.h>],[
+#include <sys/types.h>
+#include <pthread.h>],[
int main()
{
pthread_mutex_t mutex;
@@ -1706,10 +1706,10 @@
case $host in
*linux*)
AC_EGREP_CPP(yes,[
- #include <linux/socket.h>
- #ifdef TCP_CORK
- yes
- #endif
+#include <linux/socket.h>
+#ifdef TCP_CORK
+yes
+#endif
],[
apr_tcp_nopush_flag="3"
have_corkable_tcp="1"
1.42 +12 -12 apr/build/apr_common.m4
Index: apr_common.m4
===================================================================
RCS file: /home/cvs/apr/build/apr_common.m4,v
retrieving revision 1.41
retrieving revision 1.42
diff -u -r1.41 -r1.42
--- apr_common.m4 22 Aug 2002 20:34:16 -0000 1.41
+++ apr_common.m4 16 Oct 2002 11:36:33 -0000 1.42
@@ -235,10 +235,10 @@
for curhdr in $2
do
AC_EGREP_CPP(YES_IS_DEFINED, [
- #include <$curhdr>
- #ifdef $1
- YES_IS_DEFINED
- #endif
+#include <$curhdr>
+#ifdef $1
+YES_IS_DEFINED
+#endif
], ac_cv_define_$1=yes)
done
])
@@ -254,10 +254,10 @@
AC_DEFUN(APR_CHECK_DEFINE,[
AC_CACHE_CHECK([for $1 in $2],ac_cv_define_$1,[
AC_EGREP_CPP(YES_IS_DEFINED, [
- #include <$2>
- #ifdef $1
- YES_IS_DEFINED
- #endif
+#include <$2>
+#ifdef $1
+YES_IS_DEFINED
+#endif
], ac_cv_define_$1=yes, ac_cv_define_$1=no)
])
if test "$ac_cv_define_$1" = "yes"; then
@@ -270,10 +270,10 @@
dnl
AC_DEFUN(APR_CHECK_APR_DEFINE,[
AC_EGREP_CPP(YES_IS_DEFINED, [
- #include "$2/include/apr.h"
- #if $1
- YES_IS_DEFINED
- #endif
+#include "$2/include/apr.h"
+#if $1
+YES_IS_DEFINED
+#endif
], ac_cv_define_$1=yes, ac_cv_define_$1=no)
])