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.61a-282


From: Paul Eggert
Subject: [SCM] GNU Autoconf source repository branch, master, updated. v2.61a-282-g6108174
Date: Tue, 13 Nov 2007 07:31:13 +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=610817462bbfcacab3df3b8ed678f7b4b31fe1ad

The branch, master has been updated
       via  610817462bbfcacab3df3b8ed678f7b4b31fe1ad (commit)
      from  7daa47a115af00621ccbf202e61d87e69e5e48b9 (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 610817462bbfcacab3df3b8ed678f7b4b31fe1ad
Author: Ralf Wildenhues <address@hidden>
Date:   Mon Nov 12 23:30:58 2007 -0800

    * doc/autoconf.texi (Making testsuite Scripts): Document
    
    ":;{" shorthand as in previous patch.
    
    2007-11-12  Paul Eggert  <address@hidden>
    
    * doc/autoconf.texi (Limitations of Builtins): Document problem
    with { ... } a bit more clearly.  Suggest ":;{" as a shorthand
    for the workaround.
    * lib/m4sugar/Makefile.am (version.m4): Detect 'echo' failure.
    Use ":;{" shorthand.
    * tests/Makefile.am ($(srcdir)/package.m4): Likewise.

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

Summary of changes:
 ChangeLog               |   14 ++++++++++++++
 doc/autoconf.texi       |   30 +++++++++++++-----------------
 lib/m4sugar/Makefile.am |   21 ++++++++++-----------
 tests/Makefile.am       |   13 ++++++-------
 4 files changed, 43 insertions(+), 35 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 6b95b48..1426278 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,17 @@
+2007-11-12  Ralf Wildenhues  <address@hidden>
+
+       * doc/autoconf.texi (Making testsuite Scripts): Document
+       ":;{" shorthand as in previous patch.
+
+2007-11-12  Paul Eggert  <address@hidden>
+
+       * doc/autoconf.texi (Limitations of Builtins): Document problem
+       with { ... } a bit more clearly.  Suggest ":;{" as a shorthand
+       for the workaround.
+       * lib/m4sugar/Makefile.am (version.m4): Detect 'echo' failure.
+       Use ":;{" shorthand.
+       * tests/Makefile.am ($(srcdir)/package.m4): Likewise.
+
 2007-11-12  Jim Meyering  <address@hidden>
 
        Add more non-srcdir build support.
diff --git a/doc/autoconf.texi b/doc/autoconf.texi
index acc80cf..8633fa2 100644
--- a/doc/autoconf.texi
+++ b/doc/autoconf.texi
@@ -13572,11 +13572,10 @@ if @var{command}; then (exit 1); else :; fi
 @item @address@hidden@}}
 @c --------------------
 @prindex @address@hidden@}}
-As recently as GNU Bash 3.2, some shells do not properly set @samp{$?}
-when failing to write redirected output of any compound command other
-than a subshell group, when that compound command is the first thing
-executed.  This is most commonly observed with @address@hidden, but also 
affects
-other compound commands.
+Bash 3.2 (and earlier versions) sometimes does not properly set
address@hidden when failing to write redirected output of a compound command.
+This problem is most commonly observed with @address@hidden@address@hidden; it 
does
+not occur with @samp{(@dots{})}.  For example:
 
 @example
 $ @kbd{bash -c '@{ echo foo; @} >/bad; echo $?'}
@@ -13587,14 +13586,10 @@ bash: line 1: /bad: Permission denied
 0
 @end example
 
-The workaround is simple: prime bash with a simple command before any
-compound command with redirection.
+To work around the bug, prepend @samp{:;}:
 
 @example
-$ @kbd{bash -c ':; @{ echo foo; @} >/bad; echo $?'}
-bash: line 1: /bad: Permission denied
-1
-$ @kbd{bash -c ':; while :; do echo; done >/bad; echo $?'}
+$ @kbd{bash -c ':;@{ echo foo; @} >/bad; echo $?'}
 bash: line 1: /bad: Permission denied
 1
 @end example
@@ -20239,13 +20234,14 @@ we suggest that you also define 
@code{AT_PACKAGE_NAME},
 suggest the following makefile excerpt:
 
 @smallexample
+# The `:;' works around a Bash 3.2 bug when the output is not writeable.
 $(srcdir)/package.m4: $(top_srcdir)/configure.ac
-        @{                                      \
-          echo '# Signature of the current package.'; \
-          echo 'm4_define([AT_PACKAGE_NAME],      [@@PACKAGE_NAME@@])'; \
-          echo 'm4_define([AT_PACKAGE_TARNAME],   [@@PACKAGE_TARNAME@@])'; \
-          echo 'm4_define([AT_PACKAGE_VERSION],   [@@PACKAGE_VERSION@@])'; \
-          echo 'm4_define([AT_PACKAGE_STRING],    [@@PACKAGE_STRING@@])'; \
+        :;@{ \
+          echo '# Signature of the current package.' && \
+          echo 'm4_define([AT_PACKAGE_NAME],      [@@PACKAGE_NAME@@])' && \
+          echo 'm4_define([AT_PACKAGE_TARNAME],   [@@PACKAGE_TARNAME@@])' && \
+          echo 'm4_define([AT_PACKAGE_VERSION],   [@@PACKAGE_VERSION@@])' && \
+          echo 'm4_define([AT_PACKAGE_STRING],    [@@PACKAGE_STRING@@])' && \
           echo 'm4_define([AT_PACKAGE_BUGREPORT], [@@PACKAGE_BUGREPORT@@])'; \
         @} >'$(srcdir)/package.m4'
 @end smallexample
diff --git a/lib/m4sugar/Makefile.am b/lib/m4sugar/Makefile.am
index de32907..7360ca1 100644
--- a/lib/m4sugar/Makefile.am
+++ b/lib/m4sugar/Makefile.am
@@ -26,17 +26,16 @@ CLEANFILES = $(nodist_m4sugarlib_DATA)
 
 # The `:;' works around a redirected compound command bash exit status bug.
 version.m4: $(top_srcdir)/configure.ac
-       :; \
-       {                                       \
-         echo '# This file is part of -*- Autoconf -*-.'; \
-         echo '# Version of Autoconf.'; \
-         echo '# Copyright (C) 1999, 2000, 2001, 2002, 2006, 2007'; \
-         echo '# Free Software Foundation, Inc.'; \
-         echo ;\
-         echo 'm4_define([m4_PACKAGE_NAME],      [$(PACKAGE_NAME)])'; \
-         echo 'm4_define([m4_PACKAGE_TARNAME],   [$(PACKAGE_TARNAME)])'; \
-         echo 'm4_define([m4_PACKAGE_VERSION],   [$(PACKAGE_VERSION)])'; \
-         echo 'm4_define([m4_PACKAGE_STRING],    [$(PACKAGE_STRING)])'; \
+       :;{ \
+         echo '# This file is part of -*- Autoconf -*-.' && \
+         echo '# Version of Autoconf.' && \
+         echo '# Copyright (C) 1999, 2000, 2001, 2002, 2006, 2007' && \
+         echo '# Free Software Foundation, Inc.' && \
+         echo  &&\
+         echo 'm4_define([m4_PACKAGE_NAME],      [$(PACKAGE_NAME)])' && \
+         echo 'm4_define([m4_PACKAGE_TARNAME],   [$(PACKAGE_TARNAME)])' && \
+         echo 'm4_define([m4_PACKAGE_VERSION],   [$(PACKAGE_VERSION)])' && \
+         echo 'm4_define([m4_PACKAGE_STRING],    [$(PACKAGE_STRING)])' && \
          echo 'm4_define([m4_PACKAGE_BUGREPORT], [$(PACKAGE_BUGREPORT)])'; \
        } >version.m4
 
diff --git a/tests/Makefile.am b/tests/Makefile.am
index aa43da6..4cf7fd1 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -36,13 +36,12 @@ include ../lib/freeze.mk
 
 # The `:;' works around a redirected compound command bash exit status bug.
 package.m4: Makefile
-       :; \
-       {                                       \
-         echo '# Signature of the current package.'; \
-         echo 'm4_define([AT_PACKAGE_NAME],      [$(PACKAGE_NAME)])'; \
-         echo 'm4_define([AT_PACKAGE_TARNAME],   [$(PACKAGE_TARNAME)])'; \
-         echo 'm4_define([AT_PACKAGE_VERSION],   [$(PACKAGE_VERSION)])'; \
-         echo 'm4_define([AT_PACKAGE_STRING],    [$(PACKAGE_STRING)])'; \
+       :;{ \
+         echo '# Signature of the current package.' && \
+         echo 'm4_define([AT_PACKAGE_NAME],      [$(PACKAGE_NAME)])' && \
+         echo 'm4_define([AT_PACKAGE_TARNAME],   [$(PACKAGE_TARNAME)])' && \
+         echo 'm4_define([AT_PACKAGE_VERSION],   [$(PACKAGE_VERSION)])' && \
+         echo 'm4_define([AT_PACKAGE_STRING],    [$(PACKAGE_STRING)])' && \
          echo 'm4_define([AT_PACKAGE_BUGREPORT], [$(PACKAGE_BUGREPORT)])'; \
        } > address@hidden
        mv address@hidden $@


hooks/post-receive
--
GNU Autoconf source repository




reply via email to

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