autoconf
[Top][All Lists]
Advanced

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

Re: m4 quoting change? (2.52->2.53)


From: Akim Demaille
Subject: Re: m4 quoting change? (2.52->2.53)
Date: 08 Apr 2002 11:08:28 +0200
User-agent: Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.4 (Common Lisp)

| Running autoheader for a second time does not generate these
| warnings--is this autom4te?

Yes.  This is the remainder of a discussion that never really ended.
autom4te is here to cache, so it looses some side effects, such as
warnings.  We could fight to have them cached too, but I don't know if
it is really needed.  Use --force wen you don't trust it.

| The code in question is quite simple:
|   m4_pushdef([DOWN], m4_translit([$1], [A-Z], [a-z]))dnl
|   m4_pushdef([CACHE], ac_cv_path_lib_[]DOWN)dnl
| then
|   AC_CACHE_CHECK([for UP CFLAGS],
|                  [CACHE[]_cflags],
|                [CACHE[]_cflags=`$UP[]_CONFIG $LDOWN[]_config_args \
|                                 LIBCONFIG_CFLAGS`])
| 
| All four sets (cflags, libs, version, present) of three warnings are
| within AC_CACHE_CHECK macros. The [] is to separate the macro to be
| expanded from the shell variable suffix.
| 
| The errors seem wrong--the `[' and `]' are /not/ unmatched at all!  I
| didn't see anything relating to this specifically in the NEWS file.
| What should I be doing differently?

I'm afraid you found a bug in 2.53.  I tend to think it is the bug
that was introduced in m4_bmatch.  I observe the following:

/tmp % cat configure.ac
m4_define([AX_FOO],
[m4_pushdef([DOWN], m4_translit([$1], [A-Z], [a-z]))dnl
m4_pushdef([CACHE], ac_cv_path_lib_[]DOWN)dnl
AC_CACHE_CHECK([for UP CFLAGS],
               [CACHE[]_cflags],
               [CACHE[]_cflags=`$UP[]_CONFIG $LDOWN[]_config_args \
                                  LIBCONFIG_CFLAGS`])
m4_popdef([CACHE])
m4_popdef([DOWN])
])

AC_INIT
AX_FOO(pbar)
/tmp % autoconf -f
/usr/local/bin/m4: configure.ac: 13: m4_bregexp: bad regular expression `test 
"${CACHE[]_cflags+set}" = set': Unmatched [ or [^
/usr/local/bin/m4: configure.ac: 13: m4_bregexp: bad regular expression 
`$CACHE[]_cflags': Unmatched [ or [^
/usr/local/bin/m4: configure.ac: 13: m4_bregexp: bad regular expression 
`$CACHE[]_cflags': Unmatched [ or [^

This was a 2.53a a few days ago.

/tmp % PATH=$ace/tests:$PATH autoconf -f
/tmp %

this is the current CVS Autoconf.  So the problem is gone.  Sorry for the
confusion.  We plan to issue 2.54 in the near future.

| Another question is upgrading between different versions of autoconf.
| Are there any version-specific macros I can use to cater for use with
| incompatible versions of automake? (In m4 macros, not configure.ac.)

I'm sorry, I don't understand exactly what you mean here.



reply via email to

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