automake-commit
[Top][All Lists]
Advanced

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

[Automake-commit] [SCM] GNU Automake branch, maint, updated. v1.12.1-61-


From: Stefano Lattarini
Subject: [Automake-commit] [SCM] GNU Automake branch, maint, updated. v1.12.1-61-gdbc83fa
Date: Sun, 24 Jun 2012 14:53:42 +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 Automake".

http://git.sv.gnu.org/gitweb/?p=automake.git;a=commitdiff;h=dbc83fa9f32ee17e52d02d58e1a840fd046ed9a9

The branch, maint has been updated
       via  dbc83fa9f32ee17e52d02d58e1a840fd046ed9a9 (commit)
       via  3a7149594efc4ae7cd9f2b362baecde9d94e13f5 (commit)
       via  76fea2de5fa1e2f240e744ab067acb6db98480f7 (commit)
       via  d8024b510375dd4ea44fa15a24490c9885f722b4 (commit)
       via  f1e0300d38e7c79ec58a259c9c821d9469bb6c02 (commit)
      from  5898641fb97b63ff62d84eed90ea7e1b2329bfe8 (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 dbc83fa9f32ee17e52d02d58e1a840fd046ed9a9
Author: Stefano Lattarini <address@hidden>
Date:   Sun Jun 24 16:52:51 2012 +0200

    tests: avoid a spurious failure on NetBSD
    
    * t/maken.sh: Do not expect the timestamp of the current directory
    to be unchanged after a "make -n".
    
    Signed-off-by: Stefano Lattarini <address@hidden>

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

Summary of changes:
 defs           |   10 +++++-----
 defs-static.in |   41 ++++++++++++++---------------------------
 t/README       |   21 ++++-----------------
 t/maken.sh     |    2 +-
 4 files changed, 24 insertions(+), 50 deletions(-)

diff --git a/defs b/defs
index a47a541..217665e 100644
--- a/defs
+++ b/defs
@@ -32,8 +32,8 @@ case ${AM_TESTS_REEXEC-yes} in
     ;;
   *)
     # Ensure we can find ourselves.
-    if test ! -f "$0"; then
-      echo "$0: unable to find myself" >&2
+    if test ! -f "$argv0"; then
+      echo "$argv0: unable to find myself" >&2
       exit 99
     fi
     AM_TESTS_REEXEC=no; export AM_TESTS_REEXEC
@@ -46,10 +46,10 @@ case ${AM_TESTS_REEXEC-yes} in
       *x*) opts=-x;;
       *) opts=;;
     esac
-    echo exec $AM_TEST_RUNNER_SHELL $opts "$0" "$*"
-    exec $AM_TEST_RUNNER_SHELL $opts "$0" ${1+"$@"}
+    echo exec $AM_TEST_RUNNER_SHELL $opts "$argv0" "$*"
+    exec $AM_TEST_RUNNER_SHELL $opts "$argv0" ${1+"$@"}
     # This should be dead code, unless some strange error happened. 
-    echo "$0: failed to re-execute with $AM_TEST_RUNNER_SHELL" >&2
+    echo "$argv0: failed to re-execute with $AM_TEST_RUNNER_SHELL" >&2
     exit 99
     ;;
 esac
diff --git a/defs-static.in b/defs-static.in
index 1dfd8d3..da5dcff 100644
--- a/defs-static.in
+++ b/defs-static.in
@@ -31,35 +31,22 @@ DUALCASE=1; export DUALCASE # for MKS sh
 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
   emulate sh
   NULLCMD=:
-  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
-  # is contrary to our usage.  Disable this feature.
-  alias -g '${1+"$@"}'='"$@"'
   setopt NO_GLOB_SUBST
-  # If Zsh is not started directly in Bourne-compatibility mode, it has
-  # some incompatibilities in the handling of $0 that conflict with
-  # our usage: i.e., $0 inside a file sourced with the '.' builtin is
-  # temporarily set to the name of the sourced file.
-  # Work around this when possible, otherwise abort the script.
+  # If Zsh is not started directly in POSIX-compatibility mode, it has some
+  # incompatibilities in the handling of $0 that conflict with our usage;
+  # i.e., $0 inside a file sourced with the '.' builtin is temporarily set
+  # to the name of the sourced file.  Work around that.
   # Note that a bug in some versions of Zsh prevents us from resetting $0
   # in a sourced script, so the use of $argv0.  For more info see:
-  #  <http://www.zsh.org/mla/workers/2009/msg01140.html>
-  # Note: the apparently useless 'eval' below are needed by at least
-  # dash 0.5.2, to prevent it from bailing out with an error like
-  # "Syntax error: Bad substitution"
-  if eval '[[ "$0" = *."test" ]]'; then
-    # Good, FUNCTION_ARGZERO option was already off when this file was
-    # sourced.  Thus we've nothing to do.
-    argv0=$0
-  elif eval 'test -n "${functrace[-1]}"'; then
-    # FUNCTION_ARGZERO option was on, but we have a easy workaround.
-    eval 'argv0=${functrace[-1]%:*}'
-  else
-    # Give up.
-    echo "$0: cannot determine the path of running test script" >&2
-    echo "$0: test was running with Zsh version $ZSH_VERSION" >&2
-    echo "$0: did you enable the NO_FUNCTION_ARGZERO option?" >&2
+  #   <http://www.zsh.org/mla/workers/2009/msg01140.html>
+  # The apparently useless 'eval' here is needed by at least dash 0.5.2,
+  # to prevent it from bailing out with an error like:
+  #   "Syntax error: Bad substitution".
+  eval 'argv0=${functrace[-1]%:*}' && test -f "$argv0" || {
+    echo "Cannot determine the path of running test script." >&2
+    echo "Your Zsh (version $ZSH_VERSION) is probably too old." >&2
     exit 99
-  fi
+  }
 else
   argv0=$0
   # Avoid command substitution failure, for Tru64 sh -e and instspc*.test.
@@ -140,8 +127,8 @@ build_alias=${build_alias-'@build_alias@'}; export 
build_alias
 
 # The shell we use to run our own test scripts, determined at configure
 # time.  It is required in the self tests, and most importantly for the
-# the automatic re-execution of test scripts.
-AM_TEST_RUNNER_SHELL='@AM_TEST_RUNNER_SHELL@'
+# automatic re-execution of test scripts.
+AM_TEST_RUNNER_SHELL=${AM_TEST_RUNNER_SHELL-'@AM_TEST_RUNNER_SHELL@'}
 
 # Make sure we override the user shell.  And do not read the value of
 # $SHELL from the environment (think to the non-uncommon situation where
diff --git a/t/README b/t/README
index 3f56400..43f7b71 100644
--- a/t/README
+++ b/t/README
@@ -105,23 +105,10 @@ Supported shells
   to run the test(s) through the makefile test driver.
 
   The test scripts are written with portability in mind, so that they
-  should run with any decent Bourne-compatible shell.
-
-  However, some care must be used with Zsh, since, when not directly
-  started in Bourne-compatibility mode, it has some incompatibilities
-  in the handling of $0 which conflict with our usage.  Our testsuite
-  can automatically work around these incompatibilities when a version
-  4.3 or later of Zsh is used, but unfortunately not when an older
-  version of Zsh is used.  Thus, if you want to run a test script, say
-  'foo.sh', with Zsh 4.2, you *can't* simply do "zsh foo.sh", but
-  you *must* resort to:
-
-    AM_TESTS_REEXEC=no zsh -o no_function_argzero foo.sh
-
-  Note that this problem does not occur if Zsh is executed through
-  a symlink with a basename of 'sh', since in that case Zsh starts
-  in Bourne compatibility mode.  So you should be perfectly safe
-  when /bin/sh is Zsh, even a it's version < 4.3.
+  should run with any decent Bourne-compatible shell.  However, it is
+  worth nothing that older versions of Zsh (pre-4.3) exhibited several
+  bugs and incompatibilities with our uses, and are thus not supported
+  for running Automake's test scripts.
 
 
 Reporting failures
diff --git a/t/maken.sh b/t/maken.sh
index 1257e4a..a114422 100755
--- a/t/maken.sh
+++ b/t/maken.sh
@@ -56,7 +56,7 @@ for target in dist distcheck; do
   fi
   $MAKE test-no-distdir
   # No file has been actually touched or created.
-  is_newest stampfile $(find .)
+  is_newest stampfile $(find . -type f) sub
 done
 
 :


hooks/post-receive
-- 
GNU Automake



reply via email to

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