GNU bug report logs -
#10898
test-suite output of automake-1.11.3 - it requested I send it to you!
Previous Next
Reported by: Lou Picciano <Lou <at> Picciano.org>
Date: Mon, 27 Feb 2012 17:02:01 UTC
Severity: normal
Tags: moreinfo, patch
Done: Stefano Lattarini <stefano.lattarini <at> gmail.com>
Bug is archived. No further changes may be made.
Full log
Message #25 received at 10898 <at> debbugs.gnu.org (full text, mbox):
Fixes automake bug#10898. See also the older (much older) thread:
<http://lists.gnu.org/archive/html/automake-patches/2009-12/msg00036.html>
At least the AT&T and OpenSolaris versions of the Korn shell, as well
as the /bin/sh from OpenIndiana 11, have a strange bug regarding the
expansion of ${1+"$@"}: when exactly *one empty* argument is passed to
a script run by one of this shells, inside that script ${1+"$@"} will
expand to *nothing*, rather than to to the single empty string, as
one would expect (OTOH, $# will correctly expand to 1). This buggy
behaviour was causing a spurious failure in our testsuite (test 6 in
't/automake-cmdline.tap'). Work around it.
* t/wrap/automake.in: Here.
Signed-off-by: Stefano Lattarini <stefano.lattarini <at> gmail.com>
---
t/wrap/automake.in | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/t/wrap/automake.in b/t/wrap/automake.in
index 14f437f..b77177c 100644
--- a/t/wrap/automake.in
+++ b/t/wrap/automake.in
@@ -27,4 +27,10 @@ fi
perllibdir="@abs_top_builddir@/lib <at> PATH_SEPARATOR@@abs_top_srcdir@/lib"
export perllibdir
-exec "@abs_top_builddir@/automake" "--libdir=@abs_top_srcdir@/lib" ${1+"$@"}
+# Don't trust ${1+"$@"}: it has subtle bugs in some Korn shells (for very
+# corner case only admittedly, but those have already bitten us -- see
+# automake bug#10898).
+case $# in
+ 0) exec "@abs_top_builddir@/automake" "--libdir=@abs_top_srcdir@/lib";;
+ *) exec "@abs_top_builddir@/automake" "--libdir=@abs_top_srcdir@/lib" "$@";;
+esac
--
1.7.12.rc0
This bug report was last modified 13 years and 20 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.