diff options
author | Zack Weinberg <zackw@panix.com> | 2020-11-15 14:27:38 -0500 |
---|---|---|
committer | Zack Weinberg <zackw@panix.com> | 2020-11-15 14:27:38 -0500 |
commit | 15acc26a209accd353f5961487dfef3a03e12b4a (patch) | |
tree | a9866760bd8bc2cbebd04f545ab4ee42d70b146d | |
parent | fd633e92cb63f7bb592dcffd2f2871fa28ab189d (diff) | |
download | autoconf-15acc26a209accd353f5961487dfef3a03e12b4a.tar.gz |
Don’t issue obsoletion warnings for AC_LANG_SAVE/RESTORE (#110375)
The most recently released version of libtool.m4 is five years old as
of this commit, and no new release is likely to appear anytime soon.
It uses AC_LANG_SAVE and AC_LANG_RESTORE, in a way that doesn’t
obviously translate to AC_LANG_PUSH and AC_LANG_POP. This will need
to be fixed by libtool upstream. Until that actually happens, disable
the -Wobsolete warnings for AC_LANG_SAVE and AC_LANG_RESTORE. (They
are still documented as obsolete in the manual, as they have been for
many years.)
Fixes bug #110375.
* lib/autoconf/lang.m4 (AC_LANG_SAVE, AC_LANG_RESTORE): Define with
AC_DEFUN, not AU_DEFUN; remove manual -Wobsolete warnings.
-rw-r--r-- | lib/autoconf/lang.m4 | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/lib/autoconf/lang.m4 b/lib/autoconf/lang.m4 index 9e6e3b35..b1e730a2 100644 --- a/lib/autoconf/lang.m4 +++ b/lib/autoconf/lang.m4 @@ -119,20 +119,25 @@ m4_popdef([$0 OLD])dnl # AC_LANG_SAVE # ------------ # Save the current language, but don't change language. -AU_DEFUN([AC_LANG_SAVE], -[[AC_LANG_SAVE]], -[Instead of using `AC_LANG', `AC_LANG_SAVE', and `AC_LANG_RESTORE', -you should use `AC_LANG_PUSH' and `AC_LANG_POP'.]) +# XXX 2020-11-15: This macro is obsolete, but we do not define it with +# AU_DEFUN because autoupdate can't fix it, and we don't issue an +# obsoletion warning yet either, because it is used in the most +# recently released version of libtool.m4, which is not fair to expect +# packagers to tinker with. Revisit after libtool makes a release +# with their code updated. AC_DEFUN([AC_LANG_SAVE], -[m4_pushdef([_AC_LANG], _AC_LANG)dnl -m4_warn([obsolete], [The macro `AC_LANG_SAVE' is obsolete. -You should run autoupdate.])]) +[m4_pushdef([_AC_LANG], _AC_LANG)]) # AC_LANG_RESTORE # --------------- # Restore the current language from the stack. -AU_DEFUN([AC_LANG_RESTORE], [AC_LANG_POP($@)]) +# XXX 2020-11-15: This macro is obsolete, but we do not define it with +# AU_DEFUN because autoupdate can't fix it properly, and we don't issue +# an obsoletion warning because it, like AC_LANG_SAVE, is used by the +# most recently released version of libtool.m4. +AC_DEFUN([AC_LANG_RESTORE], +[AC_LANG_POP($@)]) # _AC_LANG_ABBREV |