Reduce the dependencies of m4/sys_socket_h.m4.
authorBruno Haible <bruno@clisp.org>
Sat, 25 Oct 2008 20:51:05 +0000 (22:51 +0200)
committerBruno Haible <bruno@clisp.org>
Sat, 25 Oct 2008 20:51:05 +0000 (22:51 +0200)
ChangeLog
m4/sys_socket_h.m4
modules/sys_socket

index cb538aa..e180e15 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2008-10-25  Bruno Haible  <bruno@clisp.org>
 
+       * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_WINSOCK2): Require
+       gl_UNISTD_H_DEFAULTS, gl_SYS_IOCTL_H_DEFAULTS only if they exist.
+       * modules/sys_socket (Files): Remove m4/unistd_h.m4, m4/sys_ioctl_h.m4.
+
        * lib/sys_socket.in.h (HAVE__GL_CLOSE_FD_MAYBE_SOCKET); Move macro from
        here ...
        * lib/unistd.in.h (HAVE__GL_CLOSE_FD_MAYBE_SOCKET); ... to here.
index 9d2d92c..85a0ace 100644 (file)
@@ -71,8 +71,8 @@ AC_DEFUN([gl_HEADER_SYS_SOCKET],
 # Sets and substitutes HAVE_WINSOCK2_H.
 AC_DEFUN([gl_PREREQ_SYS_H_WINSOCK2],
 [
-  AC_REQUIRE([gl_UNISTD_H_DEFAULTS])
-  AC_REQUIRE([gl_SYS_IOCTL_H_DEFAULTS])
+  m4_ifdef([gl_UNISTD_H_DEFAULTS], [AC_REQUIRE([gl_UNISTD_H_DEFAULTS])])
+  m4_ifdef([gl_SYS_IOCTL_H_DEFAULTS], [AC_REQUIRE([gl_SYS_IOCTL_H_DEFAULTS])])
   AC_CHECK_HEADERS_ONCE([sys/socket.h])
   if test $ac_cv_header_sys_socket_h != yes; then
     dnl We cannot use AC_CHECK_HEADERS_ONCE here, because that would make
index c42db6a..98b4429 100644 (file)
@@ -5,8 +5,6 @@ Files:
 lib/sys_socket.in.h
 m4/sys_socket_h.m4
 m4/sockpfaf.m4
-m4/unistd_h.m4
-m4/sys_ioctl_h.m4
 
 Depends-on:
 include_next