mirror of https://github.com/getdnsapi/getdns.git
Improve config check for TFO
This commit is contained in:
parent
736d9f20bf
commit
438870785a
27
configure.ac
27
configure.ac
|
@ -160,30 +160,21 @@ case "$enable_debug_sec" in
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
# AC_ARG_ENABLE(tcp-fastopen, AC_HELP_STRING([--enable-tcp-fastopen], [Enable TCP Fast Open]))
|
|
||||||
# case "$enable_tcp_fastopen" in
|
|
||||||
# yes)
|
|
||||||
# AC_CHECK_DECL([CONNECT_RESUME_ON_READ_WRITE], [], [AC_MSG_ERROR([TCP Fast Open is not available: please rerun without --enable-tcp-fastopen])], [AC_INCLUDES_DEFAULT
|
|
||||||
# #include <sys/socket.h>
|
|
||||||
# ])
|
|
||||||
# AC_DEFINE_UNQUOTED([USE_TCP_FASTOPEN], [1], [Define this to enable TCP fast open.])
|
|
||||||
# ;;
|
|
||||||
# no|*)
|
|
||||||
# ;;
|
|
||||||
# esac
|
|
||||||
|
|
||||||
AC_ARG_ENABLE(tcp-fastopen, AC_HELP_STRING([--disable-tcp-fastopen], Disable TCP Fast Open (default=enabled if available)),
|
AC_ARG_ENABLE(tcp-fastopen, AC_HELP_STRING([--disable-tcp-fastopen], Disable TCP Fast Open (default=enabled if available)),
|
||||||
enable_tcp_fastopen="$enableval", enable_tcp_fastopen=yes)
|
enable_tcp_fastopen="$enableval", enable_tcp_fastopen=yes)
|
||||||
if test "x$enable_tcp_fastopen" = xno; then
|
if test "x$enable_tcp_fastopen" = xno; then
|
||||||
AC_MSG_WARN([TCP Fast Open is disabled])
|
AC_MSG_WARN([TCP Fast Open is disabled])
|
||||||
else
|
else
|
||||||
my_have_linux_tfo=1
|
case `uname` in
|
||||||
AC_CHECK_DECL([MSG_FASTOPEN], [AC_DEFINE_UNQUOTED([USE_TCP_FASTOPEN], [1], [Define this to enable TCP fast open.])],
|
Linux) AC_CHECK_DECL([MSG_FASTOPEN], [AC_DEFINE_UNQUOTED([USE_TCP_FASTOPEN], [1], [Define this to enable TCP fast open.])],
|
||||||
my_have_linux_tfo=0, [#include <sys/socket.h>])
|
|
||||||
if test my_have_linux_tfo=0; then
|
|
||||||
AC_CHECK_DECL([CONNECT_RESUME_ON_READ_WRITE], [AC_DEFINE_UNQUOTED([USE_OSX_TCP_FASTOPEN], [1], [Define this to enable TCP fast open.])],
|
|
||||||
[AC_MSG_WARN([TCP Fast Open is not available, continuing without])], [#include <sys/socket.h>])
|
[AC_MSG_WARN([TCP Fast Open is not available, continuing without])], [#include <sys/socket.h>])
|
||||||
fi
|
;;
|
||||||
|
Darwin) AC_CHECK_DECL([CONNECT_RESUME_ON_READ_WRITE], [AC_DEFINE_UNQUOTED([USE_OSX_TCP_FASTOPEN], [1], [Define this to enable TCP fast open.])],
|
||||||
|
[AC_MSG_WARN([TCP Fast Open is not available, continuing without])], [#include <sys/socket.h>])
|
||||||
|
;;
|
||||||
|
*) AC_MSG_WARN([TCP Fast Open is not available, continuing without])
|
||||||
|
;;
|
||||||
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
||||||
AC_ARG_ENABLE(native-stub-dnssec, AC_HELP_STRING([--disable-native-stub-dnssec], [Disable native stub DNSSEC support]))
|
AC_ARG_ENABLE(native-stub-dnssec, AC_HELP_STRING([--disable-native-stub-dnssec], [Disable native stub DNSSEC support]))
|
||||||
|
|
Loading…
Reference in New Issue