[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: bad m4 quotation? (was: echo "enhancement" leads to confused legacy
From: |
Stepan Kasal |
Subject: |
Re: bad m4 quotation? (was: echo "enhancement" leads to confused legacy script tools...) |
Date: |
Tue, 28 Mar 2006 15:09:24 +0200 |
User-agent: |
Mutt/1.4.1i |
Hello Ralf,
you metioned that the call
AC_CONFIG_FILES([m4_default([$1], [foobar])])
(which appears inside a definition of an Autoconf macro) doesn't work;
the outer pair of quotes have to be removed.
As we both know, the reason is that the first parameter of
AC_CONFIG_FOOS is split by whitespace before any expansion. [*]
(I think that the individual words are expanded later, but I'm afraid
that the only well tested case is when the words are literal strings,
without any quotes or macro calls.)
Actually, m4_default is usually used this way: the logic ``if the
parameter given was empty, use this one'' should be executed before
the macro call, the macro called (AC_CONFIG_FILES in this case) shall
see only the result of this decision.
Footnote:
[*] I vaguely recall contemplating this, but I wasn't able to find
strong reasons for any of the two variants. So I tried to be backward
compatible in this case. ;-)
Have a nice day,
Stepan
- Re: echo "enhancement" leads to confused legacy script tools..., (continued)
- Re: echo "enhancement" leads to confused legacy script tools..., Ralf Wildenhues, 2006/03/20
- Re: echo "enhancement" leads to confused legacy script tools..., Henrik Nordstrom, 2006/03/20
- Re: echo "enhancement" leads to confused legacy script tools..., Paul Eggert, 2006/03/20
- Re: echo "enhancement" leads to confused legacy script tools..., Henrik Nordstrom, 2006/03/20
- Re: echo "enhancement" leads to confused legacy script tools..., Linda W, 2006/03/20
- Re: echo "enhancement" leads to confused legacy script tools..., Ralf Wildenhues, 2006/03/21
- Re: echo "enhancement" leads to confused legacy script tools..., Ralf Wildenhues, 2006/03/21
- Re: echo "enhancement" leads to confused legacy script tools..., Ralf Wildenhues, 2006/03/21
- Re: echo "enhancement" leads to confused legacy script tools..., Henrik Nordstrom, 2006/03/21
- bad m4 quotation? (was: echo "enhancement" leads to confused legacy script tools...), Ralf Wildenhues, 2006/03/27
- Re: bad m4 quotation? (was: echo "enhancement" leads to confused legacy script tools...),
Stepan Kasal <=
- Re: bad m4 quotation?, Ralf Wildenhues, 2006/03/28
- Re: bad m4 quotation?, Stepan Kasal, 2006/03/28
- Re: bad m4 quotation?, Stepan Kasal, 2006/03/29
- AX_PREFIX_CONFIG_H and m4 quoting (was: bad m4 quotation?), Ralf Wildenhues, 2006/03/30
- Re: echo "enhancement" leads to confused legacy script tools..., Chet Ramey, 2006/03/31
- Re: echo "enhancement" leads to confused legacy script tools..., Henrik Nordstrom, 2006/03/20
Re: echo "enhancement" leads to confused legacy script tools..., Andreas Schwab, 2006/03/22