From 82f7e927e27fc886c514e3146494a2f1c310dffa Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Sat, 28 Jan 2012 13:31:06 -0800 Subject: [PATCH] strtoimax: eliminate need for stdint.h, inttypes.h checks * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Don't use gl_AC_HEADER_STDINT_H or gl_AC_HEADER_INTTYPES_H. This reduces the prerequisites for a recently-introduced strtoimax test. I guess this might cause strtoimax to be replaced when not strictly necessary on older hosts, but this shouldn't introduce any bugs and it should make Emacs 'configure' faster on typical modern hosts. Problem discovered when importing the latest gnulib to an Emacs test version. * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4. --- ChangeLog | 13 +++++++++++++ m4/strtoimax.m4 | 13 ++----------- modules/strtoimax | 2 -- 3 files changed, 15 insertions(+), 13 deletions(-) diff --git a/ChangeLog b/ChangeLog index 15b73d373..30be2b810 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,16 @@ +2012-01-28 Paul Eggert + + strtoimax: eliminate need for stdint.h, inttypes.h checks + * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Don't use + gl_AC_HEADER_STDINT_H or gl_AC_HEADER_INTTYPES_H. This reduces + the prerequisites for a recently-introduced strtoimax test. + I guess this might cause strtoimax to be replaced when not + strictly necessary on older hosts, but this shouldn't introduce + any bugs and it should make Emacs 'configure' faster on typical + modern hosts. Problem discovered when importing the latest gnulib + to an Emacs test version. + * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4. + 2012-01-28 Bruno Haible sys_time: Override 'struct timeval' on some native Windows platforms. diff --git a/m4/strtoimax.m4 b/m4/strtoimax.m4 index 76d55600d..58a31899b 100644 --- a/m4/strtoimax.m4 +++ b/m4/strtoimax.m4 @@ -1,4 +1,4 @@ -# strtoimax.m4 serial 12 +# strtoimax.m4 serial 13 dnl Copyright (C) 2002-2004, 2006, 2009-2012 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, @@ -18,22 +18,13 @@ AC_DEFUN([gl_FUNC_STRTOIMAX], if test $ac_cv_func_strtoimax = yes; then HAVE_STRTOIMAX=1 dnl On AIX 5.1, strtoimax() fails for values outside the 'int' range. - AC_REQUIRE([gl_AC_HEADER_STDINT_H]) - AC_REQUIRE([gl_AC_HEADER_INTTYPES_H]) AC_REQUIRE([AC_CANONICAL_HOST]) dnl for cross-compiles AC_CACHE_CHECK([whether strtoimax works], [gl_cv_func_strtoimax], [AC_RUN_IFELSE( [AC_LANG_SOURCE([[ #include -#include #include -#include -#if HAVE_STDINT_H_WITH_UINTMAX -# include -#endif -#if HAVE_INTTYPES_H_WITH_UINTMAX -# include -#endif +#include int main () { if (sizeof (intmax_t) > sizeof (int)) diff --git a/modules/strtoimax b/modules/strtoimax index f3f561212..2517603c6 100644 --- a/modules/strtoimax +++ b/modules/strtoimax @@ -4,8 +4,6 @@ strtoimax() function: convert string to 'intmax_t'. Files: lib/strtoimax.c m4/strtoimax.m4 -m4/stdint_h.m4 -m4/inttypes_h.m4 m4/longlong.m4 Depends-on: -- 2.11.0