autoconf-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: proposed gnulib-related additions to Autoconf


From: Paul Eggert
Subject: Re: proposed gnulib-related additions to Autoconf
Date: Fri, 31 Mar 2006 11:51:45 -0800
User-agent: Gnus/5.1007 (Gnus v5.10.7) Emacs/21.4 (gnu/linux)

Ralf Wildenhues <address@hidden> writes:

> Even that is theoretical at this point: I do not know of a system that
> has an intmax_t that is larger than long long.  But AFAIK C99 allows it.

Once we go down that route we're in trouble.  C99 allows an infinite
number of integer types.  For example, an implementation can have an
integer type that is halfway between int and long.  I think the only
way we can address this, with the current API, is to catalog the
monsters that we find.  (I'm hoping we don't find any.)

> That's why I only suggested it for long and long long, not for int.
> But maybe I'm still missing something else here.

Ah, OK, I think I see your point now.  Yes, that would be an optimization.

Here's my current attempt to address all the issues you mentioned, as
a patch against CVS Autoconf.  I started to factor out the bits-width
stuff into a new macro _AC_C_TYPE_BITS_INTEGER, but it doesn't have a
public API yet, since I still don't have the caching/sharing issues
nailed down.

2006-03-31  Paul Eggert  <address@hidden>

        Import macros from gnulib (often changing their name).

        * NEWS: AC_C_TYPE_LONG_DOUBLE is now obsolete.
        New macros AC_CHECK_DECLS_ONCE, AC_CHECK_FUNCS_ONCE,
        AC_CHECK_HEADERS_ONCE, AC_FUNC_STRTOLD, AC_HEADER_ASSERT,
        AC_STRUCT_DIRENT_D_INO, AC_STRUCT_DIRENT_D_TYPE,
        AC_TYPE_LONG_DOUBLE, AC_TYPE_LONG_DOUBLE_WIDER, AC_TYPE_INT8_T,
        AC_TYPE_INT16_T, AC_TYPE_INT32_T, AC_TYPE_INT64_T,
        AC_TYPE_INTMAX_T, AC_TYPE_INTPTR_T, AC_TYPE_LONG_LONG_INT,
        AC_TYPE_UINT8_T, AC_TYPE_UINT16_T, AC_TYPE_UINT32_T,
        AC_TYPE_UINT64_T, AC_TYPE_UINTMAX_T, AC_TYPE_UINTPTR_T,
        AC_TYPE_UNSIGNED_LONG_LONG_INT AC_C_TYPE_RANGE_INTEGER,
        AC_TYPE_RANGE_INT8_T, AC_TYPE_RANGE_INT16_T,
        AC_TYPE_RANGE_INT32_T, AC_TYPE_RANGE_INT64_T,
        AC_TYPE_RANGE_INTMAX_T, AC_TYPE_RANGE_INTPTR_T,
        AC_TYPE_RANGE_LONG_LONG_INT, AC_TYPE_RANGE_PTRDIFF_T,
        AC_TYPE_RANGE_SIZE_T, AC_TYPE_RANGE_UINT8_T,
        AC_TYPE_RANGE_UINT16_T, AC_TYPE_RANGE_UINT32_T,
        AC_TYPE_RANGE_UINT64_T, AC_TYPE_RANGE_UINTMAX_T,
        AC_TYPE_RANGE_UINTPTR_T, AC_TYPE_RANGE_UNSIGNED_LONG_LONG_INT,
        AC_USE_SYSTEM_EXTENSIONS.  The manual mentions Gnulib more
        prominently.
        * doc/autoconf.texi (Gnulib, Ranges of Particular Types):
        (Ranges of Integer Types): New nodes.
        (Pointers): Add Gnulib URL.
        (Particular Functions): Alphabetize.  Add AC_FUNC_STRTOLD.
        (Generic Functions): Add AC_CHECK_FUNCS_ONCE.  Refer to new
        Gnulib section.
        (Particular Headers): Add AC_HEADER_ASSERT.  For stdbool.h,
        suggest a #define rather than a typedef for _Bool, and mention
        Gnulib rather than trying to substitute stdbool code.
        (Generic Headers): Add AC_CHECK_HEADERS_ONCE.
        (Generic Declarations): Add AC_CHECK_DECLS_ONCE.
        (Particular Structures): Add AC_STRUCT_DIRENT_D_INO,
        AC_STRUCT_DIRENT_D_TYPE.
        (Particular Types): Mention stdint.h and inttypes.h as standard
        headers too.
        Add AC_TYPE_INT8_T, AC_TYPE_INT16_T, AC_TYPE_INT32_T, AC_TYPE_INT64_T,
        AC_TYPE_INTMAX_T, AC_TYPE_INTPTR_T, AC_TYPE_LONG_DOUBLE,
        AC_TYPE_LONG_DOUBLE_WIDER, AC_TYPE_LONG_LONG_INT, AC_TYPE_UINT8_T,
        AC_TYPE_UINT16_T, AC_TYPE_UINT32_T, AC_TYPE_UINT64_T, AC_TYPE_UINTMAX_T,
        AC_TYPE_UINTPTR_T, AC_TYPE_UNSIGNED_LONG_LONG_INT.
        (C Compiler): Move AC_C_LONG_DOUBLE to ...
        (Obsolete Macros): here.  Under AC_LONG_DOUBLE, mention
        AC_TYPE_LONG_DOUBLE or AC_TYPE_LONG_DOUBLE_WIDER instead.
        (Posix Variants): Add AC_USE_SYSTEM_EXTENSIONS.
        (Coding Style).  Don't mention m4_expand_once.
        * lib/autoconf/c.m4 (AC_C_LONG_DOUBLE): Implement via
        AC_TYPE_LONG_DOUBLE_WIDER.  Now obsolete.
        (_AC_C_TYPE_BITS_INTEGER, AC_C_TYPE_RANGE_INTEGER): New macros.
        * lib/autoconf/functions.m4 (_AH_CHECK_FUNCS): New macro.
        (AC_CHECK_FUNCS): Use it.
        (AC_CHECK_FUNCS_ONCE, AC_FUNC_STRTOLD): New macros.
        (AC_FUNC_WAIT3): "the Open Group standards" -> "POSIX".
        * lib/autoconf/general.m4 (AC_CHECK_DECLS_ONCE): New macro.
        * lib/autoconf/headers.m4 (AC_CHECK_HEADERS_ONCE): New macro.
        (AC_HEADER_ASSERT): New macro.
        (AC_HEADER_STDBOOL): Don't assume "#error" works.
        Catch a bug in IBM AIX xlc compiler version 6.0.0.0.
        Catch a bug in an HP-UX C compiler.
        * lib/autoconf/specific.m4 (AC_USE_SYSTEM_EXTENSIONS): New macro.
        * lib/autoconf/types.m4 (AC_TYPE_INTMAX_T. AC_TYPE_UINTMAX_T):
        (AC_TYPE_INTPTR_T, AC_TYPE_UINTPTR_T. AC_TYPE_LONG_DOUBLE):
        (AC_TYPE_LONG_DOUBLE_WIDER, AC_C_LONG_DOUBLE, AC_TYPE_LONG_LONG_INT):
        (AC_TYPE_UNSIGNED_LONG_LONG_INT, _AC_TYPE_INT, _AC_TYPE_UNSIGNED_INT):
        (_AC_TYPE_RANGE_INT, _AC_TYPE_RANGE_UNSIGNED_INT):
        (AC_TYPE_RANGE_PTRDIFF_T, AC_TYPE_RANGE_SIZE_T):
        (AC_TYPE_RANGE_LONG_LONG_INT, AC_TYPE_RANGE_UNSIGNED_LONG_LONG_INT):
        (AC_TYPE_RANGE_INT8_T, AC_TYPE_RANGE_INT16_T, AC_TYPE_RANGE_INT32_T):
        (AC_TYPE_RANGE_INT64_T, AC_TYPE_RANGE_UINT8_T, AC_TYPE_RANGE_UINT16_T):
        (AC_TYPE_RANGE_UINT32_T, AC_TYPE_RANGE_UINT64_T):
        (AC_TYPE_RANGE_INTPTR_T, AC_TYPE_RANGE_INTMAX_T):
        (AC_TYPE_RANGE_UINTPTR_T, AC_TYPE_RANGE_UINTMAX_T):
        (_AC_STRUCT_DIRENT, AC_STRUCT_DIRENT_D_INO, AC_STRUCT_DIRENT_D_TYPE):
        New macros.
        * tests/mktests.sh (ac_exclude_list): Exclude AC_C_TYPE_RANGE_INTEGER,
        since it has arguments.

Index: NEWS
===================================================================
RCS file: /cvsroot/autoconf/autoconf/NEWS,v
retrieving revision 1.354
diff -p -u -r1.354 NEWS
--- NEWS        20 Mar 2006 20:28:56 -0000      1.354
+++ NEWS        31 Mar 2006 19:40:03 -0000
@@ -35,6 +35,16 @@
 ** AC_C_TYPEOF
   New macro to check for support of 'typeof' syntax a la GNU C.
 
+** AC_CHECK_DECLS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_HEADERS_ONCE
+  New "once-only" variants of commonly-used macros, to make 'configure'
+  smaller and faster in common cases.
+
+** AC_FUNC_STRTOLD
+  New macro to check for strtold with C99 semantics.
+
+** AC_HEADER_ASSERT
+  New macro that lets builder disable assertions at 'configure'-time.
+
 ** AC_PATH_X
   Now checks for X11/Xlib.h and XrmInitialize (X proper) rather than
   X11/Intrinsic.h and XtMalloc (Xt).
@@ -50,6 +60,9 @@
   ac_cv_prog_cc_c99 or ac_cv_prog_cc_c89 (whichever is valid, in
   that order).
 
+** AC_STRUCT_DIRENT_D_INO, AC_STRUCT_DIRENT_D_TYPE
+  New macro for checking commonly-used members of struct dirent.
+
 ** AC_SUBST
   The subtituted value can now contain newlines.
 
@@ -57,6 +70,31 @@
   The substitution now occurs only when @variable@ is on a line by itself,
   optionally surrounded by spaces and tabs.  The whole line is replaced.
 
+** AC_TYPE_LONG_DOUBLE, AC_TYPE_LONG_DOUBLE_WIDER
+  New macros to check for long double, and whether it is wider than double.
+  The old macro AC_C_TYPE_LONG_DOUBLE has been marked as obsolete;
+  applications should switch to the new macro.
+
+** AC_TYPE_INT8_T, AC_TYPE_INT16_T, AC_TYPE_INT32_T, AC_TYPE_INT64_T,
+   AC_TYPE_INTMAX_T, AC_TYPE_INTPTR_T, AC_TYPE_LONG_LONG_INT, AC_TYPE_SSIZE_T,
+   AC_TYPE_UINT8_T, AC_TYPE_UINT16_T, AC_TYPE_UINT32_T, AC_TYPE_UINT64_T,
+   AC_TYPE_UINTMAX_T, AC_TYPE_UINTPTR_T, AC_TYPE_UNSIGNED_LONG_LONG_INT
+  New macros to check for C99 and POSIX types.
+
+** AC_C_TYPE_RANGE_INTEGER
+  New macro to check for the lower and upper bounds of C integer types.
+
+** AC_TYPE_RANGE_INT8_T, AC_TYPE_RANGE_INT16_T, AC_TYPE_RANGE_INT32_T,
+   AC_TYPE_RANGE_INT64_T, AC_TYPE_RANGE_INTMAX_T, AC_TYPE_RANGE_INTPTR_T,
+   AC_TYPE_RANGE_LONG_LONG_INT, AC_TYPE_RANGE_PTRDIFF_T, AC_TYPE_RANGE_SIZE_T,
+   AC_TYPE_RANGE_SSIZE_T, AC_TYPE_RANGE_UINT8_T, AC_TYPE_RANGE_UINT16_T,
+   AC_TYPE_RANGE_UINT32_T, AC_TYPE_RANGE_UINT64_T, AC_TYPE_RANGE_UINTMAX_T,
+   AC_TYPE_RANGE_UINTPTR_T, AC_TYPE_RANGE_UNSIGNED_LONG_LONG_INT
+  New macros to check for the lower and upper bounds of C99 types.
+
+** AC_USE_SYSTEM_EXTENSIONS
+  New macro to enable extensions to Posix.
+
 ** AH_HEADER
   New macro which is defined to the name of the first declared config header
   or undefined if no config headers have been declared yet.
@@ -87,6 +125,8 @@
   New macros for configuring installation of Erlang libraries:
   AC_ERLANG_SUBST_INSTALL_LIB_DIR, AC_ERLANG_SUBST_INSTALL_LIB_SUBDIR.
 
+** The manual now mentions Gnulib more prominently.
+
 ** New macros to support Objective C.
   AC_PROG_OBJC, AC_PROG_OBJCPP.
 
Index: doc/autoconf.texi
===================================================================
RCS file: /cvsroot/autoconf/autoconf/doc/autoconf.texi,v
retrieving revision 1.976
diff -p -u -r1.976 autoconf.texi
--- doc/autoconf.texi   31 Mar 2006 18:55:43 -0000      1.976
+++ doc/autoconf.texi   31 Mar 2006 19:40:04 -0000
@@ -279,6 +279,7 @@ published by the Free Software Foundatio
 The @acronym{GNU} Build System
 
 * Automake::                    Escaping Makefile hell
+* Gnulib::                      The @acronym{GNU} portability library
 * Libtool::                     Building libraries portably
 * Pointers::                    More info on the @acronym{GNU} build system
 
@@ -375,7 +376,9 @@ Structures
 Types
 
 * Particular Types::            Special handling to find certain types
+* Ranges of Particular Types::  Special handling to find ranges of certain 
types
 * Generic Types::               How to find other types
+* Ranges of Integer Types::     How to find ranges of other integer types
 
 Compilers and Preprocessors
 
@@ -708,6 +711,7 @@ entire @acronym{GNU} build system for yo
 
 @menu
 * Automake::                    Escaping Makefile hell
+* Gnulib::                      The @acronym{GNU} portability library
 * Libtool::                     Building libraries portably
 * Pointers::                    More info on the @acronym{GNU} build system
 @end menu
@@ -754,6 +758,32 @@ The benefits of Automake increase for la
 with subdirectories), but even for small programs the added convenience
 and portability can be substantial.  And that's not address@hidden
 
address@hidden Gnulib
address@hidden Gnulib
+
address@hidden software has a well-deserved reputation for running on
+many different types of systems.  While our primary goal is to write
+software for the @acronym{GNU} system, many users and developers have
+been introduced to us through the systems that they were already using.
+
address@hidden Gnulib
+Gnulib is a central location for common @acronym{GNU} code, intended to
+be shared among free software packages.  Its components are typically
+shared at the source level, rather than being a library that gets built,
+installed, and linked against.  The idea is to copy files from Gnulib
+into your own source tree.  There is no distribution tarball; developers
+should just grab source modules from the repository.  The source files
+are available online, under various licenses, mostly @acronym{GNU}
address@hidden or @acronym{GNU} @acronym{LGPL}.
+
+Gnulib modules typically contain C source code along with Autoconf
+macros used to configure the source code.  For example, the Gnulib
address@hidden module implements a @file{stdbool.h} header that nearly
+conforms to C99, even on old-fashioned hosts that lack @file{stdbool.h}.
+This module contains a source file for the replacement header, along
+with an Autoconf macro that arranges to use the replacement header on
+old-fashioned systems.
+
 @node Libtool
 @section Libtool
 
@@ -801,7 +831,8 @@ the @acronym{GNU} build tools.
 
 The home pages for
 @uref{http://www.gnu.org/software/autoconf/, Autoconf},
address@hidden://www.gnu.org/software/automake/, Automake}, and
address@hidden://www.gnu.org/software/automake/, Automake},
address@hidden://www.gnu.org/software/gnulib/, Gnulib}, and
 @uref{http://www.gnu.org/software/libtool/, Libtool}.
 
 @item Automake Manual
@@ -4532,17 +4563,6 @@ If the @code{strcoll} function exists an
 definitions of @code{strcoll} that should not be used.
 @end defmac
 
address@hidden AC_FUNC_STRTOD
address@hidden
address@hidden POW_LIB
address@hidden @fuindex strtod
address@hidden @code{strtod}
-If the @code{strtod} function does not exist or doesn't work correctly,
-ask for an @code{AC_LIBOBJ} replacement of @samp{strtod}.  In this case,
-because @file{strtod.c} is likely to need @samp{pow}, set the output
-variable @code{POW_LIB} to the extra library needed.
address@hidden defmac
-
 @defmac AC_FUNC_STRERROR_R
 @acindex{FUNC_STRERROR_R}
 @cvindex HAVE_STRERROR_R
@@ -4569,6 +4589,24 @@ Check for @code{strftime} in the @file{i
 Then, if @code{strftime} is available, define @code{HAVE_STRFTIME}.
 @end defmac
 
address@hidden AC_FUNC_STRTOD
address@hidden
address@hidden POW_LIB
address@hidden @fuindex strtod
address@hidden @code{strtod}
+If the @code{strtod} function does not exist or doesn't work correctly,
+ask for an @code{AC_LIBOBJ} replacement of @samp{strtod}.  In this case,
+because @file{strtod.c} is likely to need @samp{pow}, set the output
+variable @code{POW_LIB} to the extra library needed.
address@hidden defmac
+
address@hidden AC_FUNC_STRTOLD
address@hidden
address@hidden @code{strtold}
+If the @code{strtold} function exists and conforms to C99, define
address@hidden
address@hidden defmac
+
 @defmac AC_FUNC_STRNLEN
 @acindex{FUNC_STRNLEN}
 @cvindex HAVE_STRNLEN
@@ -4650,6 +4688,17 @@ execute when one of the functions is fou
 functions is not found.
 @end defmac
 
address@hidden AC_CHECK_FUNCS_ONCE (@address@hidden)
address@hidden
address@hidden address@hidden
+For each @var{function} enumerated in the blank-or-newline-separated argument
+list, define @address@hidden (in all capitals) if it is available.
+This is a once-only variant of @code{AC_CHECK_FUNCS}.  It generates the
+checking code at most once, so that @command{configure} is smaller and
+faster; but the checks cannot be conditionalized and are always done once,
+early during the @command{configure} run.
address@hidden defmac
+
 @sp 1
 
 Autoconf follows a philosophy that was formed over the years by those
@@ -4659,10 +4708,7 @@ environment.  Some functions may be miss
 package must be ready to replace them.
 
 Suitable replacements for many such problem functions are available from
address@hidden://www.gnu.org/software/gnulib/, Gnulib}, which aims to
-provide a centralized repository of such portability functions (among
-other things).  The source files are available online, under various
-licences, mostly @acronym{GNU} @acronym{GPL} or @acronym{GNU} @acronym{LGPL}.
+Gnulib (@pxref{Gnulib}).
 
 @defmac AC_LIBOBJ (@var{function})
 @acindex{LIBOBJ}
@@ -4775,6 +4821,12 @@ problems they cause.  By definition, thi
 additions.  Please help us keeping it as complete as possible.
 
 @table @asis
+
address@hidden @file{limits.h}
+C99 says that @file{limits.h} defines @code{LLONG_MIN},
address@hidden, and @code{ULLONG_MAX}, but many almost-C99
+environments (e.g., default GCC 4.0.2 + glibc 2.4) do not define them.
+
 @item @file{inttypes.h} vs.@: @file{stdint.h}
 @hdrindex{inttypes.h}
 @hdrindex{stdint.h}
@@ -4882,6 +4934,15 @@ AC_CHECK_HEADERS([X11/extensions/scrnsav
 These macros check for particular system header files---whether they
 exist, and in some cases whether they declare certain symbols.
 
address@hidden AC_HEADER_ASSERT
address@hidden
address@hidden NDEBUG
address@hidden
+Check whether to enable assertions in the style of @file{assert.h}.
+Assertions are enabled by default, but the user can override this by
+invoking @command{configure} with the @option{--disable-assert} option.
address@hidden defmac
+
 @defmac AC_HEADER_DIRENT
 @acindex{HEADER_DIRENT}
 @cvindex HAVE_DIRENT_H
@@ -4933,6 +4994,9 @@ the length of a directory entry name by 
 @code{struct dirent} to the @code{NAMLEN} macro.
 
 This macro also checks for the SCO Xenix @file{dir} and @file{x} libraries.
+
+Also see @code{AC_STRUCT_DIRENT_D_INO} and
address@hidden (@pxref{Particular Structures}).
 @end defmac
 
 @defmac AC_HEADER_MAJOR
@@ -4988,7 +5052,7 @@ Amdahl UTS and Motorola System V/88.
 @cvindex HAVE__BOOL
 @hdrindex{stdbool.h}
 @hdrindex{system.h}
-If @file{stdbool.h} exists and is conformant to C99, define
+If @file{stdbool.h} exists and conforms to C99, define
 @code{HAVE_STDBOOL_H} to 1; if the type @code{_Bool} is defined, define
 @code{HAVE__BOOL} to 1.  To fulfill the C99 requirements, your
 @file{system.h} could contain the following code:
@@ -5001,7 +5065,7 @@ If @file{stdbool.h} exists and is confor
 #  ifdef __cplusplus
 typedef bool _Bool;
 #  else
-typedef unsigned char _Bool;
+#   define _Bool signed char
 #  endif
 # endif
 # define bool _Bool
@@ -5011,37 +5075,10 @@ typedef unsigned char _Bool;
 #endif
 @end verbatim
 
-Alternatively you can construct an output variable that includes only
-those headers and definitions needed.  For example:
+Alternatively you can use the @samp{stdbool} package of Gnulib
+(@pxref{Gnulib}); it packages the above code into a replacement header
+and contains a few other bells and whistles.
 
address@hidden
-AC_HEADER_STDBOOL
-AC_SUBST([stdbool])
-if test "x$ac_cv_header_stdbool_h" = xyes; then
-  stdbool='
-#include <stdbool.h>
-'
-else
-  if test "x$ac_cv_type__Bool" != xyes; then
-    stdbool='
-#ifdef __cplusplus
-typedef bool _Bool;
-#else
-typedef unsigned char _Bool;
-#endif
-'
-  else
-    stdbool='
-'
-  fi
-  stdbool=$stdbool'
-#define bool _Bool
-#define false 0
-#define true 1
-#define __bool_true_false_are_defined 1
-'
-fi
address@hidden verbatim
 @end defmac
 
 
@@ -5292,6 +5329,21 @@ AC_CHECK_HEADERS([bar.h], [], [],
 ])
 @end verbatim
 
+The following variant generates smaller, faster @command{configure}
+files if you do not need the full power of @code{AC_CHECK_HEADERS}.
+
address@hidden AC_CHECK_HEADERS_ONCE (@address@hidden)
address@hidden
address@hidden address@hidden
+For each given system header file @var{header-file} in the
+blank-separated argument list that exists, define
address@hidden@var{header-file}} (in all capitals).
+This is a once-only variant of @code{AC_CHECK_HEADERS}.  It generates the
+checking code at most once, so that @command{configure} is smaller and
+faster; but the checks cannot be conditionalized and are always done once,
+early during the @command{configure} run.
address@hidden defmac
+
 @node Declarations
 @section Declarations
 @cindex Declaration, checking
@@ -5377,6 +5429,18 @@ your files may be used without being con
 the configuration.  In most cases the traditional approach is enough.
 @end defmac
 
address@hidden AC_CHECK_DECLS_ONCE (@var{symbols})
address@hidden
address@hidden address@hidden
+For each of the @var{symbols} (@emph{comma}-separated list), define
address@hidden@var{symbol}} (in all capitals) to @samp{1} if
address@hidden is declared in the default include files, otherwise to
address@hidden  This is a once-only variant of @code{AC_CHECK_DECLS}.  It
+generates the checking code at most once, so that @command{configure} is
+smaller and faster; but the checks cannot be conditionalized and are
+always done once, early during the @command{configure} run.
address@hidden defmac
+
 
 @node Structures
 @section Structures
@@ -5398,6 +5462,28 @@ member you need, then you can use the ge
 
 The following macros check for certain structures or structure members.
 
address@hidden AC_STRUCT_DIRENT_D_INO
address@hidden
address@hidden HAVE_STRUCT_DIRENT_D_INO
+Perform all the actions of @code{AC_HEADER_DIRENT} (@pxref{Particular
+Headers}).  Then, if @code{struct dirent} contains a @code{d_ino}
+member, define @code{HAVE_STRUCT_DIRENT_D_INO}.
+
address@hidden indicates only the presence of
address@hidden, not whether its contents are always reliable.
+Traditionally, a zero @code{d_ino} indicated a deleted directory entry,
+though modern systems hide this detail from the user and never return
+zero @code{d_ino} values.
address@hidden defmac
+
address@hidden AC_STRUCT_DIRENT_D_TYPE
address@hidden
address@hidden HAVE_STRUCT_DIRENT_D_TYPE
+Perform all the actions of @code{AC_HEADER_DIRENT} (@pxref{Particular
+Headers}).  Then, if @code{struct dirent} contains a @code{d_type}
+member, define @code{HAVE_STRUCT_DIRENT_D_TYPE}.
address@hidden defmac
+
 @defmac AC_STRUCT_ST_BLKSIZE
 @acindex{STRUCT_ST_BLKSIZE}
 @cvindex HAVE_STRUCT_STAT_ST_BLKSIZE
@@ -5513,7 +5599,9 @@ use a general type-check macro.
 
 @menu
 * Particular Types::            Special handling to find certain types
+* Ranges of Particular Types::  Special handling to find ranges of certain 
types
 * Generic Types::               How to find other types
+* Ranges of Integer Types::     How to find ranges of other integer types
 @end menu
 
 @node Particular Types
@@ -5521,8 +5609,15 @@ use a general type-check macro.
 
 @hdrindex{sys/types.h}
 @hdrindex{stdlib.h}
address@hidden
address@hidden
 These macros check for particular C types in @file{sys/types.h},
address@hidden and others, if they exist.
address@hidden, @file{stdint.h}, @file{inttypes.h} and others, if they
+exist.
+
+The Gnulib @code{stdint} module is an alternate way to define many of
+these symbols; it is useful if you prefer your code to assume a
+C99-or-better environment.  @xref{Gnulib}.
 
 @defmac AC_TYPE_GETGROUPS
 @acindex{TYPE_GETGROUPS}
@@ -5531,6 +5626,79 @@ Define @code{GETGROUPS_T} to be whicheve
 is the base type of the array argument to @code{getgroups}.
 @end defmac
 
address@hidden AC_TYPE_INT8_T
address@hidden
address@hidden HAVE_INT8_T
address@hidden int8_t
+If @file{stdint.h} or @file{inttypes.h} defines the type @code{int8_t},
+define @code{HAVE_INT8_T}.  Otherwise, define @code{int8_t} to a signed
+integer type that is exactly 8 bits wide and that uses two's complement
+representation, if such a type exists.
address@hidden defmac
+
address@hidden AC_TYPE_INT16_T
address@hidden
address@hidden HAVE_INT16_T
address@hidden int16_t
+This is like @code{AC_TYPE_INT8_T}, except for 16-bit integers.
address@hidden defmac
+
address@hidden AC_TYPE_INT32_T
address@hidden
address@hidden HAVE_INT32_T
address@hidden int32_t
+This is like @code{AC_TYPE_INT8_T}, except for 32-bit integers.
address@hidden defmac
+
address@hidden AC_TYPE_INT64_T
address@hidden
address@hidden HAVE_INT64_T
address@hidden int64_t
+This is like @code{AC_TYPE_INT8_T}, except for 64-bit integers.
address@hidden defmac
+
address@hidden AC_TYPE_INTMAX_T
address@hidden
address@hidden HAVE_INTMAX_T
address@hidden intmax_t
+If @file{stdint.h} or @file{inttypes.h} defines the type @code{intmax_t},
+define @code{HAVE_INTMAX_T}.  Otherwise, define @code{intmax_t} to the
+widest signed integer type.
address@hidden defmac
+
address@hidden AC_TYPE_INTPTR_T
address@hidden
address@hidden HAVE_INTPTR_T
address@hidden intptr_t
+If @file{stdint.h} or @file{inttypes.h} defines the type @code{intptr_t},
+define @code{HAVE_INTPTR_T}.  Otherwise, define @code{intptr_t} to a
+signed integer type wide enough to hold a pointer, if such a type
+exists.
address@hidden defmac
+
address@hidden AC_TYPE_LONG_DOUBLE
address@hidden
address@hidden HAVE_LONG_DOUBLE
+If the C compiler supports a working @code{long double} type, define
address@hidden  The @code{long double} type might have the
+same range and precision as @code{double}.
address@hidden defmac
+
address@hidden AC_TYPE_LONG_DOUBLE_WIDER
address@hidden
address@hidden HAVE_LONG_DOUBLE_WIDER
+If the C compiler supports a working @code{long double} type with more
+range or precision than the @code{double} type, define
address@hidden
address@hidden defmac
+
address@hidden AC_TYPE_LONG_LONG_INT
address@hidden
address@hidden HAVE_LONG_LONG_INT
+If the C compiler supports a working @code{long long int} type, define
address@hidden
address@hidden defmac
+
 @defmac AC_TYPE_MBSTATE_T
 @acindex{TYPE_MBSTATE_T}
 @cvindex mbstate_t
@@ -5585,6 +5753,12 @@ hup_handler ()
 Equivalent to @samp{AC_CHECK_TYPE([size_t], [unsigned int])}.
 @end defmac
 
address@hidden AC_TYPE_SSIZE_T
address@hidden
address@hidden ssize_t
+Equivalent to @samp{AC_CHECK_TYPE([ssize_t], [int])}.
address@hidden defmac
+
 @defmac AC_TYPE_UID_T
 @acindex{TYPE_UID_T}
 @cvindex uid_t
@@ -5593,6 +5767,205 @@ If @code{uid_t} is not defined, define @
 @code{gid_t} to be @code{int}.
 @end defmac
 
address@hidden AC_TYPE_UINT8_T
address@hidden
address@hidden HAVE_UINT8_T
address@hidden uint8_t
+If @file{stdint.h} or @file{inttypes.h} defines the type @code{uint8_t},
+define @code{HAVE_UINT8_T}.  Otherwise, define @code{uint8_t} to an
+unsigned integer type that is exactly 8 bits wide, if such a type
+exists.
address@hidden defmac
+
address@hidden AC_TYPE_UINT16_T
address@hidden
address@hidden HAVE_UINT16_T
address@hidden uint16_t
+This is like @code{AC_TYPE_UINT8_T}, except for 16-bit unsigned integers.
address@hidden defmac
+
address@hidden AC_TYPE_UINT32_T
address@hidden
address@hidden HAVE_UINT32_T
address@hidden uint32_t
+This is like @code{AC_TYPE_UINT8_T}, except for 32-bit unsigned integers.
address@hidden defmac
+
address@hidden AC_TYPE_UINT64_T
address@hidden
address@hidden HAVE_UINT64_T
address@hidden uint64_t
+This is like @code{AC_TYPE_UINT8_T}, except for 64-bit unsigned integers.
address@hidden defmac
+
address@hidden AC_TYPE_UINTMAX_T
address@hidden
address@hidden HAVE_UINTMAX_T
address@hidden uintmax_t
+If @file{stdint.h} or @file{inttypes.h} defines the type @code{uintmax_t},
+define @code{HAVE_UINTMAX_T}.  Otherwise, define @code{uintmax_t} to the
+widest unsigned integer type.
address@hidden defmac
+
address@hidden AC_TYPE_UINTPTR_T
address@hidden
address@hidden HAVE_UINTPTR_T
address@hidden uintptr_t
+If @file{stdint.h} or @file{inttypes.h} defines the type @code{uintptr_t},
+define @code{HAVE_UINTPTR_T}.  Otherwise, define @code{uintptr_t} to an
+unsigned integer type wide enough to hold a pointer, if such a type
+exists.
address@hidden defmac
+
address@hidden AC_TYPE_UNSIGNED_LONG_LONG_INT
address@hidden
address@hidden HAVE_UNSIGNED_LONG_LONG_INT
+If the C compiler supports a working @code{unsigned long long int} type,
+define @code{HAVE_UNSIGNED_LONG_LONG_INT}.
address@hidden defmac
+
address@hidden Ranges of Particular Types
address@hidden Checks for Ranges of Particular Types
+
address@hidden
address@hidden
+These macros check for ranges of particular C types in @file{limits.h},
address@hidden and @file{inttypes.h}.
+
+The Gnulib @code{stdint} module is an alternate way to define many of
+these symbols; it is useful if you prefer your code to assume a
+C99-or-better environment.  @xref{Gnulib}.
+
address@hidden AC_TYPE_RANGE_INT8_T
address@hidden
address@hidden INT8_MIN
address@hidden INT8_MAX
+Define @code{INT8_MIN} and @code{INT8_MAX} to the bounds of the type
address@hidden, if the standard headers do not define them, and if the
+type exists.
address@hidden defmac
+
address@hidden AC_TYPE_RANGE_INT16_T
address@hidden
address@hidden INT16_MIN
address@hidden INT16_MAX
+Like @code{AC_TYPE_RANGE_INT8_T}, except for 16-bit integers.
address@hidden defmac
+
address@hidden AC_TYPE_RANGE_INT32_T
address@hidden
address@hidden INT32_MIN
address@hidden INT32_MAX
+Like @code{AC_TYPE_RANGE_INT8_T}, except for 32-bit integers.
address@hidden defmac
+
address@hidden AC_TYPE_RANGE_INT64_T
address@hidden
address@hidden INT64_MIN
address@hidden INT64_MAX
+Like @code{AC_TYPE_RANGE_INT8_T}, except for 64-bit integers.
address@hidden defmac
+
address@hidden AC_TYPE_RANGE_INTMAX_T
address@hidden
address@hidden INTMAX_MIN
address@hidden INTMAX_MAX
+Define @code{INTMAX_MIN} and @code{INTMAX_MAX} to the bounds of the type
address@hidden, if the standard headers do not define them, and if the
+type exists.
address@hidden defmac
+
address@hidden AC_TYPE_RANGE_INTPTR_T
address@hidden
address@hidden INTPTR_MIN
address@hidden INTPTR_MAX
+Define @code{INTPTR_MIN} and @code{INTPTR_MAX} to the bounds of the type
address@hidden, if the standard headers do not define them, and if the
+type exists.
address@hidden defmac
+
address@hidden AC_TYPE_RANGE_LONG_LONG_INT
address@hidden
address@hidden LLONG_MAX
address@hidden LLONG_MIN
+Define @code{LLONG_MIN} and @code{LLONG_MAX} to the bounds of the type
address@hidden long int}, if the standard headers do not define them, and if
+the type exists.
address@hidden defmac
+
address@hidden AC_TYPE_RANGE_PTRDIFF_T
address@hidden
address@hidden PTRDIFF_MAX
address@hidden PTRDIFF_MIN
+Define @code{PTRDIFF_MIN} and @code{PTRDIFF_MAX} to the bounds of the
+type @code{ptrdiff_t}, if neither @file{stdint.h} nor @file{inttypes.h}
+defines them.
address@hidden defmac
+
address@hidden AC_TYPE_RANGE_SIZE_T
address@hidden
address@hidden SIZE_MAX
+Define @code{SIZE_MAX} to the upper bound of the type @code{size_t}, if
+neither @file{stdint.h} nor @file{inttypes.h} defines it.
address@hidden defmac
+
address@hidden AC_TYPE_RANGE_SSIZE_T
address@hidden
address@hidden SSIZE_MIN
address@hidden SSIZE_MAX
+Define @code{SSIZE_MIN} and @code{SSIZE_MAX} to the bounds of the
+type @code{ssize_t}, if @file{limits.h} does not define them.
address@hidden defmac
+
address@hidden AC_TYPE_RANGE_UINT8_T
address@hidden
address@hidden UINT8_MAX
+Define @code{UINT8_MAX} to the upper bound of the type @code{uint8_t},
+if the standard headers do not define the macro, and if the type exists.
address@hidden defmac
+
address@hidden AC_TYPE_RANGE_UINT16_T
address@hidden
address@hidden UINT16_MAX
+Like @code{AC_TYPE_RANGE_UINT8_T}, except for 16-bit unsigned integers.
address@hidden defmac
+
address@hidden AC_TYPE_RANGE_UINT32_T
address@hidden
address@hidden UINT32_MAX
+Like @code{AC_TYPE_RANGE_UINT8_T}, except for 32-bit unsigned integers.
address@hidden defmac
+
address@hidden AC_TYPE_RANGE_UINT64_T
address@hidden
address@hidden UINT64_MAX
+Like @code{AC_TYPE_RANGE_UINT8_T}, except for 64-bit unsigned integers.
address@hidden defmac
+
address@hidden AC_TYPE_RANGE_UINTMAX_T
address@hidden
address@hidden UINTMAX_MAX
+Define @code{UINTMAX_MAX} to the upper bound of the type
address@hidden, if the standard headers do not define the macro, and
+if the type exists.
address@hidden defmac
+
address@hidden AC_TYPE_RANGE_UINTPTR_T
address@hidden
address@hidden UINTPTR_MAX
+Define @code{UINTPTR_MAX} to the upper bound of the type
address@hidden, if the standard headers do not define the macro, and
+if the type exists.
address@hidden defmac
+
address@hidden AC_TYPE_RANGE_UNSIGNED_LONG_LONG_INT
address@hidden
address@hidden ULLONG_MAX
+Define @code{ULLONG_MAX} to the upper bound of the type @code{unsigned
+long long int}, if the standard headers do not define the macro, and if
+the type exists.
address@hidden defmac
+
 @node Generic Types
 @subsection Generic Type Checks
 
@@ -5629,6 +6002,22 @@ compatibility, a simple heuristics, quit
 implemented.  In case of doubt, read the documentation of the former
 @code{AC_CHECK_TYPE}, see @ref{Obsolete Macros}.
 
address@hidden Ranges of Integer Types
address@hidden Checks for Ranges of Integer Types
+
+This macro checks for ranges of integer types not covered by the
+``particular'' test macros.
+
address@hidden AC_C_TYPE_RANGE_INTEGER (@var{type}, @ovar{min-variable}, 
@var{max-variable}, @dvar{includes, default-includes})
address@hidden
+Compute the bounds of the integer @var{type} and define
address@hidden and @var{max-variable} to integer constant
+expressions that are suitable for use even in the preprocessor.  Do not
+define @var{min-variable} if it is absent.  Do not define either
+variable if it is already defined by @var{includes}, or if @var{type} is
+not a valid type.
address@hidden defmac
+
 
 @node Compilers and Preprocessors
 @section Compilers and Preprocessors
@@ -6029,14 +6418,6 @@ If the C type @code{char} is unsigned, d
 unless the C compiler predefines it.
 @end defmac
 
address@hidden AC_C_LONG_DOUBLE
address@hidden
address@hidden HAVE_LONG_DOUBLE
-If the C compiler supports a working @code{long double} type with more
-range or precision than the @code{double} type, define
address@hidden
address@hidden defmac
-
 @defmac AC_C_STRINGIZE
 @acindex{C_STRINGIZE}
 @cvindex HAVE_STRINGIZE
@@ -6727,6 +7108,23 @@ If on Minix, define @code{_MINIX} and @c
 facilities.  Should be called before any macros that run the C compiler.
 @end defmac
 
address@hidden AC_USE_SYSTEM_EXTENSIONS
address@hidden
address@hidden _ALL_SOURCE
address@hidden _GNU_SOURCE
address@hidden _MINIX
address@hidden _POSIX_1_SOURCE
address@hidden _POSIX_PTHREAD_SEMANTICS
address@hidden _POSIX_SOURCE
address@hidden __EXTENSIONS__
+If possible, enable extensions to Posix on hosts that normally disable
+the extensions, typically due to standards-conformance namespace issues.
+This may involve defining @code{__EXTENSIONS__} and
address@hidden, which are macros used by Solaris.  This
+macro also has the combined effects of @code{AC_GNU_SOURCE},
address@hidden, and @code{AC_MINIX}.
address@hidden defmac
+
 
 @node Erlang Libraries
 @section Erlang Libraries
@@ -9975,8 +10373,8 @@ by setting @address@hidden,
 But since there is a macro named @code{AC_SUBST_FILE}, it was just
 impossible to @samp{AC_SUBST(FILE)}!  In this case,
 @code{AC_SUBST(@var{symbol})} or @code{_AC_SUBST(@var{symbol})} should
-have been used (yes, with the parentheses)@dots{}or better yet, high-level
-macros such as @code{AC_EXPAND_ONCE}.
+have been used (yes, with the parentheses).
address@hidden or better yet, high-level macros such as @code{m4_expand_once}
 
 No Autoconf macro should ever enter the user-variable name space; i.e.,
 except for the variables that are the actual result of running the
@@ -14963,6 +15361,17 @@ removed because of limited usefulness
 This macro is obsolete; it does nothing.
 @end defmac
 
address@hidden AC_C_LONG_DOUBLE
address@hidden
address@hidden HAVE_LONG_DOUBLE
+If the C compiler supports a working @code{long double} type with more
+range or precision than the @code{double} type, define
address@hidden
+
+You should use @code{AC_TYPE_LONG_DOUBLE} or
address@hidden instead.  @xref{Particular Types}.
address@hidden defmac
+
 @defmac AC_CANONICAL_SYSTEM
 @acindex{CANONICAL_SYSTEM}
 Determine the system type and set output variables to the names of the
@@ -15347,7 +15756,12 @@ Use the generic macro @samp{AC_CHECK_SIZ
 
 @defmac AC_LONG_DOUBLE
 @acindex{LONG_DOUBLE}
address@hidden
+If the C compiler supports a working @code{long double} type with more
+range or precision than the @code{double} type, define
address@hidden
+
+You should use @code{AC_TYPE_LONG_DOUBLE} or
address@hidden instead.  @xref{Particular Types}.
 @end defmac
 
 @defmac AC_LONG_FILE_NAMES
Index: lib/autoconf/c.m4
===================================================================
RCS file: /cvsroot/autoconf/autoconf/lib/autoconf/c.m4,v
retrieving revision 1.213
diff -p -u -r1.213 c.m4
--- lib/autoconf/c.m4   20 Mar 2006 20:28:56 -0000      1.213
+++ lib/autoconf/c.m4   31 Mar 2006 19:40:04 -0000
@@ -1,4 +1,4 @@
-# This file is part of Autoconf.                       -*- Autoconf -*-
+# This file is part of Autoconf.                       -*- Autoconf -*-
 # Programming languages support.
 # Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006 Free Software
 # Foundation, Inc.
@@ -583,8 +583,8 @@ AC_CACHE_CHECK(whether $CC accepts -g, a
      [ac_cv_prog_cc_g=yes],
      [CFLAGS=""
       _AC_COMPILE_IFELSE([AC_LANG_PROGRAM()],
-        [],
-        [ac_c_werror_flag=$ac_save_c_werror_flag
+       [],
+       [ac_c_werror_flag=$ac_save_c_werror_flag
         CFLAGS="-g"
         _AC_COMPILE_IFELSE([AC_LANG_PROGRAM()],
           [ac_cv_prog_cc_g=yes])])])
@@ -811,8 +811,8 @@ AC_CACHE_CHECK(whether $CXX accepts -g, 
      [ac_cv_prog_cxx_g=yes],
      [CXXFLAGS=""
       _AC_COMPILE_IFELSE([AC_LANG_PROGRAM()],
-        [],
-        [ac_cxx_werror_flag=$ac_save_cxx_werror_flag
+       [],
+       [ac_cxx_werror_flag=$ac_save_cxx_werror_flag
         CXXFLAGS="-g"
         _AC_COMPILE_IFELSE([AC_LANG_PROGRAM()],
           [ac_cv_prog_cxx_g=yes])])])
@@ -865,9 +865,9 @@ do
 done
 rm -f conftest*
 if test -n "$ac_declaration"; then
-  echo '#ifdef __cplusplus' >>confdefs.h
-  echo $ac_declaration      >>confdefs.h
-  echo '#endif'             >>confdefs.h
+  echo '#ifdef __cplusplus'    >>confdefs.h
+  echo $ac_declaration         >>confdefs.h
+  echo '#endif'                        >>confdefs.h
 fi
 ])# _AC_PROG_CXX_EXIT_DECLARATION
 
@@ -980,8 +980,8 @@ AC_CACHE_CHECK(whether $OBJC accepts -g,
      [ac_cv_prog_objc_g=yes],
      [OBJCFLAGS=""
       _AC_COMPILE_IFELSE([AC_LANG_PROGRAM()],
-        [],
-        [ac_objc_werror_flag=$ac_save_objc_werror_flag
+       [],
+       [ac_objc_werror_flag=$ac_save_objc_werror_flag
         OBJCFLAGS="-g"
         _AC_COMPILE_IFELSE([AC_LANG_PROGRAM()],
           [ac_cv_prog_objc_g=yes])])])
@@ -1067,7 +1067,7 @@ char **argv;]],
 [[return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];]],
 dnl Don't try gcc -ansi; that turns off useful extensions and
 dnl breaks some systems' header files.
-dnl AIX circa 2003     -qlanglvl=extc89
+dnl AIX circa 2003     -qlanglvl=extc89
 dnl old AIX            -qlanglvl=ansi
 dnl Ultrix, OSF/1, Tru64       -std
 dnl HP-UX 10.20 and later      -Ae
@@ -1263,9 +1263,9 @@ AC_DEFUN([AC_PROG_CC_STDC],
       ;;
     *)
       if test "x$ac_cv_prog_cc_stdc" = x; then
-        AC_MSG_RESULT([none needed])
+       AC_MSG_RESULT([none needed])
       else
-        AC_MSG_RESULT([$ac_cv_prog_cc_stdc])
+       AC_MSG_RESULT([$ac_cv_prog_cc_stdc])
       fi
       ;;
   esac
@@ -1319,42 +1319,6 @@ fi
 ])# AC_C_CHAR_UNSIGNED
 
 
-# AC_C_LONG_DOUBLE
-# ----------------
-AC_DEFUN([AC_C_LONG_DOUBLE],
-[AC_CACHE_CHECK(
-   [for working long double with more range or precision than double],
-   [ac_cv_c_long_double],
-   [AC_COMPILE_IFELSE(
-      [AC_LANG_BOOL_COMPILE_TRY(
-        [[#include <float.h>
-          long double const a[] =
-            {
-               0.0L, DBL_MIN, DBL_MAX, DBL_EPSILON,
-               LDBL_MIN, LDBL_MAX, LDBL_EPSILON
-            };
-          long double
-          f (long double x)
-          {
-             return ((x + (unsigned long int) 10) * (-1 / x) + a[0]
-                      + (x ? f (x) : 'c'));
-          }
-        ]],
-        [[(0 < ((DBL_MAX_EXP < LDBL_MAX_EXP)
-                 + (DBL_MANT_DIG < LDBL_MANT_DIG)
-                 - (LDBL_MAX_EXP < DBL_MAX_EXP)
-                 - (LDBL_MANT_DIG < DBL_MANT_DIG)))
-          && (int) LDBL_EPSILON == 0
-         ]])],
-      ac_cv_c_long_double=yes,
-      ac_cv_c_long_double=no)])
-if test $ac_cv_c_long_double = yes; then
-  AC_DEFINE(HAVE_LONG_DOUBLE, 1,
-           [Define to 1 if long double works and has more range or precision 
than double.])
-fi
-])# AC_C_LONG_DOUBLE
-
-
 # AC_C_BIGENDIAN ([ACTION-IF-TRUE], [ACTION-IF-FALSE], [ACTION-IF-UNKNOWN])
 # -------------------------------------------------------------------------
 AC_DEFUN([AC_C_BIGENDIAN],
@@ -1670,3 +1634,132 @@ AC_DEFUN([AC_C_TYPEOF],
     fi
   fi
 ])
+
+
+# _AC_C_TYPE_BITS_INTEGER(TYPE, SIGNBITS, BITS-SHELLVAR,
+#                        [INCLUDES = DEFAULT-INCLUDES])
+# ------------------------------------------------------
+# Compute the number of bits in the integer type TYPE.
+# SIGNBITS should be 1 for a signed, type, 0 for unsigned.
+# The shell variable BITS-SHELLVAR should already be initialized
+# to a lower bound on the number of bits; store the
+# result back into BITS-SHELLVAR.
+# The type is either built in, or is defined in INCLUDES.
+AC_DEFUN([_AC_C_TYPE_BITS_INTEGER],
+[
+  # Double the number of bits until this fails.
+  while :; do
+    $3[]1=`expr $$3 '*' 2`
+    ac_max="((((($1) 1 << ($$3 - 1 - $2)) - 1) << 1) + 1)"
+    ac_max1="((((($1) 1 << ($$3[]1 - 1 - $2)) - 1) << 1) + 1)"
+    AC_COMPILE_IFELSE(
+      [AC_LANG_BOOL_COMPILE_TRY([AC_INCLUDES_DEFAULT([$4])],
+        [$ac_max < $ac_max1 && ($1) $ac_max1 == $ac_max1])],
+      [],
+      [break])
+    $3=$$3[]1
+  done
+
+  # Add 1 to the number of bits until this fails.
+  while :; do
+    $3[]1=`expr $$3 + 1`
+    ac_max="((((($1) 1 << ($$3 - 1 - $2)) - 1) << 1) + 1)"
+    ac_max1="((((($1) 1 << ($$3[]1 - 1 - $2)) - 1) << 1) + 1)"
+    AC_COMPILE_IFELSE(
+      [AC_LANG_BOOL_COMPILE_TRY([AC_INCLUDES_DEFAULT([$4])],
+        [$ac_max < $ac_max1 && ($1) $ac_max1 == $ac_max1])],
+      [],
+      [break])
+    $3=$$3[]1
+  done
+])# _AC_C_TYPE_BITS_INTEGER
+
+# AC_C_TYPE_RANGE_INTEGER(TYPE, [MIN-VARIABLE], MAX-VARIABLE,
+#                        [INCLUDES = DEFAULT-INCLUDES])
+# -----------------------------------------------------------
+# Compute the bounds of the integer TYPE and define MIN-VARIABLE and
+# MAX-VARIABLE to those bounds.  The bounds are expressions that are
+# suitable for use in the preprocessor.  If MIN-VARIABLE is absent, do
+# not define it.  If either variable is already defined by INCLUDES, do
+# not define it.  If TYPE does not work, do not define either variable.
+# Works OK if cross compiling.
+AC_DEFUN([AC_C_TYPE_RANGE_INTEGER],
+[
+  AC_CACHE_CHECK([for $3], [ac_cv_value_$3],
+    [ac_cv_value_$3=no
+     ac_signbits=
+     AC_COMPILE_IFELSE(
+       [AC_LANG_BOOL_COMPILE_TRY([AC_INCLUDES_DEFAULT([$4])], [($1) -1 < 0])],
+       [ac_signbits=1; ac_suffix=; ac_unsigned=],
+       [AC_COMPILE_IFELSE(
+         [AC_LANG_BOOL_COMPILE_TRY(
+            [AC_INCLUDES_DEFAULT([$4])], [0 < ($1) -1])],
+         [ac_signbits=0; ac_suffix=U; ac_unsigned=unsigned])])
+     if test -n "$ac_signbits"; then
+       AC_COMPILE_IFELSE(
+        [AC_LANG_BOOL_COMPILE_TRY([AC_INCLUDES_DEFAULT([$4])], [$3 == $3])],
+        [ac_cv_value_$3=yes],
+        [ac_1=1 ac_bits=8
+         for ac_type in \
+             "$ac_unsigned int" \
+             "$ac_unsigned long int" \
+             "$ac_unsigned long long int"; do
+           AC_COMPILE_IFELSE(
+             [AC_LANG_PROGRAM(
+                [$4
+                 extern $ac_type ac_$3;
+                 extern $1 ac_$3;],
+                [return !ac_$3;])],
+             [ac_1=1$ac_suffix
+              case $ac_type in #(
+              *'long long'*) ac_1=${ac_1}LL ac_bits=64;; #(
+              *long*) ac_1=${ac_1}L ac_bits=32;; #(
+              *) ac_bits=16;;
+              esac
+              break])
+         done
+
+         _AC_C_TYPE_BITS_INTEGER([$1], [$ac_signbits], [ac_bits], [$4])
+         ac_shift=`expr $ac_bits - 1 - $ac_signbits`
+         ac_cv_value_$3="(((($ac_1 << $ac_shift) - 1) << 1) + 1)"])
+     fi])
+
+  case $ac_cv_value_$3 in #(
+  yes|no) ;; #(
+  *)
+    AC_DEFINE_UNQUOTED([$3], [$ac_cv_value_$3],
+      [Define to the maximum value for the integer type `$1', if the
+       usual headers do not define $3 and if `$1' is a valid type.]);;
+  esac
+
+  m4_ifval([$2],
+    [AC_CACHE_CHECK([for $2], [ac_cv_value_$2],
+       [if test "$ac_cv_value_$3" = no; then
+         ac_cv_value_$2=no
+       else
+         AC_COMPILE_IFELSE(
+           [AC_LANG_BOOL_COMPILE_TRY([AC_INCLUDES_DEFAULT([$4])],
+              [$2 == $2])],
+           [ac_cv_value_$2=yes],
+           [ac_min='(- $3)'
+            ac_min1='(-1 - $3)'
+            AC_COMPILE_IFELSE(
+              [AC_LANG_BOOL_COMPILE_TRY([AC_INCLUDES_DEFAULT([$4])],
+                 [$ac_min1 < $ac_min && ($1) $ac_min1 == $ac_min1])],
+              [ac_min=$ac_min1],
+              [AC_COMPILE_IFELSE(
+                 [AC_LANG_BOOL_COMPILE_TRY([AC_INCLUDES_DEFAULT([$4])],
+                    [($1) -1 < 0])],
+                 [],
+                 [ac_min=0])])
+            ac_cv_value_$2=$ac_min])
+        fi])
+
+     case $ac_cv_value_$2 in #(
+     yes|no) ;; #(
+     *)
+       AC_DEFINE_UNQUOTED([$2], [$ac_cv_value_$2],
+        [Define to the minimum value for the integer type `$1', if the
+         usual headers do not define $2 and if `$1' is a valid type.]);;
+     esac])
+])# AC_C_TYPE_RANGE_INTEGER
Index: lib/autoconf/functions.m4
===================================================================
RCS file: /cvsroot/autoconf/autoconf/lib/autoconf/functions.m4,v
retrieving revision 1.96
diff -p -u -r1.96 functions.m4
--- lib/autoconf/functions.m4   3 Mar 2006 20:41:40 -0000       1.96
+++ lib/autoconf/functions.m4   31 Mar 2006 19:40:04 -0000
@@ -1,4 +1,4 @@
-# This file is part of Autoconf.                       -*- Autoconf -*-
+# This file is part of Autoconf.                       -*- Autoconf -*-
 # Checking for functions.
 # Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software
 # Foundation, Inc.
@@ -75,12 +75,18 @@ AS_VAR_POPDEF([ac_var])dnl
 ])# AC_CHECK_FUNC
 
 
+# _AH_CHECK_FUNCS(FUNCTION...)
+# ----------------------------
+m4_define([_AH_CHECK_FUNCS],
+[m4_foreach_w([AC_Func], [$1],
+   [AH_TEMPLATE(AS_TR_CPP([HAVE_]m4_defn([AC_Func])),
+      [Define to 1 if you have the `]m4_defn([AC_Func])[' function.])])])
+
+
 # AC_CHECK_FUNCS(FUNCTION..., [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
 # ---------------------------------------------------------------------
 AC_DEFUN([AC_CHECK_FUNCS],
-[m4_foreach_w([AC_Func], [$1],
-  [AH_TEMPLATE(AS_TR_CPP(HAVE_[]AC_Func),
-              [Define to 1 if you have the `]AC_Func[' function.])])dnl
+[_AH_CHECK_FUNCS([$1])dnl
 for ac_func in $1
 do
 AC_CHECK_FUNC($ac_func,
@@ -90,6 +96,26 @@ done
 ])
 
 
+# AC_CHECK_FUNCS_ONCE(FUNCTION...)
+# --------------------------------
+AC_DEFUN([AC_CHECK_FUNCS_ONCE],
+[
+  _AH_CHECK_FUNCS([$1])
+  m4_foreach_w([AC_Func], [$1],
+    [AC_DEFUN([_AC_Func_]m4_defn([AC_Func]),
+       [m4_divert_text([INIT_PREPARE],
+         [ac_func_list="$ac_func_list AC_Func"])
+       _AC_FUNCS_EXPANSION])
+     AC_REQUIRE([_AC_Func_]m4_defn([AC_Func]))])
+])
+m4_define([_AC_FUNCS_EXPANSION],
+[
+  m4_divert_text([DEFAULTS], [ac_func_list=])
+  AC_CHECK_FUNCS([$ac_func_list])
+  m4_define([_AC_FUNCS_EXPANSION], [])
+])
+
+
 # AC_REPLACE_FUNCS(FUNCTION...)
 # -----------------------------
 AC_DEFUN([AC_REPLACE_FUNCS],
@@ -1500,6 +1526,36 @@ fi
 ])
 
 
+# AC_FUNC_STRTOLD
+# ---------------
+AC_DEFUN([AC_FUNC_STRTOLD],
+[
+  AC_CACHE_CHECK([whether strtold conforms to C99],
+    [ac_cv_func_strtold],
+    [AC_COMPILE_IFELSE(
+       [AC_LANG_PROGRAM(
+         [[/* On HP-UX before 11.23, strtold returns a struct instead of
+               long double.  Reject implementations like that, by requiring
+               compatibility with the C99 prototype.  */
+#           include <stdlib.h>
+            static long double (*p) (char const *, char **) = strtold;
+            static long double
+            test (char const *nptr, char **endptr)
+            {
+              long double r;
+              r = strtold (nptr, endptr);
+              return r;
+            }]],
+          [[return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1;]])],
+       [ac_cv_func_strtold=yes],
+       [ac_cv_func_strtold=no])])
+  if test $ac_cv_func_strtold = yes; then
+    AC_DEFINE([HAVE_STRTOLD], 1,
+      [Define to 1 if strtold exists and conforms to C99.])
+  fi
+])# AC_FUNC_STRTOLD
+
+
 # AU::AM_FUNC_STRTOD
 # ------------------
 AU_ALIAS([AM_FUNC_STRTOD], [AC_FUNC_STRTOD])
@@ -1897,7 +1953,7 @@ AU_ALIAS([AC_VPRINTF], [AC_FUNC_VPRINTF]
 AN_FUNCTION([wait3], [AC_FUNC_WAIT3])
 AC_DEFUN([AC_FUNC_WAIT3],
 [AC_DIAGNOSE([obsolete],
-[$0: `wait3' is being removed from the Open Group standards.
+[$0: `wait3' has been removed from POSIX.
 Remove this `AC_FUNC_WAIT3' and adjust your code to use `waitpid' instead.])dnl
 AC_CACHE_CHECK([for wait3 that fills in rusage],
               [ac_cv_func_wait3_rusage],
Index: lib/autoconf/general.m4
===================================================================
RCS file: /cvsroot/autoconf/autoconf/lib/autoconf/general.m4,v
retrieving revision 1.891
diff -p -u -r1.891 general.m4
--- lib/autoconf/general.m4     16 Mar 2006 13:33:18 -0000      1.891
+++ lib/autoconf/general.m4     31 Mar 2006 19:40:04 -0000
@@ -558,8 +558,8 @@ AC_SUBST([localstatedir],  ['${prefix}/v
 AC_SUBST([includedir],     ['${prefix}/include'])dnl
 AC_SUBST([oldincludedir],  ['/usr/include'])dnl
 AC_SUBST([docdir],         [m4_ifset([AC_PACKAGE_TARNAME],
-                                     ['${datarootdir}/doc/${PACKAGE_TARNAME}'],
-                                     ['${datarootdir}/doc/${PACKAGE}'])])dnl
+                                    ['${datarootdir}/doc/${PACKAGE_TARNAME}'],
+                                    ['${datarootdir}/doc/${PACKAGE}'])])dnl
 AC_SUBST([infodir],        ['${datarootdir}/info'])dnl
 AC_SUBST([htmldir],        ['${docdir}'])dnl
 AC_SUBST([dvidir],         ['${docdir}'])dnl
@@ -1632,7 +1632,7 @@ test -d "$ac_macro_dir" ||
 # It announces FILE is required in the auxdir.
 m4_define([AC_REQUIRE_AUX_FILE],
 [AS_LITERAL_IF([$1], [],
-               [AC_FATAL([$0: requires a literal argument])])])
+              [AC_FATAL([$0: requires a literal argument])])])
 
 
 
@@ -2464,6 +2464,18 @@ $3],
 ])# AC_CHECK_DECLS
 
 
+# AC_CHECK_DECLS_ONCE(SYMBOLS)
+# ----------------------------
+# Like AC_CHECK_DECLS(SYMBOLS), but do it at most once.
+AC_DEFUN([AC_CHECK_DECLS_ONCE],
+[
+  m4_foreach([AC_Symbol], [$1],
+    [AC_DEFUN([_AC_Check_Decl_]m4_defn([AC_Symbol]),
+       [AC_CHECK_DECLS(m4_defn([AC_Symbol]))])
+     AC_REQUIRE([_AC_Check_Decl_]m4_defn([AC_Symbol]))])
+])
+
+
 
 ## ---------------------------------- ##
 ## Replacement of library functions.  ##
@@ -2542,8 +2554,8 @@ AC_SUBST([LTLIBOBJS], [$ac_ltlibobjs])
 ## ----------------------------------- ##
 
 
-# _AC_COMPUTE_INT_COMPILE(EXPRESSION, VARIABLE, [INCLUDES], [IF-FAILS])
-# ---------------------------------------------------------------------
+# _AC_COMPUTE_INT_COMPILE(EXPRESSION, VARIABLE, PROLOGUE, [IF-FAILS])
+# -------------------------------------------------------------------
 # Compute the integer EXPRESSION and store the result in the VARIABLE.
 # Works OK if cross compiling, but assumes twos-complement arithmetic.
 m4_define([_AC_COMPUTE_INT_COMPILE],
@@ -2586,15 +2598,15 @@ esac[]dnl
 ])# _AC_COMPUTE_INT_COMPILE
 
 
-# _AC_COMPUTE_INT_RUN(EXPRESSION, VARIABLE, [INCLUDES], [IF-FAILS])
-# -----------------------------------------------------------------
+# _AC_COMPUTE_INT_RUN(EXPRESSION, VARIABLE, PROLOGUE, [IF-FAILS])
+# ---------------------------------------------------------------
 # Store the evaluation of the integer EXPRESSION in VARIABLE.
 m4_define([_AC_COMPUTE_INT_RUN],
 [_AC_RUN_IFELSE([AC_LANG_INT_SAVE([$3], [$1])],
                [$2=`cat conftest.val`], [$4])])
 
 
-# _AC_COMPUTE_INT(EXPRESSION, VARIABLE, INCLUDES, IF-FAILS)
+# _AC_COMPUTE_INT(EXPRESSION, VARIABLE, PROLOGUE, IF-FAILS)
 # ---------------------------------------------------------
 m4_define([_AC_COMPUTE_INT],
 [AC_LANG_COMPILER_REQUIRE()dnl
Index: lib/autoconf/headers.m4
===================================================================
RCS file: /cvsroot/autoconf/autoconf/lib/autoconf/headers.m4,v
retrieving revision 1.45
diff -p -u -r1.45 headers.m4
--- lib/autoconf/headers.m4     24 Jan 2006 00:20:15 -0000      1.45
+++ lib/autoconf/headers.m4     31 Mar 2006 19:40:04 -0000
@@ -1,7 +1,7 @@
-# This file is part of Autoconf.                       -*- Autoconf -*-
+# This file is part of Autoconf.                       -*- Autoconf -*-
 # Checking for headers.
 #
-# Copyright (C) 2000, 2001, 2002, 2003, 2004, 2006 Free Software
+# Copyright (C) 1988, 1999, 2000, 2001, 2002, 2003, 2004, 2006 Free Software
 # Foundation, Inc.
 #
 # This program is free software; you can redistribute it and/or modify
@@ -65,8 +65,8 @@
 
 
 # AC_CHECK_HEADER(HEADER-FILE,
-#                 [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND],
-#                 [INCLUDES])
+#                [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND],
+#                [INCLUDES])
 # ---------------------------------------------------------
 # We are slowly moving to checking headers with the compiler instead
 # of the preproc, so that we actually learn about the usability of a
@@ -93,9 +93,9 @@ AC_DEFUN([AC_CHECK_HEADER],
 
 
 # _AC_CHECK_HEADER_MONGREL(HEADER-FILE,
-#                          [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND],
-#                          [INCLUDES])
-# --------------------------------------------------------------
+#                         [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND],
+#                         [INCLUDES = DEFAULT-INCLUDES])
+# ------------------------------------------------------------------
 # Check using both the compiler and the preprocessor.  If they disagree,
 # warn, and the preproc wins.
 #
@@ -152,8 +152,8 @@ AS_VAR_POPDEF([ac_Header])dnl
 
 
 # _AC_CHECK_HEADER_NEW(HEADER-FILE,
-#                      [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND],
-#                      [INCLUDES])
+#                     [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND],
+#                     [INCLUDES = DEFAULT-INCLUDES])
 # --------------------------------------------------------------
 # Check the compiler accepts HEADER-FILE.  The INCLUDES are defaulted.
 m4_define([_AC_CHECK_HEADER_NEW],
@@ -169,7 +169,7 @@ AS_VAR_POPDEF([ac_Header])dnl
 
 
 # _AC_CHECK_HEADER_OLD(HEADER-FILE,
-#                      [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
+#                     [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
 # --------------------------------------------------------------
 # Check the preprocessor accepts HEADER-FILE.
 m4_define([_AC_CHECK_HEADER_OLD],
@@ -187,13 +187,13 @@ AS_VAR_POPDEF([ac_Header])dnl
 # --------------------------------
 m4_define([AH_CHECK_HEADERS],
 [m4_foreach_w([AC_Header], [$1],
-  [AH_TEMPLATE(AS_TR_CPP(HAVE_[]AC_Header),
-              [Define to 1 if you have the <]AC_Header[> header file.])])])
+  [AH_TEMPLATE(AS_TR_CPP([HAVE_]m4_defn([AC_Header])),
+     [Define to 1 if you have the <]m4_defn([AC_Header])[> header file.])])])
 
 
-# AC_CHECK_HEADERS(HEADER-FILE...
-#                  [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND],
-#                  [INCLUDES])
+# AC_CHECK_HEADERS(HEADER-FILE...,
+#                 [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND],
+#                 [INCLUDES])
 # ----------------------------------------------------------
 AC_DEFUN([AC_CHECK_HEADERS],
 [AH_CHECK_HEADERS([$1])dnl
@@ -207,6 +207,26 @@ done
 ])# AC_CHECK_HEADERS
 
 
+# AC_CHECK_HEADERS_ONCE(HEADER-FILE...)
+# -------------------------------------
+AC_DEFUN([AC_CHECK_HEADERS_ONCE],
+[
+  AH_CHECK_HEADERS([$1])
+  m4_foreach_w([AC_Header], [$1],
+    [AC_DEFUN([_AC_Header_]m4_quote(m4_translit(AC_Header, [./-], [___])),
+       [m4_divert_text([INIT_PREPARE],
+         [ac_header_list="$ac_header_list AC_Header"])
+       _AC_HEADERS_EXPANSION])
+     AC_REQUIRE([_AC_Header_]m4_quote(m4_translit(AC_Header, [./-], [___])))])
+])
+m4_define([_AC_HEADERS_EXPANSION],
+[
+  m4_divert_text([DEFAULTS], [ac_header_list=])
+  AC_CHECK_HEADERS([$ac_header_list])
+  m4_define([_AC_HEADERS_EXPANSION], [])
+])
+
+
 
 
 ## --------------------- ##
@@ -357,9 +377,22 @@ AN_HEADER([wctype.h],           [AC_CHEC
 ## 4. Tests for specific headers.  ##
 ## ------------------------------- ##
 
+# AC_HEADER_ASSERT
+# ----------------
+# Check whether to enable assertions.
+AC_DEFUN([AC_HEADER_ASSERT],
+[
+  AC_MSG_CHECKING([whether to enable assertions])
+  AC_ARG_ENABLE([assert],
+    [  --disable-assert        turn off assertions],
+    [AC_MSG_RESULT([no])
+     AC_DEFINE(NDEBUG, 1, [Define to 1 if assertions should be disabled.])],
+    [AC_MSG_RESULT(yes)])
+])
+
 
 # _AC_CHECK_HEADER_DIRENT(HEADER-FILE,
-#                         [ACTION-IF-FOUND], [ACTION-IF-NOT_FOUND])
+#                        [ACTION-IF-FOUND], [ACTION-IF-NOT_FOUND])
 # -----------------------------------------------------------------
 # Like AC_CHECK_HEADER, except also make sure that HEADER-FILE
 # defines the type `DIR'.  dirent.h on NextStep 3.2 doesn't.
@@ -529,22 +562,22 @@ AC_DEFUN([AC_HEADER_STDBOOL],
       [[
 #include <stdbool.h>
 #ifndef bool
-# error bool is not defined
+ "error: bool is not defined"
 #endif
 #ifndef false
-# error false is not defined
+ "error: false is not defined"
 #endif
 #if false
-# error false is not 0
+ "error: false is not 0"
 #endif
 #ifndef true
-# error true is not defined
+ "error: true is not defined"
 #endif
 #if true != 1
-# error true is not 1
+ "error: true is not 1"
 #endif
 #ifndef __bool_true_false_are_defined
-# error __bool_true_false_are_defined is not defined
+ "error: __bool_true_false_are_defined is not defined"
 #endif
 
        struct s { _Bool s: 1; _Bool t; } s;
@@ -561,10 +594,39 @@ AC_DEFUN([AC_HEADER_STDBOOL],
        enum { j = false, k = true, l = false * true, m = true * 256 };
        _Bool n[m];
        char o[sizeof n == m * sizeof n[0] ? 1 : -1];
+       char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
+#      if defined __xlc__ || defined __GNUC__
+        /* Catch a bug in IBM AIX xlc compiler version 6.0.0.0
+           reported by James Lemley on 2005-10-05; see
+           
http://lists.gnu.org/archive/html/bug-coreutils/2005-10/msg00086.html
+           This test is not quite right, since xlc is allowed to
+           reject this program, as the initializer for xlcbug is
+           not one of the forms that C requires support for.
+           However, doing the test right would require a run-time
+           test, and that would make cross-compilation harder.
+           Let us hope that IBM fixes the xlc bug, and also adds
+           support for this kind of constant expression.  In the
+           meantime, this test will reject xlc, which is OK, since
+           our stdbool.h substitute should suffice.  We also test
+           this with GCC, where it should work, to detect more
+           quickly whether someone messes up the test in the
+           future.  */
+        char digs[] = "0123456789";
+        int xlcbug = 1 / (&(digs + 5)[-2 + (bool) 1] == &digs[4] ? 1 : -1);
+#      endif
+       /* Catch a bug in an HP-UX C compiler.  See
+          http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
+          http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
+        */
+       _Bool q = true;
+       _Bool *pq = &q;
       ]],
       [[
-        return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !j + !k + !l
-                + !m + !n + !o);
+       *pq |= q;
+       *pq |= ! q;
+       /* Refer to every declared value, to avoid compiler optimizations.  */
+       return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
+               + !m + !n + !o + !p + !q + !pq);
       ]])],
       [ac_cv_header_stdbool_h=yes],
       [ac_cv_header_stdbool_h=no])])
Index: lib/autoconf/specific.m4
===================================================================
RCS file: /cvsroot/autoconf/autoconf/lib/autoconf/specific.m4,v
retrieving revision 1.363
diff -p -u -r1.363 specific.m4
--- lib/autoconf/specific.m4    24 Jan 2006 00:20:15 -0000      1.363
+++ lib/autoconf/specific.m4    31 Mar 2006 19:40:04 -0000
@@ -1,4 +1,4 @@
-# This file is part of Autoconf.                       -*- Autoconf -*-
+# This file is part of Autoconf.                       -*- Autoconf -*-
 # Macros that test for specific, unclassified, features.
 #
 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@@ -123,19 +123,19 @@ m4_define([_AC_SYS_LARGEFILE_TEST_INCLUD
 
 
 # _AC_SYS_LARGEFILE_MACRO_VALUE(C-MACRO, VALUE,
-#                               CACHE-VAR,
-#                               DESCRIPTION,
-#                               [INCLUDES], [FUNCTION-BODY])
+#                              CACHE-VAR,
+#                              DESCRIPTION,
+#                              PROLOGUE, [FUNCTION-BODY])
 # ----------------------------------------------------------
 m4_define([_AC_SYS_LARGEFILE_MACRO_VALUE],
 [AC_CACHE_CHECK([for $1 value needed for large files], [$3],
 [while :; do
   $3=no
   AC_COMPILE_IFELSE([AC_LANG_PROGRAM([$5], [$6])],
-                   [break])
+                   [break])
   AC_COMPILE_IFELSE([AC_LANG_PROGRAM(address@hidden:@define $1 $2
 $5], [$6])],
-                   [$3=$2; break])
+                   [$3=$2; break])
   break
 done])
 if test "$$3" != no; then
@@ -162,12 +162,12 @@ if test "$enable_largefile" != no; then
      if test "$GCC" != yes; then
        ac_save_CC=$CC
        while :; do
-        # IRIX 6.2 and later do not support large files by default,
-        # so use the C compiler's -n32 option if that helps.
+        # IRIX 6.2 and later do not support large files by default,
+        # so use the C compiler's -n32 option if that helps.
         AC_LANG_CONFTEST([AC_LANG_PROGRAM([_AC_SYS_LARGEFILE_TEST_INCLUDES])])
-        AC_COMPILE_IFELSE([], [break])
-        CC="$CC -n32"
-        AC_COMPILE_IFELSE([], [ac_cv_sys_largefile_CC=' -n32'; break])
+        AC_COMPILE_IFELSE([], [break])
+        CC="$CC -n32"
+        AC_COMPILE_IFELSE([], [ac_cv_sys_largefile_CC=' -n32'; break])
         break
        done
        CC=$ac_save_CC
@@ -379,6 +379,41 @@ esac
 matches *mingw32*])# AC_MINGW32
 
 
+# AC_USE_SYSTEM_EXTENSIONS
+# ------------------------
+# Enable extensions on systems that normally disable them,
+# typically due to standards-conformance issues.
+AC_DEFUN([AC_USE_SYSTEM_EXTENSIONS],
+[
+  AC_BEFORE([$0], [AC_COMPILE_IFELSE])
+  AC_BEFORE([$0], [AC_RUN_IFELSE])
+
+  AC_REQUIRE([AC_GNU_SOURCE])
+  AC_REQUIRE([AC_AIX])
+  AC_REQUIRE([AC_MINIX])
+
+  AH_VERBATIM([__EXTENSIONS__],
+[/* Enable extensions on Solaris.  */
+#ifndef __EXTENSIONS__
+# undef __EXTENSIONS__
+#endif
+#ifndef _POSIX_PTHREAD_SEMANTICS
+# undef _POSIX_PTHREAD_SEMANTICS
+#endif])
+  AC_CACHE_CHECK([whether it is safe to define __EXTENSIONS__],
+    [ac_cv_safe_to_define___extensions__],
+    [AC_COMPILE_IFELSE(
+       [AC_LANG_PROGRAM([
+#        define __EXTENSIONS__ 1
+         AC_INCLUDES_DEFAULT])],
+       [ac_cv_safe_to_define___extensions__=yes],
+       [ac_cv_safe_to_define___extensions__=no])])
+  test $ac_cv_safe_to_define___extensions__ = yes &&
+    AC_DEFINE([__EXTENSIONS__])
+  AC_DEFINE([_POSIX_PTHREAD_SEMANTICS])
+])
+
+
 
 
 ## -------------------------- ##
Index: lib/autoconf/types.m4
===================================================================
RCS file: /cvsroot/autoconf/autoconf/lib/autoconf/types.m4,v
retrieving revision 1.34
diff -p -u -r1.34 types.m4
--- lib/autoconf/types.m4       11 Mar 2006 13:22:42 -0000      1.34
+++ lib/autoconf/types.m4       31 Mar 2006 19:40:05 -0000
@@ -1,6 +1,8 @@
-# This file is part of Autoconf.                       -*- Autoconf -*-
+# This file is part of Autoconf.                       -*- Autoconf -*-
 # Type related macros: existence, sizeof, and structure members.
-# Copyright (C) 2000, 2001, 2002, 2004, 2005 Free Software Foundation, Inc.
+#
+# Copyright (C) 2000, 2001, 2002, 2004, 2005, 2006 Free Software
+# Foundation, Inc.
 #
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -65,8 +67,8 @@
 # AC_CHECK_ families:
 #
 #    AC_CHECK_TYPE(TYPE,
-#                 [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND],
-#                 [INCLUDES])
+#                 [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND],
+#                 [INCLUDES = DEFAULT-INCLUDES])
 #
 # In order to provide backward compatibility, the new scheme is
 # implemented as _AC_CHECK_TYPE_NEW, the old scheme as _AC_CHECK_TYPE_OLD,
@@ -139,7 +141,7 @@
 # (not necessarily size_t etc.).  Equally, instead of defining an unused
 # variable, we just use a cast to avoid warnings from the compiler.
 # Suggested by Paul Eggert.
-# 
+#
 # Now, the next issue is that C++ disallows defining types inside casts
 # and inside `sizeof()', but we would like to allow unnamed structs, for
 # use inside AC_CHECK_SIZEOF, for example.  So we create a typedef of the
@@ -162,8 +164,8 @@ AS_VAR_POPDEF([ac_Type])dnl
 
 
 # AC_CHECK_TYPES(TYPES,
-#                [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND],
-#                [INCLUDES = DEFAULT-INCLUDES])
+#               [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND],
+#               [INCLUDES = DEFAULT-INCLUDES])
 # --------------------------------------------------------
 # TYPES is an m4 list.  There are no ambiguities here, we mean the newer
 # AC_CHECK_TYPE.
@@ -217,16 +219,16 @@ m4_define([_AC_CHECK_TYPE_MAYBE_TYPE_P],
 # AC_CHECK_TYPE(TYPE, DEFAULT)
 #  or
 # AC_CHECK_TYPE(TYPE,
-#              [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND],
-#              [INCLUDES = DEFAULT-INCLUDES])
+#              [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND],
+#              [INCLUDES = DEFAULT-INCLUDES])
 # -------------------------------------------------------
 #
 # Dispatch respectively to _AC_CHECK_TYPE_OLD or _AC_CHECK_TYPE_NEW.
-# 1. More than two arguments         => NEW
+# 1. More than two arguments        => NEW
 # 2. $2 seems to be replacement type => OLD
 #    See _AC_CHECK_TYPE_REPLACEMENT_TYPE_P for `replacement type'.
-# 3. $2 seems to be a type           => NEW plus a warning
-# 4. default                         => NEW
+# 3. $2 seems to be a type          => NEW plus a warning
+# 4. default                        => NEW
 AC_DEFUN([AC_CHECK_TYPE],
 [m4_if($#, 3,
         [_AC_CHECK_TYPE_NEW($@)],
@@ -304,6 +306,202 @@ AU_DEFUN([AM_TYPE_PTRDIFF_T],
 [AC_CHECK_TYPES(ptrdiff_t)])
 
 
+# AC_TYPE_INTMAX_T
+# -----------------
+AC_DEFUN([AC_TYPE_INTMAX_T],
+[
+  AC_REQUIRE([AC_TYPE_LONG_LONG_INT])
+  AC_CHECK_TYPE([intmax_t],
+    [AC_DEFINE([HAVE_INTMAX_T], 1,
+       [Define to 1 if the system has the type `intmax_t'.])],
+    [test $ac_cv_type_long_long_int = yes \
+       && ac_type='long long int' \
+       || ac_type='long int'
+     AC_DEFINE_UNQUOTED([intmax_t], [$ac_type],
+       [Define to the widest signed integer type
+       if <stdint.h> and <inttypes.h> do not define.])])
+])
+
+
+# AC_TYPE_UINTMAX_T
+# -----------------
+AC_DEFUN([AC_TYPE_UINTMAX_T],
+[
+  AC_REQUIRE([AC_TYPE_UNSIGNED_LONG_LONG_INT])
+  AC_CHECK_TYPE([uintmax_t],
+    [AC_DEFINE([HAVE_UINTMAX_T], 1,
+       [Define to 1 if the system has the type `uintmax_t'.])],
+    [test $ac_cv_type_unsigned_long_long_int = yes \
+       && ac_type='unsigned long long int' \
+       || ac_type='unsigned long int'
+     AC_DEFINE_UNQUOTED([uintmax_t], [$ac_type],
+       [Define to the widest unsigned integer type
+       if <stdint.h> and <inttypes.h> do not define.])])
+])
+
+
+# AC_TYPE_INTPTR_T
+# -----------------
+AC_DEFUN([AC_TYPE_INTPTR_T],
+[
+  AC_CHECK_TYPE([intptr_t],
+    [AC_DEFINE([HAVE_INTPTR_T], 1,
+       [Define to 1 if the system has the type `intptr_t'.])],
+    [for ac_type in 'int' 'long int' 'long long int'; do
+       AC_COMPILE_IFELSE(
+        [AC_LANG_BOOL_COMPILE_TRY(
+           [AC_INCLUDES_DEFAULT],
+           [[sizeof (void *) <= sizeof ($ac_type)]])],
+        [AC_DEFINE_UNQUOTED([intptr_t], [$ac_type],
+           [Define to the type of a signed integer type wide enough to
+            hold a pointer, if such a type exists, and if the system
+            does not define it.])
+         break])
+     done])
+])
+
+
+# AC_TYPE_UINTPTR_T
+# -----------------
+AC_DEFUN([AC_TYPE_UINTPTR_T],
+[
+  AC_CHECK_TYPE([uintptr_t],
+    [AC_DEFINE([HAVE_UINTPTR_T], 1,
+       [Define to 1 if the system has the type `uintptr_t'.])],
+    [for ac_type in 'unsigned int' 'unsigned long int' \
+       'unsigned long long int'; do
+       AC_COMPILE_IFELSE(
+        [AC_LANG_BOOL_COMPILE_TRY(
+           [AC_INCLUDES_DEFAULT],
+           [[sizeof (void *) <= sizeof ($ac_type)]])],
+        [AC_DEFINE_UNQUOTED([uintptr_t], [$ac_type],
+           [Define to the type of an unsigned integer type wide enough to
+            hold a pointer, if such a type exists, and if the system
+            does not define it.])
+         break])
+     done])
+])
+
+
+# AC_TYPE_LONG_DOUBLE
+# -------------------
+AC_DEFUN([AC_TYPE_LONG_DOUBLE],
+[
+  AC_CACHE_CHECK([for long double], [ac_cv_type_long_double],
+    [if test "$GCC" = yes; then
+       ac_cv_type_long_double=yes
+     else
+       AC_COMPILE_IFELSE(
+        [AC_LANG_BOOL_COMPILE_TRY(
+           [[/* The Stardent Vistra knows sizeof (long double), but does
+                not support it.  */
+             long double foo = 0.0L;]],
+           [[/* On Ultrix 4.3 cc, long double is 4 and double is 8.  */
+             sizeof (double) <= sizeof (long double)]])],
+        [ac_cv_type_long_double=yes],
+        [ac_cv_type_long_double=no])
+     fi])
+  if test $ac_cv_type_long_double = yes; then
+    AC_DEFINE([HAVE_LONG_DOUBLE], 1,
+      [Define to 1 if the system has the type `long double'.])
+  fi
+])
+
+
+# AC_TYPE_LONG_DOUBLE_WIDER
+# -------------------------
+AC_DEFUN([AC_TYPE_LONG_DOUBLE_WIDER],
+[
+  AC_CACHE_CHECK(
+    [for long double with more range or precision than double],
+    [ac_cv_type_long_double_wider],
+    [AC_COMPILE_IFELSE(
+       [AC_LANG_BOOL_COMPILE_TRY(
+         [[#include <float.h>
+           long double const a[] =
+             {
+                0.0L, DBL_MIN, DBL_MAX, DBL_EPSILON,
+                LDBL_MIN, LDBL_MAX, LDBL_EPSILON
+             };
+           long double
+           f (long double x)
+           {
+              return ((x + (unsigned long int) 10) * (-1 / x) + a[0]
+                       + (x ? f (x) : 'c'));
+           }
+         ]],
+         [[(0 < ((DBL_MAX_EXP < LDBL_MAX_EXP)
+                  + (DBL_MANT_DIG < LDBL_MANT_DIG)
+                  - (LDBL_MAX_EXP < DBL_MAX_EXP)
+                  - (LDBL_MANT_DIG < DBL_MANT_DIG)))
+           && (int) LDBL_EPSILON == 0
+         ]])],
+       ac_cv_type_long_double_wider=yes,
+       ac_cv_type_long_double_wider=no)])
+  if test $ac_cv_type_long_double_wider = yes; then
+    AC_DEFINE([HAVE_LONG_DOUBLE_WIDER], 1,
+      [Define to 1 if the type `long double' works and has more range or
+       precision than `double'.])
+  fi
+])# AC_TYPE_LONG_DOUBLE_WIDER
+
+
+# AC_C_LONG_DOUBLE
+# ----------------
+AU_DEFUN([AC_C_LONG_DOUBLE],
+  [
+    AC_TYPE_LONG_DOUBLE_WIDER
+    ac_cv_c_long_double=$ac_cv_type_long_double_wider
+    if test $ac_cv_c_long_double = yes; then
+      AC_DEFINE([HAVE_LONG_DOUBLE], 1,
+       [Define to 1 if the type `long double' works and has more range or
+        precision than `double'.])
+    fi
+  ],
+  [The macro `AC_C_LONG_DOUBLE' is obsolete.
+You should use `AC_TYPE_LONG_DOUBLE' or `AC_TYPE_LONG_DOUBLE_WIDER' instead.]
+)
+
+
+# AC_TYPE_LONG_LONG_INT
+# ---------------------
+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 = 1LL; int i = 63;],
+         [long long int llmax = (long long int) -1;
+          return 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
+])
+
+
+# AC_TYPE_UNSIGNED_LONG_LONG_INT
+# ------------------------------
+AC_DEFUN([AC_TYPE_UNSIGNED_LONG_LONG_INT],
+[
+  AC_CACHE_CHECK([for unsigned long long int],
+    [ac_cv_type_unsigned_long_long_int],
+    [AC_LINK_IFELSE(
+       [AC_LANG_PROGRAM(
+         [unsigned long long int ull = 1ULL; int i = 63;],
+         [unsigned long long int ullmax = (unsigned long long int) -1;
+          return ull << i | ull >> i | ullmax / ull | ullmax % ull;])],
+       [ac_cv_type_unsigned_long_long_int=yes],
+       [ac_cv_type_unsigned_long_long_int=no])])
+  if test $ac_cv_type_unsigned_long_long_int = yes; then
+    AC_DEFINE([HAVE_UNSIGNED_LONG_LONG_INT], 1,
+      [Define to 1 if the system has the type `unsigned long long int'.])
+  fi
+])
+
+
 # AC_TYPE_MBSTATE_T
 # -----------------
 AC_DEFUN([AC_TYPE_MBSTATE_T],
@@ -343,6 +541,9 @@ fi
 AN_IDENTIFIER([size_t], [AC_TYPE_SIZE_T])
 AC_DEFUN([AC_TYPE_SIZE_T], [AC_CHECK_TYPE(size_t, unsigned int)])
 
+AN_IDENTIFIER([ssize_t], [AC_TYPE_SSIZE_T])
+AC_DEFUN([AC_TYPE_SSIZE_T], [AC_CHECK_TYPE(ssize_t, int)])
+
 AN_IDENTIFIER([pid_t], [AC_TYPE_PID_T])
 AC_DEFUN([AC_TYPE_PID_T],  [AC_CHECK_TYPE(pid_t,  int)])
 
@@ -352,6 +553,102 @@ AC_DEFUN([AC_TYPE_OFF_T],  [AC_CHECK_TYP
 AN_IDENTIFIER([mode_t], [AC_TYPE_MODE_T])
 AC_DEFUN([AC_TYPE_MODE_T], [AC_CHECK_TYPE(mode_t, int)])
 
+AN_IDENTIFIER([int8_t], [AC_TYPE_INT8_T])
+AN_IDENTIFIER([int16_t], [AC_TYPE_INT16_T])
+AN_IDENTIFIER([int32_t], [AC_TYPE_INT32_T])
+AN_IDENTIFIER([int64_t], [AC_TYPE_INT64_T])
+AN_IDENTIFIER([uint8_t], [AC_TYPE_UINT8_T])
+AN_IDENTIFIER([uint16_t], [AC_TYPE_UINT16_T])
+AN_IDENTIFIER([uint32_t], [AC_TYPE_UINT32_T])
+AN_IDENTIFIER([uint64_t], [AC_TYPE_UINT64_T])
+AC_DEFUN([AC_TYPE_INT8_T], [_AC_TYPE_INT(8)])
+AC_DEFUN([AC_TYPE_INT16_T], [_AC_TYPE_INT(16)])
+AC_DEFUN([AC_TYPE_INT32_T], [_AC_TYPE_INT(32)])
+AC_DEFUN([AC_TYPE_INT64_T], [_AC_TYPE_INT(64)])
+AC_DEFUN([AC_TYPE_UINT8_T], [_AC_TYPE_UNSIGNED_INT(8)])
+AC_DEFUN([AC_TYPE_UINT16_T], [_AC_TYPE_UNSIGNED_INT(16)])
+AC_DEFUN([AC_TYPE_UINT32_T], [_AC_TYPE_UNSIGNED_INT(32)])
+AC_DEFUN([AC_TYPE_UINT64_T], [_AC_TYPE_UNSIGNED_INT(64)])
+
+# _AC_TYPE_INT(NBITS)
+# -------------------
+AC_DEFUN([_AC_TYPE_INT],
+[
+  AC_CACHE_CHECK([for int$1_t], [ac_cv_c_int$1_t],
+    [ac_cv_c_int$1_t=no
+     for ac_type in 'int$1_t' 'int' 'long int' \
+        'long long int' 'short int' 'signed char' 'char'; do
+       AC_COMPILE_IFELSE(
+        [AC_LANG_BOOL_COMPILE_TRY(
+           [AC_INCLUDES_DEFAULT],
+           [[0 < ($ac_type) 1 << ($1 - 2)]])],
+        [AC_COMPILE_IFELSE(
+           [AC_LANG_BOOL_COMPILE_TRY(
+              [AC_INCLUDES_DEFAULT],
+              [[0 < ($ac_type) 1 << ($1 - 1)]])],
+           [],
+           [ac_cv_c_int$1_t=$ac_type; break])])
+     done])
+  case $ac_cv_c_int$1_t in #(
+  no|int$1_t) ;; #(
+  *)
+    AC_DEFINE_UNQUOTED([int$1_t], [$ac_cv_c_int$1_t],
+      [Define to the type of a signed integer type of width exactly $1 bits
+       if such a type exists and the standard includes do not define it.]);;
+  esac
+])# _AC_TYPE_INT
+
+# _AC_TYPE_UNSIGNED_INT(NBITS)
+# ----------------------------
+AC_DEFUN([_AC_TYPE_UNSIGNED_INT],
+[
+  AC_CACHE_CHECK([for uint$1_t], [ac_cv_c_uint$1_t],
+    [ac_cv_c_uint$1_t=no
+     for ac_type in 'uint$1_t' 'unsigned int' 'unsigned long int' \
+        'unsigned long long int' 'unsigned short int' 'unsigned char'; do
+       AC_COMPILE_IFELSE(
+        [AC_LANG_BOOL_COMPILE_TRY(
+           [AC_INCLUDES_DEFAULT],
+           [[($ac_type) -1 >> ($1 - 1) == 1]])],
+        [ac_cv_c_uint$1_t=$ac_type; break])
+     done])
+  case $ac_cv_c_uint$1_t in #(
+  no|uint$1_t) ;; #(
+  *)
+    m4_if([$1], 32,
+      [AC_DEFINE([_UINT$1_T], 1,
+        [Define for Solaris 2.5.1 so the uint$1_t typedef from
+         <sys/synch.h>, <pthread.h>, or <semaphore.h> is not used.
+         If the typedef was allowed, the #define below would cause a
+         syntax error.])])
+    AC_DEFINE_UNQUOTED([uint$1_t], [$ac_cv_c_uint$1_t],
+      [Define to the type of an unsigned integer type of width exactly $1 bits
+       if such a type exists and the standard includes do not define it.]);;
+  esac
+])# _AC_TYPE_UNSIGNED_INT
+
+# _AC_TYPE_RANGE_INT(INTSPEC)
+# ---------------------------
+AC_DEFUN([_AC_TYPE_RANGE_INT],
+[
+  case $ac_cv_c_int$1_t in #(
+  no) ;; #(
+  *)
+    AC_C_TYPE_RANGE_INTEGER([int$1_t],
+      AS_TR_CPP([INT$1_MIN]),
+      AS_TR_CPP([INT$1_MAX]));;
+  esac
+])
+
+# _AC_TYPE_RANGE_UNSIGNED_INT(INTSPEC)
+# ------------------------------------
+AC_DEFUN([_AC_TYPE_RANGE_UNSIGNED_INT],
+[
+  case $ac_cv_c_uint$1_t in #(
+  no) ;; #(
+  *) AC_C_TYPE_RANGE_INTEGER([uint$1_t], [], AS_TR_CPP([UINT$1_MAX]));;
+  esac
+])
 
 # AC_TYPE_SIGNAL
 # --------------
@@ -458,6 +755,69 @@ test $ac_cv_sizeof_long_int = 8 &&
 you adjust the code.])
 
 
+## -------------------------- ##
+## Checks for bounds of types ##
+## -------------------------- ##
+
+# AC_TYPE_RANGE_PTRDIFF_T
+# -----------------------
+AC_DEFUN([AC_TYPE_RANGE_PTRDIFF_T],
+  [AC_C_TYPE_RANGE_INTEGER([ptrdiff_t], [PTRDIFF_MIN], [PTRDIFF_MAX])])
+
+
+# AC_TYPE_RANGE_SIZE_T
+# --------------------
+AC_DEFUN([AC_TYPE_RANGE_SIZE_T],
+  [AC_C_TYPE_RANGE_INTEGER([size_t], [], [SIZE_MAX])])
+
+
+# AC_TYPE_RANGE_SSIZE_T
+# --------------------
+AC_DEFUN([AC_TYPE_RANGE_SSIZE_T],
+  [AC_C_TYPE_RANGE_INTEGER([ssize_t], [SSIZE_MIN], [SSIZE_MAX])])
+
+
+# AC_TYPE_RANGE_LONG_LONG_INT
+# ---------------------------
+AC_DEFUN([AC_TYPE_RANGE_LONG_LONG_INT],
+  [AC_C_TYPE_RANGE_INTEGER([long long int], [LLONG_MIN], [LLONG_MAX],
+     [#include <limits.h>])])
+
+
+# AC_TYPE_RANGE_UNSIGNED_LONG_LONG_INT
+# ------------------------------------
+AC_DEFUN([AC_TYPE_RANGE_UNSIGNED_LONG_LONG_INT],
+  [AC_C_TYPE_RANGE_INTEGER([unsigned long long int], [], [ULLONG_MAX],
+     [#include <limits.h>])])
+
+# Likewise for the usual suspects in <stdint.h>.
+
+AC_DEFUN([AC_TYPE_RANGE_INT8_T],
+  [AC_REQUIRE([AC_TYPE_INT8_T])_AC_TYPE_RANGE_INT(8)])
+AC_DEFUN([AC_TYPE_RANGE_INT16_T],
+  [AC_REQUIRE([AC_TYPE_INT16_T])_AC_TYPE_RANGE_INT(16)])
+AC_DEFUN([AC_TYPE_RANGE_INT32_T],
+  [AC_REQUIRE([AC_TYPE_INT32_T])_AC_TYPE_RANGE_INT(32)])
+AC_DEFUN([AC_TYPE_RANGE_INT64_T],
+  [AC_REQUIRE([AC_TYPE_INT64_T])_AC_TYPE_RANGE_INT(64)])
+AC_DEFUN([AC_TYPE_RANGE_UINT8_T],
+  [AC_REQUIRE([AC_TYPE_UINT8_T])_AC_TYPE_RANGE_UNSIGNED_INT(8)])
+AC_DEFUN([AC_TYPE_RANGE_UINT16_T],
+  [AC_REQUIRE([AC_TYPE_UINT16_T])_AC_TYPE_RANGE_UNSIGNED_INT(16)])
+AC_DEFUN([AC_TYPE_RANGE_UINT32_T],
+  [AC_REQUIRE([AC_TYPE_UINT32_T])_AC_TYPE_RANGE_UNSIGNED_INT(32)])
+AC_DEFUN([AC_TYPE_RANGE_UINT64_T],
+  [AC_REQUIRE([AC_TYPE_UINT64_T])_AC_TYPE_RANGE_UNSIGNED_INT(64)])
+
+AC_DEFUN([AC_TYPE_RANGE_INTPTR_T],
+  [AC_REQUIRE([AC_TYPE_INTPTR_T])_AC_TYPE_RANGE_INT(ptr)])
+AC_DEFUN([AC_TYPE_RANGE_INTMAX_T],
+  [AC_REQUIRE([AC_TYPE_INTMAX_T])_AC_TYPE_RANGE_INT(max)])
+AC_DEFUN([AC_TYPE_RANGE_UINTPTR_T],
+  [AC_REQUIRE([AC_TYPE_UINTPTR_T])_AC_TYPE_RANGE_UNSIGNED_INT(ptr)])
+AC_DEFUN([AC_TYPE_RANGE_UINTMAX_T],
+  [AC_REQUIRE([AC_TYPE_UINTMAX_T])_AC_TYPE_RANGE_UNSIGNED_INT(max)])
+
 
 ## -------------------------- ##
 ## Generic structure checks.  ##
@@ -469,8 +829,8 @@ you adjust the code.])
 # ---------------- #
 
 # AC_CHECK_MEMBER(AGGREGATE.MEMBER,
-#                 [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND],
-#                 [INCLUDES])
+#                [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND],
+#                [INCLUDES = DEFAULT-INCLUDES])
 # ---------------------------------------------------------
 # AGGREGATE.MEMBER is for instance `struct passwd.pw_gecos', shell
 # variables are not a valid argument.
@@ -503,8 +863,8 @@ AS_VAR_POPDEF([ac_Member])dnl
 
 
 # AC_CHECK_MEMBERS([AGGREGATE.MEMBER, ...],
-#                  [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]
-#                  [INCLUDES])
+#                 [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]
+#                 [INCLUDES = DEFAULT-INCLUDES])
 # ---------------------------------------------------------
 # The first argument is an m4 list.
 AC_DEFUN([AC_CHECK_MEMBERS],
@@ -530,6 +890,40 @@ AN_IDENTIFIER([st_rdev],    [AC_CHECK_ME
 
 # Alphabetic order, please.
 
+# _AC_STRUCT_DIRENT(MEMBER)
+# -------------------------
+AC_DEFUN([_AC_STRUCT_DIRENT],
+[
+  AC_REQUIRE([AC_HEADER_DIRENT])
+  AC_CHECK_MEMBERS([struct dirent.$1], [], [],
+    [
+#include <sys/types.h>
+#ifdef HAVE_DIRENT_H
+# include <dirent.h>
+#else
+# define dirent direct
+# ifdef HAVE_SYS_NDIR_H
+#  include <sys/ndir.h>
+# endif
+# ifdef HAVE_SYS_DIR_H
+#  include <sys/dir.h>
+# endif
+# ifdef HAVE_NDIR_H
+#  include <ndir.h>
+# endif
+#endif
+    ])
+])
+
+# AC_STRUCT_DIRENT_D_INO
+# -----------------------------------
+AC_DEFUN([AC_STRUCT_DIRENT_D_INO], [_AC_STRUCT_DIRENT([d_ino])])
+
+# AC_STRUCT_DIRENT_D_TYPE
+# ------------------------------------
+AC_DEFUN([AC_STRUCT_DIRENT_D_TYPE], [_AC_STRUCT_DIRENT([d_type])])
+
+
 # AC_STRUCT_ST_BLKSIZE
 # --------------------
 AU_DEFUN([AC_STRUCT_ST_BLKSIZE],
@@ -553,7 +947,7 @@ the `AC_DEFINE' when you adjust the code
 #
 # AC_OBSOLETE([$0], [; replace it with
 #   AC_CHECK_MEMBERS([struct stat.st_blocks],
-#                     [AC_LIBOBJ([fileblocks])])
+#                    [AC_LIBOBJ([fileblocks])])
 # Please note that it will define `HAVE_STRUCT_STAT_ST_BLOCKS',
 # and not `HAVE_ST_BLOCKS'.])dnl
 #
Index: lib/autoscan/autoscan.list
===================================================================
RCS file: /cvsroot/autoconf/autoconf/lib/autoscan/autoscan.list,v
retrieving revision 1.12
diff -p -u -r1.12 autoscan.list
--- lib/autoscan/autoscan.list  21 Mar 2006 17:50:11 -0000      1.12
+++ lib/autoscan/autoscan.list  31 Mar 2006 19:40:05 -0000
@@ -253,6 +253,10 @@ identifier: const          AC_C_CONST
 identifier: false              AC_HEADER_STDBOOL
 identifier: gid_t              AC_TYPE_UID_T
 identifier: inline             AC_C_INLINE
+identifier: int16_t            AC_TYPE_INT16_T
+identifier: int32_t            AC_TYPE_INT32_T
+identifier: int64_t            AC_TYPE_INT64_T
+identifier: int8_t             AC_TYPE_INT8_T
 identifier: mode_t             AC_TYPE_MODE_T
 identifier: obstack            AC_FUNC_OBSTACK
 identifier: off_t              AC_TYPE_OFF_T
@@ -260,6 +264,7 @@ identifier: pid_t           AC_TYPE_PID_T
 identifier: ptrdiff_t          AC_CHECK_TYPES
 identifier: restrict           AC_C_RESTRICT
 identifier: size_t             AC_TYPE_SIZE_T
+identifier: ssize_t            AC_TYPE_SSIZE_T
 identifier: st_blksize         AC_CHECK_MEMBERS([struct stat.st_blksize])
 identifier: st_blocks          AC_STRUCT_ST_BLOCKS
 identifier: st_rdev            AC_CHECK_MEMBERS([struct stat.st_rdev])
@@ -269,6 +274,10 @@ identifier: tm             AC_STRUCT_TM
 identifier: tm_zone            AC_STRUCT_TIMEZONE
 identifier: true               AC_HEADER_STDBOOL
 identifier: uid_t              AC_TYPE_UID_T
+identifier: uint16_t           AC_TYPE_UINT16_T
+identifier: uint32_t           AC_TYPE_UINT32_T
+identifier: uint64_t           AC_TYPE_UINT64_T
+identifier: uint8_t            AC_TYPE_UINT8_T
 identifier: volatile           AC_C_VOLATILE
 makevar: AWK           AC_PROG_AWK
 makevar: BISON         AC_PROG_YACC
Index: tests/acc.at
===================================================================
RCS file: /cvsroot/autoconf/autoconf/tests/acc.at,v
retrieving revision 1.12
diff -p -u -r1.12 acc.at
--- tests/acc.at        30 Mar 2006 19:52:19 -0000      1.12
+++ tests/acc.at        31 Mar 2006 19:40:05 -0000
@@ -12,7 +12,6 @@ AT_BANNER([Testing autoconf/c macros.])
 AT_CHECK_MACRO([AC_C_BACKSLASH_A])
 AT_CHECK_MACRO([AC_C_BIGENDIAN])
 AT_CHECK_MACRO([AC_C_CHAR_UNSIGNED])
-AT_CHECK_MACRO([AC_C_LONG_DOUBLE])
 AT_CHECK_MACRO([AC_C_STRINGIZE])
 AT_CHECK_MACRO([AC_C_TYPEOF])
 AT_CHECK_MACRO([AC_PROG_CC_C89])
Index: tests/acfunctions.at
===================================================================
RCS file: /cvsroot/autoconf/autoconf/tests/acfunctions.at,v
retrieving revision 1.17
diff -p -u -r1.17 acfunctions.at
--- tests/acfunctions.at        3 Jan 2005 07:42:44 -0000       1.17
+++ tests/acfunctions.at        31 Mar 2006 19:40:05 -0000
@@ -9,6 +9,7 @@
 AT_BANNER([Testing autoconf/functions macros.])
 
 # Modern macros.
+AT_CHECK_MACRO([AC_CHECK_FUNCS_ONCE])
 AT_CHECK_MACRO([AC_FUNC_CHOWN])
 AT_CHECK_MACRO([AC_FUNC_CLOSEDIR_VOID])
 AT_CHECK_MACRO([AC_FUNC_ERROR_AT_LINE])
@@ -34,6 +35,7 @@ AT_CHECK_MACRO([AC_FUNC_STRERROR_R])
 AT_CHECK_MACRO([AC_FUNC_STRFTIME])
 AT_CHECK_MACRO([AC_FUNC_STRNLEN])
 AT_CHECK_MACRO([AC_FUNC_STRTOD])
+AT_CHECK_MACRO([AC_FUNC_STRTOLD])
 AT_CHECK_MACRO([AC_FUNC_UTIME_NULL])
 AT_CHECK_MACRO([AC_FUNC_VPRINTF])
 
Index: tests/acgeneral.at
===================================================================
RCS file: /cvsroot/autoconf/autoconf/tests/acgeneral.at,v
retrieving revision 1.13
diff -p -u -r1.13 acgeneral.at
--- tests/acgeneral.at  1 Jun 2005 06:36:25 -0000       1.13
+++ tests/acgeneral.at  31 Mar 2006 19:40:05 -0000
@@ -13,6 +13,7 @@ AT_CHECK_MACRO([AC_ARG_ENABLE])
 AT_CHECK_MACRO([AC_ARG_PROGRAM])
 AT_CHECK_MACRO([AC_ARG_WITH])
 AT_CHECK_MACRO([AC_CANONICAL_TARGET])
+AT_CHECK_MACRO([AC_CHECK_DECLS_ONCE])
 AT_CHECK_MACRO([AC_EGREP_CPP])
 AT_CHECK_MACRO([AC_EGREP_HEADER])
 AT_CHECK_MACRO([AC_PREFIX_DEFAULT])
Index: tests/acheaders.at
===================================================================
RCS file: /cvsroot/autoconf/autoconf/tests/acheaders.at,v
retrieving revision 1.9
diff -p -u -r1.9 acheaders.at
--- tests/acheaders.at  3 Jan 2005 07:42:44 -0000       1.9
+++ tests/acheaders.at  31 Mar 2006 19:40:05 -0000
@@ -9,6 +9,8 @@
 AT_BANNER([Testing autoconf/headers macros.])
 
 # Modern macros.
+AT_CHECK_MACRO([AC_CHECK_HEADERS_ONCE])
+AT_CHECK_MACRO([AC_HEADER_ASSERT])
 AT_CHECK_MACRO([AC_HEADER_MAJOR])
 AT_CHECK_MACRO([AC_HEADER_RESOLV])
 AT_CHECK_MACRO([AC_HEADER_STAT])
Index: tests/acspecific.at
===================================================================
RCS file: /cvsroot/autoconf/autoconf/tests/acspecific.at,v
retrieving revision 1.13
diff -p -u -r1.13 acspecific.at
--- tests/acspecific.at 3 Jan 2005 07:42:44 -0000       1.13
+++ tests/acspecific.at 31 Mar 2006 19:40:05 -0000
@@ -9,13 +9,12 @@
 AT_BANNER([Testing autoconf/specific macros.])
 
 # Modern macros.
-AT_CHECK_MACRO([AC_AIX])
 AT_CHECK_MACRO([AC_ISC_POSIX])
-AT_CHECK_MACRO([AC_MINIX])
 AT_CHECK_MACRO([AC_SYS_INTERPRETER])
 AT_CHECK_MACRO([AC_SYS_LARGEFILE])
 AT_CHECK_MACRO([AC_SYS_LONG_FILE_NAMES])
 AT_CHECK_MACRO([AC_SYS_POSIX_TERMIOS])
+AT_CHECK_MACRO([AC_USE_SYSTEM_EXTENSIONS])
 
 # Obsolete macros.
 AT_CHECK_AU_MACRO([AC_ARG_ARRAY])
Index: tests/actypes.at
===================================================================
RCS file: /cvsroot/autoconf/autoconf/tests/actypes.at,v
retrieving revision 1.7
diff -p -u -r1.7 actypes.at
--- tests/actypes.at    3 Jan 2005 07:42:44 -0000       1.7
+++ tests/actypes.at    31 Mar 2006 19:40:05 -0000
@@ -9,13 +9,36 @@
 AT_BANNER([Testing autoconf/types macros.])
 
 # Modern macros.
+AT_CHECK_MACRO([AC_STRUCT_DIRENT_D_INO])
+AT_CHECK_MACRO([AC_STRUCT_DIRENT_D_TYPE])
 AT_CHECK_MACRO([AC_STRUCT_ST_BLOCKS])
 AT_CHECK_MACRO([AC_STRUCT_TIMEZONE])
+AT_CHECK_MACRO([AC_TYPE_LONG_DOUBLE])
+AT_CHECK_MACRO([AC_TYPE_LONG_DOUBLE_WIDER])
 AT_CHECK_MACRO([AC_TYPE_MODE_T])
 AT_CHECK_MACRO([AC_TYPE_OFF_T])
+AT_CHECK_MACRO([AC_TYPE_RANGE_INT16_T])
+AT_CHECK_MACRO([AC_TYPE_RANGE_INT32_T])
+AT_CHECK_MACRO([AC_TYPE_RANGE_INT64_T])
+AT_CHECK_MACRO([AC_TYPE_RANGE_INT8_T])
+AT_CHECK_MACRO([AC_TYPE_RANGE_INTMAX_T])
+AT_CHECK_MACRO([AC_TYPE_RANGE_INTPTR_T])
+AT_CHECK_MACRO([AC_TYPE_RANGE_LONG_LONG_INT])
+AT_CHECK_MACRO([AC_TYPE_RANGE_PTRDIFF_T])
+AT_CHECK_MACRO([AC_TYPE_RANGE_SIZE_T])
+AT_CHECK_MACRO([AC_TYPE_RANGE_SSIZE_T])
+AT_CHECK_MACRO([AC_TYPE_RANGE_UINT16_T])
+AT_CHECK_MACRO([AC_TYPE_RANGE_UINT32_T])
+AT_CHECK_MACRO([AC_TYPE_RANGE_UINT64_T])
+AT_CHECK_MACRO([AC_TYPE_RANGE_UINT8_T])
+AT_CHECK_MACRO([AC_TYPE_RANGE_UINTMAX_T])
+AT_CHECK_MACRO([AC_TYPE_RANGE_UINTPTR_T])
+AT_CHECK_MACRO([AC_TYPE_RANGE_UNSIGNED_LONG_LONG_INT])
 AT_CHECK_MACRO([AC_TYPE_SIGNAL])
+AT_CHECK_MACRO([AC_TYPE_SSIZE_T])
 
 # Obsolete macros.
+AT_CHECK_AU_MACRO([AC_C_LONG_DOUBLE])
 AT_CHECK_AU_MACRO([AC_INT_16_BITS])
 AT_CHECK_AU_MACRO([AC_LONG_64_BITS])
 AT_CHECK_AU_MACRO([AC_STRUCT_ST_BLKSIZE])
Index: tests/mktests.sh
===================================================================
RCS file: /cvsroot/autoconf/autoconf/tests/mktests.sh,v
retrieving revision 1.44
diff -p -u -r1.44 mktests.sh
--- tests/mktests.sh    6 Mar 2006 21:13:22 -0000       1.44
+++ tests/mktests.sh    31 Mar 2006 19:40:05 -0000
@@ -81,7 +81,7 @@ exclude_list='^ac_cv_prog_(gcc|gxx|g77)$
 # and some are already tested elsewhere.  EGREP_EXCLUDE must filter out
 # the macros we don't want to test in ac-macros.at.
 #
-# - AC_CANONICALIZE, AC_PREFIX_PROGRAM, AC_PREREQ
+# - AC_C_TYPE_RANGE_INTEGER, AC_CANONICALIZE, AC_PREFIX_PROGRAM, AC_PREREQ
 #   Need an argument.
 #
 # - AC_CHECK alignof, decl, file, func, header, lib, member, prog, sizeof,
@@ -134,7 +134,7 @@ exclude_list='^ac_cv_prog_(gcc|gxx|g77)$
 #   Obsolete, checked in semantics.
 #
 ac_exclude_list='^AC_ARG_VAR$
-^AC_CANONICALIZE|AC_PREFIX_PROGRAM|AC_PREREQ$
+^AC_C_TYPE_RANGE_INTEGER|AC_CANONICALIZE|AC_PREFIX_PROGRAM|AC_PREREQ$
 
^AC_CHECK_(ALIGNOF|DECL|FILE|FUNC|HEADER|LIB|MEMBER|PROG|SIZEOF|(TARGET_)?TOOL|TYPE)S?$
 ^AC_CONFIG
 ^AC_(F77|FC)_FUNC$




reply via email to

[Prev in Thread] Current Thread [Next in Thread]