autoconf
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: regression in autoconf 2.65 ?


From: Eric Blake
Subject: Re: regression in autoconf 2.65 ?
Date: Sat, 28 Nov 2009 05:51:26 -0700
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.23) Gecko/20090812 Thunderbird/2.0.0.23 Mnenhy/0.7.6.666

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

According to Vincent Torri on 11/28/2009 2:22 AM:
> AC_DEFUN([ECORE_CHECK_MODULE],
> [
> m4_pushdef([UP], m4_toupper([[$1]]))dnl
> m4_pushdef([DOWN], m4_tolower([[$1]]))dnl

Lose the extra quotes.  Per the NEWS, m4_toupper and m4_tolower now
properly quote their expansion.  So you need:

m4_pushdef([UP], m4_toupper([$1]))dnl
m4_pushdef([DOWN], m4_tolower([$1]))dnl

and everything else should fall into place.  For example,

> 
> have_ecore_[]m4_defn([DOWN])=no

with the extra quotes, this line was producing
have_ecore_foo[foo]=no
instead of the intended
have_ecore_foo=no

Sorry that this is a backwards-incompatible change, but we did document
it, and it makes m4_toupper more consistent with other m4sugar text
manipulation macros, in that it does not spuriously cause macro expansion
of the resulting text if the case-change happens to name an existing macro.

In order to write a configure.ac script that will work with both 2.64 and
younger, and with 2.65, you will need a wrapper function.  Here's one way
to write it:

m4_pushdef([AAA],[BBB])dnl
m4_if(m4_toupper([aaa]),[BBB],
  [m4_define([my_toupper],[m4_toupper([[$1]])])],
  [m4_copy([m4_toupper], [my_toupper])])
m4_popdef([AAA])

and likewise for m4_tolower; then use my_toupper instead of m4_toupper.

- --
Don't work too hard, make some time for fun as well!

Eric Blake             address@hidden
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAksRHM4ACgkQ84KuGfSFAYCRowCfexlfAt/MutExPK+254LDe2lR
GaMAoK7548FrWALelGWdeD0o9MQUe1CI
=SoNg
-----END PGP SIGNATURE-----




reply via email to

[Prev in Thread] Current Thread [Next in Thread]