mirror of
git://git.sv.gnu.org/autoconf
synced 2025-01-06 10:25:53 +08:00
Fix shell code in AS_TR_SH documentation.
* doc/autoconf.texi (Common Shell Constructs) <AS_TR_SH>: Fix example to expand to valid shell code. Reported by Ralf Wildenhues. Signed-off-by: Eric Blake <eblake@redhat.com>
This commit is contained in:
parent
026070fea8
commit
d174a5362e
@ -1,5 +1,10 @@
|
||||
2010-03-02 Eric Blake <eblake@redhat.com>
|
||||
|
||||
Fix shell code in AS_TR_SH documentation.
|
||||
* doc/autoconf.texi (Common Shell Constructs) <AS_TR_SH>: Fix
|
||||
example to expand to valid shell code.
|
||||
Reported by Ralf Wildenhues.
|
||||
|
||||
Improve documentation on AC_{COMPILE,LINK}_IFELSE.
|
||||
* doc/autoconf.texi (Running the Compiler): Mention that the
|
||||
object file is available after a successful compile.
|
||||
|
@ -13206,12 +13206,15 @@ echo "[#]define AS_TR_CPP([HAVE_$type]) 1"
|
||||
|
||||
@defmac AS_TR_SH (@var{expression})
|
||||
@asindex{TR_SH}
|
||||
Transform @var{expression} into a valid shell variable name. For example:
|
||||
Transform @var{expression} into shell code that generates a valid shell
|
||||
variable name. The result is literal when possible at m4 time, but must
|
||||
be used with @code{eval} if @var{expression} causes shell indirections.
|
||||
For example:
|
||||
|
||||
@example
|
||||
# This outputs "Have it!".
|
||||
header="sys/some file.h"
|
||||
AS_TR_SH([HAVE_$header])=yes
|
||||
eval AS_TR_SH([HAVE_$header])=yes
|
||||
if test "x$HAVE_sys_some_file_h" = xyes; then echo "Have it!"; fi
|
||||
@end example
|
||||
@end defmac
|
||||
|
Loading…
Reference in New Issue
Block a user