summaryrefslogtreecommitdiffstats
path: root/gl/m4/inet_ntop.m4
diff options
context:
space:
mode:
Diffstat (limited to 'gl/m4/inet_ntop.m4')
-rw-r--r--gl/m4/inet_ntop.m417
1 files changed, 12 insertions, 5 deletions
diff --git a/gl/m4/inet_ntop.m4 b/gl/m4/inet_ntop.m4
index bb02d22..42bfc5e 100644
--- a/gl/m4/inet_ntop.m4
+++ b/gl/m4/inet_ntop.m4
@@ -1,19 +1,26 @@
1# inet_ntop.m4 serial 3 1# inet_ntop.m4 serial 8
2dnl Copyright (C) 2005, 2006 Free Software Foundation, Inc. 2dnl Copyright (C) 2005, 2006, 2008, 2009 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,
5dnl with or without modifications, as long as this notice is preserved. 5dnl with or without modifications, as long as this notice is preserved.
6 6
7AC_DEFUN([gl_INET_NTOP], 7AC_DEFUN([gl_INET_NTOP],
8[ 8[
9 AC_REPLACE_FUNCS(inet_ntop) 9 dnl Persuade Solaris <arpa/inet.h> to declare inet_ntop.
10 AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS])
11
12 gl_REPLACE_ARPA_INET_H
13
14 AC_REPLACE_FUNCS([inet_ntop])
10 gl_PREREQ_INET_NTOP 15 gl_PREREQ_INET_NTOP
11]) 16])
12 17
13# Prerequisites of lib/inet_ntop.h and lib/inet_ntop.c. 18# Prerequisites of lib/inet_ntop.c.
14AC_DEFUN([gl_PREREQ_INET_NTOP], [ 19AC_DEFUN([gl_PREREQ_INET_NTOP], [
15 AC_CHECK_HEADERS_ONCE([netinet/in.h arpa/inet.h])
16 AC_CHECK_DECLS([inet_ntop],,,[#include <arpa/inet.h>]) 20 AC_CHECK_DECLS([inet_ntop],,,[#include <arpa/inet.h>])
21 if test $ac_cv_have_decl_inet_ntop = no; then
22 HAVE_DECL_INET_NTOP=0
23 fi
17 AC_REQUIRE([gl_SOCKET_FAMILIES]) 24 AC_REQUIRE([gl_SOCKET_FAMILIES])
18 AC_REQUIRE([AC_C_RESTRICT]) 25 AC_REQUIRE([AC_C_RESTRICT])
19]) 26])