summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2013-02-26 12:55:24 -0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2013-02-28 23:15:49 +0000
commit0d2b60e2d657c17beb1242893a18707465843e01 (patch)
tree7bdd989c3273ebd053c53435a71e39fc50a2a461 /meta
parent68ddf00775513e39fd69ad4c9b6ef2bb620ca823 (diff)
downloadpoky-0d2b60e2d657c17beb1242893a18707465843e01.tar.gz
binutils: Delete recipes for 2.22
We have 2.23.1 as default now. (From OE-Core rev: a2f5a228422f9807fa21de88ad589853817695f8) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r--meta/recipes-devtools/binutils/binutils-2.22.inc51
-rw-r--r--meta/recipes-devtools/binutils/binutils-cross-canadian_2.22.bb3
-rw-r--r--meta/recipes-devtools/binutils/binutils-cross_2.22.bb3
-rw-r--r--meta/recipes-devtools/binutils/binutils-crosssdk_2.22.bb14
-rw-r--r--meta/recipes-devtools/binutils/binutils/0001-PR-ld-13470.patch82
-rw-r--r--meta/recipes-devtools/binutils/binutils/0006-mips-dis.c-print_insn_micromips-Rename-local-variabl.patch634
-rw-r--r--meta/recipes-devtools/binutils/binutils/0019-PR-ld-13468.patch46
-rw-r--r--meta/recipes-devtools/binutils/binutils/0028-Backport-from-mainline.patch139
-rw-r--r--meta/recipes-devtools/binutils/binutils/0035-2011-12-19-Chung-Lin-Tang-cltang-codesourcery.com.patch47
-rw-r--r--meta/recipes-devtools/binutils/binutils/0036-2011-12-19-Chung-Lin-Tang-cltang-codesourcery.com.patch214
-rw-r--r--meta/recipes-devtools/binutils/binutils/0037-2011-12-19-Chung-Lin-Tang-cltang-codesourcery.com.patch1068
-rw-r--r--meta/recipes-devtools/binutils/binutils/0039-emulparams-elf32bmip.sh-OTHER_SECTIONS-Put-.mdebug.-.patch49
-rw-r--r--meta/recipes-devtools/binutils/binutils/0052-gas.patch83
-rw-r--r--meta/recipes-devtools/binutils/binutils/0055-Remove-ABI_64_P-check-on-R_X86_64_PCXX.patch176
-rw-r--r--meta/recipes-devtools/binutils/binutils/0078-PR-binutils-13622.patch48
-rw-r--r--meta/recipes-devtools/binutils/binutils/0144-timer.cc-include-unistd.h.patch32
-rw-r--r--meta/recipes-devtools/binutils/binutils/0166-2012-04-27-Doug-Kwan-dougkwan-google.com.patch169
-rw-r--r--meta/recipes-devtools/binutils/binutils/0182-PR-ld-13991.patch1617
-rw-r--r--meta/recipes-devtools/binutils/binutils/binutils-2.19.1-ld-sysroot.patch39
-rw-r--r--meta/recipes-devtools/binutils/binutils/binutils-armv5e.patch24
-rw-r--r--meta/recipes-devtools/binutils/binutils/binutils-poison.patch255
-rw-r--r--meta/recipes-devtools/binutils/binutils/binutils-powerpc-e5500.patch936
-rw-r--r--meta/recipes-devtools/binutils/binutils/binutils-pr12366.patch428
-rw-r--r--meta/recipes-devtools/binutils/binutils/binutils-uclibc-100-uclibc-conf.patch40
-rw-r--r--meta/recipes-devtools/binutils/binutils/binutils-uclibc-300-001_ld_makefile_patch.patch55
-rw-r--r--meta/recipes-devtools/binutils/binutils/binutils-uclibc-300-006_better_file_error.patch45
-rw-r--r--meta/recipes-devtools/binutils/binutils/binutils-uclibc-300-012_check_ldrunpath_length.patch49
-rw-r--r--meta/recipes-devtools/binutils/binutils/binutils-uclibc-gas-needs-libm.patch38
-rw-r--r--meta/recipes-devtools/binutils/binutils/binutils-x86_64_i386_biarch.patch29
-rw-r--r--meta/recipes-devtools/binutils/binutils/clone-shadow.patch79
-rw-r--r--meta/recipes-devtools/binutils/binutils/libiberty_path_fix.patch22
-rw-r--r--meta/recipes-devtools/binutils/binutils/libtool-2.4-update.patch18705
-rw-r--r--meta/recipes-devtools/binutils/binutils/libtool-rpath-fix.patch39
-rw-r--r--meta/recipes-devtools/binutils/binutils/mips64-default-ld-emulation.patch49
-rw-r--r--meta/recipes-devtools/binutils/binutils/relocatable_sdk.patch49
-rw-r--r--meta/recipes-devtools/binutils/binutils/rpath-sysroot.patch38
-rw-r--r--meta/recipes-devtools/binutils/binutils_2.22.bb35
37 files changed, 0 insertions, 25429 deletions
diff --git a/meta/recipes-devtools/binutils/binutils-2.22.inc b/meta/recipes-devtools/binutils/binutils-2.22.inc
deleted file mode 100644
index 9697242379..0000000000
--- a/meta/recipes-devtools/binutils/binutils-2.22.inc
+++ /dev/null
@@ -1,51 +0,0 @@
1PR = "r17"
2
3LIC_FILES_CHKSUM="\
4 file://src-release;endline=17;md5=4830a9ef968f3b18dd5e9f2c00db2d35\
5 file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552\
6 file://COPYING.LIB;md5=9f604d8a4f8e74f4f5140845a21b6674\
7 file://COPYING3;md5=d32239bcb673463ab874e80d47fae504\
8 file://COPYING3.LIB;md5=6a6a8e020838b23406c81b19c1d46df6\
9 file://gas/COPYING;md5=d32239bcb673463ab874e80d47fae504\
10 file://include/COPYING;md5=59530bdf33659b29e73d4adb9f9f6552\
11 file://include/COPYING3;md5=d32239bcb673463ab874e80d47fae504\
12 file://libiberty/COPYING.LIB;md5=a916467b91076e631dd8edb7424769c7\
13 file://bfd/COPYING;md5=d32239bcb673463ab874e80d47fae504\
14 "
15
16SRC_URI = "\
17 ${GNU_MIRROR}/binutils/binutils-${PV}.tar.bz2 \
18 file://binutils-uclibc-100-uclibc-conf.patch \
19 file://binutils-uclibc-300-001_ld_makefile_patch.patch \
20 file://binutils-uclibc-300-006_better_file_error.patch \
21 file://binutils-uclibc-300-012_check_ldrunpath_length.patch \
22 file://binutils-uclibc-gas-needs-libm.patch \
23 file://binutils-x86_64_i386_biarch.patch \
24 file://libtool-2.4-update.patch \
25 file://binutils-2.19.1-ld-sysroot.patch \
26 file://libiberty_path_fix.patch \
27 file://binutils-poison.patch \
28 file://libtool-rpath-fix.patch \
29 file://clone-shadow.patch \
30 file://binutils-powerpc-e5500.patch \
31 file://binutils-armv5e.patch \
32 file://mips64-default-ld-emulation.patch \
33 file://0001-PR-ld-13470.patch \
34 file://rpath-sysroot.patch \
35 file://0006-mips-dis.c-print_insn_micromips-Rename-local-variabl.patch \
36 file://0019-PR-ld-13468.patch \
37 file://0028-Backport-from-mainline.patch \
38 file://0035-2011-12-19-Chung-Lin-Tang-cltang-codesourcery.com.patch \
39 file://0036-2011-12-19-Chung-Lin-Tang-cltang-codesourcery.com.patch \
40 file://0037-2011-12-19-Chung-Lin-Tang-cltang-codesourcery.com.patch \
41 file://0039-emulparams-elf32bmip.sh-OTHER_SECTIONS-Put-.mdebug.-.patch \
42 file://0052-gas.patch \
43 file://0055-Remove-ABI_64_P-check-on-R_X86_64_PCXX.patch \
44 file://0078-PR-binutils-13622.patch \
45 file://0144-timer.cc-include-unistd.h.patch \
46 file://0166-2012-04-27-Doug-Kwan-dougkwan-google.com.patch \
47 file://0182-PR-ld-13991.patch \
48 "
49
50SRC_URI[md5sum] = "ee0f10756c84979622b992a4a61ea3f5"
51SRC_URI[sha256sum] = "6c7af8ed1c8cf9b4b9d6e6fe09a3e1d3d479fe63984ba8b9b26bf356b6313ca9"
diff --git a/meta/recipes-devtools/binutils/binutils-cross-canadian_2.22.bb b/meta/recipes-devtools/binutils/binutils-cross-canadian_2.22.bb
deleted file mode 100644
index 5dbaa03017..0000000000
--- a/meta/recipes-devtools/binutils/binutils-cross-canadian_2.22.bb
+++ /dev/null
@@ -1,3 +0,0 @@
1require binutils.inc
2require binutils-${PV}.inc
3require binutils-cross-canadian.inc
diff --git a/meta/recipes-devtools/binutils/binutils-cross_2.22.bb b/meta/recipes-devtools/binutils/binutils-cross_2.22.bb
deleted file mode 100644
index fbd1f7d25a..0000000000
--- a/meta/recipes-devtools/binutils/binutils-cross_2.22.bb
+++ /dev/null
@@ -1,3 +0,0 @@
1require binutils.inc
2require binutils-${PV}.inc
3require binutils-cross.inc
diff --git a/meta/recipes-devtools/binutils/binutils-crosssdk_2.22.bb b/meta/recipes-devtools/binutils/binutils-crosssdk_2.22.bb
deleted file mode 100644
index c93654992a..0000000000
--- a/meta/recipes-devtools/binutils/binutils-crosssdk_2.22.bb
+++ /dev/null
@@ -1,14 +0,0 @@
1require binutils-cross_${PV}.bb
2
3inherit crosssdk
4
5PR = "r1"
6
7PROVIDES = "virtual/${TARGET_PREFIX}binutils-crosssdk"
8
9
10SRC_URI += "file://relocatable_sdk.patch"
11
12do_configure_prepend () {
13 sed -i 's#/usr/local/lib /lib /usr/lib#${SDKPATHNATIVE}/lib ${SDKPATHNATIVE}/usr/lib /usr/local/lib /lib /usr/lib#' ${S}/ld/configure.tgt
14}
diff --git a/meta/recipes-devtools/binutils/binutils/0001-PR-ld-13470.patch b/meta/recipes-devtools/binutils/binutils/0001-PR-ld-13470.patch
deleted file mode 100644
index 0a0e064451..0000000000
--- a/meta/recipes-devtools/binutils/binutils/0001-PR-ld-13470.patch
+++ /dev/null
@@ -1,82 +0,0 @@
1From 82fdddd1c4e37881db9b4c6a944261521c6f10ac Mon Sep 17 00:00:00 2001
2From: Alan Modra <amodra@bigpond.net.au>
3Date: Sat, 3 Dec 2011 00:57:59 +0000
4Subject: [PATCH] PR ld/13470 * elf32-ppc.c
5 (ppc_elf_copy_indirect_symbol): Revert substantive
6 change in 2011-07-01 commit. Comment. *
7 elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
8
9---
10 bfd/ChangeLog | 7 +++++++
11 bfd/elf32-ppc.c | 14 ++++++++++----
12 bfd/elf64-ppc.c | 14 ++++++++++----
13 3 files changed, 27 insertions(+), 8 deletions(-)
14
15
16Upstream-Status: Backport
17
18Signed-off-by: Khem Raj <raj.khem@gmail.com>
19Index: binutils-2.22/bfd/elf32-ppc.c
20===================================================================
21--- binutils-2.22.orig/bfd/elf32-ppc.c 2011-11-21 01:29:21.000000000 -0800
22+++ binutils-2.22/bfd/elf32-ppc.c 2012-05-31 14:28:48.273784929 -0700
23@@ -2987,10 +2987,6 @@
24 edir->elf.needs_plt |= eind->elf.needs_plt;
25 edir->elf.pointer_equality_needed |= eind->elf.pointer_equality_needed;
26
27- /* If we were called to copy over info for a weak sym, that's all. */
28- if (eind->elf.root.type != bfd_link_hash_indirect)
29- return;
30-
31 if (eind->dyn_relocs != NULL)
32 {
33 if (edir->dyn_relocs != NULL)
34@@ -3022,6 +3018,16 @@
35 eind->dyn_relocs = NULL;
36 }
37
38+ /* If we were called to copy over info for a weak sym, that's all.
39+ You might think dyn_relocs need not be copied over; After all,
40+ both syms will be dynamic or both non-dynamic so we're just
41+ moving reloc accounting around. However, ELIMINATE_COPY_RELOCS
42+ code in ppc_elf_adjust_dynamic_symbol needs to check for
43+ dyn_relocs in read-only sections, and it does so on what is the
44+ DIR sym here. */
45+ if (eind->elf.root.type != bfd_link_hash_indirect)
46+ return;
47+
48 /* Copy over the GOT refcount entries that we may have already seen to
49 the symbol which just became indirect. */
50 edir->elf.got.refcount += eind->elf.got.refcount;
51Index: binutils-2.22/bfd/elf64-ppc.c
52===================================================================
53--- binutils-2.22.orig/bfd/elf64-ppc.c 2011-11-21 01:29:24.000000000 -0800
54+++ binutils-2.22/bfd/elf64-ppc.c 2012-05-31 14:28:48.285784951 -0700
55@@ -4435,10 +4435,6 @@
56 edir->elf.ref_regular_nonweak |= eind->elf.ref_regular_nonweak;
57 edir->elf.needs_plt |= eind->elf.needs_plt;
58
59- /* If we were called to copy over info for a weak sym, that's all. */
60- if (eind->elf.root.type != bfd_link_hash_indirect)
61- return;
62-
63 /* Copy over any dynamic relocs we may have on the indirect sym. */
64 if (eind->dyn_relocs != NULL)
65 {
66@@ -4471,6 +4467,16 @@
67 eind->dyn_relocs = NULL;
68 }
69
70+ /* If we were called to copy over info for a weak sym, that's all.
71+ You might think dyn_relocs need not be copied over; After all,
72+ both syms will be dynamic or both non-dynamic so we're just
73+ moving reloc accounting around. However, ELIMINATE_COPY_RELOCS
74+ code in ppc64_elf_adjust_dynamic_symbol needs to check for
75+ dyn_relocs in read-only sections, and it does so on what is the
76+ DIR sym here. */
77+ if (eind->elf.root.type != bfd_link_hash_indirect)
78+ return;
79+
80 /* Copy over got entries that we may have already seen to the
81 symbol which just became indirect. */
82 if (eind->elf.got.glist != NULL)
diff --git a/meta/recipes-devtools/binutils/binutils/0006-mips-dis.c-print_insn_micromips-Rename-local-variabl.patch b/meta/recipes-devtools/binutils/binutils/0006-mips-dis.c-print_insn_micromips-Rename-local-variabl.patch
deleted file mode 100644
index 1baf1e839a..0000000000
--- a/meta/recipes-devtools/binutils/binutils/0006-mips-dis.c-print_insn_micromips-Rename-local-variabl.patch
+++ /dev/null
@@ -1,634 +0,0 @@
1Upstream-Status: Backport
2
3From f72b2c498bc98f42048a3bf7f7d7891db9cabcfc Mon Sep 17 00:00:00 2001
4From: Pierre Muller <muller@ics.u-strasbg.fr>
5Date: Fri, 25 Nov 2011 16:57:32 +0000
6Subject: [PATCH 006/262] * mips-dis.c (print_insn_micromips): Rename
7 local variable iprintf to infprintf to
8 avoid shadow warning.
9
10---
11 opcodes/ChangeLog | 5 ++
12 opcodes/mips-dis.c | 188 ++++++++++++++++++++++++++--------------------------
13 2 files changed, 99 insertions(+), 94 deletions(-)
14
152011-11-25 Pierre Muller <muller@ics.u-strasbg.fr>
16
17 * mips-dis.c (print_insn_micromips): Rename local variable iprintf
18 to infprintf to avoid shadow warning.
19
20diff --git a/opcodes/mips-dis.c b/opcodes/mips-dis.c
21index 4e18d8a..72285de 100644
22--- a/opcodes/mips-dis.c
23+++ b/opcodes/mips-dis.c
24@@ -2260,7 +2260,7 @@ print_insn_mips16 (bfd_vma memaddr, struct disassemble_info *info)
25 static int
26 print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
27 {
28- const fprintf_ftype iprintf = info->fprintf_func;
29+ const fprintf_ftype infprintf = info->fprintf_func;
30 const struct mips_opcode *op, *opend;
31 unsigned int lsb, msbd, msb;
32 void *is = info->stream;
33@@ -2307,7 +2307,7 @@ print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
34 status = (*info->read_memory_func) (memaddr + 2, buffer, 2, info);
35 if (status != 0)
36 {
37- iprintf (is, "micromips 0x%x", higher);
38+ infprintf (is, "micromips 0x%x", higher);
39 (*info->memory_error_func) (status, memaddr + 2, info);
40 return -1;
41 }
42@@ -2320,7 +2320,7 @@ print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
43 status = (*info->read_memory_func) (memaddr + 4, buffer, 2, info);
44 if (status != 0)
45 {
46- iprintf (is, "micromips 0x%x", higher);
47+ infprintf (is, "micromips 0x%x", higher);
48 (*info->memory_error_func) (status, memaddr + 4, info);
49 return -1;
50 }
51@@ -2328,7 +2328,7 @@ print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
52 insn = bfd_getb16 (buffer);
53 else
54 insn = bfd_getl16 (buffer);
55- iprintf (is, "0x%x%04x (48-bit insn)", higher, insn);
56+ infprintf (is, "0x%x%04x (48-bit insn)", higher, insn);
57
58 info->insn_type = dis_noninsn;
59 return 6;
60@@ -2341,7 +2341,7 @@ print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
61 status = (*info->read_memory_func) (memaddr + 2, buffer, 2, info);
62 if (status != 0)
63 {
64- iprintf (is, "micromips 0x%x", higher);
65+ infprintf (is, "micromips 0x%x", higher);
66 (*info->memory_error_func) (status, memaddr + 2, info);
67 return -1;
68 }
69@@ -2371,9 +2371,9 @@ print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
70 {
71 const char *s;
72
73- iprintf (is, "%s", op->name);
74+ infprintf (is, "%s", op->name);
75 if (op->args[0] != '\0')
76- iprintf (is, "\t");
77+ infprintf (is, "\t");
78
79 for (s = op->args; *s != '\0'; s++)
80 {
81@@ -2382,37 +2382,37 @@ print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
82 case ',':
83 case '(':
84 case ')':
85- iprintf (is, "%c", *s);
86+ infprintf (is, "%c", *s);
87 break;
88
89 case '.':
90 delta = GET_OP (insn, OFFSET10);
91 if (delta & 0x200)
92 delta |= ~0x3ff;
93- iprintf (is, "%d", delta);
94+ infprintf (is, "%d", delta);
95 break;
96
97 case '1':
98- iprintf (is, "0x%lx", GET_OP (insn, STYPE));
99+ infprintf (is, "0x%lx", GET_OP (insn, STYPE));
100 break;
101
102 case '<':
103- iprintf (is, "0x%lx", GET_OP (insn, SHAMT));
104+ infprintf (is, "0x%lx", GET_OP (insn, SHAMT));
105 break;
106
107 case '\\':
108- iprintf (is, "0x%lx", GET_OP (insn, 3BITPOS));
109+ infprintf (is, "0x%lx", GET_OP (insn, 3BITPOS));
110 break;
111
112 case '|':
113- iprintf (is, "0x%lx", GET_OP (insn, TRAP));
114+ infprintf (is, "0x%lx", GET_OP (insn, TRAP));
115 break;
116
117 case '~':
118 delta = GET_OP (insn, OFFSET12);
119 if (delta & 0x800)
120 delta |= ~0x7ff;
121- iprintf (is, "%d", delta);
122+ infprintf (is, "%d", delta);
123 break;
124
125 case 'a':
126@@ -2433,34 +2433,34 @@ print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
127 case 'r':
128 case 's':
129 case 'v':
130- iprintf (is, "%s", mips_gpr_names[GET_OP (insn, RS)]);
131+ infprintf (is, "%s", mips_gpr_names[GET_OP (insn, RS)]);
132 break;
133
134 case 'c':
135- iprintf (is, "0x%lx", GET_OP (insn, CODE));
136+ infprintf (is, "0x%lx", GET_OP (insn, CODE));
137 break;
138
139 case 'd':
140- iprintf (is, "%s", mips_gpr_names[GET_OP (insn, RD)]);
141+ infprintf (is, "%s", mips_gpr_names[GET_OP (insn, RD)]);
142 break;
143
144 case 'h':
145- iprintf (is, "0x%lx", GET_OP (insn, PREFX));
146+ infprintf (is, "0x%lx", GET_OP (insn, PREFX));
147 break;
148
149 case 'i':
150 case 'u':
151- iprintf (is, "0x%lx", GET_OP (insn, IMMEDIATE));
152+ infprintf (is, "0x%lx", GET_OP (insn, IMMEDIATE));
153 break;
154
155 case 'j': /* Same as i, but sign-extended. */
156 case 'o':
157 delta = (GET_OP (insn, DELTA) ^ 0x8000) - 0x8000;
158- iprintf (is, "%d", delta);
159+ infprintf (is, "%d", delta);
160 break;
161
162 case 'k':
163- iprintf (is, "0x%x", GET_OP (insn, CACHE));
164+ infprintf (is, "0x%x", GET_OP (insn, CACHE));
165 break;
166
167 case 'n':
168@@ -2472,26 +2472,26 @@ print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
169 if (s_reg_encode != 0)
170 {
171 if (s_reg_encode == 1)
172- iprintf (is, "%s", mips_gpr_names[16]);
173+ infprintf (is, "%s", mips_gpr_names[16]);
174 else if (s_reg_encode < 9)
175- iprintf (is, "%s-%s",
176+ infprintf (is, "%s-%s",
177 mips_gpr_names[16],
178 mips_gpr_names[15 + s_reg_encode]);
179 else if (s_reg_encode == 9)
180- iprintf (is, "%s-%s,%s",
181+ infprintf (is, "%s-%s,%s",
182 mips_gpr_names[16],
183 mips_gpr_names[23],
184 mips_gpr_names[30]);
185 else
186- iprintf (is, "UNKNOWN");
187+ infprintf (is, "UNKNOWN");
188 }
189
190 if (immed & 0x10) /* For ra. */
191 {
192 if (s_reg_encode == 0)
193- iprintf (is, "%s", mips_gpr_names[31]);
194+ infprintf (is, "%s", mips_gpr_names[31]);
195 else
196- iprintf (is, ",%s", mips_gpr_names[31]);
197+ infprintf (is, ",%s", mips_gpr_names[31]);
198 }
199 break;
200 }
201@@ -2504,32 +2504,32 @@ print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
202 break;
203
204 case 'q':
205- iprintf (is, "0x%lx", GET_OP (insn, CODE2));
206+ infprintf (is, "0x%lx", GET_OP (insn, CODE2));
207 break;
208
209 case 't':
210 case 'w':
211- iprintf (is, "%s", mips_gpr_names[GET_OP (insn, RT)]);
212+ infprintf (is, "%s", mips_gpr_names[GET_OP (insn, RT)]);
213 break;
214
215 case 'y':
216- iprintf (is, "%s", mips_gpr_names[GET_OP (insn, RS3)]);
217+ infprintf (is, "%s", mips_gpr_names[GET_OP (insn, RS3)]);
218 break;
219
220 case 'z':
221- iprintf (is, "%s", mips_gpr_names[0]);
222+ infprintf (is, "%s", mips_gpr_names[0]);
223 break;
224
225 case 'B':
226- iprintf (is, "0x%lx", GET_OP (insn, CODE10));
227+ infprintf (is, "0x%lx", GET_OP (insn, CODE10));
228 break;
229
230 case 'C':
231- iprintf (is, "0x%lx", GET_OP (insn, COPZ));
232+ infprintf (is, "0x%lx", GET_OP (insn, COPZ));
233 break;
234
235 case 'D':
236- iprintf (is, "%s", mips_fpr_names[GET_OP (insn, FD)]);
237+ infprintf (is, "%s", mips_fpr_names[GET_OP (insn, FD)]);
238 break;
239
240 case 'E':
241@@ -2540,7 +2540,7 @@ print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
242 'T' format. Therefore, until we gain understanding of
243 cp2 register names, we can simply print the register
244 numbers. */
245- iprintf (is, "$%ld", GET_OP (insn, RT));
246+ infprintf (is, "$%ld", GET_OP (insn, RT));
247 break;
248
249 case 'G':
250@@ -2559,44 +2559,44 @@ print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
251 case 0x000002fc: /* mtc0 */
252 case 0x580000fc: /* dmfc0 */
253 case 0x580002fc: /* dmtc0 */
254- iprintf (is, "%s", mips_cp0_names[GET_OP (insn, RS)]);
255+ infprintf (is, "%s", mips_cp0_names[GET_OP (insn, RS)]);
256 break;
257 default:
258- iprintf (is, "$%ld", GET_OP (insn, RS));
259+ infprintf (is, "$%ld", GET_OP (insn, RS));
260 break;
261 }
262 break;
263
264 case 'H':
265- iprintf (is, "%ld", GET_OP (insn, SEL));
266+ infprintf (is, "%ld", GET_OP (insn, SEL));
267 break;
268
269 case 'K':
270- iprintf (is, "%s", mips_hwr_names[GET_OP (insn, RS)]);
271+ infprintf (is, "%s", mips_hwr_names[GET_OP (insn, RS)]);
272 break;
273
274 case 'M':
275- iprintf (is, "$fcc%ld", GET_OP (insn, CCC));
276+ infprintf (is, "$fcc%ld", GET_OP (insn, CCC));
277 break;
278
279 case 'N':
280- iprintf (is,
281+ infprintf (is,
282 (op->pinfo & (FP_D | FP_S)) != 0
283 ? "$fcc%ld" : "$cc%ld",
284 GET_OP (insn, BCC));
285 break;
286
287 case 'R':
288- iprintf (is, "%s", mips_fpr_names[GET_OP (insn, FR)]);
289+ infprintf (is, "%s", mips_fpr_names[GET_OP (insn, FR)]);
290 break;
291
292 case 'S':
293 case 'V':
294- iprintf (is, "%s", mips_fpr_names[GET_OP (insn, FS)]);
295+ infprintf (is, "%s", mips_fpr_names[GET_OP (insn, FS)]);
296 break;
297
298 case 'T':
299- iprintf (is, "%s", mips_fpr_names[GET_OP (insn, FT)]);
300+ infprintf (is, "%s", mips_fpr_names[GET_OP (insn, FT)]);
301 break;
302
303 case '+':
304@@ -2606,18 +2606,18 @@ print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
305 {
306 case 'A':
307 lsb = GET_OP (insn, EXTLSB);
308- iprintf (is, "0x%x", lsb);
309+ infprintf (is, "0x%x", lsb);
310 break;
311
312 case 'B':
313 msb = GET_OP (insn, INSMSB);
314- iprintf (is, "0x%x", msb - lsb + 1);
315+ infprintf (is, "0x%x", msb - lsb + 1);
316 break;
317
318 case 'C':
319 case 'H':
320 msbd = GET_OP (insn, EXTMSBD);
321- iprintf (is, "0x%x", msbd + 1);
322+ infprintf (is, "0x%x", msbd + 1);
323 break;
324
325 case 'D':
326@@ -2637,30 +2637,30 @@ print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
327 mips_cp0sel_names_len,
328 cp0reg, sel);
329 if (n != NULL)
330- iprintf (is, "%s", n->name);
331+ infprintf (is, "%s", n->name);
332 else
333- iprintf (is, "$%d,%d", cp0reg, sel);
334+ infprintf (is, "$%d,%d", cp0reg, sel);
335 break;
336 }
337
338 case 'E':
339 lsb = GET_OP (insn, EXTLSB) + 32;
340- iprintf (is, "0x%x", lsb);
341+ infprintf (is, "0x%x", lsb);
342 break;
343
344 case 'F':
345 msb = GET_OP (insn, INSMSB) + 32;
346- iprintf (is, "0x%x", msb - lsb + 1);
347+ infprintf (is, "0x%x", msb - lsb + 1);
348 break;
349
350 case 'G':
351 msbd = GET_OP (insn, EXTMSBD) + 32;
352- iprintf (is, "0x%x", msbd + 1);
353+ infprintf (is, "0x%x", msbd + 1);
354 break;
355
356 default:
357 /* xgettext:c-format */
358- iprintf (is,
359+ infprintf (is,
360 _("# internal disassembler error, "
361 "unrecognized modifier (+%c)"),
362 *s);
363@@ -2674,111 +2674,111 @@ print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
364 switch (*s)
365 {
366 case 'a': /* global pointer. */
367- iprintf (is, "%s", mips_gpr_names[28]);
368+ infprintf (is, "%s", mips_gpr_names[28]);
369 break;
370
371 case 'b':
372 regno = micromips_to_32_reg_b_map[GET_OP (insn, MB)];
373- iprintf (is, "%s", mips_gpr_names[regno]);
374+ infprintf (is, "%s", mips_gpr_names[regno]);
375 break;
376
377 case 'c':
378 regno = micromips_to_32_reg_c_map[GET_OP (insn, MC)];
379- iprintf (is, "%s", mips_gpr_names[regno]);
380+ infprintf (is, "%s", mips_gpr_names[regno]);
381 break;
382
383 case 'd':
384 regno = micromips_to_32_reg_d_map[GET_OP (insn, MD)];
385- iprintf (is, "%s", mips_gpr_names[regno]);
386+ infprintf (is, "%s", mips_gpr_names[regno]);
387 break;
388
389 case 'e':
390 regno = micromips_to_32_reg_e_map[GET_OP (insn, ME)];
391- iprintf (is, "%s", mips_gpr_names[regno]);
392+ infprintf (is, "%s", mips_gpr_names[regno]);
393 break;
394
395 case 'f':
396 /* Save lastregno for "mt" to print out later. */
397 lastregno = micromips_to_32_reg_f_map[GET_OP (insn, MF)];
398- iprintf (is, "%s", mips_gpr_names[lastregno]);
399+ infprintf (is, "%s", mips_gpr_names[lastregno]);
400 break;
401
402 case 'g':
403 regno = micromips_to_32_reg_g_map[GET_OP (insn, MG)];
404- iprintf (is, "%s", mips_gpr_names[regno]);
405+ infprintf (is, "%s", mips_gpr_names[regno]);
406 break;
407
408 case 'h':
409 regno = micromips_to_32_reg_h_map[GET_OP (insn, MH)];
410- iprintf (is, "%s", mips_gpr_names[regno]);
411+ infprintf (is, "%s", mips_gpr_names[regno]);
412 break;
413
414 case 'i':
415 regno = micromips_to_32_reg_i_map[GET_OP (insn, MI)];
416- iprintf (is, "%s", mips_gpr_names[regno]);
417+ infprintf (is, "%s", mips_gpr_names[regno]);
418 break;
419
420 case 'j':
421- iprintf (is, "%s", mips_gpr_names[GET_OP (insn, MJ)]);
422+ infprintf (is, "%s", mips_gpr_names[GET_OP (insn, MJ)]);
423 break;
424
425 case 'l':
426 regno = micromips_to_32_reg_l_map[GET_OP (insn, ML)];
427- iprintf (is, "%s", mips_gpr_names[regno]);
428+ infprintf (is, "%s", mips_gpr_names[regno]);
429 break;
430
431 case 'm':
432 regno = micromips_to_32_reg_m_map[GET_OP (insn, MM)];
433- iprintf (is, "%s", mips_gpr_names[regno]);
434+ infprintf (is, "%s", mips_gpr_names[regno]);
435 break;
436
437 case 'n':
438 regno = micromips_to_32_reg_n_map[GET_OP (insn, MN)];
439- iprintf (is, "%s", mips_gpr_names[regno]);
440+ infprintf (is, "%s", mips_gpr_names[regno]);
441 break;
442
443 case 'p':
444 /* Save lastregno for "mt" to print out later. */
445 lastregno = GET_OP (insn, MP);
446- iprintf (is, "%s", mips_gpr_names[lastregno]);
447+ infprintf (is, "%s", mips_gpr_names[lastregno]);
448 break;
449
450 case 'q':
451 regno = micromips_to_32_reg_q_map[GET_OP (insn, MQ)];
452- iprintf (is, "%s", mips_gpr_names[regno]);
453+ infprintf (is, "%s", mips_gpr_names[regno]);
454 break;
455
456 case 'r': /* program counter. */
457- iprintf (is, "$pc");
458+ infprintf (is, "$pc");
459 break;
460
461 case 's': /* stack pointer. */
462 lastregno = 29;
463- iprintf (is, "%s", mips_gpr_names[29]);
464+ infprintf (is, "%s", mips_gpr_names[29]);
465 break;
466
467 case 't':
468- iprintf (is, "%s", mips_gpr_names[lastregno]);
469+ infprintf (is, "%s", mips_gpr_names[lastregno]);
470 break;
471
472 case 'z': /* $0. */
473- iprintf (is, "%s", mips_gpr_names[0]);
474+ infprintf (is, "%s", mips_gpr_names[0]);
475 break;
476
477 case 'A':
478 /* Sign-extend the immediate. */
479 immed = ((GET_OP (insn, IMMA) ^ 0x40) - 0x40) << 2;
480- iprintf (is, "%d", immed);
481+ infprintf (is, "%d", immed);
482 break;
483
484 case 'B':
485 immed = micromips_imm_b_map[GET_OP (insn, IMMB)];
486- iprintf (is, "%d", immed);
487+ infprintf (is, "%d", immed);
488 break;
489
490 case 'C':
491 immed = micromips_imm_c_map[GET_OP (insn, IMMC)];
492- iprintf (is, "0x%lx", immed);
493+ infprintf (is, "0x%lx", immed);
494 break;
495
496 case 'D':
497@@ -2797,50 +2797,50 @@ print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
498
499 case 'F':
500 immed = GET_OP (insn, IMMF);
501- iprintf (is, "0x%x", immed);
502+ infprintf (is, "0x%x", immed);
503 break;
504
505 case 'G':
506 immed = (insn >> MICROMIPSOP_SH_IMMG) + 1;
507 immed = (immed & MICROMIPSOP_MASK_IMMG) - 1;
508- iprintf (is, "%d", immed);
509+ infprintf (is, "%d", immed);
510 break;
511
512 case 'H':
513 immed = GET_OP (insn, IMMH) << 1;
514- iprintf (is, "%d", immed);
515+ infprintf (is, "%d", immed);
516 break;
517
518 case 'I':
519 immed = (insn >> MICROMIPSOP_SH_IMMI) + 1;
520 immed = (immed & MICROMIPSOP_MASK_IMMI) - 1;
521- iprintf (is, "%d", immed);
522+ infprintf (is, "%d", immed);
523 break;
524
525 case 'J':
526 immed = GET_OP (insn, IMMJ) << 2;
527- iprintf (is, "%d", immed);
528+ infprintf (is, "%d", immed);
529 break;
530
531 case 'L':
532 immed = GET_OP (insn, IMML);
533- iprintf (is, "%d", immed);
534+ infprintf (is, "%d", immed);
535 break;
536
537 case 'M':
538 immed = (insn >> MICROMIPSOP_SH_IMMM) - 1;
539 immed = (immed & MICROMIPSOP_MASK_IMMM) + 1;
540- iprintf (is, "%d", immed);
541+ infprintf (is, "%d", immed);
542 break;
543
544 case 'N':
545 immed = GET_OP (insn, IMMN);
546 if (immed == 0)
547- iprintf (is, "%s,%s",
548+ infprintf (is, "%s,%s",
549 mips_gpr_names[16],
550 mips_gpr_names[31]);
551 else
552- iprintf (is, "%s-%s,%s",
553+ infprintf (is, "%s-%s,%s",
554 mips_gpr_names[16],
555 mips_gpr_names[16 + immed],
556 mips_gpr_names[31]);
557@@ -2848,35 +2848,35 @@ print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
558
559 case 'O':
560 immed = GET_OP (insn, IMMO);
561- iprintf (is, "0x%x", immed);
562+ infprintf (is, "0x%x", immed);
563 break;
564
565 case 'P':
566 immed = GET_OP (insn, IMMP) << 2;
567- iprintf (is, "%d", immed);
568+ infprintf (is, "%d", immed);
569 break;
570
571 case 'Q':
572 /* Sign-extend the immediate. */
573 immed = (GET_OP (insn, IMMQ) ^ 0x400000) - 0x400000;
574 immed <<= 2;
575- iprintf (is, "%d", immed);
576+ infprintf (is, "%d", immed);
577 break;
578
579 case 'U':
580 immed = GET_OP (insn, IMMU) << 2;
581- iprintf (is, "%d", immed);
582+ infprintf (is, "%d", immed);
583 break;
584
585 case 'W':
586 immed = GET_OP (insn, IMMW) << 2;
587- iprintf (is, "%d", immed);
588+ infprintf (is, "%d", immed);
589 break;
590
591 case 'X':
592 /* Sign-extend the immediate. */
593 immed = (GET_OP (insn, IMMX) ^ 0x8) - 0x8;
594- iprintf (is, "%d", immed);
595+ infprintf (is, "%d", immed);
596 break;
597
598 case 'Y':
599@@ -2885,12 +2885,12 @@ print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
600 if (immed >= -2 && immed <= 1)
601 immed ^= 0x100;
602 immed = immed << 2;
603- iprintf (is, "%d", immed);
604+ infprintf (is, "%d", immed);
605 break;
606
607 default:
608 /* xgettext:c-format */
609- iprintf (is,
610+ infprintf (is,
611 _("# internal disassembler error, "
612 "unrecognized modifier (m%c)"),
613 *s);
614@@ -2900,7 +2900,7 @@ print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
615
616 default:
617 /* xgettext:c-format */
618- iprintf (is,
619+ infprintf (is,
620 _("# internal disassembler error, "
621 "unrecognized modifier (%c)"),
622 *s);
623@@ -2937,7 +2937,7 @@ print_insn_micromips (bfd_vma memaddr, struct disassemble_info *info)
624 }
625 #undef GET_OP
626
627- iprintf (is, "0x%x", insn);
628+ infprintf (is, "0x%x", insn);
629 info->insn_type = dis_noninsn;
630
631 return length;
632--
6331.7.9.5
634
diff --git a/meta/recipes-devtools/binutils/binutils/0019-PR-ld-13468.patch b/meta/recipes-devtools/binutils/binutils/0019-PR-ld-13468.patch
deleted file mode 100644
index 79d9f48453..0000000000
--- a/meta/recipes-devtools/binutils/binutils/0019-PR-ld-13468.patch
+++ /dev/null
@@ -1,46 +0,0 @@
1Upstream-Status: Backport
2
3From 4c362e4511c4046e230fc9e330bf086753f04338 Mon Sep 17 00:00:00 2001
4From: Alan Modra <amodra@bigpond.net.au>
5Date: Sat, 3 Dec 2011 10:29:17 +0000
6Subject: [PATCH 019/262] PR ld/13468 * elflink.c
7 (bfd_elf_final_link): Don't segfault when checking
8 for DT_TEXTREL and .dynamic does not exist.
9
10---
11 bfd/ChangeLog | 6 ++++++
12 bfd/elflink.c | 9 +++------
13 2 files changed, 9 insertions(+), 6 deletions(-)
14
15 2011-12-03 Alan Modra <amodra@gmail.com>
16
17 PR ld/13468
18 * elflink.c (bfd_elf_final_link): Don't segfault when checking
19 for DT_TEXTREL and .dynamic does not exist.
20
21diff --git a/bfd/elflink.c b/bfd/elflink.c
22index fc4266b..8556cec 100644
23--- a/bfd/elflink.c
24+++ b/bfd/elflink.c
25@@ -11188,15 +11188,12 @@ bfd_elf_final_link (bfd *abfd, struct bfd_link_info *info)
26 goto error_return;
27
28 /* Check for DT_TEXTREL (late, in case the backend removes it). */
29- if ((info->warn_shared_textrel && info->shared)
30- || info->error_textrel)
31+ if (((info->warn_shared_textrel && info->shared)
32+ || info->error_textrel)
33+ && (o = bfd_get_section_by_name (dynobj, ".dynamic")) != NULL)
34 {
35 bfd_byte *dyncon, *dynconend;
36
37- /* Fix up .dynamic entries. */
38- o = bfd_get_section_by_name (dynobj, ".dynamic");
39- BFD_ASSERT (o != NULL);
40-
41 dyncon = o->contents;
42 dynconend = o->contents + o->size;
43 for (; dyncon < dynconend; dyncon += bed->s->sizeof_dyn)
44--
451.7.9.5
46
diff --git a/meta/recipes-devtools/binutils/binutils/0028-Backport-from-mainline.patch b/meta/recipes-devtools/binutils/binutils/0028-Backport-from-mainline.patch
deleted file mode 100644
index 2b86b6bf3b..0000000000
--- a/meta/recipes-devtools/binutils/binutils/0028-Backport-from-mainline.patch
+++ /dev/null
@@ -1,139 +0,0 @@
1Upstream-Status: Backport
2
3From fbd07e4e15de7a81a2de7f9583fa3240302e2867 Mon Sep 17 00:00:00 2001
4From: David Daney <ddaney@avtrex.com>
5Date: Sun, 11 Dec 2011 02:28:10 +0000
6Subject: [PATCH 028/262] Backport from mainline:
7
8 2011-12-10 David Daney <david.daney@cavium.com>
9
10 * elfxx-mips.c (mips_elf_link_hash_table.rld_value): Remove.
11 (mips_elf_link_hash_table.rld_symbol): New field;
12 (MIPS_ELF_RLD_MAP_SIZE): New macro.
13 (_bfd_mips_elf_add_symbol_hook): Remember __rld_obj_head symbol
14 in rld_symbol.
15 (_bfd_mips_elf_create_dynamic_sections): Remember __rld_map symbol
16 in rld_symbol.
17 (_bfd_mips_elf_size_dynamic_sections): Set correct size for .rld_map.
18 (_bfd_mips_elf_finish_dynamic_symbol): Remove .rld_map handling.
19 (_bfd_mips_elf_finish_dynamic_sections): Use rld_symbol to
20 calculate DT_MIPS_RLD_MAP value.
21 (_bfd_mips_elf_link_hash_table_create): Initialize rld_symbol,
22 quit initializing rld_value.
23
24diff --git a/bfd/elfxx-mips.c b/bfd/elfxx-mips.c
25index 33a454d..6b908ad 100644
26--- a/bfd/elfxx-mips.c
27+++ b/bfd/elfxx-mips.c
28@@ -436,8 +436,8 @@ struct mips_elf_link_hash_table
29 entry is set to the address of __rld_obj_head as in IRIX5. */
30 bfd_boolean use_rld_obj_head;
31
32- /* This is the value of the __rld_map or __rld_obj_head symbol. */
33- bfd_vma rld_value;
34+ /* The __rld_map or __rld_obj_head symbol. */
35+ struct elf_link_hash_entry *rld_symbol;
36
37 /* This is set if we see any mips16 stub sections. */
38 bfd_boolean mips16_stubs_seen;
39@@ -768,6 +768,10 @@ static bfd *reldyn_sorting_bfd;
40 #define MIPS_ELF_GOT_SIZE(abfd) \
41 (get_elf_backend_data (abfd)->s->arch_size / 8)
42
43+/* The size of the .rld_map section. */
44+#define MIPS_ELF_RLD_MAP_SIZE(abfd) \
45+ (get_elf_backend_data (abfd)->s->arch_size / 8)
46+
47 /* The size of a symbol-table entry. */
48 #define MIPS_ELF_SYM_SIZE(abfd) \
49 (get_elf_backend_data (abfd)->s->sizeof_sym)
50@@ -7081,6 +7085,7 @@ _bfd_mips_elf_add_symbol_hook (bfd *abfd, struct bfd_link_info *info,
51 return FALSE;
52
53 mips_elf_hash_table (info)->use_rld_obj_head = TRUE;
54+ mips_elf_hash_table (info)->rld_symbol = h;
55 }
56
57 /* If this is a mips16 text symbol, add 1 to the value to make it
58@@ -7266,6 +7271,7 @@ _bfd_mips_elf_create_dynamic_sections (bfd *abfd, struct bfd_link_info *info)
59
60 if (! bfd_elf_link_record_dynamic_symbol (info, h))
61 return FALSE;
62+ mips_elf_hash_table (info)->rld_symbol = h;
63 }
64 }
65
66@@ -9027,7 +9033,7 @@ _bfd_mips_elf_size_dynamic_sections (bfd *output_bfd,
67 {
68 /* We add a room for __rld_map. It will be filled in by the
69 rtld to contain a pointer to the _r_debug structure. */
70- s->size += 4;
71+ s->size += MIPS_ELF_RLD_MAP_SIZE (output_bfd);
72 }
73 else if (SGI_COMPAT (output_bfd)
74 && CONST_STRNEQ (name, ".compact_rel"))
75@@ -10030,31 +10036,6 @@ _bfd_mips_elf_finish_dynamic_symbol (bfd *output_bfd,
76 if (IRIX_COMPAT (output_bfd) == ict_irix6)
77 mips_elf_irix6_finish_dynamic_symbol (output_bfd, name, sym);
78
79- if (! info->shared)
80- {
81- if (! mips_elf_hash_table (info)->use_rld_obj_head
82- && (strcmp (name, "__rld_map") == 0
83- || strcmp (name, "__RLD_MAP") == 0))
84- {
85- asection *s = bfd_get_section_by_name (dynobj, ".rld_map");
86- BFD_ASSERT (s != NULL);
87- sym->st_value = s->output_section->vma + s->output_offset;
88- bfd_put_32 (output_bfd, 0, s->contents);
89- if (mips_elf_hash_table (info)->rld_value == 0)
90- mips_elf_hash_table (info)->rld_value = sym->st_value;
91- }
92- else if (mips_elf_hash_table (info)->use_rld_obj_head
93- && strcmp (name, "__rld_obj_head") == 0)
94- {
95- /* IRIX6 does not use a .rld_map section. */
96- if (IRIX_COMPAT (output_bfd) == ict_irix5
97- || IRIX_COMPAT (output_bfd) == ict_none)
98- BFD_ASSERT (bfd_get_section_by_name (dynobj, ".rld_map")
99- != NULL);
100- mips_elf_hash_table (info)->rld_value = sym->st_value;
101- }
102- }
103-
104 /* Keep dynamic MIPS16 symbols odd. This allows the dynamic linker to
105 treat MIPS16 symbols like any other. */
106 if (ELF_ST_IS_MIPS16 (sym->st_other))
107@@ -10517,7 +10498,19 @@ _bfd_mips_elf_finish_dynamic_sections (bfd *output_bfd,
108 break;
109
110 case DT_MIPS_RLD_MAP:
111- dyn.d_un.d_ptr = mips_elf_hash_table (info)->rld_value;
112+ {
113+ struct elf_link_hash_entry *h;
114+ h = mips_elf_hash_table (info)->rld_symbol;
115+ if (!h)
116+ {
117+ dyn_to_skip = MIPS_ELF_DYN_SIZE (dynobj);
118+ swap_out_p = FALSE;
119+ break;
120+ }
121+ s = h->root.u.def.section;
122+ dyn.d_un.d_ptr = (s->output_section->vma + s->output_offset
123+ + h->root.u.def.value);
124+ }
125 break;
126
127 case DT_MIPS_OPTIONS:
128@@ -12794,7 +12787,7 @@ _bfd_mips_elf_link_hash_table_create (bfd *abfd)
129 ret->procedure_count = 0;
130 ret->compact_rel_size = 0;
131 ret->use_rld_obj_head = FALSE;
132- ret->rld_value = 0;
133+ ret->rld_symbol = NULL;
134 ret->mips16_stubs_seen = FALSE;
135 ret->use_plts_and_copy_relocs = FALSE;
136 ret->is_vxworks = FALSE;
137--
1381.7.9.5
139
diff --git a/meta/recipes-devtools/binutils/binutils/0035-2011-12-19-Chung-Lin-Tang-cltang-codesourcery.com.patch b/meta/recipes-devtools/binutils/binutils/0035-2011-12-19-Chung-Lin-Tang-cltang-codesourcery.com.patch
deleted file mode 100644
index a83a5979f6..0000000000
--- a/meta/recipes-devtools/binutils/binutils/0035-2011-12-19-Chung-Lin-Tang-cltang-codesourcery.com.patch
+++ /dev/null
@@ -1,47 +0,0 @@
1Upstream-Status: Backport
2
3From 97beee82f0e45e65308083a7e4cfaab57623733c Mon Sep 17 00:00:00 2001
4From: cltang <cltang>
5Date: Mon, 19 Dec 2011 10:34:15 +0000
6Subject: [PATCH 035/262] 2011-12-19 Chung-Lin Tang
7 <cltang@codesourcery.com>
8
9 Backport from mainline:
10
11 2011-12-13 Chung-Lin Tang <cltang@codesourcery.com>
12
13 * elfxx-mips.c (mips_elf_calculate_relocation): Correct
14 R_MIPS16_HI16/R_MIPS16_LO16 handling of two cleared lower bits,
15 update comments.
16
17diff --git a/bfd/elfxx-mips.c b/bfd/elfxx-mips.c
18index 6b908ad..3939183 100644
19--- a/bfd/elfxx-mips.c
20+++ b/bfd/elfxx-mips.c
21@@ -5531,10 +5531,11 @@ mips_elf_calculate_relocation (bfd *abfd, bfd *input_bfd,
22 12: addu $v0,$v1
23 14: move $gp,$v0
24 So the offsets of hi and lo relocs are the same, but the
25- $pc is four higher than $t9 would be, so reduce
26- both reloc addends by 4. */
27+ base $pc is that used by the ADDIUPC instruction at $t9 + 4.
28+ ADDIUPC clears the low two bits of the instruction address,
29+ so the base is ($t9 + 4) & ~3. */
30 if (r_type == R_MIPS16_HI16)
31- value = mips_elf_high (addend + gp - p - 4);
32+ value = mips_elf_high (addend + gp - ((p + 4) & ~(bfd_vma) 0x3));
33 /* The microMIPS .cpload sequence uses the same assembly
34 instructions as the traditional psABI version, but the
35 incoming $t9 has the low bit set. */
36@@ -5557,7 +5558,7 @@ mips_elf_calculate_relocation (bfd *abfd, bfd *input_bfd,
37 /* See the comment for R_MIPS16_HI16 above for the reason
38 for this conditional. */
39 if (r_type == R_MIPS16_LO16)
40- value = addend + gp - p;
41+ value = addend + gp - (p & ~(bfd_vma) 0x3);
42 else if (r_type == R_MICROMIPS_LO16
43 || r_type == R_MICROMIPS_HI0_LO16)
44 value = addend + gp - p + 3;
45--
461.7.9.5
47
diff --git a/meta/recipes-devtools/binutils/binutils/0036-2011-12-19-Chung-Lin-Tang-cltang-codesourcery.com.patch b/meta/recipes-devtools/binutils/binutils/0036-2011-12-19-Chung-Lin-Tang-cltang-codesourcery.com.patch
deleted file mode 100644
index 9017c250de..0000000000
--- a/meta/recipes-devtools/binutils/binutils/0036-2011-12-19-Chung-Lin-Tang-cltang-codesourcery.com.patch
+++ /dev/null
@@ -1,214 +0,0 @@
1Upstream-Status: Backport
2
3From 26e802720ccd055d70addadbc39f4119716f8573 Mon Sep 17 00:00:00 2001
4From: cltang <cltang>
5Date: Mon, 19 Dec 2011 10:39:27 +0000
6Subject: [PATCH 036/262] 2011-12-19 Chung-Lin Tang
7 <cltang@codesourcery.com>
8
9 Backport from mainline:
10
11 2011-12-19 Chung-Lin Tang <cltang@codesourcery.com>
12 Catherine Moore <clm@codesourcery.com>
13 Sandra Loosemore <sandra@codesourcery.com>
14 Richard Sandiford <rdsandiford@googlemail.com>
15
16 * elfxx-mips.c (mips_elf_local_pic_function_p): Return true when
17 H is a MIPS16 function with a kept 32-bit stub. Update comments.
18 (mips_elf_get_la25_target): New function.
19 (mips_elf_add_la25_intro): Change to use mips_elf_get_la25_target().
20 (mips_elf_add_la25_stub): Move compute of use_trampoline_p down,
21 change to use mips_elf_get_la25_target().
22 (mips_elf_relocation_needs_la25_stub): Add target_is_16_bit_code_p
23 parameter, add switch case for R_MIPS16_26.
24 (mips_elf_calculate_relocation): Redirect relocation to point to the
25 LA25 stub if it exists, instead of the MIPS16 stub. Update arguments
26 of call to mips_elf_relocation_needs_la25_stub(), don't use la25 stub
27 for mips16->mips16 calls.
28 (_bfd_mips_elf_check_relocs): Update arguments of call to
29 mips_elf_relocation_needs_la25_stub().
30 (mips_elf_create_la25_stub): Change to use mips_elf_get_la25_target().
31
32diff --git a/bfd/elfxx-mips.c b/bfd/elfxx-mips.c
33index 3939183..9f3833b 100644
34--- a/bfd/elfxx-mips.c
35+++ b/bfd/elfxx-mips.c
36@@ -1575,9 +1575,10 @@ _bfd_mips_elf_init_stubs (struct bfd_link_info *info,
37 }
38
39 /* Return true if H is a locally-defined PIC function, in the sense
40- that it might need $25 to be valid on entry. Note that MIPS16
41- functions never need $25 to be valid on entry; they set up $gp
42- using PC-relative instructions instead. */
43+ that it or its fn_stub might need $25 to be valid on entry.
44+ Note that MIPS16 functions set up $gp using PC-relative instructions,
45+ so they themselves never need $25 to be valid. Only non-MIPS16
46+ entry points are of interest here. */
47
48 static bfd_boolean
49 mips_elf_local_pic_function_p (struct mips_elf_link_hash_entry *h)
50@@ -1586,11 +1587,32 @@ mips_elf_local_pic_function_p (struct mips_elf_link_hash_entry *h)
51 || h->root.root.type == bfd_link_hash_defweak)
52 && h->root.def_regular
53 && !bfd_is_abs_section (h->root.root.u.def.section)
54- && !ELF_ST_IS_MIPS16 (h->root.other)
55+ && (!ELF_ST_IS_MIPS16 (h->root.other)
56+ || (h->fn_stub && h->need_fn_stub))
57 && (PIC_OBJECT_P (h->root.root.u.def.section->owner)
58 || ELF_ST_IS_MIPS_PIC (h->root.other)));
59 }
60
61+/* Set *SEC to the input section that contains the target of STUB.
62+ Return the offset of the target from the start of that section. */
63+
64+static bfd_vma
65+mips_elf_get_la25_target (struct mips_elf_la25_stub *stub,
66+ asection **sec)
67+{
68+ if (ELF_ST_IS_MIPS16 (stub->h->root.other))
69+ {
70+ BFD_ASSERT (stub->h->need_fn_stub);
71+ *sec = stub->h->fn_stub;
72+ return 0;
73+ }
74+ else
75+ {
76+ *sec = stub->h->root.root.u.def.section;
77+ return stub->h->root.root.u.def.value;
78+ }
79+}
80+
81 /* STUB describes an la25 stub that we have decided to implement
82 by inserting an LUI/ADDIU pair before the target function.
83 Create the section and redirect the function symbol to it. */
84@@ -1615,7 +1637,7 @@ mips_elf_add_la25_intro (struct mips_elf_la25_stub *stub,
85 sprintf (name, ".text.stub.%d", (int) htab_elements (htab->la25_stubs));
86
87 /* Create the section. */
88- input_section = stub->h->root.root.u.def.section;
89+ mips_elf_get_la25_target (stub, &input_section);
90 s = htab->add_stub_section (name, input_section,
91 input_section->output_section);
92 if (s == NULL)
93@@ -1689,12 +1711,6 @@ mips_elf_add_la25_stub (struct bfd_link_info *info,
94 bfd_vma value;
95 void **slot;
96
97- /* Prefer to use LUI/ADDIU stubs if the function is at the beginning
98- of the section and if we would need no more than 2 nops. */
99- s = h->root.root.u.def.section;
100- value = h->root.root.u.def.value;
101- use_trampoline_p = (value != 0 || s->alignment_power > 4);
102-
103 /* Describe the stub we want. */
104 search.stub_section = NULL;
105 search.offset = 0;
106@@ -1724,6 +1740,11 @@ mips_elf_add_la25_stub (struct bfd_link_info *info,
107 *stub = search;
108 *slot = stub;
109
110+ /* Prefer to use LUI/ADDIU stubs if the function is at the beginning
111+ of the section and if we would need no more than 2 nops. */
112+ value = mips_elf_get_la25_target (stub, &s);
113+ use_trampoline_p = (value != 0 || s->alignment_power > 4);
114+
115 h->la25_stub = stub;
116 return (use_trampoline_p
117 ? mips_elf_add_la25_trampoline (stub, info)
118@@ -4911,7 +4932,8 @@ is_gott_symbol (struct bfd_link_info *info, struct elf_link_hash_entry *h)
119 stub. */
120
121 static bfd_boolean
122-mips_elf_relocation_needs_la25_stub (bfd *input_bfd, int r_type)
123+mips_elf_relocation_needs_la25_stub (bfd *input_bfd, int r_type,
124+ bfd_boolean target_is_16_bit_code_p)
125 {
126 /* We specifically ignore branches and jumps from EF_PIC objects,
127 where the onus is on the compiler or programmer to perform any
128@@ -4925,7 +4947,6 @@ mips_elf_relocation_needs_la25_stub (bfd *input_bfd, int r_type)
129 {
130 case R_MIPS_26:
131 case R_MIPS_PC16:
132- case R_MIPS16_26:
133 case R_MICROMIPS_26_S1:
134 case R_MICROMIPS_PC7_S1:
135 case R_MICROMIPS_PC10_S1:
136@@ -4933,6 +4954,9 @@ mips_elf_relocation_needs_la25_stub (bfd *input_bfd, int r_type)
137 case R_MICROMIPS_PC23_S2:
138 return TRUE;
139
140+ case R_MIPS16_26:
141+ return !target_is_16_bit_code_p;
142+
143 default:
144 return FALSE;
145 }
146@@ -5193,14 +5217,28 @@ mips_elf_calculate_relocation (bfd *abfd, bfd *input_bfd,
147 have already noticed that we were going to need the
148 stub. */
149 if (local_p)
150- sec = elf_tdata (input_bfd)->local_stubs[r_symndx];
151+ {
152+ sec = elf_tdata (input_bfd)->local_stubs[r_symndx];
153+ value = 0;
154+ }
155 else
156 {
157 BFD_ASSERT (h->need_fn_stub);
158- sec = h->fn_stub;
159+ if (h->la25_stub)
160+ {
161+ /* If a LA25 header for the stub itself exists, point to the
162+ prepended LUI/ADDIU sequence. */
163+ sec = h->la25_stub->stub_section;
164+ value = h->la25_stub->offset;
165+ }
166+ else
167+ {
168+ sec = h->fn_stub;
169+ value = 0;
170+ }
171 }
172
173- symbol = sec->output_section->vma + sec->output_offset;
174+ symbol = sec->output_section->vma + sec->output_offset + value;
175 /* The target is 16-bit, but the stub isn't. */
176 target_is_16_bit_code_p = FALSE;
177 }
178@@ -5250,7 +5288,8 @@ mips_elf_calculate_relocation (bfd *abfd, bfd *input_bfd,
179 /* If this is a direct call to a PIC function, redirect to the
180 non-PIC stub. */
181 else if (h != NULL && h->la25_stub
182- && mips_elf_relocation_needs_la25_stub (input_bfd, r_type))
183+ && mips_elf_relocation_needs_la25_stub (input_bfd, r_type,
184+ target_is_16_bit_code_p))
185 symbol = (h->la25_stub->stub_section->output_section->vma
186 + h->la25_stub->stub_section->output_offset
187 + h->la25_stub->offset);
188@@ -7925,7 +7964,9 @@ _bfd_mips_elf_check_relocs (bfd *abfd, struct bfd_link_info *info,
189 return FALSE;
190 }
191
192- if (h != NULL && mips_elf_relocation_needs_la25_stub (abfd, r_type))
193+ if (h != NULL
194+ && mips_elf_relocation_needs_la25_stub (abfd, r_type,
195+ ELF_ST_IS_MIPS16 (h->other)))
196 ((struct mips_elf_link_hash_entry *) h)->has_nonpic_branches = TRUE;
197
198 switch (r_type)
199@@ -9622,9 +9663,9 @@ mips_elf_create_la25_stub (void **slot, void *data)
200 offset = stub->offset;
201
202 /* Work out the target address. */
203- target = (stub->h->root.root.u.def.section->output_section->vma
204- + stub->h->root.root.u.def.section->output_offset
205- + stub->h->root.root.u.def.value);
206+ target = mips_elf_get_la25_target (stub, &s);
207+ target += s->output_section->vma + s->output_offset;
208+
209 target_high = ((target + 0x8000) >> 16) & 0xffff;
210 target_low = (target & 0xffff);
211
212--
2131.7.9.5
214
diff --git a/meta/recipes-devtools/binutils/binutils/0037-2011-12-19-Chung-Lin-Tang-cltang-codesourcery.com.patch b/meta/recipes-devtools/binutils/binutils/0037-2011-12-19-Chung-Lin-Tang-cltang-codesourcery.com.patch
deleted file mode 100644
index 4b0caafb48..0000000000
--- a/meta/recipes-devtools/binutils/binutils/0037-2011-12-19-Chung-Lin-Tang-cltang-codesourcery.com.patch
+++ /dev/null
@@ -1,1068 +0,0 @@
1Upstream-Status: Backport
2
3From 7e2b7154b03e4c77233171eec5cba8d113e04fea Mon Sep 17 00:00:00 2001
4From: cltang <cltang>
5Date: Mon, 19 Dec 2011 10:49:24 +0000
6Subject: [PATCH 037/262] 2011-12-19 Chung-Lin Tang
7 <cltang@codesourcery.com>
8
9 Backport from mainline:
10
11 2011-12-19 Chung-Lin Tang <cltang@codesourcery.com>
12
13 gas/
14 * config/tc-mips.c (mips_pseudo_table): Add tprelword/tpreldword
15 entries.
16 (mips16_percent_op): Add MIPS16 TLS relocation ops.
17 (md_apply_fix): Add BFD_RELOC_MIPS16_TLS_* switch cases.
18 (s_tls_rel_directive): Rename from s_dtprel_internal(). Abstract out
19 directive string and reloc type as function parameters. Update
20 comments.
21 (s_dtprelword,s_dtpreldword): Change to use s_tls_rel_directive().
22 (s_tprelword,s_tpreldword): New functions.
23
24 include/
25 * elf/mips.h (elf_mips_reloc_type): Add R_MIPS16_TLS_* entries.
26
27 bfd/
28 * reloc.c (BFD_RELOC_MIPS16_TLS_GD,BFD_RELOC_MIPS16_TLS_LDM,
29 BFD_RELOC_MIPS16_TLS_DTPREL_HI16,BFD_RELOC_MIPS16_TLS_DTPREL_LO16,
30 BFD_RELOC_MIPS16_TLS_GOTTPREL,BFD_RELOC_MIPS16_TLS_TPREL_HI16,
31 BFD_RELOC_MIPS16_TLS_TPREL_LO16): New relocations for MIPS16 TLS.
32 * bfd-in2.h (bfd_reloc_code_real): Regenerate.
33 * libbfd.h (bfd_reloc_code_real_names): Regenerate.
34 * elf32-mips.c (elf_mips16_howto_table_rel): Add R_MIPS16_TLS_*
35 entries.
36 (mips16_reloc_map): Add BFD_RELOC_MIPS16_TLS_* to R_MIPS16_TLS_*
37 mappings.
38 * elfn32-mips.c (elf_mips16_howto_table_rel,
39 elf_mips16_howto_table_rela): Add R_MIPS16_TLS_* entries.
40 (mips16_reloc_map): Add BFD_RELOC_MIPS16_TLS_* to R_MIPS16_TLS_*
41 mappings.
42 * elf64-mips.c (mips16_elf64_howto_table_rel,
43 mips16_elf64_howto_table_rela): Add R_MIPS16_TLS_* entries.
44 (mips16_reloc_map): Add BFD_RELOC_MIPS16_TLS_* to R_MIPS16_TLS_*
45 mappings.
46 * elfxx-mips.c (TLS_RELOC_P,mips16_reloc_p,
47 _bfd_mips_elf_check_relocs): Add cases for R_MIPS16_TLS_* relocations.
48 (tls_gd_reloc_p): Add R_MIPS16_TLS_GD case.
49 (tls_ldm_reloc_p): Add R_MIPS16_TLS_LDM case.
50 (tls_gottprel_reloc_p): Add R_MIPS16_TLS_GOTTPREL case.
51 (mips_elf_calculate_relocation): Add cases for R_MIPS16_TLS_*,
52 R_MIPS_TLS_DTPREL32/64, and R_MIPS_TLS_TPREL32/64 relocations.
53---
54 bfd/ChangeLog | 32 ++++++++
55 bfd/bfd-in2.h | 9 +++
56 bfd/elf32-mips.c | 114 ++++++++++++++++++++++++++
57 bfd/elf64-mips.c | 219 ++++++++++++++++++++++++++++++++++++++++++++++++++
58 bfd/elfn32-mips.c | 219 ++++++++++++++++++++++++++++++++++++++++++++++++++
59 bfd/elfxx-mips.c | 48 +++++++++--
60 bfd/libbfd.h | 7 ++
61 bfd/reloc.c | 17 ++++
62 gas/ChangeLog | 16 ++++
63 gas/config/tc-mips.c | 62 ++++++++++----
64 include/ChangeLog | 8 ++
65 include/elf/mips.h | 9 ++-
66 12 files changed, 739 insertions(+), 21 deletions(-)
67
68diff --git a/bfd/bfd-in2.h b/bfd/bfd-in2.h
69index 22fcdf6..cd90740 100644
70--- a/bfd/bfd-in2.h
71+++ b/bfd/bfd-in2.h
72@@ -2780,6 +2780,15 @@ to compensate for the borrow when the low bits are added. */
73 /* MIPS16 low 16 bits. */
74 BFD_RELOC_MIPS16_LO16,
75
76+/* MIPS16 TLS relocations */
77+ BFD_RELOC_MIPS16_TLS_GD,
78+ BFD_RELOC_MIPS16_TLS_LDM,
79+ BFD_RELOC_MIPS16_TLS_DTPREL_HI16,
80+ BFD_RELOC_MIPS16_TLS_DTPREL_LO16,
81+ BFD_RELOC_MIPS16_TLS_GOTTPREL,
82+ BFD_RELOC_MIPS16_TLS_TPREL_HI16,
83+ BFD_RELOC_MIPS16_TLS_TPREL_LO16,
84+
85 /* Relocation against a MIPS literal section. */
86 BFD_RELOC_MIPS_LITERAL,
87 BFD_RELOC_MICROMIPS_LITERAL,
88diff --git a/bfd/elf32-mips.c b/bfd/elf32-mips.c
89index fd3d4ba..61e8b45 100644
90--- a/bfd/elf32-mips.c
91+++ b/bfd/elf32-mips.c
92@@ -830,6 +830,111 @@ static reloc_howto_type elf_mips16_howto_table_rel[] =
93 0x0000ffff, /* src_mask */
94 0x0000ffff, /* dst_mask */
95 FALSE), /* pcrel_offset */
96+
97+ /* MIPS16 TLS general dynamic variable reference. */
98+ HOWTO (R_MIPS16_TLS_GD, /* type */
99+ 0, /* rightshift */
100+ 2, /* size (0 = byte, 1 = short, 2 = long) */
101+ 16, /* bitsize */
102+ FALSE, /* pc_relative */
103+ 0, /* bitpos */
104+ complain_overflow_signed, /* complain_on_overflow */
105+ _bfd_mips_elf_generic_reloc, /* special_function */
106+ "R_MIPS16_TLS_GD", /* name */
107+ TRUE, /* partial_inplace */
108+ 0x0000ffff, /* src_mask */
109+ 0x0000ffff, /* dst_mask */
110+ FALSE), /* pcrel_offset */
111+
112+ /* MIPS16 TLS local dynamic variable reference. */
113+ HOWTO (R_MIPS16_TLS_LDM, /* type */
114+ 0, /* rightshift */
115+ 2, /* size (0 = byte, 1 = short, 2 = long) */
116+ 16, /* bitsize */
117+ FALSE, /* pc_relative */
118+ 0, /* bitpos */
119+ complain_overflow_signed, /* complain_on_overflow */
120+ _bfd_mips_elf_generic_reloc, /* special_function */
121+ "R_MIPS16_TLS_LDM", /* name */
122+ TRUE, /* partial_inplace */
123+ 0x0000ffff, /* src_mask */
124+ 0x0000ffff, /* dst_mask */
125+ FALSE), /* pcrel_offset */
126+
127+ /* MIPS16 TLS local dynamic offset. */
128+ HOWTO (R_MIPS16_TLS_DTPREL_HI16, /* type */
129+ 0, /* rightshift */
130+ 2, /* size (0 = byte, 1 = short, 2 = long) */
131+ 16, /* bitsize */
132+ FALSE, /* pc_relative */
133+ 0, /* bitpos */
134+ complain_overflow_signed, /* complain_on_overflow */
135+ _bfd_mips_elf_generic_reloc, /* special_function */
136+ "R_MIPS16_TLS_DTPREL_HI16", /* name */
137+ TRUE, /* partial_inplace */
138+ 0x0000ffff, /* src_mask */
139+ 0x0000ffff, /* dst_mask */
140+ FALSE), /* pcrel_offset */
141+
142+ /* MIPS16 TLS local dynamic offset. */
143+ HOWTO (R_MIPS16_TLS_DTPREL_LO16, /* type */
144+ 0, /* rightshift */
145+ 2, /* size (0 = byte, 1 = short, 2 = long) */
146+ 16, /* bitsize */
147+ FALSE, /* pc_relative */
148+ 0, /* bitpos */
149+ complain_overflow_signed, /* complain_on_overflow */
150+ _bfd_mips_elf_generic_reloc, /* special_function */
151+ "R_MIPS16_TLS_DTPREL_LO16", /* name */
152+ TRUE, /* partial_inplace */
153+ 0x0000ffff, /* src_mask */
154+ 0x0000ffff, /* dst_mask */
155+ FALSE), /* pcrel_offset */
156+
157+ /* MIPS16 TLS thread pointer offset. */
158+ HOWTO (R_MIPS16_TLS_GOTTPREL, /* type */
159+ 0, /* rightshift */
160+ 2, /* size (0 = byte, 1 = short, 2 = long) */
161+ 16, /* bitsize */
162+ FALSE, /* pc_relative */
163+ 0, /* bitpos */
164+ complain_overflow_signed, /* complain_on_overflow */
165+ _bfd_mips_elf_generic_reloc, /* special_function */
166+ "R_MIPS16_TLS_GOTTPREL", /* name */
167+ TRUE, /* partial_inplace */
168+ 0x0000ffff, /* src_mask */
169+ 0x0000ffff, /* dst_mask */
170+ FALSE), /* pcrel_offset */
171+
172+ /* MIPS16 TLS thread pointer offset. */
173+ HOWTO (R_MIPS16_TLS_TPREL_HI16, /* type */
174+ 0, /* rightshift */
175+ 2, /* size (0 = byte, 1 = short, 2 = long) */
176+ 16, /* bitsize */
177+ FALSE, /* pc_relative */
178+ 0, /* bitpos */
179+ complain_overflow_signed, /* complain_on_overflow */
180+ _bfd_mips_elf_generic_reloc, /* special_function */
181+ "R_MIPS16_TLS_TPREL_HI16", /* name */
182+ TRUE, /* partial_inplace */
183+ 0x0000ffff, /* src_mask */
184+ 0x0000ffff, /* dst_mask */
185+ FALSE), /* pcrel_offset */
186+
187+ /* MIPS16 TLS thread pointer offset. */
188+ HOWTO (R_MIPS16_TLS_TPREL_LO16, /* type */
189+ 0, /* rightshift */
190+ 2, /* size (0 = byte, 1 = short, 2 = long) */
191+ 16, /* bitsize */
192+ FALSE, /* pc_relative */
193+ 0, /* bitpos */
194+ complain_overflow_signed, /* complain_on_overflow */
195+ _bfd_mips_elf_generic_reloc, /* special_function */
196+ "R_MIPS16_TLS_TPREL_LO16", /* name */
197+ TRUE, /* partial_inplace */
198+ 0x0000ffff, /* src_mask */
199+ 0x0000ffff, /* dst_mask */
200+ FALSE), /* pcrel_offset */
201 };
202
203 static reloc_howto_type elf_micromips_howto_table_rel[] =
204@@ -1796,6 +1901,15 @@ static const struct elf_reloc_map mips16_reloc_map[] =
205 { BFD_RELOC_MIPS16_CALL16, R_MIPS16_CALL16 - R_MIPS16_min },
206 { BFD_RELOC_MIPS16_HI16_S, R_MIPS16_HI16 - R_MIPS16_min },
207 { BFD_RELOC_MIPS16_LO16, R_MIPS16_LO16 - R_MIPS16_min },
208+ { BFD_RELOC_MIPS16_TLS_GD, R_MIPS16_TLS_GD - R_MIPS16_min },
209+ { BFD_RELOC_MIPS16_TLS_LDM, R_MIPS16_TLS_LDM - R_MIPS16_min },
210+ { BFD_RELOC_MIPS16_TLS_DTPREL_HI16,
211+ R_MIPS16_TLS_DTPREL_HI16 - R_MIPS16_min },
212+ { BFD_RELOC_MIPS16_TLS_DTPREL_LO16,
213+ R_MIPS16_TLS_DTPREL_LO16 - R_MIPS16_min },
214+ { BFD_RELOC_MIPS16_TLS_GOTTPREL, R_MIPS16_TLS_GOTTPREL - R_MIPS16_min },
215+ { BFD_RELOC_MIPS16_TLS_TPREL_HI16, R_MIPS16_TLS_TPREL_HI16 - R_MIPS16_min },
216+ { BFD_RELOC_MIPS16_TLS_TPREL_LO16, R_MIPS16_TLS_TPREL_LO16 - R_MIPS16_min }
217 };
218
219 static const struct elf_reloc_map micromips_reloc_map[] =
220diff --git a/bfd/elf64-mips.c b/bfd/elf64-mips.c
221index 3feb1bb..bdd0c19 100644
222--- a/bfd/elf64-mips.c
223+++ b/bfd/elf64-mips.c
224@@ -1590,6 +1590,111 @@ static reloc_howto_type mips16_elf64_howto_table_rel[] =
225 0x0000ffff, /* src_mask */
226 0x0000ffff, /* dst_mask */
227 FALSE), /* pcrel_offset */
228+
229+ /* MIPS16 TLS general dynamic variable reference. */
230+ HOWTO (R_MIPS16_TLS_GD, /* type */
231+ 0, /* rightshift */
232+ 2, /* size (0 = byte, 1 = short, 2 = long) */
233+ 16, /* bitsize */
234+ FALSE, /* pc_relative */
235+ 0, /* bitpos */
236+ complain_overflow_signed, /* complain_on_overflow */
237+ _bfd_mips_elf_generic_reloc, /* special_function */
238+ "R_MIPS16_TLS_GD", /* name */
239+ TRUE, /* partial_inplace */
240+ 0x0000ffff, /* src_mask */
241+ 0x0000ffff, /* dst_mask */
242+ FALSE), /* pcrel_offset */
243+
244+ /* MIPS16 TLS local dynamic variable reference. */
245+ HOWTO (R_MIPS16_TLS_LDM, /* type */
246+ 0, /* rightshift */
247+ 2, /* size (0 = byte, 1 = short, 2 = long) */
248+ 16, /* bitsize */
249+ FALSE, /* pc_relative */
250+ 0, /* bitpos */
251+ complain_overflow_signed, /* complain_on_overflow */
252+ _bfd_mips_elf_generic_reloc, /* special_function */
253+ "R_MIPS16_TLS_LDM", /* name */
254+ TRUE, /* partial_inplace */
255+ 0x0000ffff, /* src_mask */
256+ 0x0000ffff, /* dst_mask */
257+ FALSE), /* pcrel_offset */
258+
259+ /* MIPS16 TLS local dynamic offset. */
260+ HOWTO (R_MIPS16_TLS_DTPREL_HI16, /* type */
261+ 0, /* rightshift */
262+ 2, /* size (0 = byte, 1 = short, 2 = long) */
263+ 16, /* bitsize */
264+ FALSE, /* pc_relative */
265+ 0, /* bitpos */
266+ complain_overflow_signed, /* complain_on_overflow */
267+ _bfd_mips_elf_generic_reloc, /* special_function */
268+ "R_MIPS16_TLS_DTPREL_HI16", /* name */
269+ TRUE, /* partial_inplace */
270+ 0x0000ffff, /* src_mask */
271+ 0x0000ffff, /* dst_mask */
272+ FALSE), /* pcrel_offset */
273+
274+ /* MIPS16 TLS local dynamic offset. */
275+ HOWTO (R_MIPS16_TLS_DTPREL_LO16, /* type */
276+ 0, /* rightshift */
277+ 2, /* size (0 = byte, 1 = short, 2 = long) */
278+ 16, /* bitsize */
279+ FALSE, /* pc_relative */
280+ 0, /* bitpos */
281+ complain_overflow_signed, /* complain_on_overflow */
282+ _bfd_mips_elf_generic_reloc, /* special_function */
283+ "R_MIPS16_TLS_DTPREL_LO16", /* name */
284+ TRUE, /* partial_inplace */
285+ 0x0000ffff, /* src_mask */
286+ 0x0000ffff, /* dst_mask */
287+ FALSE), /* pcrel_offset */
288+
289+ /* MIPS16 TLS thread pointer offset. */
290+ HOWTO (R_MIPS16_TLS_GOTTPREL, /* type */
291+ 0, /* rightshift */
292+ 2, /* size (0 = byte, 1 = short, 2 = long) */
293+ 16, /* bitsize */
294+ FALSE, /* pc_relative */
295+ 0, /* bitpos */
296+ complain_overflow_signed, /* complain_on_overflow */
297+ _bfd_mips_elf_generic_reloc, /* special_function */
298+ "R_MIPS16_TLS_GOTTPREL", /* name */
299+ TRUE, /* partial_inplace */
300+ 0x0000ffff, /* src_mask */
301+ 0x0000ffff, /* dst_mask */
302+ FALSE), /* pcrel_offset */
303+
304+ /* MIPS16 TLS thread pointer offset. */
305+ HOWTO (R_MIPS16_TLS_TPREL_HI16, /* type */
306+ 0, /* rightshift */
307+ 2, /* size (0 = byte, 1 = short, 2 = long) */
308+ 16, /* bitsize */
309+ FALSE, /* pc_relative */
310+ 0, /* bitpos */
311+ complain_overflow_signed, /* complain_on_overflow */
312+ _bfd_mips_elf_generic_reloc, /* special_function */
313+ "R_MIPS16_TLS_TPREL_HI16", /* name */
314+ TRUE, /* partial_inplace */
315+ 0x0000ffff, /* src_mask */
316+ 0x0000ffff, /* dst_mask */
317+ FALSE), /* pcrel_offset */
318+
319+ /* MIPS16 TLS thread pointer offset. */
320+ HOWTO (R_MIPS16_TLS_TPREL_LO16, /* type */
321+ 0, /* rightshift */
322+ 2, /* size (0 = byte, 1 = short, 2 = long) */
323+ 16, /* bitsize */
324+ FALSE, /* pc_relative */
325+ 0, /* bitpos */
326+ complain_overflow_signed, /* complain_on_overflow */
327+ _bfd_mips_elf_generic_reloc, /* special_function */
328+ "R_MIPS16_TLS_TPREL_LO16", /* name */
329+ TRUE, /* partial_inplace */
330+ 0x0000ffff, /* src_mask */
331+ 0x0000ffff, /* dst_mask */
332+ FALSE), /* pcrel_offset */
333 };
334
335 static reloc_howto_type mips16_elf64_howto_table_rela[] =
336@@ -1686,6 +1791,111 @@ static reloc_howto_type mips16_elf64_howto_table_rela[] =
337 0x0000ffff, /* src_mask */
338 0x0000ffff, /* dst_mask */
339 FALSE), /* pcrel_offset */
340+
341+ /* MIPS16 TLS general dynamic variable reference. */
342+ HOWTO (R_MIPS16_TLS_GD, /* type */
343+ 0, /* rightshift */
344+ 2, /* size (0 = byte, 1 = short, 2 = long) */
345+ 16, /* bitsize */
346+ FALSE, /* pc_relative */
347+ 0, /* bitpos */
348+ complain_overflow_signed, /* complain_on_overflow */
349+ _bfd_mips_elf_generic_reloc, /* special_function */
350+ "R_MIPS16_TLS_GD", /* name */
351+ FALSE, /* partial_inplace */
352+ 0x0000ffff, /* src_mask */
353+ 0x0000ffff, /* dst_mask */
354+ FALSE), /* pcrel_offset */
355+
356+ /* MIPS16 TLS local dynamic variable reference. */
357+ HOWTO (R_MIPS16_TLS_LDM, /* type */
358+ 0, /* rightshift */
359+ 2, /* size (0 = byte, 1 = short, 2 = long) */
360+ 16, /* bitsize */
361+ FALSE, /* pc_relative */
362+ 0, /* bitpos */
363+ complain_overflow_signed, /* complain_on_overflow */
364+ _bfd_mips_elf_generic_reloc, /* special_function */
365+ "R_MIPS16_TLS_LDM", /* name */
366+ FALSE, /* partial_inplace */
367+ 0x0000ffff, /* src_mask */
368+ 0x0000ffff, /* dst_mask */
369+ FALSE), /* pcrel_offset */
370+
371+ /* MIPS16 TLS local dynamic offset. */
372+ HOWTO (R_MIPS16_TLS_DTPREL_HI16, /* type */
373+ 0, /* rightshift */
374+ 2, /* size (0 = byte, 1 = short, 2 = long) */
375+ 16, /* bitsize */
376+ FALSE, /* pc_relative */
377+ 0, /* bitpos */
378+ complain_overflow_signed, /* complain_on_overflow */
379+ _bfd_mips_elf_generic_reloc, /* special_function */
380+ "R_MIPS16_TLS_DTPREL_HI16", /* name */
381+ FALSE, /* partial_inplace */
382+ 0x0000ffff, /* src_mask */
383+ 0x0000ffff, /* dst_mask */
384+ FALSE), /* pcrel_offset */
385+
386+ /* MIPS16 TLS local dynamic offset. */
387+ HOWTO (R_MIPS16_TLS_DTPREL_LO16, /* type */
388+ 0, /* rightshift */
389+ 2, /* size (0 = byte, 1 = short, 2 = long) */
390+ 16, /* bitsize */
391+ FALSE, /* pc_relative */
392+ 0, /* bitpos */
393+ complain_overflow_signed, /* complain_on_overflow */
394+ _bfd_mips_elf_generic_reloc, /* special_function */
395+ "R_MIPS16_TLS_DTPREL_LO16", /* name */
396+ FALSE, /* partial_inplace */
397+ 0x0000ffff, /* src_mask */
398+ 0x0000ffff, /* dst_mask */
399+ FALSE), /* pcrel_offset */
400+
401+ /* MIPS16 TLS thread pointer offset. */
402+ HOWTO (R_MIPS16_TLS_GOTTPREL, /* type */
403+ 0, /* rightshift */
404+ 2, /* size (0 = byte, 1 = short, 2 = long) */
405+ 16, /* bitsize */
406+ FALSE, /* pc_relative */
407+ 0, /* bitpos */
408+ complain_overflow_signed, /* complain_on_overflow */
409+ _bfd_mips_elf_generic_reloc, /* special_function */
410+ "R_MIPS16_TLS_GOTTPREL", /* name */
411+ FALSE, /* partial_inplace */
412+ 0x0000ffff, /* src_mask */
413+ 0x0000ffff, /* dst_mask */
414+ FALSE), /* pcrel_offset */
415+
416+ /* MIPS16 TLS thread pointer offset. */
417+ HOWTO (R_MIPS16_TLS_TPREL_HI16, /* type */
418+ 0, /* rightshift */
419+ 2, /* size (0 = byte, 1 = short, 2 = long) */
420+ 16, /* bitsize */
421+ FALSE, /* pc_relative */
422+ 0, /* bitpos */
423+ complain_overflow_signed, /* complain_on_overflow */
424+ _bfd_mips_elf_generic_reloc, /* special_function */
425+ "R_MIPS16_TLS_TPREL_HI16", /* name */
426+ FALSE, /* partial_inplace */
427+ 0x0000ffff, /* src_mask */
428+ 0x0000ffff, /* dst_mask */
429+ FALSE), /* pcrel_offset */
430+
431+ /* MIPS16 TLS thread pointer offset. */
432+ HOWTO (R_MIPS16_TLS_TPREL_LO16, /* type */
433+ 0, /* rightshift */
434+ 2, /* size (0 = byte, 1 = short, 2 = long) */
435+ 16, /* bitsize */
436+ FALSE, /* pc_relative */
437+ 0, /* bitpos */
438+ complain_overflow_signed, /* complain_on_overflow */
439+ _bfd_mips_elf_generic_reloc, /* special_function */
440+ "R_MIPS16_TLS_TPREL_LO16", /* name */
441+ FALSE, /* partial_inplace */
442+ 0x0000ffff, /* src_mask */
443+ 0x0000ffff, /* dst_mask */
444+ FALSE), /* pcrel_offset */
445 };
446
447 static reloc_howto_type micromips_elf64_howto_table_rel[] =
448@@ -2908,6 +3118,15 @@ static const struct elf_reloc_map mips16_reloc_map[] =
449 { BFD_RELOC_MIPS16_CALL16, R_MIPS16_CALL16 - R_MIPS16_min },
450 { BFD_RELOC_MIPS16_HI16_S, R_MIPS16_HI16 - R_MIPS16_min },
451 { BFD_RELOC_MIPS16_LO16, R_MIPS16_LO16 - R_MIPS16_min },
452+ { BFD_RELOC_MIPS16_TLS_GD, R_MIPS16_TLS_GD - R_MIPS16_min },
453+ { BFD_RELOC_MIPS16_TLS_LDM, R_MIPS16_TLS_LDM - R_MIPS16_min },
454+ { BFD_RELOC_MIPS16_TLS_DTPREL_HI16,
455+ R_MIPS16_TLS_DTPREL_HI16 - R_MIPS16_min },
456+ { BFD_RELOC_MIPS16_TLS_DTPREL_LO16,
457+ R_MIPS16_TLS_DTPREL_LO16 - R_MIPS16_min },
458+ { BFD_RELOC_MIPS16_TLS_GOTTPREL, R_MIPS16_TLS_GOTTPREL - R_MIPS16_min },
459+ { BFD_RELOC_MIPS16_TLS_TPREL_HI16, R_MIPS16_TLS_TPREL_HI16 - R_MIPS16_min },
460+ { BFD_RELOC_MIPS16_TLS_TPREL_LO16, R_MIPS16_TLS_TPREL_LO16 - R_MIPS16_min }
461 };
462
463 static const struct elf_reloc_map micromips_reloc_map[] =
464diff --git a/bfd/elfn32-mips.c b/bfd/elfn32-mips.c
465index 00ec8b0..2189566 100644
466--- a/bfd/elfn32-mips.c
467+++ b/bfd/elfn32-mips.c
468@@ -1555,6 +1555,111 @@ static reloc_howto_type elf_mips16_howto_table_rel[] =
469 0x0000ffff, /* src_mask */
470 0x0000ffff, /* dst_mask */
471 FALSE), /* pcrel_offset */
472+
473+ /* MIPS16 TLS general dynamic variable reference. */
474+ HOWTO (R_MIPS16_TLS_GD, /* type */
475+ 0, /* rightshift */
476+ 2, /* size (0 = byte, 1 = short, 2 = long) */
477+ 16, /* bitsize */
478+ FALSE, /* pc_relative */
479+ 0, /* bitpos */
480+ complain_overflow_signed, /* complain_on_overflow */
481+ _bfd_mips_elf_generic_reloc, /* special_function */
482+ "R_MIPS16_TLS_GD", /* name */
483+ TRUE, /* partial_inplace */
484+ 0x0000ffff, /* src_mask */
485+ 0x0000ffff, /* dst_mask */
486+ FALSE), /* pcrel_offset */
487+
488+ /* MIPS16 TLS local dynamic variable reference. */
489+ HOWTO (R_MIPS16_TLS_LDM, /* type */
490+ 0, /* rightshift */
491+ 2, /* size (0 = byte, 1 = short, 2 = long) */
492+ 16, /* bitsize */
493+ FALSE, /* pc_relative */
494+ 0, /* bitpos */
495+ complain_overflow_signed, /* complain_on_overflow */
496+ _bfd_mips_elf_generic_reloc, /* special_function */
497+ "R_MIPS16_TLS_LDM", /* name */
498+ TRUE, /* partial_inplace */
499+ 0x0000ffff, /* src_mask */
500+ 0x0000ffff, /* dst_mask */
501+ FALSE), /* pcrel_offset */
502+
503+ /* MIPS16 TLS local dynamic offset. */
504+ HOWTO (R_MIPS16_TLS_DTPREL_HI16, /* type */
505+ 0, /* rightshift */
506+ 2, /* size (0 = byte, 1 = short, 2 = long) */
507+ 16, /* bitsize */
508+ FALSE, /* pc_relative */
509+ 0, /* bitpos */
510+ complain_overflow_signed, /* complain_on_overflow */
511+ _bfd_mips_elf_generic_reloc, /* special_function */
512+ "R_MIPS16_TLS_DTPREL_HI16", /* name */
513+ TRUE, /* partial_inplace */
514+ 0x0000ffff, /* src_mask */
515+ 0x0000ffff, /* dst_mask */
516+ FALSE), /* pcrel_offset */
517+
518+ /* MIPS16 TLS local dynamic offset. */
519+ HOWTO (R_MIPS16_TLS_DTPREL_LO16, /* type */
520+ 0, /* rightshift */
521+ 2, /* size (0 = byte, 1 = short, 2 = long) */
522+ 16, /* bitsize */
523+ FALSE, /* pc_relative */
524+ 0, /* bitpos */
525+ complain_overflow_signed, /* complain_on_overflow */
526+ _bfd_mips_elf_generic_reloc, /* special_function */
527+ "R_MIPS16_TLS_DTPREL_LO16", /* name */
528+ TRUE, /* partial_inplace */
529+ 0x0000ffff, /* src_mask */
530+ 0x0000ffff, /* dst_mask */
531+ FALSE), /* pcrel_offset */
532+
533+ /* MIPS16 TLS thread pointer offset. */
534+ HOWTO (R_MIPS16_TLS_GOTTPREL, /* type */
535+ 0, /* rightshift */
536+ 2, /* size (0 = byte, 1 = short, 2 = long) */
537+ 16, /* bitsize */
538+ FALSE, /* pc_relative */
539+ 0, /* bitpos */
540+ complain_overflow_signed, /* complain_on_overflow */
541+ _bfd_mips_elf_generic_reloc, /* special_function */
542+ "R_MIPS16_TLS_GOTTPREL", /* name */
543+ TRUE, /* partial_inplace */
544+ 0x0000ffff, /* src_mask */
545+ 0x0000ffff, /* dst_mask */
546+ FALSE), /* pcrel_offset */
547+
548+ /* MIPS16 TLS thread pointer offset. */
549+ HOWTO (R_MIPS16_TLS_TPREL_HI16, /* type */
550+ 0, /* rightshift */
551+ 2, /* size (0 = byte, 1 = short, 2 = long) */
552+ 16, /* bitsize */
553+ FALSE, /* pc_relative */
554+ 0, /* bitpos */
555+ complain_overflow_signed, /* complain_on_overflow */
556+ _bfd_mips_elf_generic_reloc, /* special_function */
557+ "R_MIPS16_TLS_TPREL_HI16", /* name */
558+ TRUE, /* partial_inplace */
559+ 0x0000ffff, /* src_mask */
560+ 0x0000ffff, /* dst_mask */
561+ FALSE), /* pcrel_offset */
562+
563+ /* MIPS16 TLS thread pointer offset. */
564+ HOWTO (R_MIPS16_TLS_TPREL_LO16, /* type */
565+ 0, /* rightshift */
566+ 2, /* size (0 = byte, 1 = short, 2 = long) */
567+ 16, /* bitsize */
568+ FALSE, /* pc_relative */
569+ 0, /* bitpos */
570+ complain_overflow_signed, /* complain_on_overflow */
571+ _bfd_mips_elf_generic_reloc, /* special_function */
572+ "R_MIPS16_TLS_TPREL_LO16", /* name */
573+ TRUE, /* partial_inplace */
574+ 0x0000ffff, /* src_mask */
575+ 0x0000ffff, /* dst_mask */
576+ FALSE), /* pcrel_offset */
577 };
578
579 static reloc_howto_type elf_mips16_howto_table_rela[] =
580@@ -1651,6 +1756,111 @@ static reloc_howto_type elf_mips16_howto_table_rela[] =
581 0x0000ffff, /* src_mask */
582 0x0000ffff, /* dst_mask */
583 FALSE), /* pcrel_offset */
584+
585+ /* MIPS16 TLS general dynamic variable reference. */
586+ HOWTO (R_MIPS16_TLS_GD, /* type */
587+ 0, /* rightshift */
588+ 2, /* size (0 = byte, 1 = short, 2 = long) */
589+ 16, /* bitsize */
590+ FALSE, /* pc_relative */
591+ 0, /* bitpos */
592+ complain_overflow_signed, /* complain_on_overflow */
593+ _bfd_mips_elf_generic_reloc, /* special_function */
594+ "R_MIPS16_TLS_GD", /* name */
595+ FALSE, /* partial_inplace */
596+ 0x0000ffff, /* src_mask */
597+ 0x0000ffff, /* dst_mask */
598+ FALSE), /* pcrel_offset */
599+
600+ /* MIPS16 TLS local dynamic variable reference. */
601+ HOWTO (R_MIPS16_TLS_LDM, /* type */
602+ 0, /* rightshift */
603+ 2, /* size (0 = byte, 1 = short, 2 = long) */
604+ 16, /* bitsize */
605+ FALSE, /* pc_relative */
606+ 0, /* bitpos */
607+ complain_overflow_signed, /* complain_on_overflow */
608+ _bfd_mips_elf_generic_reloc, /* special_function */
609+ "R_MIPS16_TLS_LDM", /* name */
610+ FALSE, /* partial_inplace */
611+ 0x0000ffff, /* src_mask */
612+ 0x0000ffff, /* dst_mask */
613+ FALSE), /* pcrel_offset */
614+
615+ /* MIPS16 TLS local dynamic offset. */
616+ HOWTO (R_MIPS16_TLS_DTPREL_HI16, /* type */
617+ 0, /* rightshift */
618+ 2, /* size (0 = byte, 1 = short, 2 = long) */
619+ 16, /* bitsize */
620+ FALSE, /* pc_relative */
621+ 0, /* bitpos */
622+ complain_overflow_signed, /* complain_on_overflow */
623+ _bfd_mips_elf_generic_reloc, /* special_function */
624+ "R_MIPS16_TLS_DTPREL_HI16", /* name */
625+ FALSE, /* partial_inplace */
626+ 0x0000ffff, /* src_mask */
627+ 0x0000ffff, /* dst_mask */
628+ FALSE), /* pcrel_offset */
629+
630+ /* MIPS16 TLS local dynamic offset. */
631+ HOWTO (R_MIPS16_TLS_DTPREL_LO16, /* type */
632+ 0, /* rightshift */
633+ 2, /* size (0 = byte, 1 = short, 2 = long) */
634+ 16, /* bitsize */
635+ FALSE, /* pc_relative */
636+ 0, /* bitpos */
637+ complain_overflow_signed, /* complain_on_overflow */
638+ _bfd_mips_elf_generic_reloc, /* special_function */
639+ "R_MIPS16_TLS_DTPREL_LO16", /* name */
640+ FALSE, /* partial_inplace */
641+ 0x0000ffff, /* src_mask */
642+ 0x0000ffff, /* dst_mask */
643+ FALSE), /* pcrel_offset */
644+
645+ /* MIPS16 TLS thread pointer offset. */
646+ HOWTO (R_MIPS16_TLS_GOTTPREL, /* type */
647+ 0, /* rightshift */
648+ 2, /* size (0 = byte, 1 = short, 2 = long) */
649+ 16, /* bitsize */
650+ FALSE, /* pc_relative */
651+ 0, /* bitpos */
652+ complain_overflow_signed, /* complain_on_overflow */
653+ _bfd_mips_elf_generic_reloc, /* special_function */
654+ "R_MIPS16_TLS_GOTTPREL", /* name */
655+ FALSE, /* partial_inplace */
656+ 0x0000ffff, /* src_mask */
657+ 0x0000ffff, /* dst_mask */
658+ FALSE), /* pcrel_offset */
659+
660+ /* MIPS16 TLS thread pointer offset. */
661+ HOWTO (R_MIPS16_TLS_TPREL_HI16, /* type */
662+ 0, /* rightshift */
663+ 2, /* size (0 = byte, 1 = short, 2 = long) */
664+ 16, /* bitsize */
665+ FALSE, /* pc_relative */
666+ 0, /* bitpos */
667+ complain_overflow_signed, /* complain_on_overflow */
668+ _bfd_mips_elf_generic_reloc, /* special_function */
669+ "R_MIPS16_TLS_TPREL_HI16", /* name */
670+ FALSE, /* partial_inplace */
671+ 0x0000ffff, /* src_mask */
672+ 0x0000ffff, /* dst_mask */
673+ FALSE), /* pcrel_offset */
674+
675+ /* MIPS16 TLS thread pointer offset. */
676+ HOWTO (R_MIPS16_TLS_TPREL_LO16, /* type */
677+ 0, /* rightshift */
678+ 2, /* size (0 = byte, 1 = short, 2 = long) */
679+ 16, /* bitsize */
680+ FALSE, /* pc_relative */
681+ 0, /* bitpos */
682+ complain_overflow_signed, /* complain_on_overflow */
683+ _bfd_mips_elf_generic_reloc, /* special_function */
684+ "R_MIPS16_TLS_TPREL_LO16", /* name */
685+ FALSE, /* partial_inplace */
686+ 0x0000ffff, /* src_mask */
687+ 0x0000ffff, /* dst_mask */
688+ FALSE), /* pcrel_offset */
689 };
690
691 static reloc_howto_type elf_micromips_howto_table_rel[] =
692@@ -2724,6 +2934,15 @@ static const struct elf_reloc_map mips16_reloc_map[] =
693 { BFD_RELOC_MIPS16_CALL16, R_MIPS16_CALL16 - R_MIPS16_min },
694 { BFD_RELOC_MIPS16_HI16_S, R_MIPS16_HI16 - R_MIPS16_min },
695 { BFD_RELOC_MIPS16_LO16, R_MIPS16_LO16 - R_MIPS16_min },
696+ { BFD_RELOC_MIPS16_TLS_GD, R_MIPS16_TLS_GD - R_MIPS16_min },
697+ { BFD_RELOC_MIPS16_TLS_LDM, R_MIPS16_TLS_LDM - R_MIPS16_min },
698+ { BFD_RELOC_MIPS16_TLS_DTPREL_HI16,
699+ R_MIPS16_TLS_DTPREL_HI16 - R_MIPS16_min },
700+ { BFD_RELOC_MIPS16_TLS_DTPREL_LO16,
701+ R_MIPS16_TLS_DTPREL_LO16 - R_MIPS16_min },
702+ { BFD_RELOC_MIPS16_TLS_GOTTPREL, R_MIPS16_TLS_GOTTPREL - R_MIPS16_min },
703+ { BFD_RELOC_MIPS16_TLS_TPREL_HI16, R_MIPS16_TLS_TPREL_HI16 - R_MIPS16_min },
704+ { BFD_RELOC_MIPS16_TLS_TPREL_LO16, R_MIPS16_TLS_TPREL_LO16 - R_MIPS16_min }
705 };
706
707 static const struct elf_reloc_map micromips_reloc_map[] =
708diff --git a/bfd/elfxx-mips.c b/bfd/elfxx-mips.c
709index 9f3833b..fa906cd 100644
710--- a/bfd/elfxx-mips.c
711+++ b/bfd/elfxx-mips.c
712@@ -529,6 +529,13 @@ struct mips_htab_traverse_info
713 || r_type == R_MIPS_TLS_TPREL64 \
714 || r_type == R_MIPS_TLS_TPREL_HI16 \
715 || r_type == R_MIPS_TLS_TPREL_LO16 \
716+ || r_type == R_MIPS16_TLS_GD \
717+ || r_type == R_MIPS16_TLS_LDM \
718+ || r_type == R_MIPS16_TLS_DTPREL_HI16 \
719+ || r_type == R_MIPS16_TLS_DTPREL_LO16 \
720+ || r_type == R_MIPS16_TLS_GOTTPREL \
721+ || r_type == R_MIPS16_TLS_TPREL_HI16 \
722+ || r_type == R_MIPS16_TLS_TPREL_LO16 \
723 || r_type == R_MICROMIPS_TLS_GD \
724 || r_type == R_MICROMIPS_TLS_LDM \
725 || r_type == R_MICROMIPS_TLS_DTPREL_HI16 \
726@@ -1885,6 +1892,13 @@ mips16_reloc_p (int r_type)
727 case R_MIPS16_CALL16:
728 case R_MIPS16_HI16:
729 case R_MIPS16_LO16:
730+ case R_MIPS16_TLS_GD:
731+ case R_MIPS16_TLS_LDM:
732+ case R_MIPS16_TLS_DTPREL_HI16:
733+ case R_MIPS16_TLS_DTPREL_LO16:
734+ case R_MIPS16_TLS_GOTTPREL:
735+ case R_MIPS16_TLS_TPREL_HI16:
736+ case R_MIPS16_TLS_TPREL_LO16:
737 return TRUE;
738
739 default:
740@@ -2012,19 +2026,25 @@ micromips_branch_reloc_p (int r_type)
741 static inline bfd_boolean
742 tls_gd_reloc_p (unsigned int r_type)
743 {
744- return r_type == R_MIPS_TLS_GD || r_type == R_MICROMIPS_TLS_GD;
745+ return (r_type == R_MIPS_TLS_GD
746+ || r_type == R_MIPS16_TLS_GD
747+ || r_type == R_MICROMIPS_TLS_GD);
748 }
749
750 static inline bfd_boolean
751 tls_ldm_reloc_p (unsigned int r_type)
752 {
753- return r_type == R_MIPS_TLS_LDM || r_type == R_MICROMIPS_TLS_LDM;
754+ return (r_type == R_MIPS_TLS_LDM
755+ || r_type == R_MIPS16_TLS_LDM
756+ || r_type == R_MICROMIPS_TLS_LDM);
757 }
758
759 static inline bfd_boolean
760 tls_gottprel_reloc_p (unsigned int r_type)
761 {
762- return r_type == R_MIPS_TLS_GOTTPREL || r_type == R_MICROMIPS_TLS_GOTTPREL;
763+ return (r_type == R_MIPS_TLS_GOTTPREL
764+ || r_type == R_MIPS16_TLS_GOTTPREL
765+ || r_type == R_MICROMIPS_TLS_GOTTPREL);
766 }
767
768 void
769@@ -5361,6 +5381,9 @@ mips_elf_calculate_relocation (bfd *abfd, bfd *input_bfd,
770 case R_MIPS_TLS_GD:
771 case R_MIPS_TLS_GOTTPREL:
772 case R_MIPS_TLS_LDM:
773+ case R_MIPS16_TLS_GD:
774+ case R_MIPS16_TLS_GOTTPREL:
775+ case R_MIPS16_TLS_LDM:
776 case R_MICROMIPS_TLS_GD:
777 case R_MICROMIPS_TLS_GOTTPREL:
778 case R_MICROMIPS_TLS_LDM:
779@@ -5530,6 +5553,7 @@ mips_elf_calculate_relocation (bfd *abfd, bfd *input_bfd,
780 break;
781
782 case R_MIPS_TLS_DTPREL_HI16:
783+ case R_MIPS16_TLS_DTPREL_HI16:
784 case R_MICROMIPS_TLS_DTPREL_HI16:
785 value = (mips_elf_high (addend + symbol - dtprel_base (info))
786 & howto->dst_mask);
787@@ -5538,17 +5562,22 @@ mips_elf_calculate_relocation (bfd *abfd, bfd *input_bfd,
788 case R_MIPS_TLS_DTPREL_LO16:
789 case R_MIPS_TLS_DTPREL32:
790 case R_MIPS_TLS_DTPREL64:
791+ case R_MIPS16_TLS_DTPREL_LO16:
792 case R_MICROMIPS_TLS_DTPREL_LO16:
793 value = (symbol + addend - dtprel_base (info)) & howto->dst_mask;
794 break;
795
796 case R_MIPS_TLS_TPREL_HI16:
797+ case R_MIPS16_TLS_TPREL_HI16:
798 case R_MICROMIPS_TLS_TPREL_HI16:
799 value = (mips_elf_high (addend + symbol - tprel_base (info))
800 & howto->dst_mask);
801 break;
802
803 case R_MIPS_TLS_TPREL_LO16:
804+ case R_MIPS_TLS_TPREL32:
805+ case R_MIPS_TLS_TPREL64:
806+ case R_MIPS16_TLS_TPREL_LO16:
807 case R_MICROMIPS_TLS_TPREL_LO16:
808 value = (symbol + addend - tprel_base (info)) & howto->dst_mask;
809 break;
810@@ -5681,6 +5710,9 @@ mips_elf_calculate_relocation (bfd *abfd, bfd *input_bfd,
811 case R_MIPS_TLS_GOTTPREL:
812 case R_MIPS_TLS_LDM:
813 case R_MIPS_GOT_DISP:
814+ case R_MIPS16_TLS_GD:
815+ case R_MIPS16_TLS_GOTTPREL:
816+ case R_MIPS16_TLS_LDM:
817 case R_MICROMIPS_TLS_GD:
818 case R_MICROMIPS_TLS_GOTTPREL:
819 case R_MICROMIPS_TLS_LDM:
820@@ -7813,8 +7845,6 @@ _bfd_mips_elf_check_relocs (bfd *abfd, struct bfd_link_info *info,
821 can_make_dynamic_p = FALSE;
822 switch (r_type)
823 {
824- case R_MIPS16_GOT16:
825- case R_MIPS16_CALL16:
826 case R_MIPS_GOT16:
827 case R_MIPS_CALL16:
828 case R_MIPS_CALL_HI16:
829@@ -7827,6 +7857,11 @@ _bfd_mips_elf_check_relocs (bfd *abfd, struct bfd_link_info *info,
830 case R_MIPS_TLS_GOTTPREL:
831 case R_MIPS_TLS_GD:
832 case R_MIPS_TLS_LDM:
833+ case R_MIPS16_GOT16:
834+ case R_MIPS16_CALL16:
835+ case R_MIPS16_TLS_GOTTPREL:
836+ case R_MIPS16_TLS_GD:
837+ case R_MIPS16_TLS_LDM:
838 case R_MICROMIPS_GOT16:
839 case R_MICROMIPS_CALL16:
840 case R_MICROMIPS_CALL_HI16:
841@@ -8063,12 +8098,14 @@ _bfd_mips_elf_check_relocs (bfd *abfd, struct bfd_link_info *info,
842 break;
843
844 case R_MIPS_TLS_GOTTPREL:
845+ case R_MIPS16_TLS_GOTTPREL:
846 case R_MICROMIPS_TLS_GOTTPREL:
847 if (info->shared)
848 info->flags |= DF_STATIC_TLS;
849 /* Fall through */
850
851 case R_MIPS_TLS_LDM:
852+ case R_MIPS16_TLS_LDM:
853 case R_MICROMIPS_TLS_LDM:
854 if (tls_ldm_reloc_p (r_type))
855 {
856@@ -8078,6 +8115,7 @@ _bfd_mips_elf_check_relocs (bfd *abfd, struct bfd_link_info *info,
857 /* Fall through */
858
859 case R_MIPS_TLS_GD:
860+ case R_MIPS16_TLS_GD:
861 case R_MICROMIPS_TLS_GD:
862 /* This symbol requires a global offset table entry, or two
863 for TLS GD relocations. */
864diff --git a/bfd/libbfd.h b/bfd/libbfd.h
865index 200a6fa..0395ec2 100644
866--- a/bfd/libbfd.h
867+++ b/bfd/libbfd.h
868@@ -1086,6 +1086,13 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
869 "BFD_RELOC_MIPS16_HI16",
870 "BFD_RELOC_MIPS16_HI16_S",
871 "BFD_RELOC_MIPS16_LO16",
872+ "BFD_RELOC_MIPS16_TLS_GD",
873+ "BFD_RELOC_MIPS16_TLS_LDM",
874+ "BFD_RELOC_MIPS16_TLS_DTPREL_HI16",
875+ "BFD_RELOC_MIPS16_TLS_DTPREL_LO16",
876+ "BFD_RELOC_MIPS16_TLS_GOTTPREL",
877+ "BFD_RELOC_MIPS16_TLS_TPREL_HI16",
878+ "BFD_RELOC_MIPS16_TLS_TPREL_LO16",
879 "BFD_RELOC_MIPS_LITERAL",
880 "BFD_RELOC_MICROMIPS_LITERAL",
881 "BFD_RELOC_MICROMIPS_7_PCREL_S1",
882diff --git a/bfd/reloc.c b/bfd/reloc.c
883index 6ac7148..ef55cc3 100644
884--- a/bfd/reloc.c
885+++ b/bfd/reloc.c
886@@ -2247,6 +2247,23 @@ ENUMDOC
887 MIPS16 low 16 bits.
888
889 ENUM
890+ BFD_RELOC_MIPS16_TLS_GD
891+ENUMX
892+ BFD_RELOC_MIPS16_TLS_LDM
893+ENUMX
894+ BFD_RELOC_MIPS16_TLS_DTPREL_HI16
895+ENUMX
896+ BFD_RELOC_MIPS16_TLS_DTPREL_LO16
897+ENUMX
898+ BFD_RELOC_MIPS16_TLS_GOTTPREL
899+ENUMX
900+ BFD_RELOC_MIPS16_TLS_TPREL_HI16
901+ENUMX
902+ BFD_RELOC_MIPS16_TLS_TPREL_LO16
903+ENUMDOC
904+ MIPS16 TLS relocations
905+
906+ENUM
907 BFD_RELOC_MIPS_LITERAL
908 ENUMX
909 BFD_RELOC_MICROMIPS_LITERAL
910diff --git a/gas/config/tc-mips.c b/gas/config/tc-mips.c
911index 0e4c66e..0fb3a6e 100644
912--- a/gas/config/tc-mips.c
913+++ b/gas/config/tc-mips.c
914@@ -1352,6 +1352,8 @@ static void s_cprestore (int);
915 static void s_cpreturn (int);
916 static void s_dtprelword (int);
917 static void s_dtpreldword (int);
918+static void s_tprelword (int);
919+static void s_tpreldword (int);
920 static void s_gpvalue (int);
921 static void s_gpword (int);
922 static void s_gpdword (int);
923@@ -1431,6 +1433,8 @@ static const pseudo_typeS mips_pseudo_table[] =
924 {"cpreturn", s_cpreturn, 0},
925 {"dtprelword", s_dtprelword, 0},
926 {"dtpreldword", s_dtpreldword, 0},
927+ {"tprelword", s_tprelword, 0},
928+ {"tpreldword", s_tpreldword, 0},
929 {"gpvalue", s_gpvalue, 0},
930 {"gpword", s_gpword, 0},
931 {"gpdword", s_gpdword, 0},
932@@ -14040,7 +14044,14 @@ static const struct percent_op_match mips16_percent_op[] =
933 {"%gprel", BFD_RELOC_MIPS16_GPREL},
934 {"%got", BFD_RELOC_MIPS16_GOT16},
935 {"%call16", BFD_RELOC_MIPS16_CALL16},
936- {"%hi", BFD_RELOC_MIPS16_HI16_S}
937+ {"%hi", BFD_RELOC_MIPS16_HI16_S},
938+ {"%tlsgd", BFD_RELOC_MIPS16_TLS_GD},
939+ {"%tlsldm", BFD_RELOC_MIPS16_TLS_LDM},
940+ {"%dtprel_hi", BFD_RELOC_MIPS16_TLS_DTPREL_HI16},
941+ {"%dtprel_lo", BFD_RELOC_MIPS16_TLS_DTPREL_LO16},
942+ {"%tprel_hi", BFD_RELOC_MIPS16_TLS_TPREL_HI16},
943+ {"%tprel_lo", BFD_RELOC_MIPS16_TLS_TPREL_LO16},
944+ {"%gottprel", BFD_RELOC_MIPS16_TLS_GOTTPREL}
945 };
946
947
948@@ -15369,6 +15380,8 @@ md_apply_fix (fixS *fixP, valueT *valP, segT seg ATTRIBUTE_UNUSED)
949 case BFD_RELOC_MIPS_TLS_DTPREL_HI16:
950 case BFD_RELOC_MIPS_TLS_DTPREL_LO16:
951 case BFD_RELOC_MIPS_TLS_GOTTPREL:
952+ case BFD_RELOC_MIPS_TLS_TPREL32:
953+ case BFD_RELOC_MIPS_TLS_TPREL64:
954 case BFD_RELOC_MIPS_TLS_TPREL_HI16:
955 case BFD_RELOC_MIPS_TLS_TPREL_LO16:
956 case BFD_RELOC_MICROMIPS_TLS_GD:
957@@ -15378,6 +15391,13 @@ md_apply_fix (fixS *fixP, valueT *valP, segT seg ATTRIBUTE_UNUSED)
958 case BFD_RELOC_MICROMIPS_TLS_GOTTPREL:
959 case BFD_RELOC_MICROMIPS_TLS_TPREL_HI16:
960 case BFD_RELOC_MICROMIPS_TLS_TPREL_LO16:
961+ case BFD_RELOC_MIPS16_TLS_GD:
962+ case BFD_RELOC_MIPS16_TLS_LDM:
963+ case BFD_RELOC_MIPS16_TLS_DTPREL_HI16:
964+ case BFD_RELOC_MIPS16_TLS_DTPREL_LO16:
965+ case BFD_RELOC_MIPS16_TLS_GOTTPREL:
966+ case BFD_RELOC_MIPS16_TLS_TPREL_HI16:
967+ case BFD_RELOC_MIPS16_TLS_TPREL_LO16:
968 S_SET_THREAD_LOCAL (fixP->fx_addsy);
969 /* fall through */
970
971@@ -16547,12 +16567,14 @@ s_cpreturn (int ignore ATTRIBUTE_UNUSED)
972 demand_empty_rest_of_line ();
973 }
974
975-/* Handle the .dtprelword and .dtpreldword pseudo-ops. They generate
976- a 32-bit or 64-bit DTP-relative relocation (BYTES says which) for
977- use in DWARF debug information. */
978+/* Handle a .dtprelword, .dtpreldword, .tprelword, or .tpreldword
979+ pseudo-op; DIRSTR says which. The pseudo-op generates a BYTES-size
980+ DTP- or TP-relative relocation of type RTYPE, for use in either DWARF
981+ debug information or MIPS16 TLS. */
982
983 static void
984-s_dtprel_internal (size_t bytes)
985+s_tls_rel_directive (const size_t bytes, const char *dirstr,
986+ bfd_reloc_code_real_type rtype)
987 {
988 expressionS ex;
989 char *p;
990@@ -16561,19 +16583,13 @@ s_dtprel_internal (size_t bytes)
991
992 if (ex.X_op != O_symbol)
993 {
994- as_bad (_("Unsupported use of %s"), (bytes == 8
995- ? ".dtpreldword"
996- : ".dtprelword"));
997+ as_bad (_("Unsupported use of %s"), dirstr);
998 ignore_rest_of_line ();
999 }
1000
1001 p = frag_more (bytes);
1002 md_number_to_chars (p, 0, bytes);
1003- fix_new_exp (frag_now, p - frag_now->fr_literal, bytes, &ex, FALSE,
1004- (bytes == 8
1005- ? BFD_RELOC_MIPS_TLS_DTPREL64
1006- : BFD_RELOC_MIPS_TLS_DTPREL32));
1007-
1008+ fix_new_exp (frag_now, p - frag_now->fr_literal, bytes, &ex, FALSE, rtype);
1009 demand_empty_rest_of_line ();
1010 }
1011
1012@@ -16582,7 +16598,7 @@ s_dtprel_internal (size_t bytes)
1013 static void
1014 s_dtprelword (int ignore ATTRIBUTE_UNUSED)
1015 {
1016- s_dtprel_internal (4);
1017+ s_tls_rel_directive (4, ".dtprelword", BFD_RELOC_MIPS_TLS_DTPREL32);
1018 }
1019
1020 /* Handle .dtpreldword. */
1021@@ -16590,7 +16606,23 @@ s_dtprelword (int ignore ATTRIBUTE_UNUSED)
1022 static void
1023 s_dtpreldword (int ignore ATTRIBUTE_UNUSED)
1024 {
1025- s_dtprel_internal (8);
1026+ s_tls_rel_directive (8, ".dtpreldword", BFD_RELOC_MIPS_TLS_DTPREL64);
1027+}
1028+
1029+/* Handle .tprelword. */
1030+
1031+static void
1032+s_tprelword (int ignore ATTRIBUTE_UNUSED)
1033+{
1034+ s_tls_rel_directive (4, ".tprelword", BFD_RELOC_MIPS_TLS_TPREL32);
1035+}
1036+
1037+/* Handle .tpreldword. */
1038+
1039+static void
1040+s_tpreldword (int ignore ATTRIBUTE_UNUSED)
1041+{
1042+ s_tls_rel_directive (8, ".tpreldword", BFD_RELOC_MIPS_TLS_TPREL64);
1043 }
1044
1045 /* Handle the .gpvalue pseudo-op. This is used when generating NewABI PIC
1046diff --git a/include/elf/mips.h b/include/elf/mips.h
1047index db5fa54..c2c5922 100644
1048--- a/include/elf/mips.h
1049+++ b/include/elf/mips.h
1050@@ -98,7 +98,14 @@ START_RELOC_NUMBERS (elf_mips_reloc_type)
1051 RELOC_NUMBER (R_MIPS16_CALL16, 103)
1052 RELOC_NUMBER (R_MIPS16_HI16, 104)
1053 RELOC_NUMBER (R_MIPS16_LO16, 105)
1054- FAKE_RELOC (R_MIPS16_max, 106)
1055+ RELOC_NUMBER (R_MIPS16_TLS_GD, 106)
1056+ RELOC_NUMBER (R_MIPS16_TLS_LDM, 107)
1057+ RELOC_NUMBER (R_MIPS16_TLS_DTPREL_HI16, 108)
1058+ RELOC_NUMBER (R_MIPS16_TLS_DTPREL_LO16, 109)
1059+ RELOC_NUMBER (R_MIPS16_TLS_GOTTPREL, 110)
1060+ RELOC_NUMBER (R_MIPS16_TLS_TPREL_HI16, 111)
1061+ RELOC_NUMBER (R_MIPS16_TLS_TPREL_LO16, 112)
1062+ FAKE_RELOC (R_MIPS16_max, 113)
1063 /* These relocations are specific to VxWorks. */
1064 RELOC_NUMBER (R_MIPS_COPY, 126)
1065 RELOC_NUMBER (R_MIPS_JUMP_SLOT, 127)
1066--
10671.7.9.5
1068
diff --git a/meta/recipes-devtools/binutils/binutils/0039-emulparams-elf32bmip.sh-OTHER_SECTIONS-Put-.mdebug.-.patch b/meta/recipes-devtools/binutils/binutils/0039-emulparams-elf32bmip.sh-OTHER_SECTIONS-Put-.mdebug.-.patch
deleted file mode 100644
index 657d6739eb..0000000000
--- a/meta/recipes-devtools/binutils/binutils/0039-emulparams-elf32bmip.sh-OTHER_SECTIONS-Put-.mdebug.-.patch
+++ /dev/null
@@ -1,49 +0,0 @@
1Upstream-Status: Backport
2
3From 80041361bf80194da35c5efb842125f3ce1d2bf2 Mon Sep 17 00:00:00 2001
4From: Joseph Myers <joseph@codesourcery.com>
5Date: Tue, 20 Dec 2011 18:00:03 +0000
6Subject: [PATCH 039/262] * emulparams/elf32bmip.sh (OTHER_SECTIONS):
7 Put .mdebug.* and .gcc_compiled_long* sections
8 at address 0.
9
10---
11 ld/ChangeLog | 5 +++++
12 ld/emulparams/elf32bmip.sh | 16 ++++++++--------
13 2 files changed, 13 insertions(+), 8 deletions(-)
14
152011-12-20 Joseph Myers <joseph@codesourcery.com>
16
17 * emulparams/elf32bmip.sh (OTHER_SECTIONS): Put .mdebug.* and
18 .gcc_compiled_long* sections at address 0.
19
20diff --git a/ld/emulparams/elf32bmip.sh b/ld/emulparams/elf32bmip.sh
21index 44a0b8a..f0fcd2c 100644
22--- a/ld/emulparams/elf32bmip.sh
23+++ b/ld/emulparams/elf32bmip.sh
24@@ -64,14 +64,14 @@ OTHER_BSS_SYMBOLS='_fbss = .;'
25 OTHER_SECTIONS='
26 .gptab.sdata : { *(.gptab.data) *(.gptab.sdata) }
27 .gptab.sbss : { *(.gptab.bss) *(.gptab.sbss) }
28- .mdebug.abi32 : { KEEP(*(.mdebug.abi32)) }
29- .mdebug.abiN32 : { KEEP(*(.mdebug.abiN32)) }
30- .mdebug.abi64 : { KEEP(*(.mdebug.abi64)) }
31- .mdebug.abiO64 : { KEEP(*(.mdebug.abiO64)) }
32- .mdebug.eabi32 : { KEEP(*(.mdebug.eabi32)) }
33- .mdebug.eabi64 : { KEEP(*(.mdebug.eabi64)) }
34- .gcc_compiled_long32 : { KEEP(*(.gcc_compiled_long32)) }
35- .gcc_compiled_long64 : { KEEP(*(.gcc_compiled_long64)) }
36+ .mdebug.abi32 0 : { KEEP(*(.mdebug.abi32)) }
37+ .mdebug.abiN32 0 : { KEEP(*(.mdebug.abiN32)) }
38+ .mdebug.abi64 0 : { KEEP(*(.mdebug.abi64)) }
39+ .mdebug.abiO64 0 : { KEEP(*(.mdebug.abiO64)) }
40+ .mdebug.eabi32 0 : { KEEP(*(.mdebug.eabi32)) }
41+ .mdebug.eabi64 0 : { KEEP(*(.mdebug.eabi64)) }
42+ .gcc_compiled_long32 0 : { KEEP(*(.gcc_compiled_long32)) }
43+ .gcc_compiled_long64 0 : { KEEP(*(.gcc_compiled_long64)) }
44 '
45 ARCH=mips
46 MACHINE=
47--
481.7.9.5
49
diff --git a/meta/recipes-devtools/binutils/binutils/0052-gas.patch b/meta/recipes-devtools/binutils/binutils/0052-gas.patch
deleted file mode 100644
index a9bb3ac0e4..0000000000
--- a/meta/recipes-devtools/binutils/binutils/0052-gas.patch
+++ /dev/null
@@ -1,83 +0,0 @@
1Upstream-Status: Backport
2
3From e45a3a5695408d472e8f0ca6c21eb03e5fd42817 Mon Sep 17 00:00:00 2001
4From: Richard Sandiford <rsandifo@nildram.co.uk>
5Date: Sun, 8 Jan 2012 12:34:30 +0000
6Subject: [PATCH 052/262] gas/ * config/tc-mips.c (s_tls_rel_directive):
7 Call mips_clear_insn_labels.
8
9gas/testsuite/
10 * gas/mips/tls-relw.s, gas/mips/tls-relw.d: New test.
11 * gas/mips/mips.exp: Run it.
12---
13 gas/ChangeLog | 4 ++++
14 gas/config/tc-mips.c | 1 +
15 gas/testsuite/ChangeLog | 5 +++++
16 gas/testsuite/gas/mips/mips.exp | 1 +
17 gas/testsuite/gas/mips/tls-relw.d | 8 ++++++++
18 gas/testsuite/gas/mips/tls-relw.s | 12 ++++++++++++
19 6 files changed, 31 insertions(+)
20 create mode 100644 gas/testsuite/gas/mips/tls-relw.d
21 create mode 100644 gas/testsuite/gas/mips/tls-relw.s
22
232012-01-08 Richard Sandiford <rdsandiford@googlemail.com>
24
25 * config/tc-mips.c (s_tls_rel_directive): Call mips_clear_insn_labels.
26
27diff --git a/gas/config/tc-mips.c b/gas/config/tc-mips.c
28index 0fb3a6e..5324450 100644
29--- a/gas/config/tc-mips.c
30+++ b/gas/config/tc-mips.c
31@@ -16591,6 +16591,7 @@ s_tls_rel_directive (const size_t bytes, const char *dirstr,
32 md_number_to_chars (p, 0, bytes);
33 fix_new_exp (frag_now, p - frag_now->fr_literal, bytes, &ex, FALSE, rtype);
34 demand_empty_rest_of_line ();
35+ mips_clear_insn_labels ();
36 }
37
38 /* Handle .dtprelword. */
39--- a/gas/testsuite/gas/mips/mips.exp
40+++ b/gas/testsuite/gas/mips/mips.exp
41@@ -878,6 +878,7 @@ if { [istarget mips*-*-vxworks*] } {
42
43 run_list_test "tls-ill" "-32"
44 run_dump_test "tls-o32"
45+ run_dump_test "tls-relw"
46 run_dump_test "jalr2"
47
48 run_dump_test_arches "aent" [mips_arch_list_matching mips1]
49diff --git a/gas/testsuite/gas/mips/tls-relw.d b/gas/testsuite/gas/mips/tls-relw.d
50new file mode 100644
51index 0000000..bc13b43
52--- /dev/null
53+++ b/gas/testsuite/gas/mips/tls-relw.d
54@@ -0,0 +1,8 @@
55+# as: -EB
56+# objdump: -sj.data
57+
58+.*
59+
60+Contents of section \.data:
61+ 0000 00000001 00000000 00000002 00000004 ................
62+ 0010 00000000 00000003 00000010 00000000 ................
63diff --git a/gas/testsuite/gas/mips/tls-relw.s b/gas/testsuite/gas/mips/tls-relw.s
64new file mode 100644
65index 0000000..6890685
66--- /dev/null
67+++ b/gas/testsuite/gas/mips/tls-relw.s
68@@ -0,0 +1,12 @@
69+ .data
70+start:
71+ .word 1
72+a:
73+ .tprelword t1
74+ .word 2
75+ .word a-start
76+b:
77+ .dtprelword t2
78+ .word 3
79+ .word b-start
80+ .word 0
81--
821.7.9.5
83
diff --git a/meta/recipes-devtools/binutils/binutils/0055-Remove-ABI_64_P-check-on-R_X86_64_PCXX.patch b/meta/recipes-devtools/binutils/binutils/0055-Remove-ABI_64_P-check-on-R_X86_64_PCXX.patch
deleted file mode 100644
index 697d70eac5..0000000000
--- a/meta/recipes-devtools/binutils/binutils/0055-Remove-ABI_64_P-check-on-R_X86_64_PCXX.patch
+++ /dev/null
@@ -1,176 +0,0 @@
1Upstream-Status: Backport
2
3From fee27086a7592c1812253e9c1c26f412dd87f3a2 Mon Sep 17 00:00:00 2001
4From: "H.J. Lu" <hjl.tools@gmail.com>
5Date: Tue, 10 Jan 2012 20:34:56 +0000
6Subject: [PATCH 055/262] Remove ABI_64_P check on R_X86_64_PCXX
7
8bfd/
9
102012-01-10 H.J. Lu <hongjiu.lu@intel.com>
11
12 PR ld/13581
13 * elf64-x86-64.c (elf_x86_64_relocate_section): Remove ABI_64_P
14 check on R_X86_64_PCXX.
15
16ld/testsuite/
17
182012-01-10 H.J. Lu <hongjiu.lu@intel.com>
19
20 PR ld/13581
21 * ld-x86-64/ilp32-4.s: New.
22 * ld-x86-64/ilp32-10.d: Likewise.
23 * ld-x86-64/ilp32-10.s: Likewise.
24
25 * ld-x86-64/ilp32-4.d: Adjusted.
26 * ld-x86-64/ilp32-5.d: Likewise.
27 * ld-x86-64/ilp32-5.s: Likewise.
28
29 * ld-x86-64/x86-64.exp: Run ilp32-10.
30---
31 bfd/ChangeLog | 7 +++++++
32 bfd/elf64-x86-64.c | 1 -
33 ld/testsuite/ChangeLog | 14 ++++++++++++++
34 ld/testsuite/ld-x86-64/ilp32-10.d | 3 +++
35 ld/testsuite/ld-x86-64/ilp32-10.s | 3 +++
36 ld/testsuite/ld-x86-64/ilp32-4.d | 32 +++++++++++++-------------------
37 ld/testsuite/ld-x86-64/ilp32-4.s | 3 +++
38 ld/testsuite/ld-x86-64/ilp32-5.d | 2 +-
39 ld/testsuite/ld-x86-64/ilp32-5.s | 2 +-
40 ld/testsuite/ld-x86-64/x86-64.exp | 1 +
41 10 files changed, 46 insertions(+), 22 deletions(-)
42 create mode 100644 ld/testsuite/ld-x86-64/ilp32-10.d
43 create mode 100644 ld/testsuite/ld-x86-64/ilp32-10.s
44 create mode 100644 ld/testsuite/ld-x86-64/ilp32-4.s
45
46diff --git a/bfd/elf64-x86-64.c b/bfd/elf64-x86-64.c
47index 3a2444b..bdb3ae6 100644
48--- a/bfd/elf64-x86-64.c
49+++ b/bfd/elf64-x86-64.c
50@@ -3460,7 +3460,6 @@ elf_x86_64_relocate_section (bfd *output_bfd,
51 case R_X86_64_PC16:
52 case R_X86_64_PC32:
53 if (info->shared
54- && ABI_64_P (output_bfd)
55 && (input_section->flags & SEC_ALLOC) != 0
56 && (input_section->flags & SEC_READONLY) != 0
57 && h != NULL)
58diff --git a/ld/testsuite/ld-x86-64/ilp32-10.d b/ld/testsuite/ld-x86-64/ilp32-10.d
59new file mode 100644
60index 0000000..43d9fbd
61--- /dev/null
62+++ b/ld/testsuite/ld-x86-64/ilp32-10.d
63@@ -0,0 +1,3 @@
64+#as: --x32
65+#ld: -shared -melf32_x86_64
66+#error: .*relocation R_X86_64_PC32 against undefined symbol `bar' can not be used when making a shared object; recompile with -fPIC
67diff --git a/ld/testsuite/ld-x86-64/ilp32-10.s b/ld/testsuite/ld-x86-64/ilp32-10.s
68new file mode 100644
69index 0000000..70e4a90
70--- /dev/null
71+++ b/ld/testsuite/ld-x86-64/ilp32-10.s
72@@ -0,0 +1,3 @@
73+ .globl foo
74+foo:
75+ mov bar(%rip), %rax
76diff --git a/ld/testsuite/ld-x86-64/ilp32-4.d b/ld/testsuite/ld-x86-64/ilp32-4.d
77index 84dc7b2..92d8a67 100644
78--- a/ld/testsuite/ld-x86-64/ilp32-4.d
79+++ b/ld/testsuite/ld-x86-64/ilp32-4.d
80@@ -1,36 +1,30 @@
81-#source: start.s
82 #as: --x32
83 #ld: -m elf32_x86_64 -shared --no-ld-generated-unwind-info
84 #readelf: -d -S --wide
85
86-There are 10 section headers, starting at offset 0x22c:
87+There are 9 section headers, starting at offset 0x1d8:
88
89 Section Headers:
90 \[Nr\] Name Type Addr Off Size ES Flg Lk Inf Al
91 \[ 0\] NULL 00000000 000000 000000 00 0 0 0
92- \[ 1\] .hash HASH 00000094 000094 000030 04 A 2 0 4
93- \[ 2\] .dynsym DYNSYM 000000c4 0000c4 000070 10 A 3 2 4
94- \[ 3\] .dynstr STRTAB 00000134 000134 00001d 00 A 0 0 1
95- \[ 4\] .rela.dyn RELA 00000154 000154 00000c 0c A 2 0 4
96- \[ 5\] .text PROGBITS 00000160 000160 000005 00 AX 0 0 4
97- \[ 6\] .dynamic DYNAMIC 00200168 000168 000078 08 WA 3 0 4
98- \[ 7\] .shstrtab STRTAB 00000000 0001e0 00004a 00 0 0 1
99- \[ 8\] .symtab SYMTAB 00000000 0003bc 0000e0 10 9 9 4
100- \[ 9\] .strtab STRTAB 00000000 00049c 000043 00 0 0 1
101+ \[ 1\] .hash HASH 00000094 000094 00002c 04 A 2 0 4
102+ \[ 2\] .dynsym DYNSYM 000000c0 0000c0 000060 10 A 3 2 4
103+ \[ 3\] .dynstr STRTAB 00000120 000120 000019 00 A 0 0 1
104+ \[ 4\] .text PROGBITS 0000013c 00013c 000001 00 AX 0 0 4
105+ \[ 5\] .dynamic DYNAMIC 00200140 000140 000058 08 WA 3 0 4
106+ \[ 6\] .shstrtab STRTAB 00000000 000198 000040 00 0 0 1
107+ \[ 7\] .symtab SYMTAB 00000000 000340 0000c0 10 8 8 4
108+ \[ 8\] .strtab STRTAB 00000000 000400 00003f 00 0 0 1
109 Key to Flags:
110 W \(write\), A \(alloc\), X \(execute\), M \(merge\), S \(strings\), l \(large\)
111 I \(info\), L \(link order\), G \(group\), T \(TLS\), E \(exclude\), x \(unknown\)
112 O \(extra OS processing required\) o \(OS specific\), p \(processor specific\)
113
114-Dynamic section at offset 0x168 contains 10 entries:
115+Dynamic section at offset 0x140 contains 6 entries:
116 Tag Type Name/Value
117 0x00000004 \(HASH\) 0x94
118- 0x00000005 \(STRTAB\) 0x134
119- 0x00000006 \(SYMTAB\) 0xc4
120- 0x0000000a \(STRSZ\) 29 \(bytes\)
121+ 0x00000005 \(STRTAB\) 0x120
122+ 0x00000006 \(SYMTAB\) 0xc0
123+ 0x0000000a \(STRSZ\) 25 \(bytes\)
124 0x0000000b \(SYMENT\) 16 \(bytes\)
125- 0x00000007 \(RELA\) 0x154
126- 0x00000008 \(RELASZ\) 12 \(bytes\)
127- 0x00000009 \(RELAENT\) 12 \(bytes\)
128- 0x00000016 \(TEXTREL\) 0x0
129 0x00000000 \(NULL\) 0x0
130diff --git a/ld/testsuite/ld-x86-64/ilp32-4.s b/ld/testsuite/ld-x86-64/ilp32-4.s
131new file mode 100644
132index 0000000..5f270c7
133--- /dev/null
134+++ b/ld/testsuite/ld-x86-64/ilp32-4.s
135@@ -0,0 +1,3 @@
136+ .globl _start
137+_start:
138+ ret
139diff --git a/ld/testsuite/ld-x86-64/ilp32-5.d b/ld/testsuite/ld-x86-64/ilp32-5.d
140index e4673e5..4870c2b 100644
141--- a/ld/testsuite/ld-x86-64/ilp32-5.d
142+++ b/ld/testsuite/ld-x86-64/ilp32-5.d
143@@ -4,5 +4,5 @@
144
145 #...
146 [0-9a-f]+ +[0-9a-f]+ +R_X86_64_RELATIVE +[0-9a-f]+
147-[0-9a-f]+ +[0-9a-f]+ +R_X86_64_PC32 +[0-9a-f]+ +foo - 4
148+[0-9a-f]+ +[0-9a-f]+ +R_X86_64_GLOB_DAT +[0-9a-f]+ +foo \+ 0
149 [0-9a-f]+ +[0-9a-f]+ +R_X86_64_32 +[0-9a-f]+ +foo \+ 0
150diff --git a/ld/testsuite/ld-x86-64/ilp32-5.s b/ld/testsuite/ld-x86-64/ilp32-5.s
151index 0d97807..ef0c60e 100644
152--- a/ld/testsuite/ld-x86-64/ilp32-5.s
153+++ b/ld/testsuite/ld-x86-64/ilp32-5.s
154@@ -1,6 +1,6 @@
155 .globl bar
156 bar:
157- mov foo(%rip), %rax
158+ mov foo@GOTPCREL(%rip), %rax
159
160 .data
161 xxx:
162diff --git a/ld/testsuite/ld-x86-64/x86-64.exp b/ld/testsuite/ld-x86-64/x86-64.exp
163index 77b081b..44d3e07 100644
164--- a/ld/testsuite/ld-x86-64/x86-64.exp
165+++ b/ld/testsuite/ld-x86-64/x86-64.exp
166@@ -207,6 +207,7 @@ run_dump_test "ilp32-6"
167 run_dump_test "ilp32-7"
168 run_dump_test "ilp32-8"
169 run_dump_test "ilp32-9"
170+run_dump_test "ilp32-10"
171 run_dump_test "ia32-1"
172 run_dump_test "ia32-2"
173 run_dump_test "ia32-3"
174--
1751.7.9.5
176
diff --git a/meta/recipes-devtools/binutils/binutils/0078-PR-binutils-13622.patch b/meta/recipes-devtools/binutils/binutils/0078-PR-binutils-13622.patch
deleted file mode 100644
index a28fc9d8e9..0000000000
--- a/meta/recipes-devtools/binutils/binutils/0078-PR-binutils-13622.patch
+++ /dev/null
@@ -1,48 +0,0 @@
1Upstream-Status: Backport
2
3From dcf0cb6bb406708020efe2db44f53af0fe822773 Mon Sep 17 00:00:00 2001
4From: Nick Clifton <nickc@redhat.com>
5Date: Mon, 30 Jan 2012 11:35:37 +0000
6Subject: [PATCH 078/262] PR binutils/13622 * readelf.c
7 (process_section_groups): If there are no section
8 headers do not scan for section groups.
9 (process_note_sections): Likewise for note
10 sections.
11
12---
13 binutils/ChangeLog | 7 +++++++
14 binutils/readelf.c | 5 +++--
15 2 files changed, 10 insertions(+), 2 deletions(-)
16
172012-01-26 Nick Clifton <nickc@redhat.com>
18
19 PR binutils/13622
20 * readelf.c (process_section_groups): If there are no section
21 headers do not scan for section groups.
22 (process_note_sections): Likewise for note sections.
23diff --git a/binutils/readelf.c b/binutils/readelf.c
24index 9e13190..bf053d9 100644
25--- a/binutils/readelf.c
26+++ b/binutils/readelf.c
27@@ -4937,7 +4937,8 @@ process_section_groups (FILE * file)
28 if (section_headers == NULL)
29 {
30 error (_("Section headers are not available!\n"));
31- abort ();
32+ /* PR 13622: This can happen with a corrupt ELF header. */
33+ return 0;
34 }
35
36 section_headers_groups = (struct group **) calloc (elf_header.e_shnum,
37@@ -12942,7 +12943,7 @@ process_note_sections (FILE * file)
38 int res = 1;
39
40 for (i = 0, section = section_headers;
41- i < elf_header.e_shnum;
42+ i < elf_header.e_shnum && section != NULL;
43 i++, section++)
44 if (section->sh_type == SHT_NOTE)
45 res &= process_corefile_note_segment (file,
46--
471.7.9.5
48
diff --git a/meta/recipes-devtools/binutils/binutils/0144-timer.cc-include-unistd.h.patch b/meta/recipes-devtools/binutils/binutils/0144-timer.cc-include-unistd.h.patch
deleted file mode 100644
index 271c513daf..0000000000
--- a/meta/recipes-devtools/binutils/binutils/0144-timer.cc-include-unistd.h.patch
+++ /dev/null
@@ -1,32 +0,0 @@
1Upstream-Status: Backport
2
3From b7578c6b7bd966b63ab1b2682fd90ed4f3a92e71 Mon Sep 17 00:00:00 2001
4From: Ian Lance Taylor <ian@airs.com>
5Date: Fri, 6 Apr 2012 17:23:58 +0000
6Subject: [PATCH 144/262] * timer.cc: #include <unistd.h>.
7
8---
9 gold/ChangeLog | 4 ++++
10 gold/timer.cc | 2 ++
11 2 files changed, 6 insertions(+)
12
132012-04-06 Ian Lance Taylor <iant@google.com>
14
15 * timer.cc: #include <unistd.h>.
16
17diff --git a/gold/timer.cc b/gold/timer.cc
18index d9b8874..44e19f5 100644
19--- a/gold/timer.cc
20+++ b/gold/timer.cc
21@@ -22,6 +22,8 @@
22
23 #include "gold.h"
24
25+#include <unistd.h>
26+
27 #ifdef HAVE_TIMES
28 #include <sys/times.h>
29 #endif
30--
311.7.9.5
32
diff --git a/meta/recipes-devtools/binutils/binutils/0166-2012-04-27-Doug-Kwan-dougkwan-google.com.patch b/meta/recipes-devtools/binutils/binutils/0166-2012-04-27-Doug-Kwan-dougkwan-google.com.patch
deleted file mode 100644
index bd1ff5bd95..0000000000
--- a/meta/recipes-devtools/binutils/binutils/0166-2012-04-27-Doug-Kwan-dougkwan-google.com.patch
+++ /dev/null
@@ -1,169 +0,0 @@
1Upstream-Status: Backport
2
3From b6db4b7975d21ec53da5975ddac021098da13bf3 Mon Sep 17 00:00:00 2001
4From: Doug Kwan <dougkwan@google.com>
5Date: Thu, 26 Apr 2012 18:08:19 +0000
6Subject: [PATCH 166/262] 2012-04-27 Doug Kwan <dougkwan@google.com>
7
8 Backport from mainline:
9
10 2012-03-16 Doug Kwan <dougkwan@google.com>
11
12 * testsuite/Makefile.am: Disable test initpri3b.
13 * testsuite/Makefile.in: Regenerate.
14
15 2012-03-14 Doug Kwan <dougkwan@google.com>
16
17 * gold/arm.cc (Target_arm::Scan::global): Generate
18 R_ARM_GLOB_DAT dynamic relocations for protected symbols in
19 shared objects.
20---
21 gold/ChangeLog | 15 +++++++++++++++
22 gold/arm.cc | 4 +++-
23 gold/testsuite/Makefile.am | 15 ++++++++++-----
24 gold/testsuite/Makefile.in | 32 +++++++++++++-------------------
25 4 files changed, 41 insertions(+), 25 deletions(-)
26
27diff --git a/gold/arm.cc b/gold/arm.cc
28index 72c3670..a1e8e4c 100644
29--- a/gold/arm.cc
30+++ b/gold/arm.cc
31@@ -8374,7 +8374,9 @@ Target_arm<big_endian>::Scan::global(Symbol_table* symtab,
32 Reloc_section* rel_dyn = target->rel_dyn_section(layout);
33 if (gsym->is_from_dynobj()
34 || gsym->is_undefined()
35- || gsym->is_preemptible())
36+ || gsym->is_preemptible()
37+ || (gsym->visibility() == elfcpp::STV_PROTECTED
38+ && parameters->options().shared()))
39 got->add_global_with_rel(gsym, GOT_TYPE_STANDARD,
40 rel_dyn, elfcpp::R_ARM_GLOB_DAT);
41 else
42diff --git a/gold/testsuite/Makefile.am b/gold/testsuite/Makefile.am
43index 9b8605b..97d6457 100644
44--- a/gold/testsuite/Makefile.am
45+++ b/gold/testsuite/Makefile.am
46@@ -870,11 +870,16 @@ initpri3a_DEPENDENCIES = gcctestdir/ld
47 initpri3a_LDFLAGS = -Bgcctestdir/
48 initpri3a_LDADD =
49
50-check_PROGRAMS += initpri3b
51-initpri3b_SOURCES = initpri3.c
52-initpri3b_DEPENDENCIES = gcctestdir/ld
53-initpri3b_LDFLAGS = -Bgcctestdir/ -Wl,--no-ctors-in-init-array
54-initpri3b_LDADD =
55+# This test fails on targets not using .ctors and .dtors sections (e.g. ARM
56+# EABI). Given that gcc is moving towards using .init_array in all cases,
57+# this test is commented out. A better fix would be checking whether gcc
58+# uses .ctors or .init_array sections in configure.
59+
60+# check_PROGRAMS += initpri3b
61+# initpri3b_SOURCES = initpri3.c
62+# initpri3b_DEPENDENCIES = gcctestdir/ld
63+# initpri3b_LDFLAGS = -Bgcctestdir/ -Wl,--no-ctors-in-init-array
64+# initpri3b_LDADD =
65
66 # Test --detect-odr-violations
67 check_SCRIPTS += debug_msg.sh
68diff --git a/gold/testsuite/Makefile.in b/gold/testsuite/Makefile.in
69index 785dcdd..518d32b 100644
70--- a/gold/testsuite/Makefile.in
71+++ b/gold/testsuite/Makefile.in
72@@ -56,6 +56,17 @@ check_PROGRAMS = $(am__EXEEXT_1) $(am__EXEEXT_2) $(am__EXEEXT_3) \
73 @NATIVE_OR_CROSS_LINKER_TRUE@am__append_1 = object_unittest \
74 @NATIVE_OR_CROSS_LINKER_TRUE@ binary_unittest
75
76+# This test fails on targets not using .ctors and .dtors sections (e.g. ARM
77+# EABI). Given that gcc is moving towards using .init_array in all cases,
78+# this test is commented out. A better fix would be checking whether gcc
79+# uses .ctors or .init_array sections in configure.
80+
81+# check_PROGRAMS += initpri3b
82+# initpri3b_SOURCES = initpri3.c
83+# initpri3b_DEPENDENCIES = gcctestdir/ld
84+# initpri3b_LDFLAGS = -Bgcctestdir/ -Wl,--no-ctors-in-init-array
85+# initpri3b_LDADD =
86+
87 # Test --detect-odr-violations
88
89 # Similar to --detect-odr-violations: check for undefined symbols in .so's
90@@ -189,7 +200,7 @@ check_PROGRAMS = $(am__EXEEXT_1) $(am__EXEEXT_2) $(am__EXEEXT_3) \
91 # Test -o when emitting to a special file (such as something in /dev).
92 @GCC_TRUE@@NATIVE_LINKER_TRUE@am__append_24 = many_sections_test \
93 @GCC_TRUE@@NATIVE_LINKER_TRUE@ many_sections_r_test initpri1 \
94-@GCC_TRUE@@NATIVE_LINKER_TRUE@ initpri2 initpri3a initpri3b \
95+@GCC_TRUE@@NATIVE_LINKER_TRUE@ initpri2 initpri3a \
96 @GCC_TRUE@@NATIVE_LINKER_TRUE@ flagstest_o_specialfile
97 @GCC_FALSE@many_sections_test_DEPENDENCIES =
98 @NATIVE_LINKER_FALSE@many_sections_test_DEPENDENCIES =
99@@ -204,8 +215,6 @@ check_PROGRAMS = $(am__EXEEXT_1) $(am__EXEEXT_2) $(am__EXEEXT_3) \
100 @NATIVE_LINKER_FALSE@initpri2_DEPENDENCIES =
101 @GCC_FALSE@initpri3a_DEPENDENCIES =
102 @NATIVE_LINKER_FALSE@initpri3a_DEPENDENCIES =
103-@GCC_FALSE@initpri3b_DEPENDENCIES =
104-@NATIVE_LINKER_FALSE@initpri3b_DEPENDENCIES =
105
106 # Check that --detect-odr-violations works with compressed debug sections.
107 @GCC_TRUE@@HAVE_ZLIB_TRUE@@NATIVE_LINKER_TRUE@am__append_27 = debug_msg_cdebug.err
108@@ -712,7 +721,6 @@ libgoldtest_a_OBJECTS = $(am_libgoldtest_a_OBJECTS)
109 @GCC_TRUE@@NATIVE_LINKER_TRUE@ initpri1$(EXEEXT) \
110 @GCC_TRUE@@NATIVE_LINKER_TRUE@ initpri2$(EXEEXT) \
111 @GCC_TRUE@@NATIVE_LINKER_TRUE@ initpri3a$(EXEEXT) \
112-@GCC_TRUE@@NATIVE_LINKER_TRUE@ initpri3b$(EXEEXT) \
113 @GCC_TRUE@@NATIVE_LINKER_TRUE@ flagstest_o_specialfile$(EXEEXT)
114 @GCC_TRUE@@HAVE_ZLIB_TRUE@@NATIVE_LINKER_TRUE@am__EXEEXT_21 = flagstest_compress_debug_sections$(EXEEXT) \
115 @GCC_TRUE@@HAVE_ZLIB_TRUE@@NATIVE_LINKER_TRUE@ flagstest_o_specialfile_and_compress_debug_sections$(EXEEXT)
116@@ -1200,11 +1208,6 @@ initpri2_LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(initpri2_LDFLAGS) \
117 initpri3a_OBJECTS = $(am_initpri3a_OBJECTS)
118 initpri3a_LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(initpri3a_LDFLAGS) \
119 $(LDFLAGS) -o $@
120-@GCC_TRUE@@NATIVE_LINKER_TRUE@am_initpri3b_OBJECTS = \
121-@GCC_TRUE@@NATIVE_LINKER_TRUE@ initpri3.$(OBJEXT)
122-initpri3b_OBJECTS = $(am_initpri3b_OBJECTS)
123-initpri3b_LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(initpri3b_LDFLAGS) \
124- $(LDFLAGS) -o $@
125 @GCC_TRUE@@NATIVE_LINKER_TRUE@am_justsyms_OBJECTS = \
126 @GCC_TRUE@@NATIVE_LINKER_TRUE@ justsyms_1.$(OBJEXT)
127 justsyms_OBJECTS = $(am_justsyms_OBJECTS)
128@@ -1698,7 +1701,7 @@ SOURCES = $(libgoldtest_a_SOURCES) basic_pic_test.c basic_pie_test.c \
129 incremental_copy_test.c incremental_test_2.c \
130 incremental_test_3.c incremental_test_4.c incremental_test_5.c \
131 incremental_test_6.c $(initpri1_SOURCES) $(initpri2_SOURCES) \
132- $(initpri3a_SOURCES) $(initpri3b_SOURCES) $(justsyms_SOURCES) \
133+ $(initpri3a_SOURCES) $(justsyms_SOURCES) \
134 $(justsyms_exec_SOURCES) $(large_SOURCES) local_labels_test.c \
135 many_sections_r_test.c $(many_sections_test_SOURCES) \
136 $(object_unittest_SOURCES) permission_test.c plugin_test_1.c \
137@@ -2281,10 +2284,6 @@ LDADD = libgoldtest.a ../libgold.a ../../libiberty/libiberty.a $(LIBINTL) \
138 @GCC_TRUE@@NATIVE_LINKER_TRUE@initpri3a_DEPENDENCIES = gcctestdir/ld
139 @GCC_TRUE@@NATIVE_LINKER_TRUE@initpri3a_LDFLAGS = -Bgcctestdir/
140 @GCC_TRUE@@NATIVE_LINKER_TRUE@initpri3a_LDADD =
141-@GCC_TRUE@@NATIVE_LINKER_TRUE@initpri3b_SOURCES = initpri3.c
142-@GCC_TRUE@@NATIVE_LINKER_TRUE@initpri3b_DEPENDENCIES = gcctestdir/ld
143-@GCC_TRUE@@NATIVE_LINKER_TRUE@initpri3b_LDFLAGS = -Bgcctestdir/ -Wl,--no-ctors-in-init-array
144-@GCC_TRUE@@NATIVE_LINKER_TRUE@initpri3b_LDADD =
145 @GCC_TRUE@@NATIVE_LINKER_TRUE@ver_test_SOURCES = ver_test_main.cc
146 @GCC_TRUE@@NATIVE_LINKER_TRUE@ver_test_DEPENDENCIES = gcctestdir/ld ver_test_1.so ver_test_2.so ver_test_4.so
147 @GCC_TRUE@@NATIVE_LINKER_TRUE@ver_test_LDFLAGS = -Bgcctestdir/ -Wl,-R,.
148@@ -2928,9 +2927,6 @@ initpri2$(EXEEXT): $(initpri2_OBJECTS) $(initpri2_DEPENDENCIES)
149 initpri3a$(EXEEXT): $(initpri3a_OBJECTS) $(initpri3a_DEPENDENCIES)
150 @rm -f initpri3a$(EXEEXT)
151 $(initpri3a_LINK) $(initpri3a_OBJECTS) $(initpri3a_LDADD) $(LIBS)
152-initpri3b$(EXEEXT): $(initpri3b_OBJECTS) $(initpri3b_DEPENDENCIES)
153- @rm -f initpri3b$(EXEEXT)
154- $(initpri3b_LINK) $(initpri3b_OBJECTS) $(initpri3b_LDADD) $(LIBS)
155 justsyms$(EXEEXT): $(justsyms_OBJECTS) $(justsyms_DEPENDENCIES)
156 @rm -f justsyms$(EXEEXT)
157 $(justsyms_LINK) $(justsyms_OBJECTS) $(justsyms_LDADD) $(LIBS)
158@@ -3869,8 +3865,6 @@ initpri2.log: initpri2$(EXEEXT)
159 @p='initpri2$(EXEEXT)'; $(am__check_pre) $(LOG_COMPILE) "$$tst" $(am__check_post)
160 initpri3a.log: initpri3a$(EXEEXT)
161 @p='initpri3a$(EXEEXT)'; $(am__check_pre) $(LOG_COMPILE) "$$tst" $(am__check_post)
162-initpri3b.log: initpri3b$(EXEEXT)
163- @p='initpri3b$(EXEEXT)'; $(am__check_pre) $(LOG_COMPILE) "$$tst" $(am__check_post)
164 flagstest_o_specialfile.log: flagstest_o_specialfile$(EXEEXT)
165 @p='flagstest_o_specialfile$(EXEEXT)'; $(am__check_pre) $(LOG_COMPILE) "$$tst" $(am__check_post)
166 flagstest_compress_debug_sections.log: flagstest_compress_debug_sections$(EXEEXT)
167--
1681.7.9.5
169
diff --git a/meta/recipes-devtools/binutils/binutils/0182-PR-ld-13991.patch b/meta/recipes-devtools/binutils/binutils/0182-PR-ld-13991.patch
deleted file mode 100644
index f4c94388c8..0000000000
--- a/meta/recipes-devtools/binutils/binutils/0182-PR-ld-13991.patch
+++ /dev/null
@@ -1,1617 +0,0 @@
1Upstream-Status: Backport
2
3From e827844b6119ff7e0c2de167f2b261c6c06226c8 Mon Sep 17 00:00:00 2001
4From: Nick Clifton <nickc@redhat.com>
5Date: Fri, 11 May 2012 12:24:12 +0000
6Subject: [PATCH 182/262] PR ld/13991 bfd/ * bfd/elf-bfd.h
7 (_bfd_elf_link_just_syms): Define as
8 _bfd_generic_link_just_syms. * bfd/elflink.c
9 (_bfd_elf_link_just_syms): Delete. *
10 bfd/linker.c (_bfd_generic_link_just_syms): Set
11 sec_info_type.
12
13 * bfd/bfd-in.h (discarded_section): Renamed from elf_discarded_section.
14 * bfd/section.c (SEC_INFO_TYPE_NONE, SEC_INFO_TYPE_STABS,
15 SEC_INFO_TYPE_MERGE, SEC_INFO_TYPE_EH_FRAME,
16 SEC_INFO_TYPE_JUST_SYMS): Renamed from corresponding ELF_INFO_TYPE.
17 * bfd/elf-eh-frame.c, * bfd/elf-m10200.c, * bfd/elf-m10300.c,
18 * bfd/elf.c, * bfd/elf32-arm.c, * bfd/elf32-avr.c, * bfd/elf32-bfin.c,
19 * bfd/elf32-cr16.c, * bfd/elf32-cr16c.c, * bfd/elf32-cris.c,
20 * bfd/elf32-crx.c, * bfd/elf32-d10v.c, * bfd/elf32-epiphany.c,
21 * bfd/elf32-fr30.c, * bfd/elf32-frv.c, * bfd/elf32-h8300.c,
22 * bfd/elf32-hppa.c, * bfd/elf32-i370.c, * bfd/elf32-i386.c,
23 * bfd/elf32-i860.c, * bfd/elf32-ip2k.c, * bfd/elf32-iq2000.c,
24 * bfd/elf32-lm32.c, * bfd/elf32-m32c.c, * bfd/elf32-m32r.c,
25 * bfd/elf32-m68hc1x.c, * bfd/elf32-m68k.c, * bfd/elf32-mcore.c,
26 * bfd/elf32-mep.c, * bfd/elf32-moxie.c, * bfd/elf32-msp430.c,
27 * bfd/elf32-mt.c, * bfd/elf32-openrisc.c, * bfd/elf32-ppc.c,
28 * bfd/elf32-rl78.c, * bfd/elf32-rx.c, * bfd/elf32-s390.c,
29 * bfd/elf32-score.c, * bfd/elf32-score7.c, * bfd/elf32-sh.c,
30 * bfd/elf32-spu.c, * bfd/elf32-tic6x.c, * bfd/elf32-tilepro.c,
31 * bfd/elf32-v850.c, * bfd/elf32-vax.c, * bfd/elf32-xc16x.c,
32 * bfd/elf32-xstormy16.c, * bfd/elf32-xtensa.c, * bfd/elf64-alpha.c,
33 * bfd/elf64-hppa.c, * bfd/elf64-ia64-vms.c, * bfd/elf64-mmix.c,
34 * bfd/elf64-ppc.c, * bfd/elf64-s390.c, * bfd/elf64-sh64.c,
35 * bfd/elf64-x86-64.c, * bfd/elflink.c, * bfd/elfnn-ia64.c,
36 * bfd/elfxx-mips.c, * bfd/elfxx-sparc.c, * bfd/elfxx-tilegx.c,
37 * bfd/reloc.c: Update all references.
38 * bfd/bfd-in2.h: Regenerate.
39 ld/
40 * ld/ldlang.c (size_input_section): Use sec_info_type rather than
41 usrdata->flags.just_syms.
42 * ld/ldwrite.c (build_link_order): Likewise.
43 * ld/emultempl/hppaelf.em (build_section_lists): Likewise.
44 * ld/emultempl/ppc64elf.em (build_toc_list): Likewise.
45 * ld/emultempl/armelf.em (build_section_lists): Likewise.
46 (after_allocation): Update for renamed sec_info_type value.
47 * ld/emultempl/tic6xdsbt.em: Likewise.
48---
49 bfd/ChangeLog | 38 +++++++++++++++++++++++++++++++++
50 bfd/bfd-in.h | 6 +++---
51 bfd/bfd-in2.h | 16 +++++++-------
52 bfd/elf-bfd.h | 3 +--
53 bfd/elf-eh-frame.c | 10 ++++-----
54 bfd/elf-m10200.c | 2 +-
55 bfd/elf-m10300.c | 4 ++--
56 bfd/elf.c | 10 ++++-----
57 bfd/elf32-arm.c | 6 +++---
58 bfd/elf32-avr.c | 2 +-
59 bfd/elf32-bfin.c | 6 +++---
60 bfd/elf32-cr16.c | 2 +-
61 bfd/elf32-cr16c.c | 2 +-
62 bfd/elf32-cris.c | 2 +-
63 bfd/elf32-crx.c | 2 +-
64 bfd/elf32-d10v.c | 2 +-
65 bfd/elf32-fr30.c | 2 +-
66 bfd/elf32-frv.c | 4 ++--
67 bfd/elf32-h8300.c | 2 +-
68 bfd/elf32-hppa.c | 2 +-
69 bfd/elf32-i370.c | 2 +-
70 bfd/elf32-i386.c | 4 ++--
71 bfd/elf32-i860.c | 2 +-
72 bfd/elf32-ip2k.c | 2 +-
73 bfd/elf32-iq2000.c | 2 +-
74 bfd/elf32-lm32.c | 6 +++---
75 bfd/elf32-m32c.c | 2 +-
76 bfd/elf32-m32r.c | 2 +-
77 bfd/elf32-m68hc1x.c | 2 +-
78 bfd/elf32-m68k.c | 2 +-
79 bfd/elf32-mcore.c | 2 +-
80 bfd/elf32-mep.c | 2 +-
81 bfd/elf32-moxie.c | 2 +-
82 bfd/elf32-msp430.c | 2 +-
83 bfd/elf32-mt.c | 2 +-
84 bfd/elf32-openrisc.c | 2 +-
85 bfd/elf32-ppc.c | 6 +++---
86 bfd/elf32-rx.c | 4 ++--
87 bfd/elf32-s390.c | 2 +-
88 bfd/elf32-score.c | 2 +-
89 bfd/elf32-score7.c | 2 +-
90 bfd/elf32-sh.c | 4 ++--
91 bfd/elf32-spu.c | 2 +-
92 bfd/elf32-tic6x.c | 2 +-
93 bfd/elf32-tilepro.c | 2 +-
94 bfd/elf32-v850.c | 2 +-
95 bfd/elf32-vax.c | 2 +-
96 bfd/elf32-xc16x.c | 2 +-
97 bfd/elf32-xstormy16.c | 2 +-
98 bfd/elf32-xtensa.c | 8 +++----
99 bfd/elf64-alpha.c | 8 +++----
100 bfd/elf64-hppa.c | 2 +-
101 bfd/elf64-mmix.c | 2 +-
102 bfd/elf64-ppc.c | 20 +++++++++---------
103 bfd/elf64-s390.c | 2 +-
104 bfd/elf64-sh64.c | 4 ++--
105 bfd/elf64-x86-64.c | 4 ++--
106 bfd/elflink.c | 51 ++++++++++++++++++---------------------------
107 bfd/elfnn-ia64.c | 6 +++---
108 bfd/elfxx-mips.c | 2 +-
109 bfd/elfxx-sparc.c | 2 +-
110 bfd/elfxx-tilegx.c | 2 +-
111 bfd/linker.c | 3 ++-
112 bfd/reloc.c | 2 +-
113 bfd/section.c | 10 ++++-----
114 ld/ChangeLog | 15 +++++++++++++
115 ld/emultempl/armelf.em | 4 ++--
116 ld/emultempl/hppaelf.em | 2 +-
117 ld/emultempl/ppc64elf.em | 4 ++--
118 ld/emultempl/tic6xdsbt.em | 2 +-
119 ld/ldlang.c | 2 +-
120 ld/ldwrite.c | 4 ++--
121 72 files changed, 199 insertions(+), 157 deletions(-)
122
123diff --git a/bfd/bfd-in.h b/bfd/bfd-in.h
124index a477b49..7c5298a 100644
125--- a/bfd/bfd-in.h
126+++ b/bfd/bfd-in.h
127@@ -295,11 +295,11 @@ typedef struct bfd_section *sec_ptr;
128 ? (sec)->rawsize : (sec)->size) / bfd_octets_per_byte (bfd))
129
130 /* Return TRUE if input section SEC has been discarded. */
131-#define elf_discarded_section(sec) \
132+#define discarded_section(sec) \
133 (!bfd_is_abs_section (sec) \
134 && bfd_is_abs_section ((sec)->output_section) \
135- && (sec)->sec_info_type != ELF_INFO_TYPE_MERGE \
136- && (sec)->sec_info_type != ELF_INFO_TYPE_JUST_SYMS)
137+ && (sec)->sec_info_type != SEC_INFO_TYPE_MERGE \
138+ && (sec)->sec_info_type != SEC_INFO_TYPE_JUST_SYMS)
139
140 /* Forward define. */
141 struct stat;
142diff --git a/bfd/bfd-in2.h b/bfd/bfd-in2.h
143index cd90740..34f9628 100644
144--- a/bfd/bfd-in2.h
145+++ b/bfd/bfd-in2.h
146@@ -302,11 +302,11 @@ typedef struct bfd_section *sec_ptr;
147 ? (sec)->rawsize : (sec)->size) / bfd_octets_per_byte (bfd))
148
149 /* Return TRUE if input section SEC has been discarded. */
150-#define elf_discarded_section(sec) \
151+#define discarded_section(sec) \
152 (!bfd_is_abs_section (sec) \
153 && bfd_is_abs_section ((sec)->output_section) \
154- && (sec)->sec_info_type != ELF_INFO_TYPE_MERGE \
155- && (sec)->sec_info_type != ELF_INFO_TYPE_JUST_SYMS)
156+ && (sec)->sec_info_type != SEC_INFO_TYPE_MERGE \
157+ && (sec)->sec_info_type != SEC_INFO_TYPE_JUST_SYMS)
158
159 /* Forward define. */
160 struct stat;
161@@ -1384,11 +1384,11 @@ typedef struct bfd_section
162
163 /* Type of sec_info information. */
164 unsigned int sec_info_type:3;
165-#define ELF_INFO_TYPE_NONE 0
166-#define ELF_INFO_TYPE_STABS 1
167-#define ELF_INFO_TYPE_MERGE 2
168-#define ELF_INFO_TYPE_EH_FRAME 3
169-#define ELF_INFO_TYPE_JUST_SYMS 4
170+#define SEC_INFO_TYPE_NONE 0
171+#define SEC_INFO_TYPE_STABS 1
172+#define SEC_INFO_TYPE_MERGE 2
173+#define SEC_INFO_TYPE_EH_FRAME 3
174+#define SEC_INFO_TYPE_JUST_SYMS 4
175
176 /* Nonzero if this section uses RELA relocations, rather than REL. */
177 unsigned int use_rela_p:1;
178diff --git a/bfd/elf-bfd.h b/bfd/elf-bfd.h
179index d6e2ab2..2cfe2ba 100644
180--- a/bfd/elf-bfd.h
181+++ b/bfd/elf-bfd.h
182@@ -1807,8 +1807,7 @@ extern void bfd_elf_set_group_contents
183 (bfd *, asection *, void *);
184 extern asection *_bfd_elf_check_kept_section
185 (asection *, struct bfd_link_info *);
186-extern void _bfd_elf_link_just_syms
187- (asection *, struct bfd_link_info *);
188+#define _bfd_elf_link_just_syms _bfd_generic_link_just_syms
189 extern void _bfd_elf_copy_link_hash_symbol_type
190 (bfd *, struct bfd_link_hash_entry *, struct bfd_link_hash_entry *);
191 extern bfd_boolean _bfd_elf_size_group_sections
192diff --git a/bfd/elf-eh-frame.c b/bfd/elf-eh-frame.c
193index 54142b2..7b5cf7a 100644
194--- a/bfd/elf-eh-frame.c
195+++ b/bfd/elf-eh-frame.c
196@@ -491,7 +491,7 @@ _bfd_elf_parse_eh_frame (bfd *abfd, struct bfd_link_info *info,
197 return;
198
199 if (sec->size == 0
200- || sec->sec_info_type != ELF_INFO_TYPE_NONE)
201+ || sec->sec_info_type != SEC_INFO_TYPE_NONE)
202 {
203 /* This file does not contain .eh_frame information. */
204 return;
205@@ -904,7 +904,7 @@ _bfd_elf_parse_eh_frame (bfd *abfd, struct bfd_link_info *info,
206 BFD_ASSERT (cie_count == num_cies);
207
208 elf_section_data (sec)->sec_info = sec_info;
209- sec->sec_info_type = ELF_INFO_TYPE_EH_FRAME;
210+ sec->sec_info_type = SEC_INFO_TYPE_EH_FRAME;
211 if (hdr_info->merge_cies)
212 {
213 sec_info->cies = local_cies;
214@@ -1137,7 +1137,7 @@ _bfd_elf_discard_section_eh_frame
215 struct eh_frame_hdr_info *hdr_info;
216 unsigned int ptr_size, offset;
217
218- if (sec->sec_info_type != ELF_INFO_TYPE_EH_FRAME)
219+ if (sec->sec_info_type != SEC_INFO_TYPE_EH_FRAME)
220 return FALSE;
221
222 sec_info = (struct eh_frame_sec_info *) elf_section_data (sec)->sec_info;
223@@ -1307,7 +1307,7 @@ _bfd_elf_eh_frame_section_offset (bfd *output_bfd ATTRIBUTE_UNUSED,
224 struct eh_frame_sec_info *sec_info;
225 unsigned int lo, hi, mid;
226
227- if (sec->sec_info_type != ELF_INFO_TYPE_EH_FRAME)
228+ if (sec->sec_info_type != SEC_INFO_TYPE_EH_FRAME)
229 return offset;
230 sec_info = (struct eh_frame_sec_info *) elf_section_data (sec)->sec_info;
231
232@@ -1395,7 +1395,7 @@ _bfd_elf_write_section_eh_frame (bfd *abfd,
233 unsigned int ptr_size;
234 struct eh_cie_fde *ent;
235
236- if (sec->sec_info_type != ELF_INFO_TYPE_EH_FRAME)
237+ if (sec->sec_info_type != SEC_INFO_TYPE_EH_FRAME)
238 /* FIXME: octets_per_byte. */
239 return bfd_set_section_contents (abfd, sec->output_section, contents,
240 sec->output_offset, sec->size);
241diff --git a/bfd/elf-m10200.c b/bfd/elf-m10200.c
242index a38f4db..d58c75c 100644
243--- a/bfd/elf-m10200.c
244+++ b/bfd/elf-m10200.c
245@@ -401,7 +401,7 @@ mn10200_elf_relocate_section (output_bfd, info, input_bfd, input_section,
246 unresolved_reloc, warned);
247 }
248
249- if (sec != NULL && elf_discarded_section (sec))
250+ if (sec != NULL && discarded_section (sec))
251 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
252 rel, relend, howto, contents);
253
254diff --git a/bfd/elf-m10300.c b/bfd/elf-m10300.c
255index 8276a2f..876ff4a 100644
256--- a/bfd/elf-m10300.c
257+++ b/bfd/elf-m10300.c
258@@ -1509,7 +1509,7 @@ mn10300_elf_relocate_section (bfd *output_bfd,
259 h->root.root.root.string);
260 }
261
262- if (sec != NULL && elf_discarded_section (sec))
263+ if (sec != NULL && discarded_section (sec))
264 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
265 rel, relend, howto, contents);
266
267@@ -2763,7 +2763,7 @@ mn10300_elf_relax_section (bfd *abfd,
268 isym->st_name);
269
270 if ((sym_sec->flags & SEC_MERGE)
271- && sym_sec->sec_info_type == ELF_INFO_TYPE_MERGE)
272+ && sym_sec->sec_info_type == SEC_INFO_TYPE_MERGE)
273 {
274 symval = isym->st_value;
275
276diff --git a/bfd/elf.c b/bfd/elf.c
277index aa40c33..9e23bee 100644
278--- a/bfd/elf.c
279+++ b/bfd/elf.c
280@@ -3071,7 +3071,7 @@ assign_section_numbers (bfd *abfd, struct bfd_link_info *link_info)
281 if (link_info != NULL)
282 {
283 /* Check discarded linkonce section. */
284- if (elf_discarded_section (s))
285+ if (discarded_section (s))
286 {
287 asection *kept;
288 (*_bfd_error_handler)
289@@ -9390,7 +9390,7 @@ _bfd_elf_rela_local_sym (bfd *abfd,
290 + sym->st_value);
291 if ((sec->flags & SEC_MERGE)
292 && ELF_ST_TYPE (sym->st_info) == STT_SECTION
293- && sec->sec_info_type == ELF_INFO_TYPE_MERGE)
294+ && sec->sec_info_type == SEC_INFO_TYPE_MERGE)
295 {
296 rel->r_addend =
297 _bfd_merged_section_offset (abfd, psec,
298@@ -9421,7 +9421,7 @@ _bfd_elf_rel_local_sym (bfd *abfd,
299 {
300 asection *sec = *psec;
301
302- if (sec->sec_info_type != ELF_INFO_TYPE_MERGE)
303+ if (sec->sec_info_type != SEC_INFO_TYPE_MERGE)
304 return sym->st_value + addend;
305
306 return _bfd_merged_section_offset (abfd, psec,
307@@ -9437,10 +9437,10 @@ _bfd_elf_section_offset (bfd *abfd,
308 {
309 switch (sec->sec_info_type)
310 {
311- case ELF_INFO_TYPE_STABS:
312+ case SEC_INFO_TYPE_STABS:
313 return _bfd_stab_section_offset (sec, elf_section_data (sec)->sec_info,
314 offset);
315- case ELF_INFO_TYPE_EH_FRAME:
316+ case SEC_INFO_TYPE_EH_FRAME:
317 return _bfd_elf_eh_frame_section_offset (abfd, info, sec, offset);
318 default:
319 if ((sec->flags & SEC_ELF_REVERSE_COPY) != 0)
320diff --git a/bfd/elf32-arm.c b/bfd/elf32-arm.c
321index 1f6c1a0..9355f66 100644
322--- a/bfd/elf32-arm.c
323+++ b/bfd/elf32-arm.c
324@@ -4485,7 +4485,7 @@ cortex_a8_erratum_scan (bfd *input_bfd,
325 if (elf_section_type (section) != SHT_PROGBITS
326 || (elf_section_flags (section) & SHF_EXECINSTR) == 0
327 || (section->flags & SEC_EXCLUDE) != 0
328- || (section->sec_info_type == ELF_INFO_TYPE_JUST_SYMS)
329+ || (section->sec_info_type == SEC_INFO_TYPE_JUST_SYMS)
330 || (section->output_section == bfd_abs_section_ptr))
331 continue;
332
333@@ -6556,7 +6556,7 @@ bfd_elf32_arm_vfp11_erratum_scan (bfd *abfd, struct bfd_link_info *link_info)
334 if (elf_section_type (sec) != SHT_PROGBITS
335 || (elf_section_flags (sec) & SHF_EXECINSTR) == 0
336 || (sec->flags & SEC_EXCLUDE) != 0
337- || sec->sec_info_type == ELF_INFO_TYPE_JUST_SYMS
338+ || sec->sec_info_type == SEC_INFO_TYPE_JUST_SYMS
339 || sec->output_section == bfd_abs_section_ptr
340 || strcmp (sec->name, VFP11_ERRATUM_VENEER_SECTION_NAME) == 0)
341 continue;
342@@ -10305,7 +10305,7 @@ elf32_arm_relocate_section (bfd * output_bfd,
343 sym_type = h->type;
344 }
345
346- if (sec != NULL && elf_discarded_section (sec))
347+ if (sec != NULL && discarded_section (sec))
348 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
349 rel, relend, howto, contents);
350
351diff --git a/bfd/elf32-avr.c b/bfd/elf32-avr.c
352index a7f9217..97dc268 100644
353--- a/bfd/elf32-avr.c
354+++ b/bfd/elf32-avr.c
355@@ -1189,7 +1189,7 @@ elf32_avr_relocate_section (bfd *output_bfd ATTRIBUTE_UNUSED,
356 name = h->root.root.string;
357 }
358
359- if (sec != NULL && elf_discarded_section (sec))
360+ if (sec != NULL && discarded_section (sec))
361 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
362 rel, relend, howto, contents);
363
364diff --git a/bfd/elf32-bfin.c b/bfd/elf32-bfin.c
365index b112dfc..4941f40 100644
366--- a/bfd/elf32-bfin.c
367+++ b/bfd/elf32-bfin.c
368@@ -1444,7 +1444,7 @@ bfin_relocate_section (bfd * output_bfd,
369 unresolved_reloc, warned);
370 }
371
372- if (sec != NULL && elf_discarded_section (sec))
373+ if (sec != NULL && discarded_section (sec))
374 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
375 rel, relend, howto, contents);
376
377@@ -2663,7 +2663,7 @@ bfinfdpic_relocate_section (bfd * output_bfd,
378 osec = sec;
379 }
380
381- if (sec != NULL && elf_discarded_section (sec))
382+ if (sec != NULL && discarded_section (sec))
383 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
384 rel, relend, howto, contents);
385
386@@ -4429,7 +4429,7 @@ bfinfdpic_elf_discard_info (bfd *ibfd,
387
388 /* Account for relaxation of .eh_frame section. */
389 for (s = ibfd->sections; s; s = s->next)
390- if (s->sec_info_type == ELF_INFO_TYPE_EH_FRAME)
391+ if (s->sec_info_type == SEC_INFO_TYPE_EH_FRAME)
392 {
393 if (!_bfinfdpic_check_discarded_relocs (ibfd, s, info, &changed))
394 return FALSE;
395diff --git a/bfd/elf32-cr16.c b/bfd/elf32-cr16.c
396index 0118131..38af05f 100644
397--- a/bfd/elf32-cr16.c
398+++ b/bfd/elf32-cr16.c
399@@ -1431,7 +1431,7 @@ elf32_cr16_relocate_section (bfd *output_bfd, struct bfd_link_info *info,
400 unresolved_reloc, warned);
401 }
402
403- if (sec != NULL && elf_discarded_section (sec))
404+ if (sec != NULL && discarded_section (sec))
405 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
406 rel, relend, howto, contents);
407
408diff --git a/bfd/elf32-cr16c.c b/bfd/elf32-cr16c.c
409index ca2d7cb..109936b 100644
410--- a/bfd/elf32-cr16c.c
411+++ b/bfd/elf32-cr16c.c
412@@ -723,7 +723,7 @@ elf32_cr16c_relocate_section (bfd *output_bfd,
413 unresolved_reloc, warned);
414 }
415
416- if (sec != NULL && elf_discarded_section (sec))
417+ if (sec != NULL && discarded_section (sec))
418 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
419 rel, relend, howto, contents);
420
421diff --git a/bfd/elf32-cris.c b/bfd/elf32-cris.c
422index 310f6d1..ec23f03 100644
423--- a/bfd/elf32-cris.c
424+++ b/bfd/elf32-cris.c
425@@ -1180,7 +1180,7 @@ cris_elf_relocate_section (bfd *output_bfd ATTRIBUTE_UNUSED,
426 }
427 }
428
429- if (sec != NULL && elf_discarded_section (sec))
430+ if (sec != NULL && discarded_section (sec))
431 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
432 rel, relend, howto, contents);
433
434diff --git a/bfd/elf32-crx.c b/bfd/elf32-crx.c
435index d48932d..fd13447 100644
436--- a/bfd/elf32-crx.c
437+++ b/bfd/elf32-crx.c
438@@ -873,7 +873,7 @@ elf32_crx_relocate_section (bfd *output_bfd, struct bfd_link_info *info,
439 unresolved_reloc, warned);
440 }
441
442- if (sec != NULL && elf_discarded_section (sec))
443+ if (sec != NULL && discarded_section (sec))
444 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
445 rel, relend, howto, contents);
446
447diff --git a/bfd/elf32-d10v.c b/bfd/elf32-d10v.c
448index 7d65395..e39a9b5 100644
449--- a/bfd/elf32-d10v.c
450+++ b/bfd/elf32-d10v.c
451@@ -463,7 +463,7 @@ elf32_d10v_relocate_section (bfd *output_bfd,
452 unresolved_reloc, warned);
453 }
454
455- if (sec != NULL && elf_discarded_section (sec))
456+ if (sec != NULL && discarded_section (sec))
457 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
458 rel, relend, howto, contents);
459
460diff --git a/bfd/elf32-fr30.c b/bfd/elf32-fr30.c
461index 97b0d29..57be6ae 100644
462--- a/bfd/elf32-fr30.c
463+++ b/bfd/elf32-fr30.c
464@@ -577,7 +577,7 @@ fr30_elf_relocate_section (output_bfd, info, input_bfd, input_section,
465 name = h->root.root.string;
466 }
467
468- if (sec != NULL && elf_discarded_section (sec))
469+ if (sec != NULL && discarded_section (sec))
470 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
471 rel, relend, howto, contents);
472
473diff --git a/bfd/elf32-frv.c b/bfd/elf32-frv.c
474index 7f3c4dd..513f811 100644
475--- a/bfd/elf32-frv.c
476+++ b/bfd/elf32-frv.c
477@@ -2812,7 +2812,7 @@ elf32_frv_relocate_section (output_bfd, info, input_bfd, input_section,
478 name = h->root.root.string;
479 }
480
481- if (sec != NULL && elf_discarded_section (sec))
482+ if (sec != NULL && discarded_section (sec))
483 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
484 rel, relend, howto, contents);
485
486@@ -5678,7 +5678,7 @@ frvfdpic_elf_discard_info (bfd *ibfd,
487
488 /* Account for relaxation of .eh_frame section. */
489 for (s = ibfd->sections; s; s = s->next)
490- if (s->sec_info_type == ELF_INFO_TYPE_EH_FRAME)
491+ if (s->sec_info_type == SEC_INFO_TYPE_EH_FRAME)
492 {
493 if (!_frvfdpic_check_discarded_relocs (ibfd, s, info, &changed))
494 return FALSE;
495diff --git a/bfd/elf32-h8300.c b/bfd/elf32-h8300.c
496index 95d3983..ff1ee70 100644
497--- a/bfd/elf32-h8300.c
498+++ b/bfd/elf32-h8300.c
499@@ -460,7 +460,7 @@ elf32_h8_relocate_section (bfd *output_bfd, struct bfd_link_info *info,
500 unresolved_reloc, warned);
501 }
502
503- if (sec != NULL && elf_discarded_section (sec))
504+ if (sec != NULL && discarded_section (sec))
505 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
506 rel, relend, howto, contents);
507
508diff --git a/bfd/elf32-hppa.c b/bfd/elf32-hppa.c
509index dcf6df0..044b6fa 100644
510--- a/bfd/elf32-hppa.c
511+++ b/bfd/elf32-hppa.c
512@@ -3741,7 +3741,7 @@ elf32_hppa_relocate_section (bfd *output_bfd,
513 hh = hppa_elf_hash_entry (eh);
514 }
515
516- if (sym_sec != NULL && elf_discarded_section (sym_sec))
517+ if (sym_sec != NULL && discarded_section (sym_sec))
518 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
519 rela, relend,
520 elf_hppa_howto_table + r_type,
521diff --git a/bfd/elf32-i370.c b/bfd/elf32-i370.c
522index 8082927..516511f 100644
523--- a/bfd/elf32-i370.c
524+++ b/bfd/elf32-i370.c
525@@ -1138,7 +1138,7 @@ i370_elf_relocate_section (bfd *output_bfd,
526 }
527 }
528
529- if (sec != NULL && elf_discarded_section (sec))
530+ if (sec != NULL && discarded_section (sec))
531 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
532 rel, relend, howto, contents);
533
534diff --git a/bfd/elf32-i386.c b/bfd/elf32-i386.c
535index d518d01..b925ca6 100644
536--- a/bfd/elf32-i386.c
537+++ b/bfd/elf32-i386.c
538@@ -3178,7 +3178,7 @@ elf_i386_relocate_section (bfd *output_bfd,
539 unresolved_reloc, warned);
540 }
541
542- if (sec != NULL && elf_discarded_section (sec))
543+ if (sec != NULL && discarded_section (sec))
544 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
545 rel, relend, howto, contents);
546
547@@ -4846,7 +4846,7 @@ elf_i386_finish_dynamic_sections (bfd *output_bfd,
548 + PLT_FDE_START_OFFSET);
549 }
550 if (htab->plt_eh_frame->sec_info_type
551- == ELF_INFO_TYPE_EH_FRAME)
552+ == SEC_INFO_TYPE_EH_FRAME)
553 {
554 if (! _bfd_elf_write_section_eh_frame (output_bfd, info,
555 htab->plt_eh_frame,
556diff --git a/bfd/elf32-i860.c b/bfd/elf32-i860.c
557index 00c8ca7..88f4265 100644
558--- a/bfd/elf32-i860.c
559+++ b/bfd/elf32-i860.c
560@@ -1128,7 +1128,7 @@ elf32_i860_relocate_section (bfd *output_bfd ATTRIBUTE_UNUSED,
561 unresolved_reloc, warned);
562 }
563
564- if (sec != NULL && elf_discarded_section (sec))
565+ if (sec != NULL && discarded_section (sec))
566 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
567 rel, relend, howto, contents);
568
569diff --git a/bfd/elf32-ip2k.c b/bfd/elf32-ip2k.c
570index 0a251b8..43c7b1c 100644
571--- a/bfd/elf32-ip2k.c
572+++ b/bfd/elf32-ip2k.c
573@@ -1436,7 +1436,7 @@ ip2k_elf_relocate_section (bfd *output_bfd ATTRIBUTE_UNUSED,
574 name = h->root.root.string;
575 }
576
577- if (sec != NULL && elf_discarded_section (sec))
578+ if (sec != NULL && discarded_section (sec))
579 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
580 rel, relend, howto, contents);
581
582diff --git a/bfd/elf32-iq2000.c b/bfd/elf32-iq2000.c
583index 63ef3dc..3954616 100644
584--- a/bfd/elf32-iq2000.c
585+++ b/bfd/elf32-iq2000.c
586@@ -633,7 +633,7 @@ iq2000_elf_relocate_section (bfd * output_bfd ATTRIBUTE_UNUSED,
587 name = h->root.root.string;
588 }
589
590- if (sec != NULL && elf_discarded_section (sec))
591+ if (sec != NULL && discarded_section (sec))
592 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
593 rel, relend, howto, contents);
594
595diff --git a/bfd/elf32-lm32.c b/bfd/elf32-lm32.c
596index 07add20..a2b1003 100644
597--- a/bfd/elf32-lm32.c
598+++ b/bfd/elf32-lm32.c
599@@ -893,7 +893,7 @@ lm32_elf_relocate_section (bfd *output_bfd,
600 name = h->root.root.string;
601 }
602
603- if (sec != NULL && elf_discarded_section (sec))
604+ if (sec != NULL && discarded_section (sec))
605 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
606 rel, relend, howto, contents);
607
608@@ -2372,7 +2372,7 @@ lm32_elf_size_dynamic_sections (bfd *output_bfd,
609 /* Don't generate entries for weak symbols. */
610 if (!h || (h && h->root.type != bfd_link_hash_undefweak))
611 {
612- if (!elf_discarded_section (s) && !((bfd_get_section_flags (ibfd, s) & SEC_ALLOC) == 0))
613+ if (!discarded_section (s) && !((bfd_get_section_flags (ibfd, s) & SEC_ALLOC) == 0))
614 {
615 switch (ELF32_R_TYPE (internal_relocs->r_info))
616 {
617@@ -2394,7 +2394,7 @@ lm32_elf_size_dynamic_sections (bfd *output_bfd,
618 if (!strcmp (current->name, h->root.root.string))
619 break;
620 }
621- if (!current && !elf_discarded_section (s) && (bfd_get_section_flags (ibfd, s) & SEC_ALLOC))
622+ if (!current && !discarded_section (s) && (bfd_get_section_flags (ibfd, s) & SEC_ALLOC))
623 {
624 /* Will this have an entry in the GOT. */
625 if (ELF32_R_TYPE (internal_relocs->r_info) == R_LM32_16_GOT)
626diff --git a/bfd/elf32-m32c.c b/bfd/elf32-m32c.c
627index cf7ad99..bcdb55d 100644
628--- a/bfd/elf32-m32c.c
629+++ b/bfd/elf32-m32c.c
630@@ -434,7 +434,7 @@ m32c_elf_relocate_section
631 }
632 }
633
634- if (sec != NULL && elf_discarded_section (sec))
635+ if (sec != NULL && discarded_section (sec))
636 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
637 rel, relend, howto, contents);
638
639diff --git a/bfd/elf32-m32r.c b/bfd/elf32-m32r.c
640index 51ef61e..b151a8a 100644
641--- a/bfd/elf32-m32r.c
642+++ b/bfd/elf32-m32r.c
643@@ -2616,7 +2616,7 @@ m32r_elf_relocate_section (bfd *output_bfd ATTRIBUTE_UNUSED,
644 }
645 }
646
647- if (sec != NULL && elf_discarded_section (sec))
648+ if (sec != NULL && discarded_section (sec))
649 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
650 rel, relend, howto, contents);
651
652diff --git a/bfd/elf32-m68hc1x.c b/bfd/elf32-m68hc1x.c
653index 961dce4..4b9a1c0 100644
654--- a/bfd/elf32-m68hc1x.c
655+++ b/bfd/elf32-m68hc1x.c
656@@ -970,7 +970,7 @@ elf32_m68hc11_relocate_section (bfd *output_bfd ATTRIBUTE_UNUSED,
657 is_far = (h && (h->other & STO_M68HC12_FAR));
658 }
659
660- if (sec != NULL && elf_discarded_section (sec))
661+ if (sec != NULL && discarded_section (sec))
662 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
663 rel, relend, howto, contents);
664
665diff --git a/bfd/elf32-m68k.c b/bfd/elf32-m68k.c
666index 3e9ada9..518a41a 100644
667--- a/bfd/elf32-m68k.c
668+++ b/bfd/elf32-m68k.c
669@@ -3717,7 +3717,7 @@ elf_m68k_relocate_section (output_bfd, info, input_bfd, input_section,
670 unresolved_reloc, warned);
671 }
672
673- if (sec != NULL && elf_discarded_section (sec))
674+ if (sec != NULL && discarded_section (sec))
675 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
676 rel, relend, howto, contents);
677
678diff --git a/bfd/elf32-mcore.c b/bfd/elf32-mcore.c
679index 31cc095..02aef53 100644
680--- a/bfd/elf32-mcore.c
681+++ b/bfd/elf32-mcore.c
682@@ -466,7 +466,7 @@ mcore_elf_relocate_section (bfd * output_bfd,
683 unresolved_reloc, warned);
684 }
685
686- if (sec != NULL && elf_discarded_section (sec))
687+ if (sec != NULL && discarded_section (sec))
688 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
689 rel, relend, howto, contents);
690
691diff --git a/bfd/elf32-mep.c b/bfd/elf32-mep.c
692index 6fecb25..e5104b3 100644
693--- a/bfd/elf32-mep.c
694+++ b/bfd/elf32-mep.c
695@@ -500,7 +500,7 @@ mep_elf_relocate_section
696 name = h->root.root.string;
697 }
698
699- if (sec != NULL && elf_discarded_section (sec))
700+ if (sec != NULL && discarded_section (sec))
701 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
702 rel, relend, howto, contents);
703
704diff --git a/bfd/elf32-moxie.c b/bfd/elf32-moxie.c
705index 8463599..c340826 100644
706--- a/bfd/elf32-moxie.c
707+++ b/bfd/elf32-moxie.c
708@@ -250,7 +250,7 @@ moxie_elf_relocate_section (bfd *output_bfd,
709 name = h->root.root.string;
710 }
711
712- if (sec != NULL && elf_discarded_section (sec))
713+ if (sec != NULL && discarded_section (sec))
714 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
715 rel, relend, howto, contents);
716
717diff --git a/bfd/elf32-msp430.c b/bfd/elf32-msp430.c
718index 9a5fb2a..2fa70d9 100644
719--- a/bfd/elf32-msp430.c
720+++ b/bfd/elf32-msp430.c
721@@ -454,7 +454,7 @@ elf32_msp430_relocate_section (bfd * output_bfd ATTRIBUTE_UNUSED,
722 unresolved_reloc, warned);
723 }
724
725- if (sec != NULL && elf_discarded_section (sec))
726+ if (sec != NULL && discarded_section (sec))
727 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
728 rel, relend, howto, contents);
729
730diff --git a/bfd/elf32-mt.c b/bfd/elf32-mt.c
731index 1be5d00..b87995e 100644
732--- a/bfd/elf32-mt.c
733+++ b/bfd/elf32-mt.c
734@@ -354,7 +354,7 @@ mt_elf_relocate_section
735 name = h->root.root.string;
736 }
737
738- if (sec != NULL && elf_discarded_section (sec))
739+ if (sec != NULL && discarded_section (sec))
740 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
741 rel, relend, howto, contents);
742
743diff --git a/bfd/elf32-openrisc.c b/bfd/elf32-openrisc.c
744index ada738e..e441f4d 100644
745--- a/bfd/elf32-openrisc.c
746+++ b/bfd/elf32-openrisc.c
747@@ -373,7 +373,7 @@ openrisc_elf_relocate_section (bfd *output_bfd,
748 unresolved_reloc, warned);
749 }
750
751- if (sec != NULL && elf_discarded_section (sec))
752+ if (sec != NULL && discarded_section (sec))
753 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
754 rel, relend, howto, contents);
755
756diff --git a/bfd/elf32-ppc.c b/bfd/elf32-ppc.c
757index 574cd98..d3925af 100644
758--- a/bfd/elf32-ppc.c
759+++ b/bfd/elf32-ppc.c
760@@ -6231,7 +6231,7 @@ ppc_elf_relax_section (bfd *abfd,
761 attribute for a code section, and we are only looking at
762 branches. However, implement it correctly here as a
763 reference for other target relax_section functions. */
764- if (0 && tsec->sec_info_type == ELF_INFO_TYPE_MERGE)
765+ if (0 && tsec->sec_info_type == SEC_INFO_TYPE_MERGE)
766 {
767 /* At this stage in linking, no SEC_MERGE symbol has been
768 adjusted, so all references to such symbols need to be
769@@ -6886,7 +6886,7 @@ ppc_elf_relocate_section (bfd *output_bfd,
770 sym_name = h->root.root.string;
771 }
772
773- if (sec != NULL && elf_discarded_section (sec))
774+ if (sec != NULL && discarded_section (sec))
775 {
776 /* For relocs against symbols from removed linkonce sections,
777 or sections discarded by a linker script, we just want the
778@@ -9054,7 +9054,7 @@ ppc_elf_finish_dynamic_sections (bfd *output_bfd,
779 BFD_ASSERT ((bfd_vma) ((p + 3 - htab->glink_eh_frame->contents) & -4)
780 == htab->glink_eh_frame->size);
781
782- if (htab->glink_eh_frame->sec_info_type == ELF_INFO_TYPE_EH_FRAME
783+ if (htab->glink_eh_frame->sec_info_type == SEC_INFO_TYPE_EH_FRAME
784 && !_bfd_elf_write_section_eh_frame (output_bfd, info,
785 htab->glink_eh_frame,
786 htab->glink_eh_frame->contents))
787diff --git a/bfd/elf32-rx.c b/bfd/elf32-rx.c
788index f049f6e..32820b4 100644
789--- a/bfd/elf32-rx.c
790+++ b/bfd/elf32-rx.c
791@@ -510,7 +510,7 @@ rx_elf_relocate_section
792 name = h->root.root.string;
793 }
794
795- if (sec != NULL && elf_discarded_section (sec))
796+ if (sec != NULL && discarded_section (sec))
797 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
798 rel, relend, howto, contents);
799
800@@ -1588,7 +1588,7 @@ rx_offset_for_reloc (bfd * abfd,
801 if (ssec)
802 {
803 if ((ssec->flags & SEC_MERGE)
804- && ssec->sec_info_type == ELF_INFO_TYPE_MERGE)
805+ && ssec->sec_info_type == SEC_INFO_TYPE_MERGE)
806 symval = _bfd_merged_section_offset (abfd, & ssec,
807 elf_section_data (ssec)->sec_info,
808 symval);
809diff --git a/bfd/elf32-s390.c b/bfd/elf32-s390.c
810index 98437d0..11fb072 100644
811--- a/bfd/elf32-s390.c
812+++ b/bfd/elf32-s390.c
813@@ -2282,7 +2282,7 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
814 unresolved_reloc, warned);
815 }
816
817- if (sec != NULL && elf_discarded_section (sec))
818+ if (sec != NULL && discarded_section (sec))
819 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
820 rel, relend, howto, contents);
821
822diff --git a/bfd/elf32-score.c b/bfd/elf32-score.c
823index b437624..ef849aa 100644
824--- a/bfd/elf32-score.c
825+++ b/bfd/elf32-score.c
826@@ -2672,7 +2672,7 @@ s3_bfd_score_elf_relocate_section (bfd *output_bfd,
827 }
828 }
829
830- if (sec != NULL && elf_discarded_section (sec))
831+ if (sec != NULL && discarded_section (sec))
832 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
833 rel, relend, howto, contents);
834
835diff --git a/bfd/elf32-score7.c b/bfd/elf32-score7.c
836index 3e98bfc..3d228f3 100644
837--- a/bfd/elf32-score7.c
838+++ b/bfd/elf32-score7.c
839@@ -2443,7 +2443,7 @@ s7_bfd_score_elf_relocate_section (bfd *output_bfd,
840 }
841 }
842
843- if (sec != NULL && elf_discarded_section (sec))
844+ if (sec != NULL && discarded_section (sec))
845 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
846 rel, relend, howto, contents);
847
848diff --git a/bfd/elf32-sh.c b/bfd/elf32-sh.c
849index ca2c4af..e56c3b5 100644
850--- a/bfd/elf32-sh.c
851+++ b/bfd/elf32-sh.c
852@@ -4048,7 +4048,7 @@ sh_elf_relocate_section (bfd *output_bfd, struct bfd_link_info *info,
853 _("Unexpected STO_SH5_ISA32 on local symbol is not handled"),
854 input_bfd, input_section, rel->r_offset));
855
856- if (sec != NULL && elf_discarded_section (sec))
857+ if (sec != NULL && discarded_section (sec))
858 /* Handled below. */
859 ;
860 else if (info->relocatable)
861@@ -4236,7 +4236,7 @@ sh_elf_relocate_section (bfd *output_bfd, struct bfd_link_info *info,
862 }
863 }
864
865- if (sec != NULL && elf_discarded_section (sec))
866+ if (sec != NULL && discarded_section (sec))
867 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
868 rel, relend, howto, contents);
869
870diff --git a/bfd/elf32-spu.c b/bfd/elf32-spu.c
871index ae3ed10..40a9da2 100644
872--- a/bfd/elf32-spu.c
873+++ b/bfd/elf32-spu.c
874@@ -4895,7 +4895,7 @@ spu_elf_relocate_section (bfd *output_bfd,
875 sym_name = h->root.root.string;
876 }
877
878- if (sec != NULL && elf_discarded_section (sec))
879+ if (sec != NULL && discarded_section (sec))
880 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
881 rel, relend, howto, contents);
882
883diff --git a/bfd/elf32-tic6x.c b/bfd/elf32-tic6x.c
884index 44042eb..a879d3c 100644
885--- a/bfd/elf32-tic6x.c
886+++ b/bfd/elf32-tic6x.c
887@@ -2334,7 +2334,7 @@ elf32_tic6x_relocate_section (bfd *output_bfd,
888 unresolved_reloc, warned);
889 }
890
891- if (sec != NULL && elf_discarded_section (sec))
892+ if (sec != NULL && discarded_section (sec))
893 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
894 rel, relend, howto, contents);
895
896diff --git a/bfd/elf32-tilepro.c b/bfd/elf32-tilepro.c
897index f2aed9c..a4e565d 100644
898--- a/bfd/elf32-tilepro.c
899+++ b/bfd/elf32-tilepro.c
900@@ -2594,7 +2594,7 @@ tilepro_elf_relocate_section (bfd *output_bfd, struct bfd_link_info *info,
901 }
902 }
903
904- if (sec != NULL && elf_discarded_section (sec))
905+ if (sec != NULL && discarded_section (sec))
906 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
907 rel, relend, howto, contents);
908
909diff --git a/bfd/elf32-v850.c b/bfd/elf32-v850.c
910index 9e6f77d..0fbe080 100644
911--- a/bfd/elf32-v850.c
912+++ b/bfd/elf32-v850.c
913@@ -2093,7 +2093,7 @@ v850_elf_relocate_section (bfd *output_bfd,
914 unresolved_reloc, warned);
915 }
916
917- if (sec != NULL && elf_discarded_section (sec))
918+ if (sec != NULL && discarded_section (sec))
919 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
920 rel, relend, howto, contents);
921
922diff --git a/bfd/elf32-vax.c b/bfd/elf32-vax.c
923index 643381c..fc3cb7c 100644
924--- a/bfd/elf32-vax.c
925+++ b/bfd/elf32-vax.c
926@@ -1450,7 +1450,7 @@ elf_vax_relocate_section (bfd *output_bfd,
927 relocation = 0;
928 }
929
930- if (sec != NULL && elf_discarded_section (sec))
931+ if (sec != NULL && discarded_section (sec))
932 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
933 rel, relend, howto, contents);
934
935diff --git a/bfd/elf32-xc16x.c b/bfd/elf32-xc16x.c
936index 11d9840..00c7841 100644
937--- a/bfd/elf32-xc16x.c
938+++ b/bfd/elf32-xc16x.c
939@@ -381,7 +381,7 @@ elf32_xc16x_relocate_section (bfd *output_bfd,
940 unresolved_reloc, warned);
941 }
942
943- if (sec != NULL && elf_discarded_section (sec))
944+ if (sec != NULL && discarded_section (sec))
945 {
946 /* For relocs against symbols from removed linkonce sections,
947 or sections discarded by a linker script, we just want the
948diff --git a/bfd/elf32-xstormy16.c b/bfd/elf32-xstormy16.c
949index 6141783..86e1d5b 100644
950--- a/bfd/elf32-xstormy16.c
951+++ b/bfd/elf32-xstormy16.c
952@@ -825,7 +825,7 @@ xstormy16_elf_relocate_section (bfd * output_bfd ATTRIBUTE_UNU
953 unresolved_reloc, warned);
954 }
955
956- if (sec != NULL && elf_discarded_section (sec))
957+ if (sec != NULL && discarded_section (sec))
958 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
959 rel, relend, howto, contents);
960
961diff --git a/bfd/elf32-xtensa.c b/bfd/elf32-xtensa.c
962index c6e4fb4..5a51eae 100644
963--- a/bfd/elf32-xtensa.c
964+++ b/bfd/elf32-xtensa.c
965@@ -1712,7 +1712,7 @@ elf_xtensa_size_dynamic_sections (bfd *output_bfd ATTRIBUTE_UNUSED,
966 continue;
967 for (s = abfd->sections; s != NULL; s = s->next)
968 {
969- if (! elf_discarded_section (s)
970+ if (! discarded_section (s)
971 && xtensa_is_littable_section (s)
972 && s != spltlittbl)
973 sgotloc->size += s->size;
974@@ -2656,7 +2656,7 @@ elf_xtensa_relocate_section (bfd *output_bfd,
975 sym_type = h->type;
976 }
977
978- if (sec != NULL && elf_discarded_section (sec))
979+ if (sec != NULL && discarded_section (sec))
980 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
981 rel, relend, howto, contents);
982
983@@ -8960,9 +8960,9 @@ relax_section (bfd *abfd, asection *sec, struct bfd_link_info *link_info)
984 that here and adjust things accordingly. */
985 if (! elf_xtensa_ignore_discarded_relocs (sec)
986 && elf_xtensa_action_discarded (sec) == PRETEND
987- && sec->sec_info_type != ELF_INFO_TYPE_STABS
988+ && sec->sec_info_type != SEC_INFO_TYPE_STABS
989 && target_sec != NULL
990- && elf_discarded_section (target_sec))
991+ && discarded_section (target_sec))
992 {
993 /* It would be natural to call _bfd_elf_check_kept_section
994 here, but it's not exported from elflink.c. It's also a
995diff --git a/bfd/elf64-alpha.c b/bfd/elf64-alpha.c
996index 6076709..ddb1cd7 100644
997--- a/bfd/elf64-alpha.c
998+++ b/bfd/elf64-alpha.c
999@@ -4106,7 +4106,7 @@ elf64_alpha_relocate_section_r (bfd *output_bfd ATTRIBUTE_UNUSED,
1000 sec = h->root.u.def.section;
1001 }
1002
1003- if (sec != NULL && elf_discarded_section (sec))
1004+ if (sec != NULL && discarded_section (sec))
1005 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
1006 rel, relend,
1007 elf64_alpha_howto_table + r_type,
1008@@ -4263,7 +4263,7 @@ elf64_alpha_relocate_section (bfd *output_bfd, struct bfd_link_info *info,
1009 unless it has been done already. */
1010 if ((sec->flags & SEC_MERGE)
1011 && ELF_ST_TYPE (sym->st_info) == STT_SECTION
1012- && sec->sec_info_type == ELF_INFO_TYPE_MERGE
1013+ && sec->sec_info_type == SEC_INFO_TYPE_MERGE
1014 && gotent
1015 && !gotent->reloc_xlated)
1016 {
1017@@ -4315,7 +4315,7 @@ elf64_alpha_relocate_section (bfd *output_bfd, struct bfd_link_info *info,
1018 gotent = h->got_entries;
1019 }
1020
1021- if (sec != NULL && elf_discarded_section (sec))
1022+ if (sec != NULL && discarded_section (sec))
1023 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
1024 rel, relend, howto, contents);
1025
1026@@ -4717,7 +4717,7 @@ elf64_alpha_relocate_section (bfd *output_bfd, struct bfd_link_info *info,
1027
1028 if (r_symndx < symtab_hdr->sh_info
1029 && sec != NULL && howto->pc_relative
1030- && elf_discarded_section (sec))
1031+ && discarded_section (sec))
1032 break;
1033
1034 if (h != NULL)
1035diff --git a/bfd/elf64-hppa.c b/bfd/elf64-hppa.c
1036index 057a92d..9d2dfcf 100644
1037--- a/bfd/elf64-hppa.c
1038+++ b/bfd/elf64-hppa.c
1039@@ -3919,7 +3919,7 @@ elf64_hppa_relocate_section (bfd *output_bfd,
1040 }
1041 }
1042
1043- if (sym_sec != NULL && elf_discarded_section (sym_sec))
1044+ if (sym_sec != NULL && discarded_section (sym_sec))
1045 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
1046 rel, relend, howto, contents);
1047
1048diff --git a/bfd/elf64-mmix.c b/bfd/elf64-mmix.c
1049index ecc9ad0..9cc407f 100644
1050--- a/bfd/elf64-mmix.c
1051+++ b/bfd/elf64-mmix.c
1052@@ -1475,7 +1475,7 @@ mmix_elf_relocate_section (output_bfd, info, input_bfd, input_section,
1053 name = h->root.root.string;
1054 }
1055
1056- if (sec != NULL && elf_discarded_section (sec))
1057+ if (sec != NULL && discarded_section (sec))
1058 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
1059 rel, relend, howto, contents);
1060
1061diff --git a/bfd/elf64-ppc.c b/bfd/elf64-ppc.c
1062index 32a3430..52e9ce9 100644
1063--- a/bfd/elf64-ppc.c
1064+++ b/bfd/elf64-ppc.c
1065@@ -6852,7 +6852,7 @@ adjust_opd_syms (struct elf_link_hash_entry *h, void *inf ATTRIBUTE_UNUSED)
1066 if (dsec == NULL)
1067 {
1068 for (dsec = sym_sec->owner->sections; dsec; dsec = dsec->next)
1069- if (elf_discarded_section (dsec))
1070+ if (discarded_section (dsec))
1071 {
1072 ppc64_elf_tdata (sym_sec->owner)->deleted_section = dsec;
1073 break;
1074@@ -7033,7 +7033,7 @@ ppc64_elf_edit_opd (struct bfd_link_info *info, bfd_boolean non_overlapping)
1075 if (sec == NULL || sec->size == 0)
1076 continue;
1077
1078- if (sec->sec_info_type == ELF_INFO_TYPE_JUST_SYMS)
1079+ if (sec->sec_info_type == SEC_INFO_TYPE_JUST_SYMS)
1080 continue;
1081
1082 if (sec->output_section == bfd_abs_section_ptr)
1083@@ -8077,8 +8077,8 @@ ppc64_elf_edit_toc (struct bfd_link_info *info)
1084 toc = bfd_get_section_by_name (ibfd, ".toc");
1085 if (toc == NULL
1086 || toc->size == 0
1087- || toc->sec_info_type == ELF_INFO_TYPE_JUST_SYMS
1088- || elf_discarded_section (toc))
1089+ || toc->sec_info_type == SEC_INFO_TYPE_JUST_SYMS
1090+ || discarded_section (toc))
1091 continue;
1092
1093 toc_relocs = NULL;
1094@@ -8091,7 +8091,7 @@ ppc64_elf_edit_toc (struct bfd_link_info *info)
1095 for (sec = ibfd->sections; sec != NULL; sec = sec->next)
1096 {
1097 if (sec->reloc_count == 0
1098- || !elf_discarded_section (sec)
1099+ || !discarded_section (sec)
1100 || get_opd_info (sec)
1101 || (sec->flags & SEC_ALLOC) == 0
1102 || (sec->flags & SEC_DEBUGGING) != 0)
1103@@ -8201,7 +8201,7 @@ ppc64_elf_edit_toc (struct bfd_link_info *info)
1104 goto error_ret;
1105
1106 if (sym_sec == NULL
1107- || elf_discarded_section (sym_sec))
1108+ || discarded_section (sym_sec))
1109 continue;
1110
1111 if (!SYMBOL_CALLS_LOCAL (info, h))
1112@@ -8281,7 +8281,7 @@ ppc64_elf_edit_toc (struct bfd_link_info *info)
1113 int repeat;
1114
1115 if (sec->reloc_count == 0
1116- || elf_discarded_section (sec)
1117+ || discarded_section (sec)
1118 || get_opd_info (sec)
1119 || (sec->flags & SEC_ALLOC) == 0
1120 || (sec->flags & SEC_DEBUGGING) != 0)
1121@@ -8503,7 +8503,7 @@ ppc64_elf_edit_toc (struct bfd_link_info *info)
1122 for (sec = ibfd->sections; sec != NULL; sec = sec->next)
1123 {
1124 if (sec->reloc_count == 0
1125- || elf_discarded_section (sec))
1126+ || discarded_section (sec))
1127 continue;
1128
1129 relstart = _bfd_elf_link_read_relocs (ibfd, sec, NULL, NULL,
1130@@ -12036,7 +12036,7 @@ ppc64_elf_relocate_section (bfd *output_bfd,
1131 }
1132 h = (struct ppc_link_hash_entry *) h_elf;
1133
1134- if (sec != NULL && elf_discarded_section (sec))
1135+ if (sec != NULL && discarded_section (sec))
1136 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
1137 rel, relend,
1138 ppc64_elf_howto_table[r_type],
1139@@ -13865,7 +13865,7 @@ ppc64_elf_finish_dynamic_sections (bfd *output_bfd,
1140
1141
1142 if (htab->glink_eh_frame != NULL
1143- && htab->glink_eh_frame->sec_info_type == ELF_INFO_TYPE_EH_FRAME
1144+ && htab->glink_eh_frame->sec_info_type == SEC_INFO_TYPE_EH_FRAME
1145 && !_bfd_elf_write_section_eh_frame (output_bfd, info,
1146 htab->glink_eh_frame,
1147 htab->glink_eh_frame->contents))
1148diff --git a/bfd/elf64-s390.c b/bfd/elf64-s390.c
1149index 9884da0..e9138a6 100644
1150--- a/bfd/elf64-s390.c
1151+++ b/bfd/elf64-s390.c
1152@@ -2270,7 +2270,7 @@ elf_s390_relocate_section (bfd *output_bfd,
1153 unresolved_reloc, warned);
1154 }
1155
1156- if (sec != NULL && elf_discarded_section (sec))
1157+ if (sec != NULL && discarded_section (sec))
1158 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
1159 rel, relend, howto, contents);
1160
1161diff --git a/bfd/elf64-sh64.c b/bfd/elf64-sh64.c
1162index bbef2a2..d8f2120 100644
1163--- a/bfd/elf64-sh64.c
1164+++ b/bfd/elf64-sh64.c
1165@@ -1514,7 +1514,7 @@ sh_elf64_relocate_section (bfd *output_bfd ATTRIBUTE_UNUSED,
1166 _("Unexpected STO_SH5_ISA32 on local symbol is not handled"),
1167 input_bfd, input_section, rel->r_offset));
1168
1169- if (sec != NULL && elf_discarded_section (sec))
1170+ if (sec != NULL && discarded_section (sec))
1171 /* Handled below. */
1172 ;
1173 else if (info->relocatable)
1174@@ -1657,7 +1657,7 @@ sh_elf64_relocate_section (bfd *output_bfd ATTRIBUTE_UNUSED,
1175 }
1176 }
1177
1178- if (sec != NULL && elf_discarded_section (sec))
1179+ if (sec != NULL && discarded_section (sec))
1180 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
1181 rel, relend, howto, contents);
1182
1183diff --git a/bfd/elf64-x86-64.c b/bfd/elf64-x86-64.c
1184index bdb3ae6..9d826e7 100644
1185--- a/bfd/elf64-x86-64.c
1186+++ b/bfd/elf64-x86-64.c
1187@@ -3062,7 +3062,7 @@ elf_x86_64_relocate_section (bfd *output_bfd,
1188 unresolved_reloc, warned);
1189 }
1190
1191- if (sec != NULL && elf_discarded_section (sec))
1192+ if (sec != NULL && discarded_section (sec))
1193 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
1194 rel, relend, howto, contents);
1195
1196@@ -4625,7 +4625,7 @@ elf_x86_64_finish_dynamic_sections (bfd *output_bfd,
1197 + PLT_FDE_START_OFFSET);
1198 }
1199 if (htab->plt_eh_frame->sec_info_type
1200- == ELF_INFO_TYPE_EH_FRAME)
1201+ == SEC_INFO_TYPE_EH_FRAME)
1202 {
1203 if (! _bfd_elf_write_section_eh_frame (output_bfd, info,
1204 htab->plt_eh_frame,
1205diff --git a/bfd/elflink.c b/bfd/elflink.c
1206index 8556cec..da6be48 100644
1207--- a/bfd/elflink.c
1208+++ b/bfd/elflink.c
1209@@ -1,6 +1,6 @@
1210 /* ELF linking support for BFD.
1211 Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
1212- 2005, 2006, 2007, 2008, 2009, 2010, 2011
1213+ 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012
1214 Free Software Foundation, Inc.
1215
1216 This file is part of BFD, the Binary File Descriptor library.
1217@@ -937,7 +937,7 @@ _bfd_elf_merge_symbol (bfd *abfd,
1218 /* Silently discard TLS symbols from --just-syms. There's no way to
1219 combine a static TLS block with a new TLS block for this executable. */
1220 if (ELF_ST_TYPE (sym->st_info) == STT_TLS
1221- && sec->sec_info_type == ELF_INFO_TYPE_JUST_SYMS)
1222+ && sec->sec_info_type == SEC_INFO_TYPE_JUST_SYMS)
1223 {
1224 *skip = TRUE;
1225 return TRUE;
1226@@ -2708,7 +2708,7 @@ _bfd_elf_link_sec_merge_syms (struct elf_link_hash_entry *h, void *data)
1227 if ((h->root.type == bfd_link_hash_defined
1228 || h->root.type == bfd_link_hash_defweak)
1229 && ((sec = h->root.u.def.section)->flags & SEC_MERGE)
1230- && sec->sec_info_type == ELF_INFO_TYPE_MERGE)
1231+ && sec->sec_info_type == SEC_INFO_TYPE_MERGE)
1232 {
1233 bfd *output_bfd = (bfd *) data;
1234
1235@@ -3499,7 +3499,7 @@ elf_link_add_object_symbols (bfd *abfd, struct bfd_link_info *info)
1236 /* ld --just-symbols and dynamic objects don't mix very well.
1237 ld shouldn't allow it. */
1238 if ((s = abfd->sections) != NULL
1239- && s->sec_info_type == ELF_INFO_TYPE_JUST_SYMS)
1240+ && s->sec_info_type == SEC_INFO_TYPE_JUST_SYMS)
1241 abort ();
1242
1243 /* If this dynamic lib was specified on the command line with
1244@@ -3896,7 +3896,7 @@ error_free_dyn:
1245 sec = bfd_section_from_elf_index (abfd, isym->st_shndx);
1246 if (sec == NULL)
1247 sec = bfd_abs_section_ptr;
1248- else if (elf_discarded_section (sec))
1249+ else if (discarded_section (sec))
1250 {
1251 /* Symbols from discarded section are undefined. We keep
1252 its visibility. */
1253@@ -4861,7 +4861,7 @@ error_free_dyn:
1254 &string_offset))
1255 goto error_return;
1256 if (secdata->sec_info)
1257- stab->sec_info_type = ELF_INFO_TYPE_STABS;
1258+ stab->sec_info_type = SEC_INFO_TYPE_STABS;
1259 }
1260 }
1261 }
1262@@ -6644,25 +6644,14 @@ bfd_elf_size_dynsym_hash_dynstr (bfd *output_bfd, struct bfd_link_info *info)
1263 return TRUE;
1264 }
1265
1266-/* Indicate that we are only retrieving symbol values from this
1267- section. */
1268-
1269-void
1270-_bfd_elf_link_just_syms (asection *sec, struct bfd_link_info *info)
1271-{
1272- if (is_elf_hash_table (info->hash))
1273- sec->sec_info_type = ELF_INFO_TYPE_JUST_SYMS;
1274- _bfd_generic_link_just_syms (sec, info);
1275-}
1276-
1277 /* Make sure sec_info_type is cleared if sec_info is cleared too. */
1278
1279 static void
1280 merge_sections_remove_hook (bfd *abfd ATTRIBUTE_UNUSED,
1281 asection *sec)
1282 {
1283- BFD_ASSERT (sec->sec_info_type == ELF_INFO_TYPE_MERGE);
1284- sec->sec_info_type = ELF_INFO_TYPE_NONE;
1285+ BFD_ASSERT (sec->sec_info_type == SEC_INFO_TYPE_MERGE);
1286+ sec->sec_info_type = SEC_INFO_TYPE_NONE;
1287 }
1288
1289 /* Finish SHF_MERGE section merging. */
1290@@ -6690,7 +6679,7 @@ _bfd_elf_merge_sections (bfd *abfd, struct bfd_link_info *info)
1291 sec, &secdata->sec_info))
1292 return FALSE;
1293 else if (secdata->sec_info)
1294- sec->sec_info_type = ELF_INFO_TYPE_MERGE;
1295+ sec->sec_info_type = SEC_INFO_TYPE_MERGE;
1296 }
1297
1298 if (elf_hash_table (info)->merge_info != NULL)
1299@@ -8708,7 +8697,7 @@ elf_link_output_extsym (struct bfd_hash_entry *bh, void *data)
1300 else if ((h->root.type == bfd_link_hash_defined
1301 || h->root.type == bfd_link_hash_defweak)
1302 && ((finfo->info->strip_discarded
1303- && elf_discarded_section (h->root.u.def.section))
1304+ && discarded_section (h->root.u.def.section))
1305 || (h->root.u.def.section->owner != NULL
1306 && (h->root.u.def.section->owner->flags & BFD_PLUGIN) != 0)))
1307 strip = TRUE;
1308@@ -9007,8 +8996,8 @@ elf_section_ignore_discarded_relocs (asection *sec)
1309
1310 switch (sec->sec_info_type)
1311 {
1312- case ELF_INFO_TYPE_STABS:
1313- case ELF_INFO_TYPE_EH_FRAME:
1314+ case SEC_INFO_TYPE_STABS:
1315+ case SEC_INFO_TYPE_EH_FRAME:
1316 return TRUE;
1317 default:
1318 break;
1319@@ -9193,7 +9182,7 @@ elf_link_input_bfd (struct elf_final_link_info *finfo, bfd *input_bfd)
1320 *ppsection = NULL;
1321 continue;
1322 }
1323- else if (isec->sec_info_type == ELF_INFO_TYPE_MERGE
1324+ else if (isec->sec_info_type == SEC_INFO_TYPE_MERGE
1325 && ELF_ST_TYPE (isym->st_info) != STT_SECTION)
1326 isym->st_value =
1327 _bfd_merged_section_offset (output_bfd, &isec,
1328@@ -9537,7 +9526,7 @@ elf_link_input_bfd (struct elf_final_link_info *finfo, bfd *input_bfd)
1329 {
1330 /* Complain if the definition comes from a
1331 discarded section. */
1332- if ((sec = *ps) != NULL && elf_discarded_section (sec))
1333+ if ((sec = *ps) != NULL && discarded_section (sec))
1334 {
1335 BFD_ASSERT (r_symndx != STN_UNDEF);
1336 if (action_discarded & COMPLAIN)
1337@@ -9874,19 +9863,19 @@ elf_link_input_bfd (struct elf_final_link_info *finfo, bfd *input_bfd)
1338 }
1339 else switch (o->sec_info_type)
1340 {
1341- case ELF_INFO_TYPE_STABS:
1342+ case SEC_INFO_TYPE_STABS:
1343 if (! (_bfd_write_section_stabs
1344 (output_bfd,
1345 &elf_hash_table (finfo->info)->stab_info,
1346 o, &elf_section_data (o)->sec_info, contents)))
1347 return FALSE;
1348 break;
1349- case ELF_INFO_TYPE_MERGE:
1350+ case SEC_INFO_TYPE_MERGE:
1351 if (! _bfd_write_merged_section (output_bfd, o,
1352 elf_section_data (o)->sec_info))
1353 return FALSE;
1354 break;
1355- case ELF_INFO_TYPE_EH_FRAME:
1356+ case SEC_INFO_TYPE_EH_FRAME:
1357 {
1358 if (! _bfd_elf_write_section_eh_frame (output_bfd, finfo->info,
1359 o, contents))
1360@@ -12415,7 +12404,7 @@ bfd_elf_reloc_symbol_deleted_p (bfd_vma offset, void *cookie)
1361
1362 if ((h->root.type == bfd_link_hash_defined
1363 || h->root.type == bfd_link_hash_defweak)
1364- && elf_discarded_section (h->root.u.def.section))
1365+ && discarded_section (h->root.u.def.section))
1366 return TRUE;
1367 else
1368 return FALSE;
1369@@ -12431,7 +12420,7 @@ bfd_elf_reloc_symbol_deleted_p (bfd_vma offset, void *cookie)
1370 /* Need to: get the symbol; get the section. */
1371 isym = &rcookie->locsyms[r_symndx];
1372 isec = bfd_section_from_elf_index (rcookie->abfd, isym->st_shndx);
1373- if (isec != NULL && elf_discarded_section (isec))
1374+ if (isec != NULL && discarded_section (isec))
1375 return TRUE;
1376 }
1377 return FALSE;
1378@@ -12482,7 +12471,7 @@ bfd_elf_discard_info (bfd *output_bfd, struct bfd_link_info *info)
1379 if (stab != NULL
1380 && (stab->size == 0
1381 || bfd_is_abs_section (stab->output_section)
1382- || stab->sec_info_type != ELF_INFO_TYPE_STABS))
1383+ || stab->sec_info_type != SEC_INFO_TYPE_STABS))
1384 stab = NULL;
1385
1386 if (stab == NULL
1387diff --git a/bfd/elfnn-ia64.c b/bfd/elfnn-ia64.c
1388index 3e2ee0b..0f6b720 100644
1389--- a/bfd/elfnn-ia64.c
1390+++ b/bfd/elfnn-ia64.c
1391@@ -530,7 +530,7 @@ elfNN_ia64_relax_section (bfd *abfd, asection *sec,
1392 symtype = h->type;
1393 }
1394
1395- if (tsec->sec_info_type == ELF_INFO_TYPE_MERGE)
1396+ if (tsec->sec_info_type == SEC_INFO_TYPE_MERGE)
1397 {
1398 /* At this stage in linking, no SEC_MERGE symbol has been
1399 adjusted, so all references to such symbols need to be
1400@@ -3861,7 +3861,7 @@ elfNN_ia64_relocate_section (bfd *output_bfd,
1401 if (!info->relocatable
1402 && (sym_sec->flags & SEC_MERGE) != 0
1403 && ELF_ST_TYPE (sym->st_info) == STT_SECTION
1404- && sym_sec->sec_info_type == ELF_INFO_TYPE_MERGE)
1405+ && sym_sec->sec_info_type == SEC_INFO_TYPE_MERGE)
1406 {
1407 struct elfNN_ia64_local_hash_entry *loc_h;
1408
1409@@ -3919,7 +3919,7 @@ elfNN_ia64_relocate_section (bfd *output_bfd,
1410 continue;
1411 }
1412
1413- if (sym_sec != NULL && elf_discarded_section (sym_sec))
1414+ if (sym_sec != NULL && discarded_section (sym_sec))
1415 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
1416 rel, relend, howto, contents);
1417
1418diff --git a/bfd/elfxx-mips.c b/bfd/elfxx-mips.c
1419index fa906cd..7911050 100644
1420--- a/bfd/elfxx-mips.c
1421+++ b/bfd/elfxx-mips.c
1422@@ -9385,7 +9385,7 @@ _bfd_mips_elf_relocate_section (bfd *output_bfd, struct bfd_link_info *info,
1423 sec = h->root.u.def.section;
1424 }
1425
1426- if (sec != NULL && elf_discarded_section (sec))
1427+ if (sec != NULL && discarded_section (sec))
1428 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
1429 rel, relend, howto, contents);
1430
1431diff --git a/bfd/elfxx-sparc.c b/bfd/elfxx-sparc.c
1432index 9a15124..f3c631e 100644
1433--- a/bfd/elfxx-sparc.c
1434+++ b/bfd/elfxx-sparc.c
1435@@ -2970,7 +2970,7 @@ _bfd_sparc_elf_relocate_section (bfd *output_bfd,
1436 }
1437 }
1438
1439- if (sec != NULL && elf_discarded_section (sec))
1440+ if (sec != NULL && discarded_section (sec))
1441 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
1442 rel, relend, howto, contents);
1443
1444diff --git a/bfd/elfxx-tilegx.c b/bfd/elfxx-tilegx.c
1445index c484562..e1c8946 100644
1446--- a/bfd/elfxx-tilegx.c
1447+++ b/bfd/elfxx-tilegx.c
1448@@ -2908,7 +2908,7 @@ tilegx_elf_relocate_section (bfd *output_bfd, struct bfd_link_info *info,
1449 }
1450 }
1451
1452- if (sec != NULL && elf_discarded_section (sec))
1453+ if (sec != NULL && discarded_section (sec))
1454 RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
1455 rel, relend, howto, contents);
1456
1457diff --git a/bfd/linker.c b/bfd/linker.c
1458index 7a01e11..e5d20b2 100644
1459--- a/bfd/linker.c
1460+++ b/bfd/linker.c
1461@@ -1,6 +1,6 @@
1462 /* linker.c -- BFD linker routines
1463 Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
1464- 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011
1465+ 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012
1466 Free Software Foundation, Inc.
1467 Written by Steve Chamberlain and Ian Lance Taylor, Cygnus Support
1468
1469@@ -810,6 +810,7 @@ void
1470 _bfd_generic_link_just_syms (asection *sec,
1471 struct bfd_link_info *info ATTRIBUTE_UNUSED)
1472 {
1473+ sec->sec_info_type = SEC_INFO_TYPE_JUST_SYMS;
1474 sec->output_section = bfd_abs_section_ptr;
1475 sec->output_offset = sec->vma;
1476 }
1477diff --git a/bfd/reloc.c b/bfd/reloc.c
1478index ef55cc3..e3f0343 100644
1479--- a/bfd/reloc.c
1480+++ b/bfd/reloc.c
1481@@ -6235,7 +6235,7 @@ bfd_generic_get_relocated_section_contents (bfd *abfd,
1482 bfd_reloc_status_type r;
1483
1484 symbol = *(*parent)->sym_ptr_ptr;
1485- if (symbol->section && elf_discarded_section (symbol->section))
1486+ if (symbol->section && discarded_section (symbol->section))
1487 {
1488 bfd_byte *p;
1489 static reloc_howto_type none_howto
1490diff --git a/bfd/section.c b/bfd/section.c
1491index 7c1f750..e60f247 100644
1492--- a/bfd/section.c
1493+++ b/bfd/section.c
1494@@ -382,11 +382,11 @@ CODE_FRAGMENT
1495 .
1496 . {* Type of sec_info information. *}
1497 . unsigned int sec_info_type:3;
1498-.#define ELF_INFO_TYPE_NONE 0
1499-.#define ELF_INFO_TYPE_STABS 1
1500-.#define ELF_INFO_TYPE_MERGE 2
1501-.#define ELF_INFO_TYPE_EH_FRAME 3
1502-.#define ELF_INFO_TYPE_JUST_SYMS 4
1503+.#define SEC_INFO_TYPE_NONE 0
1504+.#define SEC_INFO_TYPE_STABS 1
1505+.#define SEC_INFO_TYPE_MERGE 2
1506+.#define SEC_INFO_TYPE_EH_FRAME 3
1507+.#define SEC_INFO_TYPE_JUST_SYMS 4
1508 .
1509 . {* Nonzero if this section uses RELA relocations, rather than REL. *}
1510 . unsigned int use_rela_p:1;
1511diff --git a/ld/emultempl/armelf.em b/ld/emultempl/armelf.em
1512index d29da59..7631474 100644
1513--- a/ld/emultempl/armelf.em
1514+++ b/ld/emultempl/armelf.em
1515@@ -240,7 +240,7 @@ build_section_lists (lang_statement_union_type *statement)
1516 {
1517 asection *i = statement->input_section.section;
1518
1519- if (!((lang_input_statement_type *) i->owner->usrdata)->just_syms_flag
1520+ if (i->sec_info_type != SEC_INFO_TYPE_JUST_SYMS
1521 && (i->flags & SEC_EXCLUDE) == 0
1522 && i->output_section != NULL
1523 && i->output_section->owner == link_info.output_bfd)
1524@@ -299,7 +299,7 @@ gld${EMULATION_NAME}_after_allocation (void)
1525 && elf_section_type (sec) == SHT_PROGBITS
1526 && (elf_section_flags (sec) & SHF_EXECINSTR) != 0
1527 && (sec->flags & SEC_EXCLUDE) == 0
1528- && sec->sec_info_type != ELF_INFO_TYPE_JUST_SYMS
1529+ && sec->sec_info_type != SEC_INFO_TYPE_JUST_SYMS
1530 && out_sec != bfd_abs_section_ptr)
1531 {
1532 if (sec_count == list_size)
1533diff --git a/ld/emultempl/hppaelf.em b/ld/emultempl/hppaelf.em
1534index 1137ba2..6258bf4 100644
1535--- a/ld/emultempl/hppaelf.em
1536+++ b/ld/emultempl/hppaelf.em
1537@@ -229,7 +229,7 @@ build_section_lists (lang_statement_union_type *statement)
1538 {
1539 asection *i = statement->input_section.section;
1540
1541- if (!((lang_input_statement_type *) i->owner->usrdata)->just_syms_flag
1542+ if (i->sec_info_type != SEC_INFO_TYPE_JUST_SYMS
1543 && (i->flags & SEC_EXCLUDE) == 0
1544 && i->output_section != NULL
1545 && i->output_section->owner == link_info.output_bfd)
1546diff --git a/ld/emultempl/ppc64elf.em b/ld/emultempl/ppc64elf.em
1547index 92a468f..52b9f05 100644
1548--- a/ld/emultempl/ppc64elf.em
1549+++ b/ld/emultempl/ppc64elf.em
1550@@ -428,7 +428,7 @@ build_toc_list (lang_statement_union_type *statement)
1551 {
1552 asection *i = statement->input_section.section;
1553
1554- if (!((lang_input_statement_type *) i->owner->usrdata)->just_syms_flag
1555+ if (i->sec_info_type != SEC_INFO_TYPE_JUST_SYMS
1556 && (i->flags & SEC_EXCLUDE) == 0
1557 && i->output_section == toc_section)
1558 {
1559@@ -446,7 +446,7 @@ build_section_lists (lang_statement_union_type *statement)
1560 {
1561 asection *i = statement->input_section.section;
1562
1563- if (!((lang_input_statement_type *) i->owner->usrdata)->just_syms_flag
1564+ if (i->sec_info_type != SEC_INFO_TYPE_JUST_SYMS
1565 && (i->flags & SEC_EXCLUDE) == 0
1566 && i->output_section != NULL
1567 && i->output_section->owner == link_info.output_bfd)
1568diff --git a/ld/emultempl/tic6xdsbt.em b/ld/emultempl/tic6xdsbt.em
1569index e287005..fd7a12b 100644
1570--- a/ld/emultempl/tic6xdsbt.em
1571+++ b/ld/emultempl/tic6xdsbt.em
1572@@ -122,7 +122,7 @@ gld${EMULATION_NAME}_after_allocation (void)
1573 && elf_section_type (sec) == SHT_PROGBITS
1574 && (elf_section_flags (sec) & SHF_EXECINSTR) != 0
1575 && (sec->flags & SEC_EXCLUDE) == 0
1576- && sec->sec_info_type != ELF_INFO_TYPE_JUST_SYMS
1577+ && sec->sec_info_type != SEC_INFO_TYPE_JUST_SYMS
1578 && out_sec != bfd_abs_section_ptr)
1579 {
1580 if (sec_count == list_size)
1581diff --git a/ld/ldlang.c b/ld/ldlang.c
1582index 2c56b56..7ecbae2 100644
1583--- a/ld/ldlang.c
1584+++ b/ld/ldlang.c
1585@@ -4648,7 +4648,7 @@ size_input_section
1586 lang_input_section_type *is = &((*this_ptr)->input_section);
1587 asection *i = is->section;
1588
1589- if (!((lang_input_statement_type *) i->owner->usrdata)->just_syms_flag
1590+ if (i->sec_info_type != SEC_INFO_TYPE_JUST_SYMS
1591 && (i->flags & SEC_EXCLUDE) == 0)
1592 {
1593 unsigned int alignment_needed;
1594diff --git a/ld/ldwrite.c b/ld/ldwrite.c
1595index b7a1469..2503d1f 100644
1596--- a/ld/ldwrite.c
1597+++ b/ld/ldwrite.c
1598@@ -1,6 +1,6 @@
1599 /* ldwrite.c -- write out the linked file
1600 Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000, 2002,
1601- 2003, 2004, 2005, 2006, 2007, 2008, 2010
1602+ 2003, 2004, 2005, 2006, 2007, 2008, 2010, 2012
1603 Free Software Foundation, Inc.
1604 Written by Steve Chamberlain sac@cygnus.com
1605
1606@@ -240,7 +240,7 @@ build_link_order (lang_statement_union_type *statement)
1607 attached */
1608 asection *i = statement->input_section.section;
1609
1610- if (!((lang_input_statement_type *) i->owner->usrdata)->just_syms_flag
1611+ if (i->sec_info_type != SEC_INFO_TYPE_JUST_SYMS
1612 && (i->flags & SEC_EXCLUDE) == 0)
1613 {
1614 asection *output_section = i->output_section;
1615--
16161.7.9.5
1617
diff --git a/meta/recipes-devtools/binutils/binutils/binutils-2.19.1-ld-sysroot.patch b/meta/recipes-devtools/binutils/binutils/binutils-2.19.1-ld-sysroot.patch
deleted file mode 100644
index 5e6be3a653..0000000000
--- a/meta/recipes-devtools/binutils/binutils/binutils-2.19.1-ld-sysroot.patch
+++ /dev/null
@@ -1,39 +0,0 @@
1Upstream-Status: Pending
2
3http://sourceware.org/bugzilla/show_bug.cgi?id=10340
4
5Signed-off-by: Sven Rebhan <odinshorse@googlemail.com>
6
7Always try to prepend the sysroot prefix to absolute filenames first.
8
9Index: binutils-2.22/ld/ldfile.c
10===================================================================
11--- binutils-2.22.orig/ld/ldfile.c
12+++ binutils-2.22/ld/ldfile.c
13@@ -351,18 +351,24 @@ ldfile_open_file_search (const char *arc
14 directory first. */
15 if (! entry->maybe_archive)
16 {
17- if (entry->sysrooted && IS_ABSOLUTE_PATH (entry->filename))
18+ /* For absolute pathnames, try to always open the file in the
19+ sysroot first. If this fails, try to open the file at the
20+ given location. */
21+ entry->sysrooted = is_sysrooted_pathname(entry->filename, FALSE);
22+ if (IS_ABSOLUTE_PATH (entry->filename) && ld_sysroot && ! entry->sysrooted)
23 {
24 char *name = concat (ld_sysroot, entry->filename,
25 (const char *) NULL);
26 if (ldfile_try_open_bfd (name, entry))
27 {
28 entry->filename = name;
29+ entry->sysrooted = TRUE;
30 return TRUE;
31 }
32 free (name);
33 }
34- else if (ldfile_try_open_bfd (entry->filename, entry))
35+
36+ if (ldfile_try_open_bfd (entry->filename, entry))
37 {
38 entry->sysrooted = IS_ABSOLUTE_PATH (entry->filename)
39 && is_sysrooted_pathname (entry->filename, TRUE);
diff --git a/meta/recipes-devtools/binutils/binutils/binutils-armv5e.patch b/meta/recipes-devtools/binutils/binutils/binutils-armv5e.patch
deleted file mode 100644
index c95eed6f94..0000000000
--- a/meta/recipes-devtools/binutils/binutils/binutils-armv5e.patch
+++ /dev/null
@@ -1,24 +0,0 @@
1Add the armv5e architecture to binutils
2
3Binutils has a comment that indicates it is supposed to match gcc for all of
4the support "-march=" settings, but it was lacking the armv5e setting. This
5was a simple way to add it, as thumb instructions shouldn't be generated by
6the compiler anyway.
7
8Upstream-Status: Denied
9Upstream maintainer indicated that we should not be using armv5e, even though
10it is a legal archicture defined by our gcc.
11
12Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
13
14diff -urN binutils-2.22.orig/gas/config/tc-arm.c binutils-2.22/gas/config/tc-arm.c
15--- binutils-2.22.orig/gas/config/tc-arm.c 2011-11-21 03:29:31.000000000 -0600
16+++ binutils-2.22/gas/config/tc-arm.c 2012-04-03 12:07:42.230158760 -0500
17@@ -22990,6 +22990,7 @@
18 {"armv4t", ARM_ARCH_V4T, FPU_ARCH_FPA},
19 {"armv4txm", ARM_ARCH_V4TxM, FPU_ARCH_FPA},
20 {"armv5", ARM_ARCH_V5, FPU_ARCH_VFP},
21+ {"armv5e", ARM_ARCH_V5TE, FPU_ARCH_VFP},
22 {"armv5t", ARM_ARCH_V5T, FPU_ARCH_VFP},
23 {"armv5txm", ARM_ARCH_V5TxM, FPU_ARCH_VFP},
24 {"armv5te", ARM_ARCH_V5TE, FPU_ARCH_VFP},
diff --git a/meta/recipes-devtools/binutils/binutils/binutils-poison.patch b/meta/recipes-devtools/binutils/binutils/binutils-poison.patch
deleted file mode 100644
index 7f81838f72..0000000000
--- a/meta/recipes-devtools/binutils/binutils/binutils-poison.patch
+++ /dev/null
@@ -1,255 +0,0 @@
1Upstream-Status: Inappropriate [distribution: codesourcery]
2
3Patch originally created by Mark Hatle, forward-ported to
4binutils 2.21 by Scott Garman.
5
6purpose: warn for uses of system directories when cross linking
7
8Code Merged from Sourcery G++ binutils 2.19 - 4.4-277
9
102008-07-02 Joseph Myers <joseph@codesourcery.com>
11
12 ld/
13 * ld.h (args_type): Add error_poison_system_directories.
14 * ld.texinfo (--error-poison-system-directories): Document.
15 * ldfile.c (ldfile_add_library_path): Check
16 command_line.error_poison_system_directories.
17 * ldmain.c (main): Initialize
18 command_line.error_poison_system_directories.
19 * lexsup.c (enum option_values): Add
20 OPTION_ERROR_POISON_SYSTEM_DIRECTORIES.
21 (ld_options): Add --error-poison-system-directories.
22 (parse_args): Handle new option.
23
242007-06-13 Joseph Myers <joseph@codesourcery.com>
25
26 ld/
27 * config.in: Regenerate.
28 * ld.h (args_type): Add poison_system_directories.
29 * ld.texinfo (--no-poison-system-directories): Document.
30 * ldfile.c (ldfile_add_library_path): Check
31 command_line.poison_system_directories.
32 * ldmain.c (main): Initialize
33 command_line.poison_system_directories.
34 * lexsup.c (enum option_values): Add
35 OPTION_NO_POISON_SYSTEM_DIRECTORIES.
36 (ld_options): Add --no-poison-system-directories.
37 (parse_args): Handle new option.
38
392007-04-20 Joseph Myers <joseph@codesourcery.com>
40
41 Merge from Sourcery G++ binutils 2.17:
42
43 2007-03-20 Joseph Myers <joseph@codesourcery.com>
44 Based on patch by Mark Hatle <mark.hatle@windriver.com>.
45 ld/
46 * configure.in (--enable-poison-system-directories): New option.
47 * configure, config.in: Regenerate.
48 * ldfile.c (ldfile_add_library_path): If
49 ENABLE_POISON_SYSTEM_DIRECTORIES defined, warn for use of /lib,
50 /usr/lib, /usr/local/lib or /usr/X11R6/lib.
51
52Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
53Signed-off-by: Scott Garman <scott.a.garman@intel.com>
54
55Index: binutils-2.22/ld/config.in
56===================================================================
57--- binutils-2.22.orig/ld/config.in
58+++ binutils-2.22/ld/config.in
59@@ -4,6 +4,9 @@
60 language is requested. */
61 #undef ENABLE_NLS
62
63+/* Define to warn for use of native system library directories */
64+#undef ENABLE_POISON_SYSTEM_DIRECTORIES
65+
66 /* Additional extension a shared object might have. */
67 #undef EXTRA_SHLIB_EXTENSION
68
69Index: binutils-2.22/ld/configure
70===================================================================
71--- binutils-2.22.orig/ld/configure
72+++ binutils-2.22/ld/configure
73@@ -776,6 +776,7 @@ with_lib_path
74 enable_targets
75 enable_64_bit_bfd
76 with_sysroot
77+enable_poison_system_directories
78 enable_gold
79 enable_got
80 enable_werror
81@@ -1431,6 +1432,8 @@ Optional Features:
82 (and sometimes confusing) to the casual installer
83 --enable-targets alternative target configurations
84 --enable-64-bit-bfd 64-bit support (on hosts with narrower word sizes)
85+ --enable-poison-system-directories
86+ warn for use of native system library directories
87 --enable-gold[=ARG] build gold [ARG={default,yes,no}]
88 --enable-got=<type> GOT handling scheme (target, single, negative,
89 multigot)
90@@ -4342,7 +4345,18 @@ else
91 fi
92
93
94+# Check whether --enable-poison-system-directories was given.
95+if test "${enable_poison_system_directories+set}" = set; then :
96+ enableval=$enable_poison_system_directories;
97+else
98+ enable_poison_system_directories=no
99+fi
100+
101+if test "x${enable_poison_system_directories}" = "xyes"; then
102
103+$as_echo "#define ENABLE_POISON_SYSTEM_DIRECTORIES 1" >>confdefs.h
104+
105+fi
106
107 # Check whether --enable-got was given.
108 if test "${enable_got+set}" = set; then :
109Index: binutils-2.22/ld/configure.in
110===================================================================
111--- binutils-2.22.orig/ld/configure.in
112+++ binutils-2.22/ld/configure.in
113@@ -70,6 +70,16 @@ AC_SUBST(use_sysroot)
114 AC_SUBST(TARGET_SYSTEM_ROOT)
115 AC_SUBST(TARGET_SYSTEM_ROOT_DEFINE)
116
117+AC_ARG_ENABLE([poison-system-directories],
118+ AS_HELP_STRING([--enable-poison-system-directories],
119+ [warn for use of native system library directories]),,
120+ [enable_poison_system_directories=no])
121+if test "x${enable_poison_system_directories}" = "xyes"; then
122+ AC_DEFINE([ENABLE_POISON_SYSTEM_DIRECTORIES],
123+ [1],
124+ [Define to warn for use of native system library directories])
125+fi
126+
127 dnl Use --enable-gold to decide if this linker should be the default.
128 dnl "install_as_default" is set to false if gold is the default linker.
129 dnl "installed_linker" is the installed BFD linker name.
130Index: binutils-2.22/ld/ldfile.c
131===================================================================
132--- binutils-2.22.orig/ld/ldfile.c
133+++ binutils-2.22/ld/ldfile.c
134@@ -125,6 +125,23 @@ ldfile_add_library_path (const char *nam
135 {
136 new_dirs->name = xstrdup (name);
137 new_dirs->sysrooted = is_sysrooted_pathname (name, FALSE);
138+
139+#ifdef ENABLE_POISON_SYSTEM_DIRECTORIES
140+ if (command_line.poison_system_directories
141+ && ((!strncmp (name, "/lib", 4))
142+ || (!strncmp (name, "/usr/lib", 8))
143+ || (!strncmp (name, "/usr/local/lib", 14))
144+ || (!strncmp (name, "/usr/X11R6/lib", 14))))
145+ {
146+ if (command_line.error_poison_system_directories)
147+ einfo (_("%X%P: error: library search path \"%s\" is unsafe for "
148+ "cross-compilation\n"), name);
149+ else
150+ einfo (_("%P: warning: library search path \"%s\" is unsafe for "
151+ "cross-compilation\n"), name);
152+ }
153+#endif
154+
155 }
156 }
157
158Index: binutils-2.22/ld/ld.h
159===================================================================
160--- binutils-2.22.orig/ld/ld.h
161+++ binutils-2.22/ld/ld.h
162@@ -203,6 +203,14 @@ typedef struct {
163 /* If TRUE we'll just print the default output on stdout. */
164 bfd_boolean print_output_format;
165
166+ /* If TRUE (the default) warn for uses of system directories when
167+ cross linking. */
168+ bfd_boolean poison_system_directories;
169+
170+ /* If TRUE (default FALSE) give an error for uses of system
171+ directories when cross linking instead of a warning. */
172+ bfd_boolean error_poison_system_directories;
173+
174 /* Big or little endian as set on command line. */
175 enum endian_enum endian;
176
177Index: binutils-2.22/ld/ldmain.c
178===================================================================
179--- binutils-2.22.orig/ld/ldmain.c
180+++ binutils-2.22/ld/ldmain.c
181@@ -259,6 +259,8 @@ main (int argc, char **argv)
182 command_line.warn_search_mismatch = TRUE;
183 command_line.check_section_addresses = -1;
184 command_line.disable_target_specific_optimizations = -1;
185+ command_line.poison_system_directories = TRUE;
186+ command_line.error_poison_system_directories = FALSE;
187
188 /* We initialize DEMANGLING based on the environment variable
189 COLLECT_NO_DEMANGLE. The gcc collect2 program will demangle the
190Index: binutils-2.22/ld/ld.texinfo
191===================================================================
192--- binutils-2.22.orig/ld/ld.texinfo
193+++ binutils-2.22/ld/ld.texinfo
194@@ -2147,6 +2147,18 @@ string identifying the original linked f
195
196 Passing @code{none} for @var{style} disables the setting from any
197 @code{--build-id} options earlier on the command line.
198+
199+@kindex --no-poison-system-directories
200+@item --no-poison-system-directories
201+Do not warn for @option{-L} options using system directories such as
202+@file{/usr/lib} when cross linking. This option is intended for use
203+in chroot environments when such directories contain the correct
204+libraries for the target system rather than the host.
205+
206+@kindex --error-poison-system-directories
207+@item --error-poison-system-directories
208+Give an error instead of a warning for @option{-L} options using
209+system directories when cross linking.
210 @end table
211
212 @c man end
213Index: binutils-2.22/ld/lexsup.c
214===================================================================
215--- binutils-2.22.orig/ld/lexsup.c
216+++ binutils-2.22/ld/lexsup.c
217@@ -176,6 +176,8 @@ enum option_values
218 #endif /* ENABLE_PLUGINS */
219 OPTION_DEFAULT_SCRIPT,
220 OPTION_PRINT_OUTPUT_FORMAT,
221+ OPTION_NO_POISON_SYSTEM_DIRECTORIES,
222+ OPTION_ERROR_POISON_SYSTEM_DIRECTORIES
223 };
224
225 /* The long options. This structure is used for both the option
226@@ -612,6 +614,14 @@ static const struct ld_option ld_options
227 TWO_DASHES },
228 { {"wrap", required_argument, NULL, OPTION_WRAP},
229 '\0', N_("SYMBOL"), N_("Use wrapper functions for SYMBOL"), TWO_DASHES },
230+ { {"no-poison-system-directories", no_argument, NULL,
231+ OPTION_NO_POISON_SYSTEM_DIRECTORIES},
232+ '\0', NULL, N_("Do not warn for -L options using system directories"),
233+ TWO_DASHES },
234+ { {"error-poison-system-directories", no_argument, NULL,
235+ OPTION_ERROR_POISON_SYSTEM_DIRECTORIES},
236+ '\0', NULL, N_("Give an error for -L options using system directories"),
237+ TWO_DASHES },
238 };
239
240 #define OPTION_COUNT ARRAY_SIZE (ld_options)
241@@ -1541,6 +1551,14 @@ parse_args (unsigned argc, char **argv)
242 einfo (_("%P%X: --hash-size needs a numeric argument\n"));
243 }
244 break;
245+
246+ case OPTION_NO_POISON_SYSTEM_DIRECTORIES:
247+ command_line.poison_system_directories = FALSE;
248+ break;
249+
250+ case OPTION_ERROR_POISON_SYSTEM_DIRECTORIES:
251+ command_line.error_poison_system_directories = TRUE;
252+ break;
253 }
254 }
255
diff --git a/meta/recipes-devtools/binutils/binutils/binutils-powerpc-e5500.patch b/meta/recipes-devtools/binutils/binutils/binutils-powerpc-e5500.patch
deleted file mode 100644
index 1f146ce68e..0000000000
--- a/meta/recipes-devtools/binutils/binutils/binutils-powerpc-e5500.patch
+++ /dev/null
@@ -1,936 +0,0 @@
1Upstream-Status: Backport
2Signed-off- by: Khem Raj <raj.khem@gmail.com>
3
4From 4f017a6dfe0c3e84c21431c85e82ce2af0941ac1 Mon Sep 17 00:00:00 2001
5From: Alan Modra <amodra@bigpond.net.au>
6Date: Fri, 9 Mar 2012 23:39:02 +0000
7Subject: [PATCH] include/opcode/ * ppc.h: Add PPC_OPCODE_ALTIVEC2,
8 PPC_OPCODE_E6500, PPC_OPCODE_TMR. opcodes/ * ppc-dis.c
9 (ppc_opts): Add entries for "e5500" and "e6500". *
10 ppc-opc.c (insert_ls, TMR, ESYNC, XSYNCLE_MASK): New.
11 (PPCVEC2, PPCTMR, E6500): New short names.
12 (powerpc_opcodes): Add vabsdub, vabsduh, vabsduw, dni,
13 mvidsplt, mviwsplt, icblq., mftmr, mttmr, dcblq.,
14 miso, lvexbx, lvexhx, lvexwx, stvexbx, stvexhx, stvexwx,
15 lvepx, lvepxl, stvepx, stvepxl, lvtrx, lvtrxl,
16 lvtlx, lvtlxl, stvfrx, stvfrxl, stvflx, stvflxl,
17 lvswx, lvswxl, stvswx, stvswxl, lvsm mnemonics. Accept LS,
18 ESYNC optional operands on sync instruction for E6500
19 target. bfd/ * archures.c: Add bfd_mach_ppc_e5500 and
20 bfd_mach_ppc_e6500. * bfd-in2.h: Regenerate. *
21 cpu-powerpc.c (bfd_powerpc_archs): Add entryies for
22 bfd_mach_ppc_e5500 and bfd_mach_ppc_e6500. gas/ *
23 config/tc-ppc.c (md_show_usage): Document -me5500 and
24 -me6500. (ppc_handle_align): Add termination nop
25 opcode for e500mc family. * doc/as.texinfo: Document
26 options -me5500 and -me6500. * doc/c-ppc.texi: Likewise.
27 gas/testsuite/ * gas/ppc/e500mc64_nop.s: New test
28 case for e500mc family termination nops. *
29 gas/ppc/e500mc64_nop.d: Likewise. *
30 gas/ppc/e5500_nop.s: Likewise. *
31 gas/ppc/e5500_nop.d: Likewise. *
32 gas/ppc/e6500_nop.s: Likewise. *
33 gas/ppc/e6500_nop.d: Likewise. * gas/ppc/e6500.s:
34 New. * gas/ppc/e6500.d: Likewise. * gas/ppc/ppc.exp:
35 Run e6500, e500mc64_nop, e5500_nop, and e6500_nop.
36
37---
38 bfd/ChangeLog | 7 +++
39 bfd/archures.c | 6 +-
40 bfd/bfd-in2.h | 2 +
41 bfd/cpu-powerpc.c | 34 ++++++++++-
42 gas/ChangeLog | 7 +++
43 gas/config/tc-ppc.c | 14 ++++-
44 gas/doc/as.texinfo | 6 +-
45 gas/doc/c-ppc.texi | 8 ++-
46 gas/testsuite/ChangeLog | 13 ++++
47 gas/testsuite/gas/ppc/e500mc64_nop.d | 13 ++++
48 gas/testsuite/gas/ppc/e500mc64_nop.s | 5 ++
49 gas/testsuite/gas/ppc/e5500_nop.d | 13 ++++
50 gas/testsuite/gas/ppc/e5500_nop.s | 5 ++
51 gas/testsuite/gas/ppc/e6500.d | 75 +++++++++++++++++++++++
52 gas/testsuite/gas/ppc/e6500.s | 69 +++++++++++++++++++++
53 gas/testsuite/gas/ppc/e6500_nop.d | 13 ++++
54 gas/testsuite/gas/ppc/e6500_nop.s | 5 ++
55 gas/testsuite/gas/ppc/ppc.exp | 4 ++
56 include/opcode/ChangeLog | 4 ++
57 include/opcode/ppc.h | 11 +++-
58 opcodes/ChangeLog | 12 ++++
59 opcodes/ppc-dis.c | 14 ++++-
60 opcodes/ppc-opc.c | 112 +++++++++++++++++++++++++++++++---
61 23 files changed, 432 insertions(+), 20 deletions(-)
62 create mode 100644 gas/testsuite/gas/ppc/e500mc64_nop.d
63 create mode 100644 gas/testsuite/gas/ppc/e500mc64_nop.s
64 create mode 100644 gas/testsuite/gas/ppc/e5500_nop.d
65 create mode 100644 gas/testsuite/gas/ppc/e5500_nop.s
66 create mode 100644 gas/testsuite/gas/ppc/e6500.d
67 create mode 100644 gas/testsuite/gas/ppc/e6500.s
68 create mode 100644 gas/testsuite/gas/ppc/e6500_nop.d
69 create mode 100644 gas/testsuite/gas/ppc/e6500_nop.s
70
71Index: binutils-2.22/bfd/archures.c
72===================================================================
73--- binutils-2.22.orig/bfd/archures.c 2012-07-06 20:40:40.000000000 -0700
74+++ binutils-2.22/bfd/archures.c 2012-07-06 20:41:27.822780001 -0700
75@@ -1,7 +1,7 @@
76 /* BFD library support routines for architectures.
77 Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
78- 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011
79- Free Software Foundation, Inc.
80+ 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011,
81+ 2012 Free Software Foundation, Inc.
82 Hacked by John Gilmore and Steve Chamberlain of Cygnus Support.
83
84 This file is part of BFD, the Binary File Descriptor library.
85@@ -239,6 +239,8 @@
86 .#define bfd_mach_ppc_e500 500
87 .#define bfd_mach_ppc_e500mc 5001
88 .#define bfd_mach_ppc_e500mc64 5005
89+.#define bfd_mach_ppc_e5500 5006
90+.#define bfd_mach_ppc_e6500 5007
91 .#define bfd_mach_ppc_titan 83
92 . bfd_arch_rs6000, {* IBM RS/6000 *}
93 .#define bfd_mach_rs6k 6000
94Index: binutils-2.22/bfd/bfd-in2.h
95===================================================================
96--- binutils-2.22.orig/bfd/bfd-in2.h 2012-07-06 20:40:40.000000000 -0700
97+++ binutils-2.22/bfd/bfd-in2.h 2012-07-06 20:41:27.822780001 -0700
98@@ -1946,6 +1946,8 @@
99 #define bfd_mach_ppc_e500 500
100 #define bfd_mach_ppc_e500mc 5001
101 #define bfd_mach_ppc_e500mc64 5005
102+#define bfd_mach_ppc_e5500 5006
103+#define bfd_mach_ppc_e6500 5007
104 #define bfd_mach_ppc_titan 83
105 bfd_arch_rs6000, /* IBM RS/6000 */
106 #define bfd_mach_rs6k 6000
107Index: binutils-2.22/bfd/cpu-powerpc.c
108===================================================================
109--- binutils-2.22.orig/bfd/cpu-powerpc.c 2012-07-06 20:40:40.000000000 -0700
110+++ binutils-2.22/bfd/cpu-powerpc.c 2012-07-06 20:41:27.822780001 -0700
111@@ -1,6 +1,6 @@
112 /* BFD PowerPC CPU definition
113- Copyright 1994, 1995, 1996, 2000, 2001, 2002, 2003, 2005, 2007, 2008, 2010
114- Free Software Foundation, Inc.
115+ Copyright 1994, 1995, 1996, 2000, 2001, 2002, 2003, 2005, 2007, 2008,
116+ 2010, 2012 Free Software Foundation, Inc.
117 Contributed by Ian Lance Taylor, Cygnus Support.
118
119 This file is part of BFD, the Binary File Descriptor library.
120Index: binutils-2.22/gas/config/tc-ppc.c
121===================================================================
122--- binutils-2.22.orig/gas/config/tc-ppc.c 2012-07-06 20:40:40.000000000 -0700
123+++ binutils-2.22/gas/config/tc-ppc.c 2012-07-06 20:41:27.826780001 -0700
124@@ -1,6 +1,6 @@
125 /* tc-ppc.c -- Assemble for the PowerPC or POWER (RS/6000)
126 Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
127- 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011
128+ 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012
129 Free Software Foundation, Inc.
130 Written by Ian Lance Taylor, Cygnus Support.
131
132@@ -1265,6 +1265,8 @@
133 -me500, -me500x2 generate code for Motorola e500 core complex\n\
134 -me500mc, generate code for Freescale e500mc core complex\n\
135 -me500mc64, generate code for Freescale e500mc64 core complex\n\
136+-me5500, generate code for Freescale e5500 core complex\n\
137+-me6500, generate code for Freescale e6500 core complex\n\
138 -mspe generate code for Motorola SPE instructions\n\
139 -mtitan generate code for AppliedMicro Titan core complex\n\
140 -mregnames Allow symbolic names for registers\n\
141@@ -6012,8 +6014,14 @@
142 }
143
144 if ((ppc_cpu & PPC_OPCODE_POWER7) != 0)
145- /* power7 group terminating nop: "ori 2,2,0". */
146- md_number_to_chars (dest, 0x60420000, 4);
147+ {
148+ if (ppc_cpu & PPC_OPCODE_E500MC)
149+ /* e500mc group terminating nop: "ori 0,0,0". */
150+ md_number_to_chars (dest, 0x60000000, 4);
151+ else
152+ /* power7 group terminating nop: "ori 2,2,0". */
153+ md_number_to_chars (dest, 0x60420000, 4);
154+ }
155 else
156 /* power6 group terminating nop: "ori 1,1,0". */
157 md_number_to_chars (dest, 0x60210000, 4);
158Index: binutils-2.22/gas/doc/as.texinfo
159===================================================================
160--- binutils-2.22.orig/gas/doc/as.texinfo 2012-07-06 20:40:40.000000000 -0700
161+++ binutils-2.22/gas/doc/as.texinfo 2012-07-06 20:41:27.826780001 -0700
162@@ -1,6 +1,6 @@
163 \input texinfo @c -*-Texinfo-*-
164 @c Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
165-@c 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011
166+@c 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012
167 @c Free Software Foundation, Inc.
168 @c UPDATE!! On future updates--
169 @c (1) check for new machine-dep cmdline options in
170@@ -434,8 +434,8 @@
171 [@b{-a32}|@b{-a64}]
172 [@b{-mpwrx}|@b{-mpwr2}|@b{-mpwr}|@b{-m601}|@b{-mppc}|@b{-mppc32}|@b{-m603}|@b{-m604}|@b{-m403}|@b{-m405}|
173 @b{-m440}|@b{-m464}|@b{-m476}|@b{-m7400}|@b{-m7410}|@b{-m7450}|@b{-m7455}|@b{-m750cl}|@b{-mppc64}|
174- @b{-m620}|@b{-me500}|@b{-e500x2}|@b{-me500mc}|@b{-me500mc64}|@b{-mppc64bridge}|@b{-mbooke}|
175- @b{-mpower4}|@b{-mpr4}|@b{-mpower5}|@b{-mpwr5}|@b{-mpwr5x}|@b{-mpower6}|@b{-mpwr6}|
176+ @b{-m620}|@b{-me500}|@b{-e500x2}|@b{-me500mc}|@b{-me500mc64}|@b{-me5500}|@b{-me6500}|@b{-mppc64bridge}|
177+ @b{-mbooke}|@b{-mpower4}|@b{-mpr4}|@b{-mpower5}|@b{-mpwr5}|@b{-mpwr5x}|@b{-mpower6}|@b{-mpwr6}|
178 @b{-mpower7}|@b{-mpw7}|@b{-ma2}|@b{-mcell}|@b{-mspe}|@b{-mtitan}|@b{-me300}|@b{-mcom}]
179 [@b{-many}] [@b{-maltivec}|@b{-mvsx}]
180 [@b{-mregnames}|@b{-mno-regnames}]
181Index: binutils-2.22/gas/doc/c-ppc.texi
182===================================================================
183--- binutils-2.22.orig/gas/doc/c-ppc.texi 2012-07-06 20:40:40.000000000 -0700
184+++ binutils-2.22/gas/doc/c-ppc.texi 2012-07-06 20:41:27.826780001 -0700
185@@ -1,5 +1,5 @@
186 @c Copyright 2001, 2002, 2003, 2005, 2006, 2007, 2008, 2009, 2010, 2011
187-@c Free Software Foundation, Inc.
188+@c 2012 Free Software Foundation, Inc.
189 @c This is part of the GAS manual.
190 @c For copying conditions, see the file as.texinfo.
191 @c man end
192@@ -88,6 +88,12 @@
193 @item -me500mc64
194 Generate code for Freescale e500mc64 core complex.
195
196+@item -me5500
197+Generate code for Freescale e5500 core complex.
198+
199+@item -me6500
200+Generate code for Freescale e6500 core complex.
201+
202 @item -mspe
203 Generate code for Motorola SPE instructions.
204
205Index: binutils-2.22/gas/testsuite/gas/ppc/e500mc64_nop.d
206===================================================================
207--- /dev/null 1970-01-01 00:00:00.000000000 +0000
208+++ binutils-2.22/gas/testsuite/gas/ppc/e500mc64_nop.d 2012-07-06 20:41:27.826780001 -0700
209@@ -0,0 +1,13 @@
210+#as: -mppc -me500mc64
211+#objdump: -dr -Me500mc64
212+#name: Power E500MC64 nop tests
213+
214+.*: +file format elf(32)?(64)?-powerpc.*
215+
216+Disassembly of section \.text:
217+
218+0+00 <start>:
219+ 0: 60 00 00 00 nop
220+ 4: 60 00 00 00 nop
221+ 8: 60 00 00 00 nop
222+ c: 60 00 00 00 nop
223Index: binutils-2.22/gas/testsuite/gas/ppc/e500mc64_nop.s
224===================================================================
225--- /dev/null 1970-01-01 00:00:00.000000000 +0000
226+++ binutils-2.22/gas/testsuite/gas/ppc/e500mc64_nop.s 2012-07-06 20:41:27.826780001 -0700
227@@ -0,0 +1,5 @@
228+# Power E500MC64 nop tests
229+ .section ".text"
230+start:
231+ nop
232+ .p2align 4,,15
233Index: binutils-2.22/gas/testsuite/gas/ppc/e5500_nop.d
234===================================================================
235--- /dev/null 1970-01-01 00:00:00.000000000 +0000
236+++ binutils-2.22/gas/testsuite/gas/ppc/e5500_nop.d 2012-07-06 20:41:27.826780001 -0700
237@@ -0,0 +1,13 @@
238+#as: -mppc -me5500
239+#objdump: -dr -Me5500
240+#name: Power E5500 nop tests
241+
242+.*: +file format elf(32)?(64)?-powerpc.*
243+
244+Disassembly of section \.text:
245+
246+0+00 <start>:
247+ 0: 60 00 00 00 nop
248+ 4: 60 00 00 00 nop
249+ 8: 60 00 00 00 nop
250+ c: 60 00 00 00 nop
251Index: binutils-2.22/gas/testsuite/gas/ppc/e5500_nop.s
252===================================================================
253--- /dev/null 1970-01-01 00:00:00.000000000 +0000
254+++ binutils-2.22/gas/testsuite/gas/ppc/e5500_nop.s 2012-07-06 20:41:27.826780001 -0700
255@@ -0,0 +1,5 @@
256+# Power E5500 nop tests
257+ .section ".text"
258+start:
259+ nop
260+ .p2align 4,,15
261Index: binutils-2.22/gas/testsuite/gas/ppc/e6500.d
262===================================================================
263--- /dev/null 1970-01-01 00:00:00.000000000 +0000
264+++ binutils-2.22/gas/testsuite/gas/ppc/e6500.d 2012-07-06 20:41:27.826780001 -0700
265@@ -0,0 +1,75 @@
266+#as: -mppc -me6500
267+#objdump: -dr -Me6500
268+#name: Power E6500 tests
269+
270+.*: +file format elf(32)?(64)?-powerpc.*
271+
272+Disassembly of section \.text:
273+
274+0+00 <start>:
275+ 0: 10 01 10 c0 vabsdub v0,v1,v2
276+ 4: 10 01 11 00 vabsduh v0,v1,v2
277+ 8: 10 01 11 40 vabsduw v0,v1,v2
278+ c: 7c 01 10 dc mvidsplt v0,r1,r2
279+ 10: 7c 01 11 1c mviwsplt v0,r1,r2
280+ 14: 7c 00 12 0a lvexbx v0,0,r2
281+ 18: 7c 01 12 0a lvexbx v0,r1,r2
282+ 1c: 7c 00 12 4a lvexhx v0,0,r2
283+ 20: 7c 01 12 4a lvexhx v0,r1,r2
284+ 24: 7c 00 12 8a lvexwx v0,0,r2
285+ 28: 7c 01 12 8a lvexwx v0,r1,r2
286+ 2c: 7c 00 13 0a stvexbx v0,0,r2
287+ 30: 7c 01 13 0a stvexbx v0,r1,r2
288+ 34: 7c 00 13 4a stvexhx v0,0,r2
289+ 38: 7c 01 13 4a stvexhx v0,r1,r2
290+ 3c: 7c 00 13 8a stvexwx v0,0,r2
291+ 40: 7c 01 13 8a stvexwx v0,r1,r2
292+ 44: 7c 00 12 4e lvepx v0,0,r2
293+ 48: 7c 01 12 4e lvepx v0,r1,r2
294+ 4c: 7c 00 12 0e lvepxl v0,0,r2
295+ 50: 7c 01 12 0e lvepxl v0,r1,r2
296+ 54: 7c 00 16 4e stvepx v0,0,r2
297+ 58: 7c 01 16 4e stvepx v0,r1,r2
298+ 5c: 7c 00 16 0e stvepxl v0,0,r2
299+ 60: 7c 01 16 0e stvepxl v0,r1,r2
300+ 64: 7c 00 14 8a lvtlx v0,0,r2
301+ 68: 7c 01 14 8a lvtlx v0,r1,r2
302+ 6c: 7c 00 16 8a lvtlxl v0,0,r2
303+ 70: 7c 01 16 8a lvtlxl v0,r1,r2
304+ 74: 7c 00 14 4a lvtrx v0,0,r2
305+ 78: 7c 01 14 4a lvtrx v0,r1,r2
306+ 7c: 7c 00 16 4a lvtrxl v0,0,r2
307+ 80: 7c 01 16 4a lvtrxl v0,r1,r2
308+ 84: 7c 00 15 8a stvflx v0,0,r2
309+ 88: 7c 01 15 8a stvflx v0,r1,r2
310+ 8c: 7c 00 17 8a stvflxl v0,0,r2
311+ 90: 7c 01 17 8a stvflxl v0,r1,r2
312+ 94: 7c 00 15 4a stvfrx v0,0,r2
313+ 98: 7c 01 15 4a stvfrx v0,r1,r2
314+ 9c: 7c 00 17 4a stvfrxl v0,0,r2
315+ a0: 7c 01 17 4a stvfrxl v0,r1,r2
316+ a4: 7c 00 14 ca lvswx v0,0,r2
317+ a8: 7c 01 14 ca lvswx v0,r1,r2
318+ ac: 7c 00 16 ca lvswxl v0,0,r2
319+ b0: 7c 01 16 ca lvswxl v0,r1,r2
320+ b4: 7c 00 15 ca stvswx v0,0,r2
321+ b8: 7c 01 15 ca stvswx v0,r1,r2
322+ bc: 7c 00 17 ca stvswxl v0,0,r2
323+ c0: 7c 01 17 ca stvswxl v0,r1,r2
324+ c4: 7c 00 16 0a lvsm v0,0,r2
325+ c8: 7c 01 16 0a lvsm v0,r1,r2
326+ cc: 7f 5a d3 78 miso
327+ d0: 7c 00 04 ac sync
328+ d4: 7c 00 04 ac sync
329+ d8: 7c 20 04 ac lwsync
330+ dc: 7c 00 04 ac sync
331+ e0: 7c 07 04 ac sync 0,7
332+ e4: 7c 28 04 ac sync 1,8
333+ e8: 7c 00 00 c3 dni 0,0
334+ ec: 7f ff 00 c3 dni 31,31
335+ f0: 7c 40 0b 4d dcblq. 2,0,r1
336+ f4: 7c 43 0b 4d dcblq. 2,r3,r1
337+ f8: 7c 40 09 8d icblq. 2,0,r1
338+ fc: 7c 43 09 8d icblq. 2,r3,r1
339+ 100: 7c 10 02 dc mftmr r0,16
340+ 104: 7c 10 03 dc mttmr 16,r0
341Index: binutils-2.22/gas/testsuite/gas/ppc/e6500.s
342===================================================================
343--- /dev/null 1970-01-01 00:00:00.000000000 +0000
344+++ binutils-2.22/gas/testsuite/gas/ppc/e6500.s 2012-07-06 20:41:27.830780001 -0700
345@@ -0,0 +1,69 @@
346+# Power E6500 tests
347+ .section ".text"
348+start:
349+ vabsdub 0, 1, 2
350+ vabsduh 0, 1, 2
351+ vabsduw 0, 1, 2
352+ mvidsplt 0, 1, 2
353+ mviwsplt 0, 1, 2
354+ lvexbx 0, 0, 2
355+ lvexbx 0, 1, 2
356+ lvexhx 0, 0, 2
357+ lvexhx 0, 1, 2
358+ lvexwx 0, 0, 2
359+ lvexwx 0, 1, 2
360+ stvexbx 0, 0, 2
361+ stvexbx 0, 1, 2
362+ stvexhx 0, 0, 2
363+ stvexhx 0, 1, 2
364+ stvexwx 0, 0, 2
365+ stvexwx 0, 1, 2
366+ lvepx 0, 0, 2
367+ lvepx 0, 1, 2
368+ lvepxl 0, 0, 2
369+ lvepxl 0, 1, 2
370+ stvepx 0, 0, 2
371+ stvepx 0, 1, 2
372+ stvepxl 0, 0, 2
373+ stvepxl 0, 1, 2
374+ lvtlx 0, 0, 2
375+ lvtlx 0, 1, 2
376+ lvtlxl 0, 0, 2
377+ lvtlxl 0, 1, 2
378+ lvtrx 0, 0, 2
379+ lvtrx 0, 1, 2
380+ lvtrxl 0, 0, 2
381+ lvtrxl 0, 1, 2
382+ stvflx 0, 0, 2
383+ stvflx 0, 1, 2
384+ stvflxl 0, 0, 2
385+ stvflxl 0, 1, 2
386+ stvfrx 0, 0, 2
387+ stvfrx 0, 1, 2
388+ stvfrxl 0, 0, 2
389+ stvfrxl 0, 1, 2
390+ lvswx 0, 0, 2
391+ lvswx 0, 1, 2
392+ lvswxl 0, 0, 2
393+ lvswxl 0, 1, 2
394+ stvswx 0, 0, 2
395+ stvswx 0, 1, 2
396+ stvswxl 0, 0, 2
397+ stvswxl 0, 1, 2
398+ lvsm 0, 0, 2
399+ lvsm 0, 1, 2
400+ miso
401+ sync
402+ sync 0,0
403+ sync 1,0
404+ sync 2,0
405+ sync 3,7
406+ sync 3,8
407+ dni 0,0
408+ dni 31,31
409+ dcblq. 2,0,1
410+ dcblq. 2,3,1
411+ icblq. 2,0,1
412+ icblq. 2,3,1
413+ mftmr 0,16
414+ mttmr 16,0
415Index: binutils-2.22/gas/testsuite/gas/ppc/e6500_nop.d
416===================================================================
417--- /dev/null 1970-01-01 00:00:00.000000000 +0000
418+++ binutils-2.22/gas/testsuite/gas/ppc/e6500_nop.d 2012-07-06 20:41:27.830780001 -0700
419@@ -0,0 +1,13 @@
420+#as: -mppc -me6500
421+#objdump: -dr -Me6500
422+#name: Power E6500 nop tests
423+
424+.*: +file format elf(32)?(64)?-powerpc.*
425+
426+Disassembly of section \.text:
427+
428+0+00 <start>:
429+ 0: 60 00 00 00 nop
430+ 4: 60 00 00 00 nop
431+ 8: 60 00 00 00 nop
432+ c: 60 00 00 00 nop
433Index: binutils-2.22/gas/testsuite/gas/ppc/e6500_nop.s
434===================================================================
435--- /dev/null 1970-01-01 00:00:00.000000000 +0000
436+++ binutils-2.22/gas/testsuite/gas/ppc/e6500_nop.s 2012-07-06 20:41:27.830780001 -0700
437@@ -0,0 +1,5 @@
438+# Power E6500 nop tests
439+ .section ".text"
440+start:
441+ nop
442+ .p2align 4,,15
443Index: binutils-2.22/gas/testsuite/gas/ppc/ppc.exp
444===================================================================
445--- binutils-2.22.orig/gas/testsuite/gas/ppc/ppc.exp 2010-02-07 17:59:38.000000000 -0800
446+++ binutils-2.22/gas/testsuite/gas/ppc/ppc.exp 2012-07-06 20:41:27.830780001 -0700
447@@ -42,6 +42,10 @@
448 run_list_test "range" "-a32"
449 run_dump_test "ppc750ps"
450 run_dump_test "e500mc"
451+ run_dump_test "e6500"
452+ run_dump_test "e500mc64_nop"
453+ run_dump_test "e5500_nop"
454+ run_dump_test "e6500_nop"
455 run_dump_test "a2"
456 run_dump_test "cell"
457 run_dump_test "common"
458Index: binutils-2.22/include/opcode/ppc.h
459===================================================================
460--- binutils-2.22.orig/include/opcode/ppc.h 2010-07-02 23:51:53.000000000 -0700
461+++ binutils-2.22/include/opcode/ppc.h 2012-07-06 20:41:27.830780001 -0700
462@@ -1,6 +1,6 @@
463 /* ppc.h -- Header file for PowerPC opcode table
464 Copyright 1994, 1995, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
465- 2007, 2008, 2009, 2010 Free Software Foundation, Inc.
466+ 2007, 2008, 2009, 2010, 2012 Free Software Foundation, Inc.
467 Written by Ian Lance Taylor, Cygnus Support
468
469 This file is part of GDB, GAS, and the GNU binutils.
470@@ -174,6 +174,15 @@
471 /* Opcode which is supported by the e500 family */
472 #define PPC_OPCODE_E500 0x100000000ull
473
474+/* Opcode is supported by Extended Altivec Vector Unit */
475+#define PPC_OPCODE_ALTIVEC2 0x200000000ull
476+
477+/* Opcode is supported by Power E6500 */
478+#define PPC_OPCODE_E6500 0x400000000ull
479+
480+/* Opcode is supported by Thread management APU */
481+#define PPC_OPCODE_TMR 0x800000000ull
482+
483 /* A macro to extract the major opcode from an instruction. */
484 #define PPC_OP(i) (((i) >> 26) & 0x3f)
485
486Index: binutils-2.22/opcodes/ppc-dis.c
487===================================================================
488--- binutils-2.22.orig/opcodes/ppc-dis.c 2012-07-06 20:40:40.000000000 -0700
489+++ binutils-2.22/opcodes/ppc-dis.c 2012-07-06 20:41:27.830780001 -0700
490@@ -1,6 +1,6 @@
491 /* ppc-dis.c -- Disassemble PowerPC instructions
492 Copyright 1994, 1995, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
493- 2008, 2009, 2010 Free Software Foundation, Inc.
494+ 2008, 2009, 2010, 2011, 2012 Free Software Foundation, Inc.
495 Written by Ian Lance Taylor, Cygnus Support
496
497 This file is part of the GNU opcodes library.
498@@ -114,6 +114,18 @@
499 | PPC_OPCODE_E500MC | PPC_OPCODE_64 | PPC_OPCODE_POWER5
500 | PPC_OPCODE_POWER6 | PPC_OPCODE_POWER7),
501 0 },
502+ { "e5500", (PPC_OPCODE_PPC | PPC_OPCODE_BOOKE | PPC_OPCODE_ISEL
503+ | PPC_OPCODE_PMR | PPC_OPCODE_CACHELCK | PPC_OPCODE_RFMCI
504+ | PPC_OPCODE_E500MC | PPC_OPCODE_64 | PPC_OPCODE_POWER4
505+ | PPC_OPCODE_POWER5 | PPC_OPCODE_POWER6
506+ | PPC_OPCODE_POWER7),
507+ 0 },
508+ { "e6500", (PPC_OPCODE_PPC | PPC_OPCODE_BOOKE | PPC_OPCODE_ISEL
509+ | PPC_OPCODE_PMR | PPC_OPCODE_CACHELCK | PPC_OPCODE_RFMCI
510+ | PPC_OPCODE_E500MC | PPC_OPCODE_64 | PPC_OPCODE_ALTIVEC
511+ | PPC_OPCODE_ALTIVEC2 | PPC_OPCODE_E6500 | PPC_OPCODE_POWER4
512+ | PPC_OPCODE_POWER5 | PPC_OPCODE_POWER6 | PPC_OPCODE_POWER7),
513+ 0 },
514 { "e500x2", (PPC_OPCODE_PPC | PPC_OPCODE_BOOKE | PPC_OPCODE_SPE
515 | PPC_OPCODE_ISEL | PPC_OPCODE_EFS | PPC_OPCODE_BRLOCK
516 | PPC_OPCODE_PMR | PPC_OPCODE_CACHELCK | PPC_OPCODE_RFMCI
517Index: binutils-2.22/opcodes/ppc-opc.c
518===================================================================
519--- binutils-2.22.orig/opcodes/ppc-opc.c 2011-11-21 01:29:40.000000000 -0800
520+++ binutils-2.22/opcodes/ppc-opc.c 2012-07-06 20:41:27.834780001 -0700
521@@ -1,6 +1,6 @@
522 /* ppc-opc.c -- PowerPC opcode list
523 Copyright 1994, 1995, 1996, 1997, 1998, 2000, 2001, 2002, 2003, 2004,
524- 2005, 2006, 2007, 2008, 2009, 2010, 2011
525+ 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012
526 Free Software Foundation, Inc.
527 Written by Ian Lance Taylor, Cygnus Support
528
529@@ -53,6 +53,7 @@
530 static long extract_boe (unsigned long, ppc_cpu_t, int *);
531 static unsigned long insert_fxm (unsigned long, long, ppc_cpu_t, const char **);
532 static long extract_fxm (unsigned long, ppc_cpu_t, int *);
533+static unsigned long insert_ls (unsigned long, long, ppc_cpu_t, const char **);
534 static unsigned long insert_mbe (unsigned long, long, ppc_cpu_t, const char **);
535 static long extract_mbe (unsigned long, ppc_cpu_t, int *);
536 static unsigned long insert_mb6 (unsigned long, long, ppc_cpu_t, const char **);
537@@ -477,6 +478,7 @@
538 lower 5 bits are stored in the upper 5 and vice- versa. */
539 #define SPR SISIGNOPT + 1
540 #define PMR SPR
541+#define TMR SPR
542 #define SPR_MASK (0x3ff << 11)
543 { 0x3ff, 11, insert_spr, extract_spr, 0 },
544
545@@ -499,8 +501,12 @@
546 #define T STRM
547 { 0x3, 21, NULL, NULL, 0 },
548
549+ /* The ESYNC field in an X (sync) form instruction. */
550+#define ESYNC STRM + 1
551+ { 0xf, 16, insert_ls, NULL, PPC_OPERAND_OPTIONAL },
552+
553 /* The SV field in a POWER SC form instruction. */
554-#define SV STRM + 1
555+#define SV ESYNC + 1
556 { 0x3fff, 2, NULL, NULL, 0 },
557
558 /* The TBR field in an XFX form instruction. This is like the SPR
559@@ -542,6 +548,7 @@
560
561 /* The UIMM field in a VX form instruction. */
562 #define UIMM SIMM + 1
563+#define DCTL UIMM
564 { 0x1f, 16, NULL, NULL, 0 },
565
566 /* The SHB field in a VA form instruction. */
567@@ -1027,6 +1034,32 @@
568 return mask;
569 }
570
571+/* The LS field in a sync instruction that accepts 2 operands
572+ Values 2 and 3 are reserved,
573+ must be treated as 0 for future compatibility
574+ Values 0 and 1 can be accepted, if field ESYNC is zero
575+ Otherwise L = complement of ESYNC-bit2 (1<<18) */
576+
577+static unsigned long
578+insert_ls (unsigned long insn,
579+ long value,
580+ ppc_cpu_t dialect ATTRIBUTE_UNUSED,
581+ const char **errmsg ATTRIBUTE_UNUSED)
582+{
583+ unsigned long ls;
584+
585+ ls = (insn >> 21) & 0x03;
586+ if (value == 0)
587+ {
588+ if (ls > 1)
589+ return insn & ~(0x3 << 21);
590+ return insn;
591+ }
592+ if ((value & 0x2) != 0)
593+ return (insn & ~(0x3 << 21)) | ((value & 0xf) << 16);
594+ return (insn & ~(0x3 << 21)) | (0x1 << 21) | ((value & 0xf) << 16);
595+}
596+
597 /* The MB and ME fields in an M form instruction expressed as a single
598 operand which is itself a bitmask. The extraction function always
599 marks it as invalid, since we never want to recognize an
600@@ -1795,6 +1828,9 @@
601 /* An X form sync instruction with everything filled in except the LS field. */
602 #define XSYNC_MASK (0xff9fffff)
603
604+/* An X form sync instruction with everything filled in except the L and E fields. */
605+#define XSYNCLE_MASK (0xff90ffff)
606+
607 /* An X_MASK, but with the EH bit clear. */
608 #define XEH_MASK (X_MASK & ~((unsigned long )1))
609
610@@ -1989,6 +2025,7 @@
611 #define PPC860 PPC
612 #define PPCPS PPC_OPCODE_PPCPS
613 #define PPCVEC PPC_OPCODE_ALTIVEC
614+#define PPCVEC2 PPC_OPCODE_ALTIVEC2
615 #define PPCVSX PPC_OPCODE_VSX
616 #define POWER PPC_OPCODE_POWER
617 #define POWER2 PPC_OPCODE_POWER | PPC_OPCODE_POWER2
618@@ -2007,6 +2044,7 @@
619 #define PPCEFS PPC_OPCODE_EFS
620 #define PPCBRLK PPC_OPCODE_BRLOCK
621 #define PPCPMR PPC_OPCODE_PMR
622+#define PPCTMR PPC_OPCODE_TMR
623 #define PPCCHLK PPC_OPCODE_CACHELCK
624 #define PPCRFMCI PPC_OPCODE_RFMCI
625 #define E500MC PPC_OPCODE_E500MC
626@@ -2014,6 +2052,7 @@
627 #define TITAN PPC_OPCODE_TITAN
628 #define MULHW PPC_OPCODE_405 | PPC_OPCODE_440 | TITAN
629 #define E500 PPC_OPCODE_E500
630+#define E6500 PPC_OPCODE_E6500
631
632 /* The opcode table.
633
634@@ -2179,12 +2218,14 @@
635 {"machhwsu", XO (4, 76,0,0),XO_MASK, MULHW, PPCNONE, {RT, RA, RB}},
636 {"machhwsu.", XO (4, 76,0,1),XO_MASK, MULHW, PPCNONE, {RT, RA, RB}},
637 {"ps_cmpo1", X (4, 96), X_MASK|(3<<21), PPCPS, PPCNONE, {BF, FRA, FRB}},
638+{"vabsdub", VX (4, 192), VX_MASK, PPCVEC2, PPCNONE, {VD, VA, VB}},
639 {"vcmpeqfp", VXR(4, 198,0), VXR_MASK, PPCVEC, PPCNONE, {VD, VA, VB}},
640 {"vpkuwus", VX (4, 206), VX_MASK, PPCVEC, PPCNONE, {VD, VA, VB}},
641 {"machhws", XO (4, 108,0,0),XO_MASK, MULHW, PPCNONE, {RT, RA, RB}},
642 {"machhws.", XO (4, 108,0,1),XO_MASK, MULHW, PPCNONE, {RT, RA, RB}},
643 {"nmachhws", XO (4, 110,0,0),XO_MASK, MULHW, PPCNONE, {RT, RA, RB}},
644 {"nmachhws.", XO (4, 110,0,1),XO_MASK, MULHW, PPCNONE, {RT, RA, RB}},
645+{"vabsduh", VX (4, 256), VX_MASK, PPCVEC2, PPCNONE, {VD, VA, VB}},
646 {"vmaxsb", VX (4, 258), VX_MASK, PPCVEC, PPCNONE, {VD, VA, VB}},
647 {"vslb", VX (4, 260), VX_MASK, PPCVEC, PPCNONE, {VD, VA, VB}},
648 {"vmulosb", VX (4, 264), VX_MASK, PPCVEC, PPCNONE, {VD, VA, VB}},
649@@ -2197,6 +2238,7 @@
650 {"mulchwu.", XRC(4, 136,1), X_MASK, MULHW, PPCNONE, {RT, RA, RB}},
651 {"macchwu", XO (4, 140,0,0),XO_MASK, MULHW, PPCNONE, {RT, RA, RB}},
652 {"macchwu.", XO (4, 140,0,1),XO_MASK, MULHW, PPCNONE, {RT, RA, RB}},
653+{"vabsduw", VX (4, 320), VX_MASK, PPCVEC2, PPCNONE, {VD, VA, VB}},
654 {"vmaxsh", VX (4, 322), VX_MASK, PPCVEC, PPCNONE, {VD, VA, VB}},
655 {"vslh", VX (4, 324), VX_MASK, PPCVEC, PPCNONE, {VD, VA, VB}},
656 {"vmulosh", VX (4, 328), VX_MASK, PPCVEC, PPCNONE, {VD, VA, VB}},
657@@ -3680,6 +3722,8 @@
658
659 {"lbepx", X(31,95), X_MASK, E500MC|PPCA2, PPCNONE, {RT, RA, RB}},
660
661+{"dni", XRC(31,97,1), XRB_MASK, E6500, PPCNONE, {DUI, DCTL}},
662+
663 {"lvx", X(31,103), X_MASK, PPCVEC, PPCNONE, {VD, RA, RB}},
664 {"lqfcmx", APU(31,103,0), APU_MASK, PPC405, PPCNONE, {FCRT, RA, RB}},
665
666@@ -3689,6 +3733,8 @@
667 {"mul", XO(31,107,0,0), XO_MASK, M601, PPCNONE, {RT, RA, RB}},
668 {"mul.", XO(31,107,0,1), XO_MASK, M601, PPCNONE, {RT, RA, RB}},
669
670+{"mvidsplt", X(31,110), X_MASK, PPCVEC2, PPCNONE, {VD, RA, RB}},
671+
672 {"mtsrdin", X(31,114), XRA_MASK, PPC64, PPCNONE, {RS, RB}},
673
674 {"lharx", X(31,116), XEH_MASK, POWER7, PPCNONE, {RT, RA0, RB, EH}},
675@@ -3723,7 +3769,9 @@
676 {"adde.", XO(31,138,0,1), XO_MASK, PPCCOM, PPCNONE, {RT, RA, RB}},
677 {"ae.", XO(31,138,0,1), XO_MASK, PWRCOM, PPCNONE, {RT, RA, RB}},
678
679-{"dcbtstlse", X(31,142), X_MASK, PPCCHLK, PPCNONE, {CT, RA, RB}},
680+{"mviwsplt", X(31,142), X_MASK, PPCVEC2, PPCNONE, {VD, RA, RB}},
681+
682+{"dcbtstlse", X(31,142), X_MASK, PPCCHLK, E500MC, {CT, RA, RB}},
683
684 {"mtcr", XFXM(31,144,0xff,0), XRARB_MASK, COM, PPCNONE, {RS}},
685 {"mtcrf", XFXM(31,144,0,0), XFXFXM_MASK, COM, PPCNONE, {FXM, RS}},
686@@ -3760,7 +3808,7 @@
687 {"stvehx", X(31,167), X_MASK, PPCVEC, PPCNONE, {VS, RA, RB}},
688 {"sthfcmx", APU(31,167,0), APU_MASK, PPC405, PPCNONE, {FCRT, RA, RB}},
689
690-{"dcbtlse", X(31,174), X_MASK, PPCCHLK, PPCNONE, {CT, RA, RB}},
691+{"dcbtlse", X(31,174), X_MASK, PPCCHLK, E500MC, {CT, RA, RB}},
692
693 {"mtmsrd", X(31,178), XRLARB_MASK, PPC64, PPCNONE, {RS, A_L}},
694
695@@ -3778,6 +3826,8 @@
696
697 {"prtyd", X(31,186), XRB_MASK, POWER6|PPCA2, PPCNONE, {RA, RS}},
698
699+{"icblq.", XRC(31,198,1), X_MASK, E6500, PPCNONE, {CT, RA0, RB}},
700+
701 {"stvewx", X(31,199), X_MASK, PPCVEC, PPCNONE, {VS, RA, RB}},
702 {"stwfcmx", APU(31,199,0), APU_MASK, PPC405, PPCNONE, {FCRT, RA, RB}},
703
704@@ -3855,8 +3905,12 @@
705 {"mfdcrx", X(31,259), X_MASK, BOOKE|PPCA2|PPC476, TITAN, {RS, RA}},
706 {"mfdcrx.", XRC(31,259,1), X_MASK, PPCA2, PPCNONE, {RS, RA}},
707
708+{"lvexbx", X(31,261), X_MASK, PPCVEC2, PPCNONE, {VD, RA0, RB}},
709+
710 {"icbt", X(31,262), XRT_MASK, PPC403, PPCNONE, {RA, RB}},
711
712+{"lvepxl", X(31,263), X_MASK, PPCVEC2, PPCNONE, {VD, RA0, RB}},
713+
714 {"ldfcmx", APU(31,263,0), APU_MASK, PPC405, PPCNONE, {FCRT, RA, RB}},
715 {"doz", XO(31,264,0,0), XO_MASK, M601, PPCNONE, {RT, RA, RB}},
716 {"doz.", XO(31,264,0,1), XO_MASK, M601, PPCNONE, {RT, RA, RB}},
717@@ -3890,6 +3944,9 @@
718
719 {"mfdcrux", X(31,291), X_MASK, PPC464, PPCNONE, {RS, RA}},
720
721+{"lvexhx", X(31,293), X_MASK, PPCVEC2, PPCNONE, {VD, RA0, RB}},
722+{"lvepx", X(31,295), X_MASK, PPCVEC2, PPCNONE, {VD, RA0, RB}},
723+
724 {"tlbie", X(31,306), XRTLRA_MASK, PPC, TITAN, {RB, L}},
725 {"tlbi", X(31,306), XRT_MASK, POWER, PPCNONE, {RA0, RB}},
726
727@@ -3941,6 +3998,8 @@
728 {"mfdcr", X(31,323), X_MASK, PPC403|BOOKE|PPCA2|PPC476, TITAN, {RT, SPR}},
729 {"mfdcr.", XRC(31,323,1), X_MASK, PPCA2, PPCNONE, {RT, SPR}},
730
731+{"lvexwx", X(31,325), X_MASK, PPCVEC2, PPCNONE, {VD, RA0, RB}},
732+
733 {"dcread", X(31,326), X_MASK, PPC476|TITAN, PPCNONE, {RT, RA, RB}},
734
735 {"div", XO(31,331,0,0), XO_MASK, M601, PPCNONE, {RT, RA, RB}},
736@@ -3949,6 +4008,7 @@
737 {"lxvdsx", X(31,332), XX1_MASK, PPCVSX, PPCNONE, {XT6, RA, RB}},
738
739 {"mfpmr", X(31,334), X_MASK, PPCPMR|PPCE300, PPCNONE, {RT, PMR}},
740+{"mftmr", X(31,366), X_MASK, PPCTMR|E6500, PPCNONE, {RT, TMR}},
741
742 {"mfmq", XSPR(31,339, 0), XSPR_MASK, M601, PPCNONE, {RT}},
743 {"mfxer", XSPR(31,339, 1), XSPR_MASK, COM, PPCNONE, {RT}},
744@@ -4179,6 +4239,8 @@
745 {"mtdcrx", X(31,387), X_MASK, BOOKE|PPCA2|PPC476, TITAN, {RA, RS}},
746 {"mtdcrx.", XRC(31,387,1), X_MASK, PPCA2, PPCNONE, {RA, RS}},
747
748+{"stvexbx", X(31,389), X_MASK, PPCVEC2, PPCNONE, {VS, RA0, RB}},
749+
750 {"dcblc", X(31,390), X_MASK, PPCCHLK|PPC476|TITAN, PPCNONE, {CT, RA, RB}},
751 {"stdfcmx", APU(31,391,0), APU_MASK, PPC405, PPCNONE, {FCRT, RA, RB}},
752
753@@ -4187,7 +4249,7 @@
754 {"divweu", XO(31,395,0,0), XO_MASK, POWER7|PPCA2, PPCNONE, {RT, RA, RB}},
755 {"divweu.", XO(31,395,0,1), XO_MASK, POWER7|PPCA2, PPCNONE, {RT, RA, RB}},
756
757-{"dcblce", X(31,398), X_MASK, PPCCHLK, PPCNONE, {CT, RA, RB}},
758+{"dcblce", X(31,398), X_MASK, PPCCHLK, E500MC, {CT, RA, RB}},
759
760 {"slbmte", X(31,402), XRA_MASK, PPC64, PPCNONE, {RS, RB}},
761
762@@ -4203,6 +4265,10 @@
763
764 {"mtdcrux", X(31,419), X_MASK, PPC464, PPCNONE, {RA, RS}},
765
766+{"stvexhx", X(31,421), X_MASK, PPCVEC2, PPCNONE, {VS, RA0, RB}},
767+
768+{"dcblq.", XRC(31,422,1), X_MASK, E6500, PPCNONE, {CT, RA0, RB}},
769+
770 {"divde", XO(31,425,0,0), XO_MASK, POWER7|PPCA2, PPCNONE, {RT, RA, RB}},
771 {"divde.", XO(31,425,0,1), XO_MASK, POWER7|PPCA2, PPCNONE, {RT, RA, RB}},
772 {"divwe", XO(31,427,0,0), XO_MASK, POWER7|PPCA2, PPCNONE, {RT, RA, RB}},
773@@ -4216,6 +4282,8 @@
774
775 {"mdors", 0x7f9ce378, 0xffffffff, E500MC, PPCNONE, {0}},
776
777+{"miso", 0x7f5ad378, 0xffffffff, E6500, PPCNONE, {0}},
778+
779 {"mr", XRC(31,444,0), X_MASK, COM, PPCNONE, {RA, RS, RBS}},
780 {"or", XRC(31,444,0), X_MASK, COM, PPCNONE, {RA, RS, RB}},
781 {"mr.", XRC(31,444,1), X_MASK, COM, PPCNONE, {RA, RS, RBS}},
782@@ -4258,6 +4326,8 @@
783 {"mtdcr", X(31,451), X_MASK, PPC403|BOOKE|PPCA2|PPC476, TITAN, {SPR, RS}},
784 {"mtdcr.", XRC(31,451,1), X_MASK, PPCA2, PPCNONE, {SPR, RS}},
785
786+{"stvexwx", X(31,453), X_MASK, PPCVEC2, PPCNONE, {VS, RA0, RB}},
787+
788 {"dccci", X(31,454), XRT_MASK, PPC403|PPC440|TITAN|PPCA2, PPCNONE, {RAOPT, RBOPT}},
789 {"dci", X(31,454), XRARB_MASK, PPCA2|PPC476, PPCNONE, {CT}},
790
791@@ -4268,6 +4338,7 @@
792 {"divwu.", XO(31,459,0,1), XO_MASK, PPC, PPCNONE, {RT, RA, RB}},
793
794 {"mtpmr", X(31,462), X_MASK, PPCPMR|PPCE300, PPCNONE, {PMR, RS}},
795+{"mttmr", X(31,494), X_MASK, PPCTMR|E6500, PPCNONE, {TMR, RS}},
796
797 {"mtmq", XSPR(31,467, 0), XSPR_MASK, M601, PPCNONE, {RS}},
798 {"mtxer", XSPR(31,467, 1), XSPR_MASK, COM, PPCNONE, {RS}},
799@@ -4453,7 +4524,7 @@
800 {"divw", XO(31,491,0,0), XO_MASK, PPC, PPCNONE, {RT, RA, RB}},
801 {"divw.", XO(31,491,0,1), XO_MASK, PPC, PPCNONE, {RT, RA, RB}},
802
803-{"icbtlse", X(31,494), X_MASK, PPCCHLK, PPCNONE, {CT, RA, RB}},
804+{"icbtlse", X(31,494), X_MASK, PPCCHLK, E500MC, {CT, RA, RB}},
805
806 {"slbia", X(31,498), 0xffffffff, PPC64, PPCNONE, {0}},
807
808@@ -4512,6 +4583,8 @@
809
810 {"lhdx", X(31,547), X_MASK, E500MC, PPCNONE, {RT, RA, RB}},
811
812+{"lvtrx", X(31,549), X_MASK, PPCVEC2, PPCNONE, {VD, RA0, RB}},
813+
814 {"bbelr", X(31,550), X_MASK, PPCBRLK, PPCNONE, {0}},
815
816 {"lvrx", X(31,551), X_MASK, CELL, PPCNONE, {VD, RA0, RB}},
817@@ -4528,6 +4601,8 @@
818
819 {"lwdx", X(31,579), X_MASK, E500MC, PPCNONE, {RT, RA, RB}},
820
821+{"lvtlx", X(31,581), X_MASK, PPCVEC2, PPCNONE, {VD, RA0, RB}},
822+
823 {"lwfcmux", APU(31,583,0), APU_MASK, PPC405, PPCNONE, {FCRT, RA, RB}},
824
825 {"lxsdx", X(31,588), XX1_MASK, PPCVSX, PPCNONE, {XT6, RA, RB}},
826@@ -4539,9 +4614,10 @@
827
828 {"lwsync", XSYNC(31,598,1), 0xffffffff, PPC, E500, {0}},
829 {"ptesync", XSYNC(31,598,2), 0xffffffff, PPC64, PPCNONE, {0}},
830+{"sync", X(31,598), XSYNCLE_MASK,E6500, PPCNONE, {LS, ESYNC}},
831 {"sync", X(31,598), XSYNC_MASK, PPCCOM, BOOKE|PPC476, {LS}},
832 {"msync", X(31,598), 0xffffffff, BOOKE|PPCA2|PPC476, PPCNONE, {0}},
833-{"sync", X(31,598), 0xffffffff, BOOKE|PPC476, PPCNONE, {0}},
834+{"sync", X(31,598), 0xffffffff, BOOKE|PPC476, E6500, {0}},
835 {"lwsync", X(31,598), 0xffffffff, E500, PPCNONE, {0}},
836 {"dcs", X(31,598), 0xffffffff, PWRCOM, PPCNONE, {0}},
837
838@@ -4552,6 +4628,8 @@
839
840 {"lddx", X(31,611), X_MASK, E500MC, PPCNONE, {RT, RA, RB}},
841
842+{"lvswx", X(31,613), X_MASK, PPCVEC2, PPCNONE, {VD, RA0, RB}},
843+
844 {"lqfcmux", APU(31,615,0), APU_MASK, PPC405, PPCNONE, {FCRT, RA, RB}},
845
846 {"nego", XO(31,104,1,0), XORB_MASK, COM, PPCNONE, {RT, RA}},
847@@ -4601,6 +4679,8 @@
848
849 {"sthdx", X(31,675), X_MASK, E500MC, PPCNONE, {RS, RA, RB}},
850
851+{"stvfrx", X(31,677), X_MASK, PPCVEC2, PPCNONE, {VS, RA0, RB}},
852+
853 {"stvrx", X(31,679), X_MASK, CELL, PPCNONE, {VS, RA0, RB}},
854 {"sthfcmux", APU(31,679,0), APU_MASK, PPC405, PPCNONE, {FCRT, RA, RB}},
855
856@@ -4613,6 +4693,8 @@
857
858 {"stwdx", X(31,707), X_MASK, E500MC, PPCNONE, {RS, RA, RB}},
859
860+{"stvflx", X(31,709), X_MASK, PPCVEC2, PPCNONE, {VS, RA0, RB}},
861+
862 {"stwfcmux", APU(31,711,0), APU_MASK, PPC405, PPCNONE, {FCRT, RA, RB}},
863
864 {"stxsdx", X(31,716), XX1_MASK, PPCVSX, PPCNONE, {XS6, RA, RB}},
865@@ -4645,6 +4727,8 @@
866
867 {"stddx", X(31,739), X_MASK, E500MC, PPCNONE, {RS, RA, RB}},
868
869+{"stvswx", X(31,741), X_MASK, PPCVEC2, PPCNONE, {VS, RA0, RB}},
870+
871 {"stqfcmux", APU(31,743,0), APU_MASK, PPC405, PPCNONE, {FCRT, RA, RB}},
872
873 {"subfmeo", XO(31,232,1,0), XORB_MASK, PPCCOM, PPCNONE, {RT, RA}},
874@@ -4673,6 +4757,8 @@
875 {"srliq", XRC(31,760,0), X_MASK, M601, PPCNONE, {RA, RS, SH}},
876 {"srliq.", XRC(31,760,1), X_MASK, M601, PPCNONE, {RA, RS, SH}},
877
878+{"lvsm", X(31,773), X_MASK, PPCVEC2, PPCNONE, {VD, RA0, RB}},
879+{"stvepxl", X(31,775), X_MASK, PPCVEC2, PPCNONE, {VS, RA0, RB}},
880 {"lvlxl", X(31,775), X_MASK, CELL, PPCNONE, {VD, RA0, RB}},
881 {"ldfcmux", APU(31,775,0), APU_MASK, PPC405, PPCNONE, {FCRT, RA, RB}},
882
883@@ -4705,6 +4791,8 @@
884
885 {"lfddx", X(31,803), X_MASK, E500MC, PPCNONE, {FRT, RA, RB}},
886
887+{"lvtrxl", X(31,805), X_MASK, PPCVEC2, PPCNONE, {VD, RA0, RB}},
888+{"stvepx", X(31,807), X_MASK, PPCVEC2, PPCNONE, {VS, RA0, RB}},
889 {"lvrxl", X(31,807), X_MASK, CELL, PPCNONE, {VD, RA0, RB}},
890
891 {"rac", X(31,818), X_MASK, M601, PPCNONE, {RT, RA, RB}},
892@@ -4725,6 +4813,8 @@
893 {"sradi", XS(31,413,0), XS_MASK, PPC64, PPCNONE, {RA, RS, SH6}},
894 {"sradi.", XS(31,413,1), XS_MASK, PPC64, PPCNONE, {RA, RS, SH6}},
895
896+{"lvtlxl", X(31,837), X_MASK, PPCVEC2, PPCNONE, {VD, RA0, RB}},
897+
898 {"divo", XO(31,331,1,0), XO_MASK, M601, PPCNONE, {RT, RA, RB}},
899 {"divo.", XO(31,331,1,1), XO_MASK, M601, PPCNONE, {RT, RA, RB}},
900
901@@ -4743,6 +4833,8 @@
902
903 {"lfiwax", X(31,855), X_MASK, POWER6|PPCA2|PPC476, PPCNONE, {FRT, RA0, RB}},
904
905+{"lvswxl", X(31,869), X_MASK, PPCVEC2, PPCNONE, {VD, RA0, RB}},
906+
907 {"abso", XO(31,360,1,0), XORB_MASK, M601, PPCNONE, {RT, RA}},
908 {"abso.", XO(31,360,1,1), XORB_MASK, M601, PPCNONE, {RT, RA}},
909
910@@ -4788,6 +4880,8 @@
911
912 {"stfddx", X(31,931), X_MASK, E500MC, PPCNONE, {FRS, RA, RB}},
913
914+{"stvfrxl", X(31,933), X_MASK, PPCVEC2, PPCNONE, {VS, RA0, RB}},
915+
916 {"wclrone", XOPL2(31,934,2),XRT_MASK, PPCA2, PPCNONE, {RA0, RB}},
917 {"wclrall", X(31,934), XRARB_MASK, PPCA2, PPCNONE, {L}},
918 {"wclr", X(31,934), X_MASK, PPCA2, PPCNONE, {L, RA0, RB}},
919@@ -4816,6 +4910,8 @@
920 {"extsb", XRC(31,954,0), XRB_MASK, PPC, PPCNONE, {RA, RS}},
921 {"extsb.", XRC(31,954,1), XRB_MASK, PPC, PPCNONE, {RA, RS}},
922
923+{"stvflxl", X(31,965), X_MASK, PPCVEC2, PPCNONE, {VS, RA0, RB}},
924+
925 {"iccci", X(31,966), XRT_MASK, PPC403|PPC440|TITAN|PPCA2, PPCNONE, {RAOPT, RBOPT}},
926 {"ici", X(31,966), XRARB_MASK, PPCA2|PPC476, PPCNONE, {CT}},
927
928@@ -4843,6 +4939,8 @@
929
930 {"icbiep", XRT(31,991,0), XRT_MASK, E500MC|PPCA2, PPCNONE, {RA, RB}},
931
932+{"stvswxl", X(31,997), X_MASK, PPCVEC2, PPCNONE, {VS, RA0, RB}},
933+
934 {"icread", X(31,998), XRT_MASK, PPC403|PPC440|PPC476|TITAN, PPCNONE, {RA, RB}},
935
936 {"nabso", XO(31,488,1,0), XORB_MASK, M601, PPCNONE, {RT, RA}},
diff --git a/meta/recipes-devtools/binutils/binutils/binutils-pr12366.patch b/meta/recipes-devtools/binutils/binutils/binutils-pr12366.patch
deleted file mode 100644
index c11a802941..0000000000
--- a/meta/recipes-devtools/binutils/binutils/binutils-pr12366.patch
+++ /dev/null
@@ -1,428 +0,0 @@
1This is backport from 2.21 branch
2
3Upstream-Status: Backport
4
5Signed-off-by: Khem Raj <raj.khem@gmail.com>
6
7
8commit 946593d19f203b02efd45b5102dd2787d9418e24
9Author: H.J. Lu <hjl.tools@gmail.com>
10Date: Wed May 25 17:41:32 2011 +0000
11
12 Handle STT_GNU_IFUNC symols when building shared library.
13
14 bfd/
15
16 2012-05-25 H.J. Lu <hongjiu.lu@intel.com>
17
18 Backport from mainline
19 2012-01-06 H.J. Lu <hongjiu.lu@intel.com>
20
21 PR ld/12366
22 PR ld/12371
23 * elf-ifunc.c (_bfd_elf_allocate_ifunc_dyn_relocs): Properly
24 handle symbols marked with regular reference, but not non-GOT
25 reference when building shared library.
26
27 * elf32-i386.c (elf_i386_gc_sweep_hook): Properly handle
28 local and global STT_GNU_IFUNC symols when building shared
29 library.
30 * elf64-x86-64.c (elf_x86_64_gc_sweep_hook): Likewise.
31
32 ld/testsuite/
33
34 2012-05-25 H.J. Lu <hongjiu.lu@intel.com>
35
36 Backport from mainline
37 2012-01-06 H.J. Lu <hongjiu.lu@intel.com>
38
39 PR ld/12366
40 PR ld/12371
41 * ld-ifunc/ifunc-10-i386.s: Add more tests.
42 * ld-ifunc/ifunc-10-x86-64.s: Likewise.
43 * ld-ifunc/ifunc-11-i386.s: Likewise.
44 * ld-ifunc/ifunc-11-x86-64.s: Likewise.
45
46 * ld-ifunc/ifunc-12-i386.d: New.
47 * ld-ifunc/ifunc-12-i386.s: Likewise.
48 * ld-ifunc/ifunc-12-x86-64.d: Likewise.
49 * ld-ifunc/ifunc-12-x86-64.s: Likewise.
50 * ld-ifunc/ifunc-13-i386.d: Likewise.
51 * ld-ifunc/ifunc-13-x86-64.d: Likewise.
52 * ld-ifunc/ifunc-13a-i386.s: Likewise.
53 * ld-ifunc/ifunc-13a-x86-64.s: Likewise.
54 * ld-ifunc/ifunc-13b-i386.s: Likewise.
55 * ld-ifunc/ifunc-13b-x86-64.s: Likewise.
56
57Index: binutils-2.21/bfd/elf-ifunc.c
58===================================================================
59--- binutils-2.21.orig/bfd/elf-ifunc.c 2010-07-13 09:59:10.000000000 -0700
60+++ binutils-2.21/bfd/elf-ifunc.c 2011-06-21 16:33:40.751884107 -0700
61@@ -190,10 +190,29 @@
62 /* Support garbage collection against STT_GNU_IFUNC symbols. */
63 if (h->plt.refcount <= 0 && h->got.refcount <= 0)
64 {
65- h->got = htab->init_got_offset;
66- h->plt = htab->init_plt_offset;
67- *head = NULL;
68- return TRUE;
69+ /* When building shared library, we need to handle the case
70+ where it is marked with regular reference, but not non-GOT
71+ reference. It may happen if we didn't see STT_GNU_IFUNC
72+ symbol at the time when checking relocations. */
73+ bfd_size_type count = 0;
74+
75+ if (info->shared
76+ && !h->non_got_ref
77+ && h->ref_regular)
78+ {
79+ for (p = *head; p != NULL; p = p->next)
80+ count += p->count;
81+ if (count != 0)
82+ h->non_got_ref = 1;
83+ }
84+
85+ if (count == 0)
86+ {
87+ h->got = htab->init_got_offset;
88+ h->plt = htab->init_plt_offset;
89+ *head = NULL;
90+ return TRUE;
91+ }
92 }
93
94 /* Return and discard space for dynamic relocations against it if
95Index: binutils-2.21/bfd/elf32-i386.c
96===================================================================
97--- binutils-2.21.orig/bfd/elf32-i386.c 2010-10-21 05:29:02.000000000 -0700
98+++ binutils-2.21/bfd/elf32-i386.c 2011-06-21 16:33:40.761884138 -0700
99@@ -1807,23 +1807,10 @@
100 r_symndx = ELF32_R_SYM (rel->r_info);
101 if (r_symndx >= symtab_hdr->sh_info)
102 {
103- struct elf_i386_link_hash_entry *eh;
104- struct elf_dyn_relocs **pp;
105- struct elf_dyn_relocs *p;
106-
107 h = sym_hashes[r_symndx - symtab_hdr->sh_info];
108 while (h->root.type == bfd_link_hash_indirect
109 || h->root.type == bfd_link_hash_warning)
110 h = (struct elf_link_hash_entry *) h->root.u.i.link;
111- eh = (struct elf_i386_link_hash_entry *) h;
112-
113- for (pp = &eh->dyn_relocs; (p = *pp) != NULL; pp = &p->next)
114- if (p->sec == sec)
115- {
116- /* Everything must go for SEC. */
117- *pp = p->next;
118- break;
119- }
120 }
121 else
122 {
123@@ -1843,6 +1830,22 @@
124 }
125 }
126
127+ if (h)
128+ {
129+ struct elf_i386_link_hash_entry *eh;
130+ struct elf_dyn_relocs **pp;
131+ struct elf_dyn_relocs *p;
132+
133+ eh = (struct elf_i386_link_hash_entry *) h;
134+ for (pp = &eh->dyn_relocs; (p = *pp) != NULL; pp = &p->next)
135+ if (p->sec == sec)
136+ {
137+ /* Everything must go for SEC. */
138+ *pp = p->next;
139+ break;
140+ }
141+ }
142+
143 r_type = ELF32_R_TYPE (rel->r_info);
144 if (! elf_i386_tls_transition (info, abfd, sec, NULL,
145 symtab_hdr, sym_hashes,
146@@ -1883,7 +1886,8 @@
147
148 case R_386_32:
149 case R_386_PC32:
150- if (info->shared)
151+ if (info->shared
152+ && (h == NULL || h->type != STT_GNU_IFUNC))
153 break;
154 /* Fall through */
155
156Index: binutils-2.21/bfd/elf64-x86-64.c
157===================================================================
158--- binutils-2.21.orig/bfd/elf64-x86-64.c 2010-10-21 05:29:02.000000000 -0700
159+++ binutils-2.21/bfd/elf64-x86-64.c 2011-06-21 16:33:40.761884138 -0700
160@@ -1645,23 +1645,10 @@
161 r_symndx = ELF64_R_SYM (rel->r_info);
162 if (r_symndx >= symtab_hdr->sh_info)
163 {
164- struct elf64_x86_64_link_hash_entry *eh;
165- struct elf_dyn_relocs **pp;
166- struct elf_dyn_relocs *p;
167-
168 h = sym_hashes[r_symndx - symtab_hdr->sh_info];
169 while (h->root.type == bfd_link_hash_indirect
170 || h->root.type == bfd_link_hash_warning)
171 h = (struct elf_link_hash_entry *) h->root.u.i.link;
172- eh = (struct elf64_x86_64_link_hash_entry *) h;
173-
174- for (pp = &eh->dyn_relocs; (p = *pp) != NULL; pp = &p->next)
175- if (p->sec == sec)
176- {
177- /* Everything must go for SEC. */
178- *pp = p->next;
179- break;
180- }
181 }
182 else
183 {
184@@ -1682,7 +1669,24 @@
185 }
186 }
187
188- r_type = ELF64_R_TYPE (rel->r_info);
189+ if (h)
190+ {
191+ struct elf64_x86_64_link_hash_entry *eh;
192+ struct elf_dyn_relocs **pp;
193+ struct elf_dyn_relocs *p;
194+
195+ eh = (struct elf64_x86_64_link_hash_entry *) h;
196+
197+ for (pp = &eh->dyn_relocs; (p = *pp) != NULL; pp = &p->next)
198+ if (p->sec == sec)
199+ {
200+ /* Everything must go for SEC. */
201+ *pp = p->next;
202+ break;
203+ }
204+ }
205+
206+ r_type = ELF32_R_TYPE (rel->r_info);
207 if (! elf64_x86_64_tls_transition (info, abfd, sec, NULL,
208 symtab_hdr, sym_hashes,
209 &r_type, GOT_UNKNOWN,
210@@ -1733,7 +1737,8 @@
211 case R_X86_64_PC16:
212 case R_X86_64_PC32:
213 case R_X86_64_PC64:
214- if (info->shared)
215+ if (info->shared
216+ && (h == NULL || h->type != STT_GNU_IFUNC))
217 break;
218 /* Fall thru */
219
220Index: binutils-2.21/ld/testsuite/ld-ifunc/ifunc-10-i386.s
221===================================================================
222--- binutils-2.21.orig/ld/testsuite/ld-ifunc/ifunc-10-i386.s 2010-07-13 09:59:14.000000000 -0700
223+++ binutils-2.21/ld/testsuite/ld-ifunc/ifunc-10-i386.s 2011-06-21 16:36:36.832142380 -0700
224@@ -6,6 +6,8 @@
225 movl ifunc@GOTOFF(%ecx), %eax
226 call ifunc@PLT
227 call ifunc
228+ movl xxx@GOT(%ecx), %eax
229+ movl xxx, %eax
230 ret
231
232 .section .text.bar,"ax",@progbits
233@@ -18,3 +20,7 @@
234 .type ifunc, @gnu_indirect_function
235 ifunc:
236 ret
237+
238+ .section .data.foo,"aw",@progbits
239+xxx:
240+ .long ifunc
241Index: binutils-2.21/ld/testsuite/ld-ifunc/ifunc-10-x86-64.s
242===================================================================
243--- binutils-2.21.orig/ld/testsuite/ld-ifunc/ifunc-10-x86-64.s 2010-07-13 09:59:14.000000000 -0700
244+++ binutils-2.21/ld/testsuite/ld-ifunc/ifunc-10-x86-64.s 2011-06-21 16:36:36.822142371 -0700
245@@ -6,6 +6,7 @@
246 movl ifunc(%rip), %eax
247 call ifunc@PLT
248 call ifunc
249+ movl xxx(%rip), %eax
250 ret
251
252 .section .text.bar,"ax",@progbits
253@@ -18,3 +19,7 @@
254 .type ifunc, @gnu_indirect_function
255 ifunc:
256 ret
257+
258+ .section .data.foo,"aw",@progbits
259+xxx:
260+ .quad ifunc
261Index: binutils-2.21/ld/testsuite/ld-ifunc/ifunc-11-i386.s
262===================================================================
263--- binutils-2.21.orig/ld/testsuite/ld-ifunc/ifunc-11-i386.s 2010-07-13 09:59:14.000000000 -0700
264+++ binutils-2.21/ld/testsuite/ld-ifunc/ifunc-11-i386.s 2011-06-21 16:36:36.832142380 -0700
265@@ -3,9 +3,11 @@
266 foo:
267 .global foo
268 movl ifunc@GOT(%ecx), %eax
269- movl ifunc@GOTOFF(%ecx), %eax
270+ movl ifunc@GOTOFF(%ecx), %eax
271 call ifunc@PLT
272 call ifunc
273+ movl xxx@GOT(%ecx), %eax
274+ movl xxx, %eax
275 ret
276
277 .section .text.bar,"ax",@progbits
278@@ -16,6 +18,10 @@
279
280 .section .text.ifunc,"ax",@progbits
281 .type ifunc, @gnu_indirect_function
282- .global ifunc
283+ .global ifunc
284 ifunc:
285 ret
286+
287+ .section .data.foo,"aw",@progbits
288+xxx:
289+ .long ifunc
290Index: binutils-2.21/ld/testsuite/ld-ifunc/ifunc-11-x86-64.s
291===================================================================
292--- binutils-2.21.orig/ld/testsuite/ld-ifunc/ifunc-11-x86-64.s 2010-07-13 09:59:14.000000000 -0700
293+++ binutils-2.21/ld/testsuite/ld-ifunc/ifunc-11-x86-64.s 2011-06-21 16:36:36.822142371 -0700
294@@ -6,6 +6,7 @@
295 movl ifunc(%rip), %eax
296 call ifunc@PLT
297 call ifunc
298+ movl xxx(%rip), %eax
299 ret
300
301 .section .text.bar,"ax",@progbits
302@@ -19,3 +20,7 @@
303 .global ifunc
304 ifunc:
305 ret
306+
307+ .section .data.foo,"aw",@progbits
308+xxx:
309+ .quad ifunc
310Index: binutils-2.21/ld/testsuite/ld-ifunc/ifunc-12-i386.d
311===================================================================
312--- /dev/null 1970-01-01 00:00:00.000000000 +0000
313+++ binutils-2.21/ld/testsuite/ld-ifunc/ifunc-12-i386.d 2011-06-21 16:33:40.761884138 -0700
314@@ -0,0 +1,6 @@
315+#ld: -shared -m elf_i386 -e bar --gc-sections
316+#as: --32
317+#readelf: -r --wide
318+#target: x86_64-*-* i?86-*-*
319+
320+There are no relocations in this file.
321Index: binutils-2.21/ld/testsuite/ld-ifunc/ifunc-12-x86-64.d
322===================================================================
323--- /dev/null 1970-01-01 00:00:00.000000000 +0000
324+++ binutils-2.21/ld/testsuite/ld-ifunc/ifunc-12-x86-64.d 2011-06-21 16:33:40.761884138 -0700
325@@ -0,0 +1,6 @@
326+#ld: -shared -m elf_x86_64 -e bar --gc-sections
327+#as: --64
328+#readelf: -r --wide
329+#target: x86_64-*-*
330+
331+There are no relocations in this file.
332Index: binutils-2.21/ld/testsuite/ld-ifunc/ifunc-13-i386.d
333===================================================================
334--- /dev/null 1970-01-01 00:00:00.000000000 +0000
335+++ binutils-2.21/ld/testsuite/ld-ifunc/ifunc-13-i386.d 2011-06-21 16:33:40.761884138 -0700
336@@ -0,0 +1,19 @@
337+#source: ifunc-13a-i386.s
338+#source: ifunc-13b-i386.s
339+#ld: -shared -m elf_i386 -z nocombreloc
340+#as: --32
341+#readelf: -r --wide
342+#target: x86_64-*-* i?86-*-*
343+
344+Relocation section '.rel.got' at .*
345+[ ]+Offset[ ]+Info[ ]+Type[ ]+.*
346+#...
347+[0-9a-f]+[ ]+[0-9a-f]+[ ]+R_386_GLOB_DAT[ ]+ifunc\(\)[ ]+ifunc
348+#...
349+Relocation section '.rel.ifunc' at .*
350+[ ]+Offset[ ]+Info[ ]+Type[ ]+.*
351+[0-9a-f]+[ ]+[0-9a-f]+[ ]+R_386_32[ ]+ifunc\(\)[ ]+ifunc
352+#...
353+Relocation section '.rel.plt' at .*
354+[ ]+Offset[ ]+Info[ ]+Type[ ]+.*
355+[0-9a-f]+[ ]+[0-9a-f]+[ ]+R_386_JUMP_SLOT[ ]+ifunc\(\)[ ]+ifunc
356Index: binutils-2.21/ld/testsuite/ld-ifunc/ifunc-13-x86-64.d
357===================================================================
358--- /dev/null 1970-01-01 00:00:00.000000000 +0000
359+++ binutils-2.21/ld/testsuite/ld-ifunc/ifunc-13-x86-64.d 2011-06-21 16:33:40.761884138 -0700
360@@ -0,0 +1,18 @@
361+#source: ifunc-13a-x86-64.s
362+#source: ifunc-13b-x86-64.s
363+#ld: -shared -m elf_x86_64 -z nocombreloc
364+#as: --64
365+#readelf: -r --wide
366+#target: x86_64-*-*
367+
368+Relocation section '.rela.got' at .*
369+[ ]+Offset[ ]+Info[ ]+Type[ ]+.*
370+[0-9a-f]+[ ]+[0-9a-f]+[ ]+R_X86_64_GLOB_DAT[ ]+ifunc\(\)[ ]+ifunc \+ 0
371+#...
372+Relocation section '.rela.ifunc' at .*
373+[ ]+Offset[ ]+Info[ ]+Type[ ]+.*
374+[0-9a-f]+[ ]+[0-9a-f]+[ ]+R_X86_64_64[ ]+ifunc\(\)[ ]+ifunc \+ 0
375+#...
376+Relocation section '.rela.plt' at .*
377+[ ]+Offset[ ]+Info[ ]+Type[ ]+.*
378+[0-9a-f]+[ ]+[0-9a-f]+[ ]+R_X86_64_JUMP_SLOT[ ]+ifunc\(\)[ ]+ifunc \+ 0
379Index: binutils-2.21/ld/testsuite/ld-ifunc/ifunc-13a-i386.s
380===================================================================
381--- /dev/null 1970-01-01 00:00:00.000000000 +0000
382+++ binutils-2.21/ld/testsuite/ld-ifunc/ifunc-13a-i386.s 2011-06-21 16:36:36.822142371 -0700
383@@ -0,0 +1,10 @@
384+ .text
385+ .type foo, @function
386+ .global
387+foo:
388+ movl xxx@GOT(%ebx), %eax
389+ ret
390+
391+ .data
392+xxx:
393+ .long ifunc
394Index: binutils-2.21/ld/testsuite/ld-ifunc/ifunc-13a-x86-64.s
395===================================================================
396--- /dev/null 1970-01-01 00:00:00.000000000 +0000
397+++ binutils-2.21/ld/testsuite/ld-ifunc/ifunc-13a-x86-64.s 2011-06-21 16:36:36.822142371 -0700
398@@ -0,0 +1,10 @@
399+ .text
400+ .type foo, @function
401+ .global
402+foo:
403+ movl xxx(%rip), %eax
404+ ret
405+
406+ .data
407+xxx:
408+ .quad ifunc
409Index: binutils-2.21/ld/testsuite/ld-ifunc/ifunc-13b-i386.s
410===================================================================
411--- /dev/null 1970-01-01 00:00:00.000000000 +0000
412+++ binutils-2.21/ld/testsuite/ld-ifunc/ifunc-13b-i386.s 2011-06-21 16:33:40.761884138 -0700
413@@ -0,0 +1,5 @@
414+ .text
415+ .type ifunc, @gnu_indirect_function
416+ .globl ifunc
417+ifunc:
418+ ret
419Index: binutils-2.21/ld/testsuite/ld-ifunc/ifunc-13b-x86-64.s
420===================================================================
421--- /dev/null 1970-01-01 00:00:00.000000000 +0000
422+++ binutils-2.21/ld/testsuite/ld-ifunc/ifunc-13b-x86-64.s 2011-06-21 16:33:40.761884138 -0700
423@@ -0,0 +1,5 @@
424+ .text
425+ .type ifunc, @gnu_indirect_function
426+ .globl ifunc
427+ifunc:
428+ ret
diff --git a/meta/recipes-devtools/binutils/binutils/binutils-uclibc-100-uclibc-conf.patch b/meta/recipes-devtools/binutils/binutils/binutils-uclibc-100-uclibc-conf.patch
deleted file mode 100644
index b5a25c2389..0000000000
--- a/meta/recipes-devtools/binutils/binutils/binutils-uclibc-100-uclibc-conf.patch
+++ /dev/null
@@ -1,40 +0,0 @@
1Upstream-Status: Pending
2
3Index: binutils-2.22/configure
4===================================================================
5--- binutils-2.22.orig/configure
6+++ binutils-2.22/configure
7@@ -3130,7 +3130,7 @@ case "${target}" in
8 ;;
9 s390-*-* | s390x-*-*)
10 ;;
11- sh-*-* | sh[34]*-*-*)
12+ sh*-*-* | sh[34]*-*-*)
13 ;;
14 sh64-*-* | sh5*-*-*)
15 ;;
16@@ -3570,7 +3570,7 @@ case "${target}" in
17 mips*-*-*)
18 noconfigdirs="$noconfigdirs gprof"
19 ;;
20- sh-*-* | sh64-*-*)
21+ sh*-*-* | sh64-*-*)
22 case "${target}" in
23 sh*-*-elf)
24 ;;
25Index: binutils-2.22/gprof/configure
26===================================================================
27--- binutils-2.22.orig/gprof/configure
28+++ binutils-2.22/gprof/configure
29@@ -6103,6 +6103,11 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu)
30 lt_cv_deplibs_check_method=pass_all
31 ;;
32
33+linux-uclibc*)
34+ lt_cv_deplibs_check_method=pass_all
35+ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so`
36+ ;;
37+
38 netbsd*)
39 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
40 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
diff --git a/meta/recipes-devtools/binutils/binutils/binutils-uclibc-300-001_ld_makefile_patch.patch b/meta/recipes-devtools/binutils/binutils/binutils-uclibc-300-001_ld_makefile_patch.patch
deleted file mode 100644
index c6e1efcea0..0000000000
--- a/meta/recipes-devtools/binutils/binutils/binutils-uclibc-300-001_ld_makefile_patch.patch
+++ /dev/null
@@ -1,55 +0,0 @@
1#!/bin/sh -e
2## 001_ld_makefile_patch.dpatch
3##
4## All lines beginning with `## DP:' are a description of the patch.
5## DP: Description: correct where ld scripts are installed
6## DP: Author: Chris Chimelis <chris@debian.org>
7## DP: Upstream status: N/A
8## DP: Date: ??
9
10if [ $# -ne 1 ]; then
11 echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
12 exit 1
13fi
14
15[ -f debian/patches/00patch-opts ] && . debian/patches/00patch-opts
16patch_opts="${patch_opts:--f --no-backup-if-mismatch}"
17
18case "$1" in
19 -patch) patch $patch_opts -p1 < $0;;
20 -unpatch) patch $patch_opts -p1 -R < $0;;
21 *)
22 echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
23 exit 1;;
24esac
25
26exit 0
27Upstream-Status: Inappropriate [debian patch]
28
29@DPATCH@
30Index: binutils-2.22/ld/Makefile.am
31===================================================================
32--- binutils-2.22.orig/ld/Makefile.am
33+++ binutils-2.22/ld/Makefile.am
34@@ -37,7 +37,7 @@ endif
35 # We put the scripts in the directory $(scriptdir)/ldscripts.
36 # We can't put the scripts in $(datadir) because the SEARCH_DIR
37 # directives need to be different for native and cross linkers.
38-scriptdir = $(tooldir)/lib
39+scriptdir = $(libdir)
40
41 EMUL = @EMUL@
42 EMULATION_OFILES = @EMULATION_OFILES@
43Index: binutils-2.22/ld/Makefile.in
44===================================================================
45--- binutils-2.22.orig/ld/Makefile.in
46+++ binutils-2.22/ld/Makefile.in
47@@ -366,7 +366,7 @@ AM_CFLAGS = $(WARN_CFLAGS)
48 # We put the scripts in the directory $(scriptdir)/ldscripts.
49 # We can't put the scripts in $(datadir) because the SEARCH_DIR
50 # directives need to be different for native and cross linkers.
51-scriptdir = $(tooldir)/lib
52+scriptdir = $(libdir)
53 BASEDIR = $(srcdir)/..
54 BFDDIR = $(BASEDIR)/bfd
55 INCDIR = $(BASEDIR)/include
diff --git a/meta/recipes-devtools/binutils/binutils/binutils-uclibc-300-006_better_file_error.patch b/meta/recipes-devtools/binutils/binutils/binutils-uclibc-300-006_better_file_error.patch
deleted file mode 100644
index 47bd8ff109..0000000000
--- a/meta/recipes-devtools/binutils/binutils/binutils-uclibc-300-006_better_file_error.patch
+++ /dev/null
@@ -1,45 +0,0 @@
1#!/bin/sh -e
2## 006_better_file_error.dpatch by David Kimdon <dwhedon@gordian.com>
3##
4## All lines beginning with `## DP:' are a description of the patch.
5## DP: Specify which filename is causing an error if the filename is a
6## DP: directory. (#45832)
7
8if [ $# -ne 1 ]; then
9 echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
10 exit 1
11fi
12
13[ -f debian/patches/00patch-opts ] && . debian/patches/00patch-opts
14patch_opts="${patch_opts:--f --no-backup-if-mismatch}"
15
16case "$1" in
17 -patch) patch $patch_opts -p1 < $0;;
18 -unpatch) patch $patch_opts -p1 -R < $0;;
19 *)
20 echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
21 exit 1;;
22esac
23
24exit 0
25Upstream-Status: Inappropriate [debian patch]
26
27@DPATCH@
28Index: binutils-2.22/bfd/opncls.c
29===================================================================
30--- binutils-2.22.orig/bfd/opncls.c
31+++ binutils-2.22/bfd/opncls.c
32@@ -197,6 +197,13 @@ bfd_fopen (const char *filename, const c
33 {
34 bfd *nbfd;
35 const bfd_target *target_vec;
36+ struct stat s;
37+
38+ if (stat (filename, &s) == 0)
39+ if (S_ISDIR(s.st_mode)) {
40+ bfd_set_error (bfd_error_file_not_recognized);
41+ return NULL;
42+ }
43
44 nbfd = _bfd_new_bfd ();
45 if (nbfd == NULL)
diff --git a/meta/recipes-devtools/binutils/binutils/binutils-uclibc-300-012_check_ldrunpath_length.patch b/meta/recipes-devtools/binutils/binutils/binutils-uclibc-300-012_check_ldrunpath_length.patch
deleted file mode 100644
index d31f80cd3d..0000000000
--- a/meta/recipes-devtools/binutils/binutils/binutils-uclibc-300-012_check_ldrunpath_length.patch
+++ /dev/null
@@ -1,49 +0,0 @@
1#!/bin/sh -e
2## 012_check_ldrunpath_length.dpatch by Chris Chimelis <chris@debian.org>
3##
4## All lines beginning with `## DP:' are a description of the patch.
5## DP: Only generate an RPATH entry if LD_RUN_PATH is not empty, for
6## DP: cases where -rpath isn't specified. (#151024)
7
8if [ $# -ne 1 ]; then
9 echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
10 exit 1
11fi
12
13[ -f debian/patches/00patch-opts ] && . debian/patches/00patch-opts
14patch_opts="${patch_opts:--f --no-backup-if-mismatch}"
15
16case "$1" in
17 -patch) patch $patch_opts -p1 < $0;;
18 -unpatch) patch $patch_opts -p1 -R < $0;;
19 *)
20 echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
21 exit 1;;
22esac
23
24exit 0
25Upstream-Status: Inappropriate [debian patch]
26
27@DPATCH@
28Index: binutils-2.22/ld/emultempl/elf32.em
29===================================================================
30--- binutils-2.22.orig/ld/emultempl/elf32.em
31+++ binutils-2.22/ld/emultempl/elf32.em
32@@ -1273,6 +1273,8 @@ fragment <<EOF
33 && command_line.rpath == NULL)
34 {
35 lib_path = (const char *) getenv ("LD_RUN_PATH");
36+ if ((lib_path) && (strlen (lib_path) == 0))
37+ lib_path = NULL;
38 if (gld${EMULATION_NAME}_search_needed (lib_path, &n,
39 force))
40 break;
41@@ -1500,6 +1502,8 @@ gld${EMULATION_NAME}_before_allocation (
42 rpath = command_line.rpath;
43 if (rpath == NULL)
44 rpath = (const char *) getenv ("LD_RUN_PATH");
45+ if ((rpath) && (strlen (rpath) == 0))
46+ rpath = NULL;
47
48 for (abfd = link_info.input_bfds; abfd; abfd = abfd->link_next)
49 if (bfd_get_flavour (abfd) == bfd_target_elf_flavour)
diff --git a/meta/recipes-devtools/binutils/binutils/binutils-uclibc-gas-needs-libm.patch b/meta/recipes-devtools/binutils/binutils/binutils-uclibc-gas-needs-libm.patch
deleted file mode 100644
index 3869faff0e..0000000000
--- a/meta/recipes-devtools/binutils/binutils/binutils-uclibc-gas-needs-libm.patch
+++ /dev/null
@@ -1,38 +0,0 @@
1Source: Khem Raj <raj.khem@gmail.com>
2Disposition: submit upstream.
3Upstream-Status: Pending
4
5Description:
6
7We do not need to have the libtool patch anymore for binutils after
8libtool has been updated upstream it include support for it. However
9for building gas natively on uclibc systems we have to link it with
10-lm so that it picks up missing symbols.
11
12/local/build_area/BUILD/arm_v5t_le_uclibc/binutils-2.17.50/objdir/libiberty/pic/libiberty.a(floatformat.o): In function `floatformat_from_double':
13floatformat.c:(.text+0x1ec): undefined reference to `frexp'
14floatformat.c:(.text+0x2f8): undefined reference to `ldexp'
15/local/build_area/BUILD/arm_v5t_le_uclibc/binutils-2.17.50/objdir/libiberty/pic/libiberty.a(floatformat.o): In function `floatformat_to_double':
16floatformat.c:(.text+0x38a): undefined reference to `ldexp'
17floatformat.c:(.text+0x3d2): undefined reference to `ldexp'
18floatformat.c:(.text+0x43e): undefined reference to `ldexp' floatformat.c:(.text+0x4e2): undefined reference to `ldexp'
19collect2: ld returned 1 exit status
20make[4]: *** [as-new] Error 1
21
22Index: binutils-2.22/gas/configure.tgt
23===================================================================
24--- binutils-2.22.orig/gas/configure.tgt
25+++ binutils-2.22/gas/configure.tgt
26@@ -428,6 +428,12 @@ case ${generic_target} in
27 *-*-netware) fmt=elf em=netware ;;
28 esac
29
30+case ${generic_target} in
31+ arm-*-*uclibc*)
32+ need_libm=yes
33+ ;;
34+esac
35+
36 case ${cpu_type} in
37 alpha | arm | i386 | ia64 | microblaze | mips | ns32k | pdp11 | ppc | sparc | z80 | z8k)
38 bfd_gas=yes
diff --git a/meta/recipes-devtools/binutils/binutils/binutils-x86_64_i386_biarch.patch b/meta/recipes-devtools/binutils/binutils/binutils-x86_64_i386_biarch.patch
deleted file mode 100644
index c09578a787..0000000000
--- a/meta/recipes-devtools/binutils/binutils/binutils-x86_64_i386_biarch.patch
+++ /dev/null
@@ -1,29 +0,0 @@
1#!/bin/sh -e
2## 127_x86_64_i386_biarch.dpatch
3##
4## DP: Description: Add (/usr)/lib32 to the search paths on x86_64.
5## DP: Author: Aurelien Jarno <aurel32.debian.org>
6## DP: Upstream status: Debian specific
7#
8# Hacked to apply with quilt
9# Adapted to binutils 2.18.50.0.7
10Upstream-Status: Inappropriate [embedded specific]
11
12Index: binutils-2.22/ld/emulparams/elf_i386.sh
13===================================================================
14--- binutils-2.22.orig/ld/emulparams/elf_i386.sh
15+++ binutils-2.22/ld/emulparams/elf_i386.sh
16@@ -14,3 +14,13 @@ GENERATE_PIE_SCRIPT=yes
17 NO_SMALL_DATA=yes
18 SEPARATE_GOTPLT=12
19 IREL_IN_PLT=
20+
21+# Linux modify the default library search path to first include
22+# a 32-bit specific directory.
23+case "$target" in
24+ x86_64*-linux* | i[3-7]86*-linux* | x86_64*-kfreebsd*-gnu | i[3-7]86*-kfreebsd*-gnu)
25+ case "$EMULATION_NAME" in
26+ *i386*) LIBPATH_SUFFIX=32 ;;
27+ esac
28+ ;;
29+esac
diff --git a/meta/recipes-devtools/binutils/binutils/clone-shadow.patch b/meta/recipes-devtools/binutils/binutils/clone-shadow.patch
deleted file mode 100644
index 73d9db29a5..0000000000
--- a/meta/recipes-devtools/binutils/binutils/clone-shadow.patch
+++ /dev/null
@@ -1,79 +0,0 @@
1This fixes a global shadow warning. The warning is treated as error hence breaks the build of target
2binutils.
3
4 /b/openembedded-core/build/tmp-uclibc/work/armv5te-oe-linux-uclibceabi/binutils-2.21.1-r1/binutils-2.21.1/gas/config/obj-elf.c: In function 'obj_elf_parse_section_letters':
5| /b/openembedded-core/build/tmp-uclibc/work/armv5te-oe-linux-uclibceabi/binutils-2.21.1-r1/binutils-2.21.1/gas/config/obj-elf.c:744:68: error: declaration of 'clone' shadows a global declaration [-Werror=shadow]
6| /b/openembedded-core/build/tmp-uclibc/work/armv5te-oe-linux-uclibceabi/binutils-2.21.1-r1/binutils-2.21.1/gas/config/obj-elf.c: In function 'obj_elf_section':
7| /b/openembedded-core/build/tmp-uclibc/work/armv5te-oe-linux-uclibceabi/binutils-2.21.1-r1/binutils-2.21.1/gas/config/obj-elf.c:981:16: error: declaration of 'clone' shadows a global declaration [-Werror=shadow]
8| cc1: all warnings being treated as errors
9|
10
11Upstream-Status: Pending
12
13Signed-off-by: Khem Raj <raj.khem@gmail.com>
14Index: binutils-2.22/gas/config/obj-elf.c
15===================================================================
16--- binutils-2.22.orig/gas/config/obj-elf.c
17+++ binutils-2.22/gas/config/obj-elf.c
18@@ -741,10 +741,10 @@ obj_elf_change_section (const char *name
19 }
20
21 static bfd_vma
22-obj_elf_parse_section_letters (char *str, size_t len, bfd_boolean *clone)
23+obj_elf_parse_section_letters (char *str, size_t len, bfd_boolean *cloneit)
24 {
25 bfd_vma attr = 0;
26- *clone = FALSE;
27+ *cloneit = FALSE;
28
29 while (len > 0)
30 {
31@@ -775,7 +775,7 @@ obj_elf_parse_section_letters (char *str
32 attr |= SHF_TLS;
33 break;
34 case '?':
35- *clone = TRUE;
36+ *cloneit = TRUE;
37 break;
38 /* Compatibility. */
39 case 'm':
40@@ -978,7 +978,7 @@ obj_elf_section (int push)
41
42 if (*input_line_pointer == '"')
43 {
44- bfd_boolean clone;
45+ bfd_boolean cloneit;
46
47 beg = demand_copy_C_string (&dummy);
48 if (beg == NULL)
49@@ -986,7 +986,7 @@ obj_elf_section (int push)
50 ignore_rest_of_line ();
51 return;
52 }
53- attr |= obj_elf_parse_section_letters (beg, strlen (beg), &clone);
54+ attr |= obj_elf_parse_section_letters (beg, strlen (beg), &cloneit);
55
56 SKIP_WHITESPACE ();
57 if (*input_line_pointer == ',')
58@@ -1038,10 +1038,10 @@ obj_elf_section (int push)
59 attr &= ~SHF_MERGE;
60 }
61
62- if ((attr & SHF_GROUP) != 0 && clone)
63+ if ((attr & SHF_GROUP) != 0 && cloneit)
64 {
65 as_warn (_("? section flag ignored with G present"));
66- clone = FALSE;
67+ cloneit = FALSE;
68 }
69 if ((attr & SHF_GROUP) != 0 && *input_line_pointer == ',')
70 {
71@@ -1063,7 +1063,7 @@ obj_elf_section (int push)
72 attr &= ~SHF_GROUP;
73 }
74
75- if (clone)
76+ if (cloneit)
77 {
78 const char *now_group = elf_group_name (now_seg);
79 if (now_group != NULL)
diff --git a/meta/recipes-devtools/binutils/binutils/libiberty_path_fix.patch b/meta/recipes-devtools/binutils/binutils/libiberty_path_fix.patch
deleted file mode 100644
index 6e732fbd0a..0000000000
--- a/meta/recipes-devtools/binutils/binutils/libiberty_path_fix.patch
+++ /dev/null
@@ -1,22 +0,0 @@
1Upstream-Status: Inappropriate [embedded specific]
2
3don't let the distro compiler point to the wrong installation location
4
5Thanks to RP for helping find the source code causing the issue.
6
72010/08/13
8Nitin A Kamble <nitin.a.kamble@intel.com>
9Index: binutils-2.22/libiberty/Makefile.in
10===================================================================
11--- binutils-2.22.orig/libiberty/Makefile.in
12+++ binutils-2.22/libiberty/Makefile.in
13@@ -350,7 +350,8 @@ install-strip: install
14 # multilib-specific flags, it's overridden by FLAGS_TO_PASS from the
15 # default multilib, so we have to take CFLAGS into account as well,
16 # since it will be passed the multilib flags.
17-MULTIOSDIR = `$(CC) $(CFLAGS) -print-multi-os-directory`
18+#MULTIOSDIR = `$(CC) $(CFLAGS) -print-multi-os-directory`
19+MULTIOSDIR = ""
20 install_to_libdir: all
21 ${mkinstalldirs} $(DESTDIR)$(libdir)/$(MULTIOSDIR)
22 $(INSTALL_DATA) $(TARGETLIB) $(DESTDIR)$(libdir)/$(MULTIOSDIR)/$(TARGETLIB)n
diff --git a/meta/recipes-devtools/binutils/binutils/libtool-2.4-update.patch b/meta/recipes-devtools/binutils/binutils/libtool-2.4-update.patch
deleted file mode 100644
index 0f27361e4b..0000000000
--- a/meta/recipes-devtools/binutils/binutils/libtool-2.4-update.patch
+++ /dev/null
@@ -1,18705 +0,0 @@
1Upstream-Status: Inappropriate [embedded specific]
2
3Index: binutils-2.22/libtool.m4
4===================================================================
5--- binutils-2.22.orig/libtool.m4
6+++ binutils-2.22/libtool.m4
7@@ -1,7 +1,8 @@
8 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
9 #
10 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
11-# 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
12+# 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
13+# Inc.
14 # Written by Gordon Matzigkeit, 1996
15 #
16 # This file is free software; the Free Software Foundation gives
17@@ -10,7 +11,8 @@
18
19 m4_define([_LT_COPYING], [dnl
20 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
21-# 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
22+# 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
23+# Inc.
24 # Written by Gordon Matzigkeit, 1996
25 #
26 # This file is part of GNU Libtool.
27@@ -37,7 +39,7 @@ m4_define([_LT_COPYING], [dnl
28 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
29 ])
30
31-# serial 56 LT_INIT
32+# serial 57 LT_INIT
33
34
35 # LT_PREREQ(VERSION)
36@@ -92,7 +94,8 @@ _LT_SET_OPTIONS([$0], [$1])
37 LIBTOOL_DEPS="$ltmain"
38
39 # Always use our own libtool.
40-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
41+LIBTOOL='$(SHELL) $(top_builddir)'
42+LIBTOOL="$LIBTOOL/${host_alias}-libtool"
43 AC_SUBST(LIBTOOL)dnl
44
45 _LT_SETUP
46@@ -166,10 +169,13 @@ _LT_DECL([], [exeext], [0], [Executable
47 dnl
48 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
49 m4_require([_LT_CHECK_SHELL_FEATURES])dnl
50+m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl
51 m4_require([_LT_CMD_RELOAD])dnl
52 m4_require([_LT_CHECK_MAGIC_METHOD])dnl
53+m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl
54 m4_require([_LT_CMD_OLD_ARCHIVE])dnl
55 m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
56+m4_require([_LT_WITH_SYSROOT])dnl
57
58 _LT_CONFIG_LIBTOOL_INIT([
59 # See if we are running on zsh, and set the options which allow our
60@@ -199,7 +205,7 @@ aix3*)
61 esac
62
63 # Global variables:
64-ofile=libtool
65+ofile=${host_alias}-libtool
66 can_build_shared=yes
67
68 # All known linkers require a `.a' archive for static linking (except MSVC,
69@@ -632,7 +638,7 @@ m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_
70 m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
71 configured by $[0], generated by m4_PACKAGE_STRING.
72
73-Copyright (C) 2009 Free Software Foundation, Inc.
74+Copyright (C) 2010 Free Software Foundation, Inc.
75 This config.lt script is free software; the Free Software Foundation
76 gives unlimited permision to copy, distribute and modify it."
77
78@@ -746,15 +752,12 @@ _LT_EOF
79 # if finds mixed CR/LF and LF-only lines. Since sed operates in
80 # text mode, it properly converts lines to CR/LF. This bash problem
81 # is reportedly fixed, but why not run on old versions too?
82- sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
83- || (rm -f "$cfgfile"; exit 1)
84+ sed '$q' "$ltmain" >> "$cfgfile" \
85+ || (rm -f "$cfgfile"; exit 1)
86
87- _LT_PROG_XSI_SHELLFNS
88+ _LT_PROG_REPLACE_SHELLFNS
89
90- sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
91- || (rm -f "$cfgfile"; exit 1)
92-
93- mv -f "$cfgfile" "$ofile" ||
94+ mv -f "$cfgfile" "$ofile" ||
95 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
96 chmod +x "$ofile"
97 ],
98@@ -980,6 +983,8 @@ _LT_EOF
99 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD
100 echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD
101 $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD
102+ echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD
103+ $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD
104 cat > conftest.c << _LT_EOF
105 int main() { return 0;}
106 _LT_EOF
107@@ -1069,30 +1074,41 @@ m4_defun([_LT_DARWIN_LINKER_FEATURES],
108 fi
109 ])
110
111-# _LT_SYS_MODULE_PATH_AIX
112-# -----------------------
113+# _LT_SYS_MODULE_PATH_AIX([TAGNAME])
114+# ----------------------------------
115 # Links a minimal program and checks the executable
116 # for the system default hardcoded library path. In most cases,
117 # this is /usr/lib:/lib, but when the MPI compilers are used
118 # the location of the communication and MPI libs are included too.
119 # If we don't find anything, use the default library path according
120 # to the aix ld manual.
121+# Store the results from the different compilers for each TAGNAME.
122+# Allow to override them for all tags through lt_cv_aix_libpath.
123 m4_defun([_LT_SYS_MODULE_PATH_AIX],
124 [m4_require([_LT_DECL_SED])dnl
125-AC_LINK_IFELSE(AC_LANG_PROGRAM,[
126-lt_aix_libpath_sed='
127- /Import File Strings/,/^$/ {
128- /^0/ {
129- s/^0 *\(.*\)$/\1/
130- p
131- }
132- }'
133-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
134-# Check for a 64-bit object if we didn't find anything.
135-if test -z "$aix_libpath"; then
136- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
137-fi],[])
138-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
139+if test "${lt_cv_aix_libpath+set}" = set; then
140+ aix_libpath=$lt_cv_aix_libpath
141+else
142+ AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])],
143+ [AC_LINK_IFELSE([AC_LANG_PROGRAM],[
144+ lt_aix_libpath_sed='[
145+ /Import File Strings/,/^$/ {
146+ /^0/ {
147+ s/^0 *\([^ ]*\) *$/\1/
148+ p
149+ }
150+ }]'
151+ _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
152+ # Check for a 64-bit object if we didn't find anything.
153+ if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
154+ _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
155+ fi],[])
156+ if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
157+ _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib"
158+ fi
159+ ])
160+ aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])
161+fi
162 ])# _LT_SYS_MODULE_PATH_AIX
163
164
165@@ -1117,7 +1133,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
166
167 AC_MSG_CHECKING([how to print strings])
168 # Test print first, because it will be a builtin if present.
169-if test "X`print -r -- -n 2>/dev/null`" = X-n && \
170+if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
171 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
172 ECHO='print -r --'
173 elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
174@@ -1161,6 +1177,39 @@ _LT_DECL([], [ECHO], [1], [An echo progr
175 ])# _LT_PROG_ECHO_BACKSLASH
176
177
178+# _LT_WITH_SYSROOT
179+# ----------------
180+AC_DEFUN([_LT_WITH_SYSROOT],
181+[AC_MSG_CHECKING([for sysroot])
182+AC_ARG_WITH([libtool-sysroot],
183+[ --with-libtool-sysroot[=DIR] Search for dependent libraries within DIR
184+ (or the compiler's sysroot if not specified).],
185+[], [with_libtool_sysroot=no])
186+
187+dnl lt_sysroot will always be passed unquoted. We quote it here
188+dnl in case the user passed a directory name.
189+lt_sysroot=
190+case ${with_libtool_sysroot} in #(
191+ yes)
192+ if test "$GCC" = yes; then
193+ lt_sysroot=`$CC --print-sysroot 2>/dev/null`
194+ fi
195+ ;; #(
196+ /*)
197+ lt_sysroot=`echo "$with_libtool_sysroot" | sed -e "$sed_quote_subst"`
198+ ;; #(
199+ no|'')
200+ ;; #(
201+ *)
202+ AC_MSG_RESULT([${with_libtool_sysroot}])
203+ AC_MSG_ERROR([The sysroot must be an absolute path.])
204+ ;;
205+esac
206+
207+ AC_MSG_RESULT([${lt_sysroot:-no}])
208+_LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl
209+[dependent libraries, and in which our libraries should be installed.])])
210+
211 # _LT_ENABLE_LOCK
212 # ---------------
213 m4_defun([_LT_ENABLE_LOCK],
214@@ -1307,14 +1356,47 @@ need_locks="$enable_libtool_lock"
215 ])# _LT_ENABLE_LOCK
216
217
218+# _LT_PROG_AR
219+# -----------
220+m4_defun([_LT_PROG_AR],
221+[AC_CHECK_TOOLS(AR, [ar], false)
222+: ${AR=ar}
223+: ${AR_FLAGS=cru}
224+_LT_DECL([], [AR], [1], [The archiver])
225+_LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive])
226+
227+AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file],
228+ [lt_cv_ar_at_file=no
229+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM],
230+ [echo conftest.$ac_objext > conftest.lst
231+ lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD'
232+ AC_TRY_EVAL([lt_ar_try])
233+ if test "$ac_status" -eq 0; then
234+ # Ensure the archiver fails upon bogus file names.
235+ rm -f conftest.$ac_objext libconftest.a
236+ AC_TRY_EVAL([lt_ar_try])
237+ if test "$ac_status" -ne 0; then
238+ lt_cv_ar_at_file=@
239+ fi
240+ fi
241+ rm -f conftest.* libconftest.a
242+ ])
243+ ])
244+
245+if test "x$lt_cv_ar_at_file" = xno; then
246+ archiver_list_spec=
247+else
248+ archiver_list_spec=$lt_cv_ar_at_file
249+fi
250+_LT_DECL([], [archiver_list_spec], [1],
251+ [How to feed a file listing to the archiver])
252+])# _LT_PROG_AR
253+
254+
255 # _LT_CMD_OLD_ARCHIVE
256 # -------------------
257 m4_defun([_LT_CMD_OLD_ARCHIVE],
258-[AC_CHECK_TOOL(AR, ar, false)
259-test -z "$AR" && AR=ar
260-test -z "$AR_FLAGS" && AR_FLAGS=cru
261-_LT_DECL([], [AR], [1], [The archiver])
262-_LT_DECL([], [AR_FLAGS], [1])
263+[_LT_PROG_AR
264
265 AC_CHECK_TOOL(STRIP, strip, :)
266 test -z "$STRIP" && STRIP=:
267@@ -1610,7 +1692,7 @@ else
268 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
269 lt_status=$lt_dlunknown
270 cat > conftest.$ac_ext <<_LT_EOF
271-[#line __oline__ "configure"
272+[#line $LINENO "configure"
273 #include "confdefs.h"
274
275 #if HAVE_DLFCN_H
276@@ -1654,10 +1736,10 @@ else
277 /* When -fvisbility=hidden is used, assume the code has been annotated
278 correspondingly for the symbols needed. */
279 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
280-void fnord () __attribute__((visibility("default")));
281+int fnord () __attribute__((visibility("default")));
282 #endif
283
284-void fnord () { int i=42; }
285+int fnord () { return 42; }
286 int main ()
287 {
288 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
289@@ -2197,8 +2279,9 @@ cygwin* | mingw* | pw32* | cegcc*)
290 need_version=no
291 need_lib_prefix=no
292
293- case $GCC,$host_os in
294- yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
295+ case $GCC,$cc_basename in
296+ yes,*)
297+ # gcc
298 library_names_spec='$libname.dll.a'
299 # DLL is installed to $(libdir)/../bin by postinstall_cmds
300 postinstall_cmds='base_file=`basename \${file}`~
301@@ -2231,13 +2314,71 @@ m4_if([$1], [],[
302 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
303 ;;
304 esac
305+ dynamic_linker='Win32 ld.exe'
306+ ;;
307+
308+ *,cl*)
309+ # Native MSVC
310+ libname_spec='$name'
311+ soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
312+ library_names_spec='${libname}.dll.lib'
313+
314+ case $build_os in
315+ mingw*)
316+ sys_lib_search_path_spec=
317+ lt_save_ifs=$IFS
318+ IFS=';'
319+ for lt_path in $LIB
320+ do
321+ IFS=$lt_save_ifs
322+ # Let DOS variable expansion print the short 8.3 style file name.
323+ lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
324+ sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
325+ done
326+ IFS=$lt_save_ifs
327+ # Convert to MSYS style.
328+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'`
329+ ;;
330+ cygwin*)
331+ # Convert to unix form, then to dos form, then back to unix form
332+ # but this time dos style (no spaces!) so that the unix form looks
333+ # like /cygdrive/c/PROGRA~1:/cygdr...
334+ sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
335+ sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
336+ sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
337+ ;;
338+ *)
339+ sys_lib_search_path_spec="$LIB"
340+ if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
341+ # It is most probably a Windows format PATH.
342+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
343+ else
344+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
345+ fi
346+ # FIXME: find the short name or the path components, as spaces are
347+ # common. (e.g. "Program Files" -> "PROGRA~1")
348+ ;;
349+ esac
350+
351+ # DLL is installed to $(libdir)/../bin by postinstall_cmds
352+ postinstall_cmds='base_file=`basename \${file}`~
353+ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
354+ dldir=$destdir/`dirname \$dlpath`~
355+ test -d \$dldir || mkdir -p \$dldir~
356+ $install_prog $dir/$dlname \$dldir/$dlname'
357+ postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
358+ dlpath=$dir/\$dldll~
359+ $RM \$dlpath'
360+ shlibpath_overrides_runpath=yes
361+ dynamic_linker='Win32 link.exe'
362 ;;
363
364 *)
365+ # Assume MSVC wrapper
366 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
367+ dynamic_linker='Win32 ld.exe'
368 ;;
369 esac
370- dynamic_linker='Win32 ld.exe'
371 # FIXME: first we should search . and the directory the executable is in
372 shlibpath_var=PATH
373 ;;
374@@ -2329,7 +2470,7 @@ haiku*)
375 soname_spec='${libname}${release}${shared_ext}$major'
376 shlibpath_var=LIBRARY_PATH
377 shlibpath_overrides_runpath=yes
378- sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/beos/system/lib'
379+ sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
380 hardcode_into_libs=yes
381 ;;
382
383@@ -2937,6 +3078,11 @@ case $reload_flag in
384 esac
385 reload_cmds='$LD$reload_flag -o $output$reload_objs'
386 case $host_os in
387+ cygwin* | mingw* | pw32* | cegcc*)
388+ if test "$GCC" != yes; then
389+ reload_cmds=false
390+ fi
391+ ;;
392 darwin*)
393 if test "$GCC" = yes; then
394 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
395@@ -3003,7 +3149,8 @@ mingw* | pw32*)
396 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
397 lt_cv_file_magic_cmd='func_win32_libid'
398 else
399- lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
400+ # Keep this pattern in sync with the one in func_win32_libid.
401+ lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
402 lt_cv_file_magic_cmd='$OBJDUMP -f'
403 fi
404 ;;
405@@ -3154,6 +3301,21 @@ tpf*)
406 ;;
407 esac
408 ])
409+
410+file_magic_glob=
411+want_nocaseglob=no
412+if test "$build" = "$host"; then
413+ case $host_os in
414+ mingw* | pw32*)
415+ if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
416+ want_nocaseglob=yes
417+ else
418+ file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"`
419+ fi
420+ ;;
421+ esac
422+fi
423+
424 file_magic_cmd=$lt_cv_file_magic_cmd
425 deplibs_check_method=$lt_cv_deplibs_check_method
426 test -z "$deplibs_check_method" && deplibs_check_method=unknown
427@@ -3161,7 +3323,11 @@ test -z "$deplibs_check_method" && depli
428 _LT_DECL([], [deplibs_check_method], [1],
429 [Method to check whether dependent libraries are shared objects])
430 _LT_DECL([], [file_magic_cmd], [1],
431- [Command to use when deplibs_check_method == "file_magic"])
432+ [Command to use when deplibs_check_method = "file_magic"])
433+_LT_DECL([], [file_magic_glob], [1],
434+ [How to find potential files when deplibs_check_method = "file_magic"])
435+_LT_DECL([], [want_nocaseglob], [1],
436+ [Find potential files using nocaseglob when deplibs_check_method = "file_magic"])
437 ])# _LT_CHECK_MAGIC_METHOD
438
439
440@@ -3264,6 +3430,67 @@ dnl aclocal-1.4 backwards compatibility:
441 dnl AC_DEFUN([AM_PROG_NM], [])
442 dnl AC_DEFUN([AC_PROG_NM], [])
443
444+# _LT_CHECK_SHAREDLIB_FROM_LINKLIB
445+# --------------------------------
446+# how to determine the name of the shared library
447+# associated with a specific link library.
448+# -- PORTME fill in with the dynamic library characteristics
449+m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB],
450+[m4_require([_LT_DECL_EGREP])
451+m4_require([_LT_DECL_OBJDUMP])
452+m4_require([_LT_DECL_DLLTOOL])
453+AC_CACHE_CHECK([how to associate runtime and link libraries],
454+lt_cv_sharedlib_from_linklib_cmd,
455+[lt_cv_sharedlib_from_linklib_cmd='unknown'
456+
457+case $host_os in
458+cygwin* | mingw* | pw32* | cegcc*)
459+ # two different shell functions defined in ltmain.sh
460+ # decide which to use based on capabilities of $DLLTOOL
461+ case `$DLLTOOL --help 2>&1` in
462+ *--identify-strict*)
463+ lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
464+ ;;
465+ *)
466+ lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
467+ ;;
468+ esac
469+ ;;
470+*)
471+ # fallback: assume linklib IS sharedlib
472+ lt_cv_sharedlib_from_linklib_cmd="$ECHO"
473+ ;;
474+esac
475+])
476+sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
477+test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
478+
479+_LT_DECL([], [sharedlib_from_linklib_cmd], [1],
480+ [Command to associate shared and link libraries])
481+])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB
482+
483+
484+# _LT_PATH_MANIFEST_TOOL
485+# ----------------------
486+# locate the manifest tool
487+m4_defun([_LT_PATH_MANIFEST_TOOL],
488+[AC_CHECK_TOOL(MANIFEST_TOOL, mt, :)
489+test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
490+AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool],
491+ [lt_cv_path_mainfest_tool=no
492+ echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD
493+ $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
494+ cat conftest.err >&AS_MESSAGE_LOG_FD
495+ if $GREP 'Manifest Tool' conftest.out > /dev/null; then
496+ lt_cv_path_mainfest_tool=yes
497+ fi
498+ rm -f conftest*])
499+if test "x$lt_cv_path_mainfest_tool" != xyes; then
500+ MANIFEST_TOOL=:
501+fi
502+_LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl
503+])# _LT_PATH_MANIFEST_TOOL
504+
505
506 # LT_LIB_M
507 # --------
508@@ -3390,8 +3617,8 @@ esac
509 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
510
511 # Transform an extracted symbol line into symbol name and symbol address
512-lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'"
513-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
514+lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'"
515+lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
516
517 # Handle CRLF in mingw tool chain
518 opt_cr=
519@@ -3427,6 +3654,7 @@ for ac_symprfx in "" "_"; do
520 else
521 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
522 fi
523+ lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
524
525 # Check to see that the pipe works correctly.
526 pipe_works=no
527@@ -3460,6 +3688,18 @@ _LT_EOF
528 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
529 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
530 cat <<_LT_EOF > conftest.$ac_ext
531+/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
532+#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
533+/* DATA imports from DLLs on WIN32 con't be const, because runtime
534+ relocations are performed -- see ld's documentation on pseudo-relocs. */
535+# define LT@&t@_DLSYM_CONST
536+#elif defined(__osf__)
537+/* This system does not cope well with relocations in const data. */
538+# define LT@&t@_DLSYM_CONST
539+#else
540+# define LT@&t@_DLSYM_CONST const
541+#endif
542+
543 #ifdef __cplusplus
544 extern "C" {
545 #endif
546@@ -3471,7 +3711,7 @@ _LT_EOF
547 cat <<_LT_EOF >> conftest.$ac_ext
548
549 /* The mapping between symbol names and symbols. */
550-const struct {
551+LT@&t@_DLSYM_CONST struct {
552 const char *name;
553 void *address;
554 }
555@@ -3497,15 +3737,15 @@ static const void *lt_preloaded_setup()
556 _LT_EOF
557 # Now try linking the two files.
558 mv conftest.$ac_objext conftstm.$ac_objext
559- lt_save_LIBS="$LIBS"
560- lt_save_CFLAGS="$CFLAGS"
561+ lt_globsym_save_LIBS=$LIBS
562+ lt_globsym_save_CFLAGS=$CFLAGS
563 LIBS="conftstm.$ac_objext"
564 CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
565 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
566 pipe_works=yes
567 fi
568- LIBS="$lt_save_LIBS"
569- CFLAGS="$lt_save_CFLAGS"
570+ LIBS=$lt_globsym_save_LIBS
571+ CFLAGS=$lt_globsym_save_CFLAGS
572 else
573 echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
574 fi
575@@ -3538,6 +3778,13 @@ else
576 AC_MSG_RESULT(ok)
577 fi
578
579+# Response file support.
580+if test "$lt_cv_nm_interface" = "MS dumpbin"; then
581+ nm_file_list_spec='@'
582+elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then
583+ nm_file_list_spec='@'
584+fi
585+
586 _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
587 [Take the output of nm and produce a listing of raw symbols and C names])
588 _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
589@@ -3548,6 +3795,8 @@ _LT_DECL([global_symbol_to_c_name_addres
590 _LT_DECL([global_symbol_to_c_name_address_lib_prefix],
591 [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
592 [Transform the output of nm in a C name address pair when lib prefix is needed])
593+_LT_DECL([], [nm_file_list_spec], [1],
594+ [Specify filename containing input files for $NM])
595 ]) # _LT_CMD_GLOBAL_SYMBOLS
596
597
598@@ -3559,7 +3808,6 @@ _LT_TAGVAR(lt_prog_compiler_wl, $1)=
599 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
600 _LT_TAGVAR(lt_prog_compiler_static, $1)=
601
602-AC_MSG_CHECKING([for $compiler option to produce PIC])
603 m4_if([$1], [CXX], [
604 # C++ specific cases for pic, static, wl, etc.
605 if test "$GXX" = yes; then
606@@ -3664,6 +3912,12 @@ m4_if([$1], [CXX], [
607 ;;
608 esac
609 ;;
610+ mingw* | cygwin* | os2* | pw32* | cegcc*)
611+ # This hack is so that the source file can tell whether it is being
612+ # built for inclusion in a dll (and should export symbols for example).
613+ m4_if([$1], [GCJ], [],
614+ [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
615+ ;;
616 dgux*)
617 case $cc_basename in
618 ec++*)
619@@ -3816,7 +4070,7 @@ m4_if([$1], [CXX], [
620 ;;
621 solaris*)
622 case $cc_basename in
623- CC*)
624+ CC* | sunCC*)
625 # Sun C++ 4.2, 5.x and Centerline C++
626 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
627 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
628@@ -4038,6 +4292,12 @@ m4_if([$1], [CXX], [
629 _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared'
630 _LT_TAGVAR(lt_prog_compiler_static, $1)='--static'
631 ;;
632+ nagfor*)
633+ # NAG Fortran compiler
634+ _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,'
635+ _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
636+ _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
637+ ;;
638 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
639 # Portland Group compilers (*not* the Pentium gcc compiler,
640 # which looks to be a dead project)
641@@ -4100,7 +4360,7 @@ m4_if([$1], [CXX], [
642 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
643 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
644 case $cc_basename in
645- f77* | f90* | f95*)
646+ f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
647 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
648 *)
649 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
650@@ -4157,9 +4417,11 @@ case $host_os in
651 _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])"
652 ;;
653 esac
654-AC_MSG_RESULT([$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
655-_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
656- [How to pass a linker flag through the compiler])
657+
658+AC_CACHE_CHECK([for $compiler option to produce PIC],
659+ [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)],
660+ [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
661+_LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)
662
663 #
664 # Check to make sure the PIC flag actually works.
665@@ -4178,6 +4440,8 @@ fi
666 _LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1],
667 [Additional compiler flags for building library objects])
668
669+_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
670+ [How to pass a linker flag through the compiler])
671 #
672 # Check to make sure the static flag actually works.
673 #
674@@ -4198,6 +4462,7 @@ _LT_TAGDECL([link_static_flag], [lt_prog
675 m4_defun([_LT_LINKER_SHLIBS],
676 [AC_REQUIRE([LT_PATH_LD])dnl
677 AC_REQUIRE([LT_PATH_NM])dnl
678+m4_require([_LT_PATH_MANIFEST_TOOL])dnl
679 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
680 m4_require([_LT_DECL_EGREP])dnl
681 m4_require([_LT_DECL_SED])dnl
682@@ -4206,6 +4471,7 @@ m4_require([_LT_TAG_COMPILER])dnl
683 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
684 m4_if([$1], [CXX], [
685 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
686+ _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
687 case $host_os in
688 aix[[4-9]]*)
689 # If we're using GNU nm, then we don't want the "-C" option.
690@@ -4220,15 +4486,20 @@ m4_if([$1], [CXX], [
691 ;;
692 pw32*)
693 _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
694- ;;
695+ ;;
696 cygwin* | mingw* | cegcc*)
697- _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
698- ;;
699+ case $cc_basename in
700+ cl*) ;;
701+ *)
702+ _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
703+ _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
704+ ;;
705+ esac
706+ ;;
707 *)
708 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
709- ;;
710+ ;;
711 esac
712- _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
713 ], [
714 runpath_var=
715 _LT_TAGVAR(allow_undefined_flag, $1)=
716@@ -4396,7 +4667,8 @@ _LT_EOF
717 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
718 _LT_TAGVAR(always_export_symbols, $1)=no
719 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
720- _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
721+ _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
722+ _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
723
724 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
725 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
726@@ -4444,7 +4716,7 @@ _LT_EOF
727 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
728 && test "$tmp_diet" = no
729 then
730- tmp_addflag=
731+ tmp_addflag=' $pic_flag'
732 tmp_sharedflag='-shared'
733 case $cc_basename,$host_cpu in
734 pgcc*) # Portland Group C compiler
735@@ -4495,12 +4767,12 @@ _LT_EOF
736 _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
737 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
738 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
739- _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
740+ _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
741 if test "x$supports_anon_versioning" = xyes; then
742 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
743 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
744 echo "local: *; };" >> $output_objdir/$libname.ver~
745- $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
746+ $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
747 fi
748 ;;
749 esac
750@@ -4514,8 +4786,8 @@ _LT_EOF
751 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
752 wlarc=
753 else
754- _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
755- _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
756+ _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
757+ _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
758 fi
759 ;;
760
761@@ -4533,8 +4805,8 @@ _LT_EOF
762
763 _LT_EOF
764 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
765- _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
766- _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
767+ _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
768+ _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
769 else
770 _LT_TAGVAR(ld_shlibs, $1)=no
771 fi
772@@ -4580,8 +4852,8 @@ _LT_EOF
773
774 *)
775 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
776- _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
777- _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
778+ _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
779+ _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
780 else
781 _LT_TAGVAR(ld_shlibs, $1)=no
782 fi
783@@ -4711,7 +4983,7 @@ _LT_EOF
784 _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
785 # Determine the default libpath from the value encoded in an
786 # empty executable.
787- _LT_SYS_MODULE_PATH_AIX
788+ _LT_SYS_MODULE_PATH_AIX([$1])
789 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
790 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
791 else
792@@ -4722,7 +4994,7 @@ _LT_EOF
793 else
794 # Determine the default libpath from the value encoded in an
795 # empty executable.
796- _LT_SYS_MODULE_PATH_AIX
797+ _LT_SYS_MODULE_PATH_AIX([$1])
798 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
799 # Warning - without using the other run time loading flags,
800 # -berok will link without error, but may produce a broken library.
801@@ -4766,20 +5038,63 @@ _LT_EOF
802 # Microsoft Visual C++.
803 # hardcode_libdir_flag_spec is actually meaningless, as there is
804 # no search path for DLLs.
805- _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
806- _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
807- # Tell ltmain to make .lib files, not .a files.
808- libext=lib
809- # Tell ltmain to make .dll files, not .so files.
810- shrext_cmds=".dll"
811- # FIXME: Setting linknames here is a bad hack.
812- _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
813- # The linker will automatically build a .lib file if we build a DLL.
814- _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
815- # FIXME: Should let the user specify the lib program.
816- _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
817- _LT_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`'
818- _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
819+ case $cc_basename in
820+ cl*)
821+ # Native MSVC
822+ _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
823+ _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
824+ _LT_TAGVAR(always_export_symbols, $1)=yes
825+ _LT_TAGVAR(file_list_spec, $1)='@'
826+ # Tell ltmain to make .lib files, not .a files.
827+ libext=lib
828+ # Tell ltmain to make .dll files, not .so files.
829+ shrext_cmds=".dll"
830+ # FIXME: Setting linknames here is a bad hack.
831+ _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
832+ _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
833+ sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
834+ else
835+ sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
836+ fi~
837+ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
838+ linknames='
839+ # The linker will not automatically build a static lib if we build a DLL.
840+ # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
841+ _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
842+ _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1,DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
843+ # Don't use ranlib
844+ _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
845+ _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
846+ lt_tool_outputfile="@TOOL_OUTPUT@"~
847+ case $lt_outputfile in
848+ *.exe|*.EXE) ;;
849+ *)
850+ lt_outputfile="$lt_outputfile.exe"
851+ lt_tool_outputfile="$lt_tool_outputfile.exe"
852+ ;;
853+ esac~
854+ if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
855+ $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
856+ $RM "$lt_outputfile.manifest";
857+ fi'
858+ ;;
859+ *)
860+ # Assume MSVC wrapper
861+ _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
862+ _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
863+ # Tell ltmain to make .lib files, not .a files.
864+ libext=lib
865+ # Tell ltmain to make .dll files, not .so files.
866+ shrext_cmds=".dll"
867+ # FIXME: Setting linknames here is a bad hack.
868+ _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
869+ # The linker will automatically build a .lib file if we build a DLL.
870+ _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
871+ # FIXME: Should let the user specify the lib program.
872+ _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
873+ _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
874+ ;;
875+ esac
876 ;;
877
878 darwin* | rhapsody*)
879@@ -4813,7 +5128,7 @@ _LT_EOF
880
881 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
882 freebsd* | dragonfly*)
883- _LT_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
884+ _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
885 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
886 _LT_TAGVAR(hardcode_direct, $1)=yes
887 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
888@@ -4821,7 +5136,7 @@ _LT_EOF
889
890 hpux9*)
891 if test "$GCC" = yes; then
892- _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
893+ _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
894 else
895 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
896 fi
897@@ -4837,7 +5152,7 @@ _LT_EOF
898
899 hpux10*)
900 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
901- _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
902+ _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
903 else
904 _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
905 fi
906@@ -4861,10 +5176,10 @@ _LT_EOF
907 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
908 ;;
909 ia64*)
910- _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
911+ _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
912 ;;
913 *)
914- _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
915+ _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
916 ;;
917 esac
918 else
919@@ -4911,16 +5226,31 @@ _LT_EOF
920
921 irix5* | irix6* | nonstopux*)
922 if test "$GCC" = yes; then
923- _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
924+ _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
925 # Try to use the -exported_symbol ld option, if it does not
926 # work, assume that -exports_file does not work either and
927 # implicitly export all symbols.
928- save_LDFLAGS="$LDFLAGS"
929- LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
930- AC_LINK_IFELSE(int foo(void) {},
931- _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
932- )
933- LDFLAGS="$save_LDFLAGS"
934+ # This should be the same for all languages, so no per-tag cache variable.
935+ AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol],
936+ [lt_cv_irix_exported_symbol],
937+ [save_LDFLAGS="$LDFLAGS"
938+ LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
939+ AC_LINK_IFELSE(
940+ [AC_LANG_SOURCE(
941+ [AC_LANG_CASE([C], [[int foo (void) { return 0; }]],
942+ [C++], [[int foo (void) { return 0; }]],
943+ [Fortran 77], [[
944+ subroutine foo
945+ end]],
946+ [Fortran], [[
947+ subroutine foo
948+ end]])])],
949+ [lt_cv_irix_exported_symbol=yes],
950+ [lt_cv_irix_exported_symbol=no])
951+ LDFLAGS="$save_LDFLAGS"])
952+ if test "$lt_cv_irix_exported_symbol" = yes; then
953+ _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
954+ fi
955 else
956 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
957 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
958@@ -5005,7 +5335,7 @@ _LT_EOF
959 osf4* | osf5*) # as osf3* with the addition of -msym flag
960 if test "$GCC" = yes; then
961 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
962- _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
963+ _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
964 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
965 else
966 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
967@@ -5024,9 +5354,9 @@ _LT_EOF
968 _LT_TAGVAR(no_undefined_flag, $1)=' -z defs'
969 if test "$GCC" = yes; then
970 wlarc='${wl}'
971- _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
972+ _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
973 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
974- $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
975+ $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
976 else
977 case `$CC -V 2>&1` in
978 *"Compilers 5.0"*)
979@@ -5298,8 +5628,6 @@ _LT_TAGDECL([], [inherit_rpath], [0],
980 to runtime path list])
981 _LT_TAGDECL([], [link_all_deplibs], [0],
982 [Whether libtool must link a program against all its dependency libraries])
983-_LT_TAGDECL([], [fix_srcfile_path], [1],
984- [Fix the shell variable $srcfile for the compiler])
985 _LT_TAGDECL([], [always_export_symbols], [0],
986 [Set to "yes" if exported symbols are required])
987 _LT_TAGDECL([], [export_symbols_cmds], [2],
988@@ -5310,6 +5638,8 @@ _LT_TAGDECL([], [include_expsyms], [1],
989 [Symbols that must always be exported])
990 _LT_TAGDECL([], [prelink_cmds], [2],
991 [Commands necessary for linking programs (against libraries) with templates])
992+_LT_TAGDECL([], [postlink_cmds], [2],
993+ [Commands necessary for finishing linking programs])
994 _LT_TAGDECL([], [file_list_spec], [1],
995 [Specify filename containing input files])
996 dnl FIXME: Not yet implemented
997@@ -5411,6 +5741,7 @@ CC="$lt_save_CC"
998 m4_defun([_LT_LANG_CXX_CONFIG],
999 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1000 m4_require([_LT_DECL_EGREP])dnl
1001+m4_require([_LT_PATH_MANIFEST_TOOL])dnl
1002 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
1003 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
1004 (test "X$CXX" != "Xg++"))) ; then
1005@@ -5472,6 +5803,7 @@ if test "$_lt_caught_CXX_error" != yes;
1006
1007 # Allow CC to be a program name with arguments.
1008 lt_save_CC=$CC
1009+ lt_save_CFLAGS=$CFLAGS
1010 lt_save_LD=$LD
1011 lt_save_GCC=$GCC
1012 GCC=$GXX
1013@@ -5489,6 +5821,7 @@ if test "$_lt_caught_CXX_error" != yes;
1014 fi
1015 test -z "${LDCXX+set}" || LD=$LDCXX
1016 CC=${CXX-"c++"}
1017+ CFLAGS=$CXXFLAGS
1018 compiler=$CC
1019 _LT_TAGVAR(compiler, $1)=$CC
1020 _LT_CC_BASENAME([$compiler])
1021@@ -5510,8 +5843,8 @@ if test "$_lt_caught_CXX_error" != yes;
1022 # Check if GNU C++ uses GNU ld as the underlying linker, since the
1023 # archiving commands below assume that GNU ld is being used.
1024 if test "$with_gnu_ld" = yes; then
1025- _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
1026- _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
1027+ _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
1028+ _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
1029
1030 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
1031 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
1032@@ -5652,7 +5985,7 @@ if test "$_lt_caught_CXX_error" != yes;
1033 _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
1034 # Determine the default libpath from the value encoded in an empty
1035 # executable.
1036- _LT_SYS_MODULE_PATH_AIX
1037+ _LT_SYS_MODULE_PATH_AIX([$1])
1038 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
1039
1040 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
1041@@ -5664,7 +5997,7 @@ if test "$_lt_caught_CXX_error" != yes;
1042 else
1043 # Determine the default libpath from the value encoded in an
1044 # empty executable.
1045- _LT_SYS_MODULE_PATH_AIX
1046+ _LT_SYS_MODULE_PATH_AIX([$1])
1047 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
1048 # Warning - without using the other run time loading flags,
1049 # -berok will link without error, but may produce a broken library.
1050@@ -5706,29 +6039,75 @@ if test "$_lt_caught_CXX_error" != yes;
1051 ;;
1052
1053 cygwin* | mingw* | pw32* | cegcc*)
1054- # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
1055- # as there is no search path for DLLs.
1056- _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
1057- _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
1058- _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
1059- _LT_TAGVAR(always_export_symbols, $1)=no
1060- _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
1061-
1062- if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
1063- _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
1064- # If the export-symbols file already is a .def file (1st line
1065- # is EXPORTS), use it as is; otherwise, prepend...
1066- _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
1067- cp $export_symbols $output_objdir/$soname.def;
1068- else
1069- echo EXPORTS > $output_objdir/$soname.def;
1070- cat $export_symbols >> $output_objdir/$soname.def;
1071- fi~
1072- $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
1073- else
1074- _LT_TAGVAR(ld_shlibs, $1)=no
1075- fi
1076- ;;
1077+ case $GXX,$cc_basename in
1078+ ,cl* | no,cl*)
1079+ # Native MSVC
1080+ # hardcode_libdir_flag_spec is actually meaningless, as there is
1081+ # no search path for DLLs.
1082+ _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
1083+ _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
1084+ _LT_TAGVAR(always_export_symbols, $1)=yes
1085+ _LT_TAGVAR(file_list_spec, $1)='@'
1086+ # Tell ltmain to make .lib files, not .a files.
1087+ libext=lib
1088+ # Tell ltmain to make .dll files, not .so files.
1089+ shrext_cmds=".dll"
1090+ # FIXME: Setting linknames here is a bad hack.
1091+ _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
1092+ _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
1093+ $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
1094+ else
1095+ $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
1096+ fi~
1097+ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
1098+ linknames='
1099+ # The linker will not automatically build a static lib if we build a DLL.
1100+ # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
1101+ _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
1102+ # Don't use ranlib
1103+ _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
1104+ _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
1105+ lt_tool_outputfile="@TOOL_OUTPUT@"~
1106+ case $lt_outputfile in
1107+ *.exe|*.EXE) ;;
1108+ *)
1109+ lt_outputfile="$lt_outputfile.exe"
1110+ lt_tool_outputfile="$lt_tool_outputfile.exe"
1111+ ;;
1112+ esac~
1113+ func_to_tool_file "$lt_outputfile"~
1114+ if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
1115+ $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
1116+ $RM "$lt_outputfile.manifest";
1117+ fi'
1118+ ;;
1119+ *)
1120+ # g++
1121+ # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
1122+ # as there is no search path for DLLs.
1123+ _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
1124+ _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
1125+ _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
1126+ _LT_TAGVAR(always_export_symbols, $1)=no
1127+ _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
1128+
1129+ if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
1130+ _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
1131+ # If the export-symbols file already is a .def file (1st line
1132+ # is EXPORTS), use it as is; otherwise, prepend...
1133+ _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
1134+ cp $export_symbols $output_objdir/$soname.def;
1135+ else
1136+ echo EXPORTS > $output_objdir/$soname.def;
1137+ cat $export_symbols >> $output_objdir/$soname.def;
1138+ fi~
1139+ $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
1140+ else
1141+ _LT_TAGVAR(ld_shlibs, $1)=no
1142+ fi
1143+ ;;
1144+ esac
1145+ ;;
1146 darwin* | rhapsody*)
1147 _LT_DARWIN_LINKER_FEATURES($1)
1148 ;;
1149@@ -5803,7 +6182,7 @@ if test "$_lt_caught_CXX_error" != yes;
1150 ;;
1151 *)
1152 if test "$GXX" = yes; then
1153- _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
1154+ _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
1155 else
1156 # FIXME: insert proper C++ library support
1157 _LT_TAGVAR(ld_shlibs, $1)=no
1158@@ -5874,10 +6253,10 @@ if test "$_lt_caught_CXX_error" != yes;
1159 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
1160 ;;
1161 ia64*)
1162- _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
1163+ _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
1164 ;;
1165 *)
1166- _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
1167+ _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
1168 ;;
1169 esac
1170 fi
1171@@ -5918,9 +6297,9 @@ if test "$_lt_caught_CXX_error" != yes;
1172 *)
1173 if test "$GXX" = yes; then
1174 if test "$with_gnu_ld" = no; then
1175- _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
1176+ _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
1177 else
1178- _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib'
1179+ _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib'
1180 fi
1181 fi
1182 _LT_TAGVAR(link_all_deplibs, $1)=yes
1183@@ -5990,20 +6369,20 @@ if test "$_lt_caught_CXX_error" != yes;
1184 _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
1185 rm -rf $tpldir~
1186 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
1187- compile_command="$compile_command `find $tpldir -name \*.o | $NL2SP`"'
1188+ compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
1189 _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~
1190 rm -rf $tpldir~
1191 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
1192- $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | $NL2SP`~
1193+ $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
1194 $RANLIB $oldlib'
1195 _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~
1196 rm -rf $tpldir~
1197 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
1198- $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
1199+ $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
1200 _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~
1201 rm -rf $tpldir~
1202 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
1203- $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
1204+ $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
1205 ;;
1206 *) # Version 6 and above use weak symbols
1207 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
1208@@ -6198,7 +6577,7 @@ if test "$_lt_caught_CXX_error" != yes;
1209 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
1210 ;;
1211 *)
1212- _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
1213+ _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
1214 ;;
1215 esac
1216
1217@@ -6244,7 +6623,7 @@ if test "$_lt_caught_CXX_error" != yes;
1218
1219 solaris*)
1220 case $cc_basename in
1221- CC*)
1222+ CC* | sunCC*)
1223 # Sun C++ 4.2, 5.x and Centerline C++
1224 _LT_TAGVAR(archive_cmds_need_lc,$1)=yes
1225 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
1226@@ -6285,9 +6664,9 @@ if test "$_lt_caught_CXX_error" != yes;
1227 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
1228 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
1229 if $CC --version | $GREP -v '^2\.7' > /dev/null; then
1230- _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
1231+ _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
1232 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
1233- $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
1234+ $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
1235
1236 # Commands to make compiler produce verbose output that lists
1237 # what "hidden" libraries, object files and flags are used when
1238@@ -6416,6 +6795,7 @@ if test "$_lt_caught_CXX_error" != yes;
1239 fi # test -n "$compiler"
1240
1241 CC=$lt_save_CC
1242+ CFLAGS=$lt_save_CFLAGS
1243 LDCXX=$LD
1244 LD=$lt_save_LD
1245 GCC=$lt_save_GCC
1246@@ -6430,6 +6810,29 @@ AC_LANG_POP
1247 ])# _LT_LANG_CXX_CONFIG
1248
1249
1250+# _LT_FUNC_STRIPNAME_CNF
1251+# ----------------------
1252+# func_stripname_cnf prefix suffix name
1253+# strip PREFIX and SUFFIX off of NAME.
1254+# PREFIX and SUFFIX must not contain globbing or regex special
1255+# characters, hashes, percent signs, but SUFFIX may contain a leading
1256+# dot (in which case that matches only a dot).
1257+#
1258+# This function is identical to the (non-XSI) version of func_stripname,
1259+# except this one can be used by m4 code that may be executed by configure,
1260+# rather than the libtool script.
1261+m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl
1262+AC_REQUIRE([_LT_DECL_SED])
1263+AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])
1264+func_stripname_cnf ()
1265+{
1266+ case ${2} in
1267+ .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
1268+ *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
1269+ esac
1270+} # func_stripname_cnf
1271+])# _LT_FUNC_STRIPNAME_CNF
1272+
1273 # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME])
1274 # ---------------------------------
1275 # Figure out "hidden" library dependencies from verbose
1276@@ -6438,6 +6841,7 @@ AC_LANG_POP
1277 # objects, libraries and library flags.
1278 m4_defun([_LT_SYS_HIDDEN_LIBDEPS],
1279 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1280+AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl
1281 # Dependencies to place before and after the object being linked:
1282 _LT_TAGVAR(predep_objects, $1)=
1283 _LT_TAGVAR(postdep_objects, $1)=
1284@@ -6488,6 +6892,13 @@ public class foo {
1285 };
1286 _LT_EOF
1287 ])
1288+
1289+_lt_libdeps_save_CFLAGS=$CFLAGS
1290+case "$CC $CFLAGS " in #(
1291+*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;;
1292+*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;;
1293+esac
1294+
1295 dnl Parse the compiler output and extract the necessary
1296 dnl objects, libraries and library flags.
1297 if AC_TRY_EVAL(ac_compile); then
1298@@ -6499,7 +6910,7 @@ if AC_TRY_EVAL(ac_compile); then
1299 pre_test_object_deps_done=no
1300
1301 for p in `eval "$output_verbose_link_cmd"`; do
1302- case $p in
1303+ case ${prev}${p} in
1304
1305 -L* | -R* | -l*)
1306 # Some compilers place space between "-{L,R}" and the path.
1307@@ -6508,13 +6919,22 @@ if AC_TRY_EVAL(ac_compile); then
1308 test $p = "-R"; then
1309 prev=$p
1310 continue
1311- else
1312- prev=
1313 fi
1314
1315+ # Expand the sysroot to ease extracting the directories later.
1316+ if test -z "$prev"; then
1317+ case $p in
1318+ -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;;
1319+ -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;;
1320+ -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;;
1321+ esac
1322+ fi
1323+ case $p in
1324+ =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
1325+ esac
1326 if test "$pre_test_object_deps_done" = no; then
1327- case $p in
1328- -L* | -R*)
1329+ case ${prev} in
1330+ -L | -R)
1331 # Internal compiler library paths should come after those
1332 # provided the user. The postdeps already come after the
1333 # user supplied libs so there is no need to process them.
1334@@ -6534,8 +6954,10 @@ if AC_TRY_EVAL(ac_compile); then
1335 _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}"
1336 fi
1337 fi
1338+ prev=
1339 ;;
1340
1341+ *.lto.$objext) ;; # Ignore GCC LTO objects
1342 *.$objext)
1343 # This assumes that the test object file only shows up
1344 # once in the compiler output.
1345@@ -6571,6 +6993,7 @@ else
1346 fi
1347
1348 $RM -f confest.$objext
1349+CFLAGS=$_lt_libdeps_save_CFLAGS
1350
1351 # PORTME: override above test on systems where it is broken
1352 m4_if([$1], [CXX],
1353@@ -6607,7 +7030,7 @@ linux*)
1354
1355 solaris*)
1356 case $cc_basename in
1357- CC*)
1358+ CC* | sunCC*)
1359 # The more standards-conforming stlport4 library is
1360 # incompatible with the Cstd library. Avoid specifying
1361 # it if it's in CXXFLAGS. Ignore libCrun as
1362@@ -6720,7 +7143,9 @@ if test "$_lt_disable_F77" != yes; then
1363 # Allow CC to be a program name with arguments.
1364 lt_save_CC="$CC"
1365 lt_save_GCC=$GCC
1366+ lt_save_CFLAGS=$CFLAGS
1367 CC=${F77-"f77"}
1368+ CFLAGS=$FFLAGS
1369 compiler=$CC
1370 _LT_TAGVAR(compiler, $1)=$CC
1371 _LT_CC_BASENAME([$compiler])
1372@@ -6774,6 +7199,7 @@ if test "$_lt_disable_F77" != yes; then
1373
1374 GCC=$lt_save_GCC
1375 CC="$lt_save_CC"
1376+ CFLAGS="$lt_save_CFLAGS"
1377 fi # test "$_lt_disable_F77" != yes
1378
1379 AC_LANG_POP
1380@@ -6850,7 +7276,9 @@ if test "$_lt_disable_FC" != yes; then
1381 # Allow CC to be a program name with arguments.
1382 lt_save_CC="$CC"
1383 lt_save_GCC=$GCC
1384+ lt_save_CFLAGS=$CFLAGS
1385 CC=${FC-"f95"}
1386+ CFLAGS=$FCFLAGS
1387 compiler=$CC
1388 GCC=$ac_cv_fc_compiler_gnu
1389
1390@@ -6906,7 +7334,8 @@ if test "$_lt_disable_FC" != yes; then
1391 fi # test -n "$compiler"
1392
1393 GCC=$lt_save_GCC
1394- CC="$lt_save_CC"
1395+ CC=$lt_save_CC
1396+ CFLAGS=$lt_save_CFLAGS
1397 fi # test "$_lt_disable_FC" != yes
1398
1399 AC_LANG_POP
1400@@ -6943,10 +7372,12 @@ _LT_COMPILER_BOILERPLATE
1401 _LT_LINKER_BOILERPLATE
1402
1403 # Allow CC to be a program name with arguments.
1404-lt_save_CC="$CC"
1405+lt_save_CC=$CC
1406+lt_save_CFLAGS=$CFLAGS
1407 lt_save_GCC=$GCC
1408 GCC=yes
1409 CC=${GCJ-"gcj"}
1410+CFLAGS=$GCJFLAGS
1411 compiler=$CC
1412 _LT_TAGVAR(compiler, $1)=$CC
1413 _LT_TAGVAR(LD, $1)="$LD"
1414@@ -6977,7 +7408,8 @@ fi
1415 AC_LANG_RESTORE
1416
1417 GCC=$lt_save_GCC
1418-CC="$lt_save_CC"
1419+CC=$lt_save_CC
1420+CFLAGS=$lt_save_CFLAGS
1421 ])# _LT_LANG_GCJ_CONFIG
1422
1423
1424@@ -7012,9 +7444,11 @@ _LT_LINKER_BOILERPLATE
1425
1426 # Allow CC to be a program name with arguments.
1427 lt_save_CC="$CC"
1428+lt_save_CFLAGS=$CFLAGS
1429 lt_save_GCC=$GCC
1430 GCC=
1431 CC=${RC-"windres"}
1432+CFLAGS=
1433 compiler=$CC
1434 _LT_TAGVAR(compiler, $1)=$CC
1435 _LT_CC_BASENAME([$compiler])
1436@@ -7027,7 +7461,8 @@ fi
1437
1438 GCC=$lt_save_GCC
1439 AC_LANG_RESTORE
1440-CC="$lt_save_CC"
1441+CC=$lt_save_CC
1442+CFLAGS=$lt_save_CFLAGS
1443 ])# _LT_LANG_RC_CONFIG
1444
1445
1446@@ -7086,6 +7521,15 @@ _LT_DECL([], [OBJDUMP], [1], [An object
1447 AC_SUBST([OBJDUMP])
1448 ])
1449
1450+# _LT_DECL_DLLTOOL
1451+# ----------------
1452+# Ensure DLLTOOL variable is set.
1453+m4_defun([_LT_DECL_DLLTOOL],
1454+[AC_CHECK_TOOL(DLLTOOL, dlltool, false)
1455+test -z "$DLLTOOL" && DLLTOOL=dlltool
1456+_LT_DECL([], [DLLTOOL], [1], [DLL creation program])
1457+AC_SUBST([DLLTOOL])
1458+])
1459
1460 # _LT_DECL_SED
1461 # ------------
1462@@ -7179,8 +7623,8 @@ m4_defun([_LT_CHECK_SHELL_FEATURES],
1463 # Try some XSI features
1464 xsi_shell=no
1465 ( _lt_dummy="a/b/c"
1466- test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
1467- = c,a/b,, \
1468+ test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
1469+ = c,a/b,b/c, \
1470 && eval 'test $(( 1 + 1 )) -eq 2 \
1471 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
1472 && xsi_shell=yes
1473@@ -7219,206 +7663,162 @@ _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn
1474 ])# _LT_CHECK_SHELL_FEATURES
1475
1476
1477-# _LT_PROG_XSI_SHELLFNS
1478-# ---------------------
1479-# Bourne and XSI compatible variants of some useful shell functions.
1480-m4_defun([_LT_PROG_XSI_SHELLFNS],
1481-[case $xsi_shell in
1482- yes)
1483- cat << \_LT_EOF >> "$cfgfile"
1484-
1485-# func_dirname file append nondir_replacement
1486-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
1487-# otherwise set result to NONDIR_REPLACEMENT.
1488-func_dirname ()
1489-{
1490- case ${1} in
1491- */*) func_dirname_result="${1%/*}${2}" ;;
1492- * ) func_dirname_result="${3}" ;;
1493- esac
1494-}
1495-
1496-# func_basename file
1497-func_basename ()
1498-{
1499- func_basename_result="${1##*/}"
1500-}
1501-
1502-# func_dirname_and_basename file append nondir_replacement
1503-# perform func_basename and func_dirname in a single function
1504-# call:
1505-# dirname: Compute the dirname of FILE. If nonempty,
1506-# add APPEND to the result, otherwise set result
1507-# to NONDIR_REPLACEMENT.
1508-# value returned in "$func_dirname_result"
1509-# basename: Compute filename of FILE.
1510-# value retuned in "$func_basename_result"
1511-# Implementation must be kept synchronized with func_dirname
1512-# and func_basename. For efficiency, we do not delegate to
1513-# those functions but instead duplicate the functionality here.
1514-func_dirname_and_basename ()
1515-{
1516- case ${1} in
1517- */*) func_dirname_result="${1%/*}${2}" ;;
1518- * ) func_dirname_result="${3}" ;;
1519- esac
1520- func_basename_result="${1##*/}"
1521-}
1522-
1523-# func_stripname prefix suffix name
1524-# strip PREFIX and SUFFIX off of NAME.
1525-# PREFIX and SUFFIX must not contain globbing or regex special
1526-# characters, hashes, percent signs, but SUFFIX may contain a leading
1527-# dot (in which case that matches only a dot).
1528-func_stripname ()
1529-{
1530- # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
1531- # positional parameters, so assign one to ordinary parameter first.
1532- func_stripname_result=${3}
1533- func_stripname_result=${func_stripname_result#"${1}"}
1534- func_stripname_result=${func_stripname_result%"${2}"}
1535-}
1536-
1537-# func_opt_split
1538-func_opt_split ()
1539-{
1540- func_opt_split_opt=${1%%=*}
1541- func_opt_split_arg=${1#*=}
1542-}
1543-
1544-# func_lo2o object
1545-func_lo2o ()
1546-{
1547- case ${1} in
1548- *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
1549- *) func_lo2o_result=${1} ;;
1550- esac
1551-}
1552-
1553-# func_xform libobj-or-source
1554-func_xform ()
1555-{
1556- func_xform_result=${1%.*}.lo
1557-}
1558-
1559-# func_arith arithmetic-term...
1560-func_arith ()
1561-{
1562- func_arith_result=$(( $[*] ))
1563-}
1564-
1565-# func_len string
1566-# STRING may not start with a hyphen.
1567-func_len ()
1568-{
1569- func_len_result=${#1}
1570-}
1571-
1572-_LT_EOF
1573- ;;
1574- *) # Bourne compatible functions.
1575- cat << \_LT_EOF >> "$cfgfile"
1576-
1577-# func_dirname file append nondir_replacement
1578-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
1579-# otherwise set result to NONDIR_REPLACEMENT.
1580-func_dirname ()
1581-{
1582- # Extract subdirectory from the argument.
1583- func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
1584- if test "X$func_dirname_result" = "X${1}"; then
1585- func_dirname_result="${3}"
1586- else
1587- func_dirname_result="$func_dirname_result${2}"
1588- fi
1589-}
1590-
1591-# func_basename file
1592-func_basename ()
1593-{
1594- func_basename_result=`$ECHO "${1}" | $SED "$basename"`
1595-}
1596+# _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY)
1597+# ------------------------------------------------------
1598+# In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and
1599+# '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY.
1600+m4_defun([_LT_PROG_FUNCTION_REPLACE],
1601+[dnl {
1602+sed -e '/^$1 ()$/,/^} # $1 /c\
1603+$1 ()\
1604+{\
1605+m4_bpatsubsts([$2], [$], [\\], [^\([ ]\)], [\\\1])
1606+} # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \
1607+ && mv -f "$cfgfile.tmp" "$cfgfile" \
1608+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
1609+test 0 -eq $? || _lt_function_replace_fail=:
1610+])
1611
1612-dnl func_dirname_and_basename
1613-dnl A portable version of this function is already defined in general.m4sh
1614-dnl so there is no need for it here.
1615
1616-# func_stripname prefix suffix name
1617-# strip PREFIX and SUFFIX off of NAME.
1618-# PREFIX and SUFFIX must not contain globbing or regex special
1619-# characters, hashes, percent signs, but SUFFIX may contain a leading
1620-# dot (in which case that matches only a dot).
1621-# func_strip_suffix prefix name
1622-func_stripname ()
1623-{
1624- case ${2} in
1625- .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
1626- *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
1627- esac
1628-}
1629+# _LT_PROG_REPLACE_SHELLFNS
1630+# -------------------------
1631+# Replace existing portable implementations of several shell functions with
1632+# equivalent extended shell implementations where those features are available..
1633+m4_defun([_LT_PROG_REPLACE_SHELLFNS],
1634+[if test x"$xsi_shell" = xyes; then
1635+ _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl
1636+ case ${1} in
1637+ */*) func_dirname_result="${1%/*}${2}" ;;
1638+ * ) func_dirname_result="${3}" ;;
1639+ esac])
1640+
1641+ _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl
1642+ func_basename_result="${1##*/}"])
1643+
1644+ _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl
1645+ case ${1} in
1646+ */*) func_dirname_result="${1%/*}${2}" ;;
1647+ * ) func_dirname_result="${3}" ;;
1648+ esac
1649+ func_basename_result="${1##*/}"])
1650
1651-# sed scripts:
1652-my_sed_long_opt='1s/^\(-[[^=]]*\)=.*/\1/;q'
1653-my_sed_long_arg='1s/^-[[^=]]*=//'
1654+ _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl
1655+ # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
1656+ # positional parameters, so assign one to ordinary parameter first.
1657+ func_stripname_result=${3}
1658+ func_stripname_result=${func_stripname_result#"${1}"}
1659+ func_stripname_result=${func_stripname_result%"${2}"}])
1660+
1661+ _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl
1662+ func_split_long_opt_name=${1%%=*}
1663+ func_split_long_opt_arg=${1#*=}])
1664+
1665+ _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl
1666+ func_split_short_opt_arg=${1#??}
1667+ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}])
1668+
1669+ _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl
1670+ case ${1} in
1671+ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
1672+ *) func_lo2o_result=${1} ;;
1673+ esac])
1674
1675-# func_opt_split
1676-func_opt_split ()
1677-{
1678- func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"`
1679- func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"`
1680-}
1681+ _LT_PROG_FUNCTION_REPLACE([func_xform], [ func_xform_result=${1%.*}.lo])
1682
1683-# func_lo2o object
1684-func_lo2o ()
1685-{
1686- func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
1687-}
1688+ _LT_PROG_FUNCTION_REPLACE([func_arith], [ func_arith_result=$(( $[*] ))])
1689
1690-# func_xform libobj-or-source
1691-func_xform ()
1692-{
1693- func_xform_result=`$ECHO "${1}" | $SED 's/\.[[^.]]*$/.lo/'`
1694-}
1695+ _LT_PROG_FUNCTION_REPLACE([func_len], [ func_len_result=${#1}])
1696+fi
1697
1698-# func_arith arithmetic-term...
1699-func_arith ()
1700-{
1701- func_arith_result=`expr "$[@]"`
1702-}
1703+if test x"$lt_shell_append" = xyes; then
1704+ _LT_PROG_FUNCTION_REPLACE([func_append], [ eval "${1}+=\\${2}"])
1705
1706-# func_len string
1707-# STRING may not start with a hyphen.
1708-func_len ()
1709-{
1710- func_len_result=`expr "$[1]" : ".*" 2>/dev/null || echo $max_cmd_len`
1711-}
1712+ _LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl
1713+ func_quote_for_eval "${2}"
1714+dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \
1715+ eval "${1}+=\\\\ \\$func_quote_for_eval_result"])
1716+
1717+ # Save a `func_append' function call where possible by direct use of '+='
1718+ sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
1719+ && mv -f "$cfgfile.tmp" "$cfgfile" \
1720+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
1721+ test 0 -eq $? || _lt_function_replace_fail=:
1722+else
1723+ # Save a `func_append' function call even when '+=' is not available
1724+ sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
1725+ && mv -f "$cfgfile.tmp" "$cfgfile" \
1726+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
1727+ test 0 -eq $? || _lt_function_replace_fail=:
1728+fi
1729
1730-_LT_EOF
1731-esac
1732+if test x"$_lt_function_replace_fail" = x":"; then
1733+ AC_MSG_WARN([Unable to substitute extended shell functions in $ofile])
1734+fi
1735+])
1736
1737-case $lt_shell_append in
1738- yes)
1739- cat << \_LT_EOF >> "$cfgfile"
1740-
1741-# func_append var value
1742-# Append VALUE to the end of shell variable VAR.
1743-func_append ()
1744-{
1745- eval "$[1]+=\$[2]"
1746-}
1747-_LT_EOF
1748+# _LT_PATH_CONVERSION_FUNCTIONS
1749+# -----------------------------
1750+# Determine which file name conversion functions should be used by
1751+# func_to_host_file (and, implicitly, by func_to_host_path). These are needed
1752+# for certain cross-compile configurations and native mingw.
1753+m4_defun([_LT_PATH_CONVERSION_FUNCTIONS],
1754+[AC_REQUIRE([AC_CANONICAL_HOST])dnl
1755+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
1756+AC_MSG_CHECKING([how to convert $build file names to $host format])
1757+AC_CACHE_VAL(lt_cv_to_host_file_cmd,
1758+[case $host in
1759+ *-*-mingw* )
1760+ case $build in
1761+ *-*-mingw* ) # actually msys
1762+ lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
1763+ ;;
1764+ *-*-cygwin* )
1765+ lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
1766+ ;;
1767+ * ) # otherwise, assume *nix
1768+ lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
1769+ ;;
1770+ esac
1771 ;;
1772- *)
1773- cat << \_LT_EOF >> "$cfgfile"
1774-
1775-# func_append var value
1776-# Append VALUE to the end of shell variable VAR.
1777-func_append ()
1778-{
1779- eval "$[1]=\$$[1]\$[2]"
1780-}
1781-
1782-_LT_EOF
1783+ *-*-cygwin* )
1784+ case $build in
1785+ *-*-mingw* ) # actually msys
1786+ lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
1787+ ;;
1788+ *-*-cygwin* )
1789+ lt_cv_to_host_file_cmd=func_convert_file_noop
1790+ ;;
1791+ * ) # otherwise, assume *nix
1792+ lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
1793+ ;;
1794+ esac
1795 ;;
1796- esac
1797+ * ) # unhandled hosts (and "normal" native builds)
1798+ lt_cv_to_host_file_cmd=func_convert_file_noop
1799+ ;;
1800+esac
1801+])
1802+to_host_file_cmd=$lt_cv_to_host_file_cmd
1803+AC_MSG_RESULT([$lt_cv_to_host_file_cmd])
1804+_LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd],
1805+ [0], [convert $build file names to $host format])dnl
1806+
1807+AC_MSG_CHECKING([how to convert $build file names to toolchain format])
1808+AC_CACHE_VAL(lt_cv_to_tool_file_cmd,
1809+[#assume ordinary cross tools, or native build.
1810+lt_cv_to_tool_file_cmd=func_convert_file_noop
1811+case $host in
1812+ *-*-mingw* )
1813+ case $build in
1814+ *-*-mingw* ) # actually msys
1815+ lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
1816+ ;;
1817+ esac
1818+ ;;
1819+esac
1820 ])
1821+to_tool_file_cmd=$lt_cv_to_tool_file_cmd
1822+AC_MSG_RESULT([$lt_cv_to_tool_file_cmd])
1823+_LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd],
1824+ [0], [convert $build files to toolchain format])dnl
1825+])# _LT_PATH_CONVERSION_FUNCTIONS
1826Index: binutils-2.22/ltmain.sh
1827===================================================================
1828--- binutils-2.22.orig/ltmain.sh
1829+++ binutils-2.22/ltmain.sh
1830@@ -1,10 +1,9 @@
1831-# Generated from ltmain.m4sh.
1832
1833-# libtool (GNU libtool 1.3134 2009-11-29) 2.2.7a
1834+# libtool (GNU libtool) 2.4
1835 # Written by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
1836
1837 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006,
1838-# 2007, 2008, 2009 Free Software Foundation, Inc.
1839+# 2007, 2008, 2009, 2010 Free Software Foundation, Inc.
1840 # This is free software; see the source for copying conditions. There is NO
1841 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
1842
1843@@ -38,7 +37,6 @@
1844 # -n, --dry-run display commands without modifying any files
1845 # --features display basic configuration information and exit
1846 # --mode=MODE use operation mode MODE
1847-# --no-finish let install mode avoid finish commands
1848 # --preserve-dup-deps don't remove duplicate dependency libraries
1849 # --quiet, --silent don't print informational messages
1850 # --no-quiet, --no-silent
1851@@ -71,17 +69,19 @@
1852 # compiler: $LTCC
1853 # compiler flags: $LTCFLAGS
1854 # linker: $LD (gnu? $with_gnu_ld)
1855-# $progname: (GNU libtool 1.3134 2009-11-29) 2.2.7a
1856+# $progname: (GNU libtool) 2.4
1857 # automake: $automake_version
1858 # autoconf: $autoconf_version
1859 #
1860 # Report bugs to <bug-libtool@gnu.org>.
1861+# GNU libtool home page: <http://www.gnu.org/software/libtool/>.
1862+# General help using GNU software: <http://www.gnu.org/gethelp/>.
1863
1864 PROGRAM=libtool
1865 PACKAGE=libtool
1866-VERSION=2.2.7a
1867-TIMESTAMP=" 1.3134 2009-11-29"
1868-package_revision=1.3134
1869+VERSION=2.4
1870+TIMESTAMP=""
1871+package_revision=1.3293
1872
1873 # Be Bourne compatible
1874 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
1875@@ -106,9 +106,6 @@ _LTECHO_EOF'
1876 }
1877
1878 # NLS nuisances: We save the old values to restore during execute mode.
1879-# Only set LANG and LC_ALL to C if already set.
1880-# These must not be set unconditionally because not all systems understand
1881-# e.g. LANG=C (notably SCO).
1882 lt_user_locale=
1883 lt_safe_locale=
1884 for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES
1885@@ -121,15 +118,13 @@ do
1886 lt_safe_locale=\"$lt_var=C; \$lt_safe_locale\"
1887 fi"
1888 done
1889+LC_ALL=C
1890+LANGUAGE=C
1891+export LANGUAGE LC_ALL
1892
1893 $lt_unset CDPATH
1894
1895
1896-
1897-
1898-
1899-
1900-
1901 # Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh
1902 # is ksh but when the shell is invoked as "sh" and the current value of
1903 # the _XPG environment variable is not equal to 1 (one), the special
1904@@ -140,7 +135,7 @@ progpath="$0"
1905
1906
1907 : ${CP="cp -f"}
1908-: ${ECHO=$as_echo}
1909+test "${ECHO+set}" = set || ECHO=${as_echo-'printf %s\n'}
1910 : ${EGREP="/bin/grep -E"}
1911 : ${FGREP="/bin/grep -F"}
1912 : ${GREP="/bin/grep"}
1913@@ -149,7 +144,7 @@ progpath="$0"
1914 : ${MKDIR="mkdir"}
1915 : ${MV="mv -f"}
1916 : ${RM="rm -f"}
1917-: ${SED="/mount/endor/wildenhu/local-x86_64/bin/sed"}
1918+: ${SED="/bin/sed"}
1919 : ${SHELL="${CONFIG_SHELL-/bin/sh}"}
1920 : ${Xsed="$SED -e 1s/^X//"}
1921
1922@@ -169,6 +164,27 @@ IFS=" $lt_nl"
1923 dirname="s,/[^/]*$,,"
1924 basename="s,^.*/,,"
1925
1926+# func_dirname file append nondir_replacement
1927+# Compute the dirname of FILE. If nonempty, add APPEND to the result,
1928+# otherwise set result to NONDIR_REPLACEMENT.
1929+func_dirname ()
1930+{
1931+ func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
1932+ if test "X$func_dirname_result" = "X${1}"; then
1933+ func_dirname_result="${3}"
1934+ else
1935+ func_dirname_result="$func_dirname_result${2}"
1936+ fi
1937+} # func_dirname may be replaced by extended shell implementation
1938+
1939+
1940+# func_basename file
1941+func_basename ()
1942+{
1943+ func_basename_result=`$ECHO "${1}" | $SED "$basename"`
1944+} # func_basename may be replaced by extended shell implementation
1945+
1946+
1947 # func_dirname_and_basename file append nondir_replacement
1948 # perform func_basename and func_dirname in a single function
1949 # call:
1950@@ -183,17 +199,31 @@ basename="s,^.*/,,"
1951 # those functions but instead duplicate the functionality here.
1952 func_dirname_and_basename ()
1953 {
1954- # Extract subdirectory from the argument.
1955- func_dirname_result=`$ECHO "${1}" | $SED -e "$dirname"`
1956- if test "X$func_dirname_result" = "X${1}"; then
1957- func_dirname_result="${3}"
1958- else
1959- func_dirname_result="$func_dirname_result${2}"
1960- fi
1961- func_basename_result=`$ECHO "${1}" | $SED -e "$basename"`
1962-}
1963+ # Extract subdirectory from the argument.
1964+ func_dirname_result=`$ECHO "${1}" | $SED -e "$dirname"`
1965+ if test "X$func_dirname_result" = "X${1}"; then
1966+ func_dirname_result="${3}"
1967+ else
1968+ func_dirname_result="$func_dirname_result${2}"
1969+ fi
1970+ func_basename_result=`$ECHO "${1}" | $SED -e "$basename"`
1971+} # func_dirname_and_basename may be replaced by extended shell implementation
1972+
1973+
1974+# func_stripname prefix suffix name
1975+# strip PREFIX and SUFFIX off of NAME.
1976+# PREFIX and SUFFIX must not contain globbing or regex special
1977+# characters, hashes, percent signs, but SUFFIX may contain a leading
1978+# dot (in which case that matches only a dot).
1979+# func_strip_suffix prefix name
1980+func_stripname ()
1981+{
1982+ case ${2} in
1983+ .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
1984+ *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
1985+ esac
1986+} # func_stripname may be replaced by extended shell implementation
1987
1988-# Generated shell functions inserted here.
1989
1990 # These SED scripts presuppose an absolute path with a trailing slash.
1991 pathcar='s,^/\([^/]*\).*$,\1,'
1992@@ -376,6 +406,15 @@ sed_quote_subst='s/\([`"$\\]\)/\\\1/g'
1993 # Same as above, but do not quote variable references.
1994 double_quote_subst='s/\(["`\\]\)/\\\1/g'
1995
1996+# Sed substitution that turns a string into a regex matching for the
1997+# string literally.
1998+sed_make_literal_regex='s,[].[^$\\*\/],\\&,g'
1999+
2000+# Sed substitution that converts a w32 file name or path
2001+# which contains forward slashes, into one that contains
2002+# (escaped) backslashes. A very naive implementation.
2003+lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g'
2004+
2005 # Re-`\' parameter expansions in output of double_quote_subst that were
2006 # `\'-ed in input to the same. If an odd number of `\' preceded a '$'
2007 # in input to double_quote_subst, that '$' was protected from expansion.
2008@@ -404,7 +443,7 @@ opt_warning=:
2009 # name if it has been set yet.
2010 func_echo ()
2011 {
2012- $ECHO "$progname${mode+: }$mode: $*"
2013+ $ECHO "$progname: ${opt_mode+$opt_mode: }$*"
2014 }
2015
2016 # func_verbose arg...
2017@@ -430,14 +469,14 @@ func_echo_all ()
2018 # Echo program name prefixed message to standard error.
2019 func_error ()
2020 {
2021- $ECHO "$progname${mode+: }$mode: "${1+"$@"} 1>&2
2022+ $ECHO "$progname: ${opt_mode+$opt_mode: }"${1+"$@"} 1>&2
2023 }
2024
2025 # func_warning arg...
2026 # Echo program name prefixed warning message to standard error.
2027 func_warning ()
2028 {
2029- $opt_warning && $ECHO "$progname${mode+: }$mode: warning: "${1+"$@"} 1>&2
2030+ $opt_warning && $ECHO "$progname: ${opt_mode+$opt_mode: }warning: "${1+"$@"} 1>&2
2031
2032 # bash bug again:
2033 :
2034@@ -656,19 +695,35 @@ func_show_eval_locale ()
2035 fi
2036 }
2037
2038-
2039-
2040+# func_tr_sh
2041+# Turn $1 into a string suitable for a shell variable name.
2042+# Result is stored in $func_tr_sh_result. All characters
2043+# not in the set a-zA-Z0-9_ are replaced with '_'. Further,
2044+# if $1 begins with a digit, a '_' is prepended as well.
2045+func_tr_sh ()
2046+{
2047+ case $1 in
2048+ [0-9]* | *[!a-zA-Z0-9_]*)
2049+ func_tr_sh_result=`$ECHO "$1" | $SED 's/^\([0-9]\)/_\1/; s/[^a-zA-Z0-9_]/_/g'`
2050+ ;;
2051+ * )
2052+ func_tr_sh_result=$1
2053+ ;;
2054+ esac
2055+}
2056
2057
2058 # func_version
2059 # Echo version message to standard output and exit.
2060 func_version ()
2061 {
2062+ $opt_debug
2063+
2064 $SED -n '/(C)/!b go
2065 :more
2066 /\./!{
2067 N
2068- s/\n# //
2069+ s/\n# / /
2070 b more
2071 }
2072 :go
2073@@ -685,7 +740,9 @@ func_version ()
2074 # Echo short help message to standard output and exit.
2075 func_usage ()
2076 {
2077- $SED -n '/^# Usage:/,/^# *-h/ {
2078+ $opt_debug
2079+
2080+ $SED -n '/^# Usage:/,/^# *.*--help/ {
2081 s/^# //
2082 s/^# *$//
2083 s/\$progname/'$progname'/
2084@@ -701,7 +758,10 @@ func_usage ()
2085 # unless 'noexit' is passed as argument.
2086 func_help ()
2087 {
2088+ $opt_debug
2089+
2090 $SED -n '/^# Usage:/,/# Report bugs to/ {
2091+ :print
2092 s/^# //
2093 s/^# *$//
2094 s*\$progname*'$progname'*
2095@@ -714,7 +774,11 @@ func_help ()
2096 s/\$automake_version/'"`(automake --version) 2>/dev/null |$SED 1q`"'/
2097 s/\$autoconf_version/'"`(autoconf --version) 2>/dev/null |$SED 1q`"'/
2098 p
2099- }' < "$progpath"
2100+ d
2101+ }
2102+ /^# .* home page:/b print
2103+ /^# General help using/b print
2104+ ' < "$progpath"
2105 ret=$?
2106 if test -z "$1"; then
2107 exit $ret
2108@@ -726,12 +790,39 @@ func_help ()
2109 # exit_cmd.
2110 func_missing_arg ()
2111 {
2112- func_error "missing argument for $1"
2113+ $opt_debug
2114+
2115+ func_error "missing argument for $1."
2116 exit_cmd=exit
2117 }
2118
2119-exit_cmd=:
2120
2121+# func_split_short_opt shortopt
2122+# Set func_split_short_opt_name and func_split_short_opt_arg shell
2123+# variables after splitting SHORTOPT after the 2nd character.
2124+func_split_short_opt ()
2125+{
2126+ my_sed_short_opt='1s/^\(..\).*$/\1/;q'
2127+ my_sed_short_rest='1s/^..\(.*\)$/\1/;q'
2128+
2129+ func_split_short_opt_name=`$ECHO "$1" | $SED "$my_sed_short_opt"`
2130+ func_split_short_opt_arg=`$ECHO "$1" | $SED "$my_sed_short_rest"`
2131+} # func_split_short_opt may be replaced by extended shell implementation
2132+
2133+
2134+# func_split_long_opt longopt
2135+# Set func_split_long_opt_name and func_split_long_opt_arg shell
2136+# variables after splitting LONGOPT at the `=' sign.
2137+func_split_long_opt ()
2138+{
2139+ my_sed_long_opt='1s/^\(--[^=]*\)=.*/\1/;q'
2140+ my_sed_long_arg='1s/^--[^=]*=//'
2141+
2142+ func_split_long_opt_name=`$ECHO "$1" | $SED "$my_sed_long_opt"`
2143+ func_split_long_opt_arg=`$ECHO "$1" | $SED "$my_sed_long_arg"`
2144+} # func_split_long_opt may be replaced by extended shell implementation
2145+
2146+exit_cmd=:
2147
2148
2149
2150@@ -741,26 +832,64 @@ magic="%%%MAGIC variable%%%"
2151 magic_exe="%%%MAGIC EXE variable%%%"
2152
2153 # Global variables.
2154-# $mode is unset
2155 nonopt=
2156-execute_dlfiles=
2157 preserve_args=
2158 lo2o="s/\\.lo\$/.${objext}/"
2159 o2lo="s/\\.${objext}\$/.lo/"
2160 extracted_archives=
2161 extracted_serial=0
2162
2163-opt_dry_run=false
2164-opt_finish=:
2165-opt_duplicate_deps=false
2166-opt_silent=false
2167-opt_debug=:
2168-
2169 # If this variable is set in any of the actions, the command in it
2170 # will be execed at the end. This prevents here-documents from being
2171 # left over by shells.
2172 exec_cmd=
2173
2174+# func_append var value
2175+# Append VALUE to the end of shell variable VAR.
2176+func_append ()
2177+{
2178+ eval "${1}=\$${1}\${2}"
2179+} # func_append may be replaced by extended shell implementation
2180+
2181+# func_append_quoted var value
2182+# Quote VALUE and append to the end of shell variable VAR, separated
2183+# by a space.
2184+func_append_quoted ()
2185+{
2186+ func_quote_for_eval "${2}"
2187+ eval "${1}=\$${1}\\ \$func_quote_for_eval_result"
2188+} # func_append_quoted may be replaced by extended shell implementation
2189+
2190+
2191+# func_arith arithmetic-term...
2192+func_arith ()
2193+{
2194+ func_arith_result=`expr "${@}"`
2195+} # func_arith may be replaced by extended shell implementation
2196+
2197+
2198+# func_len string
2199+# STRING may not start with a hyphen.
2200+func_len ()
2201+{
2202+ func_len_result=`expr "${1}" : ".*" 2>/dev/null || echo $max_cmd_len`
2203+} # func_len may be replaced by extended shell implementation
2204+
2205+
2206+# func_lo2o object
2207+func_lo2o ()
2208+{
2209+ func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
2210+} # func_lo2o may be replaced by extended shell implementation
2211+
2212+
2213+# func_xform libobj-or-source
2214+func_xform ()
2215+{
2216+ func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
2217+} # func_xform may be replaced by extended shell implementation
2218+
2219+
2220 # func_fatal_configuration arg...
2221 # Echo program name prefixed message to standard error, followed by
2222 # a configuration failure hint, and exit.
2223@@ -850,130 +979,204 @@ func_enable_tag ()
2224 esac
2225 }
2226
2227-# Parse options once, thoroughly. This comes as soon as possible in
2228-# the script to make things like `libtool --version' happen quickly.
2229+# func_check_version_match
2230+# Ensure that we are using m4 macros, and libtool script from the same
2231+# release of libtool.
2232+func_check_version_match ()
2233 {
2234+ if test "$package_revision" != "$macro_revision"; then
2235+ if test "$VERSION" != "$macro_version"; then
2236+ if test -z "$macro_version"; then
2237+ cat >&2 <<_LT_EOF
2238+$progname: Version mismatch error. This is $PACKAGE $VERSION, but the
2239+$progname: definition of this LT_INIT comes from an older release.
2240+$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION
2241+$progname: and run autoconf again.
2242+_LT_EOF
2243+ else
2244+ cat >&2 <<_LT_EOF
2245+$progname: Version mismatch error. This is $PACKAGE $VERSION, but the
2246+$progname: definition of this LT_INIT comes from $PACKAGE $macro_version.
2247+$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION
2248+$progname: and run autoconf again.
2249+_LT_EOF
2250+ fi
2251+ else
2252+ cat >&2 <<_LT_EOF
2253+$progname: Version mismatch error. This is $PACKAGE $VERSION, revision $package_revision,
2254+$progname: but the definition of this LT_INIT comes from revision $macro_revision.
2255+$progname: You should recreate aclocal.m4 with macros from revision $package_revision
2256+$progname: of $PACKAGE $VERSION and run autoconf again.
2257+_LT_EOF
2258+ fi
2259+
2260+ exit $EXIT_MISMATCH
2261+ fi
2262+}
2263+
2264+
2265+# Shorthand for --mode=foo, only valid as the first argument
2266+case $1 in
2267+clean|clea|cle|cl)
2268+ shift; set dummy --mode clean ${1+"$@"}; shift
2269+ ;;
2270+compile|compil|compi|comp|com|co|c)
2271+ shift; set dummy --mode compile ${1+"$@"}; shift
2272+ ;;
2273+execute|execut|execu|exec|exe|ex|e)
2274+ shift; set dummy --mode execute ${1+"$@"}; shift
2275+ ;;
2276+finish|finis|fini|fin|fi|f)
2277+ shift; set dummy --mode finish ${1+"$@"}; shift
2278+ ;;
2279+install|instal|insta|inst|ins|in|i)
2280+ shift; set dummy --mode install ${1+"$@"}; shift
2281+ ;;
2282+link|lin|li|l)
2283+ shift; set dummy --mode link ${1+"$@"}; shift
2284+ ;;
2285+uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u)
2286+ shift; set dummy --mode uninstall ${1+"$@"}; shift
2287+ ;;
2288+esac
2289
2290- # Shorthand for --mode=foo, only valid as the first argument
2291- case $1 in
2292- clean|clea|cle|cl)
2293- shift; set dummy --mode clean ${1+"$@"}; shift
2294- ;;
2295- compile|compil|compi|comp|com|co|c)
2296- shift; set dummy --mode compile ${1+"$@"}; shift
2297- ;;
2298- execute|execut|execu|exec|exe|ex|e)
2299- shift; set dummy --mode execute ${1+"$@"}; shift
2300- ;;
2301- finish|finis|fini|fin|fi|f)
2302- shift; set dummy --mode finish ${1+"$@"}; shift
2303- ;;
2304- install|instal|insta|inst|ins|in|i)
2305- shift; set dummy --mode install ${1+"$@"}; shift
2306- ;;
2307- link|lin|li|l)
2308- shift; set dummy --mode link ${1+"$@"}; shift
2309- ;;
2310- uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u)
2311- shift; set dummy --mode uninstall ${1+"$@"}; shift
2312- ;;
2313- esac
2314
2315- # Parse non-mode specific arguments:
2316- while test "$#" -gt 0; do
2317+
2318+# Option defaults:
2319+opt_debug=:
2320+opt_dry_run=false
2321+opt_config=false
2322+opt_preserve_dup_deps=false
2323+opt_features=false
2324+opt_finish=false
2325+opt_help=false
2326+opt_help_all=false
2327+opt_silent=:
2328+opt_verbose=:
2329+opt_silent=false
2330+opt_verbose=false
2331+
2332+
2333+# Parse options once, thoroughly. This comes as soon as possible in the
2334+# script to make things like `--version' happen as quickly as we can.
2335+{
2336+ # this just eases exit handling
2337+ while test $# -gt 0; do
2338 opt="$1"
2339 shift
2340-
2341 case $opt in
2342- --config) func_config ;;
2343-
2344- --debug) preserve_args="$preserve_args $opt"
2345+ --debug|-x) opt_debug='set -x'
2346 func_echo "enabling shell trace mode"
2347- opt_debug='set -x'
2348 $opt_debug
2349 ;;
2350-
2351- -dlopen) test "$#" -eq 0 && func_missing_arg "$opt" && break
2352- execute_dlfiles="$execute_dlfiles $1"
2353- shift
2354+ --dry-run|--dryrun|-n)
2355+ opt_dry_run=:
2356 ;;
2357-
2358- --dry-run | -n) opt_dry_run=: ;;
2359- --features) func_features ;;
2360- --finish) mode="finish" ;;
2361- --no-finish) opt_finish=false ;;
2362-
2363- --mode) test "$#" -eq 0 && func_missing_arg "$opt" && break
2364- case $1 in
2365- # Valid mode arguments:
2366- clean) ;;
2367- compile) ;;
2368- execute) ;;
2369- finish) ;;
2370- install) ;;
2371- link) ;;
2372- relink) ;;
2373- uninstall) ;;
2374-
2375- # Catch anything else as an error
2376- *) func_error "invalid argument for $opt"
2377- exit_cmd=exit
2378- break
2379- ;;
2380- esac
2381-
2382- mode="$1"
2383+ --config)
2384+ opt_config=:
2385+func_config
2386+ ;;
2387+ --dlopen|-dlopen)
2388+ optarg="$1"
2389+ opt_dlopen="${opt_dlopen+$opt_dlopen
2390+}$optarg"
2391 shift
2392 ;;
2393-
2394 --preserve-dup-deps)
2395- opt_duplicate_deps=: ;;
2396-
2397- --quiet|--silent) preserve_args="$preserve_args $opt"
2398- opt_silent=:
2399- opt_verbose=false
2400+ opt_preserve_dup_deps=:
2401 ;;
2402-
2403- --no-quiet|--no-silent)
2404- preserve_args="$preserve_args $opt"
2405- opt_silent=false
2406+ --features)
2407+ opt_features=:
2408+func_features
2409 ;;
2410-
2411- --verbose| -v) preserve_args="$preserve_args $opt"
2412+ --finish)
2413+ opt_finish=:
2414+set dummy --mode finish ${1+"$@"}; shift
2415+ ;;
2416+ --help)
2417+ opt_help=:
2418+ ;;
2419+ --help-all)
2420+ opt_help_all=:
2421+opt_help=': help-all'
2422+ ;;
2423+ --mode)
2424+ test $# = 0 && func_missing_arg $opt && break
2425+ optarg="$1"
2426+ opt_mode="$optarg"
2427+case $optarg in
2428+ # Valid mode arguments:
2429+ clean|compile|execute|finish|install|link|relink|uninstall) ;;
2430+
2431+ # Catch anything else as an error
2432+ *) func_error "invalid argument for $opt"
2433+ exit_cmd=exit
2434+ break
2435+ ;;
2436+esac
2437+ shift
2438+ ;;
2439+ --no-silent|--no-quiet)
2440 opt_silent=false
2441- opt_verbose=:
2442+func_append preserve_args " $opt"
2443 ;;
2444-
2445- --no-verbose) preserve_args="$preserve_args $opt"
2446+ --no-verbose)
2447 opt_verbose=false
2448+func_append preserve_args " $opt"
2449 ;;
2450-
2451- --tag) test "$#" -eq 0 && func_missing_arg "$opt" && break
2452- preserve_args="$preserve_args $opt $1"
2453- func_enable_tag "$1" # tagname is set here
2454+ --silent|--quiet)
2455+ opt_silent=:
2456+func_append preserve_args " $opt"
2457+ opt_verbose=false
2458+ ;;
2459+ --verbose|-v)
2460+ opt_verbose=:
2461+func_append preserve_args " $opt"
2462+opt_silent=false
2463+ ;;
2464+ --tag)
2465+ test $# = 0 && func_missing_arg $opt && break
2466+ optarg="$1"
2467+ opt_tag="$optarg"
2468+func_append preserve_args " $opt $optarg"
2469+func_enable_tag "$optarg"
2470 shift
2471 ;;
2472
2473+ -\?|-h) func_usage ;;
2474+ --help) func_help ;;
2475+ --version) func_version ;;
2476+
2477 # Separate optargs to long options:
2478- -dlopen=*|--mode=*|--tag=*)
2479- func_opt_split "$opt"
2480- set dummy "$func_opt_split_opt" "$func_opt_split_arg" ${1+"$@"}
2481+ --*=*)
2482+ func_split_long_opt "$opt"
2483+ set dummy "$func_split_long_opt_name" "$func_split_long_opt_arg" ${1+"$@"}
2484 shift
2485 ;;
2486
2487- -\?|-h) func_usage ;;
2488- --help) opt_help=: ;;
2489- --help-all) opt_help=': help-all' ;;
2490- --version) func_version ;;
2491-
2492- -*) func_fatal_help "unrecognized option \`$opt'" ;;
2493-
2494- *) nonopt="$opt"
2495- break
2496+ # Separate non-argument short options:
2497+ -\?*|-h*|-n*|-v*)
2498+ func_split_short_opt "$opt"
2499+ set dummy "$func_split_short_opt_name" "-$func_split_short_opt_arg" ${1+"$@"}
2500+ shift
2501 ;;
2502+
2503+ --) break ;;
2504+ -*) func_fatal_help "unrecognized option \`$opt'" ;;
2505+ *) set dummy "$opt" ${1+"$@"}; shift; break ;;
2506 esac
2507 done
2508
2509+ # Validate options:
2510+
2511+ # save first non-option argument
2512+ if test "$#" -gt 0; then
2513+ nonopt="$opt"
2514+ shift
2515+ fi
2516+
2517+ # preserve --debug
2518+ test "$opt_debug" = : || func_append preserve_args " --debug"
2519
2520 case $host in
2521 *cygwin* | *mingw* | *pw32* | *cegcc*)
2522@@ -981,82 +1184,44 @@ func_enable_tag ()
2523 opt_duplicate_compiler_generated_deps=:
2524 ;;
2525 *)
2526- opt_duplicate_compiler_generated_deps=$opt_duplicate_deps
2527+ opt_duplicate_compiler_generated_deps=$opt_preserve_dup_deps
2528 ;;
2529 esac
2530
2531- # Having warned about all mis-specified options, bail out if
2532- # anything was wrong.
2533- $exit_cmd $EXIT_FAILURE
2534-}
2535+ $opt_help || {
2536+ # Sanity checks first:
2537+ func_check_version_match
2538
2539-# func_check_version_match
2540-# Ensure that we are using m4 macros, and libtool script from the same
2541-# release of libtool.
2542-func_check_version_match ()
2543-{
2544- if test "$package_revision" != "$macro_revision"; then
2545- if test "$VERSION" != "$macro_version"; then
2546- if test -z "$macro_version"; then
2547- cat >&2 <<_LT_EOF
2548-$progname: Version mismatch error. This is $PACKAGE $VERSION, but the
2549-$progname: definition of this LT_INIT comes from an older release.
2550-$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION
2551-$progname: and run autoconf again.
2552-_LT_EOF
2553- else
2554- cat >&2 <<_LT_EOF
2555-$progname: Version mismatch error. This is $PACKAGE $VERSION, but the
2556-$progname: definition of this LT_INIT comes from $PACKAGE $macro_version.
2557-$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION
2558-$progname: and run autoconf again.
2559-_LT_EOF
2560- fi
2561- else
2562- cat >&2 <<_LT_EOF
2563-$progname: Version mismatch error. This is $PACKAGE $VERSION, revision $package_revision,
2564-$progname: but the definition of this LT_INIT comes from revision $macro_revision.
2565-$progname: You should recreate aclocal.m4 with macros from revision $package_revision
2566-$progname: of $PACKAGE $VERSION and run autoconf again.
2567-_LT_EOF
2568+ if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then
2569+ func_fatal_configuration "not configured to build any kind of library"
2570 fi
2571
2572- exit $EXIT_MISMATCH
2573- fi
2574-}
2575-
2576+ # Darwin sucks
2577+ eval std_shrext=\"$shrext_cmds\"
2578
2579-## ----------- ##
2580-## Main. ##
2581-## ----------- ##
2582-
2583-$opt_help || {
2584- # Sanity checks first:
2585- func_check_version_match
2586-
2587- if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then
2588- func_fatal_configuration "not configured to build any kind of library"
2589- fi
2590+ # Only execute mode is allowed to have -dlopen flags.
2591+ if test -n "$opt_dlopen" && test "$opt_mode" != execute; then
2592+ func_error "unrecognized option \`-dlopen'"
2593+ $ECHO "$help" 1>&2
2594+ exit $EXIT_FAILURE
2595+ fi
2596
2597- test -z "$mode" && func_fatal_error "error: you must specify a MODE."
2598+ # Change the help message to a mode-specific one.
2599+ generic_help="$help"
2600+ help="Try \`$progname --help --mode=$opt_mode' for more information."
2601+ }
2602
2603
2604- # Darwin sucks
2605- eval "std_shrext=\"$shrext_cmds\""
2606+ # Bail if the options were screwed
2607+ $exit_cmd $EXIT_FAILURE
2608+}
2609
2610
2611- # Only execute mode is allowed to have -dlopen flags.
2612- if test -n "$execute_dlfiles" && test "$mode" != execute; then
2613- func_error "unrecognized option \`-dlopen'"
2614- $ECHO "$help" 1>&2
2615- exit $EXIT_FAILURE
2616- fi
2617
2618- # Change the help message to a mode-specific one.
2619- generic_help="$help"
2620- help="Try \`$progname --help --mode=$mode' for more information."
2621-}
2622
2623+## ----------- ##
2624+## Main. ##
2625+## ----------- ##
2626
2627 # func_lalib_p file
2628 # True iff FILE is a libtool `.la' library or `.lo' object file.
2629@@ -1121,12 +1286,9 @@ func_ltwrapper_executable_p ()
2630 # temporary ltwrapper_script.
2631 func_ltwrapper_scriptname ()
2632 {
2633- func_ltwrapper_scriptname_result=""
2634- if func_ltwrapper_executable_p "$1"; then
2635- func_dirname_and_basename "$1" "" "."
2636- func_stripname '' '.exe' "$func_basename_result"
2637- func_ltwrapper_scriptname_result="$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper"
2638- fi
2639+ func_dirname_and_basename "$1" "" "."
2640+ func_stripname '' '.exe' "$func_basename_result"
2641+ func_ltwrapper_scriptname_result="$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper"
2642 }
2643
2644 # func_ltwrapper_p file
2645@@ -1149,7 +1311,7 @@ func_execute_cmds ()
2646 save_ifs=$IFS; IFS='~'
2647 for cmd in $1; do
2648 IFS=$save_ifs
2649- eval "cmd=\"$cmd\""
2650+ eval cmd=\"$cmd\"
2651 func_show_eval "$cmd" "${2-:}"
2652 done
2653 IFS=$save_ifs
2654@@ -1172,6 +1334,37 @@ func_source ()
2655 }
2656
2657
2658+# func_resolve_sysroot PATH
2659+# Replace a leading = in PATH with a sysroot. Store the result into
2660+# func_resolve_sysroot_result
2661+func_resolve_sysroot ()
2662+{
2663+ func_resolve_sysroot_result=$1
2664+ case $func_resolve_sysroot_result in
2665+ =*)
2666+ func_stripname '=' '' "$func_resolve_sysroot_result"
2667+ func_resolve_sysroot_result=$lt_sysroot$func_stripname_result
2668+ ;;
2669+ esac
2670+}
2671+
2672+# func_replace_sysroot PATH
2673+# If PATH begins with the sysroot, replace it with = and
2674+# store the result into func_replace_sysroot_result.
2675+func_replace_sysroot ()
2676+{
2677+ case "$lt_sysroot:$1" in
2678+ ?*:"$lt_sysroot"*)
2679+ func_stripname "$lt_sysroot" '' "$1"
2680+ func_replace_sysroot_result="=$func_stripname_result"
2681+ ;;
2682+ *)
2683+ # Including no sysroot.
2684+ func_replace_sysroot_result=$1
2685+ ;;
2686+ esac
2687+}
2688+
2689 # func_infer_tag arg
2690 # Infer tagged configuration to use if any are available and
2691 # if one wasn't chosen via the "--tag" command line option.
2692@@ -1184,8 +1377,7 @@ func_infer_tag ()
2693 if test -n "$available_tags" && test -z "$tagname"; then
2694 CC_quoted=
2695 for arg in $CC; do
2696- func_quote_for_eval "$arg"
2697- CC_quoted="$CC_quoted $func_quote_for_eval_result"
2698+ func_append_quoted CC_quoted "$arg"
2699 done
2700 CC_expanded=`func_echo_all $CC`
2701 CC_quoted_expanded=`func_echo_all $CC_quoted`
2702@@ -1204,8 +1396,7 @@ func_infer_tag ()
2703 CC_quoted=
2704 for arg in $CC; do
2705 # Double-quote args containing other shell metacharacters.
2706- func_quote_for_eval "$arg"
2707- CC_quoted="$CC_quoted $func_quote_for_eval_result"
2708+ func_append_quoted CC_quoted "$arg"
2709 done
2710 CC_expanded=`func_echo_all $CC`
2711 CC_quoted_expanded=`func_echo_all $CC_quoted`
2712@@ -1274,6 +1465,486 @@ EOF
2713 }
2714 }
2715
2716+
2717+##################################################
2718+# FILE NAME AND PATH CONVERSION HELPER FUNCTIONS #
2719+##################################################
2720+
2721+# func_convert_core_file_wine_to_w32 ARG
2722+# Helper function used by file name conversion functions when $build is *nix,
2723+# and $host is mingw, cygwin, or some other w32 environment. Relies on a
2724+# correctly configured wine environment available, with the winepath program
2725+# in $build's $PATH.
2726+#
2727+# ARG is the $build file name to be converted to w32 format.
2728+# Result is available in $func_convert_core_file_wine_to_w32_result, and will
2729+# be empty on error (or when ARG is empty)
2730+func_convert_core_file_wine_to_w32 ()
2731+{
2732+ $opt_debug
2733+ func_convert_core_file_wine_to_w32_result="$1"
2734+ if test -n "$1"; then
2735+ # Unfortunately, winepath does not exit with a non-zero error code, so we
2736+ # are forced to check the contents of stdout. On the other hand, if the
2737+ # command is not found, the shell will set an exit code of 127 and print
2738+ # *an error message* to stdout. So we must check for both error code of
2739+ # zero AND non-empty stdout, which explains the odd construction:
2740+ func_convert_core_file_wine_to_w32_tmp=`winepath -w "$1" 2>/dev/null`
2741+ if test "$?" -eq 0 && test -n "${func_convert_core_file_wine_to_w32_tmp}"; then
2742+ func_convert_core_file_wine_to_w32_result=`$ECHO "$func_convert_core_file_wine_to_w32_tmp" |
2743+ $SED -e "$lt_sed_naive_backslashify"`
2744+ else
2745+ func_convert_core_file_wine_to_w32_result=
2746+ fi
2747+ fi
2748+}
2749+# end: func_convert_core_file_wine_to_w32
2750+
2751+
2752+# func_convert_core_path_wine_to_w32 ARG
2753+# Helper function used by path conversion functions when $build is *nix, and
2754+# $host is mingw, cygwin, or some other w32 environment. Relies on a correctly
2755+# configured wine environment available, with the winepath program in $build's
2756+# $PATH. Assumes ARG has no leading or trailing path separator characters.
2757+#
2758+# ARG is path to be converted from $build format to win32.
2759+# Result is available in $func_convert_core_path_wine_to_w32_result.
2760+# Unconvertible file (directory) names in ARG are skipped; if no directory names
2761+# are convertible, then the result may be empty.
2762+func_convert_core_path_wine_to_w32 ()
2763+{
2764+ $opt_debug
2765+ # unfortunately, winepath doesn't convert paths, only file names
2766+ func_convert_core_path_wine_to_w32_result=""
2767+ if test -n "$1"; then
2768+ oldIFS=$IFS
2769+ IFS=:
2770+ for func_convert_core_path_wine_to_w32_f in $1; do
2771+ IFS=$oldIFS
2772+ func_convert_core_file_wine_to_w32 "$func_convert_core_path_wine_to_w32_f"
2773+ if test -n "$func_convert_core_file_wine_to_w32_result" ; then
2774+ if test -z "$func_convert_core_path_wine_to_w32_result"; then
2775+ func_convert_core_path_wine_to_w32_result="$func_convert_core_file_wine_to_w32_result"
2776+ else
2777+ func_append func_convert_core_path_wine_to_w32_result ";$func_convert_core_file_wine_to_w32_result"
2778+ fi
2779+ fi
2780+ done
2781+ IFS=$oldIFS
2782+ fi
2783+}
2784+# end: func_convert_core_path_wine_to_w32
2785+
2786+
2787+# func_cygpath ARGS...
2788+# Wrapper around calling the cygpath program via LT_CYGPATH. This is used when
2789+# when (1) $build is *nix and Cygwin is hosted via a wine environment; or (2)
2790+# $build is MSYS and $host is Cygwin, or (3) $build is Cygwin. In case (1) or
2791+# (2), returns the Cygwin file name or path in func_cygpath_result (input
2792+# file name or path is assumed to be in w32 format, as previously converted
2793+# from $build's *nix or MSYS format). In case (3), returns the w32 file name
2794+# or path in func_cygpath_result (input file name or path is assumed to be in
2795+# Cygwin format). Returns an empty string on error.
2796+#
2797+# ARGS are passed to cygpath, with the last one being the file name or path to
2798+# be converted.
2799+#
2800+# Specify the absolute *nix (or w32) name to cygpath in the LT_CYGPATH
2801+# environment variable; do not put it in $PATH.
2802+func_cygpath ()
2803+{
2804+ $opt_debug
2805+ if test -n "$LT_CYGPATH" && test -f "$LT_CYGPATH"; then
2806+ func_cygpath_result=`$LT_CYGPATH "$@" 2>/dev/null`
2807+ if test "$?" -ne 0; then
2808+ # on failure, ensure result is empty
2809+ func_cygpath_result=
2810+ fi
2811+ else
2812+ func_cygpath_result=
2813+ func_error "LT_CYGPATH is empty or specifies non-existent file: \`$LT_CYGPATH'"
2814+ fi
2815+}
2816+#end: func_cygpath
2817+
2818+
2819+# func_convert_core_msys_to_w32 ARG
2820+# Convert file name or path ARG from MSYS format to w32 format. Return
2821+# result in func_convert_core_msys_to_w32_result.
2822+func_convert_core_msys_to_w32 ()
2823+{
2824+ $opt_debug
2825+ # awkward: cmd appends spaces to result
2826+ func_convert_core_msys_to_w32_result=`( cmd //c echo "$1" ) 2>/dev/null |
2827+ $SED -e 's/[ ]*$//' -e "$lt_sed_naive_backslashify"`
2828+}
2829+#end: func_convert_core_msys_to_w32
2830+
2831+
2832+# func_convert_file_check ARG1 ARG2
2833+# Verify that ARG1 (a file name in $build format) was converted to $host
2834+# format in ARG2. Otherwise, emit an error message, but continue (resetting
2835+# func_to_host_file_result to ARG1).
2836+func_convert_file_check ()
2837+{
2838+ $opt_debug
2839+ if test -z "$2" && test -n "$1" ; then
2840+ func_error "Could not determine host file name corresponding to"
2841+ func_error " \`$1'"
2842+ func_error "Continuing, but uninstalled executables may not work."
2843+ # Fallback:
2844+ func_to_host_file_result="$1"
2845+ fi
2846+}
2847+# end func_convert_file_check
2848+
2849+
2850+# func_convert_path_check FROM_PATHSEP TO_PATHSEP FROM_PATH TO_PATH
2851+# Verify that FROM_PATH (a path in $build format) was converted to $host
2852+# format in TO_PATH. Otherwise, emit an error message, but continue, resetting
2853+# func_to_host_file_result to a simplistic fallback value (see below).
2854+func_convert_path_check ()
2855+{
2856+ $opt_debug
2857+ if test -z "$4" && test -n "$3"; then
2858+ func_error "Could not determine the host path corresponding to"
2859+ func_error " \`$3'"
2860+ func_error "Continuing, but uninstalled executables may not work."
2861+ # Fallback. This is a deliberately simplistic "conversion" and
2862+ # should not be "improved". See libtool.info.
2863+ if test "x$1" != "x$2"; then
2864+ lt_replace_pathsep_chars="s|$1|$2|g"
2865+ func_to_host_path_result=`echo "$3" |
2866+ $SED -e "$lt_replace_pathsep_chars"`
2867+ else
2868+ func_to_host_path_result="$3"
2869+ fi
2870+ fi
2871+}
2872+# end func_convert_path_check
2873+
2874+
2875+# func_convert_path_front_back_pathsep FRONTPAT BACKPAT REPL ORIG
2876+# Modifies func_to_host_path_result by prepending REPL if ORIG matches FRONTPAT
2877+# and appending REPL if ORIG matches BACKPAT.
2878+func_convert_path_front_back_pathsep ()
2879+{
2880+ $opt_debug
2881+ case $4 in
2882+ $1 ) func_to_host_path_result="$3$func_to_host_path_result"
2883+ ;;
2884+ esac
2885+ case $4 in
2886+ $2 ) func_append func_to_host_path_result "$3"
2887+ ;;
2888+ esac
2889+}
2890+# end func_convert_path_front_back_pathsep
2891+
2892+
2893+##################################################
2894+# $build to $host FILE NAME CONVERSION FUNCTIONS #
2895+##################################################
2896+# invoked via `$to_host_file_cmd ARG'
2897+#
2898+# In each case, ARG is the path to be converted from $build to $host format.
2899+# Result will be available in $func_to_host_file_result.
2900+
2901+
2902+# func_to_host_file ARG
2903+# Converts the file name ARG from $build format to $host format. Return result
2904+# in func_to_host_file_result.
2905+func_to_host_file ()
2906+{
2907+ $opt_debug
2908+ $to_host_file_cmd "$1"
2909+}
2910+# end func_to_host_file
2911+
2912+
2913+# func_to_tool_file ARG LAZY
2914+# converts the file name ARG from $build format to toolchain format. Return
2915+# result in func_to_tool_file_result. If the conversion in use is listed
2916+# in (the comma separated) LAZY, no conversion takes place.
2917+func_to_tool_file ()
2918+{
2919+ $opt_debug
2920+ case ,$2, in
2921+ *,"$to_tool_file_cmd",*)
2922+ func_to_tool_file_result=$1
2923+ ;;
2924+ *)
2925+ $to_tool_file_cmd "$1"
2926+ func_to_tool_file_result=$func_to_host_file_result
2927+ ;;
2928+ esac
2929+}
2930+# end func_to_tool_file
2931+
2932+
2933+# func_convert_file_noop ARG
2934+# Copy ARG to func_to_host_file_result.
2935+func_convert_file_noop ()
2936+{
2937+ func_to_host_file_result="$1"
2938+}
2939+# end func_convert_file_noop
2940+
2941+
2942+# func_convert_file_msys_to_w32 ARG
2943+# Convert file name ARG from (mingw) MSYS to (mingw) w32 format; automatic
2944+# conversion to w32 is not available inside the cwrapper. Returns result in
2945+# func_to_host_file_result.
2946+func_convert_file_msys_to_w32 ()
2947+{
2948+ $opt_debug
2949+ func_to_host_file_result="$1"
2950+ if test -n "$1"; then
2951+ func_convert_core_msys_to_w32 "$1"
2952+ func_to_host_file_result="$func_convert_core_msys_to_w32_result"
2953+ fi
2954+ func_convert_file_check "$1" "$func_to_host_file_result"
2955+}
2956+# end func_convert_file_msys_to_w32
2957+
2958+
2959+# func_convert_file_cygwin_to_w32 ARG
2960+# Convert file name ARG from Cygwin to w32 format. Returns result in
2961+# func_to_host_file_result.
2962+func_convert_file_cygwin_to_w32 ()
2963+{
2964+ $opt_debug
2965+ func_to_host_file_result="$1"
2966+ if test -n "$1"; then
2967+ # because $build is cygwin, we call "the" cygpath in $PATH; no need to use
2968+ # LT_CYGPATH in this case.
2969+ func_to_host_file_result=`cygpath -m "$1"`
2970+ fi
2971+ func_convert_file_check "$1" "$func_to_host_file_result"
2972+}
2973+# end func_convert_file_cygwin_to_w32
2974+
2975+
2976+# func_convert_file_nix_to_w32 ARG
2977+# Convert file name ARG from *nix to w32 format. Requires a wine environment
2978+# and a working winepath. Returns result in func_to_host_file_result.
2979+func_convert_file_nix_to_w32 ()
2980+{
2981+ $opt_debug
2982+ func_to_host_file_result="$1"
2983+ if test -n "$1"; then
2984+ func_convert_core_file_wine_to_w32 "$1"
2985+ func_to_host_file_result="$func_convert_core_file_wine_to_w32_result"
2986+ fi
2987+ func_convert_file_check "$1" "$func_to_host_file_result"
2988+}
2989+# end func_convert_file_nix_to_w32
2990+
2991+
2992+# func_convert_file_msys_to_cygwin ARG
2993+# Convert file name ARG from MSYS to Cygwin format. Requires LT_CYGPATH set.
2994+# Returns result in func_to_host_file_result.
2995+func_convert_file_msys_to_cygwin ()
2996+{
2997+ $opt_debug
2998+ func_to_host_file_result="$1"
2999+ if test -n "$1"; then
3000+ func_convert_core_msys_to_w32 "$1"
3001+ func_cygpath -u "$func_convert_core_msys_to_w32_result"
3002+ func_to_host_file_result="$func_cygpath_result"
3003+ fi
3004+ func_convert_file_check "$1" "$func_to_host_file_result"
3005+}
3006+# end func_convert_file_msys_to_cygwin
3007+
3008+
3009+# func_convert_file_nix_to_cygwin ARG
3010+# Convert file name ARG from *nix to Cygwin format. Requires Cygwin installed
3011+# in a wine environment, working winepath, and LT_CYGPATH set. Returns result
3012+# in func_to_host_file_result.
3013+func_convert_file_nix_to_cygwin ()
3014+{
3015+ $opt_debug
3016+ func_to_host_file_result="$1"
3017+ if test -n "$1"; then
3018+ # convert from *nix to w32, then use cygpath to convert from w32 to cygwin.
3019+ func_convert_core_file_wine_to_w32 "$1"
3020+ func_cygpath -u "$func_convert_core_file_wine_to_w32_result"
3021+ func_to_host_file_result="$func_cygpath_result"
3022+ fi
3023+ func_convert_file_check "$1" "$func_to_host_file_result"
3024+}
3025+# end func_convert_file_nix_to_cygwin
3026+
3027+
3028+#############################################
3029+# $build to $host PATH CONVERSION FUNCTIONS #
3030+#############################################
3031+# invoked via `$to_host_path_cmd ARG'
3032+#
3033+# In each case, ARG is the path to be converted from $build to $host format.
3034+# The result will be available in $func_to_host_path_result.
3035+#
3036+# Path separators are also converted from $build format to $host format. If
3037+# ARG begins or ends with a path separator character, it is preserved (but
3038+# converted to $host format) on output.
3039+#
3040+# All path conversion functions are named using the following convention:
3041+# file name conversion function : func_convert_file_X_to_Y ()
3042+# path conversion function : func_convert_path_X_to_Y ()
3043+# where, for any given $build/$host combination the 'X_to_Y' value is the
3044+# same. If conversion functions are added for new $build/$host combinations,
3045+# the two new functions must follow this pattern, or func_init_to_host_path_cmd
3046+# will break.
3047+
3048+
3049+# func_init_to_host_path_cmd
3050+# Ensures that function "pointer" variable $to_host_path_cmd is set to the
3051+# appropriate value, based on the value of $to_host_file_cmd.
3052+to_host_path_cmd=
3053+func_init_to_host_path_cmd ()
3054+{
3055+ $opt_debug
3056+ if test -z "$to_host_path_cmd"; then
3057+ func_stripname 'func_convert_file_' '' "$to_host_file_cmd"
3058+ to_host_path_cmd="func_convert_path_${func_stripname_result}"
3059+ fi
3060+}
3061+
3062+
3063+# func_to_host_path ARG
3064+# Converts the path ARG from $build format to $host format. Return result
3065+# in func_to_host_path_result.
3066+func_to_host_path ()
3067+{
3068+ $opt_debug
3069+ func_init_to_host_path_cmd
3070+ $to_host_path_cmd "$1"
3071+}
3072+# end func_to_host_path
3073+
3074+
3075+# func_convert_path_noop ARG
3076+# Copy ARG to func_to_host_path_result.
3077+func_convert_path_noop ()
3078+{
3079+ func_to_host_path_result="$1"
3080+}
3081+# end func_convert_path_noop
3082+
3083+
3084+# func_convert_path_msys_to_w32 ARG
3085+# Convert path ARG from (mingw) MSYS to (mingw) w32 format; automatic
3086+# conversion to w32 is not available inside the cwrapper. Returns result in
3087+# func_to_host_path_result.
3088+func_convert_path_msys_to_w32 ()
3089+{
3090+ $opt_debug
3091+ func_to_host_path_result="$1"
3092+ if test -n "$1"; then
3093+ # Remove leading and trailing path separator characters from ARG. MSYS
3094+ # behavior is inconsistent here; cygpath turns them into '.;' and ';.';
3095+ # and winepath ignores them completely.
3096+ func_stripname : : "$1"
3097+ func_to_host_path_tmp1=$func_stripname_result
3098+ func_convert_core_msys_to_w32 "$func_to_host_path_tmp1"
3099+ func_to_host_path_result="$func_convert_core_msys_to_w32_result"
3100+ func_convert_path_check : ";" \
3101+ "$func_to_host_path_tmp1" "$func_to_host_path_result"
3102+ func_convert_path_front_back_pathsep ":*" "*:" ";" "$1"
3103+ fi
3104+}
3105+# end func_convert_path_msys_to_w32
3106+
3107+
3108+# func_convert_path_cygwin_to_w32 ARG
3109+# Convert path ARG from Cygwin to w32 format. Returns result in
3110+# func_to_host_file_result.
3111+func_convert_path_cygwin_to_w32 ()
3112+{
3113+ $opt_debug
3114+ func_to_host_path_result="$1"
3115+ if test -n "$1"; then
3116+ # See func_convert_path_msys_to_w32:
3117+ func_stripname : : "$1"
3118+ func_to_host_path_tmp1=$func_stripname_result
3119+ func_to_host_path_result=`cygpath -m -p "$func_to_host_path_tmp1"`
3120+ func_convert_path_check : ";" \
3121+ "$func_to_host_path_tmp1" "$func_to_host_path_result"
3122+ func_convert_path_front_back_pathsep ":*" "*:" ";" "$1"
3123+ fi
3124+}
3125+# end func_convert_path_cygwin_to_w32
3126+
3127+
3128+# func_convert_path_nix_to_w32 ARG
3129+# Convert path ARG from *nix to w32 format. Requires a wine environment and
3130+# a working winepath. Returns result in func_to_host_file_result.
3131+func_convert_path_nix_to_w32 ()
3132+{
3133+ $opt_debug
3134+ func_to_host_path_result="$1"
3135+ if test -n "$1"; then
3136+ # See func_convert_path_msys_to_w32:
3137+ func_stripname : : "$1"
3138+ func_to_host_path_tmp1=$func_stripname_result
3139+ func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1"
3140+ func_to_host_path_result="$func_convert_core_path_wine_to_w32_result"
3141+ func_convert_path_check : ";" \
3142+ "$func_to_host_path_tmp1" "$func_to_host_path_result"
3143+ func_convert_path_front_back_pathsep ":*" "*:" ";" "$1"
3144+ fi
3145+}
3146+# end func_convert_path_nix_to_w32
3147+
3148+
3149+# func_convert_path_msys_to_cygwin ARG
3150+# Convert path ARG from MSYS to Cygwin format. Requires LT_CYGPATH set.
3151+# Returns result in func_to_host_file_result.
3152+func_convert_path_msys_to_cygwin ()
3153+{
3154+ $opt_debug
3155+ func_to_host_path_result="$1"
3156+ if test -n "$1"; then
3157+ # See func_convert_path_msys_to_w32:
3158+ func_stripname : : "$1"
3159+ func_to_host_path_tmp1=$func_stripname_result
3160+ func_convert_core_msys_to_w32 "$func_to_host_path_tmp1"
3161+ func_cygpath -u -p "$func_convert_core_msys_to_w32_result"
3162+ func_to_host_path_result="$func_cygpath_result"
3163+ func_convert_path_check : : \
3164+ "$func_to_host_path_tmp1" "$func_to_host_path_result"
3165+ func_convert_path_front_back_pathsep ":*" "*:" : "$1"
3166+ fi
3167+}
3168+# end func_convert_path_msys_to_cygwin
3169+
3170+
3171+# func_convert_path_nix_to_cygwin ARG
3172+# Convert path ARG from *nix to Cygwin format. Requires Cygwin installed in a
3173+# a wine environment, working winepath, and LT_CYGPATH set. Returns result in
3174+# func_to_host_file_result.
3175+func_convert_path_nix_to_cygwin ()
3176+{
3177+ $opt_debug
3178+ func_to_host_path_result="$1"
3179+ if test -n "$1"; then
3180+ # Remove leading and trailing path separator characters from
3181+ # ARG. msys behavior is inconsistent here, cygpath turns them
3182+ # into '.;' and ';.', and winepath ignores them completely.
3183+ func_stripname : : "$1"
3184+ func_to_host_path_tmp1=$func_stripname_result
3185+ func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1"
3186+ func_cygpath -u -p "$func_convert_core_path_wine_to_w32_result"
3187+ func_to_host_path_result="$func_cygpath_result"
3188+ func_convert_path_check : : \
3189+ "$func_to_host_path_tmp1" "$func_to_host_path_result"
3190+ func_convert_path_front_back_pathsep ":*" "*:" : "$1"
3191+ fi
3192+}
3193+# end func_convert_path_nix_to_cygwin
3194+
3195+
3196 # func_mode_compile arg...
3197 func_mode_compile ()
3198 {
3199@@ -1314,12 +1985,12 @@ func_mode_compile ()
3200 ;;
3201
3202 -pie | -fpie | -fPIE)
3203- pie_flag="$pie_flag $arg"
3204+ func_append pie_flag " $arg"
3205 continue
3206 ;;
3207
3208 -shared | -static | -prefer-pic | -prefer-non-pic)
3209- later="$later $arg"
3210+ func_append later " $arg"
3211 continue
3212 ;;
3213
3214@@ -1340,15 +2011,14 @@ func_mode_compile ()
3215 save_ifs="$IFS"; IFS=','
3216 for arg in $args; do
3217 IFS="$save_ifs"
3218- func_quote_for_eval "$arg"
3219- lastarg="$lastarg $func_quote_for_eval_result"
3220+ func_append_quoted lastarg "$arg"
3221 done
3222 IFS="$save_ifs"
3223 func_stripname ' ' '' "$lastarg"
3224 lastarg=$func_stripname_result
3225
3226 # Add the arguments to base_compile.
3227- base_compile="$base_compile $lastarg"
3228+ func_append base_compile " $lastarg"
3229 continue
3230 ;;
3231
3232@@ -1364,8 +2034,7 @@ func_mode_compile ()
3233 esac # case $arg_mode
3234
3235 # Aesthetically quote the previous argument.
3236- func_quote_for_eval "$lastarg"
3237- base_compile="$base_compile $func_quote_for_eval_result"
3238+ func_append_quoted base_compile "$lastarg"
3239 done # for arg
3240
3241 case $arg_mode in
3242@@ -1496,17 +2165,16 @@ compiler."
3243 $opt_dry_run || $RM $removelist
3244 exit $EXIT_FAILURE
3245 fi
3246- removelist="$removelist $output_obj"
3247+ func_append removelist " $output_obj"
3248 $ECHO "$srcfile" > "$lockfile"
3249 fi
3250
3251 $opt_dry_run || $RM $removelist
3252- removelist="$removelist $lockfile"
3253+ func_append removelist " $lockfile"
3254 trap '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' 1 2 15
3255
3256- if test -n "$fix_srcfile_path"; then
3257- eval "srcfile=\"$fix_srcfile_path\""
3258- fi
3259+ func_to_tool_file "$srcfile" func_convert_file_msys_to_w32
3260+ srcfile=$func_to_tool_file_result
3261 func_quote_for_eval "$srcfile"
3262 qsrcfile=$func_quote_for_eval_result
3263
3264@@ -1526,7 +2194,7 @@ compiler."
3265
3266 if test -z "$output_obj"; then
3267 # Place PIC objects in $objdir
3268- command="$command -o $lobj"
3269+ func_append command " -o $lobj"
3270 fi
3271
3272 func_show_eval_locale "$command" \
3273@@ -1573,11 +2241,11 @@ compiler."
3274 command="$base_compile $qsrcfile $pic_flag"
3275 fi
3276 if test "$compiler_c_o" = yes; then
3277- command="$command -o $obj"
3278+ func_append command " -o $obj"
3279 fi
3280
3281 # Suppress compiler output if we already did a PIC compilation.
3282- command="$command$suppress_output"
3283+ func_append command "$suppress_output"
3284 func_show_eval_locale "$command" \
3285 '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE'
3286
3287@@ -1622,13 +2290,13 @@ compiler."
3288 }
3289
3290 $opt_help || {
3291- test "$mode" = compile && func_mode_compile ${1+"$@"}
3292+ test "$opt_mode" = compile && func_mode_compile ${1+"$@"}
3293 }
3294
3295 func_mode_help ()
3296 {
3297 # We need to display help for each of the modes.
3298- case $mode in
3299+ case $opt_mode in
3300 "")
3301 # Generic help is extracted from the usage comments
3302 # at the start of this file.
3303@@ -1659,8 +2327,8 @@ This mode accepts the following addition
3304
3305 -o OUTPUT-FILE set the output file name to OUTPUT-FILE
3306 -no-suppress do not suppress compiler output for multiple passes
3307- -prefer-pic try to building PIC objects only
3308- -prefer-non-pic try to building non-PIC objects only
3309+ -prefer-pic try to build PIC objects only
3310+ -prefer-non-pic try to build non-PIC objects only
3311 -shared do not build a \`.o' file suitable for static linking
3312 -static only build a \`.o' file suitable for static linking
3313 -Wc,FLAG pass FLAG directly to the compiler
3314@@ -1804,7 +2472,7 @@ Otherwise, only FILE itself is deleted u
3315 ;;
3316
3317 *)
3318- func_fatal_help "invalid operation mode \`$mode'"
3319+ func_fatal_help "invalid operation mode \`$opt_mode'"
3320 ;;
3321 esac
3322
3323@@ -1819,13 +2487,13 @@ if $opt_help; then
3324 else
3325 {
3326 func_help noexit
3327- for mode in compile link execute install finish uninstall clean; do
3328+ for opt_mode in compile link execute install finish uninstall clean; do
3329 func_mode_help
3330 done
3331 } | sed -n '1p; 2,$s/^Usage:/ or: /p'
3332 {
3333 func_help noexit
3334- for mode in compile link execute install finish uninstall clean; do
3335+ for opt_mode in compile link execute install finish uninstall clean; do
3336 echo
3337 func_mode_help
3338 done
3339@@ -1854,13 +2522,16 @@ func_mode_execute ()
3340 func_fatal_help "you must specify a COMMAND"
3341
3342 # Handle -dlopen flags immediately.
3343- for file in $execute_dlfiles; do
3344+ for file in $opt_dlopen; do
3345 test -f "$file" \
3346 || func_fatal_help "\`$file' is not a file"
3347
3348 dir=
3349 case $file in
3350 *.la)
3351+ func_resolve_sysroot "$file"
3352+ file=$func_resolve_sysroot_result
3353+
3354 # Check to see that this really is a libtool archive.
3355 func_lalib_unsafe_p "$file" \
3356 || func_fatal_help "\`$lib' is not a valid libtool archive"
3357@@ -1882,7 +2553,7 @@ func_mode_execute ()
3358 dir="$func_dirname_result"
3359
3360 if test -f "$dir/$objdir/$dlname"; then
3361- dir="$dir/$objdir"
3362+ func_append dir "/$objdir"
3363 else
3364 if test ! -f "$dir/$dlname"; then
3365 func_fatal_error "cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'"
3366@@ -1907,10 +2578,10 @@ func_mode_execute ()
3367 test -n "$absdir" && dir="$absdir"
3368
3369 # Now add the directory to shlibpath_var.
3370- if eval test -z \"\$$shlibpath_var\"; then
3371- eval $shlibpath_var=\$dir
3372+ if eval "test -z \"\$$shlibpath_var\""; then
3373+ eval "$shlibpath_var=\"\$dir\""
3374 else
3375- eval $shlibpath_var=\$dir:\$$shlibpath_var
3376+ eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\""
3377 fi
3378 done
3379
3380@@ -1939,8 +2610,7 @@ func_mode_execute ()
3381 ;;
3382 esac
3383 # Quote arguments (to preserve shell metacharacters).
3384- func_quote_for_eval "$file"
3385- args="$args $func_quote_for_eval_result"
3386+ func_append_quoted args "$file"
3387 done
3388
3389 if test "X$opt_dry_run" = Xfalse; then
3390@@ -1972,22 +2642,59 @@ func_mode_execute ()
3391 fi
3392 }
3393
3394-test "$mode" = execute && func_mode_execute ${1+"$@"}
3395+test "$opt_mode" = execute && func_mode_execute ${1+"$@"}
3396
3397
3398 # func_mode_finish arg...
3399 func_mode_finish ()
3400 {
3401 $opt_debug
3402- libdirs="$nonopt"
3403+ libs=
3404+ libdirs=
3405 admincmds=
3406
3407- if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then
3408- for dir
3409- do
3410- libdirs="$libdirs $dir"
3411- done
3412+ for opt in "$nonopt" ${1+"$@"}
3413+ do
3414+ if test -d "$opt"; then
3415+ func_append libdirs " $opt"
3416+
3417+ elif test -f "$opt"; then
3418+ if func_lalib_unsafe_p "$opt"; then
3419+ func_append libs " $opt"
3420+ else
3421+ func_warning "\`$opt' is not a valid libtool archive"
3422+ fi
3423+
3424+ else
3425+ func_fatal_error "invalid argument \`$opt'"
3426+ fi
3427+ done
3428+
3429+ if test -n "$libs"; then
3430+ if test -n "$lt_sysroot"; then
3431+ sysroot_regex=`$ECHO "$lt_sysroot" | $SED "$sed_make_literal_regex"`
3432+ sysroot_cmd="s/\([ ']\)$sysroot_regex/\1/g;"
3433+ else
3434+ sysroot_cmd=
3435+ fi
3436+
3437+ # Remove sysroot references
3438+ if $opt_dry_run; then
3439+ for lib in $libs; do
3440+ echo "removing references to $lt_sysroot and \`=' prefixes from $lib"
3441+ done
3442+ else
3443+ tmpdir=`func_mktempdir`
3444+ for lib in $libs; do
3445+ sed -e "${sysroot_cmd} s/\([ ']-[LR]\)=/\1/g; s/\([ ']\)=/\1/g" $lib \
3446+ > $tmpdir/tmp-la
3447+ mv -f $tmpdir/tmp-la $lib
3448+ done
3449+ ${RM}r "$tmpdir"
3450+ fi
3451+ fi
3452
3453+ if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then
3454 for libdir in $libdirs; do
3455 if test -n "$finish_cmds"; then
3456 # Do each command in the finish commands.
3457@@ -1997,7 +2704,7 @@ func_mode_finish ()
3458 if test -n "$finish_eval"; then
3459 # Do the single finish_eval.
3460 eval cmds=\"$finish_eval\"
3461- $opt_dry_run || eval "$cmds" || admincmds="$admincmds
3462+ $opt_dry_run || eval "$cmds" || func_append admincmds "
3463 $cmds"
3464 fi
3465 done
3466@@ -2006,53 +2713,55 @@ func_mode_finish ()
3467 # Exit here if they wanted silent mode.
3468 $opt_silent && exit $EXIT_SUCCESS
3469
3470- echo "----------------------------------------------------------------------"
3471- echo "Libraries have been installed in:"
3472- for libdir in $libdirs; do
3473- $ECHO " $libdir"
3474- done
3475- echo
3476- echo "If you ever happen to want to link against installed libraries"
3477- echo "in a given directory, LIBDIR, you must either use libtool, and"
3478- echo "specify the full pathname of the library, or use the \`-LLIBDIR'"
3479- echo "flag during linking and do at least one of the following:"
3480- if test -n "$shlibpath_var"; then
3481- echo " - add LIBDIR to the \`$shlibpath_var' environment variable"
3482- echo " during execution"
3483- fi
3484- if test -n "$runpath_var"; then
3485- echo " - add LIBDIR to the \`$runpath_var' environment variable"
3486- echo " during linking"
3487- fi
3488- if test -n "$hardcode_libdir_flag_spec"; then
3489- libdir=LIBDIR
3490- eval "flag=\"$hardcode_libdir_flag_spec\""
3491+ if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then
3492+ echo "----------------------------------------------------------------------"
3493+ echo "Libraries have been installed in:"
3494+ for libdir in $libdirs; do
3495+ $ECHO " $libdir"
3496+ done
3497+ echo
3498+ echo "If you ever happen to want to link against installed libraries"
3499+ echo "in a given directory, LIBDIR, you must either use libtool, and"
3500+ echo "specify the full pathname of the library, or use the \`-LLIBDIR'"
3501+ echo "flag during linking and do at least one of the following:"
3502+ if test -n "$shlibpath_var"; then
3503+ echo " - add LIBDIR to the \`$shlibpath_var' environment variable"
3504+ echo " during execution"
3505+ fi
3506+ if test -n "$runpath_var"; then
3507+ echo " - add LIBDIR to the \`$runpath_var' environment variable"
3508+ echo " during linking"
3509+ fi
3510+ if test -n "$hardcode_libdir_flag_spec"; then
3511+ libdir=LIBDIR
3512+ eval flag=\"$hardcode_libdir_flag_spec\"
3513
3514- $ECHO " - use the \`$flag' linker flag"
3515- fi
3516- if test -n "$admincmds"; then
3517- $ECHO " - have your system administrator run these commands:$admincmds"
3518- fi
3519- if test -f /etc/ld.so.conf; then
3520- echo " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'"
3521- fi
3522- echo
3523+ $ECHO " - use the \`$flag' linker flag"
3524+ fi
3525+ if test -n "$admincmds"; then
3526+ $ECHO " - have your system administrator run these commands:$admincmds"
3527+ fi
3528+ if test -f /etc/ld.so.conf; then
3529+ echo " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'"
3530+ fi
3531+ echo
3532
3533- echo "See any operating system documentation about shared libraries for"
3534- case $host in
3535- solaris2.[6789]|solaris2.1[0-9])
3536- echo "more information, such as the ld(1), crle(1) and ld.so(8) manual"
3537- echo "pages."
3538- ;;
3539- *)
3540- echo "more information, such as the ld(1) and ld.so(8) manual pages."
3541- ;;
3542- esac
3543- echo "----------------------------------------------------------------------"
3544+ echo "See any operating system documentation about shared libraries for"
3545+ case $host in
3546+ solaris2.[6789]|solaris2.1[0-9])
3547+ echo "more information, such as the ld(1), crle(1) and ld.so(8) manual"
3548+ echo "pages."
3549+ ;;
3550+ *)
3551+ echo "more information, such as the ld(1) and ld.so(8) manual pages."
3552+ ;;
3553+ esac
3554+ echo "----------------------------------------------------------------------"
3555+ fi
3556 exit $EXIT_SUCCESS
3557 }
3558
3559-test "$mode" = finish && func_mode_finish ${1+"$@"}
3560+test "$opt_mode" = finish && func_mode_finish ${1+"$@"}
3561
3562
3563 # func_mode_install arg...
3564@@ -2077,7 +2786,7 @@ func_mode_install ()
3565 # The real first argument should be the name of the installation program.
3566 # Aesthetically quote it.
3567 func_quote_for_eval "$arg"
3568- install_prog="$install_prog$func_quote_for_eval_result"
3569+ func_append install_prog "$func_quote_for_eval_result"
3570 install_shared_prog=$install_prog
3571 case " $install_prog " in
3572 *[\\\ /]cp\ *) install_cp=: ;;
3573@@ -2097,7 +2806,7 @@ func_mode_install ()
3574 do
3575 arg2=
3576 if test -n "$dest"; then
3577- files="$files $dest"
3578+ func_append files " $dest"
3579 dest=$arg
3580 continue
3581 fi
3582@@ -2135,11 +2844,11 @@ func_mode_install ()
3583
3584 # Aesthetically quote the argument.
3585 func_quote_for_eval "$arg"
3586- install_prog="$install_prog $func_quote_for_eval_result"
3587+ func_append install_prog " $func_quote_for_eval_result"
3588 if test -n "$arg2"; then
3589 func_quote_for_eval "$arg2"
3590 fi
3591- install_shared_prog="$install_shared_prog $func_quote_for_eval_result"
3592+ func_append install_shared_prog " $func_quote_for_eval_result"
3593 done
3594
3595 test -z "$install_prog" && \
3596@@ -2151,7 +2860,7 @@ func_mode_install ()
3597 if test -n "$install_override_mode" && $no_mode; then
3598 if $install_cp; then :; else
3599 func_quote_for_eval "$install_override_mode"
3600- install_shared_prog="$install_shared_prog -m $func_quote_for_eval_result"
3601+ func_append install_shared_prog " -m $func_quote_for_eval_result"
3602 fi
3603 fi
3604
3605@@ -2209,10 +2918,13 @@ func_mode_install ()
3606 case $file in
3607 *.$libext)
3608 # Do the static libraries later.
3609- staticlibs="$staticlibs $file"
3610+ func_append staticlibs " $file"
3611 ;;
3612
3613 *.la)
3614+ func_resolve_sysroot "$file"
3615+ file=$func_resolve_sysroot_result
3616+
3617 # Check to see that this really is a libtool archive.
3618 func_lalib_unsafe_p "$file" \
3619 || func_fatal_help "\`$file' is not a valid libtool archive"
3620@@ -2226,23 +2938,30 @@ func_mode_install ()
3621 if test "X$destdir" = "X$libdir"; then
3622 case "$current_libdirs " in
3623 *" $libdir "*) ;;
3624- *) current_libdirs="$current_libdirs $libdir" ;;
3625+ *) func_append current_libdirs " $libdir" ;;
3626 esac
3627 else
3628 # Note the libdir as a future libdir.
3629 case "$future_libdirs " in
3630 *" $libdir "*) ;;
3631- *) future_libdirs="$future_libdirs $libdir" ;;
3632+ *) func_append future_libdirs " $libdir" ;;
3633 esac
3634 fi
3635
3636 func_dirname "$file" "/" ""
3637 dir="$func_dirname_result"
3638- dir="$dir$objdir"
3639+ func_append dir "$objdir"
3640
3641 if test -n "$relink_command"; then
3642+ # Strip any trailing slash from the destination.
3643+ func_stripname '' '/' "$libdir"
3644+ destlibdir=$func_stripname_result
3645+
3646+ func_stripname '' '/' "$destdir"
3647+ s_destdir=$func_stripname_result
3648+
3649 # Determine the prefix the user has applied to our future dir.
3650- inst_prefix_dir=`$ECHO "$destdir" | $SED -e "s%$libdir\$%%"`
3651+ inst_prefix_dir=`$ECHO "X$s_destdir" | $Xsed -e "s%$destlibdir\$%%"`
3652
3653 # Don't allow the user to place us outside of our expected
3654 # location b/c this prevents finding dependent libraries that
3655@@ -2315,7 +3034,7 @@ func_mode_install ()
3656 func_show_eval "$install_prog $instname $destdir/$name" 'exit $?'
3657
3658 # Maybe install the static library, too.
3659- test -n "$old_library" && staticlibs="$staticlibs $dir/$old_library"
3660+ test -n "$old_library" && func_append staticlibs " $dir/$old_library"
3661 ;;
3662
3663 *.lo)
3664@@ -2503,7 +3222,7 @@ func_mode_install ()
3665 test -n "$future_libdirs" && \
3666 func_warning "remember to run \`$progname --finish$future_libdirs'"
3667
3668- if test -n "$current_libdirs" && $opt_finish; then
3669+ if test -n "$current_libdirs"; then
3670 # Maybe just do a dry run.
3671 $opt_dry_run && current_libdirs=" -n$current_libdirs"
3672 exec_cmd='$SHELL $progpath $preserve_args --finish$current_libdirs'
3673@@ -2512,7 +3231,7 @@ func_mode_install ()
3674 fi
3675 }
3676
3677-test "$mode" = install && func_mode_install ${1+"$@"}
3678+test "$opt_mode" = install && func_mode_install ${1+"$@"}
3679
3680
3681 # func_generate_dlsyms outputname originator pic_p
3682@@ -2559,6 +3278,18 @@ extern \"C\" {
3683 #pragma GCC diagnostic ignored \"-Wstrict-prototypes\"
3684 #endif
3685
3686+/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
3687+#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
3688+/* DATA imports from DLLs on WIN32 con't be const, because runtime
3689+ relocations are performed -- see ld's documentation on pseudo-relocs. */
3690+# define LT_DLSYM_CONST
3691+#elif defined(__osf__)
3692+/* This system does not cope well with relocations in const data. */
3693+# define LT_DLSYM_CONST
3694+#else
3695+# define LT_DLSYM_CONST const
3696+#endif
3697+
3698 /* External symbol declarations for the compiler. */\
3699 "
3700
3701@@ -2570,21 +3301,22 @@ extern \"C\" {
3702 # Add our own program objects to the symbol list.
3703 progfiles=`$ECHO "$objs$old_deplibs" | $SP2NL | $SED "$lo2o" | $NL2SP`
3704 for progfile in $progfiles; do
3705- func_verbose "extracting global C symbols from \`$progfile'"
3706- $opt_dry_run || eval "$NM $progfile | $global_symbol_pipe >> '$nlist'"
3707+ func_to_tool_file "$progfile" func_convert_file_msys_to_w32
3708+ func_verbose "extracting global C symbols from \`$func_to_tool_file_result'"
3709+ $opt_dry_run || eval "$NM $func_to_tool_file_result | $global_symbol_pipe >> '$nlist'"
3710 done
3711
3712 if test -n "$exclude_expsyms"; then
3713 $opt_dry_run || {
3714- $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T
3715- $MV "$nlist"T "$nlist"
3716+ eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T'
3717+ eval '$MV "$nlist"T "$nlist"'
3718 }
3719 fi
3720
3721 if test -n "$export_symbols_regex"; then
3722 $opt_dry_run || {
3723- $EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T
3724- $MV "$nlist"T "$nlist"
3725+ eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T'
3726+ eval '$MV "$nlist"T "$nlist"'
3727 }
3728 fi
3729
3730@@ -2593,23 +3325,23 @@ extern \"C\" {
3731 export_symbols="$output_objdir/$outputname.exp"
3732 $opt_dry_run || {
3733 $RM $export_symbols
3734- ${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' < "$nlist" > "$export_symbols"
3735+ eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"'
3736 case $host in
3737 *cygwin* | *mingw* | *cegcc* )
3738- echo EXPORTS > "$output_objdir/$outputname.def"
3739- cat "$export_symbols" >> "$output_objdir/$outputname.def"
3740+ eval "echo EXPORTS "'> "$output_objdir/$outputname.def"'
3741+ eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"'
3742 ;;
3743 esac
3744 }
3745 else
3746 $opt_dry_run || {
3747- ${SED} -e 's/\([].[*^$]\)/\\\1/g' -e 's/^/ /' -e 's/$/$/' < "$export_symbols" > "$output_objdir/$outputname.exp"
3748- $GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T
3749- $MV "$nlist"T "$nlist"
3750+ eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"'
3751+ eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T'
3752+ eval '$MV "$nlist"T "$nlist"'
3753 case $host in
3754 *cygwin* | *mingw* | *cegcc* )
3755- echo EXPORTS > "$output_objdir/$outputname.def"
3756- cat "$nlist" >> "$output_objdir/$outputname.def"
3757+ eval "echo EXPORTS "'> "$output_objdir/$outputname.def"'
3758+ eval 'cat "$nlist" >> "$output_objdir/$outputname.def"'
3759 ;;
3760 esac
3761 }
3762@@ -2620,10 +3352,52 @@ extern \"C\" {
3763 func_verbose "extracting global C symbols from \`$dlprefile'"
3764 func_basename "$dlprefile"
3765 name="$func_basename_result"
3766- $opt_dry_run || {
3767- $ECHO ": $name " >> "$nlist"
3768- eval "$NM $dlprefile 2>/dev/null | $global_symbol_pipe >> '$nlist'"
3769- }
3770+ case $host in
3771+ *cygwin* | *mingw* | *cegcc* )
3772+ # if an import library, we need to obtain dlname
3773+ if func_win32_import_lib_p "$dlprefile"; then
3774+ func_tr_sh "$dlprefile"
3775+ eval "curr_lafile=\$libfile_$func_tr_sh_result"
3776+ dlprefile_dlbasename=""
3777+ if test -n "$curr_lafile" && func_lalib_p "$curr_lafile"; then
3778+ # Use subshell, to avoid clobbering current variable values
3779+ dlprefile_dlname=`source "$curr_lafile" && echo "$dlname"`
3780+ if test -n "$dlprefile_dlname" ; then
3781+ func_basename "$dlprefile_dlname"
3782+ dlprefile_dlbasename="$func_basename_result"
3783+ else
3784+ # no lafile. user explicitly requested -dlpreopen <import library>.
3785+ $sharedlib_from_linklib_cmd "$dlprefile"
3786+ dlprefile_dlbasename=$sharedlib_from_linklib_result
3787+ fi
3788+ fi
3789+ $opt_dry_run || {
3790+ if test -n "$dlprefile_dlbasename" ; then
3791+ eval '$ECHO ": $dlprefile_dlbasename" >> "$nlist"'
3792+ else
3793+ func_warning "Could not compute DLL name from $name"
3794+ eval '$ECHO ": $name " >> "$nlist"'
3795+ fi
3796+ func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32
3797+ eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe |
3798+ $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/_nm__//' >> '$nlist'"
3799+ }
3800+ else # not an import lib
3801+ $opt_dry_run || {
3802+ eval '$ECHO ": $name " >> "$nlist"'
3803+ func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32
3804+ eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'"
3805+ }
3806+ fi
3807+ ;;
3808+ *)
3809+ $opt_dry_run || {
3810+ eval '$ECHO ": $name " >> "$nlist"'
3811+ func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32
3812+ eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'"
3813+ }
3814+ ;;
3815+ esac
3816 done
3817
3818 $opt_dry_run || {
3819@@ -2661,26 +3435,9 @@ typedef struct {
3820 const char *name;
3821 void *address;
3822 } lt_dlsymlist;
3823-"
3824- case $host in
3825- *cygwin* | *mingw* | *cegcc* )
3826- echo >> "$output_objdir/$my_dlsyms" "\
3827-/* DATA imports from DLLs on WIN32 con't be const, because
3828- runtime relocations are performed -- see ld's documentation
3829- on pseudo-relocs. */"
3830- lt_dlsym_const= ;;
3831- *osf5*)
3832- echo >> "$output_objdir/$my_dlsyms" "\
3833-/* This system does not cope well with relocations in const data */"
3834- lt_dlsym_const= ;;
3835- *)
3836- lt_dlsym_const=const ;;
3837- esac
3838-
3839- echo >> "$output_objdir/$my_dlsyms" "\
3840-extern $lt_dlsym_const lt_dlsymlist
3841+extern LT_DLSYM_CONST lt_dlsymlist
3842 lt_${my_prefix}_LTX_preloaded_symbols[];
3843-$lt_dlsym_const lt_dlsymlist
3844+LT_DLSYM_CONST lt_dlsymlist
3845 lt_${my_prefix}_LTX_preloaded_symbols[] =
3846 {\
3847 { \"$my_originator\", (void *) 0 },"
3848@@ -2736,7 +3493,7 @@ static const void *lt_preloaded_setup()
3849 for arg in $LTCFLAGS; do
3850 case $arg in
3851 -pie | -fpie | -fPIE) ;;
3852- *) symtab_cflags="$symtab_cflags $arg" ;;
3853+ *) func_append symtab_cflags " $arg" ;;
3854 esac
3855 done
3856
3857@@ -2796,9 +3553,11 @@ func_win32_libid ()
3858 win32_libid_type="x86 archive import"
3859 ;;
3860 *ar\ archive*) # could be an import, or static
3861- if $OBJDUMP -f "$1" | $SED -e '10q' 2>/dev/null |
3862- $EGREP 'file format (pe-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then
3863- win32_nmres=`$NM -f posix -A "$1" |
3864+ # Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD.
3865+ if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null |
3866+ $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then
3867+ func_to_tool_file "$1" func_convert_file_msys_to_w32
3868+ win32_nmres=`eval $NM -f posix -A \"$func_to_tool_file_result\" |
3869 $SED -n -e '
3870 1,100{
3871 / I /{
3872@@ -2827,6 +3586,131 @@ func_win32_libid ()
3873 $ECHO "$win32_libid_type"
3874 }
3875
3876+# func_cygming_dll_for_implib ARG
3877+#
3878+# Platform-specific function to extract the
3879+# name of the DLL associated with the specified
3880+# import library ARG.
3881+# Invoked by eval'ing the libtool variable
3882+# $sharedlib_from_linklib_cmd
3883+# Result is available in the variable
3884+# $sharedlib_from_linklib_result
3885+func_cygming_dll_for_implib ()
3886+{
3887+ $opt_debug
3888+ sharedlib_from_linklib_result=`$DLLTOOL --identify-strict --identify "$1"`
3889+}
3890+
3891+# func_cygming_dll_for_implib_fallback_core SECTION_NAME LIBNAMEs
3892+#
3893+# The is the core of a fallback implementation of a
3894+# platform-specific function to extract the name of the
3895+# DLL associated with the specified import library LIBNAME.
3896+#
3897+# SECTION_NAME is either .idata$6 or .idata$7, depending
3898+# on the platform and compiler that created the implib.
3899+#
3900+# Echos the name of the DLL associated with the
3901+# specified import library.
3902+func_cygming_dll_for_implib_fallback_core ()
3903+{
3904+ $opt_debug
3905+ match_literal=`$ECHO "$1" | $SED "$sed_make_literal_regex"`
3906+ $OBJDUMP -s --section "$1" "$2" 2>/dev/null |
3907+ $SED '/^Contents of section '"$match_literal"':/{
3908+ # Place marker at beginning of archive member dllname section
3909+ s/.*/====MARK====/
3910+ p
3911+ d
3912+ }
3913+ # These lines can sometimes be longer than 43 characters, but
3914+ # are always uninteresting
3915+ /:[ ]*file format pe[i]\{,1\}-/d
3916+ /^In archive [^:]*:/d
3917+ # Ensure marker is printed
3918+ /^====MARK====/p
3919+ # Remove all lines with less than 43 characters
3920+ /^.\{43\}/!d
3921+ # From remaining lines, remove first 43 characters
3922+ s/^.\{43\}//' |
3923+ $SED -n '
3924+ # Join marker and all lines until next marker into a single line
3925+ /^====MARK====/ b para
3926+ H
3927+ $ b para
3928+ b
3929+ :para
3930+ x
3931+ s/\n//g
3932+ # Remove the marker
3933+ s/^====MARK====//
3934+ # Remove trailing dots and whitespace
3935+ s/[\. \t]*$//
3936+ # Print
3937+ /./p' |
3938+ # we now have a list, one entry per line, of the stringified
3939+ # contents of the appropriate section of all members of the
3940+ # archive which possess that section. Heuristic: eliminate
3941+ # all those which have a first or second character that is
3942+ # a '.' (that is, objdump's representation of an unprintable
3943+ # character.) This should work for all archives with less than
3944+ # 0x302f exports -- but will fail for DLLs whose name actually
3945+ # begins with a literal '.' or a single character followed by
3946+ # a '.'.
3947+ #
3948+ # Of those that remain, print the first one.
3949+ $SED -e '/^\./d;/^.\./d;q'
3950+}
3951+
3952+# func_cygming_gnu_implib_p ARG
3953+# This predicate returns with zero status (TRUE) if
3954+# ARG is a GNU/binutils-style import library. Returns
3955+# with nonzero status (FALSE) otherwise.
3956+func_cygming_gnu_implib_p ()
3957+{
3958+ $opt_debug
3959+ func_to_tool_file "$1" func_convert_file_msys_to_w32
3960+ func_cygming_gnu_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $EGREP ' (_head_[A-Za-z0-9_]+_[ad]l*|[A-Za-z0-9_]+_[ad]l*_iname)$'`
3961+ test -n "$func_cygming_gnu_implib_tmp"
3962+}
3963+
3964+# func_cygming_ms_implib_p ARG
3965+# This predicate returns with zero status (TRUE) if
3966+# ARG is an MS-style import library. Returns
3967+# with nonzero status (FALSE) otherwise.
3968+func_cygming_ms_implib_p ()
3969+{
3970+ $opt_debug
3971+ func_to_tool_file "$1" func_convert_file_msys_to_w32
3972+ func_cygming_ms_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $GREP '_NULL_IMPORT_DESCRIPTOR'`
3973+ test -n "$func_cygming_ms_implib_tmp"
3974+}
3975+
3976+# func_cygming_dll_for_implib_fallback ARG
3977+# Platform-specific function to extract the
3978+# name of the DLL associated with the specified
3979+# import library ARG.
3980+#
3981+# This fallback implementation is for use when $DLLTOOL
3982+# does not support the --identify-strict option.
3983+# Invoked by eval'ing the libtool variable
3984+# $sharedlib_from_linklib_cmd
3985+# Result is available in the variable
3986+# $sharedlib_from_linklib_result
3987+func_cygming_dll_for_implib_fallback ()
3988+{
3989+ $opt_debug
3990+ if func_cygming_gnu_implib_p "$1" ; then
3991+ # binutils import library
3992+ sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$7' "$1"`
3993+ elif func_cygming_ms_implib_p "$1" ; then
3994+ # ms-generated import library
3995+ sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$6' "$1"`
3996+ else
3997+ # unknown
3998+ sharedlib_from_linklib_result=""
3999+ fi
4000+}
4001
4002
4003 # func_extract_an_archive dir oldlib
4004@@ -2917,7 +3801,7 @@ func_extract_archives ()
4005 darwin_file=
4006 darwin_files=
4007 for darwin_file in $darwin_filelist; do
4008- darwin_files=`find unfat-$$ -name $darwin_file -print | $NL2SP`
4009+ darwin_files=`find unfat-$$ -name $darwin_file -print | sort | $NL2SP`
4010 $LIPO -create -output "$darwin_file" $darwin_files
4011 done # $darwin_filelist
4012 $RM -rf unfat-$$
4013@@ -2932,7 +3816,7 @@ func_extract_archives ()
4014 func_extract_an_archive "$my_xdir" "$my_xabs"
4015 ;;
4016 esac
4017- my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | $NL2SP`
4018+ my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | sort | $NL2SP`
4019 done
4020
4021 func_extract_archives_result="$my_oldobjs"
4022@@ -3014,7 +3898,110 @@ func_fallback_echo ()
4023 _LTECHO_EOF'
4024 }
4025 ECHO=\"$qECHO\"
4026- fi\
4027+ fi
4028+
4029+# Very basic option parsing. These options are (a) specific to
4030+# the libtool wrapper, (b) are identical between the wrapper
4031+# /script/ and the wrapper /executable/ which is used only on
4032+# windows platforms, and (c) all begin with the string "--lt-"
4033+# (application programs are unlikely to have options which match
4034+# this pattern).
4035+#
4036+# There are only two supported options: --lt-debug and
4037+# --lt-dump-script. There is, deliberately, no --lt-help.
4038+#
4039+# The first argument to this parsing function should be the
4040+# script's $0 value, followed by "$@".
4041+lt_option_debug=
4042+func_parse_lt_options ()
4043+{
4044+ lt_script_arg0=\$0
4045+ shift
4046+ for lt_opt
4047+ do
4048+ case \"\$lt_opt\" in
4049+ --lt-debug) lt_option_debug=1 ;;
4050+ --lt-dump-script)
4051+ lt_dump_D=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%/[^/]*$%%'\`
4052+ test \"X\$lt_dump_D\" = \"X\$lt_script_arg0\" && lt_dump_D=.
4053+ lt_dump_F=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%^.*/%%'\`
4054+ cat \"\$lt_dump_D/\$lt_dump_F\"
4055+ exit 0
4056+ ;;
4057+ --lt-*)
4058+ \$ECHO \"Unrecognized --lt- option: '\$lt_opt'\" 1>&2
4059+ exit 1
4060+ ;;
4061+ esac
4062+ done
4063+
4064+ # Print the debug banner immediately:
4065+ if test -n \"\$lt_option_debug\"; then
4066+ echo \"${outputname}:${output}:\${LINENO}: libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\" 1>&2
4067+ fi
4068+}
4069+
4070+# Used when --lt-debug. Prints its arguments to stdout
4071+# (redirection is the responsibility of the caller)
4072+func_lt_dump_args ()
4073+{
4074+ lt_dump_args_N=1;
4075+ for lt_arg
4076+ do
4077+ \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[\$lt_dump_args_N]: \$lt_arg\"
4078+ lt_dump_args_N=\`expr \$lt_dump_args_N + 1\`
4079+ done
4080+}
4081+
4082+# Core function for launching the target application
4083+func_exec_program_core ()
4084+{
4085+"
4086+ case $host in
4087+ # Backslashes separate directories on plain windows
4088+ *-*-mingw | *-*-os2* | *-cegcc*)
4089+ $ECHO "\
4090+ if test -n \"\$lt_option_debug\"; then
4091+ \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir\\\\\$program\" 1>&2
4092+ func_lt_dump_args \${1+\"\$@\"} 1>&2
4093+ fi
4094+ exec \"\$progdir\\\\\$program\" \${1+\"\$@\"}
4095+"
4096+ ;;
4097+
4098+ *)
4099+ $ECHO "\
4100+ if test -n \"\$lt_option_debug\"; then
4101+ \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir/\$program\" 1>&2
4102+ func_lt_dump_args \${1+\"\$@\"} 1>&2
4103+ fi
4104+ exec \"\$progdir/\$program\" \${1+\"\$@\"}
4105+"
4106+ ;;
4107+ esac
4108+ $ECHO "\
4109+ \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2
4110+ exit 1
4111+}
4112+
4113+# A function to encapsulate launching the target application
4114+# Strips options in the --lt-* namespace from \$@ and
4115+# launches target application with the remaining arguments.
4116+func_exec_program ()
4117+{
4118+ for lt_wr_arg
4119+ do
4120+ case \$lt_wr_arg in
4121+ --lt-*) ;;
4122+ *) set x \"\$@\" \"\$lt_wr_arg\"; shift;;
4123+ esac
4124+ shift
4125+ done
4126+ func_exec_program_core \${1+\"\$@\"}
4127+}
4128+
4129+ # Parse options
4130+ func_parse_lt_options \"\$0\" \${1+\"\$@\"}
4131
4132 # Find the directory that this script lives in.
4133 thisdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*$%%'\`
4134@@ -3078,7 +4065,7 @@ _LTECHO_EOF'
4135
4136 # relink executable if necessary
4137 if test -n \"\$relink_command\"; then
4138- if relink_command_output=\`eval \"\$relink_command\" 2>&1\`; then :
4139+ if relink_command_output=\`eval \$relink_command 2>&1\`; then :
4140 else
4141 $ECHO \"\$relink_command_output\" >&2
4142 $RM \"\$progdir/\$file\"
4143@@ -3102,6 +4089,18 @@ _LTECHO_EOF'
4144
4145 if test -f \"\$progdir/\$program\"; then"
4146
4147+ # fixup the dll searchpath if we need to.
4148+ #
4149+ # Fix the DLL searchpath if we need to. Do this before prepending
4150+ # to shlibpath, because on Windows, both are PATH and uninstalled
4151+ # libraries must come first.
4152+ if test -n "$dllsearchpath"; then
4153+ $ECHO "\
4154+ # Add the dll search path components to the executable PATH
4155+ PATH=$dllsearchpath:\$PATH
4156+"
4157+ fi
4158+
4159 # Export our shlibpath_var if we have one.
4160 if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then
4161 $ECHO "\
4162@@ -3116,35 +4115,10 @@ _LTECHO_EOF'
4163 "
4164 fi
4165
4166- # fixup the dll searchpath if we need to.
4167- if test -n "$dllsearchpath"; then
4168- $ECHO "\
4169- # Add the dll search path components to the executable PATH
4170- PATH=$dllsearchpath:\$PATH
4171-"
4172- fi
4173-
4174 $ECHO "\
4175 if test \"\$libtool_execute_magic\" != \"$magic\"; then
4176 # Run the actual program with our arguments.
4177-"
4178- case $host in
4179- # Backslashes separate directories on plain windows
4180- *-*-mingw | *-*-os2* | *-cegcc*)
4181- $ECHO "\
4182- exec \"\$progdir\\\\\$program\" \${1+\"\$@\"}
4183-"
4184- ;;
4185-
4186- *)
4187- $ECHO "\
4188- exec \"\$progdir/\$program\" \${1+\"\$@\"}
4189-"
4190- ;;
4191- esac
4192- $ECHO "\
4193- \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2
4194- exit 1
4195+ func_exec_program \${1+\"\$@\"}
4196 fi
4197 else
4198 # The program doesn't exist.
4199@@ -3158,166 +4132,6 @@ fi\
4200 }
4201
4202
4203-# func_to_host_path arg
4204-#
4205-# Convert paths to host format when used with build tools.
4206-# Intended for use with "native" mingw (where libtool itself
4207-# is running under the msys shell), or in the following cross-
4208-# build environments:
4209-# $build $host
4210-# mingw (msys) mingw [e.g. native]
4211-# cygwin mingw
4212-# *nix + wine mingw
4213-# where wine is equipped with the `winepath' executable.
4214-# In the native mingw case, the (msys) shell automatically
4215-# converts paths for any non-msys applications it launches,
4216-# but that facility isn't available from inside the cwrapper.
4217-# Similar accommodations are necessary for $host mingw and
4218-# $build cygwin. Calling this function does no harm for other
4219-# $host/$build combinations not listed above.
4220-#
4221-# ARG is the path (on $build) that should be converted to
4222-# the proper representation for $host. The result is stored
4223-# in $func_to_host_path_result.
4224-func_to_host_path ()
4225-{
4226- func_to_host_path_result="$1"
4227- if test -n "$1"; then
4228- case $host in
4229- *mingw* )
4230- lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g'
4231- case $build in
4232- *mingw* ) # actually, msys
4233- # awkward: cmd appends spaces to result
4234- func_to_host_path_result=`( cmd //c echo "$1" ) 2>/dev/null |
4235- $SED -e 's/[ ]*$//' -e "$lt_sed_naive_backslashify"`
4236- ;;
4237- *cygwin* )
4238- func_to_host_path_result=`cygpath -w "$1" |
4239- $SED -e "$lt_sed_naive_backslashify"`
4240- ;;
4241- * )
4242- # Unfortunately, winepath does not exit with a non-zero
4243- # error code, so we are forced to check the contents of
4244- # stdout. On the other hand, if the command is not
4245- # found, the shell will set an exit code of 127 and print
4246- # *an error message* to stdout. So we must check for both
4247- # error code of zero AND non-empty stdout, which explains
4248- # the odd construction:
4249- func_to_host_path_tmp1=`winepath -w "$1" 2>/dev/null`
4250- if test "$?" -eq 0 && test -n "${func_to_host_path_tmp1}"; then
4251- func_to_host_path_result=`$ECHO "$func_to_host_path_tmp1" |
4252- $SED -e "$lt_sed_naive_backslashify"`
4253- else
4254- # Allow warning below.
4255- func_to_host_path_result=
4256- fi
4257- ;;
4258- esac
4259- if test -z "$func_to_host_path_result" ; then
4260- func_error "Could not determine host path corresponding to"
4261- func_error " \`$1'"
4262- func_error "Continuing, but uninstalled executables may not work."
4263- # Fallback:
4264- func_to_host_path_result="$1"
4265- fi
4266- ;;
4267- esac
4268- fi
4269-}
4270-# end: func_to_host_path
4271-
4272-# func_to_host_pathlist arg
4273-#
4274-# Convert pathlists to host format when used with build tools.
4275-# See func_to_host_path(), above. This function supports the
4276-# following $build/$host combinations (but does no harm for
4277-# combinations not listed here):
4278-# $build $host
4279-# mingw (msys) mingw [e.g. native]
4280-# cygwin mingw
4281-# *nix + wine mingw
4282-#
4283-# Path separators are also converted from $build format to
4284-# $host format. If ARG begins or ends with a path separator
4285-# character, it is preserved (but converted to $host format)
4286-# on output.
4287-#
4288-# ARG is a pathlist (on $build) that should be converted to
4289-# the proper representation on $host. The result is stored
4290-# in $func_to_host_pathlist_result.
4291-func_to_host_pathlist ()
4292-{
4293- func_to_host_pathlist_result="$1"
4294- if test -n "$1"; then
4295- case $host in
4296- *mingw* )
4297- lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g'
4298- # Remove leading and trailing path separator characters from
4299- # ARG. msys behavior is inconsistent here, cygpath turns them
4300- # into '.;' and ';.', and winepath ignores them completely.
4301- func_stripname : : "$1"
4302- func_to_host_pathlist_tmp1=$func_stripname_result
4303- case $build in
4304- *mingw* ) # Actually, msys.
4305- # Awkward: cmd appends spaces to result.
4306- func_to_host_pathlist_result=`
4307- ( cmd //c echo "$func_to_host_pathlist_tmp1" ) 2>/dev/null |
4308- $SED -e 's/[ ]*$//' -e "$lt_sed_naive_backslashify"`
4309- ;;
4310- *cygwin* )
4311- func_to_host_pathlist_result=`cygpath -w -p "$func_to_host_pathlist_tmp1" |
4312- $SED -e "$lt_sed_naive_backslashify"`
4313- ;;
4314- * )
4315- # unfortunately, winepath doesn't convert pathlists
4316- func_to_host_pathlist_result=""
4317- func_to_host_pathlist_oldIFS=$IFS
4318- IFS=:
4319- for func_to_host_pathlist_f in $func_to_host_pathlist_tmp1 ; do
4320- IFS=$func_to_host_pathlist_oldIFS
4321- if test -n "$func_to_host_pathlist_f" ; then
4322- func_to_host_path "$func_to_host_pathlist_f"
4323- if test -n "$func_to_host_path_result" ; then
4324- if test -z "$func_to_host_pathlist_result" ; then
4325- func_to_host_pathlist_result="$func_to_host_path_result"
4326- else
4327- func_append func_to_host_pathlist_result ";$func_to_host_path_result"
4328- fi
4329- fi
4330- fi
4331- done
4332- IFS=$func_to_host_pathlist_oldIFS
4333- ;;
4334- esac
4335- if test -z "$func_to_host_pathlist_result"; then
4336- func_error "Could not determine the host path(s) corresponding to"
4337- func_error " \`$1'"
4338- func_error "Continuing, but uninstalled executables may not work."
4339- # Fallback. This may break if $1 contains DOS-style drive
4340- # specifications. The fix is not to complicate the expression
4341- # below, but for the user to provide a working wine installation
4342- # with winepath so that path translation in the cross-to-mingw
4343- # case works properly.
4344- lt_replace_pathsep_nix_to_dos="s|:|;|g"
4345- func_to_host_pathlist_result=`echo "$func_to_host_pathlist_tmp1" |\
4346- $SED -e "$lt_replace_pathsep_nix_to_dos"`
4347- fi
4348- # Now, add the leading and trailing path separators back
4349- case "$1" in
4350- :* ) func_to_host_pathlist_result=";$func_to_host_pathlist_result"
4351- ;;
4352- esac
4353- case "$1" in
4354- *: ) func_append func_to_host_pathlist_result ";"
4355- ;;
4356- esac
4357- ;;
4358- esac
4359- fi
4360-}
4361-# end: func_to_host_pathlist
4362-
4363 # func_emit_cwrapperexe_src
4364 # emit the source code for a wrapper executable on stdout
4365 # Must ONLY be called from within func_mode_link because
4366@@ -3334,10 +4148,6 @@ func_emit_cwrapperexe_src ()
4367
4368 This wrapper executable should never be moved out of the build directory.
4369 If it is, it will not operate correctly.
4370-
4371- Currently, it simply execs the wrapper *script* "$SHELL $output",
4372- but could eventually absorb all of the scripts functionality and
4373- exec $objdir/$outputname directly.
4374 */
4375 EOF
4376 cat <<"EOF"
4377@@ -3462,22 +4272,13 @@ int setenv (const char *, const char *,
4378 if (stale) { free ((void *) stale); stale = 0; } \
4379 } while (0)
4380
4381-#undef LTWRAPPER_DEBUGPRINTF
4382-#if defined LT_DEBUGWRAPPER
4383-# define LTWRAPPER_DEBUGPRINTF(args) ltwrapper_debugprintf args
4384-static void
4385-ltwrapper_debugprintf (const char *fmt, ...)
4386-{
4387- va_list args;
4388- va_start (args, fmt);
4389- (void) vfprintf (stderr, fmt, args);
4390- va_end (args);
4391-}
4392+#if defined(LT_DEBUGWRAPPER)
4393+static int lt_debug = 1;
4394 #else
4395-# define LTWRAPPER_DEBUGPRINTF(args)
4396+static int lt_debug = 0;
4397 #endif
4398
4399-const char *program_name = NULL;
4400+const char *program_name = "libtool-wrapper"; /* in case xstrdup fails */
4401
4402 void *xmalloc (size_t num);
4403 char *xstrdup (const char *string);
4404@@ -3487,7 +4288,10 @@ char *chase_symlinks (const char *pathsp
4405 int make_executable (const char *path);
4406 int check_executable (const char *path);
4407 char *strendzap (char *str, const char *pat);
4408-void lt_fatal (const char *message, ...);
4409+void lt_debugprintf (const char *file, int line, const char *fmt, ...);
4410+void lt_fatal (const char *file, int line, const char *message, ...);
4411+static const char *nonnull (const char *s);
4412+static const char *nonempty (const char *s);
4413 void lt_setenv (const char *name, const char *value);
4414 char *lt_extend_str (const char *orig_value, const char *add, int to_end);
4415 void lt_update_exe_path (const char *name, const char *value);
4416@@ -3497,14 +4301,14 @@ void lt_dump_script (FILE *f);
4417 EOF
4418
4419 cat <<EOF
4420-const char * MAGIC_EXE = "$magic_exe";
4421+volatile const char * MAGIC_EXE = "$magic_exe";
4422 const char * LIB_PATH_VARNAME = "$shlibpath_var";
4423 EOF
4424
4425 if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then
4426- func_to_host_pathlist "$temp_rpath"
4427+ func_to_host_path "$temp_rpath"
4428 cat <<EOF
4429-const char * LIB_PATH_VALUE = "$func_to_host_pathlist_result";
4430+const char * LIB_PATH_VALUE = "$func_to_host_path_result";
4431 EOF
4432 else
4433 cat <<"EOF"
4434@@ -3513,10 +4317,10 @@ EOF
4435 fi
4436
4437 if test -n "$dllsearchpath"; then
4438- func_to_host_pathlist "$dllsearchpath:"
4439+ func_to_host_path "$dllsearchpath:"
4440 cat <<EOF
4441 const char * EXE_PATH_VARNAME = "PATH";
4442-const char * EXE_PATH_VALUE = "$func_to_host_pathlist_result";
4443+const char * EXE_PATH_VALUE = "$func_to_host_path_result";
4444 EOF
4445 else
4446 cat <<"EOF"
4447@@ -3539,12 +4343,10 @@ EOF
4448 cat <<"EOF"
4449
4450 #define LTWRAPPER_OPTION_PREFIX "--lt-"
4451-#define LTWRAPPER_OPTION_PREFIX_LENGTH 5
4452
4453-static const size_t opt_prefix_len = LTWRAPPER_OPTION_PREFIX_LENGTH;
4454 static const char *ltwrapper_option_prefix = LTWRAPPER_OPTION_PREFIX;
4455-
4456 static const char *dumpscript_opt = LTWRAPPER_OPTION_PREFIX "dump-script";
4457+static const char *debug_opt = LTWRAPPER_OPTION_PREFIX "debug";
4458
4459 int
4460 main (int argc, char *argv[])
4461@@ -3561,10 +4363,13 @@ main (int argc, char *argv[])
4462 int i;
4463
4464 program_name = (char *) xstrdup (base_name (argv[0]));
4465- LTWRAPPER_DEBUGPRINTF (("(main) argv[0] : %s\n", argv[0]));
4466- LTWRAPPER_DEBUGPRINTF (("(main) program_name : %s\n", program_name));
4467+ newargz = XMALLOC (char *, argc + 1);
4468
4469- /* very simple arg parsing; don't want to rely on getopt */
4470+ /* very simple arg parsing; don't want to rely on getopt
4471+ * also, copy all non cwrapper options to newargz, except
4472+ * argz[0], which is handled differently
4473+ */
4474+ newargc=0;
4475 for (i = 1; i < argc; i++)
4476 {
4477 if (strcmp (argv[i], dumpscript_opt) == 0)
4478@@ -3581,21 +4386,54 @@ EOF
4479 lt_dump_script (stdout);
4480 return 0;
4481 }
4482+ if (strcmp (argv[i], debug_opt) == 0)
4483+ {
4484+ lt_debug = 1;
4485+ continue;
4486+ }
4487+ if (strcmp (argv[i], ltwrapper_option_prefix) == 0)
4488+ {
4489+ /* however, if there is an option in the LTWRAPPER_OPTION_PREFIX
4490+ namespace, but it is not one of the ones we know about and
4491+ have already dealt with, above (inluding dump-script), then
4492+ report an error. Otherwise, targets might begin to believe
4493+ they are allowed to use options in the LTWRAPPER_OPTION_PREFIX
4494+ namespace. The first time any user complains about this, we'll
4495+ need to make LTWRAPPER_OPTION_PREFIX a configure-time option
4496+ or a configure.ac-settable value.
4497+ */
4498+ lt_fatal (__FILE__, __LINE__,
4499+ "unrecognized %s option: '%s'",
4500+ ltwrapper_option_prefix, argv[i]);
4501+ }
4502+ /* otherwise ... */
4503+ newargz[++newargc] = xstrdup (argv[i]);
4504 }
4505+ newargz[++newargc] = NULL;
4506+
4507+EOF
4508+ cat <<EOF
4509+ /* The GNU banner must be the first non-error debug message */
4510+ lt_debugprintf (__FILE__, __LINE__, "libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\n");
4511+EOF
4512+ cat <<"EOF"
4513+ lt_debugprintf (__FILE__, __LINE__, "(main) argv[0]: %s\n", argv[0]);
4514+ lt_debugprintf (__FILE__, __LINE__, "(main) program_name: %s\n", program_name);
4515
4516- newargz = XMALLOC (char *, argc + 1);
4517 tmp_pathspec = find_executable (argv[0]);
4518 if (tmp_pathspec == NULL)
4519- lt_fatal ("Couldn't find %s", argv[0]);
4520- LTWRAPPER_DEBUGPRINTF (("(main) found exe (before symlink chase) at : %s\n",
4521- tmp_pathspec));
4522+ lt_fatal (__FILE__, __LINE__, "couldn't find %s", argv[0]);
4523+ lt_debugprintf (__FILE__, __LINE__,
4524+ "(main) found exe (before symlink chase) at: %s\n",
4525+ tmp_pathspec);
4526
4527 actual_cwrapper_path = chase_symlinks (tmp_pathspec);
4528- LTWRAPPER_DEBUGPRINTF (("(main) found exe (after symlink chase) at : %s\n",
4529- actual_cwrapper_path));
4530+ lt_debugprintf (__FILE__, __LINE__,
4531+ "(main) found exe (after symlink chase) at: %s\n",
4532+ actual_cwrapper_path);
4533 XFREE (tmp_pathspec);
4534
4535- actual_cwrapper_name = xstrdup( base_name (actual_cwrapper_path));
4536+ actual_cwrapper_name = xstrdup (base_name (actual_cwrapper_path));
4537 strendzap (actual_cwrapper_path, actual_cwrapper_name);
4538
4539 /* wrapper name transforms */
4540@@ -3613,8 +4451,9 @@ EOF
4541 target_name = tmp_pathspec;
4542 tmp_pathspec = 0;
4543
4544- LTWRAPPER_DEBUGPRINTF (("(main) libtool target name: %s\n",
4545- target_name));
4546+ lt_debugprintf (__FILE__, __LINE__,
4547+ "(main) libtool target name: %s\n",
4548+ target_name);
4549 EOF
4550
4551 cat <<EOF
4552@@ -3664,35 +4503,19 @@ EOF
4553
4554 lt_setenv ("BIN_SH", "xpg4"); /* for Tru64 */
4555 lt_setenv ("DUALCASE", "1"); /* for MSK sh */
4556- lt_update_lib_path (LIB_PATH_VARNAME, LIB_PATH_VALUE);
4557+ /* Update the DLL searchpath. EXE_PATH_VALUE ($dllsearchpath) must
4558+ be prepended before (that is, appear after) LIB_PATH_VALUE ($temp_rpath)
4559+ because on Windows, both *_VARNAMEs are PATH but uninstalled
4560+ libraries must come first. */
4561 lt_update_exe_path (EXE_PATH_VARNAME, EXE_PATH_VALUE);
4562+ lt_update_lib_path (LIB_PATH_VARNAME, LIB_PATH_VALUE);
4563
4564- newargc=0;
4565- for (i = 1; i < argc; i++)
4566- {
4567- if (strncmp (argv[i], ltwrapper_option_prefix, opt_prefix_len) == 0)
4568- {
4569- /* however, if there is an option in the LTWRAPPER_OPTION_PREFIX
4570- namespace, but it is not one of the ones we know about and
4571- have already dealt with, above (inluding dump-script), then
4572- report an error. Otherwise, targets might begin to believe
4573- they are allowed to use options in the LTWRAPPER_OPTION_PREFIX
4574- namespace. The first time any user complains about this, we'll
4575- need to make LTWRAPPER_OPTION_PREFIX a configure-time option
4576- or a configure.ac-settable value.
4577- */
4578- lt_fatal ("Unrecognized option in %s namespace: '%s'",
4579- ltwrapper_option_prefix, argv[i]);
4580- }
4581- /* otherwise ... */
4582- newargz[++newargc] = xstrdup (argv[i]);
4583- }
4584- newargz[++newargc] = NULL;
4585-
4586- LTWRAPPER_DEBUGPRINTF (("(main) lt_argv_zero : %s\n", (lt_argv_zero ? lt_argv_zero : "<NULL>")));
4587+ lt_debugprintf (__FILE__, __LINE__, "(main) lt_argv_zero: %s\n",
4588+ nonnull (lt_argv_zero));
4589 for (i = 0; i < newargc; i++)
4590 {
4591- LTWRAPPER_DEBUGPRINTF (("(main) newargz[%d] : %s\n", i, (newargz[i] ? newargz[i] : "<NULL>")));
4592+ lt_debugprintf (__FILE__, __LINE__, "(main) newargz[%d]: %s\n",
4593+ i, nonnull (newargz[i]));
4594 }
4595
4596 EOF
4597@@ -3706,7 +4529,9 @@ EOF
4598 if (rval == -1)
4599 {
4600 /* failed to start process */
4601- LTWRAPPER_DEBUGPRINTF (("(main) failed to launch target \"%s\": errno = %d\n", lt_argv_zero, errno));
4602+ lt_debugprintf (__FILE__, __LINE__,
4603+ "(main) failed to launch target \"%s\": %s\n",
4604+ lt_argv_zero, nonnull (strerror (errno)));
4605 return 127;
4606 }
4607 return rval;
4608@@ -3728,7 +4553,7 @@ xmalloc (size_t num)
4609 {
4610 void *p = (void *) malloc (num);
4611 if (!p)
4612- lt_fatal ("Memory exhausted");
4613+ lt_fatal (__FILE__, __LINE__, "memory exhausted");
4614
4615 return p;
4616 }
4617@@ -3762,8 +4587,8 @@ check_executable (const char *path)
4618 {
4619 struct stat st;
4620
4621- LTWRAPPER_DEBUGPRINTF (("(check_executable) : %s\n",
4622- path ? (*path ? path : "EMPTY!") : "NULL!"));
4623+ lt_debugprintf (__FILE__, __LINE__, "(check_executable): %s\n",
4624+ nonempty (path));
4625 if ((!path) || (!*path))
4626 return 0;
4627
4628@@ -3780,8 +4605,8 @@ make_executable (const char *path)
4629 int rval = 0;
4630 struct stat st;
4631
4632- LTWRAPPER_DEBUGPRINTF (("(make_executable) : %s\n",
4633- path ? (*path ? path : "EMPTY!") : "NULL!"));
4634+ lt_debugprintf (__FILE__, __LINE__, "(make_executable): %s\n",
4635+ nonempty (path));
4636 if ((!path) || (!*path))
4637 return 0;
4638
4639@@ -3807,8 +4632,8 @@ find_executable (const char *wrapper)
4640 int tmp_len;
4641 char *concat_name;
4642
4643- LTWRAPPER_DEBUGPRINTF (("(find_executable) : %s\n",
4644- wrapper ? (*wrapper ? wrapper : "EMPTY!") : "NULL!"));
4645+ lt_debugprintf (__FILE__, __LINE__, "(find_executable): %s\n",
4646+ nonempty (wrapper));
4647
4648 if ((wrapper == NULL) || (*wrapper == '\0'))
4649 return NULL;
4650@@ -3861,7 +4686,8 @@ find_executable (const char *wrapper)
4651 {
4652 /* empty path: current directory */
4653 if (getcwd (tmp, LT_PATHMAX) == NULL)
4654- lt_fatal ("getcwd failed");
4655+ lt_fatal (__FILE__, __LINE__, "getcwd failed: %s",
4656+ nonnull (strerror (errno)));
4657 tmp_len = strlen (tmp);
4658 concat_name =
4659 XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1);
4660@@ -3886,7 +4712,8 @@ find_executable (const char *wrapper)
4661 }
4662 /* Relative path | not found in path: prepend cwd */
4663 if (getcwd (tmp, LT_PATHMAX) == NULL)
4664- lt_fatal ("getcwd failed");
4665+ lt_fatal (__FILE__, __LINE__, "getcwd failed: %s",
4666+ nonnull (strerror (errno)));
4667 tmp_len = strlen (tmp);
4668 concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1);
4669 memcpy (concat_name, tmp, tmp_len);
4670@@ -3912,8 +4739,9 @@ chase_symlinks (const char *pathspec)
4671 int has_symlinks = 0;
4672 while (strlen (tmp_pathspec) && !has_symlinks)
4673 {
4674- LTWRAPPER_DEBUGPRINTF (("checking path component for symlinks: %s\n",
4675- tmp_pathspec));
4676+ lt_debugprintf (__FILE__, __LINE__,
4677+ "checking path component for symlinks: %s\n",
4678+ tmp_pathspec);
4679 if (lstat (tmp_pathspec, &s) == 0)
4680 {
4681 if (S_ISLNK (s.st_mode) != 0)
4682@@ -3935,8 +4763,9 @@ chase_symlinks (const char *pathspec)
4683 }
4684 else
4685 {
4686- char *errstr = strerror (errno);
4687- lt_fatal ("Error accessing file %s (%s)", tmp_pathspec, errstr);
4688+ lt_fatal (__FILE__, __LINE__,
4689+ "error accessing file \"%s\": %s",
4690+ tmp_pathspec, nonnull (strerror (errno)));
4691 }
4692 }
4693 XFREE (tmp_pathspec);
4694@@ -3949,7 +4778,8 @@ chase_symlinks (const char *pathspec)
4695 tmp_pathspec = realpath (pathspec, buf);
4696 if (tmp_pathspec == 0)
4697 {
4698- lt_fatal ("Could not follow symlinks for %s", pathspec);
4699+ lt_fatal (__FILE__, __LINE__,
4700+ "could not follow symlinks for %s", pathspec);
4701 }
4702 return xstrdup (tmp_pathspec);
4703 #endif
4704@@ -3975,11 +4805,25 @@ strendzap (char *str, const char *pat)
4705 return str;
4706 }
4707
4708+void
4709+lt_debugprintf (const char *file, int line, const char *fmt, ...)
4710+{
4711+ va_list args;
4712+ if (lt_debug)
4713+ {
4714+ (void) fprintf (stderr, "%s:%s:%d: ", program_name, file, line);
4715+ va_start (args, fmt);
4716+ (void) vfprintf (stderr, fmt, args);
4717+ va_end (args);
4718+ }
4719+}
4720+
4721 static void
4722-lt_error_core (int exit_status, const char *mode,
4723+lt_error_core (int exit_status, const char *file,
4724+ int line, const char *mode,
4725 const char *message, va_list ap)
4726 {
4727- fprintf (stderr, "%s: %s: ", program_name, mode);
4728+ fprintf (stderr, "%s:%s:%d: %s: ", program_name, file, line, mode);
4729 vfprintf (stderr, message, ap);
4730 fprintf (stderr, ".\n");
4731
4732@@ -3988,20 +4832,32 @@ lt_error_core (int exit_status, const ch
4733 }
4734
4735 void
4736-lt_fatal (const char *message, ...)
4737+lt_fatal (const char *file, int line, const char *message, ...)
4738 {
4739 va_list ap;
4740 va_start (ap, message);
4741- lt_error_core (EXIT_FAILURE, "FATAL", message, ap);
4742+ lt_error_core (EXIT_FAILURE, file, line, "FATAL", message, ap);
4743 va_end (ap);
4744 }
4745
4746+static const char *
4747+nonnull (const char *s)
4748+{
4749+ return s ? s : "(null)";
4750+}
4751+
4752+static const char *
4753+nonempty (const char *s)
4754+{
4755+ return (s && !*s) ? "(empty)" : nonnull (s);
4756+}
4757+
4758 void
4759 lt_setenv (const char *name, const char *value)
4760 {
4761- LTWRAPPER_DEBUGPRINTF (("(lt_setenv) setting '%s' to '%s'\n",
4762- (name ? name : "<NULL>"),
4763- (value ? value : "<NULL>")));
4764+ lt_debugprintf (__FILE__, __LINE__,
4765+ "(lt_setenv) setting '%s' to '%s'\n",
4766+ nonnull (name), nonnull (value));
4767 {
4768 #ifdef HAVE_SETENV
4769 /* always make a copy, for consistency with !HAVE_SETENV */
4770@@ -4049,9 +4905,9 @@ lt_extend_str (const char *orig_value, c
4771 void
4772 lt_update_exe_path (const char *name, const char *value)
4773 {
4774- LTWRAPPER_DEBUGPRINTF (("(lt_update_exe_path) modifying '%s' by prepending '%s'\n",
4775- (name ? name : "<NULL>"),
4776- (value ? value : "<NULL>")));
4777+ lt_debugprintf (__FILE__, __LINE__,
4778+ "(lt_update_exe_path) modifying '%s' by prepending '%s'\n",
4779+ nonnull (name), nonnull (value));
4780
4781 if (name && *name && value && *value)
4782 {
4783@@ -4070,9 +4926,9 @@ lt_update_exe_path (const char *name, co
4784 void
4785 lt_update_lib_path (const char *name, const char *value)
4786 {
4787- LTWRAPPER_DEBUGPRINTF (("(lt_update_lib_path) modifying '%s' by prepending '%s'\n",
4788- (name ? name : "<NULL>"),
4789- (value ? value : "<NULL>")));
4790+ lt_debugprintf (__FILE__, __LINE__,
4791+ "(lt_update_lib_path) modifying '%s' by prepending '%s'\n",
4792+ nonnull (name), nonnull (value));
4793
4794 if (name && *name && value && *value)
4795 {
4796@@ -4222,7 +5078,7 @@ EOF
4797 func_win32_import_lib_p ()
4798 {
4799 $opt_debug
4800- case `eval "$file_magic_cmd \"\$1\" 2>/dev/null" | $SED -e 10q` in
4801+ case `eval $file_magic_cmd \"\$1\" 2>/dev/null | $SED -e 10q` in
4802 *import*) : ;;
4803 *) false ;;
4804 esac
4805@@ -4401,9 +5257,9 @@ func_mode_link ()
4806 ;;
4807 *)
4808 if test "$prev" = dlfiles; then
4809- dlfiles="$dlfiles $arg"
4810+ func_append dlfiles " $arg"
4811 else
4812- dlprefiles="$dlprefiles $arg"
4813+ func_append dlprefiles " $arg"
4814 fi
4815 prev=
4816 continue
4817@@ -4427,7 +5283,7 @@ func_mode_link ()
4818 *-*-darwin*)
4819 case "$deplibs " in
4820 *" $qarg.ltframework "*) ;;
4821- *) deplibs="$deplibs $qarg.ltframework" # this is fixed later
4822+ *) func_append deplibs " $qarg.ltframework" # this is fixed later
4823 ;;
4824 esac
4825 ;;
4826@@ -4446,7 +5302,7 @@ func_mode_link ()
4827 moreargs=
4828 for fil in `cat "$save_arg"`
4829 do
4830-# moreargs="$moreargs $fil"
4831+# func_append moreargs " $fil"
4832 arg=$fil
4833 # A libtool-controlled object.
4834
4835@@ -4475,7 +5331,7 @@ func_mode_link ()
4836
4837 if test "$prev" = dlfiles; then
4838 if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then
4839- dlfiles="$dlfiles $pic_object"
4840+ func_append dlfiles " $pic_object"
4841 prev=
4842 continue
4843 else
4844@@ -4487,7 +5343,7 @@ func_mode_link ()
4845 # CHECK ME: I think I busted this. -Ossama
4846 if test "$prev" = dlprefiles; then
4847 # Preload the old-style object.
4848- dlprefiles="$dlprefiles $pic_object"
4849+ func_append dlprefiles " $pic_object"
4850 prev=
4851 fi
4852
4853@@ -4557,12 +5413,12 @@ func_mode_link ()
4854 if test "$prev" = rpath; then
4855 case "$rpath " in
4856 *" $arg "*) ;;
4857- *) rpath="$rpath $arg" ;;
4858+ *) func_append rpath " $arg" ;;
4859 esac
4860 else
4861 case "$xrpath " in
4862 *" $arg "*) ;;
4863- *) xrpath="$xrpath $arg" ;;
4864+ *) func_append xrpath " $arg" ;;
4865 esac
4866 fi
4867 prev=
4868@@ -4574,28 +5430,28 @@ func_mode_link ()
4869 continue
4870 ;;
4871 weak)
4872- weak_libs="$weak_libs $arg"
4873+ func_append weak_libs " $arg"
4874 prev=
4875 continue
4876 ;;
4877 xcclinker)
4878- linker_flags="$linker_flags $qarg"
4879- compiler_flags="$compiler_flags $qarg"
4880+ func_append linker_flags " $qarg"
4881+ func_append compiler_flags " $qarg"
4882 prev=
4883 func_append compile_command " $qarg"
4884 func_append finalize_command " $qarg"
4885 continue
4886 ;;
4887 xcompiler)
4888- compiler_flags="$compiler_flags $qarg"
4889+ func_append compiler_flags " $qarg"
4890 prev=
4891 func_append compile_command " $qarg"
4892 func_append finalize_command " $qarg"
4893 continue
4894 ;;
4895 xlinker)
4896- linker_flags="$linker_flags $qarg"
4897- compiler_flags="$compiler_flags $wl$qarg"
4898+ func_append linker_flags " $qarg"
4899+ func_append compiler_flags " $wl$qarg"
4900 prev=
4901 func_append compile_command " $wl$qarg"
4902 func_append finalize_command " $wl$qarg"
4903@@ -4686,15 +5542,16 @@ func_mode_link ()
4904 ;;
4905
4906 -L*)
4907- func_stripname '-L' '' "$arg"
4908- dir=$func_stripname_result
4909- if test -z "$dir"; then
4910+ func_stripname "-L" '' "$arg"
4911+ if test -z "$func_stripname_result"; then
4912 if test "$#" -gt 0; then
4913 func_fatal_error "require no space between \`-L' and \`$1'"
4914 else
4915 func_fatal_error "need path for \`-L' option"
4916 fi
4917 fi
4918+ func_resolve_sysroot "$func_stripname_result"
4919+ dir=$func_resolve_sysroot_result
4920 # We need an absolute path.
4921 case $dir in
4922 [\\/]* | [A-Za-z]:[\\/]*) ;;
4923@@ -4706,10 +5563,16 @@ func_mode_link ()
4924 ;;
4925 esac
4926 case "$deplibs " in
4927- *" -L$dir "*) ;;
4928+ *" -L$dir "* | *" $arg "*)
4929+ # Will only happen for absolute or sysroot arguments
4930+ ;;
4931 *)
4932- deplibs="$deplibs -L$dir"
4933- lib_search_path="$lib_search_path $dir"
4934+ # Preserve sysroot, but never include relative directories
4935+ case $dir in
4936+ [\\/]* | [A-Za-z]:[\\/]* | =*) func_append deplibs " $arg" ;;
4937+ *) func_append deplibs " -L$dir" ;;
4938+ esac
4939+ func_append lib_search_path " $dir"
4940 ;;
4941 esac
4942 case $host in
4943@@ -4718,12 +5581,12 @@ func_mode_link ()
4944 case :$dllsearchpath: in
4945 *":$dir:"*) ;;
4946 ::) dllsearchpath=$dir;;
4947- *) dllsearchpath="$dllsearchpath:$dir";;
4948+ *) func_append dllsearchpath ":$dir";;
4949 esac
4950 case :$dllsearchpath: in
4951 *":$testbindir:"*) ;;
4952 ::) dllsearchpath=$testbindir;;
4953- *) dllsearchpath="$dllsearchpath:$testbindir";;
4954+ *) func_append dllsearchpath ":$testbindir";;
4955 esac
4956 ;;
4957 esac
4958@@ -4747,7 +5610,7 @@ func_mode_link ()
4959 ;;
4960 *-*-rhapsody* | *-*-darwin1.[012])
4961 # Rhapsody C and math libraries are in the System framework
4962- deplibs="$deplibs System.ltframework"
4963+ func_append deplibs " System.ltframework"
4964 continue
4965 ;;
4966 *-*-sco3.2v5* | *-*-sco5v6*)
4967@@ -4758,9 +5621,6 @@ func_mode_link ()
4968 # Compiler inserts libc in the correct place for threads to work
4969 test "X$arg" = "X-lc" && continue
4970 ;;
4971- *-*-linux*)
4972- test "X$arg" = "X-lc" && continue
4973- ;;
4974 esac
4975 elif test "X$arg" = "X-lc_r"; then
4976 case $host in
4977@@ -4770,7 +5630,7 @@ func_mode_link ()
4978 ;;
4979 esac
4980 fi
4981- deplibs="$deplibs $arg"
4982+ func_append deplibs " $arg"
4983 continue
4984 ;;
4985
4986@@ -4782,8 +5642,8 @@ func_mode_link ()
4987 # Tru64 UNIX uses -model [arg] to determine the layout of C++
4988 # classes, name mangling, and exception handling.
4989 # Darwin uses the -arch flag to determine output architecture.
4990- -model|-arch|-isysroot)
4991- compiler_flags="$compiler_flags $arg"
4992+ -model|-arch|-isysroot|--sysroot)
4993+ func_append compiler_flags " $arg"
4994 func_append compile_command " $arg"
4995 func_append finalize_command " $arg"
4996 prev=xcompiler
4997@@ -4791,12 +5651,12 @@ func_mode_link ()
4998 ;;
4999
5000 -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads)
5001- compiler_flags="$compiler_flags $arg"
5002+ func_append compiler_flags " $arg"
5003 func_append compile_command " $arg"
5004 func_append finalize_command " $arg"
5005 case "$new_inherited_linker_flags " in
5006 *" $arg "*) ;;
5007- * ) new_inherited_linker_flags="$new_inherited_linker_flags $arg" ;;
5008+ * ) func_append new_inherited_linker_flags " $arg" ;;
5009 esac
5010 continue
5011 ;;
5012@@ -4863,13 +5723,17 @@ func_mode_link ()
5013 # We need an absolute path.
5014 case $dir in
5015 [\\/]* | [A-Za-z]:[\\/]*) ;;
5016+ =*)
5017+ func_stripname '=' '' "$dir"
5018+ dir=$lt_sysroot$func_stripname_result
5019+ ;;
5020 *)
5021 func_fatal_error "only absolute run-paths are allowed"
5022 ;;
5023 esac
5024 case "$xrpath " in
5025 *" $dir "*) ;;
5026- *) xrpath="$xrpath $dir" ;;
5027+ *) func_append xrpath " $dir" ;;
5028 esac
5029 continue
5030 ;;
5031@@ -4922,8 +5786,8 @@ func_mode_link ()
5032 for flag in $args; do
5033 IFS="$save_ifs"
5034 func_quote_for_eval "$flag"
5035- arg="$arg $func_quote_for_eval_result"
5036- compiler_flags="$compiler_flags $func_quote_for_eval_result"
5037+ func_append arg " $func_quote_for_eval_result"
5038+ func_append compiler_flags " $func_quote_for_eval_result"
5039 done
5040 IFS="$save_ifs"
5041 func_stripname ' ' '' "$arg"
5042@@ -4938,9 +5802,9 @@ func_mode_link ()
5043 for flag in $args; do
5044 IFS="$save_ifs"
5045 func_quote_for_eval "$flag"
5046- arg="$arg $wl$func_quote_for_eval_result"
5047- compiler_flags="$compiler_flags $wl$func_quote_for_eval_result"
5048- linker_flags="$linker_flags $func_quote_for_eval_result"
5049+ func_append arg " $wl$func_quote_for_eval_result"
5050+ func_append compiler_flags " $wl$func_quote_for_eval_result"
5051+ func_append linker_flags " $func_quote_for_eval_result"
5052 done
5053 IFS="$save_ifs"
5054 func_stripname ' ' '' "$arg"
5055@@ -4968,24 +5832,27 @@ func_mode_link ()
5056 arg="$func_quote_for_eval_result"
5057 ;;
5058
5059- # -64, -mips[0-9] enable 64-bit mode on the SGI compiler
5060- # -r[0-9][0-9]* specifies the processor on the SGI compiler
5061- # -xarch=*, -xtarget=* enable 64-bit mode on the Sun compiler
5062- # +DA*, +DD* enable 64-bit mode on the HP compiler
5063- # -q* pass through compiler args for the IBM compiler
5064- # -m*, -t[45]*, -txscale* pass through architecture-specific
5065- # compiler args for GCC
5066- # -F/path gives path to uninstalled frameworks, gcc on darwin
5067- # -p, -pg, --coverage, -fprofile-* pass through profiling flag for GCC
5068- # @file GCC response files
5069- # -tp=* Portland pgcc target processor selection
5070+ # Flags to be passed through unchanged, with rationale:
5071+ # -64, -mips[0-9] enable 64-bit mode for the SGI compiler
5072+ # -r[0-9][0-9]* specify processor for the SGI compiler
5073+ # -xarch=*, -xtarget=* enable 64-bit mode for the Sun compiler
5074+ # +DA*, +DD* enable 64-bit mode for the HP compiler
5075+ # -q* compiler args for the IBM compiler
5076+ # -m*, -t[45]*, -txscale* architecture-specific flags for GCC
5077+ # -F/path path to uninstalled frameworks, gcc on darwin
5078+ # -p, -pg, --coverage, -fprofile-* profiling flags for GCC
5079+ # @file GCC response files
5080+ # -tp=* Portland pgcc target processor selection
5081+ # --sysroot=* for sysroot support
5082+ # -O*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization
5083 -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \
5084- -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*)
5085+ -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \
5086+ -O*|-flto*|-fwhopr*|-fuse-linker-plugin)
5087 func_quote_for_eval "$arg"
5088 arg="$func_quote_for_eval_result"
5089 func_append compile_command " $arg"
5090 func_append finalize_command " $arg"
5091- compiler_flags="$compiler_flags $arg"
5092+ func_append compiler_flags " $arg"
5093 continue
5094 ;;
5095
5096@@ -4997,7 +5864,7 @@ func_mode_link ()
5097
5098 *.$objext)
5099 # A standard object.
5100- objs="$objs $arg"
5101+ func_append objs " $arg"
5102 ;;
5103
5104 *.lo)
5105@@ -5028,7 +5895,7 @@ func_mode_link ()
5106
5107 if test "$prev" = dlfiles; then
5108 if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then
5109- dlfiles="$dlfiles $pic_object"
5110+ func_append dlfiles " $pic_object"
5111 prev=
5112 continue
5113 else
5114@@ -5040,7 +5907,7 @@ func_mode_link ()
5115 # CHECK ME: I think I busted this. -Ossama
5116 if test "$prev" = dlprefiles; then
5117 # Preload the old-style object.
5118- dlprefiles="$dlprefiles $pic_object"
5119+ func_append dlprefiles " $pic_object"
5120 prev=
5121 fi
5122
5123@@ -5085,24 +5952,25 @@ func_mode_link ()
5124
5125 *.$libext)
5126 # An archive.
5127- deplibs="$deplibs $arg"
5128- old_deplibs="$old_deplibs $arg"
5129+ func_append deplibs " $arg"
5130+ func_append old_deplibs " $arg"
5131 continue
5132 ;;
5133
5134 *.la)
5135 # A libtool-controlled library.
5136
5137+ func_resolve_sysroot "$arg"
5138 if test "$prev" = dlfiles; then
5139 # This library was specified with -dlopen.
5140- dlfiles="$dlfiles $arg"
5141+ func_append dlfiles " $func_resolve_sysroot_result"
5142 prev=
5143 elif test "$prev" = dlprefiles; then
5144 # The library was specified with -dlpreopen.
5145- dlprefiles="$dlprefiles $arg"
5146+ func_append dlprefiles " $func_resolve_sysroot_result"
5147 prev=
5148 else
5149- deplibs="$deplibs $arg"
5150+ func_append deplibs " $func_resolve_sysroot_result"
5151 fi
5152 continue
5153 ;;
5154@@ -5127,7 +5995,7 @@ func_mode_link ()
5155 func_fatal_help "the \`$prevarg' option requires an argument"
5156
5157 if test "$export_dynamic" = yes && test -n "$export_dynamic_flag_spec"; then
5158- eval "arg=\"$export_dynamic_flag_spec\""
5159+ eval arg=\"$export_dynamic_flag_spec\"
5160 func_append compile_command " $arg"
5161 func_append finalize_command " $arg"
5162 fi
5163@@ -5144,11 +6012,13 @@ func_mode_link ()
5164 else
5165 shlib_search_path=
5166 fi
5167- eval "sys_lib_search_path=\"$sys_lib_search_path_spec\""
5168- eval "sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\""
5169+ eval sys_lib_search_path=\"$sys_lib_search_path_spec\"
5170+ eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\"
5171
5172 func_dirname "$output" "/" ""
5173 output_objdir="$func_dirname_result$objdir"
5174+ func_to_tool_file "$output_objdir/"
5175+ tool_output_objdir=$func_to_tool_file_result
5176 # Create the object directory.
5177 func_mkdir_p "$output_objdir"
5178
5179@@ -5169,12 +6039,12 @@ func_mode_link ()
5180 # Find all interdependent deplibs by searching for libraries
5181 # that are linked more than once (e.g. -la -lb -la)
5182 for deplib in $deplibs; do
5183- if $opt_duplicate_deps ; then
5184+ if $opt_preserve_dup_deps ; then
5185 case "$libs " in
5186- *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;;
5187+ *" $deplib "*) func_append specialdeplibs " $deplib" ;;
5188 esac
5189 fi
5190- libs="$libs $deplib"
5191+ func_append libs " $deplib"
5192 done
5193
5194 if test "$linkmode" = lib; then
5195@@ -5187,9 +6057,9 @@ func_mode_link ()
5196 if $opt_duplicate_compiler_generated_deps; then
5197 for pre_post_dep in $predeps $postdeps; do
5198 case "$pre_post_deps " in
5199- *" $pre_post_dep "*) specialdeplibs="$specialdeplibs $pre_post_deps" ;;
5200+ *" $pre_post_dep "*) func_append specialdeplibs " $pre_post_deps" ;;
5201 esac
5202- pre_post_deps="$pre_post_deps $pre_post_dep"
5203+ func_append pre_post_deps " $pre_post_dep"
5204 done
5205 fi
5206 pre_post_deps=
5207@@ -5256,8 +6126,9 @@ func_mode_link ()
5208 for lib in $dlprefiles; do
5209 # Ignore non-libtool-libs
5210 dependency_libs=
5211+ func_resolve_sysroot "$lib"
5212 case $lib in
5213- *.la) func_source "$lib" ;;
5214+ *.la) func_source "$func_resolve_sysroot_result" ;;
5215 esac
5216
5217 # Collect preopened libtool deplibs, except any this library
5218@@ -5267,7 +6138,7 @@ func_mode_link ()
5219 deplib_base=$func_basename_result
5220 case " $weak_libs " in
5221 *" $deplib_base "*) ;;
5222- *) deplibs="$deplibs $deplib" ;;
5223+ *) func_append deplibs " $deplib" ;;
5224 esac
5225 done
5226 done
5227@@ -5288,11 +6159,11 @@ func_mode_link ()
5228 compile_deplibs="$deplib $compile_deplibs"
5229 finalize_deplibs="$deplib $finalize_deplibs"
5230 else
5231- compiler_flags="$compiler_flags $deplib"
5232+ func_append compiler_flags " $deplib"
5233 if test "$linkmode" = lib ; then
5234 case "$new_inherited_linker_flags " in
5235 *" $deplib "*) ;;
5236- * ) new_inherited_linker_flags="$new_inherited_linker_flags $deplib" ;;
5237+ * ) func_append new_inherited_linker_flags " $deplib" ;;
5238 esac
5239 fi
5240 fi
5241@@ -5377,7 +6248,7 @@ func_mode_link ()
5242 if test "$linkmode" = lib ; then
5243 case "$new_inherited_linker_flags " in
5244 *" $deplib "*) ;;
5245- * ) new_inherited_linker_flags="$new_inherited_linker_flags $deplib" ;;
5246+ * ) func_append new_inherited_linker_flags " $deplib" ;;
5247 esac
5248 fi
5249 fi
5250@@ -5390,7 +6261,8 @@ func_mode_link ()
5251 test "$pass" = conv && continue
5252 newdependency_libs="$deplib $newdependency_libs"
5253 func_stripname '-L' '' "$deplib"
5254- newlib_search_path="$newlib_search_path $func_stripname_result"
5255+ func_resolve_sysroot "$func_stripname_result"
5256+ func_append newlib_search_path " $func_resolve_sysroot_result"
5257 ;;
5258 prog)
5259 if test "$pass" = conv; then
5260@@ -5404,7 +6276,8 @@ func_mode_link ()
5261 finalize_deplibs="$deplib $finalize_deplibs"
5262 fi
5263 func_stripname '-L' '' "$deplib"
5264- newlib_search_path="$newlib_search_path $func_stripname_result"
5265+ func_resolve_sysroot "$func_stripname_result"
5266+ func_append newlib_search_path " $func_resolve_sysroot_result"
5267 ;;
5268 *)
5269 func_warning "\`-L' is ignored for archives/objects"
5270@@ -5415,17 +6288,21 @@ func_mode_link ()
5271 -R*)
5272 if test "$pass" = link; then
5273 func_stripname '-R' '' "$deplib"
5274- dir=$func_stripname_result
5275+ func_resolve_sysroot "$func_stripname_result"
5276+ dir=$func_resolve_sysroot_result
5277 # Make sure the xrpath contains only unique directories.
5278 case "$xrpath " in
5279 *" $dir "*) ;;
5280- *) xrpath="$xrpath $dir" ;;
5281+ *) func_append xrpath " $dir" ;;
5282 esac
5283 fi
5284 deplibs="$deplib $deplibs"
5285 continue
5286 ;;
5287- *.la) lib="$deplib" ;;
5288+ *.la)
5289+ func_resolve_sysroot "$deplib"
5290+ lib=$func_resolve_sysroot_result
5291+ ;;
5292 *.$libext)
5293 if test "$pass" = conv; then
5294 deplibs="$deplib $deplibs"
5295@@ -5488,11 +6365,11 @@ func_mode_link ()
5296 if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then
5297 # If there is no dlopen support or we're linking statically,
5298 # we need to preload.
5299- newdlprefiles="$newdlprefiles $deplib"
5300+ func_append newdlprefiles " $deplib"
5301 compile_deplibs="$deplib $compile_deplibs"
5302 finalize_deplibs="$deplib $finalize_deplibs"
5303 else
5304- newdlfiles="$newdlfiles $deplib"
5305+ func_append newdlfiles " $deplib"
5306 fi
5307 fi
5308 continue
5309@@ -5538,7 +6415,7 @@ func_mode_link ()
5310 for tmp_inherited_linker_flag in $tmp_inherited_linker_flags; do
5311 case " $new_inherited_linker_flags " in
5312 *" $tmp_inherited_linker_flag "*) ;;
5313- *) new_inherited_linker_flags="$new_inherited_linker_flags $tmp_inherited_linker_flag";;
5314+ *) func_append new_inherited_linker_flags " $tmp_inherited_linker_flag";;
5315 esac
5316 done
5317 fi
5318@@ -5546,8 +6423,8 @@ func_mode_link ()
5319 if test "$linkmode,$pass" = "lib,link" ||
5320 test "$linkmode,$pass" = "prog,scan" ||
5321 { test "$linkmode" != prog && test "$linkmode" != lib; }; then
5322- test -n "$dlopen" && dlfiles="$dlfiles $dlopen"
5323- test -n "$dlpreopen" && dlprefiles="$dlprefiles $dlpreopen"
5324+ test -n "$dlopen" && func_append dlfiles " $dlopen"
5325+ test -n "$dlpreopen" && func_append dlprefiles " $dlpreopen"
5326 fi
5327
5328 if test "$pass" = conv; then
5329@@ -5558,20 +6435,20 @@ func_mode_link ()
5330 func_fatal_error "cannot find name of link library for \`$lib'"
5331 fi
5332 # It is a libtool convenience library, so add in its objects.
5333- convenience="$convenience $ladir/$objdir/$old_library"
5334- old_convenience="$old_convenience $ladir/$objdir/$old_library"
5335+ func_append convenience " $ladir/$objdir/$old_library"
5336+ func_append old_convenience " $ladir/$objdir/$old_library"
5337 elif test "$linkmode" != prog && test "$linkmode" != lib; then
5338 func_fatal_error "\`$lib' is not a convenience library"
5339 fi
5340 tmp_libs=
5341 for deplib in $dependency_libs; do
5342 deplibs="$deplib $deplibs"
5343- if $opt_duplicate_deps ; then
5344+ if $opt_preserve_dup_deps ; then
5345 case "$tmp_libs " in
5346- *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;;
5347+ *" $deplib "*) func_append specialdeplibs " $deplib" ;;
5348 esac
5349 fi
5350- tmp_libs="$tmp_libs $deplib"
5351+ func_append tmp_libs " $deplib"
5352 done
5353 continue
5354 fi # $pass = conv
5355@@ -5579,9 +6456,15 @@ func_mode_link ()
5356
5357 # Get the name of the library we link against.
5358 linklib=
5359- for l in $old_library $library_names; do
5360- linklib="$l"
5361- done
5362+ if test -n "$old_library" &&
5363+ { test "$prefer_static_libs" = yes ||
5364+ test "$prefer_static_libs,$installed" = "built,no"; }; then
5365+ linklib=$old_library
5366+ else
5367+ for l in $old_library $library_names; do
5368+ linklib="$l"
5369+ done
5370+ fi
5371 if test -z "$linklib"; then
5372 func_fatal_error "cannot find name of link library for \`$lib'"
5373 fi
5374@@ -5598,9 +6481,9 @@ func_mode_link ()
5375 # statically, we need to preload. We also need to preload any
5376 # dependent libraries so libltdl's deplib preloader doesn't
5377 # bomb out in the load deplibs phase.
5378- dlprefiles="$dlprefiles $lib $dependency_libs"
5379+ func_append dlprefiles " $lib $dependency_libs"
5380 else
5381- newdlfiles="$newdlfiles $lib"
5382+ func_append newdlfiles " $lib"
5383 fi
5384 continue
5385 fi # $pass = dlopen
5386@@ -5622,14 +6505,14 @@ func_mode_link ()
5387
5388 # Find the relevant object directory and library name.
5389 if test "X$installed" = Xyes; then
5390- if test ! -f "$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then
5391+ if test ! -f "$lt_sysroot$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then
5392 func_warning "library \`$lib' was moved."
5393 dir="$ladir"
5394 absdir="$abs_ladir"
5395 libdir="$abs_ladir"
5396 else
5397- dir="$libdir"
5398- absdir="$libdir"
5399+ dir="$lt_sysroot$libdir"
5400+ absdir="$lt_sysroot$libdir"
5401 fi
5402 test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes
5403 else
5404@@ -5637,12 +6520,12 @@ func_mode_link ()
5405 dir="$ladir"
5406 absdir="$abs_ladir"
5407 # Remove this search path later
5408- notinst_path="$notinst_path $abs_ladir"
5409+ func_append notinst_path " $abs_ladir"
5410 else
5411 dir="$ladir/$objdir"
5412 absdir="$abs_ladir/$objdir"
5413 # Remove this search path later
5414- notinst_path="$notinst_path $abs_ladir"
5415+ func_append notinst_path " $abs_ladir"
5416 fi
5417 fi # $installed = yes
5418 func_stripname 'lib' '.la' "$laname"
5419@@ -5653,20 +6536,46 @@ func_mode_link ()
5420 if test -z "$libdir" && test "$linkmode" = prog; then
5421 func_fatal_error "only libraries may -dlpreopen a convenience library: \`$lib'"
5422 fi
5423- # Prefer using a static library (so that no silly _DYNAMIC symbols
5424- # are required to link).
5425- if test -n "$old_library"; then
5426- newdlprefiles="$newdlprefiles $dir/$old_library"
5427- # Keep a list of preopened convenience libraries to check
5428- # that they are being used correctly in the link pass.
5429- test -z "$libdir" && \
5430- dlpreconveniencelibs="$dlpreconveniencelibs $dir/$old_library"
5431- # Otherwise, use the dlname, so that lt_dlopen finds it.
5432- elif test -n "$dlname"; then
5433- newdlprefiles="$newdlprefiles $dir/$dlname"
5434- else
5435- newdlprefiles="$newdlprefiles $dir/$linklib"
5436- fi
5437+ case "$host" in
5438+ # special handling for platforms with PE-DLLs.
5439+ *cygwin* | *mingw* | *cegcc* )
5440+ # Linker will automatically link against shared library if both
5441+ # static and shared are present. Therefore, ensure we extract
5442+ # symbols from the import library if a shared library is present
5443+ # (otherwise, the dlopen module name will be incorrect). We do
5444+ # this by putting the import library name into $newdlprefiles.
5445+ # We recover the dlopen module name by 'saving' the la file
5446+ # name in a special purpose variable, and (later) extracting the
5447+ # dlname from the la file.
5448+ if test -n "$dlname"; then
5449+ func_tr_sh "$dir/$linklib"
5450+ eval "libfile_$func_tr_sh_result=\$abs_ladir/\$laname"
5451+ func_append newdlprefiles " $dir/$linklib"
5452+ else
5453+ func_append newdlprefiles " $dir/$old_library"
5454+ # Keep a list of preopened convenience libraries to check
5455+ # that they are being used correctly in the link pass.
5456+ test -z "$libdir" && \
5457+ func_append dlpreconveniencelibs " $dir/$old_library"
5458+ fi
5459+ ;;
5460+ * )
5461+ # Prefer using a static library (so that no silly _DYNAMIC symbols
5462+ # are required to link).
5463+ if test -n "$old_library"; then
5464+ func_append newdlprefiles " $dir/$old_library"
5465+ # Keep a list of preopened convenience libraries to check
5466+ # that they are being used correctly in the link pass.
5467+ test -z "$libdir" && \
5468+ func_append dlpreconveniencelibs " $dir/$old_library"
5469+ # Otherwise, use the dlname, so that lt_dlopen finds it.
5470+ elif test -n "$dlname"; then
5471+ func_append newdlprefiles " $dir/$dlname"
5472+ else
5473+ func_append newdlprefiles " $dir/$linklib"
5474+ fi
5475+ ;;
5476+ esac
5477 fi # $pass = dlpreopen
5478
5479 if test -z "$libdir"; then
5480@@ -5684,7 +6593,7 @@ func_mode_link ()
5481
5482
5483 if test "$linkmode" = prog && test "$pass" != link; then
5484- newlib_search_path="$newlib_search_path $ladir"
5485+ func_append newlib_search_path " $ladir"
5486 deplibs="$lib $deplibs"
5487
5488 linkalldeplibs=no
5489@@ -5697,7 +6606,8 @@ func_mode_link ()
5490 for deplib in $dependency_libs; do
5491 case $deplib in
5492 -L*) func_stripname '-L' '' "$deplib"
5493- newlib_search_path="$newlib_search_path $func_stripname_result"
5494+ func_resolve_sysroot "$func_stripname_result"
5495+ func_append newlib_search_path " $func_resolve_sysroot_result"
5496 ;;
5497 esac
5498 # Need to link against all dependency_libs?
5499@@ -5708,12 +6618,12 @@ func_mode_link ()
5500 # or/and link against static libraries
5501 newdependency_libs="$deplib $newdependency_libs"
5502 fi
5503- if $opt_duplicate_deps ; then
5504+ if $opt_preserve_dup_deps ; then
5505 case "$tmp_libs " in
5506- *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;;
5507+ *" $deplib "*) func_append specialdeplibs " $deplib" ;;
5508 esac
5509 fi
5510- tmp_libs="$tmp_libs $deplib"
5511+ func_append tmp_libs " $deplib"
5512 done # for deplib
5513 continue
5514 fi # $linkmode = prog...
5515@@ -5728,7 +6638,7 @@ func_mode_link ()
5516 # Make sure the rpath contains only unique directories.
5517 case "$temp_rpath:" in
5518 *"$absdir:"*) ;;
5519- *) temp_rpath="$temp_rpath$absdir:" ;;
5520+ *) func_append temp_rpath "$absdir:" ;;
5521 esac
5522 fi
5523
5524@@ -5740,7 +6650,7 @@ func_mode_link ()
5525 *)
5526 case "$compile_rpath " in
5527 *" $absdir "*) ;;
5528- *) compile_rpath="$compile_rpath $absdir"
5529+ *) func_append compile_rpath " $absdir" ;;
5530 esac
5531 ;;
5532 esac
5533@@ -5749,7 +6659,7 @@ func_mode_link ()
5534 *)
5535 case "$finalize_rpath " in
5536 *" $libdir "*) ;;
5537- *) finalize_rpath="$finalize_rpath $libdir"
5538+ *) func_append finalize_rpath " $libdir" ;;
5539 esac
5540 ;;
5541 esac
5542@@ -5774,12 +6684,12 @@ func_mode_link ()
5543 case $host in
5544 *cygwin* | *mingw* | *cegcc*)
5545 # No point in relinking DLLs because paths are not encoded
5546- notinst_deplibs="$notinst_deplibs $lib"
5547+ func_append notinst_deplibs " $lib"
5548 need_relink=no
5549 ;;
5550 *)
5551 if test "$installed" = no; then
5552- notinst_deplibs="$notinst_deplibs $lib"
5553+ func_append notinst_deplibs " $lib"
5554 need_relink=yes
5555 fi
5556 ;;
5557@@ -5814,7 +6724,7 @@ func_mode_link ()
5558 *)
5559 case "$compile_rpath " in
5560 *" $absdir "*) ;;
5561- *) compile_rpath="$compile_rpath $absdir"
5562+ *) func_append compile_rpath " $absdir" ;;
5563 esac
5564 ;;
5565 esac
5566@@ -5823,7 +6733,7 @@ func_mode_link ()
5567 *)
5568 case "$finalize_rpath " in
5569 *" $libdir "*) ;;
5570- *) finalize_rpath="$finalize_rpath $libdir"
5571+ *) func_append finalize_rpath " $libdir" ;;
5572 esac
5573 ;;
5574 esac
5575@@ -5835,7 +6745,7 @@ func_mode_link ()
5576 shift
5577 realname="$1"
5578 shift
5579- eval "libname=\"$libname_spec\""
5580+ libname=`eval "\\$ECHO \"$libname_spec\""`
5581 # use dlname if we got it. it's perfectly good, no?
5582 if test -n "$dlname"; then
5583 soname="$dlname"
5584@@ -5848,7 +6758,7 @@ func_mode_link ()
5585 versuffix="-$major"
5586 ;;
5587 esac
5588- eval "soname=\"$soname_spec\""
5589+ eval soname=\"$soname_spec\"
5590 else
5591 soname="$realname"
5592 fi
5593@@ -5877,7 +6787,7 @@ func_mode_link ()
5594 linklib=$newlib
5595 fi # test -n "$old_archive_from_expsyms_cmds"
5596
5597- if test "$linkmode" = prog || test "$mode" != relink; then
5598+ if test "$linkmode" = prog || test "$opt_mode" != relink; then
5599 add_shlibpath=
5600 add_dir=
5601 add=
5602@@ -5933,7 +6843,7 @@ func_mode_link ()
5603 if test -n "$inst_prefix_dir"; then
5604 case $libdir in
5605 [\\/]*)
5606- add_dir="$add_dir -L$inst_prefix_dir$libdir"
5607+ func_append add_dir " -L$inst_prefix_dir$libdir"
5608 ;;
5609 esac
5610 fi
5611@@ -5955,7 +6865,7 @@ func_mode_link ()
5612 if test -n "$add_shlibpath"; then
5613 case :$compile_shlibpath: in
5614 *":$add_shlibpath:"*) ;;
5615- *) compile_shlibpath="$compile_shlibpath$add_shlibpath:" ;;
5616+ *) func_append compile_shlibpath "$add_shlibpath:" ;;
5617 esac
5618 fi
5619 if test "$linkmode" = prog; then
5620@@ -5969,13 +6879,13 @@ func_mode_link ()
5621 test "$hardcode_shlibpath_var" = yes; then
5622 case :$finalize_shlibpath: in
5623 *":$libdir:"*) ;;
5624- *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;;
5625+ *) func_append finalize_shlibpath "$libdir:" ;;
5626 esac
5627 fi
5628 fi
5629 fi
5630
5631- if test "$linkmode" = prog || test "$mode" = relink; then
5632+ if test "$linkmode" = prog || test "$opt_mode" = relink; then
5633 add_shlibpath=
5634 add_dir=
5635 add=
5636@@ -5989,7 +6899,7 @@ func_mode_link ()
5637 elif test "$hardcode_shlibpath_var" = yes; then
5638 case :$finalize_shlibpath: in
5639 *":$libdir:"*) ;;
5640- *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;;
5641+ *) func_append finalize_shlibpath "$libdir:" ;;
5642 esac
5643 add="-l$name"
5644 elif test "$hardcode_automatic" = yes; then
5645@@ -6001,12 +6911,12 @@ func_mode_link ()
5646 fi
5647 else
5648 # We cannot seem to hardcode it, guess we'll fake it.
5649- add_dir="-L$libdir"
5650+ add_dir="-L$lt_sysroot$libdir"
5651 # Try looking first in the location we're being installed to.
5652 if test -n "$inst_prefix_dir"; then
5653 case $libdir in
5654 [\\/]*)
5655- add_dir="$add_dir -L$inst_prefix_dir$libdir"
5656+ func_append add_dir " -L$inst_prefix_dir$libdir"
5657 ;;
5658 esac
5659 fi
5660@@ -6083,27 +6993,33 @@ func_mode_link ()
5661 temp_xrpath=$func_stripname_result
5662 case " $xrpath " in
5663 *" $temp_xrpath "*) ;;
5664- *) xrpath="$xrpath $temp_xrpath";;
5665+ *) func_append xrpath " $temp_xrpath";;
5666 esac;;
5667- *) temp_deplibs="$temp_deplibs $libdir";;
5668+ *) func_append temp_deplibs " $libdir";;
5669 esac
5670 done
5671 dependency_libs="$temp_deplibs"
5672 fi
5673
5674- newlib_search_path="$newlib_search_path $absdir"
5675+ func_append newlib_search_path " $absdir"
5676 # Link against this library
5677 test "$link_static" = no && newdependency_libs="$abs_ladir/$laname $newdependency_libs"
5678 # ... and its dependency_libs
5679 tmp_libs=
5680 for deplib in $dependency_libs; do
5681 newdependency_libs="$deplib $newdependency_libs"
5682- if $opt_duplicate_deps ; then
5683+ case $deplib in
5684+ -L*) func_stripname '-L' '' "$deplib"
5685+ func_resolve_sysroot "$func_stripname_result";;
5686+ *) func_resolve_sysroot "$deplib" ;;
5687+ esac
5688+ if $opt_preserve_dup_deps ; then
5689 case "$tmp_libs " in
5690- *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;;
5691+ *" $func_resolve_sysroot_result "*)
5692+ func_append specialdeplibs " $func_resolve_sysroot_result" ;;
5693 esac
5694 fi
5695- tmp_libs="$tmp_libs $deplib"
5696+ func_append tmp_libs " $func_resolve_sysroot_result"
5697 done
5698
5699 if test "$link_all_deplibs" != no; then
5700@@ -6113,8 +7029,10 @@ func_mode_link ()
5701 case $deplib in
5702 -L*) path="$deplib" ;;
5703 *.la)
5704+ func_resolve_sysroot "$deplib"
5705+ deplib=$func_resolve_sysroot_result
5706 func_dirname "$deplib" "" "."
5707- dir="$func_dirname_result"
5708+ dir=$func_dirname_result
5709 # We need an absolute path.
5710 case $dir in
5711 [\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;;
5712@@ -6130,7 +7048,7 @@ func_mode_link ()
5713 case $host in
5714 *-*-darwin*)
5715 depdepl=
5716- deplibrary_names=`${SED} -n -e 's/^library_names=\(.*\)$/\1/p' $deplib`
5717+ eval deplibrary_names=`${SED} -n -e 's/^library_names=\(.*\)$/\1/p' $deplib`
5718 if test -n "$deplibrary_names" ; then
5719 for tmp in $deplibrary_names ; do
5720 depdepl=$tmp
5721@@ -6141,8 +7059,8 @@ func_mode_link ()
5722 if test -z "$darwin_install_name"; then
5723 darwin_install_name=`${OTOOL64} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'`
5724 fi
5725- compiler_flags="$compiler_flags ${wl}-dylib_file ${wl}${darwin_install_name}:${depdepl}"
5726- linker_flags="$linker_flags -dylib_file ${darwin_install_name}:${depdepl}"
5727+ func_append compiler_flags " ${wl}-dylib_file ${wl}${darwin_install_name}:${depdepl}"
5728+ func_append linker_flags " -dylib_file ${darwin_install_name}:${depdepl}"
5729 path=
5730 fi
5731 fi
5732@@ -6152,7 +7070,7 @@ func_mode_link ()
5733 ;;
5734 esac
5735 else
5736- libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib`
5737+ eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib`
5738 test -z "$libdir" && \
5739 func_fatal_error "\`$deplib' is not a valid libtool archive"
5740 test "$absdir" != "$libdir" && \
5741@@ -6192,7 +7110,7 @@ func_mode_link ()
5742 for dir in $newlib_search_path; do
5743 case "$lib_search_path " in
5744 *" $dir "*) ;;
5745- *) lib_search_path="$lib_search_path $dir" ;;
5746+ *) func_append lib_search_path " $dir" ;;
5747 esac
5748 done
5749 newlib_search_path=
5750@@ -6205,7 +7123,7 @@ func_mode_link ()
5751 fi
5752 for var in $vars dependency_libs; do
5753 # Add libraries to $var in reverse order
5754- eval tmp_libs=\$$var
5755+ eval tmp_libs=\"\$$var\"
5756 new_libs=
5757 for deplib in $tmp_libs; do
5758 # FIXME: Pedantically, this is the right thing to do, so
5759@@ -6250,13 +7168,13 @@ func_mode_link ()
5760 -L*)
5761 case " $tmp_libs " in
5762 *" $deplib "*) ;;
5763- *) tmp_libs="$tmp_libs $deplib" ;;
5764+ *) func_append tmp_libs " $deplib" ;;
5765 esac
5766 ;;
5767- *) tmp_libs="$tmp_libs $deplib" ;;
5768+ *) func_append tmp_libs " $deplib" ;;
5769 esac
5770 done
5771- eval $var=\$tmp_libs
5772+ eval $var=\"$tmp_libs\"
5773 done # for var
5774 fi
5775 # Last step: remove runtime libs from dependency_libs
5776@@ -6269,7 +7187,7 @@ func_mode_link ()
5777 ;;
5778 esac
5779 if test -n "$i" ; then
5780- tmp_libs="$tmp_libs $i"
5781+ func_append tmp_libs " $i"
5782 fi
5783 done
5784 dependency_libs=$tmp_libs
5785@@ -6310,7 +7228,7 @@ func_mode_link ()
5786 # Now set the variables for building old libraries.
5787 build_libtool_libs=no
5788 oldlibs="$output"
5789- objs="$objs$old_deplibs"
5790+ func_append objs "$old_deplibs"
5791 ;;
5792
5793 lib)
5794@@ -6319,8 +7237,8 @@ func_mode_link ()
5795 lib*)
5796 func_stripname 'lib' '.la' "$outputname"
5797 name=$func_stripname_result
5798- eval "shared_ext=\"$shrext_cmds\""
5799- eval "libname=\"$libname_spec\""
5800+ eval shared_ext=\"$shrext_cmds\"
5801+ eval libname=\"$libname_spec\"
5802 ;;
5803 *)
5804 test "$module" = no && \
5805@@ -6330,8 +7248,8 @@ func_mode_link ()
5806 # Add the "lib" prefix for modules if required
5807 func_stripname '' '.la' "$outputname"
5808 name=$func_stripname_result
5809- eval "shared_ext=\"$shrext_cmds\""
5810- eval "libname=\"$libname_spec\""
5811+ eval shared_ext=\"$shrext_cmds\"
5812+ eval libname=\"$libname_spec\"
5813 else
5814 func_stripname '' '.la' "$outputname"
5815 libname=$func_stripname_result
5816@@ -6346,7 +7264,7 @@ func_mode_link ()
5817 echo
5818 $ECHO "*** Warning: Linking the shared library $output against the non-libtool"
5819 $ECHO "*** objects $objs is not portable!"
5820- libobjs="$libobjs $objs"
5821+ func_append libobjs " $objs"
5822 fi
5823 fi
5824
5825@@ -6544,7 +7462,7 @@ func_mode_link ()
5826 done
5827
5828 # Make executables depend on our current version.
5829- verstring="$verstring:${current}.0"
5830+ func_append verstring ":${current}.0"
5831 ;;
5832
5833 qnx)
5834@@ -6612,10 +7530,10 @@ func_mode_link ()
5835 fi
5836
5837 func_generate_dlsyms "$libname" "$libname" "yes"
5838- libobjs="$libobjs $symfileobj"
5839+ func_append libobjs " $symfileobj"
5840 test "X$libobjs" = "X " && libobjs=
5841
5842- if test "$mode" != relink; then
5843+ if test "$opt_mode" != relink; then
5844 # Remove our outputs, but don't remove object files since they
5845 # may have been created when compiling PIC objects.
5846 removelist=
5847@@ -6631,7 +7549,7 @@ func_mode_link ()
5848 continue
5849 fi
5850 fi
5851- removelist="$removelist $p"
5852+ func_append removelist " $p"
5853 ;;
5854 *) ;;
5855 esac
5856@@ -6642,7 +7560,7 @@ func_mode_link ()
5857
5858 # Now set the variables for building old libraries.
5859 if test "$build_old_libs" = yes && test "$build_libtool_libs" != convenience ; then
5860- oldlibs="$oldlibs $output_objdir/$libname.$libext"
5861+ func_append oldlibs " $output_objdir/$libname.$libext"
5862
5863 # Transform .lo files to .o files.
5864 oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; $lo2o" | $NL2SP`
5865@@ -6659,10 +7577,11 @@ func_mode_link ()
5866 # If the user specified any rpath flags, then add them.
5867 temp_xrpath=
5868 for libdir in $xrpath; do
5869- temp_xrpath="$temp_xrpath -R$libdir"
5870+ func_replace_sysroot "$libdir"
5871+ func_append temp_xrpath " -R$func_replace_sysroot_result"
5872 case "$finalize_rpath " in
5873 *" $libdir "*) ;;
5874- *) finalize_rpath="$finalize_rpath $libdir" ;;
5875+ *) func_append finalize_rpath " $libdir" ;;
5876 esac
5877 done
5878 if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then
5879@@ -6676,7 +7595,7 @@ func_mode_link ()
5880 for lib in $old_dlfiles; do
5881 case " $dlprefiles $dlfiles " in
5882 *" $lib "*) ;;
5883- *) dlfiles="$dlfiles $lib" ;;
5884+ *) func_append dlfiles " $lib" ;;
5885 esac
5886 done
5887
5888@@ -6686,7 +7605,7 @@ func_mode_link ()
5889 for lib in $old_dlprefiles; do
5890 case "$dlprefiles " in
5891 *" $lib "*) ;;
5892- *) dlprefiles="$dlprefiles $lib" ;;
5893+ *) func_append dlprefiles " $lib" ;;
5894 esac
5895 done
5896
5897@@ -6698,7 +7617,7 @@ func_mode_link ()
5898 ;;
5899 *-*-rhapsody* | *-*-darwin1.[012])
5900 # Rhapsody C library is in the System framework
5901- deplibs="$deplibs System.ltframework"
5902+ func_append deplibs " System.ltframework"
5903 ;;
5904 *-*-netbsd*)
5905 # Don't link with libc until the a.out ld.so is fixed.
5906@@ -6715,7 +7634,7 @@ func_mode_link ()
5907 *)
5908 # Add libc to deplibs on all other systems if necessary.
5909 if test "$build_libtool_need_lc" = "yes"; then
5910- deplibs="$deplibs -lc"
5911+ func_append deplibs " -lc"
5912 fi
5913 ;;
5914 esac
5915@@ -6764,18 +7683,18 @@ EOF
5916 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
5917 case " $predeps $postdeps " in
5918 *" $i "*)
5919- newdeplibs="$newdeplibs $i"
5920+ func_append newdeplibs " $i"
5921 i=""
5922 ;;
5923 esac
5924 fi
5925 if test -n "$i" ; then
5926- eval "libname=\"$libname_spec\""
5927- eval "deplib_matches=\"$library_names_spec\""
5928+ libname=`eval "\\$ECHO \"$libname_spec\""`
5929+ deplib_matches=`eval "\\$ECHO \"$library_names_spec\""`
5930 set dummy $deplib_matches; shift
5931 deplib_match=$1
5932 if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0 ; then
5933- newdeplibs="$newdeplibs $i"
5934+ func_append newdeplibs " $i"
5935 else
5936 droppeddeps=yes
5937 echo
5938@@ -6789,7 +7708,7 @@ EOF
5939 fi
5940 ;;
5941 *)
5942- newdeplibs="$newdeplibs $i"
5943+ func_append newdeplibs " $i"
5944 ;;
5945 esac
5946 done
5947@@ -6807,18 +7726,18 @@ EOF
5948 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
5949 case " $predeps $postdeps " in
5950 *" $i "*)
5951- newdeplibs="$newdeplibs $i"
5952+ func_append newdeplibs " $i"
5953 i=""
5954 ;;
5955 esac
5956 fi
5957 if test -n "$i" ; then
5958- eval "libname=\"$libname_spec\""
5959- eval "deplib_matches=\"$library_names_spec\""
5960+ libname=`eval "\\$ECHO \"$libname_spec\""`
5961+ deplib_matches=`eval "\\$ECHO \"$library_names_spec\""`
5962 set dummy $deplib_matches; shift
5963 deplib_match=$1
5964 if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0 ; then
5965- newdeplibs="$newdeplibs $i"
5966+ func_append newdeplibs " $i"
5967 else
5968 droppeddeps=yes
5969 echo
5970@@ -6840,7 +7759,7 @@ EOF
5971 fi
5972 ;;
5973 *)
5974- newdeplibs="$newdeplibs $i"
5975+ func_append newdeplibs " $i"
5976 ;;
5977 esac
5978 done
5979@@ -6857,15 +7776,27 @@ EOF
5980 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
5981 case " $predeps $postdeps " in
5982 *" $a_deplib "*)
5983- newdeplibs="$newdeplibs $a_deplib"
5984+ func_append newdeplibs " $a_deplib"
5985 a_deplib=""
5986 ;;
5987 esac
5988 fi
5989 if test -n "$a_deplib" ; then
5990- eval "libname=\"$libname_spec\""
5991+ libname=`eval "\\$ECHO \"$libname_spec\""`
5992+ if test -n "$file_magic_glob"; then
5993+ libnameglob=`func_echo_all "$libname" | $SED -e $file_magic_glob`
5994+ else
5995+ libnameglob=$libname
5996+ fi
5997+ test "$want_nocaseglob" = yes && nocaseglob=`shopt -p nocaseglob`
5998 for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do
5999- potential_libs=`ls $i/$libname[.-]* 2>/dev/null`
6000+ if test "$want_nocaseglob" = yes; then
6001+ shopt -s nocaseglob
6002+ potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null`
6003+ $nocaseglob
6004+ else
6005+ potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null`
6006+ fi
6007 for potent_lib in $potential_libs; do
6008 # Follow soft links.
6009 if ls -lLd "$potent_lib" 2>/dev/null |
6010@@ -6885,10 +7816,10 @@ EOF
6011 *) potlib=`$ECHO "$potlib" | $SED 's,[^/]*$,,'`"$potliblink";;
6012 esac
6013 done
6014- if eval "$file_magic_cmd \"\$potlib\"" 2>/dev/null |
6015+ if eval $file_magic_cmd \"\$potlib\" 2>/dev/null |
6016 $SED -e 10q |
6017 $EGREP "$file_magic_regex" > /dev/null; then
6018- newdeplibs="$newdeplibs $a_deplib"
6019+ func_append newdeplibs " $a_deplib"
6020 a_deplib=""
6021 break 2
6022 fi
6023@@ -6913,7 +7844,7 @@ EOF
6024 ;;
6025 *)
6026 # Add a -L argument.
6027- newdeplibs="$newdeplibs $a_deplib"
6028+ func_append newdeplibs " $a_deplib"
6029 ;;
6030 esac
6031 done # Gone through all deplibs.
6032@@ -6929,20 +7860,20 @@ EOF
6033 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
6034 case " $predeps $postdeps " in
6035 *" $a_deplib "*)
6036- newdeplibs="$newdeplibs $a_deplib"
6037+ func_append newdeplibs " $a_deplib"
6038 a_deplib=""
6039 ;;
6040 esac
6041 fi
6042 if test -n "$a_deplib" ; then
6043- eval "libname=\"$libname_spec\""
6044+ libname=`eval "\\$ECHO \"$libname_spec\""`
6045 for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do
6046 potential_libs=`ls $i/$libname[.-]* 2>/dev/null`
6047 for potent_lib in $potential_libs; do
6048 potlib="$potent_lib" # see symlink-check above in file_magic test
6049 if eval "\$ECHO \"$potent_lib\"" 2>/dev/null | $SED 10q | \
6050 $EGREP "$match_pattern_regex" > /dev/null; then
6051- newdeplibs="$newdeplibs $a_deplib"
6052+ func_append newdeplibs " $a_deplib"
6053 a_deplib=""
6054 break 2
6055 fi
6056@@ -6967,7 +7898,7 @@ EOF
6057 ;;
6058 *)
6059 # Add a -L argument.
6060- newdeplibs="$newdeplibs $a_deplib"
6061+ func_append newdeplibs " $a_deplib"
6062 ;;
6063 esac
6064 done # Gone through all deplibs.
6065@@ -7071,7 +8002,7 @@ EOF
6066 *)
6067 case " $deplibs " in
6068 *" -L$path/$objdir "*)
6069- new_libs="$new_libs -L$path/$objdir" ;;
6070+ func_append new_libs " -L$path/$objdir" ;;
6071 esac
6072 ;;
6073 esac
6074@@ -7081,10 +8012,10 @@ EOF
6075 -L*)
6076 case " $new_libs " in
6077 *" $deplib "*) ;;
6078- *) new_libs="$new_libs $deplib" ;;
6079+ *) func_append new_libs " $deplib" ;;
6080 esac
6081 ;;
6082- *) new_libs="$new_libs $deplib" ;;
6083+ *) func_append new_libs " $deplib" ;;
6084 esac
6085 done
6086 deplibs="$new_libs"
6087@@ -7101,10 +8032,12 @@ EOF
6088 hardcode_libdirs=
6089 dep_rpath=
6090 rpath="$finalize_rpath"
6091- test "$mode" != relink && rpath="$compile_rpath$rpath"
6092+ test "$opt_mode" != relink && rpath="$compile_rpath$rpath"
6093 for libdir in $rpath; do
6094 if test -n "$hardcode_libdir_flag_spec"; then
6095 if test -n "$hardcode_libdir_separator"; then
6096+ func_replace_sysroot "$libdir"
6097+ libdir=$func_replace_sysroot_result
6098 if test -z "$hardcode_libdirs"; then
6099 hardcode_libdirs="$libdir"
6100 else
6101@@ -7113,18 +8046,18 @@ EOF
6102 *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*)
6103 ;;
6104 *)
6105- hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir"
6106+ func_append hardcode_libdirs "$hardcode_libdir_separator$libdir"
6107 ;;
6108 esac
6109 fi
6110 else
6111- eval "flag=\"$hardcode_libdir_flag_spec\""
6112- dep_rpath="$dep_rpath $flag"
6113+ eval flag=\"$hardcode_libdir_flag_spec\"
6114+ func_append dep_rpath " $flag"
6115 fi
6116 elif test -n "$runpath_var"; then
6117 case "$perm_rpath " in
6118 *" $libdir "*) ;;
6119- *) perm_rpath="$perm_rpath $libdir" ;;
6120+ *) func_apped perm_rpath " $libdir" ;;
6121 esac
6122 fi
6123 done
6124@@ -7133,40 +8066,38 @@ EOF
6125 test -n "$hardcode_libdirs"; then
6126 libdir="$hardcode_libdirs"
6127 if test -n "$hardcode_libdir_flag_spec_ld"; then
6128- eval "dep_rpath=\"$hardcode_libdir_flag_spec_ld\""
6129+ eval dep_rpath=\"$hardcode_libdir_flag_spec_ld\"
6130 else
6131- eval "dep_rpath=\"$hardcode_libdir_flag_spec\""
6132+ eval dep_rpath=\"$hardcode_libdir_flag_spec\"
6133 fi
6134 fi
6135 if test -n "$runpath_var" && test -n "$perm_rpath"; then
6136 # We should set the runpath_var.
6137 rpath=
6138 for dir in $perm_rpath; do
6139- rpath="$rpath$dir:"
6140+ func_append rpath "$dir:"
6141 done
6142- eval $runpath_var=\$rpath\$$runpath_var
6143- export $runpath_var
6144+ eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var"
6145 fi
6146 test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs"
6147 fi
6148
6149 shlibpath="$finalize_shlibpath"
6150- test "$mode" != relink && shlibpath="$compile_shlibpath$shlibpath"
6151+ test "$opt_mode" != relink && shlibpath="$compile_shlibpath$shlibpath"
6152 if test -n "$shlibpath"; then
6153- eval $shlibpath_var=\$shlibpath\$$shlibpath_var
6154- export $shlibpath_var
6155+ eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var"
6156 fi
6157
6158 # Get the real and link names of the library.
6159- eval "shared_ext=\"$shrext_cmds\""
6160- eval "library_names=\"$library_names_spec\""
6161+ eval shared_ext=\"$shrext_cmds\"
6162+ eval library_names=\"$library_names_spec\"
6163 set dummy $library_names
6164 shift
6165 realname="$1"
6166 shift
6167
6168 if test -n "$soname_spec"; then
6169- eval "soname=\"$soname_spec\""
6170+ eval soname=\"$soname_spec\"
6171 else
6172 soname="$realname"
6173 fi
6174@@ -7178,7 +8109,7 @@ EOF
6175 linknames=
6176 for link
6177 do
6178- linknames="$linknames $link"
6179+ func_append linknames " $link"
6180 done
6181
6182 # Use standard objects if they are pic
6183@@ -7189,7 +8120,7 @@ EOF
6184 if test -n "$export_symbols" && test -n "$include_expsyms"; then
6185 $opt_dry_run || cp "$export_symbols" "$output_objdir/$libname.uexp"
6186 export_symbols="$output_objdir/$libname.uexp"
6187- delfiles="$delfiles $export_symbols"
6188+ func_append delfiles " $export_symbols"
6189 fi
6190
6191 orig_export_symbols=
6192@@ -7220,13 +8151,45 @@ EOF
6193 $opt_dry_run || $RM $export_symbols
6194 cmds=$export_symbols_cmds
6195 save_ifs="$IFS"; IFS='~'
6196- for cmd in $cmds; do
6197+ for cmd1 in $cmds; do
6198 IFS="$save_ifs"
6199- eval "cmd=\"$cmd\""
6200- func_len " $cmd"
6201- len=$func_len_result
6202- if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then
6203+ # Take the normal branch if the nm_file_list_spec branch
6204+ # doesn't work or if tool conversion is not needed.
6205+ case $nm_file_list_spec~$to_tool_file_cmd in
6206+ *~func_convert_file_noop | *~func_convert_file_msys_to_w32 | ~*)
6207+ try_normal_branch=yes
6208+ eval cmd=\"$cmd1\"
6209+ func_len " $cmd"
6210+ len=$func_len_result
6211+ ;;
6212+ *)
6213+ try_normal_branch=no
6214+ ;;
6215+ esac
6216+ if test "$try_normal_branch" = yes \
6217+ && { test "$len" -lt "$max_cmd_len" \
6218+ || test "$max_cmd_len" -le -1; }
6219+ then
6220+ func_show_eval "$cmd" 'exit $?'
6221+ skipped_export=false
6222+ elif test -n "$nm_file_list_spec"; then
6223+ func_basename "$output"
6224+ output_la=$func_basename_result
6225+ save_libobjs=$libobjs
6226+ save_output=$output
6227+ output=${output_objdir}/${output_la}.nm
6228+ func_to_tool_file "$output"
6229+ libobjs=$nm_file_list_spec$func_to_tool_file_result
6230+ func_append delfiles " $output"
6231+ func_verbose "creating $NM input file list: $output"
6232+ for obj in $save_libobjs; do
6233+ func_to_tool_file "$obj"
6234+ $ECHO "$func_to_tool_file_result"
6235+ done > "$output"
6236+ eval cmd=\"$cmd1\"
6237 func_show_eval "$cmd" 'exit $?'
6238+ output=$save_output
6239+ libobjs=$save_libobjs
6240 skipped_export=false
6241 else
6242 # The command line is too long to execute in one step.
6243@@ -7248,7 +8211,7 @@ EOF
6244 if test -n "$export_symbols" && test -n "$include_expsyms"; then
6245 tmp_export_symbols="$export_symbols"
6246 test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols"
6247- $opt_dry_run || $ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"
6248+ $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"'
6249 fi
6250
6251 if test "X$skipped_export" != "X:" && test -n "$orig_export_symbols"; then
6252@@ -7260,7 +8223,7 @@ EOF
6253 # global variables. join(1) would be nice here, but unfortunately
6254 # isn't a blessed tool.
6255 $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter
6256- delfiles="$delfiles $export_symbols $output_objdir/$libname.filter"
6257+ func_append delfiles " $export_symbols $output_objdir/$libname.filter"
6258 export_symbols=$output_objdir/$libname.def
6259 $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols
6260 fi
6261@@ -7270,7 +8233,7 @@ EOF
6262 case " $convenience " in
6263 *" $test_deplib "*) ;;
6264 *)
6265- tmp_deplibs="$tmp_deplibs $test_deplib"
6266+ func_append tmp_deplibs " $test_deplib"
6267 ;;
6268 esac
6269 done
6270@@ -7286,43 +8249,43 @@ EOF
6271 fi
6272 if test -n "$whole_archive_flag_spec"; then
6273 save_libobjs=$libobjs
6274- eval "libobjs=\"\$libobjs $whole_archive_flag_spec\""
6275+ eval libobjs=\"\$libobjs $whole_archive_flag_spec\"
6276 test "X$libobjs" = "X " && libobjs=
6277 else
6278 gentop="$output_objdir/${outputname}x"
6279- generated="$generated $gentop"
6280+ func_append generated " $gentop"
6281
6282 func_extract_archives $gentop $convenience
6283- libobjs="$libobjs $func_extract_archives_result"
6284+ func_append libobjs " $func_extract_archives_result"
6285 test "X$libobjs" = "X " && libobjs=
6286 fi
6287 fi
6288
6289 if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then
6290- eval "flag=\"$thread_safe_flag_spec\""
6291- linker_flags="$linker_flags $flag"
6292+ eval flag=\"$thread_safe_flag_spec\"
6293+ func_append linker_flags " $flag"
6294 fi
6295
6296 # Make a backup of the uninstalled library when relinking
6297- if test "$mode" = relink; then
6298- $opt_dry_run || (cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U) || exit $?
6299+ if test "$opt_mode" = relink; then
6300+ $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $?
6301 fi
6302
6303 # Do each of the archive commands.
6304 if test "$module" = yes && test -n "$module_cmds" ; then
6305 if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then
6306- eval "test_cmds=\"$module_expsym_cmds\""
6307+ eval test_cmds=\"$module_expsym_cmds\"
6308 cmds=$module_expsym_cmds
6309 else
6310- eval "test_cmds=\"$module_cmds\""
6311+ eval test_cmds=\"$module_cmds\"
6312 cmds=$module_cmds
6313 fi
6314 else
6315 if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then
6316- eval "test_cmds=\"$archive_expsym_cmds\""
6317+ eval test_cmds=\"$archive_expsym_cmds\"
6318 cmds=$archive_expsym_cmds
6319 else
6320- eval "test_cmds=\"$archive_cmds\""
6321+ eval test_cmds=\"$archive_cmds\"
6322 cmds=$archive_cmds
6323 fi
6324 fi
6325@@ -7366,10 +8329,13 @@ EOF
6326 echo 'INPUT (' > $output
6327 for obj in $save_libobjs
6328 do
6329- $ECHO "$obj" >> $output
6330+ func_to_tool_file "$obj"
6331+ $ECHO "$func_to_tool_file_result" >> $output
6332 done
6333 echo ')' >> $output
6334- delfiles="$delfiles $output"
6335+ func_append delfiles " $output"
6336+ func_to_tool_file "$output"
6337+ output=$func_to_tool_file_result
6338 elif test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "X$file_list_spec" != X; then
6339 output=${output_objdir}/${output_la}.lnk
6340 func_verbose "creating linker input file list: $output"
6341@@ -7383,15 +8349,17 @@ EOF
6342 fi
6343 for obj
6344 do
6345- $ECHO "$obj" >> $output
6346+ func_to_tool_file "$obj"
6347+ $ECHO "$func_to_tool_file_result" >> $output
6348 done
6349- delfiles="$delfiles $output"
6350- output=$firstobj\"$file_list_spec$output\"
6351+ func_append delfiles " $output"
6352+ func_to_tool_file "$output"
6353+ output=$firstobj\"$file_list_spec$func_to_tool_file_result\"
6354 else
6355 if test -n "$save_libobjs"; then
6356 func_verbose "creating reloadable object files..."
6357 output=$output_objdir/$output_la-${k}.$objext
6358- eval "test_cmds=\"$reload_cmds\""
6359+ eval test_cmds=\"$reload_cmds\"
6360 func_len " $test_cmds"
6361 len0=$func_len_result
6362 len=$len0
6363@@ -7411,12 +8379,12 @@ EOF
6364 if test "$k" -eq 1 ; then
6365 # The first file doesn't have a previous command to add.
6366 reload_objs=$objlist
6367- eval "concat_cmds=\"$reload_cmds\""
6368+ eval concat_cmds=\"$reload_cmds\"
6369 else
6370 # All subsequent reloadable object files will link in
6371 # the last one created.
6372 reload_objs="$objlist $last_robj"
6373- eval "concat_cmds=\"\$concat_cmds~$reload_cmds~\$RM $last_robj\""
6374+ eval concat_cmds=\"\$concat_cmds~$reload_cmds~\$RM $last_robj\"
6375 fi
6376 last_robj=$output_objdir/$output_la-${k}.$objext
6377 func_arith $k + 1
6378@@ -7433,11 +8401,11 @@ EOF
6379 # files will link in the last one created.
6380 test -z "$concat_cmds" || concat_cmds=$concat_cmds~
6381 reload_objs="$objlist $last_robj"
6382- eval "concat_cmds=\"\${concat_cmds}$reload_cmds\""
6383+ eval concat_cmds=\"\${concat_cmds}$reload_cmds\"
6384 if test -n "$last_robj"; then
6385- eval "concat_cmds=\"\${concat_cmds}~\$RM $last_robj\""
6386+ eval concat_cmds=\"\${concat_cmds}~\$RM $last_robj\"
6387 fi
6388- delfiles="$delfiles $output"
6389+ func_append delfiles " $output"
6390
6391 else
6392 output=
6393@@ -7450,9 +8418,9 @@ EOF
6394 libobjs=$output
6395 # Append the command to create the export file.
6396 test -z "$concat_cmds" || concat_cmds=$concat_cmds~
6397- eval "concat_cmds=\"\$concat_cmds$export_symbols_cmds\""
6398+ eval concat_cmds=\"\$concat_cmds$export_symbols_cmds\"
6399 if test -n "$last_robj"; then
6400- eval "concat_cmds=\"\$concat_cmds~\$RM $last_robj\""
6401+ eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\"
6402 fi
6403 fi
6404
6405@@ -7471,7 +8439,7 @@ EOF
6406 lt_exit=$?
6407
6408 # Restore the uninstalled library and exit
6409- if test "$mode" = relink; then
6410+ if test "$opt_mode" = relink; then
6411 ( cd "$output_objdir" && \
6412 $RM "${realname}T" && \
6413 $MV "${realname}U" "$realname" )
6414@@ -7492,7 +8460,7 @@ EOF
6415 if test -n "$export_symbols" && test -n "$include_expsyms"; then
6416 tmp_export_symbols="$export_symbols"
6417 test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols"
6418- $opt_dry_run || $ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"
6419+ $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"'
6420 fi
6421
6422 if test -n "$orig_export_symbols"; then
6423@@ -7504,7 +8472,7 @@ EOF
6424 # global variables. join(1) would be nice here, but unfortunately
6425 # isn't a blessed tool.
6426 $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter
6427- delfiles="$delfiles $export_symbols $output_objdir/$libname.filter"
6428+ func_append delfiles " $export_symbols $output_objdir/$libname.filter"
6429 export_symbols=$output_objdir/$libname.def
6430 $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols
6431 fi
6432@@ -7515,7 +8483,7 @@ EOF
6433 output=$save_output
6434
6435 if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then
6436- eval "libobjs=\"\$libobjs $whole_archive_flag_spec\""
6437+ eval libobjs=\"\$libobjs $whole_archive_flag_spec\"
6438 test "X$libobjs" = "X " && libobjs=
6439 fi
6440 # Expand the library linking commands again to reset the
6441@@ -7539,23 +8507,23 @@ EOF
6442
6443 if test -n "$delfiles"; then
6444 # Append the command to remove temporary files to $cmds.
6445- eval "cmds=\"\$cmds~\$RM $delfiles\""
6446+ eval cmds=\"\$cmds~\$RM $delfiles\"
6447 fi
6448
6449 # Add any objects from preloaded convenience libraries
6450 if test -n "$dlprefiles"; then
6451 gentop="$output_objdir/${outputname}x"
6452- generated="$generated $gentop"
6453+ func_append generated " $gentop"
6454
6455 func_extract_archives $gentop $dlprefiles
6456- libobjs="$libobjs $func_extract_archives_result"
6457+ func_append libobjs " $func_extract_archives_result"
6458 test "X$libobjs" = "X " && libobjs=
6459 fi
6460
6461 save_ifs="$IFS"; IFS='~'
6462 for cmd in $cmds; do
6463 IFS="$save_ifs"
6464- eval "cmd=\"$cmd\""
6465+ eval cmd=\"$cmd\"
6466 $opt_silent || {
6467 func_quote_for_expand "$cmd"
6468 eval "func_echo $func_quote_for_expand_result"
6469@@ -7564,7 +8532,7 @@ EOF
6470 lt_exit=$?
6471
6472 # Restore the uninstalled library and exit
6473- if test "$mode" = relink; then
6474+ if test "$opt_mode" = relink; then
6475 ( cd "$output_objdir" && \
6476 $RM "${realname}T" && \
6477 $MV "${realname}U" "$realname" )
6478@@ -7576,8 +8544,8 @@ EOF
6479 IFS="$save_ifs"
6480
6481 # Restore the uninstalled library and exit
6482- if test "$mode" = relink; then
6483- $opt_dry_run || (cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname) || exit $?
6484+ if test "$opt_mode" = relink; then
6485+ $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname)' || exit $?
6486
6487 if test -n "$convenience"; then
6488 if test -z "$whole_archive_flag_spec"; then
6489@@ -7656,17 +8624,20 @@ EOF
6490
6491 if test -n "$convenience"; then
6492 if test -n "$whole_archive_flag_spec"; then
6493- eval "tmp_whole_archive_flags=\"$whole_archive_flag_spec\""
6494+ eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\"
6495 reload_conv_objs=$reload_objs\ `$ECHO "$tmp_whole_archive_flags" | $SED 's|,| |g'`
6496 else
6497 gentop="$output_objdir/${obj}x"
6498- generated="$generated $gentop"
6499+ func_append generated " $gentop"
6500
6501 func_extract_archives $gentop $convenience
6502 reload_conv_objs="$reload_objs $func_extract_archives_result"
6503 fi
6504 fi
6505
6506+ # If we're not building shared, we need to use non_pic_objs
6507+ test "$build_libtool_libs" != yes && libobjs="$non_pic_objects"
6508+
6509 # Create the old-style object.
6510 reload_objs="$objs$old_deplibs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; /\.lib$/d; $lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test
6511
6512@@ -7690,7 +8661,7 @@ EOF
6513 # Create an invalid libtool object if no PIC, so that we don't
6514 # accidentally link it into a program.
6515 # $show "echo timestamp > $libobj"
6516- # $opt_dry_run || echo timestamp > $libobj || exit $?
6517+ # $opt_dry_run || eval "echo timestamp > $libobj" || exit $?
6518 exit $EXIT_SUCCESS
6519 fi
6520
6521@@ -7740,8 +8711,8 @@ EOF
6522 if test "$tagname" = CXX ; then
6523 case ${MACOSX_DEPLOYMENT_TARGET-10.0} in
6524 10.[0123])
6525- compile_command="$compile_command ${wl}-bind_at_load"
6526- finalize_command="$finalize_command ${wl}-bind_at_load"
6527+ func_append compile_command " ${wl}-bind_at_load"
6528+ func_append finalize_command " ${wl}-bind_at_load"
6529 ;;
6530 esac
6531 fi
6532@@ -7761,7 +8732,7 @@ EOF
6533 *)
6534 case " $compile_deplibs " in
6535 *" -L$path/$objdir "*)
6536- new_libs="$new_libs -L$path/$objdir" ;;
6537+ func_append new_libs " -L$path/$objdir" ;;
6538 esac
6539 ;;
6540 esac
6541@@ -7771,17 +8742,17 @@ EOF
6542 -L*)
6543 case " $new_libs " in
6544 *" $deplib "*) ;;
6545- *) new_libs="$new_libs $deplib" ;;
6546+ *) func_append new_libs " $deplib" ;;
6547 esac
6548 ;;
6549- *) new_libs="$new_libs $deplib" ;;
6550+ *) func_append new_libs " $deplib" ;;
6551 esac
6552 done
6553 compile_deplibs="$new_libs"
6554
6555
6556- compile_command="$compile_command $compile_deplibs"
6557- finalize_command="$finalize_command $finalize_deplibs"
6558+ func_append compile_command " $compile_deplibs"
6559+ func_append finalize_command " $finalize_deplibs"
6560
6561 if test -n "$rpath$xrpath"; then
6562 # If the user specified any rpath flags, then add them.
6563@@ -7789,7 +8760,7 @@ EOF
6564 # This is the magic to use -rpath.
6565 case "$finalize_rpath " in
6566 *" $libdir "*) ;;
6567- *) finalize_rpath="$finalize_rpath $libdir" ;;
6568+ *) func_append finalize_rpath " $libdir" ;;
6569 esac
6570 done
6571 fi
6572@@ -7808,18 +8779,18 @@ EOF
6573 *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*)
6574 ;;
6575 *)
6576- hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir"
6577+ func_append hardcode_libdirs "$hardcode_libdir_separator$libdir"
6578 ;;
6579 esac
6580 fi
6581 else
6582- eval "flag=\"$hardcode_libdir_flag_spec\""
6583- rpath="$rpath $flag"
6584+ eval flag=\"$hardcode_libdir_flag_spec\"
6585+ func_append rpath " $flag"
6586 fi
6587 elif test -n "$runpath_var"; then
6588 case "$perm_rpath " in
6589 *" $libdir "*) ;;
6590- *) perm_rpath="$perm_rpath $libdir" ;;
6591+ *) func_append perm_rpath " $libdir" ;;
6592 esac
6593 fi
6594 case $host in
6595@@ -7828,12 +8799,12 @@ EOF
6596 case :$dllsearchpath: in
6597 *":$libdir:"*) ;;
6598 ::) dllsearchpath=$libdir;;
6599- *) dllsearchpath="$dllsearchpath:$libdir";;
6600+ *) func_append dllsearchpath ":$libdir";;
6601 esac
6602 case :$dllsearchpath: in
6603 *":$testbindir:"*) ;;
6604 ::) dllsearchpath=$testbindir;;
6605- *) dllsearchpath="$dllsearchpath:$testbindir";;
6606+ *) func_append dllsearchpath ":$testbindir";;
6607 esac
6608 ;;
6609 esac
6610@@ -7842,7 +8813,7 @@ EOF
6611 if test -n "$hardcode_libdir_separator" &&
6612 test -n "$hardcode_libdirs"; then
6613 libdir="$hardcode_libdirs"
6614- eval "rpath=\" $hardcode_libdir_flag_spec\""
6615+ eval rpath=\" $hardcode_libdir_flag_spec\"
6616 fi
6617 compile_rpath="$rpath"
6618
6619@@ -7859,18 +8830,18 @@ EOF
6620 *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*)
6621 ;;
6622 *)
6623- hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir"
6624+ func_append hardcode_libdirs "$hardcode_libdir_separator$libdir"
6625 ;;
6626 esac
6627 fi
6628 else
6629- eval "flag=\"$hardcode_libdir_flag_spec\""
6630- rpath="$rpath $flag"
6631+ eval flag=\"$hardcode_libdir_flag_spec\"
6632+ func_append rpath " $flag"
6633 fi
6634 elif test -n "$runpath_var"; then
6635 case "$finalize_perm_rpath " in
6636 *" $libdir "*) ;;
6637- *) finalize_perm_rpath="$finalize_perm_rpath $libdir" ;;
6638+ *) func_append finalize_perm_rpath " $libdir" ;;
6639 esac
6640 fi
6641 done
6642@@ -7878,7 +8849,7 @@ EOF
6643 if test -n "$hardcode_libdir_separator" &&
6644 test -n "$hardcode_libdirs"; then
6645 libdir="$hardcode_libdirs"
6646- eval "rpath=\" $hardcode_libdir_flag_spec\""
6647+ eval rpath=\" $hardcode_libdir_flag_spec\"
6648 fi
6649 finalize_rpath="$rpath"
6650
6651@@ -7921,6 +8892,12 @@ EOF
6652 exit_status=0
6653 func_show_eval "$link_command" 'exit_status=$?'
6654
6655+ if test -n "$postlink_cmds"; then
6656+ func_to_tool_file "$output"
6657+ postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'`
6658+ func_execute_cmds "$postlink_cmds" 'exit $?'
6659+ fi
6660+
6661 # Delete the generated files.
6662 if test -f "$output_objdir/${outputname}S.${objext}"; then
6663 func_show_eval '$RM "$output_objdir/${outputname}S.${objext}"'
6664@@ -7943,7 +8920,7 @@ EOF
6665 # We should set the runpath_var.
6666 rpath=
6667 for dir in $perm_rpath; do
6668- rpath="$rpath$dir:"
6669+ func_append rpath "$dir:"
6670 done
6671 compile_var="$runpath_var=\"$rpath\$$runpath_var\" "
6672 fi
6673@@ -7951,7 +8928,7 @@ EOF
6674 # We should set the runpath_var.
6675 rpath=
6676 for dir in $finalize_perm_rpath; do
6677- rpath="$rpath$dir:"
6678+ func_append rpath "$dir:"
6679 done
6680 finalize_var="$runpath_var=\"$rpath\$$runpath_var\" "
6681 fi
6682@@ -7966,6 +8943,13 @@ EOF
6683 $opt_dry_run || $RM $output
6684 # Link the executable and exit
6685 func_show_eval "$link_command" 'exit $?'
6686+
6687+ if test -n "$postlink_cmds"; then
6688+ func_to_tool_file "$output"
6689+ postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'`
6690+ func_execute_cmds "$postlink_cmds" 'exit $?'
6691+ fi
6692+
6693 exit $EXIT_SUCCESS
6694 fi
6695
6696@@ -7999,6 +8983,12 @@ EOF
6697
6698 func_show_eval "$link_command" 'exit $?'
6699
6700+ if test -n "$postlink_cmds"; then
6701+ func_to_tool_file "$output_objdir/$outputname"
6702+ postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'`
6703+ func_execute_cmds "$postlink_cmds" 'exit $?'
6704+ fi
6705+
6706 # Now create the wrapper script.
6707 func_verbose "creating $output"
6708
6709@@ -8096,7 +9086,7 @@ EOF
6710 else
6711 oldobjs="$old_deplibs $non_pic_objects"
6712 if test "$preload" = yes && test -f "$symfileobj"; then
6713- oldobjs="$oldobjs $symfileobj"
6714+ func_append oldobjs " $symfileobj"
6715 fi
6716 fi
6717 addlibs="$old_convenience"
6718@@ -8104,10 +9094,10 @@ EOF
6719
6720 if test -n "$addlibs"; then
6721 gentop="$output_objdir/${outputname}x"
6722- generated="$generated $gentop"
6723+ func_append generated " $gentop"
6724
6725 func_extract_archives $gentop $addlibs
6726- oldobjs="$oldobjs $func_extract_archives_result"
6727+ func_append oldobjs " $func_extract_archives_result"
6728 fi
6729
6730 # Do each command in the archive commands.
6731@@ -8118,10 +9108,10 @@ EOF
6732 # Add any objects from preloaded convenience libraries
6733 if test -n "$dlprefiles"; then
6734 gentop="$output_objdir/${outputname}x"
6735- generated="$generated $gentop"
6736+ func_append generated " $gentop"
6737
6738 func_extract_archives $gentop $dlprefiles
6739- oldobjs="$oldobjs $func_extract_archives_result"
6740+ func_append oldobjs " $func_extract_archives_result"
6741 fi
6742
6743 # POSIX demands no paths to be encoded in archives. We have
6744@@ -8139,7 +9129,7 @@ EOF
6745 else
6746 echo "copying selected object files to avoid basename conflicts..."
6747 gentop="$output_objdir/${outputname}x"
6748- generated="$generated $gentop"
6749+ func_append generated " $gentop"
6750 func_mkdir_p "$gentop"
6751 save_oldobjs=$oldobjs
6752 oldobjs=
6753@@ -8163,18 +9153,28 @@ EOF
6754 esac
6755 done
6756 func_show_eval "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj"
6757- oldobjs="$oldobjs $gentop/$newobj"
6758+ func_append oldobjs " $gentop/$newobj"
6759 ;;
6760- *) oldobjs="$oldobjs $obj" ;;
6761+ *) func_append oldobjs " $obj" ;;
6762 esac
6763 done
6764 fi
6765- eval "cmds=\"$old_archive_cmds\""
6766+ eval cmds=\"$old_archive_cmds\"
6767
6768 func_len " $cmds"
6769 len=$func_len_result
6770 if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then
6771 cmds=$old_archive_cmds
6772+ elif test -n "$archiver_list_spec"; then
6773+ func_verbose "using command file archive linking..."
6774+ for obj in $oldobjs
6775+ do
6776+ func_to_tool_file "$obj"
6777+ $ECHO "$func_to_tool_file_result"
6778+ done > $output_objdir/$libname.libcmd
6779+ func_to_tool_file "$output_objdir/$libname.libcmd"
6780+ oldobjs=" $archiver_list_spec$func_to_tool_file_result"
6781+ cmds=$old_archive_cmds
6782 else
6783 # the command line is too long to link in one step, link in parts
6784 func_verbose "using piecewise archive linking..."
6785@@ -8189,7 +9189,7 @@ EOF
6786 do
6787 last_oldobj=$obj
6788 done
6789- eval "test_cmds=\"$old_archive_cmds\""
6790+ eval test_cmds=\"$old_archive_cmds\"
6791 func_len " $test_cmds"
6792 len0=$func_len_result
6793 len=$len0
6794@@ -8208,7 +9208,7 @@ EOF
6795 RANLIB=$save_RANLIB
6796 fi
6797 test -z "$concat_cmds" || concat_cmds=$concat_cmds~
6798- eval "concat_cmds=\"\${concat_cmds}$old_archive_cmds\""
6799+ eval concat_cmds=\"\${concat_cmds}$old_archive_cmds\"
6800 objlist=
6801 len=$len0
6802 fi
6803@@ -8216,9 +9216,9 @@ EOF
6804 RANLIB=$save_RANLIB
6805 oldobjs=$objlist
6806 if test "X$oldobjs" = "X" ; then
6807- eval "cmds=\"\$concat_cmds\""
6808+ eval cmds=\"\$concat_cmds\"
6809 else
6810- eval "cmds=\"\$concat_cmds~\$old_archive_cmds\""
6811+ eval cmds=\"\$concat_cmds~\$old_archive_cmds\"
6812 fi
6813 fi
6814 fi
6815@@ -8268,12 +9268,23 @@ EOF
6816 *.la)
6817 func_basename "$deplib"
6818 name="$func_basename_result"
6819- libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib`
6820+ func_resolve_sysroot "$deplib"
6821+ eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $func_resolve_sysroot_result`
6822 test -z "$libdir" && \
6823 func_fatal_error "\`$deplib' is not a valid libtool archive"
6824- newdependency_libs="$newdependency_libs $libdir/$name"
6825+ func_append newdependency_libs " ${lt_sysroot:+=}$libdir/$name"
6826+ ;;
6827+ -L*)
6828+ func_stripname -L '' "$deplib"
6829+ func_replace_sysroot "$func_stripname_result"
6830+ func_append newdependency_libs " -L$func_replace_sysroot_result"
6831 ;;
6832- *) newdependency_libs="$newdependency_libs $deplib" ;;
6833+ -R*)
6834+ func_stripname -R '' "$deplib"
6835+ func_replace_sysroot "$func_stripname_result"
6836+ func_append newdependency_libs " -R$func_replace_sysroot_result"
6837+ ;;
6838+ *) func_append newdependency_libs " $deplib" ;;
6839 esac
6840 done
6841 dependency_libs="$newdependency_libs"
6842@@ -8284,12 +9295,14 @@ EOF
6843 *.la)
6844 func_basename "$lib"
6845 name="$func_basename_result"
6846- libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib`
6847+ func_resolve_sysroot "$lib"
6848+ eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $func_resolve_sysroot_result`
6849+
6850 test -z "$libdir" && \
6851 func_fatal_error "\`$lib' is not a valid libtool archive"
6852- newdlfiles="$newdlfiles $libdir/$name"
6853+ func_append newdlfiles " ${lt_sysroot:+=}$libdir/$name"
6854 ;;
6855- *) newdlfiles="$newdlfiles $lib" ;;
6856+ *) func_append newdlfiles " $lib" ;;
6857 esac
6858 done
6859 dlfiles="$newdlfiles"
6860@@ -8303,10 +9316,11 @@ EOF
6861 # the library:
6862 func_basename "$lib"
6863 name="$func_basename_result"
6864- libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib`
6865+ func_resolve_sysroot "$lib"
6866+ eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $func_resolve_sysroot_result`
6867 test -z "$libdir" && \
6868 func_fatal_error "\`$lib' is not a valid libtool archive"
6869- newdlprefiles="$newdlprefiles $libdir/$name"
6870+ func_append newdlprefiles " ${lt_sysroot:+=}$libdir/$name"
6871 ;;
6872 esac
6873 done
6874@@ -8318,7 +9332,7 @@ EOF
6875 [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;;
6876 *) abs=`pwd`"/$lib" ;;
6877 esac
6878- newdlfiles="$newdlfiles $abs"
6879+ func_append newdlfiles " $abs"
6880 done
6881 dlfiles="$newdlfiles"
6882 newdlprefiles=
6883@@ -8327,7 +9341,7 @@ EOF
6884 [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;;
6885 *) abs=`pwd`"/$lib" ;;
6886 esac
6887- newdlprefiles="$newdlprefiles $abs"
6888+ func_append newdlprefiles " $abs"
6889 done
6890 dlprefiles="$newdlprefiles"
6891 fi
6892@@ -8412,7 +9426,7 @@ relink_command=\"$relink_command\""
6893 exit $EXIT_SUCCESS
6894 }
6895
6896-{ test "$mode" = link || test "$mode" = relink; } &&
6897+{ test "$opt_mode" = link || test "$opt_mode" = relink; } &&
6898 func_mode_link ${1+"$@"}
6899
6900
6901@@ -8432,9 +9446,9 @@ func_mode_uninstall ()
6902 for arg
6903 do
6904 case $arg in
6905- -f) RM="$RM $arg"; rmforce=yes ;;
6906- -*) RM="$RM $arg" ;;
6907- *) files="$files $arg" ;;
6908+ -f) func_append RM " $arg"; rmforce=yes ;;
6909+ -*) func_append RM " $arg" ;;
6910+ *) func_append files " $arg" ;;
6911 esac
6912 done
6913
6914@@ -8443,24 +9457,23 @@ func_mode_uninstall ()
6915
6916 rmdirs=
6917
6918- origobjdir="$objdir"
6919 for file in $files; do
6920 func_dirname "$file" "" "."
6921 dir="$func_dirname_result"
6922 if test "X$dir" = X.; then
6923- objdir="$origobjdir"
6924+ odir="$objdir"
6925 else
6926- objdir="$dir/$origobjdir"
6927+ odir="$dir/$objdir"
6928 fi
6929 func_basename "$file"
6930 name="$func_basename_result"
6931- test "$mode" = uninstall && objdir="$dir"
6932+ test "$opt_mode" = uninstall && odir="$dir"
6933
6934- # Remember objdir for removal later, being careful to avoid duplicates
6935- if test "$mode" = clean; then
6936+ # Remember odir for removal later, being careful to avoid duplicates
6937+ if test "$opt_mode" = clean; then
6938 case " $rmdirs " in
6939- *" $objdir "*) ;;
6940- *) rmdirs="$rmdirs $objdir" ;;
6941+ *" $odir "*) ;;
6942+ *) func_append rmdirs " $odir" ;;
6943 esac
6944 fi
6945
6946@@ -8486,18 +9499,17 @@ func_mode_uninstall ()
6947
6948 # Delete the libtool libraries and symlinks.
6949 for n in $library_names; do
6950- rmfiles="$rmfiles $objdir/$n"
6951+ func_append rmfiles " $odir/$n"
6952 done
6953- test -n "$old_library" && rmfiles="$rmfiles $objdir/$old_library"
6954+ test -n "$old_library" && func_append rmfiles " $odir/$old_library"
6955
6956- case "$mode" in
6957+ case "$opt_mode" in
6958 clean)
6959- case " $library_names " in
6960- # " " in the beginning catches empty $dlname
6961+ case " $library_names " in
6962 *" $dlname "*) ;;
6963- *) rmfiles="$rmfiles $objdir/$dlname" ;;
6964+ *) test -n "$dlname" && func_append rmfiles " $odir/$dlname" ;;
6965 esac
6966- test -n "$libdir" && rmfiles="$rmfiles $objdir/$name $objdir/${name}i"
6967+ test -n "$libdir" && func_append rmfiles " $odir/$name $odir/${name}i"
6968 ;;
6969 uninstall)
6970 if test -n "$library_names"; then
6971@@ -8525,19 +9537,19 @@ func_mode_uninstall ()
6972 # Add PIC object to the list of files to remove.
6973 if test -n "$pic_object" &&
6974 test "$pic_object" != none; then
6975- rmfiles="$rmfiles $dir/$pic_object"
6976+ func_append rmfiles " $dir/$pic_object"
6977 fi
6978
6979 # Add non-PIC object to the list of files to remove.
6980 if test -n "$non_pic_object" &&
6981 test "$non_pic_object" != none; then
6982- rmfiles="$rmfiles $dir/$non_pic_object"
6983+ func_append rmfiles " $dir/$non_pic_object"
6984 fi
6985 fi
6986 ;;
6987
6988 *)
6989- if test "$mode" = clean ; then
6990+ if test "$opt_mode" = clean ; then
6991 noexename=$name
6992 case $file in
6993 *.exe)
6994@@ -8547,7 +9559,7 @@ func_mode_uninstall ()
6995 noexename=$func_stripname_result
6996 # $file with .exe has already been added to rmfiles,
6997 # add $file without .exe
6998- rmfiles="$rmfiles $file"
6999+ func_append rmfiles " $file"
7000 ;;
7001 esac
7002 # Do a test to see if this is a libtool program.
7003@@ -8556,7 +9568,7 @@ func_mode_uninstall ()
7004 func_ltwrapper_scriptname "$file"
7005 relink_command=
7006 func_source $func_ltwrapper_scriptname_result
7007- rmfiles="$rmfiles $func_ltwrapper_scriptname_result"
7008+ func_append rmfiles " $func_ltwrapper_scriptname_result"
7009 else
7010 relink_command=
7011 func_source $dir/$noexename
7012@@ -8564,12 +9576,12 @@ func_mode_uninstall ()
7013
7014 # note $name still contains .exe if it was in $file originally
7015 # as does the version of $file that was added into $rmfiles
7016- rmfiles="$rmfiles $objdir/$name $objdir/${name}S.${objext}"
7017+ func_append rmfiles " $odir/$name $odir/${name}S.${objext}"
7018 if test "$fast_install" = yes && test -n "$relink_command"; then
7019- rmfiles="$rmfiles $objdir/lt-$name"
7020+ func_append rmfiles " $odir/lt-$name"
7021 fi
7022 if test "X$noexename" != "X$name" ; then
7023- rmfiles="$rmfiles $objdir/lt-${noexename}.c"
7024+ func_append rmfiles " $odir/lt-${noexename}.c"
7025 fi
7026 fi
7027 fi
7028@@ -8577,7 +9589,6 @@ func_mode_uninstall ()
7029 esac
7030 func_show_eval "$RM $rmfiles" 'exit_status=1'
7031 done
7032- objdir="$origobjdir"
7033
7034 # Try to remove the ${objdir}s in the directories where we deleted files
7035 for dir in $rmdirs; do
7036@@ -8589,16 +9600,16 @@ func_mode_uninstall ()
7037 exit $exit_status
7038 }
7039
7040-{ test "$mode" = uninstall || test "$mode" = clean; } &&
7041+{ test "$opt_mode" = uninstall || test "$opt_mode" = clean; } &&
7042 func_mode_uninstall ${1+"$@"}
7043
7044-test -z "$mode" && {
7045+test -z "$opt_mode" && {
7046 help="$generic_help"
7047 func_fatal_help "you must specify a MODE"
7048 }
7049
7050 test -z "$exec_cmd" && \
7051- func_fatal_help "invalid operation mode \`$mode'"
7052+ func_fatal_help "invalid operation mode \`$opt_mode'"
7053
7054 if test -n "$exec_cmd"; then
7055 eval exec "$exec_cmd"
7056Index: binutils-2.22/ltoptions.m4
7057===================================================================
7058--- binutils-2.22.orig/ltoptions.m4
7059+++ binutils-2.22/ltoptions.m4
7060@@ -8,7 +8,7 @@
7061 # unlimited permission to copy and/or distribute it, with or without
7062 # modifications, as long as this notice is preserved.
7063
7064-# serial 6 ltoptions.m4
7065+# serial 7 ltoptions.m4
7066
7067 # This is to help aclocal find these macros, as it can't see m4_define.
7068 AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
7069Index: binutils-2.22/ltversion.m4
7070===================================================================
7071--- binutils-2.22.orig/ltversion.m4
7072+++ binutils-2.22/ltversion.m4
7073@@ -7,17 +7,17 @@
7074 # unlimited permission to copy and/or distribute it, with or without
7075 # modifications, as long as this notice is preserved.
7076
7077-# Generated from ltversion.in.
7078+# @configure_input@
7079
7080-# serial 3134 ltversion.m4
7081+# serial 3293 ltversion.m4
7082 # This file is part of GNU Libtool
7083
7084-m4_define([LT_PACKAGE_VERSION], [2.2.7a])
7085-m4_define([LT_PACKAGE_REVISION], [1.3134])
7086+m4_define([LT_PACKAGE_VERSION], [2.4])
7087+m4_define([LT_PACKAGE_REVISION], [1.3293])
7088
7089 AC_DEFUN([LTVERSION_VERSION],
7090-[macro_version='2.2.7a'
7091-macro_revision='1.3134'
7092+[macro_version='2.4'
7093+macro_revision='1.3293'
7094 _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
7095 _LT_DECL(, macro_revision, 0)
7096 ])
7097Index: binutils-2.22/lt~obsolete.m4
7098===================================================================
7099--- binutils-2.22.orig/lt~obsolete.m4
7100+++ binutils-2.22/lt~obsolete.m4
7101@@ -7,7 +7,7 @@
7102 # unlimited permission to copy and/or distribute it, with or without
7103 # modifications, as long as this notice is preserved.
7104
7105-# serial 4 lt~obsolete.m4
7106+# serial 5 lt~obsolete.m4
7107
7108 # These exist entirely to fool aclocal when bootstrapping libtool.
7109 #
7110Index: binutils-2.22/configure
7111===================================================================
7112--- binutils-2.22.orig/configure
7113+++ binutils-2.22/configure
7114@@ -7788,7 +7788,7 @@ case " $build_configdirs " in
7115 # For an installed makeinfo, we require it to be from texinfo 4.7 or
7116 # higher, else we use the "missing" dummy.
7117 if ${MAKEINFO} --version \
7118- | egrep 'texinfo[^0-9]*(4\.([7-9]|[1-9][0-9])|[5-9]|[1-9][0-9])' >/dev/null 2>&1; then
7119+ | egrep 'texinfo[^0-9]*([1-3][0-9]|4.[4-9]|4.[1-9][0-9]+|[5-9])' >/dev/null 2>&1; then
7120 :
7121 else
7122 MAKEINFO="$MISSING makeinfo"
7123Index: binutils-2.22/bfd/configure
7124===================================================================
7125--- binutils-2.22.orig/bfd/configure
7126+++ binutils-2.22/bfd/configure
7127@@ -667,6 +667,9 @@ OTOOL
7128 LIPO
7129 NMEDIT
7130 DSYMUTIL
7131+MANIFEST_TOOL
7132+ac_ct_AR
7133+DLLTOOL
7134 OBJDUMP
7135 LN_S
7136 NM
7137@@ -779,6 +782,7 @@ enable_static
7138 with_pic
7139 enable_fast_install
7140 with_gnu_ld
7141+with_libtool_sysroot
7142 enable_libtool_lock
7143 enable_plugins
7144 enable_largefile
7145@@ -1453,6 +1457,8 @@ Optional Packages:
7146 --with-pic try to use only PIC/non-PIC objects [default=use
7147 both]
7148 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
7149+ --with-libtool-sysroot=DIR Search for dependent libraries within DIR
7150+ (or the compiler's sysroot if not specified).
7151 --with-mmap try using mmap for BFD input files if available
7152 --with-separate-debug-dir=DIR
7153 Look for global separate debug info in DIR
7154@@ -5383,8 +5389,8 @@ esac
7155
7156
7157
7158-macro_version='2.2.7a'
7159-macro_revision='1.3134'
7160+macro_version='2.4'
7161+macro_revision='1.3293'
7162
7163
7164
7165@@ -5424,7 +5430,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
7166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
7167 $as_echo_n "checking how to print strings... " >&6; }
7168 # Test print first, because it will be a builtin if present.
7169-if test "X`print -r -- -n 2>/dev/null`" = X-n && \
7170+if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
7171 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
7172 ECHO='print -r --'
7173 elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
7174@@ -6110,8 +6116,8 @@ $as_echo_n "checking whether the shell u
7175 # Try some XSI features
7176 xsi_shell=no
7177 ( _lt_dummy="a/b/c"
7178- test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
7179- = c,a/b,, \
7180+ test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
7181+ = c,a/b,b/c, \
7182 && eval 'test $(( 1 + 1 )) -eq 2 \
7183 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
7184 && xsi_shell=yes
7185@@ -6160,6 +6166,80 @@ esac
7186
7187
7188
7189+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
7190+$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
7191+if test "${lt_cv_to_host_file_cmd+set}" = set; then :
7192+ $as_echo_n "(cached) " >&6
7193+else
7194+ case $host in
7195+ *-*-mingw* )
7196+ case $build in
7197+ *-*-mingw* ) # actually msys
7198+ lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
7199+ ;;
7200+ *-*-cygwin* )
7201+ lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
7202+ ;;
7203+ * ) # otherwise, assume *nix
7204+ lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
7205+ ;;
7206+ esac
7207+ ;;
7208+ *-*-cygwin* )
7209+ case $build in
7210+ *-*-mingw* ) # actually msys
7211+ lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
7212+ ;;
7213+ *-*-cygwin* )
7214+ lt_cv_to_host_file_cmd=func_convert_file_noop
7215+ ;;
7216+ * ) # otherwise, assume *nix
7217+ lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
7218+ ;;
7219+ esac
7220+ ;;
7221+ * ) # unhandled hosts (and "normal" native builds)
7222+ lt_cv_to_host_file_cmd=func_convert_file_noop
7223+ ;;
7224+esac
7225+
7226+fi
7227+
7228+to_host_file_cmd=$lt_cv_to_host_file_cmd
7229+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
7230+$as_echo "$lt_cv_to_host_file_cmd" >&6; }
7231+
7232+
7233+
7234+
7235+
7236+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
7237+$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
7238+if test "${lt_cv_to_tool_file_cmd+set}" = set; then :
7239+ $as_echo_n "(cached) " >&6
7240+else
7241+ #assume ordinary cross tools, or native build.
7242+lt_cv_to_tool_file_cmd=func_convert_file_noop
7243+case $host in
7244+ *-*-mingw* )
7245+ case $build in
7246+ *-*-mingw* ) # actually msys
7247+ lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
7248+ ;;
7249+ esac
7250+ ;;
7251+esac
7252+
7253+fi
7254+
7255+to_tool_file_cmd=$lt_cv_to_tool_file_cmd
7256+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
7257+$as_echo "$lt_cv_to_tool_file_cmd" >&6; }
7258+
7259+
7260+
7261+
7262+
7263 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
7264 $as_echo_n "checking for $LD option to reload object files... " >&6; }
7265 if test "${lt_cv_ld_reload_flag+set}" = set; then :
7266@@ -6176,6 +6256,11 @@ case $reload_flag in
7267 esac
7268 reload_cmds='$LD$reload_flag -o $output$reload_objs'
7269 case $host_os in
7270+ cygwin* | mingw* | pw32* | cegcc*)
7271+ if test "$GCC" != yes; then
7272+ reload_cmds=false
7273+ fi
7274+ ;;
7275 darwin*)
7276 if test "$GCC" = yes; then
7277 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
7278@@ -6344,7 +6429,8 @@ mingw* | pw32*)
7279 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
7280 lt_cv_file_magic_cmd='func_win32_libid'
7281 else
7282- lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
7283+ # Keep this pattern in sync with the one in func_win32_libid.
7284+ lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
7285 lt_cv_file_magic_cmd='$OBJDUMP -f'
7286 fi
7287 ;;
7288@@ -6498,6 +6584,21 @@ esac
7289 fi
7290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
7291 $as_echo "$lt_cv_deplibs_check_method" >&6; }
7292+
7293+file_magic_glob=
7294+want_nocaseglob=no
7295+if test "$build" = "$host"; then
7296+ case $host_os in
7297+ mingw* | pw32*)
7298+ if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
7299+ want_nocaseglob=yes
7300+ else
7301+ file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
7302+ fi
7303+ ;;
7304+ esac
7305+fi
7306+
7307 file_magic_cmd=$lt_cv_file_magic_cmd
7308 deplibs_check_method=$lt_cv_deplibs_check_method
7309 test -z "$deplibs_check_method" && deplibs_check_method=unknown
7310@@ -6513,9 +6614,162 @@ test -z "$deplibs_check_method" && depli
7311
7312
7313
7314+
7315+
7316+
7317+
7318+
7319+
7320+
7321+
7322+
7323+
7324 if test -n "$ac_tool_prefix"; then
7325- # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
7326-set dummy ${ac_tool_prefix}ar; ac_word=$2
7327+ # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
7328+set dummy ${ac_tool_prefix}dlltool; ac_word=$2
7329+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7330+$as_echo_n "checking for $ac_word... " >&6; }
7331+if test "${ac_cv_prog_DLLTOOL+set}" = set; then :
7332+ $as_echo_n "(cached) " >&6
7333+else
7334+ if test -n "$DLLTOOL"; then
7335+ ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
7336+else
7337+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7338+for as_dir in $PATH
7339+do
7340+ IFS=$as_save_IFS
7341+ test -z "$as_dir" && as_dir=.
7342+ for ac_exec_ext in '' $ac_executable_extensions; do
7343+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7344+ ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
7345+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7346+ break 2
7347+ fi
7348+done
7349+ done
7350+IFS=$as_save_IFS
7351+
7352+fi
7353+fi
7354+DLLTOOL=$ac_cv_prog_DLLTOOL
7355+if test -n "$DLLTOOL"; then
7356+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
7357+$as_echo "$DLLTOOL" >&6; }
7358+else
7359+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7360+$as_echo "no" >&6; }
7361+fi
7362+
7363+
7364+fi
7365+if test -z "$ac_cv_prog_DLLTOOL"; then
7366+ ac_ct_DLLTOOL=$DLLTOOL
7367+ # Extract the first word of "dlltool", so it can be a program name with args.
7368+set dummy dlltool; ac_word=$2
7369+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7370+$as_echo_n "checking for $ac_word... " >&6; }
7371+if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then :
7372+ $as_echo_n "(cached) " >&6
7373+else
7374+ if test -n "$ac_ct_DLLTOOL"; then
7375+ ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
7376+else
7377+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7378+for as_dir in $PATH
7379+do
7380+ IFS=$as_save_IFS
7381+ test -z "$as_dir" && as_dir=.
7382+ for ac_exec_ext in '' $ac_executable_extensions; do
7383+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7384+ ac_cv_prog_ac_ct_DLLTOOL="dlltool"
7385+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7386+ break 2
7387+ fi
7388+done
7389+ done
7390+IFS=$as_save_IFS
7391+
7392+fi
7393+fi
7394+ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
7395+if test -n "$ac_ct_DLLTOOL"; then
7396+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
7397+$as_echo "$ac_ct_DLLTOOL" >&6; }
7398+else
7399+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7400+$as_echo "no" >&6; }
7401+fi
7402+
7403+ if test "x$ac_ct_DLLTOOL" = x; then
7404+ DLLTOOL="false"
7405+ else
7406+ case $cross_compiling:$ac_tool_warned in
7407+yes:)
7408+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7409+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7410+ac_tool_warned=yes ;;
7411+esac
7412+ DLLTOOL=$ac_ct_DLLTOOL
7413+ fi
7414+else
7415+ DLLTOOL="$ac_cv_prog_DLLTOOL"
7416+fi
7417+
7418+test -z "$DLLTOOL" && DLLTOOL=dlltool
7419+
7420+
7421+
7422+
7423+
7424+
7425+
7426+
7427+
7428+
7429+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
7430+$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
7431+if test "${lt_cv_sharedlib_from_linklib_cmd+set}" = set; then :
7432+ $as_echo_n "(cached) " >&6
7433+else
7434+ lt_cv_sharedlib_from_linklib_cmd='unknown'
7435+
7436+case $host_os in
7437+cygwin* | mingw* | pw32* | cegcc*)
7438+ # two different shell functions defined in ltmain.sh
7439+ # decide which to use based on capabilities of $DLLTOOL
7440+ case `$DLLTOOL --help 2>&1` in
7441+ *--identify-strict*)
7442+ lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
7443+ ;;
7444+ *)
7445+ lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
7446+ ;;
7447+ esac
7448+ ;;
7449+*)
7450+ # fallback: assume linklib IS sharedlib
7451+ lt_cv_sharedlib_from_linklib_cmd="$ECHO"
7452+ ;;
7453+esac
7454+
7455+fi
7456+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
7457+$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
7458+sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
7459+test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
7460+
7461+
7462+
7463+
7464+
7465+
7466+
7467+if test -n "$ac_tool_prefix"; then
7468+ for ac_prog in ar
7469+ do
7470+ # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
7471+set dummy $ac_tool_prefix$ac_prog; ac_word=$2
7472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7473 $as_echo_n "checking for $ac_word... " >&6; }
7474 if test "${ac_cv_prog_AR+set}" = set; then :
7475@@ -6531,7 +6785,7 @@ do
7476 test -z "$as_dir" && as_dir=.
7477 for ac_exec_ext in '' $ac_executable_extensions; do
7478 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7479- ac_cv_prog_AR="${ac_tool_prefix}ar"
7480+ ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
7481 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7482 break 2
7483 fi
7484@@ -6551,11 +6805,15 @@ $as_echo "no" >&6; }
7485 fi
7486
7487
7488+ test -n "$AR" && break
7489+ done
7490 fi
7491-if test -z "$ac_cv_prog_AR"; then
7492+if test -z "$AR"; then
7493 ac_ct_AR=$AR
7494- # Extract the first word of "ar", so it can be a program name with args.
7495-set dummy ar; ac_word=$2
7496+ for ac_prog in ar
7497+do
7498+ # Extract the first word of "$ac_prog", so it can be a program name with args.
7499+set dummy $ac_prog; ac_word=$2
7500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7501 $as_echo_n "checking for $ac_word... " >&6; }
7502 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
7503@@ -6571,7 +6829,7 @@ do
7504 test -z "$as_dir" && as_dir=.
7505 for ac_exec_ext in '' $ac_executable_extensions; do
7506 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7507- ac_cv_prog_ac_ct_AR="ar"
7508+ ac_cv_prog_ac_ct_AR="$ac_prog"
7509 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7510 break 2
7511 fi
7512@@ -6590,6 +6848,10 @@ else
7513 $as_echo "no" >&6; }
7514 fi
7515
7516+
7517+ test -n "$ac_ct_AR" && break
7518+done
7519+
7520 if test "x$ac_ct_AR" = x; then
7521 AR="false"
7522 else
7523@@ -6601,16 +6863,72 @@ ac_tool_warned=yes ;;
7524 esac
7525 AR=$ac_ct_AR
7526 fi
7527-else
7528- AR="$ac_cv_prog_AR"
7529 fi
7530
7531-test -z "$AR" && AR=ar
7532-test -z "$AR_FLAGS" && AR_FLAGS=cru
7533+: ${AR=ar}
7534+: ${AR_FLAGS=cru}
7535+
7536+
7537+
7538+
7539+
7540+
7541+
7542+
7543+
7544+
7545
7546+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
7547+$as_echo_n "checking for archiver @FILE support... " >&6; }
7548+if test "${lt_cv_ar_at_file+set}" = set; then :
7549+ $as_echo_n "(cached) " >&6
7550+else
7551+ lt_cv_ar_at_file=no
7552+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7553+/* end confdefs.h. */
7554
7555+int
7556+main ()
7557+{
7558
7559+ ;
7560+ return 0;
7561+}
7562+_ACEOF
7563+if ac_fn_c_try_compile "$LINENO"; then :
7564+ echo conftest.$ac_objext > conftest.lst
7565+ lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
7566+ { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
7567+ (eval $lt_ar_try) 2>&5
7568+ ac_status=$?
7569+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7570+ test $ac_status = 0; }
7571+ if test "$ac_status" -eq 0; then
7572+ # Ensure the archiver fails upon bogus file names.
7573+ rm -f conftest.$ac_objext libconftest.a
7574+ { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
7575+ (eval $lt_ar_try) 2>&5
7576+ ac_status=$?
7577+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7578+ test $ac_status = 0; }
7579+ if test "$ac_status" -ne 0; then
7580+ lt_cv_ar_at_file=@
7581+ fi
7582+ fi
7583+ rm -f conftest.* libconftest.a
7584
7585+fi
7586+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7587+
7588+fi
7589+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
7590+$as_echo "$lt_cv_ar_at_file" >&6; }
7591+
7592+if test "x$lt_cv_ar_at_file" = xno; then
7593+ archiver_list_spec=
7594+else
7595+ archiver_list_spec=$lt_cv_ar_at_file
7596+fi
7597
7598
7599
7600@@ -6952,8 +7270,8 @@ esac
7601 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
7602
7603 # Transform an extracted symbol line into symbol name and symbol address
7604-lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
7605-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
7606+lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
7607+lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
7608
7609 # Handle CRLF in mingw tool chain
7610 opt_cr=
7611@@ -6989,6 +7307,7 @@ for ac_symprfx in "" "_"; do
7612 else
7613 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
7614 fi
7615+ lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
7616
7617 # Check to see that the pipe works correctly.
7618 pipe_works=no
7619@@ -7030,6 +7349,18 @@ _LT_EOF
7620 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
7621 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
7622 cat <<_LT_EOF > conftest.$ac_ext
7623+/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
7624+#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
7625+/* DATA imports from DLLs on WIN32 con't be const, because runtime
7626+ relocations are performed -- see ld's documentation on pseudo-relocs. */
7627+# define LT_DLSYM_CONST
7628+#elif defined(__osf__)
7629+/* This system does not cope well with relocations in const data. */
7630+# define LT_DLSYM_CONST
7631+#else
7632+# define LT_DLSYM_CONST const
7633+#endif
7634+
7635 #ifdef __cplusplus
7636 extern "C" {
7637 #endif
7638@@ -7041,7 +7372,7 @@ _LT_EOF
7639 cat <<_LT_EOF >> conftest.$ac_ext
7640
7641 /* The mapping between symbol names and symbols. */
7642-const struct {
7643+LT_DLSYM_CONST struct {
7644 const char *name;
7645 void *address;
7646 }
7647@@ -7067,8 +7398,8 @@ static const void *lt_preloaded_setup()
7648 _LT_EOF
7649 # Now try linking the two files.
7650 mv conftest.$ac_objext conftstm.$ac_objext
7651- lt_save_LIBS="$LIBS"
7652- lt_save_CFLAGS="$CFLAGS"
7653+ lt_globsym_save_LIBS=$LIBS
7654+ lt_globsym_save_CFLAGS=$CFLAGS
7655 LIBS="conftstm.$ac_objext"
7656 CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
7657 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
7658@@ -7078,8 +7409,8 @@ _LT_EOF
7659 test $ac_status = 0; } && test -s conftest${ac_exeext}; then
7660 pipe_works=yes
7661 fi
7662- LIBS="$lt_save_LIBS"
7663- CFLAGS="$lt_save_CFLAGS"
7664+ LIBS=$lt_globsym_save_LIBS
7665+ CFLAGS=$lt_globsym_save_CFLAGS
7666 else
7667 echo "cannot find nm_test_func in $nlist" >&5
7668 fi
7669@@ -7116,6 +7447,20 @@ else
7670 $as_echo "ok" >&6; }
7671 fi
7672
7673+# Response file support.
7674+if test "$lt_cv_nm_interface" = "MS dumpbin"; then
7675+ nm_file_list_spec='@'
7676+elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
7677+ nm_file_list_spec='@'
7678+fi
7679+
7680+
7681+
7682+
7683+
7684+
7685+
7686+
7687
7688
7689
7690@@ -7135,6 +7480,41 @@ fi
7691
7692
7693
7694+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
7695+$as_echo_n "checking for sysroot... " >&6; }
7696+
7697+# Check whether --with-libtool-sysroot was given.
7698+if test "${with_libtool_sysroot+set}" = set; then :
7699+ withval=$with_libtool_sysroot;
7700+else
7701+ with_libtool_sysroot=no
7702+fi
7703+
7704+
7705+lt_sysroot=
7706+case ${with_libtool_sysroot} in #(
7707+ yes)
7708+ if test "$GCC" = yes; then
7709+ lt_sysroot=`$CC --print-sysroot 2>/dev/null`
7710+ fi
7711+ ;; #(
7712+ /*)
7713+ lt_sysroot=`echo "$with_libtool_sysroot" | sed -e "$sed_quote_subst"`
7714+ ;; #(
7715+ no|'')
7716+ ;; #(
7717+ *)
7718+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libtool_sysroot}" >&5
7719+$as_echo "${with_libtool_sysroot}" >&6; }
7720+ as_fn_error "The sysroot must be an absolute path." "$LINENO" 5
7721+ ;;
7722+esac
7723+
7724+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
7725+$as_echo "${lt_sysroot:-no}" >&6; }
7726+
7727+
7728+
7729
7730
7731 # Check whether --enable-libtool-lock was given.
7732@@ -7330,6 +7710,123 @@ esac
7733
7734 need_locks="$enable_libtool_lock"
7735
7736+if test -n "$ac_tool_prefix"; then
7737+ # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
7738+set dummy ${ac_tool_prefix}mt; ac_word=$2
7739+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7740+$as_echo_n "checking for $ac_word... " >&6; }
7741+if test "${ac_cv_prog_MANIFEST_TOOL+set}" = set; then :
7742+ $as_echo_n "(cached) " >&6
7743+else
7744+ if test -n "$MANIFEST_TOOL"; then
7745+ ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
7746+else
7747+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7748+for as_dir in $PATH
7749+do
7750+ IFS=$as_save_IFS
7751+ test -z "$as_dir" && as_dir=.
7752+ for ac_exec_ext in '' $ac_executable_extensions; do
7753+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7754+ ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
7755+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7756+ break 2
7757+ fi
7758+done
7759+ done
7760+IFS=$as_save_IFS
7761+
7762+fi
7763+fi
7764+MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
7765+if test -n "$MANIFEST_TOOL"; then
7766+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
7767+$as_echo "$MANIFEST_TOOL" >&6; }
7768+else
7769+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7770+$as_echo "no" >&6; }
7771+fi
7772+
7773+
7774+fi
7775+if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
7776+ ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
7777+ # Extract the first word of "mt", so it can be a program name with args.
7778+set dummy mt; ac_word=$2
7779+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7780+$as_echo_n "checking for $ac_word... " >&6; }
7781+if test "${ac_cv_prog_ac_ct_MANIFEST_TOOL+set}" = set; then :
7782+ $as_echo_n "(cached) " >&6
7783+else
7784+ if test -n "$ac_ct_MANIFEST_TOOL"; then
7785+ ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
7786+else
7787+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7788+for as_dir in $PATH
7789+do
7790+ IFS=$as_save_IFS
7791+ test -z "$as_dir" && as_dir=.
7792+ for ac_exec_ext in '' $ac_executable_extensions; do
7793+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7794+ ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
7795+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7796+ break 2
7797+ fi
7798+done
7799+ done
7800+IFS=$as_save_IFS
7801+
7802+fi
7803+fi
7804+ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
7805+if test -n "$ac_ct_MANIFEST_TOOL"; then
7806+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
7807+$as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
7808+else
7809+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7810+$as_echo "no" >&6; }
7811+fi
7812+
7813+ if test "x$ac_ct_MANIFEST_TOOL" = x; then
7814+ MANIFEST_TOOL=":"
7815+ else
7816+ case $cross_compiling:$ac_tool_warned in
7817+yes:)
7818+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7819+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7820+ac_tool_warned=yes ;;
7821+esac
7822+ MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
7823+ fi
7824+else
7825+ MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
7826+fi
7827+
7828+test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
7829+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
7830+$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
7831+if test "${lt_cv_path_mainfest_tool+set}" = set; then :
7832+ $as_echo_n "(cached) " >&6
7833+else
7834+ lt_cv_path_mainfest_tool=no
7835+ echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
7836+ $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
7837+ cat conftest.err >&5
7838+ if $GREP 'Manifest Tool' conftest.out > /dev/null; then
7839+ lt_cv_path_mainfest_tool=yes
7840+ fi
7841+ rm -f conftest*
7842+fi
7843+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
7844+$as_echo "$lt_cv_path_mainfest_tool" >&6; }
7845+if test "x$lt_cv_path_mainfest_tool" != xyes; then
7846+ MANIFEST_TOOL=:
7847+fi
7848+
7849+
7850+
7851+
7852+
7853
7854 case $host_os in
7855 rhapsody* | darwin*)
7856@@ -7893,6 +8390,8 @@ _LT_EOF
7857 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
7858 echo "$AR cru libconftest.a conftest.o" >&5
7859 $AR cru libconftest.a conftest.o 2>&5
7860+ echo "$RANLIB libconftest.a" >&5
7861+ $RANLIB libconftest.a 2>&5
7862 cat > conftest.c << _LT_EOF
7863 int main() { return 0;}
7864 _LT_EOF
7865@@ -8057,7 +8556,8 @@ fi
7866 LIBTOOL_DEPS="$ltmain"
7867
7868 # Always use our own libtool.
7869-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
7870+LIBTOOL='$(SHELL) $(top_builddir)'
7871+LIBTOOL="$LIBTOOL/${host_alias}-libtool"
7872
7873
7874
7875@@ -8146,7 +8646,7 @@ aix3*)
7876 esac
7877
7878 # Global variables:
7879-ofile=libtool
7880+ofile=${host_alias}-libtool
7881 can_build_shared=yes
7882
7883 # All known linkers require a `.a' archive for static linking (except MSVC,
7884@@ -8444,8 +8944,6 @@ fi
7885 lt_prog_compiler_pic=
7886 lt_prog_compiler_static=
7887
7888-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
7889-$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
7890
7891 if test "$GCC" = yes; then
7892 lt_prog_compiler_wl='-Wl,'
7893@@ -8610,6 +9108,12 @@ $as_echo_n "checking for $compiler optio
7894 lt_prog_compiler_pic='--shared'
7895 lt_prog_compiler_static='--static'
7896 ;;
7897+ nagfor*)
7898+ # NAG Fortran compiler
7899+ lt_prog_compiler_wl='-Wl,-Wl,,'
7900+ lt_prog_compiler_pic='-PIC'
7901+ lt_prog_compiler_static='-Bstatic'
7902+ ;;
7903 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
7904 # Portland Group compilers (*not* the Pentium gcc compiler,
7905 # which looks to be a dead project)
7906@@ -8672,7 +9176,7 @@ $as_echo_n "checking for $compiler optio
7907 lt_prog_compiler_pic='-KPIC'
7908 lt_prog_compiler_static='-Bstatic'
7909 case $cc_basename in
7910- f77* | f90* | f95*)
7911+ f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
7912 lt_prog_compiler_wl='-Qoption ld ';;
7913 *)
7914 lt_prog_compiler_wl='-Wl,';;
7915@@ -8729,13 +9233,17 @@ case $host_os in
7916 lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
7917 ;;
7918 esac
7919-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5
7920-$as_echo "$lt_prog_compiler_pic" >&6; }
7921-
7922-
7923-
7924-
7925
7926+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
7927+$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
7928+if test "${lt_cv_prog_compiler_pic+set}" = set; then :
7929+ $as_echo_n "(cached) " >&6
7930+else
7931+ lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
7932+fi
7933+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
7934+$as_echo "$lt_cv_prog_compiler_pic" >&6; }
7935+lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
7936
7937 #
7938 # Check to make sure the PIC flag actually works.
7939@@ -8796,6 +9304,11 @@ fi
7940
7941
7942
7943+
7944+
7945+
7946+
7947+
7948 #
7949 # Check to make sure the static flag actually works.
7950 #
7951@@ -9146,7 +9659,8 @@ _LT_EOF
7952 allow_undefined_flag=unsupported
7953 always_export_symbols=no
7954 enable_shared_with_static_runtimes=yes
7955- export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
7956+ export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
7957+ exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
7958
7959 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
7960 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
7961@@ -9194,7 +9708,7 @@ _LT_EOF
7962 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
7963 && test "$tmp_diet" = no
7964 then
7965- tmp_addflag=
7966+ tmp_addflag=' $pic_flag'
7967 tmp_sharedflag='-shared'
7968 case $cc_basename,$host_cpu in
7969 pgcc*) # Portland Group C compiler
7970@@ -9245,12 +9759,12 @@ _LT_EOF
7971 whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
7972 hardcode_libdir_flag_spec=
7973 hardcode_libdir_flag_spec_ld='-rpath $libdir'
7974- archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
7975+ archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
7976 if test "x$supports_anon_versioning" = xyes; then
7977 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
7978 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
7979 echo "local: *; };" >> $output_objdir/$libname.ver~
7980- $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
7981+ $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
7982 fi
7983 ;;
7984 esac
7985@@ -9264,8 +9778,8 @@ _LT_EOF
7986 archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
7987 wlarc=
7988 else
7989- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7990- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
7991+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7992+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
7993 fi
7994 ;;
7995
7996@@ -9283,8 +9797,8 @@ _LT_EOF
7997
7998 _LT_EOF
7999 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
8000- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8001- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8002+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8003+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8004 else
8005 ld_shlibs=no
8006 fi
8007@@ -9330,8 +9844,8 @@ _LT_EOF
8008
8009 *)
8010 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
8011- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8012- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8013+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8014+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8015 else
8016 ld_shlibs=no
8017 fi
8018@@ -9461,7 +9975,13 @@ _LT_EOF
8019 allow_undefined_flag='-berok'
8020 # Determine the default libpath from the value encoded in an
8021 # empty executable.
8022- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8023+ if test "${lt_cv_aix_libpath+set}" = set; then
8024+ aix_libpath=$lt_cv_aix_libpath
8025+else
8026+ if test "${lt_cv_aix_libpath_+set}" = set; then :
8027+ $as_echo_n "(cached) " >&6
8028+else
8029+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8030 /* end confdefs.h. */
8031
8032 int
8033@@ -9474,22 +9994,29 @@ main ()
8034 _ACEOF
8035 if ac_fn_c_try_link "$LINENO"; then :
8036
8037-lt_aix_libpath_sed='
8038- /Import File Strings/,/^$/ {
8039- /^0/ {
8040- s/^0 *\(.*\)$/\1/
8041- p
8042- }
8043- }'
8044-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
8045-# Check for a 64-bit object if we didn't find anything.
8046-if test -z "$aix_libpath"; then
8047- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
8048-fi
8049+ lt_aix_libpath_sed='
8050+ /Import File Strings/,/^$/ {
8051+ /^0/ {
8052+ s/^0 *\([^ ]*\) *$/\1/
8053+ p
8054+ }
8055+ }'
8056+ lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
8057+ # Check for a 64-bit object if we didn't find anything.
8058+ if test -z "$lt_cv_aix_libpath_"; then
8059+ lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
8060+ fi
8061 fi
8062 rm -f core conftest.err conftest.$ac_objext \
8063 conftest$ac_exeext conftest.$ac_ext
8064-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
8065+ if test -z "$lt_cv_aix_libpath_"; then
8066+ lt_cv_aix_libpath_="/usr/lib:/lib"
8067+ fi
8068+
8069+fi
8070+
8071+ aix_libpath=$lt_cv_aix_libpath_
8072+fi
8073
8074 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
8075 archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
8076@@ -9501,7 +10028,13 @@ if test -z "$aix_libpath"; then aix_libp
8077 else
8078 # Determine the default libpath from the value encoded in an
8079 # empty executable.
8080- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8081+ if test "${lt_cv_aix_libpath+set}" = set; then
8082+ aix_libpath=$lt_cv_aix_libpath
8083+else
8084+ if test "${lt_cv_aix_libpath_+set}" = set; then :
8085+ $as_echo_n "(cached) " >&6
8086+else
8087+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8088 /* end confdefs.h. */
8089
8090 int
8091@@ -9514,22 +10047,29 @@ main ()
8092 _ACEOF
8093 if ac_fn_c_try_link "$LINENO"; then :
8094
8095-lt_aix_libpath_sed='
8096- /Import File Strings/,/^$/ {
8097- /^0/ {
8098- s/^0 *\(.*\)$/\1/
8099- p
8100- }
8101- }'
8102-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
8103-# Check for a 64-bit object if we didn't find anything.
8104-if test -z "$aix_libpath"; then
8105- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
8106-fi
8107+ lt_aix_libpath_sed='
8108+ /Import File Strings/,/^$/ {
8109+ /^0/ {
8110+ s/^0 *\([^ ]*\) *$/\1/
8111+ p
8112+ }
8113+ }'
8114+ lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
8115+ # Check for a 64-bit object if we didn't find anything.
8116+ if test -z "$lt_cv_aix_libpath_"; then
8117+ lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
8118+ fi
8119 fi
8120 rm -f core conftest.err conftest.$ac_objext \
8121 conftest$ac_exeext conftest.$ac_ext
8122-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
8123+ if test -z "$lt_cv_aix_libpath_"; then
8124+ lt_cv_aix_libpath_="/usr/lib:/lib"
8125+ fi
8126+
8127+fi
8128+
8129+ aix_libpath=$lt_cv_aix_libpath_
8130+fi
8131
8132 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
8133 # Warning - without using the other run time loading flags,
8134@@ -9574,20 +10114,63 @@ if test -z "$aix_libpath"; then aix_libp
8135 # Microsoft Visual C++.
8136 # hardcode_libdir_flag_spec is actually meaningless, as there is
8137 # no search path for DLLs.
8138- hardcode_libdir_flag_spec=' '
8139- allow_undefined_flag=unsupported
8140- # Tell ltmain to make .lib files, not .a files.
8141- libext=lib
8142- # Tell ltmain to make .dll files, not .so files.
8143- shrext_cmds=".dll"
8144- # FIXME: Setting linknames here is a bad hack.
8145- archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
8146- # The linker will automatically build a .lib file if we build a DLL.
8147- old_archive_from_new_cmds='true'
8148- # FIXME: Should let the user specify the lib program.
8149- old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
8150- fix_srcfile_path='`cygpath -w "$srcfile"`'
8151- enable_shared_with_static_runtimes=yes
8152+ case $cc_basename in
8153+ cl*)
8154+ # Native MSVC
8155+ hardcode_libdir_flag_spec=' '
8156+ allow_undefined_flag=unsupported
8157+ always_export_symbols=yes
8158+ file_list_spec='@'
8159+ # Tell ltmain to make .lib files, not .a files.
8160+ libext=lib
8161+ # Tell ltmain to make .dll files, not .so files.
8162+ shrext_cmds=".dll"
8163+ # FIXME: Setting linknames here is a bad hack.
8164+ archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
8165+ archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
8166+ sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
8167+ else
8168+ sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
8169+ fi~
8170+ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
8171+ linknames='
8172+ # The linker will not automatically build a static lib if we build a DLL.
8173+ # _LT_TAGVAR(old_archive_from_new_cmds, )='true'
8174+ enable_shared_with_static_runtimes=yes
8175+ export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
8176+ # Don't use ranlib
8177+ old_postinstall_cmds='chmod 644 $oldlib'
8178+ postlink_cmds='lt_outputfile="@OUTPUT@"~
8179+ lt_tool_outputfile="@TOOL_OUTPUT@"~
8180+ case $lt_outputfile in
8181+ *.exe|*.EXE) ;;
8182+ *)
8183+ lt_outputfile="$lt_outputfile.exe"
8184+ lt_tool_outputfile="$lt_tool_outputfile.exe"
8185+ ;;
8186+ esac~
8187+ if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
8188+ $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
8189+ $RM "$lt_outputfile.manifest";
8190+ fi'
8191+ ;;
8192+ *)
8193+ # Assume MSVC wrapper
8194+ hardcode_libdir_flag_spec=' '
8195+ allow_undefined_flag=unsupported
8196+ # Tell ltmain to make .lib files, not .a files.
8197+ libext=lib
8198+ # Tell ltmain to make .dll files, not .so files.
8199+ shrext_cmds=".dll"
8200+ # FIXME: Setting linknames here is a bad hack.
8201+ archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
8202+ # The linker will automatically build a .lib file if we build a DLL.
8203+ old_archive_from_new_cmds='true'
8204+ # FIXME: Should let the user specify the lib program.
8205+ old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
8206+ enable_shared_with_static_runtimes=yes
8207+ ;;
8208+ esac
8209 ;;
8210
8211 darwin* | rhapsody*)
8212@@ -9648,7 +10231,7 @@ if test -z "$aix_libpath"; then aix_libp
8213
8214 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
8215 freebsd* | dragonfly*)
8216- archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
8217+ archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
8218 hardcode_libdir_flag_spec='-R$libdir'
8219 hardcode_direct=yes
8220 hardcode_shlibpath_var=no
8221@@ -9656,7 +10239,7 @@ if test -z "$aix_libpath"; then aix_libp
8222
8223 hpux9*)
8224 if test "$GCC" = yes; then
8225- archive_cmds='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
8226+ archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
8227 else
8228 archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
8229 fi
8230@@ -9672,7 +10255,7 @@ if test -z "$aix_libpath"; then aix_libp
8231
8232 hpux10*)
8233 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
8234- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
8235+ archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
8236 else
8237 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
8238 fi
8239@@ -9696,10 +10279,10 @@ if test -z "$aix_libpath"; then aix_libp
8240 archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8241 ;;
8242 ia64*)
8243- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
8244+ archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
8245 ;;
8246 *)
8247- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
8248+ archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
8249 ;;
8250 esac
8251 else
8252@@ -9778,23 +10361,36 @@ fi
8253
8254 irix5* | irix6* | nonstopux*)
8255 if test "$GCC" = yes; then
8256- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
8257+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
8258 # Try to use the -exported_symbol ld option, if it does not
8259 # work, assume that -exports_file does not work either and
8260 # implicitly export all symbols.
8261- save_LDFLAGS="$LDFLAGS"
8262- LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
8263- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8264+ # This should be the same for all languages, so no per-tag cache variable.
8265+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
8266+$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
8267+if test "${lt_cv_irix_exported_symbol+set}" = set; then :
8268+ $as_echo_n "(cached) " >&6
8269+else
8270+ save_LDFLAGS="$LDFLAGS"
8271+ LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
8272+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8273 /* end confdefs.h. */
8274-int foo(void) {}
8275+int foo (void) { return 0; }
8276 _ACEOF
8277 if ac_fn_c_try_link "$LINENO"; then :
8278- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
8279-
8280+ lt_cv_irix_exported_symbol=yes
8281+else
8282+ lt_cv_irix_exported_symbol=no
8283 fi
8284 rm -f core conftest.err conftest.$ac_objext \
8285 conftest$ac_exeext conftest.$ac_ext
8286- LDFLAGS="$save_LDFLAGS"
8287+ LDFLAGS="$save_LDFLAGS"
8288+fi
8289+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
8290+$as_echo "$lt_cv_irix_exported_symbol" >&6; }
8291+ if test "$lt_cv_irix_exported_symbol" = yes; then
8292+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
8293+ fi
8294 else
8295 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
8296 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
8297@@ -9879,7 +10475,7 @@ rm -f core conftest.err conftest.$ac_obj
8298 osf4* | osf5*) # as osf3* with the addition of -msym flag
8299 if test "$GCC" = yes; then
8300 allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
8301- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
8302+ archive_cmds='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
8303 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8304 else
8305 allow_undefined_flag=' -expect_unresolved \*'
8306@@ -9898,9 +10494,9 @@ rm -f core conftest.err conftest.$ac_obj
8307 no_undefined_flag=' -z defs'
8308 if test "$GCC" = yes; then
8309 wlarc='${wl}'
8310- archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8311+ archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8312 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
8313- $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
8314+ $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
8315 else
8316 case `$CC -V 2>&1` in
8317 *"Compilers 5.0"*)
8318@@ -10476,8 +11072,9 @@ cygwin* | mingw* | pw32* | cegcc*)
8319 need_version=no
8320 need_lib_prefix=no
8321
8322- case $GCC,$host_os in
8323- yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
8324+ case $GCC,$cc_basename in
8325+ yes,*)
8326+ # gcc
8327 library_names_spec='$libname.dll.a'
8328 # DLL is installed to $(libdir)/../bin by postinstall_cmds
8329 postinstall_cmds='base_file=`basename \${file}`~
8330@@ -10510,13 +11107,71 @@ cygwin* | mingw* | pw32* | cegcc*)
8331 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
8332 ;;
8333 esac
8334+ dynamic_linker='Win32 ld.exe'
8335+ ;;
8336+
8337+ *,cl*)
8338+ # Native MSVC
8339+ libname_spec='$name'
8340+ soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
8341+ library_names_spec='${libname}.dll.lib'
8342+
8343+ case $build_os in
8344+ mingw*)
8345+ sys_lib_search_path_spec=
8346+ lt_save_ifs=$IFS
8347+ IFS=';'
8348+ for lt_path in $LIB
8349+ do
8350+ IFS=$lt_save_ifs
8351+ # Let DOS variable expansion print the short 8.3 style file name.
8352+ lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
8353+ sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
8354+ done
8355+ IFS=$lt_save_ifs
8356+ # Convert to MSYS style.
8357+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
8358+ ;;
8359+ cygwin*)
8360+ # Convert to unix form, then to dos form, then back to unix form
8361+ # but this time dos style (no spaces!) so that the unix form looks
8362+ # like /cygdrive/c/PROGRA~1:/cygdr...
8363+ sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
8364+ sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
8365+ sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
8366+ ;;
8367+ *)
8368+ sys_lib_search_path_spec="$LIB"
8369+ if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
8370+ # It is most probably a Windows format PATH.
8371+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
8372+ else
8373+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
8374+ fi
8375+ # FIXME: find the short name or the path components, as spaces are
8376+ # common. (e.g. "Program Files" -> "PROGRA~1")
8377+ ;;
8378+ esac
8379+
8380+ # DLL is installed to $(libdir)/../bin by postinstall_cmds
8381+ postinstall_cmds='base_file=`basename \${file}`~
8382+ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
8383+ dldir=$destdir/`dirname \$dlpath`~
8384+ test -d \$dldir || mkdir -p \$dldir~
8385+ $install_prog $dir/$dlname \$dldir/$dlname'
8386+ postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
8387+ dlpath=$dir/\$dldll~
8388+ $RM \$dlpath'
8389+ shlibpath_overrides_runpath=yes
8390+ dynamic_linker='Win32 link.exe'
8391 ;;
8392
8393 *)
8394+ # Assume MSVC wrapper
8395 library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
8396+ dynamic_linker='Win32 ld.exe'
8397 ;;
8398 esac
8399- dynamic_linker='Win32 ld.exe'
8400 # FIXME: first we should search . and the directory the executable is in
8401 shlibpath_var=PATH
8402 ;;
8403@@ -10608,7 +11263,7 @@ haiku*)
8404 soname_spec='${libname}${release}${shared_ext}$major'
8405 shlibpath_var=LIBRARY_PATH
8406 shlibpath_overrides_runpath=yes
8407- sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/beos/system/lib'
8408+ sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
8409 hardcode_into_libs=yes
8410 ;;
8411
8412@@ -11404,7 +12059,7 @@ else
8413 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
8414 lt_status=$lt_dlunknown
8415 cat > conftest.$ac_ext <<_LT_EOF
8416-#line 11407 "configure"
8417+#line $LINENO "configure"
8418 #include "confdefs.h"
8419
8420 #if HAVE_DLFCN_H
8421@@ -11448,10 +12103,10 @@ else
8422 /* When -fvisbility=hidden is used, assume the code has been annotated
8423 correspondingly for the symbols needed. */
8424 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
8425-void fnord () __attribute__((visibility("default")));
8426+int fnord () __attribute__((visibility("default")));
8427 #endif
8428
8429-void fnord () { int i=42; }
8430+int fnord () { return 42; }
8431 int main ()
8432 {
8433 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
8434@@ -11510,7 +12165,7 @@ else
8435 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
8436 lt_status=$lt_dlunknown
8437 cat > conftest.$ac_ext <<_LT_EOF
8438-#line 11513 "configure"
8439+#line $LINENO "configure"
8440 #include "confdefs.h"
8441
8442 #if HAVE_DLFCN_H
8443@@ -11554,10 +12209,10 @@ else
8444 /* When -fvisbility=hidden is used, assume the code has been annotated
8445 correspondingly for the symbols needed. */
8446 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
8447-void fnord () __attribute__((visibility("default")));
8448+int fnord () __attribute__((visibility("default")));
8449 #endif
8450
8451-void fnord () { int i=42; }
8452+int fnord () { return 42; }
8453 int main ()
8454 {
8455 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
8456@@ -15037,7 +15692,7 @@ SHARED_LDFLAGS=
8457 if test "$enable_shared" = "yes"; then
8458 x=`sed -n -e 's/^[ ]*PICFLAG[ ]*=[ ]*//p' < ../libiberty/Makefile | sed -n '$p'`
8459 if test -n "$x"; then
8460- SHARED_LIBADD="-L`pwd`/../libiberty/pic -liberty"
8461+ SHARED_LIBADD="`pwd`/../libiberty/pic/libiberty.a"
8462 fi
8463
8464 # More hacks to build DLLs on Windows.
8465@@ -16629,13 +17284,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_
8466 lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
8467 lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
8468 lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
8469+lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
8470+lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
8471 reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
8472 reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
8473 OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
8474 deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
8475 file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
8476+file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
8477+want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
8478+DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
8479+sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
8480 AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
8481 AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
8482+archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
8483 STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
8484 RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
8485 old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
8486@@ -16650,14 +17312,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$l
8487 lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
8488 lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
8489 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
8490+nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
8491+lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
8492 objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
8493 MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
8494 lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
8495-lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
8496 lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
8497+lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
8498 lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
8499 lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
8500 need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
8501+MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
8502 DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
8503 NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
8504 LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
8505@@ -16690,12 +17355,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcod
8506 hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
8507 inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
8508 link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
8509-fix_srcfile_path='`$ECHO "$fix_srcfile_path" | $SED "$delay_single_quote_subst"`'
8510 always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
8511 export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
8512 exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
8513 include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
8514 prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
8515+postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
8516 file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
8517 variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
8518 need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
8519@@ -16750,8 +17415,13 @@ reload_flag \
8520 OBJDUMP \
8521 deplibs_check_method \
8522 file_magic_cmd \
8523+file_magic_glob \
8524+want_nocaseglob \
8525+DLLTOOL \
8526+sharedlib_from_linklib_cmd \
8527 AR \
8528 AR_FLAGS \
8529+archiver_list_spec \
8530 STRIP \
8531 RANLIB \
8532 CC \
8533@@ -16761,12 +17431,14 @@ lt_cv_sys_global_symbol_pipe \
8534 lt_cv_sys_global_symbol_to_cdecl \
8535 lt_cv_sys_global_symbol_to_c_name_address \
8536 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
8537+nm_file_list_spec \
8538 lt_prog_compiler_no_builtin_flag \
8539-lt_prog_compiler_wl \
8540 lt_prog_compiler_pic \
8541+lt_prog_compiler_wl \
8542 lt_prog_compiler_static \
8543 lt_cv_prog_compiler_c_o \
8544 need_locks \
8545+MANIFEST_TOOL \
8546 DSYMUTIL \
8547 NMEDIT \
8548 LIPO \
8549@@ -16782,7 +17454,6 @@ no_undefined_flag \
8550 hardcode_libdir_flag_spec \
8551 hardcode_libdir_flag_spec_ld \
8552 hardcode_libdir_separator \
8553-fix_srcfile_path \
8554 exclude_expsyms \
8555 include_expsyms \
8556 file_list_spec \
8557@@ -16818,6 +17489,7 @@ module_cmds \
8558 module_expsym_cmds \
8559 export_symbols_cmds \
8560 prelink_cmds \
8561+postlink_cmds \
8562 postinstall_cmds \
8563 postuninstall_cmds \
8564 finish_cmds \
8565@@ -17597,7 +18269,8 @@ $as_echo X"$file" |
8566 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
8567 #
8568 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
8569-# 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
8570+# 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
8571+# Inc.
8572 # Written by Gordon Matzigkeit, 1996
8573 #
8574 # This file is part of GNU Libtool.
8575@@ -17700,19 +18373,42 @@ SP2NL=$lt_lt_SP2NL
8576 # turn newlines into spaces.
8577 NL2SP=$lt_lt_NL2SP
8578
8579+# convert \$build file names to \$host format.
8580+to_host_file_cmd=$lt_cv_to_host_file_cmd
8581+
8582+# convert \$build files to toolchain format.
8583+to_tool_file_cmd=$lt_cv_to_tool_file_cmd
8584+
8585 # An object symbol dumper.
8586 OBJDUMP=$lt_OBJDUMP
8587
8588 # Method to check whether dependent libraries are shared objects.
8589 deplibs_check_method=$lt_deplibs_check_method
8590
8591-# Command to use when deplibs_check_method == "file_magic".
8592+# Command to use when deplibs_check_method = "file_magic".
8593 file_magic_cmd=$lt_file_magic_cmd
8594
8595+# How to find potential files when deplibs_check_method = "file_magic".
8596+file_magic_glob=$lt_file_magic_glob
8597+
8598+# Find potential files using nocaseglob when deplibs_check_method = "file_magic".
8599+want_nocaseglob=$lt_want_nocaseglob
8600+
8601+# DLL creation program.
8602+DLLTOOL=$lt_DLLTOOL
8603+
8604+# Command to associate shared and link libraries.
8605+sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
8606+
8607 # The archiver.
8608 AR=$lt_AR
8609+
8610+# Flags to create an archive.
8611 AR_FLAGS=$lt_AR_FLAGS
8612
8613+# How to feed a file listing to the archiver.
8614+archiver_list_spec=$lt_archiver_list_spec
8615+
8616 # A symbol stripping program.
8617 STRIP=$lt_STRIP
8618
8619@@ -17742,6 +18438,12 @@ global_symbol_to_c_name_address=$lt_lt_c
8620 # Transform the output of nm in a C name address pair when lib prefix is needed.
8621 global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
8622
8623+# Specify filename containing input files for \$NM.
8624+nm_file_list_spec=$lt_nm_file_list_spec
8625+
8626+# The root where to search for dependent libraries,and in which our libraries should be installed.
8627+lt_sysroot=$lt_sysroot
8628+
8629 # The name of the directory that contains temporary libtool files.
8630 objdir=$objdir
8631
8632@@ -17751,6 +18453,9 @@ MAGIC_CMD=$MAGIC_CMD
8633 # Must we lock files when doing compilation?
8634 need_locks=$lt_need_locks
8635
8636+# Manifest tool.
8637+MANIFEST_TOOL=$lt_MANIFEST_TOOL
8638+
8639 # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
8640 DSYMUTIL=$lt_DSYMUTIL
8641
8642@@ -17865,12 +18570,12 @@ with_gcc=$GCC
8643 # Compiler flag to turn off builtin functions.
8644 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
8645
8646-# How to pass a linker flag through the compiler.
8647-wl=$lt_lt_prog_compiler_wl
8648-
8649 # Additional compiler flags for building library objects.
8650 pic_flag=$lt_lt_prog_compiler_pic
8651
8652+# How to pass a linker flag through the compiler.
8653+wl=$lt_lt_prog_compiler_wl
8654+
8655 # Compiler flag to prevent dynamic linking.
8656 link_static_flag=$lt_lt_prog_compiler_static
8657
8658@@ -17957,9 +18662,6 @@ inherit_rpath=$inherit_rpath
8659 # Whether libtool must link a program against all its dependency libraries.
8660 link_all_deplibs=$link_all_deplibs
8661
8662-# Fix the shell variable \$srcfile for the compiler.
8663-fix_srcfile_path=$lt_fix_srcfile_path
8664-
8665 # Set to "yes" if exported symbols are required.
8666 always_export_symbols=$always_export_symbols
8667
8668@@ -17975,6 +18677,9 @@ include_expsyms=$lt_include_expsyms
8669 # Commands necessary for linking programs (against libraries) with templates.
8670 prelink_cmds=$lt_prelink_cmds
8671
8672+# Commands necessary for finishing linking programs.
8673+postlink_cmds=$lt_postlink_cmds
8674+
8675 # Specify filename containing input files.
8676 file_list_spec=$lt_file_list_spec
8677
8678@@ -18007,210 +18712,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
8679 # if finds mixed CR/LF and LF-only lines. Since sed operates in
8680 # text mode, it properly converts lines to CR/LF. This bash problem
8681 # is reportedly fixed, but why not run on old versions too?
8682- sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
8683- || (rm -f "$cfgfile"; exit 1)
8684-
8685- case $xsi_shell in
8686- yes)
8687- cat << \_LT_EOF >> "$cfgfile"
8688-
8689-# func_dirname file append nondir_replacement
8690-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
8691-# otherwise set result to NONDIR_REPLACEMENT.
8692-func_dirname ()
8693-{
8694- case ${1} in
8695- */*) func_dirname_result="${1%/*}${2}" ;;
8696- * ) func_dirname_result="${3}" ;;
8697- esac
8698-}
8699-
8700-# func_basename file
8701-func_basename ()
8702-{
8703- func_basename_result="${1##*/}"
8704-}
8705-
8706-# func_dirname_and_basename file append nondir_replacement
8707-# perform func_basename and func_dirname in a single function
8708-# call:
8709-# dirname: Compute the dirname of FILE. If nonempty,
8710-# add APPEND to the result, otherwise set result
8711-# to NONDIR_REPLACEMENT.
8712-# value returned in "$func_dirname_result"
8713-# basename: Compute filename of FILE.
8714-# value retuned in "$func_basename_result"
8715-# Implementation must be kept synchronized with func_dirname
8716-# and func_basename. For efficiency, we do not delegate to
8717-# those functions but instead duplicate the functionality here.
8718-func_dirname_and_basename ()
8719-{
8720- case ${1} in
8721- */*) func_dirname_result="${1%/*}${2}" ;;
8722- * ) func_dirname_result="${3}" ;;
8723- esac
8724- func_basename_result="${1##*/}"
8725-}
8726-
8727-# func_stripname prefix suffix name
8728-# strip PREFIX and SUFFIX off of NAME.
8729-# PREFIX and SUFFIX must not contain globbing or regex special
8730-# characters, hashes, percent signs, but SUFFIX may contain a leading
8731-# dot (in which case that matches only a dot).
8732-func_stripname ()
8733-{
8734- # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
8735- # positional parameters, so assign one to ordinary parameter first.
8736- func_stripname_result=${3}
8737- func_stripname_result=${func_stripname_result#"${1}"}
8738- func_stripname_result=${func_stripname_result%"${2}"}
8739-}
8740-
8741-# func_opt_split
8742-func_opt_split ()
8743-{
8744- func_opt_split_opt=${1%%=*}
8745- func_opt_split_arg=${1#*=}
8746-}
8747-
8748-# func_lo2o object
8749-func_lo2o ()
8750-{
8751- case ${1} in
8752- *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
8753- *) func_lo2o_result=${1} ;;
8754- esac
8755-}
8756-
8757-# func_xform libobj-or-source
8758-func_xform ()
8759-{
8760- func_xform_result=${1%.*}.lo
8761-}
8762-
8763-# func_arith arithmetic-term...
8764-func_arith ()
8765-{
8766- func_arith_result=$(( $* ))
8767-}
8768-
8769-# func_len string
8770-# STRING may not start with a hyphen.
8771-func_len ()
8772-{
8773- func_len_result=${#1}
8774-}
8775-
8776-_LT_EOF
8777- ;;
8778- *) # Bourne compatible functions.
8779- cat << \_LT_EOF >> "$cfgfile"
8780-
8781-# func_dirname file append nondir_replacement
8782-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
8783-# otherwise set result to NONDIR_REPLACEMENT.
8784-func_dirname ()
8785-{
8786- # Extract subdirectory from the argument.
8787- func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
8788- if test "X$func_dirname_result" = "X${1}"; then
8789- func_dirname_result="${3}"
8790- else
8791- func_dirname_result="$func_dirname_result${2}"
8792- fi
8793-}
8794-
8795-# func_basename file
8796-func_basename ()
8797-{
8798- func_basename_result=`$ECHO "${1}" | $SED "$basename"`
8799-}
8800-
8801-
8802-# func_stripname prefix suffix name
8803-# strip PREFIX and SUFFIX off of NAME.
8804-# PREFIX and SUFFIX must not contain globbing or regex special
8805-# characters, hashes, percent signs, but SUFFIX may contain a leading
8806-# dot (in which case that matches only a dot).
8807-# func_strip_suffix prefix name
8808-func_stripname ()
8809-{
8810- case ${2} in
8811- .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
8812- *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
8813- esac
8814-}
8815-
8816-# sed scripts:
8817-my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q'
8818-my_sed_long_arg='1s/^-[^=]*=//'
8819-
8820-# func_opt_split
8821-func_opt_split ()
8822-{
8823- func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"`
8824- func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"`
8825-}
8826-
8827-# func_lo2o object
8828-func_lo2o ()
8829-{
8830- func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
8831-}
8832-
8833-# func_xform libobj-or-source
8834-func_xform ()
8835-{
8836- func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
8837-}
8838-
8839-# func_arith arithmetic-term...
8840-func_arith ()
8841-{
8842- func_arith_result=`expr "$@"`
8843-}
8844-
8845-# func_len string
8846-# STRING may not start with a hyphen.
8847-func_len ()
8848-{
8849- func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len`
8850-}
8851-
8852-_LT_EOF
8853-esac
8854-
8855-case $lt_shell_append in
8856- yes)
8857- cat << \_LT_EOF >> "$cfgfile"
8858-
8859-# func_append var value
8860-# Append VALUE to the end of shell variable VAR.
8861-func_append ()
8862-{
8863- eval "$1+=\$2"
8864-}
8865-_LT_EOF
8866- ;;
8867- *)
8868- cat << \_LT_EOF >> "$cfgfile"
8869-
8870-# func_append var value
8871-# Append VALUE to the end of shell variable VAR.
8872-func_append ()
8873-{
8874- eval "$1=\$$1\$2"
8875-}
8876-
8877-_LT_EOF
8878- ;;
8879- esac
8880+ sed '$q' "$ltmain" >> "$cfgfile" \
8881+ || (rm -f "$cfgfile"; exit 1)
8882
8883+ if test x"$xsi_shell" = xyes; then
8884+ sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
8885+func_dirname ()\
8886+{\
8887+\ case ${1} in\
8888+\ */*) func_dirname_result="${1%/*}${2}" ;;\
8889+\ * ) func_dirname_result="${3}" ;;\
8890+\ esac\
8891+} # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \
8892+ && mv -f "$cfgfile.tmp" "$cfgfile" \
8893+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
8894+test 0 -eq $? || _lt_function_replace_fail=:
8895+
8896+
8897+ sed -e '/^func_basename ()$/,/^} # func_basename /c\
8898+func_basename ()\
8899+{\
8900+\ func_basename_result="${1##*/}"\
8901+} # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \
8902+ && mv -f "$cfgfile.tmp" "$cfgfile" \
8903+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
8904+test 0 -eq $? || _lt_function_replace_fail=:
8905+
8906+
8907+ sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\
8908+func_dirname_and_basename ()\
8909+{\
8910+\ case ${1} in\
8911+\ */*) func_dirname_result="${1%/*}${2}" ;;\
8912+\ * ) func_dirname_result="${3}" ;;\
8913+\ esac\
8914+\ func_basename_result="${1##*/}"\
8915+} # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \
8916+ && mv -f "$cfgfile.tmp" "$cfgfile" \
8917+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
8918+test 0 -eq $? || _lt_function_replace_fail=:
8919+
8920+
8921+ sed -e '/^func_stripname ()$/,/^} # func_stripname /c\
8922+func_stripname ()\
8923+{\
8924+\ # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\
8925+\ # positional parameters, so assign one to ordinary parameter first.\
8926+\ func_stripname_result=${3}\
8927+\ func_stripname_result=${func_stripname_result#"${1}"}\
8928+\ func_stripname_result=${func_stripname_result%"${2}"}\
8929+} # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \
8930+ && mv -f "$cfgfile.tmp" "$cfgfile" \
8931+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
8932+test 0 -eq $? || _lt_function_replace_fail=:
8933+
8934+
8935+ sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\
8936+func_split_long_opt ()\
8937+{\
8938+\ func_split_long_opt_name=${1%%=*}\
8939+\ func_split_long_opt_arg=${1#*=}\
8940+} # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \
8941+ && mv -f "$cfgfile.tmp" "$cfgfile" \
8942+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
8943+test 0 -eq $? || _lt_function_replace_fail=:
8944+
8945+
8946+ sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\
8947+func_split_short_opt ()\
8948+{\
8949+\ func_split_short_opt_arg=${1#??}\
8950+\ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\
8951+} # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \
8952+ && mv -f "$cfgfile.tmp" "$cfgfile" \
8953+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
8954+test 0 -eq $? || _lt_function_replace_fail=:
8955+
8956+
8957+ sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\
8958+func_lo2o ()\
8959+{\
8960+\ case ${1} in\
8961+\ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\
8962+\ *) func_lo2o_result=${1} ;;\
8963+\ esac\
8964+} # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \
8965+ && mv -f "$cfgfile.tmp" "$cfgfile" \
8966+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
8967+test 0 -eq $? || _lt_function_replace_fail=:
8968+
8969+
8970+ sed -e '/^func_xform ()$/,/^} # func_xform /c\
8971+func_xform ()\
8972+{\
8973+ func_xform_result=${1%.*}.lo\
8974+} # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \
8975+ && mv -f "$cfgfile.tmp" "$cfgfile" \
8976+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
8977+test 0 -eq $? || _lt_function_replace_fail=:
8978+
8979+
8980+ sed -e '/^func_arith ()$/,/^} # func_arith /c\
8981+func_arith ()\
8982+{\
8983+ func_arith_result=$(( $* ))\
8984+} # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \
8985+ && mv -f "$cfgfile.tmp" "$cfgfile" \
8986+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
8987+test 0 -eq $? || _lt_function_replace_fail=:
8988+
8989+
8990+ sed -e '/^func_len ()$/,/^} # func_len /c\
8991+func_len ()\
8992+{\
8993+ func_len_result=${#1}\
8994+} # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \
8995+ && mv -f "$cfgfile.tmp" "$cfgfile" \
8996+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
8997+test 0 -eq $? || _lt_function_replace_fail=:
8998+
8999+fi
9000+
9001+if test x"$lt_shell_append" = xyes; then
9002+ sed -e '/^func_append ()$/,/^} # func_append /c\
9003+func_append ()\
9004+{\
9005+ eval "${1}+=\\${2}"\
9006+} # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \
9007+ && mv -f "$cfgfile.tmp" "$cfgfile" \
9008+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
9009+test 0 -eq $? || _lt_function_replace_fail=:
9010+
9011+
9012+ sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\
9013+func_append_quoted ()\
9014+{\
9015+\ func_quote_for_eval "${2}"\
9016+\ eval "${1}+=\\\\ \\$func_quote_for_eval_result"\
9017+} # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \
9018+ && mv -f "$cfgfile.tmp" "$cfgfile" \
9019+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
9020+test 0 -eq $? || _lt_function_replace_fail=:
9021+
9022+
9023+ # Save a `func_append' function call where possible by direct use of '+='
9024+ sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
9025+ && mv -f "$cfgfile.tmp" "$cfgfile" \
9026+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
9027+ test 0 -eq $? || _lt_function_replace_fail=:
9028+else
9029+ # Save a `func_append' function call even when '+=' is not available
9030+ sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
9031+ && mv -f "$cfgfile.tmp" "$cfgfile" \
9032+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
9033+ test 0 -eq $? || _lt_function_replace_fail=:
9034+fi
9035+
9036+if test x"$_lt_function_replace_fail" = x":"; then
9037+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
9038+$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
9039+fi
9040
9041- sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
9042- || (rm -f "$cfgfile"; exit 1)
9043
9044- mv -f "$cfgfile" "$ofile" ||
9045+ mv -f "$cfgfile" "$ofile" ||
9046 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
9047 chmod +x "$ofile"
9048
9049Index: binutils-2.22/opcodes/configure
9050===================================================================
9051--- binutils-2.22.orig/opcodes/configure
9052+++ binutils-2.22/opcodes/configure
9053@@ -647,6 +647,9 @@ OTOOL
9054 LIPO
9055 NMEDIT
9056 DSYMUTIL
9057+MANIFEST_TOOL
9058+ac_ct_AR
9059+DLLTOOL
9060 OBJDUMP
9061 LN_S
9062 NM
9063@@ -759,6 +762,7 @@ enable_static
9064 with_pic
9065 enable_fast_install
9066 with_gnu_ld
9067+with_libtool_sysroot
9068 enable_libtool_lock
9069 enable_targets
9070 enable_werror
9071@@ -1417,6 +1421,8 @@ Optional Packages:
9072 --with-pic try to use only PIC/non-PIC objects [default=use
9073 both]
9074 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
9075+ --with-libtool-sysroot=DIR Search for dependent libraries within DIR
9076+ (or the compiler's sysroot if not specified).
9077
9078 Some influential environment variables:
9079 CC C compiler command
9080@@ -5112,8 +5118,8 @@ esac
9081
9082
9083
9084-macro_version='2.2.7a'
9085-macro_revision='1.3134'
9086+macro_version='2.4'
9087+macro_revision='1.3293'
9088
9089
9090
9091@@ -5153,7 +5159,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
9092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
9093 $as_echo_n "checking how to print strings... " >&6; }
9094 # Test print first, because it will be a builtin if present.
9095-if test "X`print -r -- -n 2>/dev/null`" = X-n && \
9096+if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
9097 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
9098 ECHO='print -r --'
9099 elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
9100@@ -5839,8 +5845,8 @@ $as_echo_n "checking whether the shell u
9101 # Try some XSI features
9102 xsi_shell=no
9103 ( _lt_dummy="a/b/c"
9104- test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
9105- = c,a/b,, \
9106+ test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
9107+ = c,a/b,b/c, \
9108 && eval 'test $(( 1 + 1 )) -eq 2 \
9109 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
9110 && xsi_shell=yes
9111@@ -5889,6 +5895,80 @@ esac
9112
9113
9114
9115+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
9116+$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
9117+if test "${lt_cv_to_host_file_cmd+set}" = set; then :
9118+ $as_echo_n "(cached) " >&6
9119+else
9120+ case $host in
9121+ *-*-mingw* )
9122+ case $build in
9123+ *-*-mingw* ) # actually msys
9124+ lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
9125+ ;;
9126+ *-*-cygwin* )
9127+ lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
9128+ ;;
9129+ * ) # otherwise, assume *nix
9130+ lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
9131+ ;;
9132+ esac
9133+ ;;
9134+ *-*-cygwin* )
9135+ case $build in
9136+ *-*-mingw* ) # actually msys
9137+ lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
9138+ ;;
9139+ *-*-cygwin* )
9140+ lt_cv_to_host_file_cmd=func_convert_file_noop
9141+ ;;
9142+ * ) # otherwise, assume *nix
9143+ lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
9144+ ;;
9145+ esac
9146+ ;;
9147+ * ) # unhandled hosts (and "normal" native builds)
9148+ lt_cv_to_host_file_cmd=func_convert_file_noop
9149+ ;;
9150+esac
9151+
9152+fi
9153+
9154+to_host_file_cmd=$lt_cv_to_host_file_cmd
9155+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
9156+$as_echo "$lt_cv_to_host_file_cmd" >&6; }
9157+
9158+
9159+
9160+
9161+
9162+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
9163+$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
9164+if test "${lt_cv_to_tool_file_cmd+set}" = set; then :
9165+ $as_echo_n "(cached) " >&6
9166+else
9167+ #assume ordinary cross tools, or native build.
9168+lt_cv_to_tool_file_cmd=func_convert_file_noop
9169+case $host in
9170+ *-*-mingw* )
9171+ case $build in
9172+ *-*-mingw* ) # actually msys
9173+ lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
9174+ ;;
9175+ esac
9176+ ;;
9177+esac
9178+
9179+fi
9180+
9181+to_tool_file_cmd=$lt_cv_to_tool_file_cmd
9182+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
9183+$as_echo "$lt_cv_to_tool_file_cmd" >&6; }
9184+
9185+
9186+
9187+
9188+
9189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
9190 $as_echo_n "checking for $LD option to reload object files... " >&6; }
9191 if test "${lt_cv_ld_reload_flag+set}" = set; then :
9192@@ -5905,6 +5985,11 @@ case $reload_flag in
9193 esac
9194 reload_cmds='$LD$reload_flag -o $output$reload_objs'
9195 case $host_os in
9196+ cygwin* | mingw* | pw32* | cegcc*)
9197+ if test "$GCC" != yes; then
9198+ reload_cmds=false
9199+ fi
9200+ ;;
9201 darwin*)
9202 if test "$GCC" = yes; then
9203 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
9204@@ -6073,7 +6158,8 @@ mingw* | pw32*)
9205 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
9206 lt_cv_file_magic_cmd='func_win32_libid'
9207 else
9208- lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
9209+ # Keep this pattern in sync with the one in func_win32_libid.
9210+ lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
9211 lt_cv_file_magic_cmd='$OBJDUMP -f'
9212 fi
9213 ;;
9214@@ -6227,6 +6313,21 @@ esac
9215 fi
9216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
9217 $as_echo "$lt_cv_deplibs_check_method" >&6; }
9218+
9219+file_magic_glob=
9220+want_nocaseglob=no
9221+if test "$build" = "$host"; then
9222+ case $host_os in
9223+ mingw* | pw32*)
9224+ if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
9225+ want_nocaseglob=yes
9226+ else
9227+ file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
9228+ fi
9229+ ;;
9230+ esac
9231+fi
9232+
9233 file_magic_cmd=$lt_cv_file_magic_cmd
9234 deplibs_check_method=$lt_cv_deplibs_check_method
9235 test -z "$deplibs_check_method" && deplibs_check_method=unknown
9236@@ -6242,9 +6343,162 @@ test -z "$deplibs_check_method" && depli
9237
9238
9239
9240+
9241+
9242+
9243+
9244+
9245+
9246+
9247+
9248+
9249+
9250 if test -n "$ac_tool_prefix"; then
9251- # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
9252-set dummy ${ac_tool_prefix}ar; ac_word=$2
9253+ # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
9254+set dummy ${ac_tool_prefix}dlltool; ac_word=$2
9255+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9256+$as_echo_n "checking for $ac_word... " >&6; }
9257+if test "${ac_cv_prog_DLLTOOL+set}" = set; then :
9258+ $as_echo_n "(cached) " >&6
9259+else
9260+ if test -n "$DLLTOOL"; then
9261+ ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
9262+else
9263+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9264+for as_dir in $PATH
9265+do
9266+ IFS=$as_save_IFS
9267+ test -z "$as_dir" && as_dir=.
9268+ for ac_exec_ext in '' $ac_executable_extensions; do
9269+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9270+ ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
9271+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9272+ break 2
9273+ fi
9274+done
9275+ done
9276+IFS=$as_save_IFS
9277+
9278+fi
9279+fi
9280+DLLTOOL=$ac_cv_prog_DLLTOOL
9281+if test -n "$DLLTOOL"; then
9282+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
9283+$as_echo "$DLLTOOL" >&6; }
9284+else
9285+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9286+$as_echo "no" >&6; }
9287+fi
9288+
9289+
9290+fi
9291+if test -z "$ac_cv_prog_DLLTOOL"; then
9292+ ac_ct_DLLTOOL=$DLLTOOL
9293+ # Extract the first word of "dlltool", so it can be a program name with args.
9294+set dummy dlltool; ac_word=$2
9295+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9296+$as_echo_n "checking for $ac_word... " >&6; }
9297+if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then :
9298+ $as_echo_n "(cached) " >&6
9299+else
9300+ if test -n "$ac_ct_DLLTOOL"; then
9301+ ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
9302+else
9303+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9304+for as_dir in $PATH
9305+do
9306+ IFS=$as_save_IFS
9307+ test -z "$as_dir" && as_dir=.
9308+ for ac_exec_ext in '' $ac_executable_extensions; do
9309+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9310+ ac_cv_prog_ac_ct_DLLTOOL="dlltool"
9311+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9312+ break 2
9313+ fi
9314+done
9315+ done
9316+IFS=$as_save_IFS
9317+
9318+fi
9319+fi
9320+ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
9321+if test -n "$ac_ct_DLLTOOL"; then
9322+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
9323+$as_echo "$ac_ct_DLLTOOL" >&6; }
9324+else
9325+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9326+$as_echo "no" >&6; }
9327+fi
9328+
9329+ if test "x$ac_ct_DLLTOOL" = x; then
9330+ DLLTOOL="false"
9331+ else
9332+ case $cross_compiling:$ac_tool_warned in
9333+yes:)
9334+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9335+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9336+ac_tool_warned=yes ;;
9337+esac
9338+ DLLTOOL=$ac_ct_DLLTOOL
9339+ fi
9340+else
9341+ DLLTOOL="$ac_cv_prog_DLLTOOL"
9342+fi
9343+
9344+test -z "$DLLTOOL" && DLLTOOL=dlltool
9345+
9346+
9347+
9348+
9349+
9350+
9351+
9352+
9353+
9354+
9355+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
9356+$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
9357+if test "${lt_cv_sharedlib_from_linklib_cmd+set}" = set; then :
9358+ $as_echo_n "(cached) " >&6
9359+else
9360+ lt_cv_sharedlib_from_linklib_cmd='unknown'
9361+
9362+case $host_os in
9363+cygwin* | mingw* | pw32* | cegcc*)
9364+ # two different shell functions defined in ltmain.sh
9365+ # decide which to use based on capabilities of $DLLTOOL
9366+ case `$DLLTOOL --help 2>&1` in
9367+ *--identify-strict*)
9368+ lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
9369+ ;;
9370+ *)
9371+ lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
9372+ ;;
9373+ esac
9374+ ;;
9375+*)
9376+ # fallback: assume linklib IS sharedlib
9377+ lt_cv_sharedlib_from_linklib_cmd="$ECHO"
9378+ ;;
9379+esac
9380+
9381+fi
9382+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
9383+$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
9384+sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
9385+test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
9386+
9387+
9388+
9389+
9390+
9391+
9392+
9393+if test -n "$ac_tool_prefix"; then
9394+ for ac_prog in ar
9395+ do
9396+ # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
9397+set dummy $ac_tool_prefix$ac_prog; ac_word=$2
9398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9399 $as_echo_n "checking for $ac_word... " >&6; }
9400 if test "${ac_cv_prog_AR+set}" = set; then :
9401@@ -6260,7 +6514,7 @@ do
9402 test -z "$as_dir" && as_dir=.
9403 for ac_exec_ext in '' $ac_executable_extensions; do
9404 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9405- ac_cv_prog_AR="${ac_tool_prefix}ar"
9406+ ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
9407 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9408 break 2
9409 fi
9410@@ -6280,11 +6534,15 @@ $as_echo "no" >&6; }
9411 fi
9412
9413
9414+ test -n "$AR" && break
9415+ done
9416 fi
9417-if test -z "$ac_cv_prog_AR"; then
9418+if test -z "$AR"; then
9419 ac_ct_AR=$AR
9420- # Extract the first word of "ar", so it can be a program name with args.
9421-set dummy ar; ac_word=$2
9422+ for ac_prog in ar
9423+do
9424+ # Extract the first word of "$ac_prog", so it can be a program name with args.
9425+set dummy $ac_prog; ac_word=$2
9426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9427 $as_echo_n "checking for $ac_word... " >&6; }
9428 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
9429@@ -6300,7 +6558,7 @@ do
9430 test -z "$as_dir" && as_dir=.
9431 for ac_exec_ext in '' $ac_executable_extensions; do
9432 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9433- ac_cv_prog_ac_ct_AR="ar"
9434+ ac_cv_prog_ac_ct_AR="$ac_prog"
9435 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9436 break 2
9437 fi
9438@@ -6319,6 +6577,10 @@ else
9439 $as_echo "no" >&6; }
9440 fi
9441
9442+
9443+ test -n "$ac_ct_AR" && break
9444+done
9445+
9446 if test "x$ac_ct_AR" = x; then
9447 AR="false"
9448 else
9449@@ -6330,12 +6592,11 @@ ac_tool_warned=yes ;;
9450 esac
9451 AR=$ac_ct_AR
9452 fi
9453-else
9454- AR="$ac_cv_prog_AR"
9455 fi
9456
9457-test -z "$AR" && AR=ar
9458-test -z "$AR_FLAGS" && AR_FLAGS=cru
9459+: ${AR=ar}
9460+: ${AR_FLAGS=cru}
9461+
9462
9463
9464
9465@@ -6346,6 +6607,63 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
9466
9467
9468
9469+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
9470+$as_echo_n "checking for archiver @FILE support... " >&6; }
9471+if test "${lt_cv_ar_at_file+set}" = set; then :
9472+ $as_echo_n "(cached) " >&6
9473+else
9474+ lt_cv_ar_at_file=no
9475+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9476+/* end confdefs.h. */
9477+
9478+int
9479+main ()
9480+{
9481+
9482+ ;
9483+ return 0;
9484+}
9485+_ACEOF
9486+if ac_fn_c_try_compile "$LINENO"; then :
9487+ echo conftest.$ac_objext > conftest.lst
9488+ lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
9489+ { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
9490+ (eval $lt_ar_try) 2>&5
9491+ ac_status=$?
9492+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9493+ test $ac_status = 0; }
9494+ if test "$ac_status" -eq 0; then
9495+ # Ensure the archiver fails upon bogus file names.
9496+ rm -f conftest.$ac_objext libconftest.a
9497+ { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
9498+ (eval $lt_ar_try) 2>&5
9499+ ac_status=$?
9500+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9501+ test $ac_status = 0; }
9502+ if test "$ac_status" -ne 0; then
9503+ lt_cv_ar_at_file=@
9504+ fi
9505+ fi
9506+ rm -f conftest.* libconftest.a
9507+
9508+fi
9509+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9510+
9511+fi
9512+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
9513+$as_echo "$lt_cv_ar_at_file" >&6; }
9514+
9515+if test "x$lt_cv_ar_at_file" = xno; then
9516+ archiver_list_spec=
9517+else
9518+ archiver_list_spec=$lt_cv_ar_at_file
9519+fi
9520+
9521+
9522+
9523+
9524+
9525+
9526
9527 if test -n "$ac_tool_prefix"; then
9528 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
9529@@ -6681,8 +6999,8 @@ esac
9530 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
9531
9532 # Transform an extracted symbol line into symbol name and symbol address
9533-lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
9534-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
9535+lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
9536+lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
9537
9538 # Handle CRLF in mingw tool chain
9539 opt_cr=
9540@@ -6718,6 +7036,7 @@ for ac_symprfx in "" "_"; do
9541 else
9542 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
9543 fi
9544+ lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
9545
9546 # Check to see that the pipe works correctly.
9547 pipe_works=no
9548@@ -6759,6 +7078,18 @@ _LT_EOF
9549 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
9550 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
9551 cat <<_LT_EOF > conftest.$ac_ext
9552+/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
9553+#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
9554+/* DATA imports from DLLs on WIN32 con't be const, because runtime
9555+ relocations are performed -- see ld's documentation on pseudo-relocs. */
9556+# define LT_DLSYM_CONST
9557+#elif defined(__osf__)
9558+/* This system does not cope well with relocations in const data. */
9559+# define LT_DLSYM_CONST
9560+#else
9561+# define LT_DLSYM_CONST const
9562+#endif
9563+
9564 #ifdef __cplusplus
9565 extern "C" {
9566 #endif
9567@@ -6770,7 +7101,7 @@ _LT_EOF
9568 cat <<_LT_EOF >> conftest.$ac_ext
9569
9570 /* The mapping between symbol names and symbols. */
9571-const struct {
9572+LT_DLSYM_CONST struct {
9573 const char *name;
9574 void *address;
9575 }
9576@@ -6796,8 +7127,8 @@ static const void *lt_preloaded_setup()
9577 _LT_EOF
9578 # Now try linking the two files.
9579 mv conftest.$ac_objext conftstm.$ac_objext
9580- lt_save_LIBS="$LIBS"
9581- lt_save_CFLAGS="$CFLAGS"
9582+ lt_globsym_save_LIBS=$LIBS
9583+ lt_globsym_save_CFLAGS=$CFLAGS
9584 LIBS="conftstm.$ac_objext"
9585 CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
9586 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
9587@@ -6807,8 +7138,8 @@ _LT_EOF
9588 test $ac_status = 0; } && test -s conftest${ac_exeext}; then
9589 pipe_works=yes
9590 fi
9591- LIBS="$lt_save_LIBS"
9592- CFLAGS="$lt_save_CFLAGS"
9593+ LIBS=$lt_globsym_save_LIBS
9594+ CFLAGS=$lt_globsym_save_CFLAGS
9595 else
9596 echo "cannot find nm_test_func in $nlist" >&5
9597 fi
9598@@ -6845,6 +7176,14 @@ else
9599 $as_echo "ok" >&6; }
9600 fi
9601
9602+# Response file support.
9603+if test "$lt_cv_nm_interface" = "MS dumpbin"; then
9604+ nm_file_list_spec='@'
9605+elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
9606+ nm_file_list_spec='@'
9607+fi
9608+
9609+
9610
9611
9612
9613@@ -6866,6 +7205,47 @@ fi
9614
9615
9616
9617+
9618+
9619+
9620+
9621+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
9622+$as_echo_n "checking for sysroot... " >&6; }
9623+
9624+# Check whether --with-libtool-sysroot was given.
9625+if test "${with_libtool_sysroot+set}" = set; then :
9626+ withval=$with_libtool_sysroot;
9627+else
9628+ with_libtool_sysroot=no
9629+fi
9630+
9631+
9632+lt_sysroot=
9633+case ${with_libtool_sysroot} in #(
9634+ yes)
9635+ if test "$GCC" = yes; then
9636+ lt_sysroot=`$CC --print-sysroot 2>/dev/null`
9637+ fi
9638+ ;; #(
9639+ /*)
9640+ lt_sysroot=`echo "$with_libtool_sysroot" | sed -e "$sed_quote_subst"`
9641+ ;; #(
9642+ no|'')
9643+ ;; #(
9644+ *)
9645+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libtool_sysroot}" >&5
9646+$as_echo "${with_libtool_sysroot}" >&6; }
9647+ as_fn_error "The sysroot must be an absolute path." "$LINENO" 5
9648+ ;;
9649+esac
9650+
9651+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
9652+$as_echo "${lt_sysroot:-no}" >&6; }
9653+
9654+
9655+
9656+
9657+
9658 # Check whether --enable-libtool-lock was given.
9659 if test "${enable_libtool_lock+set}" = set; then :
9660 enableval=$enable_libtool_lock;
9661@@ -7059,6 +7439,123 @@ esac
9662
9663 need_locks="$enable_libtool_lock"
9664
9665+if test -n "$ac_tool_prefix"; then
9666+ # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
9667+set dummy ${ac_tool_prefix}mt; ac_word=$2
9668+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9669+$as_echo_n "checking for $ac_word... " >&6; }
9670+if test "${ac_cv_prog_MANIFEST_TOOL+set}" = set; then :
9671+ $as_echo_n "(cached) " >&6
9672+else
9673+ if test -n "$MANIFEST_TOOL"; then
9674+ ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
9675+else
9676+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9677+for as_dir in $PATH
9678+do
9679+ IFS=$as_save_IFS
9680+ test -z "$as_dir" && as_dir=.
9681+ for ac_exec_ext in '' $ac_executable_extensions; do
9682+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9683+ ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
9684+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9685+ break 2
9686+ fi
9687+done
9688+ done
9689+IFS=$as_save_IFS
9690+
9691+fi
9692+fi
9693+MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
9694+if test -n "$MANIFEST_TOOL"; then
9695+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
9696+$as_echo "$MANIFEST_TOOL" >&6; }
9697+else
9698+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9699+$as_echo "no" >&6; }
9700+fi
9701+
9702+
9703+fi
9704+if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
9705+ ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
9706+ # Extract the first word of "mt", so it can be a program name with args.
9707+set dummy mt; ac_word=$2
9708+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9709+$as_echo_n "checking for $ac_word... " >&6; }
9710+if test "${ac_cv_prog_ac_ct_MANIFEST_TOOL+set}" = set; then :
9711+ $as_echo_n "(cached) " >&6
9712+else
9713+ if test -n "$ac_ct_MANIFEST_TOOL"; then
9714+ ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
9715+else
9716+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9717+for as_dir in $PATH
9718+do
9719+ IFS=$as_save_IFS
9720+ test -z "$as_dir" && as_dir=.
9721+ for ac_exec_ext in '' $ac_executable_extensions; do
9722+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9723+ ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
9724+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9725+ break 2
9726+ fi
9727+done
9728+ done
9729+IFS=$as_save_IFS
9730+
9731+fi
9732+fi
9733+ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
9734+if test -n "$ac_ct_MANIFEST_TOOL"; then
9735+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
9736+$as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
9737+else
9738+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9739+$as_echo "no" >&6; }
9740+fi
9741+
9742+ if test "x$ac_ct_MANIFEST_TOOL" = x; then
9743+ MANIFEST_TOOL=":"
9744+ else
9745+ case $cross_compiling:$ac_tool_warned in
9746+yes:)
9747+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9748+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9749+ac_tool_warned=yes ;;
9750+esac
9751+ MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
9752+ fi
9753+else
9754+ MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
9755+fi
9756+
9757+test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
9758+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
9759+$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
9760+if test "${lt_cv_path_mainfest_tool+set}" = set; then :
9761+ $as_echo_n "(cached) " >&6
9762+else
9763+ lt_cv_path_mainfest_tool=no
9764+ echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
9765+ $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
9766+ cat conftest.err >&5
9767+ if $GREP 'Manifest Tool' conftest.out > /dev/null; then
9768+ lt_cv_path_mainfest_tool=yes
9769+ fi
9770+ rm -f conftest*
9771+fi
9772+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
9773+$as_echo "$lt_cv_path_mainfest_tool" >&6; }
9774+if test "x$lt_cv_path_mainfest_tool" != xyes; then
9775+ MANIFEST_TOOL=:
9776+fi
9777+
9778+
9779+
9780+
9781+
9782
9783 case $host_os in
9784 rhapsody* | darwin*)
9785@@ -7622,6 +8119,8 @@ _LT_EOF
9786 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
9787 echo "$AR cru libconftest.a conftest.o" >&5
9788 $AR cru libconftest.a conftest.o 2>&5
9789+ echo "$RANLIB libconftest.a" >&5
9790+ $RANLIB libconftest.a 2>&5
9791 cat > conftest.c << _LT_EOF
9792 int main() { return 0;}
9793 _LT_EOF
9794@@ -7787,7 +8286,8 @@ fi
9795 LIBTOOL_DEPS="$ltmain"
9796
9797 # Always use our own libtool.
9798-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
9799+LIBTOOL='$(SHELL) $(top_builddir)'
9800+LIBTOOL="$LIBTOOL/${host_alias}-libtool"
9801
9802
9803
9804@@ -7876,7 +8376,7 @@ aix3*)
9805 esac
9806
9807 # Global variables:
9808-ofile=libtool
9809+ofile=${host_alias}-libtool
9810 can_build_shared=yes
9811
9812 # All known linkers require a `.a' archive for static linking (except MSVC,
9813@@ -8174,8 +8674,6 @@ fi
9814 lt_prog_compiler_pic=
9815 lt_prog_compiler_static=
9816
9817-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
9818-$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
9819
9820 if test "$GCC" = yes; then
9821 lt_prog_compiler_wl='-Wl,'
9822@@ -8340,6 +8838,12 @@ $as_echo_n "checking for $compiler optio
9823 lt_prog_compiler_pic='--shared'
9824 lt_prog_compiler_static='--static'
9825 ;;
9826+ nagfor*)
9827+ # NAG Fortran compiler
9828+ lt_prog_compiler_wl='-Wl,-Wl,,'
9829+ lt_prog_compiler_pic='-PIC'
9830+ lt_prog_compiler_static='-Bstatic'
9831+ ;;
9832 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
9833 # Portland Group compilers (*not* the Pentium gcc compiler,
9834 # which looks to be a dead project)
9835@@ -8402,7 +8906,7 @@ $as_echo_n "checking for $compiler optio
9836 lt_prog_compiler_pic='-KPIC'
9837 lt_prog_compiler_static='-Bstatic'
9838 case $cc_basename in
9839- f77* | f90* | f95*)
9840+ f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
9841 lt_prog_compiler_wl='-Qoption ld ';;
9842 *)
9843 lt_prog_compiler_wl='-Wl,';;
9844@@ -8459,13 +8963,17 @@ case $host_os in
9845 lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
9846 ;;
9847 esac
9848-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5
9849-$as_echo "$lt_prog_compiler_pic" >&6; }
9850-
9851-
9852-
9853-
9854
9855+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
9856+$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
9857+if test "${lt_cv_prog_compiler_pic+set}" = set; then :
9858+ $as_echo_n "(cached) " >&6
9859+else
9860+ lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
9861+fi
9862+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
9863+$as_echo "$lt_cv_prog_compiler_pic" >&6; }
9864+lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
9865
9866 #
9867 # Check to make sure the PIC flag actually works.
9868@@ -8526,6 +9034,11 @@ fi
9869
9870
9871
9872+
9873+
9874+
9875+
9876+
9877 #
9878 # Check to make sure the static flag actually works.
9879 #
9880@@ -8876,7 +9389,8 @@ _LT_EOF
9881 allow_undefined_flag=unsupported
9882 always_export_symbols=no
9883 enable_shared_with_static_runtimes=yes
9884- export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
9885+ export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
9886+ exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
9887
9888 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
9889 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
9890@@ -8924,7 +9438,7 @@ _LT_EOF
9891 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
9892 && test "$tmp_diet" = no
9893 then
9894- tmp_addflag=
9895+ tmp_addflag=' $pic_flag'
9896 tmp_sharedflag='-shared'
9897 case $cc_basename,$host_cpu in
9898 pgcc*) # Portland Group C compiler
9899@@ -8975,12 +9489,12 @@ _LT_EOF
9900 whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
9901 hardcode_libdir_flag_spec=
9902 hardcode_libdir_flag_spec_ld='-rpath $libdir'
9903- archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
9904+ archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
9905 if test "x$supports_anon_versioning" = xyes; then
9906 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
9907 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
9908 echo "local: *; };" >> $output_objdir/$libname.ver~
9909- $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
9910+ $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
9911 fi
9912 ;;
9913 esac
9914@@ -8994,8 +9508,8 @@ _LT_EOF
9915 archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
9916 wlarc=
9917 else
9918- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9919- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
9920+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9921+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
9922 fi
9923 ;;
9924
9925@@ -9013,8 +9527,8 @@ _LT_EOF
9926
9927 _LT_EOF
9928 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
9929- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9930- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
9931+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9932+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
9933 else
9934 ld_shlibs=no
9935 fi
9936@@ -9060,8 +9574,8 @@ _LT_EOF
9937
9938 *)
9939 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
9940- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9941- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
9942+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9943+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
9944 else
9945 ld_shlibs=no
9946 fi
9947@@ -9191,7 +9705,13 @@ _LT_EOF
9948 allow_undefined_flag='-berok'
9949 # Determine the default libpath from the value encoded in an
9950 # empty executable.
9951- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9952+ if test "${lt_cv_aix_libpath+set}" = set; then
9953+ aix_libpath=$lt_cv_aix_libpath
9954+else
9955+ if test "${lt_cv_aix_libpath_+set}" = set; then :
9956+ $as_echo_n "(cached) " >&6
9957+else
9958+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9959 /* end confdefs.h. */
9960
9961 int
9962@@ -9204,22 +9724,29 @@ main ()
9963 _ACEOF
9964 if ac_fn_c_try_link "$LINENO"; then :
9965
9966-lt_aix_libpath_sed='
9967- /Import File Strings/,/^$/ {
9968- /^0/ {
9969- s/^0 *\(.*\)$/\1/
9970- p
9971- }
9972- }'
9973-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
9974-# Check for a 64-bit object if we didn't find anything.
9975-if test -z "$aix_libpath"; then
9976- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
9977-fi
9978+ lt_aix_libpath_sed='
9979+ /Import File Strings/,/^$/ {
9980+ /^0/ {
9981+ s/^0 *\([^ ]*\) *$/\1/
9982+ p
9983+ }
9984+ }'
9985+ lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
9986+ # Check for a 64-bit object if we didn't find anything.
9987+ if test -z "$lt_cv_aix_libpath_"; then
9988+ lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
9989+ fi
9990 fi
9991 rm -f core conftest.err conftest.$ac_objext \
9992 conftest$ac_exeext conftest.$ac_ext
9993-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
9994+ if test -z "$lt_cv_aix_libpath_"; then
9995+ lt_cv_aix_libpath_="/usr/lib:/lib"
9996+ fi
9997+
9998+fi
9999+
10000+ aix_libpath=$lt_cv_aix_libpath_
10001+fi
10002
10003 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
10004 archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
10005@@ -9231,7 +9758,13 @@ if test -z "$aix_libpath"; then aix_libp
10006 else
10007 # Determine the default libpath from the value encoded in an
10008 # empty executable.
10009- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10010+ if test "${lt_cv_aix_libpath+set}" = set; then
10011+ aix_libpath=$lt_cv_aix_libpath
10012+else
10013+ if test "${lt_cv_aix_libpath_+set}" = set; then :
10014+ $as_echo_n "(cached) " >&6
10015+else
10016+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10017 /* end confdefs.h. */
10018
10019 int
10020@@ -9244,22 +9777,29 @@ main ()
10021 _ACEOF
10022 if ac_fn_c_try_link "$LINENO"; then :
10023
10024-lt_aix_libpath_sed='
10025- /Import File Strings/,/^$/ {
10026- /^0/ {
10027- s/^0 *\(.*\)$/\1/
10028- p
10029- }
10030- }'
10031-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
10032-# Check for a 64-bit object if we didn't find anything.
10033-if test -z "$aix_libpath"; then
10034- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
10035-fi
10036+ lt_aix_libpath_sed='
10037+ /Import File Strings/,/^$/ {
10038+ /^0/ {
10039+ s/^0 *\([^ ]*\) *$/\1/
10040+ p
10041+ }
10042+ }'
10043+ lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
10044+ # Check for a 64-bit object if we didn't find anything.
10045+ if test -z "$lt_cv_aix_libpath_"; then
10046+ lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
10047+ fi
10048 fi
10049 rm -f core conftest.err conftest.$ac_objext \
10050 conftest$ac_exeext conftest.$ac_ext
10051-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
10052+ if test -z "$lt_cv_aix_libpath_"; then
10053+ lt_cv_aix_libpath_="/usr/lib:/lib"
10054+ fi
10055+
10056+fi
10057+
10058+ aix_libpath=$lt_cv_aix_libpath_
10059+fi
10060
10061 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
10062 # Warning - without using the other run time loading flags,
10063@@ -9304,20 +9844,63 @@ if test -z "$aix_libpath"; then aix_libp
10064 # Microsoft Visual C++.
10065 # hardcode_libdir_flag_spec is actually meaningless, as there is
10066 # no search path for DLLs.
10067- hardcode_libdir_flag_spec=' '
10068- allow_undefined_flag=unsupported
10069- # Tell ltmain to make .lib files, not .a files.
10070- libext=lib
10071- # Tell ltmain to make .dll files, not .so files.
10072- shrext_cmds=".dll"
10073- # FIXME: Setting linknames here is a bad hack.
10074- archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
10075- # The linker will automatically build a .lib file if we build a DLL.
10076- old_archive_from_new_cmds='true'
10077- # FIXME: Should let the user specify the lib program.
10078- old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
10079- fix_srcfile_path='`cygpath -w "$srcfile"`'
10080- enable_shared_with_static_runtimes=yes
10081+ case $cc_basename in
10082+ cl*)
10083+ # Native MSVC
10084+ hardcode_libdir_flag_spec=' '
10085+ allow_undefined_flag=unsupported
10086+ always_export_symbols=yes
10087+ file_list_spec='@'
10088+ # Tell ltmain to make .lib files, not .a files.
10089+ libext=lib
10090+ # Tell ltmain to make .dll files, not .so files.
10091+ shrext_cmds=".dll"
10092+ # FIXME: Setting linknames here is a bad hack.
10093+ archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
10094+ archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
10095+ sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
10096+ else
10097+ sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
10098+ fi~
10099+ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
10100+ linknames='
10101+ # The linker will not automatically build a static lib if we build a DLL.
10102+ # _LT_TAGVAR(old_archive_from_new_cmds, )='true'
10103+ enable_shared_with_static_runtimes=yes
10104+ export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
10105+ # Don't use ranlib
10106+ old_postinstall_cmds='chmod 644 $oldlib'
10107+ postlink_cmds='lt_outputfile="@OUTPUT@"~
10108+ lt_tool_outputfile="@TOOL_OUTPUT@"~
10109+ case $lt_outputfile in
10110+ *.exe|*.EXE) ;;
10111+ *)
10112+ lt_outputfile="$lt_outputfile.exe"
10113+ lt_tool_outputfile="$lt_tool_outputfile.exe"
10114+ ;;
10115+ esac~
10116+ if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
10117+ $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
10118+ $RM "$lt_outputfile.manifest";
10119+ fi'
10120+ ;;
10121+ *)
10122+ # Assume MSVC wrapper
10123+ hardcode_libdir_flag_spec=' '
10124+ allow_undefined_flag=unsupported
10125+ # Tell ltmain to make .lib files, not .a files.
10126+ libext=lib
10127+ # Tell ltmain to make .dll files, not .so files.
10128+ shrext_cmds=".dll"
10129+ # FIXME: Setting linknames here is a bad hack.
10130+ archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
10131+ # The linker will automatically build a .lib file if we build a DLL.
10132+ old_archive_from_new_cmds='true'
10133+ # FIXME: Should let the user specify the lib program.
10134+ old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
10135+ enable_shared_with_static_runtimes=yes
10136+ ;;
10137+ esac
10138 ;;
10139
10140 darwin* | rhapsody*)
10141@@ -9378,7 +9961,7 @@ if test -z "$aix_libpath"; then aix_libp
10142
10143 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
10144 freebsd* | dragonfly*)
10145- archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
10146+ archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
10147 hardcode_libdir_flag_spec='-R$libdir'
10148 hardcode_direct=yes
10149 hardcode_shlibpath_var=no
10150@@ -9386,7 +9969,7 @@ if test -z "$aix_libpath"; then aix_libp
10151
10152 hpux9*)
10153 if test "$GCC" = yes; then
10154- archive_cmds='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
10155+ archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
10156 else
10157 archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
10158 fi
10159@@ -9402,7 +9985,7 @@ if test -z "$aix_libpath"; then aix_libp
10160
10161 hpux10*)
10162 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
10163- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
10164+ archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
10165 else
10166 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
10167 fi
10168@@ -9426,10 +10009,10 @@ if test -z "$aix_libpath"; then aix_libp
10169 archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
10170 ;;
10171 ia64*)
10172- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
10173+ archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
10174 ;;
10175 *)
10176- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
10177+ archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
10178 ;;
10179 esac
10180 else
10181@@ -9508,23 +10091,36 @@ fi
10182
10183 irix5* | irix6* | nonstopux*)
10184 if test "$GCC" = yes; then
10185- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
10186+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
10187 # Try to use the -exported_symbol ld option, if it does not
10188 # work, assume that -exports_file does not work either and
10189 # implicitly export all symbols.
10190- save_LDFLAGS="$LDFLAGS"
10191- LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
10192- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10193+ # This should be the same for all languages, so no per-tag cache variable.
10194+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
10195+$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
10196+if test "${lt_cv_irix_exported_symbol+set}" = set; then :
10197+ $as_echo_n "(cached) " >&6
10198+else
10199+ save_LDFLAGS="$LDFLAGS"
10200+ LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
10201+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10202 /* end confdefs.h. */
10203-int foo(void) {}
10204+int foo (void) { return 0; }
10205 _ACEOF
10206 if ac_fn_c_try_link "$LINENO"; then :
10207- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
10208-
10209+ lt_cv_irix_exported_symbol=yes
10210+else
10211+ lt_cv_irix_exported_symbol=no
10212 fi
10213 rm -f core conftest.err conftest.$ac_objext \
10214 conftest$ac_exeext conftest.$ac_ext
10215- LDFLAGS="$save_LDFLAGS"
10216+ LDFLAGS="$save_LDFLAGS"
10217+fi
10218+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
10219+$as_echo "$lt_cv_irix_exported_symbol" >&6; }
10220+ if test "$lt_cv_irix_exported_symbol" = yes; then
10221+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
10222+ fi
10223 else
10224 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
10225 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
10226@@ -9609,7 +10205,7 @@ rm -f core conftest.err conftest.$ac_obj
10227 osf4* | osf5*) # as osf3* with the addition of -msym flag
10228 if test "$GCC" = yes; then
10229 allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
10230- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
10231+ archive_cmds='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
10232 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
10233 else
10234 allow_undefined_flag=' -expect_unresolved \*'
10235@@ -9628,9 +10224,9 @@ rm -f core conftest.err conftest.$ac_obj
10236 no_undefined_flag=' -z defs'
10237 if test "$GCC" = yes; then
10238 wlarc='${wl}'
10239- archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
10240+ archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
10241 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
10242- $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
10243+ $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
10244 else
10245 case `$CC -V 2>&1` in
10246 *"Compilers 5.0"*)
10247@@ -10206,8 +10802,9 @@ cygwin* | mingw* | pw32* | cegcc*)
10248 need_version=no
10249 need_lib_prefix=no
10250
10251- case $GCC,$host_os in
10252- yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
10253+ case $GCC,$cc_basename in
10254+ yes,*)
10255+ # gcc
10256 library_names_spec='$libname.dll.a'
10257 # DLL is installed to $(libdir)/../bin by postinstall_cmds
10258 postinstall_cmds='base_file=`basename \${file}`~
10259@@ -10240,13 +10837,71 @@ cygwin* | mingw* | pw32* | cegcc*)
10260 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
10261 ;;
10262 esac
10263+ dynamic_linker='Win32 ld.exe'
10264+ ;;
10265+
10266+ *,cl*)
10267+ # Native MSVC
10268+ libname_spec='$name'
10269+ soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
10270+ library_names_spec='${libname}.dll.lib'
10271+
10272+ case $build_os in
10273+ mingw*)
10274+ sys_lib_search_path_spec=
10275+ lt_save_ifs=$IFS
10276+ IFS=';'
10277+ for lt_path in $LIB
10278+ do
10279+ IFS=$lt_save_ifs
10280+ # Let DOS variable expansion print the short 8.3 style file name.
10281+ lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
10282+ sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
10283+ done
10284+ IFS=$lt_save_ifs
10285+ # Convert to MSYS style.
10286+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
10287+ ;;
10288+ cygwin*)
10289+ # Convert to unix form, then to dos form, then back to unix form
10290+ # but this time dos style (no spaces!) so that the unix form looks
10291+ # like /cygdrive/c/PROGRA~1:/cygdr...
10292+ sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
10293+ sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
10294+ sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
10295+ ;;
10296+ *)
10297+ sys_lib_search_path_spec="$LIB"
10298+ if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
10299+ # It is most probably a Windows format PATH.
10300+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
10301+ else
10302+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
10303+ fi
10304+ # FIXME: find the short name or the path components, as spaces are
10305+ # common. (e.g. "Program Files" -> "PROGRA~1")
10306+ ;;
10307+ esac
10308+
10309+ # DLL is installed to $(libdir)/../bin by postinstall_cmds
10310+ postinstall_cmds='base_file=`basename \${file}`~
10311+ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
10312+ dldir=$destdir/`dirname \$dlpath`~
10313+ test -d \$dldir || mkdir -p \$dldir~
10314+ $install_prog $dir/$dlname \$dldir/$dlname'
10315+ postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
10316+ dlpath=$dir/\$dldll~
10317+ $RM \$dlpath'
10318+ shlibpath_overrides_runpath=yes
10319+ dynamic_linker='Win32 link.exe'
10320 ;;
10321
10322 *)
10323+ # Assume MSVC wrapper
10324 library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
10325+ dynamic_linker='Win32 ld.exe'
10326 ;;
10327 esac
10328- dynamic_linker='Win32 ld.exe'
10329 # FIXME: first we should search . and the directory the executable is in
10330 shlibpath_var=PATH
10331 ;;
10332@@ -10338,7 +10993,7 @@ haiku*)
10333 soname_spec='${libname}${release}${shared_ext}$major'
10334 shlibpath_var=LIBRARY_PATH
10335 shlibpath_overrides_runpath=yes
10336- sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/beos/system/lib'
10337+ sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
10338 hardcode_into_libs=yes
10339 ;;
10340
10341@@ -11134,7 +11789,7 @@ else
10342 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
10343 lt_status=$lt_dlunknown
10344 cat > conftest.$ac_ext <<_LT_EOF
10345-#line 11137 "configure"
10346+#line $LINENO "configure"
10347 #include "confdefs.h"
10348
10349 #if HAVE_DLFCN_H
10350@@ -11178,10 +11833,10 @@ else
10351 /* When -fvisbility=hidden is used, assume the code has been annotated
10352 correspondingly for the symbols needed. */
10353 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
10354-void fnord () __attribute__((visibility("default")));
10355+int fnord () __attribute__((visibility("default")));
10356 #endif
10357
10358-void fnord () { int i=42; }
10359+int fnord () { return 42; }
10360 int main ()
10361 {
10362 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
10363@@ -11240,7 +11895,7 @@ else
10364 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
10365 lt_status=$lt_dlunknown
10366 cat > conftest.$ac_ext <<_LT_EOF
10367-#line 11243 "configure"
10368+#line $LINENO "configure"
10369 #include "confdefs.h"
10370
10371 #if HAVE_DLFCN_H
10372@@ -11284,10 +11939,10 @@ else
10373 /* When -fvisbility=hidden is used, assume the code has been annotated
10374 correspondingly for the symbols needed. */
10375 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
10376-void fnord () __attribute__((visibility("default")));
10377+int fnord () __attribute__((visibility("default")));
10378 #endif
10379
10380-void fnord () { int i=42; }
10381+int fnord () { return 42; }
10382 int main ()
10383 {
10384 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
10385@@ -12320,7 +12975,7 @@ if test "$enable_shared" = "yes"; then
10386 # since libbfd may not pull in the entirety of libiberty.
10387 x=`sed -n -e 's/^[ ]*PICFLAG[ ]*=[ ]*//p' < ../libiberty/Makefile | sed -n '$p'`
10388 if test -n "$x"; then
10389- SHARED_LIBADD="-L`pwd`/../libiberty/pic -liberty"
10390+ SHARED_LIBADD="`pwd`/../libiberty/pic/libiberty.a"
10391 fi
10392
10393 case "${host}" in
10394@@ -13283,13 +13938,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_
10395 lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
10396 lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
10397 lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
10398+lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
10399+lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
10400 reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
10401 reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
10402 OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
10403 deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
10404 file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
10405+file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
10406+want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
10407+DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
10408+sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
10409 AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
10410 AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
10411+archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
10412 STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
10413 RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
10414 old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
10415@@ -13304,14 +13966,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$l
10416 lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
10417 lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
10418 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
10419+nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
10420+lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
10421 objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
10422 MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
10423 lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
10424-lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
10425 lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
10426+lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
10427 lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
10428 lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
10429 need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
10430+MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
10431 DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
10432 NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
10433 LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
10434@@ -13344,12 +14009,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcod
10435 hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
10436 inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
10437 link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
10438-fix_srcfile_path='`$ECHO "$fix_srcfile_path" | $SED "$delay_single_quote_subst"`'
10439 always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
10440 export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
10441 exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
10442 include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
10443 prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
10444+postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
10445 file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
10446 variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
10447 need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
10448@@ -13404,8 +14069,13 @@ reload_flag \
10449 OBJDUMP \
10450 deplibs_check_method \
10451 file_magic_cmd \
10452+file_magic_glob \
10453+want_nocaseglob \
10454+DLLTOOL \
10455+sharedlib_from_linklib_cmd \
10456 AR \
10457 AR_FLAGS \
10458+archiver_list_spec \
10459 STRIP \
10460 RANLIB \
10461 CC \
10462@@ -13415,12 +14085,14 @@ lt_cv_sys_global_symbol_pipe \
10463 lt_cv_sys_global_symbol_to_cdecl \
10464 lt_cv_sys_global_symbol_to_c_name_address \
10465 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
10466+nm_file_list_spec \
10467 lt_prog_compiler_no_builtin_flag \
10468-lt_prog_compiler_wl \
10469 lt_prog_compiler_pic \
10470+lt_prog_compiler_wl \
10471 lt_prog_compiler_static \
10472 lt_cv_prog_compiler_c_o \
10473 need_locks \
10474+MANIFEST_TOOL \
10475 DSYMUTIL \
10476 NMEDIT \
10477 LIPO \
10478@@ -13436,7 +14108,6 @@ no_undefined_flag \
10479 hardcode_libdir_flag_spec \
10480 hardcode_libdir_flag_spec_ld \
10481 hardcode_libdir_separator \
10482-fix_srcfile_path \
10483 exclude_expsyms \
10484 include_expsyms \
10485 file_list_spec \
10486@@ -13472,6 +14143,7 @@ module_cmds \
10487 module_expsym_cmds \
10488 export_symbols_cmds \
10489 prelink_cmds \
10490+postlink_cmds \
10491 postinstall_cmds \
10492 postuninstall_cmds \
10493 finish_cmds \
10494@@ -14228,7 +14900,8 @@ $as_echo X"$file" |
10495 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
10496 #
10497 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
10498-# 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
10499+# 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
10500+# Inc.
10501 # Written by Gordon Matzigkeit, 1996
10502 #
10503 # This file is part of GNU Libtool.
10504@@ -14331,19 +15004,42 @@ SP2NL=$lt_lt_SP2NL
10505 # turn newlines into spaces.
10506 NL2SP=$lt_lt_NL2SP
10507
10508+# convert \$build file names to \$host format.
10509+to_host_file_cmd=$lt_cv_to_host_file_cmd
10510+
10511+# convert \$build files to toolchain format.
10512+to_tool_file_cmd=$lt_cv_to_tool_file_cmd
10513+
10514 # An object symbol dumper.
10515 OBJDUMP=$lt_OBJDUMP
10516
10517 # Method to check whether dependent libraries are shared objects.
10518 deplibs_check_method=$lt_deplibs_check_method
10519
10520-# Command to use when deplibs_check_method == "file_magic".
10521+# Command to use when deplibs_check_method = "file_magic".
10522 file_magic_cmd=$lt_file_magic_cmd
10523
10524+# How to find potential files when deplibs_check_method = "file_magic".
10525+file_magic_glob=$lt_file_magic_glob
10526+
10527+# Find potential files using nocaseglob when deplibs_check_method = "file_magic".
10528+want_nocaseglob=$lt_want_nocaseglob
10529+
10530+# DLL creation program.
10531+DLLTOOL=$lt_DLLTOOL
10532+
10533+# Command to associate shared and link libraries.
10534+sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
10535+
10536 # The archiver.
10537 AR=$lt_AR
10538+
10539+# Flags to create an archive.
10540 AR_FLAGS=$lt_AR_FLAGS
10541
10542+# How to feed a file listing to the archiver.
10543+archiver_list_spec=$lt_archiver_list_spec
10544+
10545 # A symbol stripping program.
10546 STRIP=$lt_STRIP
10547
10548@@ -14373,6 +15069,12 @@ global_symbol_to_c_name_address=$lt_lt_c
10549 # Transform the output of nm in a C name address pair when lib prefix is needed.
10550 global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
10551
10552+# Specify filename containing input files for \$NM.
10553+nm_file_list_spec=$lt_nm_file_list_spec
10554+
10555+# The root where to search for dependent libraries,and in which our libraries should be installed.
10556+lt_sysroot=$lt_sysroot
10557+
10558 # The name of the directory that contains temporary libtool files.
10559 objdir=$objdir
10560
10561@@ -14382,6 +15084,9 @@ MAGIC_CMD=$MAGIC_CMD
10562 # Must we lock files when doing compilation?
10563 need_locks=$lt_need_locks
10564
10565+# Manifest tool.
10566+MANIFEST_TOOL=$lt_MANIFEST_TOOL
10567+
10568 # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
10569 DSYMUTIL=$lt_DSYMUTIL
10570
10571@@ -14496,12 +15201,12 @@ with_gcc=$GCC
10572 # Compiler flag to turn off builtin functions.
10573 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
10574
10575-# How to pass a linker flag through the compiler.
10576-wl=$lt_lt_prog_compiler_wl
10577-
10578 # Additional compiler flags for building library objects.
10579 pic_flag=$lt_lt_prog_compiler_pic
10580
10581+# How to pass a linker flag through the compiler.
10582+wl=$lt_lt_prog_compiler_wl
10583+
10584 # Compiler flag to prevent dynamic linking.
10585 link_static_flag=$lt_lt_prog_compiler_static
10586
10587@@ -14588,9 +15293,6 @@ inherit_rpath=$inherit_rpath
10588 # Whether libtool must link a program against all its dependency libraries.
10589 link_all_deplibs=$link_all_deplibs
10590
10591-# Fix the shell variable \$srcfile for the compiler.
10592-fix_srcfile_path=$lt_fix_srcfile_path
10593-
10594 # Set to "yes" if exported symbols are required.
10595 always_export_symbols=$always_export_symbols
10596
10597@@ -14606,6 +15308,9 @@ include_expsyms=$lt_include_expsyms
10598 # Commands necessary for linking programs (against libraries) with templates.
10599 prelink_cmds=$lt_prelink_cmds
10600
10601+# Commands necessary for finishing linking programs.
10602+postlink_cmds=$lt_postlink_cmds
10603+
10604 # Specify filename containing input files.
10605 file_list_spec=$lt_file_list_spec
10606
10607@@ -14638,210 +15343,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
10608 # if finds mixed CR/LF and LF-only lines. Since sed operates in
10609 # text mode, it properly converts lines to CR/LF. This bash problem
10610 # is reportedly fixed, but why not run on old versions too?
10611- sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
10612- || (rm -f "$cfgfile"; exit 1)
10613-
10614- case $xsi_shell in
10615- yes)
10616- cat << \_LT_EOF >> "$cfgfile"
10617-
10618-# func_dirname file append nondir_replacement
10619-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
10620-# otherwise set result to NONDIR_REPLACEMENT.
10621-func_dirname ()
10622-{
10623- case ${1} in
10624- */*) func_dirname_result="${1%/*}${2}" ;;
10625- * ) func_dirname_result="${3}" ;;
10626- esac
10627-}
10628-
10629-# func_basename file
10630-func_basename ()
10631-{
10632- func_basename_result="${1##*/}"
10633-}
10634-
10635-# func_dirname_and_basename file append nondir_replacement
10636-# perform func_basename and func_dirname in a single function
10637-# call:
10638-# dirname: Compute the dirname of FILE. If nonempty,
10639-# add APPEND to the result, otherwise set result
10640-# to NONDIR_REPLACEMENT.
10641-# value returned in "$func_dirname_result"
10642-# basename: Compute filename of FILE.
10643-# value retuned in "$func_basename_result"
10644-# Implementation must be kept synchronized with func_dirname
10645-# and func_basename. For efficiency, we do not delegate to
10646-# those functions but instead duplicate the functionality here.
10647-func_dirname_and_basename ()
10648-{
10649- case ${1} in
10650- */*) func_dirname_result="${1%/*}${2}" ;;
10651- * ) func_dirname_result="${3}" ;;
10652- esac
10653- func_basename_result="${1##*/}"
10654-}
10655-
10656-# func_stripname prefix suffix name
10657-# strip PREFIX and SUFFIX off of NAME.
10658-# PREFIX and SUFFIX must not contain globbing or regex special
10659-# characters, hashes, percent signs, but SUFFIX may contain a leading
10660-# dot (in which case that matches only a dot).
10661-func_stripname ()
10662-{
10663- # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
10664- # positional parameters, so assign one to ordinary parameter first.
10665- func_stripname_result=${3}
10666- func_stripname_result=${func_stripname_result#"${1}"}
10667- func_stripname_result=${func_stripname_result%"${2}"}
10668-}
10669-
10670-# func_opt_split
10671-func_opt_split ()
10672-{
10673- func_opt_split_opt=${1%%=*}
10674- func_opt_split_arg=${1#*=}
10675-}
10676-
10677-# func_lo2o object
10678-func_lo2o ()
10679-{
10680- case ${1} in
10681- *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
10682- *) func_lo2o_result=${1} ;;
10683- esac
10684-}
10685-
10686-# func_xform libobj-or-source
10687-func_xform ()
10688-{
10689- func_xform_result=${1%.*}.lo
10690-}
10691-
10692-# func_arith arithmetic-term...
10693-func_arith ()
10694-{
10695- func_arith_result=$(( $* ))
10696-}
10697-
10698-# func_len string
10699-# STRING may not start with a hyphen.
10700-func_len ()
10701-{
10702- func_len_result=${#1}
10703-}
10704-
10705-_LT_EOF
10706- ;;
10707- *) # Bourne compatible functions.
10708- cat << \_LT_EOF >> "$cfgfile"
10709-
10710-# func_dirname file append nondir_replacement
10711-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
10712-# otherwise set result to NONDIR_REPLACEMENT.
10713-func_dirname ()
10714-{
10715- # Extract subdirectory from the argument.
10716- func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
10717- if test "X$func_dirname_result" = "X${1}"; then
10718- func_dirname_result="${3}"
10719- else
10720- func_dirname_result="$func_dirname_result${2}"
10721- fi
10722-}
10723-
10724-# func_basename file
10725-func_basename ()
10726-{
10727- func_basename_result=`$ECHO "${1}" | $SED "$basename"`
10728-}
10729-
10730-
10731-# func_stripname prefix suffix name
10732-# strip PREFIX and SUFFIX off of NAME.
10733-# PREFIX and SUFFIX must not contain globbing or regex special
10734-# characters, hashes, percent signs, but SUFFIX may contain a leading
10735-# dot (in which case that matches only a dot).
10736-# func_strip_suffix prefix name
10737-func_stripname ()
10738-{
10739- case ${2} in
10740- .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
10741- *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
10742- esac
10743-}
10744-
10745-# sed scripts:
10746-my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q'
10747-my_sed_long_arg='1s/^-[^=]*=//'
10748-
10749-# func_opt_split
10750-func_opt_split ()
10751-{
10752- func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"`
10753- func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"`
10754-}
10755-
10756-# func_lo2o object
10757-func_lo2o ()
10758-{
10759- func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
10760-}
10761-
10762-# func_xform libobj-or-source
10763-func_xform ()
10764-{
10765- func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
10766-}
10767-
10768-# func_arith arithmetic-term...
10769-func_arith ()
10770-{
10771- func_arith_result=`expr "$@"`
10772-}
10773-
10774-# func_len string
10775-# STRING may not start with a hyphen.
10776-func_len ()
10777-{
10778- func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len`
10779-}
10780-
10781-_LT_EOF
10782-esac
10783-
10784-case $lt_shell_append in
10785- yes)
10786- cat << \_LT_EOF >> "$cfgfile"
10787-
10788-# func_append var value
10789-# Append VALUE to the end of shell variable VAR.
10790-func_append ()
10791-{
10792- eval "$1+=\$2"
10793-}
10794-_LT_EOF
10795- ;;
10796- *)
10797- cat << \_LT_EOF >> "$cfgfile"
10798-
10799-# func_append var value
10800-# Append VALUE to the end of shell variable VAR.
10801-func_append ()
10802-{
10803- eval "$1=\$$1\$2"
10804-}
10805-
10806-_LT_EOF
10807- ;;
10808- esac
10809+ sed '$q' "$ltmain" >> "$cfgfile" \
10810+ || (rm -f "$cfgfile"; exit 1)
10811
10812+ if test x"$xsi_shell" = xyes; then
10813+ sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
10814+func_dirname ()\
10815+{\
10816+\ case ${1} in\
10817+\ */*) func_dirname_result="${1%/*}${2}" ;;\
10818+\ * ) func_dirname_result="${3}" ;;\
10819+\ esac\
10820+} # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \
10821+ && mv -f "$cfgfile.tmp" "$cfgfile" \
10822+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
10823+test 0 -eq $? || _lt_function_replace_fail=:
10824+
10825+
10826+ sed -e '/^func_basename ()$/,/^} # func_basename /c\
10827+func_basename ()\
10828+{\
10829+\ func_basename_result="${1##*/}"\
10830+} # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \
10831+ && mv -f "$cfgfile.tmp" "$cfgfile" \
10832+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
10833+test 0 -eq $? || _lt_function_replace_fail=:
10834+
10835+
10836+ sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\
10837+func_dirname_and_basename ()\
10838+{\
10839+\ case ${1} in\
10840+\ */*) func_dirname_result="${1%/*}${2}" ;;\
10841+\ * ) func_dirname_result="${3}" ;;\
10842+\ esac\
10843+\ func_basename_result="${1##*/}"\
10844+} # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \
10845+ && mv -f "$cfgfile.tmp" "$cfgfile" \
10846+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
10847+test 0 -eq $? || _lt_function_replace_fail=:
10848+
10849+
10850+ sed -e '/^func_stripname ()$/,/^} # func_stripname /c\
10851+func_stripname ()\
10852+{\
10853+\ # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\
10854+\ # positional parameters, so assign one to ordinary parameter first.\
10855+\ func_stripname_result=${3}\
10856+\ func_stripname_result=${func_stripname_result#"${1}"}\
10857+\ func_stripname_result=${func_stripname_result%"${2}"}\
10858+} # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \
10859+ && mv -f "$cfgfile.tmp" "$cfgfile" \
10860+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
10861+test 0 -eq $? || _lt_function_replace_fail=:
10862+
10863+
10864+ sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\
10865+func_split_long_opt ()\
10866+{\
10867+\ func_split_long_opt_name=${1%%=*}\
10868+\ func_split_long_opt_arg=${1#*=}\
10869+} # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \
10870+ && mv -f "$cfgfile.tmp" "$cfgfile" \
10871+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
10872+test 0 -eq $? || _lt_function_replace_fail=:
10873+
10874+
10875+ sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\
10876+func_split_short_opt ()\
10877+{\
10878+\ func_split_short_opt_arg=${1#??}\
10879+\ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\
10880+} # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \
10881+ && mv -f "$cfgfile.tmp" "$cfgfile" \
10882+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
10883+test 0 -eq $? || _lt_function_replace_fail=:
10884+
10885+
10886+ sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\
10887+func_lo2o ()\
10888+{\
10889+\ case ${1} in\
10890+\ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\
10891+\ *) func_lo2o_result=${1} ;;\
10892+\ esac\
10893+} # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \
10894+ && mv -f "$cfgfile.tmp" "$cfgfile" \
10895+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
10896+test 0 -eq $? || _lt_function_replace_fail=:
10897+
10898+
10899+ sed -e '/^func_xform ()$/,/^} # func_xform /c\
10900+func_xform ()\
10901+{\
10902+ func_xform_result=${1%.*}.lo\
10903+} # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \
10904+ && mv -f "$cfgfile.tmp" "$cfgfile" \
10905+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
10906+test 0 -eq $? || _lt_function_replace_fail=:
10907+
10908+
10909+ sed -e '/^func_arith ()$/,/^} # func_arith /c\
10910+func_arith ()\
10911+{\
10912+ func_arith_result=$(( $* ))\
10913+} # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \
10914+ && mv -f "$cfgfile.tmp" "$cfgfile" \
10915+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
10916+test 0 -eq $? || _lt_function_replace_fail=:
10917+
10918+
10919+ sed -e '/^func_len ()$/,/^} # func_len /c\
10920+func_len ()\
10921+{\
10922+ func_len_result=${#1}\
10923+} # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \
10924+ && mv -f "$cfgfile.tmp" "$cfgfile" \
10925+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
10926+test 0 -eq $? || _lt_function_replace_fail=:
10927+
10928+fi
10929+
10930+if test x"$lt_shell_append" = xyes; then
10931+ sed -e '/^func_append ()$/,/^} # func_append /c\
10932+func_append ()\
10933+{\
10934+ eval "${1}+=\\${2}"\
10935+} # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \
10936+ && mv -f "$cfgfile.tmp" "$cfgfile" \
10937+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
10938+test 0 -eq $? || _lt_function_replace_fail=:
10939+
10940+
10941+ sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\
10942+func_append_quoted ()\
10943+{\
10944+\ func_quote_for_eval "${2}"\
10945+\ eval "${1}+=\\\\ \\$func_quote_for_eval_result"\
10946+} # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \
10947+ && mv -f "$cfgfile.tmp" "$cfgfile" \
10948+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
10949+test 0 -eq $? || _lt_function_replace_fail=:
10950+
10951+
10952+ # Save a `func_append' function call where possible by direct use of '+='
10953+ sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
10954+ && mv -f "$cfgfile.tmp" "$cfgfile" \
10955+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
10956+ test 0 -eq $? || _lt_function_replace_fail=:
10957+else
10958+ # Save a `func_append' function call even when '+=' is not available
10959+ sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
10960+ && mv -f "$cfgfile.tmp" "$cfgfile" \
10961+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
10962+ test 0 -eq $? || _lt_function_replace_fail=:
10963+fi
10964+
10965+if test x"$_lt_function_replace_fail" = x":"; then
10966+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
10967+$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
10968+fi
10969
10970- sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
10971- || (rm -f "$cfgfile"; exit 1)
10972
10973- mv -f "$cfgfile" "$ofile" ||
10974+ mv -f "$cfgfile" "$ofile" ||
10975 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
10976 chmod +x "$ofile"
10977
10978Index: binutils-2.22/binutils/configure
10979===================================================================
10980--- binutils-2.22.orig/binutils/configure
10981+++ binutils-2.22/binutils/configure
10982@@ -655,8 +655,11 @@ OTOOL
10983 LIPO
10984 NMEDIT
10985 DSYMUTIL
10986+MANIFEST_TOOL
10987 RANLIB
10988+ac_ct_AR
10989 AR
10990+DLLTOOL
10991 OBJDUMP
10992 LN_S
10993 NM
10994@@ -769,6 +772,7 @@ enable_static
10995 with_pic
10996 enable_fast_install
10997 with_gnu_ld
10998+with_libtool_sysroot
10999 enable_libtool_lock
11000 enable_targets
11001 enable_werror
11002@@ -1430,6 +1434,8 @@ Optional Packages:
11003 --with-pic try to use only PIC/non-PIC objects [default=use
11004 both]
11005 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
11006+ --with-libtool-sysroot=DIR Search for dependent libraries within DIR
11007+ (or the compiler's sysroot if not specified).
11008 --with-gnu-ld assume the C compiler uses GNU ld default=no
11009 --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
11010 --without-libiconv-prefix don't search for libiconv in includedir and libdir
11011@@ -5147,8 +5153,8 @@ esac
11012
11013
11014
11015-macro_version='2.2.7a'
11016-macro_revision='1.3134'
11017+macro_version='2.4'
11018+macro_revision='1.3293'
11019
11020
11021
11022@@ -5188,7 +5194,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
11023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
11024 $as_echo_n "checking how to print strings... " >&6; }
11025 # Test print first, because it will be a builtin if present.
11026-if test "X`print -r -- -n 2>/dev/null`" = X-n && \
11027+if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
11028 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
11029 ECHO='print -r --'
11030 elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
11031@@ -5874,8 +5880,8 @@ $as_echo_n "checking whether the shell u
11032 # Try some XSI features
11033 xsi_shell=no
11034 ( _lt_dummy="a/b/c"
11035- test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
11036- = c,a/b,, \
11037+ test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
11038+ = c,a/b,b/c, \
11039 && eval 'test $(( 1 + 1 )) -eq 2 \
11040 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
11041 && xsi_shell=yes
11042@@ -5924,6 +5930,80 @@ esac
11043
11044
11045
11046+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
11047+$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
11048+if test "${lt_cv_to_host_file_cmd+set}" = set; then :
11049+ $as_echo_n "(cached) " >&6
11050+else
11051+ case $host in
11052+ *-*-mingw* )
11053+ case $build in
11054+ *-*-mingw* ) # actually msys
11055+ lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
11056+ ;;
11057+ *-*-cygwin* )
11058+ lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
11059+ ;;
11060+ * ) # otherwise, assume *nix
11061+ lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
11062+ ;;
11063+ esac
11064+ ;;
11065+ *-*-cygwin* )
11066+ case $build in
11067+ *-*-mingw* ) # actually msys
11068+ lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
11069+ ;;
11070+ *-*-cygwin* )
11071+ lt_cv_to_host_file_cmd=func_convert_file_noop
11072+ ;;
11073+ * ) # otherwise, assume *nix
11074+ lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
11075+ ;;
11076+ esac
11077+ ;;
11078+ * ) # unhandled hosts (and "normal" native builds)
11079+ lt_cv_to_host_file_cmd=func_convert_file_noop
11080+ ;;
11081+esac
11082+
11083+fi
11084+
11085+to_host_file_cmd=$lt_cv_to_host_file_cmd
11086+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
11087+$as_echo "$lt_cv_to_host_file_cmd" >&6; }
11088+
11089+
11090+
11091+
11092+
11093+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
11094+$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
11095+if test "${lt_cv_to_tool_file_cmd+set}" = set; then :
11096+ $as_echo_n "(cached) " >&6
11097+else
11098+ #assume ordinary cross tools, or native build.
11099+lt_cv_to_tool_file_cmd=func_convert_file_noop
11100+case $host in
11101+ *-*-mingw* )
11102+ case $build in
11103+ *-*-mingw* ) # actually msys
11104+ lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
11105+ ;;
11106+ esac
11107+ ;;
11108+esac
11109+
11110+fi
11111+
11112+to_tool_file_cmd=$lt_cv_to_tool_file_cmd
11113+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
11114+$as_echo "$lt_cv_to_tool_file_cmd" >&6; }
11115+
11116+
11117+
11118+
11119+
11120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
11121 $as_echo_n "checking for $LD option to reload object files... " >&6; }
11122 if test "${lt_cv_ld_reload_flag+set}" = set; then :
11123@@ -5940,6 +6020,11 @@ case $reload_flag in
11124 esac
11125 reload_cmds='$LD$reload_flag -o $output$reload_objs'
11126 case $host_os in
11127+ cygwin* | mingw* | pw32* | cegcc*)
11128+ if test "$GCC" != yes; then
11129+ reload_cmds=false
11130+ fi
11131+ ;;
11132 darwin*)
11133 if test "$GCC" = yes; then
11134 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
11135@@ -6108,7 +6193,8 @@ mingw* | pw32*)
11136 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
11137 lt_cv_file_magic_cmd='func_win32_libid'
11138 else
11139- lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
11140+ # Keep this pattern in sync with the one in func_win32_libid.
11141+ lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
11142 lt_cv_file_magic_cmd='$OBJDUMP -f'
11143 fi
11144 ;;
11145@@ -6262,6 +6348,21 @@ esac
11146 fi
11147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
11148 $as_echo "$lt_cv_deplibs_check_method" >&6; }
11149+
11150+file_magic_glob=
11151+want_nocaseglob=no
11152+if test "$build" = "$host"; then
11153+ case $host_os in
11154+ mingw* | pw32*)
11155+ if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
11156+ want_nocaseglob=yes
11157+ else
11158+ file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
11159+ fi
11160+ ;;
11161+ esac
11162+fi
11163+
11164 file_magic_cmd=$lt_cv_file_magic_cmd
11165 deplibs_check_method=$lt_cv_deplibs_check_method
11166 test -z "$deplibs_check_method" && deplibs_check_method=unknown
11167@@ -6277,9 +6378,162 @@ test -z "$deplibs_check_method" && depli
11168
11169
11170
11171+
11172+
11173+
11174+
11175+
11176+
11177+
11178+
11179+
11180+
11181 if test -n "$ac_tool_prefix"; then
11182- # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
11183-set dummy ${ac_tool_prefix}ar; ac_word=$2
11184+ # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
11185+set dummy ${ac_tool_prefix}dlltool; ac_word=$2
11186+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11187+$as_echo_n "checking for $ac_word... " >&6; }
11188+if test "${ac_cv_prog_DLLTOOL+set}" = set; then :
11189+ $as_echo_n "(cached) " >&6
11190+else
11191+ if test -n "$DLLTOOL"; then
11192+ ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
11193+else
11194+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11195+for as_dir in $PATH
11196+do
11197+ IFS=$as_save_IFS
11198+ test -z "$as_dir" && as_dir=.
11199+ for ac_exec_ext in '' $ac_executable_extensions; do
11200+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11201+ ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
11202+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11203+ break 2
11204+ fi
11205+done
11206+ done
11207+IFS=$as_save_IFS
11208+
11209+fi
11210+fi
11211+DLLTOOL=$ac_cv_prog_DLLTOOL
11212+if test -n "$DLLTOOL"; then
11213+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
11214+$as_echo "$DLLTOOL" >&6; }
11215+else
11216+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11217+$as_echo "no" >&6; }
11218+fi
11219+
11220+
11221+fi
11222+if test -z "$ac_cv_prog_DLLTOOL"; then
11223+ ac_ct_DLLTOOL=$DLLTOOL
11224+ # Extract the first word of "dlltool", so it can be a program name with args.
11225+set dummy dlltool; ac_word=$2
11226+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11227+$as_echo_n "checking for $ac_word... " >&6; }
11228+if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then :
11229+ $as_echo_n "(cached) " >&6
11230+else
11231+ if test -n "$ac_ct_DLLTOOL"; then
11232+ ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
11233+else
11234+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11235+for as_dir in $PATH
11236+do
11237+ IFS=$as_save_IFS
11238+ test -z "$as_dir" && as_dir=.
11239+ for ac_exec_ext in '' $ac_executable_extensions; do
11240+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11241+ ac_cv_prog_ac_ct_DLLTOOL="dlltool"
11242+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11243+ break 2
11244+ fi
11245+done
11246+ done
11247+IFS=$as_save_IFS
11248+
11249+fi
11250+fi
11251+ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
11252+if test -n "$ac_ct_DLLTOOL"; then
11253+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
11254+$as_echo "$ac_ct_DLLTOOL" >&6; }
11255+else
11256+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11257+$as_echo "no" >&6; }
11258+fi
11259+
11260+ if test "x$ac_ct_DLLTOOL" = x; then
11261+ DLLTOOL="false"
11262+ else
11263+ case $cross_compiling:$ac_tool_warned in
11264+yes:)
11265+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
11266+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
11267+ac_tool_warned=yes ;;
11268+esac
11269+ DLLTOOL=$ac_ct_DLLTOOL
11270+ fi
11271+else
11272+ DLLTOOL="$ac_cv_prog_DLLTOOL"
11273+fi
11274+
11275+test -z "$DLLTOOL" && DLLTOOL=dlltool
11276+
11277+
11278+
11279+
11280+
11281+
11282+
11283+
11284+
11285+
11286+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
11287+$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
11288+if test "${lt_cv_sharedlib_from_linklib_cmd+set}" = set; then :
11289+ $as_echo_n "(cached) " >&6
11290+else
11291+ lt_cv_sharedlib_from_linklib_cmd='unknown'
11292+
11293+case $host_os in
11294+cygwin* | mingw* | pw32* | cegcc*)
11295+ # two different shell functions defined in ltmain.sh
11296+ # decide which to use based on capabilities of $DLLTOOL
11297+ case `$DLLTOOL --help 2>&1` in
11298+ *--identify-strict*)
11299+ lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
11300+ ;;
11301+ *)
11302+ lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
11303+ ;;
11304+ esac
11305+ ;;
11306+*)
11307+ # fallback: assume linklib IS sharedlib
11308+ lt_cv_sharedlib_from_linklib_cmd="$ECHO"
11309+ ;;
11310+esac
11311+
11312+fi
11313+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
11314+$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
11315+sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
11316+test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
11317+
11318+
11319+
11320+
11321+
11322+
11323+
11324+if test -n "$ac_tool_prefix"; then
11325+ for ac_prog in ar
11326+ do
11327+ # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
11328+set dummy $ac_tool_prefix$ac_prog; ac_word=$2
11329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11330 $as_echo_n "checking for $ac_word... " >&6; }
11331 if test "${ac_cv_prog_AR+set}" = set; then :
11332@@ -6295,7 +6549,7 @@ do
11333 test -z "$as_dir" && as_dir=.
11334 for ac_exec_ext in '' $ac_executable_extensions; do
11335 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11336- ac_cv_prog_AR="${ac_tool_prefix}ar"
11337+ ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
11338 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11339 break 2
11340 fi
11341@@ -6315,11 +6569,15 @@ $as_echo "no" >&6; }
11342 fi
11343
11344
11345+ test -n "$AR" && break
11346+ done
11347 fi
11348-if test -z "$ac_cv_prog_AR"; then
11349+if test -z "$AR"; then
11350 ac_ct_AR=$AR
11351- # Extract the first word of "ar", so it can be a program name with args.
11352-set dummy ar; ac_word=$2
11353+ for ac_prog in ar
11354+do
11355+ # Extract the first word of "$ac_prog", so it can be a program name with args.
11356+set dummy $ac_prog; ac_word=$2
11357 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11358 $as_echo_n "checking for $ac_word... " >&6; }
11359 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
11360@@ -6335,7 +6593,7 @@ do
11361 test -z "$as_dir" && as_dir=.
11362 for ac_exec_ext in '' $ac_executable_extensions; do
11363 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11364- ac_cv_prog_ac_ct_AR="ar"
11365+ ac_cv_prog_ac_ct_AR="$ac_prog"
11366 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11367 break 2
11368 fi
11369@@ -6354,6 +6612,10 @@ else
11370 $as_echo "no" >&6; }
11371 fi
11372
11373+
11374+ test -n "$ac_ct_AR" && break
11375+done
11376+
11377 if test "x$ac_ct_AR" = x; then
11378 AR="false"
11379 else
11380@@ -6365,12 +6627,10 @@ ac_tool_warned=yes ;;
11381 esac
11382 AR=$ac_ct_AR
11383 fi
11384-else
11385- AR="$ac_cv_prog_AR"
11386 fi
11387
11388-test -z "$AR" && AR=ar
11389-test -z "$AR_FLAGS" && AR_FLAGS=cru
11390+: ${AR=ar}
11391+: ${AR_FLAGS=cru}
11392
11393
11394
11395@@ -6382,6 +6642,64 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
11396
11397
11398
11399+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
11400+$as_echo_n "checking for archiver @FILE support... " >&6; }
11401+if test "${lt_cv_ar_at_file+set}" = set; then :
11402+ $as_echo_n "(cached) " >&6
11403+else
11404+ lt_cv_ar_at_file=no
11405+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11406+/* end confdefs.h. */
11407+
11408+int
11409+main ()
11410+{
11411+
11412+ ;
11413+ return 0;
11414+}
11415+_ACEOF
11416+if ac_fn_c_try_compile "$LINENO"; then :
11417+ echo conftest.$ac_objext > conftest.lst
11418+ lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
11419+ { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
11420+ (eval $lt_ar_try) 2>&5
11421+ ac_status=$?
11422+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
11423+ test $ac_status = 0; }
11424+ if test "$ac_status" -eq 0; then
11425+ # Ensure the archiver fails upon bogus file names.
11426+ rm -f conftest.$ac_objext libconftest.a
11427+ { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
11428+ (eval $lt_ar_try) 2>&5
11429+ ac_status=$?
11430+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
11431+ test $ac_status = 0; }
11432+ if test "$ac_status" -ne 0; then
11433+ lt_cv_ar_at_file=@
11434+ fi
11435+ fi
11436+ rm -f conftest.* libconftest.a
11437+
11438+fi
11439+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11440+
11441+fi
11442+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
11443+$as_echo "$lt_cv_ar_at_file" >&6; }
11444+
11445+if test "x$lt_cv_ar_at_file" = xno; then
11446+ archiver_list_spec=
11447+else
11448+ archiver_list_spec=$lt_cv_ar_at_file
11449+fi
11450+
11451+
11452+
11453+
11454+
11455+
11456+
11457 if test -n "$ac_tool_prefix"; then
11458 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
11459 set dummy ${ac_tool_prefix}strip; ac_word=$2
11460@@ -6716,8 +7034,8 @@ esac
11461 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
11462
11463 # Transform an extracted symbol line into symbol name and symbol address
11464-lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
11465-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
11466+lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
11467+lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
11468
11469 # Handle CRLF in mingw tool chain
11470 opt_cr=
11471@@ -6753,6 +7071,7 @@ for ac_symprfx in "" "_"; do
11472 else
11473 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
11474 fi
11475+ lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
11476
11477 # Check to see that the pipe works correctly.
11478 pipe_works=no
11479@@ -6794,6 +7113,18 @@ _LT_EOF
11480 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
11481 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
11482 cat <<_LT_EOF > conftest.$ac_ext
11483+/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
11484+#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
11485+/* DATA imports from DLLs on WIN32 con't be const, because runtime
11486+ relocations are performed -- see ld's documentation on pseudo-relocs. */
11487+# define LT_DLSYM_CONST
11488+#elif defined(__osf__)
11489+/* This system does not cope well with relocations in const data. */
11490+# define LT_DLSYM_CONST
11491+#else
11492+# define LT_DLSYM_CONST const
11493+#endif
11494+
11495 #ifdef __cplusplus
11496 extern "C" {
11497 #endif
11498@@ -6805,7 +7136,7 @@ _LT_EOF
11499 cat <<_LT_EOF >> conftest.$ac_ext
11500
11501 /* The mapping between symbol names and symbols. */
11502-const struct {
11503+LT_DLSYM_CONST struct {
11504 const char *name;
11505 void *address;
11506 }
11507@@ -6831,8 +7162,8 @@ static const void *lt_preloaded_setup()
11508 _LT_EOF
11509 # Now try linking the two files.
11510 mv conftest.$ac_objext conftstm.$ac_objext
11511- lt_save_LIBS="$LIBS"
11512- lt_save_CFLAGS="$CFLAGS"
11513+ lt_globsym_save_LIBS=$LIBS
11514+ lt_globsym_save_CFLAGS=$CFLAGS
11515 LIBS="conftstm.$ac_objext"
11516 CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
11517 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
11518@@ -6842,8 +7173,8 @@ _LT_EOF
11519 test $ac_status = 0; } && test -s conftest${ac_exeext}; then
11520 pipe_works=yes
11521 fi
11522- LIBS="$lt_save_LIBS"
11523- CFLAGS="$lt_save_CFLAGS"
11524+ LIBS=$lt_globsym_save_LIBS
11525+ CFLAGS=$lt_globsym_save_CFLAGS
11526 else
11527 echo "cannot find nm_test_func in $nlist" >&5
11528 fi
11529@@ -6880,6 +7211,19 @@ else
11530 $as_echo "ok" >&6; }
11531 fi
11532
11533+# Response file support.
11534+if test "$lt_cv_nm_interface" = "MS dumpbin"; then
11535+ nm_file_list_spec='@'
11536+elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
11537+ nm_file_list_spec='@'
11538+fi
11539+
11540+
11541+
11542+
11543+
11544+
11545+
11546
11547
11548
11549@@ -6900,6 +7244,42 @@ fi
11550
11551
11552
11553+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
11554+$as_echo_n "checking for sysroot... " >&6; }
11555+
11556+# Check whether --with-libtool-sysroot was given.
11557+if test "${with_libtool_sysroot+set}" = set; then :
11558+ withval=$with_libtool_sysroot;
11559+else
11560+ with_libtool_sysroot=no
11561+fi
11562+
11563+
11564+lt_sysroot=
11565+case ${with_libtool_sysroot} in #(
11566+ yes)
11567+ if test "$GCC" = yes; then
11568+ lt_sysroot=`$CC --print-sysroot 2>/dev/null`
11569+ fi
11570+ ;; #(
11571+ /*)
11572+ lt_sysroot=`echo "$with_libtool_sysroot" | sed -e "$sed_quote_subst"`
11573+ ;; #(
11574+ no|'')
11575+ ;; #(
11576+ *)
11577+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libtool_sysroot}" >&5
11578+$as_echo "${with_libtool_sysroot}" >&6; }
11579+ as_fn_error "The sysroot must be an absolute path." "$LINENO" 5
11580+ ;;
11581+esac
11582+
11583+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
11584+$as_echo "${lt_sysroot:-no}" >&6; }
11585+
11586+
11587+
11588+
11589
11590 # Check whether --enable-libtool-lock was given.
11591 if test "${enable_libtool_lock+set}" = set; then :
11592@@ -7094,6 +7474,123 @@ esac
11593
11594 need_locks="$enable_libtool_lock"
11595
11596+if test -n "$ac_tool_prefix"; then
11597+ # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
11598+set dummy ${ac_tool_prefix}mt; ac_word=$2
11599+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11600+$as_echo_n "checking for $ac_word... " >&6; }
11601+if test "${ac_cv_prog_MANIFEST_TOOL+set}" = set; then :
11602+ $as_echo_n "(cached) " >&6
11603+else
11604+ if test -n "$MANIFEST_TOOL"; then
11605+ ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
11606+else
11607+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11608+for as_dir in $PATH
11609+do
11610+ IFS=$as_save_IFS
11611+ test -z "$as_dir" && as_dir=.
11612+ for ac_exec_ext in '' $ac_executable_extensions; do
11613+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11614+ ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
11615+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11616+ break 2
11617+ fi
11618+done
11619+ done
11620+IFS=$as_save_IFS
11621+
11622+fi
11623+fi
11624+MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
11625+if test -n "$MANIFEST_TOOL"; then
11626+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
11627+$as_echo "$MANIFEST_TOOL" >&6; }
11628+else
11629+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11630+$as_echo "no" >&6; }
11631+fi
11632+
11633+
11634+fi
11635+if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
11636+ ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
11637+ # Extract the first word of "mt", so it can be a program name with args.
11638+set dummy mt; ac_word=$2
11639+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11640+$as_echo_n "checking for $ac_word... " >&6; }
11641+if test "${ac_cv_prog_ac_ct_MANIFEST_TOOL+set}" = set; then :
11642+ $as_echo_n "(cached) " >&6
11643+else
11644+ if test -n "$ac_ct_MANIFEST_TOOL"; then
11645+ ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
11646+else
11647+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11648+for as_dir in $PATH
11649+do
11650+ IFS=$as_save_IFS
11651+ test -z "$as_dir" && as_dir=.
11652+ for ac_exec_ext in '' $ac_executable_extensions; do
11653+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11654+ ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
11655+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11656+ break 2
11657+ fi
11658+done
11659+ done
11660+IFS=$as_save_IFS
11661+
11662+fi
11663+fi
11664+ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
11665+if test -n "$ac_ct_MANIFEST_TOOL"; then
11666+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
11667+$as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
11668+else
11669+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11670+$as_echo "no" >&6; }
11671+fi
11672+
11673+ if test "x$ac_ct_MANIFEST_TOOL" = x; then
11674+ MANIFEST_TOOL=":"
11675+ else
11676+ case $cross_compiling:$ac_tool_warned in
11677+yes:)
11678+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
11679+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
11680+ac_tool_warned=yes ;;
11681+esac
11682+ MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
11683+ fi
11684+else
11685+ MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
11686+fi
11687+
11688+test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
11689+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
11690+$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
11691+if test "${lt_cv_path_mainfest_tool+set}" = set; then :
11692+ $as_echo_n "(cached) " >&6
11693+else
11694+ lt_cv_path_mainfest_tool=no
11695+ echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
11696+ $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
11697+ cat conftest.err >&5
11698+ if $GREP 'Manifest Tool' conftest.out > /dev/null; then
11699+ lt_cv_path_mainfest_tool=yes
11700+ fi
11701+ rm -f conftest*
11702+fi
11703+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
11704+$as_echo "$lt_cv_path_mainfest_tool" >&6; }
11705+if test "x$lt_cv_path_mainfest_tool" != xyes; then
11706+ MANIFEST_TOOL=:
11707+fi
11708+
11709+
11710+
11711+
11712+
11713
11714 case $host_os in
11715 rhapsody* | darwin*)
11716@@ -7657,6 +8154,8 @@ _LT_EOF
11717 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
11718 echo "$AR cru libconftest.a conftest.o" >&5
11719 $AR cru libconftest.a conftest.o 2>&5
11720+ echo "$RANLIB libconftest.a" >&5
11721+ $RANLIB libconftest.a 2>&5
11722 cat > conftest.c << _LT_EOF
11723 int main() { return 0;}
11724 _LT_EOF
11725@@ -7852,7 +8351,8 @@ fi
11726 LIBTOOL_DEPS="$ltmain"
11727
11728 # Always use our own libtool.
11729-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
11730+LIBTOOL='$(SHELL) $(top_builddir)'
11731+LIBTOOL="$LIBTOOL/${host_alias}-libtool"
11732
11733
11734
11735@@ -7941,7 +8441,7 @@ aix3*)
11736 esac
11737
11738 # Global variables:
11739-ofile=libtool
11740+ofile=${host_alias}-libtool
11741 can_build_shared=yes
11742
11743 # All known linkers require a `.a' archive for static linking (except MSVC,
11744@@ -8239,8 +8739,6 @@ fi
11745 lt_prog_compiler_pic=
11746 lt_prog_compiler_static=
11747
11748-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
11749-$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
11750
11751 if test "$GCC" = yes; then
11752 lt_prog_compiler_wl='-Wl,'
11753@@ -8405,6 +8903,12 @@ $as_echo_n "checking for $compiler optio
11754 lt_prog_compiler_pic='--shared'
11755 lt_prog_compiler_static='--static'
11756 ;;
11757+ nagfor*)
11758+ # NAG Fortran compiler
11759+ lt_prog_compiler_wl='-Wl,-Wl,,'
11760+ lt_prog_compiler_pic='-PIC'
11761+ lt_prog_compiler_static='-Bstatic'
11762+ ;;
11763 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
11764 # Portland Group compilers (*not* the Pentium gcc compiler,
11765 # which looks to be a dead project)
11766@@ -8467,7 +8971,7 @@ $as_echo_n "checking for $compiler optio
11767 lt_prog_compiler_pic='-KPIC'
11768 lt_prog_compiler_static='-Bstatic'
11769 case $cc_basename in
11770- f77* | f90* | f95*)
11771+ f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
11772 lt_prog_compiler_wl='-Qoption ld ';;
11773 *)
11774 lt_prog_compiler_wl='-Wl,';;
11775@@ -8524,13 +9028,17 @@ case $host_os in
11776 lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
11777 ;;
11778 esac
11779-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5
11780-$as_echo "$lt_prog_compiler_pic" >&6; }
11781-
11782-
11783-
11784-
11785
11786+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
11787+$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
11788+if test "${lt_cv_prog_compiler_pic+set}" = set; then :
11789+ $as_echo_n "(cached) " >&6
11790+else
11791+ lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
11792+fi
11793+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
11794+$as_echo "$lt_cv_prog_compiler_pic" >&6; }
11795+lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
11796
11797 #
11798 # Check to make sure the PIC flag actually works.
11799@@ -8591,6 +9099,11 @@ fi
11800
11801
11802
11803+
11804+
11805+
11806+
11807+
11808 #
11809 # Check to make sure the static flag actually works.
11810 #
11811@@ -8941,7 +9454,8 @@ _LT_EOF
11812 allow_undefined_flag=unsupported
11813 always_export_symbols=no
11814 enable_shared_with_static_runtimes=yes
11815- export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
11816+ export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
11817+ exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
11818
11819 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
11820 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
11821@@ -8989,7 +9503,7 @@ _LT_EOF
11822 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
11823 && test "$tmp_diet" = no
11824 then
11825- tmp_addflag=
11826+ tmp_addflag=' $pic_flag'
11827 tmp_sharedflag='-shared'
11828 case $cc_basename,$host_cpu in
11829 pgcc*) # Portland Group C compiler
11830@@ -9040,12 +9554,12 @@ _LT_EOF
11831 whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
11832 hardcode_libdir_flag_spec=
11833 hardcode_libdir_flag_spec_ld='-rpath $libdir'
11834- archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
11835+ archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
11836 if test "x$supports_anon_versioning" = xyes; then
11837 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
11838 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
11839 echo "local: *; };" >> $output_objdir/$libname.ver~
11840- $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
11841+ $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
11842 fi
11843 ;;
11844 esac
11845@@ -9059,8 +9573,8 @@ _LT_EOF
11846 archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
11847 wlarc=
11848 else
11849- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
11850- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
11851+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
11852+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
11853 fi
11854 ;;
11855
11856@@ -9078,8 +9592,8 @@ _LT_EOF
11857
11858 _LT_EOF
11859 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11860- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
11861- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
11862+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
11863+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
11864 else
11865 ld_shlibs=no
11866 fi
11867@@ -9125,8 +9639,8 @@ _LT_EOF
11868
11869 *)
11870 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11871- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
11872- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
11873+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
11874+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
11875 else
11876 ld_shlibs=no
11877 fi
11878@@ -9256,7 +9770,13 @@ _LT_EOF
11879 allow_undefined_flag='-berok'
11880 # Determine the default libpath from the value encoded in an
11881 # empty executable.
11882- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11883+ if test "${lt_cv_aix_libpath+set}" = set; then
11884+ aix_libpath=$lt_cv_aix_libpath
11885+else
11886+ if test "${lt_cv_aix_libpath_+set}" = set; then :
11887+ $as_echo_n "(cached) " >&6
11888+else
11889+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11890 /* end confdefs.h. */
11891
11892 int
11893@@ -9269,22 +9789,29 @@ main ()
11894 _ACEOF
11895 if ac_fn_c_try_link "$LINENO"; then :
11896
11897-lt_aix_libpath_sed='
11898- /Import File Strings/,/^$/ {
11899- /^0/ {
11900- s/^0 *\(.*\)$/\1/
11901- p
11902- }
11903- }'
11904-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
11905-# Check for a 64-bit object if we didn't find anything.
11906-if test -z "$aix_libpath"; then
11907- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
11908-fi
11909+ lt_aix_libpath_sed='
11910+ /Import File Strings/,/^$/ {
11911+ /^0/ {
11912+ s/^0 *\([^ ]*\) *$/\1/
11913+ p
11914+ }
11915+ }'
11916+ lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
11917+ # Check for a 64-bit object if we didn't find anything.
11918+ if test -z "$lt_cv_aix_libpath_"; then
11919+ lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
11920+ fi
11921 fi
11922 rm -f core conftest.err conftest.$ac_objext \
11923 conftest$ac_exeext conftest.$ac_ext
11924-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
11925+ if test -z "$lt_cv_aix_libpath_"; then
11926+ lt_cv_aix_libpath_="/usr/lib:/lib"
11927+ fi
11928+
11929+fi
11930+
11931+ aix_libpath=$lt_cv_aix_libpath_
11932+fi
11933
11934 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
11935 archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
11936@@ -9296,7 +9823,13 @@ if test -z "$aix_libpath"; then aix_libp
11937 else
11938 # Determine the default libpath from the value encoded in an
11939 # empty executable.
11940- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11941+ if test "${lt_cv_aix_libpath+set}" = set; then
11942+ aix_libpath=$lt_cv_aix_libpath
11943+else
11944+ if test "${lt_cv_aix_libpath_+set}" = set; then :
11945+ $as_echo_n "(cached) " >&6
11946+else
11947+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11948 /* end confdefs.h. */
11949
11950 int
11951@@ -9309,22 +9842,29 @@ main ()
11952 _ACEOF
11953 if ac_fn_c_try_link "$LINENO"; then :
11954
11955-lt_aix_libpath_sed='
11956- /Import File Strings/,/^$/ {
11957- /^0/ {
11958- s/^0 *\(.*\)$/\1/
11959- p
11960- }
11961- }'
11962-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
11963-# Check for a 64-bit object if we didn't find anything.
11964-if test -z "$aix_libpath"; then
11965- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
11966-fi
11967+ lt_aix_libpath_sed='
11968+ /Import File Strings/,/^$/ {
11969+ /^0/ {
11970+ s/^0 *\([^ ]*\) *$/\1/
11971+ p
11972+ }
11973+ }'
11974+ lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
11975+ # Check for a 64-bit object if we didn't find anything.
11976+ if test -z "$lt_cv_aix_libpath_"; then
11977+ lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
11978+ fi
11979 fi
11980 rm -f core conftest.err conftest.$ac_objext \
11981 conftest$ac_exeext conftest.$ac_ext
11982-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
11983+ if test -z "$lt_cv_aix_libpath_"; then
11984+ lt_cv_aix_libpath_="/usr/lib:/lib"
11985+ fi
11986+
11987+fi
11988+
11989+ aix_libpath=$lt_cv_aix_libpath_
11990+fi
11991
11992 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
11993 # Warning - without using the other run time loading flags,
11994@@ -9369,20 +9909,63 @@ if test -z "$aix_libpath"; then aix_libp
11995 # Microsoft Visual C++.
11996 # hardcode_libdir_flag_spec is actually meaningless, as there is
11997 # no search path for DLLs.
11998- hardcode_libdir_flag_spec=' '
11999- allow_undefined_flag=unsupported
12000- # Tell ltmain to make .lib files, not .a files.
12001- libext=lib
12002- # Tell ltmain to make .dll files, not .so files.
12003- shrext_cmds=".dll"
12004- # FIXME: Setting linknames here is a bad hack.
12005- archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
12006- # The linker will automatically build a .lib file if we build a DLL.
12007- old_archive_from_new_cmds='true'
12008- # FIXME: Should let the user specify the lib program.
12009- old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
12010- fix_srcfile_path='`cygpath -w "$srcfile"`'
12011- enable_shared_with_static_runtimes=yes
12012+ case $cc_basename in
12013+ cl*)
12014+ # Native MSVC
12015+ hardcode_libdir_flag_spec=' '
12016+ allow_undefined_flag=unsupported
12017+ always_export_symbols=yes
12018+ file_list_spec='@'
12019+ # Tell ltmain to make .lib files, not .a files.
12020+ libext=lib
12021+ # Tell ltmain to make .dll files, not .so files.
12022+ shrext_cmds=".dll"
12023+ # FIXME: Setting linknames here is a bad hack.
12024+ archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
12025+ archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
12026+ sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
12027+ else
12028+ sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
12029+ fi~
12030+ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
12031+ linknames='
12032+ # The linker will not automatically build a static lib if we build a DLL.
12033+ # _LT_TAGVAR(old_archive_from_new_cmds, )='true'
12034+ enable_shared_with_static_runtimes=yes
12035+ export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
12036+ # Don't use ranlib
12037+ old_postinstall_cmds='chmod 644 $oldlib'
12038+ postlink_cmds='lt_outputfile="@OUTPUT@"~
12039+ lt_tool_outputfile="@TOOL_OUTPUT@"~
12040+ case $lt_outputfile in
12041+ *.exe|*.EXE) ;;
12042+ *)
12043+ lt_outputfile="$lt_outputfile.exe"
12044+ lt_tool_outputfile="$lt_tool_outputfile.exe"
12045+ ;;
12046+ esac~
12047+ if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
12048+ $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
12049+ $RM "$lt_outputfile.manifest";
12050+ fi'
12051+ ;;
12052+ *)
12053+ # Assume MSVC wrapper
12054+ hardcode_libdir_flag_spec=' '
12055+ allow_undefined_flag=unsupported
12056+ # Tell ltmain to make .lib files, not .a files.
12057+ libext=lib
12058+ # Tell ltmain to make .dll files, not .so files.
12059+ shrext_cmds=".dll"
12060+ # FIXME: Setting linknames here is a bad hack.
12061+ archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
12062+ # The linker will automatically build a .lib file if we build a DLL.
12063+ old_archive_from_new_cmds='true'
12064+ # FIXME: Should let the user specify the lib program.
12065+ old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
12066+ enable_shared_with_static_runtimes=yes
12067+ ;;
12068+ esac
12069 ;;
12070
12071 darwin* | rhapsody*)
12072@@ -9443,7 +10026,7 @@ if test -z "$aix_libpath"; then aix_libp
12073
12074 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
12075 freebsd* | dragonfly*)
12076- archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
12077+ archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12078 hardcode_libdir_flag_spec='-R$libdir'
12079 hardcode_direct=yes
12080 hardcode_shlibpath_var=no
12081@@ -9451,7 +10034,7 @@ if test -z "$aix_libpath"; then aix_libp
12082
12083 hpux9*)
12084 if test "$GCC" = yes; then
12085- archive_cmds='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
12086+ archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
12087 else
12088 archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
12089 fi
12090@@ -9467,7 +10050,7 @@ if test -z "$aix_libpath"; then aix_libp
12091
12092 hpux10*)
12093 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
12094- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
12095+ archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
12096 else
12097 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
12098 fi
12099@@ -9491,10 +10074,10 @@ if test -z "$aix_libpath"; then aix_libp
12100 archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
12101 ;;
12102 ia64*)
12103- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
12104+ archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
12105 ;;
12106 *)
12107- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
12108+ archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
12109 ;;
12110 esac
12111 else
12112@@ -9573,23 +10156,36 @@ fi
12113
12114 irix5* | irix6* | nonstopux*)
12115 if test "$GCC" = yes; then
12116- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
12117+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
12118 # Try to use the -exported_symbol ld option, if it does not
12119 # work, assume that -exports_file does not work either and
12120 # implicitly export all symbols.
12121- save_LDFLAGS="$LDFLAGS"
12122- LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
12123- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12124+ # This should be the same for all languages, so no per-tag cache variable.
12125+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
12126+$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
12127+if test "${lt_cv_irix_exported_symbol+set}" = set; then :
12128+ $as_echo_n "(cached) " >&6
12129+else
12130+ save_LDFLAGS="$LDFLAGS"
12131+ LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
12132+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12133 /* end confdefs.h. */
12134-int foo(void) {}
12135+int foo (void) { return 0; }
12136 _ACEOF
12137 if ac_fn_c_try_link "$LINENO"; then :
12138- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
12139-
12140+ lt_cv_irix_exported_symbol=yes
12141+else
12142+ lt_cv_irix_exported_symbol=no
12143 fi
12144 rm -f core conftest.err conftest.$ac_objext \
12145 conftest$ac_exeext conftest.$ac_ext
12146- LDFLAGS="$save_LDFLAGS"
12147+ LDFLAGS="$save_LDFLAGS"
12148+fi
12149+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
12150+$as_echo "$lt_cv_irix_exported_symbol" >&6; }
12151+ if test "$lt_cv_irix_exported_symbol" = yes; then
12152+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
12153+ fi
12154 else
12155 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
12156 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
12157@@ -9674,7 +10270,7 @@ rm -f core conftest.err conftest.$ac_obj
12158 osf4* | osf5*) # as osf3* with the addition of -msym flag
12159 if test "$GCC" = yes; then
12160 allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
12161- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
12162+ archive_cmds='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
12163 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
12164 else
12165 allow_undefined_flag=' -expect_unresolved \*'
12166@@ -9693,9 +10289,9 @@ rm -f core conftest.err conftest.$ac_obj
12167 no_undefined_flag=' -z defs'
12168 if test "$GCC" = yes; then
12169 wlarc='${wl}'
12170- archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
12171+ archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
12172 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12173- $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
12174+ $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
12175 else
12176 case `$CC -V 2>&1` in
12177 *"Compilers 5.0"*)
12178@@ -10271,8 +10867,9 @@ cygwin* | mingw* | pw32* | cegcc*)
12179 need_version=no
12180 need_lib_prefix=no
12181
12182- case $GCC,$host_os in
12183- yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
12184+ case $GCC,$cc_basename in
12185+ yes,*)
12186+ # gcc
12187 library_names_spec='$libname.dll.a'
12188 # DLL is installed to $(libdir)/../bin by postinstall_cmds
12189 postinstall_cmds='base_file=`basename \${file}`~
12190@@ -10305,13 +10902,71 @@ cygwin* | mingw* | pw32* | cegcc*)
12191 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
12192 ;;
12193 esac
12194+ dynamic_linker='Win32 ld.exe'
12195+ ;;
12196+
12197+ *,cl*)
12198+ # Native MSVC
12199+ libname_spec='$name'
12200+ soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
12201+ library_names_spec='${libname}.dll.lib'
12202+
12203+ case $build_os in
12204+ mingw*)
12205+ sys_lib_search_path_spec=
12206+ lt_save_ifs=$IFS
12207+ IFS=';'
12208+ for lt_path in $LIB
12209+ do
12210+ IFS=$lt_save_ifs
12211+ # Let DOS variable expansion print the short 8.3 style file name.
12212+ lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
12213+ sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
12214+ done
12215+ IFS=$lt_save_ifs
12216+ # Convert to MSYS style.
12217+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
12218+ ;;
12219+ cygwin*)
12220+ # Convert to unix form, then to dos form, then back to unix form
12221+ # but this time dos style (no spaces!) so that the unix form looks
12222+ # like /cygdrive/c/PROGRA~1:/cygdr...
12223+ sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
12224+ sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
12225+ sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
12226+ ;;
12227+ *)
12228+ sys_lib_search_path_spec="$LIB"
12229+ if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
12230+ # It is most probably a Windows format PATH.
12231+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
12232+ else
12233+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
12234+ fi
12235+ # FIXME: find the short name or the path components, as spaces are
12236+ # common. (e.g. "Program Files" -> "PROGRA~1")
12237+ ;;
12238+ esac
12239+
12240+ # DLL is installed to $(libdir)/../bin by postinstall_cmds
12241+ postinstall_cmds='base_file=`basename \${file}`~
12242+ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
12243+ dldir=$destdir/`dirname \$dlpath`~
12244+ test -d \$dldir || mkdir -p \$dldir~
12245+ $install_prog $dir/$dlname \$dldir/$dlname'
12246+ postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
12247+ dlpath=$dir/\$dldll~
12248+ $RM \$dlpath'
12249+ shlibpath_overrides_runpath=yes
12250+ dynamic_linker='Win32 link.exe'
12251 ;;
12252
12253 *)
12254+ # Assume MSVC wrapper
12255 library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
12256+ dynamic_linker='Win32 ld.exe'
12257 ;;
12258 esac
12259- dynamic_linker='Win32 ld.exe'
12260 # FIXME: first we should search . and the directory the executable is in
12261 shlibpath_var=PATH
12262 ;;
12263@@ -10403,7 +11058,7 @@ haiku*)
12264 soname_spec='${libname}${release}${shared_ext}$major'
12265 shlibpath_var=LIBRARY_PATH
12266 shlibpath_overrides_runpath=yes
12267- sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/beos/system/lib'
12268+ sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
12269 hardcode_into_libs=yes
12270 ;;
12271
12272@@ -11199,7 +11854,7 @@ else
12273 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
12274 lt_status=$lt_dlunknown
12275 cat > conftest.$ac_ext <<_LT_EOF
12276-#line 11202 "configure"
12277+#line $LINENO "configure"
12278 #include "confdefs.h"
12279
12280 #if HAVE_DLFCN_H
12281@@ -11243,10 +11898,10 @@ else
12282 /* When -fvisbility=hidden is used, assume the code has been annotated
12283 correspondingly for the symbols needed. */
12284 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
12285-void fnord () __attribute__((visibility("default")));
12286+int fnord () __attribute__((visibility("default")));
12287 #endif
12288
12289-void fnord () { int i=42; }
12290+int fnord () { return 42; }
12291 int main ()
12292 {
12293 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
12294@@ -11305,7 +11960,7 @@ else
12295 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
12296 lt_status=$lt_dlunknown
12297 cat > conftest.$ac_ext <<_LT_EOF
12298-#line 11308 "configure"
12299+#line $LINENO "configure"
12300 #include "confdefs.h"
12301
12302 #if HAVE_DLFCN_H
12303@@ -11349,10 +12004,10 @@ else
12304 /* When -fvisbility=hidden is used, assume the code has been annotated
12305 correspondingly for the symbols needed. */
12306 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
12307-void fnord () __attribute__((visibility("default")));
12308+int fnord () __attribute__((visibility("default")));
12309 #endif
12310
12311-void fnord () { int i=42; }
12312+int fnord () { return 42; }
12313 int main ()
12314 {
12315 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
12316@@ -14784,13 +15439,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_
12317 lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
12318 lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
12319 lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
12320+lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
12321+lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
12322 reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
12323 reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
12324 OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
12325 deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
12326 file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
12327+file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
12328+want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
12329+DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
12330+sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
12331 AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
12332 AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
12333+archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
12334 STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
12335 RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
12336 old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
12337@@ -14805,14 +15467,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$l
12338 lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
12339 lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
12340 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
12341+nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
12342+lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
12343 objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
12344 MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
12345 lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
12346-lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
12347 lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
12348+lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
12349 lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
12350 lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
12351 need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
12352+MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
12353 DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
12354 NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
12355 LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
12356@@ -14845,12 +15510,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcod
12357 hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
12358 inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
12359 link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
12360-fix_srcfile_path='`$ECHO "$fix_srcfile_path" | $SED "$delay_single_quote_subst"`'
12361 always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
12362 export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
12363 exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
12364 include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
12365 prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
12366+postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
12367 file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
12368 variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
12369 need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
12370@@ -14905,8 +15570,13 @@ reload_flag \
12371 OBJDUMP \
12372 deplibs_check_method \
12373 file_magic_cmd \
12374+file_magic_glob \
12375+want_nocaseglob \
12376+DLLTOOL \
12377+sharedlib_from_linklib_cmd \
12378 AR \
12379 AR_FLAGS \
12380+archiver_list_spec \
12381 STRIP \
12382 RANLIB \
12383 CC \
12384@@ -14916,12 +15586,14 @@ lt_cv_sys_global_symbol_pipe \
12385 lt_cv_sys_global_symbol_to_cdecl \
12386 lt_cv_sys_global_symbol_to_c_name_address \
12387 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
12388+nm_file_list_spec \
12389 lt_prog_compiler_no_builtin_flag \
12390-lt_prog_compiler_wl \
12391 lt_prog_compiler_pic \
12392+lt_prog_compiler_wl \
12393 lt_prog_compiler_static \
12394 lt_cv_prog_compiler_c_o \
12395 need_locks \
12396+MANIFEST_TOOL \
12397 DSYMUTIL \
12398 NMEDIT \
12399 LIPO \
12400@@ -14937,7 +15609,6 @@ no_undefined_flag \
12401 hardcode_libdir_flag_spec \
12402 hardcode_libdir_flag_spec_ld \
12403 hardcode_libdir_separator \
12404-fix_srcfile_path \
12405 exclude_expsyms \
12406 include_expsyms \
12407 file_list_spec \
12408@@ -14973,6 +15644,7 @@ module_cmds \
12409 module_expsym_cmds \
12410 export_symbols_cmds \
12411 prelink_cmds \
12412+postlink_cmds \
12413 postinstall_cmds \
12414 postuninstall_cmds \
12415 finish_cmds \
12416@@ -15730,7 +16402,8 @@ $as_echo X"$file" |
12417 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
12418 #
12419 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
12420-# 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
12421+# 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
12422+# Inc.
12423 # Written by Gordon Matzigkeit, 1996
12424 #
12425 # This file is part of GNU Libtool.
12426@@ -15833,19 +16506,42 @@ SP2NL=$lt_lt_SP2NL
12427 # turn newlines into spaces.
12428 NL2SP=$lt_lt_NL2SP
12429
12430+# convert \$build file names to \$host format.
12431+to_host_file_cmd=$lt_cv_to_host_file_cmd
12432+
12433+# convert \$build files to toolchain format.
12434+to_tool_file_cmd=$lt_cv_to_tool_file_cmd
12435+
12436 # An object symbol dumper.
12437 OBJDUMP=$lt_OBJDUMP
12438
12439 # Method to check whether dependent libraries are shared objects.
12440 deplibs_check_method=$lt_deplibs_check_method
12441
12442-# Command to use when deplibs_check_method == "file_magic".
12443+# Command to use when deplibs_check_method = "file_magic".
12444 file_magic_cmd=$lt_file_magic_cmd
12445
12446+# How to find potential files when deplibs_check_method = "file_magic".
12447+file_magic_glob=$lt_file_magic_glob
12448+
12449+# Find potential files using nocaseglob when deplibs_check_method = "file_magic".
12450+want_nocaseglob=$lt_want_nocaseglob
12451+
12452+# DLL creation program.
12453+DLLTOOL=$lt_DLLTOOL
12454+
12455+# Command to associate shared and link libraries.
12456+sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
12457+
12458 # The archiver.
12459 AR=$lt_AR
12460+
12461+# Flags to create an archive.
12462 AR_FLAGS=$lt_AR_FLAGS
12463
12464+# How to feed a file listing to the archiver.
12465+archiver_list_spec=$lt_archiver_list_spec
12466+
12467 # A symbol stripping program.
12468 STRIP=$lt_STRIP
12469
12470@@ -15875,6 +16571,12 @@ global_symbol_to_c_name_address=$lt_lt_c
12471 # Transform the output of nm in a C name address pair when lib prefix is needed.
12472 global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
12473
12474+# Specify filename containing input files for \$NM.
12475+nm_file_list_spec=$lt_nm_file_list_spec
12476+
12477+# The root where to search for dependent libraries,and in which our libraries should be installed.
12478+lt_sysroot=$lt_sysroot
12479+
12480 # The name of the directory that contains temporary libtool files.
12481 objdir=$objdir
12482
12483@@ -15884,6 +16586,9 @@ MAGIC_CMD=$MAGIC_CMD
12484 # Must we lock files when doing compilation?
12485 need_locks=$lt_need_locks
12486
12487+# Manifest tool.
12488+MANIFEST_TOOL=$lt_MANIFEST_TOOL
12489+
12490 # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
12491 DSYMUTIL=$lt_DSYMUTIL
12492
12493@@ -15998,12 +16703,12 @@ with_gcc=$GCC
12494 # Compiler flag to turn off builtin functions.
12495 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
12496
12497-# How to pass a linker flag through the compiler.
12498-wl=$lt_lt_prog_compiler_wl
12499-
12500 # Additional compiler flags for building library objects.
12501 pic_flag=$lt_lt_prog_compiler_pic
12502
12503+# How to pass a linker flag through the compiler.
12504+wl=$lt_lt_prog_compiler_wl
12505+
12506 # Compiler flag to prevent dynamic linking.
12507 link_static_flag=$lt_lt_prog_compiler_static
12508
12509@@ -16090,9 +16795,6 @@ inherit_rpath=$inherit_rpath
12510 # Whether libtool must link a program against all its dependency libraries.
12511 link_all_deplibs=$link_all_deplibs
12512
12513-# Fix the shell variable \$srcfile for the compiler.
12514-fix_srcfile_path=$lt_fix_srcfile_path
12515-
12516 # Set to "yes" if exported symbols are required.
12517 always_export_symbols=$always_export_symbols
12518
12519@@ -16108,6 +16810,9 @@ include_expsyms=$lt_include_expsyms
12520 # Commands necessary for linking programs (against libraries) with templates.
12521 prelink_cmds=$lt_prelink_cmds
12522
12523+# Commands necessary for finishing linking programs.
12524+postlink_cmds=$lt_postlink_cmds
12525+
12526 # Specify filename containing input files.
12527 file_list_spec=$lt_file_list_spec
12528
12529@@ -16140,210 +16845,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
12530 # if finds mixed CR/LF and LF-only lines. Since sed operates in
12531 # text mode, it properly converts lines to CR/LF. This bash problem
12532 # is reportedly fixed, but why not run on old versions too?
12533- sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
12534- || (rm -f "$cfgfile"; exit 1)
12535-
12536- case $xsi_shell in
12537- yes)
12538- cat << \_LT_EOF >> "$cfgfile"
12539-
12540-# func_dirname file append nondir_replacement
12541-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
12542-# otherwise set result to NONDIR_REPLACEMENT.
12543-func_dirname ()
12544-{
12545- case ${1} in
12546- */*) func_dirname_result="${1%/*}${2}" ;;
12547- * ) func_dirname_result="${3}" ;;
12548- esac
12549-}
12550-
12551-# func_basename file
12552-func_basename ()
12553-{
12554- func_basename_result="${1##*/}"
12555-}
12556-
12557-# func_dirname_and_basename file append nondir_replacement
12558-# perform func_basename and func_dirname in a single function
12559-# call:
12560-# dirname: Compute the dirname of FILE. If nonempty,
12561-# add APPEND to the result, otherwise set result
12562-# to NONDIR_REPLACEMENT.
12563-# value returned in "$func_dirname_result"
12564-# basename: Compute filename of FILE.
12565-# value retuned in "$func_basename_result"
12566-# Implementation must be kept synchronized with func_dirname
12567-# and func_basename. For efficiency, we do not delegate to
12568-# those functions but instead duplicate the functionality here.
12569-func_dirname_and_basename ()
12570-{
12571- case ${1} in
12572- */*) func_dirname_result="${1%/*}${2}" ;;
12573- * ) func_dirname_result="${3}" ;;
12574- esac
12575- func_basename_result="${1##*/}"
12576-}
12577-
12578-# func_stripname prefix suffix name
12579-# strip PREFIX and SUFFIX off of NAME.
12580-# PREFIX and SUFFIX must not contain globbing or regex special
12581-# characters, hashes, percent signs, but SUFFIX may contain a leading
12582-# dot (in which case that matches only a dot).
12583-func_stripname ()
12584-{
12585- # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
12586- # positional parameters, so assign one to ordinary parameter first.
12587- func_stripname_result=${3}
12588- func_stripname_result=${func_stripname_result#"${1}"}
12589- func_stripname_result=${func_stripname_result%"${2}"}
12590-}
12591-
12592-# func_opt_split
12593-func_opt_split ()
12594-{
12595- func_opt_split_opt=${1%%=*}
12596- func_opt_split_arg=${1#*=}
12597-}
12598-
12599-# func_lo2o object
12600-func_lo2o ()
12601-{
12602- case ${1} in
12603- *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
12604- *) func_lo2o_result=${1} ;;
12605- esac
12606-}
12607-
12608-# func_xform libobj-or-source
12609-func_xform ()
12610-{
12611- func_xform_result=${1%.*}.lo
12612-}
12613-
12614-# func_arith arithmetic-term...
12615-func_arith ()
12616-{
12617- func_arith_result=$(( $* ))
12618-}
12619-
12620-# func_len string
12621-# STRING may not start with a hyphen.
12622-func_len ()
12623-{
12624- func_len_result=${#1}
12625-}
12626-
12627-_LT_EOF
12628- ;;
12629- *) # Bourne compatible functions.
12630- cat << \_LT_EOF >> "$cfgfile"
12631-
12632-# func_dirname file append nondir_replacement
12633-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
12634-# otherwise set result to NONDIR_REPLACEMENT.
12635-func_dirname ()
12636-{
12637- # Extract subdirectory from the argument.
12638- func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
12639- if test "X$func_dirname_result" = "X${1}"; then
12640- func_dirname_result="${3}"
12641- else
12642- func_dirname_result="$func_dirname_result${2}"
12643- fi
12644-}
12645-
12646-# func_basename file
12647-func_basename ()
12648-{
12649- func_basename_result=`$ECHO "${1}" | $SED "$basename"`
12650-}
12651-
12652-
12653-# func_stripname prefix suffix name
12654-# strip PREFIX and SUFFIX off of NAME.
12655-# PREFIX and SUFFIX must not contain globbing or regex special
12656-# characters, hashes, percent signs, but SUFFIX may contain a leading
12657-# dot (in which case that matches only a dot).
12658-# func_strip_suffix prefix name
12659-func_stripname ()
12660-{
12661- case ${2} in
12662- .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
12663- *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
12664- esac
12665-}
12666-
12667-# sed scripts:
12668-my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q'
12669-my_sed_long_arg='1s/^-[^=]*=//'
12670-
12671-# func_opt_split
12672-func_opt_split ()
12673-{
12674- func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"`
12675- func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"`
12676-}
12677-
12678-# func_lo2o object
12679-func_lo2o ()
12680-{
12681- func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
12682-}
12683-
12684-# func_xform libobj-or-source
12685-func_xform ()
12686-{
12687- func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
12688-}
12689-
12690-# func_arith arithmetic-term...
12691-func_arith ()
12692-{
12693- func_arith_result=`expr "$@"`
12694-}
12695-
12696-# func_len string
12697-# STRING may not start with a hyphen.
12698-func_len ()
12699-{
12700- func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len`
12701-}
12702-
12703-_LT_EOF
12704-esac
12705-
12706-case $lt_shell_append in
12707- yes)
12708- cat << \_LT_EOF >> "$cfgfile"
12709-
12710-# func_append var value
12711-# Append VALUE to the end of shell variable VAR.
12712-func_append ()
12713-{
12714- eval "$1+=\$2"
12715-}
12716-_LT_EOF
12717- ;;
12718- *)
12719- cat << \_LT_EOF >> "$cfgfile"
12720-
12721-# func_append var value
12722-# Append VALUE to the end of shell variable VAR.
12723-func_append ()
12724-{
12725- eval "$1=\$$1\$2"
12726-}
12727-
12728-_LT_EOF
12729- ;;
12730- esac
12731+ sed '$q' "$ltmain" >> "$cfgfile" \
12732+ || (rm -f "$cfgfile"; exit 1)
12733
12734+ if test x"$xsi_shell" = xyes; then
12735+ sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
12736+func_dirname ()\
12737+{\
12738+\ case ${1} in\
12739+\ */*) func_dirname_result="${1%/*}${2}" ;;\
12740+\ * ) func_dirname_result="${3}" ;;\
12741+\ esac\
12742+} # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \
12743+ && mv -f "$cfgfile.tmp" "$cfgfile" \
12744+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
12745+test 0 -eq $? || _lt_function_replace_fail=:
12746+
12747+
12748+ sed -e '/^func_basename ()$/,/^} # func_basename /c\
12749+func_basename ()\
12750+{\
12751+\ func_basename_result="${1##*/}"\
12752+} # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \
12753+ && mv -f "$cfgfile.tmp" "$cfgfile" \
12754+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
12755+test 0 -eq $? || _lt_function_replace_fail=:
12756+
12757+
12758+ sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\
12759+func_dirname_and_basename ()\
12760+{\
12761+\ case ${1} in\
12762+\ */*) func_dirname_result="${1%/*}${2}" ;;\
12763+\ * ) func_dirname_result="${3}" ;;\
12764+\ esac\
12765+\ func_basename_result="${1##*/}"\
12766+} # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \
12767+ && mv -f "$cfgfile.tmp" "$cfgfile" \
12768+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
12769+test 0 -eq $? || _lt_function_replace_fail=:
12770+
12771+
12772+ sed -e '/^func_stripname ()$/,/^} # func_stripname /c\
12773+func_stripname ()\
12774+{\
12775+\ # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\
12776+\ # positional parameters, so assign one to ordinary parameter first.\
12777+\ func_stripname_result=${3}\
12778+\ func_stripname_result=${func_stripname_result#"${1}"}\
12779+\ func_stripname_result=${func_stripname_result%"${2}"}\
12780+} # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \
12781+ && mv -f "$cfgfile.tmp" "$cfgfile" \
12782+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
12783+test 0 -eq $? || _lt_function_replace_fail=:
12784+
12785+
12786+ sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\
12787+func_split_long_opt ()\
12788+{\
12789+\ func_split_long_opt_name=${1%%=*}\
12790+\ func_split_long_opt_arg=${1#*=}\
12791+} # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \
12792+ && mv -f "$cfgfile.tmp" "$cfgfile" \
12793+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
12794+test 0 -eq $? || _lt_function_replace_fail=:
12795+
12796+
12797+ sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\
12798+func_split_short_opt ()\
12799+{\
12800+\ func_split_short_opt_arg=${1#??}\
12801+\ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\
12802+} # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \
12803+ && mv -f "$cfgfile.tmp" "$cfgfile" \
12804+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
12805+test 0 -eq $? || _lt_function_replace_fail=:
12806+
12807+
12808+ sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\
12809+func_lo2o ()\
12810+{\
12811+\ case ${1} in\
12812+\ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\
12813+\ *) func_lo2o_result=${1} ;;\
12814+\ esac\
12815+} # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \
12816+ && mv -f "$cfgfile.tmp" "$cfgfile" \
12817+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
12818+test 0 -eq $? || _lt_function_replace_fail=:
12819+
12820+
12821+ sed -e '/^func_xform ()$/,/^} # func_xform /c\
12822+func_xform ()\
12823+{\
12824+ func_xform_result=${1%.*}.lo\
12825+} # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \
12826+ && mv -f "$cfgfile.tmp" "$cfgfile" \
12827+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
12828+test 0 -eq $? || _lt_function_replace_fail=:
12829+
12830+
12831+ sed -e '/^func_arith ()$/,/^} # func_arith /c\
12832+func_arith ()\
12833+{\
12834+ func_arith_result=$(( $* ))\
12835+} # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \
12836+ && mv -f "$cfgfile.tmp" "$cfgfile" \
12837+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
12838+test 0 -eq $? || _lt_function_replace_fail=:
12839+
12840+
12841+ sed -e '/^func_len ()$/,/^} # func_len /c\
12842+func_len ()\
12843+{\
12844+ func_len_result=${#1}\
12845+} # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \
12846+ && mv -f "$cfgfile.tmp" "$cfgfile" \
12847+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
12848+test 0 -eq $? || _lt_function_replace_fail=:
12849+
12850+fi
12851+
12852+if test x"$lt_shell_append" = xyes; then
12853+ sed -e '/^func_append ()$/,/^} # func_append /c\
12854+func_append ()\
12855+{\
12856+ eval "${1}+=\\${2}"\
12857+} # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \
12858+ && mv -f "$cfgfile.tmp" "$cfgfile" \
12859+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
12860+test 0 -eq $? || _lt_function_replace_fail=:
12861+
12862+
12863+ sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\
12864+func_append_quoted ()\
12865+{\
12866+\ func_quote_for_eval "${2}"\
12867+\ eval "${1}+=\\\\ \\$func_quote_for_eval_result"\
12868+} # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \
12869+ && mv -f "$cfgfile.tmp" "$cfgfile" \
12870+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
12871+test 0 -eq $? || _lt_function_replace_fail=:
12872+
12873+
12874+ # Save a `func_append' function call where possible by direct use of '+='
12875+ sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
12876+ && mv -f "$cfgfile.tmp" "$cfgfile" \
12877+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
12878+ test 0 -eq $? || _lt_function_replace_fail=:
12879+else
12880+ # Save a `func_append' function call even when '+=' is not available
12881+ sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
12882+ && mv -f "$cfgfile.tmp" "$cfgfile" \
12883+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
12884+ test 0 -eq $? || _lt_function_replace_fail=:
12885+fi
12886+
12887+if test x"$_lt_function_replace_fail" = x":"; then
12888+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
12889+$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
12890+fi
12891
12892- sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
12893- || (rm -f "$cfgfile"; exit 1)
12894
12895- mv -f "$cfgfile" "$ofile" ||
12896+ mv -f "$cfgfile" "$ofile" ||
12897 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
12898 chmod +x "$ofile"
12899
12900Index: binutils-2.22/gas/configure
12901===================================================================
12902--- binutils-2.22.orig/gas/configure
12903+++ binutils-2.22/gas/configure
12904@@ -645,8 +645,11 @@ OTOOL
12905 LIPO
12906 NMEDIT
12907 DSYMUTIL
12908+MANIFEST_TOOL
12909 RANLIB
12910+ac_ct_AR
12911 AR
12912+DLLTOOL
12913 OBJDUMP
12914 LN_S
12915 NM
12916@@ -759,6 +762,7 @@ enable_static
12917 with_pic
12918 enable_fast_install
12919 with_gnu_ld
12920+with_libtool_sysroot
12921 enable_libtool_lock
12922 enable_targets
12923 enable_checking
12924@@ -1420,6 +1424,8 @@ Optional Packages:
12925 --with-pic try to use only PIC/non-PIC objects [default=use
12926 both]
12927 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
12928+ --with-libtool-sysroot=DIR Search for dependent libraries within DIR
12929+ (or the compiler's sysroot if not specified).
12930 --with-zlib include zlib support (auto/yes/no) default=auto
12931
12932 Some influential environment variables:
12933@@ -5135,8 +5141,8 @@ esac
12934
12935
12936
12937-macro_version='2.2.7a'
12938-macro_revision='1.3134'
12939+macro_version='2.4'
12940+macro_revision='1.3293'
12941
12942
12943
12944@@ -5176,7 +5182,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
12945 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
12946 $as_echo_n "checking how to print strings... " >&6; }
12947 # Test print first, because it will be a builtin if present.
12948-if test "X`print -r -- -n 2>/dev/null`" = X-n && \
12949+if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
12950 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
12951 ECHO='print -r --'
12952 elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
12953@@ -5862,8 +5868,8 @@ $as_echo_n "checking whether the shell u
12954 # Try some XSI features
12955 xsi_shell=no
12956 ( _lt_dummy="a/b/c"
12957- test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
12958- = c,a/b,, \
12959+ test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
12960+ = c,a/b,b/c, \
12961 && eval 'test $(( 1 + 1 )) -eq 2 \
12962 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
12963 && xsi_shell=yes
12964@@ -5912,6 +5918,80 @@ esac
12965
12966
12967
12968+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
12969+$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
12970+if test "${lt_cv_to_host_file_cmd+set}" = set; then :
12971+ $as_echo_n "(cached) " >&6
12972+else
12973+ case $host in
12974+ *-*-mingw* )
12975+ case $build in
12976+ *-*-mingw* ) # actually msys
12977+ lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
12978+ ;;
12979+ *-*-cygwin* )
12980+ lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
12981+ ;;
12982+ * ) # otherwise, assume *nix
12983+ lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
12984+ ;;
12985+ esac
12986+ ;;
12987+ *-*-cygwin* )
12988+ case $build in
12989+ *-*-mingw* ) # actually msys
12990+ lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
12991+ ;;
12992+ *-*-cygwin* )
12993+ lt_cv_to_host_file_cmd=func_convert_file_noop
12994+ ;;
12995+ * ) # otherwise, assume *nix
12996+ lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
12997+ ;;
12998+ esac
12999+ ;;
13000+ * ) # unhandled hosts (and "normal" native builds)
13001+ lt_cv_to_host_file_cmd=func_convert_file_noop
13002+ ;;
13003+esac
13004+
13005+fi
13006+
13007+to_host_file_cmd=$lt_cv_to_host_file_cmd
13008+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
13009+$as_echo "$lt_cv_to_host_file_cmd" >&6; }
13010+
13011+
13012+
13013+
13014+
13015+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
13016+$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
13017+if test "${lt_cv_to_tool_file_cmd+set}" = set; then :
13018+ $as_echo_n "(cached) " >&6
13019+else
13020+ #assume ordinary cross tools, or native build.
13021+lt_cv_to_tool_file_cmd=func_convert_file_noop
13022+case $host in
13023+ *-*-mingw* )
13024+ case $build in
13025+ *-*-mingw* ) # actually msys
13026+ lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
13027+ ;;
13028+ esac
13029+ ;;
13030+esac
13031+
13032+fi
13033+
13034+to_tool_file_cmd=$lt_cv_to_tool_file_cmd
13035+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
13036+$as_echo "$lt_cv_to_tool_file_cmd" >&6; }
13037+
13038+
13039+
13040+
13041+
13042 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
13043 $as_echo_n "checking for $LD option to reload object files... " >&6; }
13044 if test "${lt_cv_ld_reload_flag+set}" = set; then :
13045@@ -5928,6 +6008,11 @@ case $reload_flag in
13046 esac
13047 reload_cmds='$LD$reload_flag -o $output$reload_objs'
13048 case $host_os in
13049+ cygwin* | mingw* | pw32* | cegcc*)
13050+ if test "$GCC" != yes; then
13051+ reload_cmds=false
13052+ fi
13053+ ;;
13054 darwin*)
13055 if test "$GCC" = yes; then
13056 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
13057@@ -6096,7 +6181,8 @@ mingw* | pw32*)
13058 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
13059 lt_cv_file_magic_cmd='func_win32_libid'
13060 else
13061- lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
13062+ # Keep this pattern in sync with the one in func_win32_libid.
13063+ lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
13064 lt_cv_file_magic_cmd='$OBJDUMP -f'
13065 fi
13066 ;;
13067@@ -6250,6 +6336,21 @@ esac
13068 fi
13069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
13070 $as_echo "$lt_cv_deplibs_check_method" >&6; }
13071+
13072+file_magic_glob=
13073+want_nocaseglob=no
13074+if test "$build" = "$host"; then
13075+ case $host_os in
13076+ mingw* | pw32*)
13077+ if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
13078+ want_nocaseglob=yes
13079+ else
13080+ file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
13081+ fi
13082+ ;;
13083+ esac
13084+fi
13085+
13086 file_magic_cmd=$lt_cv_file_magic_cmd
13087 deplibs_check_method=$lt_cv_deplibs_check_method
13088 test -z "$deplibs_check_method" && deplibs_check_method=unknown
13089@@ -6265,9 +6366,162 @@ test -z "$deplibs_check_method" && depli
13090
13091
13092
13093+
13094+
13095+
13096+
13097+
13098+
13099+
13100+
13101+
13102+
13103+if test -n "$ac_tool_prefix"; then
13104+ # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
13105+set dummy ${ac_tool_prefix}dlltool; ac_word=$2
13106+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13107+$as_echo_n "checking for $ac_word... " >&6; }
13108+if test "${ac_cv_prog_DLLTOOL+set}" = set; then :
13109+ $as_echo_n "(cached) " >&6
13110+else
13111+ if test -n "$DLLTOOL"; then
13112+ ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
13113+else
13114+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13115+for as_dir in $PATH
13116+do
13117+ IFS=$as_save_IFS
13118+ test -z "$as_dir" && as_dir=.
13119+ for ac_exec_ext in '' $ac_executable_extensions; do
13120+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13121+ ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
13122+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13123+ break 2
13124+ fi
13125+done
13126+ done
13127+IFS=$as_save_IFS
13128+
13129+fi
13130+fi
13131+DLLTOOL=$ac_cv_prog_DLLTOOL
13132+if test -n "$DLLTOOL"; then
13133+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
13134+$as_echo "$DLLTOOL" >&6; }
13135+else
13136+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13137+$as_echo "no" >&6; }
13138+fi
13139+
13140+
13141+fi
13142+if test -z "$ac_cv_prog_DLLTOOL"; then
13143+ ac_ct_DLLTOOL=$DLLTOOL
13144+ # Extract the first word of "dlltool", so it can be a program name with args.
13145+set dummy dlltool; ac_word=$2
13146+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13147+$as_echo_n "checking for $ac_word... " >&6; }
13148+if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then :
13149+ $as_echo_n "(cached) " >&6
13150+else
13151+ if test -n "$ac_ct_DLLTOOL"; then
13152+ ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
13153+else
13154+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13155+for as_dir in $PATH
13156+do
13157+ IFS=$as_save_IFS
13158+ test -z "$as_dir" && as_dir=.
13159+ for ac_exec_ext in '' $ac_executable_extensions; do
13160+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13161+ ac_cv_prog_ac_ct_DLLTOOL="dlltool"
13162+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13163+ break 2
13164+ fi
13165+done
13166+ done
13167+IFS=$as_save_IFS
13168+
13169+fi
13170+fi
13171+ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
13172+if test -n "$ac_ct_DLLTOOL"; then
13173+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
13174+$as_echo "$ac_ct_DLLTOOL" >&6; }
13175+else
13176+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13177+$as_echo "no" >&6; }
13178+fi
13179+
13180+ if test "x$ac_ct_DLLTOOL" = x; then
13181+ DLLTOOL="false"
13182+ else
13183+ case $cross_compiling:$ac_tool_warned in
13184+yes:)
13185+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
13186+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
13187+ac_tool_warned=yes ;;
13188+esac
13189+ DLLTOOL=$ac_ct_DLLTOOL
13190+ fi
13191+else
13192+ DLLTOOL="$ac_cv_prog_DLLTOOL"
13193+fi
13194+
13195+test -z "$DLLTOOL" && DLLTOOL=dlltool
13196+
13197+
13198+
13199+
13200+
13201+
13202+
13203+
13204+
13205+
13206+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
13207+$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
13208+if test "${lt_cv_sharedlib_from_linklib_cmd+set}" = set; then :
13209+ $as_echo_n "(cached) " >&6
13210+else
13211+ lt_cv_sharedlib_from_linklib_cmd='unknown'
13212+
13213+case $host_os in
13214+cygwin* | mingw* | pw32* | cegcc*)
13215+ # two different shell functions defined in ltmain.sh
13216+ # decide which to use based on capabilities of $DLLTOOL
13217+ case `$DLLTOOL --help 2>&1` in
13218+ *--identify-strict*)
13219+ lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
13220+ ;;
13221+ *)
13222+ lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
13223+ ;;
13224+ esac
13225+ ;;
13226+*)
13227+ # fallback: assume linklib IS sharedlib
13228+ lt_cv_sharedlib_from_linklib_cmd="$ECHO"
13229+ ;;
13230+esac
13231+
13232+fi
13233+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
13234+$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
13235+sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
13236+test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
13237+
13238+
13239+
13240+
13241+
13242+
13243+
13244 if test -n "$ac_tool_prefix"; then
13245- # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
13246-set dummy ${ac_tool_prefix}ar; ac_word=$2
13247+ for ac_prog in ar
13248+ do
13249+ # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
13250+set dummy $ac_tool_prefix$ac_prog; ac_word=$2
13251 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13252 $as_echo_n "checking for $ac_word... " >&6; }
13253 if test "${ac_cv_prog_AR+set}" = set; then :
13254@@ -6283,7 +6537,7 @@ do
13255 test -z "$as_dir" && as_dir=.
13256 for ac_exec_ext in '' $ac_executable_extensions; do
13257 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13258- ac_cv_prog_AR="${ac_tool_prefix}ar"
13259+ ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
13260 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13261 break 2
13262 fi
13263@@ -6303,11 +6557,15 @@ $as_echo "no" >&6; }
13264 fi
13265
13266
13267+ test -n "$AR" && break
13268+ done
13269 fi
13270-if test -z "$ac_cv_prog_AR"; then
13271+if test -z "$AR"; then
13272 ac_ct_AR=$AR
13273- # Extract the first word of "ar", so it can be a program name with args.
13274-set dummy ar; ac_word=$2
13275+ for ac_prog in ar
13276+do
13277+ # Extract the first word of "$ac_prog", so it can be a program name with args.
13278+set dummy $ac_prog; ac_word=$2
13279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13280 $as_echo_n "checking for $ac_word... " >&6; }
13281 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
13282@@ -6323,7 +6581,7 @@ do
13283 test -z "$as_dir" && as_dir=.
13284 for ac_exec_ext in '' $ac_executable_extensions; do
13285 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13286- ac_cv_prog_ac_ct_AR="ar"
13287+ ac_cv_prog_ac_ct_AR="$ac_prog"
13288 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13289 break 2
13290 fi
13291@@ -6342,6 +6600,10 @@ else
13292 $as_echo "no" >&6; }
13293 fi
13294
13295+
13296+ test -n "$ac_ct_AR" && break
13297+done
13298+
13299 if test "x$ac_ct_AR" = x; then
13300 AR="false"
13301 else
13302@@ -6353,16 +6615,72 @@ ac_tool_warned=yes ;;
13303 esac
13304 AR=$ac_ct_AR
13305 fi
13306-else
13307- AR="$ac_cv_prog_AR"
13308 fi
13309
13310-test -z "$AR" && AR=ar
13311-test -z "$AR_FLAGS" && AR_FLAGS=cru
13312+: ${AR=ar}
13313+: ${AR_FLAGS=cru}
13314+
13315+
13316+
13317+
13318+
13319+
13320+
13321+
13322+
13323+
13324+
13325+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
13326+$as_echo_n "checking for archiver @FILE support... " >&6; }
13327+if test "${lt_cv_ar_at_file+set}" = set; then :
13328+ $as_echo_n "(cached) " >&6
13329+else
13330+ lt_cv_ar_at_file=no
13331+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13332+/* end confdefs.h. */
13333+
13334+int
13335+main ()
13336+{
13337
13338+ ;
13339+ return 0;
13340+}
13341+_ACEOF
13342+if ac_fn_c_try_compile "$LINENO"; then :
13343+ echo conftest.$ac_objext > conftest.lst
13344+ lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
13345+ { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
13346+ (eval $lt_ar_try) 2>&5
13347+ ac_status=$?
13348+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
13349+ test $ac_status = 0; }
13350+ if test "$ac_status" -eq 0; then
13351+ # Ensure the archiver fails upon bogus file names.
13352+ rm -f conftest.$ac_objext libconftest.a
13353+ { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
13354+ (eval $lt_ar_try) 2>&5
13355+ ac_status=$?
13356+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
13357+ test $ac_status = 0; }
13358+ if test "$ac_status" -ne 0; then
13359+ lt_cv_ar_at_file=@
13360+ fi
13361+ fi
13362+ rm -f conftest.* libconftest.a
13363
13364+fi
13365+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13366
13367+fi
13368+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
13369+$as_echo "$lt_cv_ar_at_file" >&6; }
13370
13371+if test "x$lt_cv_ar_at_file" = xno; then
13372+ archiver_list_spec=
13373+else
13374+ archiver_list_spec=$lt_cv_ar_at_file
13375+fi
13376
13377
13378
13379@@ -6704,8 +7022,8 @@ esac
13380 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
13381
13382 # Transform an extracted symbol line into symbol name and symbol address
13383-lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
13384-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
13385+lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
13386+lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
13387
13388 # Handle CRLF in mingw tool chain
13389 opt_cr=
13390@@ -6741,6 +7059,7 @@ for ac_symprfx in "" "_"; do
13391 else
13392 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
13393 fi
13394+ lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
13395
13396 # Check to see that the pipe works correctly.
13397 pipe_works=no
13398@@ -6782,6 +7101,18 @@ _LT_EOF
13399 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
13400 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
13401 cat <<_LT_EOF > conftest.$ac_ext
13402+/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
13403+#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
13404+/* DATA imports from DLLs on WIN32 con't be const, because runtime
13405+ relocations are performed -- see ld's documentation on pseudo-relocs. */
13406+# define LT_DLSYM_CONST
13407+#elif defined(__osf__)
13408+/* This system does not cope well with relocations in const data. */
13409+# define LT_DLSYM_CONST
13410+#else
13411+# define LT_DLSYM_CONST const
13412+#endif
13413+
13414 #ifdef __cplusplus
13415 extern "C" {
13416 #endif
13417@@ -6793,7 +7124,7 @@ _LT_EOF
13418 cat <<_LT_EOF >> conftest.$ac_ext
13419
13420 /* The mapping between symbol names and symbols. */
13421-const struct {
13422+LT_DLSYM_CONST struct {
13423 const char *name;
13424 void *address;
13425 }
13426@@ -6819,8 +7150,8 @@ static const void *lt_preloaded_setup()
13427 _LT_EOF
13428 # Now try linking the two files.
13429 mv conftest.$ac_objext conftstm.$ac_objext
13430- lt_save_LIBS="$LIBS"
13431- lt_save_CFLAGS="$CFLAGS"
13432+ lt_globsym_save_LIBS=$LIBS
13433+ lt_globsym_save_CFLAGS=$CFLAGS
13434 LIBS="conftstm.$ac_objext"
13435 CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
13436 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
13437@@ -6830,8 +7161,8 @@ _LT_EOF
13438 test $ac_status = 0; } && test -s conftest${ac_exeext}; then
13439 pipe_works=yes
13440 fi
13441- LIBS="$lt_save_LIBS"
13442- CFLAGS="$lt_save_CFLAGS"
13443+ LIBS=$lt_globsym_save_LIBS
13444+ CFLAGS=$lt_globsym_save_CFLAGS
13445 else
13446 echo "cannot find nm_test_func in $nlist" >&5
13447 fi
13448@@ -6868,6 +7199,19 @@ else
13449 $as_echo "ok" >&6; }
13450 fi
13451
13452+# Response file support.
13453+if test "$lt_cv_nm_interface" = "MS dumpbin"; then
13454+ nm_file_list_spec='@'
13455+elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
13456+ nm_file_list_spec='@'
13457+fi
13458+
13459+
13460+
13461+
13462+
13463+
13464+
13465
13466
13467
13468@@ -6888,6 +7232,42 @@ fi
13469
13470
13471
13472+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
13473+$as_echo_n "checking for sysroot... " >&6; }
13474+
13475+# Check whether --with-libtool-sysroot was given.
13476+if test "${with_libtool_sysroot+set}" = set; then :
13477+ withval=$with_libtool_sysroot;
13478+else
13479+ with_libtool_sysroot=no
13480+fi
13481+
13482+
13483+lt_sysroot=
13484+case ${with_libtool_sysroot} in #(
13485+ yes)
13486+ if test "$GCC" = yes; then
13487+ lt_sysroot=`$CC --print-sysroot 2>/dev/null`
13488+ fi
13489+ ;; #(
13490+ /*)
13491+ lt_sysroot=`echo "$with_libtool_sysroot" | sed -e "$sed_quote_subst"`
13492+ ;; #(
13493+ no|'')
13494+ ;; #(
13495+ *)
13496+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libtool_sysroot}" >&5
13497+$as_echo "${with_libtool_sysroot}" >&6; }
13498+ as_fn_error "The sysroot must be an absolute path." "$LINENO" 5
13499+ ;;
13500+esac
13501+
13502+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
13503+$as_echo "${lt_sysroot:-no}" >&6; }
13504+
13505+
13506+
13507+
13508
13509 # Check whether --enable-libtool-lock was given.
13510 if test "${enable_libtool_lock+set}" = set; then :
13511@@ -7082,6 +7462,123 @@ esac
13512
13513 need_locks="$enable_libtool_lock"
13514
13515+if test -n "$ac_tool_prefix"; then
13516+ # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
13517+set dummy ${ac_tool_prefix}mt; ac_word=$2
13518+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13519+$as_echo_n "checking for $ac_word... " >&6; }
13520+if test "${ac_cv_prog_MANIFEST_TOOL+set}" = set; then :
13521+ $as_echo_n "(cached) " >&6
13522+else
13523+ if test -n "$MANIFEST_TOOL"; then
13524+ ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
13525+else
13526+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13527+for as_dir in $PATH
13528+do
13529+ IFS=$as_save_IFS
13530+ test -z "$as_dir" && as_dir=.
13531+ for ac_exec_ext in '' $ac_executable_extensions; do
13532+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13533+ ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
13534+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13535+ break 2
13536+ fi
13537+done
13538+ done
13539+IFS=$as_save_IFS
13540+
13541+fi
13542+fi
13543+MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
13544+if test -n "$MANIFEST_TOOL"; then
13545+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
13546+$as_echo "$MANIFEST_TOOL" >&6; }
13547+else
13548+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13549+$as_echo "no" >&6; }
13550+fi
13551+
13552+
13553+fi
13554+if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
13555+ ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
13556+ # Extract the first word of "mt", so it can be a program name with args.
13557+set dummy mt; ac_word=$2
13558+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13559+$as_echo_n "checking for $ac_word... " >&6; }
13560+if test "${ac_cv_prog_ac_ct_MANIFEST_TOOL+set}" = set; then :
13561+ $as_echo_n "(cached) " >&6
13562+else
13563+ if test -n "$ac_ct_MANIFEST_TOOL"; then
13564+ ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
13565+else
13566+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13567+for as_dir in $PATH
13568+do
13569+ IFS=$as_save_IFS
13570+ test -z "$as_dir" && as_dir=.
13571+ for ac_exec_ext in '' $ac_executable_extensions; do
13572+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13573+ ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
13574+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13575+ break 2
13576+ fi
13577+done
13578+ done
13579+IFS=$as_save_IFS
13580+
13581+fi
13582+fi
13583+ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
13584+if test -n "$ac_ct_MANIFEST_TOOL"; then
13585+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
13586+$as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
13587+else
13588+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13589+$as_echo "no" >&6; }
13590+fi
13591+
13592+ if test "x$ac_ct_MANIFEST_TOOL" = x; then
13593+ MANIFEST_TOOL=":"
13594+ else
13595+ case $cross_compiling:$ac_tool_warned in
13596+yes:)
13597+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
13598+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
13599+ac_tool_warned=yes ;;
13600+esac
13601+ MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
13602+ fi
13603+else
13604+ MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
13605+fi
13606+
13607+test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
13608+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
13609+$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
13610+if test "${lt_cv_path_mainfest_tool+set}" = set; then :
13611+ $as_echo_n "(cached) " >&6
13612+else
13613+ lt_cv_path_mainfest_tool=no
13614+ echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
13615+ $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
13616+ cat conftest.err >&5
13617+ if $GREP 'Manifest Tool' conftest.out > /dev/null; then
13618+ lt_cv_path_mainfest_tool=yes
13619+ fi
13620+ rm -f conftest*
13621+fi
13622+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
13623+$as_echo "$lt_cv_path_mainfest_tool" >&6; }
13624+if test "x$lt_cv_path_mainfest_tool" != xyes; then
13625+ MANIFEST_TOOL=:
13626+fi
13627+
13628+
13629+
13630+
13631+
13632
13633 case $host_os in
13634 rhapsody* | darwin*)
13635@@ -7645,6 +8142,8 @@ _LT_EOF
13636 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
13637 echo "$AR cru libconftest.a conftest.o" >&5
13638 $AR cru libconftest.a conftest.o 2>&5
13639+ echo "$RANLIB libconftest.a" >&5
13640+ $RANLIB libconftest.a 2>&5
13641 cat > conftest.c << _LT_EOF
13642 int main() { return 0;}
13643 _LT_EOF
13644@@ -7840,7 +8339,8 @@ fi
13645 LIBTOOL_DEPS="$ltmain"
13646
13647 # Always use our own libtool.
13648-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
13649+LIBTOOL='$(SHELL) $(top_builddir)'
13650+LIBTOOL="$LIBTOOL/${host_alias}-libtool"
13651
13652
13653
13654@@ -7929,7 +8429,7 @@ aix3*)
13655 esac
13656
13657 # Global variables:
13658-ofile=libtool
13659+ofile=${host_alias}-libtool
13660 can_build_shared=yes
13661
13662 # All known linkers require a `.a' archive for static linking (except MSVC,
13663@@ -8227,8 +8727,6 @@ fi
13664 lt_prog_compiler_pic=
13665 lt_prog_compiler_static=
13666
13667-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
13668-$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
13669
13670 if test "$GCC" = yes; then
13671 lt_prog_compiler_wl='-Wl,'
13672@@ -8393,6 +8891,12 @@ $as_echo_n "checking for $compiler optio
13673 lt_prog_compiler_pic='--shared'
13674 lt_prog_compiler_static='--static'
13675 ;;
13676+ nagfor*)
13677+ # NAG Fortran compiler
13678+ lt_prog_compiler_wl='-Wl,-Wl,,'
13679+ lt_prog_compiler_pic='-PIC'
13680+ lt_prog_compiler_static='-Bstatic'
13681+ ;;
13682 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
13683 # Portland Group compilers (*not* the Pentium gcc compiler,
13684 # which looks to be a dead project)
13685@@ -8455,7 +8959,7 @@ $as_echo_n "checking for $compiler optio
13686 lt_prog_compiler_pic='-KPIC'
13687 lt_prog_compiler_static='-Bstatic'
13688 case $cc_basename in
13689- f77* | f90* | f95*)
13690+ f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
13691 lt_prog_compiler_wl='-Qoption ld ';;
13692 *)
13693 lt_prog_compiler_wl='-Wl,';;
13694@@ -8512,13 +9016,17 @@ case $host_os in
13695 lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
13696 ;;
13697 esac
13698-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5
13699-$as_echo "$lt_prog_compiler_pic" >&6; }
13700-
13701-
13702-
13703-
13704
13705+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
13706+$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
13707+if test "${lt_cv_prog_compiler_pic+set}" = set; then :
13708+ $as_echo_n "(cached) " >&6
13709+else
13710+ lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
13711+fi
13712+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
13713+$as_echo "$lt_cv_prog_compiler_pic" >&6; }
13714+lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
13715
13716 #
13717 # Check to make sure the PIC flag actually works.
13718@@ -8579,6 +9087,11 @@ fi
13719
13720
13721
13722+
13723+
13724+
13725+
13726+
13727 #
13728 # Check to make sure the static flag actually works.
13729 #
13730@@ -8929,7 +9442,8 @@ _LT_EOF
13731 allow_undefined_flag=unsupported
13732 always_export_symbols=no
13733 enable_shared_with_static_runtimes=yes
13734- export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
13735+ export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
13736+ exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
13737
13738 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
13739 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
13740@@ -8977,7 +9491,7 @@ _LT_EOF
13741 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
13742 && test "$tmp_diet" = no
13743 then
13744- tmp_addflag=
13745+ tmp_addflag=' $pic_flag'
13746 tmp_sharedflag='-shared'
13747 case $cc_basename,$host_cpu in
13748 pgcc*) # Portland Group C compiler
13749@@ -9028,12 +9542,12 @@ _LT_EOF
13750 whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
13751 hardcode_libdir_flag_spec=
13752 hardcode_libdir_flag_spec_ld='-rpath $libdir'
13753- archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
13754+ archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
13755 if test "x$supports_anon_versioning" = xyes; then
13756 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
13757 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
13758 echo "local: *; };" >> $output_objdir/$libname.ver~
13759- $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
13760+ $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
13761 fi
13762 ;;
13763 esac
13764@@ -9047,8 +9561,8 @@ _LT_EOF
13765 archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
13766 wlarc=
13767 else
13768- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
13769- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
13770+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
13771+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
13772 fi
13773 ;;
13774
13775@@ -9066,8 +9580,8 @@ _LT_EOF
13776
13777 _LT_EOF
13778 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
13779- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
13780- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
13781+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
13782+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
13783 else
13784 ld_shlibs=no
13785 fi
13786@@ -9113,8 +9627,8 @@ _LT_EOF
13787
13788 *)
13789 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
13790- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
13791- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
13792+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
13793+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
13794 else
13795 ld_shlibs=no
13796 fi
13797@@ -9244,7 +9758,13 @@ _LT_EOF
13798 allow_undefined_flag='-berok'
13799 # Determine the default libpath from the value encoded in an
13800 # empty executable.
13801- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13802+ if test "${lt_cv_aix_libpath+set}" = set; then
13803+ aix_libpath=$lt_cv_aix_libpath
13804+else
13805+ if test "${lt_cv_aix_libpath_+set}" = set; then :
13806+ $as_echo_n "(cached) " >&6
13807+else
13808+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13809 /* end confdefs.h. */
13810
13811 int
13812@@ -9257,22 +9777,29 @@ main ()
13813 _ACEOF
13814 if ac_fn_c_try_link "$LINENO"; then :
13815
13816-lt_aix_libpath_sed='
13817- /Import File Strings/,/^$/ {
13818- /^0/ {
13819- s/^0 *\(.*\)$/\1/
13820- p
13821- }
13822- }'
13823-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
13824-# Check for a 64-bit object if we didn't find anything.
13825-if test -z "$aix_libpath"; then
13826- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
13827-fi
13828+ lt_aix_libpath_sed='
13829+ /Import File Strings/,/^$/ {
13830+ /^0/ {
13831+ s/^0 *\([^ ]*\) *$/\1/
13832+ p
13833+ }
13834+ }'
13835+ lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
13836+ # Check for a 64-bit object if we didn't find anything.
13837+ if test -z "$lt_cv_aix_libpath_"; then
13838+ lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
13839+ fi
13840 fi
13841 rm -f core conftest.err conftest.$ac_objext \
13842 conftest$ac_exeext conftest.$ac_ext
13843-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
13844+ if test -z "$lt_cv_aix_libpath_"; then
13845+ lt_cv_aix_libpath_="/usr/lib:/lib"
13846+ fi
13847+
13848+fi
13849+
13850+ aix_libpath=$lt_cv_aix_libpath_
13851+fi
13852
13853 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
13854 archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
13855@@ -9284,7 +9811,13 @@ if test -z "$aix_libpath"; then aix_libp
13856 else
13857 # Determine the default libpath from the value encoded in an
13858 # empty executable.
13859- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13860+ if test "${lt_cv_aix_libpath+set}" = set; then
13861+ aix_libpath=$lt_cv_aix_libpath
13862+else
13863+ if test "${lt_cv_aix_libpath_+set}" = set; then :
13864+ $as_echo_n "(cached) " >&6
13865+else
13866+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13867 /* end confdefs.h. */
13868
13869 int
13870@@ -9297,22 +9830,29 @@ main ()
13871 _ACEOF
13872 if ac_fn_c_try_link "$LINENO"; then :
13873
13874-lt_aix_libpath_sed='
13875- /Import File Strings/,/^$/ {
13876- /^0/ {
13877- s/^0 *\(.*\)$/\1/
13878- p
13879- }
13880- }'
13881-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
13882-# Check for a 64-bit object if we didn't find anything.
13883-if test -z "$aix_libpath"; then
13884- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
13885-fi
13886+ lt_aix_libpath_sed='
13887+ /Import File Strings/,/^$/ {
13888+ /^0/ {
13889+ s/^0 *\([^ ]*\) *$/\1/
13890+ p
13891+ }
13892+ }'
13893+ lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
13894+ # Check for a 64-bit object if we didn't find anything.
13895+ if test -z "$lt_cv_aix_libpath_"; then
13896+ lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
13897+ fi
13898 fi
13899 rm -f core conftest.err conftest.$ac_objext \
13900 conftest$ac_exeext conftest.$ac_ext
13901-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
13902+ if test -z "$lt_cv_aix_libpath_"; then
13903+ lt_cv_aix_libpath_="/usr/lib:/lib"
13904+ fi
13905+
13906+fi
13907+
13908+ aix_libpath=$lt_cv_aix_libpath_
13909+fi
13910
13911 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
13912 # Warning - without using the other run time loading flags,
13913@@ -9357,20 +9897,63 @@ if test -z "$aix_libpath"; then aix_libp
13914 # Microsoft Visual C++.
13915 # hardcode_libdir_flag_spec is actually meaningless, as there is
13916 # no search path for DLLs.
13917- hardcode_libdir_flag_spec=' '
13918- allow_undefined_flag=unsupported
13919- # Tell ltmain to make .lib files, not .a files.
13920- libext=lib
13921- # Tell ltmain to make .dll files, not .so files.
13922- shrext_cmds=".dll"
13923- # FIXME: Setting linknames here is a bad hack.
13924- archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
13925- # The linker will automatically build a .lib file if we build a DLL.
13926- old_archive_from_new_cmds='true'
13927- # FIXME: Should let the user specify the lib program.
13928- old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
13929- fix_srcfile_path='`cygpath -w "$srcfile"`'
13930- enable_shared_with_static_runtimes=yes
13931+ case $cc_basename in
13932+ cl*)
13933+ # Native MSVC
13934+ hardcode_libdir_flag_spec=' '
13935+ allow_undefined_flag=unsupported
13936+ always_export_symbols=yes
13937+ file_list_spec='@'
13938+ # Tell ltmain to make .lib files, not .a files.
13939+ libext=lib
13940+ # Tell ltmain to make .dll files, not .so files.
13941+ shrext_cmds=".dll"
13942+ # FIXME: Setting linknames here is a bad hack.
13943+ archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
13944+ archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
13945+ sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
13946+ else
13947+ sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
13948+ fi~
13949+ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
13950+ linknames='
13951+ # The linker will not automatically build a static lib if we build a DLL.
13952+ # _LT_TAGVAR(old_archive_from_new_cmds, )='true'
13953+ enable_shared_with_static_runtimes=yes
13954+ export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
13955+ # Don't use ranlib
13956+ old_postinstall_cmds='chmod 644 $oldlib'
13957+ postlink_cmds='lt_outputfile="@OUTPUT@"~
13958+ lt_tool_outputfile="@TOOL_OUTPUT@"~
13959+ case $lt_outputfile in
13960+ *.exe|*.EXE) ;;
13961+ *)
13962+ lt_outputfile="$lt_outputfile.exe"
13963+ lt_tool_outputfile="$lt_tool_outputfile.exe"
13964+ ;;
13965+ esac~
13966+ if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
13967+ $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
13968+ $RM "$lt_outputfile.manifest";
13969+ fi'
13970+ ;;
13971+ *)
13972+ # Assume MSVC wrapper
13973+ hardcode_libdir_flag_spec=' '
13974+ allow_undefined_flag=unsupported
13975+ # Tell ltmain to make .lib files, not .a files.
13976+ libext=lib
13977+ # Tell ltmain to make .dll files, not .so files.
13978+ shrext_cmds=".dll"
13979+ # FIXME: Setting linknames here is a bad hack.
13980+ archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
13981+ # The linker will automatically build a .lib file if we build a DLL.
13982+ old_archive_from_new_cmds='true'
13983+ # FIXME: Should let the user specify the lib program.
13984+ old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
13985+ enable_shared_with_static_runtimes=yes
13986+ ;;
13987+ esac
13988 ;;
13989
13990 darwin* | rhapsody*)
13991@@ -9431,7 +10014,7 @@ if test -z "$aix_libpath"; then aix_libp
13992
13993 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
13994 freebsd* | dragonfly*)
13995- archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
13996+ archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
13997 hardcode_libdir_flag_spec='-R$libdir'
13998 hardcode_direct=yes
13999 hardcode_shlibpath_var=no
14000@@ -9439,7 +10022,7 @@ if test -z "$aix_libpath"; then aix_libp
14001
14002 hpux9*)
14003 if test "$GCC" = yes; then
14004- archive_cmds='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
14005+ archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
14006 else
14007 archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
14008 fi
14009@@ -9455,7 +10038,7 @@ if test -z "$aix_libpath"; then aix_libp
14010
14011 hpux10*)
14012 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
14013- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
14014+ archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
14015 else
14016 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
14017 fi
14018@@ -9479,10 +10062,10 @@ if test -z "$aix_libpath"; then aix_libp
14019 archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
14020 ;;
14021 ia64*)
14022- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
14023+ archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
14024 ;;
14025 *)
14026- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
14027+ archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
14028 ;;
14029 esac
14030 else
14031@@ -9561,23 +10144,36 @@ fi
14032
14033 irix5* | irix6* | nonstopux*)
14034 if test "$GCC" = yes; then
14035- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
14036+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
14037 # Try to use the -exported_symbol ld option, if it does not
14038 # work, assume that -exports_file does not work either and
14039 # implicitly export all symbols.
14040- save_LDFLAGS="$LDFLAGS"
14041- LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
14042- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14043+ # This should be the same for all languages, so no per-tag cache variable.
14044+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
14045+$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
14046+if test "${lt_cv_irix_exported_symbol+set}" = set; then :
14047+ $as_echo_n "(cached) " >&6
14048+else
14049+ save_LDFLAGS="$LDFLAGS"
14050+ LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
14051+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14052 /* end confdefs.h. */
14053-int foo(void) {}
14054+int foo (void) { return 0; }
14055 _ACEOF
14056 if ac_fn_c_try_link "$LINENO"; then :
14057- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
14058-
14059+ lt_cv_irix_exported_symbol=yes
14060+else
14061+ lt_cv_irix_exported_symbol=no
14062 fi
14063 rm -f core conftest.err conftest.$ac_objext \
14064 conftest$ac_exeext conftest.$ac_ext
14065- LDFLAGS="$save_LDFLAGS"
14066+ LDFLAGS="$save_LDFLAGS"
14067+fi
14068+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
14069+$as_echo "$lt_cv_irix_exported_symbol" >&6; }
14070+ if test "$lt_cv_irix_exported_symbol" = yes; then
14071+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
14072+ fi
14073 else
14074 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
14075 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
14076@@ -9662,7 +10258,7 @@ rm -f core conftest.err conftest.$ac_obj
14077 osf4* | osf5*) # as osf3* with the addition of -msym flag
14078 if test "$GCC" = yes; then
14079 allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
14080- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
14081+ archive_cmds='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
14082 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
14083 else
14084 allow_undefined_flag=' -expect_unresolved \*'
14085@@ -9681,9 +10277,9 @@ rm -f core conftest.err conftest.$ac_obj
14086 no_undefined_flag=' -z defs'
14087 if test "$GCC" = yes; then
14088 wlarc='${wl}'
14089- archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
14090+ archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
14091 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
14092- $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
14093+ $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
14094 else
14095 case `$CC -V 2>&1` in
14096 *"Compilers 5.0"*)
14097@@ -10259,8 +10855,9 @@ cygwin* | mingw* | pw32* | cegcc*)
14098 need_version=no
14099 need_lib_prefix=no
14100
14101- case $GCC,$host_os in
14102- yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
14103+ case $GCC,$cc_basename in
14104+ yes,*)
14105+ # gcc
14106 library_names_spec='$libname.dll.a'
14107 # DLL is installed to $(libdir)/../bin by postinstall_cmds
14108 postinstall_cmds='base_file=`basename \${file}`~
14109@@ -10293,13 +10890,71 @@ cygwin* | mingw* | pw32* | cegcc*)
14110 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
14111 ;;
14112 esac
14113+ dynamic_linker='Win32 ld.exe'
14114+ ;;
14115+
14116+ *,cl*)
14117+ # Native MSVC
14118+ libname_spec='$name'
14119+ soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
14120+ library_names_spec='${libname}.dll.lib'
14121+
14122+ case $build_os in
14123+ mingw*)
14124+ sys_lib_search_path_spec=
14125+ lt_save_ifs=$IFS
14126+ IFS=';'
14127+ for lt_path in $LIB
14128+ do
14129+ IFS=$lt_save_ifs
14130+ # Let DOS variable expansion print the short 8.3 style file name.
14131+ lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
14132+ sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
14133+ done
14134+ IFS=$lt_save_ifs
14135+ # Convert to MSYS style.
14136+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
14137+ ;;
14138+ cygwin*)
14139+ # Convert to unix form, then to dos form, then back to unix form
14140+ # but this time dos style (no spaces!) so that the unix form looks
14141+ # like /cygdrive/c/PROGRA~1:/cygdr...
14142+ sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
14143+ sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
14144+ sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
14145+ ;;
14146+ *)
14147+ sys_lib_search_path_spec="$LIB"
14148+ if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
14149+ # It is most probably a Windows format PATH.
14150+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
14151+ else
14152+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
14153+ fi
14154+ # FIXME: find the short name or the path components, as spaces are
14155+ # common. (e.g. "Program Files" -> "PROGRA~1")
14156+ ;;
14157+ esac
14158+
14159+ # DLL is installed to $(libdir)/../bin by postinstall_cmds
14160+ postinstall_cmds='base_file=`basename \${file}`~
14161+ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
14162+ dldir=$destdir/`dirname \$dlpath`~
14163+ test -d \$dldir || mkdir -p \$dldir~
14164+ $install_prog $dir/$dlname \$dldir/$dlname'
14165+ postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
14166+ dlpath=$dir/\$dldll~
14167+ $RM \$dlpath'
14168+ shlibpath_overrides_runpath=yes
14169+ dynamic_linker='Win32 link.exe'
14170 ;;
14171
14172 *)
14173+ # Assume MSVC wrapper
14174 library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
14175+ dynamic_linker='Win32 ld.exe'
14176 ;;
14177 esac
14178- dynamic_linker='Win32 ld.exe'
14179 # FIXME: first we should search . and the directory the executable is in
14180 shlibpath_var=PATH
14181 ;;
14182@@ -10391,7 +11046,7 @@ haiku*)
14183 soname_spec='${libname}${release}${shared_ext}$major'
14184 shlibpath_var=LIBRARY_PATH
14185 shlibpath_overrides_runpath=yes
14186- sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/beos/system/lib'
14187+ sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
14188 hardcode_into_libs=yes
14189 ;;
14190
14191@@ -11187,7 +11842,7 @@ else
14192 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
14193 lt_status=$lt_dlunknown
14194 cat > conftest.$ac_ext <<_LT_EOF
14195-#line 11190 "configure"
14196+#line $LINENO "configure"
14197 #include "confdefs.h"
14198
14199 #if HAVE_DLFCN_H
14200@@ -11231,10 +11886,10 @@ else
14201 /* When -fvisbility=hidden is used, assume the code has been annotated
14202 correspondingly for the symbols needed. */
14203 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
14204-void fnord () __attribute__((visibility("default")));
14205+int fnord () __attribute__((visibility("default")));
14206 #endif
14207
14208-void fnord () { int i=42; }
14209+int fnord () { return 42; }
14210 int main ()
14211 {
14212 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
14213@@ -11293,7 +11948,7 @@ else
14214 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
14215 lt_status=$lt_dlunknown
14216 cat > conftest.$ac_ext <<_LT_EOF
14217-#line 11296 "configure"
14218+#line $LINENO "configure"
14219 #include "confdefs.h"
14220
14221 #if HAVE_DLFCN_H
14222@@ -11337,10 +11992,10 @@ else
14223 /* When -fvisbility=hidden is used, assume the code has been annotated
14224 correspondingly for the symbols needed. */
14225 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
14226-void fnord () __attribute__((visibility("default")));
14227+int fnord () __attribute__((visibility("default")));
14228 #endif
14229
14230-void fnord () { int i=42; }
14231+int fnord () { return 42; }
14232 int main ()
14233 {
14234 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
14235@@ -14939,13 +15594,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_
14236 lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
14237 lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
14238 lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
14239+lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
14240+lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
14241 reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
14242 reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
14243 OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
14244 deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
14245 file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
14246+file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
14247+want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
14248+DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
14249+sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
14250 AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
14251 AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
14252+archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
14253 STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
14254 RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
14255 old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
14256@@ -14960,14 +15622,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$l
14257 lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
14258 lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
14259 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
14260+nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
14261+lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
14262 objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
14263 MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
14264 lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
14265-lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
14266 lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
14267+lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
14268 lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
14269 lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
14270 need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
14271+MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
14272 DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
14273 NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
14274 LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
14275@@ -15000,12 +15665,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcod
14276 hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
14277 inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
14278 link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
14279-fix_srcfile_path='`$ECHO "$fix_srcfile_path" | $SED "$delay_single_quote_subst"`'
14280 always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
14281 export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
14282 exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
14283 include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
14284 prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
14285+postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
14286 file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
14287 variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
14288 need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
14289@@ -15060,8 +15725,13 @@ reload_flag \
14290 OBJDUMP \
14291 deplibs_check_method \
14292 file_magic_cmd \
14293+file_magic_glob \
14294+want_nocaseglob \
14295+DLLTOOL \
14296+sharedlib_from_linklib_cmd \
14297 AR \
14298 AR_FLAGS \
14299+archiver_list_spec \
14300 STRIP \
14301 RANLIB \
14302 CC \
14303@@ -15071,12 +15741,14 @@ lt_cv_sys_global_symbol_pipe \
14304 lt_cv_sys_global_symbol_to_cdecl \
14305 lt_cv_sys_global_symbol_to_c_name_address \
14306 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
14307+nm_file_list_spec \
14308 lt_prog_compiler_no_builtin_flag \
14309-lt_prog_compiler_wl \
14310 lt_prog_compiler_pic \
14311+lt_prog_compiler_wl \
14312 lt_prog_compiler_static \
14313 lt_cv_prog_compiler_c_o \
14314 need_locks \
14315+MANIFEST_TOOL \
14316 DSYMUTIL \
14317 NMEDIT \
14318 LIPO \
14319@@ -15092,7 +15764,6 @@ no_undefined_flag \
14320 hardcode_libdir_flag_spec \
14321 hardcode_libdir_flag_spec_ld \
14322 hardcode_libdir_separator \
14323-fix_srcfile_path \
14324 exclude_expsyms \
14325 include_expsyms \
14326 file_list_spec \
14327@@ -15128,6 +15799,7 @@ module_cmds \
14328 module_expsym_cmds \
14329 export_symbols_cmds \
14330 prelink_cmds \
14331+postlink_cmds \
14332 postinstall_cmds \
14333 postuninstall_cmds \
14334 finish_cmds \
14335@@ -15892,7 +16564,8 @@ $as_echo X"$file" |
14336 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
14337 #
14338 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
14339-# 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
14340+# 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
14341+# Inc.
14342 # Written by Gordon Matzigkeit, 1996
14343 #
14344 # This file is part of GNU Libtool.
14345@@ -15995,19 +16668,42 @@ SP2NL=$lt_lt_SP2NL
14346 # turn newlines into spaces.
14347 NL2SP=$lt_lt_NL2SP
14348
14349+# convert \$build file names to \$host format.
14350+to_host_file_cmd=$lt_cv_to_host_file_cmd
14351+
14352+# convert \$build files to toolchain format.
14353+to_tool_file_cmd=$lt_cv_to_tool_file_cmd
14354+
14355 # An object symbol dumper.
14356 OBJDUMP=$lt_OBJDUMP
14357
14358 # Method to check whether dependent libraries are shared objects.
14359 deplibs_check_method=$lt_deplibs_check_method
14360
14361-# Command to use when deplibs_check_method == "file_magic".
14362+# Command to use when deplibs_check_method = "file_magic".
14363 file_magic_cmd=$lt_file_magic_cmd
14364
14365+# How to find potential files when deplibs_check_method = "file_magic".
14366+file_magic_glob=$lt_file_magic_glob
14367+
14368+# Find potential files using nocaseglob when deplibs_check_method = "file_magic".
14369+want_nocaseglob=$lt_want_nocaseglob
14370+
14371+# DLL creation program.
14372+DLLTOOL=$lt_DLLTOOL
14373+
14374+# Command to associate shared and link libraries.
14375+sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
14376+
14377 # The archiver.
14378 AR=$lt_AR
14379+
14380+# Flags to create an archive.
14381 AR_FLAGS=$lt_AR_FLAGS
14382
14383+# How to feed a file listing to the archiver.
14384+archiver_list_spec=$lt_archiver_list_spec
14385+
14386 # A symbol stripping program.
14387 STRIP=$lt_STRIP
14388
14389@@ -16037,6 +16733,12 @@ global_symbol_to_c_name_address=$lt_lt_c
14390 # Transform the output of nm in a C name address pair when lib prefix is needed.
14391 global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
14392
14393+# Specify filename containing input files for \$NM.
14394+nm_file_list_spec=$lt_nm_file_list_spec
14395+
14396+# The root where to search for dependent libraries,and in which our libraries should be installed.
14397+lt_sysroot=$lt_sysroot
14398+
14399 # The name of the directory that contains temporary libtool files.
14400 objdir=$objdir
14401
14402@@ -16046,6 +16748,9 @@ MAGIC_CMD=$MAGIC_CMD
14403 # Must we lock files when doing compilation?
14404 need_locks=$lt_need_locks
14405
14406+# Manifest tool.
14407+MANIFEST_TOOL=$lt_MANIFEST_TOOL
14408+
14409 # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
14410 DSYMUTIL=$lt_DSYMUTIL
14411
14412@@ -16160,12 +16865,12 @@ with_gcc=$GCC
14413 # Compiler flag to turn off builtin functions.
14414 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
14415
14416-# How to pass a linker flag through the compiler.
14417-wl=$lt_lt_prog_compiler_wl
14418-
14419 # Additional compiler flags for building library objects.
14420 pic_flag=$lt_lt_prog_compiler_pic
14421
14422+# How to pass a linker flag through the compiler.
14423+wl=$lt_lt_prog_compiler_wl
14424+
14425 # Compiler flag to prevent dynamic linking.
14426 link_static_flag=$lt_lt_prog_compiler_static
14427
14428@@ -16252,9 +16957,6 @@ inherit_rpath=$inherit_rpath
14429 # Whether libtool must link a program against all its dependency libraries.
14430 link_all_deplibs=$link_all_deplibs
14431
14432-# Fix the shell variable \$srcfile for the compiler.
14433-fix_srcfile_path=$lt_fix_srcfile_path
14434-
14435 # Set to "yes" if exported symbols are required.
14436 always_export_symbols=$always_export_symbols
14437
14438@@ -16270,6 +16972,9 @@ include_expsyms=$lt_include_expsyms
14439 # Commands necessary for linking programs (against libraries) with templates.
14440 prelink_cmds=$lt_prelink_cmds
14441
14442+# Commands necessary for finishing linking programs.
14443+postlink_cmds=$lt_postlink_cmds
14444+
14445 # Specify filename containing input files.
14446 file_list_spec=$lt_file_list_spec
14447
14448@@ -16302,210 +17007,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
14449 # if finds mixed CR/LF and LF-only lines. Since sed operates in
14450 # text mode, it properly converts lines to CR/LF. This bash problem
14451 # is reportedly fixed, but why not run on old versions too?
14452- sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
14453- || (rm -f "$cfgfile"; exit 1)
14454-
14455- case $xsi_shell in
14456- yes)
14457- cat << \_LT_EOF >> "$cfgfile"
14458-
14459-# func_dirname file append nondir_replacement
14460-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
14461-# otherwise set result to NONDIR_REPLACEMENT.
14462-func_dirname ()
14463-{
14464- case ${1} in
14465- */*) func_dirname_result="${1%/*}${2}" ;;
14466- * ) func_dirname_result="${3}" ;;
14467- esac
14468-}
14469-
14470-# func_basename file
14471-func_basename ()
14472-{
14473- func_basename_result="${1##*/}"
14474-}
14475-
14476-# func_dirname_and_basename file append nondir_replacement
14477-# perform func_basename and func_dirname in a single function
14478-# call:
14479-# dirname: Compute the dirname of FILE. If nonempty,
14480-# add APPEND to the result, otherwise set result
14481-# to NONDIR_REPLACEMENT.
14482-# value returned in "$func_dirname_result"
14483-# basename: Compute filename of FILE.
14484-# value retuned in "$func_basename_result"
14485-# Implementation must be kept synchronized with func_dirname
14486-# and func_basename. For efficiency, we do not delegate to
14487-# those functions but instead duplicate the functionality here.
14488-func_dirname_and_basename ()
14489-{
14490- case ${1} in
14491- */*) func_dirname_result="${1%/*}${2}" ;;
14492- * ) func_dirname_result="${3}" ;;
14493- esac
14494- func_basename_result="${1##*/}"
14495-}
14496-
14497-# func_stripname prefix suffix name
14498-# strip PREFIX and SUFFIX off of NAME.
14499-# PREFIX and SUFFIX must not contain globbing or regex special
14500-# characters, hashes, percent signs, but SUFFIX may contain a leading
14501-# dot (in which case that matches only a dot).
14502-func_stripname ()
14503-{
14504- # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
14505- # positional parameters, so assign one to ordinary parameter first.
14506- func_stripname_result=${3}
14507- func_stripname_result=${func_stripname_result#"${1}"}
14508- func_stripname_result=${func_stripname_result%"${2}"}
14509-}
14510-
14511-# func_opt_split
14512-func_opt_split ()
14513-{
14514- func_opt_split_opt=${1%%=*}
14515- func_opt_split_arg=${1#*=}
14516-}
14517-
14518-# func_lo2o object
14519-func_lo2o ()
14520-{
14521- case ${1} in
14522- *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
14523- *) func_lo2o_result=${1} ;;
14524- esac
14525-}
14526-
14527-# func_xform libobj-or-source
14528-func_xform ()
14529-{
14530- func_xform_result=${1%.*}.lo
14531-}
14532-
14533-# func_arith arithmetic-term...
14534-func_arith ()
14535-{
14536- func_arith_result=$(( $* ))
14537-}
14538-
14539-# func_len string
14540-# STRING may not start with a hyphen.
14541-func_len ()
14542-{
14543- func_len_result=${#1}
14544-}
14545-
14546-_LT_EOF
14547- ;;
14548- *) # Bourne compatible functions.
14549- cat << \_LT_EOF >> "$cfgfile"
14550-
14551-# func_dirname file append nondir_replacement
14552-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
14553-# otherwise set result to NONDIR_REPLACEMENT.
14554-func_dirname ()
14555-{
14556- # Extract subdirectory from the argument.
14557- func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
14558- if test "X$func_dirname_result" = "X${1}"; then
14559- func_dirname_result="${3}"
14560- else
14561- func_dirname_result="$func_dirname_result${2}"
14562- fi
14563-}
14564-
14565-# func_basename file
14566-func_basename ()
14567-{
14568- func_basename_result=`$ECHO "${1}" | $SED "$basename"`
14569-}
14570-
14571-
14572-# func_stripname prefix suffix name
14573-# strip PREFIX and SUFFIX off of NAME.
14574-# PREFIX and SUFFIX must not contain globbing or regex special
14575-# characters, hashes, percent signs, but SUFFIX may contain a leading
14576-# dot (in which case that matches only a dot).
14577-# func_strip_suffix prefix name
14578-func_stripname ()
14579-{
14580- case ${2} in
14581- .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
14582- *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
14583- esac
14584-}
14585-
14586-# sed scripts:
14587-my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q'
14588-my_sed_long_arg='1s/^-[^=]*=//'
14589-
14590-# func_opt_split
14591-func_opt_split ()
14592-{
14593- func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"`
14594- func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"`
14595-}
14596-
14597-# func_lo2o object
14598-func_lo2o ()
14599-{
14600- func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
14601-}
14602-
14603-# func_xform libobj-or-source
14604-func_xform ()
14605-{
14606- func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
14607-}
14608-
14609-# func_arith arithmetic-term...
14610-func_arith ()
14611-{
14612- func_arith_result=`expr "$@"`
14613-}
14614-
14615-# func_len string
14616-# STRING may not start with a hyphen.
14617-func_len ()
14618-{
14619- func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len`
14620-}
14621-
14622-_LT_EOF
14623-esac
14624-
14625-case $lt_shell_append in
14626- yes)
14627- cat << \_LT_EOF >> "$cfgfile"
14628-
14629-# func_append var value
14630-# Append VALUE to the end of shell variable VAR.
14631-func_append ()
14632-{
14633- eval "$1+=\$2"
14634-}
14635-_LT_EOF
14636- ;;
14637- *)
14638- cat << \_LT_EOF >> "$cfgfile"
14639-
14640-# func_append var value
14641-# Append VALUE to the end of shell variable VAR.
14642-func_append ()
14643-{
14644- eval "$1=\$$1\$2"
14645-}
14646-
14647-_LT_EOF
14648- ;;
14649- esac
14650+ sed '$q' "$ltmain" >> "$cfgfile" \
14651+ || (rm -f "$cfgfile"; exit 1)
14652
14653+ if test x"$xsi_shell" = xyes; then
14654+ sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
14655+func_dirname ()\
14656+{\
14657+\ case ${1} in\
14658+\ */*) func_dirname_result="${1%/*}${2}" ;;\
14659+\ * ) func_dirname_result="${3}" ;;\
14660+\ esac\
14661+} # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \
14662+ && mv -f "$cfgfile.tmp" "$cfgfile" \
14663+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
14664+test 0 -eq $? || _lt_function_replace_fail=:
14665+
14666+
14667+ sed -e '/^func_basename ()$/,/^} # func_basename /c\
14668+func_basename ()\
14669+{\
14670+\ func_basename_result="${1##*/}"\
14671+} # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \
14672+ && mv -f "$cfgfile.tmp" "$cfgfile" \
14673+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
14674+test 0 -eq $? || _lt_function_replace_fail=:
14675+
14676+
14677+ sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\
14678+func_dirname_and_basename ()\
14679+{\
14680+\ case ${1} in\
14681+\ */*) func_dirname_result="${1%/*}${2}" ;;\
14682+\ * ) func_dirname_result="${3}" ;;\
14683+\ esac\
14684+\ func_basename_result="${1##*/}"\
14685+} # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \
14686+ && mv -f "$cfgfile.tmp" "$cfgfile" \
14687+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
14688+test 0 -eq $? || _lt_function_replace_fail=:
14689+
14690+
14691+ sed -e '/^func_stripname ()$/,/^} # func_stripname /c\
14692+func_stripname ()\
14693+{\
14694+\ # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\
14695+\ # positional parameters, so assign one to ordinary parameter first.\
14696+\ func_stripname_result=${3}\
14697+\ func_stripname_result=${func_stripname_result#"${1}"}\
14698+\ func_stripname_result=${func_stripname_result%"${2}"}\
14699+} # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \
14700+ && mv -f "$cfgfile.tmp" "$cfgfile" \
14701+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
14702+test 0 -eq $? || _lt_function_replace_fail=:
14703+
14704+
14705+ sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\
14706+func_split_long_opt ()\
14707+{\
14708+\ func_split_long_opt_name=${1%%=*}\
14709+\ func_split_long_opt_arg=${1#*=}\
14710+} # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \
14711+ && mv -f "$cfgfile.tmp" "$cfgfile" \
14712+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
14713+test 0 -eq $? || _lt_function_replace_fail=:
14714+
14715+
14716+ sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\
14717+func_split_short_opt ()\
14718+{\
14719+\ func_split_short_opt_arg=${1#??}\
14720+\ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\
14721+} # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \
14722+ && mv -f "$cfgfile.tmp" "$cfgfile" \
14723+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
14724+test 0 -eq $? || _lt_function_replace_fail=:
14725+
14726+
14727+ sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\
14728+func_lo2o ()\
14729+{\
14730+\ case ${1} in\
14731+\ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\
14732+\ *) func_lo2o_result=${1} ;;\
14733+\ esac\
14734+} # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \
14735+ && mv -f "$cfgfile.tmp" "$cfgfile" \
14736+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
14737+test 0 -eq $? || _lt_function_replace_fail=:
14738+
14739+
14740+ sed -e '/^func_xform ()$/,/^} # func_xform /c\
14741+func_xform ()\
14742+{\
14743+ func_xform_result=${1%.*}.lo\
14744+} # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \
14745+ && mv -f "$cfgfile.tmp" "$cfgfile" \
14746+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
14747+test 0 -eq $? || _lt_function_replace_fail=:
14748+
14749+
14750+ sed -e '/^func_arith ()$/,/^} # func_arith /c\
14751+func_arith ()\
14752+{\
14753+ func_arith_result=$(( $* ))\
14754+} # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \
14755+ && mv -f "$cfgfile.tmp" "$cfgfile" \
14756+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
14757+test 0 -eq $? || _lt_function_replace_fail=:
14758+
14759+
14760+ sed -e '/^func_len ()$/,/^} # func_len /c\
14761+func_len ()\
14762+{\
14763+ func_len_result=${#1}\
14764+} # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \
14765+ && mv -f "$cfgfile.tmp" "$cfgfile" \
14766+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
14767+test 0 -eq $? || _lt_function_replace_fail=:
14768+
14769+fi
14770+
14771+if test x"$lt_shell_append" = xyes; then
14772+ sed -e '/^func_append ()$/,/^} # func_append /c\
14773+func_append ()\
14774+{\
14775+ eval "${1}+=\\${2}"\
14776+} # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \
14777+ && mv -f "$cfgfile.tmp" "$cfgfile" \
14778+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
14779+test 0 -eq $? || _lt_function_replace_fail=:
14780+
14781+
14782+ sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\
14783+func_append_quoted ()\
14784+{\
14785+\ func_quote_for_eval "${2}"\
14786+\ eval "${1}+=\\\\ \\$func_quote_for_eval_result"\
14787+} # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \
14788+ && mv -f "$cfgfile.tmp" "$cfgfile" \
14789+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
14790+test 0 -eq $? || _lt_function_replace_fail=:
14791+
14792+
14793+ # Save a `func_append' function call where possible by direct use of '+='
14794+ sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
14795+ && mv -f "$cfgfile.tmp" "$cfgfile" \
14796+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
14797+ test 0 -eq $? || _lt_function_replace_fail=:
14798+else
14799+ # Save a `func_append' function call even when '+=' is not available
14800+ sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
14801+ && mv -f "$cfgfile.tmp" "$cfgfile" \
14802+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
14803+ test 0 -eq $? || _lt_function_replace_fail=:
14804+fi
14805+
14806+if test x"$_lt_function_replace_fail" = x":"; then
14807+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
14808+$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
14809+fi
14810
14811- sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
14812- || (rm -f "$cfgfile"; exit 1)
14813
14814- mv -f "$cfgfile" "$ofile" ||
14815+ mv -f "$cfgfile" "$ofile" ||
14816 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
14817 chmod +x "$ofile"
14818
14819Index: binutils-2.22/gprof/configure
14820===================================================================
14821--- binutils-2.22.orig/gprof/configure
14822+++ binutils-2.22/gprof/configure
14823@@ -629,8 +629,11 @@ OTOOL
14824 LIPO
14825 NMEDIT
14826 DSYMUTIL
14827+MANIFEST_TOOL
14828 RANLIB
14829+ac_ct_AR
14830 AR
14831+DLLTOOL
14832 OBJDUMP
14833 LN_S
14834 NM
14835@@ -743,6 +746,7 @@ enable_static
14836 with_pic
14837 enable_fast_install
14838 with_gnu_ld
14839+with_libtool_sysroot
14840 enable_libtool_lock
14841 enable_nls
14842 enable_maintainer_mode
14843@@ -1397,6 +1401,8 @@ Optional Packages:
14844 --with-pic try to use only PIC/non-PIC objects [default=use
14845 both]
14846 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
14847+ --with-libtool-sysroot=DIR Search for dependent libraries within DIR
14848+ (or the compiler's sysroot if not specified).
14849
14850 Some influential environment variables:
14851 CC C compiler command
14852@@ -5065,8 +5071,8 @@ esac
14853
14854
14855
14856-macro_version='2.2.7a'
14857-macro_revision='1.3134'
14858+macro_version='2.4'
14859+macro_revision='1.3293'
14860
14861
14862
14863@@ -5106,7 +5112,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
14864 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
14865 $as_echo_n "checking how to print strings... " >&6; }
14866 # Test print first, because it will be a builtin if present.
14867-if test "X`print -r -- -n 2>/dev/null`" = X-n && \
14868+if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
14869 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
14870 ECHO='print -r --'
14871 elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
14872@@ -5792,8 +5798,8 @@ $as_echo_n "checking whether the shell u
14873 # Try some XSI features
14874 xsi_shell=no
14875 ( _lt_dummy="a/b/c"
14876- test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
14877- = c,a/b,, \
14878+ test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
14879+ = c,a/b,b/c, \
14880 && eval 'test $(( 1 + 1 )) -eq 2 \
14881 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
14882 && xsi_shell=yes
14883@@ -5842,6 +5848,80 @@ esac
14884
14885
14886
14887+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
14888+$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
14889+if test "${lt_cv_to_host_file_cmd+set}" = set; then :
14890+ $as_echo_n "(cached) " >&6
14891+else
14892+ case $host in
14893+ *-*-mingw* )
14894+ case $build in
14895+ *-*-mingw* ) # actually msys
14896+ lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
14897+ ;;
14898+ *-*-cygwin* )
14899+ lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
14900+ ;;
14901+ * ) # otherwise, assume *nix
14902+ lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
14903+ ;;
14904+ esac
14905+ ;;
14906+ *-*-cygwin* )
14907+ case $build in
14908+ *-*-mingw* ) # actually msys
14909+ lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
14910+ ;;
14911+ *-*-cygwin* )
14912+ lt_cv_to_host_file_cmd=func_convert_file_noop
14913+ ;;
14914+ * ) # otherwise, assume *nix
14915+ lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
14916+ ;;
14917+ esac
14918+ ;;
14919+ * ) # unhandled hosts (and "normal" native builds)
14920+ lt_cv_to_host_file_cmd=func_convert_file_noop
14921+ ;;
14922+esac
14923+
14924+fi
14925+
14926+to_host_file_cmd=$lt_cv_to_host_file_cmd
14927+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
14928+$as_echo "$lt_cv_to_host_file_cmd" >&6; }
14929+
14930+
14931+
14932+
14933+
14934+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
14935+$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
14936+if test "${lt_cv_to_tool_file_cmd+set}" = set; then :
14937+ $as_echo_n "(cached) " >&6
14938+else
14939+ #assume ordinary cross tools, or native build.
14940+lt_cv_to_tool_file_cmd=func_convert_file_noop
14941+case $host in
14942+ *-*-mingw* )
14943+ case $build in
14944+ *-*-mingw* ) # actually msys
14945+ lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
14946+ ;;
14947+ esac
14948+ ;;
14949+esac
14950+
14951+fi
14952+
14953+to_tool_file_cmd=$lt_cv_to_tool_file_cmd
14954+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
14955+$as_echo "$lt_cv_to_tool_file_cmd" >&6; }
14956+
14957+
14958+
14959+
14960+
14961 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
14962 $as_echo_n "checking for $LD option to reload object files... " >&6; }
14963 if test "${lt_cv_ld_reload_flag+set}" = set; then :
14964@@ -5858,6 +5938,11 @@ case $reload_flag in
14965 esac
14966 reload_cmds='$LD$reload_flag -o $output$reload_objs'
14967 case $host_os in
14968+ cygwin* | mingw* | pw32* | cegcc*)
14969+ if test "$GCC" != yes; then
14970+ reload_cmds=false
14971+ fi
14972+ ;;
14973 darwin*)
14974 if test "$GCC" = yes; then
14975 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
14976@@ -6026,7 +6111,8 @@ mingw* | pw32*)
14977 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
14978 lt_cv_file_magic_cmd='func_win32_libid'
14979 else
14980- lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
14981+ # Keep this pattern in sync with the one in func_win32_libid.
14982+ lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
14983 lt_cv_file_magic_cmd='$OBJDUMP -f'
14984 fi
14985 ;;
14986@@ -6103,11 +6189,6 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu)
14987 lt_cv_deplibs_check_method=pass_all
14988 ;;
14989
14990-linux-uclibc*)
14991- lt_cv_deplibs_check_method=pass_all
14992- lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so`
14993- ;;
14994-
14995 netbsd*)
14996 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
14997 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
14998@@ -6185,6 +6266,21 @@ esac
14999 fi
15000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
15001 $as_echo "$lt_cv_deplibs_check_method" >&6; }
15002+
15003+file_magic_glob=
15004+want_nocaseglob=no
15005+if test "$build" = "$host"; then
15006+ case $host_os in
15007+ mingw* | pw32*)
15008+ if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
15009+ want_nocaseglob=yes
15010+ else
15011+ file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
15012+ fi
15013+ ;;
15014+ esac
15015+fi
15016+
15017 file_magic_cmd=$lt_cv_file_magic_cmd
15018 deplibs_check_method=$lt_cv_deplibs_check_method
15019 test -z "$deplibs_check_method" && deplibs_check_method=unknown
15020@@ -6200,9 +6296,162 @@ test -z "$deplibs_check_method" && depli
15021
15022
15023
15024+
15025+
15026+
15027+
15028+
15029+
15030+
15031+
15032+
15033+
15034 if test -n "$ac_tool_prefix"; then
15035- # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
15036-set dummy ${ac_tool_prefix}ar; ac_word=$2
15037+ # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
15038+set dummy ${ac_tool_prefix}dlltool; ac_word=$2
15039+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15040+$as_echo_n "checking for $ac_word... " >&6; }
15041+if test "${ac_cv_prog_DLLTOOL+set}" = set; then :
15042+ $as_echo_n "(cached) " >&6
15043+else
15044+ if test -n "$DLLTOOL"; then
15045+ ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
15046+else
15047+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15048+for as_dir in $PATH
15049+do
15050+ IFS=$as_save_IFS
15051+ test -z "$as_dir" && as_dir=.
15052+ for ac_exec_ext in '' $ac_executable_extensions; do
15053+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
15054+ ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
15055+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15056+ break 2
15057+ fi
15058+done
15059+ done
15060+IFS=$as_save_IFS
15061+
15062+fi
15063+fi
15064+DLLTOOL=$ac_cv_prog_DLLTOOL
15065+if test -n "$DLLTOOL"; then
15066+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
15067+$as_echo "$DLLTOOL" >&6; }
15068+else
15069+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15070+$as_echo "no" >&6; }
15071+fi
15072+
15073+
15074+fi
15075+if test -z "$ac_cv_prog_DLLTOOL"; then
15076+ ac_ct_DLLTOOL=$DLLTOOL
15077+ # Extract the first word of "dlltool", so it can be a program name with args.
15078+set dummy dlltool; ac_word=$2
15079+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15080+$as_echo_n "checking for $ac_word... " >&6; }
15081+if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then :
15082+ $as_echo_n "(cached) " >&6
15083+else
15084+ if test -n "$ac_ct_DLLTOOL"; then
15085+ ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
15086+else
15087+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15088+for as_dir in $PATH
15089+do
15090+ IFS=$as_save_IFS
15091+ test -z "$as_dir" && as_dir=.
15092+ for ac_exec_ext in '' $ac_executable_extensions; do
15093+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
15094+ ac_cv_prog_ac_ct_DLLTOOL="dlltool"
15095+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15096+ break 2
15097+ fi
15098+done
15099+ done
15100+IFS=$as_save_IFS
15101+
15102+fi
15103+fi
15104+ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
15105+if test -n "$ac_ct_DLLTOOL"; then
15106+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
15107+$as_echo "$ac_ct_DLLTOOL" >&6; }
15108+else
15109+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15110+$as_echo "no" >&6; }
15111+fi
15112+
15113+ if test "x$ac_ct_DLLTOOL" = x; then
15114+ DLLTOOL="false"
15115+ else
15116+ case $cross_compiling:$ac_tool_warned in
15117+yes:)
15118+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
15119+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
15120+ac_tool_warned=yes ;;
15121+esac
15122+ DLLTOOL=$ac_ct_DLLTOOL
15123+ fi
15124+else
15125+ DLLTOOL="$ac_cv_prog_DLLTOOL"
15126+fi
15127+
15128+test -z "$DLLTOOL" && DLLTOOL=dlltool
15129+
15130+
15131+
15132+
15133+
15134+
15135+
15136+
15137+
15138+
15139+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
15140+$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
15141+if test "${lt_cv_sharedlib_from_linklib_cmd+set}" = set; then :
15142+ $as_echo_n "(cached) " >&6
15143+else
15144+ lt_cv_sharedlib_from_linklib_cmd='unknown'
15145+
15146+case $host_os in
15147+cygwin* | mingw* | pw32* | cegcc*)
15148+ # two different shell functions defined in ltmain.sh
15149+ # decide which to use based on capabilities of $DLLTOOL
15150+ case `$DLLTOOL --help 2>&1` in
15151+ *--identify-strict*)
15152+ lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
15153+ ;;
15154+ *)
15155+ lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
15156+ ;;
15157+ esac
15158+ ;;
15159+*)
15160+ # fallback: assume linklib IS sharedlib
15161+ lt_cv_sharedlib_from_linklib_cmd="$ECHO"
15162+ ;;
15163+esac
15164+
15165+fi
15166+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
15167+$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
15168+sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
15169+test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
15170+
15171+
15172+
15173+
15174+
15175+
15176+
15177+if test -n "$ac_tool_prefix"; then
15178+ for ac_prog in ar
15179+ do
15180+ # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
15181+set dummy $ac_tool_prefix$ac_prog; ac_word=$2
15182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15183 $as_echo_n "checking for $ac_word... " >&6; }
15184 if test "${ac_cv_prog_AR+set}" = set; then :
15185@@ -6218,7 +6467,7 @@ do
15186 test -z "$as_dir" && as_dir=.
15187 for ac_exec_ext in '' $ac_executable_extensions; do
15188 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
15189- ac_cv_prog_AR="${ac_tool_prefix}ar"
15190+ ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
15191 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15192 break 2
15193 fi
15194@@ -6238,11 +6487,15 @@ $as_echo "no" >&6; }
15195 fi
15196
15197
15198+ test -n "$AR" && break
15199+ done
15200 fi
15201-if test -z "$ac_cv_prog_AR"; then
15202+if test -z "$AR"; then
15203 ac_ct_AR=$AR
15204- # Extract the first word of "ar", so it can be a program name with args.
15205-set dummy ar; ac_word=$2
15206+ for ac_prog in ar
15207+do
15208+ # Extract the first word of "$ac_prog", so it can be a program name with args.
15209+set dummy $ac_prog; ac_word=$2
15210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15211 $as_echo_n "checking for $ac_word... " >&6; }
15212 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
15213@@ -6258,7 +6511,7 @@ do
15214 test -z "$as_dir" && as_dir=.
15215 for ac_exec_ext in '' $ac_executable_extensions; do
15216 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
15217- ac_cv_prog_ac_ct_AR="ar"
15218+ ac_cv_prog_ac_ct_AR="$ac_prog"
15219 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15220 break 2
15221 fi
15222@@ -6277,6 +6530,10 @@ else
15223 $as_echo "no" >&6; }
15224 fi
15225
15226+
15227+ test -n "$ac_ct_AR" && break
15228+done
15229+
15230 if test "x$ac_ct_AR" = x; then
15231 AR="false"
15232 else
15233@@ -6288,16 +6545,72 @@ ac_tool_warned=yes ;;
15234 esac
15235 AR=$ac_ct_AR
15236 fi
15237-else
15238- AR="$ac_cv_prog_AR"
15239 fi
15240
15241-test -z "$AR" && AR=ar
15242-test -z "$AR_FLAGS" && AR_FLAGS=cru
15243+: ${AR=ar}
15244+: ${AR_FLAGS=cru}
15245+
15246+
15247+
15248+
15249+
15250+
15251+
15252+
15253+
15254+
15255+
15256+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
15257+$as_echo_n "checking for archiver @FILE support... " >&6; }
15258+if test "${lt_cv_ar_at_file+set}" = set; then :
15259+ $as_echo_n "(cached) " >&6
15260+else
15261+ lt_cv_ar_at_file=no
15262+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15263+/* end confdefs.h. */
15264+
15265+int
15266+main ()
15267+{
15268
15269+ ;
15270+ return 0;
15271+}
15272+_ACEOF
15273+if ac_fn_c_try_compile "$LINENO"; then :
15274+ echo conftest.$ac_objext > conftest.lst
15275+ lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
15276+ { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
15277+ (eval $lt_ar_try) 2>&5
15278+ ac_status=$?
15279+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
15280+ test $ac_status = 0; }
15281+ if test "$ac_status" -eq 0; then
15282+ # Ensure the archiver fails upon bogus file names.
15283+ rm -f conftest.$ac_objext libconftest.a
15284+ { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
15285+ (eval $lt_ar_try) 2>&5
15286+ ac_status=$?
15287+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
15288+ test $ac_status = 0; }
15289+ if test "$ac_status" -ne 0; then
15290+ lt_cv_ar_at_file=@
15291+ fi
15292+ fi
15293+ rm -f conftest.* libconftest.a
15294
15295+fi
15296+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15297
15298+fi
15299+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
15300+$as_echo "$lt_cv_ar_at_file" >&6; }
15301
15302+if test "x$lt_cv_ar_at_file" = xno; then
15303+ archiver_list_spec=
15304+else
15305+ archiver_list_spec=$lt_cv_ar_at_file
15306+fi
15307
15308
15309
15310@@ -6639,8 +6952,8 @@ esac
15311 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
15312
15313 # Transform an extracted symbol line into symbol name and symbol address
15314-lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
15315-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
15316+lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
15317+lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
15318
15319 # Handle CRLF in mingw tool chain
15320 opt_cr=
15321@@ -6676,6 +6989,7 @@ for ac_symprfx in "" "_"; do
15322 else
15323 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
15324 fi
15325+ lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
15326
15327 # Check to see that the pipe works correctly.
15328 pipe_works=no
15329@@ -6717,6 +7031,18 @@ _LT_EOF
15330 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
15331 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
15332 cat <<_LT_EOF > conftest.$ac_ext
15333+/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
15334+#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
15335+/* DATA imports from DLLs on WIN32 con't be const, because runtime
15336+ relocations are performed -- see ld's documentation on pseudo-relocs. */
15337+# define LT_DLSYM_CONST
15338+#elif defined(__osf__)
15339+/* This system does not cope well with relocations in const data. */
15340+# define LT_DLSYM_CONST
15341+#else
15342+# define LT_DLSYM_CONST const
15343+#endif
15344+
15345 #ifdef __cplusplus
15346 extern "C" {
15347 #endif
15348@@ -6728,7 +7054,7 @@ _LT_EOF
15349 cat <<_LT_EOF >> conftest.$ac_ext
15350
15351 /* The mapping between symbol names and symbols. */
15352-const struct {
15353+LT_DLSYM_CONST struct {
15354 const char *name;
15355 void *address;
15356 }
15357@@ -6754,8 +7080,8 @@ static const void *lt_preloaded_setup()
15358 _LT_EOF
15359 # Now try linking the two files.
15360 mv conftest.$ac_objext conftstm.$ac_objext
15361- lt_save_LIBS="$LIBS"
15362- lt_save_CFLAGS="$CFLAGS"
15363+ lt_globsym_save_LIBS=$LIBS
15364+ lt_globsym_save_CFLAGS=$CFLAGS
15365 LIBS="conftstm.$ac_objext"
15366 CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
15367 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
15368@@ -6765,8 +7091,8 @@ _LT_EOF
15369 test $ac_status = 0; } && test -s conftest${ac_exeext}; then
15370 pipe_works=yes
15371 fi
15372- LIBS="$lt_save_LIBS"
15373- CFLAGS="$lt_save_CFLAGS"
15374+ LIBS=$lt_globsym_save_LIBS
15375+ CFLAGS=$lt_globsym_save_CFLAGS
15376 else
15377 echo "cannot find nm_test_func in $nlist" >&5
15378 fi
15379@@ -6803,6 +7129,17 @@ else
15380 $as_echo "ok" >&6; }
15381 fi
15382
15383+# Response file support.
15384+if test "$lt_cv_nm_interface" = "MS dumpbin"; then
15385+ nm_file_list_spec='@'
15386+elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
15387+ nm_file_list_spec='@'
15388+fi
15389+
15390+
15391+
15392+
15393+
15394
15395
15396
15397@@ -6824,6 +7161,44 @@ fi
15398
15399
15400
15401+
15402+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
15403+$as_echo_n "checking for sysroot... " >&6; }
15404+
15405+# Check whether --with-libtool-sysroot was given.
15406+if test "${with_libtool_sysroot+set}" = set; then :
15407+ withval=$with_libtool_sysroot;
15408+else
15409+ with_libtool_sysroot=no
15410+fi
15411+
15412+
15413+lt_sysroot=
15414+case ${with_libtool_sysroot} in #(
15415+ yes)
15416+ if test "$GCC" = yes; then
15417+ lt_sysroot=`$CC --print-sysroot 2>/dev/null`
15418+ fi
15419+ ;; #(
15420+ /*)
15421+ lt_sysroot=`echo "$with_libtool_sysroot" | sed -e "$sed_quote_subst"`
15422+ ;; #(
15423+ no|'')
15424+ ;; #(
15425+ *)
15426+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libtool_sysroot}" >&5
15427+$as_echo "${with_libtool_sysroot}" >&6; }
15428+ as_fn_error "The sysroot must be an absolute path." "$LINENO" 5
15429+ ;;
15430+esac
15431+
15432+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
15433+$as_echo "${lt_sysroot:-no}" >&6; }
15434+
15435+
15436+
15437+
15438+
15439 # Check whether --enable-libtool-lock was given.
15440 if test "${enable_libtool_lock+set}" = set; then :
15441 enableval=$enable_libtool_lock;
15442@@ -7017,6 +7392,123 @@ esac
15443
15444 need_locks="$enable_libtool_lock"
15445
15446+if test -n "$ac_tool_prefix"; then
15447+ # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
15448+set dummy ${ac_tool_prefix}mt; ac_word=$2
15449+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15450+$as_echo_n "checking for $ac_word... " >&6; }
15451+if test "${ac_cv_prog_MANIFEST_TOOL+set}" = set; then :
15452+ $as_echo_n "(cached) " >&6
15453+else
15454+ if test -n "$MANIFEST_TOOL"; then
15455+ ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
15456+else
15457+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15458+for as_dir in $PATH
15459+do
15460+ IFS=$as_save_IFS
15461+ test -z "$as_dir" && as_dir=.
15462+ for ac_exec_ext in '' $ac_executable_extensions; do
15463+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
15464+ ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
15465+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15466+ break 2
15467+ fi
15468+done
15469+ done
15470+IFS=$as_save_IFS
15471+
15472+fi
15473+fi
15474+MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
15475+if test -n "$MANIFEST_TOOL"; then
15476+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
15477+$as_echo "$MANIFEST_TOOL" >&6; }
15478+else
15479+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15480+$as_echo "no" >&6; }
15481+fi
15482+
15483+
15484+fi
15485+if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
15486+ ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
15487+ # Extract the first word of "mt", so it can be a program name with args.
15488+set dummy mt; ac_word=$2
15489+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15490+$as_echo_n "checking for $ac_word... " >&6; }
15491+if test "${ac_cv_prog_ac_ct_MANIFEST_TOOL+set}" = set; then :
15492+ $as_echo_n "(cached) " >&6
15493+else
15494+ if test -n "$ac_ct_MANIFEST_TOOL"; then
15495+ ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
15496+else
15497+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15498+for as_dir in $PATH
15499+do
15500+ IFS=$as_save_IFS
15501+ test -z "$as_dir" && as_dir=.
15502+ for ac_exec_ext in '' $ac_executable_extensions; do
15503+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
15504+ ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
15505+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15506+ break 2
15507+ fi
15508+done
15509+ done
15510+IFS=$as_save_IFS
15511+
15512+fi
15513+fi
15514+ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
15515+if test -n "$ac_ct_MANIFEST_TOOL"; then
15516+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
15517+$as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
15518+else
15519+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15520+$as_echo "no" >&6; }
15521+fi
15522+
15523+ if test "x$ac_ct_MANIFEST_TOOL" = x; then
15524+ MANIFEST_TOOL=":"
15525+ else
15526+ case $cross_compiling:$ac_tool_warned in
15527+yes:)
15528+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
15529+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
15530+ac_tool_warned=yes ;;
15531+esac
15532+ MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
15533+ fi
15534+else
15535+ MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
15536+fi
15537+
15538+test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
15539+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
15540+$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
15541+if test "${lt_cv_path_mainfest_tool+set}" = set; then :
15542+ $as_echo_n "(cached) " >&6
15543+else
15544+ lt_cv_path_mainfest_tool=no
15545+ echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
15546+ $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
15547+ cat conftest.err >&5
15548+ if $GREP 'Manifest Tool' conftest.out > /dev/null; then
15549+ lt_cv_path_mainfest_tool=yes
15550+ fi
15551+ rm -f conftest*
15552+fi
15553+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
15554+$as_echo "$lt_cv_path_mainfest_tool" >&6; }
15555+if test "x$lt_cv_path_mainfest_tool" != xyes; then
15556+ MANIFEST_TOOL=:
15557+fi
15558+
15559+
15560+
15561+
15562+
15563
15564 case $host_os in
15565 rhapsody* | darwin*)
15566@@ -7580,6 +8072,8 @@ _LT_EOF
15567 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
15568 echo "$AR cru libconftest.a conftest.o" >&5
15569 $AR cru libconftest.a conftest.o 2>&5
15570+ echo "$RANLIB libconftest.a" >&5
15571+ $RANLIB libconftest.a 2>&5
15572 cat > conftest.c << _LT_EOF
15573 int main() { return 0;}
15574 _LT_EOF
15575@@ -7775,7 +8269,8 @@ fi
15576 LIBTOOL_DEPS="$ltmain"
15577
15578 # Always use our own libtool.
15579-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
15580+LIBTOOL='$(SHELL) $(top_builddir)'
15581+LIBTOOL="$LIBTOOL/${host_alias}-libtool"
15582
15583
15584
15585@@ -7864,7 +8359,7 @@ aix3*)
15586 esac
15587
15588 # Global variables:
15589-ofile=libtool
15590+ofile=${host_alias}-libtool
15591 can_build_shared=yes
15592
15593 # All known linkers require a `.a' archive for static linking (except MSVC,
15594@@ -8162,8 +8657,6 @@ fi
15595 lt_prog_compiler_pic=
15596 lt_prog_compiler_static=
15597
15598-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
15599-$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
15600
15601 if test "$GCC" = yes; then
15602 lt_prog_compiler_wl='-Wl,'
15603@@ -8328,6 +8821,12 @@ $as_echo_n "checking for $compiler optio
15604 lt_prog_compiler_pic='--shared'
15605 lt_prog_compiler_static='--static'
15606 ;;
15607+ nagfor*)
15608+ # NAG Fortran compiler
15609+ lt_prog_compiler_wl='-Wl,-Wl,,'
15610+ lt_prog_compiler_pic='-PIC'
15611+ lt_prog_compiler_static='-Bstatic'
15612+ ;;
15613 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
15614 # Portland Group compilers (*not* the Pentium gcc compiler,
15615 # which looks to be a dead project)
15616@@ -8390,7 +8889,7 @@ $as_echo_n "checking for $compiler optio
15617 lt_prog_compiler_pic='-KPIC'
15618 lt_prog_compiler_static='-Bstatic'
15619 case $cc_basename in
15620- f77* | f90* | f95*)
15621+ f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
15622 lt_prog_compiler_wl='-Qoption ld ';;
15623 *)
15624 lt_prog_compiler_wl='-Wl,';;
15625@@ -8447,13 +8946,17 @@ case $host_os in
15626 lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
15627 ;;
15628 esac
15629-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5
15630-$as_echo "$lt_prog_compiler_pic" >&6; }
15631-
15632-
15633-
15634-
15635
15636+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
15637+$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
15638+if test "${lt_cv_prog_compiler_pic+set}" = set; then :
15639+ $as_echo_n "(cached) " >&6
15640+else
15641+ lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
15642+fi
15643+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
15644+$as_echo "$lt_cv_prog_compiler_pic" >&6; }
15645+lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
15646
15647 #
15648 # Check to make sure the PIC flag actually works.
15649@@ -8514,6 +9017,11 @@ fi
15650
15651
15652
15653+
15654+
15655+
15656+
15657+
15658 #
15659 # Check to make sure the static flag actually works.
15660 #
15661@@ -8864,7 +9372,8 @@ _LT_EOF
15662 allow_undefined_flag=unsupported
15663 always_export_symbols=no
15664 enable_shared_with_static_runtimes=yes
15665- export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
15666+ export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
15667+ exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
15668
15669 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
15670 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
15671@@ -8912,7 +9421,7 @@ _LT_EOF
15672 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
15673 && test "$tmp_diet" = no
15674 then
15675- tmp_addflag=
15676+ tmp_addflag=' $pic_flag'
15677 tmp_sharedflag='-shared'
15678 case $cc_basename,$host_cpu in
15679 pgcc*) # Portland Group C compiler
15680@@ -8963,12 +9472,12 @@ _LT_EOF
15681 whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
15682 hardcode_libdir_flag_spec=
15683 hardcode_libdir_flag_spec_ld='-rpath $libdir'
15684- archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
15685+ archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
15686 if test "x$supports_anon_versioning" = xyes; then
15687 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
15688 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
15689 echo "local: *; };" >> $output_objdir/$libname.ver~
15690- $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
15691+ $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
15692 fi
15693 ;;
15694 esac
15695@@ -8982,8 +9491,8 @@ _LT_EOF
15696 archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
15697 wlarc=
15698 else
15699- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
15700- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
15701+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
15702+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
15703 fi
15704 ;;
15705
15706@@ -9001,8 +9510,8 @@ _LT_EOF
15707
15708 _LT_EOF
15709 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
15710- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
15711- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
15712+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
15713+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
15714 else
15715 ld_shlibs=no
15716 fi
15717@@ -9048,8 +9557,8 @@ _LT_EOF
15718
15719 *)
15720 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
15721- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
15722- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
15723+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
15724+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
15725 else
15726 ld_shlibs=no
15727 fi
15728@@ -9179,7 +9688,13 @@ _LT_EOF
15729 allow_undefined_flag='-berok'
15730 # Determine the default libpath from the value encoded in an
15731 # empty executable.
15732- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15733+ if test "${lt_cv_aix_libpath+set}" = set; then
15734+ aix_libpath=$lt_cv_aix_libpath
15735+else
15736+ if test "${lt_cv_aix_libpath_+set}" = set; then :
15737+ $as_echo_n "(cached) " >&6
15738+else
15739+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15740 /* end confdefs.h. */
15741
15742 int
15743@@ -9192,22 +9707,29 @@ main ()
15744 _ACEOF
15745 if ac_fn_c_try_link "$LINENO"; then :
15746
15747-lt_aix_libpath_sed='
15748- /Import File Strings/,/^$/ {
15749- /^0/ {
15750- s/^0 *\(.*\)$/\1/
15751- p
15752- }
15753- }'
15754-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
15755-# Check for a 64-bit object if we didn't find anything.
15756-if test -z "$aix_libpath"; then
15757- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
15758-fi
15759+ lt_aix_libpath_sed='
15760+ /Import File Strings/,/^$/ {
15761+ /^0/ {
15762+ s/^0 *\([^ ]*\) *$/\1/
15763+ p
15764+ }
15765+ }'
15766+ lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
15767+ # Check for a 64-bit object if we didn't find anything.
15768+ if test -z "$lt_cv_aix_libpath_"; then
15769+ lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
15770+ fi
15771 fi
15772 rm -f core conftest.err conftest.$ac_objext \
15773 conftest$ac_exeext conftest.$ac_ext
15774-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
15775+ if test -z "$lt_cv_aix_libpath_"; then
15776+ lt_cv_aix_libpath_="/usr/lib:/lib"
15777+ fi
15778+
15779+fi
15780+
15781+ aix_libpath=$lt_cv_aix_libpath_
15782+fi
15783
15784 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
15785 archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
15786@@ -9219,7 +9741,13 @@ if test -z "$aix_libpath"; then aix_libp
15787 else
15788 # Determine the default libpath from the value encoded in an
15789 # empty executable.
15790- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15791+ if test "${lt_cv_aix_libpath+set}" = set; then
15792+ aix_libpath=$lt_cv_aix_libpath
15793+else
15794+ if test "${lt_cv_aix_libpath_+set}" = set; then :
15795+ $as_echo_n "(cached) " >&6
15796+else
15797+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15798 /* end confdefs.h. */
15799
15800 int
15801@@ -9232,22 +9760,29 @@ main ()
15802 _ACEOF
15803 if ac_fn_c_try_link "$LINENO"; then :
15804
15805-lt_aix_libpath_sed='
15806- /Import File Strings/,/^$/ {
15807- /^0/ {
15808- s/^0 *\(.*\)$/\1/
15809- p
15810- }
15811- }'
15812-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
15813-# Check for a 64-bit object if we didn't find anything.
15814-if test -z "$aix_libpath"; then
15815- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
15816-fi
15817+ lt_aix_libpath_sed='
15818+ /Import File Strings/,/^$/ {
15819+ /^0/ {
15820+ s/^0 *\([^ ]*\) *$/\1/
15821+ p
15822+ }
15823+ }'
15824+ lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
15825+ # Check for a 64-bit object if we didn't find anything.
15826+ if test -z "$lt_cv_aix_libpath_"; then
15827+ lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
15828+ fi
15829 fi
15830 rm -f core conftest.err conftest.$ac_objext \
15831 conftest$ac_exeext conftest.$ac_ext
15832-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
15833+ if test -z "$lt_cv_aix_libpath_"; then
15834+ lt_cv_aix_libpath_="/usr/lib:/lib"
15835+ fi
15836+
15837+fi
15838+
15839+ aix_libpath=$lt_cv_aix_libpath_
15840+fi
15841
15842 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
15843 # Warning - without using the other run time loading flags,
15844@@ -9292,20 +9827,63 @@ if test -z "$aix_libpath"; then aix_libp
15845 # Microsoft Visual C++.
15846 # hardcode_libdir_flag_spec is actually meaningless, as there is
15847 # no search path for DLLs.
15848- hardcode_libdir_flag_spec=' '
15849- allow_undefined_flag=unsupported
15850- # Tell ltmain to make .lib files, not .a files.
15851- libext=lib
15852- # Tell ltmain to make .dll files, not .so files.
15853- shrext_cmds=".dll"
15854- # FIXME: Setting linknames here is a bad hack.
15855- archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
15856- # The linker will automatically build a .lib file if we build a DLL.
15857- old_archive_from_new_cmds='true'
15858- # FIXME: Should let the user specify the lib program.
15859- old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
15860- fix_srcfile_path='`cygpath -w "$srcfile"`'
15861- enable_shared_with_static_runtimes=yes
15862+ case $cc_basename in
15863+ cl*)
15864+ # Native MSVC
15865+ hardcode_libdir_flag_spec=' '
15866+ allow_undefined_flag=unsupported
15867+ always_export_symbols=yes
15868+ file_list_spec='@'
15869+ # Tell ltmain to make .lib files, not .a files.
15870+ libext=lib
15871+ # Tell ltmain to make .dll files, not .so files.
15872+ shrext_cmds=".dll"
15873+ # FIXME: Setting linknames here is a bad hack.
15874+ archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
15875+ archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
15876+ sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
15877+ else
15878+ sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
15879+ fi~
15880+ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
15881+ linknames='
15882+ # The linker will not automatically build a static lib if we build a DLL.
15883+ # _LT_TAGVAR(old_archive_from_new_cmds, )='true'
15884+ enable_shared_with_static_runtimes=yes
15885+ export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
15886+ # Don't use ranlib
15887+ old_postinstall_cmds='chmod 644 $oldlib'
15888+ postlink_cmds='lt_outputfile="@OUTPUT@"~
15889+ lt_tool_outputfile="@TOOL_OUTPUT@"~
15890+ case $lt_outputfile in
15891+ *.exe|*.EXE) ;;
15892+ *)
15893+ lt_outputfile="$lt_outputfile.exe"
15894+ lt_tool_outputfile="$lt_tool_outputfile.exe"
15895+ ;;
15896+ esac~
15897+ if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
15898+ $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
15899+ $RM "$lt_outputfile.manifest";
15900+ fi'
15901+ ;;
15902+ *)
15903+ # Assume MSVC wrapper
15904+ hardcode_libdir_flag_spec=' '
15905+ allow_undefined_flag=unsupported
15906+ # Tell ltmain to make .lib files, not .a files.
15907+ libext=lib
15908+ # Tell ltmain to make .dll files, not .so files.
15909+ shrext_cmds=".dll"
15910+ # FIXME: Setting linknames here is a bad hack.
15911+ archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
15912+ # The linker will automatically build a .lib file if we build a DLL.
15913+ old_archive_from_new_cmds='true'
15914+ # FIXME: Should let the user specify the lib program.
15915+ old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
15916+ enable_shared_with_static_runtimes=yes
15917+ ;;
15918+ esac
15919 ;;
15920
15921 darwin* | rhapsody*)
15922@@ -9366,7 +9944,7 @@ if test -z "$aix_libpath"; then aix_libp
15923
15924 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
15925 freebsd* | dragonfly*)
15926- archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
15927+ archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
15928 hardcode_libdir_flag_spec='-R$libdir'
15929 hardcode_direct=yes
15930 hardcode_shlibpath_var=no
15931@@ -9374,7 +9952,7 @@ if test -z "$aix_libpath"; then aix_libp
15932
15933 hpux9*)
15934 if test "$GCC" = yes; then
15935- archive_cmds='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
15936+ archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
15937 else
15938 archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
15939 fi
15940@@ -9390,7 +9968,7 @@ if test -z "$aix_libpath"; then aix_libp
15941
15942 hpux10*)
15943 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
15944- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
15945+ archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
15946 else
15947 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
15948 fi
15949@@ -9414,10 +9992,10 @@ if test -z "$aix_libpath"; then aix_libp
15950 archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
15951 ;;
15952 ia64*)
15953- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
15954+ archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
15955 ;;
15956 *)
15957- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
15958+ archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
15959 ;;
15960 esac
15961 else
15962@@ -9496,23 +10074,36 @@ fi
15963
15964 irix5* | irix6* | nonstopux*)
15965 if test "$GCC" = yes; then
15966- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
15967+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
15968 # Try to use the -exported_symbol ld option, if it does not
15969 # work, assume that -exports_file does not work either and
15970 # implicitly export all symbols.
15971- save_LDFLAGS="$LDFLAGS"
15972- LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
15973- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15974+ # This should be the same for all languages, so no per-tag cache variable.
15975+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
15976+$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
15977+if test "${lt_cv_irix_exported_symbol+set}" = set; then :
15978+ $as_echo_n "(cached) " >&6
15979+else
15980+ save_LDFLAGS="$LDFLAGS"
15981+ LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
15982+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15983 /* end confdefs.h. */
15984-int foo(void) {}
15985+int foo (void) { return 0; }
15986 _ACEOF
15987 if ac_fn_c_try_link "$LINENO"; then :
15988- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
15989-
15990+ lt_cv_irix_exported_symbol=yes
15991+else
15992+ lt_cv_irix_exported_symbol=no
15993 fi
15994 rm -f core conftest.err conftest.$ac_objext \
15995 conftest$ac_exeext conftest.$ac_ext
15996- LDFLAGS="$save_LDFLAGS"
15997+ LDFLAGS="$save_LDFLAGS"
15998+fi
15999+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
16000+$as_echo "$lt_cv_irix_exported_symbol" >&6; }
16001+ if test "$lt_cv_irix_exported_symbol" = yes; then
16002+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
16003+ fi
16004 else
16005 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
16006 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
16007@@ -9597,7 +10188,7 @@ rm -f core conftest.err conftest.$ac_obj
16008 osf4* | osf5*) # as osf3* with the addition of -msym flag
16009 if test "$GCC" = yes; then
16010 allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
16011- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
16012+ archive_cmds='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
16013 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
16014 else
16015 allow_undefined_flag=' -expect_unresolved \*'
16016@@ -9616,9 +10207,9 @@ rm -f core conftest.err conftest.$ac_obj
16017 no_undefined_flag=' -z defs'
16018 if test "$GCC" = yes; then
16019 wlarc='${wl}'
16020- archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
16021+ archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
16022 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
16023- $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
16024+ $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
16025 else
16026 case `$CC -V 2>&1` in
16027 *"Compilers 5.0"*)
16028@@ -10194,8 +10785,9 @@ cygwin* | mingw* | pw32* | cegcc*)
16029 need_version=no
16030 need_lib_prefix=no
16031
16032- case $GCC,$host_os in
16033- yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
16034+ case $GCC,$cc_basename in
16035+ yes,*)
16036+ # gcc
16037 library_names_spec='$libname.dll.a'
16038 # DLL is installed to $(libdir)/../bin by postinstall_cmds
16039 postinstall_cmds='base_file=`basename \${file}`~
16040@@ -10228,13 +10820,71 @@ cygwin* | mingw* | pw32* | cegcc*)
16041 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
16042 ;;
16043 esac
16044+ dynamic_linker='Win32 ld.exe'
16045+ ;;
16046+
16047+ *,cl*)
16048+ # Native MSVC
16049+ libname_spec='$name'
16050+ soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
16051+ library_names_spec='${libname}.dll.lib'
16052+
16053+ case $build_os in
16054+ mingw*)
16055+ sys_lib_search_path_spec=
16056+ lt_save_ifs=$IFS
16057+ IFS=';'
16058+ for lt_path in $LIB
16059+ do
16060+ IFS=$lt_save_ifs
16061+ # Let DOS variable expansion print the short 8.3 style file name.
16062+ lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
16063+ sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
16064+ done
16065+ IFS=$lt_save_ifs
16066+ # Convert to MSYS style.
16067+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
16068+ ;;
16069+ cygwin*)
16070+ # Convert to unix form, then to dos form, then back to unix form
16071+ # but this time dos style (no spaces!) so that the unix form looks
16072+ # like /cygdrive/c/PROGRA~1:/cygdr...
16073+ sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
16074+ sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
16075+ sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
16076+ ;;
16077+ *)
16078+ sys_lib_search_path_spec="$LIB"
16079+ if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
16080+ # It is most probably a Windows format PATH.
16081+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
16082+ else
16083+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
16084+ fi
16085+ # FIXME: find the short name or the path components, as spaces are
16086+ # common. (e.g. "Program Files" -> "PROGRA~1")
16087+ ;;
16088+ esac
16089+
16090+ # DLL is installed to $(libdir)/../bin by postinstall_cmds
16091+ postinstall_cmds='base_file=`basename \${file}`~
16092+ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
16093+ dldir=$destdir/`dirname \$dlpath`~
16094+ test -d \$dldir || mkdir -p \$dldir~
16095+ $install_prog $dir/$dlname \$dldir/$dlname'
16096+ postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
16097+ dlpath=$dir/\$dldll~
16098+ $RM \$dlpath'
16099+ shlibpath_overrides_runpath=yes
16100+ dynamic_linker='Win32 link.exe'
16101 ;;
16102
16103 *)
16104+ # Assume MSVC wrapper
16105 library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
16106+ dynamic_linker='Win32 ld.exe'
16107 ;;
16108 esac
16109- dynamic_linker='Win32 ld.exe'
16110 # FIXME: first we should search . and the directory the executable is in
16111 shlibpath_var=PATH
16112 ;;
16113@@ -10326,7 +10976,7 @@ haiku*)
16114 soname_spec='${libname}${release}${shared_ext}$major'
16115 shlibpath_var=LIBRARY_PATH
16116 shlibpath_overrides_runpath=yes
16117- sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/beos/system/lib'
16118+ sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
16119 hardcode_into_libs=yes
16120 ;;
16121
16122@@ -11122,7 +11772,7 @@ else
16123 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
16124 lt_status=$lt_dlunknown
16125 cat > conftest.$ac_ext <<_LT_EOF
16126-#line 11120 "configure"
16127+#line $LINENO "configure"
16128 #include "confdefs.h"
16129
16130 #if HAVE_DLFCN_H
16131@@ -11166,10 +11816,10 @@ else
16132 /* When -fvisbility=hidden is used, assume the code has been annotated
16133 correspondingly for the symbols needed. */
16134 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
16135-void fnord () __attribute__((visibility("default")));
16136+int fnord () __attribute__((visibility("default")));
16137 #endif
16138
16139-void fnord () { int i=42; }
16140+int fnord () { return 42; }
16141 int main ()
16142 {
16143 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
16144@@ -11228,7 +11878,7 @@ else
16145 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
16146 lt_status=$lt_dlunknown
16147 cat > conftest.$ac_ext <<_LT_EOF
16148-#line 11226 "configure"
16149+#line $LINENO "configure"
16150 #include "confdefs.h"
16151
16152 #if HAVE_DLFCN_H
16153@@ -11272,10 +11922,10 @@ else
16154 /* When -fvisbility=hidden is used, assume the code has been annotated
16155 correspondingly for the symbols needed. */
16156 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
16157-void fnord () __attribute__((visibility("default")));
16158+int fnord () __attribute__((visibility("default")));
16159 #endif
16160
16161-void fnord () { int i=42; }
16162+int fnord () { return 42; }
16163 int main ()
16164 {
16165 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
16166@@ -12817,13 +13467,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_
16167 lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
16168 lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
16169 lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
16170+lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
16171+lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
16172 reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
16173 reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
16174 OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
16175 deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
16176 file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
16177+file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
16178+want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
16179+DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
16180+sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
16181 AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
16182 AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
16183+archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
16184 STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
16185 RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
16186 old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
16187@@ -12838,14 +13495,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$l
16188 lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
16189 lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
16190 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
16191+nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
16192+lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
16193 objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
16194 MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
16195 lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
16196-lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
16197 lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
16198+lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
16199 lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
16200 lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
16201 need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
16202+MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
16203 DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
16204 NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
16205 LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
16206@@ -12878,12 +13538,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcod
16207 hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
16208 inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
16209 link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
16210-fix_srcfile_path='`$ECHO "$fix_srcfile_path" | $SED "$delay_single_quote_subst"`'
16211 always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
16212 export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
16213 exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
16214 include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
16215 prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
16216+postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
16217 file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
16218 variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
16219 need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
16220@@ -12938,8 +13598,13 @@ reload_flag \
16221 OBJDUMP \
16222 deplibs_check_method \
16223 file_magic_cmd \
16224+file_magic_glob \
16225+want_nocaseglob \
16226+DLLTOOL \
16227+sharedlib_from_linklib_cmd \
16228 AR \
16229 AR_FLAGS \
16230+archiver_list_spec \
16231 STRIP \
16232 RANLIB \
16233 CC \
16234@@ -12949,12 +13614,14 @@ lt_cv_sys_global_symbol_pipe \
16235 lt_cv_sys_global_symbol_to_cdecl \
16236 lt_cv_sys_global_symbol_to_c_name_address \
16237 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
16238+nm_file_list_spec \
16239 lt_prog_compiler_no_builtin_flag \
16240-lt_prog_compiler_wl \
16241 lt_prog_compiler_pic \
16242+lt_prog_compiler_wl \
16243 lt_prog_compiler_static \
16244 lt_cv_prog_compiler_c_o \
16245 need_locks \
16246+MANIFEST_TOOL \
16247 DSYMUTIL \
16248 NMEDIT \
16249 LIPO \
16250@@ -12970,7 +13637,6 @@ no_undefined_flag \
16251 hardcode_libdir_flag_spec \
16252 hardcode_libdir_flag_spec_ld \
16253 hardcode_libdir_separator \
16254-fix_srcfile_path \
16255 exclude_expsyms \
16256 include_expsyms \
16257 file_list_spec \
16258@@ -13006,6 +13672,7 @@ module_cmds \
16259 module_expsym_cmds \
16260 export_symbols_cmds \
16261 prelink_cmds \
16262+postlink_cmds \
16263 postinstall_cmds \
16264 postuninstall_cmds \
16265 finish_cmds \
16266@@ -13762,7 +14429,8 @@ $as_echo X"$file" |
16267 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
16268 #
16269 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
16270-# 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
16271+# 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
16272+# Inc.
16273 # Written by Gordon Matzigkeit, 1996
16274 #
16275 # This file is part of GNU Libtool.
16276@@ -13865,19 +14533,42 @@ SP2NL=$lt_lt_SP2NL
16277 # turn newlines into spaces.
16278 NL2SP=$lt_lt_NL2SP
16279
16280+# convert \$build file names to \$host format.
16281+to_host_file_cmd=$lt_cv_to_host_file_cmd
16282+
16283+# convert \$build files to toolchain format.
16284+to_tool_file_cmd=$lt_cv_to_tool_file_cmd
16285+
16286 # An object symbol dumper.
16287 OBJDUMP=$lt_OBJDUMP
16288
16289 # Method to check whether dependent libraries are shared objects.
16290 deplibs_check_method=$lt_deplibs_check_method
16291
16292-# Command to use when deplibs_check_method == "file_magic".
16293+# Command to use when deplibs_check_method = "file_magic".
16294 file_magic_cmd=$lt_file_magic_cmd
16295
16296+# How to find potential files when deplibs_check_method = "file_magic".
16297+file_magic_glob=$lt_file_magic_glob
16298+
16299+# Find potential files using nocaseglob when deplibs_check_method = "file_magic".
16300+want_nocaseglob=$lt_want_nocaseglob
16301+
16302+# DLL creation program.
16303+DLLTOOL=$lt_DLLTOOL
16304+
16305+# Command to associate shared and link libraries.
16306+sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
16307+
16308 # The archiver.
16309 AR=$lt_AR
16310+
16311+# Flags to create an archive.
16312 AR_FLAGS=$lt_AR_FLAGS
16313
16314+# How to feed a file listing to the archiver.
16315+archiver_list_spec=$lt_archiver_list_spec
16316+
16317 # A symbol stripping program.
16318 STRIP=$lt_STRIP
16319
16320@@ -13907,6 +14598,12 @@ global_symbol_to_c_name_address=$lt_lt_c
16321 # Transform the output of nm in a C name address pair when lib prefix is needed.
16322 global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
16323
16324+# Specify filename containing input files for \$NM.
16325+nm_file_list_spec=$lt_nm_file_list_spec
16326+
16327+# The root where to search for dependent libraries,and in which our libraries should be installed.
16328+lt_sysroot=$lt_sysroot
16329+
16330 # The name of the directory that contains temporary libtool files.
16331 objdir=$objdir
16332
16333@@ -13916,6 +14613,9 @@ MAGIC_CMD=$MAGIC_CMD
16334 # Must we lock files when doing compilation?
16335 need_locks=$lt_need_locks
16336
16337+# Manifest tool.
16338+MANIFEST_TOOL=$lt_MANIFEST_TOOL
16339+
16340 # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
16341 DSYMUTIL=$lt_DSYMUTIL
16342
16343@@ -14030,12 +14730,12 @@ with_gcc=$GCC
16344 # Compiler flag to turn off builtin functions.
16345 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
16346
16347-# How to pass a linker flag through the compiler.
16348-wl=$lt_lt_prog_compiler_wl
16349-
16350 # Additional compiler flags for building library objects.
16351 pic_flag=$lt_lt_prog_compiler_pic
16352
16353+# How to pass a linker flag through the compiler.
16354+wl=$lt_lt_prog_compiler_wl
16355+
16356 # Compiler flag to prevent dynamic linking.
16357 link_static_flag=$lt_lt_prog_compiler_static
16358
16359@@ -14122,9 +14822,6 @@ inherit_rpath=$inherit_rpath
16360 # Whether libtool must link a program against all its dependency libraries.
16361 link_all_deplibs=$link_all_deplibs
16362
16363-# Fix the shell variable \$srcfile for the compiler.
16364-fix_srcfile_path=$lt_fix_srcfile_path
16365-
16366 # Set to "yes" if exported symbols are required.
16367 always_export_symbols=$always_export_symbols
16368
16369@@ -14140,6 +14837,9 @@ include_expsyms=$lt_include_expsyms
16370 # Commands necessary for linking programs (against libraries) with templates.
16371 prelink_cmds=$lt_prelink_cmds
16372
16373+# Commands necessary for finishing linking programs.
16374+postlink_cmds=$lt_postlink_cmds
16375+
16376 # Specify filename containing input files.
16377 file_list_spec=$lt_file_list_spec
16378
16379@@ -14172,210 +14872,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
16380 # if finds mixed CR/LF and LF-only lines. Since sed operates in
16381 # text mode, it properly converts lines to CR/LF. This bash problem
16382 # is reportedly fixed, but why not run on old versions too?
16383- sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
16384- || (rm -f "$cfgfile"; exit 1)
16385-
16386- case $xsi_shell in
16387- yes)
16388- cat << \_LT_EOF >> "$cfgfile"
16389-
16390-# func_dirname file append nondir_replacement
16391-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
16392-# otherwise set result to NONDIR_REPLACEMENT.
16393-func_dirname ()
16394-{
16395- case ${1} in
16396- */*) func_dirname_result="${1%/*}${2}" ;;
16397- * ) func_dirname_result="${3}" ;;
16398- esac
16399-}
16400-
16401-# func_basename file
16402-func_basename ()
16403-{
16404- func_basename_result="${1##*/}"
16405-}
16406-
16407-# func_dirname_and_basename file append nondir_replacement
16408-# perform func_basename and func_dirname in a single function
16409-# call:
16410-# dirname: Compute the dirname of FILE. If nonempty,
16411-# add APPEND to the result, otherwise set result
16412-# to NONDIR_REPLACEMENT.
16413-# value returned in "$func_dirname_result"
16414-# basename: Compute filename of FILE.
16415-# value retuned in "$func_basename_result"
16416-# Implementation must be kept synchronized with func_dirname
16417-# and func_basename. For efficiency, we do not delegate to
16418-# those functions but instead duplicate the functionality here.
16419-func_dirname_and_basename ()
16420-{
16421- case ${1} in
16422- */*) func_dirname_result="${1%/*}${2}" ;;
16423- * ) func_dirname_result="${3}" ;;
16424- esac
16425- func_basename_result="${1##*/}"
16426-}
16427-
16428-# func_stripname prefix suffix name
16429-# strip PREFIX and SUFFIX off of NAME.
16430-# PREFIX and SUFFIX must not contain globbing or regex special
16431-# characters, hashes, percent signs, but SUFFIX may contain a leading
16432-# dot (in which case that matches only a dot).
16433-func_stripname ()
16434-{
16435- # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
16436- # positional parameters, so assign one to ordinary parameter first.
16437- func_stripname_result=${3}
16438- func_stripname_result=${func_stripname_result#"${1}"}
16439- func_stripname_result=${func_stripname_result%"${2}"}
16440-}
16441-
16442-# func_opt_split
16443-func_opt_split ()
16444-{
16445- func_opt_split_opt=${1%%=*}
16446- func_opt_split_arg=${1#*=}
16447-}
16448-
16449-# func_lo2o object
16450-func_lo2o ()
16451-{
16452- case ${1} in
16453- *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
16454- *) func_lo2o_result=${1} ;;
16455- esac
16456-}
16457-
16458-# func_xform libobj-or-source
16459-func_xform ()
16460-{
16461- func_xform_result=${1%.*}.lo
16462-}
16463-
16464-# func_arith arithmetic-term...
16465-func_arith ()
16466-{
16467- func_arith_result=$(( $* ))
16468-}
16469-
16470-# func_len string
16471-# STRING may not start with a hyphen.
16472-func_len ()
16473-{
16474- func_len_result=${#1}
16475-}
16476-
16477-_LT_EOF
16478- ;;
16479- *) # Bourne compatible functions.
16480- cat << \_LT_EOF >> "$cfgfile"
16481-
16482-# func_dirname file append nondir_replacement
16483-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
16484-# otherwise set result to NONDIR_REPLACEMENT.
16485-func_dirname ()
16486-{
16487- # Extract subdirectory from the argument.
16488- func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
16489- if test "X$func_dirname_result" = "X${1}"; then
16490- func_dirname_result="${3}"
16491- else
16492- func_dirname_result="$func_dirname_result${2}"
16493- fi
16494-}
16495-
16496-# func_basename file
16497-func_basename ()
16498-{
16499- func_basename_result=`$ECHO "${1}" | $SED "$basename"`
16500-}
16501-
16502-
16503-# func_stripname prefix suffix name
16504-# strip PREFIX and SUFFIX off of NAME.
16505-# PREFIX and SUFFIX must not contain globbing or regex special
16506-# characters, hashes, percent signs, but SUFFIX may contain a leading
16507-# dot (in which case that matches only a dot).
16508-# func_strip_suffix prefix name
16509-func_stripname ()
16510-{
16511- case ${2} in
16512- .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
16513- *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
16514- esac
16515-}
16516-
16517-# sed scripts:
16518-my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q'
16519-my_sed_long_arg='1s/^-[^=]*=//'
16520-
16521-# func_opt_split
16522-func_opt_split ()
16523-{
16524- func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"`
16525- func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"`
16526-}
16527-
16528-# func_lo2o object
16529-func_lo2o ()
16530-{
16531- func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
16532-}
16533-
16534-# func_xform libobj-or-source
16535-func_xform ()
16536-{
16537- func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
16538-}
16539-
16540-# func_arith arithmetic-term...
16541-func_arith ()
16542-{
16543- func_arith_result=`expr "$@"`
16544-}
16545-
16546-# func_len string
16547-# STRING may not start with a hyphen.
16548-func_len ()
16549-{
16550- func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len`
16551-}
16552-
16553-_LT_EOF
16554-esac
16555-
16556-case $lt_shell_append in
16557- yes)
16558- cat << \_LT_EOF >> "$cfgfile"
16559-
16560-# func_append var value
16561-# Append VALUE to the end of shell variable VAR.
16562-func_append ()
16563-{
16564- eval "$1+=\$2"
16565-}
16566-_LT_EOF
16567- ;;
16568- *)
16569- cat << \_LT_EOF >> "$cfgfile"
16570-
16571-# func_append var value
16572-# Append VALUE to the end of shell variable VAR.
16573-func_append ()
16574-{
16575- eval "$1=\$$1\$2"
16576-}
16577-
16578-_LT_EOF
16579- ;;
16580- esac
16581+ sed '$q' "$ltmain" >> "$cfgfile" \
16582+ || (rm -f "$cfgfile"; exit 1)
16583
16584+ if test x"$xsi_shell" = xyes; then
16585+ sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
16586+func_dirname ()\
16587+{\
16588+\ case ${1} in\
16589+\ */*) func_dirname_result="${1%/*}${2}" ;;\
16590+\ * ) func_dirname_result="${3}" ;;\
16591+\ esac\
16592+} # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \
16593+ && mv -f "$cfgfile.tmp" "$cfgfile" \
16594+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
16595+test 0 -eq $? || _lt_function_replace_fail=:
16596+
16597+
16598+ sed -e '/^func_basename ()$/,/^} # func_basename /c\
16599+func_basename ()\
16600+{\
16601+\ func_basename_result="${1##*/}"\
16602+} # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \
16603+ && mv -f "$cfgfile.tmp" "$cfgfile" \
16604+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
16605+test 0 -eq $? || _lt_function_replace_fail=:
16606+
16607+
16608+ sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\
16609+func_dirname_and_basename ()\
16610+{\
16611+\ case ${1} in\
16612+\ */*) func_dirname_result="${1%/*}${2}" ;;\
16613+\ * ) func_dirname_result="${3}" ;;\
16614+\ esac\
16615+\ func_basename_result="${1##*/}"\
16616+} # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \
16617+ && mv -f "$cfgfile.tmp" "$cfgfile" \
16618+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
16619+test 0 -eq $? || _lt_function_replace_fail=:
16620+
16621+
16622+ sed -e '/^func_stripname ()$/,/^} # func_stripname /c\
16623+func_stripname ()\
16624+{\
16625+\ # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\
16626+\ # positional parameters, so assign one to ordinary parameter first.\
16627+\ func_stripname_result=${3}\
16628+\ func_stripname_result=${func_stripname_result#"${1}"}\
16629+\ func_stripname_result=${func_stripname_result%"${2}"}\
16630+} # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \
16631+ && mv -f "$cfgfile.tmp" "$cfgfile" \
16632+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
16633+test 0 -eq $? || _lt_function_replace_fail=:
16634+
16635+
16636+ sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\
16637+func_split_long_opt ()\
16638+{\
16639+\ func_split_long_opt_name=${1%%=*}\
16640+\ func_split_long_opt_arg=${1#*=}\
16641+} # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \
16642+ && mv -f "$cfgfile.tmp" "$cfgfile" \
16643+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
16644+test 0 -eq $? || _lt_function_replace_fail=:
16645+
16646+
16647+ sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\
16648+func_split_short_opt ()\
16649+{\
16650+\ func_split_short_opt_arg=${1#??}\
16651+\ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\
16652+} # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \
16653+ && mv -f "$cfgfile.tmp" "$cfgfile" \
16654+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
16655+test 0 -eq $? || _lt_function_replace_fail=:
16656+
16657+
16658+ sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\
16659+func_lo2o ()\
16660+{\
16661+\ case ${1} in\
16662+\ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\
16663+\ *) func_lo2o_result=${1} ;;\
16664+\ esac\
16665+} # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \
16666+ && mv -f "$cfgfile.tmp" "$cfgfile" \
16667+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
16668+test 0 -eq $? || _lt_function_replace_fail=:
16669+
16670+
16671+ sed -e '/^func_xform ()$/,/^} # func_xform /c\
16672+func_xform ()\
16673+{\
16674+ func_xform_result=${1%.*}.lo\
16675+} # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \
16676+ && mv -f "$cfgfile.tmp" "$cfgfile" \
16677+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
16678+test 0 -eq $? || _lt_function_replace_fail=:
16679+
16680+
16681+ sed -e '/^func_arith ()$/,/^} # func_arith /c\
16682+func_arith ()\
16683+{\
16684+ func_arith_result=$(( $* ))\
16685+} # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \
16686+ && mv -f "$cfgfile.tmp" "$cfgfile" \
16687+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
16688+test 0 -eq $? || _lt_function_replace_fail=:
16689+
16690+
16691+ sed -e '/^func_len ()$/,/^} # func_len /c\
16692+func_len ()\
16693+{\
16694+ func_len_result=${#1}\
16695+} # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \
16696+ && mv -f "$cfgfile.tmp" "$cfgfile" \
16697+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
16698+test 0 -eq $? || _lt_function_replace_fail=:
16699+
16700+fi
16701+
16702+if test x"$lt_shell_append" = xyes; then
16703+ sed -e '/^func_append ()$/,/^} # func_append /c\
16704+func_append ()\
16705+{\
16706+ eval "${1}+=\\${2}"\
16707+} # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \
16708+ && mv -f "$cfgfile.tmp" "$cfgfile" \
16709+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
16710+test 0 -eq $? || _lt_function_replace_fail=:
16711+
16712+
16713+ sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\
16714+func_append_quoted ()\
16715+{\
16716+\ func_quote_for_eval "${2}"\
16717+\ eval "${1}+=\\\\ \\$func_quote_for_eval_result"\
16718+} # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \
16719+ && mv -f "$cfgfile.tmp" "$cfgfile" \
16720+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
16721+test 0 -eq $? || _lt_function_replace_fail=:
16722+
16723+
16724+ # Save a `func_append' function call where possible by direct use of '+='
16725+ sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
16726+ && mv -f "$cfgfile.tmp" "$cfgfile" \
16727+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
16728+ test 0 -eq $? || _lt_function_replace_fail=:
16729+else
16730+ # Save a `func_append' function call even when '+=' is not available
16731+ sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
16732+ && mv -f "$cfgfile.tmp" "$cfgfile" \
16733+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
16734+ test 0 -eq $? || _lt_function_replace_fail=:
16735+fi
16736+
16737+if test x"$_lt_function_replace_fail" = x":"; then
16738+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
16739+$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
16740+fi
16741
16742- sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
16743- || (rm -f "$cfgfile"; exit 1)
16744
16745- mv -f "$cfgfile" "$ofile" ||
16746+ mv -f "$cfgfile" "$ofile" ||
16747 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
16748 chmod +x "$ofile"
16749
16750Index: binutils-2.22/ld/configure
16751===================================================================
16752--- binutils-2.22.orig/ld/configure
16753+++ binutils-2.22/ld/configure
16754@@ -645,8 +645,11 @@ OTOOL
16755 LIPO
16756 NMEDIT
16757 DSYMUTIL
16758+MANIFEST_TOOL
16759 RANLIB
16760+ac_ct_AR
16761 AR
16762+DLLTOOL
16763 OBJDUMP
16764 LN_S
16765 NM
16766@@ -784,6 +787,7 @@ enable_static
16767 with_pic
16768 enable_fast_install
16769 with_gnu_ld
16770+with_libtool_sysroot
16771 enable_libtool_lock
16772 enable_nls
16773 enable_initfini_array
16774@@ -1450,6 +1454,8 @@ Optional Packages:
16775 --with-pic try to use only PIC/non-PIC objects [default=use
16776 both]
16777 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
16778+ --with-libtool-sysroot=DIR Search for dependent libraries within DIR
16779+ (or the compiler's sysroot if not specified).
16780
16781 Some influential environment variables:
16782 CC C compiler command
16783@@ -6085,8 +6091,8 @@ esac
16784
16785
16786
16787-macro_version='2.2.7a'
16788-macro_revision='1.3134'
16789+macro_version='2.4'
16790+macro_revision='1.3293'
16791
16792
16793
16794@@ -6126,7 +6132,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
16795 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
16796 $as_echo_n "checking how to print strings... " >&6; }
16797 # Test print first, because it will be a builtin if present.
16798-if test "X`print -r -- -n 2>/dev/null`" = X-n && \
16799+if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
16800 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
16801 ECHO='print -r --'
16802 elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
16803@@ -6812,8 +6818,8 @@ $as_echo_n "checking whether the shell u
16804 # Try some XSI features
16805 xsi_shell=no
16806 ( _lt_dummy="a/b/c"
16807- test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
16808- = c,a/b,, \
16809+ test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
16810+ = c,a/b,b/c, \
16811 && eval 'test $(( 1 + 1 )) -eq 2 \
16812 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
16813 && xsi_shell=yes
16814@@ -6862,6 +6868,80 @@ esac
16815
16816
16817
16818+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
16819+$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
16820+if test "${lt_cv_to_host_file_cmd+set}" = set; then :
16821+ $as_echo_n "(cached) " >&6
16822+else
16823+ case $host in
16824+ *-*-mingw* )
16825+ case $build in
16826+ *-*-mingw* ) # actually msys
16827+ lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
16828+ ;;
16829+ *-*-cygwin* )
16830+ lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
16831+ ;;
16832+ * ) # otherwise, assume *nix
16833+ lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
16834+ ;;
16835+ esac
16836+ ;;
16837+ *-*-cygwin* )
16838+ case $build in
16839+ *-*-mingw* ) # actually msys
16840+ lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
16841+ ;;
16842+ *-*-cygwin* )
16843+ lt_cv_to_host_file_cmd=func_convert_file_noop
16844+ ;;
16845+ * ) # otherwise, assume *nix
16846+ lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
16847+ ;;
16848+ esac
16849+ ;;
16850+ * ) # unhandled hosts (and "normal" native builds)
16851+ lt_cv_to_host_file_cmd=func_convert_file_noop
16852+ ;;
16853+esac
16854+
16855+fi
16856+
16857+to_host_file_cmd=$lt_cv_to_host_file_cmd
16858+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
16859+$as_echo "$lt_cv_to_host_file_cmd" >&6; }
16860+
16861+
16862+
16863+
16864+
16865+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
16866+$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
16867+if test "${lt_cv_to_tool_file_cmd+set}" = set; then :
16868+ $as_echo_n "(cached) " >&6
16869+else
16870+ #assume ordinary cross tools, or native build.
16871+lt_cv_to_tool_file_cmd=func_convert_file_noop
16872+case $host in
16873+ *-*-mingw* )
16874+ case $build in
16875+ *-*-mingw* ) # actually msys
16876+ lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
16877+ ;;
16878+ esac
16879+ ;;
16880+esac
16881+
16882+fi
16883+
16884+to_tool_file_cmd=$lt_cv_to_tool_file_cmd
16885+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
16886+$as_echo "$lt_cv_to_tool_file_cmd" >&6; }
16887+
16888+
16889+
16890+
16891+
16892 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
16893 $as_echo_n "checking for $LD option to reload object files... " >&6; }
16894 if test "${lt_cv_ld_reload_flag+set}" = set; then :
16895@@ -6878,6 +6958,11 @@ case $reload_flag in
16896 esac
16897 reload_cmds='$LD$reload_flag -o $output$reload_objs'
16898 case $host_os in
16899+ cygwin* | mingw* | pw32* | cegcc*)
16900+ if test "$GCC" != yes; then
16901+ reload_cmds=false
16902+ fi
16903+ ;;
16904 darwin*)
16905 if test "$GCC" = yes; then
16906 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
16907@@ -7046,7 +7131,8 @@ mingw* | pw32*)
16908 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
16909 lt_cv_file_magic_cmd='func_win32_libid'
16910 else
16911- lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
16912+ # Keep this pattern in sync with the one in func_win32_libid.
16913+ lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
16914 lt_cv_file_magic_cmd='$OBJDUMP -f'
16915 fi
16916 ;;
16917@@ -7200,6 +7286,21 @@ esac
16918 fi
16919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
16920 $as_echo "$lt_cv_deplibs_check_method" >&6; }
16921+
16922+file_magic_glob=
16923+want_nocaseglob=no
16924+if test "$build" = "$host"; then
16925+ case $host_os in
16926+ mingw* | pw32*)
16927+ if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
16928+ want_nocaseglob=yes
16929+ else
16930+ file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
16931+ fi
16932+ ;;
16933+ esac
16934+fi
16935+
16936 file_magic_cmd=$lt_cv_file_magic_cmd
16937 deplibs_check_method=$lt_cv_deplibs_check_method
16938 test -z "$deplibs_check_method" && deplibs_check_method=unknown
16939@@ -7215,9 +7316,162 @@ test -z "$deplibs_check_method" && depli
16940
16941
16942
16943+
16944+
16945+
16946+
16947+
16948+
16949+
16950+
16951+
16952+
16953 if test -n "$ac_tool_prefix"; then
16954- # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
16955-set dummy ${ac_tool_prefix}ar; ac_word=$2
16956+ # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
16957+set dummy ${ac_tool_prefix}dlltool; ac_word=$2
16958+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16959+$as_echo_n "checking for $ac_word... " >&6; }
16960+if test "${ac_cv_prog_DLLTOOL+set}" = set; then :
16961+ $as_echo_n "(cached) " >&6
16962+else
16963+ if test -n "$DLLTOOL"; then
16964+ ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
16965+else
16966+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16967+for as_dir in $PATH
16968+do
16969+ IFS=$as_save_IFS
16970+ test -z "$as_dir" && as_dir=.
16971+ for ac_exec_ext in '' $ac_executable_extensions; do
16972+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
16973+ ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
16974+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16975+ break 2
16976+ fi
16977+done
16978+ done
16979+IFS=$as_save_IFS
16980+
16981+fi
16982+fi
16983+DLLTOOL=$ac_cv_prog_DLLTOOL
16984+if test -n "$DLLTOOL"; then
16985+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
16986+$as_echo "$DLLTOOL" >&6; }
16987+else
16988+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16989+$as_echo "no" >&6; }
16990+fi
16991+
16992+
16993+fi
16994+if test -z "$ac_cv_prog_DLLTOOL"; then
16995+ ac_ct_DLLTOOL=$DLLTOOL
16996+ # Extract the first word of "dlltool", so it can be a program name with args.
16997+set dummy dlltool; ac_word=$2
16998+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16999+$as_echo_n "checking for $ac_word... " >&6; }
17000+if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then :
17001+ $as_echo_n "(cached) " >&6
17002+else
17003+ if test -n "$ac_ct_DLLTOOL"; then
17004+ ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
17005+else
17006+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17007+for as_dir in $PATH
17008+do
17009+ IFS=$as_save_IFS
17010+ test -z "$as_dir" && as_dir=.
17011+ for ac_exec_ext in '' $ac_executable_extensions; do
17012+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
17013+ ac_cv_prog_ac_ct_DLLTOOL="dlltool"
17014+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17015+ break 2
17016+ fi
17017+done
17018+ done
17019+IFS=$as_save_IFS
17020+
17021+fi
17022+fi
17023+ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
17024+if test -n "$ac_ct_DLLTOOL"; then
17025+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
17026+$as_echo "$ac_ct_DLLTOOL" >&6; }
17027+else
17028+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17029+$as_echo "no" >&6; }
17030+fi
17031+
17032+ if test "x$ac_ct_DLLTOOL" = x; then
17033+ DLLTOOL="false"
17034+ else
17035+ case $cross_compiling:$ac_tool_warned in
17036+yes:)
17037+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
17038+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
17039+ac_tool_warned=yes ;;
17040+esac
17041+ DLLTOOL=$ac_ct_DLLTOOL
17042+ fi
17043+else
17044+ DLLTOOL="$ac_cv_prog_DLLTOOL"
17045+fi
17046+
17047+test -z "$DLLTOOL" && DLLTOOL=dlltool
17048+
17049+
17050+
17051+
17052+
17053+
17054+
17055+
17056+
17057+
17058+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
17059+$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
17060+if test "${lt_cv_sharedlib_from_linklib_cmd+set}" = set; then :
17061+ $as_echo_n "(cached) " >&6
17062+else
17063+ lt_cv_sharedlib_from_linklib_cmd='unknown'
17064+
17065+case $host_os in
17066+cygwin* | mingw* | pw32* | cegcc*)
17067+ # two different shell functions defined in ltmain.sh
17068+ # decide which to use based on capabilities of $DLLTOOL
17069+ case `$DLLTOOL --help 2>&1` in
17070+ *--identify-strict*)
17071+ lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
17072+ ;;
17073+ *)
17074+ lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
17075+ ;;
17076+ esac
17077+ ;;
17078+*)
17079+ # fallback: assume linklib IS sharedlib
17080+ lt_cv_sharedlib_from_linklib_cmd="$ECHO"
17081+ ;;
17082+esac
17083+
17084+fi
17085+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
17086+$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
17087+sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
17088+test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
17089+
17090+
17091+
17092+
17093+
17094+
17095+
17096+if test -n "$ac_tool_prefix"; then
17097+ for ac_prog in ar
17098+ do
17099+ # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
17100+set dummy $ac_tool_prefix$ac_prog; ac_word=$2
17101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17102 $as_echo_n "checking for $ac_word... " >&6; }
17103 if test "${ac_cv_prog_AR+set}" = set; then :
17104@@ -7233,7 +7487,7 @@ do
17105 test -z "$as_dir" && as_dir=.
17106 for ac_exec_ext in '' $ac_executable_extensions; do
17107 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
17108- ac_cv_prog_AR="${ac_tool_prefix}ar"
17109+ ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
17110 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17111 break 2
17112 fi
17113@@ -7253,11 +7507,15 @@ $as_echo "no" >&6; }
17114 fi
17115
17116
17117+ test -n "$AR" && break
17118+ done
17119 fi
17120-if test -z "$ac_cv_prog_AR"; then
17121+if test -z "$AR"; then
17122 ac_ct_AR=$AR
17123- # Extract the first word of "ar", so it can be a program name with args.
17124-set dummy ar; ac_word=$2
17125+ for ac_prog in ar
17126+do
17127+ # Extract the first word of "$ac_prog", so it can be a program name with args.
17128+set dummy $ac_prog; ac_word=$2
17129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17130 $as_echo_n "checking for $ac_word... " >&6; }
17131 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
17132@@ -7273,7 +7531,7 @@ do
17133 test -z "$as_dir" && as_dir=.
17134 for ac_exec_ext in '' $ac_executable_extensions; do
17135 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
17136- ac_cv_prog_ac_ct_AR="ar"
17137+ ac_cv_prog_ac_ct_AR="$ac_prog"
17138 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17139 break 2
17140 fi
17141@@ -7292,6 +7550,10 @@ else
17142 $as_echo "no" >&6; }
17143 fi
17144
17145+
17146+ test -n "$ac_ct_AR" && break
17147+done
17148+
17149 if test "x$ac_ct_AR" = x; then
17150 AR="false"
17151 else
17152@@ -7303,12 +7565,10 @@ ac_tool_warned=yes ;;
17153 esac
17154 AR=$ac_ct_AR
17155 fi
17156-else
17157- AR="$ac_cv_prog_AR"
17158 fi
17159
17160-test -z "$AR" && AR=ar
17161-test -z "$AR_FLAGS" && AR_FLAGS=cru
17162+: ${AR=ar}
17163+: ${AR_FLAGS=cru}
17164
17165
17166
17167@@ -7320,6 +7580,64 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
17168
17169
17170
17171+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
17172+$as_echo_n "checking for archiver @FILE support... " >&6; }
17173+if test "${lt_cv_ar_at_file+set}" = set; then :
17174+ $as_echo_n "(cached) " >&6
17175+else
17176+ lt_cv_ar_at_file=no
17177+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17178+/* end confdefs.h. */
17179+
17180+int
17181+main ()
17182+{
17183+
17184+ ;
17185+ return 0;
17186+}
17187+_ACEOF
17188+if ac_fn_c_try_compile "$LINENO"; then :
17189+ echo conftest.$ac_objext > conftest.lst
17190+ lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
17191+ { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
17192+ (eval $lt_ar_try) 2>&5
17193+ ac_status=$?
17194+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
17195+ test $ac_status = 0; }
17196+ if test "$ac_status" -eq 0; then
17197+ # Ensure the archiver fails upon bogus file names.
17198+ rm -f conftest.$ac_objext libconftest.a
17199+ { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
17200+ (eval $lt_ar_try) 2>&5
17201+ ac_status=$?
17202+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
17203+ test $ac_status = 0; }
17204+ if test "$ac_status" -ne 0; then
17205+ lt_cv_ar_at_file=@
17206+ fi
17207+ fi
17208+ rm -f conftest.* libconftest.a
17209+
17210+fi
17211+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17212+
17213+fi
17214+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
17215+$as_echo "$lt_cv_ar_at_file" >&6; }
17216+
17217+if test "x$lt_cv_ar_at_file" = xno; then
17218+ archiver_list_spec=
17219+else
17220+ archiver_list_spec=$lt_cv_ar_at_file
17221+fi
17222+
17223+
17224+
17225+
17226+
17227+
17228+
17229 if test -n "$ac_tool_prefix"; then
17230 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
17231 set dummy ${ac_tool_prefix}strip; ac_word=$2
17232@@ -7654,8 +7972,8 @@ esac
17233 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
17234
17235 # Transform an extracted symbol line into symbol name and symbol address
17236-lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
17237-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
17238+lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
17239+lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
17240
17241 # Handle CRLF in mingw tool chain
17242 opt_cr=
17243@@ -7691,6 +8009,7 @@ for ac_symprfx in "" "_"; do
17244 else
17245 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
17246 fi
17247+ lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
17248
17249 # Check to see that the pipe works correctly.
17250 pipe_works=no
17251@@ -7732,6 +8051,18 @@ _LT_EOF
17252 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
17253 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
17254 cat <<_LT_EOF > conftest.$ac_ext
17255+/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
17256+#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
17257+/* DATA imports from DLLs on WIN32 con't be const, because runtime
17258+ relocations are performed -- see ld's documentation on pseudo-relocs. */
17259+# define LT_DLSYM_CONST
17260+#elif defined(__osf__)
17261+/* This system does not cope well with relocations in const data. */
17262+# define LT_DLSYM_CONST
17263+#else
17264+# define LT_DLSYM_CONST const
17265+#endif
17266+
17267 #ifdef __cplusplus
17268 extern "C" {
17269 #endif
17270@@ -7743,7 +8074,7 @@ _LT_EOF
17271 cat <<_LT_EOF >> conftest.$ac_ext
17272
17273 /* The mapping between symbol names and symbols. */
17274-const struct {
17275+LT_DLSYM_CONST struct {
17276 const char *name;
17277 void *address;
17278 }
17279@@ -7769,8 +8100,8 @@ static const void *lt_preloaded_setup()
17280 _LT_EOF
17281 # Now try linking the two files.
17282 mv conftest.$ac_objext conftstm.$ac_objext
17283- lt_save_LIBS="$LIBS"
17284- lt_save_CFLAGS="$CFLAGS"
17285+ lt_globsym_save_LIBS=$LIBS
17286+ lt_globsym_save_CFLAGS=$CFLAGS
17287 LIBS="conftstm.$ac_objext"
17288 CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
17289 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
17290@@ -7780,8 +8111,8 @@ _LT_EOF
17291 test $ac_status = 0; } && test -s conftest${ac_exeext}; then
17292 pipe_works=yes
17293 fi
17294- LIBS="$lt_save_LIBS"
17295- CFLAGS="$lt_save_CFLAGS"
17296+ LIBS=$lt_globsym_save_LIBS
17297+ CFLAGS=$lt_globsym_save_CFLAGS
17298 else
17299 echo "cannot find nm_test_func in $nlist" >&5
17300 fi
17301@@ -7818,6 +8149,21 @@ else
17302 $as_echo "ok" >&6; }
17303 fi
17304
17305+# Response file support.
17306+if test "$lt_cv_nm_interface" = "MS dumpbin"; then
17307+ nm_file_list_spec='@'
17308+elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
17309+ nm_file_list_spec='@'
17310+fi
17311+
17312+
17313+
17314+
17315+
17316+
17317+
17318+
17319+
17320
17321
17322
17323@@ -7836,6 +8182,40 @@ fi
17324
17325
17326
17327+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
17328+$as_echo_n "checking for sysroot... " >&6; }
17329+
17330+# Check whether --with-libtool-sysroot was given.
17331+if test "${with_libtool_sysroot+set}" = set; then :
17332+ withval=$with_libtool_sysroot;
17333+else
17334+ with_libtool_sysroot=no
17335+fi
17336+
17337+
17338+lt_sysroot=
17339+case ${with_libtool_sysroot} in #(
17340+ yes)
17341+ if test "$GCC" = yes; then
17342+ lt_sysroot=`$CC --print-sysroot 2>/dev/null`
17343+ fi
17344+ ;; #(
17345+ /*)
17346+ lt_sysroot=`echo "$with_libtool_sysroot" | sed -e "$sed_quote_subst"`
17347+ ;; #(
17348+ no|'')
17349+ ;; #(
17350+ *)
17351+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libtool_sysroot}" >&5
17352+$as_echo "${with_libtool_sysroot}" >&6; }
17353+ as_fn_error "The sysroot must be an absolute path." "$LINENO" 5
17354+ ;;
17355+esac
17356+
17357+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
17358+$as_echo "${lt_sysroot:-no}" >&6; }
17359+
17360+
17361
17362
17363
17364@@ -8026,11 +8406,128 @@ sparc*-*solaris*)
17365 ;;
17366 esac
17367 fi
17368- rm -rf conftest*
17369- ;;
17370+ rm -rf conftest*
17371+ ;;
17372+esac
17373+
17374+need_locks="$enable_libtool_lock"
17375+
17376+if test -n "$ac_tool_prefix"; then
17377+ # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
17378+set dummy ${ac_tool_prefix}mt; ac_word=$2
17379+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17380+$as_echo_n "checking for $ac_word... " >&6; }
17381+if test "${ac_cv_prog_MANIFEST_TOOL+set}" = set; then :
17382+ $as_echo_n "(cached) " >&6
17383+else
17384+ if test -n "$MANIFEST_TOOL"; then
17385+ ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
17386+else
17387+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17388+for as_dir in $PATH
17389+do
17390+ IFS=$as_save_IFS
17391+ test -z "$as_dir" && as_dir=.
17392+ for ac_exec_ext in '' $ac_executable_extensions; do
17393+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
17394+ ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
17395+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17396+ break 2
17397+ fi
17398+done
17399+ done
17400+IFS=$as_save_IFS
17401+
17402+fi
17403+fi
17404+MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
17405+if test -n "$MANIFEST_TOOL"; then
17406+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
17407+$as_echo "$MANIFEST_TOOL" >&6; }
17408+else
17409+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17410+$as_echo "no" >&6; }
17411+fi
17412+
17413+
17414+fi
17415+if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
17416+ ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
17417+ # Extract the first word of "mt", so it can be a program name with args.
17418+set dummy mt; ac_word=$2
17419+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17420+$as_echo_n "checking for $ac_word... " >&6; }
17421+if test "${ac_cv_prog_ac_ct_MANIFEST_TOOL+set}" = set; then :
17422+ $as_echo_n "(cached) " >&6
17423+else
17424+ if test -n "$ac_ct_MANIFEST_TOOL"; then
17425+ ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
17426+else
17427+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17428+for as_dir in $PATH
17429+do
17430+ IFS=$as_save_IFS
17431+ test -z "$as_dir" && as_dir=.
17432+ for ac_exec_ext in '' $ac_executable_extensions; do
17433+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
17434+ ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
17435+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17436+ break 2
17437+ fi
17438+done
17439+ done
17440+IFS=$as_save_IFS
17441+
17442+fi
17443+fi
17444+ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
17445+if test -n "$ac_ct_MANIFEST_TOOL"; then
17446+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
17447+$as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
17448+else
17449+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17450+$as_echo "no" >&6; }
17451+fi
17452+
17453+ if test "x$ac_ct_MANIFEST_TOOL" = x; then
17454+ MANIFEST_TOOL=":"
17455+ else
17456+ case $cross_compiling:$ac_tool_warned in
17457+yes:)
17458+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
17459+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
17460+ac_tool_warned=yes ;;
17461 esac
17462+ MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
17463+ fi
17464+else
17465+ MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
17466+fi
17467+
17468+test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
17469+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
17470+$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
17471+if test "${lt_cv_path_mainfest_tool+set}" = set; then :
17472+ $as_echo_n "(cached) " >&6
17473+else
17474+ lt_cv_path_mainfest_tool=no
17475+ echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
17476+ $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
17477+ cat conftest.err >&5
17478+ if $GREP 'Manifest Tool' conftest.out > /dev/null; then
17479+ lt_cv_path_mainfest_tool=yes
17480+ fi
17481+ rm -f conftest*
17482+fi
17483+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
17484+$as_echo "$lt_cv_path_mainfest_tool" >&6; }
17485+if test "x$lt_cv_path_mainfest_tool" != xyes; then
17486+ MANIFEST_TOOL=:
17487+fi
17488+
17489+
17490+
17491
17492-need_locks="$enable_libtool_lock"
17493
17494
17495 case $host_os in
17496@@ -8595,6 +9092,8 @@ _LT_EOF
17497 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
17498 echo "$AR cru libconftest.a conftest.o" >&5
17499 $AR cru libconftest.a conftest.o 2>&5
17500+ echo "$RANLIB libconftest.a" >&5
17501+ $RANLIB libconftest.a 2>&5
17502 cat > conftest.c << _LT_EOF
17503 int main() { return 0;}
17504 _LT_EOF
17505@@ -8791,7 +9290,8 @@ fi
17506 LIBTOOL_DEPS="$ltmain"
17507
17508 # Always use our own libtool.
17509-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
17510+LIBTOOL='$(SHELL) $(top_builddir)'
17511+LIBTOOL="$LIBTOOL/${host_alias}-libtool"
17512
17513
17514
17515@@ -8880,7 +9380,7 @@ aix3*)
17516 esac
17517
17518 # Global variables:
17519-ofile=libtool
17520+ofile=${host_alias}-libtool
17521 can_build_shared=yes
17522
17523 # All known linkers require a `.a' archive for static linking (except MSVC,
17524@@ -9178,8 +9678,6 @@ fi
17525 lt_prog_compiler_pic=
17526 lt_prog_compiler_static=
17527
17528-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
17529-$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
17530
17531 if test "$GCC" = yes; then
17532 lt_prog_compiler_wl='-Wl,'
17533@@ -9344,6 +9842,12 @@ $as_echo_n "checking for $compiler optio
17534 lt_prog_compiler_pic='--shared'
17535 lt_prog_compiler_static='--static'
17536 ;;
17537+ nagfor*)
17538+ # NAG Fortran compiler
17539+ lt_prog_compiler_wl='-Wl,-Wl,,'
17540+ lt_prog_compiler_pic='-PIC'
17541+ lt_prog_compiler_static='-Bstatic'
17542+ ;;
17543 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
17544 # Portland Group compilers (*not* the Pentium gcc compiler,
17545 # which looks to be a dead project)
17546@@ -9406,7 +9910,7 @@ $as_echo_n "checking for $compiler optio
17547 lt_prog_compiler_pic='-KPIC'
17548 lt_prog_compiler_static='-Bstatic'
17549 case $cc_basename in
17550- f77* | f90* | f95*)
17551+ f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
17552 lt_prog_compiler_wl='-Qoption ld ';;
17553 *)
17554 lt_prog_compiler_wl='-Wl,';;
17555@@ -9463,13 +9967,17 @@ case $host_os in
17556 lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
17557 ;;
17558 esac
17559-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5
17560-$as_echo "$lt_prog_compiler_pic" >&6; }
17561-
17562-
17563-
17564-
17565
17566+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
17567+$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
17568+if test "${lt_cv_prog_compiler_pic+set}" = set; then :
17569+ $as_echo_n "(cached) " >&6
17570+else
17571+ lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
17572+fi
17573+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
17574+$as_echo "$lt_cv_prog_compiler_pic" >&6; }
17575+lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
17576
17577 #
17578 # Check to make sure the PIC flag actually works.
17579@@ -9530,6 +10038,11 @@ fi
17580
17581
17582
17583+
17584+
17585+
17586+
17587+
17588 #
17589 # Check to make sure the static flag actually works.
17590 #
17591@@ -9880,7 +10393,8 @@ _LT_EOF
17592 allow_undefined_flag=unsupported
17593 always_export_symbols=no
17594 enable_shared_with_static_runtimes=yes
17595- export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
17596+ export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
17597+ exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
17598
17599 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
17600 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
17601@@ -9928,7 +10442,7 @@ _LT_EOF
17602 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
17603 && test "$tmp_diet" = no
17604 then
17605- tmp_addflag=
17606+ tmp_addflag=' $pic_flag'
17607 tmp_sharedflag='-shared'
17608 case $cc_basename,$host_cpu in
17609 pgcc*) # Portland Group C compiler
17610@@ -9979,12 +10493,12 @@ _LT_EOF
17611 whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
17612 hardcode_libdir_flag_spec=
17613 hardcode_libdir_flag_spec_ld='-rpath $libdir'
17614- archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
17615+ archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
17616 if test "x$supports_anon_versioning" = xyes; then
17617 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
17618 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
17619 echo "local: *; };" >> $output_objdir/$libname.ver~
17620- $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
17621+ $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
17622 fi
17623 ;;
17624 esac
17625@@ -9998,8 +10512,8 @@ _LT_EOF
17626 archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
17627 wlarc=
17628 else
17629- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
17630- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
17631+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
17632+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
17633 fi
17634 ;;
17635
17636@@ -10017,8 +10531,8 @@ _LT_EOF
17637
17638 _LT_EOF
17639 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
17640- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
17641- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
17642+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
17643+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
17644 else
17645 ld_shlibs=no
17646 fi
17647@@ -10064,8 +10578,8 @@ _LT_EOF
17648
17649 *)
17650 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
17651- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
17652- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
17653+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
17654+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
17655 else
17656 ld_shlibs=no
17657 fi
17658@@ -10195,7 +10709,13 @@ _LT_EOF
17659 allow_undefined_flag='-berok'
17660 # Determine the default libpath from the value encoded in an
17661 # empty executable.
17662- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17663+ if test "${lt_cv_aix_libpath+set}" = set; then
17664+ aix_libpath=$lt_cv_aix_libpath
17665+else
17666+ if test "${lt_cv_aix_libpath_+set}" = set; then :
17667+ $as_echo_n "(cached) " >&6
17668+else
17669+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17670 /* end confdefs.h. */
17671
17672 int
17673@@ -10208,22 +10728,29 @@ main ()
17674 _ACEOF
17675 if ac_fn_c_try_link "$LINENO"; then :
17676
17677-lt_aix_libpath_sed='
17678- /Import File Strings/,/^$/ {
17679- /^0/ {
17680- s/^0 *\(.*\)$/\1/
17681- p
17682- }
17683- }'
17684-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
17685-# Check for a 64-bit object if we didn't find anything.
17686-if test -z "$aix_libpath"; then
17687- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
17688-fi
17689+ lt_aix_libpath_sed='
17690+ /Import File Strings/,/^$/ {
17691+ /^0/ {
17692+ s/^0 *\([^ ]*\) *$/\1/
17693+ p
17694+ }
17695+ }'
17696+ lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
17697+ # Check for a 64-bit object if we didn't find anything.
17698+ if test -z "$lt_cv_aix_libpath_"; then
17699+ lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
17700+ fi
17701 fi
17702 rm -f core conftest.err conftest.$ac_objext \
17703 conftest$ac_exeext conftest.$ac_ext
17704-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
17705+ if test -z "$lt_cv_aix_libpath_"; then
17706+ lt_cv_aix_libpath_="/usr/lib:/lib"
17707+ fi
17708+
17709+fi
17710+
17711+ aix_libpath=$lt_cv_aix_libpath_
17712+fi
17713
17714 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
17715 archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
17716@@ -10235,7 +10762,13 @@ if test -z "$aix_libpath"; then aix_libp
17717 else
17718 # Determine the default libpath from the value encoded in an
17719 # empty executable.
17720- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17721+ if test "${lt_cv_aix_libpath+set}" = set; then
17722+ aix_libpath=$lt_cv_aix_libpath
17723+else
17724+ if test "${lt_cv_aix_libpath_+set}" = set; then :
17725+ $as_echo_n "(cached) " >&6
17726+else
17727+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17728 /* end confdefs.h. */
17729
17730 int
17731@@ -10248,22 +10781,29 @@ main ()
17732 _ACEOF
17733 if ac_fn_c_try_link "$LINENO"; then :
17734
17735-lt_aix_libpath_sed='
17736- /Import File Strings/,/^$/ {
17737- /^0/ {
17738- s/^0 *\(.*\)$/\1/
17739- p
17740- }
17741- }'
17742-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
17743-# Check for a 64-bit object if we didn't find anything.
17744-if test -z "$aix_libpath"; then
17745- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
17746-fi
17747+ lt_aix_libpath_sed='
17748+ /Import File Strings/,/^$/ {
17749+ /^0/ {
17750+ s/^0 *\([^ ]*\) *$/\1/
17751+ p
17752+ }
17753+ }'
17754+ lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
17755+ # Check for a 64-bit object if we didn't find anything.
17756+ if test -z "$lt_cv_aix_libpath_"; then
17757+ lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
17758+ fi
17759 fi
17760 rm -f core conftest.err conftest.$ac_objext \
17761 conftest$ac_exeext conftest.$ac_ext
17762-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
17763+ if test -z "$lt_cv_aix_libpath_"; then
17764+ lt_cv_aix_libpath_="/usr/lib:/lib"
17765+ fi
17766+
17767+fi
17768+
17769+ aix_libpath=$lt_cv_aix_libpath_
17770+fi
17771
17772 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
17773 # Warning - without using the other run time loading flags,
17774@@ -10308,20 +10848,63 @@ if test -z "$aix_libpath"; then aix_libp
17775 # Microsoft Visual C++.
17776 # hardcode_libdir_flag_spec is actually meaningless, as there is
17777 # no search path for DLLs.
17778- hardcode_libdir_flag_spec=' '
17779- allow_undefined_flag=unsupported
17780- # Tell ltmain to make .lib files, not .a files.
17781- libext=lib
17782- # Tell ltmain to make .dll files, not .so files.
17783- shrext_cmds=".dll"
17784- # FIXME: Setting linknames here is a bad hack.
17785- archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
17786- # The linker will automatically build a .lib file if we build a DLL.
17787- old_archive_from_new_cmds='true'
17788- # FIXME: Should let the user specify the lib program.
17789- old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
17790- fix_srcfile_path='`cygpath -w "$srcfile"`'
17791- enable_shared_with_static_runtimes=yes
17792+ case $cc_basename in
17793+ cl*)
17794+ # Native MSVC
17795+ hardcode_libdir_flag_spec=' '
17796+ allow_undefined_flag=unsupported
17797+ always_export_symbols=yes
17798+ file_list_spec='@'
17799+ # Tell ltmain to make .lib files, not .a files.
17800+ libext=lib
17801+ # Tell ltmain to make .dll files, not .so files.
17802+ shrext_cmds=".dll"
17803+ # FIXME: Setting linknames here is a bad hack.
17804+ archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
17805+ archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
17806+ sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
17807+ else
17808+ sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
17809+ fi~
17810+ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
17811+ linknames='
17812+ # The linker will not automatically build a static lib if we build a DLL.
17813+ # _LT_TAGVAR(old_archive_from_new_cmds, )='true'
17814+ enable_shared_with_static_runtimes=yes
17815+ export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
17816+ # Don't use ranlib
17817+ old_postinstall_cmds='chmod 644 $oldlib'
17818+ postlink_cmds='lt_outputfile="@OUTPUT@"~
17819+ lt_tool_outputfile="@TOOL_OUTPUT@"~
17820+ case $lt_outputfile in
17821+ *.exe|*.EXE) ;;
17822+ *)
17823+ lt_outputfile="$lt_outputfile.exe"
17824+ lt_tool_outputfile="$lt_tool_outputfile.exe"
17825+ ;;
17826+ esac~
17827+ if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
17828+ $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
17829+ $RM "$lt_outputfile.manifest";
17830+ fi'
17831+ ;;
17832+ *)
17833+ # Assume MSVC wrapper
17834+ hardcode_libdir_flag_spec=' '
17835+ allow_undefined_flag=unsupported
17836+ # Tell ltmain to make .lib files, not .a files.
17837+ libext=lib
17838+ # Tell ltmain to make .dll files, not .so files.
17839+ shrext_cmds=".dll"
17840+ # FIXME: Setting linknames here is a bad hack.
17841+ archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
17842+ # The linker will automatically build a .lib file if we build a DLL.
17843+ old_archive_from_new_cmds='true'
17844+ # FIXME: Should let the user specify the lib program.
17845+ old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
17846+ enable_shared_with_static_runtimes=yes
17847+ ;;
17848+ esac
17849 ;;
17850
17851 darwin* | rhapsody*)
17852@@ -10382,7 +10965,7 @@ if test -z "$aix_libpath"; then aix_libp
17853
17854 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
17855 freebsd* | dragonfly*)
17856- archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
17857+ archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
17858 hardcode_libdir_flag_spec='-R$libdir'
17859 hardcode_direct=yes
17860 hardcode_shlibpath_var=no
17861@@ -10390,7 +10973,7 @@ if test -z "$aix_libpath"; then aix_libp
17862
17863 hpux9*)
17864 if test "$GCC" = yes; then
17865- archive_cmds='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
17866+ archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
17867 else
17868 archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
17869 fi
17870@@ -10406,7 +10989,7 @@ if test -z "$aix_libpath"; then aix_libp
17871
17872 hpux10*)
17873 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
17874- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
17875+ archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
17876 else
17877 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
17878 fi
17879@@ -10430,10 +11013,10 @@ if test -z "$aix_libpath"; then aix_libp
17880 archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
17881 ;;
17882 ia64*)
17883- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
17884+ archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
17885 ;;
17886 *)
17887- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
17888+ archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
17889 ;;
17890 esac
17891 else
17892@@ -10512,23 +11095,36 @@ fi
17893
17894 irix5* | irix6* | nonstopux*)
17895 if test "$GCC" = yes; then
17896- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
17897+ archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
17898 # Try to use the -exported_symbol ld option, if it does not
17899 # work, assume that -exports_file does not work either and
17900 # implicitly export all symbols.
17901- save_LDFLAGS="$LDFLAGS"
17902- LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
17903- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17904+ # This should be the same for all languages, so no per-tag cache variable.
17905+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
17906+$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
17907+if test "${lt_cv_irix_exported_symbol+set}" = set; then :
17908+ $as_echo_n "(cached) " >&6
17909+else
17910+ save_LDFLAGS="$LDFLAGS"
17911+ LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
17912+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17913 /* end confdefs.h. */
17914-int foo(void) {}
17915+int foo (void) { return 0; }
17916 _ACEOF
17917 if ac_fn_c_try_link "$LINENO"; then :
17918- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
17919-
17920+ lt_cv_irix_exported_symbol=yes
17921+else
17922+ lt_cv_irix_exported_symbol=no
17923 fi
17924 rm -f core conftest.err conftest.$ac_objext \
17925 conftest$ac_exeext conftest.$ac_ext
17926- LDFLAGS="$save_LDFLAGS"
17927+ LDFLAGS="$save_LDFLAGS"
17928+fi
17929+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
17930+$as_echo "$lt_cv_irix_exported_symbol" >&6; }
17931+ if test "$lt_cv_irix_exported_symbol" = yes; then
17932+ archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
17933+ fi
17934 else
17935 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
17936 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
17937@@ -10613,7 +11209,7 @@ rm -f core conftest.err conftest.$ac_obj
17938 osf4* | osf5*) # as osf3* with the addition of -msym flag
17939 if test "$GCC" = yes; then
17940 allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
17941- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
17942+ archive_cmds='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
17943 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
17944 else
17945 allow_undefined_flag=' -expect_unresolved \*'
17946@@ -10632,9 +11228,9 @@ rm -f core conftest.err conftest.$ac_obj
17947 no_undefined_flag=' -z defs'
17948 if test "$GCC" = yes; then
17949 wlarc='${wl}'
17950- archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
17951+ archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
17952 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
17953- $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
17954+ $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
17955 else
17956 case `$CC -V 2>&1` in
17957 *"Compilers 5.0"*)
17958@@ -11210,8 +11806,9 @@ cygwin* | mingw* | pw32* | cegcc*)
17959 need_version=no
17960 need_lib_prefix=no
17961
17962- case $GCC,$host_os in
17963- yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
17964+ case $GCC,$cc_basename in
17965+ yes,*)
17966+ # gcc
17967 library_names_spec='$libname.dll.a'
17968 # DLL is installed to $(libdir)/../bin by postinstall_cmds
17969 postinstall_cmds='base_file=`basename \${file}`~
17970@@ -11244,13 +11841,71 @@ cygwin* | mingw* | pw32* | cegcc*)
17971 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
17972 ;;
17973 esac
17974+ dynamic_linker='Win32 ld.exe'
17975+ ;;
17976+
17977+ *,cl*)
17978+ # Native MSVC
17979+ libname_spec='$name'
17980+ soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
17981+ library_names_spec='${libname}.dll.lib'
17982+
17983+ case $build_os in
17984+ mingw*)
17985+ sys_lib_search_path_spec=
17986+ lt_save_ifs=$IFS
17987+ IFS=';'
17988+ for lt_path in $LIB
17989+ do
17990+ IFS=$lt_save_ifs
17991+ # Let DOS variable expansion print the short 8.3 style file name.
17992+ lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
17993+ sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
17994+ done
17995+ IFS=$lt_save_ifs
17996+ # Convert to MSYS style.
17997+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
17998+ ;;
17999+ cygwin*)
18000+ # Convert to unix form, then to dos form, then back to unix form
18001+ # but this time dos style (no spaces!) so that the unix form looks
18002+ # like /cygdrive/c/PROGRA~1:/cygdr...
18003+ sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
18004+ sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
18005+ sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
18006+ ;;
18007+ *)
18008+ sys_lib_search_path_spec="$LIB"
18009+ if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
18010+ # It is most probably a Windows format PATH.
18011+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
18012+ else
18013+ sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
18014+ fi
18015+ # FIXME: find the short name or the path components, as spaces are
18016+ # common. (e.g. "Program Files" -> "PROGRA~1")
18017+ ;;
18018+ esac
18019+
18020+ # DLL is installed to $(libdir)/../bin by postinstall_cmds
18021+ postinstall_cmds='base_file=`basename \${file}`~
18022+ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
18023+ dldir=$destdir/`dirname \$dlpath`~
18024+ test -d \$dldir || mkdir -p \$dldir~
18025+ $install_prog $dir/$dlname \$dldir/$dlname'
18026+ postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
18027+ dlpath=$dir/\$dldll~
18028+ $RM \$dlpath'
18029+ shlibpath_overrides_runpath=yes
18030+ dynamic_linker='Win32 link.exe'
18031 ;;
18032
18033 *)
18034+ # Assume MSVC wrapper
18035 library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
18036+ dynamic_linker='Win32 ld.exe'
18037 ;;
18038 esac
18039- dynamic_linker='Win32 ld.exe'
18040 # FIXME: first we should search . and the directory the executable is in
18041 shlibpath_var=PATH
18042 ;;
18043@@ -11342,7 +11997,7 @@ haiku*)
18044 soname_spec='${libname}${release}${shared_ext}$major'
18045 shlibpath_var=LIBRARY_PATH
18046 shlibpath_overrides_runpath=yes
18047- sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/beos/system/lib'
18048+ sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
18049 hardcode_into_libs=yes
18050 ;;
18051
18052@@ -12138,7 +12793,7 @@ else
18053 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
18054 lt_status=$lt_dlunknown
18055 cat > conftest.$ac_ext <<_LT_EOF
18056-#line 12141 "configure"
18057+#line $LINENO "configure"
18058 #include "confdefs.h"
18059
18060 #if HAVE_DLFCN_H
18061@@ -12182,10 +12837,10 @@ else
18062 /* When -fvisbility=hidden is used, assume the code has been annotated
18063 correspondingly for the symbols needed. */
18064 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
18065-void fnord () __attribute__((visibility("default")));
18066+int fnord () __attribute__((visibility("default")));
18067 #endif
18068
18069-void fnord () { int i=42; }
18070+int fnord () { return 42; }
18071 int main ()
18072 {
18073 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
18074@@ -12244,7 +12899,7 @@ else
18075 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
18076 lt_status=$lt_dlunknown
18077 cat > conftest.$ac_ext <<_LT_EOF
18078-#line 12247 "configure"
18079+#line $LINENO "configure"
18080 #include "confdefs.h"
18081
18082 #if HAVE_DLFCN_H
18083@@ -12288,10 +12943,10 @@ else
18084 /* When -fvisbility=hidden is used, assume the code has been annotated
18085 correspondingly for the symbols needed. */
18086 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
18087-void fnord () __attribute__((visibility("default")));
18088+int fnord () __attribute__((visibility("default")));
18089 #endif
18090
18091-void fnord () { int i=42; }
18092+int fnord () { return 42; }
18093 int main ()
18094 {
18095 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
18096@@ -17646,13 +18301,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_
18097 lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
18098 lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
18099 lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
18100+lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
18101+lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
18102 reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
18103 reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
18104 OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
18105 deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
18106 file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
18107+file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
18108+want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
18109+DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
18110+sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
18111 AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
18112 AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
18113+archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
18114 STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
18115 RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
18116 old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
18117@@ -17667,14 +18329,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$l
18118 lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
18119 lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
18120 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
18121+nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
18122+lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
18123 objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
18124 MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
18125 lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
18126-lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
18127 lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
18128+lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
18129 lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
18130 lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
18131 need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
18132+MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
18133 DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
18134 NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
18135 LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
18136@@ -17707,12 +18372,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcod
18137 hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
18138 inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
18139 link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
18140-fix_srcfile_path='`$ECHO "$fix_srcfile_path" | $SED "$delay_single_quote_subst"`'
18141 always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
18142 export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
18143 exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
18144 include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
18145 prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
18146+postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
18147 file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
18148 variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
18149 need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
18150@@ -17822,8 +18487,13 @@ reload_flag \
18151 OBJDUMP \
18152 deplibs_check_method \
18153 file_magic_cmd \
18154+file_magic_glob \
18155+want_nocaseglob \
18156+DLLTOOL \
18157+sharedlib_from_linklib_cmd \
18158 AR \
18159 AR_FLAGS \
18160+archiver_list_spec \
18161 STRIP \
18162 RANLIB \
18163 CC \
18164@@ -17833,12 +18503,14 @@ lt_cv_sys_global_symbol_pipe \
18165 lt_cv_sys_global_symbol_to_cdecl \
18166 lt_cv_sys_global_symbol_to_c_name_address \
18167 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
18168+nm_file_list_spec \
18169 lt_prog_compiler_no_builtin_flag \
18170-lt_prog_compiler_wl \
18171 lt_prog_compiler_pic \
18172+lt_prog_compiler_wl \
18173 lt_prog_compiler_static \
18174 lt_cv_prog_compiler_c_o \
18175 need_locks \
18176+MANIFEST_TOOL \
18177 DSYMUTIL \
18178 NMEDIT \
18179 LIPO \
18180@@ -17854,7 +18526,6 @@ no_undefined_flag \
18181 hardcode_libdir_flag_spec \
18182 hardcode_libdir_flag_spec_ld \
18183 hardcode_libdir_separator \
18184-fix_srcfile_path \
18185 exclude_expsyms \
18186 include_expsyms \
18187 file_list_spec \
18188@@ -17923,6 +18594,7 @@ module_cmds \
18189 module_expsym_cmds \
18190 export_symbols_cmds \
18191 prelink_cmds \
18192+postlink_cmds \
18193 postinstall_cmds \
18194 postuninstall_cmds \
18195 finish_cmds \
18196@@ -18730,7 +19402,8 @@ $as_echo X"$file" |
18197 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
18198 #
18199 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
18200-# 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
18201+# 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
18202+# Inc.
18203 # Written by Gordon Matzigkeit, 1996
18204 #
18205 # This file is part of GNU Libtool.
18206@@ -18833,19 +19506,42 @@ SP2NL=$lt_lt_SP2NL
18207 # turn newlines into spaces.
18208 NL2SP=$lt_lt_NL2SP
18209
18210+# convert \$build file names to \$host format.
18211+to_host_file_cmd=$lt_cv_to_host_file_cmd
18212+
18213+# convert \$build files to toolchain format.
18214+to_tool_file_cmd=$lt_cv_to_tool_file_cmd
18215+
18216 # An object symbol dumper.
18217 OBJDUMP=$lt_OBJDUMP
18218
18219 # Method to check whether dependent libraries are shared objects.
18220 deplibs_check_method=$lt_deplibs_check_method
18221
18222-# Command to use when deplibs_check_method == "file_magic".
18223+# Command to use when deplibs_check_method = "file_magic".
18224 file_magic_cmd=$lt_file_magic_cmd
18225
18226+# How to find potential files when deplibs_check_method = "file_magic".
18227+file_magic_glob=$lt_file_magic_glob
18228+
18229+# Find potential files using nocaseglob when deplibs_check_method = "file_magic".
18230+want_nocaseglob=$lt_want_nocaseglob
18231+
18232+# DLL creation program.
18233+DLLTOOL=$lt_DLLTOOL
18234+
18235+# Command to associate shared and link libraries.
18236+sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
18237+
18238 # The archiver.
18239 AR=$lt_AR
18240+
18241+# Flags to create an archive.
18242 AR_FLAGS=$lt_AR_FLAGS
18243
18244+# How to feed a file listing to the archiver.
18245+archiver_list_spec=$lt_archiver_list_spec
18246+
18247 # A symbol stripping program.
18248 STRIP=$lt_STRIP
18249
18250@@ -18875,6 +19571,12 @@ global_symbol_to_c_name_address=$lt_lt_c
18251 # Transform the output of nm in a C name address pair when lib prefix is needed.
18252 global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
18253
18254+# Specify filename containing input files for \$NM.
18255+nm_file_list_spec=$lt_nm_file_list_spec
18256+
18257+# The root where to search for dependent libraries,and in which our libraries should be installed.
18258+lt_sysroot=$lt_sysroot
18259+
18260 # The name of the directory that contains temporary libtool files.
18261 objdir=$objdir
18262
18263@@ -18884,6 +19586,9 @@ MAGIC_CMD=$MAGIC_CMD
18264 # Must we lock files when doing compilation?
18265 need_locks=$lt_need_locks
18266
18267+# Manifest tool.
18268+MANIFEST_TOOL=$lt_MANIFEST_TOOL
18269+
18270 # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
18271 DSYMUTIL=$lt_DSYMUTIL
18272
18273@@ -18998,12 +19703,12 @@ with_gcc=$GCC
18274 # Compiler flag to turn off builtin functions.
18275 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
18276
18277-# How to pass a linker flag through the compiler.
18278-wl=$lt_lt_prog_compiler_wl
18279-
18280 # Additional compiler flags for building library objects.
18281 pic_flag=$lt_lt_prog_compiler_pic
18282
18283+# How to pass a linker flag through the compiler.
18284+wl=$lt_lt_prog_compiler_wl
18285+
18286 # Compiler flag to prevent dynamic linking.
18287 link_static_flag=$lt_lt_prog_compiler_static
18288
18289@@ -19090,9 +19795,6 @@ inherit_rpath=$inherit_rpath
18290 # Whether libtool must link a program against all its dependency libraries.
18291 link_all_deplibs=$link_all_deplibs
18292
18293-# Fix the shell variable \$srcfile for the compiler.
18294-fix_srcfile_path=$lt_fix_srcfile_path
18295-
18296 # Set to "yes" if exported symbols are required.
18297 always_export_symbols=$always_export_symbols
18298
18299@@ -19108,6 +19810,9 @@ include_expsyms=$lt_include_expsyms
18300 # Commands necessary for linking programs (against libraries) with templates.
18301 prelink_cmds=$lt_prelink_cmds
18302
18303+# Commands necessary for finishing linking programs.
18304+postlink_cmds=$lt_postlink_cmds
18305+
18306 # Specify filename containing input files.
18307 file_list_spec=$lt_file_list_spec
18308
18309@@ -19154,210 +19859,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
18310 # if finds mixed CR/LF and LF-only lines. Since sed operates in
18311 # text mode, it properly converts lines to CR/LF. This bash problem
18312 # is reportedly fixed, but why not run on old versions too?
18313- sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
18314- || (rm -f "$cfgfile"; exit 1)
18315-
18316- case $xsi_shell in
18317- yes)
18318- cat << \_LT_EOF >> "$cfgfile"
18319-
18320-# func_dirname file append nondir_replacement
18321-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
18322-# otherwise set result to NONDIR_REPLACEMENT.
18323-func_dirname ()
18324-{
18325- case ${1} in
18326- */*) func_dirname_result="${1%/*}${2}" ;;
18327- * ) func_dirname_result="${3}" ;;
18328- esac
18329-}
18330-
18331-# func_basename file
18332-func_basename ()
18333-{
18334- func_basename_result="${1##*/}"
18335-}
18336-
18337-# func_dirname_and_basename file append nondir_replacement
18338-# perform func_basename and func_dirname in a single function
18339-# call:
18340-# dirname: Compute the dirname of FILE. If nonempty,
18341-# add APPEND to the result, otherwise set result
18342-# to NONDIR_REPLACEMENT.
18343-# value returned in "$func_dirname_result"
18344-# basename: Compute filename of FILE.
18345-# value retuned in "$func_basename_result"
18346-# Implementation must be kept synchronized with func_dirname
18347-# and func_basename. For efficiency, we do not delegate to
18348-# those functions but instead duplicate the functionality here.
18349-func_dirname_and_basename ()
18350-{
18351- case ${1} in
18352- */*) func_dirname_result="${1%/*}${2}" ;;
18353- * ) func_dirname_result="${3}" ;;
18354- esac
18355- func_basename_result="${1##*/}"
18356-}
18357-
18358-# func_stripname prefix suffix name
18359-# strip PREFIX and SUFFIX off of NAME.
18360-# PREFIX and SUFFIX must not contain globbing or regex special
18361-# characters, hashes, percent signs, but SUFFIX may contain a leading
18362-# dot (in which case that matches only a dot).
18363-func_stripname ()
18364-{
18365- # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
18366- # positional parameters, so assign one to ordinary parameter first.
18367- func_stripname_result=${3}
18368- func_stripname_result=${func_stripname_result#"${1}"}
18369- func_stripname_result=${func_stripname_result%"${2}"}
18370-}
18371-
18372-# func_opt_split
18373-func_opt_split ()
18374-{
18375- func_opt_split_opt=${1%%=*}
18376- func_opt_split_arg=${1#*=}
18377-}
18378-
18379-# func_lo2o object
18380-func_lo2o ()
18381-{
18382- case ${1} in
18383- *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
18384- *) func_lo2o_result=${1} ;;
18385- esac
18386-}
18387-
18388-# func_xform libobj-or-source
18389-func_xform ()
18390-{
18391- func_xform_result=${1%.*}.lo
18392-}
18393-
18394-# func_arith arithmetic-term...
18395-func_arith ()
18396-{
18397- func_arith_result=$(( $* ))
18398-}
18399-
18400-# func_len string
18401-# STRING may not start with a hyphen.
18402-func_len ()
18403-{
18404- func_len_result=${#1}
18405-}
18406-
18407-_LT_EOF
18408- ;;
18409- *) # Bourne compatible functions.
18410- cat << \_LT_EOF >> "$cfgfile"
18411-
18412-# func_dirname file append nondir_replacement
18413-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
18414-# otherwise set result to NONDIR_REPLACEMENT.
18415-func_dirname ()
18416-{
18417- # Extract subdirectory from the argument.
18418- func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
18419- if test "X$func_dirname_result" = "X${1}"; then
18420- func_dirname_result="${3}"
18421- else
18422- func_dirname_result="$func_dirname_result${2}"
18423- fi
18424-}
18425-
18426-# func_basename file
18427-func_basename ()
18428-{
18429- func_basename_result=`$ECHO "${1}" | $SED "$basename"`
18430-}
18431-
18432-
18433-# func_stripname prefix suffix name
18434-# strip PREFIX and SUFFIX off of NAME.
18435-# PREFIX and SUFFIX must not contain globbing or regex special
18436-# characters, hashes, percent signs, but SUFFIX may contain a leading
18437-# dot (in which case that matches only a dot).
18438-# func_strip_suffix prefix name
18439-func_stripname ()
18440-{
18441- case ${2} in
18442- .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
18443- *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
18444- esac
18445-}
18446-
18447-# sed scripts:
18448-my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q'
18449-my_sed_long_arg='1s/^-[^=]*=//'
18450-
18451-# func_opt_split
18452-func_opt_split ()
18453-{
18454- func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"`
18455- func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"`
18456-}
18457-
18458-# func_lo2o object
18459-func_lo2o ()
18460-{
18461- func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
18462-}
18463-
18464-# func_xform libobj-or-source
18465-func_xform ()
18466-{
18467- func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
18468-}
18469-
18470-# func_arith arithmetic-term...
18471-func_arith ()
18472-{
18473- func_arith_result=`expr "$@"`
18474-}
18475-
18476-# func_len string
18477-# STRING may not start with a hyphen.
18478-func_len ()
18479-{
18480- func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len`
18481-}
18482-
18483-_LT_EOF
18484-esac
18485-
18486-case $lt_shell_append in
18487- yes)
18488- cat << \_LT_EOF >> "$cfgfile"
18489-
18490-# func_append var value
18491-# Append VALUE to the end of shell variable VAR.
18492-func_append ()
18493-{
18494- eval "$1+=\$2"
18495-}
18496-_LT_EOF
18497- ;;
18498- *)
18499- cat << \_LT_EOF >> "$cfgfile"
18500-
18501-# func_append var value
18502-# Append VALUE to the end of shell variable VAR.
18503-func_append ()
18504-{
18505- eval "$1=\$$1\$2"
18506-}
18507-
18508-_LT_EOF
18509- ;;
18510- esac
18511+ sed '$q' "$ltmain" >> "$cfgfile" \
18512+ || (rm -f "$cfgfile"; exit 1)
18513
18514+ if test x"$xsi_shell" = xyes; then
18515+ sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
18516+func_dirname ()\
18517+{\
18518+\ case ${1} in\
18519+\ */*) func_dirname_result="${1%/*}${2}" ;;\
18520+\ * ) func_dirname_result="${3}" ;;\
18521+\ esac\
18522+} # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \
18523+ && mv -f "$cfgfile.tmp" "$cfgfile" \
18524+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18525+test 0 -eq $? || _lt_function_replace_fail=:
18526+
18527+
18528+ sed -e '/^func_basename ()$/,/^} # func_basename /c\
18529+func_basename ()\
18530+{\
18531+\ func_basename_result="${1##*/}"\
18532+} # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \
18533+ && mv -f "$cfgfile.tmp" "$cfgfile" \
18534+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18535+test 0 -eq $? || _lt_function_replace_fail=:
18536+
18537+
18538+ sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\
18539+func_dirname_and_basename ()\
18540+{\
18541+\ case ${1} in\
18542+\ */*) func_dirname_result="${1%/*}${2}" ;;\
18543+\ * ) func_dirname_result="${3}" ;;\
18544+\ esac\
18545+\ func_basename_result="${1##*/}"\
18546+} # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \
18547+ && mv -f "$cfgfile.tmp" "$cfgfile" \
18548+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18549+test 0 -eq $? || _lt_function_replace_fail=:
18550+
18551+
18552+ sed -e '/^func_stripname ()$/,/^} # func_stripname /c\
18553+func_stripname ()\
18554+{\
18555+\ # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\
18556+\ # positional parameters, so assign one to ordinary parameter first.\
18557+\ func_stripname_result=${3}\
18558+\ func_stripname_result=${func_stripname_result#"${1}"}\
18559+\ func_stripname_result=${func_stripname_result%"${2}"}\
18560+} # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \
18561+ && mv -f "$cfgfile.tmp" "$cfgfile" \
18562+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18563+test 0 -eq $? || _lt_function_replace_fail=:
18564+
18565+
18566+ sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\
18567+func_split_long_opt ()\
18568+{\
18569+\ func_split_long_opt_name=${1%%=*}\
18570+\ func_split_long_opt_arg=${1#*=}\
18571+} # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \
18572+ && mv -f "$cfgfile.tmp" "$cfgfile" \
18573+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18574+test 0 -eq $? || _lt_function_replace_fail=:
18575+
18576+
18577+ sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\
18578+func_split_short_opt ()\
18579+{\
18580+\ func_split_short_opt_arg=${1#??}\
18581+\ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\
18582+} # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \
18583+ && mv -f "$cfgfile.tmp" "$cfgfile" \
18584+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18585+test 0 -eq $? || _lt_function_replace_fail=:
18586+
18587+
18588+ sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\
18589+func_lo2o ()\
18590+{\
18591+\ case ${1} in\
18592+\ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\
18593+\ *) func_lo2o_result=${1} ;;\
18594+\ esac\
18595+} # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \
18596+ && mv -f "$cfgfile.tmp" "$cfgfile" \
18597+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18598+test 0 -eq $? || _lt_function_replace_fail=:
18599+
18600+
18601+ sed -e '/^func_xform ()$/,/^} # func_xform /c\
18602+func_xform ()\
18603+{\
18604+ func_xform_result=${1%.*}.lo\
18605+} # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \
18606+ && mv -f "$cfgfile.tmp" "$cfgfile" \
18607+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18608+test 0 -eq $? || _lt_function_replace_fail=:
18609+
18610+
18611+ sed -e '/^func_arith ()$/,/^} # func_arith /c\
18612+func_arith ()\
18613+{\
18614+ func_arith_result=$(( $* ))\
18615+} # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \
18616+ && mv -f "$cfgfile.tmp" "$cfgfile" \
18617+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18618+test 0 -eq $? || _lt_function_replace_fail=:
18619+
18620+
18621+ sed -e '/^func_len ()$/,/^} # func_len /c\
18622+func_len ()\
18623+{\
18624+ func_len_result=${#1}\
18625+} # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \
18626+ && mv -f "$cfgfile.tmp" "$cfgfile" \
18627+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18628+test 0 -eq $? || _lt_function_replace_fail=:
18629+
18630+fi
18631+
18632+if test x"$lt_shell_append" = xyes; then
18633+ sed -e '/^func_append ()$/,/^} # func_append /c\
18634+func_append ()\
18635+{\
18636+ eval "${1}+=\\${2}"\
18637+} # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \
18638+ && mv -f "$cfgfile.tmp" "$cfgfile" \
18639+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18640+test 0 -eq $? || _lt_function_replace_fail=:
18641+
18642+
18643+ sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\
18644+func_append_quoted ()\
18645+{\
18646+\ func_quote_for_eval "${2}"\
18647+\ eval "${1}+=\\\\ \\$func_quote_for_eval_result"\
18648+} # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \
18649+ && mv -f "$cfgfile.tmp" "$cfgfile" \
18650+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18651+test 0 -eq $? || _lt_function_replace_fail=:
18652+
18653+
18654+ # Save a `func_append' function call where possible by direct use of '+='
18655+ sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
18656+ && mv -f "$cfgfile.tmp" "$cfgfile" \
18657+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18658+ test 0 -eq $? || _lt_function_replace_fail=:
18659+else
18660+ # Save a `func_append' function call even when '+=' is not available
18661+ sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
18662+ && mv -f "$cfgfile.tmp" "$cfgfile" \
18663+ || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18664+ test 0 -eq $? || _lt_function_replace_fail=:
18665+fi
18666+
18667+if test x"$_lt_function_replace_fail" = x":"; then
18668+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
18669+$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
18670+fi
18671
18672- sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
18673- || (rm -f "$cfgfile"; exit 1)
18674
18675- mv -f "$cfgfile" "$ofile" ||
18676+ mv -f "$cfgfile" "$ofile" ||
18677 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
18678 chmod +x "$ofile"
18679
18680Index: binutils-2.22/bfd/configure.in
18681===================================================================
18682--- binutils-2.22.orig/bfd/configure.in
18683+++ binutils-2.22/bfd/configure.in
18684@@ -536,7 +536,7 @@ changequote(,)dnl
18685 x=`sed -n -e 's/^[ ]*PICFLAG[ ]*=[ ]*//p' < ../libiberty/Makefile | sed -n '$p'`
18686 changequote([,])dnl
18687 if test -n "$x"; then
18688- SHARED_LIBADD="-L`pwd`/../libiberty/pic -liberty"
18689+ SHARED_LIBADD="`pwd`/../libiberty/pic/libiberty.a"
18690 fi
18691
18692 # More hacks to build DLLs on Windows.
18693Index: binutils-2.22/opcodes/configure.in
18694===================================================================
18695--- binutils-2.22.orig/opcodes/configure.in
18696+++ binutils-2.22/opcodes/configure.in
18697@@ -134,7 +134,7 @@ changequote(,)dnl
18698 x=`sed -n -e 's/^[ ]*PICFLAG[ ]*=[ ]*//p' < ../libiberty/Makefile | sed -n '$p'`
18699 changequote([,])dnl
18700 if test -n "$x"; then
18701- SHARED_LIBADD="-L`pwd`/../libiberty/pic -liberty"
18702+ SHARED_LIBADD="`pwd`/../libiberty/pic/libiberty.a"
18703 fi
18704
18705 case "${host}" in
diff --git a/meta/recipes-devtools/binutils/binutils/libtool-rpath-fix.patch b/meta/recipes-devtools/binutils/binutils/libtool-rpath-fix.patch
deleted file mode 100644
index 4fcffa471e..0000000000
--- a/meta/recipes-devtools/binutils/binutils/libtool-rpath-fix.patch
+++ /dev/null
@@ -1,39 +0,0 @@
1Upstream-Status: Inappropriate [embedded specific]
2
3Enabling sysroot support in libtool exposed a bug where the final
4library had an RPATH encoded into it which still pointed to the
5sysroot. This works around the issue until it gets sorted out
6upstream.
7
8Fix suggested by Richard Purdie <richard.purdie@linuxfoundation.org>
9Signed-off-by: Scott Garman <scott.a.garman@intel.com>
10
11Index: binutils-2.22/ltmain.sh
12===================================================================
13--- binutils-2.22.orig/ltmain.sh
14+++ binutils-2.22/ltmain.sh
15@@ -8035,9 +8035,11 @@ EOF
16 test "$opt_mode" != relink && rpath="$compile_rpath$rpath"
17 for libdir in $rpath; do
18 if test -n "$hardcode_libdir_flag_spec"; then
19+ func_replace_sysroot "$libdir"
20+ libdir=$func_replace_sysroot_result
21+ func_stripname '=' '' "$libdir"
22+ libdir=$func_stripname_result
23 if test -n "$hardcode_libdir_separator"; then
24- func_replace_sysroot "$libdir"
25- libdir=$func_replace_sysroot_result
26 if test -z "$hardcode_libdirs"; then
27 hardcode_libdirs="$libdir"
28 else
29@@ -8770,6 +8772,10 @@ EOF
30 hardcode_libdirs=
31 for libdir in $compile_rpath $finalize_rpath; do
32 if test -n "$hardcode_libdir_flag_spec"; then
33+ func_replace_sysroot "$libdir"
34+ libdir=$func_replace_sysroot_result
35+ func_stripname '=' '' "$libdir"
36+ libdir=$func_stripname_result
37 if test -n "$hardcode_libdir_separator"; then
38 if test -z "$hardcode_libdirs"; then
39 hardcode_libdirs="$libdir"
diff --git a/meta/recipes-devtools/binutils/binutils/mips64-default-ld-emulation.patch b/meta/recipes-devtools/binutils/binutils/mips64-default-ld-emulation.patch
deleted file mode 100644
index ab01859fa6..0000000000
--- a/meta/recipes-devtools/binutils/binutils/mips64-default-ld-emulation.patch
+++ /dev/null
@@ -1,49 +0,0 @@
1for mips64*-*-linux we change the default emulations to be
2N64 instead of N32
3
4Upstream-Status: Inappropriate [ OE configuration Specific]
5
6Signed-off-by: Khem Raj <raj.khem@gmail.com>
7
8Index: binutils-2.22/bfd/config.bfd
9===================================================================
10--- binutils-2.22.orig/bfd/config.bfd 2011-07-28 15:35:13.000000000 -0700
11+++ binutils-2.22/bfd/config.bfd 2012-04-23 21:07:44.151578222 -0700
12@@ -970,13 +970,13 @@
13 ;;
14 #ifdef BFD64
15 mips64*el-*-linux*)
16- targ_defvec=bfd_elf32_ntradlittlemips_vec
17- targ_selvecs="bfd_elf32_ntradbigmips_vec bfd_elf32_tradlittlemips_vec bfd_elf32_tradbigmips_vec bfd_elf64_tradlittlemips_vec bfd_elf64_tradbigmips_vec"
18+ targ_defvec=bfd_elf64_tradlittlemips_vec
19+ targ_selvecs="bfd_elf32_ntradbigmips_vec bfd_elf32_ntradlittlemips_vec bfd_elf32_tradlittlemips_vec bfd_elf32_tradbigmips_vec bfd_elf64_tradbigmips_vec"
20 want64=true
21 ;;
22 mips64*-*-linux*)
23- targ_defvec=bfd_elf32_ntradbigmips_vec
24- targ_selvecs="bfd_elf32_ntradlittlemips_vec bfd_elf32_tradbigmips_vec bfd_elf32_tradlittlemips_vec bfd_elf64_tradbigmips_vec bfd_elf64_tradlittlemips_vec"
25+ targ_defvec=bfd_elf64_tradbigmips_vec
26+ targ_selvecs="bfd_elf32_ntradbigmips_vec bfd_elf32_ntradlittlemips_vec bfd_elf32_tradbigmips_vec bfd_elf32_tradlittlemips_vec bfd_elf64_tradlittlemips_vec"
27 want64=true
28 ;;
29 #endif
30Index: binutils-2.22/ld/configure.tgt
31===================================================================
32--- binutils-2.22.orig/ld/configure.tgt 2011-11-21 01:29:37.000000000 -0800
33+++ binutils-2.22/ld/configure.tgt 2012-04-23 21:05:34.183571931 -0700
34@@ -395,11 +395,11 @@
35 mips*-*-vxworks*) targ_emul=elf32ebmipvxworks
36 targ_extra_emuls="elf32elmipvxworks" ;;
37 mips*-*-windiss) targ_emul=elf32mipswindiss ;;
38-mips64*el-*-linux-*) targ_emul=elf32ltsmipn32
39- targ_extra_emuls="elf32btsmipn32 elf32ltsmip elf32btsmip elf64ltsmip elf64btsmip"
40+mips64*el-*-linux-*) targ_emul=elf64ltsmip
41+ targ_extra_emuls="elf32btsmipn32 elf32ltsmipn32 elf32ltsmip elf32btsmip elf64btsmip"
42 targ_extra_libpath=$targ_extra_emuls ;;
43-mips64*-*-linux-*) targ_emul=elf32btsmipn32
44- targ_extra_emuls="elf32ltsmipn32 elf32btsmip elf32ltsmip elf64btsmip elf64ltsmip"
45+mips64*-*-linux-*) targ_emul=elf64btsmip
46+ targ_extra_emuls="elf32btsmipn32 elf32ltsmipn32 elf32btsmip elf32ltsmip elf64ltsmip"
47 targ_extra_libpath=$targ_extra_emuls ;;
48 mips*el-*-linux-*) targ_emul=elf32ltsmip
49 targ_extra_emuls="elf32btsmip elf32ltsmipn32 elf64ltsmip elf32btsmipn32 elf64btsmip"
diff --git a/meta/recipes-devtools/binutils/binutils/relocatable_sdk.patch b/meta/recipes-devtools/binutils/binutils/relocatable_sdk.patch
deleted file mode 100644
index 7408c31aad..0000000000
--- a/meta/recipes-devtools/binutils/binutils/relocatable_sdk.patch
+++ /dev/null
@@ -1,49 +0,0 @@
1Upstream-Status: Inappropriate [SDK specific]
2
3This patch will modify the ELF linker scripts so that the crosssdk linker will
4generate binaries with a 4096 bytes PT_INTERP section. When the binaries will
5be relocated, at SDK install time, the interpreter path can be easily changed
6by the relocating script.
7
8Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com>
9
10Index: binutils_git/ld/genscripts.sh
11===================================================================
12--- binutils_git.orig/ld/genscripts.sh 2012-11-21 11:58:23.325441925 +0200
13+++ binutils_git/ld/genscripts.sh 2012-11-21 12:03:42.106815400 +0200
14@@ -290,6 +290,7 @@
15 LD_FLAG=r
16 DATA_ALIGNMENT=${DATA_ALIGNMENT_r}
17 DEFAULT_DATA_ALIGNMENT="ALIGN(${SEGMENT_SIZE})"
18+PARTIAL_LINKING=" "
19 ( echo "/* Script for ld -r: link without relocation */"
20 . ${CUSTOMIZER_SCRIPT}
21 . ${srcdir}/scripttempl/${SCRIPT_NAME}.sc
22@@ -298,10 +299,12 @@
23 LD_FLAG=u
24 DATA_ALIGNMENT=${DATA_ALIGNMENT_u}
25 CONSTRUCTING=" "
26+PARTIAL_LINKING=" "
27 ( echo "/* Script for ld -Ur: link w/out relocation, do create constructors */"
28 . ${CUSTOMIZER_SCRIPT}
29 . ${srcdir}/scripttempl/${SCRIPT_NAME}.sc
30 ) | sed -e '/^ *$/d;s/[ ]*$//' > ldscripts/${EMULATION_NAME}.xu
31+unset PARTIAL_LINKING
32
33 LD_FLAG=
34 DATA_ALIGNMENT=${DATA_ALIGNMENT_}
35Index: binutils_git/ld/scripttempl/elf.sc
36===================================================================
37--- binutils_git.orig/ld/scripttempl/elf.sc 2012-11-21 12:02:26.800377384 +0200
38+++ binutils_git/ld/scripttempl/elf.sc 2012-11-21 12:04:16.166109621 +0200
39@@ -124,8 +124,8 @@
40 DATA_SEGMENT_END=". = DATA_SEGMENT_END (.);"
41 DATA_SEGMENT_RELRO_END=". = DATA_SEGMENT_RELRO_END (${SEPARATE_GOTPLT-0}, .);"
42 fi
43-if test -z "${INITIAL_READONLY_SECTIONS}${CREATE_SHLIB}"; then
44- INITIAL_READONLY_SECTIONS=".interp ${RELOCATING-0} : { *(.interp) }"
45+if test -z "${INITIAL_READONLY_SECTIONS}${CREATE_SHLIB}${PARTIAL_LINKING}"; then
46+ INITIAL_READONLY_SECTIONS=".interp ${RELOCATING-0} : { *(.interp); . = 0x1000; }"
47 fi
48 if test -z "$PLT"; then
49 IPLT=".iplt ${RELOCATING-0} : { *(.iplt) }"
diff --git a/meta/recipes-devtools/binutils/binutils/rpath-sysroot.patch b/meta/recipes-devtools/binutils/binutils/rpath-sysroot.patch
deleted file mode 100644
index 955699ed7b..0000000000
--- a/meta/recipes-devtools/binutils/binutils/rpath-sysroot.patch
+++ /dev/null
@@ -1,38 +0,0 @@
1ld: -rpath must search under sysroot
2
3The -rpath argument would search the host filesystem for libraries,
4even when a sysroot was defined. For cross toolchains with targets
5compatible with the host architecture this can find incorrect
6libraries. Leave -rpath-link unmodified, as build systems in the wild
7are already using this to point to host directories.
8
9Signed-off-by: Andy Ross <andy.ross@windriver.com>
10Upstream-Status: submitted (binutils@sourceware.org 2012-08-22)
11---
12 ld/emultempl/elf32.em | 10 +++++++---
13 1 file changed, 7 insertions(+), 3 deletions(-)
14
15diff --git a/ld/emultempl/elf32.em b/ld/emultempl/elf32.em
16index de51050..35e0e7e 100644
17--- a/ld/emultempl/elf32.em
18+++ b/ld/emultempl/elf32.em
19@@ -1263,9 +1263,13 @@ fragment <<EOF
20 EOF
21 if [ "x${USE_LIBPATH}" = xyes ] ; then
22 fragment <<EOF
23- if (gld${EMULATION_NAME}_search_needed (command_line.rpath,
24- &n, force))
25- break;
26+ if (command_line.rpath) {
27+ char *tmprp = gld${EMULATION_NAME}_add_sysroot (command_line.rpath);
28+ found = gld${EMULATION_NAME}_search_needed (tmprp, &n, force);
29+ free(tmprp);
30+ if (found)
31+ break;
32+ }
33 EOF
34 fi
35 if [ "x${NATIVE}" = xyes ] ; then
36--
371.7.11.2
38
diff --git a/meta/recipes-devtools/binutils/binutils_2.22.bb b/meta/recipes-devtools/binutils/binutils_2.22.bb
deleted file mode 100644
index 1523e87273..0000000000
--- a/meta/recipes-devtools/binutils/binutils_2.22.bb
+++ /dev/null
@@ -1,35 +0,0 @@
1require binutils.inc
2require binutils-${PV}.inc
3
4DEPENDS += "flex bison zlib"
5
6EXTRA_OECONF += "--with-sysroot=/ \
7 --enable-install-libbfd \
8 --enable-shared \
9 "
10
11EXTRA_OECONF_class-native = "--enable-targets=all --enable-64-bit-bfd --enable-install-libbfd"
12
13do_install_class-native () {
14 autotools_do_install
15
16 # Install the libiberty header
17 install -d ${D}${includedir}
18 install -m 644 ${S}/include/ansidecl.h ${D}${includedir}
19 install -m 644 ${S}/include/libiberty.h ${D}${includedir}
20
21 # We only want libiberty, libbfd and libopcodes
22 rm -rf ${D}${bindir}
23 rm -rf ${D}${prefix}/${TARGET_SYS}
24 rm -rf ${D}${prefix}/lib/ldscripts
25 rm -rf ${D}${prefix}/share/info
26 rm -rf ${D}${prefix}/share/locale
27 rm -rf ${D}${prefix}/share/man
28 rmdir ${D}${prefix}/share || :
29 rmdir ${D}/${libdir}/gcc-lib || :
30 rmdir ${D}/${libdir}64/gcc-lib || :
31 rmdir ${D}/${libdir} || :
32 rmdir ${D}/${libdir}64 || :
33}
34
35BBCLASSEXTEND = "native"