summaryrefslogtreecommitdiffstats
path: root/gl/m4/netdb_h.m4
diff options
context:
space:
mode:
Diffstat (limited to 'gl/m4/netdb_h.m4')
-rw-r--r--gl/m4/netdb_h.m417
1 files changed, 6 insertions, 11 deletions
diff --git a/gl/m4/netdb_h.m4 b/gl/m4/netdb_h.m4
index 40ba8f6..c870fb6 100644
--- a/gl/m4/netdb_h.m4
+++ b/gl/m4/netdb_h.m4
@@ -1,4 +1,4 @@
1# netdb_h.m4 serial 7 1# netdb_h.m4 serial 9
2dnl Copyright (C) 2008, 2009, 2010 Free Software Foundation, Inc. 2dnl Copyright (C) 2008, 2009, 2010 Free Software Foundation, Inc.
3dnl This file is free software; the Free Software Foundation 3dnl This file is free software; the Free Software Foundation
4dnl gives unlimited permission to copy and/or distribute it, 4dnl gives unlimited permission to copy and/or distribute it,
@@ -10,21 +10,16 @@ AC_DEFUN([gl_HEADER_NETDB],
10 AC_CHECK_HEADERS_ONCE([netdb.h]) 10 AC_CHECK_HEADERS_ONCE([netdb.h])
11 gl_CHECK_NEXT_HEADERS([netdb.h]) 11 gl_CHECK_NEXT_HEADERS([netdb.h])
12 if test $ac_cv_header_netdb_h = yes; then 12 if test $ac_cv_header_netdb_h = yes; then
13 AC_COMPILE_IFELSE(
14 [AC_LANG_PROGRAM([[
15 #include <netdb.h>
16 struct addrinfo a;
17 int b = EAI_OVERFLOW;
18 int c = AI_NUMERICSERV;
19 ]])],
20 [NETDB_H=''], [NETDB_H='netdb.h'])
21 HAVE_NETDB_H=1 13 HAVE_NETDB_H=1
22 else 14 else
23 NETDB_H='netdb.h'
24 HAVE_NETDB_H=0 15 HAVE_NETDB_H=0
25 fi 16 fi
26 AC_SUBST([HAVE_NETDB_H]) 17 AC_SUBST([HAVE_NETDB_H])
27 AC_SUBST([NETDB_H]) 18
19 dnl Check for declarations of anything we want to poison if the
20 dnl corresponding gnulib module is not in use.
21 gl_WARN_ON_USE_PREPARE([[#include <netdb.h>]],
22 [getaddrinfo freeaddrinfo gai_strerror getnameinfo])
28]) 23])
29 24
30AC_DEFUN([gl_NETDB_MODULE_INDICATOR], 25AC_DEFUN([gl_NETDB_MODULE_INDICATOR],