mbsinit: Move AC_LIBOBJ invocations to module description.
[gnulib.git] / m4 / mbrlen.m4
index c08cb85..884f8cd 100644 (file)
@@ -1,5 +1,5 @@
-# mbrlen.m4 serial 4
-dnl Copyright (C) 2008, 2010 Free Software Foundation, Inc.
+# mbrlen.m4 serial 7
+dnl Copyright (C) 2008, 2010-2011 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
 dnl with or without modifications, as long as this notice is preserved.
@@ -22,11 +22,6 @@ AC_DEFUN([gl_FUNC_MBRLEN],
       REPLACE_MBRLEN=1
     fi
   fi
-  if test $HAVE_MBRLEN = 0 || test $REPLACE_MBRLEN = 1; then
-    gl_REPLACE_WCHAR_H
-    AC_LIBOBJ([mbrlen])
-    gl_PREREQ_MBRLEN
-  fi
 ])
 
 dnl Test whether mbrlen puts the state into non-initial state when parsing an
@@ -56,6 +51,13 @@ changequote([,])dnl
           [AC_LANG_SOURCE([[
 #include <locale.h>
 #include <string.h>
+/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
+   <wchar.h>.
+   BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
+   included before <wchar.h>.  */
+#include <stddef.h>
+#include <stdio.h>
+#include <time.h>
 #include <wchar.h>
 int main ()
 {
@@ -107,6 +109,13 @@ changequote([,])dnl
           [AC_LANG_SOURCE([[
 #include <locale.h>
 #include <string.h>
+/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
+   <wchar.h>.
+   BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
+   included before <wchar.h>.  */
+#include <stddef.h>
+#include <stdio.h>
+#include <time.h>
 #include <wchar.h>
 int main ()
 {
@@ -174,6 +183,13 @@ changequote([,])dnl
           [AC_LANG_SOURCE([[
 #include <locale.h>
 #include <string.h>
+/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
+   <wchar.h>.
+   BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
+   included before <wchar.h>.  */
+#include <stddef.h>
+#include <stdio.h>
+#include <time.h>
 #include <wchar.h>
 int main ()
 {