summaryrefslogtreecommitdiff
path: root/m4
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2006-09-10 12:38:11 +0000
committerSergey Poznyakoff <gray@gnu.org.ua>2006-09-10 12:38:11 +0000
commit94fdc6094f6b02c854432e8c8f658afa6dd654c7 (patch)
tree956d62693bc2b32f89db3645f0ae89801e12495d /m4
parent3f7b793be41677691f62b3ab4b556dba6e9d48f9 (diff)
downloadmailutils-94fdc6094f6b02c854432e8c8f658afa6dd654c7.tar.gz
mailutils-94fdc6094f6b02c854432e8c8f658afa6dd654c7.tar.bz2
Updated by gnulib-sync
Diffstat (limited to 'm4')
-rw-r--r--m4/argp.m47
-rw-r--r--m4/d-type.m422
-rw-r--r--m4/exitfail.m45
-rw-r--r--m4/fnmatch.m413
-rw-r--r--m4/getdelim.m45
-rw-r--r--m4/getline.m419
-rw-r--r--m4/getlogin_r.m43
-rw-r--r--m4/getopt.m44
-rw-r--r--m4/getpass.m47
-rw-r--r--m4/glob.m49
-rw-r--r--m4/intmax_t.m46
-rw-r--r--m4/inttostr.m413
-rw-r--r--m4/inttypes_h_gl.m46
-rw-r--r--m4/longlong_gl.m439
-rw-r--r--m4/mbchar.m417
-rw-r--r--m4/mbswidth.m432
-rw-r--r--m4/md5.m45
-rw-r--r--m4/mempcpy.m45
-rw-r--r--m4/onceonly.m412
-rw-r--r--m4/regex.m413
-rw-r--r--m4/sha1.m45
-rw-r--r--m4/stat-macros.m46
-rw-r--r--m4/stdint.m4821
-rw-r--r--m4/stdint_h_gl.m46
-rw-r--r--m4/strdup.m46
-rw-r--r--m4/strndup.m416
-rw-r--r--m4/strnlen.m46
-rw-r--r--m4/strtok_r.m44
-rw-r--r--m4/xalloc.m45
29 files changed, 388 insertions, 729 deletions
diff --git a/m4/argp.m4 b/m4/argp.m4
index 7d761ae97..5c4213955 100644
--- a/m4/argp.m4
+++ b/m4/argp.m4
@@ -1,4 +1,4 @@
-# argp.m4 serial 6
+# argp.m4 serial 7
dnl Copyright (C) 2003-2006 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -7,6 +7,7 @@ dnl with or without modifications, as long as this notice is preserved.
AC_DEFUN([gl_ARGP],
[
AC_REQUIRE([AC_C_INLINE])
+ AC_REQUIRE([AC_C_RESTRICT])
AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS])
AC_REQUIRE([gl_GETOPT_SUBSTITUTE])
@@ -14,13 +15,13 @@ AC_DEFUN([gl_ARGP],
[AC_DEFINE(HAVE_DECL_PROGRAM_INVOCATION_NAME, 1,
[Define if program_invocation_name is declared])],
[AC_DEFINE(GNULIB_PROGRAM_INVOCATION_NAME, 1,
- [Define to 1 to add extern declaration of program_invocation_name to argp-namefrob.h])],
+ [Define to 1 to add extern declaration of program_invocation_name to argp.h])],
[#include <errno.h>])
AC_CHECK_DECL([program_invocation_short_name],
[AC_DEFINE(HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME, 1,
[Define if program_invocation_short_name is declared])],
[AC_DEFINE(GNULIB_PROGRAM_INVOCATION_SHORT_NAME, 1,
- [Define to 1 to add extern declaration of program_invocation_short_name to argp-namefrob.h])],
+ [Define to 1 to add extern declaration of program_invocation_short_name to argp.h])],
[#include <errno.h>])
# Check if program_invocation_name and program_invocation_short_name
diff --git a/m4/d-type.m4 b/m4/d-type.m4
index 6f3125c7e..7675dd2b0 100644
--- a/m4/d-type.m4
+++ b/m4/d-type.m4
@@ -1,11 +1,11 @@
-#serial 8
+#serial 9
dnl From Jim Meyering.
dnl
dnl Check whether struct dirent has a member named d_type.
dnl
-# Copyright (C) 1997, 1999, 2000, 2001, 2002, 2003, 2004 Free Software
+# Copyright (C) 1997, 1999, 2000, 2001, 2002, 2003, 2004, 2006 Free Software
# Foundation, Inc.
#
# This file is free software; the Free Software Foundation
@@ -13,26 +13,12 @@ dnl
# with or without modifications, as long as this notice is preserved.
AC_DEFUN([gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE],
- [AC_REQUIRE([AC_HEADER_DIRENT])dnl
- AC_CACHE_CHECK([for d_type member in directory struct],
+ [AC_CACHE_CHECK([for d_type member in directory struct],
jm_cv_struct_dirent_d_type,
[AC_TRY_LINK(dnl
[
#include <sys/types.h>
-#ifdef HAVE_DIRENT_H
-# include <dirent.h>
-#else /* not HAVE_DIRENT_H */
-# define dirent direct
-# ifdef HAVE_SYS_NDIR_H
-# include <sys/ndir.h>
-# endif /* HAVE_SYS_NDIR_H */
-# ifdef HAVE_SYS_DIR_H
-# include <sys/dir.h>
-# endif /* HAVE_SYS_DIR_H */
-# ifdef HAVE_NDIR_H
-# include <ndir.h>
-# endif /* HAVE_NDIR_H */
-#endif /* HAVE_DIRENT_H */
+#include <dirent.h>
],
[struct dirent dp; dp.d_type = 0;],
diff --git a/m4/exitfail.m4 b/m4/exitfail.m4
index 5523676f1..b7a691e50 100644
--- a/m4/exitfail.m4
+++ b/m4/exitfail.m4
@@ -1,12 +1,11 @@
-# exitfail.m4 serial 5
-dnl Copyright (C) 2002, 2003, 2005 Free Software Foundation, Inc.
+# exitfail.m4 serial 6
+dnl Copyright (C) 2002, 2003, 2005, 2006 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.
AC_DEFUN([gl_EXITFAIL],
[
- AC_LIBSOURCES([exitfail.c, exitfail.h])
AC_LIBOBJ([exitfail])
dnl No prerequisites of lib/exitfail.c.
diff --git a/m4/fnmatch.m4 b/m4/fnmatch.m4
index 12ab1b74c..1521c0052 100644
--- a/m4/fnmatch.m4
+++ b/m4/fnmatch.m4
@@ -1,14 +1,14 @@
# Check for fnmatch.
-# This is a modified version of autoconf's AC_FUNC_FNMATCH.
-# This file should be simplified after Autoconf 2.57 is required.
-
-# Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005 Free Software
+# Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software
# Foundation, Inc.
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
+# Autoconf defines AC_FUNC_FNMATCH, but that is obsolescent.
+# New applications should use the macros below instead.
+
# _AC_FUNC_FNMATCH_IF(STANDARD = GNU | POSIX, CACHE_VAR, IF-TRUE, IF-FALSE)
# -------------------------------------------------------------------------
# If a STANDARD compliant fnmatch is found, run IF-TRUE, otherwise
@@ -61,10 +61,9 @@ AS_IF([test $$2 = yes], [$3], [$4])
# ------------------
# Prepare the replacement of fnmatch.
AC_DEFUN([_MU_LIBOBJ_FNMATCH],
-[AC_REQUIRE([AC_C_CONST])dnl
-AC_REQUIRE([AC_FUNC_ALLOCA])dnl
+[AC_REQUIRE([AC_FUNC_ALLOCA])dnl
AC_REQUIRE([AC_TYPE_MBSTATE_T])dnl
-AC_CHECK_DECLS([getenv])
+AC_CHECK_DECLS([isblank], [], [], [#include <ctype.h>])
AC_CHECK_FUNCS([btowc mbsrtowcs mempcpy wmemchr wmemcpy wmempcpy])
AC_CHECK_HEADERS([wchar.h wctype.h])
MU_LIBOBJ([fnmatch])
diff --git a/m4/getdelim.m4 b/m4/getdelim.m4
index e345380ac..d1ec864b8 100644
--- a/m4/getdelim.m4
+++ b/m4/getdelim.m4
@@ -1,6 +1,6 @@
-# getdelim.m4 serial 1
+# getdelim.m4 serial 2
-dnl Copyright (C) 2005 Free Software dnl Foundation, Inc.
+dnl Copyright (C) 2005, 2006 Free Software dnl Foundation, Inc.
dnl
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -10,7 +10,6 @@ AC_PREREQ(2.52)
AC_DEFUN([gl_FUNC_GETDELIM],
[
- MU_LIBSOURCES([getdelim.c, getdelim.h])
dnl Persuade glibc <stdio.h> to declare getdelim().
AC_REQUIRE([AC_GNU_SOURCE])
diff --git a/m4/getline.m4 b/m4/getline.m4
index 812eda79b..f82dbb6f8 100644
--- a/m4/getline.m4
+++ b/m4/getline.m4
@@ -1,6 +1,6 @@
-# getline.m4 serial 13
+# getline.m4 serial 15
-dnl Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2005 Free Software
+dnl Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2005, 2006 Free Software
dnl Foundation, Inc.
dnl
dnl This file is free software; the Free Software Foundation
@@ -15,8 +15,6 @@ dnl have a function by that name in -linet that doesn't have anything
dnl to do with the function we need.
AC_DEFUN([gl_FUNC_GETLINE],
[
- MU_LIBSOURCES([getline.c, getline.h])
-
dnl Persuade glibc <stdio.h> to declare getline().
AC_REQUIRE([AC_GNU_SOURCE])
@@ -47,7 +45,18 @@ AC_DEFUN([gl_FUNC_GETLINE],
}
], am_cv_func_working_getline=yes dnl The library version works.
, am_cv_func_working_getline=no dnl The library version does NOT work.
- , am_cv_func_working_getline=no dnl We're cross compiling.
+ , dnl We're cross compiling. Assume it works on glibc2 systems.
+ [AC_EGREP_CPP([Lucky GNU user],
+ [
+#include <features.h>
+#ifdef __GNU_LIBRARY__
+ #if (__GLIBC__ >= 2)
+ Lucky GNU user
+ #endif
+#endif
+ ],
+ [am_cv_func_working_getline=yes],
+ [am_cv_func_working_getline=no])]
)])
fi
diff --git a/m4/getlogin_r.m4 b/m4/getlogin_r.m4
index 5ad365c99..70e114b20 100644
--- a/m4/getlogin_r.m4
+++ b/m4/getlogin_r.m4
@@ -1,4 +1,4 @@
-#serial 2
+#serial 3
# Copyright (C) 2005, 2006 Free Software Foundation, Inc.
#
@@ -14,7 +14,6 @@ dnl
AC_DEFUN([gl_GETLOGIN_R_SUBSTITUTE],
[
gl_PREREQ_GETLOGIN_R
- MU_LIBSOURCE([getlogin_r.h])
MU_LIBOBJ([getlogin_r])
])
diff --git a/m4/getopt.m4 b/m4/getopt.m4
index e9ebae4cf..12892d1c0 100644
--- a/m4/getopt.m4
+++ b/m4/getopt.m4
@@ -1,11 +1,11 @@
-# getopt.m4 serial 12
+# getopt.m4 serial 13
dnl Copyright (C) 2002, 2003, 2004, 2005, 2006 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.
# The getopt module assume you want GNU getopt, with getopt_long etc,
-# rather than vanilla POSIX getopt. This means your your code should
+# rather than vanilla POSIX getopt. This means your code should
# always include <getopt.h> for the getopt prototypes.
AC_DEFUN([gl_GETOPT_SUBSTITUTE],
diff --git a/m4/getpass.m4 b/m4/getpass.m4
index ba6815f61..014c52d14 100644
--- a/m4/getpass.m4
+++ b/m4/getpass.m4
@@ -1,4 +1,4 @@
-# getpass.m4 serial 7
+# getpass.m4 serial 9
dnl Copyright (C) 2002-2003, 2005-2006 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -7,8 +7,6 @@ dnl with or without modifications, as long as this notice is preserved.
# Provide a getpass() function if the system doesn't have it.
AC_DEFUN([gl_FUNC_GETPASS],
[
- AC_LIBSOURCES([getpass.c, getpass.h])
-
AC_REPLACE_FUNCS(getpass)
AC_CHECK_DECLS_ONCE(getpass)
if test $ac_cv_func_getpass = no; then
@@ -20,8 +18,6 @@ AC_DEFUN([gl_FUNC_GETPASS],
# arbitrary length (not just 8 bytes as on HP-UX).
AC_DEFUN([gl_FUNC_GETPASS_GNU],
[
- AC_LIBSOURCES([getpass.c, getpass.h])
-
AC_CHECK_DECLS_ONCE(getpass)
dnl TODO: Detect when GNU getpass() is already found in glibc.
AC_LIBOBJ(getpass)
@@ -42,4 +38,5 @@ AC_DEFUN([gl_PREREQ_GETPASS], [
AC_CHECK_DECLS_ONCE([fputs_unlocked])
AC_CHECK_DECLS_ONCE([funlockfile])
AC_CHECK_DECLS_ONCE([putc_unlocked])
+ :
])
diff --git a/m4/glob.m4 b/m4/glob.m4
index 55e624198..6d1eec9ce 100644
--- a/m4/glob.m4
+++ b/m4/glob.m4
@@ -1,11 +1,11 @@
-# glob.m4 serial 3
-dnl Copyright (C) 2005 Free Software Foundation, Inc.
+# glob.m4 serial 7
+dnl Copyright (C) 2005, 2006 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.
# The glob module assumes you want GNU glob, with glob_pattern_p etc,
-# rather than vanilla POSIX glob. This means your your code should
+# rather than vanilla POSIX glob. This means your code should
# always include <glob.h> for the glob prototypes.
AC_DEFUN([gl_GLOB_SUBSTITUTE],
@@ -13,7 +13,6 @@ AC_DEFUN([gl_GLOB_SUBSTITUTE],
gl_PREREQ_GLOB
GLOB_H=glob.h
- MU_LIBSOURCES([glob.c, glob_.h, glob-libc.h])
MU_LIBOBJ([glob])
AC_SUBST([GLOB_H])
])
@@ -73,8 +72,8 @@ if (glob ("conf*-globtest", 0, NULL, &found) == GLOB_NOMATCH) return 1;]]),
# Prerequisites of lib/glob.*.
AC_DEFUN([gl_PREREQ_GLOB],
[ AC_REQUIRE([gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE])dnl
+ AC_REQUIRE([AC_C_RESTRICT])dnl
AC_REQUIRE([AC_GNU_SOURCE])dnl
- AC_REQUIRE([AC_HEADER_DIRENT])dnl
AC_CHECK_HEADERS_ONCE([sys/cdefs.h unistd.h])dnl
AC_CHECK_FUNCS_ONCE([getlogin_r getpwnam_r])dnl
:])
diff --git a/m4/intmax_t.m4 b/m4/intmax_t.m4
index 44b16523c..17c7b0ae8 100644
--- a/m4/intmax_t.m4
+++ b/m4/intmax_t.m4
@@ -1,5 +1,5 @@
-# intmax_t.m4 serial 4
-dnl Copyright (C) 1997-2004 Free Software Foundation, Inc.
+# intmax_t.m4 serial 5
+dnl Copyright (C) 1997-2004, 2006 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.
@@ -46,7 +46,7 @@ AC_DEFUN([gt_AC_TYPE_INTMAX_T],
#if HAVE_INTTYPES_H_WITH_UINTMAX
#include <inttypes.h>
#endif
-], [intmax_t x = -1;], gt_cv_c_intmax_t=yes, gt_cv_c_intmax_t=no)])
+], [intmax_t x = -1; return !x;], gt_cv_c_intmax_t=yes, gt_cv_c_intmax_t=no)])
if test $gt_cv_c_intmax_t = yes; then
AC_DEFINE(HAVE_INTMAX_T, 1,
[Define if you have the 'intmax_t' type in <stdint.h> or <inttypes.h>.])
diff --git a/m4/inttostr.m4 b/m4/inttostr.m4
index 4df30f540..53a3149d0 100644
--- a/m4/inttostr.m4
+++ b/m4/inttostr.m4
@@ -1,18 +1,11 @@
-#serial 5
-dnl Copyright (C) 2004, 2005 Free Software Foundation, Inc.
+#serial 6
+dnl Copyright (C) 2004, 2005, 2006 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.
AC_DEFUN([gl_INTTOSTR],
[
- MU_LIBSOURCES([inttostr.c, inttostr.h, intprops.h])
-
- dnl We don't technically need to list the following .c files, since their
- dnl functions are named in the MU_LIBOBJ calls, but this is an unusual
- dnl module and it seems a little clearer to do so.
- MU_LIBSOURCES([imaxtostr.c, offtostr.c, umaxtostr.c])
-
MU_LIBOBJ([imaxtostr])
MU_LIBOBJ([offtostr])
MU_LIBOBJ([umaxtostr])
@@ -25,8 +18,6 @@ AC_DEFUN([gl_INTTOSTR],
# Prerequisites of lib/inttostr.h.
AC_DEFUN([gl_PREREQ_INTTOSTR], [
- AC_REQUIRE([gl_AC_TYPE_INTMAX_T])
- AC_REQUIRE([gl_AC_TYPE_UINTMAX_T])
AC_REQUIRE([AC_TYPE_OFF_T])
:
])
diff --git a/m4/inttypes_h_gl.m4 b/m4/inttypes_h_gl.m4
index a5d075d96..edc8ecb2d 100644
--- a/m4/inttypes_h_gl.m4
+++ b/m4/inttypes_h_gl.m4
@@ -1,5 +1,5 @@
-# inttypes_h.m4 serial 6
-dnl Copyright (C) 1997-2004 Free Software Foundation, Inc.
+# inttypes_h.m4 serial 7
+dnl Copyright (C) 1997-2004, 2006 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.
@@ -15,7 +15,7 @@ AC_DEFUN([gl_AC_HEADER_INTTYPES_H],
[AC_TRY_COMPILE(
[#include <sys/types.h>
#include <inttypes.h>],
- [uintmax_t i = (uintmax_t) -1;],
+ [uintmax_t i = (uintmax_t) -1; return !i;],
gl_cv_header_inttypes_h=yes,
gl_cv_header_inttypes_h=no)])
if test $gl_cv_header_inttypes_h = yes; then
diff --git a/m4/longlong_gl.m4 b/m4/longlong_gl.m4
index 7b399e012..89a47bd19 100644
--- a/m4/longlong_gl.m4
+++ b/m4/longlong_gl.m4
@@ -1,21 +1,42 @@
-# longlong.m4 serial 5
-dnl Copyright (C) 1999-2004 Free Software Foundation, Inc.
+# longlong.m4 serial 7
+dnl Copyright (C) 1999-2006 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.
dnl From Paul Eggert.
-# Define HAVE_LONG_LONG if 'long long' works.
+# Define HAVE_LONG_LONG_INT if 'long long int' works.
+# This fixes a bug in Autoconf 2.60, but can be removed once we
+# assume 2.61 everywhere.
+AC_DEFUN([AC_TYPE_LONG_LONG_INT],
+[
+ AC_CACHE_CHECK([for long long int], [ac_cv_type_long_long_int],
+ [AC_LINK_IFELSE(
+ [AC_LANG_PROGRAM(
+ [[long long int ll = 9223372036854775807ll;
+ long long int nll = -9223372036854775807LL;
+ typedef int a[((-9223372036854775807LL < 0
+ && 0 < 9223372036854775807ll)
+ ? 1 : -1)];
+ int i = 63;]],
+ [[long long int llmax = 9223372036854775807ll;
+ return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
+ | (llmax / ll) | (llmax % ll));]])],
+ [ac_cv_type_long_long_int=yes],
+ [ac_cv_type_long_long_int=no])])
+ if test $ac_cv_type_long_long_int = yes; then
+ AC_DEFINE([HAVE_LONG_LONG_INT], 1,
+ [Define to 1 if the system has the type `long long int'.])
+ fi
+])
+
+# This macro is obsolescent and should go away soon.
AC_DEFUN([gl_AC_TYPE_LONG_LONG],
[
- AC_CACHE_CHECK([for long long], ac_cv_type_long_long,
- [AC_TRY_LINK([long long ll = 1LL; int i = 63;],
- [long long llmax = (long long) -1;
- return ll << i | ll >> i | llmax / ll | llmax % ll;],
- ac_cv_type_long_long=yes,
- ac_cv_type_long_long=no)])
+ AC_REQUIRE([AC_TYPE_LONG_LONG_INT])
+ ac_cv_type_long_long=$ac_cv_type_long_long_int
if test $ac_cv_type_long_long = yes; then
AC_DEFINE(HAVE_LONG_LONG, 1,
[Define if you have the 'long long' type.])
diff --git a/m4/mbchar.m4 b/m4/mbchar.m4
index d08885e48..6299005fe 100644
--- a/m4/mbchar.m4
+++ b/m4/mbchar.m4
@@ -1,5 +1,5 @@
-# mbchar.m4 serial 2
-dnl Copyright (C) 2005 Free Software Foundation, Inc.
+# mbchar.m4 serial 4
+dnl Copyright (C) 2005-2006 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.
@@ -10,11 +10,14 @@ dnl From Bruno Haible.
AC_DEFUN([gl_MBCHAR],
[
AC_REQUIRE([AC_GNU_SOURCE])
- dnl The following line is that so the user can test
- dnl HAVE_WCHAR_H && HAVE_WCTYPE_H before #include "mbchar.h".
- AC_CHECK_HEADERS_ONCE(wchar.h wctype.h)
- dnl Compile mbchar.c only if HAVE_WCHAR_H && HAVE_WCTYPE_H.
- if test $ac_cv_header_wchar_h = yes && test $ac_cv_header_wctype_h = yes; then
+ dnl The following line is that so the user can test HAVE_WCHAR_H
+ dnl before #include "mbchar.h".
+ AC_CHECK_HEADERS_ONCE([wchar.h])
+ dnl Compile mbchar.c only if HAVE_WCHAR_H.
+ if test $ac_cv_header_wchar_h = yes; then
MU_LIBOBJ([mbchar])
+ dnl Prerequisites of mbchar.h and mbchar.c.
+ AC_CHECK_HEADERS_ONCE([wctype.h])
+ AC_CHECK_FUNCS([iswcntrl])
fi
])
diff --git a/m4/mbswidth.m4 b/m4/mbswidth.m4
index 878e5311d..3cb200039 100644
--- a/m4/mbswidth.m4
+++ b/m4/mbswidth.m4
@@ -1,5 +1,5 @@
-# mbswidth.m4 serial 11
-dnl Copyright (C) 2000-2002, 2004 Free Software Foundation, Inc.
+# mbswidth.m4 serial 12
+dnl Copyright (C) 2000-2002, 2004, 2006 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.
@@ -9,33 +9,11 @@ dnl From Bruno Haible.
AC_DEFUN([gl_MBSWIDTH],
[
- AC_CHECK_HEADERS_ONCE(wchar.h wctype.h)
- AC_CHECK_FUNCS_ONCE(isascii iswprint mbsinit)
- AC_CHECK_FUNCS(iswcntrl wcwidth)
+ AC_CHECK_HEADERS_ONCE([wchar.h wctype.h])
+ AC_CHECK_FUNCS_ONCE([isascii mbsinit])
+ AC_CHECK_FUNCS([iswcntrl])
gl_FUNC_MBRTOWC
- AC_CACHE_CHECK([whether wcwidth is declared], ac_cv_have_decl_wcwidth,
- [AC_TRY_COMPILE([
-/* AIX 3.2.5 declares wcwidth in <string.h>. */
-#if HAVE_STRING_H
-# include <string.h>
-#endif
-#if HAVE_WCHAR_H
-# include <wchar.h>
-#endif
-], [
-#ifndef wcwidth
- char *p = (char *) wcwidth;
-#endif
-], ac_cv_have_decl_wcwidth=yes, ac_cv_have_decl_wcwidth=no)])
- if test $ac_cv_have_decl_wcwidth = yes; then
- ac_val=1
- else
- ac_val=0
- fi
- AC_DEFINE_UNQUOTED(HAVE_DECL_WCWIDTH, $ac_val,
- [Define to 1 if you have the declaration of wcwidth(), and to 0 otherwise.])
-
dnl UnixWare 7.1.1 <wchar.h> has a declaration of a function mbswidth()
dnl that clashes with ours.
AC_CACHE_CHECK([whether mbswidth is declared in <wchar.h>],
diff --git a/m4/md5.m4 b/m4/md5.m4
index 9aeca4656..62e995924 100644
--- a/m4/md5.m4
+++ b/m4/md5.m4
@@ -1,12 +1,11 @@
-# md5.m4 serial 8
-dnl Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
+# md5.m4 serial 9
+dnl Copyright (C) 2002, 2003, 2004, 2005, 2006 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.
AC_DEFUN([gl_MD5],
[
- MU_LIBSOURCES([md5.c, md5.h])
MU_LIBOBJ([md5])
dnl Prerequisites of lib/md5.c.
diff --git a/m4/mempcpy.m4 b/m4/mempcpy.m4
index 13a150dd2..fb77d528c 100644
--- a/m4/mempcpy.m4
+++ b/m4/mempcpy.m4
@@ -1,12 +1,11 @@
-# mempcpy.m4 serial 3
-dnl Copyright (C) 2003, 2004 Free Software Foundation, Inc.
+# mempcpy.m4 serial 4
+dnl Copyright (C) 2003, 2004, 2006 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.
AC_DEFUN([gl_FUNC_MEMPCPY],
[
- MU_LIBSOURCES([mempcpy.c, mempcpy.h])
dnl Persuade glibc <string.h> to declare mempcpy().
AC_REQUIRE([AC_GNU_SOURCE])
diff --git a/m4/onceonly.m4 b/m4/onceonly.m4
index 14d3c0b2a..15884b3ea 100644
--- a/m4/onceonly.m4
+++ b/m4/onceonly.m4
@@ -1,5 +1,5 @@
-# onceonly_2_57.m4 serial 3
-dnl Copyright (C) 2002-2003, 2005 Free Software Foundation, Inc.
+# onceonly_2_57.m4 serial 4
+dnl Copyright (C) 2002-2003, 2005-2006 Free Software Foundation, Inc.
dnl This file is free software, distributed under the terms of the GNU
dnl General Public License. As a special exception to the GNU General
dnl Public License, this file may be distributed as part of a program
@@ -7,10 +7,10 @@ dnl that contains a configuration script generated by Autoconf, under
dnl the same distribution terms as the rest of that program.
dnl This file defines some "once only" variants of standard autoconf macros.
-dnl AC_CHECK_HEADERS_ONCE like AC_CHECK_HEADERS
-dnl AC_CHECK_FUNCS_ONCE like AC_CHECK_FUNCS
-dnl AC_CHECK_DECLS_ONCE like AC_CHECK_DECLS
-dnl AC_REQUIRE([AC_HEADER_STDC]) like AC_HEADER_STDC
+dnl AC_CHECK_HEADERS_ONCE like AC_CHECK_HEADERS
+dnl AC_CHECK_FUNCS_ONCE like AC_CHECK_FUNCS
+dnl AC_CHECK_DECLS_ONCE like AC_CHECK_DECLS
+dnl AC_REQUIRE([AC_FUNC_STRCOLL]) like AC_FUNC_STRCOLL
dnl The advantage is that the check for each of the headers/functions/decls
dnl will be put only once into the 'configure' file. It keeps the size of
dnl the 'configure' file down, and avoids redundant output when 'configure'
diff --git a/m4/regex.m4 b/m4/regex.m4
index 29abb7456..85b897e88 100644
--- a/m4/regex.m4
+++ b/m4/regex.m4
@@ -1,4 +1,4 @@
-#serial 36
+#serial 39
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
# 2006 Free Software Foundation, Inc.
@@ -14,10 +14,6 @@ AC_PREREQ([2.50])
AC_DEFUN([gl_REGEX],
[
- MU_LIBSOURCES(
- [regcomp.c, regex.c, regex.h,
- regex_internal.c, regex_internal.h, regexec.c])
-
AC_ARG_WITH([included-regex],
[AC_HELP_STRING([--without-included-regex],
[don't compile regex; this is the default on
@@ -28,7 +24,7 @@ AC_DEFUN([gl_REGEX],
yes|no) ac_use_included_regex=$with_included_regex
;;
'')
- # If the system regex support is good enough that it passes the the
+ # If the system regex support is good enough that it passes the
# following run test, then default to *not* using the included regex.c.
# If cross compiling, assume the test would fail and use the included
# regex.c. The first failing regular expression is from `Spencer ere
@@ -163,8 +159,9 @@ AC_DEFUN([gl_REGEX],
AC_DEFUN([gl_PREREQ_REGEX],
[
AC_REQUIRE([AC_GNU_SOURCE])
- AC_REQUIRE([gl_C_RESTRICT])
+ AC_REQUIRE([AC_C_RESTRICT])
AC_REQUIRE([AM_LANGINFO_CODESET])
AC_CHECK_HEADERS_ONCE([locale.h wchar.h wctype.h])
- AC_CHECK_FUNCS_ONCE([isblank mbrtowc mempcpy wcrtomb wcscoll])
+ AC_CHECK_FUNCS_ONCE([mbrtowc mempcpy wcrtomb wcscoll])
+ AC_CHECK_DECLS([isblank], [], [], [#include <ctype.h>])
])
diff --git a/m4/sha1.m4 b/m4/sha1.m4
index dd3a69c5e..0c7915056 100644
--- a/m4/sha1.m4
+++ b/m4/sha1.m4
@@ -1,12 +1,11 @@
-# sha1.m4 serial 6
-dnl Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
+# sha1.m4 serial 7
+dnl Copyright (C) 2002, 2003, 2004, 2005, 2006 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.
AC_DEFUN([gl_SHA1],
[
- MU_LIBSOURCES([sha1.c, sha1.h])
MU_LIBOBJ([sha1])
dnl Prerequisites of lib/sha1.c.
diff --git a/m4/stat-macros.m4 b/m4/stat-macros.m4
index 803a81286..5f3301d08 100644
--- a/m4/stat-macros.m4
+++ b/m4/stat-macros.m4
@@ -1,6 +1,6 @@
-#serial 2
+#serial 3
-# Copyright (C) 2005 Free Software Foundation, Inc.
+# Copyright (C) 2005, 2006 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -8,7 +8,5 @@
AC_DEFUN([gl_STAT_MACROS],
[
- MU_LIBSOURCES([stat-macros.h])
-
AC_REQUIRE([AC_HEADER_STAT])
])
diff --git a/m4/stdint.m4 b/m4/stdint.m4
index e529ef3d2..48748c613 100644
--- a/m4/stdint.m4
+++ b/m4/stdint.m4
@@ -1,14 +1,25 @@
-# stdint.m4 serial 10
+# stdint.m4 serial 18
dnl Copyright (C) 2001-2002, 2004-2006 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.
-dnl From Bruno Haible.
+dnl From Paul Eggert and Bruno Haible.
dnl Test whether <stdint.h> is supported or must be substituted.
AC_DEFUN([gl_STDINT_H],
[
+ AC_PREREQ(2.59)dnl
+
+ dnl Check for long long int.
+ AC_REQUIRE([AC_TYPE_LONG_LONG_INT])
+ if test $ac_cv_type_long_long_int = yes; then
+ HAVE_LONG_LONG_INT=1
+ else
+ HAVE_LONG_LONG_INT=0
+ fi
+ AC_SUBST([HAVE_LONG_LONG_INT])
+
dnl Check for <wchar.h>.
AC_CHECK_HEADERS_ONCE([wchar.h])
if test $ac_cv_header_wchar_h = yes; then
@@ -18,582 +29,186 @@ AC_DEFUN([gl_STDINT_H],
fi
AC_SUBST([HAVE_WCHAR_H])
- dnl Check for <stdint.h> that doesn't clash with <sys/types.h>.
- gl_HEADER_STDINT_H
- if test $gl_cv_header_stdint_h = yes; then
- ac_cv_header_stdint_h=yes; dnl Hack for gl_FULL_HEADER_PATH.
- gl_FULL_HEADER_PATH([stdint.h])
- FULL_PATH_STDINT_H='<'$gl_cv_full_path_stdint_h'>'
- AC_SUBST([FULL_PATH_STDINT_H])
- HAVE_STDINT_H=1
- else
- HAVE_STDINT_H=0
- fi
- AC_SUBST([HAVE_STDINT_H])
-
- dnl Check for <inttypes.h> that doesn't clash with <sys/types.h>.
- gl_HEADER_INTTYPES_H
- if test $gl_cv_header_inttypes_h = yes; then
- ac_cv_header_inttypes_h=yes; dnl Hack for gl_FULL_HEADER_PATH.
- gl_FULL_HEADER_PATH([inttypes.h])
- FULL_PATH_INTTYPES_H='<'$gl_cv_full_path_inttypes_h'>'
- AC_SUBST([FULL_PATH_INTTYPES_H])
+ dnl Check for <inttypes.h>.
+ dnl AC_INCLUDES_DEFAULT defines $ac_cv_header_inttypes_h.
+ if test $ac_cv_header_inttypes_h = yes; then
HAVE_INTTYPES_H=1
else
HAVE_INTTYPES_H=0
fi
AC_SUBST([HAVE_INTTYPES_H])
- dnl Check for <sys/inttypes.h>.
- AC_CHECK_HEADERS([sys/inttypes.h])
- if test $ac_cv_header_sys_inttypes_h = yes; then
- HAVE_SYS_INTTYPES_H=1
+ dnl Check for <sys/types.h>.
+ dnl AC_INCLUDES_DEFAULT defines $ac_cv_header_sys_types_h.
+ if test $ac_cv_header_sys_types_h = yes; then
+ HAVE_SYS_TYPES_H=1
else
- HAVE_SYS_INTTYPES_H=0
+ HAVE_SYS_TYPES_H=0
fi
- AC_SUBST([HAVE_SYS_INTTYPES_H])
+ AC_SUBST([HAVE_SYS_TYPES_H])
- dnl Check for <sys/bitypes.h> (used in Linux libc4 >= 4.6.7 and libc5).
- AC_CHECK_HEADERS([sys/bitypes.h])
- if test $ac_cv_header_sys_bitypes_h = yes; then
- HAVE_SYS_BITYPES_H=1
- else
- HAVE_SYS_BITYPES_H=0
- fi
- AC_SUBST([HAVE_SYS_BITYPES_H])
-
- dnl Is long == int64_t ?
- AC_CACHE_CHECK([whether 'long' is 64 bit wide], gl_cv_long_bitsize_64, [
- AC_TRY_COMPILE([
-#define POW63 ((((((long) 1 << 15) << 15) << 15) << 15) << 3)
-#define POW64 ((((((long) 1 << 15) << 15) << 15) << 15) << 4)
-typedef int array [2 * (POW63 != 0 && POW64 == 0) - 1];
-], , gl_cv_long_bitsize_64=yes, gl_cv_long_bitsize_64=no)])
- if test $gl_cv_long_bitsize_64 = yes; then
- HAVE_LONG_64BIT=1