-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 According to BJ Terry on 9/15/2008 11:36 PM: > Eric, > > It appears that you are right, and thanks for your help. When I upgraded > to 2.63 on my machine it now exhibits the same problem. Thanks for the investigation. And sadly, this means that both 2.62 and 2.63 are completely unusable with Erlang (maybe this warrants a 2.64 release soon?) > > I guess to fix this you would change it to read > > # AC_LANG(Erlang) > # --------------- > m4_define([AC_LANG(Erlang)], > [ac_ext=erl > ac_compile='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&AS_MESSAGE_LOG_FD' > ac_link='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&AS_MESSAGE_LOG_FD ; > echo "#!/bin/sh" > conftest$ac_exeext ; $as_echo $ERL -run conftest > start -run init stop -noshell >> conftest$ac_exeext ; chmod +x > conftest$ac_exeext' > ]) > > But why is there another echo statement in there? Do they each do > something different? Yes. 'echo "#!/bin/sh"' is safe (# cannot be confused with an option, and the entire string contains no \). 'echo $ERL' is NOT safe ($ERL might begin with a -, and be confused with an option, or might contain \, which is not portable). Hence the use of AS_ECHO, which guarantees the output of an echo statement that will do the right thing. The problem is that AS_ECHO was overquoted (and the testsuite does not adequately test Erlang, or this would have been caught more than a year ago). Your proposed patch is insufficient (AS_ECHO does other things, such as ensure that $as_echo is defined prior to this point in the script). But it is along the right lines; the AS_ECHO must be expanded (the bug was that the # was underquoted, thus the AS_ECHO was intepreted as part of an m4 comment; worse yet, this meant that the normal m4_pattern_forbid that is supposed to catch unexpanded macros did not see it, because it does not look in comments). I'm committing this: - -- Don't work too hard, make some time for fun as well! Eric Blake ebb9@xxxxxxx -----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 iEYEARECAAYFAkjPqVYACgkQ84KuGfSFAYAtFgCeKYfS2DlDybUPC4lvejKpCRxl cuMAoJ7BLRGu68GYthQFk6rlhtDy7HHk =Yj9Y -----END PGP SIGNATURE-----
>From c0215a0bb65ba266a1192b2cf32b64cfa4ef0275 Mon Sep 17 00:00:00 2001 From: Eric Blake <ebb9@xxxxxxx> Date: Tue, 16 Sep 2008 06:37:51 -0600 Subject: [PATCH] Fix Erlang regression, introduced 2006-11-17. * lib/autoconf/erlang.m4 (AC_LANG(Erlang)): Avoid overquoting. * NEWS: Mention this fix. * THANKS: Update. Reported by BJ Terry. Signed-off-by: Eric Blake <ebb9@xxxxxxx> --- ChangeLog | 8 ++++++++ NEWS | 5 +++++ THANKS | 1 + lib/autoconf/erlang.m4 | 4 ++-- 4 files changed, 16 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index f01284d..448ae92 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2008-09-16 Eric Blake <ebb9@xxxxxxx> + + Fix Erlang regression, introduced 2006-11-17. + * lib/autoconf/erlang.m4 (AC_LANG(Erlang)): Avoid overquoting. + * NEWS: Mention this fix. + * THANKS: Update. + Reported by BJ Terry. + 2008-09-13 Ralf Wildenhues <Ralf.Wildenhues@xxxxxx> * lib/autoconf/general.m4 (AC_CONFIG_AUX_DIRS): Improve a bit. diff --git a/NEWS b/NEWS index 4c997ad..0b027a1 100644 --- a/NEWS +++ b/NEWS @@ -1,5 +1,10 @@ GNU Autoconf NEWS - User visible changes. +* Major changes in Autoconf 2.64 (????-??-??) [stable] + Released by Eric Blake, based on git versions 2.63.*. + +** AC_LANG_ERLANG works once again (regression introduced in 2.61a). + * Major changes in Autoconf 2.63 (2008-09-09) [stable] Released by Eric Blake, based on git versions 2.62.*. diff --git a/THANKS b/THANKS index f1e2b04..f39e949 100644 diff --git a/lib/autoconf/erlang.m4 b/lib/autoconf/erlang.m4 index 7c2859c..9bed007 100644 --- a/lib/autoconf/erlang.m4 +++ b/lib/autoconf/erlang.m4 @@ -1,6 +1,6 @@ # This file is part of Autoconf. -*- Autoconf -*- # Erlang/OTP language support. -# Copyright (C) 2006 Free Software Foundation, Inc. +# Copyright (C) 2006, 2008 Free Software Foundation, Inc. # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -124,7 +124,7 @@ fi m4_define([AC_LANG(Erlang)], [ac_ext=erl ac_compile='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&AS_MESSAGE_LOG_FD' -ac_link='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&AS_MESSAGE_LOG_FD ; echo "#!/bin/sh" > conftest$ac_exeext ; AS_ECHO(["\"$ERL\" -run conftest start -run init stop -noshell"]) >> conftest$ac_exeext ; chmod +x conftest$ac_exeext' +ac_link='$ERLC $ERLCFLAGS -b beam conftest.$ac_ext >&AS_MESSAGE_LOG_FD ; echo "[#]!/bin/sh" > conftest$ac_exeext ; AS_ECHO(["\"$ERL\" -run conftest start -run init stop -noshell"]) >> conftest$ac_exeext ; chmod +x conftest$ac_exeext' ]) -- 1.6.0
_______________________________________________ Autoconf mailing list Autoconf@xxxxxxx http://lists.gnu.org/mailman/listinfo/autoconf