From: Ralf Wildenhues Date: Tue, 14 Nov 2006 22:07:11 +0000 (+0000) Subject: * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the X-Git-Tag: cvs-readonly~1561 X-Git-Url: http://erislabs.org.uk/gitweb/?a=commitdiff_plain;h=418f202b845a90ece24d32639b6fabbf0a108300;p=gnulib.git * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the test for conforming inttypes.h is both announced and cached. --- diff --git a/ChangeLog b/ChangeLog index fba96ef3d..35d5eb7a6 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ 2006-11-14 Ralf Wildenhues + * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the + test for conforming inttypes.h is both announced and cached. + * MODULES.html.sh (seen_modules, seen_files): New variables. (func_module): Rewrite to use a few less gnulib-tool and sed invocations. Avoid a couple of quadratic algorithms for ... diff --git a/m4/inttypes.m4 b/m4/inttypes.m4 index 71b7f48a8..525856728 100644 --- a/m4/inttypes.m4 +++ b/m4/inttypes.m4 @@ -1,4 +1,4 @@ -# inttypes.m4 serial 5 +# inttypes.m4 serial 6 dnl Copyright (C) 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, @@ -22,15 +22,18 @@ AC_DEFUN([gl_INTTYPES_H], dnl - the existence of an , dnl - that imaxabs, imaxdiv, strtoimax, strtoumax are declared, dnl - some additional tests. - gl_cv_header_working_inttypes_h=no - if test "$gl_cv_header_working_stdint_h" = yes \ - && test $ac_cv_header_inttypes_h = yes \ - && test "$ac_cv_have_decl_imaxabs" = yes \ - && test "$ac_cv_have_decl_imaxdiv" = yes \ - && test "$ac_cv_have_decl_strtoimax" = yes \ - && test "$ac_cv_have_decl_strtoumax" = yes; then - AC_COMPILE_IFELSE([ - AC_LANG_PROGRAM([ + AC_CACHE_CHECK([whether inttypes.h conforms to C99], + [gl_cv_header_working_inttypes_h], + [ + gl_cv_header_working_inttypes_h=no + if test "$gl_cv_header_working_stdint_h" = yes \ + && test $ac_cv_header_inttypes_h = yes \ + && test "$ac_cv_have_decl_imaxabs" = yes \ + && test "$ac_cv_have_decl_imaxdiv" = yes \ + && test "$ac_cv_have_decl_strtoimax" = yes \ + && test "$ac_cv_have_decl_strtoumax" = yes; then + AC_COMPILE_IFELSE([ + AC_LANG_PROGRAM([ #include #define __STDC_LIMIT_MACROS 1 /* to make it work also in C++ mode */ #define __STDC_CONSTANT_MACROS 1 /* to make it work also in C++ mode */ @@ -128,9 +131,9 @@ const char *l = /* implicit string concatenation */ SCNoPTR SCNuPTR SCNxPTR #endif ; - ])], - [gl_cv_header_working_inttypes_h=yes]) - fi + ])], + [gl_cv_header_working_inttypes_h=yes]) + fi]) if test $gl_cv_header_working_inttypes_h = yes; then dnl Use the existing . INTTYPES_H=''