[Top][All Lists]

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

Re: Aclocal bug?

From: Eric Blake-1
Subject: Re: Aclocal bug?
Date: Wed, 15 Nov 2006 13:48:03 -0800 (PST)

Hi Stepan, Bruno,

> Ccing also bug-gnu-gettext, though I'm not sure whether an action is
> needed for gettext.m4.]
> The cause is the following bug:
> $ echo "ifdef(\`MAC', bug)" |m4 --trace=MAC
> bug
> I observed it in 1.4.[34], while 1.4.5 seems to be fixed.
> autoconf calls autom4te with (among other options)
>       --preselect AM_GNU_GETTEXT_INTL_SUBDIR
> which is trasformed to --trace=AM_GNU_GETTEXT_INTL_SUBDIR on the m4
> command line.  And because the expansion of AM_GNU_GETTEXT([external])
> contains something like (see ltdl/m4/gettext.m4):
>             [AC_REQUIRE([AM_INTL_SUBDIR])])

That looks like a bug in gettext.m4 to me - autoconf uses m4sugar,
where the macro is named m4_ifdef, not ifdef.  How is gettext.m4
getting away with non-m4sugar macros in the first place?

> the buggy m4 expands AM_INTL_SUBDIR though it should not.

You know, it is STILL possible to make gettext.m4 work atop
m4 1.4.4 and earlier, in spite of this bug, using this trick to detect
the bug:

$ m4 --version | head -n1
GNU M4 1.4.3
$ m4 -tfoo <<\EOF

and this trick to neutralize the bug:
$ m4 -tfoo <<\EOF

Or in autoconf terms:

dnl work around bug in M4 1.4.4 and earlier
dnl if defined, and definition is empty, but expansion is non-empty, then
dnl we have hit the m4 bug; pop the bogus definition

followed by your original code that made decisions based on
whether AM_GNU_GETTEXT_INTL_SUBDIR is defined.

In other words, using this patch might make it so that
autoconf 2.61 can still get by with M4 1.4.4 and earlier.

Eric Blake

View this message in context: 
Sent from the Gnu - Utils - Bugs mailing list archive at Nabble.com.

reply via email to

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