1 2005-05-05 H.J. Lu <hongjiu.lu@intel.com>
3 * elflink.c (_bfd_elf_provide_section_bound_symbols): Use
4 "__bss_start" instead of "_edata" as fallback.
6 2005-05-05 H.J. Lu <hongjiu.lu@intel.com>
8 * bfd-in2.h: Regenerated.
10 2005-05-05 Paul Brook <paul@codesourcery.com>
12 * config.bfd: Use bfd_elf32_i386_vxworks_vec for i?86-*-vxworks.
13 * configure.in: Add bfd_elf32_i386_vxworks_vec. i386 targets need
15 * configure: Regenerate.
16 * Makefile.am (BFD32_BACKENDS): Add elf-vxworks.lo.
17 (BFD32_BACKENDS_CFILES): Add elf-vxworks.c.
18 (elf32-i386.lo): Depend on elf-vxworks.h.
19 (elf-vxworks.lo): New rule.
20 * Makefile.in: Regenerate.
21 * elf-bfd.h (elf_backend_data): Update type of
22 elf_backend_emit_relocs.
23 (_bfd_elf_link_output_relocs): Update prototype.
24 * elflink.c (_bfd_elf_link_output_relocs): Always use
25 bed->elf_backend_emit_relocs when outputting relocations.
26 * elfxx-target.h (elf_backend_emit_relocs): Default to
27 _bfd_elf_link_output_relocs.
28 * targets.c (bfd_elf32_i386_vxworks_vec): Declare.
29 (_bfd_target_vector): Add bfd_elf32_i386_vxworks_vec.
30 * elf32-i386.c: Add elf32-i386-vxworks target BFD.
31 (elf_i386_plt0_entry): Remove padding.
32 (elf_i386_pic_plt0_entry): Ditto.
33 (PLTRESOLVE_RELOCS_SHLIB, PLTRESOLVE_RELOCS): Define.
34 (PLT_NON_JUMP_SLOT_RELOCS): Define.
35 (elf_i386_link_hash_table): Add srelplt2, hgot, hplt, is_vxworks and
37 (elf_i386_link_hash_table_create): Zero them.
38 (elf_i386_create_dynamic_sections): Create static relocation section.
39 (allocate_dynrelocs): Allocate space for static PLT relocations.
40 (elf_i386_size_dynamic_sections): Save shortcuts to PLT and GOT
41 symbols. Give PLT symbols function type. Don't strip PLT sections
42 if we have exported symbols from them.
43 (elf_i386_finish_dynamic_symbol): Fill in VxWorks PLT static
44 relocation section. Don't mark _GLOBAL_OFFSET_TABLE_ as absolute on
46 (elf_i386_finish_dynamic_sections): Allow different pad bytes.
47 Add relocation for GOT location. Fill in PLT static relocations.
48 (elf_i386_vxworks_link_hash_table_create): New function.
49 (elf_i386_vxworks_link_output_symbol_hook): New function.
50 * elf-vxworks.h: New file.
52 2005-05-05 H.J. Lu <hongjiu.lu@intel.com>
54 * section.c (bfd_make_section_anyway_with_flags): New.
55 (bfd_make_section_anyway): Call bfd_make_section_anyway_with_flags,
56 (bfd_make_section_with_flags): New.
57 (bfd_make_section): Call bfd_make_section_with_flags.
59 * elf-m10300.c (_bfd_mn10300_elf_create_got_section): Call
60 bfd_make_section_with_flags/bfd_make_section_anyway_with_flags
61 instead of bfd_make_section/bfd_make_section and don't call
62 bfd_set_section_flags.
63 (mn10300_elf_check_relocs): Likewise.
64 (_bfd_mn10300_elf_create_dynamic_sections): Likewise.
65 * elf32-arm.c (create_got_section): Likewise.
66 (bfd_elf32_arm_add_glue_sections_to_bfd): Likewise.
67 (elf32_arm_check_relocs): Likewise.
68 * elf32-cris.c (cris_elf_check_relocs): Likewise.
69 * elf32-frv.c (elf32_frv_add_symbol_hook): Likewise.
70 (_frv_create_got_section): Likewise.
71 (elf32_frvfdpic_create_dynamic_sections): Likewise.
72 * elf32-hppa.c (elf32_hppa_create_dynamic_sections): Likewise.
73 (elf32_hppa_check_relocs): Likewise.
74 * elf32-i370.c (i370_elf_create_dynamic_sections): Likewise.
75 (i370_elf_check_relocs): Likewise.
76 * elf32-i386.c (create_got_section): Likewise.
77 (elf_i386_check_relocs): Likewise.
78 * elf32-m32r.c (m32r_elf_add_symbol_hook): Likewise.
79 (create_got_section): Likewise.
80 (m32r_elf_create_dynamic_sections): Likewise.
81 (m32r_elf_check_relocs): Likewise.
82 * elf32-m68k.c (elf_m68k_check_relocs): Likewise.
83 * elf32-ppc.c (ppc_elf_create_got): Likewise.
84 (ppc_elf_create_dynamic_sections): Likewise.
85 (ppc_elf_add_symbol_hook): Likewise.
86 (ppc_elf_check_relocs): Likewise.
87 * elf32-s390.c (create_got_section): Likewise.
88 (elf_s390_check_relocs): Likewise.
89 * elf32-sh.c (create_got_section): Likewise.
90 (sh_elf_create_dynamic_sections): Likewise.
91 (sh_elf_check_relocs): Likewise.
92 * elf32-vax.c (elf_vax_check_relocs): Likewise.
93 * elf32-xstormy16.c (xstormy16_elf_check_relocs): Likewise.
94 * elf32-xtensa.c (elf_xtensa_create_dynamic_sections): Likewise.
95 (add_extra_plt_sections): Likewise.
96 * elf64-alpha.c (elf64_alpha_add_symbol_hook): Likewise.
97 (elf64_alpha_create_got_section): Likewise.
98 (elf64_alpha_create_dynamic_sections): Likewise.
99 (elf64_alpha_check_relocs): Likewise.
100 * elf64-hppa.c (get_reloc_section): Likewise.
104 (get_stub): Likewise.
105 (elf64_hppa_create_dynamic_sectionso): Likewise.
106 * elf64-mmix.c (mmix_elf_check_common_relocs): Likewise.
107 * elf64-ppc.c (create_linkage_sections): Likewise.
108 (ppc64_elf_check_relocs): Likewise.
109 * elf64-s390.c (create_got_section): Likewise.
110 (elf_s390_check_relocs): Likewise.
111 * elf64-sh64.c (sh_elf64_check_relocs): Likewise.
112 (sh64_elf64_create_dynamic_sections): Likewise.
113 * elf64-x86-64.c (create_got_section): Likewise.
114 (elf64_x86_64_check_relocs): Likewise.
115 * elflink.c (_bfd_elf_create_got_section): Likewise.
116 (_bfd_elf_link_create_dynamic_sections): Likewise.
117 (elf_link_add_object_symbols): Likewise.
118 * elfxx-ia64.c (elfNN_ia64_add_symbol_hook): Likewise.
119 (elfNN_ia64_create_dynamic_sections): Likewise.
120 (get_fptr): Likewise.
121 (get_pltoff): Likewise.
122 (get_reloc_section): Likewise.
123 (elfNN_ia64_object_p): Likewise.
124 * elfxx-mips.c (mips_elf_rel_dyn_section): Likewise.
125 (mips_elf_create_compact_rel_section): Likewise.
126 (mips_elf_create_got_section): Likewise.
127 (_bfd_mips_elf_create_dynamic_sections): Likewise.
128 * elfxx-sparc.c (create_got_section): Likewise.
129 (_bfd_sparc_elf_check_relocs): Likewise.
131 * elf.c (_bfd_elf_new_section_hook): Call _bfd_elf_get_sec_type_attr
132 on linker created sections.
134 2005-05-05 H.J. Lu <hongjiu.lu@intel.com>
137 * elflink.c (_bfd_elf_link_assign_sym_version): Allow version
138 script on executable.
140 2005-05-05 John Levon <levon@movementarian.org>
142 * dwarf2.c (read_abbrevs): If bfd_realloc fails, free currently
143 allocated memory before returning.
144 (decode_line_info): Likewise.
145 (_bfd_dwarf2_cleanup_debug_info): New function: Frees memory
146 allocated by functions in this file.
147 * elf-bfd.h (_bfd_dwarf2_cleanup_debug_info): Prototype.
148 * elf.c (bfd_elf_close_and_cleanup): Call
149 _bfd_dwarf2_cleanup_debug_info.
151 2005-05-05 Hans-Peter Nilsson <hp@axis.com>
153 * Makefile.am (INCLUDES): Don't -D_GNU_SOURCE here.
154 * configure.in: Call AC_GNU_SOURCE here, after AC_PROG_CC.
155 * configure, config.in, Makefile.in: Regenerate.
156 * sysdep.h (stpcpy): Revert last change.
158 2005-05-05 Hans-Peter Nilsson <hp@axis.com>
160 * sysdep.h (stpcpy): Wrap declaration in parentheses.
162 2005-05-04 H.J. Lu <hongjiu.lu@intel.com>
164 * elfxx-ia64.c (ARCH_SIZE): New.
165 (LOG_SECTION_ALIGN): Likewise.
166 (elfNN_ia64_create_dynamic_sections): Use LOG_SECTION_ALIGN to
167 align relocation sections.
168 (get_fptr): Likewise.
169 (get_reloc_section): Likewise.
170 (elfNN_ia64_tprel_base): Likewise.
171 (elfNN_ia64_check_relocs): Support 32bit relocations.
172 (allocate_global_fptr_got): Likewise.
173 (allocate_dynrel_entries): Likewise.
174 (set_got_entry): Likewise.
175 (set_pltoff_entry): Likewise.
176 (elfNN_ia64_relocate_section): Likewise.
178 2005-05-04 H.J. Lu <hongjiu.lu@intel.com>
180 * configure.in: Add AC_CHECK_DECLS(stpcpy).
181 * configure: Regenerate.
182 * config.in: Likewise.
184 * sysdep.h (stpcpy): New.
186 2005-05-04 Nick Clifton <nickc@redhat.com>
188 * Update the address and phone number of the FSF organization in
189 the GPL notices in the following files:
190 aix386-core.c, aix5ppc-core.c, aout-adobe.c, aout-arm.c,
191 aout-cris.c, aout-ns32k.c, aout-sparcle.c, aout-target.h,
192 aout-tic30.c, aout0.c, aout32.c, aout64.c, aoutf1.h, aoutx.h,
193 archive.c, archive64.c, archures.c, armnetbsd.c, bfd-in.h,
194 bfd-in2.h, bfd.c, bfdio.c, bfdwin.c, binary.c, bout.c, cache.c,
195 cf-i386lynx.c, cf-m68klynx.c, cf-sparclynx.c, cisco-core.c,
196 coff-a29k.c, coff-alpha.c, coff-apollo.c, coff-arm.c, coff-aux.c,
197 coff-go32.c, coff-h8300.c, coff-h8500.c, coff-i386.c, coff-i860.c,
198 coff-i960.c, coff-ia64.c, coff-m68k.c, coff-m88k.c, coff-maxq.c,
199 coff-mcore.c, coff-mips.c, coff-or32.c, coff-pmac.c, coff-ppc.c,
200 coff-rs6000.c, coff-sh.c, coff-sparc.c, coff-stgo32.c,
201 coff-svm68k.c, coff-tic30.c, coff-tic4x.c, coff-tic54x.c,
202 coff-tic80.c, coff-u68k.c, coff-w65.c, coff-we32k.c, coff-z8k.c,
203 coff64-rs6000.c, coffcode.h, coffgen.c, cofflink.c, coffswap.h,
204 corefile.c, cpu-a29k.c, cpu-alpha.c, cpu-arc.c, cpu-arm.c,
205 cpu-avr.c, cpu-cr16c.c, cpu-cris.c, cpu-crx.c, cpu-d10v.c,
206 cpu-d30v.c, cpu-dlx.c, cpu-fr30.c, cpu-frv.c, cpu-h8300.c,
207 cpu-h8500.c, cpu-hppa.c, cpu-i370.c, cpu-i386.c, cpu-i860.c,
208 cpu-i960.c, cpu-ia64-opc.c, cpu-ia64.c, cpu-ip2k.c, cpu-iq2000.c,
209 cpu-m10200.c, cpu-m10300.c, cpu-m32r.c, cpu-m68hc11.c,
210 cpu-m68hc12.c, cpu-m68k.c, cpu-m88k.c, cpu-maxq.c, cpu-mcore.c,
211 cpu-mips.c, cpu-mmix.c, cpu-msp430.c, cpu-ns32k.c, cpu-openrisc.c,
212 cpu-or32.c, cpu-pdp11.c, cpu-pj.c, cpu-powerpc.c, cpu-rs6000.c,
213 cpu-s390.c, cpu-sh.c, cpu-sparc.c, cpu-tic30.c, cpu-tic4x.c,
214 cpu-tic54x.c, cpu-tic80.c, cpu-v850.c, cpu-vax.c, cpu-w65.c,
215 cpu-we32k.c, cpu-xstormy16.c, cpu-xtensa.c, cpu-z8k.c, demo64.c,
216 dwarf1.c, dwarf2.c, ecoff.c, ecofflink.c, ecoffswap.h,
217 efi-app-ia32.c, efi-app-ia64.c, elf-bfd.h, elf-eh-frame.c,
218 elf-hppa.h, elf-m10200.c, elf-m10300.c, elf-strtab.c, elf.c,
219 elf32-am33lin.c, elf32-arc.c, elf32-arm.c, elf32-avr.c,
220 elf32-cr16c.c, elf32-cris.c, elf32-crx.c, elf32-d10v.c,
221 elf32-d30v.c, elf32-dlx.c, elf32-fr30.c, elf32-frv.c, elf32-gen.c,
222 elf32-h8300.c, elf32-hppa.c, elf32-hppa.h, elf32-i370.c,
223 elf32-i386.c, elf32-i860.c, elf32-i960.c, elf32-ip2k.c,
224 elf32-iq2000.c, elf32-m32r.c, elf32-m68hc11.c, elf32-m68hc12.c,
225 elf32-m68hc1x.c, elf32-m68hc1x.h, elf32-m68k.c, elf32-m88k.c,
226 elf32-mcore.c, elf32-mips.c, elf32-msp430.c, elf32-openrisc.c,
227 elf32-or32.c, elf32-pj.c, elf32-ppc.c, elf32-ppc.h, elf32-s390.c,
228 elf32-sh-symbian.c, elf32-sh.c, elf32-sh64-com.c, elf32-sh64.c,
229 elf32-sh64.h, elf32-sparc.c, elf32-v850.c, elf32-vax.c,
230 elf32-xstormy16.c, elf32-xtensa.c, elf32.c, elf64-alpha.c,
231 elf64-gen.c, elf64-hppa.c, elf64-hppa.h, elf64-mips.c,
232 elf64-mmix.c, elf64-ppc.c, elf64-ppc.h, elf64-s390.c,
233 elf64-sh64.c, elf64-sparc.c, elf64-x86-64.c, elf64.c, elfcode.h,
234 elfcore.h, elflink.c, elfn32-mips.c, elfxx-ia64.c, elfxx-mips.c,
235 elfxx-mips.h, elfxx-sparc.c, elfxx-sparc.h, elfxx-target.h,
236 epoc-pe-arm.c, epoc-pei-arm.c, format.c, freebsd.h, gen-aout.c,
237 genlink.h, hash.c, host-aout.c, hp300bsd.c, hp300hpux.c,
238 hppabsd-core.c, hpux-core.c, i386aout.c, i386bsd.c, i386dynix.c,
239 i386freebsd.c, i386linux.c, i386lynx.c, i386mach3.c, i386msdos.c,
240 i386netbsd.c, i386os9k.c, ieee.c, ihex.c, init.c, irix-core.c,
241 libaout.h, libbfd-in.h, libbfd.c, libbfd.h, libcoff-in.h,
242 libcoff.h, libecoff.h, libhppa.h, libieee.h, libnlm.h, liboasys.h,
243 libpei.h, libxcoff.h, linker.c, lynx-core.c, m68k4knetbsd.c,
244 m68klinux.c, m68klynx.c, m68knetbsd.c, m88kmach3.c, m88kopenbsd.c,
245 mach-o-target.c, mach-o.c, mach-o.h, merge.c, mipsbsd.c, mmo.c,
246 netbsd-core.c, netbsd.h, newsos3.c, nlm-target.h, nlm.c,
247 nlm32-alpha.c, nlm32-i386.c, nlm32-ppc.c, nlm32-sparc.c, nlm32.c,
248 nlm64.c, nlmcode.h, nlmswap.h, ns32k.h, ns32knetbsd.c, oasys.c,
249 opncls.c, osf-core.c, pc532-mach.c, pdp11.c, pe-arm.c, pe-i386.c,
250 pe-mcore.c, pe-mips.c, pe-ppc.c, pe-sh.c, peXXigen.c,
251 pef-traceback.h, pef.c, pef.h, pei-arm.c, pei-i386.c, pei-mcore.c,
252 pei-mips.c, pei-ppc.c, pei-sh.c, peicode.h, ppcboot.c,
253 ptrace-core.c, reloc.c, reloc16.c, riscix.c, rs6000-core.c,
254 sco5-core.c, section.c, simple.c, som.c, som.h, sparclinux.c,
255 sparclynx.c, sparcnetbsd.c, srec.c, stab-syms.c, stabs.c, sunos.c,
256 syms.c, sysdep.h, targets.c, tekhex.c, ticoff.h, trad-core.c,
257 vax1knetbsd.c, vaxbsd.c, vaxnetbsd.c, versados.c, vms-gsd.c,
258 vms-hdr.c, vms-misc.c, vms-tir.c, vms.c, vms.h, xcoff-target.h,
259 xcofflink.c, xsym.c, xsym.h, xtensa-isa.c, xtensa-modules.c,
260 doc/chew.c, hosts/alphavms.h
262 2005-05-04 H.J. Lu <hongjiu.lu@intel.com>
264 * bfd-in.h (_bfd_elf_provide_section_bound_symbols): New.
265 * bfd-in2.h: Regenerated.
267 * elflink.c (bfd_elf_set_symbol): New.
268 (_bfd_elf_provide_symbol): Call it.
269 (_bfd_elf_provide_section_bound_symbols): New.
271 2005-05-04 H.J. Lu <hongjiu.lu@intel.com>
273 * elflink.c (_bfd_elf_merge_symbol): Only skip weak definitions
274 at the end, if a strong definition has already been seen.
276 2005-05-04 Alan Modra <amodra@bigpond.net.au>
278 * section.c (struct bfd_section): Replace link_order_head and
279 link_order_tail with map_head and map_tail union.
280 (STD_SECTION): Update.
281 (_bfd_strip_section_from_output): Delete.
282 * aoutx.h: Update throughout for above changes.
283 * coff-ppc.c: Likewise.
284 * cofflink.c: Likewise.
286 * elf-eh-frame.c: Likewise.
287 * elf-m10300.c: Likewise.
289 * elf32-arm.c: Likewise.
290 * elf32-cris.c: Likewise.
291 * elf32-hppa.c: Likewise.
292 * elf32-i386.c: Likewise.
293 * elf32-m32r.c: Likewise.
294 * elf32-m68hc1x.c: Likewise.
295 * elf32-m68k.c: Likewise.
296 * elf32-ppc.c: Likewise.
297 * elf32-s390.c: Likewise.
298 * elf32-sh.c: Likewise.
299 * elf32-vax.c: Likewise.
300 * elf32-xtensa.c: Likewise.
301 * elf64-alpha.c: Likewise.
302 * elf64-hppa.c: Likewise.
303 * elf64-ppc.c: Likewise.
304 * elf64-s390.c: Likewise.
305 * elf64-sh64.c: Likewise.
306 * elf64-x86-64.c: Likewise.
307 * elflink.c: Likewise.
308 * elfxx-ia64.c: Likewise.
309 * elfxx-mips.c: Likewise.
310 * elfxx-sparc.c: Likewise.
311 * linker.c: Likewise.
314 * xcofflink.c: Likewise.
315 * elflink.c (bfd_boolean bfd_elf_size_dynsym_hash_dynstr): Split
316 out from bfd_elf_size_dynamic_sections.
317 * bfd-in.h (bfd_boolean bfd_elf_size_dynsym_hash_dynstr): Declare.
318 * bfd-in2.h: Regenerate.
320 2005-05-04 Nick Clifton <nickc@redhat.com>
322 * COPYING, aix386-core.c, aix5ppc-core.c, aout-adobe.c,
323 aout-arm.c, aout-cris.c, aout-ns32k.c, aout-sparcle.c,
324 aout-target.h, aout-tic30.c, aout0.c, aout32.c, aout64.c,
325 aoutf1.h, aoutx.h, archive.c, archive64.c, archures.c,
326 armnetbsd.c, bfd-in.h, bfd-in2.h, bfd.c, bfdio.c, bfdwin.c,
327 binary.c, bout.c, cache.c, cf-i386lynx.c, cf-m68klynx.c,
328 cf-sparclynx.c, cisco-core.c, coff-a29k.c, coff-alpha.c,
329 coff-apollo.c, coff-arm.c, coff-aux.c, coff-go32.c, coff-h8300.c,
330 coff-h8500.c, coff-i386.c, coff-i860.c, coff-i960.c, coff-ia64.c,
331 coff-m68k.c, coff-m88k.c, coff-maxq.c, coff-mcore.c, coff-mips.c,
332 coff-or32.c, coff-pmac.c, coff-ppc.c, coff-rs6000.c, coff-sh.c,
333 coff-sparc.c, coff-stgo32.c, coff-svm68k.c, coff-tic30.c,
334 coff-tic4x.c, coff-tic54x.c, coff-tic80.c, coff-u68k.c,
335 coff-w65.c, coff-we32k.c, coff-z8k.c, coff64-rs6000.c, coffcode.h,
336 coffgen.c, cofflink.c, coffswap.h, corefile.c, cpu-a29k.c,
337 cpu-alpha.c, cpu-arc.c, cpu-arm.c, cpu-avr.c, cpu-cr16c.c,
338 cpu-cris.c, cpu-crx.c, cpu-d10v.c, cpu-d30v.c, cpu-dlx.c,
339 cpu-fr30.c, cpu-frv.c, cpu-h8300.c, cpu-h8500.c, cpu-hppa.c,
340 cpu-i370.c, cpu-i386.c, cpu-i860.c, cpu-i960.c, cpu-ia64-opc.c,
341 cpu-ia64.c, cpu-ip2k.c, cpu-iq2000.c, cpu-m10200.c, cpu-m10300.c,
342 cpu-m32r.c, cpu-m68hc11.c, cpu-m68hc12.c, cpu-m68k.c, cpu-m88k.c,
343 cpu-maxq.c, cpu-mcore.c, cpu-mips.c, cpu-mmix.c, cpu-msp430.c,
344 cpu-ns32k.c, cpu-openrisc.c, cpu-or32.c, cpu-pdp11.c, cpu-pj.c,
345 cpu-powerpc.c, cpu-rs6000.c, cpu-s390.c, cpu-sh.c, cpu-sparc.c,
346 cpu-tic30.c, cpu-tic4x.c, cpu-tic54x.c, cpu-tic80.c, cpu-v850.c,
347 cpu-vax.c, cpu-w65.c, cpu-we32k.c, cpu-xstormy16.c, cpu-xtensa.c,
348 cpu-z8k.c, demo64.c, dwarf1.c, dwarf2.c, ecoff.c, ecofflink.c,
349 ecoffswap.h, efi-app-ia32.c, efi-app-ia64.c, elf-bfd.h,
350 elf-eh-frame.c, elf-hppa.h, elf-m10200.c, elf-m10300.c,
351 elf-strtab.c, elf.c, elf32-am33lin.c, elf32-arc.c, elf32-arm.c,
352 elf32-avr.c, elf32-cr16c.c, elf32-cris.c, elf32-crx.c,
353 elf32-d10v.c, elf32-d30v.c, elf32-dlx.c, elf32-fr30.c,
354 elf32-frv.c, elf32-gen.c, elf32-h8300.c, elf32-hppa.c,
355 elf32-hppa.h, elf32-i370.c, elf32-i386.c, elf32-i860.c,
356 elf32-i960.c, elf32-ip2k.c, elf32-iq2000.c, elf32-m32r.c,
357 elf32-m68hc11.c, elf32-m68hc12.c, elf32-m68hc1x.c,
358 elf32-m68hc1x.h, elf32-m68k.c, elf32-m88k.c, elf32-mcore.c,
359 elf32-mips.c, elf32-msp430.c, elf32-openrisc.c, elf32-or32.c,
360 elf32-pj.c, elf32-ppc.c, elf32-ppc.h, elf32-s390.c,
361 elf32-sh-symbian.c, elf32-sh.c, elf32-sh64-com.c, elf32-sh64.c,
362 elf32-sh64.h, elf32-sparc.c, elf32-v850.c, elf32-vax.c,
363 elf32-xstormy16.c, elf32-xtensa.c, elf32.c, elf64-alpha.c,
364 elf64-gen.c, elf64-hppa.c, elf64-hppa.h, elf64-mips.c,
365 elf64-mmix.c, elf64-ppc.c, elf64-ppc.h, elf64-s390.c,
366 elf64-sh64.c, elf64-sparc.c, elf64-x86-64.c, elf64.c, elfcode.h,
367 elfcore.h, elflink.c, elfn32-mips.c, elfxx-ia64.c, elfxx-mips.c,
368 elfxx-mips.h, elfxx-sparc.c, elfxx-sparc.h, elfxx-target.h,
369 epoc-pe-arm.c, epoc-pei-arm.c, format.c, freebsd.h, gen-aout.c,
370 genlink.h, hash.c, host-aout.c, hp300bsd.c, hp300hpux.c,
371 hppabsd-core.c, hpux-core.c, i386aout.c, i386bsd.c, i386dynix.c,
372 i386freebsd.c, i386linux.c, i386lynx.c, i386mach3.c, i386msdos.c,
373 i386netbsd.c, i386os9k.c, ieee.c, ihex.c, init.c, irix-core.c,
374 libaout.h, libbfd-in.h, libbfd.c, libbfd.h, libcoff-in.h,
375 libcoff.h, libecoff.h, libhppa.h, libieee.h, libnlm.h, liboasys.h,
376 libpei.h, libxcoff.h, linker.c, lynx-core.c, m68k4knetbsd.c,
377 m68klinux.c, m68klynx.c, m68knetbsd.c, m88kmach3.c, m88kopenbsd.c,
378 mach-o-target.c, mach-o.c, mach-o.h, merge.c, mipsbsd.c, mmo.c,
379 netbsd-core.c, netbsd.h, newsos3.c, nlm-target.h, nlm.c,
380 nlm32-alpha.c, nlm32-i386.c, nlm32-ppc.c, nlm32-sparc.c, nlm32.c,
381 nlm64.c, nlmcode.h, nlmswap.h, ns32k.h, ns32knetbsd.c, oasys.c,
382 opncls.c, osf-core.c, pc532-mach.c, pdp11.c, pe-arm.c, pe-i386.c,
383 pe-mcore.c, pe-mips.c, pe-ppc.c, pe-sh.c, peXXigen.c,
384 pef-traceback.h, pef.c, pef.h, pei-arm.c, pei-i386.c, pei-mcore.c,
385 pei-mips.c, pei-ppc.c, pei-sh.c, peicode.h, ppcboot.c,
386 ptrace-core.c, reloc.c, reloc16.c, riscix.c, rs6000-core.c,
387 sco5-core.c, section.c, simple.c, som.c, som.h, sparclinux.c,
388 sparclynx.c, sparcnetbsd.c, srec.c, stab-syms.c, stabs.c, sunos.c,
389 syms.c, sysdep.h, targets.c, tekhex.c, ticoff.h, trad-core.c,
390 vax1knetbsd.c, vaxbsd.c, vaxnetbsd.c, versados.c, vms-gsd.c,
391 vms-hdr.c, vms-misc.c, vms-tir.c, vms.c, vms.h, xcoff-target.h,
392 xcofflink.c, xsym.c, xsym.h, xtensa-isa.c, xtensa-modules.c,
393 doc/chew.c, doc/fdl.texi, hosts/alphavms.h: Update FSF address.
395 2005-05-04 Alan Modra <amodra@bigpond.net.au>
397 * section.c (bfd_section_list_remove): Don't clear s->next.
398 (bfd_section_list_append): Always init s->prev.
399 (bfd_section_list_prepend): Define.
400 (bfd_section_list_insert_after): Minor optimization.
401 (bfd_section_removed_from_list): Rewrite.
402 * elf.c (assign_section_numbers): Simplify list traversal now that
403 bfd_section_list_remove doesn't destroy removed section next ptr.
404 * sunos.c (sunos_add_dynamic_symbols): Likewise.
405 * elfxx-ia64.c (elfNN_ia64_object_p): Use bfd_section_list_prepend.
406 * xcofflink.c (_bfd_xcoff_bfd_final_link): Simplify list traversal.
407 * bfd-in2.h: Regenerate.
409 2005-05-02 H.J. Lu <hongjiu.lu@intel.com>
411 * bfd.c (bfd): Remove section_tail and add section_last.
412 (bfd_preserve): Likewise.
413 (bfd_preserve_save): Likewise.
414 (bfd_preserve_restore): Likewise.
415 * opncls.c (_bfd_new_bfd): Likewise.
417 * coffcode.h (coff_compute_section_file_positions): Updated.
418 (coff_compute_section_file_positions): Likewise.
419 * elf.c (assign_section_numbers): Likewise.
420 * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise.
421 * elf64-mmix.c (mmix_elf_final_link): Likewise.
422 * elfxx-ia64.c (elfNN_ia64_object_p): Likewise.
423 * elfxx-mips.c (_bfd_mips_elf_link_hash_table_create): Likewise.
424 * sunos.c (sunos_add_dynamic_symbols): Likewise.
425 * xcofflink.c (_bfd_xcoff_bfd_final_link): Likewise.
427 * ecoff.c (bfd_debug_section): Initialize prev.
429 * section.c (bfd_section): Add prev.
430 (bfd_section_list_remove): Updated.
431 (bfd_section_list_append): New.
432 (bfd_section_list_insert_after): New.
433 (bfd_section_list_insert_before): New.
434 (bfd_section_list_insert): Removed.
435 (bfd_section_removed_from_list): Updated.
436 (STD_SECTION): Initialize prev.
437 (bfd_section_init): Updated.
438 (bfd_section_list_clear): Updated.
440 * bfd-in2.h: Regenerated.
442 2005-05-02 H.J. Lu <hongjiu.lu@intel.com>
444 * elf.c (_bfd_elf_new_section_hook): Don't call
445 _bfd_elf_get_sec_type_attr on sections from input files.
447 2005-05-02 H.J. Lu <hongjiu.lu@intel.com>
449 * merge.c (sec_merge_init): Call bfd_hash_table_init_n with
450 hash table size 16699 instead of bfd_hash_table_init.
452 2005-05-01 Paul Brook <paul@codesourcery.com>
454 * elflink.c (_bfd_elf_merge_symbol): Skip weak definitions if a strong
455 definition has already been seen.
457 2005-05-01 Paul Brook <paul@codesourcery.com>
459 * elf32-arm.c (bfd_elf32_arm_process_before_allocation): Treat
460 R_ARM_PLT32 the same as R_ARM_PC24.
461 (arm_add_to_rel): Ditto.
463 2005-04-29 Ralf Corsepius <ralf.corsepius@rtems.org>
465 * config.bfd: Add h8300*-*-rtemscoff.
466 Switch h8300*-*-rtems* to elf.
468 2005-04-28 Paul Brook <paul@codesourcery.com>
470 Merge changes only applied to Makefile.in.
471 * Makefile.am (BFD32_BACKENDS): Add elfxx-sparc.lo
472 (BFD32_BACKENDS_CFILES): Add elfxx-sparc.c
473 (elfxx-sparc.lo): New rule.
474 (elf32-sparc.lo): Add elfxx-sparc.h dependency.
475 (elf64-sparc.lo): Likewise.
477 2005-04-28 Julian Brown <julian@codesourcery.com>
479 * elflink.c (_bfd_elf_provide_symbol): Provide symbol for weak
482 2005-04-27 H.J. Lu <hongjiu.lu@intel.com>
484 * elf-bfd.h (bfd_elf_sym_name): Also take "asection *".
486 * elf.c (bfd_elf_sym_name): Updated.
487 (group_signature): Likewise.
488 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
489 * elf64-ppc.c (ppc64_elf_edit_opd): Likewise.
490 (ppc64_elf_edit_toc): Likewise.
491 (ppc64_elf_relocate_section): Likewise.
492 * elfcode.h (elf_slurp_symbol_table): Likewise.
493 * elflink.c (elf_link_input_bfd): Likewise.
495 * elfxx-ia64.c (elfNN_ia64_relocate_section): Call
496 bfd_elf_sym_name to get local symbol name when reporting errors.
498 2005-04-27 Nick Clifton <nickc@redhat.com>
500 * elflink.c (elf_link_input_bfd): Handle the case where a badly
501 formatted input file results in a reloc which has no associated
504 2005-04-26 Jerome Guitton <guitton@gnat.com>
506 * bfd.m4 (BFD_NEED_DECLARATION): Restore.
508 2005-04-25 David S. Miller <davem@davemloft.net>
510 * elfxx-sparc.c (sparc_elf_append_rela_64): Add BFD64 protection.
511 (sparc_elf_r_info_64, _bfd_sparc_elf_finish_dynamic_symbol,
512 sparc64_finish_dyn, _bfd_sparc_elf_finish_dynamic_sections):
515 2005-04-25 H.J. Lu <hongjiu.lu@intel.com>
518 * elflink.c (elf_link_input_bfd): Make non-debugging reference
519 to discarded section an error.
521 2005-04-21 Jerome Guitton <guitton@gnat.com>
523 * configure.in: Replace BFD_NEED_DECLARATION checks by the
524 corresponding AC_CHECK_DECLS.
525 * sysdep.h: Replace NEED_DECLARATION_* checks by the corresponding
527 * bfd.m4 (BFD_NEED_DECLARATION): Remove, obsolete.
528 * configure: Regenerate.
531 2005-04-21 Andreas Schwab <schwab@suse.de>
533 * elfxx-sparc.h (struct _bfd_sparc_elf_link_hash_table): Remove
534 unsigned from type of dynamic_interpreter.
535 * elfxx-sparc.c (_bfd_sparc_elf_link_hash_table_create): Remove
538 * elf.c (assign_section_numbers): Fix comment.
540 2005-04-21 Jerome Guitton <guitton@gnat.com>
542 * som.c (som_bfd_print_private_bfd_data): Add explicit cast to long
543 for struct som_exec_auxhdr fields.
545 2005-04-21 Nick Clifton <nickc@redhat.com>
547 * aout-adobe.c: Convert to ISO C and fix formatting.
548 * aout-arm.c: Convert to ISO C and fix formatting.
549 * aout-cris.c: Convert to ISO C and fix formatting.
550 * aout-ns32k.c: Convert to ISO C and fix formatting.
551 * aout-tic30.c: Convert to ISO C and fix formatting.
552 * coffcode.h: Convert to ISO C and fix formatting.
553 * coffswap.h: Convert to ISO C and fix formatting.
554 * i386aout.c: Convert to ISO C and fix formatting.
555 * libaout.h: Convert to ISO C and fix formatting.
556 * libcoff-in.h: Convert to ISO C and fix formatting.
557 * libcoff.h: Convert to ISO C and fix formatting.
558 * libecoff.h: Convert to ISO C and fix formatting.
559 * libnlm.h: Convert to ISO C and fix formatting.
560 * libpei.h: Convert to ISO C and fix formatting.
561 * libxcoff.h: Convert to ISO C and fix formatting.
562 * nlm-target.h: Convert to ISO C and fix formatting.
563 * nlm.c: Convert to ISO C and fix formatting.
564 * nlm32-alpha.c: Convert to ISO C and fix formatting.
565 * nlm32-i386.c: Convert to ISO C and fix formatting.
566 * nlm32-ppc.c: Convert to ISO C and fix formatting.
567 * nlm32-sparc.c: Convert to ISO C and fix formatting.
568 * nlmcode.h: Convert to ISO C and fix formatting.
569 * nlmswap.h: Convert to ISO C and fix formatting.
570 * pe-mips.c: Convert to ISO C and fix formatting.
571 * peXXigen.c: Convert to ISO C and fix formatting.
572 * peicode.h: Convert to ISO C and fix formatting.
573 * vms-gsd.c: Convert to ISO C and fix formatting.
574 * vms-hdr.c: Convert to ISO C and fix formatting.
575 * vms-misc.c: Convert to ISO C and fix formatting.
576 * vms-tir.c: Convert to ISO C and fix formatting.
577 * vms.c: Convert to ISO C and fix formatting.
578 * vms.h: Convert to ISO C and fix formatting.
580 * coffgen.c (coff_print_symbol): Restore correct formatting of
583 2005-04-20 David S. Miller <davem@davemloft.net>
585 * elfxx-sparc.c (sparc_elf_r_symndx_64): Fix compiler warning.
586 (_bfd_sparc_elf_link_hash_table_create): Likewise.
587 (allocate_dynrelocs): Likewise.
589 2005-04-20 Jerome Guitton <guitton@gnat.com>
591 * configure.in: Fix the check for basename declaration. Add check
592 for declarations of ftello, ftello64, fseeko, fseeko64.
593 * configure: Regenerate.
595 * sysdep.h: If needed, declare ftello, ftello64, fseeko, fseeko64.
597 2005-04-19 David S. Miller <davem@davemloft.net>
599 * elfxx-sparc.c: New file.
600 * elfxx-sparc.h: New file.
601 * Makefile.in (BFD32_BACKENDS): Add elfxx-sparc.lo
602 (BFD32_BACKENDS_CFILES): Add elfxx-sparc.c
603 (elfxx-sparc.lo): New rule.
604 (elf32-sparc.lo): Add elfxx-sparc.h dependency.
605 (elf64-sparc.lo): Likewise.
606 * configure.in (bfd_elf32_sparc_vec): Add elfxx-sparc.lo
607 (bfd_elf64_sparc_vec): Likewise.
608 * configure: Regenerate.
609 * elf32-sparc.c: Remove common code now in elfxx-sparc.c
610 * elf64-sparc.c: Likewise, also use elf64_sparc_*() naming
611 which is more consistent with elf32-sparc.c
613 2005-04-19 Daniel Jacobowitz <dan@codesourcery.com>
615 * elfxx-mips.c (struct mips_elf_link_hash_entry): Update comment.
616 (mips_elf_create_local_got_entry): Check h->root.forced_local.
618 2005-04-19 Alan Modra <amodra@bigpond.net.au>
620 * elf32-ppc.c (ppc_elf_check_relocs): Don't bother with
621 dynamic relocs in non-SEC_ALLOC sections.
622 (ppc_elf_gc_sweep_hook): Likewise.
623 (ppc_elf_relax_section): Likewise.
624 (ppc_elf_relocate_section): Likewise.
626 2005-04-18 Nick Clifton <nickc@redhat.com>
628 * aix5ppc-core.c (xcoff64_core_p): Fix compile time warning
629 assigning a value to return_value.
631 2005-04-17 H.J. Lu <hongjiu.lu@intel.com>
634 * elf.c (_bfd_elf_copy_private_section_data): Don't copy linker
637 2005-04-17 H.J. Lu <hongjiu.lu@intel.com>
640 * elf.c (setup_group): Properly handle zero group count.
642 2005-04-17 Mark Kettenis <kettenis@gnu.org>
644 * som.c (hppa_som_reloc, som_mkobject, som_is_space)
645 (som_is_subspace, compare_subspaces, som_compute_checksum)
646 (som_build_and_write_symbol_table, som_slurp_symbol_table): New
648 (hppa_som_reloc, compare_syms, compare_subspaces)
649 (som_print_symbol, som_get_section_contents)
650 (som_set_section_contents): Remove space after 'void *'.
651 (som_bfd_print_private_bfd_data): Use %lx to print longs.
652 (som_bfd_merge_private_bfd_data)
653 (som_bfd_copy_private_header_data, som_bfd_set_private_flags): New
656 2004-04-15 Julian Brown <julian@codesourcery.com>
658 * bfd-in.h (bfd_elf32_arm_set_target_relocs): Update prototype.
659 * bfd-in2.h: Regenerate.
660 * elf32-arm.c (elf32_arm_link_hash_table): New field, 'use_blx'.
661 (elf32_arm_link_hash_table_create): Initialise fix_v4bx, use_blx.
662 (bfd_elf32_arm_set_target_relocs): Handle use_blx.
663 (elf32_arm_final_link_relocate): Use Thumb BLX for R_ARM_THM_PC22
664 relocations if requested to.
665 (allocate_dynrelocs): Don't count size of omitted Thumb stubs based on
666 use_blx rather than symbian_p.
667 (elf32_arm_finish_dynamic_symbol): Don't output Thumb PLT stubs if
668 use_blx is in effect.
669 (elf32_arm_symbian_link_hash_table_create): Enable use_blx by default
672 2005-04-15 Nick Clifton <nickc@redhat.com>
674 * coffgen.c (coff_print_symbol): Use fprintf_vma to print vma
677 2005-04-15 Alan Modra <amodra@bigpond.net.au>
680 * elflink.c (elf_smash_syms): Clear undef.next if it's not being
681 used as a list pointer.
683 2005-04-14 Alan Modra <amodra@bigpond.net.au>
685 * Makefile.am (NO_WERROR): Define.
686 * warning.m4: New file
687 * acinclude.m4: Include warning.m4.
688 * configure.in: Invoke AM_BINUTILS_WARNINGS.
689 * Makefile.in: Regenerate.
690 * configure: Regenerate.
692 2005-04-14 Alan Modra <amodra@bigpond.net.au>
694 * merge.c (sec_merge_emit): Tidy. Check for bfd_zmalloc errors.
695 Write trailing padding.
697 * merge.c (merge_strings): Round up section size for alignment.
699 2005-04-14 David S. Miller <davem@davemloft.net>
701 Add TLS support for 64-bit Sparc ELF.
702 * elf64-sparc.c (sparc64_elf_dyn_relocs,
703 sparc64_elf_link_hash_entry, sparc64_elf_obj_tdata): New structs.
704 (GOT_UNKNOWN, GOT_NORMAL, GOT_TLD_GD, GOT_TLD_IE,
705 sparc64_elf_hash_entry, sparc64_elf_tdata,
706 sparc64_elf_local_got_tls_type): New defines.
707 (sparc64_elf_mkobject): New function.
708 (sparc64_elf_link_hash_table): Add members for dynamic linker
709 sections PLT, RELPLT, DYNBSS, and RELBSS. Add tls_ldm_got
710 uion to track TLS GOT references. Add sym_sec to cache
711 mappings from local sym to section.
712 (link_hash_newfunc): New function.
713 (sparc64_elf_bfd_link_hash_table_create): Rename to
714 sparc64_elf_link_hash_table_create for consistency.
715 Pass link_hash_newfunc to _bfd_elf_link_hash_table_init.
716 (sparc64_elf_create_dynamic_sections): Initialize new section
717 members of sparc64_elf_link_hash_table. Only init srelbss
719 (sparc64_elf_copy_indirect_symbol, sparc64_elf_tls_transition):
722 (sparc64_elf_build_plt, sparc64_elf_plt_entry_offset,
723 sparc64_elf_plt_ptr_offset): Delete.
724 (sparc64_plt_entry_build): New function to build PLT entries
725 gradually instread of all at once at the end of linking.
726 (sparc64_elf_check_relocs): Delete dynobj, sgot, and srelgot
727 local vars. Get them from sparc64_elf_hash_table instead.
728 Check early on if r_symndx is in bounds. Handle TLS transitions.
729 Account for TLS GOT references and DF_STATIC_TLS, as needed.
730 For TLS relocs, record the tls_type in either
731 sparc64_elf_local_got_tls_type or sparc64_elf_hash_entry as
732 appropriate. For R_SPARC_TLS_{GD,LDM}_CALL, emit a reference
733 to the __tls_get_addr symbol. For PLT relocs, track references
734 via h->plt.refcount. When R_SPARC_{PC10,PC22,PC_HH22,PC_HM10,
735 PC_LM22} and h not-NULL, set h->non_got_ref. For global data
736 symbol references, count the number of relocations needed for
737 that symbol. For default switch case, don't error, this lets
738 the TLS relocs not explicitly handled by this function get
740 (sparc64_elf_gc_mark_hook, sparc64_gc_sweep_hook): New functions.
741 (sparc64_elf_adjust_dynamic_symbol): Remove dynobj local var, get
742 it from sparc64_elf_hash_table. Store the real PLT offset
743 in h->plt.offset, and build PLT entries one at a time. Also
744 get .dynbss section pointer from htab.
745 (allocate_dynrelocs, readonly_dynrelocs,
746 sparc64_omit_section_dynsym): New functions.
747 (sparc64_elf_omit_section_dynsym): Use these new functions as
749 (dtpoff_base, tpoff): New functions.
750 (sparc64_elf_relocate_section): Kill dynobj, sgot, and splt
751 locals, get them from sparc64_elf_hash_table. Handle TLS
752 relocations and refcounting in main relocation loop.
753 (sparc64_elf_finish_dynamic_symbol): Use
754 sparc64_elf_link_hash_table. Build PLT entries as we see
755 them. Handle TLS GOT relocations.
756 (sparc64_elf_finish_dynamic_sections): Get sgot and dynobj
757 from sparc64_elf_hash_table. Initialize only PLT header
758 not all entries since we not build PLT entries one by one.
759 (elf_backend_copy_indirect_symbol, bfd_elf64_mkobject,
760 elf_backend_gc_mark_hook, elf_backend_gc_sweep_hook,
761 elf_backend_can_gc_sections, elf_backend_can_refcount): Define.
763 2005-04-13 Daniel Jacobowitz <dan@codesourcery.com>
765 * elflink.c (elf_link_input_bfd): Update check for removed
768 2005-04-12 Alan Modra <amodra@bigpond.net.au>
770 * Makefile.am: Run "make dep-am".
771 * Makefile.in: Regenerate.
772 * aclocal.m4: Regenerate.
773 * libcoff.h: Regenerate.
775 2005-04-11 H.J. Lu <hongjiu.lu@intel.com>
777 * linker.c (_bfd_generic_link_output_symbols): Also check if
778 the output section of an input section has been removed from
781 * section.c (bfd_section_list_remove): Clear the next field
782 of the removed section.
783 (bfd_section_removed_from_list): New.
784 * bfd-in2.h: Regenerated.
786 2005-04-11 David S. Miller <davem@davemloft.net>
788 * elf32-sparc.c (elf32_sparc_relocate_section,
789 R_SPARC_TLS_LDO_{HIX22,LOX10}): When not shared, transition to
790 R_SPARC_TLS_LE_{HIX22,LOX10}.
791 (elf32_sparc_relocate_section, R_SPARC_TLS_{LDO,LE}_HIX22): Only
792 xor relocation with 0xffffffff if R_SPARC_TLS_LE_HIX22.
793 (elf32_sparc_relocate_section, R_SPARC_TLS_{LDO,LE}_LOX10): Only
794 or 0x1c00 into relocation if R_SPARC_TLS_LE_HIX22.
796 2005-04-11 H.J. Lu <hongjiu.lu@intel.com>
798 * coffcode.h (STRING_SIZE_SIZE): Updated to match libcoff-in.h.
800 2005-04-11 Nick Clifton <nickc@redhat.com>
802 * aout-target.h: Convert to ISO C.
803 * aoutf1.h: Convert to ISO C.
804 * aoutx.h: Convert to ISO C.
805 * bout.c: Convert to ISO C.
806 * dwarf1.c: Convert to ISO C.
807 * ecoffswap.h: Convert to ISO C.
808 * freebsd.h: Convert to ISO C.
809 * genlink.h: Convert to ISO C.
810 * ieee.c: Convert to ISO C.
811 * ihex.c: Convert to ISO C.
812 * libcoff-in.h: Convert to ISO C.
813 * mach-o.c: Convert to ISO C.
814 * mach-o.h: Convert to ISO C.
815 * netbsd.h: Convert to ISO C.
816 * ns32k.h: Convert to ISO C.
817 * ns32knetbsd.c: Convert to ISO C.
818 * oasys.c: Convert to ISO C.
819 * pdp11.c: Convert to ISO C.
820 * pef-traceback.h: Convert to ISO C.
821 * pef.c: Convert to ISO C.
822 * pef.h: Convert to ISO C.
823 * riscix.c: Convert to ISO C.
824 * som.c: Convert to ISO C.
825 * som.h: Convert to ISO C.
826 * srec.c: Convert to ISO C.
827 * stabs.c: Convert to ISO C.
828 * sunos.c: Convert to ISO C.
829 * tekhex.c: Convert to ISO C.
830 * versados.c: Convert to ISO C.
831 * version.h: Convert to ISO C.
832 * xcoff-target.h: Convert to ISO C.
833 * xcofflink.c: Convert to ISO C.
834 * xsym.c: Convert to ISO C.
835 * xsym.h: Convert to ISO C.
837 2005-04-08 Paul Brook <paul@codesourcery.com>
839 * elf32-arm.c (ARM2THUMB_GLUE_SIZE): Rename...
840 (ARM2THUMB_STATIC_GLUE_SIZE): ... to this.
841 (ARM2THUMB_PIC_GLUE_SIZE): Define.
842 (a2t1p_ldr_insn, a2t2p_add_pc_insn, a2t3p_bx_r12_insn): Add.
843 (elf32_arm_to_thumb_stub): Create PIC stubs.
844 (record_arm_to_thumb_glue): Use different stub size for relocatable
847 2005-04-05 Alan Modra <amodra@bigpond.net.au>
849 * elf64-ppc.c (dec_dynrel_count): New function split out from
850 ppc64_elf_edit_toc, with additional code from ppc64_elf_edit_opd.
851 (ppc64_elf_edit_toc, ppc64_elf_edit_opd): Use it.
852 (ppc64_elf_tls_optimize): Likewise.
854 2005-04-05 Mark Kettenis <kettenis@gnu.org>
856 * netbsd-core.c (SPARC_WCOOKIE_OFFSET): Renamed from
858 (SPARC64_WCOOKIE_OFFSET): New.
859 (netbsd_core_file_p): Provide .wcookie section for OpenBSD/sparc64.
861 2005-04-05 Nick Clifton <nickc@redhat.com>
863 * po/rw.po: New translation: Kinyarwanda
864 * configure.in (ALL_LINGUAS): Add rw
865 * configure: Regenerate.
867 2005-04-05 Richard Sandiford <rsandifo@redhat.com>
869 * elfxx-mips.c (MIPS_ELF_OPTIONS_SECTION_NAME_P): New macro.
870 (_bfd_mips_elf_section_from_shdr): Use it to check for recognized
871 SHT_MIPS_OPTIONS names. Allow all sections with unrecognised
873 (_bfd_mips_elf_fake_sections): Use MIPS_ELF_OPTIONS_SECTION_NAME_P
874 to check for SHT_MIPS_OPTIONS sections.
875 (_bfd_mips_elf_set_section_contents): Likewise.
877 2005-04-04 Eric Christopher <echristo@redhat.com>
879 * elfxx-mips.c (_bfd_elf_mips_get_relocated_section_contents):
880 Clean up gp handling code.
882 2005-04-04 H.J. Lu <hongjiu.lu@intel.com>
884 * elf.c (bfd_elf_set_group_contents): Ignore linker created
886 (assign_section_numbers): Accept link_info. Check SHT_GROUP
887 sections for relocatable files only. Remove the linker created
889 (_bfd_elf_compute_section_file_positions): Pass link_info to
890 assign_section_numbers.
892 * elfxx-ia64.c (elfNN_ia64_object_p): New.
893 (elf_backend_object_p): Defined.
895 2005-04-04 H.J. Lu <hongjiu.lu@intel.com>
897 * elf-bfd.h (elf_section_data): Use (sec) instead of sec.
899 2005-04-03 Fred Fish <fnf@specifixinc.com>
901 * dwarf2.c (struct dwarf2_debug): Add dwarf_ranges_buffer and
902 dwarf_ranges_size members.
903 (struct comp_unit): Add base_address member.
904 (struct funcinfo): Replace low/high members with an arange.
905 (arange_add): Replace incoming "unit" parameter with "abfd" and
906 "first_arange" pointers. Reorganize/rewrite function body.
907 (decode_line_info): Change arange_add call to pass bfd and arange
909 (lookup_address_in_line_info_table): Use arange list instead of
910 individual low/high members. Walk function's arange list to find
911 lowest PC in list, to test for overlapping functions.
912 (read_debug_ranges): New function, reads the debug_ranges section.
913 (lookup_address_in_function_table): Use arange list instead of
914 individual low/high members. Rewrite to find smallest range that
916 (read_rangelist): Read a given rangelist from debug_ranges.
917 (scan_unit_for_functions): Use arange list instead of individual
918 low/high members. Handle a DW_AT_ranges attribute.
919 (parse_comp_unit): Use arange list instead of individual low/high
920 members. Save comp unit base address. Handle a DW_AT_ranges
923 2005-04-01 H.J. Lu <hongjiu.lu@intel.com>
925 * elf.c (assign_section_numbers): Really use the kept section.
927 2005-03-31 H.J. Lu <hongjiu.lu@intel.com>
929 * elf-bfd.h (_bfd_elf_check_kept_section): New.
931 * elf.c (assign_section_numbers): When sh_link points to a
932 discarded section, call _bfd_elf_check_kept_section to see if
933 the kept section can be used. Otherwise reject sh_link
934 pointing to discarded section.
936 * elflink.c (_bfd_elf_check_kept_section): New.
937 (elf_link_input_bfd): Use it.
939 2005-04-01 Alan Modra <amodra@bigpond.net.au>
941 * elf64-ppc.c (ppc64_elf_edit_toc): Account for dynamic relocs
942 that we no longer need.
944 2005-04-01 Alan Modra <amodra@bigpond.net.au>
946 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Return -1 on errors
948 (ppc64_elf_check_relocs): Remove unnecessary SEC_ALLOC check.
950 2005-03-31 H.J. Lu <hongjiu.lu@intel.com>
952 * elf.c (assign_section_numbers): Fix a typo.
954 2005-03-31 H.J. Lu <hongjiu.lu@intel.com>
956 * elflink.c (elf_link_input_bfd): Remove the extra `\n' in
958 (_bfd_elf_section_already_linked): Likewise.
960 2005-03-31 Jerome Guitton <guitton@gnat.com>
962 * config.in: Regenerate.
964 2005-03-31 Jerome Guitton <guitton@gnat.com>
966 * config.in (HAVE_DECL_BASENAME): New configure macro.
967 * configure.in: Check for basename.
968 * configure: Regenerate.
970 2005-03-30 Julian Brown <julian@codesourcery.com>
972 * bfd-in.h (bfd_is_arm_mapping_symbol_name): Rename from
973 bfd_elf32_is_arm_mapping_symbol_name.
974 * bfd-in2.h: Regenerate.
975 * cpu-arm.c (bfd_is_arm_mapping_symbol_name): Rename from
976 bfd_elf32_is_arm_mapping_symbol_name.
977 * elf32-arm.c (elf32_arm_is_target_special_symbol): Rename
978 bfd_elf32_is_arm_mapping_symbol_name to bfd_is_arm_mapping_symbol_name.
979 (arm_elf_find_function): Likewise.
980 (elf32_arm_output_symbol_hook): Likewise.
982 2005-03-30 Julian Brown <julian@codesourcery.com>
984 * bfd-in.h (bfd_elf32_is_arm_mapping_symbol_name): Add prototype.
985 * bfd-in2.h: Regenerate.
986 * elf32-arm.c (elf32_arm_is_target_special_symbol): Rename call to
987 bfd_elf32_is_arm_mapping_symbol_name.
988 (elf32_arm_output_symbol_hook): Likewise.
989 (arm_elf_find_function): Likewise, and include STT_NOTYPE in test for
991 (is_arm_mapping_symbol_name): Function moved from here...
992 * cpu-arm.c (bfd_elf32_is_arm_mapping_symbol_name): ...to here, renamed
995 2005-03-29 Aaron W. LaFramboise <aaron98wiridge9@aaronwl.com>
997 * configure.in: Check for ffs decl and alphabetize.
998 * config.in: Regenerate.
999 * configure: Regenerate.
1000 * sysdep.h [NEED_DECLARATION_FFS] (ffs): Prototype and
1003 2005-03-29 Fred Fish <fnf@specifixinc.com>
1005 * dwarf2.c (struct comp_unit): Fix typo.
1006 (scan_unit_for_functions): Remove unused local variable "name"
1007 and dead code that set it.
1009 2005-03-29 Daniel Jacobowitz <dan@codesourcery.com>
1010 Phil Blundell <philb@gnu.org>
1012 * bfd-in2.h, libbfd.h: Regenerated.
1013 * reloc.c: Add ARM TLS relocations.
1014 * elf32-arm.c (elf32_arm_howto_table): Add dynamic TLS
1016 (elf32_arm_tls_gd32_howto, elf32_arm_tls_ldo32_howto)
1017 (elf32_arm_tls_ldm32_howto, elf32_arm_tls_le32_howto)
1018 (elf32_arm_tls_ie32_howto): New.
1019 (elf32_arm_howto_from_type): Support TLS relocations.
1020 (elf32_arm_reloc_map): Likewise.
1021 (elf32_arm_reloc_type_lookup): Likewise.
1023 (struct elf32_arm_obj_tdata): New.
1024 (elf32_arm_tdata, elf32_arm_local_got_tls_type): Define.
1025 (elf32_arm_mkobject): New function.
1026 (struct elf32_arm_relocs_copied): Add pc_count.
1027 (elf32_arm_hash_entry, GOT_UNKNOWN, GOT_NORMAL, GOT_TLS_GD)
1028 (GOT_TLS_IE): Define.
1029 (struct elf32_arm_link_hash_table): Add tls_ldm_got.
1030 (elf32_arm_link_hash_newfunc): Initialize tls_type.
1031 (elf32_arm_copy_indirect_symbol): Copy pc_count and tls_type.
1032 (elf32_arm_link_hash_table_create): Initialize tls_ldm_got.
1033 (dtpoff_base, tpoff): New functions.
1034 (elf32_arm_final_link_relocate): Handle TLS relocations.
1035 (IS_ARM_TLS_RELOC): Define.
1036 (elf32_arm_relocate_section): Warn about TLS mismatches.
1037 (elf32_arm_gc_sweep_hook): Handle TLS relocations and pc_count.
1038 (elf32_arm_check_relocs): Detect invalid symbol indexes. Handle
1039 TLS relocations and pc_count.
1040 (elf32_arm_adjust_dynamic_symbol): Check non_got_ref.
1041 (allocate_dynrelocs): Handle TLS. Bind REL32 relocs to local
1043 (elf32_arm_size_dynamic_sections): Handle TLS.
1044 (elf32_arm_finish_dynamic_symbol): Likewise.
1045 (bfd_elf32_mkobject): Define.
1047 2005-03-29 Daniel Jacobowitz <dan@codesourcery.com>
1049 * elf32-arm.c (elf32_arm_check_relocs): Increment count for all
1050 relocation types. Don't count relocations which will use a PLT.
1052 2005-03-29 Joel Brobecker <brobecker@gnat.com>
1054 * elf.c (elfcore_grok_nto_status): Print tid as long.
1055 (elfcore_grok_nto_regs): Likewise.
1057 2005-03-29 Joel Brobecker <brobecker@gnat.com>
1059 * irix-core.c: Remove some unnecessary prototypes.
1061 2005-03-28 Joel Brobecker <brobecker@adacore.com>
1063 * irix-core.c: Convert to ISO C.
1065 2005-03-28 Joel Brobecker <brobecker@adacore.com>
1067 * irix-core.c (do_sections): Replace + by | in expression.
1068 (irix_core_core_file_matches_executable_p): Add ATTRIBUTE_UNUSED
1069 to unused parameters to avoid a compiler warning.
1071 2005-03-28 Mark Kettenis <kettenis@gnu.org>
1073 * netbsd-core.c: Convert to ISO C. Fix formatting.
1075 2005-03-24 Eric Christopher <echristo@redhat.com>
1077 * elfxx-mips.c: Revert previous patch.
1079 2005-03-24 Nick Clifton <nickc@redhat.com>
1081 * targets.c (_bfd_target_vector): Only include the
1082 bfd_elf32_ia64_hpux_big_vec vector when building a 64-bit BFD with
1083 all targets enabled.
1085 2005-03-24 James E Wilson <wilson@specifixinc.com>
1087 * Makefile.am (BFD32_BACKENDS): Delete elf32-ia64.lo.
1088 (BFD64_BACKENDS): Add elf32-ia64.lo.
1089 * Makefile.in: Regenerate.
1091 2005-03-23 Eric Christopher <echristo@redhat.com>
1093 * elfxx-mips.c (MIPS_ELF_READONLY_SECTION): New.
1094 (mips_elf_calculate_relocation): Use. Define DF_TEXTREL
1095 after emitting relocation.
1096 (_bfd_mips_elf_adjust_dynamic_symbol): Ditto.
1097 (_bfd_mips_elf_check_relocs): Remove code to set DF_TEXTREL
1100 2005-03-23 Mike Frysinger <vapier@gentoo.org>
1101 Nick Clifton <nickc@redhat.com>
1103 * config.bfd: Accept any C library to accompany a GNU Linux
1104 implementation, not just the GNU C library.
1105 * configure.in: Likewise.
1106 * configure: Regenerate.
1108 2005-03-22 H.J. Lu <hongjiu.lu@intel.com>
1110 * bfd-in.h (_bfd_elf_provide_symbol): New.
1111 * bfd-in2.h: Regenerated.
1113 * elf32-ppc.c (set_linker_sym): Moved to elflink.c.
1114 (ppc_elf_set_sdata_syms): Call _bfd_elf_provide_symbol instead
1117 * elflink.c (_bfd_elf_provide_symbol): New. Moved and renamed
1120 2005-03-22 Hans-Peter Nilsson <hp@axis.com>
1122 * hash.c (strtab_hash_newfunc): Fix typo in allocated size.
1124 2005-03-22 Bob Wilson <bob.wilson@acm.org>
1126 * xtensa-isa.c (xtensa_opcode_lookup, xtensa_state_lookup,
1127 xtensa_sysreg_lookup_name, xtensa_interface_lookup,
1128 xtensa_funcUnit_lookup): Skip bsearch call if count is zero.
1129 (xtensa_opcode_decode): Rearrange code.
1131 2005-03-22 Nick Clifton <nickc@redhat.com>
1133 * binary.c: Convert to ISO C90 formatting.
1134 * coff-arm.c: Convert to ISO C90 formatting.
1135 * coffgen.c: Convert to ISO C90 formatting.
1136 * elf32-gen.c: Convert to ISO C90 formatting.
1137 * elf64-gen.c: Convert to ISO C90 formatting.
1138 * hash.c: Convert to ISO C90 formatting.
1139 * ieee.c: Convert to ISO C90 formatting.
1141 2005-03-22 Daniel Jacobowitz <dan@codesourcery.com>
1143 * elf32-arm.c (elf32_arm_final_link_relocate): Don't fail for
1144 unresolved symbols in R_ARM_NONE relocations.
1146 2005-03-22 Daniel Jacobowitz <dan@codesourcery.com>
1148 * elf32-arm.c (elf32_arm_final_link_relocate): Add
1149 UNRESOLVED_RELOC_P argument. Set it appropriately.
1150 (elf32_arm_relocate_section): Update call to
1151 elf32_arm_final_link_relocate. Don't clobber RELOCATION; use
1152 unresolved_reloc instead.
1154 2005-03-23 Alan Modra <amodra@bigpond.net.au>
1156 * elflink.c (elf_link_add_object_symbols): Set SEC_EXCLUDE on
1157 .gnu.warning.* sections.
1159 2005-03-22 Alan Modra <amodra@bigpond.net.au>
1161 * elf32-ppc.c (elf_linker_section_pointers_t): Remove
1163 (ppc_elf_create_linker_section): Don't try to reuse existing section.
1164 (elf_create_pointer_linker_section): Delete info parm. Don't make
1165 h dynamic. Don't set written_address_p.
1166 (ppc_elf_check_relocs): Adjust ppc_elf_create_linker_section calls.
1167 (bfd_put_ptr): Delete.
1168 (elf_finish_pointer_linker_section): Remove output_bfd and info parms.
1169 Always write section contents. Assert global sym is def_regular.
1170 Use offset bottom bit as a written flag.
1171 (ppc_elf_relocate_section): Adjust elf_finish_pointer_linker_section
1174 2005-03-22 Alan Modra <amodra@bigpond.net.au>
1176 * elf32-ppc.c (ppc_elf_set_sdata_syms): New function, extracted from..
1177 (ppc_elf_set_sdata_syms): ..here. Expand comment. Set .sbss start
1180 2005-03-21 Nick Clifton <nickc@redhat.com>
1182 * coff-arm.c (coff_link_hash_entry): Only define for non WINCE
1184 (t2a1_bx_pc_insn): Likewise.
1185 (t2a2_noop_insn): Likewise.
1186 (t2a3_b_insn): Likewise.
1187 (t2a1_push_insn): Likewise.
1188 (t2a2_ldr_insn): Likewise.
1189 (t2a3_mov_insn): Likewise.
1190 (t2a4_bx_insn): Likewise.
1191 (t2a5_pop_insn): Likewise.
1192 (t2a6_bx_insn): Likewise.
1193 (coff_arm_relocate_section): Only declare the high_address
1194 variable for non WINCE targets.
1196 2005-03-22 Alan Modra <amodra@bigpond.net.au>
1198 * elf32-ppc.c (ppc_elf_add_symbol_hook): Make htab->sbss
1199 SEC_LINKER_CREATED. Attach to dynobj.
1200 (ppc_elf_size_dynamic_sections): Strip htab->sbss if zero size.
1202 2005-03-21 Alan Modra <amodra@bigpond.net.au>
1204 * elf32-ppc.c (struct elf_linker_section): Remove sym_hash and
1205 sym_offset. Add name, bss_name, sym_name, sym_val.
1206 (struct ppc_elf_link_hash_table): Remove sdata and sdata2 pointers.
1207 Add sdata array of elf_linker_section_t.
1208 (ppc_elf_link_hash_table_create): Set name, sym_name, and bss_name.
1209 (enum elf_linker_section_enum): Delete.
1210 (ppc_elf_create_linker_section): Rewrite. Don't create syms here.
1211 (ppc_elf_check_relocs): Delay ppc_elf_create_linker_section until
1212 the special sections are needed. Adjust htab->sdata refs.
1213 Ensure dynobj is set in sreloc code.
1214 (ppc_elf_size_dynamic_sections): Strip sdata sections.
1215 (ppc_elf_set_sdata_syms): New function.
1216 (elf_finish_pointer_linker_section): Use 0x8000 for sym_offset.
1217 (ppc_elf_relocate_section): Adjust references to htab->sdata. Use
1218 sym_val instead of sym_hash.
1219 * elf32-ppc.h (ppc_elf_set_sdata_syms): Declare.
1221 2005-03-21 Alan Modra <amodra@bigpond.net.au>
1223 * elf32-ppc.c (is_ppc_elf_target): Move to linker part of file.
1224 (ppc_elf_merge_private_bfd_data): Likewise.
1226 2005-03-21 Alan Modra <amodra@bigpond.net.au>
1228 * elf32-ppc.c (struct elf_linker_section): Remove rel_section.
1229 (ppc_elf_create_linker_section): Don't create rel_section.
1230 (elf_create_pointer_linker_section): Don't size relocs.
1231 (elf_finish_pointer_linker_section): Remove relative_reloc parm.
1232 Don't generate relocs.
1233 (ppc_elf_relocate_section): Adjust calls to
1234 elf_finish_pointer_linker_section.
1236 2005-03-21 Alan Modra <amodra@bigpond.net.au>
1238 * elf32-ppc.c (is_ppc_elf_target): New function.
1239 (ppc_elf_merge_private_bfd_data): Use it rather than just testing
1240 for bfd_target_elf_flavour. Do this test before endian check.
1241 (ppc_elf_add_symbol_hook): Use is_pcc_elf_target.
1242 (ppc_elf_size_dynamic_sections): Likewise.
1244 2005-03-20 H.J. Lu <hongjiu.lu@intel.com>
1246 * elf-bfd.h (elf_backend_data): Add int to
1247 elf_backend_section_from_shdr.
1248 (bfd_elf_section_data): Update comment for this_idx.
1249 (_bfd_elf_make_section_from_shdr): Add int.
1250 * elfxx-mips.h (_bfd_mips_elf_section_from_shdr): Likewise.
1252 * elf.c (_bfd_elf_make_section_from_shdr): Take section index
1253 and use it to set this_idx in bfd_elf_section_data.
1254 (bfd_section_from_shdr): Pass shindex to
1255 _bfd_elf_make_section_from_shdr.
1256 (_bfd_elf_section_from_bfd_section): Use this_idx in
1257 bfd_elf_section_data to find section index.
1259 * elf32-arm.c (elf32_arm_section_from_shdr): Take section
1260 index and pass it to _bfd_elf_make_section_from_shdr.
1261 * elf32-i370.c(i370_elf_section_from_shdr): Likewise.
1262 * elf32-ppc.c (ppc_elf_section_from_shdr): Likewise.
1263 * elf32-sh64.c (sh64_backend_section_from_shdr): Likewise.
1264 * elf32-v850.c (v850_elf_section_from_shdr): Likewise.
1265 * elf64-alpha.c (elf64_alpha_section_from_shdr): Likewise.
1266 * elf64-hppa.c (elf64_hppa_section_from_shdr): Likewise.
1267 * elf64-x86-64.c (elf64_x86_64_section_from_shdr): Likewise.
1268 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Likewise.
1269 * elfxx-mips.c (_bfd_mips_elf_section_from_shdr): Likewise.
1271 2005-03-19 Danny Smith <dannysmith@users.sourceforge.net>
1272 Ross Ridge <rridge@csclub.uwaterloo.ca>
1274 * peicode.h (pe_ILF_build_a_bfd): Strip only one prefix
1275 character in IMPORT_NAME_UNDECORATE and IMPORT_NAME_NOPREFIX
1278 2005-03-18 H.J. Lu <hongjiu.lu@intel.com>
1280 * elflink.c (elf_mark_used_section): Remove check for special
1283 2005-03-18 Andreas Schwab <schwab@suse.de>
1285 * elfxx-ia64.c (elfNN_ia64_install_value): Change type of insn
1286 from bfd_vma to ia64_insn, remove broken cast.
1288 2005-03-18 C Jaiprakash <cjaiprakash@noida.hcltech.com>
1290 * elf32-m68k.c (elf_cfv4e_plt0_entry): plt entry for coldfire v4e.
1291 (elf_m68k_adjust_dynamic_symbol,elf_m68k_finish_dynamic_symbol,
1292 elf_m68k_finish_dynamic_sections): Use it.
1294 2005-03-17 Paul Brook <paul@codesourcery.com>
1295 Dan Jacobowitz <dan@codesourcery.com>
1296 Mark Mitchell <mark@codesourcery.com>
1298 * elf32-arm.c (elf32_arm_modify_segment_map): New function.
1299 (elf32_arm_additional_program_headers): Likewise.
1300 (elf_backend_modify_segment_map): Define.
1301 (elf_backend_additional_program_headers): Likewise.
1302 (elf32_arm_symbian_modify_segment_map): Use
1303 elf32_arm_modify_segment_map.
1305 2005-03-18 H.J. Lu <hongjiu.lu@intel.com>
1307 * elflink.c (elf_mark_used_section): Check bfd_is_const_section
1308 for special sections.
1310 2005-03-18 Alan Modra <amodra@bigpond.net.au>
1312 * elf-bfd.h (_bfd_elf_link_renumber_dynsyms): Delete.
1313 * elflink.c (_bfd_elf_link_renumber_dynsyms): Make static, add
1314 section_sym_count param, and return number of section symbols.
1315 (bfd_elf_size_dynamic_sections): Clear section symbol area of
1316 .dynsym contents. Don't bother calling swap_symbol_out on the
1317 first all-zero dynsym.
1318 (elf_mark_used_section): Formatting. Avoid twiddling flags in
1319 special sections like bfd_abs_section.
1320 (bfd_elf_gc_sections): Spelling fix.
1322 2005-03-16 Fred Fish <fnf@specifixinc.com>
1325 * dwarf2.c (read_indirect_string): Fix apparent typo, check
1326 dwarf_str_buffer allocation, not dwarf_abbrev_buffer.
1328 2005-03-16 H.J. Lu <hongjiu.lu@intel.com>
1330 * elflink.c (elf_mark_used_section): New.
1331 (bfd_elf_gc_sections): Call elf_gc_mark_section for
1332 non-relocatable link if we don't do GC.
1334 2005-03-16 Nick Clifton <nickc@redhat.com>
1335 Ben Elliston <bje@au.ibm.com>
1337 * configure.in (werror): New switch: Add -Werror to the
1338 compiler command line. Enabled by default. Disable via
1340 * configure: Regenerate.
1342 2005-03-16 Nick Clifton <nickc@redhat.com>
1344 * ecoff.c: Convert to ISO C90 formatting.
1346 2005-03-16 Alan Modra <amodra@bigpond.net.au>
1348 * elf32-ppc.c: Divide file into general and linker specific
1349 functions. Sort linker functions into roughly the order in which
1350 they are called by the ELF linker code.
1352 2005-03-16 Alan Modra <amodra@bigpond.net.au>
1354 * elf32-ppc.c (ppc_elf_create_linker_section): Set SEC_LINKER_CREATED
1355 on section. Correct comment, and add FIXME.
1356 (ppc_elf_additional_program_headers): Don't bump header count for
1357 interp. Test SEC_ALLOC, not SEC_LOAD, and don't test size.
1358 (ppc_elf_size_dynamic_sections): Don't strip sdata and sdata2, but
1359 do allocate memory if they need it.
1361 2005-03-15 Mikkel Krautz <krautz@gmail.com>
1363 * config.bfd (x86_64-elf): Add target.
1365 2005-03-15 Alan Modra <amodra@bigpond.net.au>
1367 * po/es.po: Commit new Spanish translation.
1369 2005-03-14 H.J. Lu <hongjiu.lu@intel.com>
1371 * elfxx-ia64.c (elfNN_ia64_relocate_section): Set symbo name
1372 for global symbol when reporting overflow.
1374 2005-03-11 Jakub Jelinek <jakub@redhat.com>
1376 * libbfd-in.h (_bfd_ar_spacepad): New prototype.
1377 * libbfd.h: Rebuilt.
1378 * archive.c (_bfd_ar_spacepad): New function.
1379 (_bfd_construct_extended_name_table, _bfd_write_archive_contents,
1380 bsd_write_armap, _bfd_archive_bsd_update_armap_timestamp,
1381 coff_write_armap): Use it.
1382 (bfd_ar_hdr_from_filesystem): Likewise. Fix HP-UX large
1384 * archive64.c (bfd_elf64_archive_write_armap): Use _bfd_ar_spacepad.
1386 2005-03-10 Mark Kettenis <kettenis@gnu.org>
1388 * archive.c (_bfd_look_for_bfd_in_cache): Move declaration of
1389 has_table to the start of the function.
1391 2005-03-10 Ben Elliston <bje@au.ibm.com>
1393 * archive.c: Include hashtab.h.
1394 (struct ar_cache): Rename `arelt' to `arbfd' and remove `next'.
1395 (_bfd_look_for_bfd_in_cache): Reimplement using htab_find.
1396 (hash_file_ptr): New function.
1397 (eq_file_ptr): Likewise.
1398 (_bfd_add_bfd_to_archive_cache): Reimplement using a hash table.
1399 * libbfd-in.h: Include hashtab.h.
1400 (struct artdata): Change `cache' member type to htab_t.
1401 * libbfd.h: Rebuild.
1403 2005-03-08 Daniel Jacobowitz <dan@codesourcery.com>
1405 * configure.in: Bump version to 2.16.90.
1406 * configure: Regenerated.
1408 2005-03-07 Jakub Jelinek <jakub@redhat.com>
1410 * opncls.c (opncls_bread, opncls_bclose): Fix if pread resp.
1411 close is a function like macro in system headers.
1413 2005-03-07 Alan Modra <amodra@bigpond.net.au>
1416 * elf32-hppa.c (elf32_hppa_create_dynamic_sections): Reinstate
1417 _GLOBAL_OFFSET_TABLE_ as a normal dynamic symbol.
1419 2005-03-06 Alan Modra <amodra@bigpond.net.au>
1421 * elf.c (elfcore_grok_win32pstatus): Warning fixes.
1423 2005-03-05 Alan Modra <amodra@bigpond.net.au>
1425 * po/bfd.pot: Regenerate.
1427 2005-03-05 Alan Modra <amodra@bigpond.net.au>
1429 * elf64-ppc.c (update_plt_info): Don't mark new ABI call syms
1431 (func_desc_adjust): Force dot-syms local in executables as well
1434 2005-03-04 David Daney <ddaney@avtrex.com>
1436 * elfxx-mips.c (mips_elf_calculate_relocation): Handle special
1437 '__gnu_local_gp' symbol used by gas -mno-shared.
1439 2005-03-03 H.J. Lu <hongjiu.lu@intel.com>
1441 * elf-bfd.h (elf_backend_data): Add "const char *" to
1442 elf_backend_section_from_phdr.
1444 * elf.c (bfd_section_from_phdr): Pass "proc" to the
1445 elf_backend_section_from_phdr hook.
1447 2005-03-02 Daniel Jacobowitz <dan@codesourcery.com>
1448 Joseph Myers <joseph@codesourcery.com>
1450 * elfxx-mips.c (struct mips_got_entry): Add tls_type.
1451 (struct mips_got_info): Add tls_gotno, tls_assigned_gotno,
1453 (struct mips_elf_got_per_bfd_arg): Add global_count.
1454 (struct mips_elf_count_tls_arg): New.
1455 (struct mips_elf_hash_sort_data): Update comment for min_got_dynindx.
1456 (struct mips_elf_link_hash_entry): Add tls_type and tls_got_offset.
1457 (GOT_NORMAL, GOT_TLS_GD, GOT_TLS_LDM, GOT_TLS_IE)
1458 (GOT_TLS_OFFSET_DONE, GOT_TLS_DONE): Define.
1459 (TLS_RELOC_P): Define.
1460 (TP_OFFSET, DTP_OFFSET): Define.
1461 (dtprel_base, tprel_base): New functions.
1462 (mips_elf_link_hash_newfunc): Initialize tls_type.
1463 (mips_elf_got_entry_hash, mips_elf_got_entry_eq)
1464 (mips_elf_multi_got_entry_hash, mips_elf_multi_got_entry_eq): Handle
1466 (mips_tls_got_relocs, mips_elf_count_local_tls_relocs)
1467 (mips_elf_count_global_tls_entries, mips_elf_count_global_tls_relocs)
1468 (mips_elf_output_dynamic_relocation, mips_elf_initialize_tls_slots)
1469 (mips_tls_got_index): New functions.
1470 (mips_elf_local_got_index): Add new R_SYMNDX, H, and R_TYPE
1471 arguments. Pass them to mips_elf_create_local_got_entry. Use
1473 (mips_elf_global_got_index): Add new R_TYPE and INFO arguments.
1475 (mips_elf_got_page, mips_elf_got16_entry): Update calls to
1476 mips_elf_create_local_got_entry.
1477 (mips_elf_create_local_got_entry): Add new R_SYMNDX, H, and R_TYPE
1478 arguments. Handle TLS entries.
1479 (mips_elf_sort_hash_table_f): Add non-TLS assertions.
1480 (mips_elf_record_local_got_symbol): Add new TLS_FLAG argument. Handle
1482 (mips_elf_record_global_got_symbol): Likewise.
1483 (mips_elf_make_got_per_bfd): Initialize new mips_got_info members.
1485 (mips_elf_merge_gots): Handle TLS entries when merging.
1486 (mips_elf_initialize_tls_index): New function.
1487 (mips_elf_set_global_got_offset): Handle TLS entries.
1488 (mips_elf_adjust_gp): Handle TLS.
1489 (mips_elf_multi_got): Remove redundant call to
1490 mips_elf_resolve_final_got_entries. Initialize global_count.
1491 Correct a comment. Initialize new TLS members of mips_got_info.
1492 Assign TLS GOT indexes for new GOTs.
1493 (mips_elf_create_got_section): Initialize new TLS members of
1495 (mips_elf_calculate_relocation): Handle TLS relocs.
1496 (_bfd_mips_elf_check_relocs): Likewise. Update calls to changed
1498 (_bfd_mips_elf_always_size_sections): Handle TLS.
1499 (_bfd_mips_elf_size_dynamic_sections): Likewise.
1500 (_bfd_mips_elf_finish_dynamic_symbol): Likewise. Update calls to
1502 (_bfd_mips_elf_copy_indirect_symbol): Copy tls_type.
1503 (_bfd_mips_elf_hide_symbol): Handle TLS.
1504 * elfn32-mips.c (elf_mips_howto_table_rel, elf_mips_howto_table_rela)
1505 (mips_reloc_map): Add TLS relocs.
1506 * elf32-mips.c (elf_mips_howto_table_rel, mips_reloc_map): Likewise.
1507 * elf64-mips.c (mips_elf64_howto_table_rel)
1508 (mips_elf64_howto_table_rela, mips_reloc_map): Likewise.
1509 * reloc.c: Define new MIPS TLS relocations.
1510 * libbfd.h, bfd-in2.h: Regenerated.
1512 2005-03-02 Jan Beulich <jbeulich@novell.com>
1514 * Makefile.am: Add dependency of cache.o on libiberty.h.
1515 * cache.c: Include libiberty.h.
1516 (bfd_open_file): Use unlink_if_ordinary instead of unlink.
1518 2005-03-01 Zack Weinberg <zack@codesourcery.com>
1520 * elf.c (bfd_section_from_shdr <default case>): Call
1521 elf_backend_section_from_shdr hook unconditionally, and return
1523 (bfd_section_from_phdr): Similarly, for elf_backend_section_from_phdr.
1524 * elfxx-target.h (elf_backend_section_from_shdr)
1525 (elf_backend_section_from_phdr): Default to
1526 _bfd_elf_make_section_from_shdr and _bfd_elf_make_section_from_phdr
1529 2005-03-01 Alan Modra <amodra@bigpond.net.au>
1531 * targets.h: Typo fix.
1532 * bfd-in2.h: Regenerate.
1534 * bout.c (b_out_write_object_contents): Don't use sizeof on host
1535 structs to size on-disk structures.
1536 (b_out_set_section_contents): Size the external struct, not the
1537 internal one for on-disk size.
1538 (b_out_sizeof_headers): Likewise.
1540 2005-03-01 Alan Modra <amodra@bigpond.net.au>
1542 * elf64-ppc.c (ppc64_elf_size_stubs): Override defined dot-sym
1543 entry points with the func descriptor as well as undefweak.
1545 2005-02-28 Ross Ridge <rridge@csclub.uwaterloo.ca>
1547 * peicode.h (pe_ILF_build_a_bfd): Do not assume that an @ will be
1548 present when IMPORT_NAME_UNDOECRATE is used.
1550 2005-02-28 H.J. Lu <hongjiu.lu@intel.com>
1553 * elf-bfd.h (_bfd_elf_merge_symbol): Add a pointer to unsigned
1556 * elf32-sh-symbian.c (sh_symbian_relocate_section): Pass NULL
1557 to _bfd_elf_merge_symbol.
1559 * elflink.c (_bfd_elf_merge_symbol): Use the pointer to
1560 unsigned int to return the alignment of the old common symbol
1561 in the dynamic object.
1562 (_bfd_elf_add_default_symbol): Pass NULL to
1563 _bfd_elf_merge_symbol.
1564 (elf_link_add_object_symbols): Pass &old_alignment to
1565 _bfd_elf_merge_symbol. Get the alignment of the new common
1566 symbol in the dynamic object.
1568 2005-02-24 Ben Elliston <bje@au.ibm.com>
1570 * coffcode.h (coff_sym_filepos): Remove GNU960 conditional code.
1571 * format.c (bfd_check_format_matches): Likewise.
1572 * archive.c (BFD_GNU960_ARMAG): Likewise.
1573 (bfd_generic_archive_p): Likewise.
1574 (_bfd_write_archive_contents): Likewise.
1576 2005-02-24 H.J. Lu <hongjiu.lu@intel.com>
1578 * configure.in: (AM_INIT_AUTOMAKE): Set version to 2.15.95.
1579 * configure: Regenerate.
1581 2005-02-24 Julian Brown <julian@sirius.codesourcery.com>
1583 * elflink.c (elf_link_add_object_symbols): Force symbols in discarded
1584 COMDAT group sections to have default visibility.
1586 2005-02-24 Alan Modra <amodra@bigpond.net.au>
1588 * coffcode.h (coff_print_aux): Warning fix.
1589 * elf-m10300.c (mn10300_elf_relax_section): Use section->id
1590 instead of section pointer to identify.
1591 * coff-h8300.c (h8300_reloc16_extra_cases): Likewise. Allocate
1592 the correct size buffer for local sym mangling too.
1593 (h8300_bfd_link_add_symbols): Likewise.
1594 * elf32-sh-symbian.c (sh_symbian_process_embedded_commands): Fix
1596 * elf32-sh64.c (shmedia_prepare_reloc): Use %B and %p in error message
1597 * elf32-xtensa.c (literal_value_hash): Warning fix.
1598 * versados.c (process_otr): Warning fix.
1599 (versados_canonicalize_reloc): Likewise.
1600 * vms-gsd.c (_bfd_vms_slurp_gsd): Warning fix.
1601 * vms.c (fill_section_ptr): Warning fix.
1603 2005-02-23 H.J. Lu <hongjiu.lu@intel.com>
1605 * coff-tic54x.c (SWAP_OUT_RELOC_EXTRA): Defined.
1606 * coff-tic80.c (SWAP_OUT_RELOC_EXTRA): Likewise.
1608 2005-02-23 Nick Clifton <nickc@redhat.com>
1610 * elfxx-mips.c (mips_elf_create_dynamic_relocation): Initialise
1611 the relvaddr field of the Elf32_crinfo structure.
1613 * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Initialise
1614 variables that are passed by reference to
1615 m68hc11_get_relocation_value in case that function does not
1618 * elf32-cr16c.c (cr16c_elf_final_link_relocate): Remove duplicated
1619 return statements and replace with a single return at the end of
1620 the function. This helps pacify the flow analysis code in gcc 4.0.
1622 * elf.c (_bfd_elf_compute_section_file_positions): Initialise
1623 strtab to avoid compile time warning.
1625 2005-02-23 Ben Elliston <bje@au.ibm.com>
1627 * opncls.c (bfd_zalloc): Document this function.
1629 2005-02-21 H.J. Lu <hongjiu.lu@intel.com>
1631 * coffcode.h (sec_to_styp_flags): Replaced SEC_CLINK with
1632 SEC_TIC54X_CLINK. Replace SEC_BLOCK with SEC_TIC54X_BLOCK.
1633 Replace SEC_SHARED with SEC_COFF_SHARED.
1634 (styp_to_sec_flags): Likewise.
1636 * elfxx-target.h (TARGET_BIG_SYM): Remove SEC_ARCH_BIT_0.
1637 (TARGET_LITTLE_SYM): Likewise.
1639 * section.c (SEC_ARCH_BIT_0): Removed.
1640 (SEC_LINK_DUPLICATES_SAME_CONTENTS): Defined with
1641 SEC_LINK_DUPLICATES_ONE_ONLY and SEC_LINK_DUPLICATES_SAME_SIZE.
1642 (SEC_SHARED): Renamed to ...
1643 (SEC_COFF_SHARED): This.
1644 (SEC_BLOCK): Renamed to ...
1645 (SEC_TIC54X_BLOCK): This.
1646 (SEC_CLINK): Renamed to ...
1647 (SEC_TIC54X_CLINK): This.
1648 (SEC_XXX): Rearranged. Move SEC_COFF_SHARED_LIBRARY,
1649 SEC_COFF_SHARED, SEC_TIC54X_BLOCK and SEC_TIC54X_CLINK to the
1651 * bfd-in2.h: Regenerated.
1653 2005-02-21 Fred Fish <fnf@specifixinc.com>
1655 * dwarf2.c (find_abstract_instance_name): Call recursively
1656 to handle a DW_AT_specification.
1658 2005-02-21 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1660 * elfxx-mips.c (ecoff_swap_rpdr_out, mips_elf_output_extsym,
1661 mips_elf_create_dynamic_relocation,
1662 _bfd_mips_elf_size_dynamic_sections, _bfd_mips_elf_final_link):
1663 Remove #if 0'd code.
1665 2005-02-21 Alan Modra <amodra@bigpond.net.au>
1667 * Makefile.am: Run "make dep-am"
1668 * Makefile.in: Regenerate.
1670 2005-02-21 Alan Modra <amodra@bigpond.net.au>
1672 * coffgen.c (bfd_coff_get_comdat_section): Check that
1673 coff_section_data isn't NULL.
1675 2005-02-21 Alan Modra <amodra@bigpond.net.au>
1677 * bfd-in.h (bfd_elf_bfd_from_remote_memory): Warning fix.
1678 * coff-m68k.c (bfd_m68k_coff_create_embedded_relocs): Likewise.
1679 * coff-rs6000.c (xcoff_write_armap_big): Warning fixes. Remove
1680 useless assignments.
1681 (xcoff_write_archive_contents_big): Likewise.
1682 (_bfd_xcoff_put_ldsymbol_name): Likewise.
1683 * coff64-rs6000.c (_bfd_xcoff64_put_ldsymbol_name): Likewise.
1684 * coffgen.c (coff_write_symbols): Make "written" a bfd_vma.
1685 * cofflink.c (process_embedded_commands): Warning fixes.
1686 * cpu-arm.c: Delete unnecessary prototypes. Convert to C90.
1688 * dwarf2.c: Warning fixes.
1689 * elf-bfd.h: Likewise.
1690 * elf-eh-frame.c: Likewise.
1691 * elf-strtab.c: Likewise.
1693 * elf32-m68k.c: Likewise.
1694 * elf32-ppc.c: Likewise.
1695 * elf32-sh-symbian.c: Likewise.
1696 * elf32-sh.c: Delete unnecessary prototypes. Warning fixes.
1697 * elf64-sh64.c: Likewise.
1698 * peicode.h: Likewise.
1699 * elf64-mmix.c: Warning fixes.
1700 * elfcode.h: Likewise.
1701 * elfxx-mips.c: Likewise.
1702 * libbfd-in.h: Likewise.
1703 * libbfd.c: Likewise.
1704 * mach-o.c: Likewise.
1705 * merge.c: Likewise.
1707 * opncls.c: Likewise.
1710 * vms-hdr.c: Likewise.
1711 * vms-tir.c: Likewise.
1712 * xtensa-isa.c: Likewise.
1713 * xtensa-modules.c: Likewise.
1715 (pstrcmp): Use correct choice of string lengths. Fix return value.
1716 (bfd_sym_module_name): Correct string length.
1717 * bfd-in2.h: Regenerate.
1718 * libbfd.h: Regenerate.
1720 2005-02-17 Alexandre Oliva <aoliva@redhat.com>
1722 * elf32-frv.c (elf32_frv_relocate_section): Remove warning from
1723 uninitialized check_segment[1] in TLSMOFF case.
1724 Reported by Alan Modra.
1725 (elf32_frv_relocate_section): Improve errors and warnings.
1727 2005-02-17 Alan Modra <amodra@bigpond.net.au>
1729 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Fix warning.
1731 2005-02-16 Alan Modra <amodra@bigpond.net.au>
1733 * coff-arm.c (coff_arm_is_local_label_name): Warning fix.
1734 * elf32-frv.c (frvfdpic_relocs_info_hash): Likewise.
1735 * pef.c (bfd_pef_scan): Don't ignore return value of
1736 bfd_pef_scan_start_address.
1737 * mach-o.c (bfd_mach_o_scan): Don't ignore return value of
1738 bfd_mach_o_scan_start_address.
1739 * elfxx-ia64.c (elfNN_ia64_relax_brl): Rewrite for 32-bit bfd_vma.
1740 * elfxx-mips.c: Remove unnecessary prototypes.
1741 (sort_dynamic_relocs_64): Abort if not BFD64.
1743 2005-02-16 Alan Modra <amodra@bigpond.net.au>
1745 * elf64-ppc.c (ppc64_elf_edit_toc): Skip toc if size is zero.
1746 Skip toc reloc adjust if reloc_count is zero.
1748 2005-02-15 Nigel Stephens <nigel@mips.com>
1749 Maciej W. Rozycki <macro@mips.com>
1751 * elf32-mips.c (elf_mips16_howto_table_rel): New array for MIPS16
1752 reloc howtos. Add R_MIPS16_HI16 and R_MIPS16_LO16 relocs and
1753 R_MIPS16_GOT16 and R_MIPS16_CALL16 placeholders.
1754 (elf_mips16_jump_howto): Move into elf_mips16_howto_table_rel.
1755 (elf_mips16_gprel_howto): Likewise. Redefine src_mask and
1757 (mips16_gprel_reloc): Remove bit shuffling; call
1758 _bfd_mips16_elf_reloc_unshuffle(), _bfd_mips_elf_gprel16_with_gp()
1759 and _bfd_mips16_elf_reloc_shuffle() instead.
1760 (mips16_reloc_map): New reloc map for MIPS16 relocs.
1761 (bfd_elf32_bfd_reloc_type_lookup): Use mips16_reloc_map for MIPS16
1763 (mips_elf32_rtype_to_howto): Fetch MIPS16 howtos from
1764 elf_mips16_howto_table_rel.
1765 * elf64-mips.c (mips16_elf64_howto_table_rel): New array for
1766 MIPS16 REL reloc howtos. Add R_MIPS16_HI16 and R_MIPS16_LO16
1767 relocs and R_MIPS16_GOT16 and R_MIPS16_CALL16 placeholders.
1768 (elf_mips16_jump_howto): Move into mips16_elf64_howto_table_rel.
1769 (elf_mips16_gprel_howto): Likewise. Redefine src_mask and
1771 (mips16_elf64_howto_table_rela): New array for MIPS16 RELA
1772 reloc howtos. Add R_MIPS16_26, R_MIPS16_GPREL, R_MIPS16_HI16 and
1773 R_MIPS16_LO16 relocs and R_MIPS16_GOT16 and R_MIPS16_CALL16
1775 (mips16_gprel_reloc): Remove bit shuffling; call
1776 _bfd_mips16_elf_reloc_unshuffle(), _bfd_mips_elf_gprel16_with_gp()
1777 and _bfd_mips16_elf_reloc_shuffle() instead.
1778 (mips16_reloc_map): New reloc map for MIPS16 relocs.
1779 (bfd_elf64_bfd_reloc_type_lookup): Use mips16_reloc_map for MIPS16
1781 (mips_elf64_rtype_to_howto): Fetch MIPS16 howtos from
1782 mips16_elf64_howto_table_rela or mips16_elf64_howto_table_rel.
1783 * elfn32-mips.c (elf_mips16_howto_table_rel): New array for MIPS16
1784 REL reloc howtos. Add R_MIPS16_HI16 and R_MIPS16_LO16 relocs and
1785 R_MIPS16_GOT16 and R_MIPS16_CALL16 placeholders.
1786 (elf_mips16_jump_howto): Move into elf_mips16_howto_table_rel.
1787 (elf_mips16_gprel_howto): Likewise. Redefine src_mask and
1789 (mips16_gprel_reloc): Remove bit shuffling; call
1790 _bfd_mips16_elf_reloc_unshuffle(), _bfd_mips_elf_gprel16_with_gp()
1791 and _bfd_mips16_elf_reloc_shuffle() instead.
1792 (mips16_reloc_map): New reloc map for MIPS16 relocs.
1793 (bfd_elf32_bfd_reloc_type_lookup): Use mips16_reloc_map for MIPS16
1795 (mips_elf_n32_rtype_to_howto): Fetch MIPS16 howtos from
1796 elf_mips16_howto_table_rela or elf_mips16_howto_table_rel.
1797 * elfxx-mips.c (_bfd_mips16_elf_reloc_unshuffle): New function to
1798 handle bit shuffling for MIPS16 relocs.
1799 (_bfd_mips16_elf_reloc_shuffle): Likewise.
1800 (_bfd_mips_elf_lo16_reloc): Use _bfd_mips16_elf_reloc_unshuffle()
1801 and _bfd_mips16_elf_reloc_shuffle().
1802 (_bfd_mips_elf_generic_reloc): Likewise.
1803 (mips_elf_calculate_relocation): Likewise. Handle R_MIPS16_HI16
1805 (mips_elf_obtain_contents): Remove bit shuffling.
1806 (mips_elf_perform_relocation): Likewise; call
1807 _bfd_mips16_elf_reloc_unshuffle() and _bfd_mips16_elf_reloc_shuffle()
1809 (_bfd_mips_elf_relocate_section): Likewise. Handle R_MIPS16_HI16
1811 * elfxx-mips.h (_bfd_mips16_elf_reloc_unshuffle): Declare.
1812 (_bfd_mips16_elf_reloc_shuffle): Likewise.
1813 * reloc.c (BFD_RELOC_MIPS16_HI16): New reloc.
1814 (BFD_RELOC_MIPS16_HI16_S): Likewise.
1815 (BFD_RELOC_MIPS16_LO16): Likewise.
1816 * bfd-in2.h: Regenerate.
1817 * libbfd.h: Regenerate.
1819 2005-02-15 Jan Beulich <jbeulich@novell.com>
1821 * elfxx-ia64.c (ia64_howto_table): Correct strings for
1822 R_IA64_DTPMOD64[LM]SB.
1824 2005-02-14 H.J. Lu <hongjiu.lu@intel.com>
1826 * elfxx-ia64.c (elfNN_ia64_relax_section): Allow relax
1827 backward branch in the same section.
1828 (elfNN_ia64_relocate_section): Inform users that the input
1829 section is too big to relax br instruction when overflow
1830 happens to R_IA64_PCREL21B, R_IA64_PCREL21BI, R_IA64_PCREL21M
1831 and R_IA64_PCREL21F.
1833 2005-02-14 Orjan Friberg <orjanf@axis.com>
1835 * elfcore.h (elf_core_file_p): Move the call to
1836 elf_backend_object_p to allow the correct machine to be set before
1837 processing the program headers.
1839 2005-02-14 Nick Clifton <nickc@redhat.com>
1842 * peicode.h (pe_bfd_copy_private_bfd_data): Copy the large address
1843 aware flag from the input bfd to the output bfd.
1845 2005-02-11 Maciej W. Rozycki <macro@mips.com>
1847 * elf32-mips.c (_bfd_mips_elf32_gprel16_reloc): Reject
1848 R_MIPS_LITERAL relocations for external symbols.
1849 * elf64-mips.c (mips_elf64_literal_reloc): Likewise.
1850 * elfn32-mips.c (mips_elf_literal_reloc): Likewise.
1852 2005-02-11 H.J. Lu <hongjiu.lu@intel.com>
1854 * bfd-in2.h: Rebuilt.
1856 2005-02-11 Paul Brook <paul@codesourcery.com>
1858 * elf-bfd.h (struct elf_link_hash_table): Add
1859 is_relocatable_executable.
1860 * elf.c (_bfd_elf_link_hash_table_init): Initialize it.
1861 * elflink.c (bfd_elf_link_record_dynamic_symbol): Create local dynamic
1862 symbols in relocatable executables.
1863 (bfd_elf_record_link_assignment): Create dynamic section symbols in
1864 relocatable executables.
1865 (_bfd_elf_link_renumber_dynsyms): Ditto.
1866 (bfd_elf_final_link): Ditto.
1867 * elf32-arm.c (elf32_arm_final_link_relocate): Copy absolute
1868 relocations into relocatable executables.
1869 (elf32_arm_check_relocs): Crate dynamic sections for relocatable
1870 executables. Also copy absolute relocations.
1871 (elf32_arm_adjust_dynamic_symbol): Don't create copy relocations
1872 in relocatable executables.
1873 (allocate_dynrelocs): Copy relocations for relocatable executables.
1874 Output dynamic symbols for symbols defined in linker scripts.
1876 2005-02-11 Nick Clifton <nickc@redhat.com>
1878 * libbfd.c (read_signed_leb128): Use an unsigned type for 'shift'
1879 to avoid a compile time warning.
1881 * coff-alpha.c (alpha_adjust_reloc_in): Remove redundant test from
1884 * coff-tic4x.c (coff_rtype_to_howto): Move definition before
1885 inclusion of coffcode.h so that it is actually picked up.
1887 * coffcode.h (coff_std_swap_table): Add an unused attribute in
1888 case it is not used.
1890 * elf32-ip2k.c (ip2k_call_opcode, IS_CALL_OPCODE): Remove unused
1891 structure and macro.
1893 * elf32-iq2000.c (iq2000_reloc_map): Remove unused structure and
1896 * elf32-m32r.c (m32r_reloc_map_old): Use #ifdef USE_M32R_OLD_RELOC
1897 to protect the declaration of this array.
1899 * xsym.c (bfd_sym_parse_contained_variables_table_entry_v32):
1900 Avoid call to memcpy with a size of 0.
1902 2005-02-12 Alan Modra <amodra@bigpond.net.au>
1904 * elf64-ppc.c (toc_adjusting_stub_needed): Return true for
1905 old-style branches to undefined dot-symbols which will be
1906 satisfied by a plt call.
1908 2005-02-11 Alan Modra <amodra@bigpond.net.au>
1910 * elf64-ppc.c (move_plt_plist): New function, extracted from..
1911 (ppc64_elf_copy_indirect_symbol): ..here.
1912 (func_desc_adjust): Use move_plt_plist.
1914 2005-02-10 Paul Brook <paul@codesourcery.com>
1916 * elf32-arm.c (elf32_arm_final_link_relocate): Handle R_ARM_THM_PC9.
1918 2005-02-10 Paul Brook <paul@codesourcery.com>
1920 * elflink.c (bfd_elf_record_link_assignment): Make hidden and internal
1922 (elf_link_renumber_hash_table_dynsyms): Ignore local symbols.
1923 (elf_link_renumber_local_hash_table_dynsyms): New function.
1924 (_bfd_elf_link_renumber_dynsyms): Number local dynamic symbols.
1926 2005-02-10 Jakub Jelinek <jakub@redhat.com>
1928 * bfd-in.h (BFD_LINKER_CREATED): Define.
1929 * bfd-in2.h: Rebuilt.
1930 * elflink.c (bfd_elf_size_dynamic_sections): Disregard
1931 BFD_LINKER_CREATED bfds when determining input bfds without
1932 .note.GNU-stack section.
1934 2005-02-10 Maciej W. Rozycki <macro@mips.com>
1936 * elf64-mips.c (mips16_gprel_reloc): Update a comment.
1937 * elfn32-mips.c (mips16_gprel_reloc): Keep R_MIPS16_GPREL
1938 relocations against external symbols unchanged.
1940 2005-02-08 Paul Brook <paul@codesourcery.com>
1942 * elflink.c (elf_link_input_bfd): Ignore symbols from null input
1945 2005-02-08 Hans-Peter Nilsson <hp@axis.com>
1947 * elflink.c (elf_link_add_object_symbols): Don't add "warning: "
1950 2005-02-07 Maciej W. Rozycki <macro@mips.com>
1952 * elf64-mips.c: Fix formatting throughout.
1954 2005-02-07 Maciej W. Rozycki <macro@mips.com>
1956 * elfn32-mips.c (elf_mips_howto_table_rela): Fix a comment typo.
1958 2005-02-07 Alexandre Oliva <aoliva@redhat.com>
1960 * elf32-frv.c (FRVFDPIC_SYM_LOCAL): Remove special handling for
1961 *ABS*/*UND* sections.
1962 (elf32_frv_relocate_section): Move zero-addend-required error...
1963 (_frv_emit_got_relocs_plt_entries): ... here. Report error for
1964 missing needed TLS section.
1966 2005-02-07 Hans-Peter Nilsson <hp@axis.com>
1968 * aoutx.h (NAME(aout,find_nearest_line)): Correct case for N_SO
1969 being the last symbol.
1970 (aout_link_add_symbols): Just return TRUE if a warning
1973 2005-02-07 Maciej W. Rozycki <macro@mips.com>
1975 * elf32-mips.c (mips_elf_gprel32_reloc): Reject
1976 R_MIPS_GPREL32 relocations against external symbols.
1977 * elf64-mips.c (mips_elf64_gprel32_reloc): Replace an incorrect
1980 2005-02-07 Alan Modra <amodra@bigpond.net.au>
1982 * elf-bfd.h (elf_string_from_elf_strtab): Delete macro.
1983 * elf.c (bfd_elf_string_from_elf_section): Expand occurrence of
1984 elf_string_from_elf_strtab.
1985 (_bfd_elf_setup_group_pointers, bfd_section_from_shdr): Likewise.
1986 (bfd_section_from_shdr): For SHT_SYMTAB, load SHT_SYMTAB_SHNDX too
1987 if it exists. Don't do the reverse for SHT_SYMTAB_SHNDX. For
1988 SHT_STRTAB, check whether the strtab is for symtab or dynsymtab by
1989 looking at cached symtab info first, before iterating over headers.
1990 For SHT_REL and SHT_RELA, load dynsymtab if needed.
1991 * elfcode.h (elf_object_p): Don't load section header stringtab
1994 2005-02-06 H.J. Lu <hongjiu.lu@intel.com>
1996 * elf32-i386.c (elf_i386_relocate_section): Disallow R_386_GOTOFF
1997 against protected function when building shared library.
2000 * elf64-x86-64.c (is_32bit_relative_branch): New.
2001 (elf64_x86_64_relocate_section): Alllow R_X86_64_PC32 on a
2002 protected function symbol when building shared library for
2003 32bit relative branch instruction.
2005 2005-02-06 Alan Modra <amodra@bigpond.net.au>
2007 * elf64-ppc.c (add_symbol_adjust): Don't create fake descriptor
2008 syms when doing a relocatable link.
2009 (ppc64_elf_gc_mark_hook): Check that syms are defined before looking
2011 (ppc64_elf_tls_setup): Likewise.
2012 (ppc64_elf_edit_opd): Don't use an undefined func desc sym.
2014 2005-02-04 Alan Modra <amodra@bigpond.net.au>
2016 * elf64-ppc.c (struct ppc_link_hash_entry): Add "fake".
2017 (link_hash_newfunc): Clear all locals using memset.
2018 (make_fdh): Remove flags param. Always create fake func desc
2019 weak. Link the descriptor with the code entry sym.
2020 (ppc64_elf_archive_symbol_lookup): Don't return fake syms.
2021 (add_symbol_adjust): Adjust make_fdh call.
2022 (func_desc_adjust): Likewise. Twiddle any pre-existing fake
2023 descriptor to strong undefined if code entry is strong.
2025 2005-02-04 Alan Modra <amodra@bigpond.net.au>
2027 * elflink.c (bfd_elf_record_link_assignment): Do "provide" symbol
2028 lookup here. Set to new before calling bfd_link_repair_undef_list.
2029 (elf_smash_syms): Check that u.undef.weak isn't the not_needed bfd.
2031 2005-02-03 Alan Modra <amodra@bigpond.net.au>
2033 * linker.c (_bfd_link_hash_newfunc): Set all local fields.
2035 2005-02-03 Alan Modra <amodra@bigpond.net.au>
2037 * linker.c (_bfd_generic_link_add_one_symbol): Set u.undef.weak.
2038 * elflink.c (elf_smash_syms): Restore symbols that were undefweak
2039 before the as-needed lib was loaded. Abort on unexpected refs.
2041 2005-02-02 Alan Modra <amodra@bigpond.net.au>
2043 * elflink.c (elf_smash_syms): Expand comments.
2044 (elf_link_add_object_symbols): Only call elf_smash_syms for
2045 as-needed dynamic objects.
2047 * elfxx-ia64.c (elfNN_ia64_new_elf_hash_entry): Don't clear
2048 everything, just the field specific to ia64.
2049 * elf64-hppa.c (elf64_hppa_new_dyn_hash_entry): Likewise.
2051 2005-02-01 Alan Modra <amodra@bigpond.net.au>
2053 * elf64-ppc.c (func_desc_adjust): Move code creating func desc sym to..
2054 (make_fdh): ..here. New function. Don't set BSF_OBJECT for
2056 (struct add_symbol_adjust_data): New.
2057 (add_symbol_adjust): Make an undefweak func desc for old ABI
2058 objects to link with --as-needed shared libs. Return fail status.
2059 Don't adjust old ABI func entry sym to weak if func desc syms
2061 (ppc64_elf_check_directives): Adjust call to add_symbol_adjust,
2064 2005-02-01 Hans-Peter Nilsson <hp@axis.com>
2066 * cpu-cris.c (get_compatible): Rearrange disabled code and comment
2069 2005-02-01 Alan Modra <amodra@bigpond.net.au>
2071 * elf64-ppc.c (ppc64_elf_check_directives): Move undefs list fixup..
2072 * linker.c (bfd_link_repair_undef_list): ..to new function, but don't
2073 remove anything but new and undefweak.
2074 * elflink.c (_bfd_elf_link_create_dynamic_sections): Override any
2076 (_bfd_elf_create_dynamic_sections): Formatting.
2077 (bfd_elf_record_link_assignment): Call bfd_link_repair_undef_list.
2078 (_bfd_elf_merge_symbol): Don't handle as-needed syms here.
2079 (struct elf_smash_data): New.
2080 (elf_smash_syms): New function.
2081 (elf_link_add_object_symbols): Call elf_smash_syms. Don't add
2082 unneeded dynamic objects to loaded list.
2083 (elf_link_output_extsym): Don't handle as-needed here. Strip
2084 bfd_link_hash_new symbols.
2085 * elf32-cris.c (elf_cris_discard_excess_program_dynamics): Don't
2086 delref when dynindx is already -1.
2087 * elf64-alpha.c (elf64_alpha_output_extsym): Strip bfd_link_hash_new
2089 * elfxx-mips.c (mips_elf_output_extsym): Likewise.
2091 2005-02-01 Ben Elliston <bje@au.ibm.com>
2093 * elfxx-target.h (bfd_elfNN_bfd_discard_group): Redefine.
2095 2005-02-01 Ben Elliston <bje@au.ibm.com>
2097 * aout-arm.c, aout-target.h, aoutx.h, archive.c, armnetbsd.c,
2098 bfd-in.h, bfdio.c, coff-alpha.c, coff-arm.c, coff-h8300.c,
2099 coff-i860.c, coff-mcore.c, coff-or32.c, coff-ppc.c, coff-sh.c,
2100 coff-sparc.c, coffcode.h, coffgen.c, cofflink.c, cpu-cris.c,
2101 cpu-h8500.c, cpu-ns32k.c, ecoff.c, ecofflink.c, elf.c,
2102 elf32-dlx.c, elf32-fr30.c, elf32-frv.c, elf32-hppa.c,
2103 elf32-i860.c, elf32-ip2k.c, elf32-m32r.c, elf32-sh.c,
2104 elf32-v850.c, elf64-mips.c, elf64-sparc.c, elflink.c,
2105 i386aout.c, i386msdos.c, i386os9k.c, ieee.c, mach-o.c,
2106 nlm32-sparc.c, oasys.c, opncls.c, pdp11.c, pe-mips.c, peXXigen.c,
2107 pef.c, peicode.h, reloc.c, riscix.c, section.c, simple.c, som.c,
2108 sparclynx.c, targets.c, vms-misc.c, vms-tir.c, xsym.c, doc/chew.c,
2109 hosts/delta68.h, hosts/vaxbsd.h: Remove #if 0'd code
2110 throughout. Similarly, collapse #if 1'd code.
2112 2005-02-01 Ben Elliston <bje@au.ibm.com>
2114 * elf-bfd.h (bfd_elf_discard_group): Remove.
2115 * elf.c (bfd_elf_discard_group): Likewise.
2116 * elfxx-target.h (bfd_elfNN_bfd_discard_group): Remove macro.
2118 2005-01-31 Richard Sandiford <rsandifo@redhat.com>
2120 * elf-bfd.h (elf_backend_data): Add elf_backend_eh_frame_address_size.
2121 (_bfd_elf_eh_frame_address_size): Declare.
2122 * elfxx-target.h (elf_backend_eh_frame_address_size): Define a default.
2123 (elfNN_bed): Initialize elf_backend_eh_frame_address_size.
2124 * elfxx-mips.h (_bfd_mips_elf_eh_frame_address_size): Declare.
2125 (elf_backend_eh_frame_address_size): Define.
2126 * elfxx-mips.c (_bfd_mips_elf_eh_frame_address_size): New function.
2127 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Get the address
2128 size from the new backend hook.
2129 (_bfd_elf_write_section_eh_frame): Likewise.
2130 (_bfd_elf_eh_frame_address_size): New function.
2132 2005-01-31 Andrew Cagney <cagney@gnu.org>
2134 * configure: Regenerate to track ../gettext.m4.
2136 2005-01-31 Mark Mitchell <mark@codesourcery.com>
2138 * elf32-arm.c (elf32_arm_symbian_special_sections): Do not set
2139 SHF_WRITE for .init_array, .fini_array, and .preinit_array.
2141 2005-01-31 Nick Clifton <nickc@redhat.com>
2143 * confg.bfd: Make targets scheduled for obsoletion (m68k-lynxos,
2144 sparc-lynxos, vax-vms) be obsolete.
2146 2005-01-28 Daniel Jacobowitz <dan@codesourcery.com>
2148 * elf-bfd.h (struct elf_backend_data): Add minpagesize.
2149 * elf32-arm.c (ELF_MINPAGESIZE): Define.
2150 * elf32-ppc.c (ELF_MINPAGESIZE): Define.
2151 * elfcode.h (elf_object_p): Use minpagesize instead of
2153 * elfxx-target.h (ELF_MINPAGESIZE): Default to ELF_MAXPAGESIZE.
2154 (elfNN_bed): Include ELF_MINPAGESIZE.
2156 2005-01-28 Julian Brown <julian@codesourcery.com>
2158 * bin-in.h (bfd_elf32_arm_set_target_relocs): Update prototype.
2159 * bin-in2.h (bfd_elf32_arm_set_target_relocs): Update prototype.
2160 * elf32-arm.c (elf32_arm_link_hash_table): Add fix_v4bx flag.
2161 (bfd_elf32_arm_set_target_relocs): Add formal parameter fix_v4bx for
2162 passing flag value from ld. Set flag value in global hash table entry.
2163 (elf32_arm_final_link_relocate): Add code to implement R_ARM_V4BX
2166 2005-01-27 Andrew Cagney <cagney@gnu.org>
2168 * configure: Regenerate to track ../gettext.m4 change.
2170 2005-01-25 Mark Mitchell <mark@codesourcery.com>
2172 * elf32-arm.c (elf_backend_default_use_rela_p): Define to zero for
2175 2005-01-25 Alexandre Oliva <aoliva@redhat.com>
2177 2004-12-10 Alexandre Oliva <aoliva@redhat.com>
2178 * elf32-frv.c (elf32_frv_relocate_section): Force local binding
2180 * reloc.c: Add R_FRV_TLSMOFF.
2181 * elf32-frv.c (elf32_frv_howto_table): Likewise.
2182 (frv_reloc_map, frv_reloc_type_lookup): Map it.
2183 (elf32_frv_relocate_section): Handle it.
2184 (elf32_frv_check_relocs): Likewise.
2185 * libbfd.h, bfd-in2.h: Rebuilt.
2186 2004-11-26 Alexandre Oliva <aoliva@redhat.com>
2187 * elf32-frv.c (_frvfdpic_emit_got_relocs_plt_entries): Don't crash
2188 when given an undefweak TLS symbol. Fix constant TLS PLT entries
2189 such that they return the constant in gr9.
2190 (_frvfdpic_relax_tls_entries): Don't crash for undefweak TLS
2192 (_frvfdpic_size_got_plt): Set _cooked_size of dynamic sections.
2193 too, such that they shrink on relaxation.
2194 (elf32_frvfdpic_finish_dynamic_sections): Check __ROFIXUP_END__ as
2195 marking the position right past the _GLOBAL_OFFSET_TABLE_ value.
2196 (_frvfdpic_assign_plt_entries): Shrink constant TLS PLT entries
2197 if we can guarantee the use of 16-bit constants.
2198 2004-11-10 Alexandre Oliva <aoliva@redhat.com>
2199 Introduce TLS support for FR-V FDPIC.
2200 * reloc.c: Add TLS relocations.
2201 * elf32-frv.c (elf32_frv_howto_table): Add TLS relocations.
2202 (elf32_frv_rel_tlsdesc_value_howto): New.
2203 (elf32_frv_rel_tlsoff_howto): New.
2204 (frv_reloc_map): Add new mappings.
2205 (struct frvfdpic_elf_link_hash_table): Add pointer to summary
2207 (frvfdpic_dynamic_got_plt_info): New.
2208 (frvfdpic_plt_tls_ret_offset): New.
2209 (ELF_DYNAMIC_INTERPRETER, DEFAULT_STACK_SIZE): Move earlier.
2210 (struct _frvfdpic_dynamic_got_info): Likewise. Add TLS members.
2211 (struct _frvfdpic_dynamic_got_plt_info): Likewise.
2212 (FRVFDPIC_SYM_LOCAL): Regard symbols defined in the absolute
2214 (struct frvfdpic_relocs_info): Add TLS fields.
2215 (frvfdpic_relocs_info_hash): Warning clean up.
2216 (frvfdpic_relocs_info_find): Initialize tlsplt_entry.
2217 (frvfdpic_pic_merge_early_relocs_info): Merge TLS fields.
2218 (FRVFDPIC_TLS_BIAS): Define.
2219 (tls_biased_base): New.
2220 (_frvfdpic_emit_got_relocs_plt_entries): Deal with TLS
2222 (frv_reloc_type_lookup): Likewise.
2223 (frvfdpic_info_to_howto_rel): Likewise.
2224 (elf32_frv_relocate_section): Likewise.
2225 (_frv_create_got_section): Create the PLT section here.
2226 (elf32_frvfdpic_create_dynamic_sections): Not here.
2227 (_frvfdpic_count_nontls_entries): Move out of...
2228 (_frvfdpic_count_got_plt_entries): ... here.
2229 (_frvfdpic_count_tls_entries): Likewise. Add TLS support.
2230 (_frvfdpic_count_relocs_fixups): Likewise. Add relaxation
2232 (_frvfdpic_relax_tls_entries): New.
2233 (_frvfdpic_compute_got_alloc_data): Add TLS support.
2234 (_frvfdpic_get_tlsdesc_entry): New.
2235 (_frvfdpic_assign_got_entries): Add TLS support.
2236 (_frvfdpic_assign_plt_entries): Likewise.
2237 (_frvfdpic_reset_got_plt_entries): New.
2238 (_frvfdpic_size_got_plt): Move out of...
2239 (elf32_frvfdpic_size_dynamic_sections): ... here.
2240 (_frvfdpic_relax_got_plt_entries): New.
2241 (elf32_frvfdpic_relax_section): New.
2242 (elf32_frvfdpic_finish_dynamic_sections): Add TLS sanity check.
2243 (elf32_frv_check_relocs): Add TLS support.
2244 (bfd_elf32_bfd_relax_section): Define for FDPIC.
2245 * libbfd.h, bfd-in2.h: Rebuilt.
2247 2005-01-25 Alan Modra <amodra@bigpond.net.au>
2249 * elf.c (_bfd_elf_get_dynamic_reloc_upper_bound): Only include
2250 loadable reloc sections.
2251 (_bfd_elf_canonicalize_dynamic_reloc): Likewise.
2252 (_bfd_elf_get_synthetic_symtab): Return 0 if no dynamic syms.
2254 2005-01-25 Alan Modra <amodra@bigpond.net.au>
2256 * elflink.c (elf_link_add_object_symbols): Don't create link dynamic
2257 sections immediately when linking shared libs. Instead, wait until
2258 we know a lib is needed.
2259 (_bfd_elf_link_create_dynstrtab): Extract from..
2260 (_bfd_elf_link_create_dynamic_sections_): ..here.
2261 (elf_add_dt_needed_tag): Call _bfd_elf_link_create_dynstrtab and
2262 _bfd_elf_link_create_dynamic_sections. Add abfd param. Allow
2263 for non-existent .dynamic.
2264 (elf_link_output_extsym): Don't complain about undefined symbols
2265 in as-needed dynamic libs that aren't actually linked.
2267 2005-01-24 Andrew Cagney <cagney@gnu.org>
2269 * configure: Regenerate, ../gettext.m4 was updated.
2271 2005-01-21 Ben Elliston <bje@au.ibm.com>
2273 * aout-encap.c: Remove unused file.
2275 2005-01-19 H.J. Lu <hongjiu.lu@intel.com>
2278 * elflink.c (_bfd_elf_dynamic_symbol_p): Only protected
2279 non-function symbols are local.
2280 (_bfd_elf_symbol_refs_local_p): Likewise.
2282 2005-01-18 Alan Modra <amodra@bigpond.net.au>
2284 * bfd.c (bfd_link_just_syms): Add abfd param.
2285 * bfd-in2.h: Regenerate.
2287 2005-01-17 Richard Sandiford <rsandifo@redhat.com>
2289 * elf-eh-frame.c (skip_cfa_op, skip_non_nops): New functions.
2290 (_bfd_elf_discard_section_eh_frame): Use them to interpret the CFA
2291 instructions. If the amount of padding is known, reduce the size
2292 of the CIE or FDE by that amount.
2294 2005-01-17 Richard Sandiford <rsandifo@redhat.com>
2296 * elf-bfd.h (struct cie): Use bfd_vmas for code_align, ra_column and
2297 augmentation_size. Use bfd_signed_vmas for data_align.
2298 * elf-eh-frame.c (read_uleb128, read_sleb128): Delete in favor of...
2299 (read_byte, skip_leb128, read_uleb128, read_sleb128): ...these new
2300 functions. Don't read past the end of the enclosing CIE or FDE.
2301 (skip_bytes): New utility function.
2302 (_bfd_elf_discard_section_eh_frame): Use new functions, adding more
2304 (_bfd_elf_write_section_eh_frame): Use new functions.
2306 2005-01-17 Richard Sandiford <rsandifo@redhat.com>
2308 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Use an
2309 assert-style REQUIRE() macro to handle sanity checks.
2311 2005-01-17 H.J. Lu <hongjiu.lu@intel.com>
2313 * dwarf2.c (dwarf2_debug): Move info_ptr_unit to ...
2315 (read_unsigned_leb128): Removed.
2316 (read_signed_leb128): Removed.
2317 (find_abstract_instance_name): Updated.
2318 (parse_comp_unit): Accept info_ptr_unit.
2319 (_bfd_dwarf2_find_nearest_line): Set info_ptr_unit for each
2320 comp unit and pass it to parse_comp_unit.
2322 * elf-eh-frame.c (read_unsigned_leb128): Moved to ...
2323 (read_signed_leb128): Moved to ...
2326 * libbfd-in.h (read_unsigned_leb128): New prototype.
2327 (read_signed_leb128): Likewise.
2328 * libbfd.h: Regenerated.
2330 2005-01-17 Andrew Stubbs <andrew.stubbs@st.com>
2331 Nick Clifton <nickc@redhat.com>
2333 * cpu-sh.c (bfd_to_arch_table): Change arch_sh1_up to arch_sh_up,
2334 arch__sh4_nofp_up to arch_sh4_nofpu_up and arch_sh4a_nofp_up to
2335 arch_sh4a_nofpu_up in order to match the external names and make the
2336 testsuite's job easier.
2337 * archuires.c: Rename bfd_mach_sh2a_fake? to more meaningful
2339 * bfd-in2.h: Regenerate.
2341 2005-01-15 Andrew Cagney <cagney@gnu.org>
2344 * acinclude.m4: Move BFD_NEED_DECLARATION,
2345 BFD_HAVE_SYS_PROCFS_TYPE and BFD_HAVE_SYS_PROCFS_TYPE_MEMBER to
2346 the new file bfd.m4. Include ../bfd/bfd.m4.
2347 * configure: Re-generate.
2349 2005-01-12 Alan Modra <amodra@bigpond.net.au>
2351 * elf32-ppc.c (ppc_elf_howto_raw): Delete RELAX32* entries.
2352 (ppc_elf_relax_section): Use PLT variants of RELAX32 relocs for
2354 (ppc_elf_relocate_section): Handle R_PPC_RELAX32_PLT and
2355 R_PPC_RELAX32PC_PLT.
2357 2005-01-11 Alan Modra <amodra@bigpond.net.au>
2359 * elf64-ppc.c (ppc64_elf_gc_sweep_hook): Follow indirect and warning
2361 * elf32-arm.c (elf32_arm_gc_sweep_hook): Likewise.
2362 * elf32-cris.c (cris_elf_gc_sweep_hook): Likewise.
2363 * elf32-hppa.c (elf32_hppa_gc_sweep_hook): Likewise.
2364 * elf32-i386.c (elf_i386_gc_sweep_hook): Likewise.
2365 * elf32-m32r.c (m32r_elf_gc_sweep_hook): Likewise.
2366 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Likewise.
2367 * elf32-ppc.c (ppc_elf_gc_sweep_hook): Likewise.
2368 * elf32-s390.c (elf_s390_gc_sweep_hook): Likewise.
2369 * elf32-sh.c (sh_elf_gc_sweep_hook): Likewise.
2370 * elf32-sparc.c (elf32_sparc_gc_sweep_hook): Likewise.
2371 * elf32-vax.c (elf_vax_gc_sweep_hook): Likewise.
2372 * elf32-xtensa.c (elf_xtensa_gc_sweep_hook): Likewise.
2373 * elf64-s390.c (elf_s390_gc_sweep_hook): Likewise.
2374 * elf64-x86-64.c (elf64_x86_64_gc_sweep_hook): Likewise.
2376 2005-01-11 Alan Modra <amodra@bigpond.net.au>
2378 * elf32-ppc.c (ppc_elf_create_dynamic_sections): Correct
2381 2005-01-10 Inderpreet Singh <inderpreetb@noida.hcltech.com>
2383 * archures.c: Define bfd_mach_maxq10 and bfd_mach_maxq20.
2384 * bfd-in2.h: Regenerate.
2385 * coffcode.h (coff_set_arch_mach_hook, coff_set_flags): Add code
2386 to support these new machine values.
2387 * cpu-maxq.c (bfd_maxq10_arch): New architecture definition for
2389 (bfd_maxq_arch): Update values for the maxq20.
2391 2005-01-10 Eric Botcazou <ebotcazou@libertysurf.fr>
2393 * elf64-sparc.c (sparc64_elf_adjust_dynamic_symbol): When linking a
2394 non-shared object, do not reserve space in .plt and .rela.plt for
2395 regular symbols neither defined nor referenced in shared objects.
2397 2005-01-09 Eric Botcazou <ebotcazou@libertysurf.fr>
2399 * elf32-sparc.c (elf32_sparc_link_hash_table_create): Use bfd_zmalloc
2400 to zero the structure.
2401 (create_got_section): Use BFD_ASSERT instead of abort.
2402 * elf64-sparc.c (struct sparc64_elf_link_hash_table): New 'sgot' and
2404 (create_got_section): New function.
2405 (sparc64_elf_create_dynamic_sections): Likewise.
2406 (sparc64_elf_check_relocs): Invoke create_got_section instead of
2407 _bfd_elf_create_got_section. Use the sgot and srelgot shortcuts.
2408 (sparc64_elf_size_dynamic_sections): Use the srelgot shortcut.
2409 (sparc64_elf_relocate_section): Use the sgot and srelgot shortcuts.
2410 (sparc64_elf_finish_dynamic_symbol): Likewise.
2411 (sparc64_elf_finish_dynamic_sections): Use the sgot shortcut.
2412 (elf_backend_create_dynamic_sections): Define to
2413 sparc64_elf_create_dynamic_sections.
2415 2005-01-09 Eric Botcazou <ebotcazou@libertysurf.fr>
2417 * elf32-sparc.c (elf32_sparc_omit_section_dynsym): New function.
2418 (elf_backend_omit_section_dynsym): Define to it.
2419 * elf64-sparc.c (sparc64_elf_omit_section_dynsym): New function.
2420 (elf_backend_omit_section_dynsym): Define to it.
2422 2005-01-07 Jakub Jelinek <jakub@redhat.com>
2424 * bfd/elf.c (INCLUDE_SECTION_IN_SEGMENT): Don't put empty sections into
2425 PT_DYNAMIC segment, unless .dynamic.
2427 2005-01-06 Paul Brook <paul@codesourcery.com>
2429 * config.bfd: Add entry for arm-*-vxworks and arm-*-windiss.
2430 * configure.in: Add bfd_elf32_{big,little}arm_vxworks_vec.
2431 * configure: Regenerate.
2432 * elf32-arm.c: Add VxWorks target bfd.
2434 (elf32_arm_link_hash_table): Add use_rel.
2435 (elf32_arm_link_hash_table_create, elf32_arm_final_link_relocate,
2436 elf32_arm_relocate_section): Replace USE_REL with runtime check.
2437 Correct offset calculation for RELA case.
2438 (elf_backend_may_use_rel_p, elf_backend_may_use_rela_p,
2439 elf_backend_default_use_rela_p, elf_backend_rela_normal): Define.
2440 (elf32_arm_vxworks_link_hash_table_create): New function.
2441 * targets.c (bfd_elf32_bigarm_vxworks_vec): Add declaration.
2442 (bfd_elf32_littlearm_vxworks_vec): Ditto.
2443 (_bfd_target_vector): Add bfd_elf32_{big,little}arm_vxworks_vec.
2445 2005-01-06 Alan Modra <amodra@bigpond.net.au>
2447 * elf64-ppc.c (struct ppc_link_hash_table): Add no_multi_toc and
2449 (has_toc_reloc, makes_toc_func_call, call_check_in_progress): Define.
2450 (ppc64_elf_check_relocs): Update references to has_gp_reloc.
2451 (ppc64_elf_setup_section_lists): Add no_multi_toc parm, set htab bit.
2452 (ppc64_elf_next_toc_section): Heed no_multi_toc.
2453 (ppc64_elf_reinit_toc): Set multi_toc_needed.
2454 (toc_adjusting_stub_needed): Rewrite.
2455 (ppc64_elf_next_input_section): Use multi_toc_needed to shortcut
2456 toc tests. Adjust for toc_adjusting_stub_needed changes.
2457 (ppc64_elf_size_stubs): Update references to has_gp_reloc.
2458 * elf64-ppc.h (ppc64_elf_setup_section_lists): Update prototype.
2459 * section.c: Expand comment on backend bits.
2460 * bfd-in2.h: Regenerate.
2461 * libbfd.h: Regenerate.
2463 2005-01-06 Alan Modra <amodra@bigpond.net.au>
2465 * elf64-ppc.c (ppc64_elf_size_stubs): When determining need for
2466 toc adjusting stub, do not test source section flags.
2468 2005-01-05 Eric Botcazou <ebotcazou@libertysurf.fr>
2470 * elf64-sparc.c (sparc64_elf_relocate_section): Ignore overflows
2471 from STABS debugging sections again.
2473 2005-01-05 Fred Fish <fnf@specifixinc.com>
2475 * dwarf2.c (struct dwarf2_debug): Add info_ptr_unit member.
2476 (find_abstract_instance_name): New function.
2477 (scan_unit_for_functions): Handle DW_TAG_inlined_subroutine.
2478 (scan_unit_for_functions): Handle DW_AT_abstract_origin.
2479 (_bfd_dwarf2_find_nearest_line): Initialize info_ptr_unit.
2481 2004-12-31 Paul Brook <paul@copdesourcery.com>
2483 * elf32-arm.c (elf32_arm_symbian_plt_entry): Fix comment typo.
2485 2004-12-31 Alan Modra <amodra@bigpond.net.au>
2487 * reloc.c (BFD_RELOC_AVR_LDI, BFD_RELOC_AVR_6, BFD_RELOC_AVR_6_ADIW):
2488 Commit missing changes from 2004-12-22.
2489 * bfd-in2.h: Regenerate.
2491 2004-12-23 Tomer Levi <Tomer.Levi@nsc.com>
2493 * elf32-crx.c (elf32_crx_relax_section): Support 'bcop' relaxation.
2495 2004-12-21 Kris Warkentin <kewarken@qnx.com>
2497 * elf.c (elfcore_grok_nto_gregs): Change name to elfcore_grok_nto_regs.
2498 Add 'base' argument for constructing register sections. Reformat.
2499 (elfcore_grok_nto_note): Call elfcore_grok_nto_regs for both
2500 gp and fp regs. Reformat.
2502 2004-12-22 Klaus Rudolph <lts-rudolph@gmx.de>
2504 * reloc.c: Add new relocs R_AVR_LDI, R_AVR_6, R_AVR_6_ADIW.
2505 * bfd-in2.h: Regenerate.
2506 * elf32-avr.c (elf_avr_nowto_table): Add the new relocs.
2507 (avr_reloc_map): Likewise.
2508 (avr_final_link_relocate): Likewise.
2510 2004-12-22 Alan Modra <amodra@bigpond.net.au>
2512 * elflink.c (_bfd_elf_merge_symbol): Treat old definitions from
2513 as-needed dynamic libs as undefined.
2514 (elf_link_add_object_symbols): Remove DYN_AS_NEEDED from as-needed
2515 libs when finding they are needed.
2517 2004-12-20 Alan Modra <amodra@bigpond.net.au>
2519 * elf64-ppc.c (struct ppc64_elf_obj_tdata): Add opd_relocs.
2520 (opd_entry_value): Use opd_relocs if available.
2521 (ppc64_elf_relocate_section): Don't set reloc_done. Instead
2522 copy .opd relocations to opd_relocs.
2523 (ppc64_elf_edit_toc): Set rel_hdr.sh_size after editing relocs.
2525 2004-12-16 Richard Sandiford <rsandifo@redhat.com>
2527 * reloc.c (BFD_RELOC_V850_LO16_SPLIT_OFFSET): New bfd_reloc_code_type.
2528 * elf32-v850.c (v850_elf_howto_table): Add entry for
2529 R_V850_LO16_SPLIT_OFFSET.
2530 (v850_elf_reloc_map): Map it to BFD_RELOC_V850_LO16_SPLIT_OFFSET.
2531 (v850_elf_perform_lo16_relocation): New function, extracted from...
2532 (v850_elf_perform_relocation): ...here. Use it to handle
2533 R_V850_LO16_SPLIT_OFFSET.
2534 (v850_elf_check_relocs, v850_elf_final_link_relocate): Handle
2535 R_V850_LO16_SPLIT_OFFSET.
2536 * libbfd.h, bfd-in2.h: Regenerate.
2538 2004-12-14 P.J. Darcy <darcypj@us.ibm.com>
2540 * config.bfd: Add s390x-ibm-tpf support.
2542 2004-12-14 Tomer Levi <Tomer.Levi@nsc.com>
2544 * elf32-crx.c (elf32_crx_relax_delete_bytes): Add 'struct bfd_link_info *'
2545 to prototype, to make hash info available.
2546 Prevent wrapped symbols from being adjusted twice.
2548 2004-12-14 Richard Sandiford <rsandifo@redhat.com>
2550 * elfxx-mips.c (mips_elf_calculate_relocation): Don't report an
2551 overflow for calls to undefined weak symbols.
2553 2004-12-11 Alan Modra <amodra@bigpond.net.au>
2555 * elfcode.h (elf_slurp_symbol_table): Use bfd_elf_sym_name so that
2556 canonical sections syms have a name.
2558 2004-12-11 Alan Modra <amodra@bigpond.net.au>
2560 * elf64-ppc.c (opd_entry_value): Don't use cached relocs if they
2561 have been adjusted for output.
2562 (ppc64_elf_relocate_section): Mark sections with reloc_done.
2564 2004-12-10 Alan Modra <amodra@bigpond.net.au>
2566 * elf.c (bfd_elf_sym_name): Rename from bfd_elf_local_sym_name and
2567 add symtab_hdr param.
2568 (group_signature): Update calls.
2569 * elf-bfd.h (bfd_elf_sym_name): Update.
2570 * elf32-ppc.c (ppc_elf_relocate_section): Update.
2571 * elf64-ppc.c (ppc64_elf_edit_opd, ppc64_elf_edit_toc): Update.
2572 (ppc64_elf_relocate_section): Update.
2573 * elflink.c (elf_link_input_bfd): Update.
2575 2004-12-10 Jakub Jelinek <jakub@redhat.com>
2577 * elf.c (bfd_elf_local_sym_name): Avoid crashes with invalid
2578 st_shndx on STT_SECTION sections.
2580 2004-12-09 Daniel Jacobowitz <dan@codesourcery.com>
2582 * elfcode.h (elf_slurp_reloc_table_from_section): Don't canonicalize
2583 ELF section symbols.
2585 2004-12-09 Ian Lance Taylor <ian@wasabisystems.com>
2587 * elfxx-mips.c (mips_elf_calculate_relocation): For R_MIPS_JALR,
2588 return a real value, unless it is a PLT symbol.
2589 (mips_elf_perform_relocation): On the RM9000, turn a jal into a
2592 * elfn32-mips.c (elf_mips_howto_table_rela): Change dst_mask of
2593 R_MIPS_JALR entry to 0.
2595 * archures.c: Define bfd_mach_mips9000.
2596 * elfxx-mips.c (_bfd_elf_mips_mach): Handle E_MIPS_MACH_9000.
2597 (mips_set_isa_flags): Handle bfd_mach_mips9000.
2598 * cpu-mips.c (I_mips9000): Define.
2599 (arch_info_struct): Add case for bfd_mach_mips9000.
2600 * aoutx.h (NAME(aout,machine_type)): Handle bfd_mach_mips9000.
2601 * bfd-in2.h: Regenerate.
2603 2004-12-08 Ian Lance Taylor <ian@wasabisystems.com>
2605 * elfxx-mips.c (mips_elf_calculate_relocation): Test for R_MIPS_26
2608 2004-12-07 Ben Elliston <bje@gnu.org>
2610 * netbsd-core.c (netbsd_core_file_p): Make `i' unsigned.
2612 2004-12-06 Daniel Jacobowitz <dan@debian.org>
2614 Suggested by Fergal Daly <fergal@esatclear.ie>:
2615 * simple.c (simple_dummy_multiple_definition): New function.
2616 (bfd_simple_get_relocated_section_contents): Use it.
2618 2004-12-03 Jan Beulich <jbeulich@novell.com>
2620 * elf.c (elf_find_function): Don't use the last file symbol ever,
2621 seen, but the last one seen prior to the symbol being reported.
2622 Don't report a filename at all for global symbols when that might
2625 2004-12-01 Paul Brook <paul@codesourcery.com>
2627 * elf32-arm.c (elf32_arm_copy_private_bfd_data): Set EI_OSABI.
2628 (elf32_arm_post_process_headers): Set EI_OSABI depending on ABI
2631 2004-12-01 Paul Brook <paul@codesourcery.com>
2633 * elflink.c (elf_link_add_object_symbols): Make symbols from discarded
2636 2004-11-30 Paul Brook <paul@codesourcery.com>
2638 * elf32-arm.c (struct elf32_arm_link_hash_table): Remove
2639 no_pipeline_knowledge
2640 (elf32_arm_link_hash_table_create): Ditto.
2641 (bfd_elf32_arm_process_before_allocation): Ditto.
2642 (elf32_arm_final_link_relocate): Ditto. Remove oabi relocation
2644 * bfd-in.h (bfd_elf32_arm_process_before_allocation): Update
2646 * bfd-in2.h: Regenerate.
2648 2004-11-30 Randolph Chung <tausq@debian.org>
2650 * elf32-hppa.c (elf32_hppa_grok_prstatus): New function.
2651 (elf32_hppa_grok_psinfo): New function.
2652 (elf_backend_grok_prstatus): Define.
2653 (elf_backend_grok_psinfo): Define.
2655 2004-11-24 H.J. Lu <hongjiu.lu@intel.com>
2658 * elfcode.h (elf_slurp_symbol_table): Handle STT_TLS.
2660 2004-11-24 Paul Brook <paul@codesourcery.com>
2662 * elf.c (assign_section_numbers): Number SHT_GROUP sections first.
2664 2004-11-24 Paul Brook <paul@codesourcery.com>
2666 * elf32-arm.c (elf32_arm_swap_symbol_in): New function.
2667 (elf32_arm_swap_symbol_out): New function.
2668 (elf32_arm_size_info): Add.
2669 (elf_backend_size_info): Define.
2671 2004-11-20 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
2673 * hpux-core.c (hpux_core_core_file_p): Use offsetof macro in calls to
2676 2004-11-19 Alan Modra <amodra@bigpond.net.au>
2678 * elf32-arm.c (elf32_arm_finish_dynamic_sections): Warning fix.
2679 * elf32-iq2000.c (iq2000_reloc_type_lookup): C90 function decl.
2680 * nlmcode.h (nlm_write_object_contents): Warning fix.
2682 2004-11-18 Bob Wilson <bob.wilson@acm.org>
2684 * elf32-xtensa.c (ebb_propose_action): Fix argument order.
2686 2004-11-17 Daniel Jacobowitz <dan@codesourcery.com>
2688 * elf32-arm.c (PLT_THUMB_STUB_SIZE): Define.
2689 (elf32_arm_plt_thumb_stub): New.
2690 (struct elf32_arm_link_hash_entry): Add plt_thumb_refcount
2692 (elf32_arm_link_hash_traverse): Fix typo.
2693 (elf32_arm_link_hash_table): Add obfd.
2694 (elf32_arm_link_hash_newfunc): Initialize new fields.
2695 (elf32_arm_copy_indirect_symbol): Copy plt_thumb_refcount.
2696 (elf32_arm_link_hash_table_create): Initialize obfd.
2697 (record_arm_to_thumb_glue): Mark the glue as a local ARM function.
2698 (record_thumb_to_arm_glue): Mark the glue as a local Thumb function.
2699 (bfd_elf32_arm_get_bfd_for_interworking): Verify that the
2700 interworking BFD is not dynamic.
2701 (bfd_elf32_arm_process_before_allocation): Handle R_ARM_PLT32. Do
2702 not emit glue for PLT references.
2703 (elf32_arm_final_link_relocate): Handle Thumb functions. Do not
2704 emit glue for PLT references. Support the Thumb PLT prefix.
2705 (elf32_arm_gc_sweep_hook): Handle R_ARM_THM_PC22 and
2707 (elf32_arm_check_relocs): Likewise.
2708 (elf32_arm_adjust_dynamic_symbol): Handle Thumb functions and
2710 (allocate_dynrelocs): Handle Thumb PLT references.
2711 (elf32_arm_finish_dynamic_symbol): Likewise.
2712 (elf32_arm_symbol_processing): New function.
2713 (elf_backend_symbol_processing): Define.
2715 2004-11-16 Richard Sandiford <rsandifo@redhat.com>
2717 * elf-bfd.h (eh_cie_fde): Add new fields: add_augmentation_size and
2718 add_fde_encoding. Remove need_relative.
2719 * elf-eh-frame.c (extra_augmentation_string_bytes)
2720 (extra_augmentation_data_bytes, size_of_output_cie_fde): New functions.
2721 (_bfd_elf_discard_section_eh_frame): Consider changing the FDE encoding
2722 in cases where the CIE has no existing 'R' augmentation. Use
2723 size_of_output_cie_fde when assigning offsets. Use the final offset
2724 as the new section size.
2725 (_bfd_elf_eh_frame_section_offset): Remove need_relative handling.
2726 Account for any extra augmentation bytes in the returned offset.
2727 (_bfd_elf_write_section_eh_frame): Rework so that the entries are
2728 moved before being modified. Pad growing entries with DW_CFA_nops.
2729 Add 'z' and 'R' augmentations as directed by add_augmentation_size
2730 and add_fde_encoding.
2732 2004-11-15 Mark Mitchell <mark@codesourcery.com>
2734 * elf32-arm.c (elf32_arm_relocate_section): Use
2735 arm_real_reloc_type.
2737 2004-11-16 Richard Sandiford <rsandifo@redhat.com>
2739 * elfxx-mips.c (mips_elf_create_dynamic_relocation): Return early
2740 for discard relocations; don't add an R_MIPS_NONE to the main body
2743 2004-11-04 Paul Brook <paul@codesourcery.com>
2745 * elf-bfd.h (_bfd_elf_slurp_version_tables): Update prototype.
2746 * elf.c (_bfd_elf_print_private_bfd_data): Pass extra argument.
2747 (_bfd_elf_slurp_version_tables): Add extra argument. Create extra
2748 default version definition for unversioned symbols.
2749 * elfcode.h (elf_slurp_symbol_table): Pass extra argument.
2750 * elflink.c (elf_link_add_object_symbols): Pass extra argument to
2751 _bfd_elf_slurp_version_tables. Set default version for unversioned
2754 2004-11-15 Paul Brook <paul@codesourcery.com>
2756 * elflink.c (elf_link_add_object_symbols): Don't assume version
2757 indices are consecutive.
2759 2004-11-14 Richard Sandiford <rsandifo@redhat.com>
2761 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Deal with
2762 composite relocations against the personality data.
2764 2004-11-13 Paul Brook <paul@codesourcery.com>
2766 * bfd/elf32-arm.c (elf32_arm_final_link_relocate): Resolve
2767 R_ARM_PREL31 relocations to PLT entries.
2768 (elf32_arm_relocate_section, elf32_arm_gc_sweep_hook): Ditto.
2769 (elf32_arm_check_relocs): Ditto.
2771 2004-11-12 Bob Wilson <bob.wilson@acm.org>
2773 * xtensa-isa.c (xtensa_interface_class_id): New.
2775 2004-11-11 Bob Wilson <bob.wilson@acm.org>
2777 * elf32-xtensa.c (property_table_compare): Remove assertion about
2778 entries with the same address and non-zero size.
2779 (xtensa_read_table_entries): Report such entries as errors.
2781 2004-11-11 Mark Mitchell <mark@codesourcery.com>
2783 * elf32-arm.c (elf32_arm_final_link_relocate): Correct logic for
2784 R_ARM_RELATIVE on Symbian OS.
2786 2004-11-09 Mark Mitchell <mark@codesourcery.com>
2788 * som.c (som_bfd_print_private_bfd_data): New function.
2789 (som_object_setup): Save the auxiliary header. Don't assume that
2790 zero is an invalid entry point for a shared library.
2791 (som_object_p): Allocate the auxiliary header on the heap.
2793 * elf32-arm.c (elf32_arm_begin_write_processing): Do not use a K&R
2795 (elf32_arm_symbian_modify_segment_map): Likewise.
2797 2004-11-09 Daniel Jacobowitz <dan@debian.org>
2799 From David Poole <daveml@mbuf.com>:
2800 * elf32-arm.c (elf32_arm_readonly_dynrelocs): New function.
2801 (elf32_arm_size_dynamic_sections): Call it.
2803 2004-11-09 Alan Modra <amodra@bigpond.net.au>
2805 * Makefile.am (SOURCE_HFILES): Remove elf32-arm.h.
2806 (ALL_MACHINES_CFILES): Fix typo.
2807 * Makefile.in: Regenerate.
2808 * po/SRC-POTFILES.in: Regenerate.
2810 2004-11-08 Mark Mitchell <mark@codesourcery.com>
2812 * elf32-arm.c (elf32_arm_final_link_relocate): When generating an
2813 R_ARM_RELATIVE relocation for Symbian OS, mention the section
2814 symbol in the relocation.
2816 2004-11-08 Inderpreet Singh <inderpreetb@nioda.hcltech.com>
2817 Vineet Sharma <vineets@noida.hcltech.com>
2819 * coff-maxq.c: New File.
2820 * cpu-maxq.c: New File.
2821 * coffcode.h: Likewise.
2822 * config.bfd: Likewise.
2823 * configure.in (maxqcoff_vec): New target vector.
2824 * Makefile.am: Add support for maxq target.
2825 * configure.in: Likewise.
2826 * archures.c:. Likewise.
2827 * targets.c: Likewise.
2828 * bfd_in2.h : Regenerated.
2829 * Makefile.in: Regenerated.
2830 * configure: Regenerated.
2831 * doc/Makefile.in: Regenerated.
2833 2004-11-08 Aaron W. LaFramboise <aaron98wiridge9@aaronwl.com>
2835 * coff-i386.c (coff_i386_reloc): Fix weak symbols.
2836 * cofflink.c (_bfd_coff_link_input_bfd): Don't process
2837 C_NT_WEAK aux entries.
2838 (_bfd_coff_generic_relocate_section): Handle undefined
2841 2004-11-07 Andreas Schwab <schwab@suse.de>
2843 * elf32-m68k.c (elf_m68k_adjust_dynamic_symbol): Use
2844 SYMBOL_CALLS_LOCAL and check for undefweak symbols with
2845 non-default visibility.
2847 2004-11-01 Mark Mitchell <mark@codesourcery.com>
2849 * elf32-arm.c (elf32_arm_symbian_begin_write_processing): Clear
2851 (elf32_arm_symbian_modify_segment_map): Don't
2852 reset includes_filehdr and includes_phdrs here.
2854 2004-11-04 Daniel Jacobowitz <dan@debian.org>
2856 * Makefile.am (BFD32_BACKENDS, BFD32_BACKENDS_CFILES): Replace
2857 elfarm-nabi with elf32-arm. Remove elfarm-oabi.
2858 (elf32-arm.lo): Replace elfarm-nabi.lo rule. Remove elf32-arm.h
2860 * config.bfd: Move arm-*-oabi* and thumb-*-oabi* from obsolete list
2861 to a new removed list. Remove normal configuration stanzas.
2862 * configure.in: (bfd_elf32_bigarm_vec, bfd_elf32_bigarm_symbian_vec)
2863 (bfd_elf32_littlearm_symbian_vec, bfd_elf32_littlearm_vec): Replace
2864 elfarm-nabi.lo with elf32-arm.lo.
2865 (bfd_elf32_bigarm_oabi_vec, bfd_elf32_littlearm_oabi_vec): Remove.
2866 * elf32-arm.c: Renamed from elfarm-nabi.c. Inline elf32-arm.h.
2867 * elf32-arm.h: Remove.
2868 * elfarm-oabi.c: Remove.
2869 * targets.c (_bfd_target_vector): Remove bfd_elf32_bigarm_oabi_vec
2870 and bfd_elf32_littlearm_oabi_vec.
2871 * aclocal.m4, Makefile.in, configure, doc/Makefile.in: Regenerated.
2873 2004-11-04 Hans-Peter Nilsson <hp@axis.com>
2875 * config.bfd: Support crisv32-*-* like cris-*-*.
2876 * archures.c (bfd_mach_cris_v0_v10, bfd_mach_cris_v32)
2877 (bfd_mach_cris_v10_v32): New macros.
2878 * cpu-cris.c: Tweak formatting.
2879 (get_compatible): New function.
2881 (bfd_cris_arch_compat_v10_v32, bfd_cris_arch_v32): New
2882 bfd_arch_info_type:s.
2883 (bfd_cris_arch): Use bfd_mach_cris_v0_v10 for member mach,
2884 get_compatible for member compatible and link bfd_cris_arch_v32 as
2886 * elf32-cris.c (cris_elf_pcrel_reloc)
2887 (cris_elf_set_mach_from_flags): New functions.
2888 (cris_elf_howto_table) <R_CRIS_8_PCREL, R_CRIS_16_PCREL>
2889 <R_CRIS_32_PCREL>: Use cris_elf_pcrel_reloc.
2890 (cris_elf_grok_prstatus, cris_elf_grok_psinfo): Give correct
2891 numbers for bfd_mach_cris_v32.
2892 (PLT_ENTRY_SIZE_V32): New macro.
2893 (elf_cris_plt0_entry): Drop last comma in initializer.
2894 (elf_cris_plt0_entry_v32, elf_cris_plt_entry_v32)
2895 (elf_cris_pic_plt0_entry_v32, elf_cris_pic_plt_entry_v32): New
2897 (cris_elf_relocate_section): Change all "%B(%A)" messages to
2899 (elf_cris_finish_dynamic_symbol): Do V32-specific PLT entries.
2900 (elf_cris_finish_dynamic_sections): Similar.
2901 (elf_cris_adjust_dynamic_symbol): Similar.
2902 (cris_elf_check_relocs): Change all "%B(%A)" messages to "%B,
2904 <switch with PIC relocs>: Emit error and return FALSE for
2905 bfd_mach_cris_v10_v32.
2906 <case R_CRIS_8_PCREL, case R_CRIS_16_PCREL, case R_CRIS_32_PCREL>:
2907 Emit warning when generating textrel reloc.
2908 (cris_elf_object_p): Call cris_elf_set_mach_from_flags.
2909 (cris_elf_final_write_processing): Set flags according to mach.
2910 (cris_elf_print_private_bfd_data): Display
2911 EF_CRIS_VARIANT_COMMON_V10_V32 and EF_CRIS_VARIANT_V32.
2912 (cris_elf_merge_private_bfd_data): Drop variables old_flags,
2913 new_flags. Don't call cris_elf_final_write_processing. Don't
2914 look at the actual elf header flags at all; use
2915 bfd_get_symbol_leading_char to check ibfd, obfd. Trap difference
2916 in bfd_get_mach for ibfd and obfd and handle merging of compatible
2918 (bfd_elf32_bfd_copy_private_bfd_data): Define.
2919 * reloc.c (BFD_RELOC_CRIS_SIGNED_8, BFD_RELOC_CRIS_UNSIGNED_8)
2920 (BFD_RELOC_CRIS_SIGNED_16, BFD_RELOC_CRIS_UNSIGNED_16)
2921 (BFD_RELOC_CRIS_LAPCQ_OFFSET): New relocs.
2922 * bfd-in2.h, libbfd.h: Regenerate.
2924 2004-11-04 Alan Modra <amodra@bigpond.net.au>
2926 * elf64-ppc.h (ppc64_elf_edit_toc): Declare.
2927 * elf64-ppc.c (struct ppc_link_hash_entry <adjust_done>): Update
2929 (struct adjust_toc_info): New.
2930 (adjust_toc_syms, ppc64_elf_edit_toc): New functions.
2932 2004-11-03 Bob Wilson <bob.wilson@acm.org>
2934 * elf.c (assign_file_positions_for_segments): Set next_file_pos even
2935 if there are no segments.
2937 2004-11-02 Daniel Jacobowitz <dan@debian.org>
2939 * config.bfd: Mark arm-*-oabi and thumb-*-oabi as obsolete.
2941 2004-11-02 Nick Clifton <nickc@redhat.com>
2943 * elf32-iq2000.c: Convert to ISO C90 formatting.
2945 2004-11-02 Hans-Peter Nilsson <hp@axis.com>
2947 * elflink.c (_bfd_elf_create_got_section): Hide _GLOBAL_OFFSET_TABLE_.
2949 2004-10-28 H.J. Lu <hongjiu.lu@intel.com>
2951 * elfxx-ia64.c (elfNN_ia64_relocate_section): Handle weak
2952 undefined symbols for R_IA64_SECREL32MSB, R_IA64_SECREL32LSB,
2953 R_IA64_SECREL64MSB and R_IA64_SECREL64LSB.
2955 2004-10-28 Kaz Kojima <kkojima@rr.iij4u.or.jp>
2957 * elf32-sh.c (tpoff): Take alignment into account.
2959 2004-10-28 Nick Clifton <nickc@redhat.com>
2961 * elf32-iq2000.c (iq2000_elf_relocate_section): Do nothing when
2962 performing a relocatable link.
2963 (iq2000_elf_object_p): Do not set elf_bad_symtab. This is only
2964 for MIPS ports under Irix.
2966 2004-10-27 Richard Earnshaw <rearnsha@arm.com>
2968 * elf32-arm.h (bfd_elf32_arm_process_before_allocation): Handle
2969 R_ARM_CALL and R_ARM_JUMP24 as aliases of R_ARM_PC24.
2970 (elf32_arm_final_link_relocate): Ditto.
2971 (arm_add_to_rel, elf32_arm_relocate_section): Ditto.
2972 (elf32_arm_gc_sweep_hook, elf32_arm_check_relocs): Ditto
2973 (elf32_arm_adjust_dynamic_symbol): Ditto.
2974 * elfarm-nabi.c (elf32_arm_howto_table): Add R_ARM_CALL and
2975 R_ARM_JUMP32. Move R_ARM_R{REL32,ABS32,PC24,BASE}...
2976 (elf32_arm_r_howto): ... To here.
2977 (elf32_arm_howto_from_type): Use elf32_arm_r_howto.
2979 2004-10-26 H.J. Lu <hongjiu.lu@intel.com>
2982 * elfxx-ia64.c (elfNN_ia64_relocate_section): Correct
2983 R_IA64_SECREL32MSB, R_IA64_SECREL32LSB, R_IA64_SECREL64MSB
2984 and R_IA64_SECREL64LSB.
2986 2004-10-26 Paul Brook <paul@codesourcery.com>
2988 * elflink.c (elf_finalize_dynstr): Skip shared aux structure.
2989 (bfd_elf_size_dynamic_sections): Create default version definition.
2990 (elf_link_output_extsym): Adjust for default symbol version.
2992 2004-10-24 Hans-Peter Nilsson <hp@bitrange.com>
2994 * mmo.c: Adjust to ISO C.
2996 * mmo.c (mmo_write_section_description): New function broken out
2997 of mmo_internal_write_section.
2998 (mmo_internal_write_section): For each of .text and .data, call
2999 mmo_write_section_description before outputting contents if it has
3000 nontrivially deducible vma or contents.
3001 (mmo_has_leading_or_trailing_zero_tetra_p): New function.
3002 (mmo_canonicalize_symtab): Adjust absolute symbols to .data
3003 symbols if found within the .data address range.
3005 2004-10-24 Daniel Jacobowitz <dan@debian.org>
3007 * opncls.c (bfd_close): Return TRUE for BFD_IN_MEMORY.
3009 2004-10-24 Hans-Peter Nilsson <hp@bitrange.com>
3011 * mmo.c (File Layout): Correct place of misplaced blurb about
3014 2004-10-22 Mark Kettenis <kettenis@gnu.org>
3016 * config.bfd: Add mips64*-*-openbsd.
3018 2004-10-21 Bob Wilson <bob.wilson@acm.org>
3020 * elf32-xtensa.c (ebb_propose_action): Put declarations before
3023 2004-10-21 H.J. Lu <hongjiu.lu@intel.com>
3025 * configure.in: (AM_INIT_AUTOMAKE): Set version to 2.15.94.
3026 * configure: Regenerate.
3028 2004-10-21 H.J. Lu <hongjiu.lu@intel.com>
3031 * aoutx.h (aout_link_input_section_std): Pass proper hash entry
3032 to linker reloc_overflow callback.
3033 (aout_link_input_section_ext): Likewise.
3034 (aout_link_reloc_link_order): Likewise.
3035 * coff-a29k.c (coff_a29k_relocate_section): Likewise.
3036 * coff-alpha.c (alpha_ecoff_get_relocated_section_contents):
3038 (alpha_relocate_section): Likewise.
3039 * coff-arm.c (coff_arm_relocate_section): Likewise.
3040 * coff-h8300.c (h8300_reloc16_extra_cases): Likewise.
3041 * coff-h8500.c (extra_case): Likewise.
3042 * coff-i960.c (coff_i960_relocate_section): Likewise.
3043 * coff-mcore.c (coff_mcore_relocate_section): Likewise.
3044 * coff-mips.c (mips_relocate_section): Likewise.
3045 * coff-or32.c (coff_or32_relocate_section): Likewise.
3046 * coff-ppc.c (coff_ppc_relocate_section): Likewise.
3047 * coff-rs6000.c (xcoff_ppc_relocate_section): Likewise.
3048 * coff-sh.c (sh_relocate_section): Likewise.
3049 * coff-tic80.c (coff_tic80_relocate_section): Likewise.
3050 * coff-w65.c (w65_reloc16_extra_cases): Likewise.
3051 * coff-z8k.c (extra_case): Likewise.
3052 * coff64-rs6000.c (xcoff64_ppc_relocate_section): Likewise.
3053 * cofflink.c (_bfd_coff_reloc_link_order): Likewise.
3054 (_bfd_coff_generic_relocate_section): Likewise.
3055 * ecoff.c (ecoff_reloc_link_order): Likewise.
3056 * elf-hppa.h (elf_hppa_relocate_section): Likewise.
3057 * elf-m10200.c (mn10200_elf_relocate_section): Likewise.
3058 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
3059 * elf32-arm.h (elf32_arm_relocate_section): Likewise.
3060 * elf32-avr.c (elf32_avr_relocate_section): Likewise.
3061 * elf32-cr16c.c (elf32_cr16c_relocate_section): Likewise.
3062 * elf32-cris.c (cris_elf_relocate_section): Likewise.
3063 * elf32-crx.c (elf32_crx_relocate_section): Likewise.
3064 * elf32-d10v.c (elf32_d10v_relocate_section): Likewise.
3065 * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
3066 * elf32-frv.c (elf32_frv_relocate_section): Likewise.
3067 * elf32-h8300.c (elf32_h8_relocate_section): Likewise.
3068 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
3069 * elf32-i370.c (i370_elf_relocate_section): Likewise.
3070 * elf32-i386.c (elf_i386_relocate_section): Likewise.
3071 * elf32-i860.c (elf32_i860_relocate_section): Likewise.
3072 * elf32-ip2k.c (ip2k_elf_relocate_section): Likewise.
3073 * elf32-iq2000.c (iq2000_elf_relocate_section): Likewise.
3074 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
3075 * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Likewise.
3076 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
3077 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
3078 * elf32-msp430.c (elf32_msp430_relocate_section): Likewise.
3079 * elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
3080 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
3081 * elf32-s390.c (elf_s390_relocate_section): Likewise.
3082 * elf32-sh.c (sh_elf_relocate_section): Likewise.
3083 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
3084 * elf32-v850.c (v850_elf_relocate_section): Likewise.
3085 * elf32-vax.c (elf_vax_relocate_section): Likewise.
3086 * elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
3087 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
3088 * elf64-mmix.c (mmix_elf_relocate_section): Likewise.
3089 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
3090 * elf64-s390.c (elf_s390_relocate_section): Likewise.
3091 * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
3092 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
3093 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
3094 * elflink.c (elf_reloc_link_order): Likewise.
3095 * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
3096 * elfxx-mips.c (_bfd_mips_elf_relocate_section): Likewise.
3097 (_bfd_elf_mips_get_relocated_section_contents): Likewise.
3098 * linker.c (_bfd_generic_reloc_link_order): Likewise.
3099 * pdp11.c (pdp11_aout_link_input_section): Likewise.
3100 (aout_link_reloc_link_order): Likewise.
3101 * reloc.c (bfd_generic_get_relocated_section_contents):
3103 * xcofflink.c (xcoff_reloc_link_order): Likewise.
3104 * simple.c (simple_dummy_reloc_overflow): Updated.
3106 2004-10-20 Andreas Schwab <schwab@suse.de>
3108 * elf32-m68k.c (elf_m68k_plt_sym_val): New function.
3109 (elf_backend_plt_sym_val): Define.
3111 2004-10-19 Danny Smith <dannysmith@users.sourceforege.net>
3113 * config.bfd: Set targ_underscore=yes for PE COFF targets
3115 2004-10-19 Alan Modra <amodra@bigpond.net.au>
3117 * elf64-ppc.c (opd_entry_value): Handle --just-symbols objects.
3118 (ppc64_elf_edit_opd): Likewise.
3120 2004-10-18 Mark Mitchell <mark@codesourcery.com>
3122 * elfarm-nabi.c (ELF_DYNAMIC_SEC_FLAGS): Add comment.
3123 * elflink.c (_bfd_elf_create_dynamic_sections): For a loaded PLT,
3124 set SEC_ALLOC and SEC_LOAD.
3126 2004-10-18 Nick Clifton <nickc@redhat.com>
3128 * elf32-xstormy16.c (xstormy16_elf_relocate_section): Compute
3129 'name' for relocs against both local and global symbols.
3131 2004-10-16 Daniel Jacobowitz <dan@debian.org>
3133 * bfd-in2.h: Regenerate.
3134 * bfd.c (struct bfd): Add no_export.
3135 * elflink.c (elf_link_add_object_symbols): Handle no_export.
3137 2004-10-15 Alan Modra <amodra@bigpond.net.au>
3139 * config.bfd: Whitespace cleanup.
3140 * Makefile.am: Run "make dep-am"
3141 * Makefile.in: Regenerate.
3143 2004-10-15 Jakub Jelinek <jakub@redhat.com>
3145 * elflink.c (struct already_linked_section): Removed.
3146 (try_match_symbols_in_sections, already_linked): Removed.
3147 (_bfd_elf_section_already_linked): Skip ^\.gnu\.linkonce\.[^.]*\.
3148 prefix of section names when finding already_linked_table
3149 chain. Compare section names. Instead of calling already_linked,
3150 do it inline and only for sections in the same already_linked_list.
3152 2004-10-15 Alan Modra <amodra@bigpond.net.au>
3154 * elf-eh-frame.c (_bfd_elf_eh_frame_section_offset): Add "info"
3155 parameter. If called after _bfd_elf_write_section_eh_frame,
3156 don't allow a -2 return unless need_* bit is already set, and
3157 handle offsets adjusted for output_offset.
3158 * elf-bfd.h (_bfd_elf_eh_frame_section_offset): Update prototype.
3159 * elf.c (_bfd_elf_section_offset): Update call.
3161 2004-10-13 H.J. Lu <hongjiu.lu@intel.com>
3164 * coffcode.h (coff_compute_section_file_positions): Cast to
3165 bfd_vma when computing page alignment.
3167 2004-10-13 Mark Mitchell <mark@codesourcery.com>
3169 * elf32-arm.h (elf32_arm_finish_dynamic_sections): Use file
3170 offsets, not VMAs, for DT_VERSYM, DT_VERDEF, DT_VERNEED.
3172 2004-10-12 Mark Mitchell <mark@codesourcery.com>
3174 * elf32-arm.h (elf32_arm_finish_dynamic_symbol): Make .rel.plt
3175 relocations use a virtual address, not a section offset.
3177 2004-10-12 Bob Wilson <bob.wilson@acm.org>
3179 * elf32-xtensa.c (elf_xtensa_get_private_bfd_flags): Delete.
3180 (narrow_instruction, widen_instruction): Remove unnecessary calls to
3181 xtensa_format_encode.
3182 (ebb_propose_action): Inline call to ebb_add_proposed_action.
3183 (ebb_add_proposed_action): Delete.
3185 2004-10-12 Bob Wilson <bob.wilson@acm.org>
3187 * elf32-xtensa.c: Use ISO C90 formatting.
3189 2004-10-12 Paul Brook <paul@codesourcery.com>
3191 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Rephrase error
3194 2004-10-12 Paul Brook <paul@codesourcery.com>
3196 * elf32-arm.h: Support EABI version 4 objects.
3198 2004-10-12 Alan Modra <amodra@bigpond.net.au>
3201 * cpu-i386.c (bfd_x86_64_arch_intel_syntax): Place last in chain.
3202 Don't mark as default.
3203 (bfd_x86_64_arch): Don't mark as default.
3205 2004-10-12 Alan Modra <amodra@bigpond.net.au>
3207 * elflink.c (enum action_discarded): New.
3208 (elf_section_complain_discarded): Delete.
3209 (elf_action_discarded): New function subsuming the above and also
3210 controlling reloc behaviour.
3211 (elf_link_input_bfd): Use it.
3213 2004-10-11 Jakub Jelinek <jakub@redhat.com>
3215 * elf.c (bfd_section_from_shdr): Handle SHT_GNU_LIBLIST.
3216 (special_sections): Add .gnu.liblist and .gnu.conflict.
3217 (assign_section_numbers): Handle SHT_GNU_LIBLIST.
3219 2004-10-11 Alan Modra <amodra@bigpond.net.au>
3222 * elflink.c (elf_link_input_bfd): Try harder to support
3223 relocations against symbols in removed linkonce sections.
3225 2004-10-11 Alan Modra <amodra@bigpond.net.au>
3227 * elflink.c (elf_link_input_bfd): Revert PR 354 change.
3230 * elflink.c (elf_link_input_bfd): Check that relocs in SEC_ALLOC
3231 sections do not reference symbols in non-SEC_ALLOC sections.
3233 2004-10-11 Alan Modra <amodra@bigpond.net.au>
3236 * elflink.c (elf_link_sort_relocs): Don't bomb on unusual sections.
3237 (_bfd_elf_link_omit_section_dynsym): Formatting.
3239 2004-10-10 Alan Modra <amodra@bigpond.net.au>
3241 * libbfd-in.h (BFD_ASSERT, BFD_FAIL): Wrap macro body in do while.
3242 * libbfd.h: Regnerate.
3243 * elf32-cris.c: Add missing semicolon to BFD_ASSERTs.
3244 * elf32-frv.c: Likewise.
3245 * elf32-m32r.c: Likewise.
3246 * elf32-ppc.c: Likewise.
3247 * elf64-hppa.c: Likewise.
3248 * elfxx-ia64.c: Likewise.
3249 * opncls.c: Likewise.
3251 2004-10-10 Alan Modra <amodra@bigpond.net.au>
3253 * elf-bfd.h (struct eh_frame_hdr_info): Add offsets_adjusted.
3254 * elf-eh-frame.c (_bfd_elf_write_section_eh_frame): Adjust
3255 offsets stored in struct eh_cie_fde entries before doing other
3258 * elf-bfd.h (struct eh_cie_fde): Add cie_inf, remove sec.
3259 (struct eh_frame_hdr_info): Add last_cie_inf, remove last_cie_offset.
3260 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Delete code
3261 setting offsets for removed CIEs. Don't set "sec", instead set
3262 cie_inf for FDEs. Keep a pointer to last struct eh_cie_fde for a
3263 CIE in hdr_info. Only set make_relative and make_lsda_relative
3264 for CIEs. Use pointers rather than array indices.
3265 (_bfd_elf_eh_frame_section_offset): Test/set make_relative,
3266 make_lsda_relative, need_* on cie_inf for FDEs.
3267 (_bfd_elf_write_section_eh_frame): Adjust offset and new_offset for
3268 section output_offset. Delete cie_offset, instead use cie_inf
3269 pointer to CIE entry. Use need_relative and need_lsda_relative on
3270 CIE entry for FDEs. Use pointers rather than array indices.
3272 2004-10-09 Alan Modra <amodra@bigpond.net.au>
3274 * coff-rs6000.c (rs6000coff_vec): Add initializer for
3275 bfd_is_target_special_symbol.
3276 * coff64-rs6000.c (rs6000coff64_vec): Likewise.
3277 * som.c (som_bfd_is_target_special_symbol): Define.
3279 2004-10-08 Nick Clifton <nickc@redhat.com>
3281 * configure.in: (AM_INIT_AUTOMAKE): Set version to 2.15.93.
3282 * configure: Regenerate.
3283 * bfd-in2.h: Regenerate.
3284 * syms.c (bfd_is_target_special_symbol): New interface function.
3285 Returns true when a symbol should be considered to be special.
3286 * targets.c (bfd_target): Include bfd_is_target_special_symbol in
3287 the symbol jump table.
3288 * elf32-arm.h (elf32_arm_is_target_special_symbol): New function.
3289 Return true iff the symbol is a mapping symbol.
3290 (bfd_elf32_bfd_is_target_special_symbol): Define.
3291 * elfxx-target.h: Provide a default definition for
3292 bfd_is_target_special_symbol.
3293 * aout-target.h: Likewise.
3294 * aout-tic30.c: Likewise.
3295 * binary.c: Likewise.
3296 * coffcode.h: Likewise.
3297 * i386msdos.c: Likewise.
3300 * libaout.h: Likewise.
3301 * libbfd-in.h: Likewise
3302 * libecoff.h: Likewise.
3303 * mach-o.c: Likewise.
3305 * nlm-target.h: Likewise.
3306 * oasys.c: Likewise.
3308 * ppcboot.c: Likewise.
3310 * tekhex.c: Likewise.
3311 * versados.c: Likewise.
3313 * xcoff-target.h: Likewise.
3315 * libbfd.h: Regenerate.
3317 2004-10-08 Daniel Jacobowitz <dan@debian.org>
3319 * config.bfd: Include 64-bit support for i[3-7]86-*-solaris2*.
3320 * elf64-x86-64.c (elf64_x86_64_section_from_shdr): New function.
3321 (elf_backend_section_from_shdr): Define.
3323 2004-10-08 Alan Modra <amodra@bigpond.net.au>
3325 * syms.c (bfd_is_local_label): Return false for file symbols.
3327 2004-10-07 Bob Wilson <bob.wilson@acm.org>
3328 David Heine <dlheine@tensilica.com>
3330 * elf32-xtensa.c (elf32xtensa_size_opt): New global variable.
3331 (xtensa_default_isa): Global variable moved here from xtensa-isa.c.
3332 (elf32xtensa_no_literal_movement): New global variable.
3333 (elf_howto_table): Add entries for new relocations.
3334 (elf_xtensa_reloc_type_lookup): Handle new relocations.
3335 (property_table_compare): When addresses are equal, compare sizes and
3336 various property flags.
3337 (property_table_matches): New.
3338 (xtensa_read_table_entries): Extend to read new property tables. Add
3339 output_addr parameter to indicate that output addresses should be used.
3340 Use bfd_get_section_limit.
3341 (elf_xtensa_find_property_entry): New.
3342 (elf_xtensa_in_literal_pool): Use elf_xtensa_find_property_entry.
3343 (elf_xtensa_check_relocs): Handle new relocations.
3344 (elf_xtensa_do_reloc): Use bfd_get_section_limit. Handle new
3345 relocations. Use new xtensa-isa.h functions.
3346 (build_encoding_error_message): Remove encode_result parameter. Add
3347 new target_address parameter used to detect alignment errors.
3348 (elf_xtensa_relocate_section): Use bfd_get_section_limit. Clean up
3349 error handling. Use new is_operand_relocation function.
3350 (elf_xtensa_combine_prop_entries, elf_xtensa_merge_private_bfd_data):
3351 Use underbar macro for error messages. Formatting.
3352 (get_const16_opcode): New.
3353 (get_l32r_opcode): Add a separate flag for initialization.
3354 (get_relocation_opnd): Operand number is no longer explicit in the
3355 relocation. Change to decode the opcode and analyze its operands.
3356 (get_relocation_slot): New.
3357 (get_relocation_opcode): Add bfd parameter. Use bfd_get_section_limit.
3358 Use new xtensa-isa.h functions to handle multislot instructions.
3359 (is_l32r_relocation): Add bfd parameter. Use is_operand_relocation.
3360 (get_asm_simplify_size, is_alt_relocation, is_operand_relocation,
3361 insn_decode_len, insn_decode_opcode, check_branch_target_aligned,
3362 check_loop_aligned, check_branch_target_aligned_address, narrowable,
3363 widenable, narrow_instruction, widen_instruction, op_single_fmt_table,
3364 get_single_format, init_op_single_format_table): New.
3365 (elf_xtensa_do_asm_simplify): Add error_message parameter and use it
3366 instead of calling _bfd_error_handler. Use new xtensa-isa.h functions.
3367 (contract_asm_expansion): Add error_message parameter and pass it to
3368 elf_xtensa_do_asm_simplify. Replace use of R_XTENSA_OP0 relocation
3369 with R_XTENSA_SLOT0_OP.
3370 (get_expanded_call_opcode): Extend to handle either L32R or CONST16
3371 instructions. Use new xtensa-isa.h functions.
3372 (r_reloc struct): Add new virtual_offset field.
3373 (r_reloc_init): Add contents and content_length parameters. Set
3374 virtual_offset field to zero. Add contents to target_offset field for
3375 partial_inplace relocations.
3376 (r_reloc_is_defined): Check for null.
3377 (print_r_reloc): New debug function.
3378 (source_reloc struct): Replace xtensa_operand field with pair of the
3379 opcode and the operand position. Add is_abs_literal field.
3380 (init_source_reloc): Specify operand by opcode/position pair. Set
3381 is_abs_literal field.
3382 (source_reloc_compare): When target_offsets are equal, compare other
3383 fields to make sorting predictable.
3384 (literal_value struct): Add is_abs_literal field.
3385 (value_map_hash_table struct): Add has_last_loc and last_loc fields.
3386 (init_literal_value): New.
3387 (is_same_value): Replace with ...
3388 (literal_value_equal): ... this function. Add comparisons of
3389 virtual_offset and is_abs_literal fields.
3390 (value_map_hash_table_init): Use bfd_zmalloc. Check for allocation
3391 failure. Initialize has_last_loc field.
3392 (value_map_hash_table_delete): New.
3393 (hash_literal_value): Rename to ...
3394 (literal_value_hash): ... this. Include is_abs_literal flag and
3395 virtual_offset field in the hash value.
3396 (get_cached_value): Rename to ...
3397 (value_map_get_cached_value): ... this. Update calls to
3398 literal_value_hash and literal_value_equal.
3399 (add_value_map): Check for allocation failure. Update calls to
3400 value_map_get_cached_value and literal_value_hash.
3401 (text_action, text_action_list, text_action_t): New types.
3402 (find_fill_action, compute_removed_action_diff, adjust_fill_action,
3403 text_action_add, text_action_add_literal, offset_with_removed_text,
3404 offset_with_removed_text_before_fill, find_insn_action,
3405 print_action_list, print_removed_literals): New.
3406 (offset_with_removed_literals): Delete.
3407 (xtensa_relax_info struct): Add is_relaxable_asm_section, action_list,
3408 fix_array, fix_array_count, allocated_relocs, relocs_count, and
3409 allocated_relocs_count fields.
3410 (init_xtensa_relax_info): Initialize new fields.
3411 (reloc_bfd_fix struct): Add new translated field.
3412 (reloc_bfd_fix_init): Add translated parameter and use it to set the
3414 (fix_compare, cache_fix_array): New.
3415 (get_bfd_fix): Remove fix_list parameter and get all relax_info for the
3416 section via get_xtensa_relax_info. Use cache_fix_array to set up
3417 sorted fix_array and use bsearch instead of linear search.
3418 (section_cache_t): New struct.
3419 (init_section_cache, section_cache_section, clear_section_cache): New.
3420 (ebb_t, ebb_target_enum, proposed_action, ebb_constraint): New types.
3421 (init_ebb_constraint, free_ebb_constraint, init_ebb, extend_ebb_bounds,
3422 extend_ebb_bounds_forward, extend_ebb_bounds_backward,
3423 insn_block_decodable_len, ebb_propose_action, ebb_add_proposed_action):
3425 (retrieve_contents): Use bfd_get_section_limit.
3426 (elf_xtensa_relax_section): Add relocations_analyzed flag. Update call
3427 to compute_removed_literals. Free value_map_hash_table when no longer
3429 (analyze_relocations): Check is_relaxable_asm_section flag. Call
3430 compute_text_actions for all sections.
3431 (find_relaxable_sections): Mark sections as relaxable if they contain
3432 ASM_EXPAND relocations that can be optimized. Adjust r_reloc_init
3433 call. Increment relax_info src_count field only for appropriate
3434 relocation types. Remove is_literal_section check.
3435 (collect_source_relocs): Use bfd_get_section_limit. Adjust calls to
3436 r_reloc_init and find_associated_l32r_irel. Check
3437 is_relaxable_asm_section flag. Handle L32R instructions with absolute
3438 literals. Pass is_abs_literal flag to init_source_reloc.
3439 (is_resolvable_asm_expansion): Use bfd_get_section_limit. Check for
3440 CONST16 instructions. Adjust calls to r_reloc_init and
3441 pcrel_reloc_fits. Handle weak symbols conservatively.
3442 (find_associated_l32r_irel): Add bfd parameter and pass it to
3444 (compute_text_actions, compute_ebb_proposed_actions,
3445 compute_ebb_actions, check_section_ebb_pcrels_fit,
3446 check_section_ebb_reduces, text_action_add_proposed,
3447 compute_fill_extra_space): New.
3448 (remove_literals): Replace with ...
3449 (compute_removed_literals): ... this function. Call
3450 init_section_cache. Use bfd_get_section_limit. Sort internal_relocs.
3451 Call xtensa_read_table_entries to get the property table. Skip
3452 relocations other than R_XTENSA_32 and R_XTENSA_PLT. Use new
3453 is_removable_literal, remove_dead_literal, and
3454 identify_literal_placement functions.
3455 (get_irel_at_offset): Rewrite to use bsearch on sorted relocations
3456 instead of linear search.
3457 (is_removable_literal, remove_dead_literal,
3458 identify_literal_placement): New.
3459 (relocations_reach): Update check for literal not referenced by any
3460 PC-relative relocations. Adjust call to pcrel_reloc_fits.
3461 (coalesce_shared_literal, move_shared_literal): New.
3462 (relax_section): Use bfd_get_section_limit. Call
3463 translate_section_fixes. Update calls to r_reloc_init and
3464 offset_with_removed_text. Check new is_relaxable_asm_section flag.
3465 Add call to pin_internal_relocs. Add special handling for
3466 R_XTENSA_ASM_SIMPLIFY and R_XTENSA_DIFF* relocs. Use virtual_offset
3467 info to calculate new addend_displacement variable. Replace code for
3468 deleting literals with more general code to perform the actions
3469 determined by the action_list for the section.
3470 (translate_section_fixes, translate_reloc_bfd_fix): New.
3471 (translate_reloc): Check new is_relaxable_asm_section flag. Call
3472 find_removed_literal only if is_operand_relocation. Update call to
3473 offset_with_removed_text. Use new target_offset and removed_bytes
3475 (move_literal): New.
3476 (relax_property_section): Use bfd_get_section_limit. Set new
3477 is_full_prop_section flag and handle new property tables. Update calls
3478 to r_reloc_init and offset_with_removed_text. Check
3479 is_relaxable_asm_section flag. Handle expansion of zero-sized
3480 unreachable entries, with use of offset_with_removed_text_before_fill.
3481 For relocatable links, combine entries only for literal tables.
3482 (relax_section_symbols): Check is_relaxable_asm_section flag. Update
3483 calls to offset_with_removed_text. Translate st_size field for
3485 (do_fix_for_relocatable_link): Change to return bfd_boolean to indicate
3486 failure. Add contents parameter. Update call to get_bfd_fix. Update
3487 call to r_reloc_init. Call _bfd_error_handler and return FALSE for
3488 R_XTENSA_ASM_EXPAND relocs.
3489 (do_fix_for_final_link): Add input_bfd and contents parameters. Update
3490 call to get_bfd_fix. Include offset from contents for partial_inplace
3492 (is_reloc_sym_weak): New.
3493 (pcrel_reloc_fits): Use new xtensa-isa.h functions.
3494 (prop_sec_len): New.
3495 (xtensa_is_property_section): Handle new property sections.
3496 (is_literal_section): Delete.
3497 (internal_reloc_compare): When r_offset matches, compare r_info and
3498 r_addend to make sorting predictable.
3499 (internal_reloc_matches): New.
3500 (xtensa_get_property_section_name): Handle new property sections.
3501 (xtensa_get_property_predef_flags): New.
3502 (xtensa_callback_required_dependence): Use bfd_get_section_limit.
3503 Update calls to xtensa_isa_init, is_l32r_relocation, and r_reloc_init.
3504 * xtensa-isa.c (xtensa_default_isa): Moved to elf32-xtensa.c.
3505 (xtisa_errno, xtisa_error_msg): New variables.
3506 (xtensa_isa_errno, xtensa_isa_error_msg): New.
3507 (xtensa_insnbuf_alloc): Add error handling.
3508 (xtensa_insnbuf_to_chars): Add num_chars parameter. Update to
3509 use xtensa_format_decode. Add error handling.
3510 (xtensa_insnbuf_from_chars): Add num_chars parameter. Decode the
3511 instruction length to find the number of bytes to copy.
3512 (xtensa_isa_init): Add error handling. Replace calls to
3513 xtensa_load_isa and xtensa_extend_isa with code to initialize lookup
3514 tables in the xtensa_modules structure.
3515 (xtensa_check_isa_config, xtensa_add_isa, xtensa_load_isa,
3516 xtensa_extend_isa): Delete.
3517 (xtensa_isa_free): Change to only free lookup tables.
3518 (opname_lookup_compare): Replace with ...
3519 (xtensa_isa_name_compare): ... this function. Use strcasecmp.
3520 (xtensa_insn_maxlength): Rename to ...
3521 (xtensa_isa_maxlength): ... this.
3522 (xtensa_insn_length): Delete.
3523 (xtensa_insn_length_from_first_byte): Replace with ...
3524 (xtensa_isa_length_from_chars): ... this function.
3525 (xtensa_num_opcodes): Rename to ...
3526 (xtensa_isa_num_opcodes): ... this.
3527 (xtensa_isa_num_pipe_stages, xtensa_isa_num_formats,
3528 xtensa_isa_num_regfiles, xtensa_isa_num_stages,
3529 xtensa_isa_num_sysregs, xtensa_isa_num_interfaces,
3530 xtensa_isa_num_funcUnits, xtensa_format_name, xtensa_format_lookup,
3531 xtensa_format_decode, xtensa_format_encode, xtensa_format_length,
3532 xtensa_format_num_slots, xtensa_format_slot_nop_opcode,
3533 xtensa_format_get_slot, xtensa_format_set_slot): New functions.
3534 (xtensa_opcode_lookup): Add error handling.
3535 (xtensa_decode_insn): Replace with ...
3536 (xtensa_opcode_decode): ... this function, with new format and
3537 slot parameters. Add error handling.
3538 (xtensa_encode_insn): Replace with ...
3539 (xtensa_opcode_encode): ... this function, which does the encoding via
3540 one of the entries in the "encode_fns" array. Add error handling.
3541 (xtensa_opcode_name): Add error handling.
3542 (xtensa_opcode_is_branch, xtensa_opcode_is_jump, xtensa_opcode_is_loop,
3543 xtensa_opcode_is_call): New.
3544 (xtensa_num_operands): Replace with ...
3545 (xtensa_opcode_num_operands): ... this function. Add error handling.
3546 (xtensa_opcode_num_stateOperands,
3547 xtensa_opcode_num_interfaceOperands, xtensa_opcode_num_funcUnit_uses,
3548 xtensa_opcode_funcUnit_use, xtensa_operand_name,
3549 xtensa_operand_is_visible): New.
3550 (xtensa_get_operand, xtensa_operand_kind): Delete.
3551 (xtensa_operand_inout): Add error handling and special-case for
3553 (xtensa_operand_get_field, xtensa_operand_set_field): Rewritten to
3554 operate on one slot of an instruction. Added error handling.
3555 (xtensa_operand_encode): Handle default operands with no encoding
3556 functions. Check for success by comparing against decoded value.
3558 (xtensa_operand_decode): Handle default operands. Return decoded value
3559 through argument pointer. Add error handling.
3560 (xtensa_operand_is_register, xtensa_operand_regfile,
3561 xtensa_operand_num_regs, xtensa_operand_is_known_reg): New.
3562 (xtensa_operand_isPCRelative): Rename to ...
3563 (xtensa_operand_is_PCrelative): ... this. Add error handling.
3564 (xtensa_operand_do_reloc, xtensa_operand_undo_reloc): Return value
3565 through argument pointer. Add error handling.
3566 (xtensa_stateOperand_state, xtensa_stateOperand_inout,
3567 xtensa_interfaceOperand_interface, xtensa_regfile_lookup,
3568 xtensa_regfile_lookup_shortname, xtensa_regfile_name,
3569 xtensa_regfile_shortname, xtensa_regfile_view_parent,
3570 xtensa_regfile_num_bits, xtensa_regfile_num_entries,
3571 xtensa_state_lookup, xtensa_state_name, xtensa_state_num_bits,
3572 xtensa_state_is_exported, xtensa_sysreg_lookup,
3573 xtensa_sysreg_lookup_name, xtensa_sysreg_name, xtensa_sysreg_number,
3574 xtensa_sysreg_is_user, xtensa_interface_lookup, xtensa_interface_name,
3575 xtensa_interface_num_bits, xtensa_interface_inout,
3576 xtensa_interface_has_side_effect, xtensa_funcUnit_lookup,
3577 xtensa_funcUnit_name, xtensa_funcUnit_num_copies): New.
3578 * xtensa-modules.c: Rewrite to use new data structures.
3579 * reloc.c (BFD_RELOC_XTENSA_DIFF8, BFD_RELOC_XTENSA_DIFF16,
3580 BFD_RELOC_XTENSA_DIFF32, BFD_RELOC_XTENSA_SLOT0_OP,
3581 BFD_RELOC_XTENSA_SLOT1_OP, BFD_RELOC_XTENSA_SLOT2_OP,
3582 BFD_RELOC_XTENSA_SLOT3_OP, BFD_RELOC_XTENSA_SLOT4_OP,
3583 BFD_RELOC_XTENSA_SLOT5_OP, BFD_RELOC_XTENSA_SLOT6_OP,
3584 BFD_RELOC_XTENSA_SLOT7_OP, BFD_RELOC_XTENSA_SLOT8_OP,
3585 BFD_RELOC_XTENSA_SLOT9_OP, BFD_RELOC_XTENSA_SLOT10_OP,
3586 BFD_RELOC_XTENSA_SLOT11_OP, BFD_RELOC_XTENSA_SLOT12_OP,
3587 BFD_RELOC_XTENSA_SLOT13_OP, BFD_RELOC_XTENSA_SLOT14_OP,
3588 BFD_RELOC_XTENSA_SLOT0_ALT, BFD_RELOC_XTENSA_SLOT1_ALT,
3589 BFD_RELOC_XTENSA_SLOT2_ALT, BFD_RELOC_XTENSA_SLOT3_ALT,
3590 BFD_RELOC_XTENSA_SLOT4_ALT, BFD_RELOC_XTENSA_SLOT5_ALT,
3591 BFD_RELOC_XTENSA_SLOT6_ALT, BFD_RELOC_XTENSA_SLOT7_ALT,
3592 BFD_RELOC_XTENSA_SLOT8_ALT, BFD_RELOC_XTENSA_SLOT9_ALT,
3593 BFD_RELOC_XTENSA_SLOT10_ALT, BFD_RELOC_XTENSA_SLOT11_ALT,
3594 BFD_RELOC_XTENSA_SLOT12_ALT, BFD_RELOC_XTENSA_SLOT13_ALT,
3595 BFD_RELOC_XTENSA_SLOT14_ALT): Add new relocations.
3596 * Makefile.am (xtensa-isa.lo, xtensa-modules.lo): Update dependencies.
3597 * Makefile.in: Regenerate.
3598 * bfd-in2.h: Likewise.
3599 * libbfd.h: Likewise.
3601 2004-10-07 Richard Sandiford <rsandifo@redhat.com>
3603 * elf64-mips.c (mips_elf64_write_rel): Use STN_UNDEF for relocs
3604 against the absolute section.
3605 (mips_elf64_write_rela): Likewise.
3607 2004-10-07 Jan Beulich <jbeulich@novell.com>
3609 * elf.c (elf_find_function): Don't generally check for matching
3610 section, just for non-file symbols. Remove redunant comparison
3612 * elf32-arm.h (arm_elf_find_function): Likewise.
3614 2004-10-07 Jeff Baker <jbaker@qnx.com>
3616 * elflink.c (_bfd_elf_add_dynamic_entry): Add code to warn if
3617 adding a DT_TEXTREL to a shared object and --warn-shared-textrel
3620 2004-10-04 Roland McGrath <roland@redhat.com>
3622 * hash.c (bfd_hash_set_default_size): Use const for table.
3623 Use size_t instead of int for variable compared to sizeof results.
3625 2004-10-05 Alan Modra <amodra@bigpond.net.au>
3628 * syms.c (_bfd_stab_section_find_nearest_line): Ignore R_*_NONE relocs.
3630 2004-10-01 Paul Brook <paul@codesourcery.com>
3632 * elf32-arm.h (elf32_arm_fake_sections,
3633 is_arm_elf_unwind_section_name, elf32_arm_section_from_shdr): New
3635 (elf_backend_fake_sections, elf_backend_section_from_shdr): Define.
3637 2004-10-01 Alan Modra <amodra@bigpond.net.au>
3639 * elf-bfd.h (struct eh_cie_fde): Add need_relative and
3641 * elf-eh-frame.c (_bfd_elf_eh_frame_section_offset): Set
3642 need_relative or need_lsda_relative if we are processing an
3643 offset for a reloc on a FDE initial loc or LSDA field
3645 (_bfd_elf_write_section_eh_frame): Test need_relative and
3646 need_lsda_relative in place of corresponding make_* field
3647 when deciding to use pc-relative encodings.
3649 2004-09-30 Paul Brook <paul@codesourcery.com>
3651 * elf32-arm.h (bfd_elf32_arm_set_target_relocs): Handle "abs"
3652 target2 relocation type.
3654 2004-09-30 H.J. Lu <hongjiu.lu@intel.com>
3657 * elflink.c (_bfd_elf_merge_symbol): Check TLS symbol.
3659 2004-09-30 Paul Brook <paul@codesourcery.com>
3661 * reloc.c: Add BFD_RELOC_ARM_SMI.
3662 * bfd-in2.h: Regenerate.
3665 2004-09-24 Alan Modra <amodra@bigpond.net.au>
3667 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Add output section
3668 vma and output offset to address.
3669 * simple.c (simple_save_output_info): Only set output section
3670 and offset for debug sections, or those not already set up by
3672 (bfd_simple_get_relocated_section_contents): Update comment.
3674 2004-09-24 Alan Modra <amodra@bigpond.net.au>
3676 * elf.c (IS_LOADED): Delete.
3677 (assign_file_positions_for_segments): Just test SEC_LOAD instead.
3678 Restore SEC_HAS_CONTENTS test to the one place it was used prior
3681 2004-09-23 Alan Modra <amodra@bigpond.net.au>
3684 * elf32-sparc.c (elf32_sparc_final_write_processing): Handle
3685 bfd_mach_sparc_sparclet and bfd_mach_sparc_sparclite. Remove
3686 redundant assignment of EM_SPARC.
3688 2004-09-22 Brian Ford <ford@vss.fsi.com>
3690 * pei-i386.c (COFF_SECTION_ALIGNMENT_ENTRIES): Enable 16 byte
3691 alignment for .rdata sections so sse[2] code works with gcc >= 3.3.3
3693 * pe-i386.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
3695 2004-09-22 Alan Modra <amodra@bigpond.net.au>
3697 * elf32-ppc.c (ppc_elf_modify_segment_map): Delete.
3698 (elf_backend_modify_segment_map): Don't define.
3700 2004-09-22 Alan Modra <amodra@bigpond.net.au>
3702 * elf.c (IS_LOADED): Define.
3703 (assign_file_positions_for_segments): Don't round up file offset of
3704 PT_LOAD segments containing no SEC_LOAD sections, instead round down.
3705 Delete code handling link script adjustment of lma. Do the adjust
3706 in later code handling similar ajustments. Remove dead code error
3707 check. Warn if section lma would require a negative offset
3708 adjustment. Tweak lma adjustment to use p_filesz rather than p_memsz.
3709 Use p_vaddr + p_memsz inside section loop in place of voff. Don't
3710 update voff in section loop. Change voff in segment loop to be an
3711 adjustment on top of "off". Set sec->filepos and update "off" later.
3712 Test for loadable sections consistently using IS_LOADED. Similarly,
3713 test for alloc-only sections other than .tbss consistently.
3714 Don't bother checking SEC_ALLOC in PT_LOAD segments. Remove FIXME.
3715 Tidy PT_NOTE handling. Use %B and %A in error messages.
3716 (assign_file_positions_except_relocs): Use %B in error message.
3718 2004-09-17 H.J. Lu <hongjiu.lu@intel.com>
3720 * Makefile.am (AUTOMAKE_OPTIONS): Require 1.9.
3721 (CONFIG_STATUS_DEPENDENCIES): New.
3722 (Makefile): Removed.
3723 (config.status): Likewise.
3724 * Makefile.in: Regenerated.
3726 2004-09-17 Paul Brook <paul@codesourcery.com>
3728 * bfd-in.h (bfd_elf32_arm_set_target_relocs): Add prototype.
3729 (bfd_elf32_arm_process_before_allocation): Update prototype.
3730 * bfd-in2.h: Regenerate.
3731 * bfd/elf32-arm.h (elf32_arm_link_hash_table): Add target2_reloc.
3732 (elf32_arm_link_hash_table_create): Set it.
3733 (bfd_elf32_arm_process_before_allocation): Remove target1_is_rel.
3734 (bfd_elf32_arm_set_target_relocs): New function.
3735 (arm_real_reloc_type): New function.
3736 (elf32_arm_final_link_relocate): Use it. Handle R_ARM_PREL31 and
3737 R_ARM_GOT_PREL. Remove R_ARM_TARGET1.
3738 (elf32_arm_gc_sweep_hook): Ditto.
3739 (elf32_arm_check_relocs): Ditto.
3740 (elf32_arm_relocate_section): Handle R_ARM_GOT_PREL.
3741 * elfarm-nabi.c (elf32_arm_howto_table): Add R_ARM_PREL31 and
3743 (elf32_arm_got_prel): New variable.
3744 (elf32_arm_howto_from_type): New function.
3745 (elf32_arm_info_to_howto): Use it.
3746 (elf32_arm_reloc_map): Add BFD_RELOC_ARM_PREL31 and
3747 BFD_RELOC_ARM_TARGET2.
3748 * libbfd.h: Regenerate.
3749 * reloc.c: Add BFD_RELOC_ARM_TARGET2 and BFD_RELOC_ARM_PREL31.
3751 2004-09-17 Alan Modra <amodra@bigpond.net.au>
3753 * ecoff.c: Update u.undef.next refs.
3754 * elf64-ppc.c: Likewise.
3755 * elflink.c: Likewise.
3756 * linker.c: Likewise.
3757 * xcofflink.c: Likewise.
3759 * elf-bfd.h (struct elf_link_hash_entry): Rearrange. Add FIXME to
3760 dynamic_def. Combine weakdef and elf_hash_value. Move vtable
3761 fields to indirect struct.
3762 * elf-m10300.c: Update u.weakdef refs.
3763 * elf32-arm.h: Likewise.
3764 * elf32-cris.c: Likewise.
3765 * elf32-frv.c: Likewise.
3766 * elf32-hppa.c: Likewise.
3767 * elf32-i370.c: Likewise.
3768 * elf32-i386.c: Likewise.
3769 * elf32-m32r.c: Likewise.
3770 * elf32-m68k.c: Likewise.
3771 * elf32-ppc.c: Likewise.
3772 * elf32-s390.c: Likewise.
3773 * elf32-sh.c: Likewise.
3774 * elf32-sparc.c: Likewise.
3775 * elf32-vax.c: Likewise.
3776 * elf32-xtensa.c: Likewise.
3777 * elf64-alpha.c: Likewise.
3778 * elf64-hppa.c: Likewise.
3779 * elf64-ppc.c: Likewise.
3780 * elf64-s390.c: Likewise.
3781 * elf64-sh64.c: Likewise.
3782 * elf64-sparc.c: Likewise.
3783 * elf64-x86-64.c: Likewise.
3784 * elfxx-ia64.c: Likewise.
3785 * elfxx-mips.c: Likewise.
3786 * elflink.c: Likewise. Also u.elf_hash_value.
3787 (elf_gc_propagate_vtable_entries_used): Update for h->vtable
3789 (elf_gc_smash_unused_vtentry_relocs): Likewise.
3790 (bfd_elf_gc_record_vtinherit): Alloc vtable.
3791 (bfd_elf_gc_record_vtentry): Likewise.
3792 * elf.c (_bfd_elf_link_hash_newfunc): Use memset.
3794 2004-09-17 Alan Modra <amodra@bigpond.net.au>
3796 * Makefile.am: Run "make dep-am".
3797 * Makefile.in: Regenerate.
3798 * bfd-in2.h: Regenerate.
3799 * po/SRC-POTFILES.in: Regenerate.
3800 * po/bfd.pot: Regenerate.
3802 2004-09-16 Alan Modra <amodra@bigpond.net.au>
3804 * elf-bfd.h (struct elf_link_hash_entry): Replace elf_link_hash_flags
3805 with bitfields. Make "type" and "other" bitfields too.
3806 (ELF_LINK_HASH_REF_REGULAR, ELF_LINK_HASH_DEF_REGULAR,
3807 ELF_LINK_HASH_REF_DYNAMIC, ELF_LINK_HASH_DEF_DYNAMIC,
3808 ELF_LINK_HASH_REF_REGULAR_NONWEAK, ELF_LINK_HASH_DYNAMIC_ADJUSTED,
3809 ELF_LINK_HASH_NEEDS_COPY, ELF_LINK_HASH_NEEDS_PLT, ELF_LINK_NON_ELF,
3810 ELF_LINK_HIDDEN, ELF_LINK_FORCED_LOCAL, ELF_LINK_HASH_MARK,
3811 ELF_LINK_NON_GOT_REF, ELF_LINK_DYNAMIC_DEF, ELF_LINK_DYNAMIC_WEAK,
3812 ELF_LINK_POINTER_EQUALITY_NEEDED): Delete.
3813 (ELF_COMMON_DEF_P, WILL_CALL_FINISH_DYNAMIC_SYMBOL): Update.
3814 * elf-hppa.h: Update all uses of elf_link_hash_flags.
3815 * elf-m10300.c: Likewise.
3817 * elf32-arm.h: Likewise.
3818 * elf32-cris.c: Likewise.
3819 * elf32-frv.c: Likewise.
3820 * elf32-hppa.c: Likewise.
3821 * elf32-i370.c: Likewise.
3822 * elf32-i386.c: Likewise.
3823 * elf32-m32r.c: Likewise.
3824 * elf32-m68k.c: Likewise.
3825 * elf32-ppc.c: Likewise.
3826 * elf32-s390.c: Likewise.
3827 * elf32-sh-symbian.c: Likewise.
3828 * elf32-sh.c: Likewise.
3829 * elf32-sh64.c: Likewise.
3830 * elf32-sparc.c: Likewise.
3831 * elf32-vax.c: Likewise.
3832 * elf32-xtensa.c: Likewise.
3833 * elf64-alpha.c: Likewise.
3834 * elf64-hppa.c: Likewise.
3835 * elf64-ppc.c: Likewise.
3836 * elf64-s390.c: Likewise.
3837 * elf64-sh64.c: Likewise.
3838 * elf64-sparc.c: Likewise.
3839 * elf64-x86-64.c: Likewise.
3840 * elflink.c: Likewise.
3841 * elfxx-ia64.c: Likewise.
3842 * elfxx-mips.c: Likewise.
3843 * configure.in (AM_INIT_AUTOMAKE): Set version to 2.15.92.
3844 * configure: Regenerate.
3845 * aclocal.m4: Regenerate.
3847 2004-09-16 Alan Modra <amodra@bigpond.net.au>
3849 * elf32-arm.h (elf32_arm_gc_sweep_hook): Add #ifndef OLD_ARM_ABI
3850 around uses of R_ARM_TARGET1.
3851 (elf32_arm_check_relocs): Likewise.
3853 2004-09-13 Paul Brook <paul@codesourcery.com>
3855 * bfd-in.h (bfd_elf32_arm_process_before_allocation): Update
3857 * bfd-in2.h: Regenerate.
3858 * libbfd.h: Regenerate.
3859 * elf32-arm.h (elf32_arm_link_hash_table): Add target1_is_rel.
3860 (elf32_arm_link_hash_table_create): Set target1_is_rel.
3861 (bfd_elf32_arm_process_before_allocation): Ditto.
3862 (elf32_arm_final_link_relocate): Handle R_ARM_TARGET1.
3863 (elf32_arm_gc_sweep_hook, elf32_arm_check_relocs): Ditto.
3864 * elfarm-nabi.c (elf32_arm_howto_table): Rename RELABS to TARGET1.
3867 2004-09-10 Joel Brobecker <brobecker@gnat.com>
3869 * hpux-core.c (thread_section_p): New function.
3870 (hpux_core_core_file_p): Fix computation of offset in call
3871 to bfd_seek. Create a ".reg" section from an arbitrary
3872 ".reg/<id>" section if none was created after having read
3875 2004-09-11 Andreas Schwab <schwab@suse.de>
3877 * acinclude.m4: Fix spelling of ACX_NONCANONICAL_*.
3878 * aclocal.m4: Rebuild.
3879 * configure: Rebuild.
3881 2004-09-10 Joel Brobecker <brobecker@gnat.com>
3883 * section.c (bfd_sections_find_if): Fix parameter name in
3884 comment to match code.
3886 2004-09-10 Alan Modra <amodra@bigpond.net.au>
3888 * elf.c (assign_file_positions_except_relocs): Assign relocs
3889 stored in a bfd section.
3891 2004-09-08 Hans-Peter Nilsson <hp@axis.com>
3893 * elf32-cris.c (elf_cris_adjust_gotplt_to_got): Reset
3894 h->gotplt_refcount to 0, not -1.
3896 2004-09-07 Hans-Peter Nilsson <hp@axis.com>
3898 * elf32-cris.c (cris_elf_relocate_section) <case R_CRIS_16_GOTPLT,
3899 case R_CRIS_32_GOTPLT>: For internal error message, handle NULL
3901 (cris_elf_check_relocs) <case R_CRIS_32_PLT_PCREL>: Don't try to
3902 handle symbol visibility here.
3904 2004-09-07 Alan Modra <amodra@bigpond.net.au>
3906 * elf64-ppc.c (struct ppc_link_hash_table): Add stub_globals.
3907 (is_ppc64_elf_target): Rename from is_ppc64_target. Update all
3909 (ppc_stub_name): Remove trailing "+0" on stub name.
3910 (create_linkage_sections): Create relocations for
3911 branch lookup table when --emit-relocs as well as when --shared.
3912 (ppc_build_one_stub): Emit relocs for long branch stubs. Adjust
3913 relbrlt test. For --emit-stub-syms, always output a sym even when
3914 one already exists on a plt call stub. Put stub type in the stub
3916 (ppc_size_one_stub): Size long branch stub relocs. Adjust relbrlt
3918 (ppc64_elf_size_stubs): Count global sym stubs added. Zero
3919 reloc_count in stub sections. Adjust relbrlt test.
3920 (ppc64_elf_build_stubs): Adjust relbrlt test. Tweak stats output.
3921 * elflink.c (bfd_elf_size_dynamic_sections): Fix comment typo.
3922 (elf_link_input_bfd): Ignore symbol index zero relocs when checking
3923 for relocs against discarded symbols. Fix comments.
3925 2004-09-06 Mark Mitchell <mark@codesourcery.com>
3927 * elf-bfd.h (_bfd_elf_make_dynamic_segment): Declare it.
3928 * elf.c (_bfd_elf_make_dynamic_segment): New function, split out
3930 (map_sections_to_segments): ... here. Use it. Assign a file
3931 position to the .dynamic section if it is not loadable, but part
3932 of the PT_DYNAMIC segment.
3933 * elf32-arm.h (elf32_arm_finish_dynamic_sections): Use file
3934 offsets, not VMAs, for the BPABI. Do not fill in the header in
3935 the .got.plt section for the BPABI.
3936 * elfarm-nabi.c (elf32_arm_symbian_modify_segment_map): Add a
3938 (elf_backend_want_got_plt): Define to zero for Symbian OS.
3940 2004-09-06 Nick Clifton <nickc@redhat.com>
3942 * elflink.c (elf_link_add_object_symbols): Set the error code to
3943 bfd_error_wrong_format when the input format does not match the
3946 2004-09-06 Alan Modra <amodra@bigpond.net.au>
3948 * elf64-ppc.c (is_ppc64_target): New function, extracted from..
3949 (ppc64_elf_check_directives): ..here.
3950 (ppc64_elf_size_dynamic_sections): Use it here to check bfd type
3951 before accessing ppc64_elf_tdata.
3952 (ppc64_elf_finish_dynamic_sections): And here too.
3954 2004-09-04 Alan Modra <amodra@bigpond.net.au>
3956 * bfd.c (_bfd_default_error_handler): Correct loop exit.
3958 2004-09-03 Mark Mitchell <mark@codesourcery.com>
3960 * config.bfd (arm*-*-symbianelf*): Use OS-specific target vectors.
3961 * configure.in (bfd_elf32_bigarm_symbian_vec): Add it.
3962 (bfd_elf32_littlearm_symbian_vec): Likewise.
3963 * configure: Regenerated.
3964 * elf-bfd.h (elf_backend_data): Add dynamic_sec_flags.
3965 * elf32-arm.h (PLT_HEADER_SIZE): Do not define.
3966 (PLT_ENTRY_SIZE): Likewise.
3967 (bfd_vma_elf32_arm_symbian_plt_entry): New
3969 (elf32_arm_link_hash_table): Add plt_header_size, plt_entry_size,
3971 (create_got_section): Don't create sections when generating BPABI
3973 (elf32_arm_create_dynamic_sections): Tidy.
3974 (elf32_arm_link_hash_table_create): Set plt_header_size,
3975 plt_entry_size, and symbian_p.
3976 (elf32_arm_check_relocs): Do not mark .rel.dyn as loadable when
3977 generating BPABI objects.
3978 (allocate_dynrelocs): Use htab->plt_header_size, not
3979 PLT_HEADER_SIZE. Do not add to .got.plt when
3980 generating BPABI objects.
3981 (elf32_arm_finish_dynamic_symbol): Generate Symbian OS PLTs.
3982 * elfarm-nabi.c: Add SymbianOS target vectors.
3983 * elflink.c (_bfd_elf_create_got_section): Use dynamic_sec_flags.
3984 (_bfd_elf_link_create_dynamic_sections): Likewise.
3985 * elfxx-target.h (ELF_DYNAMIC_SEC_FLAGS): New macro.
3986 (elfNN_bed): Use it.
3987 * targets.c (bfd_elf32_bigarm_symbian_vec): New variable.
3988 (bfd_elf32_littlearm_symbian_vec): Likewise.
3989 (_bfd_target_vector): Add them.
3991 2004-09-03 Nick Clifton <nickc@redhat.com>
3994 * coffcode.h (handle_COMDAT): Replace abort with an warning
3995 message and allow the scan to continue.
3997 2004-09-02 Alan Modra <amodra@bigpond.net.au>
3999 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Use static_syms passed
4000 in when reading relocs, not our sorted syms. Remove unnecessary
4003 2004-08-31 Eric Botcazou <ebotcazou@libertysurf.fr>
4005 * elf.c (special_sections): Add .gnu.linkonce.b modelled on .bss.
4007 2004-08-30 Nathanael Nerode <neroden@gcc.gnu.org>
4009 * acinclude.m4: Require AC_CANONICAL_TARGET, not AC_CANONICAL_SYSTEM.
4010 Include ../config/acx.m4 and use ACX_NONCANONICAL_* where appropriate;
4011 replace uses of *_alias with *_noncanonical.
4012 * aclocal.m4: Rebuild with aclocal 1.4p6.
4013 * Makefile.in: Rebuild with automake 1.4p6.
4014 * doc/Makefile.in: Rebuild with automake 1.4p6.
4015 * configure.in: Autoupdate with autoupdate 2.59.
4016 * config.in: Regenerate with autoheader 2.59.
4017 * configure: Regnerate with autoconf 2.59.
4019 2004-08-28 Alan Modra <amodra@bigpond.net.au>
4021 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Copy input
4022 symbol pointer arrays before modifying.
4024 2004-08-28 Alan Modra <amodra@bigpond.net.au>
4026 * bfd.c (bfd_get_synthetic_symtab): Pass counts and both symbol tables.
4027 * elf-bfd.h (_bfd_elf_get_synthetic_symtab): Adjust.
4028 * elf.c (_bfd_elf_get_synthetic_symtab): Adjust.
4029 * libbfd-in.h (_bfd_nodynamic_get_synthetic_symtab): Adjust.
4030 * targets.c (struct bfd_target <_bfd_get_synthetic_symtab>): Adjust.
4031 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Don't read symbols.
4032 Use both symbol tables on non-relocatable objects. Use a common
4033 error exit. Fix "mid" warning.
4034 * libbfd.h: Regenerate.
4035 * bfd-in2.h: Regenerate.
4037 2004-08-28 Alan Modra <amodra@bigpond.net.au>
4039 * elf64-ppc.c (ppc64_elf_branch_reloc): Check .opd is in a regular
4041 (struct sfpr_def_parms): Save some space.
4042 (sfpr_define): Here too.
4044 * elf64-ppc.c (compare_symbols): Put section syms first.
4045 (sym_exists_at): New function.
4046 (ppc64_elf_get_synthetic_symtab): Use relocs to find code entry
4047 points only for relocatable files. Use .opd section contents
4048 otherwise. Generally clean up the code.
4050 2004-08-27 Alan Modra <amodra@bigpond.net.au>
4052 * elf64-ppc.c (STD_R0_0R1, STD_R0_0R12, LD_R0_0R1, LD_R0_0R12,
4053 LI_R12_0, STVX_VR0_R12_R0, LVX_VR0_R12_R0, MTLR_R0, SFPR_MAX): Define.
4054 (struct sfpr_def_parms): New.
4055 (sfpr_define): New function.
4056 (savegpr0, savegpr0_tail, restgpr0, restgpr0_tail): New functions.
4057 (savegpr1, savegpr1_tail, restgpr1, restgpr1_tail): New functions.
4058 (savefpr, savefpr0_tail, restfpr, restfpr0_tail): New functions.
4059 (savefpr1_tail, restfpr1_tail): New functions.
4060 (savevr, savevr_tail, restvr, restvr_tail): New functions.
4061 (MIN_SAVE_FPR, MAX_SAVE_FPR): Don't define.
4062 (ppc64_elf_func_desc_adjust): Use sfpr_define in place of existing
4063 code. Define all ABI mandated _save and _rest functions.
4065 2004-08-26 Paul Brook <paul@codesourcery.com>
4067 * elf32-arm.h (INTERWORK_FLAG): Return true for EABIv3 objects.
4069 2004-08-26 Alan Modra <amodra@bigpond.net.au>
4071 * elf32-m32r.c (m32r_elf_relocate_section): Don't compare with
4074 2004-08-26 Alan Modra <amodra@bigpond.net.au>
4076 * elf32-i386.c (elf_i386_relocate_section): Tweak last change so
4077 that pcrel correction is applied for R_386_PC32.
4079 2004-08-25 Alan Modra <amodra@bigpond.net.au>
4081 * elf32-i386.c (elf_i386_relocate_section): Zero section contents
4082 for R_386_32 and R_386_PC32 relocs against symbols defined in
4085 2004-08-25 Dmitry Diky <diwil@spec.ru>
4087 * reloc.c (BFD_RELOC_MSP430_2X_PCREL,BFD_RELOC_MSP430_RL_PCREL):
4088 Add new relocations.
4089 * bfd-in2.h: Regenerate.
4090 * libbfd.h: Regenerate.
4091 * elf32-msp430.c: Clean-up code.
4092 (elf_msp430_howto_table): Add new relocation entries.
4093 (bfd_elf32_bfd_reloc_type_lookup): New relocation handlers.
4094 (msp430_elf_relax_section): New function.
4095 (msp430_elf_relax_delete_bytes): New function.
4096 (msp430_elf_symbol_address_p): New function.
4098 2004-08-24 Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
4100 * elf32-m32r.c (m32r_elf_relocate_section): Handle
4101 R_M32R_SDA16_RELA in the same way as R_M32R_SDA16.
4103 2004-08-20 Daniel Jacobowitz <dan@debian.org>
4105 * elflink.c (_bfd_elf_section_already_linked): Handle
4106 SEC_LINK_DUPLICATES_SAME_CONTENTS.
4108 2004-08-19 Mark Mitchell <mark@codesourcery.com>
4110 * config.bfd (arm*-*-symbianelf*): New target.
4111 (arm*-*-eabi*): Likewise.
4113 2004-08-19 Alan Modra <amodra@bigpond.net.au>
4115 * elf64-ppc.c (ppc_get_stub_entry): Change third param to a
4116 "struct ppc_link_hash_entry *".
4117 (ppc64_elf_relocate_section): Ditto for type of h. Introduce h_elf
4118 to satisfy RELOC_FOR_GLOBAL_SYMBOL.
4120 2004-08-19 Jakub Jelinek <jakub@redhat.com>
4122 * elf64-ppc.c (ppc64_elf_edit_opd): Support 16 byte long .opd
4123 entries (where fd_aux overlaps next entry's fd_func).
4124 Add non_overlapping argument, use it.
4125 (ppc64_elf_check_relocs, ppc64_elf_gc_mark_hook, adjust_opd_syms,
4126 ppc64_elf_size_stubs, ppc64_elf_relocate_section,
4127 ppc64_elf_output_symbol_hook): Use address / 8 instead of address / 24
4128 as indexes into opd_sym_map/opd_adjust array.
4129 * elf64-ppc.h (ppc64_elf_edit_opd): Adjust prototype.
4131 2004-08-18 Alan Modra <amodra@bigpond.net.au>
4133 * elf64-ppc.c (func_desc_adjust): Give undefined dot-symbols a value
4134 if we can look up their function descriptor in a regular file.
4136 2004-08-18 Nick Clifton <nickc@redhat.com>
4139 * cofflink.c (coff_link_add_symbols): Check that the comdat
4140 pointer in the coff_section_data structure has been initialised
4143 2004-08-18 Alan Modra <amodra@bigpond.net.au>
4146 * elflink.c (bfd_elf_record_link_assignment): Add comment about
4147 changing bfd_link_hash_undefined to bfd_link_hash_new.
4149 2004-08-17 Jakub Jelinek <jakub@redhat.com>
4151 * elfxx-target.h (bfd_elfNN_get_synthetic_symtab): Only define
4153 * elf64-ppc.c (bfd_elf64_get_synthetic_symtab): Define.
4154 (synthetic_opd, synthetic_relocatable): New variables.
4155 (compare_symbols, compare_relocs): New helper routines.
4156 (ppc64_elf_get_synthetic_symtab): New function.
4157 * bfd.c (bfd_get_synthetic_symtab): Rename dynsyms argument
4159 * bfd-in2.h: Regenerated.
4160 * elf.c (_bfd_elf_get_synthetic_symtab): Rename dynsyms argument
4161 to relsyms. Return 0 if abfd is relocatable.
4163 2004-08-17 Alan Modra <amodra@bigpond.net.au>
4165 * elflink.h (elf_gc_sweep): Keep non-alloc, non-load sections.
4167 2004-08-17 Nick Clifton <nickc@redhat.com>
4169 * (is_arm_mapping_symbol_name): New function - return true
4170 when a symbol name matches the requirements for an ARM mapping
4172 (arm_elf_find_function): New function based on
4173 elf_find_function in elf.c but skipping ARM mapping symbols
4174 and including thumb function symbols.
4175 (elf32_arm_find_nearest_line): Use arm_elf_find_function.
4176 (elf32_arm_output_symbol_hook): Use is_arm_mapping_symbol_name.
4178 2004-08-17 Alan Modra <amodra@bigpond.net.au>
4180 * elf64-ppc.c (ppc64_elf_branch_reloc): New function.
4181 (ppc64_elf_howto_raw): Use ppc64_elf_branch_reloc.
4182 (ppc64_elf_brtaken_reloc): Here too.
4184 2004-08-17 Alan Modra <amodra@bigpond.net.au>
4186 * elf64-ppc.c (add_symbol_adjust): Correct mismatched function
4188 (ppc64_elf_check_directives): Check that we have the right hash
4189 table before proceeding.
4191 2004-08-17 Alan Modra <amodra@bigpond.net.au>
4193 * elf64-ppc.c (struct ppc64_elf_obj_tdata): Add "deleted_section".
4194 (adjust_opd_syms): Attach opd syms for deleted entries to one of
4195 the sections that will be discarded.
4197 2004-08-16 Alan Modra <amodra@bigpond.net.au>
4199 * elflink.c (elf_section_complain_discarded): Ignore .fixup.
4201 2004-08-16 Alan Modra <amodra@bigpond.net.au>
4203 * bfd.c (_bfd_default_error_handler): Account for doubled '%' in
4204 free space available.
4206 2004-08-16 Alan Modra <amodra@bigpond.net.au>
4208 * pdp11.c (struct pdp11_aout_reloc_external): Delete. Replace
4209 occurrences with bfd_byte * thoughout file.
4211 * coff-rs6000.c (do_shared_object_padding): Warning fix.
4212 (xcoff_write_armap_big): Likewise.
4213 (xcoff_write_archive_contents_old): Likewise.
4214 (xcoff_write_archive_contents_big): Likewise.
4216 * elf64-mmix.c (mmix_elf_get_section_contents): Delete declaration.
4218 2004-08-13 Nick Clifton <nickc@redhat.com>
4220 * elf32-arm.h: Convert to ISO C90.
4222 2004-08-13 Alan Modra <amodra@bigpond.net.au>
4225 * elf32-hppa.c (elf32_hppa_hide_symbol): Use init_refcount to
4228 2004-08-13 Alan Modra <amodra@bigpond.net.au>
4230 * bfd.c (_bfd_default_error_handler): Handle %A and %B.
4231 (bfd_archive_filename, bfd_get_section_ident): Delete.
4232 * ecofflink.c (bfd_ecoff_debug_accumulate_other): Don't call
4233 bfd_archive_filename.
4234 * elflink.c (elf_link_input_bfd): Don't use callbacks->error_handler
4235 to warn about symbols in discarded sections. Use _bfd_error_handler.
4236 * aout-adobe.c (aout_adobe_callback): See below.
4237 * aout-cris.c (swap_ext_reloc_in): ..
4238 * coff-arm.c (find_thumb_glue, find_arm_glue,
4239 coff_arm_relocate_section, bfd_arm_process_before_allocation,
4240 coff_arm_merge_private_bfd_data, _bfd_coff_arm_set_private_flags,
4241 coff_arm_copy_private_bfd_data): ..
4242 * coff-i860.c (i860_reloc_processing): ..
4243 * coff-mcore.c (mcore_coff_unsupported_reloc,
4244 coff_mcore_relocate_section): ..
4245 * coff-ppc.c (coff_ppc_relocate_section): ..
4246 * coff-rs6000.c (xcoff_create_csect_from_smclas
4247 * coff-sh.c (sh_relax_section, sh_relax_delete_bytes,
4248 sh_swap_insns, sh_relocate_section): ..
4249 * coff-tic54x.c (tic54x_reloc_processing): ..
4250 * coff-tic80.c (coff_tic80_relocate_section): ..
4251 * coff64-rs6000.c (xcoff64_create_csect_from_smclas): ..
4252 * coffcode.h (styp_to_sec_flags, coff_slurp_line_table,
4253 coff_slurp_symbol_table, coff_classify_symbol,
4254 coff_slurp_reloc_table): ..
4255 * coffgen.c (_bfd_coff_read_string_table): ..
4256 * cofflink.c (coff_link_add_symbols, _bfd_coff_link_input_bfd,
4257 _bfd_coff_generic_relocate_section): ..
4258 * cpu-arm.c (bfd_arm_merge_machines): ..
4259 * cpu-sh.c (sh_merge_bfd_arch): ..
4260 * elf-hppa.h (elf_hppa_relocate_section): ..
4261 * elf.c (bfd_elf_string_from_elf_section, setup_group,
4262 _bfd_elf_setup_group_pointers, bfd_section_from_shdr,
4263 assign_section_numbers, _bfd_elf_symbol_from_bfd_symbol,
4264 copy_private_bfd_data, _bfd_elf_validate_reloc): ..
4265 * elf32-arm.h (find_thumb_glue, find_arm_glue,
4266 bfd_elf32_arm_process_before_allocation, elf32_thumb_to_arm_stub,
4267 elf32_arm_to_thumb_stub, elf32_arm_final_link_relocate,
4268 elf32_arm_relocate_section, elf32_arm_set_private_flags,
4269 elf32_arm_copy_private_bfd_data, elf32_arm_merge_private_bfd_data): ..
4270 * elf32-cris.c (cris_elf_relocate_section, cris_elf_check_relocs,
4271 cris_elf_merge_private_bfd_data
4272 * elf32-frv.c (elf32_frv_relocate_section, elf32_frv_check_relocs): ..
4273 * elf32-gen.c (elf32_generic_link_add_symbols): ..
4274 * elf32-hppa.c (hppa_add_stub, hppa_build_one_stub,
4275 elf32_hppa_check_relocs, get_local_syms, final_link_relocate,
4276 elf32_hppa_relocate_section): ..
4277 * elf32-i370.c (i370_elf_merge_private_bfd_data,
4278 i370_elf_check_relocs, i370_elf_relocate_section): ..
4279 * elf32-i386.c (elf_i386_info_to_howto_rel, elf_i386_check_relocs,
4280 elf_i386_relocate_section): ..
4281 * elf32-m32r.c (m32r_elf_relocate_section,
4282 m32r_elf_merge_private_bfd_data): ..
4283 * elf32-m68hc1x.c (m68hc12_add_stub,
4284 _bfd_m68hc11_elf_merge_private_bfd_data): ..
4285 * elf32-m68k.c (elf_m68k_relocate_section): ..
4286 * elf32-mcore.c (mcore_elf_unsupported_reloc,
4287 mcore_elf_relocate_section): ..
4288 * elf32-ppc.c (ppc_elf_merge_private_bfd_data, bad_shared_reloc,
4289 ppc_elf_check_relocs, ppc_elf_relocate_section,
4290 ppc_elf_begin_write_processing): ..
4291 * elf32-s390.c (elf_s390_check_relocs, invalid_tls_insn,
4292 elf_s390_relocate_section): ..
4293 * elf32-sh-symbian.c (sh_symbian_import_as,
4294 sh_symbian_process_embedded_commands,
4295 sh_symbian_relocate_section): ..
4296 * elf32-sh.c (sh_elf_relax_section, sh_elf_relax_delete_bytes,
4297 sh_elf_swap_insns, sh_elf_relocate_section, sh_elf_check_relocs,
4298 sh_elf_merge_private_data): ..
4299 * elf32-sparc.c (elf32_sparc_check_relocs,
4300 elf32_sparc_relocate_section,
4301 elf32_sparc_merge_private_bfd_data): ..
4302 * elf32-v850.c (v850_elf_check_relocs,
4303 v850_elf_merge_private_bfd_data): ..
4304 * elf32-xtensa.c (elf_xtensa_check_relocs,
4305 elf_xtensa_relocate_section, elf_xtensa_merge_private_bfd_data): ..
4306 * elf64-alpha.c (elf64_alpha_relax_with_lituse,
4307 elf64_alpha_relax_got_load, elf64_alpha_size_got_sections,
4308 elf64_alpha_relocate_section_r, elf64_alpha_relocate_section): ..
4309 * elf64-gen.c (elf64_generic_link_add_symbols): ..
4310 * elf64-ppc.c (ppc64_elf_merge_private_bfd_data, ppc_add_stub,
4311 ppc64_elf_check_relocs, ppc64_elf_edit_opd,
4312 ppc64_elf_relocate_section): ..
4313 * elf64-s390.c (elf_s390_check_relocs, invalid_tls_insn,
4314 elf_s390_relocate_section): ..
4315 * elf64-sh64.c (sh_elf64_relocate_section): ..
4316 * elf64-sparc.c (sparc64_elf_check_relocs,
4317 sparc64_elf_add_symbol_hook, sparc64_elf_relocate_section,
4318 sparc64_elf_merge_private_bfd_data): ..
4319 * elf64-x86-64.c (elf64_x86_64_check_relocs,
4320 elf64_x86_64_relocate_section): ..
4321 * elflink.c (_bfd_elf_add_default_symbol,
4322 _bfd_elf_link_assign_sym_version, elf_link_read_relocs_from_section,
4323 _bfd_elf_link_output_relocs, elf_link_add_object_symbols,
4324 bfd_elf_size_dynamic_sections, elf_link_output_extsym,
4325 elf_get_linked_section_vma, elf_fixup_link_order,
4326 bfd_elf_final_link, bfd_elf_gc_record_vtinherit,
4327 bfd_elf_gc_record_vtinherit, _bfd_elf_section_already_linked): ..
4328 * elfxx-ia64.c (elfNN_ia64_relax_section,
4329 elfNN_ia64_relocate_section, elfNN_ia64_merge_private_bfd_data): ..
4330 * elfxx-mips.c (mips_elf_perform_relocation,
4331 _bfd_mips_elf_check_relocs,
4332 _bfd_mips_elf_merge_private_bfd_data): ..
4333 * ieee.c (ieee_slurp_external_symbols): ..
4334 * ihex.c (ihex_bad_byte, ihex_scan, ihex_read_section): ..
4335 * libbfd.c (_bfd_generic_verify_endian_match): ..
4336 * linker.c (_bfd_generic_link_add_one_symbol,
4337 _bfd_generic_section_already_linked): ..
4338 * pdp11.c (translate_to_native_sym_flags): ..
4339 * pe-mips.c (coff_pe_mips_relocate_section): ..
4340 * peicode.h (pe_ILF_build_a_bfd): ..
4341 * srec.c (srec_bad_byte): ..
4342 * stabs.c (_bfd_link_section_stabs): ..
4343 * xcofflink.c (xcoff_link_add_symbols, xcoff_link_input_bfd): ..
4344 Replace all uses of bfd_archive_filename and bfd_get_section_ident
4345 with corresponding %B and %A in _bfd_error_handler format string.
4346 Replace occurrences of "fprintf (stderr," with _bfd_error_handler
4347 calls to use %A and %B. Fix "against symbol .. from section" and
4348 similar error messages. Combine multiple _bfd_error_handler calls
4349 where they were separated due to bfd_archive_filename deficiencies.
4350 * bfd-in2.h: Regenerate.
4352 2004-08-12 H.J. Lu <hongjiu.lu@intel.com>
4354 * elf32-i386.c (elf_i386_relocate_section): Report unrecognized
4357 2004-08-10 Alan Modra <amodra@bigpond.net.au>
4359 * elf64-ppc.c (struct ppc_link_hash_entry): Add was_undefined.
4360 (struct ppc_link_hash_table): Remove no_multi_toc, multi_toc_needed.
4361 Make emit_stub_syms, stub_error and has_14bit_branch bit-fields.
4363 (link_hash_newfunc): Init was_undefined.
4364 (add_symbol_adjust): Don't set undefined dot symbols to defweak;
4365 Use undefweak instead.
4366 (ppc64_elf_check_directives): Fix undefs chain.
4367 (ppc64_elf_next_toc_section): Remove no_multi_toc and multi_toc_needed
4369 (ppc64_elf_size_stubs): Adjust for add_symbol_adjust change.
4370 (undo_symbol_twiddle, ppc64_elf_restore_symbols): New functions.
4371 * elf64-ppc.h (ppc64_elf_restore_symbols): Declare.
4373 2004-08-09 Jakub Jelinek <jakub@redhat.com>
4375 * elf64-x86-64.c (elf64_x86_64_relocate_section): For -fno-pic
4376 error, test input_section flags rather than sec.
4378 2004-08-09 Alan Modra <amodra@bigpond.net.au>
4380 * elf-bfd.h (struct elf_backend_data): Add
4381 elf_backend_archive_symbol_lookup.
4382 (_bfd_elf_archive_symbol_lookup): Declare.
4383 * elflink.c (_bfd_elf_archive_symbol_lookup): New function..
4384 (elf_link_add_archive_symbols): ..extracted from here. Call the
4386 * elfxx-target.h (elf_backend_archive_symbol_lookup): Provide default.
4387 (elfNN_bed): Init new field.
4388 * elf64-ppc.c (elf_backend_check_directives): Define.
4389 (elf_backend_archive_symbol_lookup): Define.
4390 (struct ppc_link_hash_table): Add tls_get_add_fd. Make tls_get_add
4391 a ppc_link_hash_entry pointer.
4393 (ppc64_elf_archive_symbol_lookup, opd_entry_value): New functions.
4394 (add_symbol_adjust, ppc64_elf_check_directives): New functions.
4395 (ppc64_elf_check_relocs, ppc64_elf_gc_mark_hook, func_desc_adjust,
4396 ppc64_elf_adjust_dynamic_symbol, ppc64_elf_tls_setup,
4397 ppc64_elf_tls_optimize, allocate_dynrelocs, ppc_type_of_stub,
4398 ppc_build_one_stub, ppc64_elf_size_stubs, ppc64_elf_relocate_section,
4399 ppc64_elf_finish_dynamic_symbol): Handle branch relocs to function
4402 2004-08-09 Alan Modra <amodra@bigpond.net.au>
4404 * elf64-ppc.c (struct ppc_link_hash_entry): Expand adjust_done comment.
4405 (ppc64_elf_add_symbol_hook): Test for NULL section.
4406 (get_sym_h): Formatting.
4407 (ppc64_elf_size_stubs): Include reloc addend in value stored as
4410 * elf64-ppc.c (ppc64_elf_relocate_section): Combine handling of
4411 long branch stubs with code handling plt and r2off branch stubs.
4413 2004-08-09 Alan Modra <amodra@bigpond.net.au>
4415 * elf-bfd.h (_bfd_elf_gc_mark): Declare.
4416 * elflink.c (elf_link_input_bfd): Formatting.
4417 (_bfd_elf_gc_mark): Rename from elf_gc_mark and make global. Adjust
4419 * elf64-ppc.c (struct ppc_link_hash_entry): Remove is_entry.
4420 (link_hash_newfunc): Don't set it.
4421 (ppc64_elf_copy_indirect_symbol): Nor copy it.
4422 (ppc64_elf_mark_entry_syms): Delete.
4423 (ppc64_elf_gc_mark_hook): Mark entry syms here. Also mark opd
4424 sections. Use get_opd_info.
4425 * elf64-ppc.h (ppc64_elf_mark_entry_syms): Delete.
4427 2004-08-09 Alan Modra <amodra@bigpond.net.au>
4429 * elf64-ppc.c (adjust_opd_syms): Fix merge error.
4431 * elf64-ppc.c (struct ppc_link_hash_table): Remove have_undefweak.
4432 (func_desc_adjust): Don't set have_undefweak.
4433 (ppc64_elf_func_desc_adjust): Don't add an extr nop to sfpr.
4434 (ppc64_elf_relocate_section): NOP out calls to undefweak functions.
4436 * elf64-ppc.c (struct ppc_link_hash_entry): Make "oh" a
4437 "struct ppc_link_hash_entry *". Adjust all references.
4438 (ppc64_elf_hide_symbol): Correct a comment.
4440 * elf64-ppc.c (get_opd_info): New function.
4441 (adjust_opd_syms): Use get_opd_info. Define removed symbols as zero.
4442 (ppc64_elf_edit_opd): Use get_opd_info. Check that sym has a dot
4443 before calling get_fdh. Test fdh rather than h before dereferencing
4444 fdh. Mark removed symbols in opd_adjust.
4445 (ppc64_elf_tls_optimize): Don't bother with opd adjustment here.
4446 (ppc64_elf_relocate_section): Use get_opd_info, and handle removed
4448 (ppc64_elf_output_symbol_hook): Likewise.
4450 2004-08-06 Paul Brook <paul@codesourcery.com>
4452 * elfarm-nabi.c (elf32_arm_howto_table): Add new EABI relocations.
4453 (elf32_arm_reloc_map): Add BFD_RELOC_ARM_RELABS32,
4454 BFD_RELOC_ARM_ROSEGREL32 and BFD_RELOC_ARM_SBREL32.
4455 * reloc.c: Add BFD_RELOC_ARM_RELABS32, BFD_RELOC_ARM_ROSEGREL32
4456 and BFD_RELOC_ARM_SBREL32.
4457 * bfd-in2.h, bbfd.h: Regenerate.
4459 2004-08-01 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
4461 * elfxx-mips.c (mips_elf_calculate_relocation): Test only for
4462 the dynamic link symbol actually in use.
4464 2004-08-01 Stephane Carrez <stcarrez@nerim.fr>
4466 * elf32-m68hc1x.c (elf32_m68hc11_size_stubs): Handle bfd_link_hash_new
4468 2004-07-31 Joel Brobecker <brobecker@gnat.com>
4469 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
4471 * elfxx-mips.c (_bfd_mips_elf_symbol_processing): Handle
4472 SHN_MIPS_TEXT and SHN_MIPS_DATA.
4474 2004-07-30 H.J. Lu <hongjiu.lu@intel.com>
4475 Nick Clifton <nickc@redhat.com>
4478 * bfd.c (_bfd_default_error_handler): Make it global.
4480 * elf-bfd.h (elf_backend_data): Add link_order_error_handler.
4482 * elf.c (assign_section_numbers): Cope gracefully with sections
4483 which have SHF_LINK_ORDER set but no sh_link set up.
4484 * elflink.c (elf_get_linked_section_vma): Likewise.
4486 * elfxx-ia64.c (elf_backend_link_order_error_handler): New. Set
4489 * elfxx-target.h (elf_backend_link_order_error_handler): New.
4490 Set it to _bfd_default_error_handler.
4491 (elfNN_bed): Add elf_backend_link_order_error_handler.
4493 * libbfd-in.h (_bfd_default_error_handler): New.
4495 * libbfd.h: Regenerated.
4497 2004-07-30 Jakub Jelinek <jakub@redhat.com>
4499 * archures.c (bfd_mach_sparc_64bit_p): Define.
4500 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data): Use it.
4501 * bfd-in2.h: Rebuilt.
4503 2004-07-29 Alexandre Oliva <aoliva@redhat.com>
4505 Introduce SH2a support.
4506 2004-02-18 Corinna Vinschen <vinschen@redhat.com>
4507 * archures.c (bfd_mach_sh2a_nofpu): New.
4508 * bfd-in2.h: Rebuilt.
4509 * cpu-sh.c (SH2A_NOFPU_NEXT): New.
4510 (arch_info_struct): Add sh2a_nofpu.
4511 * elf32-sh.c (sh_elf_set_mach_from_flags): Handle sh2a_nofpu.
4512 2003-12-29 DJ Delorie <dj@redhat.com>
4513 * reloc.c: Add relocs for sh2a.
4514 * bfd-in2.h: Regenerate.
4515 * libbfd.hh: Regenerate.
4516 2003-12-01 Michael Snyder <msnyder@redhat.com>
4517 * archures.c (bfd_mach_sh2a): New.
4518 * bfd-in2.h: Rebuilt.
4519 * cpu-sh.c (SH_NEXT, SH2_NEXT, etc.): Change defines to enums.
4521 (arch_info_struct): Add sh2a.
4522 * elf32-sh.c (sh_elf_set_mach_from_flags): Handle sh2a.
4524 2004-07-28 Nick Clifton <nickc@redhat.com>
4525 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
4528 * som.c (setup_sections): Improve estimation of space sizes in
4529 relocatable objects.
4531 2004-07-27 Jason Thorpe <thorpej@wasabisystems.com>
4532 * config.bfd (hppa*-*-netbsd*): Set targ_defvec to
4533 bfd_elf32_hppa_nbsd_vec. Add bfd_elf32_hppa_linux_vec
4535 * configure.in (bfd_elf32_hppa_nbsd_vec): Add case.
4536 * configure: Regenerate.
4537 * elf32-hppa.c (elf32_hppa_object_p): Add "elf32-hppa-netbsd"
4538 case that accepts OSABI=NetBSD and OSABI=SysV.
4539 (elf32_hppa_set_gp): For "elf32-hppa-netbsd", set the GP to
4540 the base of .got or .data (if .got does not exist).
4541 (elf32_hppa_post_process_headers): For elf32-hppa-netbsd,
4543 (TARGET_BIG_SYM): Add bfd_elf32_hppa_nbsd_vec case.
4544 (TARGET_BIG_NAME): Add "elf32-hppa-netbsd" case.
4545 * targets.c (bfd_elf32_hppa_nbsd_vec): Add extern declaration.
4546 (_bfd_target_vector): Add bfd_elf32_hppa_nbsd_vec.
4548 2004-07-27 H.J. Lu <hongjiu.lu@intel.com>
4551 * elf-bfd.h (bfd_elf_section_data): Add sec_group.
4552 (elf_sec_group): Defined.
4553 (bfd_elf_match_symbols_in_sections): New prototype.
4554 (_bfd_elf_setup_group_pointers): Likewise.
4556 * elf.c (bfd_elf_discard_group): Abort.
4557 (bfd_elf_set_group_contents): Also include relocation sections.
4558 Remove zero-fill for ld -r.
4559 (_bfd_elf_setup_group_pointers): New function.
4560 (elf_sort_elf_symbol): Likewise.
4561 (elf_sym_name_compare): Likewise.
4562 (bfd_elf_match_symbols_in_sections): Likewise.
4564 * elfcode.h (elf_object_p): Call _bfd_elf_setup_group_pointers.
4566 * elflink.c (match_group_member): New.
4567 (elf_link_input_bfd): Check group member for discarded section.
4568 (try_match_symbols_in_sections): New function.
4569 (already_linked): Likewise.
4570 (_bfd_elf_section_already_linked): Support mixing comdat group
4571 and linkonce section.
4573 * libbfd-in.h (bfd_section_already_linked_table_traverse): New.
4574 * linker.c (bfd_section_already_linked_table_traverse): New.
4576 * libbfd.h: Regenerated.
4578 2004-07-27 Tomer Levi <Tomer.Levi@nsc.com>
4580 * reloc.c: Add BFD_RELOC_CRX_SWITCH8, BFD_RELOC_CRX_SWITCH16,
4581 BFD_RELOC_CRX_SWITCH32.
4582 * bfd-in2.h: Regenerate.
4583 * libbfd.h: Regenerate.
4584 * elf32-crx.c: Support relocation/relaxation of
4585 BFD_RELOC_CRX_SWITCH* types.
4587 2004-07-27 Alan Modra <amodra@bigpond.net.au>
4589 * elf64-ppc.c: Correct "Linker stubs" comment.
4591 2004-07-26 H.J. Lu <hongjiu.lu@intel.com>
4593 * elf-bfd.h (bfd_elf_section_data): Add a pointer for the
4595 (elf_linked_to_section): New.
4597 * elf.c (assign_section_numbers): Set up sh_link for
4600 * elfxx-ia64.c (elfNN_ia64_final_write_processing): Set sh_info
4601 to sh_link for SHT_IA_64_UNWIND sections.
4603 2004-07-22 H.J. Lu <hongjiu.lu@intel.com>
4605 * elflink.c (elf_fixup_link_order): Add _() to error message.
4607 2004-07-22 H.J. Lu <hongjiu.lu@intel.com>
4609 * elflink.c (elf_fixup_link_order): Issue a warning and flag
4612 2004-07-21 H.J. Lu <hongjiu.lu@intel.com>
4614 * aout-adobe.c (aout_32_section_already_linked): Defined.
4615 * aout-target.h (MY_section_already_linked): Likewise.
4616 * aout-tic30.c (MY_section_already_linked): Likewise.
4617 * binary.c (binary_section_already_linked): Likewise.
4618 * bout.c (b_out_section_already_linked): Likewise.
4619 * coff-alpha.c (_bfd_ecoff_section_already_linked): Likewise.
4620 * coff-mips.c (_bfd_ecoff_section_already_linked): Likewise.
4621 * coffcode.h (coff_section_already_linked): Likewise.
4622 * i386msdos.c (msdos_section_already_linked): Likewise.
4623 * i386os9k.c (os9k_section_already_linked): Likewise.
4624 * ieee.c (ieee_section_already_linked): Likewise.
4625 * ihex.c (ihex_section_already_linked): Likewise.
4626 * mach-o.c (bfd_mach_o_section_already_linked): Likewise.
4627 * mmo.c (mmo_section_already_linked): Likewise.
4628 * nlm-target.h (nlm_section_already_linked): Likewise.
4629 * oasys.c (oasys_section_already_linked): Likewise.
4630 * pef.c (bfd_pef_section_already_linked): Likewise.
4631 * ppcboot.c (ppcboot_section_already_linked): Likewise.
4632 * som.c (som_bfd_discard_group): Likewise.
4633 * srec.c (srec_section_already_linked): Likewise.
4634 * tekhex.c (tekhex_section_already_linked): Likewise.
4635 * versados.c (versados_section_already_linked): Likewise.
4636 * vms.c (vms_section_already_linked): Likewise.
4637 * coff-target.h (_bfd_xcoff_section_already_linked): Likewise.
4638 * xsym.c (bfd_sym_section_already_linked): Likewise.
4640 * bfd-in.h (bfd_section_already_linked_table_init): New.
4641 (bfd_section_already_linked_table_free): Likewise.
4643 * coff-rs6000.c (rs6000coff_vec): Add
4644 _bfd_generic_section_already_linked.
4645 (pmac_xcoff_vec): Likewise.
4646 * coff64-rs6000.c (rs6000coff64_vec): Likewise.
4647 (aix5coff64_vec): Likewise.
4649 * elf-bfd.h (_bfd_elf_section_already_linked): New prototype.
4650 * elflink.c (_bfd_elf_section_already_linked): New function.
4652 * elfxx-target.h (bfd_elfNN_section_already_linked): Defined.
4654 * libbfd-in.h (_bfd_nolink_section_already_linked): Defined.
4655 (_bfd_generic_section_already_linked): New.
4656 (bfd_section_already_linked_hash_entry): Likewise.
4657 (bfd_section_already_linked): Likewise.
4658 (bfd_section_already_linked_table_lookup): Likewise.
4659 (bfd_section_already_linked_table_insert): Likewise.
4661 * linker.c (bfd_section_already_linked): New.
4662 (_bfd_section_already_linked_table): Likewise.
4663 (bfd_section_already_linked_table_lookup): Likewise.
4664 (bfd_section_already_linked_table_insert): Likewise.
4665 (already_linked_newfunc): Likewise.
4666 (bfd_section_already_linked_table_init): Likewise.
4667 (bfd_section_already_linked_table_free): Likewise.
4668 (_bfd_generic_section_already_linked): Likewise.
4670 * section.c (bfd_section): Remove comdat.
4671 (bfd_comdat_info): Moved to ...
4672 * bfd-in.h (coff_comdat_info): Here.
4673 (bfd_coff_get_comdat_section): New.
4674 * coffgen.c (bfd_coff_get_comdat_section): Likewise.
4675 * libcoff-in.h (coff_section_tdata): Add comdat.
4676 * coffcode.h (handle_COMDAT): Updated.
4677 * cofflink.c (coff_link_add_symbols): Likewise.
4678 * ecoff.c (bfd_debug_section): Likewise.
4680 * targets.c (bfd_target): Add _section_already_linked.
4681 (BFD_JUMP_TABLE_LINK): Updated.
4683 * bfd-in2.h: Regenerated.
4684 * libbfd.h: Likewise.
4685 * libcoff.h: Likewise.
4687 2003-07-21 Paul Brook <paul@codesourcery.com>
4689 * elflink.c (elf_get_linked_section_vma, compare_link_order,
4690 elf_fixup_link_order): New functions.
4691 (bfd_elf_final_link): Call elf_fixup_link_order.
4693 2004-07-21 Alexandre Oliva <aoliva@redhat.com>
4695 * elf-bfd.h (ELF_COMMON_DEF_P): New.
4696 * elflink.c (_bfd_elf_symbol_refs_local_p): Use it to handle
4698 * elf-m10300.c: Use SYMBOL_REFERENCES_LOCAL instead of
4699 _bfd_elf_symbol_refs_local_p.
4700 * elf32-frv.c (FRVFDPIC_SYM_LOCAL): Remove hack for common
4703 2004-07-19 H.J. Lu <hongjiu.lu@intel.com>
4705 * bfd-in.h (dynamic_lib_link_class): Add DYN_NO_ADD_NEEDED and
4707 (bfd_elf_get_dyn_lib_class): New prototype.
4708 * elf.c (bfd_elf_get_dyn_lib_class): New function.
4710 * elflink.c (elf_link_add_object_symbols): Check DYN_AS_NEEDED,
4711 DYN_DT_NEEDED and DYN_NO_NEEDED bits to see if a DT_NEEDED
4712 entry is needed. Issue an error if a DT_NEEDED entry is needed
4713 for a file marked DYN_NO_NEEDED.
4714 (elf_link_check_versioned_symbol): Check the DYN_DT_NEEDED bit
4717 * bfd-in2.h: Regenerated.
4719 2004-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
4721 * elflink.c (elf_section_complain_discarded): Don't complain in
4724 2004-07-10 James E Wilson <wilson@specifixinc.com>
4726 * elfxx-ia64.c (elfNN_ia64_relax_ldxmov): Remove abfd parameter.
4727 (elfNN_ia64_install_value, elfNN_ia64_relax_brl): Likewise.
4728 (elfNN_ia64_relax_section, elfNN_ia64_relocate_section,
4729 elfNN_ia64_finish_dynamic_symbol, elfNN_ia64_finish_dynamic_sections):
4731 (elfNN_ia64_relax_brl): Change bfd_get_64 to bfd_getl64. Change
4732 bfd_put_64 to bfd_putl64.
4733 (elfNN_ia64_relax_ldxmov, elfNN_ia64_install_value): Likewise.
4735 2004-07-09 H.J. Lu <hongjiu.lu@intel.com>
4738 * elfxx-ia64.c (elfNN_ia64_relax_section): Only warn br in
4739 .init/.fini sections when trying to relax it.
4741 2004-07-09 Jie Zhang <zhangjie@magima.com.cn>
4743 * elf.c (assign_file_positions_for_segments): Make sure the
4744 .dynamic section is the first section in the PT_DYNAMIC segment.
4746 2004-07-09 Nick Clifton <nickc@redhat.com>
4748 * config.bfd: Change sh-sybmian-elf to sh-*-symbianelf.
4749 * elf32-sh-symbian.c: Rename the sh_find_elf_flags and
4750 sh_elf_get_flags_from_mach functions so that they do not conflict
4751 when this target is built with other sh-elf targets.
4752 * elf32-sh.c (sh_elf_get_flags_from_mach): Remove bogus
4753 suppression of this function.
4754 (sh_elf_find_flags): Likewise.
4756 2004-07-07 Tomer Levi <Tomer.Levi@nsc.com>
4758 * Makefile.am (ALL_MACHINES): Add cpu-crx.lo.
4759 (ALL_MACHINES_CFILES): Add cpu-crx.c.
4760 (BFD32_BACKENDS): Add elf32-crx.lo.
4761 (BFD32_BACKENDS_CFILES): Add elf32-crx.c.
4762 (cpu-crx.lo): New target.
4763 (elf32-crx.lo): New target.
4764 * Makefile.in: Regenerate.
4765 * archures.c (bfd_architecture): Add bfd_{arch,mach}_crx.
4766 (bfd_archures_list): Add bfd_crx_arch.
4767 * bfd-in2.h: Regenerate.
4768 * config.bfd: Handle crx-*-elf*, crx*.
4769 * configure.in: Handle bfd_elf32_crx_vec.
4770 * configure: Regenerate.
4771 * cpu-crx.c: New file.
4772 * elf32-crx.c: Likewise.
4773 * libbfd.h: Regenerate.
4774 * reloc.c: Add BFD_RELOC_CRX_REL4, BFD_RELOC_CRX_REL8,
4775 BFD_RELOC_CRX_REL8_CMP, BFD_RELOC_CRX_REL16, BFD_RELOC_CRX_REL24,
4776 BFD_RELOC_CRX_REL32, BFD_RELOC_CRX_REGREL12, BFD_RELOC_CRX_REGREL22,
4777 BFD_RELOC_CRX_REGREL28, BFD_RELOC_CRX_REGREL32, BFD_RELOC_CRX_ABS16,
4778 BFD_RELOC_CRX_ABS32, BFD_RELOC_CRX_NUM8, BFD_RELOC_CRX_NUM16,
4779 BFD_RELOC_CRX_NUM32, BFD_RELOC_CRX_IMM16 and BFD_RELOC_CRX_IMM32
4780 * targets.c (bfd_elf32_crx_vec): Declare.
4781 (bfd_target_vector): Add bfd_elf32_crx_vec.
4783 2004-07-06 Nick Clifton <nickc@redhat.com>
4785 * config.bfd: Add sh-symbian-elf target.
4786 * configure.in: Add bfd_elf32_shl_symbian_vec.
4787 * configure: Regenerate.
4788 * elf-bfd.h (struct elf_backend_data): Add new field
4790 * elflink.c (elf_link_add_object_symbols): Invoke the
4791 check_directives function, if defined.
4792 * elfxx-target.h: Provide a default, NULL definition for
4794 * targets.c: Add bfd_elf32_shl_symbian_vec.
4795 * elf32-sh.c (sh_elf_swap_insns): Protect against unnecessary
4797 (elf32_shlin_grok_prstatus, elf32_shlib_grok_psinfo,
4798 * sh_elf_get_flags_from_mach, sh_elf_find_flags): Likewise.
4799 (TARGET_BIG_SYM, TARGET_LITTLE_SYM): Only define if they have
4800 not already been defined.
4801 * elf32-sh64.c: Use SH_TARGET_ALREADY_DEFINED.
4802 * sh-symbian.c: New file. Provide functions to support the
4803 * sh-symbian-elf target.
4804 * Makefile.am: Add elf32-sh-symbian.c
4805 * Makefile.in: Regenerate.
4807 2004-07-05 Andrew Stubbs <andrew.stubbs@superh.com>
4809 * elf32-sh.c: Include ../opcodes/sh-opc.h.
4810 * Makefile.am: Ran make dep-am.
4811 * Makefile.in: Ran make dep-in.
4813 2004-07-03 Aaron W. LaFramboise <aaron98wiridge9@aaronwl.com>
4815 * cofflink.c (_bfd_coff_generic_relocate_section): Resolve PE weak
4818 2004-07-02 Martin Schwidefsky <schwidefsky@de.ibm.com>
4820 * config.bfd: Add want64 to configuration target s390-*-linux*.
4822 2004-07-01 H.J. Lu <hongjiu.lu@intel.com>
4824 * bfd.c (bfd_get_section_ident): New.
4826 * elflink.c (elf_link_read_relocs_from_section): Call
4827 bfd_get_section_ident to identify the section when reporting
4829 (_bfd_elf_link_output_relocs): Likewise.
4830 (elf_link_output_extsym): Likewise.
4831 (elf_link_input_bfd): Likewise.
4832 (bfd_elf_gc_record_vtinherit): Likewise.
4834 * bfd-in2.h: Regenerated.
4836 2004-07-01 Jie Zhang <zhangjie@magima.com.cn>
4837 Nick Clifton <nickc@redhat.com>
4840 * elfxx-mips.c (_bfd_mips_elf_final_link): Pass the correct number
4841 of section symbols to mips_elf_sort_hash_table ().
4843 2004-07-01 Alan Modra <amodra@bigpond.net.au>
4845 * elflink.c (elf_section_ignore_discarded_relocs): Revert last
4847 (elf_section_complain_discarded): New function. Handle
4848 .gcc_except_table too.
4849 (elf_link_input_bfd): Rewrite handling of relocs against symbols
4850 in discarded sections.
4851 * elf-bfd.h (elf_discarded_section): Protect macro arg.
4853 2004-06-30 James E Wilson <wilson@specifixinc.com>
4855 * elfxx-ia64.c (elfNN_ia64_check_relocs): New local pltoff. Initialize
4856 to NULL. Call get_pltoff if NULL and NEED_PLTOFF is true.
4858 2004-06-30 H.J. Lu <hongjiu.lu@intel.com>
4861 * elflink.c (elf_link_input_bfd): Issue an error for non-debug
4862 local references to discarded sections and report their
4865 2004-06-30 Alan Modra <amodra@bigpond.net.au>
4867 * elflink.c (elf_section_ignore_discarded_relocs): Don't test
4868 sec_info_type, test section name instead.
4870 2004-06-29 H.J. Lu <hongjiu.lu@intel.com>
4873 * elfxx-ia64.c (elfNN_ia64_relax_section): Don't relax branch
4874 in .init/.fini sections.
4876 2004-06-29 Bob Wilson <bob.wilson@acm.org>
4878 * elf32-xtensa.c (elf_xtensa_relocate_section): Use
4879 bfd_get_section_limit.
4881 2004-06-29 Bob Wilson <bob.wilson@acm.org>
4883 * elf32-xtensa.c (elf_xtensa_combine_prop_entries): Don't change the
4884 output section size.
4886 2004-06-29 Alan Modra <amodra@bigpond.net.au>
4888 * elf64-mmix.c (mmix_set_relaxable_size): Save original size in
4890 (mmix_elf_perform_relocation): Adjust for above change.
4891 (mmix_elf_relocate_section): Likewise.
4892 (mmix_elf_relax_section): Likewise. Use output_section->rawsize.
4893 (mmix_elf_get_section_contents): Delete.
4894 (bfd_elf64_get_section_contents): Delete.
4895 (mmix_elf_relocate_section): Zero stub area.
4896 * linker.c (default_indirect_link_order): Alloc max of section size
4898 * simple.c (bfd_simple_get_relocated_section_contents): Likewise.
4899 * section.c (bfd_malloc_and_get_section): Likewise.
4900 (struct bfd_section): Update rawsize comment.
4901 * bfd-in2.h: Regenerate.
4903 * reloc16.c (bfd_coff_reloc16_relax_section): Set rawsize.
4905 2004-06-29 Alan Modra <amodra@bigpond.net.au>
4907 * bfd-in.h (bfd_get_section_limit): Define.
4908 * reloc.c (bfd_perform_relocation, bfd_install_relocation)
4909 (_bfd_final_link_relocate): Use bfd_get_section_limit.
4910 * aout-tic30.c (tic30_aout_final_link_relocate): Likewise.
4911 * coff-arm.c (coff_arm_relocate_section): Likewise.
4912 * coff-mips.c (mips_refhi_reloc, mips_gprel_reloc): Likewise.
4913 * cpu-ns32k.c (do_ns32k_reloc): Likewise.
4914 (bfd_ns32k_final_link_relocate): Likewise.
4915 * elf32-d30v.c (bfd_elf_d30v_reloc, bfd_elf_d30v_reloc_21): Likwise.
4916 * elf32-dlx.c (_bfd_dlx_elf_hi16_reloc): Likewise.
4917 * elf32-i860.c (i860_howto_pc26_reloc, i860_howto_pc16_reloc)
4918 (i860_howto_highadj_reloc, i860_howto_splitn_reloc): Likewise.
4919 * elf32-m32r.c (m32r_elf_do_10_pcrel_reloc, m32r_elf_hi16_reloc)
4920 (m32r_elf_generic_reloc, m32r_elf_relocate_section): Likewise.
4921 * elf32-m68hc1x.c (m68hc11_elf_special_reloc): Likewise.
4922 * elf32-mips.c (gprel32_with_gp, mips16_gprel_reloc): Likewise.
4923 * elf32-or32.c (or32_elf_consth_reloc): Likewise.
4924 * elf32-ppc.c (ppc_elf_addr16_ha_reloc): Likewise.
4925 * elf32-s390.c (s390_elf_ldisp_reloc): Likewise.
4926 * elf32-sh.c (sh_elf_reloc_loop): Likewise.
4927 * elf32-sparc.c (sparc_elf_wdisp16_reloc): Likewise.
4928 (sparc_elf_hix22_reloc, sparc_elf_lox10_reloc): Likwise.
4929 * elf32-v850.c (v850_elf_reloc): Likewise.
4930 * elf32-xstormy16.c (xstormy16_elf_24_reloc): Likewise.
4931 * elf32-xtensa.c (bfd_elf_xtensa_reloc): Likewise.
4932 * elf64-alpha.c (elf64_alpha_reloc_gpdisp): Likewise.
4933 * elf64-mips.c (mips_elf64_gprel32_reloc)
4934 (mips16_gprel_reloc): Likewise.
4935 * elf64-mmix.c (mmix_elf_reloc): Likewise.
4936 * elf64-s390.c (s390_elf_ldisp_reloc): Likewise.
4937 * elf64-sparc.c (init_insn_reloc): Likewise.
4938 * elfn32-mips.c (gprel32_with_gp, mips16_gprel_reloc): Likewise.
4939 * elfxx-mips.c (_bfd_mips_elf_gprel16_with_gp)
4940 (_bfd_mips_elf_hi16_reloc, _bfd_mips_elf_lo16_reloc)
4941 (_bfd_mips_elf_generic_reloc): Likewise.
4942 * bfd-in2.h: Regenerate.
4944 2004-06-28 Alan Modra <amodra@bigpond.net.au>
4946 * bfd-in.h (struct stab_info): Move from stabs.c.
4947 * stabs.c (struct stab_link_includes_table): Delete.
4948 (stab_link_includes_lookup): Delete.
4949 (_bfd_write_section_stabs, _bfd_write_stab_strings): Remove one
4950 level of indirection from sinfo parm.
4951 (_bfd_link_section_stabs): Likewise. Set SEC_LINKER_CREATED on
4952 stabstr section. Adjust hash table accesses.
4953 * coff-ppc.c (ppc_bfd_coff_final_link): Do include rawsize in contents
4954 alloc. Adjust stab_info test.
4955 * cofflink.c (_bfd_coff_link_hash_table_init): Clear stab_info.
4956 (_bfd_coff_final_link): Adjust stab_info test.
4957 (_bfd_coff_link_input_bfd): Ignore SEC_LINKER_CREATED sections.
4958 * elf-bfd.h (struct elf_link_hash_table): Include struct stab_info
4960 * libcoff-in.h (struct coff_link_hash_table): Likewise.
4961 * elf.c (_bfd_elf_link_hash_table_init): Clear stab_info.
4962 * elflink.c (bfd_elf_final_link): Don't attempt to link linker created
4963 stabstr section. Adjust stab_info test.
4964 * libbfd-in.h (_bfd_link_section_stabs, _bfd_write_section_stabs)
4965 (_bfd_write_stab_strings): Adjust prototypes.
4966 * libbfd.h: Regenerate.
4967 * libcoff.h: Regenerate.
4968 * bfd-in2.h: Regenerate.
4970 2004-06-27 Mark Kettenis <kettenis@gnu.org>
4972 From Miod Vallat <miod@online.fr>:
4973 * aoutx.h (NAME(aout,machine_type)): Handle bfd_arch_m88k.
4975 2004-06-26 Alexandre Oliva <aoliva@redhat.com>
4977 * elf-m10300.c (struct elf_mn10300_pcrel_relocs_copied): Delete.
4978 (struct elf32_mn10300_link_hash_entry): Remove
4979 pcrel_relocs_copied.
4980 (mn10300_elf_check_relocs): Only reserve dynamic relocations for
4981 R_MN10300_32. Don't adjust pcrel_relocs_copied.
4982 (mn10300_elf_final_link_relocate): Fail for direct, pc-relative
4983 and gotoff relocations if the symbol doesn't bind locally. Use
4984 _bfd_elf_symbol_refs_local_p to test. Don't create dynamic
4985 relocation for PCREL32.
4986 (mn10300_elf_relocate_section): Use _bfd_elf_symbol_refs_local_p
4987 to test whether a symbol binds locally.
4988 (elf32_mn10300_link_hash_newfunc): Don't initialize
4989 pcrel_relocs_copied.
4990 (_bfd_mn10300_elf_discard_copies): Delete.
4991 (_bfd_mn10300_elf_size_dynamic_sections): Don't call it.
4993 2004-06-26 Mark Kettenis <kettenis@gnu.org>
4995 * config.bfd: Replace m88k-*-openbsd* with m88*-*-openbsd*.
4997 2004-06-25 Joel Brobecker <brobecker@gnat.com>
4999 * som.c (som_set_reloc_info): Correct small typo.
5001 2004-06-25 Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
5003 * elf32-m32r.c (m32r_elf_howto_table): Support R_M32R_GOTOFF.
5004 (m32r_elf_relocate_section): Changed for R_M32R_GOTOFF.
5005 (m32r_elf_gcsweep_hook): Likewise.
5006 (m32r_elf_check_relocs): Likewise.
5007 (m32r_elf_howto_table): Added R_M32R_GOTOFF_HI_ULO,
5008 R_M32R_GOTOFF_HI_SLO and R_M32R_GOTOFF_LO.
5009 * reloc.c: Added BFD_RELOC_M32R_GOTOFF_HI_ULO,
5010 BFD_RELOC_M32R_GOTOFF_HI_SLO and BFD_RELOC_M32R_GOTOFF_LO.
5011 * bfd-in2.h: Regenerated.
5012 * libbfd.h: Regenerated.
5014 2004-06-24 H.J. Lu <hongjiu.lu@intel.com>
5016 * elf64-x86-64.c (elf64_x86_64_check_relocs): Warn overflow
5018 (elf64_x86_64_relocate_section): Issue an error for
5019 R_X86_64_PC8, R_X86_64_PC16 and R_X86_64_PC32 relocations
5020 against global symbols when building shared library.
5022 2004-06-24 Alan Modra <amodra@bigpond.net.au>
5024 * section.c (struct sec): Rename "_cooked_size" to "size".
5025 Rename "_raw_size" to "rawsize".
5026 (STD_SECTION): Adjust comments.
5027 (bfd_set_section_size, bfd_get_section_contents): Use size.
5028 (bfd_malloc_and_get_section): New function.
5029 * bfd-in.h (bfd_section_size, bfd_get_section_size): Use size.
5030 * coff-sh.c (sh_relax_section): Alloc coff_section_data struct early.
5031 Correctly free reloc and contents memory.
5032 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Delete FIXME
5033 and fake CIE now that we can shink section size to zero.
5034 (_bfd_elf_write_section_eh_frame): Likewise..
5035 * elf32-ppc.c (ppc_elf_relax_section): Delay reading section contents.
5036 * elf-m10300.c (mn10300_elf_final_link_relocate): Don't use
5037 _bfd_stab_section_offset. Use _bfd_elf_section_offset.
5038 * stabs.c (_bfd_stab_section_offset_): Remove unused args and
5039 unneeded indirection.
5040 * elf.c (_bfd_elf_section_offset): .. and update call.
5041 * libbfd-in.h (_bfd_stab_section_offset): Update prototype.
5042 * libbfd.h: Regenerate.
5043 * bfd-in2.h: Regenerate.
5045 Replace occurrences of "_raw_size" and "_cooked_size" in most places
5046 with "size". Set new "rawsize" for stabs, eh_frame, and SEC_MERGE
5047 sections. Use "rawsize", if non-zero, for bfd_get_section_contents
5048 calls if the section might be a stabs, eh_frame, or SEC_MERGE section.
5049 Similarly use "rawsize", if non-zero, in reloc functions to validate
5050 reloc addresses. Use new bfd_malloc_and_get_section in most places
5051 where bfd_get_section_contents was called. Expand all occurrences of
5052 bfd_section_size and bfd_get_section_size. Rename "raw_size" var in
5053 grok_prstatus and similar functions to "size".
5054 * aix386-core.c (aix386_core_file_p): ..
5055 * aix5ppc-core.c (xcoff64_core_p): ..
5056 * aout-adobe.c (aout_adobe_callback, aout_adobe_write_object_contents,
5057 aout_adobe_set_section_contents): ..
5058 * aout-target.h (callback): ..
5059 * aout-tic30.c (tic30_aout_callback, tic30_aout_final_link_relocate,
5060 MY_bfd_final_link): ..
5061 * aoutf1.h (sunos4_core_file_p): ..
5062 * aoutx.h (some_aout_object_p, adjust_o_magic, adjust_z_magic,
5063 adjust_n_magic, adjust_sizes_and_vmas, translate_from_native_sym_flags,
5064 final_link, aout_link_input_section): ..
5065 * binary.c (binary_object_p, binary_canonicalize_symtab,
5066 binary_set_section_contents): ..
5067 * bout.c (b_out_callback, b_out_write_object_contents,
5068 b_out_set_section_contents, b_out_bfd_relax_section,
5069 b_out_bfd_get_relocated_section_contents): ..
5070 * cisco-core.c (cisco_core_file_validate): ..
5071 * coff-alpha.c (alpha_ecoff_object_p,
5072 alpha_ecoff_get_relocated_section_conten, alpha_relocate_section): ..
5073 * coff-arm.c (coff_arm_relocate_section,
5074 bfd_arm_allocate_interworking_sections): ..
5075 * coff-h8300.c (h8300_reloc16_extra_cases,
5076 h8300_bfd_link_add_symbols): ..
5077 * coff-mips.c (mips_refhi_reloc, mips_gprel_reloc): ..
5078 * coff-ppc.c (coff_ppc_relocate_section, ppc_allocate_toc_section,
5079 ppc_bfd_coff_final_link): ..
5080 * coff-rs6000.c (xcoff_reloc_type_br, xcoff_ppc_relocate_section): ..
5081 * coff-sh.c (sh_relax_section, sh_relax_delete_bytes,
5082 sh_align_loads, sh_coff_get_relocated_section_contents): ..
5083 * coff64-rs6000.c (xcoff64_write_object_contents,
5084 xcoff64_reloc_type_br, xcoff64_ppc_relocate_section): ..
5085 * coffcode.h (coff_compute_section_file_positions,
5086 coff_write_object_contents): ..
5087 * coffgen.c (make_a_section_from_file, coff_write_symbols,
5088 coff_section_symbol, build_debug_section): ..
5089 * cofflink.c (coff_link_add_symbols, _bfd_coff_final_link,
5090 process_embedded_commands, _bfd_coff_link_input_bfd,
5091 _bfd_coff_write_global_sym): ..
5092 * cpu-arm.c (bfd_arm_update_notes, bfd_arm_get_mach_from_notes): ..
5093 * cpu-ns32k.c (do_ns32k_reloc, _bfd_ns32k_final_link_relocate): ..
5094 * dwarf1.c (parse_line_table, _bfd_dwarf1_find_nearest_line): ..
5095 * dwarf2.c (read_indirect_string, read_abbrevs, decode_line_info,
5096 _bfd_dwarf2_find_nearest_line): ..
5097 * ecoff.c (bfd_debug_section, ecoff_set_symbol_info,
5098 ecoff_compute_section_file_positions,
5099 _bfd_ecoff_write_object_contents, ecoff_indirect_link_order): ..
5100 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame,
5101 _bfd_elf_discard_section_eh_frame_hdr,
5102 _bfd_elf_maybe_strip_eh_frame_hdr, _bfd_elf_eh_frame_section_offset,
5103 _bfd_elf_write_section_eh_frame,
5104 _bfd_elf_write_section_eh_frame_hdr): ..
5105 * elf-hppa.h (elf_hppa_sort_unwind): ..
5106 * elf-m10200.c (mn10200_elf_relax_section,
5107 mn10200_elf_relax_delete_bytes,
5108 mn10200_elf_get_relocated_section_contents): ..
5109 * elf-m10300.c (_bfd_mn10300_elf_create_got_section,
5110 mn10300_elf_check_relocs, mn10300_elf_relax_section,
5111 mn10300_elf_relax_delete_bytes,
5112 mn10300_elf_get_relocated_section_contents,
5113 _bfd_mn10300_elf_adjust_dynamic_symbol,
5114 _bfd_mn10300_elf_discard_copies,
5115 _bfd_mn10300_elf_size_dynamic_sections,
5116 _bfd_mn10300_elf_finish_dynamic_sections): ..
5117 * elf.c (_bfd_elf_print_private_bfd_data, bfd_elf_get_bfd_needed_list,
5118 _bfd_elf_make_section_from_phdr, elf_fake_sections,
5119 bfd_elf_set_group_contents, map_sections_to_segments,
5120 elf_sort_sections, assign_file_positions_for_segments,
5121 SECTION_SIZE, copy_private_bfd_data,
5122 _bfd_elf_get_dynamic_reloc_upper_bound,
5123 _bfd_elf_canonicalize_dynamic_reloc, elfcore_maybe_make_sect,
5124 _bfd_elfcore_make_pseudosection, elfcore_grok_prstatus,
5125 elfcore_grok_lwpstatus, elfcore_grok_win32pstatus,
5126 elfcore_grok_note, elfcore_grok_nto_status, elfcore_grok_nto_gregs,
5127 _bfd_elf_rel_local_sym, _bfd_elf_get_synthetic_symtab): ..
5128 * elf32-arm.h (bfd_elf32_arm_allocate_interworking_sect,
5129 bfd_elf32_arm_process_before_allocation,
5130 elf32_arm_adjust_dynamic_symbol, allocate_dynrelocs,
5131 elf32_arm_size_dynamic_sections, elf32_arm_finish_dynamic_sections,
5132 elf32_arm_write_section): ..
5133 * elf32-cris.c (cris_elf_grok_prstatus,
5134 elf_cris_finish_dynamic_sections, cris_elf_gc_sweep_hook,
5135 elf_cris_adjust_gotplt_to_got, elf_cris_adjust_dynamic_symbol,
5136 cris_elf_check_relocs, elf_cris_size_dynamic_sections,
5137 elf_cris_discard_excess_dso_dynamics,
5138 elf_cris_discard_excess_program_dynamics): ..
5139 * elf32-d30v.c (bfd_elf_d30v_reloc, bfd_elf_d30v_reloc_21): ..
5140 * elf32-dlx.c (_bfd_dlx_elf_hi16_reloc): ..
5141 * elf32-frv.c (_frvfdpic_add_dyn_reloc, _frvfdpic_add_rofixup,
5142 _frv_create_got_section, _frvfdpic_assign_plt_entries,
5143 elf32_frvfdpic_size_dynamic_sections,
5144 elf32_frvfdpic_modify_segment_map,
5145 elf32_frvfdpic_finish_dynamic_sections): ..
5146 * elf32-h8300.c (elf32_h8_relax_section, elf32_h8_relax_delete_bytes,
5147 elf32_h8_get_relocated_section_contents): ..
5148 * elf32-hppa.c (hppa_build_one_stub, hppa_size_one_stub,
5149 elf32_hppa_adjust_dynamic_symbol, allocate_plt_static,
5150 allocate_dynrelocs, elf32_hppa_size_dynamic_sections, group_sections,
5151 elf32_hppa_size_stubs, elf32_hppa_set_gp, elf32_hppa_build_stubs,
5152 elf32_hppa_finish_dynamic_sections): ..
5153 * elf32-i370.c (i370_elf_adjust_dynamic_symbol,
5154 i370_elf_size_dynamic_sections, i370_elf_check_relocs,
5155 i370_elf_finish_dynamic_sections): ..
5156 * elf32-i386.c (elf_i386_grok_prstatus, elf_i386_adjust_dynamic_symbol,
5157 allocate_dynrelocs, elf_i386_size_dynamic_sections,
5158 elf_i386_relocate_section, elf_i386_finish_dynamic_sections): ..
5159 * elf32-i860.c (i860_howto_pc26_reloc, i860_howto_pc16_reloc,
5160 i860_howto_highadj_reloc, i860_howto_splitn_reloc): ..
5161 * elf32-ip2k.c (ip2k_is_switch_table_128,
5162 ip2k_relax_switch_table_128, ip2k_is_switch_table_256,
5163 ip2k_relax_switch_table_256, ip2k_elf_relax_section,
5164 adjust_all_relocations, ip2k_elf_relax_delete_bytes): ..
5165 * elf32-m32r.c (m32r_elf_do_10_pcrel_reloc, m32r_elf_hi16_reloc,
5166 m32r_elf_generic_reloc, m32r_elf_adjust_dynamic_symbol,
5167 allocate_dynrelocs, m32r_elf_size_dynamic_sections,
5168 m32r_elf_relocate_section, m32r_elf_finish_dynamic_sections,
5169 m32r_elf_relax_section, m32r_elf_relax_delete_bytes,
5170 m32r_elf_get_relocated_section_contents): ..
5171 * elf32-m68hc11.c (m68hc11_elf_build_one_stub,
5172 m68hc11_elf_size_one_stub, m68hc11_elf_relax_section,
5173 m68hc11_elf_relax_delete_bytes): ..
5174 * elf32-m68hc12.c (m68hc12_elf_build_one_stub,
5175 m68hc12_elf_size_one_stub): ..
5176 * elf32-m68hc1x.c (elf32_m68hc11_size_stubs,
5177 elf32_m68hc11_build_stubs, m68hc11_elf_special_reloc): ..
5178 * elf32-m68k.c (elf_m68k_check_relocs, elf_m68k_gc_sweep_hook,
5179 elf_m68k_adjust_dynamic_symbol, elf_m68k_size_dynamic_sections,
5180 elf_m68k_discard_copies, elf_m68k_finish_dynamic_sections): ..
5181 * elf32-mips.c (gprel32_with_gp, mips16_gprel_reloc,
5182 elf32_mips_grok_prstatus): ..
5183 * elf32-or32.c (or32_elf_consth_reloc): ..
5184 * elf32-ppc.c (ppc_elf_relax_section, ppc_elf_addr16_ha_reloc,
5185 elf_create_pointer_linker_section, ppc_elf_create_linker_section,
5186 ppc_elf_additional_program_headers, ppc_elf_adjust_dynamic_symbol,
5187 allocate_dynrelocs, ppc_elf_size_dynamic_sections,
5188 ppc_elf_finish_dynamic_sections, ppc_elf_grok_prstatus,
5189 ppc_elf_final_write_processing): ..
5190 * elf32-s390.c (s390_elf_ldisp_reloc, elf_s390_adjust_dynamic_symbol,
5191 allocate_dynrelocs, elf_s390_size_dynamic_sections,
5192 elf_s390_finish_dynamic_sections, elf_s390_grok_prstatus): ..
5193 * elf32-sh.c (sh_elf_reloc_loop, sh_elf_relax_section,
5194 sh_elf_relax_delete_bytes, sh_elf_align_loads,
5195 sh_elf_adjust_dynamic_symbol, allocate_dynrelocs,
5196 sh_elf_size_dynamic_sections, sh_elf_get_relocated_section_contents,
5197 sh_elf_finish_dynamic_sections, elf32_shlin_grok_prstatus): ..
5198 * elf32-sh64-com.c (sh64_address_in_cranges,
5199 sh64_get_contents_type): ..
5200 * elf32-sh64.c (sh64_find_section_for_address,
5201 sh64_elf_final_write_processing): ..
5202 * elf32-sparc.c (sparc_elf_wdisp16_reloc, sparc_elf_hix22_reloc,
5203 sparc_elf_lox10_reloc, elf32_sparc_adjust_dynamic_symbol,
5204 allocate_dynrelocs, elf32_sparc_size_dynamic_sections,
5205 elf32_sparc_relocate_section, elf32_sparc_finish_dynamic_sections): ..
5206 * elf32-v850.c (v850_elf_reloc, v850_elf_relax_section): ..
5207 * elf32-vax.c (elf_vax_check_relocs, elf_vax_adjust_dynamic_symbol,
5208 elf_vax_size_dynamic_sections, elf_vax_discard_copies,
5209 elf_vax_instantiate_got_entries, elf_vax_relocate_section,
5210 elf_vax_finish_dynamic_sections): ..
5211 * elf32-xstormy16.c (xstormy16_elf_24_reloc,
5212 xstormy16_elf_check_relocs, xstormy16_relax_plt_check,
5213 xstormy16_elf_relax_section, xstormy16_elf_always_size_sections,
5214 xstormy16_elf_finish_dynamic_sections): ..
5215 * elf32-xtensa.c (xtensa_read_table_entries,
5216 elf_xtensa_allocate_got_size, elf_xtensa_allocate_local_got_size,
5217 elf_xtensa_size_dynamic_sections, elf_xtensa_do_reloc,
5218 bfd_elf_xtensa_reloc, elf_xtensa_relocate_section,
5219 elf_xtensa_combine_prop_entries, elf_xtensa_finish_dynamic_sections,
5220 elf_xtensa_discard_info_for_section, elf_xtensa_grok_prstatus,
5221 get_relocation_opcode, retrieve_contents, find_relaxable_sections,
5222 collect_source_relocs, is_resolvable_asm_expansion, remove_literals,
5223 relax_section, shrink_dynamic_reloc_sections, relax_property_section,
5224 xtensa_callback_required_dependence): ..
5225 * elf64-alpha.c (elf64_alpha_reloc_gpdisp, elf64_alpha_relax_section,
5226 elf64_alpha_check_relocs, elf64_alpha_adjust_dynamic_symbol,
5227 elf64_alpha_calc_got_offsets_for_symbol, elf64_alpha_calc_got_offsets,
5228 elf64_alpha_size_plt_section, elf64_alpha_size_plt_section_1,
5229 elf64_alpha_always_size_sections, elf64_alpha_calc_dynrel_sizes,
5230 elf64_alpha_size_rela_got_section, elf64_alpha_size_rela_got_1,
5231 elf64_alpha_size_dynamic_sections, elf64_alpha_emit_dynrel,
5232 elf64_alpha_finish_dynamic_sections, elf64_alpha_final_link): ..
5233 * elf64-hppa.c (allocate_dynrel_entries,
5234 elf64_hppa_size_dynamic_sections,
5235 elf64_hppa_finish_dynamic_sections): ..
5236 * elf64-mips.c (mips_elf64_gprel32_reloc, mips16_gprel_reloc,
5237 mips_elf64_canonicalize_dynamic_reloc, mips_elf64_slurp_reloc_table,
5238 elf64_mips_grok_prstatus): ..
5239 * elf64-mmix.c (mmix_elf_perform_relocation, mmix_elf_reloc,
5240 mmix_elf_relocate_section, mmix_elf_final_link,
5241 mmix_set_relaxable_size, _bfd_mmix_after_linker_allocation,
5242 mmix_elf_relax_section, mmix_elf_get_section_contents): ..
5243 * elf64-ppc.c (ppc64_elf_object_p, ppc64_elf_grok_prstatus,
5244 ppc64_elf_check_relocs, ppc64_elf_func_desc_adjust,
5245 ppc64_elf_adjust_dynamic_symbol, ppc64_elf_edit_opd,
5246 allocate_dynrelocs, ppc64_elf_size_dynamic_sections,
5247 ppc_build_one_stub, ppc_size_one_stub, ppc64_elf_next_toc_section,
5248 toc_adjusting_stub_needed, group_sections, ppc64_elf_size_stubs,
5249 ppc64_elf_build_stubs, ppc64_elf_relocate_section,
5250 ppc64_elf_finish_dynamic_sections): ..
5251 * elf64-s390.c (s390_elf_ldisp_reloc, elf_s390_adjust_dynamic_symbol,
5252 allocate_dynrelocs, elf_s390_size_dynamic_sections,
5253 elf_s390_finish_dynamic_sections): ..
5254 * elf64-sh64.c (sh_elf64_get_relocated_section_contents,
5255 sh_elf64_check_relocs, sh64_elf64_adjust_dynamic_symbol,
5256 sh64_elf64_discard_copies, sh64_elf64_size_dynamic_sections,
5257 sh64_elf64_finish_dynamic_sections): ..
5258 * elf64-sparc.c (sparc64_elf_slurp_reloc_table, init_insn_reloc,
5259 sparc64_elf_check_relocs, sparc64_elf_adjust_dynamic_symbol,
5260 sparc64_elf_size_dynamic_sections, sparc64_elf_relocate_section,
5261 sparc64_elf_finish_dynamic_symbol,
5262 sparc64_elf_finish_dynamic_sections): ..
5263 * elf64-x86-64.c (elf64_x86_64_grok_prstatus,
5264 elf64_x86_64_adjust_dynamic_symbol, allocate_dynrelocs,
5265 elf64_x86_64_size_dynamic_sections, elf64_x86_64_relocate_section,
5266 elf64_x86_64_finish_dynamic_sections): ..
5267 * elfarm-nabi.c (elf32_arm_nabi_grok_prstatus): ..
5268 * elfcode.h (elf_slurp_reloc_table): ..
5269 * elflink.c (_bfd_elf_create_got_section, elf_add_dt_needed_tag,
5270 elf_finalize_dynstr, elf_link_add_object_symbols,
5271 bfd_elf_size_dynamic_sections, elf_link_sort_relocs,
5272 elf_link_input_bfd, bfd_elf_final_link, bfd_elf_discard_info): ..
5273 * elfn32-mips.c (gprel32_with_gp, mips16_gprel_reloc,
5274 elf32_mips_grok_prstatus): ..
5275 * elfxx-ia64.c (elfNN_ia64_relax_section, allocate_dynrel_entries,
5276 elfNN_ia64_size_dynamic_sections, elfNN_ia64_install_dyn_reloc,
5277 elfNN_ia64_choose_gp, elfNN_ia64_final_link,
5278 elfNN_ia64_finish_dynamic_sections): ..
5279 * elfxx-mips.c (mips_elf_create_procedure_table,
5280 mips_elf_check_mips16_stubs, _bfd_mips_elf_gprel16_with_gp,
5281 _bfd_mips_elf_hi16_reloc, _bfd_mips_elf_generic_reloc,
5282 mips_elf_global_got_index, mips_elf_multi_got,
5283 mips_elf_create_compact_rel_section, mips_elf_calculate_relocation,
5284 mips_elf_allocate_dynamic_relocations,
5285 mips_elf_create_dynamic_relocation, _bfd_mips_elf_fake_sections,
5286 _bfd_mips_relax_section, _bfd_mips_elf_adjust_dynamic_symbol,
5287 _bfd_mips_elf_always_size_sections,
5288 _bfd_mips_elf_size_dynamic_sections,
5289 _bfd_mips_elf_finish_dynamic_symbol,
5290 _bfd_mips_elf_finish_dynamic_sections,
5291 _bfd_mips_elf_modify_segment_map, _bfd_mips_elf_discard_info,
5292 _bfd_mips_elf_write_section, _bfd_mips_elf_set_section_contents,
5293 _bfd_elf_mips_get_relocated_section_contents,
5294 _bfd_mips_elf_final_link, _bfd_mips_elf_merge_private_bfd_data): ..
5295 * hp300hpux.c (callback): ..
5296 * hppabsd-core.c (make_bfd_asection): ..
5297 * hpux-core.c (make_bfd_asection): ..
5298 * i386linux.c (linux_link_create_dynamic_sections,
5299 bfd_i386linux_size_dynamic_sections, linux_finish_dynamic_link): ..
5300 * i386msdos.c (msdos_write_object_contents): ..
5301 * i386os9k.c (os9k_callback, os9k_write_object_contents,
5302 os9k_set_section_contents): ..
5303 * ieee.c (parse_expression, ieee_slurp_external_symbols,
5304 ieee_slurp_sections, ieee_slurp_debug, ieee_slurp_section_data,
5305 ieee_write_section_part, do_with_relocs, do_as_repeat,
5306 do_without_relocs, ieee_write_debug_part, init_for_output,
5307 ieee_set_section_contents): ..
5308 * ihex.c (ihex_scan, ihex_read_section, ihex_get_section_contents): ..
5309 * irix-core.c (do_sections, make_bfd_asection): ..
5310 * libaout.h (aout_section_merge_with_text_p): ..
5311 * libbfd.c (_bfd_generic_get_section_contents,
5312 _bfd_generic_get_section_contents_in_window): ..
5313 * linker.c (default_indirect_link_order): ..
5314 * lynx-core.c (make_bfd_asection): ..
5315 * m68klinux.c (linux_link_create_dynamic_sections,
5316 bfd_m68klinux_size_dynamic_sections, linux_finish_dynamic_link): ..
5317 * mach-o.c (bfd_mach_o_make_bfd_section,
5318 bfd_mach_o_scan_read_dylinker, bfd_mach_o_scan_read_dylib,
5319 bfd_mach_o_scan_read_thread, bfd_mach_o_scan_read_symtab,
5320 bfd_mach_o_scan_read_segment): ..
5321 * merge.c (_bfd_add_merge_section, record_section, merge_strings,
5322 _bfd_merge_sections): ..
5323 * mmo.c (mmo_find_sec_w_addr, mmo_get_spec_section, mmo_get_loc,
5324 mmo_map_set_sizes, mmo_canonicalize_symtab,
5325 mmo_internal_write_section, mmo_write_object_contents): ..
5326 * netbsd-core.c (netbsd_core_file_p): ..
5327 * nlm32-alpha.c (nlm_alpha_read_reloc, nlm_alpha_write_import,
5328 nlm_alpha_set_public_section): ..
5329 * nlm32-ppc.c (nlm_powerpc_read_reloc, nlm_powerpc_write_reloc): ..
5330 * nlm32-sparc.c (nlm_sparc_write_import): ..
5331 * nlmcode.h (add_bfd_section, nlm_swap_auxiliary_headers_in,
5332 nlm_compute_section_file_positions): ..
5333 * oasys.c (oasys_object_p, oasys_slurp_section_data,
5334 oasys_write_sections, oasys_write_data, oasys_set_section_contents): ..
5335 * opncls.c (get_debug_link_info): ..
5336 * osf-core.c (make_bfd_asection): ..
5337 * pdp11.c (some_aout_object_p, adjust_o_magic, adjust_z_magic,
5338 adjust_n_magic, adjust_sizes_and_vmas, squirt_out_relocs,
5339 final_link, aout_link_input_section): ..
5340 * peXXigen.c (_bfd_XXi_swap_sym_in, _bfd_XXi_swap_aouthdr_out,
5341 pe_print_idata, pe_print_edata, pe_print_pdata, pe_print_reloc): ..
5342 * pef.c (bfd_pef_make_bfd_section, bfd_pef_print_loader_section,
5343 bfd_pef_scan_start_address, bfd_pef_parse_symbols): ..
5344 * ppcboot.c (ppcboot_object_p, ppcboot_canonicalize_symtab): ..
5345 * ptrace-core.c (ptrace_unix_core_file_p): ..
5346 * reloc.c (bfd_perform_relocation, bfd_install_relocation,
5347 _bfd_final_link_relocate, bfd_generic_relax_section,
5348 bfd_generic_get_relocated_section_contents): ..
5349 * reloc16.c (bfd_coff_reloc16_relax_section,
5350 bfd_coff_reloc16_get_relocated_section_c): ..
5351 * riscix.c (riscix_some_aout_object_p): ..
5352 * rs6000-core.c (read_hdr, make_bfd_asection): ..
5353 * sco5-core.c (make_bfd_asection): ..
5354 * simple.c (bfd_simple_get_relocated_section_contents): ..
5355 * som.c (som_object_setup, setup_sections, som_prep_headers,
5356 som_write_fixups, som_begin_writing, bfd_section_from_som_symbol,
5357 som_set_reloc_info, som_get_section_contents,
5358 som_bfd_link_split_section): ..
5359 * sparclinux.c (linux_link_create_dynamic_sections,
5360 bfd_sparclinux_size_dynamic_sections, linux_finish_dynamic_link): ..
5361 * srec.c (srec_scan, srec_read_section, srec_get_section_contents): ..
5362 * stabs.c (_bfd_link_section_stabs, _bfd_discard_section_stabs,
5363 _bfd_write_stab_strings, _bfd_stab_section_offset): ..
5364 * sunos.c (sunos_read_dynamic_info, sunos_create_dynamic_sections,
5365 bfd_sunos_size_dynamic_sections, sunos_scan_std_relocs,
5366 sunos_scan_ext_relocs, sunos_scan_dynamic_symbol,
5367 sunos_write_dynamic_symbol, sunos_check_dynamic_reloc,
5368 sunos_finish_dynamic_link): ..
5369 * syms.c (_bfd_stab_section_find_nearest_line): ..
5370 * tekhex.c (first_phase, tekhex_set_section_contents,
5371 tekhex_write_object_contents): ..
5372 * trad-core.c (trad_unix_core_file_p): ..
5373 * versados.c (process_esd, process_otr, process_otr): ..
5374 * vms-gsd.c (_bfd_vms_slurp_gsd, _bfd_vms_write_gsd): ..
5375 * vms-misc.c (add_new_contents): ..
5376 * vms-tir.c (check_section, new_section, _bfd_vms_write_tir): ..
5377 * vms.c (vms_set_section_contents): ..
5378 * xcofflink.c (xcoff_get_section_contents, xcoff_link_add_symbols,
5379 xcoff_sweep, bfd_xcoff_size_dynamic_sections, xcoff_build_ldsyms,
5380 _bfd_xcoff_bfd_final_link, xcoff_link_input_bfd): ..
5381 * xsym.c (bfd_sym_scan): .. See above.
5383 2004-06-21 H.J. Lu <hongjiu.lu@intel.com>
5385 * elfxx-ia64.c (elfNN_ia64_relax_section): Add addend when
5386 calling _bfd_merged_section_offset only for section symbols.
5388 2004-06-22 Alan Modra <amodra@bigpond.net.au>
5390 * elf32-ppc.c (ppc_elf_relax_section): Implement reference code
5391 for handling SEC_MERGE symbols in relax_section.
5393 2004-06-21 Alexandre Oliva <aoliva@redhat.com>
5395 2003-05-15 Richard Sandiford <rsandifo@redhat.com>
5396 * cpu-h8300.c (compatible): Allow h8300s and h8300sx code to be
5397 linked together. Mark the result as h8300sx code.
5399 2004-06-21 Alexandre Oliva <aoliva@redhat.com>
5401 * elf-bfd.h (struct elf_backend_data): Added
5402 elf_backend_omit_section_dynsym.
5403 (_bfd_elf_link_omit_section_dynsym): Declare.
5404 * elf32-frv.c (_frvfdpic_link_omit_section_dynsym): New.
5405 (elf_backend_omit_section_dynsym): Use it for frvfdpic.
5406 * elflink.c (_bfd_elf_link_omit_section_dynsym): Split out of...
5407 (_bfd_elf_link_renumber_dynsyms): ... this function.
5408 * elfxx-target.h (elf_backend_omit_section_dynsym): Default to
5409 _bfd_elf_link_omit_section_dynsym).
5410 (elfNN_bed): Added elf_backend_omit_section_dynsym.
5412 2004-06-21 Nick Clifton <nickc@redhat.com>
5414 * coffcode.h (styp_to_sec_flags): Ignore IMAGE_SCN_MEM_NOT_PAGED
5417 2004-06-17 Jerome Guitton <guitton@gnat.com>
5419 * bfd-in.h (bfd_cache_close_all): New function declaration.
5420 * bfd-in2.h: Regenerate.
5421 * cache.c (bfd_cache_close_all): New function definition.
5423 2004-06-16 Mark Kettenis <kettenis@gnu.org>
5425 * configure.in: Don't set COREFILE to trad-core.lo for FreeBSD
5427 * configure: Regenerate.
5429 2004-06-16 Daniel Jacobowitz <dan@debian.org>
5431 * elf32-ppc.c (ppc_elf_create_linker_section): Create symbols in
5432 the pre-existing section.
5434 2004-06-15 Alan Modra <amodra@bigpond.net.au>
5436 * section.c (struct sec): Remove usused flags. Reorganize a little.
5437 (bfd_get_section_size_before_reloc): Delete.
5438 (bfd_get_section_size_after_reloc): Delete.
5439 (STD_SECTION): Update.
5440 (bfd_get_section_size_now): Delete.
5441 (bfd_set_section_contents): Don't referece reloc_done.
5442 (bfd_get_section_contents): Remove reloc_done comment.
5443 * bout.c (b_out_bfd_get_relocated_section_contents): Don't set
5445 * coff-alpha.c (alpha_ecoff_get_relocated_section_contents): Likewise.
5446 * ecoff.c (bfd_debug_section): Update initializer.
5447 * elfxx-mips.c (_bfd_elf_mips_get_relocated_section_contents): Ditto.
5448 * reloc.c (bfd_generic_get_relocated_section_contents): Likewise.
5449 * bfd-in.h (bfd_section_size): Expand.
5450 (bfd_get_section_size): New macro.
5451 * bfd-in2.h: Regenerate.
5452 * coff64-rs6000.c (xcoff64_write_object_contents): Replace
5453 bfd_get_section_size_before_reloc with bfd_get_section_size.
5454 * coffcode.h (coff_write_object_contents): Likewise.
5455 * coffgen.c (build_debug_section): Likewise.
5456 * dwarf1.c (parse_line_table): Likewise.
5457 (_bfd_dwarf1_find_nearest_line): Likewise.
5458 * ecoff.c (_bfd_ecoff_write_object_contents): Likewise.
5459 * i386msdos.c (msdos_write_object_contents): Likewise.
5460 * pdp11.c (squirt_out_relocs): Likewise.
5461 * elf32-sh64.c (sh64_find_section_for_address): Remove comment.
5462 * elf64-mmix.c (mmix_elf_final_link): Update comment.
5464 2004-06-14 Chris Demetriou <cgd@broadcom.com>
5466 * elf32-mips.c (elf_mips_gnu_pcrel32): Add (undoing 2004-04-24
5467 removal) with updated comment.
5468 (bfd_elf32_bfd_reloc_type_lookup): Add back case for
5470 (mips_elf32_rtype_to_howto): Add back case for R_MIPS_PC32.
5471 * elfxx-mips.c (mips_elf_calculate_relocation): Likewise.
5473 2004-06-12 Alan Modra <amodra@bigpond.net.au>
5475 * elf64-x86-64.c (elf64_x86_64_relocate_section): Ignore reloc
5476 overflow on branches to undefweaks.
5478 2004-06-11 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
5480 * coff-alpha.c (alpha_relocate_section): Set used_by_bfd directly
5481 as ecoff_section_data() does not return a valid lvalue.
5483 2004-06-09 Alexandre Oliva <aoliva@redhat.com>
5485 * elflink.c (elf_sort_symbol): Compare section id, not pointers.
5486 (elf_link_add_object_symbols): Likewise.
5488 * elf-m10300.c (_bfd_mn10300_elf_reloc_type_class): New.
5489 (elf_backend_reloc_type_class): New.
5491 2004-06-08 Mark Kettenis <kettenis@gnu.org>
5493 * configure.in (hppa*-*-netbsd*, hppa*-*-openbsd): Set COREFILE to
5495 * configure: Regenerate.
5497 2004-06-07 Daniel Jacobowitz <dan@debian.org>
5499 From: Albert Chin-A-Young <china@thewrittenword.com>
5500 * bfd/elf-bfd.h (struct eh_cie_fde): Convert unsigned char bitfields
5503 2004-05-29 H.J. Lu <hongjiu.lu@intel.com>
5505 * elfxx-ia64.c (elfNN_ia64_relax_section): Undo the last
5508 2004-05-28 DJ Delorie <dj@redhat.com>
5510 * elf-m10300.c (mn10300_elf_relax_section): Preserve reloc addend
5511 for linking, but otherwise adjust reloc for merged sections.
5513 2004-05-28 H.J. Lu <hongjiu.lu@intel.com>
5515 * elfxx-ia64.c (elfNN_ia64_relax_section): Properly call
5516 _bfd_merged_section_offset for local symbols.
5518 2004-05-28 Andrew Stubbs <andrew.stubbs@superh.com>
5520 * Makefile.am: Regenerate dependencies.
5521 * Makefile.in: Regenerate.
5522 * archures.c: Add bfd_mach_sh3_nommu .
5523 * bfd-in2.h: Regenerate.
5524 * cpu-sh.c: Add sh3-nommu architecture.
5525 (bfd_to_arch_table): Create new table.
5526 (sh_get_arch_from_bfd_mach): Create new function.
5527 (sh_get_arch_up_from_bfd_mach): Create new function.
5528 (sh_merge_bfd_arch): Create new function.
5529 * elf32-sh.c (sh_ef_bfd_table): Add table.
5530 (sh_elf_check_relocs): Replace switch statement with
5531 use of sh_ef_bfd_table .
5532 (sh_elf_get_flags_from_mach): Add new function.
5533 (sh_find_elf_flags): Likewise.
5534 (sh_elf_copy_private_data): Replace most of non-elf contents
5535 with a call to sh_merge_bfd_arch() .
5537 2004-05-27 Michael Chastain <mec.gnu@mindspring.com>
5539 * Makefile.am (bfdver.h): Use explicit filename, not $< .
5540 * Makefile.in: Regenerate.
5542 2004-05-27 Alexandre Oliva <aoliva@redhat.com>
5544 * elf-m10300.c (elf32_mn10300_finish_hash_table_entry): Avoid
5545 custom calling conventions for dynamic symbols.
5546 (mn10300_elf_relax_section): Avoid relaxing a function as a local
5547 symbol if it's an alias to a global one.
5549 2004-05-26 H.J. Lu <hongjiu.lu@intel.com>
5551 * elf.c (_bfd_elf_make_section_from_shdr): Undo the last
5554 2004-05-27 Alexandre Oliva <aoliva@redhat.com>
5556 * elf-m10300.c (mn10300_elf_relax_section): Don't test isym within
5559 2004-05-26 Alan Modra <amodra@bigpond.net.au>
5561 * elf.c (_bfd_elf_make_section_from_shdr): Don't set SEC_EXCLUDE
5562 for SHT_GROUP sections.
5564 2004-05-25 Alan Modra <amodra@bigpond.net.au>
5566 * elflink.c (elf_link_add_object_symbols): Don't set up merge
5568 * elf.c (_bfd_elf_merge_sections): .. Do it here instead.
5569 * merge.c: Formatting. Remove unnecessary casts. Expand
5570 bfd_get_section_alignment macro.
5571 (struct sec_merge_sec_info): Rename "first" to "first_str". Update
5572 use throughout file.
5573 (_bfd_add_merge_section): Rename from _bfd_merge_section. Update
5574 comment. Abort on dynamic or non-SEC_MERGE input. Don't test
5575 section name to determine sinfo group, instead test output section
5577 (_bfd_merge_sections): Add struct bfd_link_info param. Call
5578 _bfd_strip_section_from_output rather than just twiddling flags.
5579 * libbfd-in.h (_bfd_add_merge_section): Rename, update comment.
5580 (_bfd_merge_sections): Update prototype.
5581 * libbfd.h: Regenerate.
5583 2004-05-24 Mark Kettenis <kettenis@gnu.org>
5585 * netbsd-core.c: Correctly indent section that sets architecture
5588 From Miod Vallat <miod@online.fr>:
5589 * m88kopenbsd.c: New file.
5590 * targets.c (m88k_openbsd_vec): New.
5591 * config.bfd: Add m88k-*-openbsd*.
5592 * configure.in (m88k-*-openbsd*): Set COREFILE to netbsd-core.lo.
5593 (m88kopenbsd_vec): New.
5594 * configure: Regenerate.
5595 * Makefile.am (BFD32_BACKENDS): Add m88kopenbsd.lo.
5596 (BFD32_BACKENDS_CFILES): Add m88kopenbsd.c.
5598 * Makefile.in: Regenerate.
5599 * po/SRC-POTFILES.in: Regenerate.
5601 2004-05-24 Nick Clifton <nickc@redhat.com>
5603 * hash.c: Remove bogus node "Changing the default Hash Table Size"
5604 introduced by hash table size patch.
5606 2004-05-22 Ben Elliston <bje@au.ibm.com>
5608 * configure.in (is_release): Remove.
5609 (bfd_version_date, bfd_version, bfd_version_string): Likewise.
5610 (AC_OUTPUT): Don't output bfdver.h from version.h.
5611 * configure: Regenerate.
5612 * Makefile.am (RELEASE): New variable.
5613 (bfdver.h): New target.
5614 * Makefile.in: Regenerate.
5615 * doc/Makefile.in: Likewise.
5617 2004-05-22 Ben Elliston <bje@au.ibm.com>
5619 * Makefile.am (config.status): Don't depend on version.h.
5620 * Makefile.in: Regenerate.
5622 2004-05-22 Alan Modra <amodra@bigpond.net.au>
5624 * merge.c (_bfd_merged_section_offset): Remove "addend" param.
5625 * libbfd-in.h (_bfd_merged_section_offset): Adjust prototype.
5626 * libbfd.h: Regenerate.
5627 * elf.c (_bfd_elf_rela_local_sym): Adjust call.
5628 (_bfd_elf_rel_local_sym): Likewise.
5629 * elflink.c (_bfd_elf_link_sec_merge_syms): Likewise.
5630 (elf_link_input_bfd): Likewise.
5631 * elf32-ppc.c (ppc_elf_relax_section): Likewise.
5632 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
5633 * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
5634 (elfNN_ia64_relocate_section): Likewise.
5636 2004-05-21 Andy Chittenden <achittenden@bluearc.com>
5638 * hash.c (bfd_default_hash_table_size): New variable.
5639 (bfd_hash_table_init): Use new variable instead of DEFAULT_SIZE.
5640 (bfd_hash_set_default_size): New function. Set the default size
5641 to a selected prime number close to the argument. Document new
5643 * bfd-in.h: Add prototype for bfd_hash_set_default_size.
5644 * bfd-in2.h: Regenerate.
5645 * Makefile.am (hash.lo): Add dependency upon libiberty.h.
5646 * Makefile.in: Regenerate.
5648 2004-05-21 Mark Kettenis <kettenis@gnu.org>
5650 * libaout.h (machine_type): Add M_88K_OPENBSD and M_HPPA_OPENBSD.
5651 * netbsd-core.c (netbsd_core_file_p): Set architecture for alpha,
5652 arm, m68k, m88k and hppa core files.
5654 2004-05-21 Nick Clifton <nickc@redhat.com>
5656 * bfdio.c (bfd_bread): Do not use iovec if it is NULL.
5657 (bfd_bwrite): Likewise.
5658 (bfd_tell): Likewise.
5659 (bfd_flush): Likewise.
5660 (bfd_stat): Likewise.
5661 (bfd_seek): Likewise.
5662 (bfd_get_mtime): Likewise.
5663 (bfd_get_size): Likewise.
5665 2004-05-19 Ben Elliston <bje@au.ibm.com>
5667 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Comment correction.
5669 2004-05-19 Mikulas Patocka <mikulas@artax.karlin.mff.cuni.cz>
5671 * archive.c (_bfd_get_elt_at_filepos): Cope with a nested archives.
5672 (bfd_generic_openr_next_archived_file): Likewise.
5674 2004-05-17 Bob Wilson <bob.wilson@acm.org>
5676 * elf32-xtensa.c (xtensa_get_property_section_name): Determine linkonce
5677 section names by inserting a new substring after .gnu.linkonce, except
5678 for .gnu.linkonce.t.* where the "t." is replaced.
5680 2004-05-17 Adam Nemet <anemet@lnxw.com>
5682 * config.bfd (sparc-*-lynxos* case): Add to obsolete list.
5683 (m68-*-lynxos* case): Likewise.
5684 (powerpc-*-lyxnos* case): New case.
5685 (i[3-7]86-*-lynxos* case): Update to LynxOS 4.0 ELF.
5687 2004-05-17 David Heine <dlheine@tensilica.com>
5689 * aout-target.h (MY_bfd_copy_private_header_data): Define.
5690 * aout-tic30.c (MY_bfd_copy_private_header_data): Define.
5691 * bfd.c (bfd_copy_private_header_data): Define.
5692 * coff-rs6000.c (rs6000coff_vec, pmac_xcoff_vec): Add entries for new
5694 * coff64-rs6000.c (rs6000coff64_vec, aix5coff64_vec): Likewise.
5695 * coffcode.h (coff_bfd_copy_private_header_data): Define.
5696 * elf-bfd.h (_bfd_elf_copy_private_header_data): Declare.
5697 * elf.c (_bfd_elf_copy_private_section_data): Remove code to set up
5698 segments by calling copy_private_bfd_data.
5699 (_bfd_elf_copy_private_header_data): Define.
5700 * elfxx-target.h (bfd_elfNN_bfd_copy_private_header_data): Define.
5701 * libbfd-in.h (_bfd_generic_bfd_copy_private_header_data): Define.
5702 * libecoff.h (_bfd_ecoff_bfd_copy_private_header_data): Define.
5703 * mach-o.c (bfd_mach_o_bfd_copy_private_header_data): Define.
5704 * mmo.c (mmo_bfd_copy_private_header_data): Define.
5705 * ppcboot.c (ppcboot_bfd_copy_private_header_data): Define.
5706 * som.c (som_bfd_copy_private_header_data): Define.
5707 * targets.c (BFD_JUMP_TABLE_COPY): Add _bfd_copy_private_header_data.
5708 * vms.c (vms_bfd_copy_private_header_data): Define.
5709 * bfd-in2.h: Regenerate.
5710 * libbfd.h: Regenerate.
5712 2004-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
5714 * elfxx-mips.c (MINUS_TWO): Define.
5715 (mips_elf_higher, mips_elf_highest,
5716 mips_elf_create_dynamic_relocation): Use MINUS_ONE and MINUS_TWO for
5717 some bfd_vma values.
5718 (_bfd_mips_elf_finish_dynamic_symbol): Likewise. Code cleanup.
5720 2004-05-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
5722 * som.c (log2): Rename to exact_log2. Adjust all callers.
5724 2004-05-13 Paul Brook <paul@codesourcery.com>
5726 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Handle
5727 dwarf3 format CIE entries. Remove comment about the size of the
5728 ra_column field. It is now correctly deduced.
5730 2004-05-13 Joel Sherrill <joel@oarcorp.com>
5732 * config.bfd (or32-*-rtems*): Switch to elf.
5734 2004-05-13 Nick Clifton <nickc@redhat.com>
5736 * po/fr.po: Updated French translation.
5738 2004-05-11 Jakub Jelinek <jakub@redhat.com>
5740 * elflink.c (bfd_elf_final_link): Don't output STT_SECTION symbol
5741 into .dynsym if elf_section_data (sec)->dynindx <= 0.
5742 Adjust counting of last_local.
5743 (_bfd_elf_link_renumber_dynsyms): Don't assign dynindx to sections
5744 other than SHT_PROGBITS/SHT_NOBITS and neither for .got/.got.plt/.plt
5745 created by the linker nor !SHF_ALLOC.
5747 * elf32-i386.c (elf_i386_finish_dynamic_sections): Point
5748 DT_PLTGOT to the start of the .got.plt section instead of the
5749 .got output section. Set sh_entsize for .got section in addition
5751 (elf_i386_relocate_section): Don't assume _GLOBAL_OFFSET_TABLE_
5752 is at sgot->output_section->vma.
5753 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_sections): Point
5754 DT_PLTGOT to the start of the .got.plt section instead of the
5755 .got output section.
5756 (elf64_x86_64_relocate_section): Don't assume _GLOBAL_OFFSET_TABLE_
5757 is at sgot->output_section->vma. Set sh_entsize for .got section
5758 in addition to .got.plt.
5759 * elf.c (_bfd_elf_print_private_bfd_data): Handle PT_GNU_RELRO.
5760 (bfd_section_from_phdr): Likewise.
5761 (map_sections_to_segments): Likewise.
5762 (assign_file_positions_for_segments): Likewise.
5763 (get_program_header_size): Likewise.
5764 * elflink.c (bfd_elf_size_dynamic_sections): Set
5765 elf_tdata (output_bfd)->relro from info->relro.
5766 * elf-bfd.h (struct elf_obj_tdata): Add relro field.
5768 2004-05-08 Alexandre Oliva <aoliva@redhat.com>
5770 * elf32-frv.c (_frvfdpic_add_dyn_reloc): Don't warn when we get
5771 a zero symndx for which we hadn't accounted a dynamic relocation.
5772 (_frvfdpic_add_rofixup): Likewise.
5774 2004-05-07 Brian Ford <ford@vss.fsi.com>
5775 DJ Delorie <dj@redhat.com>
5777 * coffcode.h (coff_write_object_contents) [COFF_IMAGE_WITH_PE]:
5778 Propagate IMAGE_FILE_LARGE_ADDRESS_AWARE.
5779 * peXXigen.c (_bfd_XX_print_private_bfd_data_common): Recognize
5780 IMAGE_FILE_LARGE_ADDRESS_AWARE. Use PE defines.
5782 2004-05-07 Alexandre Oliva <aoliva@redhat.com>
5784 * elf32-frv.c (elf32_frvfdpic_modify_segment_map): Return
5785 immediately if there's no link info.
5786 (elf32_frvfdpic_copy_private_bfd_data): New.
5787 (bfd_elf32_bfd_copy_private_bfd_data): Use it for frvfdpic.
5789 2004-05-06 Zack Weinberg <zack@codesourcery.com>
5791 * dwarf2.c (add_line_info): Also set info->filename to NULL if
5792 filename argument is null; do not call strlen on a null pointer.
5794 2004-05-06 Daniel Jacobowitz <drow@mvista.com>
5796 * elf32-arm.h (elf32_arm_relocate_section): Remove R_ARM_PLT32
5799 2004-05-05 Alexandre Oliva <aoliva@redhat.com>
5801 * configure.in (bfd_elf32_frvfdpic_vec): New.
5802 * configure: Rebuilt.
5803 * targets.c (bfd_elf32_frvfdpic_vec): New.
5804 * config.bfd: Enable it on frv-*-elf and frv-*-*linux*, as default
5806 * elf32-frv.c: Prefix all identifiers added for FDPIC support with
5807 frvfdpic instead of frv. Rearrange elf-target macros such that
5808 the FDPIC-specific ones are only defined for this new target
5810 (bfd_elf32_frvfdpic_vec): Declare.
5812 (elf32_frv_relocate_section): Use it to enable segment checking
5813 and to control rofixup emission. Add output section vma to
5814 applied relocation in non-LOAD non-ALLOC sections. Use
5815 _bfd_error_handler for errors.
5816 (_frv_create_got_section): Create .rel.got and .rofixup only in
5817 FDPIC. Create non-dynamic _gp at .got+2048 in non-FDPIC, like the
5819 (elf32_frvfdpic_size_dynamic_sections): Assume FDPIC.
5820 (elf32_frvfdpic_modify_segment_map): Likewise.
5821 (elf32_frv_finish_dynamic_sections): New, do-nothing.
5822 (elf32_frvfdpic_finish_dynamic_sections): Assume FDPIC. Improve
5823 error message if we miscompute the rofixup size.
5824 (frvfdpic_elf_use_relative_eh_frame): Assume FDPIC.
5825 (frvfdpic_elf_encode_eh_address): Likewise.
5826 (elf32_frv_check_relocs): Reject FDPIC-only relocs in non-FDPIC.
5827 Record relocs only in FDPIC. Make sure _gp is defined for GPREL
5828 relocs. Reject unknown relocation types.
5829 (elf32_frv_object_p): Make sure target vector matches FDPIC bits.
5830 (frv_elf_merge_private_bfd_data): Likewise.
5831 (ELF_MAXPAGESIZE): Revert to 0x1000 for elf32-frv; keep it as
5832 0x4000 for newly-added elf32-frvfdpic.
5834 2004-05-05 Nick Clifton <nickc@redhat.com>
5837 * cache.c (bfd_cache_lookup_worker): Call abort() rather than
5838 returning NULL as most users of this function do not check its
5840 * hppabsd-core.c (hppabsd_core_core_file_p): Do not check result
5841 of bfd_cache_lookup().
5842 * sco5-core.c (sco5_core_file_p): Likewise.
5843 * trad-core.c (trad_unix_core_file_p): Likewise.
5845 2004-05-05 Nick Clifton <nickc@redhat.com>
5847 * cache.c (bfd_cache_lookup): Improve formatting.
5848 * archive.c: Fix formatting.
5850 2004-05-05 Peter Barada <peter@the-baradas.com>
5852 * bfd_archures.c(bfd_architecture): Add 521x,5249,547x,548x.
5853 * cpu-m68k.c(bfd_m68k_arch): Likewise.
5854 * bfd-in2.h(bfd_architecture): Regenerate.
5856 2004-05-03 Alan Modra <amodra@bigpond.net.au>
5858 * elf.c (_bfd_elf_rela_local_sym): Set kept_section for excluded
5860 * elflink.c (elf_link_input_bfd): Adjust output reloc index for
5861 those against discarded link-once and SEC_MERGE section symbols.
5863 2004-05-02 H.J. Lu <hongjiu.lu@intel.com>
5865 * section.c (bfd_get_section_by_name_if): New.
5866 * bfd-in2.h: Regenerated.
5868 2004-05-02 Alan Modra <amodra@bigpond.net.au>
5870 * som.c (som_bfd_is_group_section): Define.
5872 2004-05-01 Alan Modra <amodra@bigpond.net.au>
5874 * section.c (bfd_make_section_anyway): Copy the whole
5875 bfd_hash_entry, not just "next" from existing entry.
5877 2004-04-30 H.J. Lu <hongjiu.lu@intel.com>
5879 * elf.c (bfd_section_from_shdr): Maintain the section order in
5881 (special_sections): Add ".note.GNU-stack".
5882 (elf_fake_sections): Handle section group for relocatable
5885 2004-04-30 H.J. Lu <hongjiu.lu@intel.com>
5887 * section.c (bfd_sections_find_if): New.
5888 * bfd-in2.h: Regenerated.
5890 2004-04-30 Alan Modra <amodra@bigpond.net.au>
5892 * section.c (bfd_make_section_anyway): Add all sections to hash tab.
5894 * elf-bfd.h (bfd_elf_is_group_section): Declare.
5895 * elf.c (bfd_elf_is_group_section): New function.
5896 * elfxx-target.h (bfd_elfNN_bfd_is_group_section
5897 * section.c (bfd_generic_is_group_section): New function.
5898 * targets.c (struct bfd_target): Add _bfd_is_group_section field.
5899 (BFD_JUMP_TABLE_LINK): Adjust.
5900 * aout-adobe.c (aout_32_bfd_is_group_section): Define.
5901 * aout-target.h (MY_bfd_is_group_section): Define.
5902 * aout-tic30.c (MY_bfd_is_group_section): Define.
5903 * bfd.c (bfd_is_group_section): Define.
5904 * binary.c (binary_bfd_is_group_section): Define.
5905 * bout.c (b_out_bfd_is_group_section): Define.
5906 * coff-alpha.c (_bfd_ecoff_bfd_is_group_section): Define.
5907 * coff-mips.c (_bfd_ecoff_bfd_is_group_section): Define.
5908 * coff-rs6000.c (rs6000coff_vec, pmac_xcoff_vec): Adjust.
5909 * coff64-rs6000.c (rs6000coff64_vec, aix5coff64_vec): Adjust.
5910 * coffcode.h (coff_bfd_is_group_section): Define.
5911 * i386msdos.c (msdos_bfd_is_group_section): Define.
5912 * i386os9k.c (os9k_bfd_is_group_section): Define.
5913 * ieee.c (ieee_bfd_is_group_section): Define.
5914 * ihex.c (ihex_bfd_is_group_section): Define.
5915 * libbfd-in.h (_bfd_nolink_bfd_is_group_section): Define.
5916 * mach-o.c (bfd_mach_o_bfd_is_group_section): Define.
5917 * mmo.c (mmo_bfd_is_group_section): Define.
5918 * nlm-target.h (nlm_bfd_is_group_section): Define.
5919 * oasys.c (oasys_bfd_is_group_section): Define.
5920 * pef.c (bfd_pef_bfd_is_group_section): Define.
5921 * ppcboot.c (ppcboot_bfd_is_group_section): Define.
5922 * srec.c (srec_bfd_is_group_section): Define.
5923 * tekhex.c (tekhex_bfd_is_group_section): Define.
5924 * versados.c (versados_bfd_is_group_section): Define.
5925 * vms.c (vms_bfd_is_group_section): Define.
5926 * xsym.c (bfd_sym_bfd_is_group_section): Define.
5927 * bfd-in2.h: Regenerate.
5928 * libbfd.h: Regenerate.
5930 2004-04-30 Alan Modra <amodra@bigpond.net.au>
5932 * elflink.c (elf_gc_mark): Follow indirect and warning syms.
5934 2004-04-30 Hans-Peter Nilsson <hp@axis.com>
5936 * configure.in: Update version to 2.15.91.
5937 * configure: Regenerate.
5939 2004-04-29 Brian Ford <ford@vss.fsi.com>
5941 * bfd.c (bfd_get_sign_extend_vma): Add pe[i]-i386 case to DJGPP hack.
5942 * coffcode.h (DOT_DEBUG, GNU_LINKONCE_WI): Define.
5943 [!COFF_WITH_PE] (sec_to_styp_flags, styp_to_sec_flags): Use them.
5944 (coff_compute_section_file_positions) [RS6000COFF_C]: Likewise.
5945 [COFF_WITH_PE] (sec_to_styp_flags): Handle DWARF 2/3 .debug* and
5946 .gnu.linkonce.wi. sections.
5947 * pe-i386.c (COFF_SUPPORT_GNU_LINKONCE): Define.
5948 (COFF_SECTION_ALIGNMENT_ENTRIES): Add entries for .debug and
5950 * pei-i386.c (COFF_SUPPORT_GNU_LINKONCE): Likewise.
5951 (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
5953 2004-04-28 Chris Demetriou <cgd@broadcom.com>
5955 * reloc.c: Remove BFD_RELOC_PCREL_HI16_S and BFD_RELOC_PCREL_LO16.
5956 * bfd-in2.h: Regenerate.
5957 * libbfd.h: Likewise.
5959 2004-04-28 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
5961 * som.c (struct som_misc_symbol_info): Add is_comdat, is_common and
5963 (setup_sections): Use som_subspace_dictionary_record struct instead
5964 subspace_dictionary_record. Set SEC_LINK_ONCE if subspace is
5965 is_comdat, is_common or dup_common.
5966 (som_prep_headers): Use som_subspace_dictionary_record struct. Set
5967 is_comdat, is_common and dup_common in section subspace_dict from
5969 (som_begin_writing): Use som_subspace_dictionary_record struct.
5970 (som_finish_writing): Likewise.
5971 (som_bfd_derive_misc_symbol_info): Add support to set is_comdat,
5972 is_common and dup_common flags in info for symbol. Add comment
5973 regarding linker support for these fields. Slightly reorganize
5975 (som_build_and_write_symbol_table): Set is_comdat, is_common and
5976 dup_common fields in symbol table from symbol info.
5977 (bfd_som_set_subsection_attributes): Add comdat, common and dup_common
5978 arguments. Set corresponding fields in copy_data. Change all callers.
5979 (som_bfd_ar_write_symbol_stuff): Set dup_common flag in library
5981 (som_vec): Add SEC_LINK_ONCE to applicable section flags.
5982 * som.h (som_subspace_dictionary_record): Define.
5983 (som_copyable_section_data_struct): Add is_comdat, is_common and
5985 (som_section_data_struct): Use som_subspace_dictionary_record struct
5986 instead of subspace_dictionary_record.
5987 (bfd_boolean bfd_som_set_subsection_attributes): Adjust prototype.
5989 2004-04-27 Bob Wilson <bob.wilson@acm.org>
5991 * elf32-xtensa.c (xtensa_read_table_entries): Use section _cooked_size
5992 if set. Check reloc_done flag before applying relocations. Use
5993 output addresses, both when applying relocations and when comparing
5994 against the specified section.
5995 (elf_xtensa_relocate_section): Use output address to check if dynamic
5996 reloc is in a literal pool. Set section's reloc_done flag.
5998 2004-04-27 H.J. Lu <hongjiu.lu@intel.com>
6000 * elf32-sh64.c (elf_backend_section_flags): New. Defined.
6001 (sh64_elf_set_mach_from_flags): Remove the kludge for .cranges
6003 (sh64_elf_section_flags): New. Set SEC_DEBUGGING for .cranges
6006 2004-04-27 Alan Modra <amodra@bigpond.net.au>
6008 * elf64-alpha.c (elf64_alpha_read_ecoff_info): Don't assign
6009 structure field removed in 2004-04-24 patch.
6010 * elf64-sparc.c (sparc64_elf_plt_sym_val): Warning fix.
6012 * elf-bfd.h (struct elf_backend_data <elf_backend_section_flags>):
6014 * elf32-arm.h (elf32_arm_section_flags): Likewise.
6015 * elf64-alpha.c (elf64_alpha_section_flags): Likewise.
6016 * elfxx-ia64.c (elfNN_ia64_section_flags): Likewise.
6017 * elf.c (_bfd_elf_make_section_from_shdr): Set the bfd_section
6018 field before calling elf_backend_section_flags.
6020 2004-04-24 Chris Demetriou <cgd@broadcom.com>
6022 * elf32-mips.c (elf_mips_gnu_rel_hi16, elf_mips_gnu_rel_lo16)
6023 (elf_mips_gnu_pcrel64, elf_mips_gnu_pcrel32): Remove.
6024 (bfd_elf32_bfd_reloc_type_lookup): Remove cases for
6025 BFD_RELOC_PCREL_HI16_S, BFD_RELOC_PCREL_LO16, BFD_RELOC_64_PCREL,
6026 and BFD_RELOC_32_PCREL.
6027 (mips_elf32_rtype_to_howto): Remove cases for R_MIPS_GNU_REL_HI16,
6028 R_MIPS_GNU_REL_LO16, R_MIPS_PC64, R_MIPS_PC32.
6029 * elfxx-mips.c (mips_elf_calculate_relocation): Likewise.
6030 (_bfd_mips_elf_lo16_reloc): Remove handling for R_MIPS_GNU_REL_HI16.
6031 (mips_elf_next_relocation): Move comment about matching HI/LO
6033 (_bfd_mips_elf_relocate_section): Here. Remove handling for
6034 R_MIPS_GNU_REL_HI16.
6036 2004-04-23 Chris Demetriou <cgd@broadcom.com>
6038 * coff-mips.c (mips_relhi_reloc, mips_rello_reloc)
6039 (mips_switch_reloc, mips_read_relocs, mips_relax_section)
6040 (mips_relax_pcrel16, PCREL16_EXPANSION_ADJUSTMENT): Remove.
6041 (mips_relocate_hi): Remove now-unused 'adjust' and 'pcrel' arguments,
6042 and update comments to reflect current usage.
6043 (mips_howto_table): Remove entries for MIPS_R_RELHI, MIPS_R_RELLO,
6044 and MIPS_R_SWITCH, as well as several empty entries. Update comment
6046 (mips_ecoff_swap_reloc_in, mips_ecoff_swap_reloc_out)
6047 (mips_adjust_reloc_out, mips_bfd_reloc_type_lookup): Remove support
6048 for MIPS_R_SWITCH, MIPS_R_RELLO, and MIPS_R_RELHI relocations.
6049 (mips_adjust_reloc_in): Likewise, adjust maximum accepted relocation
6050 type number to be MIPS_R_PCREL16.
6051 (mips_relocate_section): Remove support for link-time relaxation
6052 of branches used by embedded-PIC. Remove support for MIPS_R_SWITCH,
6053 MIPS_R_RELLO, and MIPS_R_RELHI relocations.
6054 (_bfd_ecoff_bfd_relax_section): Redefine to bfd_generic_relax_section.
6055 * ecoff.c (ecoff_indirect_link_order): Remove support for link-time
6056 relaxation of branches used by embedded-PIC.
6057 * ecofflink.c (bfd_ecoff_debug_accumulate): Likewise.
6058 * libecoff.h (struct ecoff_section_tdata): Remove embedded-PIC
6059 related members, update comment.
6060 * pe-mips.c: Remove disabled (commented-out and #if 0'd)
6061 code related to embedded-PIC.
6062 * elfxx-mips.c (_bfd_mips_elf_read_ecoff_info): Remove
6063 initialization of now-removed 'adjust' member of
6064 'struct ecoff_debug_info'.
6066 2004-04-23 Chris Demetriou <cgd@broadcom.com>
6068 * elfxx-mips.c (mips_elf_get_global_gotsym_index): Remove.
6070 2004-04-21 Philip Blundell <pb@nexus.co.uk>
6072 * elf32-arm.h (elf32_arm_check_relocs): Don't output REL32
6073 relocs for locally defined symbols during -shared final link.
6074 (elf32_arm_final_link_relocate): Likewise.
6076 2004-04-22 Jakub Jelinek <jakub@redhat.com>
6078 * elf64-x86-64.c (elf64_x86_64_copy_indirect_symbol): Copy also
6079 ELF_LINK_POINTER_EQUALITY_NEEDED.
6080 (elf64_x86_64_check_relocs): Set ELF_LINK_POINTER_EQUALITY_NEEDED
6081 if r_type is not R_X86_64_PC32.
6082 (elf64_x86_64_finish_dynamic_symbol): If
6083 ELF_LINK_POINTER_EQUALITY_NEEDED is not set, clear st_value of
6086 2004-04-22 Kaz Kojima <kkojima@rr.iij4u.or.jp>
6088 * elf32-sh.c (sh_elf_plt_sym_val): New function.
6089 (elf_backend_plt_sym_val): Define.
6091 2004-04-22 Andrew Cagney <cagney@redhat.com>
6093 * opncls.c (bfd_alloc): Fix type of "wanted" in doco.
6095 2004-04-22 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
6097 * hpux-core.c (hpux_core_core_file_p): Add cast in call to
6099 * som.c (som_set_section_contents): Constantify second argument.
6100 (hppa_som_gen_reloc_type): Abort for unsupported selectors.
6101 (som_object_setup): Rework to avoid warning.
6102 (setup_sections, som_write_fixups, bfd_section_from_som_symbol):
6105 2004-04-22 Andrew Cagney <cagney@redhat.com>
6107 * cache.c (bfd_cache_close): Check for a previously closed file.
6109 2004-04-22 Jakub Jelinek <jakub@redhat.com>
6111 * bfd.c (bfd_get_synthetic_symtab): Define.
6112 * targets.c (BFD_JUMP_TABLE_DYNAMIC): Add
6113 NAME##_get_synthetic_symtab.
6114 (struct bfd_target): Add _bfd_get_synthetic_symtab.
6115 * libbfd-in.h (_bfd_nodynamic_get_synthetic_symtab): Define.
6116 * elf-bfd.h (struct elf_backend_data): Add plt_sym_val and
6118 (_bfd_elf_get_synthetic_symtab): New prototype.
6119 * elfcode.h (elf_get_synthetic_symtab): Define.
6120 * elf.c (_bfd_elf_get_synthetic_symtab): New function.
6121 * elfxx-target.h (bfd_elfNN_get_synthetic_symtab): Define.
6122 (elf_backend_plt_sym_val, elf_backend_relplt_name): Define.
6123 (elfNN_bed): Add elf_backend_plt_sym_val and elf_backend_relplt_name.
6124 * bfd-in2.h: Rebuilt.
6125 * libbfd.h: Rebuilt.
6126 * elf32-i386.c (elf_i386_plt_sym_val): New function.
6127 (elf_backend_plt_sym_val): Define.
6128 * elf64-x86-64.c (elf64_x86_64_plt_sym_val): New function.
6129 (elf_backend_plt_sym_val): Define.
6130 * elf32-s390.c (elf_s390_plt_sym_val): New function.
6131 (elf_backend_plt_sym_val): Define.
6132 * elf64-s390.c (elf_s390_plt_sym_val): New function.
6133 (elf_backend_plt_sym_val): Define.
6134 * elf32-sparc (elf32_sparc_plt_sym_val): New function.
6135 (elf_backend_plt_sym_val): Define.
6136 * elf64-sparc.c (sparc64_elf_plt_sym_val): New function.
6137 (elf_backend_plt_sym_val): Define.
6138 * elf32-ppc.c (ppc_elf_plt_sym_val): New function.
6139 (elf_backend_plt_sym_val): Define.
6140 * aout-target.h (MY_get_synthetic_symtab): Define.
6141 * aout-tic30.c (MY_get_synthetic_symtab): Define.
6142 * coff-rs6000.c (rs6000coff_vec): Add
6143 _bfd_nodynamic_get_synthetic_symtab.
6144 (pmac_xcoff_vec): Likewise.
6145 * coff64-rs6000.c (rs6000coff64_vec): Add
6146 _bfd_nodynamic_get_synthetic_symtab.
6147 (aix5coff64_vec): Likewise.
6148 * sunos.c (MY_get_synthetic_symtab): Define.
6149 * vms.c (vms_get_synthetic_symtab): Define.
6151 2004-04-22 Nick Clifton <nickc@redhat.com>
6153 * bfd.c (bfd_archive_filename): Return NULL on NULL input.
6155 2004-04-22 Peter Barada <peter@the-baradas.com>
6157 * archures.c: Add bfd_mach_mcfv4e to bfd_architecture.
6158 * bfd2-in.h: Regenerate.
6159 * cpu-m68k.c: Add 'm68k:mcfv4e' to arch_info_struct[].
6161 2004-04-21 Chris Demetriou <cgd@broadcom.com>
6163 * coff-mips.c (bfd_mips_ecoff_create_embedded_relocs): Remove.
6164 * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): Remove.
6165 * bfd-in.h (bfd_mips_ecoff_create_embedded_relocs)
6166 (bfd_mips_elf32_create_embedded_relocs): Remove prototypes
6167 * bfd-in2.h: Regenerate.
6169 2004-04-21 Bob Wilson <bob.wilson@acm.org>
6171 * elf32-xtensa.c (is_same_value): Add final_static_link argument and
6172 require relocations against a weak symbol to reference the same
6173 symbol hash entry if not a final, static link.
6174 (get_cached_value, add_value_map): Add final_static_link argument.
6175 (remove_literals): Pass final_static_link argument as needed.
6177 2004-04-21 Andrew Cagney <cagney@redhat.com>
6179 * opncls.c (_bfd_new_bfd_contained_in): Copy "iovec".
6180 (struct opncls, opncls_btell, opncls_bseek, opncls_bread)
6181 (opncls_bwrite, opncls_bclose, opncls_bflush)
6182 (opncls_bstat, opncls_iovec, bfd_openr_iovec): Implement a
6183 bfd iovec that uses function callbacks.
6184 (bfd_close): Use the iovec's bclose.
6185 * cache.c (cache_btell, cache_bseek, cache_bread, cache_bwrite)
6186 (cache_bclose, cache_bflush, cache_bstat)
6187 (cache_iovec): New functions and global variable, implement a
6188 cache "iovec", where applicable set bfd_error.
6189 (bfd_cache_init, bfd_cache_close): Set/test the bfd's iovec.
6190 * bfdio.c (struct bfd_iovec): Define.
6191 (real_read): Delete function.
6192 (bfd_bread, bfd_bread, bfd_bwrite, bfd_tell, bfd_flush, bfd_stat)
6193 (bfd_seek, bfd_get_mtime, bfd_get_size): Use the bfd's "iovec",
6194 assume that bread and bwrite set bfd_error.
6195 * bfd.c (struct bfd): Add "iovec", update comments.
6196 * bfd-in2.h, libbfd.h: Re-generate.
6198 2004-04-21 Andrew Cagney <cagney@redhat.com>
6200 * libaout.h (enum machine_type): Add M_POWERPC_NETBSD.
6202 2004-04-21 Eric Botcazou <ebotcazou@act-europe.fr>
6204 * elflink.c (elf_gc_mark_dynamic_ref_symbol): New function.
6205 (bfd_elf_gc_sections): Fail if a shared object is being created.
6206 Do not fail if dynamic sections have been created. Instead call
6207 elf_gc_mark_dynamic_ref_symbol to mark sections that contain
6208 dynamically referenced symbols. Do not mark the whole graph
6209 rooted at .eh_frame, only the section proper.
6211 2004-04-20 DJ Delorie <dj@redhat.com>
6213 * reloc.c: Add BFD_RELOC_32_SECREL.
6214 * bfd-in2.h: Regenerate.
6215 * libbfd.h: Likewise.
6216 * coff-i386.c (howto_table) [COFF_WITH_PE]: Add R_SECREL32.
6217 (coff_i386_rtype_to_howto) [COFF_WITH_PE]: Handle it.
6218 (coff_i386_reloc_type_lookup) [COFF_WITH_PE]: Likewise.
6220 2004-04-19 Jakub Jelinek <jakub@redhat.com>
6222 * elf32-sparc.c (elf32_sparc_relocate_section): Handle
6223 relocs against hidden/protected undefweak symbols properly.
6224 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
6226 2004-04-18 Mark Kettenis <kettenis@gnu.org>
6228 * libaout.h (enum machine_type): Add M_POWERPC_NETBSD.
6229 * netbsd-core.c (netbsd_core_file_p): Set architecture for PowerPC
6232 2004-04-17 Brian Ford <ford@vss.fsi.com>
6234 * peXXigen.c (_bfd_XXi_swap_aouthdr_out): Use the first non-zero
6235 filepos for the SizeOfHeaders field.
6236 (_bfd_XXi_swap_scnhdr_out): Correct section flags lossage on reloc
6238 (_bfd_XXi_swap_sym_in): Remove redundant section flags assignment.
6240 2004-04-16 Alan Modra <amodra@bigpond.net.au>
6242 * simple.c (bfd_simple_get_relocated_section_contents): Don't
6243 change reloc_done. Set and restore _cooked_size.
6246 2004-04-15 Mark Kettenis <kettenis@gnu.org>
6248 * netbsd-core.c (netbsd_core_file_p): Set architecture for VAX
6251 2004-04-15 Nick Clifton <nickc@redhat.com>
6253 * bfd.c (bfd_archive_filename): Catch NULL bfd pointers.
6255 2004-04-15 Alan Modra <amodra@bigpond.net.au>
6257 * elf64-sparc.c (sparc64_elf_check_relocs): Fix thinko last change.
6259 2004-04-15 H.J. Lu <hongjiu.lu@intel.com>
6261 * elflink.c (_bfd_elf_merge_symbol): Treat weak as strong only
6262 when it is a definition.
6264 2004-04-14 Alan Modra <amodra@bigpond.net.au>
6266 * elf32-sparc.c (elf32_sparc_relocate_section): Don't abort
6267 when statically linking PIC code.
6268 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
6270 2004-04-11 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
6272 * config.bfd: Remove mips*-*-mach3* and mips*-dec-mach3* targets.
6273 * configure.in: Remove mips-dec-bsd*, mips-dec-mach3*, mips-*-mach3*
6274 targets amd aout_mips_big_vec, aout_mips_little_vec target vectors.
6275 * configure: Regenerate.
6277 2004-04-08 Richard Sandiford <rsandifo@redhat.com>
6279 * elflink.c: Include libiberty.h.
6280 * Makefile.am (elflink.lo): Depend on libiberty.h.
6281 * Makefile.in: Regenerate.
6283 2004-04-06 Daniel Jacobowitz <drow@mvista.com>
6285 * elfxx-mips.c (MIPS_ELF_STUB_SECTION_NAME): Always use
6288 2004-04-05 H.J. Lu <hongjiu.lu@intel.com>
6290 * elfxx-ia64.c (elfNN_ia64_size_dynamic_sections): Always
6291 reserve the memory for dynamic linker
6293 2004-04-05 Mark Kettenis <kettenis@gnu.org>
6295 * netbsd-core.c (CORE_WCOOKIE_OFFSET): New define.
6296 (netbsd_core_file_p): Create a .wcookie section for OpenBSD/sparc.
6298 2004-04-02 H.J. Lu <hongjiu.lu@intel.com>
6300 * elf32-cr16c.c (elf32_cr16c_relocate_section): Use
6301 RELOC_FOR_GLOBAL_SYMBOL.
6302 (elf32_cr16c_add_symbol_hook): Remove const from Elf_Internal_Sym.
6304 2004-04-02 H.J. Lu <hongjiu.lu@intel.com>
6306 * elf32-arm.h (elf32_arm_final_link_relocate): Handle
6307 R_ARM_ALU* only if OLD_ARM_ABI is not defined.
6309 2004-04-01 Paul Brook <paul@codesourcery.com>
6311 * bfd-in.h (bfd_elf32_arm_process_before_allocation): Update.
6312 * elf32-arm.h (struct elf32_elf_section_map): New.
6313 (struct _arm_elf_section_data): New.
6314 (elf32_arm_section_data): Define.
6315 (struct elf32_arm_link_hash_table): Add byteswap_code.
6316 (elf32_arm_link_hash_table_create): Initialize byteswap_code.
6317 (bfd_elf32_arm_process_before_allocation): Add byteswap_code.
6318 (elf32_arm_post_process_headers): Set EF_ARM_BE8.
6319 (elf32_arm_output_symbol_hook, elf32_arm_new_section_hook,
6320 elf32_arm_compare_mapping, elf32_arm_write_section): New functions.
6321 (bfd_elf32_new_section_hook, elf_backend_write_section,
6322 elf_backend_link_output_symbol_hook): Define.
6324 2004-04-01 Andy Chittenden <achittenden@bluearc.com>
6326 * stabs.c (struct stab_link_includes_totals): Add field 'symb'
6327 that keeps the characters in a B_INCL..B_EINCL range.
6328 (_bfd_link_section_stabs): When computing the sum of the
6329 characters in a B_INCL..B_EINCL range also keep a copy of those
6330 characters. Use this information to distinguish between
6331 include sections that have the same sum and the same length
6332 but which are nevertheless unique.
6334 2004-03-31 Paul Brook <paul@codesourcery.com>
6336 * elf32-arm.h (elf32_arm_final_link_relocate): Add R_ARM_ALU*.
6337 * elfarm-nabi.c (elf32_arm_howto_table): Ditto.
6339 2004-03-31 Andy Chittenden <achittenden@bluearc.com>
6341 * stabs.c (struct stab_link_includes_totals): Rename field 'total'
6342 to 'sum_chars' and add field 'num_chars'.
6343 (_bfd_link_section_stabs): When computing the sum of the
6344 characters in a B_INCL..B_EINCL range also keep a count of the
6345 number of characters. Use this information to help distinguish
6346 between include sections when have the same sum but which
6347 nevertheless are still unique.
6349 2004-03-31 Mattias Engdegård <mattias@virtutech.se>
6351 * stabs.c (_bfd_link_section_stabs): Do not skip N_EXCL stabs.
6353 2004-03-30 Galit Heller <Galit.Heller@nsc.com>
6354 Tomer Levi <Tomer.Levi@nsc.com>
6356 * Makefile.am (ALL_MACHINES): Add cpu-cr16c.lo.
6357 (ALL_MACHINES_CFILES): Add cpu-cr16c.c.
6358 (BFD32_BACKENDS): Add elf32-cr16c.lo.
6359 (BFD32_BACKENDS_CFILES): Add elf32-cr16c.c.
6360 (cpu-cr16c.lo): New target.
6361 (elf32-cr16c.lo): Likewise.
6362 * Makefile.in: Regenerate.
6363 * archures.c (bfd_architecture): Add bfd_{arch,mach}_cr16c.
6364 (bfd_archures_list): Add bfd_cr16c_arch.
6365 * config.bfd: Handle cr16c-*-elf*.
6366 * configure.in: Handle bfd_elf32_cr16c_vec.
6367 * configure: Regenerate.
6368 * reloc.c: Add BFD_RELOC_16C_NUM08, BFD_RELOC_16C_NUM08_C,
6369 BFD_RELOC_16C_NUM16, BFD_RELOC_16C_NUM16_C,
6370 BFD_RELOC_16C_NUM32, BFD_RELOC_16C_NUM32_C,
6371 BFD_RELOC_16C_DISP04, BFD_RELOC_16C_DISP04_C,
6372 BFD_RELOC_16C_DISP08, BFD_RELOC_16C_DISP08_C,
6373 BFD_RELOC_16C_DISP16, BFD_RELOC_16C_DISP16_C,
6374 BFD_RELOC_16C_DISP24, BFD_RELOC_16C_DISP24_C,
6375 BFD_RELOC_16C_DISP24a, BFD_RELOC_16C_DISP24a_C,
6376 BFD_RELOC_16C_REG04, BFD_RELOC_16C_REG04_C,
6377 BFD_RELOC_16C_REG04a, BFD_RELOC_16C_REG04a_C,
6378 BFD_RELOC_16C_REG14, BFD_RELOC_16C_REG14_C,
6379 BFD_RELOC_16C_REG16, BFD_RELOC_16C_REG16_C,
6380 BFD_RELOC_16C_REG20, BFD_RELOC_16C_REG20_C,
6381 BFD_RELOC_16C_ABS20, BFD_RELOC_16C_ABS20_C,
6382 BFD_RELOC_16C_ABS24, BFD_RELOC_16C_ABS24_C,
6383 BFD_RELOC_16C_IMM04, BFD_RELOC_16C_IMM04_C,
6384 BFD_RELOC_16C_IMM16, BFD_RELOC_16C_IMM16_C,
6385 BFD_RELOC_16C_IMM20, BFD_RELOC_16C_IMM20_C,
6386 BFD_RELOC_16C_IMM24, BFD_RELOC_16C_IMM24_C,
6387 BFD_RELOC_16C_IMM32, BFD_RELOC_16C_IMM32_C.
6388 * targets.c (bfd_elf32_cr16c_vec): Declare.
6389 (bfd_target_vector): Add bfd_elf32_cr16c_vec.
6390 * cpu-cr16c.c: New file.
6391 * elf32-cr16c.c: Likewise.
6392 * libbfd.h: Regenerate.
6393 * bfd-in2.h: Likewise.
6395 2004-03-30 Jakub Jelinek <jakub@redhat.com>
6397 * elf.c (map_sections_to_segments): Fix handling of .tbss.
6399 2004-03-27 Alan Modra <amodra@bigpond.net.au>
6401 * Makefile.am: Remove all mention of elflink.h.
6402 * Makefile.in: Regenerate.
6403 * bfd-in.h (bfd_elf_discard_info): Declare.
6404 (bfd_elf32_discard_info, bfd_elf64_discard_info): Delete.
6405 * bfd-in2.h: Regenerate.
6406 * elf-bfd.h (bfd_elf32_print_symbol, bfd_elf64_print_symbol,
6407 bfd_elf32_link_record_dynamic_symbol,
6408 bfd_elf64_link_record_dynamic_symbol,
6409 _bfd_elf_link_record_dynamic_symbol, bfd_elf32_bfd_final_link,
6410 bfd_elf64_bfd_final_link, elf_link_record_local_dynamic_symbol,
6411 _bfd_elf32_link_record_local_dynamic_symbol,
6412 _bfd_elf64_link_record_local_dynamic_symbol,
6413 _bfd_elf32_gc_sections, _bfd_elf32_gc_common_finalize_got_offsets,
6414 _bfd_elf32_gc_common_final_link, _bfd_elf64_gc_common_final_link,
6415 _bfd_elf32_gc_record_vtinherit, _bfd_elf32_gc_record_vtentry,
6416 _bfd_elf64_gc_sections, _bfd_elf64_gc_common_finalize_got_offsets,
6417 _bfd_elf64_gc_record_vtinherit, _bfd_elf64_gc_record_vtentry,
6418 _bfd_elf32_reloc_symbol_deleted_p,
6419 _bfd_elf64_reloc_symbol_deleted_p): Delete.
6420 (bfd_elf_link_record_dynamic_symbol,
6421 bfd_elf_link_record_local_dynamic_symbol,
6422 bfd_elf_final_link, bfd_elf_gc_sections,
6423 bfd_elf_gc_record_vtinherit, bfd_elf_gc_record_vtentry,
6424 bfd_elf_gc_common_finalize_got_offsets, bfd_elf_gc_common_final_link,
6425 bfd_elf_reloc_symbol_deleted_p): Declare.
6426 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
6427 * elf32-arm.h: Update for changed function names. Remove local
6428 WILL_CALL_FINISH_DYNAMIC_SECTION define.
6429 * elf-hppa.h, elf-m10300.c, elf32-cris.c, elf32-d10v.c, elf32-dlx.c,
6430 * elf32-fr30.c, elf32-frv.c, elf32-h8300.c, elf32-hppa.c, elf32-i386.c,
6431 * elf32-iq2000.c, elf32-m32r.c, elf32-m68hc1x.c, elf32-m68k.c,
6432 * elf32-mcore.c, elf32-openrisc.c, elf32-ppc.c, elf32-s390.c,
6433 * elf32-sh.c, elf32-sparc.c, elf32-v850.c, elf32-vax.c,
6434 * elf32-xstormy16.c, elf32-xtensa.c, elf64-alpha.c, elf64-hppa.c,
6435 * elf64-mmix.c, elf64-ppc.c, elf64-s390.c, elf64-sh64.c, elf64-sparc.c,
6436 * elf64-x86-64.c, elfxx-ia64.c, elfxx-mips.c, elfxx-target.h: Likewise.
6437 * elfxx-target.h (bfd_elfNN_bfd_final_link): Define.
6438 (bfd_elfNN_print_symbol): Define.
6439 * elfcode.h: Don't include elflink.h.
6440 (elf_bfd_discard_info, elf_reloc_symbol_deleted_p,
6441 elf_link_record_dynamic_symbol, elf_bfd_final_link, elf_gc_sections,
6442 elf_gc_common_finalize_got_offsets, elf_gc_common_final_link,
6443 elf_gc_record_vtinherit, elf_gc_record_vtentry,
6444 elf_link_record_local_dynamic_symbol): Don't define.
6445 * elflink.c: Update for changed function names. Move elflink.h
6447 * elflink.h: Delete file.
6448 * po/SRC-POTFILES.in: Regenerate.
6449 * po/bfd.pot: Regenerate.
6451 2004-03-27 Alan Modra <amodra@bigpond.net.au>
6453 * elf64-mmix.c (mmix_elf_relocate_section): Restore code setting
6454 "name" for global syms accidentally removed in 2004-03-20 change.
6456 2004-03-27 Alan Modra <amodra@bigpond.net.au>
6458 * elf-bfd.h (struct elf_reloc_cookie): Add r_sym_shift field.
6459 * elflink.h: Replace all occurrences of sizeof (Elf_External_*)
6460 where Elf_External_* is different for 64 and 32 bit, with
6461 corresponding elf_size_info field.
6462 (struct elf_final_link_info): Use "bfd_byte *" instead
6463 of "Elf_External_Sym *" for external_syms and symbuf.
6464 (elf_link_adjust_relocs): Set up r_type_mask and r_sym_shift local
6465 vars and use instead of ELF_R_INFO and ELF_R_TYPE macros.
6466 (struct elf_link_sort_rela): Add "sym_mask" alias for "offset".
6467 (elf_link_sort_cmp1): Use sym_mask field instead of ELF_R_SYM.
6468 (elf_link_sort_cmp2): Adjust.
6469 (elf_link_sort_relocs): Set up r_sym_mask local var instead of
6470 using ELF_R_SYM macro. Set u.sym_mask.
6471 (elf_bfd_final_link): Call _bfd_elf_stringtab_init instead of macro
6472 version, elf_stringtab_init. Ditto for bfd_section_from_elf_index
6473 vs. section_from_elf_index. Adjust Elf_External_Sym pointer
6474 arithmetic. Pass bed to elf_link_flush_output_syms. Adjust
6475 Elf_External_Dyn pointer arithmentic. Use bed swap_dyn_in and
6476 swap_syn_out functions. Rearrange dyn swap in/out switch.
6477 (elf_link_output_sym): Adjust Elf_External_Sym pointer arithmentic.
6478 Pass bed to elf_link_flush_output_syms. Use bed swap_symbol_out.
6479 (elf_link_flush_output_syms): Add elf_backend_data arg.
6480 (elf_link_check_versioned_symbol): Likewise.
6481 (elf_link_output_extsym): Pass bed to elf_link_check_versioned_symbol.
6482 Adjust Elf_External_Sym pointer arithmetic. Use bed swap_symbol_out.
6483 (elf_link_input_bfd): Use bfd_section_from_elf_index. Set up
6484 r_type_mask and r_sym_shift local vars and use instead of ELF_R_SYM,
6485 ELF_R_TYPE and ELF_R_INFO macros.
6486 (elf_reloc_link_order): Select ELF32_R_INFO or ELF64_R_INFO invocation
6487 based on size rather than using ELF_R_INFO.
6488 (elf_gc_mark): Set up r_sym_shift local var and use instead of
6490 (struct alloc_got_off_arg): New.
6491 (elf_gc_common_finalize_got_offsets): Use elf_size_info instead of
6492 ARCH_SIZE. Pass get entry size down to elf_gc_allocate_got_offsets.
6493 (elf_gc_allocate_got_offsets): Adjust.
6494 (elf_reloc_symbol_deleted_p): Usee cookie.r_sym_shift instead of
6495 ELF_R_SYM. Use bfd_section_from_elf_index.
6496 (elf_bfd_discard_info): Set cookie.r_sym_shift.
6497 * elfcode.h (elf_stringtab_init, section_from_elf_index): Delete.
6498 (elf_slurp_symbol_table): Use bfd_section_from_elf_index.
6500 2004-03-26 Stan Shebs <shebs@apple.com>
6502 Remove MPW support, no longer used.
6503 * config.bfd (powerpc-*-mpw*): Remove configuration.
6504 * mpw-config.in, mpw-make.sed: Remove files.
6505 * ecoffswap.h [MPW_C]: Remove MPW-C-friendly version of code.
6507 2004-03-26 Alan Modra <amodra@bigpond.net.au>
6509 * elf64-ppc.c (elf_backend_add_symbol_hook): Define.
6510 (ppc64_elf_add_symbol_hook): New function.
6511 * elf-bfd.h (struct elf_backend_data <elf_add_symbol_hook>): Remove
6512 const from Elf_Internal_Sym param.
6513 * elflink.c (elf_link_add_object_symbols): Adjust.
6514 * elf-hppa.h (elf_hppa_add_symbol_hook): Adjust.
6515 * elf32-frv.c (elf32_frv_add_symbol_hook): Adjust.
6516 * elf32-i370.c (elf_backend_add_symbol_hook): Adjust.
6517 * elf32-m32r.c (m32r_elf_add_symbol_hook): Adjust.
6518 * elf32-m68hc1x.c (elf32_m68hc11_add_symbol_hook): Adjust.
6519 * elf32-m68hc1x.h (elf32_m68hc11_add_symbol_hook): Adjust.
6520 * elf32-ppc.c (ppc_elf_add_symbol_hook): Adjust.
6521 * elf32-sh64.c (sh64_elf_add_symbol_hook): Adjust.
6522 * elf32-v850.c (v850_elf_add_symbol_hook): Adjust.
6523 * elf64-alpha.c (elf64_alpha_add_symbol_hook): Adjust.
6524 * elf64-mmix.c (mmix_elf_add_symbol_hook): Adjust.
6525 * elf64-sh64.c (sh64_elf64_add_symbol_hook): Adjust.
6526 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Adjust.
6527 * elfxx-ia64.c (elfNN_ia64_add_symbol_hook): Adjust.
6528 * elfxx-mips.c (_bfd_mips_elf_add_symbol_hook): Adjust.
6529 * elfxx-mips.h (_bfd_mips_elf_add_symbol_hook): Adjust.
6531 2004-03-26 Alan Modra <amodra@bigpond.net.au>
6533 * elfxx-target.h (bfd_elfNN_bfd_link_add_symbols): Define.
6534 * elf-bfd.h (_bfd_elf_link_add_archive_symbols): Delete.
6535 (_bfd_elf_sort_symbol, _bfd_elf_add_dt_needed_tag): Delete.
6536 (_bfd_elf_finalize_dynstr, bfd_elf32_bfd_link_add_symbols): Delete.
6537 (bfd_elf64_bfd_link_add_symbols): Delete.
6538 (bfd_elf_link_add_symbols): Declare.
6539 * elfcode.h (elf_bfd_link_add_symbols): Delete.
6540 * elflink.c: Include safe-ctype.h.
6541 (elf_add_dt_needed_tag): Rename from _bfd_elf_add_dt_needed_tag,
6543 (elf_sort_symbol): Rename from _bfd_elf_sort_symbol, make static.
6544 (elf_finalize_dynstr): Rename from _bfd_elf_finalize_dynstr, make
6546 (elf_link_add_archive_symbols): Rename from
6547 _bfd_elf_link_add_archive_symbols, make static.
6548 (elf_link_add_object_symbols): New function. Corresponding
6549 elflink.h function converted to use elf_size_info.
6550 (bfd_elf_link_add_symbols): Likewise.
6551 (bfd_elf_size_dynamic_sections): Adjust.
6552 * elflink.h (elf_bfd_link_add_symbols): Delete.
6553 (elf_link_add_object_symbols): Delete.
6554 * elf32-gen.c (elf32_generic_link_add_symbols): Call
6555 bfd_elf_link_add_symbols.
6556 * elf64-gen.c (elf64_generic_link_add_symbols): Likewise.
6558 2004-03-25 Alan Modra <amodra@bigpond.net.au>
6560 * elflink.h (elf_link_add_object_symbols): Add DT_NEEDED for as-needed
6561 and chained shared libs only if dynsym. Clear dynsym on forced-local.
6563 * elf-bfd.h (_bfd_elf_add_dynamic_entry): Declare.
6564 (bfd_elf32_add_dynamic_entry, bfd_elf64_add_dynamic_entry): Delete.
6565 (_bfd_elf_add_dt_needed_tag): Declare.
6566 (_bfd_elf_sort_symbol): Declare.
6567 (_bfd_elf_finalize_dynstr): Declare.
6568 (RELOC_FOR_GLOBAL_SYM): Formatting.
6569 * elfcode.h (elf_add_dynamic_entry): Delete.
6570 * elflink.c (_bfd_elf_add_dynamic_entry): New function. Corresponding
6571 elflink.h function converted to use elf_size_info.
6572 (_bfd_elf_add_dt_needed_tag): Likewise.
6573 (_bfd_elf_sort_symbol): Likewise.
6574 (_bfd_elf_finalize_dynstr): Likewise.
6575 (compute_bucket_count): Likewise.
6576 (bfd_elf_size_dynamic_sections): Likewise. Check result of
6577 _bfd_elf_strtab_add before calling _bfd_elf_strtab_addref.
6578 (elf_adjust_dynstr_offsets, elf_collect_hash_codes): Moved from..
6579 * elflink.h: ..here.
6580 (sort_symbol, add_dt_needed_tag): Delete.
6581 (elf_add_dynamic_entry, elf_finalize_dynstr): Delete.
6582 (compute_bucket_count, NAME(bfd_elf,size_dynamic_sections)): Delete.
6584 * elf32-arm.h (add_dynamic_entry): Update. Remove casts.
6585 * elf32-cris.c (add_dynamic_entry): Likewise.
6586 * elf32-hppa.c (add_dynamic_entry): Likewise.
6587 * elf32-i370.c (add_dynamic_entry): Likewise.
6588 * elf32-i386.c (add_dynamic_entry): Likewise.
6589 * elf32-m32r.c (add_dynamic_entry): Likewise.
6590 * elf32-m68k.c (add_dynamic_entry): Likewise.
6591 * elf32-ppc.c (add_dynamic_entry): Likewise.
6592 * elf32-s390.c (add_dynamic_entry): Likewise.
6593 * elf32-sh.c (add_dynamic_entry): Likewise.
6594 * elf32-sparc.c (add_dynamic_entry): Likewise.
6595 * elf32-vax.c (add_dynamic_entry): Likewise.
6596 * elf32-xtensa.c (add_dynamic_entry): Likewise.
6597 * elf64-alpha.c (add_dynamic_entry): Likewise.
6598 * elf64-hppa.c (add_dynamic_entry): Likewise.
6599 * elf64-ppc.c (add_dynamic_entry): Likewise.
6600 * elf64-s390.c (add_dynamic_entry): Likewise.
6601 * elf64-sparc.c (add_dynamic_entry): Likewise.
6602 * elf64-x86-64.c (add_dynamic_entry): Likewise.
6603 * elfxx-ia64.c (add_dynamic_entry): Likewise.
6604 * elfxx-mips.c (MIPS_ELF_ADD_DYNAMIC_ENTRY): Likewise.
6605 * elf-m10300.c (_bfd_mn10300_elf_size_dynamic_sections): Likewise.
6606 * elf32-frv.c (elf32_frv_size_dynamic_sections): Likewise.
6607 * elf64-sh64.c (sh64_elf64_size_dynamic_sections): Likewise.
6609 2004-03-23 Paul Brook <paul@codesourcery.com>
6611 * elf32-arm.h (arm_print_private_bfd_data): Add EABI v3.
6613 2004-03-22 Bob Wilson <bob.wilson@acm.org>
6615 * elf32-xtensa.c (elf_xtensa_check_relocs): Remove code to read
6616 literal tables and check for relocs outside of literal pools.
6617 (elf_xtensa_make_sym_local): Don't clear ELF_LINK_NON_GOT_REF flag.
6618 (elf_xtensa_fix_refcounts): Don't check ELF_LINK_NON_GOT_REF or
6620 (elf_xtensa_size_dynamic_sections): Don't add DT_TEXTREL entry.
6621 (elf_xtensa_relocate_section): Read literal tables and check for
6622 dynamic relocations in read-only sections and not in literal pools.
6624 2004-03-23 Alan Modra <amodra@bigpond.net.au>
6627 * linker.c (bfd_wrapped_link_hash_lookup): Handle info->wrap_char.
6629 2004-03-22 Hans-Peter Nilsson <hp@axis.com>
6631 * elf32-cris.c (cris_elf_relocate_section) <case R_CRIS_16_GOTPLT,
6632 R_CRIS_16_GOTPLT>: Also error if there's no PLT for a symbol
6633 not defined by the executable, or defined in a DSO.
6634 <eliding run-time relocation of .got>: Initialize GOT entry for a
6635 function symbol or ELF_LINK_HASH_NEEDS_PLT statically in an
6637 (cris_elf_gc_sweep_hook): Improve fallthrough marking.
6638 (elf_cris_try_fold_plt_to_got): Improve head comment. Do not fold
6639 a PLT reloc to GOT for an executable.
6640 (elf_cris_adjust_dynamic_symbol): Only fold a .got.plt entry with
6641 .got for a DSO and explain why.
6642 (elf_cris_discard_excess_program_dynamics): Also lose GOT-relocs
6643 and unreferenced symbols for which a PLT is defined. Adjust
6644 dynamic-symbol pruning correspondingly, to make sure we don't lose
6645 a dynamic symbol also defined by a DSO.
6647 2004-03-22 Alan Modra <amodra@bigpond.net.au>
6649 * elf-bfd.h (RELOC_FOR_GLOBAL_SYMBOL): Add input_bfd, input_section
6650 and rel args. Group input and output args. Wrap to 80 columns.
6651 * elf-m10200.c, elf-m10300.c, elf32-arm.h, elf32-avr.c,
6652 elf32-cris.c, elf32-d10v.c, elf32-fr30.c, elf32-h8300.c,
6653 elf32-hppa.c, elf32-i386.c, elf32-i860.c, elf32-ip2k.c,
6654 elf32-iq2000.c, elf32-m68hc1x.c, elf32-m68k.c, elf32-mcore.c,
6655 elf32-msp430.c, elf32-openrisc.c, elf32-ppc.c, elf32-s390.c,
6656 elf32-sparc.c, elf32-v850.c, elf32-vax.c, elf32-xstormy16.c,
6657 elf32-xtensa.c, elf64-alpha.c, elf64-mmix.c, elf64-ppc.c,
6658 elf64-s390.c, elf64-sparc.c, elf64-x86-64.c, elfxx-ia64.c: Update
6659 RELOC_FOR_GLOBAL_SYMBOL invocation.
6661 2004-03-20 H.J. Lu <hongjiu.lu@intel.com>
6663 * elf-bfd.h (RELOC_FOR_GLOBAL_SYMBOL): Report error if
6664 unresolved symbols in objects aren't allowed.
6666 * elf-hppa.h (elf_hppa_relocate_section): Properly handle
6668 (elf_hppa_remark_useless_dynamic_symbols): Likewise.
6669 (elf_hppa_unmark_useless_dynamic_symbols):
6670 * elf32-frv.c (elf32_frv_relocate_section): Likewise.
6671 * elf32-hppa.c (elf32_hppa_size_stubs): Likewise.
6672 (elf32_hppa_relocate_section): Likewise.
6673 * elf32-i370.c (i370_elf_relocate_section): Likewise.
6674 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
6675 * elf32-sh.c (sh_elf_relocate_section): Likewise.
6676 * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
6677 * elfxx-mips.c (mips_elf_calculate_relocation): Likewise.
6679 * elf-m10200.c (mn10200_elf_relocate_section): Use
6680 RELOC_FOR_GLOBAL_SYMBOL.
6681 * elf32-avr.c (elf32_avr_relocate_section): Likewise.
6682 * elf32-d10v.c (elf32_d10v_relocate_section): Likewise.
6683 * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
6684 * elf32-h8300.c (elf32_h8_relocate_section): Likewise.
6685 * elf32-i860.c (elf32_i860_relocate_section): Likewise.
6686 * elf32-m68hc1x.c (m68hc11_get_relocation_value): Likewise.
6687 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
6688 * elf32-msp430.c (elf32_msp430_relocate_section): Likewise.
6689 * elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
6690 * elf32-v850.c (v850_elf_relocate_section): Likewise.
6691 * elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
6692 * elf64-mmix.c (mmix_elf_relocate_section): Likewise.
6694 2004-03-19 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
6696 * elf32-hppa.c (elf32_hppa_check_relocs): Handle R_PARISC_PCREL32.
6697 (final_link_relocate): Likewise.
6698 * elf-hppa.h (elf_hppa_reloc_final_type): Handle selectors for
6699 R_PARISC_PCREL32 and R_PARISC_PCREL64 relocations.
6701 2004-03-19 Alan Modra <amodra@bigpond.net.au>
6703 * Makefile.am: Run "make dep-am".
6704 * Makefile.in: Regenerate.
6705 * aclocal.m4: Regenerate.
6706 * config.in: Regenerate.
6707 * po/bfd.pot: Regenerate.
6709 2004-03-19 Alan Modra <amodra@bigpond.net.au>
6710 H.J. Lu <hongjiu.lu@intel.com>
6712 * elflink.c (_bfd_elf_merge_symbol): Revert last change. Move
6713 type and size change code to where it was previously. Remove
6714 dt_needed param. Treat old weak syms as strong if new sym is
6715 from a shared lib, even when old sym is from another shared
6716 lib. Remove unnecessary tests of oldweak and newweak. Correct
6718 (_bfd_elf_add_default_symbol): Remove dt_needed param. Update
6719 _bfd_elf_merge_symbol calls.
6720 * elflink.h (elf_link_add_object_symbols): Update calls. Remove
6721 dt_needed local var. Update comments.
6722 * elf-bfd.h (_bfd_elf_merge_symbol): Update prototype.
6723 (_bfd_elf_add_default_symbol): Likewise.
6725 * elflink.c (_bfd_elf_merge_symbol): Reinstate code to handle
6726 strong syms in one shared object overriding weak syms in another.
6728 2004-03-18 Alan Modra <amodra@bigpond.net.au>
6730 * elf-bfd.h (struct elf_obj_tdata): Delete dt_soname field. Add
6731 dyn_lib_class field. Rearrange for better packing.
6732 (elf_dt_soname): Delete.
6733 (elf_dyn_lib_class): Define.
6734 * elf.c (bfd_elf_set_dt_needed_name): Update comment.
6735 (bfd_elf_set_dt_needed_soname): Delete.
6736 (bfd_elf_set_dyn_lib_class): New function.
6737 * elflink.h (add_dt_needed_tag): New function. Split out from..
6738 (elf_link_add_object_symbols): ..here. Rename "name" to "soname".
6739 Use elf_dyn_lib_class to set dt_needed and add_needed. Move fallback
6740 initialization of soname.
6741 (elf_link_check_versioned_symbol): Test elf_dyn_lib_class instead of
6743 * bfd-in.h (enum dynamic_lib_link_class): New.
6744 (bfd_elf_set_dt_needed_soname): Delete.
6745 (bfd_elf_set_dyn_lib_class): Declare.
6746 * bfd-in2.h: Regenerate.
6748 * elflink.c (_bfd_elf_merge_symbol): Rewrite weak symbol handling.
6749 (_bfd_elf_add_default_symbol): Remove indirect BFD_ASSERTs.
6750 * elflink.h (elf_link_add_object_symbols): Don't clear dt_needed in
6751 symbol loop. Instead use add_needed to flag tag as written.
6753 2004-03-17 Nathan Sidwell <nathan@codesourcery.com>
6755 * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Correct
6756 logic for null_input_bfd detection.
6758 2004-03-17 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
6760 * config.bfd: Switch sh-*-rtems* to ELF. Add sh-*-rtemscoff*.
6762 2004-03-16 Mark Kettenis <kettenis@gnu.org>
6764 * netbsd-core.c (netbsd_core_file_p) [CORE_FPU_OFFSET]: Remove
6767 2004-03-16 Alan Modra <amodra@bigpond.net.au>
6769 * elflink.c (elf_link_read_relocs_from_section): Don't use
6770 NUM_SHDR_ENTRIES in end of reloc calc. Move NULL shdr check..
6771 (_bfd_elf_link_read_relocs): ..to here.
6772 * elf32-ppc.c (ppc_elf_relax_section): Formatting.
6774 2004-03-16 Alan Modra <amodra@bigpond.net.au>
6776 * configure.in (HOST_64BIT_TYPE, HOST_U_64BIT_TYPE): Don't override
6777 values selected in configure.host. Require both to be defined
6778 before setting BFD_HOST_64_BIT_DEFINED. Protect assignment to
6779 corresponding BFD_HOST vars with quotes.
6780 <${host64}-${target64}-${want64} in *true*>: Don't exempt gcc;
6781 Always require BFD_HOST_64_BIT_DEFINED.
6782 <file_ptr type>: Find off_t size before emitting message. Combine
6783 off_t and ftello64 conditional.
6784 * configure: Regenerate.
6786 2004-03-16 Alan Modra <amodra@bigpond.net.au>
6788 * elf32-m32r.c (m32r_elf_create_dynamic_sections): Fix pointer
6789 aliasing warning. Remove trailing whitespace throughout file.
6791 2004-03-15 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
6793 * elf-hppa.h (elf_hppa_relocate_section): Pass input_bfd instead of
6794 input_section in calls to get_dyn_name.
6795 * elf64-hppa.c (get_dyn_name): Change type of first argument to "bfd *". Use section id of first section in input BFD to build dynamic name for
6797 (elf64_hppa_check_relocs): Pass abfd in call to get_dyn_name.
6799 2004-03-15 Alan Modra <amodra@bigpond.net.au>
6801 * bfd-in.h (bfd_int64_t, bfd_uint64_t): New types.
6802 (BFD_HOST_64_BIT, BFD_HOST_U_64_BIT): Don't define here.
6803 (bfd_getb64, bfd_getl64, bfd_get_bits): Return bfd_uint64_t.
6804 (bfd_getb_signed_64, bfd_getl_signed_64): Return bfd_int64_t.
6805 (bfd_putb64, bfd_putl64, bfd_put_bits): Accept bfd_uint64_t.
6806 * configure.in (HOST_U_64BIT_TYPE): Set when sizeof long is 8.
6807 (BFD_HOST_64_BIT_DEFINED, BFD_HOST_64_BIT, BFD_HOST_U_64_BIT): Set
6809 * libbfd.c (EIGHT_GAZILLION, COERCE64): Use bfd_int64_t.
6810 (bfd_getb64): Return bfd_uint64_t. Enable when BFD_HOST_64_BIT.
6811 (bfd_getl64, bfd_getb_signed_64, bfd_getl_signed_64): Likewise.
6812 (bfd_putb64): Accept bfd_uint64_t. Enable when BFD_HOST_64_BIT.
6813 (bfd_putl64, bfd_put_bits, bfd_get_bits): Likewise.
6814 * dwarf2.c (struct attribute): Use bfd_int64_t and bfd_uint64_t.
6815 (read_8_bytes, read_indirect_string, read_address): Likewise.
6816 (read_abbrevs, parse_comp_unit): Likewise.
6817 * targets.c (struct bfd_target): Likewise.
6818 * aix386-core.c (NO_GET64, NO_PUT64, NO_GETS64): Define and use.
6819 * hppabsd-core.c: Likewise. Formatting.
6820 * hpux-core.c: Likewise.
6821 * irix-core.c: Likewise.
6822 * netbsd-core.c: Likewise.
6823 * osf-core.c: Likewise.
6824 * ptrace-core.c: Likewise.
6825 * sco5-core.c: Likewise.
6826 * trad-core.c: Likewise.
6827 * configure: Regenerate.
6828 * bfd-in2.h: Regenerate.
6830 2004-03-15 Alan Modra <amodra@bigpond.net.au>
6832 * bfd-in.h (bfd_getb64, bfd_getl64): Replace bfd_byte* with void*.
6833 (bfd_getb32, bfd_getl32, bfd_getb16, bfd_getl16): Likewise.
6834 (bfd_getb_signed_64, bfd_getl_signed_64): Likewise.
6835 (bfd_getb_signed_32, bfd_getl_signed_32): Likewise.
6836 (bfd_getb_signed_16, bfd_getl_signed_16): Likewise.
6837 (bfd_putb64, bfd_putl64, bfd_putb32, bfd_putl32): Likewise.
6838 (bfd_putb16, bfd_putl16, bfd_get_bits, bfd_put_bits): Likewise.
6839 * libbfd.c: Likewise in function definitions.
6840 (bfd_put_8): Mask with 0xff rather than casting to char.
6841 (bfd_putb16, bfd_putl16, bfd_putb32, bfd_putl32): Likewise.
6842 (bfd_putb64, bfd_putl64, bfd_put_bits): Likewise.
6843 (H_PUT_64, H_PUT_32, H_PUT_16, H_PUT_8): Remove casts, simplify.
6844 (H_PUT_S64, H_PUT_S32, H_PUT_S16, H_PUT_S8): Likewise.
6845 (H_GET_64, H_GET_32, H_GET_16, H_GET_8): Likewise.
6846 (H_GET_S64, H_GET_S32, H_GET_S16, H_GET_S8): Likewise.
6847 * libaout.h (H_PUT_64 H_PUT_32, H_PUT_16): Remove casts, simplify.
6848 (H_PUT_S64, H_PUT_S32, H_PUT_S16): Likewise.
6849 (H_GET_64, H_GET_32, H_GET_16): Likewise.
6850 (H_GET_S64, H_GET_S32, H_GET_S16): Likewise.
6851 * archive.c (do_slurp_coff_armap): Update swap prototype.
6852 * coff-tic54x.c (tic54x_getl32): Replace bfd_byte* with void*.
6853 (tic54x_getl_signed_32): Likewise.
6854 (tic54x_putl32): Likewise. Mask with 0xff rather than casting to char.
6855 * mach-o.c (bfd_mach_o_read_header): Update get32 prototype.
6856 * pdp11.c (bfd_getp32): Make static, replace bfd_byte* with void*.
6857 (bfd_getp_signed_32, bfd_putp32): Likewise.
6858 * targets.c (struct bfd_target): Use void* in place of bfd_byte* for
6859 bfd_getx64, bfd_getx_signed_64, bfd_putx64, bfd_getx32,
6860 bfd_getx_signed_32, bfd_putx32, bfd_getx16, bfd_getx_signed_16,
6861 bfd_putx16, bfd_h_getx64, bfd_h_getx_signed_64, bfd_h_putx64,
6862 bfd_h_getx32, bfd_h_getx_signed_32, bfd_h_putx32, bfd_h_getx16,
6863 bfd_h_getx_signed_16, bfd_h_putx16.
6864 * aix386-core.c (NO_GET, NO_GETS, NO_PUT): Update prototypes.
6865 * hppabsd-core.c: Similarly. Rename NO_SIGNED_GET to NO_GETS.
6866 * hpux-core.c: Likewise.
6867 * irix-core.c: Likewise.
6868 * netbsd-core.c: Likewise.
6869 * osf-core.c: Likewise.
6870 * ptrace-core.c: Likewise.
6871 * sco5-core.c: Likewise.
6872 * trad-core.c: Likewise.
6873 * bfd-in2.h: Regenerate.
6875 2004-03-15 Matt Thomas <matt@3am-software.com>
6877 * config.bfd: Add x86-64 vector to NetBSD/i386 if 64bit BFD is
6880 2004-03-13 Mark Kettenis <kettenis@gnu.org>
6882 * config.bfd: Add x86_64-*-openbsd*.
6883 * configure.in (x86_64-*-openbsd*): Set COREFILE to
6885 * configure: Regenerate.
6887 2004-03-12 Nick Clifton <nickc@redhat.com>
6888 Dave Murphy <wintermute2k4@ntlworld.com>
6890 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Skip most checks
6891 if the input bfd does not contain any code.
6893 2004-03-09 Steve Ellcey <sje@cup.hp.com>
6895 * elfxx-ia64.c (plt_full_entry): Change ld8 to ld8.acq.
6897 2004-03-05 Fred Fish <fnf@redhat.com>
6899 * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Just force
6900 mips16 symbols to be even rather than testing first for even/odd.
6901 (_bfd_mips_elf_link_output_symbol_hook): Ditto.
6903 2004-03-05 Nathan Sidwell <nathan@codesourcery.com>
6905 * elf.c (map_sections_to_segments): Ignore .tbss sections for
6908 2004-03-03 Alexandre Oliva <aoliva@redhat.com>
6910 * elflink.c (bfd_elf_record_link_assignment): Mark undefweak and
6911 undefined symbols as hash_new.
6913 2003-03-03 Andrew Stubbs <andrew.stubbs@superh.com>
6915 * archures.c: Add bfd_mach_sh4_nommu_nofpu.
6917 * elf32-sh.c: Ditto.
6918 * bfd-in2.h: Regenerate.
6920 2004-03-02 Alexandre Oliva <aoliva@redhat.com>
6922 * elf32-frv.c (struct frv_pic_relocs_info): Added fixups and
6924 (_frv_count_got_plt_entries): Initialize them.
6925 (frv_pic_relocs_info_find): Add insert argument. Adjust all
6927 (frv_pic_relocs_info_for_global): Likewise.
6928 (frv_pic_relocs_info_for_local): Likewise.
6929 (frv_pic_merge_early_relocs_info): New.
6930 (_frv_resolve_final_relocs_info): Use it in case one entry maps to
6932 (_frv_add_dyn_reloc): Add entry argument. Adjust all callers.
6933 Check that we don't exceed the allocated count for entry.
6934 (_frv_add_rofixup): Likewise.
6935 (_frv_emit_got_relocs_plt_entries): Adjust for coding standards.
6936 (elf32_frv_finish_dynamic_sections): Improve error message in case
6937 we emit too few rofixup entries.
6939 2004-03-01 Richard Sandiford <rsandifo@redhat.com>
6941 * archures.c (bfd_mach_fr450): New.
6942 * bfd-in2.h: Regenerate.
6943 * cpu-frv.c (arch_info_450): New bfd_arch_info_type.
6944 (arch_info_500): Link to it.
6945 * elf32-frv.c (elf32_frv_machine, frv_elf_merge_private_bfd_data)
6946 (frv_elf_print_private_bfd_data): Handle fr405 and fr450 header flags.
6947 (frv_elf_arch_extension_p): New function.
6948 (frv_elf_merge_private_bfd_data): Use it.
6950 2004-02-28 H.J. Lu <hongjiu.lu@intel.com>
6952 * elf-bfd.h (_bfd_elf_link_add_archive_symbols): New prototype.
6954 * elflink.h (is_global_data_symbol_definition): Moved to
6956 (elf_link_is_defined_archive_symbol): Likewise.
6957 (elf_link_add_archive_symbols): Likewise. Renamed to
6958 _bfd_elf_link_add_archive_symbols.
6960 * elflink.c (elf_link_is_defined_archive_symbol): Get the size
6961 of ELF symbol table entry from backend.
6962 (_bfd_elf_link_add_archive_symbols): Call bfd_link_add_symbols
6963 instead of elf_link_add_object_symbols.
6965 2004-02-27 Alexandre Oliva <aoliva@redhat.com>
6967 * elf-bfd.h (struct elf_backend_data): Added
6968 elf_backend_can_make_relative_eh_frame,
6969 elf_backend_can_make_lsda_relative_eh_frame and
6970 elf_backend_encode_eh_address.
6971 (_bfd_elf_encode_eh_address): Declare.
6972 (_bfd_elf_can_make_relative): Declare.
6973 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Use new
6974 hooks to decide whether to attempt to make_relative and
6976 (_bfd_elf_write_section_eh_frame_hdr): Call encode_eh_address.
6977 (_bfd_elf_can_make_relative): New.
6978 (_bfd_elf_encode_eh_address): New.
6979 * elf32-frv.c (frv_elf_use_relative_eh_frame): New.
6980 (frv_elf_encode_eh_address): New.
6981 (elf_backend_can_make_relative_eh_frame): Define.
6982 (elf_backend_can_make_lsda_relative_eh_frame): Define.
6983 (elf_backend_encode_eh_address): Define.
6985 (elf_backend_can_make_relative_eh_frame): Define.
6986 (elf_backend_can_make_lsda_relative_eh_frame): Define.
6987 (elf_backend_encode_eh_address): Define.
6988 (elfNN_bed): Add them.
6990 2004-02-27 Alexandre Oliva <aoliva@redhat.com>
6992 * elf32-frv.c (elf32_frv_howto_table) <R_FRV_LABEL16>: Set
6993 complain_on_overflow to signed.
6995 2004-02-27 H.J. Lu <hongjiu.lu@intel.com>
6997 * elflink.h (sort_symbol): New.
6998 (elf_link_add_object_symbols): Use a sorted symbol array for
7001 2004-02-27 Jakub Jelinek <jakub@redhat.com>
7003 * elf32-s390.c (allocate_dynrelocs): Use SYMBOL_REFERENCES_LOCAL
7004 for pc relative relocs.
7005 (elf_s390_relocate_section): Likewise.
7006 * elf64-s390.c (allocate_dynrelocs): Use SYMBOL_REFERENCES_LOCAL
7007 for pc relative relocs.
7008 (elf_s390_relocate_section): Likewise.
7010 2004-02-26 H.J. Lu <hongjiu.lu@intel.com>
7012 * elfxx-ia64.c (elfNN_ia64_check_relocs): Fix call to
7015 2004-02-25 H.J. Lu <hongjiu.lu@intel.com>
7017 * elfxx-ia64.c (elfNN_ia64_dyn_reloc_entry): Add the reltext.
7018 field to track if a relocation is against readonly section.
7019 (count_dyn_reloc): Take a new argument for rent->reltext.
7020 (elfNN_ia64_check_relocs): Adjust call to count_dyn_reloc.
7021 (get_reloc_section): Don't set ia64_info->reltext here.
7022 (allocate_dynrel_entries): Set ia64_info->reltext here.
7024 2004-02-24 Alexandre Oliva <aoliva@redhat.com>
7026 * elf32-frv.c (FRV_SYM_LOCAL): Weak undefined doesn't imply local.
7027 (_frv_emit_got_relocs_plt_entries): Decay relocation to protected
7028 function's descriptor to symbol+offset, and map local undefweak
7029 symbol to NULL function descriptor.
7030 (elf32_frv_relocate_section): Likewise.
7032 2004-02-23 Mark Kettenis <kettenis@gnu.org>
7034 * libaout.h (enum machine_type): Add M_SPARC64_NETBSD and
7036 * netbsd-core.c (M_SPARC64_OPENBSD): Define.
7037 (netbsd_core_file_p): Set architecture from machine ID for
7040 2004-02-23 Jakub Jelinek <jakub@redhat.com>
7042 * elflink.h (size_dynamic_sections): If not adding DT_FLAGS and
7043 DF_BIND_NOW is set in info->flags, create DT_BIND_NOW dynamic entry.
7045 2004-02-21 H.J. Lu <hongjiu.lu@intel.com>
7047 * elflink.c (_bfd_elf_merge_symbol): Properly handle undefined
7048 symbols with non-default visibility.
7050 2004-02-21 Danny Smith <daanysmith@users.sourceforge.net>
7052 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Clear
7053 IMAGE_SCN_MEM_WRITE on known sections only.
7055 2004-02-20 Jakub Jelinek <jakub@redhat.com>
7057 * elf32-ppc.c (allocate_dynrelocs): Create dynsym for undef weak
7058 symbols used in PIE relocs.
7060 2004-02-19 Jakub Jelinek <jakub@redhat.com>
7062 * elf32-sparc.c (elf32_sparc_finish_dynamic_sections): Clear
7065 2004-02-18 Daniel Jacobowitz <drow@mvista.com>
7067 * configure.in: Update version to 2.15.90.
7068 * configure: Regenerate.
7070 2004-02-17 Daniel Jacobowitz <drow@mvista.com>
7071 Richard Sandiford <rsandifo@redhat.com>
7073 * elfxx-mips.c (mips_elf_calculate_relocation): Use
7074 _bfd_elf_symbol_refs_local_p to decide whether to decay
7075 a GOT_PAGE/GOT_OFST pair to GOT_DISP/addend.
7076 (_bfd_mips_elf_check_relocs): Add a global GOT entry for GOT_PAGE
7077 relocs if the symbol wasn't defined by a regular object file.
7078 Don't check the symbol's dynindx.
7080 2004-02-16 Andrew Cagney <cagney@redhat.com>
7082 * bfd-in.h (file_ptr, ufile_ptr): Configure type using
7084 * bfd-in2.h: Re-generate.
7086 2004-02-14 Andrew Cagney <cagney@redhat.com>
7088 * configure.host (HDEFINES): When hppa*-*-hpux*, define
7089 _LARGEFILE64_SOURCE.
7091 2004-02-13 Andrew Cagney <cagney@redhat.com>
7093 * elf.c (vma_page_aligned_bias): New function.
7094 (assign_file_positions_except_relocs)
7095 (assign_file_positions_for_segments): Replace broken modulo
7096 arithmetic with call to vma_page_aligned_bias.
7098 2004-02-11 Andrew Cagney <cagney@redhat.com>
7100 * bfd-in.h: Update copyright.
7101 (bfd_tell): Change return type to file_ptr.
7102 * bfd-in2.h: Re-generate.
7103 * cache.c: Update copyright.
7104 (bfd_cache_lookup_worker): Use real_fseek, do not cast offset
7106 (close_one): Use real_ftell.
7107 * bfdio.c: Update copyright.
7108 (real_ftell, real_fseek): New functions.
7109 (bfd_tell): Use real_fseek and real_ftell, change return type to
7111 (bfd_seek): Use real_ftell and real_fseek, change type of
7112 file_position to a file_ptr.
7113 * libbfd-in.h: Update copyright.
7114 (real_ftell, real_fseek): Declare.
7115 * libbfd.h: Re-generate.
7117 * configure.in (AC_CHECK_FUNCS): Check for ftello, ftello64,
7118 fseeko and fseeko64. Determine bfd_file_ptr.
7119 * configure: Re-generate.
7120 * config.in: Re-generate.
7122 2004-02-09 Anil Paranjpe <anilp1@KPITCummins.com>
7124 * coff-h8300.c: Added comments about relaxation for ldc.w and stc.w.
7125 * elf32-h8300.c: Likewise.
7127 2004-02-09 Christian Vogel <vogelchr@vogel.cx>
7128 Nick Clifton <nickc@redhat.com>
7130 * elf64-alpha.c (elf64_alpha_calc_got_offsets_for_symbol): Catch
7131 GOT entries with no associated GOT subsection.
7133 2004-02-09 Richard Sandiford <rsandifo@redhat.com>
7135 * bfd-elf.h (elf_backend_name_local_section_symbols): New hook.
7136 * elf.c (swap_out_syms): Use it to decide whether local section
7137 symbols should be named.
7138 * elfxx-target.h (elf_backend_name_local_section_symbols): New macro.
7139 * elfxx-mips.h (_bfd_mips_elf_name_local_section_symbols): Declare.
7140 (elf_backend_name_local_section_symbols): Define.
7141 * elfxx-mips.c (_bfd_mips_elf_name_local_section_symbols): New.
7143 2004-01-30 H.J. Lu <hongjiu.lu@intel.com>
7145 * elfxx-ia64.c (elfNN_ia64_relax_brl): New function.
7146 (elfNN_ia64_relax_section): Optimize brl to br during the relax
7149 2004-01-30 Alexandre Oliva <aoliva@redhat.com>
7151 * elf32-frv.c (elf32_frv_always_size_sections): Initialize pointer
7152 to bfd_link_hash_entry passed by reference to
7153 _bfd_generic_link_add_one_symbol.
7155 2004-01-25 H.J. Lu <hongjiu.lu@intel.com>
7157 * elfxx-ia64.c (elfNN_ia64_relocate_section): Disallow imm
7158 relocations against dynamic symbols.
7160 2004-01-23 Daniel Jacobowitz <drow@mvista.com>
7162 * elf32-arm.h (elf32_arm_check_relocs): Revert part of 2004-01-13
7165 2004-01-21 Tom Rix <tcrix@worldnet.att.net>
7167 * reloc.c: New 5 bit reloc, BFD_RELOC_M68HC12_5B, for m68hc12 movb/movw.
7168 * bfd-in2.h, libbfd.h: Rebuilt.
7170 2004-01-20 Danny Smith <dannysmith@users.sourceforge.net>
7172 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Don't remove
7173 IMAGE_SCN_MEM_WRITE flag from .text section if WP_TEXT
7174 flag has been cleared.
7176 2004-01-19 Kazu Hirata <kazu@cs.umass.edu>
7178 * coff-h8300.c: Add and adjust comments about relaxation.
7179 * elf32-h8300.c: Likewise.
7181 2004-01-16 Kazu Hirata <kazu@cs.umass.edu>
7183 * coff-h8300.c: Fix comment typos.
7184 * elf32-h8300.c: Likewise.
7186 2004-01-16 Kazu Hirata <kazu@cs.umass.edu>
7188 * coff-h8300.c: Add comments about relaxation.
7189 * elf32-h8300.c: Likewise.
7191 2004-01-14 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
7193 * acinclude.m4: Quote names of macros to be defined by AC_DEFUN
7195 * aclocal.m4: Regenerate.
7196 * configure: Regenerate.
7198 2004-01-13 Ian Lance Taylor <ian@wasabisystems.com>
7200 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Call
7201 mips_elf64_rtype_to_howto instead of using howto_table.
7203 2004-01-13 Daniel Jacobowitz <drow@mvista.com>
7205 * elf32-arm.h (elf32_arm_final_link_relocate): Check that we created
7207 (elf32_arm_check_relocs): Don't increment the PLT refcount for
7208 relocs which would not use the PLT.
7210 2004-01-13 Alan Modra <amodra@bigpond.net.au>
7212 * elf64-ppc.c (ppc64_elf_check_relocs): Ignore !SEC_ALLOC relocs.
7213 (ppc64_elf_gc_sweep_hook): Likewise.
7214 (ppc64_elf_size_dynamic_sections): Test for .plt directly.
7216 2004-01-12 Anil Paranjpe <anilp1@KPITCummins.com>
7218 Adds linker relaxation support for bit manipulation insns like
7219 band, bclr, biand, bild, bior, bist, bixor, bld, bnot, bor, bset,
7221 * elf32-h8300.c: Opcode for bit manipulation insn is checked in
7222 elf32_h8_relax_section function while relxation for aa:16 and aa:32.
7223 * coff-h8300.c: Opcode for bit manipulation insn is checked in
7224 h8300_reloc16_extra_cases function while relxation for aa:16 and aa:32.
7226 2004-01-12 Alan Modra <amodra@bigpond.net.au>
7228 * dwarf2.c: Convert to C90, remove unneeded casts and prototypes.
7230 2004-01-11 Kazu Hirata <kazu@cs.umass.edu>
7232 * elf32-h8300.c: Fix formatting.
7234 2004-01-11 Kazu Hirata <kazu@cs.umass.edu>
7236 * elf32-cris.c (cris_elf_gc_sweep_hook): Return early if no
7237 dynamic object is present. Declare r_symndx and h in an inner
7239 * elf32-vax.c (elf_vax_gc_sweep_hook): Likewise.
7241 2004-01-09 Daniel Jacobowitz <drow@mvista.com>
7243 * elf32-arm.h (struct elf32_arm_relocs_copied): Remove pc_count.
7244 (elf32_arm_copy_indirect_symbol): Don't copy pc_count.
7245 (elf32_arm_final_link_relocate): Handle PLT32 and PC24 relocs
7246 identically. Do not emit PC24 relocations for shared libraries.
7247 (elf32_arm_gc_sweep_hook): Handle PLT32 and PC24 relocs
7248 identically. Don't adjust pc_count.
7249 (elf32_arm_check_relocs): Handle PLT32 and PC24 relocs identically.
7250 Set ELF_LINK_HASH_NEEDS_PLT for both. Don't adjust pc_count; don't
7251 adjust count for branch relocations.
7252 (allocate_dynrelocs): Correct typo in call to
7253 WILL_CALL_FINISH_DYNAMIC_SYMBOL. Never allocate space for
7254 PC24 or PLT32 relocs when linking.
7256 2004-01-09 Dmitry Semyonov <Dmitry.Semyonov@oktet.ru>
7258 * coff-arm.c (aoutarm_std_reloc_howto): [ARM_WINCE] Synchronize ARM_26D
7259 relocation howto with ARM_26 one for consistency.
7260 (coff_arm_relocate_section): Set partial_inplace for ARM_26 relocations
7261 that will be converted to ARM_26D ones, since we always want 'done'
7262 relocations to be reflected in section's data.
7263 (coff_arm_relocate_section): [ARM_WINCE] Quick fix for BL instruction
7265 (_bfd_final_link_relocate): Do not modify "inplace" data, if not
7268 2004-01-08 Dmitry Semyonov <Dmitry.Semyonov@oktet.ru>
7270 * coff-arm.c (coff_arm_relocate_section): Do not alter relocs that
7271 are not partial_inplace during a relocatable link.
7273 2004-01-08 Kazu Hirata <kazu@cs.umass.edu>
7275 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Return early
7276 if no dynamic object is present. Declare r_symndx and h in an
7279 2004-01-07 H.J. Lu <hongjiu.lu@intel.com>
7281 * elfxx-ia64.c (elfNN_ia64_relax_section): Don't install
7282 trampoline if it is known out of range.
7284 2004-01-06 Alexandre Oliva <aoliva@redhat.com>
7286 2003-12-17 Alexandre Oliva <aoliva@redhat.com>
7287 * elf32-frv.c (_frv_osec_readonly_p): New.
7288 (_frv_emit_got_relocs_plt_entries): Don't emit rofixup for
7290 (_frv_count_got_plt_entries): Adjust expected count accordingly.
7291 (elf32_frv_relocate_section): Likewise. Error out if attempting
7292 to emit rofixups or dynamic relocs in read-only segments. Use
7293 _bfd_elf_section_offset to adjust r_offsets in rofixups and
7294 dynamic relocations.
7295 2003-12-12 Alexandre Oliva <aoliva@redhat.com>
7296 * elf32-frv.c (elf32_frv_relocate_section): Compute dynamic
7297 relocations or fixups involving merged sections correctly. Avoid
7298 crash when undefined symbol is referenced by R_FRV_32 or
7299 R_FRV_FUNCDESC_VALUE.
7300 2003-12-02 Alexandre Oliva <aoliva@redhat.com>
7301 * elf32-frv.c (elf32_frv_relocate_section): Add output_offset of
7302 input section holding local symbol to addend of R_FRV_32 or
7303 R_FRV_FUNCDESC_VALUE dynamic relocation.
7304 2003-11-27 Alexandre Oliva <aoliva@redhat.com>
7305 * elf32-frv.c (elf32_frv_modify_segment_map): Add link info arg.
7306 (elf32_frv_always_size_sections): Don't store pointer to
7307 __stacksize symbol in sec_info.
7308 (elf32_frv_modify_segment_map): Look it up here.
7309 2003-11-26 Alexandre Oliva <aoliva@redhat.com>
7310 * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Emit the address
7311 of the lazy PLT entry, not only its offset, as the low word of a
7312 function descriptor.
7313 2003-11-10 Alexandre Oliva <aoliva@redhat.com>
7314 * elf32-frv.c (elf32_frv_always_size_sections): Define __stacksize
7315 if a hash table entry already exists but is not a definition.
7316 2003-11-05 Alexandre Oliva <aoliva@redhat.com>
7317 * elf32-frv.c (frv_elf_link_hash_table_create): Use bfd_zalloc.
7318 (_frv_add_rofixup): Don't inline.
7319 (_frv_emit_got_relocs_plt_entries): Use NULL as funcdesc address
7320 for undefweak symbols.
7321 (elf32_frv_relocate_section): Avoid crash while computing
7322 relocation when linking with shared library. Only emit rofixups
7323 and dynamic relocations for alloc&load sections. Mark binaries
7324 with inter-segment relocations for relocation as a unit.
7325 (_frv_create_got_section): Rename .rofixup.got to .rofixup.
7326 (DEFAULT_STACK_SIZE): New.
7327 (_frv_count_got_plt_entries): Fix thinko in deciding whether to
7328 emit rofixups or dynamic relocs when linking dynamic non-PIE
7330 (elf32_frv_size_dynamic_sections): Generate rofixup on PIEs and
7331 shared libs too. Reserve the last entry for the GOT pointer.
7332 (elf32_frv_finish_dynamic_sections): Emit it.
7333 (elf32_frv_always_size_sections): New.
7334 (elf32_frv_modify_segment_map): New.
7335 (elf32_frv_check_relocs): Reserve relocs32 space only in ALLOC
7337 (frv_elf_merge_private_bfd_data): Clear PIC bit if FDPIC is set.
7338 (frv_elf_print_private_bfd_data): Handle FDPIC and LIBPIC.
7339 (elf_backend_always_size_sections): New.
7340 (elf_backend_modify_segment_map): New.
7341 2003-10-31 Alexandre Oliva <aoliva@redhat.com>
7342 * config.bfd: Added frv-*-*linux*.
7343 * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Use idx 0 for
7344 ABS section, instead of crashing.
7345 (elf32_frv_relocate_section): Don't crash before warning about
7346 different segments in non-PIC relocation.
7347 2003-10-17 Alexandre Oliva <aoliva@redhat.com>
7348 * elf32-frv.c (elf32_frv_relocate_section): Don't warn on LABEL24
7349 relocs to undefweak symbols.
7350 (elf32_frv_relocate_section): Ditto for undefined symbols.
7351 2003-10-06 Alexandre Oliva <aoliva@redhat.com>
7352 * elf32-frv.c (elf32_frv_create_dynamic_sections): Make sure
7353 gotfixup section was created.
7354 2003-09-30 Alexandre Oliva <aoliva@redhat.com>
7355 * elf32-frv.c (elf32_frv_howto_table): Change GOT12,
7356 FUNCDESC_GOT12, GOTOFF12 and FUNCDESC_GOTOFF12 to
7357 complain_overflow_signed.
7358 * elf32-frv.c (_frv_add_rofixup): Do not error out if contents
7359 have not been allocated.
7360 (_frv_emit_got_relocs_plt_entries): Return non-void. Assert
7361 privfd only if dynamic sections were created.
7362 (elf32_frv_relocate_section): Compute gprel_segment, and use it
7363 for GPREL relocs. When linking relocatable FDPIC executables,
7364 emit warnings for relocations that would be illegal on PIE or
7365 shared libraries. Emit rofixup for R_FRV_32 only if input object
7367 (_frv_create_got_section): Define _gp symbol in the rofixup
7369 (elf32_frv_finish_dynamic_sections): If rofixups needed but
7370 dynamic sections missing, error out requesting -melf32frvfd.
7371 2003-09-19 Alexandre Oliva <aoliva@redhat.com>
7372 * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Rearrange
7373 computation of addends from section and global or local symbol
7374 value. Change return type to bfd_boolean, and return a failure if
7375 a dynamic FUNCDESC or FUNCDESC_VALUE relocation that requires a
7376 nonzero addend is required.
7377 (elf32_frv_relocate_section): Likewise. Print error for
7378 unsupported nonzero addends.
7379 2003-09-18 Alexandre Oliva <aoliva@redhat.com>
7380 * elf32-frv.c (FRV_SYM_LOCAL): In the absence of dynamic sections,
7381 force everything local.
7382 (_frv_emit_got_relocs_plt_entries): Cope with NULL sec.
7383 * elf32-frv.c (struct frv_elf_link_hash_table): Added sgotfixup.
7384 (frv_gotfixup_section): New.
7385 (FRV_SYM_LOCAL): Accept undefweak and local common symbols.
7386 (struct frv_pic_relocs_info): Split relocs into relocs32, relocsfd
7388 (_frv_add_rofixup): New.
7389 (_frv_emit_got_relocs_plt_entries): Generate fixups for non-PIE
7390 fdpic executables. Use FRV_SYM_LOCAL more widely to simplify and
7391 improve some ugly conditions.
7392 (elf32_frv_relocate_section): Likewise. Reject inter-segment
7393 relocations in fdpic.
7394 (_frv_create_got_section): Create .rofixup.got section.
7395 (struct _frv_dynamic_got_info): Added fixups.
7396 (_frv_count_got_plt_entries): Account in-GOT relocations into
7397 relocs32, relocsfd and relocsfdv. Account them into relocs or
7398 fixups, as appropriate.
7399 (elf32_frv_size_dynamic_sections): Size rofixup section. Simplify
7401 (elf32_frv_finish_dynamic_sections): Verify that the right number
7402 of relocations and fixups was generated.
7403 (elf32_frv_check_relocs): Compute relocs32, relocsfd and
7405 * elf32-frv.c (FRV_SYM_LOCAL): New macro, used instead of
7406 SYMBOL_CALLS_LOCAL and SYMBOL_REFERENCES_LOCAL.
7407 (FRV_FUNCDESC_LOCAL): New macro, used to decide whether a function
7408 descriptor of a (formerly-)global symbol is local.
7409 (struct frv_pic_relocs_info): Adjust comments.
7410 (_frv_emit_got_relocs_plt_entries): Adjust.
7411 (elf32_frv_relocate_section): Likewise.
7412 (_frv_count_got_plt_entries): Likewise.
7413 * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Don't add global
7414 symbol's value to addend in the common preamble. Decay dynamic
7415 symbols to section+offset if they bind or call locally, for GOT
7416 and FUNCDESC_VALUE, respectively.
7417 (elf32_frv_relocate_section): Likewise.
7418 (elf32_frv_check_relocs): Don't register as dynamic symbols of
7419 internal or hidden visibility.
7420 2003-09-17 Alexandre Oliva <aoliva@redhat.com>
7421 * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Get addend as
7422 argument, so as to not call _bfd_elf_rel_local_sym to compute it.
7423 (elf32_frv_relocate_section): Pass relocation addend in. Use
7424 original relocation addend to look up the got relocs/plt entries
7425 table. Do not call _bfd_elf_rel_local_sym. Don't error out when
7426 processing relocations that reference .scommon symbols.
7427 2003-09-15 Alexandre Oliva <aoliva@redhat.com>
7428 Introduce support for dynamic linking.
7429 * elf32-frv.c (R_FRV_FUNCDESC_VALUE): Mark it as 64 bits.
7430 (elf32_frv_rel_32_howto, elf32_frv_rel_funcdesc_howto,
7431 elf32_frv_rel_funcdesc_value_howto): New REL descriptors.
7432 (frv_reloc_type_lookup): Return REL howtos for executables and
7434 (frv_info_to_howto_rel): New.
7435 (struct frv_elf_link_hash_table): New.
7436 (frv_hash_table, frv_got_section, frv_gotrel_section,
7437 frv_plt_section, frv_pltrel_section, frv_relocs_info,
7438 frv_got_initial_offset, frv_plt_initial_offset): New macros.
7439 (frv_elf_link_hash_table_create): New.
7440 (struct frv_pic_relocs_info): New.
7441 (frv_pic_relocs_info_hash, frv_pic_relocs_info_eq): New.
7442 (frv_pic_relocs_info_find): New.
7443 (frv_pic_relocs_info_for_global, frv_pic_relocs_info_for_local):
7445 (FRV_LZPLT_BLOCK_SIZE, FRV_LZPLT_RESOLVE_LOC): New.
7446 (_frv_add_dyn_reloc, _frv_osec_to_segment): New.
7447 (_frv_emit_got_relocs_plt_entries): New.
7448 (elf32_frv_relocate_section): Add support for dynamic linking.
7449 Handle new relocations.
7450 (_frv_create_got_section): New.
7451 (elf32_frv_create_dynamic_sections): New.
7452 (ELF_DYNAMIC_INTERPRETER): New.
7453 (struct _frv_dynamic_got_info): New.
7454 (_frv_count_got_plt_entries): New.
7455 (struct _frv_dynamic_got_plt_info): New.
7456 (_frv_compute_got_alloc_data): New.
7457 (_frv_get_got_entry, _frv_get_fd_entry): New.
7458 (_frv_assign_got_entries, _frv_assign_plt_entries): New.
7459 (_frv_resolve_final_relocs_info): New.
7460 (elf32_frv_size_dynamic_sections): New.
7461 (elf32_frv_finish_dynamic_sections): New.
7462 (elf32_frv_adjust_dynamic_symbol): New.
7463 (elf32_frv_finish_dynamic_symbol): New.
7464 (elf32_frv_check_relocs): Handle new relocs. Explain how the
7466 (elf_info_to_howto_rel): Define.
7467 (bfd_elf32_bfd_link_hash_table_create): Define.
7468 (elf_backend_create_dynamic_sections): Define.
7469 (elf_backend_adjust_dynamic_symbol): Define.
7470 (elf_backend_size_dynamic_sections): Define.
7471 (elf_backend_finish_dynamic_symbol): Define.
7472 (elf_backend_finish_dynamic_sections): Define.
7473 (elf_backend_want_got_sym): Define.
7474 (elf_backend_got_header_size): Define.
7475 (elf_backend_want_got_plt): Define.
7476 (elf_backend_plt_readonly): Define.
7477 (elf_backend_want_plt_sym): Define.
7478 (elf_backend_plt_header_size): Define.
7479 (elf_backend_may_use_rel_p): Define.
7480 (elf_backend_may_use_rela_p): Define.
7481 (elf_backend_default_use_rela_p): Define.
7482 2003-08-08 Alexandre Oliva <aoliva@redhat.com>
7483 * elf32-frv.c (R_FRV_FUNCDESC_VALUE, R_FRV_FUNCDESC_GOTOFF12,
7484 R_FRV_FUNCDESC_GOTOFFHI, R_FRV_FUNCDESC_GOTOFFLO, R_FRV_GOTOFF12,
7485 R_FRV_GOTOFFHI, R_FRV_GOTOFFLO): New.
7486 (frv_reloc_map): Map the corresponding BFD relocs to them.
7487 (frv_reloc_type_lookup): ... and back to BFD relocs.
7488 * reloc.c: New relocs.
7489 * bfd-in2.h, libbfd.h: Rebuilt.
7490 2003-08-04 Alexandre Oliva <aoliva@redhat.com>
7491 * elf32-frv.c (R_FRV_GOT12, R_FRV_GOTHI, R_FRV_GOTLO,
7492 R_FRV_FUNCDESC, R_FRV_FUNCDESC_GOT12, R_FRV_FUNCDESC_GOTHI,
7493 R_FRV_FUNCDESC_GOTLO): New.
7494 (frv_reloc_map): Map the corresponding BFD relocs to them.
7495 (frv_reloc_type_lookup): ... and back to BFD relocs.
7496 * reloc.c: New relocs.
7497 * bfd-in2.h, libbfd.h: Rebuilt.
7499 2004-01-05 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
7501 * elf32-mips.c (ELF_MAXPAGESIZE): Redefine for traditional
7502 targets to support pages of up to 64kB.
7503 (elf32_bed): Redefine to get a separate backend data structure for
7504 traditional targets.
7505 * elf64-mips.c (ELF_MAXPAGESIZE): Redefine for traditional
7506 targets to support pages of up to 64kB.
7507 (elf64_bed): Redefine to get a separate backend data structure for
7508 traditional targets.
7509 * elfn32-mips.c (ELF_MAXPAGESIZE): Redefine for traditional
7510 targets to support pages of up to 64kB.
7511 (elf32_bed): Redefine to get a separate backend data structure for
7512 traditional targets.
7514 2004-01-04 Mark Kettenis <kettenis@gnu.org>
7516 * elf32-sparc.c (elf32_sparc_grok_psinfo): New function.
7518 2004-01-02 Mark Kettenis <kettenis@gnu.org>
7520 * elf32-i386.c (elf_i386_grok_prstatus): Add support for FreeBSD.
7521 (elf_i386_grok_psinfo): Likewise.
7523 2004-01-02 Bernardo Innocenti <bernie@develer.com>
7525 * config.bfd: Add m68k-uClinux target.
7527 2004-01-01 Grant Edwards <grante@visi.com>
7529 * elflink.h (elf_gc_sections): Warn when gc-sections option is ignored.
7530 * elf32-h8300.c (elf32_h8_gc_mark_hook): New function.
7531 (elf32_h8_gc_sweep_hook): New function.
7532 (elf_backend_gc_mark_hook): Define.
7533 (elf_backend_gc_sweep_hook): Define.
7534 (elf_backend_can_gc_sections): Define.
7536 For older changes see ChangeLog-0203
7542 version-control: never