summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorYang Tse <yangsita@gmail.com>2010-12-15 02:08:46 +0100
committerYang Tse <yangsita@gmail.com>2010-12-15 02:22:04 +0100
commit623f3cb5316dcbe5f0419efae772995643181f3a (patch)
tree2855f1e05398507eb0458f634e1345e5ecd02062 /configure.ac
parentb2dafb6974da4f3b80dda3bd343989157d8c36a0 (diff)
downloadc-ares-623f3cb5316dcbe5f0419efae772995643181f3a.tar.gz
c-ares-623f3cb5316dcbe5f0419efae772995643181f3a.tar.bz2
c-ares-623f3cb5316dcbe5f0419efae772995643181f3a.zip
configure: inet_net_pton function check adjustments
Define HAVE_INET_NET_PTON only when system's inet_net_pton function is IPv6 capable and is not affected by the WLB-2008080064 advisory. HAVE_INET_NET_PTON_IPV6 is no longer defined nor used.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac32
1 files changed, 1 insertions, 31 deletions
diff --git a/configure.ac b/configure.ac
index 9a23699..cda580e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -532,6 +532,7 @@ CARES_CHECK_FUNC_GETHOSTBYADDR
CARES_CHECK_FUNC_GETHOSTBYNAME
CARES_CHECK_FUNC_GETHOSTNAME
CARES_CHECK_FUNC_GETSERVBYPORT_R
+CARES_CHECK_FUNC_INET_NET_PTON
CARES_CHECK_FUNC_INET_NTOP
CARES_CHECK_FUNC_INET_PTON
CARES_CHECK_FUNC_IOCTL
@@ -738,37 +739,6 @@ AC_CHECK_FUNCS([bitncmp \
])
-dnl Check for inet_net_pton
-AC_CHECK_FUNCS(inet_net_pton)
-dnl Again, some systems have it, but not IPv6
-if test "$ac_cv_func_inet_net_pton" = "yes" ; then
-AC_MSG_CHECKING(if inet_net_pton supports IPv6)
-AC_TRY_RUN(
- [
-#ifdef HAVE_SYS_TYPES_H
-#include <sys/types.h>
-#endif
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
-#ifdef HAVE_NETINET_IN_H
-#include <netinet/in.h>
-#endif
-int main()
- {
- struct in6_addr addr6;
- if (inet_net_pton(AF_INET6, "::1", &addr6, sizeof(addr6)) < 1)
- exit(1);
- else
- exit(0);
- }
- ], [
- AC_MSG_RESULT(yes)
- AC_DEFINE_UNQUOTED(HAVE_INET_NET_PTON_IPV6,1,[Define to 1 if inet_net_pton supports IPv6.])
- ], AC_MSG_RESULT(no),AC_MSG_RESULT(no))
-fi
-
-
AC_CHECK_SIZEOF(struct in6_addr, ,
[
#undef inline