]> git.ipfire.org Git - thirdparty/autoconf.git/commitdiff
Clarify nested double-quotes and backquotes shell issues.
authorRalf Wildenhues <Ralf.Wildenhues@gmx.de>
Tue, 22 Jun 2010 18:05:38 +0000 (20:05 +0200)
committerRalf Wildenhues <Ralf.Wildenhues@gmx.de>
Tue, 22 Jun 2010 18:28:12 +0000 (20:28 +0200)
* doc/autoconf.texi (Shellology): New anchor for pdksh.
(Shell Substitutions): Link to it for escaped double-quotes
within double-quoted backquotes; add ksh example for unescaped
inner double-quotes problem.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
ChangeLog
doc/autoconf.texi

index df492a02fa148ba506b905e4c2317fa3930a5e08..0fc8dbe8e8aa3b3e1fdf10520f2c5ce63d04ec0c 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,11 @@
 2010-06-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
 
+       Clarify nested double-quotes and backquotes shell issues.
+       * doc/autoconf.texi (Shellology): New anchor for pdksh.
+       (Shell Substitutions): Link to it for escaped double-quotes
+       within double-quoted backquotes; add ksh example for unescaped
+       inner double-quotes problem.
+
        Mention Tru64 5.1 fgrep limitation with emtpy patterns.
        * doc/autoconf.texi (Limitations of Usual Tools): Update.
 
index c2772fe4040bb82692451f56d0faf5d75bae751c..7e97d9642f4981d681d1b4b470370534ed929837 100644 (file)
@@ -14626,6 +14626,7 @@ the standard shell conform to Posix.
 
 @item Pdksh
 @prindex @samp{pdksh}
+@anchor{pdksh}
 A public-domain clone of the Korn shell called @command{pdksh} is widely
 available: it has most of the @samp{ksh88} features along with a few of
 its own.  It usually sets @code{KSH_VERSION}, except if invoked as
@@ -15139,9 +15140,18 @@ esac
 @noindent
 and in fact it is even @emph{more} portable: in the first case of the
 first attempt, the computation of @code{top_srcdir} is not portable,
-since not all shells properly understand @code{"`@dots{}"@dots{}"@dots{}`"}.
+since not all shells properly understand @code{"`@dots{}"@dots{}"@dots{}`"},
+for example Solaris 10 ksh:
+
+@example
+$ @kbd{foo="`echo " bar" | sed 's, ,,'`"}
+ksh: : cannot execute
+ksh: bar | sed 's, ,,': cannot execute
+@end example
+
+@noindent
 Worse yet, not all shells understand @code{"`@dots{}\"@dots{}\"@dots{}`"}
-the same way.  There is just no portable way to use double-quoted
+the same way (@pxref{pdksh}).  There is just no portable way to use double-quoted
 strings inside double-quoted back-quoted expressions (pfew!).
 
 @table @code