]> sjero.net Git - wget/blobdiff - aclocal.m4
[svn] Remove the "rbuf" buffering layer. Provide peeking primitives instead.
[wget] / aclocal.m4
index a85014ab79a5b26eb0ba46c18caf2fd234f1fbb0..d71269ac3e0fb84940455392d885901c4d3a1c41 100644 (file)
@@ -3,19 +3,15 @@ dnl Check for `struct utimbuf'.
 dnl
 
 AC_DEFUN([WGET_STRUCT_UTIMBUF], [
-  AC_MSG_CHECKING([for struct utimbuf])
-  if test x"$ac_cv_header_utime_h" = xyes; then
-    AC_EGREP_CPP([struct[      ]+utimbuf],
-      [#include <utime.h>
-      ], [
-       AC_DEFINE([HAVE_STRUCT_UTIMBUF], 1,
-                 [Define if you have struct utimbuf.])
-       AC_MSG_RESULT(yes)
-      ],
-      [AC_MSG_RESULT(no)])
-  else
-    AC_MSG_RESULT(no)
-  fi
+  AC_CHECK_TYPES([struct utimbuf], [], [], [
+#include <stdio.h>
+#if HAVE_SYS_TYPES_H
+# include <sys/types.h>
+#endif
+#if HAVE_UTIME_H
+# include <utime.h>
+#endif
+  ])
 ])
 
 
@@ -27,18 +23,16 @@ dnl size_t *, we use that, else we use int.
 
 AC_DEFUN([WGET_SOCKLEN_T], [
   AC_MSG_CHECKING(for socklen_t)
-  AC_TRY_COMPILE([
+  AC_COMPILE_IFELSE([
 #include <sys/types.h>
 #include <sys/socket.h>
 socklen_t x;
-],
-    [], [AC_MSG_RESULT(socklen_t)], [
-      AC_TRY_COMPILE([
+  ], [AC_MSG_RESULT(socklen_t)], [
+    AC_COMPILE_IFELSE([
 #include <sys/types.h>
 #include <sys/socket.h>
 int accept (int, struct sockaddr *, size_t *);
-],
-      [], [
+    ], [
       AC_MSG_RESULT(size_t)
       AC_DEFINE([socklen_t], [size_t],
                 [Define to int or size_t on systems without socklen_t.])