Sorry for the self-replies.
* Ralf Wildenhues wrote on Sun, Jun 12, 2005 at 01:36:43PM CEST:
> > * Christoph Egger wrote on Sun, Jun 12, 2005 at 01:16:32PM CEST:
> > >
> > > Recent changes in the libtool-2-0 branch causes an
> > > infinite m4 loop.
*snip*
> Argh. Now I understand: it works with CVS Autoconf, but it breaks with
> 2.59. D*mn. :(
Quick hack: define our own (fixed) versions of m4_car and m4_cdr, so we
are independent of the Autoconf version used.
Does anybody know a better solution?
Regards,
Ralf
Index: m4/ltsugar.m4
===================================================================
RCS file: /cvsroot/libtool/libtool/m4/ltsugar.m4,v
retrieving revision 1.2.2.2
diff -u -r1.2.2.2 ltsugar.m4
--- m4/ltsugar.m4 11 Jun 2005 11:12:28 -0000 1.2.2.2
+++ m4/ltsugar.m4 12 Jun 2005 11:59:02 -0000
@@ -32,6 +32,19 @@
])
+# lt_car(LIST)
+# lt_cdr(LIST)
+# ------------
+# Manipulate m4 lists.
+# These macros are necessary as long as will still need to support
+# Autoconf-2.59 which quotes differently.
+m4_define([lt_car], [[$1]])
+m4_define([lt_cdr],
+[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])],
+ [$#], 1, [],
+ [m4_dquote(m4_shift($@))])])
+
+
# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...])
# ----------------------------------------------------------
# Produce a SEP delimited list of all paired combinations of elements of
@@ -40,8 +53,8 @@
m4_define([lt_combine],
[m4_if([$2], [], [],
[lt_join(m4_quote(m4_default([$1], [, ])),
- _$0([$1], m4_car($2)[$3], m4_shiftn(3, $@)),
- $0([$1], m4_cdr($2), m4_shiftn(2, $@)))])])
+ _$0([$1], lt_car($2)[$3], m4_shiftn(3, $@)),
+ $0([$1], lt_cdr($2), m4_shiftn(2, $@)))])])
m4_define([_lt_combine],
[m4_if([$3], [], [],
[lt_join(m4_quote(m4_default([$1], [, ])),
_______________________________________________
Bug-libtool mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/bug-libtool