mirror of
https://github.com/moparisthebest/curl
synced 2024-12-21 15:48:49 -05:00
Checking for function getnameinfo and its arguments is finally
done in one single function CURL_CHECK_FUNC_GETNAMEINFO which will only define HAVE_GETNAMEINFO if the function has been found AND the type of its arguments has been properly been detected
This commit is contained in:
parent
bc4208201c
commit
e4388643f1
88
acinclude.m4
88
acinclude.m4
@ -225,25 +225,91 @@ AC_DEFUN([CURL_CHECK_TYPE_SOCKLEN_T], [
|
|||||||
])
|
])
|
||||||
|
|
||||||
|
|
||||||
dnl CURL_FUNC_GETNAMEINFO_ARGTYPES
|
dnl CURL_CHECK_FUNC_GETNAMEINFO
|
||||||
dnl -------------------------------------------------
|
dnl -------------------------------------------------
|
||||||
dnl Check the type to be passed to five of the arguments
|
dnl Test if the getnameinfo function is available,
|
||||||
dnl of getnameinfo function, and define those types in
|
dnl and check the types of five of its arguments.
|
||||||
|
dnl If the function succeeds HAVE_GETNAMEINFO will be
|
||||||
|
dnl defined, defining the types of the arguments in
|
||||||
dnl GETNAMEINFO_TYPE_ARG1, GETNAMEINFO_TYPE_ARG2,
|
dnl GETNAMEINFO_TYPE_ARG1, GETNAMEINFO_TYPE_ARG2,
|
||||||
dnl GETNAMEINFO_TYPE_ARG46 and GETNAMEINFO_TYPE_ARG7.
|
dnl GETNAMEINFO_TYPE_ARG46 and GETNAMEINFO_TYPE_ARG7.
|
||||||
dnl This function is experimental and its results shall
|
dnl This function is experimental and its results shall
|
||||||
dnl not be trusted while this notice is in place ------
|
dnl not be trusted while this notice is in place ------
|
||||||
|
|
||||||
AC_DEFUN([CURL_FUNC_GETNAMEINFO_ARGTYPES], [
|
AC_DEFUN([CURL_CHECK_FUNC_GETNAMEINFO], [
|
||||||
AC_REQUIRE([CURL_CHECK_HEADER_WS2TCPIP])dnl
|
AC_REQUIRE([CURL_CHECK_HEADER_WS2TCPIP])dnl
|
||||||
AC_REQUIRE([CURL_CHECK_TYPE_SOCKLEN_T])dnl
|
AC_REQUIRE([CURL_CHECK_TYPE_SOCKLEN_T])dnl
|
||||||
AC_CHECK_HEADERS(sys/types.h sys/socket.h netdb.h)
|
AC_CHECK_HEADERS(sys/types.h sys/socket.h netdb.h)
|
||||||
|
#
|
||||||
|
AC_MSG_CHECKING([for getnameinfo])
|
||||||
|
AC_LINK_IFELSE([
|
||||||
|
AC_LANG_FUNC_LINK_TRY([getnameinfo])
|
||||||
|
],[
|
||||||
|
AC_MSG_RESULT([yes])
|
||||||
|
curl_cv_getnameinfo="yes"
|
||||||
|
],[
|
||||||
|
AC_MSG_RESULT([no])
|
||||||
|
curl_cv_getnameinfo="no"
|
||||||
|
])
|
||||||
|
#
|
||||||
|
if test "$curl_cv_getnameinfo" != "yes"; then
|
||||||
|
AC_MSG_CHECKING([deeper for getnameinfo])
|
||||||
|
AC_TRY_LINK([
|
||||||
|
],[
|
||||||
|
getnameinfo();
|
||||||
|
],[
|
||||||
|
AC_MSG_RESULT([yes])
|
||||||
|
curl_cv_getnameinfo="yes"
|
||||||
|
],[
|
||||||
|
AC_MSG_RESULT([but still no])
|
||||||
|
curl_cv_getnameinfo="no"
|
||||||
|
])
|
||||||
|
fi
|
||||||
|
#
|
||||||
|
if test "$curl_cv_getnameinfo" != "yes"; then
|
||||||
|
AC_MSG_CHECKING([deeper and deeper for getnameinfo])
|
||||||
|
AC_TRY_LINK([
|
||||||
|
#undef inline
|
||||||
|
#ifdef HAVE_WINDOWS_H
|
||||||
|
#ifndef WIN32_LEAN_AND_MEAN
|
||||||
|
#define WIN32_LEAN_AND_MEAN
|
||||||
|
#endif
|
||||||
|
#include <windows.h>
|
||||||
|
#ifdef HAVE_WINSOCK2_H
|
||||||
|
#include <winsock2.h>
|
||||||
|
#ifdef HAVE_WS2TCPIP_H
|
||||||
|
#include <ws2tcpip.h>
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
#else
|
||||||
|
#ifdef HAVE_SYS_TYPES_H
|
||||||
|
#include <sys/types.h>
|
||||||
|
#endif
|
||||||
|
#ifdef HAVE_SYS_SOCKET_H
|
||||||
|
#include <sys/socket.h>
|
||||||
|
#endif
|
||||||
|
#ifdef HAVE_NETDB_H
|
||||||
|
#include <netdb.h>
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
],[
|
||||||
|
getnameinfo(0, 0, 0, 0, 0, 0, 0);
|
||||||
|
],[
|
||||||
|
AC_MSG_RESULT([yes])
|
||||||
|
curl_cv_getnameinfo="yes"
|
||||||
|
],[
|
||||||
|
AC_MSG_RESULT([but still no])
|
||||||
|
curl_cv_getnameinfo="no"
|
||||||
|
])
|
||||||
|
fi
|
||||||
|
#
|
||||||
|
if test "$curl_cv_getnameinfo" = "yes"; then
|
||||||
AC_CACHE_CHECK([types of arguments for getnameinfo],
|
AC_CACHE_CHECK([types of arguments for getnameinfo],
|
||||||
[curl_cv_func_getnameinfo_args], [
|
[curl_cv_func_getnameinfo_args], [
|
||||||
curl_cv_func_getnameinfo_args="unknown"
|
curl_cv_func_getnameinfo_args="unknown"
|
||||||
for gni_arg1 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
|
for gni_arg1 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
|
||||||
for gni_arg2 in 'socklen_t' 'size_t' 'int'; do
|
for gni_arg2 in 'socklen_t' 'size_t' 'int'; do
|
||||||
for gni_arg46 in 'size_t' 'int' 'socklen_t' 'unsigned int'; do
|
for gni_arg46 in 'size_t' 'int' 'socklen_t' 'unsigned int' 'DWORD'; do
|
||||||
for gni_arg7 in 'int' 'unsigned int'; do
|
for gni_arg7 in 'int' 'unsigned int'; do
|
||||||
AC_COMPILE_IFELSE([
|
AC_COMPILE_IFELSE([
|
||||||
AC_LANG_PROGRAM([
|
AC_LANG_PROGRAM([
|
||||||
@ -295,12 +361,10 @@ AC_DEFUN([CURL_FUNC_GETNAMEINFO_ARGTYPES], [
|
|||||||
done
|
done
|
||||||
done
|
done
|
||||||
done
|
done
|
||||||
])
|
]) # AC_CACHE_CHECK
|
||||||
if test "$curl_cv_func_getnameinfo_args" = "unknown"; then
|
if test "$curl_cv_func_getnameinfo_args" = "unknown"; then
|
||||||
AC_MSG_WARN([Cannot find proper types to use for getnameinfo args])
|
AC_MSG_WARN([Cannot find proper types to use for getnameinfo args])
|
||||||
AC_MSG_WARN([Undefining HAVE_GETNAMEINFO])
|
AC_MSG_WARN([HAVE_GETNAMEINFO will not be defined])
|
||||||
#undef HAVE_GETNAMEINFO
|
|
||||||
ac_cv_func_getnameinfo="no"
|
|
||||||
else
|
else
|
||||||
gni_prev_IFS=$IFS; IFS=','
|
gni_prev_IFS=$IFS; IFS=','
|
||||||
set dummy `echo "$curl_cv_func_getnameinfo_args" | sed 's/\*/\*/g'`
|
set dummy `echo "$curl_cv_func_getnameinfo_args" | sed 's/\*/\*/g'`
|
||||||
@ -314,8 +378,12 @@ AC_DEFUN([CURL_FUNC_GETNAMEINFO_ARGTYPES], [
|
|||||||
[Define to the type of args 4 and 6 for getnameinfo.])
|
[Define to the type of args 4 and 6 for getnameinfo.])
|
||||||
AC_DEFINE_UNQUOTED(GETNAMEINFO_TYPE_ARG7, $[4],
|
AC_DEFINE_UNQUOTED(GETNAMEINFO_TYPE_ARG7, $[4],
|
||||||
[Define to the type of arg 7 for getnameinfo.])
|
[Define to the type of arg 7 for getnameinfo.])
|
||||||
|
AC_DEFINE_UNQUOTED(HAVE_GETNAMEINFO, 1,
|
||||||
|
[Define to 1 if you have the getnameinfo function.])
|
||||||
|
ac_cv_func_getnameinfo="yes"
|
||||||
fi
|
fi
|
||||||
])
|
fi
|
||||||
|
]) # AC_DEFUN
|
||||||
|
|
||||||
|
|
||||||
dnl CURL_CHECK_NONBLOCKING_SOCKET
|
dnl CURL_CHECK_NONBLOCKING_SOCKET
|
||||||
|
@ -204,25 +204,91 @@ AC_DEFUN([CURL_CHECK_TYPE_SOCKLEN_T], [
|
|||||||
])
|
])
|
||||||
|
|
||||||
|
|
||||||
dnl CURL_FUNC_GETNAMEINFO_ARGTYPES
|
dnl CURL_CHECK_FUNC_GETNAMEINFO
|
||||||
dnl -------------------------------------------------
|
dnl -------------------------------------------------
|
||||||
dnl Check the type to be passed to five of the arguments
|
dnl Test if the getnameinfo function is available,
|
||||||
dnl of getnameinfo function, and define those types in
|
dnl and check the types of five of its arguments.
|
||||||
|
dnl If the function succeeds HAVE_GETNAMEINFO will be
|
||||||
|
dnl defined, defining the types of the arguments in
|
||||||
dnl GETNAMEINFO_TYPE_ARG1, GETNAMEINFO_TYPE_ARG2,
|
dnl GETNAMEINFO_TYPE_ARG1, GETNAMEINFO_TYPE_ARG2,
|
||||||
dnl GETNAMEINFO_TYPE_ARG46 and GETNAMEINFO_TYPE_ARG7.
|
dnl GETNAMEINFO_TYPE_ARG46 and GETNAMEINFO_TYPE_ARG7.
|
||||||
dnl This function is experimental and its results shall
|
dnl This function is experimental and its results shall
|
||||||
dnl not be trusted while this notice is in place ------
|
dnl not be trusted while this notice is in place ------
|
||||||
|
|
||||||
AC_DEFUN([CURL_FUNC_GETNAMEINFO_ARGTYPES], [
|
AC_DEFUN([CURL_CHECK_FUNC_GETNAMEINFO], [
|
||||||
AC_REQUIRE([CURL_CHECK_HEADER_WS2TCPIP])dnl
|
AC_REQUIRE([CURL_CHECK_HEADER_WS2TCPIP])dnl
|
||||||
AC_REQUIRE([CURL_CHECK_TYPE_SOCKLEN_T])dnl
|
AC_REQUIRE([CURL_CHECK_TYPE_SOCKLEN_T])dnl
|
||||||
AC_CHECK_HEADERS(sys/types.h sys/socket.h netdb.h)
|
AC_CHECK_HEADERS(sys/types.h sys/socket.h netdb.h)
|
||||||
|
#
|
||||||
|
AC_MSG_CHECKING([for getnameinfo])
|
||||||
|
AC_LINK_IFELSE([
|
||||||
|
AC_LANG_FUNC_LINK_TRY([getnameinfo])
|
||||||
|
],[
|
||||||
|
AC_MSG_RESULT([yes])
|
||||||
|
curl_cv_getnameinfo="yes"
|
||||||
|
],[
|
||||||
|
AC_MSG_RESULT([no])
|
||||||
|
curl_cv_getnameinfo="no"
|
||||||
|
])
|
||||||
|
#
|
||||||
|
if test "$curl_cv_getnameinfo" != "yes"; then
|
||||||
|
AC_MSG_CHECKING([deeper for getnameinfo])
|
||||||
|
AC_TRY_LINK([
|
||||||
|
],[
|
||||||
|
getnameinfo();
|
||||||
|
],[
|
||||||
|
AC_MSG_RESULT([yes])
|
||||||
|
curl_cv_getnameinfo="yes"
|
||||||
|
],[
|
||||||
|
AC_MSG_RESULT([but still no])
|
||||||
|
curl_cv_getnameinfo="no"
|
||||||
|
])
|
||||||
|
fi
|
||||||
|
#
|
||||||
|
if test "$curl_cv_getnameinfo" != "yes"; then
|
||||||
|
AC_MSG_CHECKING([deeper and deeper for getnameinfo])
|
||||||
|
AC_TRY_LINK([
|
||||||
|
#undef inline
|
||||||
|
#ifdef HAVE_WINDOWS_H
|
||||||
|
#ifndef WIN32_LEAN_AND_MEAN
|
||||||
|
#define WIN32_LEAN_AND_MEAN
|
||||||
|
#endif
|
||||||
|
#include <windows.h>
|
||||||
|
#ifdef HAVE_WINSOCK2_H
|
||||||
|
#include <winsock2.h>
|
||||||
|
#ifdef HAVE_WS2TCPIP_H
|
||||||
|
#include <ws2tcpip.h>
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
#else
|
||||||
|
#ifdef HAVE_SYS_TYPES_H
|
||||||
|
#include <sys/types.h>
|
||||||
|
#endif
|
||||||
|
#ifdef HAVE_SYS_SOCKET_H
|
||||||
|
#include <sys/socket.h>
|
||||||
|
#endif
|
||||||
|
#ifdef HAVE_NETDB_H
|
||||||
|
#include <netdb.h>
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
],[
|
||||||
|
getnameinfo(0, 0, 0, 0, 0, 0, 0);
|
||||||
|
],[
|
||||||
|
AC_MSG_RESULT([yes])
|
||||||
|
curl_cv_getnameinfo="yes"
|
||||||
|
],[
|
||||||
|
AC_MSG_RESULT([but still no])
|
||||||
|
curl_cv_getnameinfo="no"
|
||||||
|
])
|
||||||
|
fi
|
||||||
|
#
|
||||||
|
if test "$curl_cv_getnameinfo" = "yes"; then
|
||||||
AC_CACHE_CHECK([types of arguments for getnameinfo],
|
AC_CACHE_CHECK([types of arguments for getnameinfo],
|
||||||
[curl_cv_func_getnameinfo_args], [
|
[curl_cv_func_getnameinfo_args], [
|
||||||
curl_cv_func_getnameinfo_args="unknown"
|
curl_cv_func_getnameinfo_args="unknown"
|
||||||
for gni_arg1 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
|
for gni_arg1 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
|
||||||
for gni_arg2 in 'socklen_t' 'size_t' 'int'; do
|
for gni_arg2 in 'socklen_t' 'size_t' 'int'; do
|
||||||
for gni_arg46 in 'size_t' 'int' 'socklen_t' 'unsigned int'; do
|
for gni_arg46 in 'size_t' 'int' 'socklen_t' 'unsigned int' 'DWORD'; do
|
||||||
for gni_arg7 in 'int' 'unsigned int'; do
|
for gni_arg7 in 'int' 'unsigned int'; do
|
||||||
AC_COMPILE_IFELSE([
|
AC_COMPILE_IFELSE([
|
||||||
AC_LANG_PROGRAM([
|
AC_LANG_PROGRAM([
|
||||||
@ -274,12 +340,10 @@ AC_DEFUN([CURL_FUNC_GETNAMEINFO_ARGTYPES], [
|
|||||||
done
|
done
|
||||||
done
|
done
|
||||||
done
|
done
|
||||||
])
|
]) # AC_CACHE_CHECK
|
||||||
if test "$curl_cv_func_getnameinfo_args" = "unknown"; then
|
if test "$curl_cv_func_getnameinfo_args" = "unknown"; then
|
||||||
AC_MSG_WARN([Cannot find proper types to use for getnameinfo args])
|
AC_MSG_WARN([Cannot find proper types to use for getnameinfo args])
|
||||||
AC_MSG_WARN([Undefining HAVE_GETNAMEINFO])
|
AC_MSG_WARN([HAVE_GETNAMEINFO will not be defined])
|
||||||
#undef HAVE_GETNAMEINFO
|
|
||||||
ac_cv_func_getnameinfo="no"
|
|
||||||
else
|
else
|
||||||
gni_prev_IFS=$IFS; IFS=','
|
gni_prev_IFS=$IFS; IFS=','
|
||||||
set dummy `echo "$curl_cv_func_getnameinfo_args" | sed 's/\*/\*/g'`
|
set dummy `echo "$curl_cv_func_getnameinfo_args" | sed 's/\*/\*/g'`
|
||||||
@ -293,8 +357,12 @@ AC_DEFUN([CURL_FUNC_GETNAMEINFO_ARGTYPES], [
|
|||||||
[Define to the type of args 4 and 6 for getnameinfo.])
|
[Define to the type of args 4 and 6 for getnameinfo.])
|
||||||
AC_DEFINE_UNQUOTED(GETNAMEINFO_TYPE_ARG7, $[4],
|
AC_DEFINE_UNQUOTED(GETNAMEINFO_TYPE_ARG7, $[4],
|
||||||
[Define to the type of arg 7 for getnameinfo.])
|
[Define to the type of arg 7 for getnameinfo.])
|
||||||
|
AC_DEFINE_UNQUOTED(HAVE_GETNAMEINFO, 1,
|
||||||
|
[Define to 1 if you have the getnameinfo function.])
|
||||||
|
ac_cv_func_getnameinfo="yes"
|
||||||
fi
|
fi
|
||||||
])
|
fi
|
||||||
|
]) # AC_DEFUN
|
||||||
|
|
||||||
|
|
||||||
dnl CURL_CHECK_NONBLOCKING_SOCKET
|
dnl CURL_CHECK_NONBLOCKING_SOCKET
|
||||||
|
@ -322,8 +322,7 @@ AC_CHECK_MEMBER(struct addrinfo.ai_flags,
|
|||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
AC_CHECK_FUNCS( getnameinfo \
|
AC_CHECK_FUNCS( bitncmp \
|
||||||
bitncmp \
|
|
||||||
if_indextoname,
|
if_indextoname,
|
||||||
dnl if found
|
dnl if found
|
||||||
[],
|
[],
|
||||||
@ -341,47 +340,6 @@ AC_TRY_LINK( [],
|
|||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
dnl Msys/Mingw does not detect getnameinfo() in AC_CHECK_FUNCS.
|
|
||||||
dnl
|
|
||||||
if test "$ac_cv_func_getnameinfo" = "no"; then
|
|
||||||
AC_MSG_CHECKING([deeper and deeper for getnameinfo])
|
|
||||||
AC_TRY_LINK([
|
|
||||||
#undef inline
|
|
||||||
#ifdef HAVE_WINDOWS_H
|
|
||||||
#ifndef WIN32_LEAN_AND_MEAN
|
|
||||||
#define WIN32_LEAN_AND_MEAN
|
|
||||||
#endif
|
|
||||||
#include <windows.h>
|
|
||||||
#ifdef HAVE_WINSOCK2_H
|
|
||||||
#include <winsock2.h>
|
|
||||||
#ifdef HAVE_WS2TCPIP_H
|
|
||||||
#include <ws2tcpip.h>
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
#else
|
|
||||||
#ifdef HAVE_SYS_TYPES_H
|
|
||||||
#include <sys/types.h>
|
|
||||||
#endif
|
|
||||||
#ifdef HAVE_SYS_SOCKET_H
|
|
||||||
#include <sys/socket.h>
|
|
||||||
#endif
|
|
||||||
#ifdef HAVE_NETDB_H
|
|
||||||
#include <netdb.h>
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
],[
|
|
||||||
getnameinfo(0, 0, 0, 0, 0, 0, 0);
|
|
||||||
],[
|
|
||||||
AC_MSG_RESULT([yes])
|
|
||||||
ac_cv_func_getnameinfo="yes"
|
|
||||||
AC_DEFINE_UNQUOTED(HAVE_GETNAMEINFO, 1,
|
|
||||||
[Define to 1 if you have the getnameinfo function.])
|
|
||||||
],[
|
|
||||||
AC_MSG_RESULT([no])
|
|
||||||
])
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
dnl check for inet_pton
|
dnl check for inet_pton
|
||||||
AC_CHECK_FUNCS(inet_pton)
|
AC_CHECK_FUNCS(inet_pton)
|
||||||
dnl Some systems have it, but not IPv6
|
dnl Some systems have it, but not IPv6
|
||||||
@ -530,13 +488,11 @@ AC_CHECK_SIZEOF(struct in_addr, ,
|
|||||||
]
|
]
|
||||||
)
|
)
|
||||||
|
|
||||||
if test "x$ac_cv_func_getnameinfo" = "x"; then
|
|
||||||
AC_MSG_ERROR([Checking availability of function getnameinfo must be done previously])
|
dnl Check if the getnameinfo function is available
|
||||||
else
|
dnl and get the types of five of its arguments.
|
||||||
if test "x$ac_cv_func_getnameinfo" = "xyes"; then
|
CURL_CHECK_FUNC_GETNAMEINFO
|
||||||
CURL_FUNC_GETNAMEINFO_ARGTYPES
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
dnl God bless non-standardized functions! We need to see which getservbyport_r variant is available
|
dnl God bless non-standardized functions! We need to see which getservbyport_r variant is available
|
||||||
CARES_CHECK_GETSERVBYPORT_R
|
CARES_CHECK_GETSERVBYPORT_R
|
||||||
|
51
configure.ac
51
configure.ac
@ -1556,7 +1556,6 @@ AC_CHECK_FUNCS( strtoll \
|
|||||||
stricmp \
|
stricmp \
|
||||||
strcmpi \
|
strcmpi \
|
||||||
gethostbyaddr \
|
gethostbyaddr \
|
||||||
getnameinfo \
|
|
||||||
gettimeofday \
|
gettimeofday \
|
||||||
inet_addr \
|
inet_addr \
|
||||||
inet_ntoa \
|
inet_ntoa \
|
||||||
@ -1629,46 +1628,6 @@ if test "$ac_cv_func_select" = "no"; then
|
|||||||
])
|
])
|
||||||
fi
|
fi
|
||||||
|
|
||||||
dnl Msys/Mingw does not detect getnameinfo() in AC_CHECK_FUNCS.
|
|
||||||
dnl
|
|
||||||
if test "$ac_cv_func_getnameinfo" = "no"; then
|
|
||||||
AC_MSG_CHECKING([deeper and deeper for getnameinfo])
|
|
||||||
AC_TRY_LINK([
|
|
||||||
#undef inline
|
|
||||||
#ifdef HAVE_WINDOWS_H
|
|
||||||
#ifndef WIN32_LEAN_AND_MEAN
|
|
||||||
#define WIN32_LEAN_AND_MEAN
|
|
||||||
#endif
|
|
||||||
#include <windows.h>
|
|
||||||
#ifdef HAVE_WINSOCK2_H
|
|
||||||
#include <winsock2.h>
|
|
||||||
#ifdef HAVE_WS2TCPIP_H
|
|
||||||
#include <ws2tcpip.h>
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
#else
|
|
||||||
#ifdef HAVE_SYS_TYPES_H
|
|
||||||
#include <sys/types.h>
|
|
||||||
#endif
|
|
||||||
#ifdef HAVE_SYS_SOCKET_H
|
|
||||||
#include <sys/socket.h>
|
|
||||||
#endif
|
|
||||||
#ifdef HAVE_NETDB_H
|
|
||||||
#include <netdb.h>
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
],[
|
|
||||||
getnameinfo(0, 0, 0, 0, 0, 0, 0);
|
|
||||||
],[
|
|
||||||
AC_MSG_RESULT([yes])
|
|
||||||
ac_cv_func_getnameinfo="yes"
|
|
||||||
AC_DEFINE_UNQUOTED(HAVE_GETNAMEINFO, 1,
|
|
||||||
[Define to 1 if you have the getnameinfo function.])
|
|
||||||
],[
|
|
||||||
AC_MSG_RESULT([no])
|
|
||||||
])
|
|
||||||
fi
|
|
||||||
|
|
||||||
dnl sigsetjmp() might be a macro and no function so if it isn't found already
|
dnl sigsetjmp() might be a macro and no function so if it isn't found already
|
||||||
dnl we make an extra check here!
|
dnl we make an extra check here!
|
||||||
if test "$ac_cv_func_sigsetjmp" != "yes"; then
|
if test "$ac_cv_func_sigsetjmp" != "yes"; then
|
||||||
@ -1705,13 +1664,9 @@ AC_CHECK_DECL(inet_pton, ,
|
|||||||
]
|
]
|
||||||
)
|
)
|
||||||
|
|
||||||
if test "x$ac_cv_func_getnameinfo" = "x"; then
|
dnl Check if the getnameinfo function is available
|
||||||
AC_MSG_ERROR([Checking availability of function getnameinfo must be done previously])
|
dnl and get the types of five of its arguments.
|
||||||
else
|
CURL_CHECK_FUNC_GETNAMEINFO
|
||||||
if test "x$ac_cv_func_getnameinfo" = "xyes"; then
|
|
||||||
CURL_FUNC_GETNAMEINFO_ARGTYPES
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
AC_MSG_CHECKING([if we are Mac OS X (to disable poll)])
|
AC_MSG_CHECKING([if we are Mac OS X (to disable poll)])
|
||||||
disable_poll=no
|
disable_poll=no
|
||||||
|
Loading…
Reference in New Issue
Block a user