]> git.ipfire.org Git - thirdparty/autoconf.git/commitdiff
* doc/autoconf.texi (Programming in M4sh): Sharpen the descriptions
authorPaul Eggert <eggert@cs.ucla.edu>
Fri, 31 Mar 2006 18:55:43 +0000 (18:55 +0000)
committerPaul Eggert <eggert@cs.ucla.edu>
Fri, 31 Mar 2006 18:55:43 +0000 (18:55 +0000)
of AS_BASENAME and AS_DIRNAME.  Reported by Stepan Kasal.

ChangeLog
doc/autoconf.texi

index 2d40cbe19b5c2485da1e5e822ab230dd57fcaf48..afb43b218a200ac05f04043de6b94ae901b33485 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2006-03-31  Paul Eggert  <eggert@cs.ucla.edu>
 
+       * doc/autoconf.texi (Programming in M4sh): Sharpen the descriptions
+       of AS_BASENAME and AS_DIRNAME.  Reported by Stepan Kasal.
+
        * lib/m4sugar/m4sh.m4 (AS_BASENAME_EXPR): Handle ///, ////, etc.
        correctly.  Problem reported by Eric Blake.
        (_AS_EXPR_PREPARE): Detect Tru64 expr bug.  Problem reported by
index 69aac5cf2ded44bef0e5b93d5474684b9d0f9bca..d2c8a81f4927863c371139262925268cbb1390c1 100644 (file)
@@ -9386,9 +9386,8 @@ that unfortunately are not portable in practice.
 @defmac AS_BASENAME (@var{file-name})
 @asindex{BASENAME}
 Output the non-directory portion of @var{file-name}.  For example,
-@code{file=`AS_BASENAME([/one/two/three])`} sets @code{file} to
-@samp{three}.  @xref{Limitations of Usual Tools}, for why this is more
-portable than @command{file=`basename /one/two/three`}.
+if @code{$file} is @samp{/one/two/three}, the command
+@code{base=`AS_BASENAME(["$file"])`} sets @code{base} to @samp{three}.
 @end defmac
 
 @defmac AS_BOURNE_COMPATIBLE
@@ -9409,9 +9408,8 @@ corresponding pattern matched @var{word}, else @var{default} is run.
 @defmac AS_DIRNAME (@var{file-name})
 @asindex{DIRNAME}
 Output the directory portion of @var{file-name}.  For example,
-@code{file=`AS_DIRNAME([/one/two/three])`} sets @code{file} to
-@samp{/one/two}.  @xref{Limitations of Usual Tools}, for why this is
-more portable than @command{file=`dirname /one/two/three`}.
+if @code{$file} is @samp{/one/two/three}, the command
+@code{dir=`AS_DIRNAME(["$file"])`} sets @code{dir} to @samp{/one/two}.
 @end defmac
 
 @defmac AS_IF (@var{test1}, @ovar{run-if-true1}, @dots{}, @ovar{run-if-false})