From: Stepan Kasal Date: Fri, 26 Aug 2005 16:12:21 +0000 (+0000) Subject: Fix the examples for AS_TR_CPP and AS_TR_SH. X-Git-Tag: AUTOCONF-2.59c~255 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0058d8366e86fe957f9ed0d31aa7976f7a49dbcb;p=thirdparty%2Fautoconf.git Fix the examples for AS_TR_CPP and AS_TR_SH. --- diff --git a/ChangeLog b/ChangeLog index b9c7a0fd9..d3ee1c682 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2005-08-26 Stepan Kasal + + * doc/autoconf.texi (Programming in M4sh) : Fix m4 quoting + in the example. Reported by Bruno Haible. + : Likewise. Also modify the example to be more convincing: + "if $undefined_var;" succeeds with my shell. + 2005-08-25 Paul Eggert * lib/m4sugar/m4sh.m4 (_AS_VERSION_COMPARE_PREPARE): diff --git a/doc/autoconf.texi b/doc/autoconf.texi index 4a1a772fc..b6a25d96e 100644 --- a/doc/autoconf.texi +++ b/doc/autoconf.texi @@ -9017,7 +9017,7 @@ For example: @example $ type="char *" -$ echo "#define AS_TR_CPP(HAVE_$type) 1" +$ echo "#define AS_TR_CPP([HAVE_$type]) 1" #define HAVE_CHAR_P 1 @end example @end defmac @@ -9028,8 +9028,8 @@ Transform @var{expression} into a valid shell variable name. For example: @example $ header="sys/some file.h" -$ AS_TR_SH(HAVE_$header)=: -$ if $HAVE_sys_some_file_h; then echo "Have it!"; fi +$ AS_TR_SH([HAVE_$header])=yes +$ if test "$HAVE_sys_some_file_h" = yes; then echo "Have it!"; fi Have it! @end example @end defmac