21.5
I'm going to do a bit of testing myself, and unless something really
unexpected happens in the tests, or Malcolm throws an exception, I'll
commit in a day or so under this ChangeLog:
2006-07-26 Malcolm Purvis <malcolmp(a)xemacs.org>
* configure.ac (XE_CDR): m4_cdr differs in autoconf 2.59 and 2.60.
(XE_EXPAND_COMPLEX_OPTIONS): Use XE_CDR, not m4_cdr.
>>>> "Malcolm" == Malcolm Purvis
<malcolmp(a)xemacs.org> writes:
Malcolm> The solution to the compatibility question is to make our
Malcolm> own copy of the 2.60 m4_cdr so that we can use it with
Malcolm> both versions of autoconf. Attached is a patch that does
Malcolm> this. When run through 2.59 it produces a copy of
Malcolm> configure that is identical to what is in CVS.
OK, thanks!
Malcolm> Looking through the release notes of 2.60 I see that the
Malcolm> definitions (but not the values) of datadir, infodir and
Malcolm> mandir have changed. This will have to be looked into.
OK. If you run into more real life, let me know, and I can do that
(but probably at about 1/10 the speed you'll achieve ;-).
Index: configure.ac
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/configure.ac,v
retrieving revision 1.47
diff -u -r1.47 configure.ac
--- configure.ac 2006/07/19 19:35:25 1.47
+++ configure.ac 2006/07/25 02:12:44
@@ -22,8 +22,6 @@
dnl Due to a dependence on the implementation of certain internal autoconf
dnl macros, die if any version other than 2.59 is used.
AC_PREREQ(2.59)dnl
-m4_if(m4_version_compare(m4_defn([m4_PACKAGE_VERSION]), [2.59]), 1,
- [m4_fatal([This script can only be generated with autoconf 2.59])], [])dnl
AC_INIT([XEmacs],[21.5],[xemacs-beta(a)xemacs.org])dnl
AC_CONFIG_SRCDIR(src/lisp.h)dnl
dnl
@@ -231,6 +229,13 @@
for W in $2; do if test -z "$T"; then T="$W"; else T="$T
$W"; fi; done
$1="$T"
])dnl XE_SPACE
+dnl Autoconf 2.59 and 2.60 have slightly different versions of m4_cdr that
+dnl return different values for an empty list. XE_CDR is a copy of the 2.60
+dnl version which will be used with both versions.
+define([XE_CDR],
+[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])],
+ [$#], 1, [],
+ [m4_dquote(m4_shift($@))])])dnl
dnl
dnl XE_MERGED_ARG(FEATURE, HELP-STRING, [ACTION-IF-TRUE], [ACTION-IF-FALSE])
dnl ------------------------------------------------------------------------
@@ -379,9 +384,9 @@
dnl Internal macro to recursively expand all the options in the option list.
dnl
define([XE_EXPAND_COMPLEX_OPTIONS],
-[m4_if([$2], [[]], [],
+[m4_if([$2], [], [],
[XE_EXPAND_COMPLEX_OPTION([$1], m4_fst($2))[]dnl
-XE_EXPAND_COMPLEX_OPTIONS([$1], m4_cdr($2))])])dnl
+XE_EXPAND_COMPLEX_OPTIONS([$1], XE_CDR($2))])])dnl
dnl
dnl XE_INIT_COMPLEX_OPTION(prefix, option_list)
dnl -------------------------------------------
--
School of Systems and Information Engineering
http://turnbull.sk.tsukuba.ac.jp
University of Tsukuba Tennodai 1-1-1 Tsukuba 305-8573 JAPAN
Ask not how you can "do" free software business;
ask what your business can "do for" free software.