toolchain/gcc: add support for gcc-4.3.5
[openwrt/svn-archive/archive.git] / toolchain / gcc / patches / 4.3.5 / 105-libtool.patch
1 2008-03-02 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
2
3 Backport from upstream Libtool:
4
5 2007-10-12 Eric Blake <ebb9@byu.net>
6
7 Deal with Autoconf 2.62's semantic change in m4_append.
8 * ltsugar.m4 (lt_append): Replace broken versions of
9 m4_append.
10 (lt_if_append_uniq): Don't require separator to be overquoted, and
11 avoid broken m4_append.
12 (lt_dict_add): Fix typo.
13 * libtool.m4 (_LT_DECL): Don't overquote separator.
14
15 --- a/libtool.m4
16 +++ b/libtool.m4
17 @@ -319,7 +319,7 @@ m4_bpatsubst([m4_bpatsubst([$1], [^ *],
18 # VALUE may be 0, 1 or 2 for a computed quote escaped value based on
19 # VARNAME. Any other value will be used directly.
20 m4_define([_LT_DECL],
21 -[lt_if_append_uniq([lt_decl_varnames], [$2], [[, ]],
22 +[lt_if_append_uniq([lt_decl_varnames], [$2], [, ],
23 [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name],
24 [m4_ifval([$1], [$1], [$2])])
25 lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3])
26 --- a/ltsugar.m4
27 +++ b/ltsugar.m4
28 @@ -1,13 +1,13 @@
29 # ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*-
30 #
31 -# Copyright (C) 2004, 2005 Free Software Foundation, Inc.
32 +# Copyright (C) 2004, 2005, 2007 Free Software Foundation, Inc.
33 # Written by Gary V. Vaughan.
34 #
35 # This file is free software; the Free Software Foundation gives
36 # unlimited permission to copy and/or distribute it, with or without
37 # modifications, as long as this notice is preserved.
38
39 -# serial 3 ltsugar.m4
40 +# serial 4 ltsugar.m4
41
42 # This is to help aclocal find these macros, as it can't see m4_define.
43 AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])])
44 @@ -46,6 +46,20 @@ m4_define([lt_cdr],
45 m4_define([lt_unquote], $1)
46
47
48 +# lt_append(MACRO-NAME, STRING, [SEPARATOR])
49 +# ------------------------------------------
50 +# Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'.
51 +# Note that neither SEPARATOR nor STRING are expanded. No SEPARATOR is
52 +# output if MACRO-NAME was previously undefined (different than defined
53 +# and empty).
54 +# This macro is needed until we can rely on Autoconf 2.62, since earlier
55 +# versions of m4 mistakenly expanded SEPARATOR.
56 +m4_define([lt_append],
57 +[m4_define([$1],
58 + m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])])
59 +
60 +
61 +
62 # lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...])
63 # ----------------------------------------------------------
64 # Produce a SEP delimited list of all paired combinations of elements of
65 @@ -67,10 +81,10 @@ m4_define([lt_combine],
66 # by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ.
67 m4_define([lt_if_append_uniq],
68 [m4_ifdef([$1],
69 - [m4_bmatch($3[]m4_defn([$1])$3, $3[]m4_re_escape([$2])$3,
70 - [$5],
71 - [m4_append([$1], [$2], [$3])$4])],
72 - [m4_append([$1], [$2], [$3])$4])])
73 + [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1],
74 + [lt_append([$1], [$2], [$3])$4],
75 + [$5])],
76 + [lt_append([$1], [$2], [$3])$4])])
77
78
79 # lt_dict_add(DICT, KEY, VALUE)