autoconf-commit
[Top][All Lists]
Advanced

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

[SCM] GNU Autoconf source repository branch, master, updated. v2.63-106-


From: Eric Blake
Subject: [SCM] GNU Autoconf source repository branch, master, updated. v2.63-106-g57079f4
Date: Sat, 25 Oct 2008 13:46:15 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU Autoconf source repository".

http://git.sv.gnu.org/gitweb/?p=autoconf.git;a=commitdiff;h=57079f4e33bf6140172a31820c9eb33e07de2de3

The branch, master has been updated
       via  57079f4e33bf6140172a31820c9eb33e07de2de3 (commit)
      from  ce2d0f043cbe77a78fb1d0e2427543cf8cb9c9ca (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 57079f4e33bf6140172a31820c9eb33e07de2de3
Author: Paolo Bonzini <address@hidden>
Date:   Mon Oct 20 15:35:32 2008 +0200

    Use a shell function for _AC_CHECK_HEADER_MONGREL.
    
    * lib/autoconf/headers.m4 (_AC_CHECK_HEADER_MONGREL_BODY): New
    macro.
    (_AC_CHECK_HEADER_MONGREL): Use a shell function.
    
    Signed-off-by: Eric Blake <address@hidden>

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog               |    8 ++++
 lib/autoconf/headers.m4 |   89 +++++++++++++++++++++++++++-------------------
 2 files changed, 60 insertions(+), 37 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index dab6a6e..85088e5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2008-10-25  Paolo Bonzini  <address@hidden>
+       and Eric Blake  <address@hidden>
+
+       Use a shell function for _AC_CHECK_HEADER_MONGREL.
+       * lib/autoconf/headers.m4 (_AC_CHECK_HEADER_MONGREL_BODY): New
+       macro.
+       (_AC_CHECK_HEADER_MONGREL): Use a shell function.
+
 2008-10-25  Eric Blake  <address@hidden>
 
        Simplify _AS_PREPARE handling of functions.
diff --git a/lib/autoconf/headers.m4 b/lib/autoconf/headers.m4
index 413be8c..4c588ca 100644
--- a/lib/autoconf/headers.m4
+++ b/lib/autoconf/headers.m4
@@ -94,60 +94,75 @@ AC_DEFUN([AC_CHECK_HEADER],
 ])# AC_CHECK_HEADER
 
 
-# _AC_CHECK_HEADER_MONGREL(HEADER-FILE,
-#                         [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.
-#
-# This is not based on _AC_CHECK_HEADER_NEW and _AC_CHECK_HEADER_OLD
-# because it obfuscate the code to try to factor everything, in particular
-# because of the cache variables, and the `checking...' messages.
-m4_define([_AC_CHECK_HEADER_MONGREL],
-[AS_VAR_PUSHDEF([ac_Header], [ac_cv_header_$1])dnl
-AS_VAR_SET_IF([ac_Header],
-             [AC_CACHE_CHECK([for $1], [ac_Header], [])],
-             [# Is the header compilable?
-AC_MSG_CHECKING([$1 usability])
-AC_COMPILE_IFELSE([AC_LANG_SOURCE([AC_INCLUDES_DEFAULT([$4])
address@hidden:@include <$1>])],
+# _AC_CHECK_HEADER_MONGREL_BODY
+# -----------------------------
+# Shell function body for _AC_CHECK_HEADER_MONGREL
+m4_define([_AC_CHECK_HEADER_MONGREL_BODY],
+[  AS_LINENO_PUSH([$[]1])
+  AS_VAR_SET_IF([$[]3],
+               [AC_CACHE_CHECK([for $[]2], [$[]3], [])],
+               [# Is the header compilable?
+AC_MSG_CHECKING([$[]2 usability])
+AC_COMPILE_IFELSE([AC_LANG_SOURCE([$[]4
address@hidden:@include <$[]2>])],
                  [ac_header_compiler=yes],
                  [ac_header_compiler=no])
 AC_MSG_RESULT([$ac_header_compiler])
 
 # Is the header present?
-AC_MSG_CHECKING([$1 presence])
-AC_PREPROC_IFELSE([AC_LANG_SOURCE(address@hidden:@include <$1>])],
+AC_MSG_CHECKING([$[]2 presence])
+AC_PREPROC_IFELSE([AC_LANG_SOURCE(address@hidden:@include <$[]2>])],
                  [ac_header_preproc=yes],
                  [ac_header_preproc=no])
 AC_MSG_RESULT([$ac_header_preproc])
 
 # So?  What about this header?
-case 
$ac_header_compiler:$ac_header_preproc:$ac_[]_AC_LANG_ABBREV[]_preproc_warn_flag
 in
+case 
$ac_header_compiler:$ac_header_preproc:$ac_[]_AC_LANG_ABBREV[]_preproc_warn_flag
 in #((
   yes:no: )
-    AC_MSG_WARN([$1: accepted by the compiler, rejected by the preprocessor!])
-    AC_MSG_WARN([$1: proceeding with the compiler's result])
+    AC_MSG_WARN([$[]2: accepted by the compiler, rejected by the 
preprocessor!])
+    AC_MSG_WARN([$[]2: proceeding with the compiler's result])
     ac_header_preproc=yes
     ;;
   no:yes:* )
-    AC_MSG_WARN([$1: present but cannot be compiled])
-    AC_MSG_WARN([$1:     check for missing prerequisite headers?])
-    AC_MSG_WARN([$1: see the Autoconf documentation])
-    AC_MSG_WARN([$1:     section "Present But Cannot Be Compiled"])
-    AC_MSG_WARN([$1: proceeding with the preprocessor's result])
-    AC_MSG_WARN([$1: in the future, the compiler will take precedence])
-    m4_ifset([AC_PACKAGE_BUGREPORT],
-    [( AS_BOX([Report this to ]AC_PACKAGE_BUGREPORT)
-     ) | sed "s/^/$as_me: WARNING:     /" >&2])
+    AC_MSG_WARN([$[]2: present but cannot be compiled])
+    AC_MSG_WARN([$[]2:     check for missing prerequisite headers?])
+    AC_MSG_WARN([$[]2: see the Autoconf documentation])
+    AC_MSG_WARN([$[]2:     section "Present But Cannot Be Compiled"])
+    AC_MSG_WARN([$[]2: proceeding with the preprocessor's result])
+    AC_MSG_WARN([$[]2: in the future, the compiler will take precedence])
+m4_ifset([AC_PACKAGE_BUGREPORT],
+[m4_n([( AS_BOX([Report this to ]AC_PACKAGE_BUGREPORT)
+     ) | sed "s/^/$as_me: WARNING:     /" >&2])])dnl
     ;;
 esac
-AC_CACHE_CHECK([for $1], [ac_Header],
-              [AS_VAR_SET([ac_Header], [$ac_header_preproc])])[]dnl
-])
+  AC_CACHE_CHECK([for $[]2], [$[]3],
+                [AS_VAR_SET([$[]3], [$ac_header_preproc])])])
+  AS_LINENO_POP
+])#_AC_CHECK_HEADER_MONGREL_BODY
+
+# _AC_CHECK_HEADER_MONGREL(HEADER-FILE,
+#                         [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.
+#
+# This is not based on _AC_CHECK_HEADER_NEW and _AC_CHECK_HEADER_OLD
+# because it obfuscate the code to try to factor everything, in particular
+# because of the cache variables, and the `checking...' messages.
+m4_define([_AC_CHECK_HEADER_MONGREL],
+[AC_REQUIRE_SHELL_FN([ac_func_]_AC_LANG_ABBREV[_check_header_mongrel],
+  [AS_FUNCTION_DESCRIBE([ac_func_]_AC_LANG_ABBREV[_check_header_mongrel],
+    [LINENO FUNC VAR INCLUDES],
+    [Tests whether HEADER exists, giving a warning if it cannot be compiled
+     using the include files in INCLUDES and setting the cache variable VAR
+     accordingly.])],
+  [$0_BODY])]dnl
+[AS_VAR_PUSHDEF([ac_Header], [ac_cv_header_$1])]dnl
+[ac_func_[]_AC_LANG_ABBREV[]_check_header_mongrel ]dnl
+["$LINENO" "$1" "ac_Header" "AS_ESCAPE([AC_INCLUDES_DEFAULT([$4], [""])])"
 AS_VAR_IF([ac_Header], [yes], [$2], [$3])
-AS_VAR_POPDEF([ac_Header])dnl
-])# _AC_CHECK_HEADER_MONGREL
+AS_VAR_POPDEF([ac_Header])])# _AC_CHECK_HEADER_MONGREL
 
 
 # _AC_CHECK_HEADER_NEW(HEADER-FILE,


hooks/post-receive
--
GNU Autoconf source repository




reply via email to

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