check if define __APPLE_USE_RFC_2292 helps to enable IPV6_*

This commit is contained in:
Gerhard Rieger 2012-07-22 21:30:26 +02:00
parent 53d969ffe3
commit 178442ab21
3 changed files with 31 additions and 3 deletions

View file

@ -119,6 +119,10 @@ porting:
IPV6_PKTINFO IPV6_RTHDR IPV6_DSTOPTS IPV6_HOPOPTS IPV6_HOPLIMIT
Thanks to Jerry Jacobs for reporting this problem (Mac OS X Lion 10.7)
check if define __APPLE_USE_RFC_2292 helps to enable IPV6_* (MacOSX
Lion 7.1); thanks to Jerry Jacobs to reporting this problem and
proposing a solution
####################### V 2.0.0-b7:
security:

View file

@ -64,7 +64,6 @@ AC_CHECK_HEADERS(netinet/ip.h, [], [], [AC_INCLUDES_DEFAULT
#include <netinet/in_systm.h>
#endif]) # Solaris prerequisites for netinet/ip.h
AC_CHECK_HEADERS(netinet/tcp.h)
AC_CHECK_HEADERS(netinet6/in6.h) # found on OpenBSD, used for IPV6_*
AC_CHECK_HEADER(net/if.h, [], [], [AC_INCLUDES_DEFAULT
#if HAVE_SYS_SOCKET_H
#include <sys/socket.h>
@ -231,6 +230,27 @@ if test "$WITH_IP6"; then
#ifdef HAVE_NETINET_IN_H
# include <netinet/in.h>
#endif])
AC_CHECK_HEADERS(netinet6/in6.h) # found on OpenBSD and Lion, used for IPV6_*
AC_MSG_CHECKING(if __APPLE_USE_RFC_2292 is helpful)
AC_CACHE_VAL(ac_cv_apple_use_rfc_2292,
[AC_TRY_COMPILE(,[#ifndef IPV6_HOPOPTS
murks;
#endif],
[ac_cv_apple_use_rfc_2292=no],
[AC_TRY_COMPILE([#define __APPLE_USE_RFC_2292],
[#ifndef IPV6_HOPOPTS
murks;
#endif],
[ac_cv_apple_use_rfc_2292=yes],
[ac_cv_apple_use_rfc_2292=no]
)]
)])
if test "$ac_cv_apple_use_rfc_2292" = yes; then
AC_DEFINE(__APPLE_USE_RFC_2292)
fi
AC_MSG_RESULT($ac_cv_apple_use_rfc_2292)
fi
AC_MSG_CHECKING(whether to include raw IP support)

View file

@ -3424,7 +3424,7 @@ wait
fi ;; # NUMCOND
esac
N=$((N+1))
set +vx
#set +vx
NAME=EXECIGNOREEOF
@ -7729,6 +7729,7 @@ pid3=$!
waittcp4port $p2 1
$CMD 2>"${te}2" &
pid2=$!
usleep $MICROS
waittcp4port $p1 1
echo "$da1a" |$CMD1 2>>"${te}1a"
echo "$da1b" |$CMD1 2>>"${te}1b"
@ -8968,7 +8969,7 @@ fi ;; # NUMCOND
esac
PORT=$((PORT+1))
N=$((N+1))
set +vx
#set +vx
# there was a bug with udp-recvfrom and fork: terminating sub processes became
# zombies because the master process caught SIGCHLD but did not wait()
@ -9348,6 +9349,9 @@ elif [ "$ROOT" = root -a $(id -u) -ne 0 -a "$withroot" -eq 0 ]; then
elif [ "$PF" = "IP6" ] && ( ! feat=$(testaddrs ip6) || ! runsip6 >/dev/null ); then
$PRINTF "test $F_n $TEST... ${YELLOW}IP6 not available${NORMAL}\n" $N
numCANT=$((numCANT+1))
elif ! testoptions $SCM_RECV >/dev/null; then
$PRINTF "test $F_n $TEST... ${YELLOW}option $SCM_RECV not available${NORMAL}\n" $N
numCANT=$((numCANT+1))
else
tf="$td/test$N.stdout"
te="$td/test$N.stderr"