[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Obsolete AC_LANG_SAVE/AC_LANG_RESTORE
From: |
Ralf Wildenhues |
Subject: |
Re: Obsolete AC_LANG_SAVE/AC_LANG_RESTORE |
Date: |
Mon, 25 May 2009 23:49:20 +0200 |
User-agent: |
Mutt/1.5.18 (2008-05-17) |
Hi Eric,
* Eric Blake wrote on Mon, May 25, 2009 at 02:52:37PM CEST:
> According to Ralf Wildenhues on 5/24/2009 7:52 AM:
> >> libtool 2.2.6a uses AC_LANG_SAVE/AC_LANG_RESTORE in libtool.m4.
> >> These macros have been obsoleted by Autoconf.
> >>
> >> Could they be switched to LANG_PUSH/AC_LANG_POP in future releases?
> >
> > Not really; I don't think the latter provide equivalent functionality;
> > at least, if memory serves correctly.
>
> In this case, there is nothing more to AC_LANG_SAVE/AC_LANG_RESTORE than
> thin AU_DEFUN wrappers around AC_LANG_POP. They provide equivalent
> functionality.
OK, I looked now. You can call AC_LANG_SAVE/AC_LANG_RESTORE without
arguments, and the restore will do TRT, namely restoring the ac_ext,
ac_compile and ac_link settings that we overwrote in the mean time.
This is useful if the language you are moving to is not defined, such as
Java and Windows Resource. I don't see how to do it with AC_LANG_PUSH
without argument, or with one not known to Autoconf:
configure.ac:189: error: AC_LANG: unknown language:
../../../autoconf/lib/autoconf/lang.m4:104: _AC_LANG_SET is expanded from...
../../../autoconf/lib/autoconf/lang.m4:120: AC_LANG_PUSH is expanded from...
libltdl/m4/libtool.m4:6837: _LT_LANG_GCJ_CONFIG is expanded from...
libltdl/m4/libtool.m4:814: _LT_LANG is expanded from...
libltdl/m4/libtool.m4:797: LT_LANG is expanded from...
configure.ac:189: the top level
configure.ac:189: error: AC_LANG: unknown language: Java
../../../autoconf/lib/autoconf/lang.m4:104: _AC_LANG_SET is expanded from...
../../../autoconf/lib/autoconf/lang.m4:120: AC_LANG_PUSH is expanded from...
libltdl/m4/libtool.m4:6837: _LT_LANG_GCJ_CONFIG is expanded from...
libltdl/m4/libtool.m4:814: _LT_LANG is expanded from...
libltdl/m4/libtool.m4:797: LT_LANG is expanded from...
configure.ac:189: the top level
Probably Libtool should define these languages, or Autoconf should?
Thanks,
Ralf