1 2003-08-16 Alan Modra <amodra@bigpond.net.au>
3 * elf64-ppc.c: Don't include elf/ppc.h.
5 2003-08-14 Richard Sandiford <rsandifo@redhat.com>
7 * elfxx-mips.c (_bfd_mips_elf_modify_segment_map): Fix PT_DYNAMIC
8 code to work with 64-bit bfds.
10 2003-08-14 Alan Modra <amodra@bigpond.net.au>
12 * dep-in.sed: Remove libintl.h.
13 * Makefile.am (SRC-POTFILES.in, BLD-POTFILES.in): Unset LC_COLLATE.
14 (POTFILES.in): Remove target.
15 * Makefile.in: Regenerate.
17 2003-08-12 Alan Modra <amodra@bigpond.net.au>
19 * elf64-ppc.c (ppc64_elf_next_input_section): Update comment.
20 (ppc64_elf_relocate_section): For zero sym R_PPC64_TOC relocs,
21 use the function sym from the previous reloc.
23 2003-08-11 Jakub Jelinek <jakub@redhat.com>
25 * elf32-i386.c (elf_i386_relocate_section): Make undefined symbols
27 * elf32-s390.c (elf_s390_relocate_section): Likewise.
28 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
29 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
30 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
31 * elf64-s390.c (elf_s390_relocate_section): Likewise.
32 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
33 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
34 * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
35 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
36 (ppc_elf_relocate_section) <case R_PPC_RELAX32>: Issue fatal error
37 on undefined symbols if -pie.
38 * elf32-sh.c (sh_elf_relocate_section): Likewise.
40 2003-08-11 Alan Modra <amodra@bigpond.net.au>
42 * elf64-ppc.c (ppc64_elf_relocate_section): Add special case for crt1.o
43 branch to __libc_start_main.
45 2003-08-08 Dmitry Diky <diwil@mail.ru>
47 * archures.c: Add xW42 and xE42 parts. Sort MPU list according to
49 * cpu-msp430.c: Likewise.
50 * elf32-msp430.c: Likewise.
51 * bfd-in2.h: Regenerate.
53 2003-08-07 Alan Modra <amodra@bigpond.net.au>
55 * elfxx-target.h: Remove PTR cast.
56 * targets.c (bfd_target): Make backend_data const void *.
57 * elf-bfd.h: Constify all occurrences of struct elf_backend_data.
58 * elf-m10300.c: Likewise.
60 * elf32-hppa.c: Likewise.
61 * elf32-i386.c: Likewise.
62 * elf32-m68hc1x.c: Likewise.
63 * elf32-ppc.c: Likewise.
64 * elf32-s390.c: Likewise.
65 * elf32-sh.c: Likewise.
66 * elf32-sh64.c: Likewise.
67 * elf32-sparc.c: Likewise.
68 * elf32-xtensa.c: Likewise.
69 * elf64-mips.c: Likewise.
70 * elf64-ppc.c: Likewise.
71 * elf64-s390.c: Likewise.
72 * elf64-sh64.c: Likewise.
73 * elf64-sparc.c: Likewise.
74 * elf64-x86-64.c: Likewise.
75 * elfcode.h: Likewise.
76 * elfcore.h: Likewise.
77 * elflink.c: Likewise.
78 * elflink.h: Likewise.
79 * elfxx-ia64.c: Likewise.
80 * elfxx-mips.c: Likewise.
81 * elfxx-mips.h: Likewise.
82 * elf.c (prep_headers): Remove useless check for null backend_data.
83 * bfd-in2.h: Regenerate.
85 * elf-bfd.h: Remove PARAMS macro. Replace PTR with void *.
86 (NAME): Use ## rather than CONCAT4 macro.
87 * elfcode.h: Remove one remaining PARAMS macro.
88 * elf-eh-frame.c: Convert to C90, remove unneeded casts and prototypes.
89 * elf-strtab.c: Likewise.
90 * elf-hppa.h: Likewise.
91 * elf32-hppa.h: Likewise.
92 * elf32-hppa.c: Likewise.
93 (elf32_hppa_add_symbol_hook): Delete.
94 (elf_backend_add_symbol_hook): Don't define.
95 * libhppa.h: Convert to C90. Replace INLINE with inline.
97 2003-08-06 Alan Modra <amodra@bigpond.net.au>
99 * elf64-ppc.c (ppc_stub_name): Tweak names for better readability.
100 (ppc64_elf_adjust_dynamic_symbol): Allow copy relocs against
101 function descriptors, but warn.
102 (ppc_build_one_stub): Remove a couple of vars. Move code creating
103 stub syms so that we can avoid a stub sym if we already have a
104 plt sym. Do not redefine an existing symbol.
105 (ppc64_elf_build_stubs): When --emit-stub-syms, print a symbol for
108 2003-08-06 Nick Clifton <nickc@redhat.com>
110 * po/fr.po: Updated French translation.
112 2003-08-06 Alan Modra <amodra@bigpond.net.au>
114 * elflink.c (_bfd_elf_create_dynamic_sections): Mark .dynbss with
117 2003-08-05 Daniel Jacobowitz <drow@mvista.com>
119 * elf32-arm.h (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
120 (elf32_arm_final_link_relocate, elf32_arm_relocate_section): Use it.
122 2003-08-03 Jeff Muizelaar <muizelaar@rogers.com>
124 * coffcode.h (coff_slurp_line_table): Return with a warning
125 message if the line number table could not be read.
127 2003-08-04 Nick Clifton <nickc@redhat.com>
129 * elflink.h (elf_link_add_object_symbols): Prepend "warning: "
130 to messages produced for .gnu.warning.SYMBOL sections.
132 2003-08-04 Alan Modra <amodra@bigpond.net.au>
134 * elfcode.h: Convert to C90, remove unneeded casts and prototypes.
135 * elfcore.h: Likewise.
136 * elflink.c: Likewise.
137 * elflink.h: Likewise.
138 * elf.c (sym_is_global): Remove INLINE.
139 (align_file_position): Replace INLINE with inline.
140 * elfcode.h (elf_swap_dyn_in, elf_swap_dyn_out): Remove INLINE.
141 (elf_file_p): Replace INLINE with inline.
143 2003-08-02 Kaz Kojima <kkojima@rr.iij4u.or.jp>
145 * elf32-sh.c (sh_elf_check_relocs): Don't set DF_TEXTREL here.
147 2003-08-01 H.J. Lu <hongjiu.lu@intel.com>
149 * elfxx-ia64.c (get_got): Align the .got section at 8 bytes.
151 2003-08-01 H.J. Lu <hongjiu.lu@intel.com>
153 * elfxx-ia64.c (elfNN_ia64_finish_dynamic_symbol): Use
154 ElfNN_External_Rela instead of Elf64_External_Rela.
156 2003-08-01 Nick Clifton <nickc@redhat.com>
158 * config.bfd: Add code to catch obsolete configurations and warn
159 about them unless --enable-obsolete is used. Use this to mark
160 vax-vms port as obsolete.
162 2003-07-30 Alan Modra <amodra@bigpond.net.au>
164 * elf32-ppc.c (ppc_elf_install_value): Tidy.
165 (ppc_elf_relax_section): Remove dead code. Remove unnecessary casts.
167 * elfxx-target.h: Remove PARAMS macro. Formatting.
169 2003-07-30 Alan Modra <amodra@bigpond.net.au>
171 * elf.c (bfd_section_from_r_symndx): Test for SHN_UNDEF.
172 * elf64-ppc.c (get_fdh): New function, split out from
174 (ppc64_elf_check_relocs): Use get_fdh.
175 (func_desc_adjust): Likewise. Tidy.
176 (ppc64_elf_edit_opd): Tighten reloc checks. Free local_syms on error
177 exit. Use get_fdh. Account for superfluous dynamic relocs.
178 (ppc64_elf_relocate_section): Warning fix.
180 2003-07-30 Jason Eckhardt <jle@rice.edu>
182 * coff-i860.c: Convert to ISO C90. Remove superflous prototypes.
184 2003-07-30 Jason Eckhardt <jle@rice.edu>
186 * elf32-i860.c: Convert to ISO C90. Remove superflous prototypes.
188 2003-07-30 Randolph Chung <tausq@debian.org>
190 * elf-hppa.h (elf_hppa_relocate_section): Look up dyn_h for undefweak.
191 * elf64-hppa.c (elf64_hppa_finalize_dlt): Check h->root.type.
193 2003-07-30 Alan Modra <amodra@bigpond.net.au>
195 * elf.c: Convert to C90, remove unnecessary prototypes and casts.
196 Replace PTR with void *. Formatting.
197 (_bfd_elf_assign_file_position_for_section): Remove INLINE.
198 (make_mapping): Likewise.
200 2003-07-29 Alan Modra <amodra@bigpond.net.au>
202 * elf64-ppc.c (func_desc_adjust): Give linker created function
203 descriptor symbols a size and type.
204 (ppc64_elf_relocate_section): Correct lq insn test.
206 2003-07-28 Eric Christopher <echristo@redhat.com>
208 * elf32-ppc.c (R_PPC_RELAX32): New relocation.
209 (ppc_elf_install_value): New function.
210 (ppc_elf_sort_rela): Remove.
211 (ppc_elf_relax_section): Rewrite. Remove old relaxation
212 and replace with out of range branch stubs.
213 (ppc_elf_relocate_section): Handle R_PPC_RELAX32.
215 2003-07-29 Alexandre Oliva <aoliva@redhat.com>
217 * elf-m10300.c (mn10300_elf_relax_section): Take symbol hash table
220 2003-07-28 Alan Modra <amodra@bigpond.net.au>
222 * elf.c (special_sections): Set attributes for .got and .plt.
224 2003-07-27 Alan Modra <amodra@bigpond.net.au>
226 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Ensure no copy relocs
227 on function descriptors.
228 (ELIMINATE_COPY_RELOCS): Expand comment.
229 (ppc64_elf_special_sections): Move. Don't include non-ppc64 sections.
232 2003-07-25 H.J. Lu <hongjiu.lu@intel.com>
234 * elf.c (_bfd_elf_new_section_hook): Set the default section
236 (elf_fake_sections): Set the section type based on asect->flags
237 if it is SHT_NULL. Don't abort on processor specific section
240 2003-07-25 H.J. Lu <hongjiu.lu@intel.com>
242 * bfd-in2.h: Regenerated.
244 2003-07-25 H.J. Lu <hongjiu.lu@intel.com>
246 * elf-bfd.h (bfd_elf_special_section): New.
247 (elf_backend_data): Add special_sections, a pointer to
248 bfd_elf_special_section.
249 (elf_section_type). New.
250 (elf_section_flags): New.
251 (_bfd_elf_get_sec_type_attr): New.
253 * elf.c (_bfd_elf_make_section_from_shdr): Always use the
254 real section type/flags.
255 (special_sections): New.
256 (get_special_section): New.
257 (_bfd_elf_get_sec_type_attr): New.
258 (_bfd_elf_new_section_hook): Check special_section to set
259 elf_section_type and elf_section_flags.
260 (elf_fake_sections): Don't use section name to set ELF section
263 * elf32-m32r.c (m32r_elf_special_sections): New.
264 (elf_backend_special_sections): Defined.
266 * elf32-m68hc11.c (elf32_m68hc11_special_sections): New.
267 (elf_backend_special_sections): Defined.
269 * elf32-mcore.c (mcore_elf_special_sections): New.
270 (elf_backend_special_sections): Defined.
272 * elf32-ppc.c (ppc_elf_special_sections): New.
273 (elf_backend_special_sections): Defined.
275 * elf32-sh64.c (sh64_elf_special_sections): New.
276 (elf_backend_special_sections): Defined.
278 * elf32-v850.c (v850_elf_special_sections): New.
279 (elf_backend_special_sections): Defined.
281 * elf32-xtensa.c (elf_xtensa_special_sections): New.
282 (elf_backend_special_sections): Defined.
284 * elf64-alpha.c (elf64_alpha_special_sections): New.
285 (elf_backend_special_sections): Defined.
287 * elf64-hppa.c (elf64_hppa_special_sections): New.
288 (elf_backend_special_sections): Defined.
290 * elf64-ppc.c (ppc64_elf_special_sections): New.
291 (elf_backend_special_sections): Defined.
293 * elf64-sh64.c (sh64_elf64_special_sections): New.
294 (elf_backend_special_sections): Defined.
296 * elfxx-ia64.c (elfNN_ia64_special_sections): New.
297 (elf_backend_special_sections): Defined.
299 * elfxx-mips.c (_bfd_mips_elf_special_sections): New.
301 * elfxx-mips.h (_bfd_mips_elf_special_sections): New.
302 (elf_backend_special_sections): Defined.
304 * elfxx-target.h (elf_backend_special_sections): New. Default
306 (elfNN_bed): Initialize special_sections.
308 * section.c (bfd_abs_section): Remove const.
309 (bfd_und_section): Likewise.
310 (bfd_com_section): Likewise.
311 (bfd_ind_section): Likewise.
313 2003-07-24 Nick Clifton <nickc@redhat.com>
315 * coff-arm.c (EXTRA_S_FLAGS): Include SEC_CODE so that code
316 sections are assigned the LOAD attribute.
318 2003-07-25 Kaz Kojima <kkojima@rr.iij4u.or.jp>
320 * elf32-sh.c: Convert to C90. Replace PTR with void *.
321 * elf32-sh64-com.c: Likewise.
322 * elf32-sh64.c: Likewise.
323 * elf32-sh64.h: Likewise.
324 * elf64-sh64.c: Likewise.
326 2003-07-24 Kaz Kojima <kkojima@rr.iij4u.or.jp>
328 * elf32-sh.c (sh_elf_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL.
329 (allocate_dynrelocs): Likewise.
330 (sh_elf_relocate_section): Likewise. Use SYMBOL_REFERENCES_LOCAL.
331 (sh_elf_finish_dynamic_symbol): Use SYMBOL_REFERENCES_LOCAL.
333 2003-07-24 Nick Clifton <nickc@redhat.com>
335 * po/fr.po: Updated French translation.
337 2003-07-23 Bob Wilson <bob.wilson@acm.org>
339 * elf32-xtensa.c (xtensa_elf_dynamic_symbol_p): Make inline and move
340 near the beginning of the file. Swap order of arguments. Call
341 _bfd_elf_dynamic_symbol_p with "ignore_protected" set to 0.
342 (elf_xtensa_fix_refcounts): Adjust xtensa_elf_dynamic_symbol_p call.
343 (elf_xtensa_relocate_section): Likewise.
344 (shrink_dynamic_reloc_sections): Likewise.
346 2003-07-23 Bob Wilson <bob.wilson@acm.org>
348 * elf32-xtensa.c (plt_reloc_count): Fix typo in comment.
349 (elf_xtensa_size_dynamic_sections): Use elf_discarded_section.
350 (elf_xtensa_combine_prop_entries): Avoid returning non-zero without
351 first printing an error message.
352 (elf_xtensa_finish_dynamic_sections): Likewise.
353 (elf_xtensa_discard_info_for_section): Adjust size of .got.loc when
354 discarding literal table entries.
355 (elf_xtensa_merge_private_bfd_data): Remove newline from error message.
356 (elf_xtensa_do_asm_simplify): Likewise.
358 2003-07-23 Stephane Carrez <stcarrez@nerim.fr>
360 * elf32-m68hc1x.c (elf32_m68hc11_size_stubs): Avoid crash when
361 we have a local symbol in common section.
363 2003-07-22 H.J. Lu <hongjiu.lu@intel.com>
365 * elflink.c (_bfd_elf_dynamic_symbol_p): Don't return TRUE for
368 2003-07-22 Nick Clifton <nickc@redhat.com>
370 * coffcode.h (coff_slurp_symbol_table): Add C_TCSYM and C_ECOML to
371 expected RS6000 storage classes.
373 2003-07-21 H.J. Lu <hongjiu.lu@intel.com>
375 * elfxx-ia64.c (elfNN_ia64_size_dynamic_sections): Mark
376 output_bfd unused to silence gcc.
378 2003-07-21 Nick Clifton <nickc@redhat.com>
380 * po/sv.po: Updated Swedish translation.
382 2003-07-21 Alan Modra <amodra@bigpond.net.au>
384 * elf-bfd.h (SYMBOL_REFERENCES_LOCAL, SYMBOL_CALLS_LOCAL): Use..
385 (_bfd_elf_symbol_refs_local_p): ..this. Declare.
386 * elflink.c (_bfd_elf_symbol_refs_local_p): New function.
387 * elf32-i386.c (elf_i386_relocate_section): Remove h NULL test
388 now done in _bfd_elf_symbol_refs_local_p.
389 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
390 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
391 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
393 2003-07-18 H.J. Lu <hongjiu.lu@intel.com>
395 * elflink.c (_bfd_elf_dynamic_symbol_p): Undo the last change.
397 2003-07-18 H.J. Lu <hongjiu.lu@intel.com>
399 * elf-bfd.h (SYMBOL_REFERENCES_LOCAL): Fix a typo.
400 (SYMBOL_CALLS_LOCAL): Likewise.
402 * elflink.c (_bfd_elf_dynamic_symbol_p): Return TRUE
403 immediately if symbol isn't defined locally.
405 2003-07-18 Richard Henderson <rth@redhat.com>
407 * elflink.c (_bfd_elf_dynamic_symbol_p): New.
408 * elf-bfd.h (_bfd_elf_dynamic_symbol_p): Declare it.
409 (SYMBOL_REFERENCES_LOCAL, SYMBOL_CALLS_LOCAL): Use it.
410 * elf32-xtensa.c (xtensa_elf_dynamic_symbol_p): Likewise.
411 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise.
412 * elf64-hppa.c (elf64_hppa_dynamic_symbol_p): Likewise.
413 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Likewise.
414 Update all callers to provide the relocation being resolved.
416 2003-07-17 Shaun Jackman <sjackman@pathwayconnect.com>
418 * config.bfd (arm-wince-pe): Add -DARM_COFF_BUGFIX to
421 2003-07-17 Nick Clifton <nickc@redhat.com>
423 * po/es.po: New Spanish translation.
424 * po/sv.po: New Swedish translation.
425 * po/opcodes.pot: Regenerate.
427 2003-07-16 Richard Henderson <rth@redhat.com>
429 * config.bfd, configure.host, configure.in: Remove ia64-aix support.
430 * elfxx-ia64.c, targets.c: Likewise.
432 2003-07-16 Richard Henderson <rth@redhat.com>
434 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Properly return false
435 for symbols defined locally plus -Bsymbolic. Tidy logic.
437 2003-07-15 Richard Sandiford <rsandifo@redhat.com>
439 * archures.c (bfd_mach_mips7000): New.
440 * bfd-in2.h: Regenerated.
441 * cpu-mips.c (arch_info_struct): Add an entry for mips:7000.
442 * elfxx-mips.c (mips_set_isa_flags): Handle bfd_mach_mips7000.
443 (mips_mach_extensions): Add an entry for it.
445 2003-07-14 Nick Clifton <nickc@redhat.com>
447 * po/tr.po: Update with latest version.
448 * po/SRC-POTFILES.in: Regenerate.
449 * po/bfd.pot: Regenerate.
450 * Makfile.in: Regenerate.
451 * configure: Regenerate.
453 2003-07-12 Jeff Baker <jbaker@qnx.com>
455 * bfd/config.bfd (__QNXTARGET__): Define for Neutrino architectures.
456 * bfd/elf32-arm.h (ELF_MAXPAGESIZE): Set to 4k for Neutrino.
457 * bfd/elf32-sh.c (ELF_MAXPAGESIZE): Set to 4k for Neutrino.
458 * bfd/elf32-ppc.c (ELF_MAXPAGESIZE): Set to 4k for Neutrino.
460 2003-07-12 Jeff Muizelaar <muizelaar@rogers.com>
462 * coffcode.h (coff_set_section_contents): Set the
463 IMAGE_FILE_32BIT_MACHINE flag for PE targets.
465 2003-07-11 Richard Sandiford <rsandifo@redhat.com>
467 * bfd-in.h (bfd_h8300_pad_address): Declare.
468 * bfd-in2.h: Regenerate.
469 * cpu-h8300.c (bfd_h8300_pad_address): New function.
470 * coff-h8300.c (h8300_reloc16_estimate): Use it to canonicalize
471 addresses before checking whether they can be relaxed.
472 (h8300_reloc16_extra_cases): Likewise for the R_MOVL2 sanity check.
473 Don't complain about overflows in general 8-bit relocations.
474 * elf32-h8300.c (elf32_h8_relax_section): Use bfd_h8300_pad_address.
475 Fix handling of R_H8_DIR24A8.
477 2003-07-11 Richard Sandiford <rsandifo@redhat.com>
479 * elf32-h8300.c: Convert function prototypes and definitions
481 * coff-h8300.c: Likewise.
482 * cpu-h8300.c: Likewise.
484 2003-07-11 Alan Modra <amodra@bigpond.net.au>
486 * po/SRC-POTFILES.in: Regenerate.
487 * po/bfd.pot: Likewise.
489 2003-07-10 Bob Wilson <bob.wilson@acm.org>
491 * elf32-xtensa.c (elf_xtensa_create_dynamic_sections): Create new
492 .got.loc section. Do not set SEC_ALLOC or SEC_LOAD flags for the
494 (elf_xtensa_size_dynamic_sections): Set size of the .got.loc section
495 and allocate memory for it.
496 (elf_xtensa_combine_prop_entries): Copy contents of .xt.lit output
497 section to the .got.loc section.
498 (elf_xtensa_finish_dynamic_sections): Fix up call to
499 elf_xtensa_combine_prop_entries and set DT_XTENSA_GOT_LOC_OFF to
500 the address of .got.loc.
501 (relax_property_section): Shrink .got.loc to match changes in any
502 literal table section.
503 (xtensa_is_property_section): Change to match
504 xtensa_get_property_section_name.
505 (xtensa_is_littable_section): New.
507 2003-07-10 H.J. Lu <hongjiu.lu@intel.com>
509 * elfxx-ia64.c (IA64_HOWTO): Set dst_mask to -1 instead of
512 2003-07-10 Alan Modra <amodra@bigpond.net.au>
514 * Makefile.am (BFD32_BACKENDS): Add elf32-am33lin.lo.
515 (BFD32_BACKENDS_CFILES): elf32-am33lin.c not elf32-am33lin.lo.
517 * Makefile.in: Regenerate.
519 2003-07-10 Alexandre Oliva <aoliva@redhat.com>
521 2001-09-12 Alexandre Oliva <aoliva@redhat.com>
522 * elf32-am33lin.c (ELF_MACHINE_CODE): Redefine to EM_MN10300.
523 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_MN10300.
524 2001-06-02 Nick Clifton <nickc@cambridge.redhat.com>
525 * elf32-am33lin.c: Rename global functions.
526 2001-05-09 Alexandre Oliva <aoliva@redhat.com>
527 * config.bfd (am33_2.0, am33_2.0-*-linux*): Added.
528 * configure.in (bfd_elf32_am33lin_vec): Added.
529 * Makefile.am (BFD32_BACKENDS): Added elf32-am33lin.lo.
530 (elf32-am33lin.lo): List dependencies.
531 * aclocal.m4, configure, Makefile.in: Rebuilt.
532 * elf-m10300.c (TARGET_LITTLE_SYM, TARGET_LITTLE_NAME,
533 ELF_ARCH, ELF_MACHINE_CODE, ELF_MAXPAGESIZE): Define only if
534 ELF_ARCH was not defined before.
535 (elf_symbol_leading_char): Define if not defined.
536 * elf32-am33lin.c: Override the definitions above.
537 * targets.c (bfd_elf32_am33lin_vec): New.
539 2003-07-09 Alexandre Oliva <aoliva@redhat.com>
541 2002-12-12 Alexandre Oliva <aoliva@redhat.com>
542 * elf-m10300.c (elf32_mn10300_link_hash_newfunc): Initialize
544 2001-12-13 Alexandre Oliva <aoliva@redhat.com>
545 * elf-m10300.c (ELF_DYNAMIC_INTERPRETER): Renamed from
546 ld-linux.so.2 to ld.so.1.
547 2001-10-10 Alexandre Oliva <aoliva@redhat.com>
548 * elf-m10300.c (elf_mn10300_sizeof_plt0): New macro.
549 (_bfd_mn10300_elf_adjust_dynamic_symbol): Use it.
550 (_bfd_mn10300_elf_finish_dynamic_symbol): Likewise.
551 * elf-m10300.c (_bfd_mn10300_elf_size_dynamic_sections): Allocate
552 .rela.* section contents with bfd_zalloc.
553 2001-09-25 Alexandre Oliva <aoliva@redhat.com>
554 * elf-m10300.c: Added declarations for functions missing them.
555 Merge some shared-library changes from the i386 back-end. Use
556 R_MN10300_RELATIVE instead of R_MN10300_PCREL32 and
557 R_MN10300_GLOB_DAT instead of R_MN10300_32 where appropriate.
558 (struct elf32_mn10300_link_hash_entry): Remove duplicates of
559 members of elf_link_hash_entry. Adjusted references.
560 (mn10300_elf_final_link_relocate): dynobj was already loaded
561 into a local variable, use it.
562 2001-09-21 Nick Clifton <nickc@cambridge.redhat.com>
563 * elf-m10300.c: Add missing function prototypes.
564 2001-08-24 Alexandre Oliva <aoliva@redhat.com>
565 * elf-m10300.c (mn10300_elf_relocate_section): Don't compute
566 relocation for dynamic relocations.
567 2001-05-16 Alexandre Oliva <aoliva@redhat.com>
568 * reloc.c (BFD_RELOC_MN10300_GOTOFF24): New.
569 * elf-m10300.c: Introduce GOTPC16, GOTOFF24, GOTOFF16 and
570 PLT16, and rename GOTPC to GOTPC32 and GOTOFF to GOTOFF32.
571 (_bfd_mn10300_elf_create_dynamic_sections): Move creation ot PLT...
572 (_bfd_mn10300_elf_create_got_section): ... here, so that its
573 adress is already known at the time we compute relaxations.
574 (mn10300_elf_relax_section): Relax GOTPC32, GOTOFF32, GOT32
575 and PLT32 to narrower relocations.
576 * libbfd.h, bfd-in2.h: Rebuilt.
577 2001-04-12 Alexandre Oliva <aoliva@redhat.com>
578 * reloc.c (BFD_RELOC_MN10300_GOT32, BFD_RELOC_MN10300_GOT24,
579 BFD_RELOC_MN10300_GOT16, BFD_RELOC_MN10300_COPY,
580 BFD_RELOC_MN10300_GLOB_DAT, BFD_RELOC_MN10300_JMP_SLOT,
581 BFD_RELOC_MN10300_RELATIVE): New relocs.
582 * libbfd.h, bfd-in2.h: Rebuilt.
583 * elf-m10300.c (struct elf_mn10300_pcrel_relocs_copied): New.
584 (struct elf32_mn10300_link_hash_entry): Added DSO-related
586 (elf_mn10300_howto): Defined new relocation types.
587 (mn10300_reloc_map): Map them.
588 (_bfd_mn10300_elf_create_got_section): New fn.
589 (mn10300_elf_check_relocs): Handle PIC relocs.
590 (mn10300_elf_final_link_relocate): Likewise.
591 (mn10300_elf_relocate_section): Handle DSOs.
592 (PLT0_ENTRY_SIZE, PLT_ENTRY_SIZE, PIC_PLT_ENTRY_SIZE): New macros.
593 (elf_mn10300_plt0_entry, elf_mn10300_plt_entry,
594 elf_mn10300_pic_plt_entry): New.
595 (elf_mn10300_sizeof_plt, elf_mn10300_plt_plt0_offset,
596 elf_mn10300_plt0_linker_offset, elf_mn10300_plt0_gotid_offset,
597 elf_mn10300_plt_temp_offset, elf_mn10300_plt_symbol_offset,
598 elf_mn10300_plt_reloc_offset: New macros.
599 (ELF_DYNAMIC_INTERPRETER): Likewise.
600 (_bfd_mn10300_elf_create_dynamic_sections): New function.
601 (_bfd_mn10300_elf_adjust_dynamic_symbol): Likewise.
602 (_bfd_mn10300_elf_discard_copies): Likewise.
603 (_bfd_mn10300_elf_size_dynamic_sections): Likewise.
604 (_bfd_mn10300_elf_finish_dynamic_symbol): Likewise.
605 (_bfd_mn10300_elf_finish_dynamic_sections): Likewise.
606 (elf_backend_can_gc_sections,
607 elf_backend_create_dynamic_sections,
608 elf_backend_adjust_dynamic_sections,
609 elf_backend_size_dynamic_sections,
610 elf_backend_finish_dynamic_symbol,
611 elf_backend_finish_dynamic_sections, elf_backend_want_got_plt,
612 elf_backend_plt_readonly, elf_backend_want_plt_sym,
613 elf_backend_got_header_size, elf_backend_plt_header_size): New
616 2003-07-09 Alexandre Oliva <aoliva@redhat.com>
618 2001-05-06 Alexandre Oliva <aoliva@redhat.com>
619 * elf-m10300.c (compute_function_info): Account for AM33
620 registers in `movm' when computing stack space for `call' when
621 linking for AM33/2.0 link.
622 2000-04-01 Alexandre Oliva <aoliva@cygnus.com>
623 * archures.c (bfd_mach_am33_2): Renamed from bfd_mach_am332.
624 * bfd-in2.h: Rebuilt.
625 * cpu-m10300.c (bfd_am33_2_arch): Renamed from bfd_am332_arch.
626 * elf-m10300.c: Updated.
627 2000-03-31 Alexandre Oliva <aoliva@cygnus.com>
628 * archures.c (bfd_mach_am332): Defined.
629 * bfd-in2.h: Rebuilt.
630 * cpu-m10300.c (bfd_am332_arch): Defined.
631 (bfd_am33_arch): Chained with am33-2.
632 * elf-m10300.c (elf_mn10300_mach): Handle am332.
633 (_bfd_mn10300_elf_final_write_processing): Likewise.
635 2003-07-09 H.J. Lu <hongjiu.lu@intel.com>
637 * elfxx-ia64.c (IA64_HOWTO): Set dst_mask to -1LL.
639 2003-07-10 Alan Modra <amodra@bigpond.net.au>
641 * elf64-ppc.c (bfd_elf64_mkobject): Define.
642 (struct ppc64_elf_obj_tdata): New.
643 (ppc64_elf_tdata, ppc64_tlsld_got): Define.
644 (ppc64_elf_mkobject): New function.
645 (struct got_entry): Add "owner". Move "tls_type".
646 (struct ppc_link_hash_table): Delete "relgot", "tlsld_got".
647 (ppc64_elf_init_stub_bfd): New function.
648 (create_got_section): Create header .got in dynobj. Create .got
649 and .rela.got in each bfd. Stash pointers in ppc64_elf_obj_tdata.
650 (ppc64_elf_create_dynamic_sections): Don't call create_got_section.
651 Look for dynobj .got, and test it.
652 (ppc64_elf_copy_indirect_symbol): Adjust for changed got.
653 (update_local_sym_info): Likewise.
654 (ppc64_elf_check_relocs): Likewise.
655 (ppc64_elf_gc_sweep_hook): Likewise.
656 (ppc64_elf_tls_optimize): Likewise.
657 (allocate_dynrelocs): Likewise.
658 (ppc64_elf_size_dynamic_sections): Likewise.
659 (ppc64_elf_relocate_section): Likewise.
660 (ppc64_elf_next_toc_section): Update comment.
661 (toc_adjusting_stub_needed): Remove unneeded cast.
662 (ppc64_elf_build_stubs): Check for stub sections in stub bfd by
663 testing section flags.
664 (ppc64_elf_build_stubs): Likewise.
665 (ppc64_elf_size_stubs): Likewise. Remove stub_bfd param.
666 (ppc64_elf_finish_dynamic_sections): Write out got sections.
667 (func_desc_adjust): Copy over dynamic info for undef weaks.
668 * elf64-ppc.h (ppc64_elf_init_stub_bfd): Declare.
669 (ppc64_elf_size_stubs): Update prototype.
670 * elflink.h (elf_link_sort_relocs): Use link_orders to find reldyn
671 input sections rather than scanning dynobj.
673 2003-07-09 Richard Sandiford <rsandifo@redhat.com>
675 * elfxx-mips.c (mips_elf_link_hash_entry): Remove min_dyn_reloc_index.
676 (bfd_mips_elf_swap_msym_in, bfd_mips_elf_swap_msym_out): Delete.
677 (mips_elf_create_msym_section): Delete.
678 (mips_elf_create_dynamic_relocation): Don't set min_dyn_reloc_index.
679 (_bfd_mips_elf_copy_indirect_symbol): Likewise.
680 (_bfd_mips_elf_create_dynamic_sections): Don't create .msym.
681 (_bfd_mips_elf_size_dynamic_sections): Don't calculate its size.
682 (_bfd_mips_elf_size_dynamic_sections): Don't add DT_MIPS_MSYM.
683 (_bfd_mips_elf_finish_dynamic_symbol): Don't add symbols to .msym.
684 (_bfd_mips_elf_finish_dynamic_sections): Likewise.
686 2003-07-09 Richard Sandiford <rsandifo@redhat.com>
688 * elfxx-mips.c (mips_elf_irix6_finish_dynamic_symbol): Make the
691 2003-07-09 Richard Sandiford <rsandifo@redhat.com>
693 * elfxx-mips.c (mips_elf_create_dynamic_relocation): Fix handling
694 of relocations whose offset is -2.
696 2003-07-09 Richard Sandiford <rsandifo@redhat.com>
698 * bfd/elfxx-mips.c (mips_elf_create_dynamic_relocation): Treat
699 forced-local symbols like other locals. Don't create relocations
700 against STN_UNDEF in irix objects.
702 2003-07-09 Richard Sandiford <rsandifo@redhat.com>
704 * bfd/elfxx-mips.c (mips_elf_create_dynamic_relocation): In SGI-
705 compatible objects, add the values of defined external symbols
708 2003-07-09 Richard Sandiford <rsandifo@redhat.com>
710 * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Always
711 initialize a GOT entry to the symbol's st_value.
713 2003-07-08 Alan Modra <amodra@bigpond.net.au>
715 * elf-bfd.h (struct elf_obj_tdata): Move linker_section_pointers..
716 * elf32-ppc.c (struct ppc_elf_obj_tdata): ..to here. New.
717 (ppc_elf_tdata): Define.
718 (elf_local_ptr_offsets): Adjust.
719 (ppc_elf_mkobject): New function.
720 (bfd_elf32_mkobject): Define.
722 * elfcode.h (elf_object_p): Allocate tdata via _bfd_set_format.
723 * elfcore.h (elf_core_file_p): Likewise.
724 * section.c (bfd_section_init): Remove prototype.
726 2003-07-08 Alan Modra <amodra@bigpond.net.au>
728 * elf-bfd.h (struct elf_link_hash_entry): Remove linker_section_pointer
730 (enum elf_linker_section_enum): Delete.
731 (struct elf_linker_section): Delete.
732 (struct elf_linker_section_pointers): Delete.
733 (struct elf_obj_tdata): Remove #if 0 chunk. Remove linker_section.
734 Make linker_section_pointers a void**.
735 (elf_local_ptr_offsets, elf_linker_section): Don't define.
736 * elf32-ppc.c (enum elf_linker_section_enum): New, cut-down version
737 of old item in elf-bfd.h.
738 (struct elf_linker_section): Likewise.
739 (struct elf_linker_section_pointers): Likewise.
740 (elf_local_ptr_offsets): Define.
741 (struct ppc_elf_link_hash_entry): Add linker_section_pointer.
742 (ppc_elf_link_hash_newfunc): Init it.
743 (struct ppc_elf_link_hash_table): Add sbss.
744 (ppc_elf_link_hash_table_create): zmalloc rather than clearing
746 (elf_create_linker_section): Fold into..
747 (ppc_elf_create_linker_section): ..here. Remove hole_size code.
748 Make rela section here if shared.
749 (elf_find_pointer_linker_section): Pass lsect rather than enum.
750 (elf_create_pointer_linker_section): Adjust. zalloc rather than
752 (elf_finish_pointer_linker_section): Adjust. Don't make rela
754 (ppc_elf_check_relocs): Adjust.
755 (ppc_elf_add_symbol_hook): Tighten hash creator test. Remove code
756 creating .sbss by hand.
757 * elf.c (_bfd_elf_link_hash_newfunc): Adjust.
759 2003-07-04 Jakub Jelinek <jakub@redhat.com>
761 * elf32-s390.c (elf_howto_table): Change R_390_GOT12 to
762 complain_overflow_bitfield.
763 * elf64-s390.c (elf_howto_table): Change R_390_GOT12 to
764 complain_overflow_bitfield.
766 2003-07-04 Jakub Jelinek <jakub@redhat.com>
768 * elf-bfd.h (SYMBOL_REFERENCES_LOCAL, SYMBOL_CALLS_LOCAL): Return
771 2003-07-04 Jakub Jelinek <jakub@redhat.com>
773 * elfxx-ia64.c (struct elfNN_ia64_link_hash_table): Add rel_fptr_sec.
774 (elfNN_ia64_dynamic_symbol_p): Change info->shared into
776 (get_fptr): For -pie create .opd as writable section and create
778 (elfNN_ia64_check_relocs): Change info->shared into
780 (allocate_fptr): Likewise.
781 (allocate_dynrel_entries): Account for a relative reloc for -pie
782 @fptr(). Don't account for a relative reloc if -pie want_ltoff_fptr
783 for undefweak symbol. Account for an IPLT reloc in .rela.opd
785 (set_got_entry): Don't create a relative reloc if -pie
786 want_ltoff_fptr for undefweak symbol.
787 (set_fptr_entry): Emit an IPLT reloc in .rela.opd for -pie.
788 (elfNN_ia64_relocate_section): Emit a relative reloc for -pie
791 * elfxx-ia64.c (elfNN_ia64_relocate_section): Issue undefined_symbol
793 * elf32-i386.c (elf_i386_relocate_section): Likewise.
794 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
795 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
796 * elf64-s390.c (elf_s390_relocate_section): Likewise.
797 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
798 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
799 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
800 * elf32-s390.c (elf_s390_relocate_section): Likewise.
801 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
803 2003-07-04 Paul Clarke <paulc@senet.com.au>
805 * elf32-h8300.c (R_H8_DIR32A16): Fix name field.
806 (elf32_h8_relax_section) <R_H8_DIR16A8>: Adjust position of relocation.
807 <R_H8_DIR32A16>: Fix type of relocation.
809 2003-07-04 Kaz Kojima <kkojima@rr.iij4u.or.jp>
811 * elf32-sh.c (sh_elf_create_dynamic_sections): Return if dynamic
812 sections were created already. Remove unnecessary tests of
815 2003-07-04 Kaz Kojima <kkojima@rr.iij4u.or.jp>
817 * elf32-sh.c (sh_elf_create_dynamic_sections): Don't call
818 bfd_make_section for existing sections.
820 2003-07-04 Alan Modra <amodra@bigpond.net.au>
822 * elf32-sparc.c (elf32_sparc_check_relocs): Don't call
823 create_got_section if we already have done so.
824 * elf32-sh.c (sh_elf_create_dynamic_sections): Likewise.
825 (sh_elf_check_relocs): Likewise.
826 (sh_elf_adjust_dynamic_symbol): Delete "dynobj" var. Use
827 htab->root.dynobj instead.
828 (sh_elf_check_relocs): Likewise.
829 (sh_elf_finish_dynamic_sections): Likewise.
831 * section.c (bfd_make_section): Return NULL for existing section.
833 2003-07-04 Alan Modra <amodra@bigpond.net.au>
835 * elf32-ppc.c (ppc_elf_create_dynamic_sections): Don't call
836 ppc_elf_create_got if we've already done so.
838 * elf-bfd.h (_bfd_elf_create_linker_section) Don't declare.
839 (_bfd_elf_find_pointer_linker_section): Likewise.
840 (bfd_elf32_create_pointer_linker_section): Likewise.
841 (bfd_elf32_finish_pointer_linker_section): Likewise.
842 (bfd_elf64_create_pointer_linker_section): Likewise.
843 (bfd_elf64_finish_pointer_linker_section): Likewise.
844 (_bfd_elf_make_linker_section_rela): Likewise.
845 * elfcode.h (elf_create_pointer_linker_section): Don't define.
846 (elf_finish_pointer_linker_section): Likewise.
847 * elflink.c (_bfd_elf_make_linker_section_rela): Delete.
848 (_bfd_elf_create_linker_section): Move this function..
849 (_bfd_elf_find_pointer_linker_section): ..and this..
850 * elflink.h (elf_create_pointer_linker_section): ..and this..
851 (elf_finish_pointer_linker_section): ..and this..
852 * elf32-ppc.c: ..to here, renaming to the following, and adjusting
854 (elf_create_linker_section): Convert to C90, tidy.
855 (elf_find_pointer_linker_section): Likewise.
856 (elf_create_pointer_linker_section): Likewise.
857 (elf_finish_pointer_linker_section): Likewise.
858 * elf32-i370.c: Delete #if 0 code.
860 2003-07-02 Alan Modra <amodra@bigpond.net.au>
862 * elf64-ppc.c (ppc64_elf_func_desc_adjust): Don't allow _savef* and
863 _restf* to be satisfied by shared libs, and always force them local.
864 (toc_adjusting_stub_needed): Avoid scanning linker created sections.
865 Correct test for "bl".
866 (ppc64_elf_relocate_section <R_PPC64_TLS>): Correct test for
869 2003-07-01 Martin Schwidefsky <schwidefsky@de.ibm.com>
871 * elf32-s390.c (s390_elf_ldisp_reloc): New prototype.
872 (s390_tls_reloc): New function.
873 (elf_howto_table): Add long displacement relocations R_390_20,
874 R_390_GOT20, R_390_GOTPLT20 and R_390_TLS_GOTIE20.
875 (elf_s390_reloc_type_lookup): Likewise.
876 (elf_s390_check_relocs): Likewise.
877 (elf_s390_gc_sweep_hook): Likewise.
878 (elf_s390_relocate_section): Likewise.
879 * elf64-s390.c: Same changes as for elf32-s390.c.
880 * reloc.c: Add long displacement relocations BFD_RELOC_390_20,
881 BFD_RELOC_390_GOT20, BFD_RELOC_390_GOTPLT20 and
882 BFD_RELOC_390_TLS_GOTIE20.
883 * bfd-in2.h: Regenerate.
884 * libbfd.h: Likewise.
886 2003-06-30 Alan Modra <amodra@bigpond.net.au>
888 * cpu-ia64-opc.c (ext_imms_scaled): Don't sign extend using shifts.
889 (ins_imms, ins_immsm1u4): Likewise. Warning fix.
891 2003-06-29 Alan Modra <amodra@bigpond.net.au>
893 * archive.c: Convert to C90, remove unnecessary prototypes and casts.
894 Replace PTR with void *. Formatting.
895 * archive64.c: Likewise.
896 * archures.c: Likewise.
897 * bfd-in.h: Likewise.
900 * bfdwin.c: Likewise.
902 * corefile.c: Likewise.
903 * format.c: Likewise.
905 * libbfd-in.h: Likewise.
906 * libbfd.c: Likewise.
907 * linker.c: Likewise.
908 * opncls.c: Likewise.
910 * section.c: Likewise.
911 * simple.c: Likewise.
913 * targets.c: Likewise.
914 * bfd-in2.h: Regenerate.
915 * libbfd.h: Regenerate.
917 * ecoff.c (bfd_debug_section): Add missing kept_section initialization.
918 * libbfd-in.h (_bfd_sh_align_load_span): Don't declare if defined.
919 * libbfd.c (COERCE32, EIGHT_GAZILLION): Simplify.
920 (bfd_getb64): Rewrite without parens.
921 (bfd_getl64, bfd_getb_signed_64, bfd_getl_signed_64): Likewise.
922 * cache.c (insert, snip): Remove INLINE.
923 * linker.c (bfd_link_add_undef): Likewise.
925 2003-06-29 Andreas Jaeger <aj@suse.de>
927 * elf64-x86-64.c: Convert to ISO C90 prototypes, remove
928 unnecessary prototypes. Replace PTR with void *.
929 (elf64_x86_64_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL to
930 trim plt entries. Move undefweak non-default visibility test ...
931 (allocate_dynrelocs): ... from here.
932 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Pass SHARED instead of INFO.
934 (allocate_dynrelocs): Use SYMBOL_CALLS_LOCAL. Use
935 SYMBOL_REFERENCES_LOCAL for dynreloc check.
936 (elf64_x86_64_relocate_section): Use SYMBOL_CALLS_LOCAL for
937 dynreloc and .got relocs.
938 (elf64_x86_64_finish_dynamic_symbol): Use SYMBOL_REFERENCES_LOCAL
941 2003-06-29 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
943 * elfxx-mips.c: Allow lazy binding for R_MIPS_JALR.
945 2003-06-27 Nick Clifton <nickc@redhat.com>
947 * opncls.c (bfd_add_gnu_debuglink_section): Rename to
948 bfd_add_gnu_debuglink_section and only create the section, do not
949 fill in its contents.
950 (bfd_fill_in_gnu_debuglink_section): New function. Fill in the
951 contents of a .gnu-debuglink section.
952 * bfd-in2.h: Regenerate.
954 2003-06-27 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
956 * elfxx-mips.c: Revert .got alignment to 2**4.
958 2003-06-27 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
960 * elf32-mips.c: Fix addend for _gp_disp special symbol.
962 2003-06-27 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
964 * elfxx-mips.c (_bfd_mips_elf_fake_sections): Remove non-default
965 relocation header setup.
967 2003-06-25 Alan Modra <amodra@bigpond.net.au>
969 * elf32-ppc.c (ppc_elf_howto_table): Remove unnecessary cast.
970 (ppc_elf_reloc_type_lookup): Modify comment.
971 (ppc_elf_info_to_howto): Ditto.
972 (ppc_elf_relocate_section): Ditto.
973 (ppc_elf_check_relocs): Call ppc_elf_howto_init.
975 2003-06-25 Alan Modra <amodra@bigpond.net.au>
977 * aout-ns32k.c: Correct spelling of "relocatable".
979 * bfd-in.h: Likewise.
982 * coff-a29k.c: Likewise.
983 * coff-alpha.c: Likewise.
984 * coff-arm.c: Likewise.
985 * coff-i386.c: Likewise.
986 * coff-i860.c: Likewise.
987 * coff-i960.c: Likewise.
988 * coff-m68k.c: Likewise.
989 * coff-m88k.c: Likewise.
990 * coff-mcore.c: Likewise.
991 * coff-mips.c: Likewise.
992 * coff-or32.c: Likewise.
993 * coff-ppc.c: Likewise.
994 * coff-rs6000.c: Likewise.
995 * coff-sh.c: Likewise.
996 * coff-tic80.c: Likewise.
997 * coff64-rs6000.c: Likewise.
998 * cofflink.c: Likewise.
999 * cpu-ns32k.c: Likewise.
1000 * ecoff.c: Likewise.
1001 * ecofflink.c: Likewise.
1002 * elf-bfd.h: Likewise.
1003 * elf-eh-frame.c: Likewise.
1004 * elf-hppa.h: Likewise.
1005 * elf-m10200.c: Likewise.
1006 * elf-m10300.c: Likewise.
1008 * elf32-arm.h: Likewise.
1009 * elf32-avr.c: Likewise.
1010 * elf32-cris.c: Likewise.
1011 * elf32-d10v.c: Likewise.
1012 * elf32-dlx.c: Likewise.
1013 * elf32-fr30.c: Likewise.
1014 * elf32-frv.c: Likewise.
1015 * elf32-h8300.c: Likewise.
1016 * elf32-hppa.c: Likewise.
1017 * elf32-i370.c: Likewise.
1018 * elf32-i386.c: Likewise.
1019 * elf32-i860.c: Likewise.
1020 * elf32-i960.c: Likewise.
1021 * elf32-ip2k.c: Likewise.
1022 * elf32-iq2000.c: Likewise.
1023 * elf32-m32r.c: Likewise.
1024 * elf32-m68hc11.c: Likewise.
1025 * elf32-m68hc1x.c: Likewise.
1026 * elf32-m68k.c: Likewise.
1027 * elf32-mcore.c: Likewise.
1028 * elf32-mips.c: Likewise.
1029 * elf32-msp430.c: Likewise.
1030 * elf32-openrisc.c: Likewise.
1031 * elf32-ppc.c: Likewise.
1032 * elf32-s390.c: Likewise.
1033 * elf32-sh.c: Likewise.
1034 * elf32-sh64.c: Likewise.
1035 * elf32-sparc.c: Likewise.
1036 * elf32-v850.c: Likewise.
1037 * elf32-vax.c: Likewise.
1038 * elf32-xstormy16.c: Likewise.
1039 * elf32-xtensa.c: Likewise.
1040 * elf64-alpha.c: Likewise.
1041 * elf64-hppa.c: Likewise.
1042 * elf64-mips.c: Likewise.
1043 * elf64-mmix.c: Likewise.
1044 * elf64-ppc.c: Likewise.
1045 * elf64-s390.c: Likewise.
1046 * elf64-sh64.c: Likewise.
1047 * elf64-sparc.c: Likewise.
1048 * elf64-x86-64.c: Likewise.
1049 * elfcode.h: Likewise.
1050 * elflink.h: Likewise.
1051 * elfn32-mips.c: Likewise.
1052 * elfxx-ia64.c: Likewise.
1053 * elfxx-mips.c: Likewise.
1054 * i386linux.c: Likewise.
1056 * libcoff-in.h: Likewise.
1057 * linker.c: Likewise.
1058 * m68klinux.c: Likewise.
1059 * pdp11.c: Likewise.
1060 * pe-mips.c: Likewise.
1061 * peXXigen.c: Likewise.
1062 * reloc.c: Likewise.
1063 * reloc16.c: Likewise.
1064 * sparclinux.c: Likewise.
1065 * sunos.c: Likewise.
1067 * versados.c: Likewise.
1069 * xcofflink.c: Likewise.
1070 * bfd-in2.h: Regenerate.
1071 * libcoff.h: Regenerate.
1072 * libbfd.h: Regenerate.
1074 2003-06-24 Alan Modra <amodra@bigpond.net.au>
1076 * elf32-ppc.c (ppc_elf_check_relocs): Report plt reloc against
1079 * elf32-i386.c: Convert to C90 function definitions, remove unnecessary
1080 prototypes and casts. Replace PTR with void *. Formatting.
1081 * elf32-ppc.c: Likewise. Break long strings too.
1082 (ppc_elf_relax_section): Use enum elf_ppc_reloc_type for r_type.
1083 (ppc_elf_unhandled_reloc): Internationalize error message.
1084 * elf32-ppc.h: Remove PARAMS.
1086 2003-06-23 Mark Mitchell <mark@codesourcery.com>
1088 * elf32-ppc.c (ppc_elf_begin_write_processing): Use bytes to count
1090 (ppc_elf_final_write_processing): Likewise.
1092 2003-06-23 H.J. Lu <hongjiu.lu@intel.com>
1094 * elflink.h (elf_link_input_bfd): Check raw size when using
1095 kept_section to preserve debug information discarded by
1098 2003-06-20 Alan Modra <amodra@bigpond.net.au>
1100 * elf64-ppc.c (struct ppc_link_hash_table): Add top_id.
1101 (ppc64_elf_setup_section_lists): Set it.
1102 (ppc64_elf_relocate_section): Check sym section id against top_id.
1103 (ppc_build_one_stub): Comment on top_id.
1105 2003-06-20 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
1107 * config.bfd: Add tic4x-*-rtems*.
1109 2003-06-20 Alan Modra <amodra@bigpond.net.au>
1111 * elf64-ppc.c: Convert to C90 function definitions, remove unnecessary
1112 prototypes and casts. Replace PTR with void *. Format copyright.
1114 (struct ppc_link_hash_table): Rename sgot, srelgot, splt, srelplt,
1115 sdynbss, srelbss, sglink, sbrlt and srelbrlt to got, relgot .. relbrlt.
1116 (ppc_type_of_stub): Make r_type an enum.
1117 (ppc64_elf_size_stubs): Likewise.
1118 * elf64-ppc.h: Remove PARAMS macro.
1120 2003-06-19 Alan Modra <amodra@bigpond.net.au>
1122 * elf64-ppc.c (ppc64_elf_link_hash_table_create): Reinstate init of
1123 elf hash tab fields.
1125 * elf64-ppc.c (ppc64_elf_reloc_type_lookup): Tidy prototype.
1126 (ppc64_elf_info_to_howto): Likewise.
1127 (ppc64_elf_build_stubs): Add "stats" param, and print statistics.
1128 * elf64-ppc.h (ppc64_elf_build_stubs): Adjust prototype.
1130 2003-06-19 Alan Modra <amodra@bigpond.net.au>
1132 * elf64-sparc.c (sparc64_elf_relocate_section): Ignore R_SPARC_DISP32
1133 reloc overflow on discarded eh_frame entries.
1135 2003-06-19 Alan Modra <amodra@bigpond.net.au>
1137 * elf64-ppc.c (toc_adjusting_stub_needed): New function.
1138 (ppc64_elf_next_input_section): Use it here to set has_gp_reloc.
1139 Return error condition.
1140 (ppc64_elf_size_stubs): Restrict toc adjusting stubs to sections
1141 that have has_gp_reloc set.
1142 (struct ppc_link_hash_table): Add stub_count.
1143 (ppc_build_one_stub): Increment it.
1144 (ppc64_elf_link_hash_table_create): zmalloc rather than clearing
1146 * elf64-ppc.h (ppc64_elf_next_input_section): Update prototype.
1148 2003-06-18 Alan Modra <amodra@bigpond.net.au>
1150 * elflink.h (elf_gc_record_vtentry): Revert last change. Correct
1151 size calculation from addend. Round size up.
1153 2003-06-18 Hans-Peter Nilsson <hp@axis.com>
1155 * elf32-cris.c (cris_elf_relocate_section) <case
1156 R_CRIS_32_GOTREL>: When linking a program, don't complain about a
1157 symbol from a normal object or an undefined weak symbol.
1159 2003-06-18 Alan Modra <amodra@bigpond.net.au>
1161 * elf64-ppc.c (ppc64_elf_relocate_section): Accept a symbol on
1164 2003-06-17 H.J. Lu <hongjiu.lu@intel.com>
1166 * section.c (struct sec): Put back kept_section.
1167 (STD_SECTION): Put back kept_section initialization.
1168 * bfd-in2.h: Regenerate.
1170 * elflink.h (elf_link_input_bfd): Also check discarded linkonce
1171 sections for relocateable output. Use kept_section to preserve
1172 debug information discarded by linkonce.
1174 2003-06-17 Roland McGrath <roland@redhat.com>
1176 * elfxx-ia64.c (elfNN_ia64_relocate_section): Support
1177 segment-relative relocation between different segments.
1179 2003-06-17 Alan Modra <amodra@bigpond.net.au>
1181 * elf64-ppc.c (ppc64_elf_relocate_section): Do unaligned reloc
1182 optimizations earlier.
1184 * elf64-ppc.c (struct ppc_link_hash_table): Reinstate top_index.
1185 Restore previous input_list type.
1186 (ppc64_elf_link_hash_table_create): Undo last change.
1187 (ppc64_elf_setup_section_lists): Reinstate code setting up input lists
1188 per output section, but don't bother with bfd_abs_section marker.
1189 (ppc64_elf_next_input_section): Adjust for multiple input section
1191 (group_sections): Likewise.
1193 2003-06-17 Jakub Jelinek <jakub@redhat.com>
1195 * elf64-ppc.c (ppc64_elf_relocation_section): Ensure
1196 *r_offset == r_addend for RELATIVE relocs against .got.
1198 2003-06-17 Alan Modra <amodra@bigpond.net.au>
1200 * elf64-ppc.c (ppc64_elf_relocate_section): Optimize unaligned relocs.
1202 2003-06-17 Nick Clifton <nickc@redhat.com>
1204 * elflink.h (elf_gc_record_vtentry): Allocate an extra element
1205 in the vtable_entries_used array to allow for the accessing
1206 the largest element.
1208 2003-06-17 Alan Modra <amodra@bigpond.net.au>
1210 * elf64-ppc.c (struct ppc_link_hash_table): Remove top_index. Modify
1212 (ppc64_elf_link_hash_table_create): Init input_list here.
1213 (ppc64_elf_setup_section_lists): Remove code setting up input lists
1214 per output section. Set toc_off for abs and other standard sections.
1215 (ppc64_elf_reinit_toc): Don't set elf_gp on input bfds lacking a toc.
1216 (ppc64_elf_next_input_section): Adjust for single input section list.
1217 Don't set toc_curr from input bfds that haven't set elf_gp.
1218 (group_sections): Adjust for single input section list.
1220 * elf64-ppc.c (ppc64_elf_relocate_section): Correct pcrel section zero.
1222 2003-06-16 Alan Modra <amodra@bigpond.net.au>
1224 * elf64-ppc.c (ppc64_elf_relocate_section): When optimizing toctprel
1225 tls, check that a TOC16_DS or TOC16_LO_DS reloc isn't pointing to a
1226 dtprel entry. Ensure TLS_LD DTPMOD reloc has a zero addend. Write
1227 got section for RELATIVE relocs. Fix wrong comment. Change condition
1228 under which dynamic relocs update the section contents.
1230 2003-06-13 Robert Millan <zeratul2@wanadoo.es>
1232 * config.bfd: Add i386-netbsd-gnu target.
1234 2003-06-12 Nick Clifton <nickc@redhat.com>
1236 * opncls.c (calc_crc32): Rename to
1237 bfd_calc_gnu_debuglink_crc32 and export.
1238 (GNU_DEBUGLINK): Define and use to replace occurrences of
1239 hard-coded ".gnu_debuglink" in the code.
1240 (get_debug_link_info): Prevent aborts by replacing call to
1241 xmalloc with a call to malloc.
1242 (find_separate_debug_file): Prevent aborts by replacing calls
1243 to xmalloc and xstrdup with calls to malloc and strdup.
1244 (bfd_add_gnu_debuglink): New function. Add a .gnu_debuglink
1246 * bfd-in2.h: Regenerate.
1248 2003-06-12 Federico G. Schwindt <fgsch@lodoss.net>
1250 * config.bfd (i[3-7]86-*-openbsd[0-2].* | i[3-7]86-*-openbsd3.[0-3]):
1251 New target (was i[3-7]86-*-openbsd* before).
1252 (i[3-7]86-*-openbsd*): Change to use bfd_elf32_i386_vec.
1253 (vax-*-openbsd*): New target.
1255 2003-06-11 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1257 * elfxx-mips.c (MIPS_ELF_OPTIONS_SECTION_NAME): Use .MIPS.options
1259 (MIPS_ELF_STUB_SECTION_NAME): Use .MIPS.stubs for n32, too.
1260 (mips_elf_rel_dyn_section): Use appropriate section alignment.
1261 (mips_elf_create_got_section): Likewise.
1262 (_bfd_mips_elf_create_dynamic_sections): Likewise.
1264 2003-06-11 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1266 * elf32-mips.c (mips_elf_generic_reloc): New Function.
1267 (elf_mips_howto_table_rel): Use it.
1268 (gprel32_with_gp): Move prototype.
1269 (mips_elf_hi16_reloc): Check for ! BSF_LOCAL instead of zero addend.
1270 Use mips_elf_generic_reloc.
1271 (mips_elf_got16_reloc): Check for ! BSF_LOCAL instead of zero addend.
1273 (_bfd_mips_elf32_gprel16_reloc): Check for ! BSF_LOCAL instead of
1275 (mips_elf_gprel32_reloc): Likewise. Use the same GP assignment logic
1276 as in the other *_gprel*_reloc functions.
1277 (gprel32_with_gp): Handle partial_inplace properly.
1278 (mips32_64bit_reloc): Use mips_elf_generic_reloc.
1279 (mips16_gprel_reloc): Check for ! BSF_LOCAL instead of zero addend.
1280 Do addend handling directly instead of calling
1281 _bfd_mips_elf_gprel16_with_gp. Handle partial_inplace properly.
1282 * elf64-mips.c (mips_elf64_hi16_reloc): Check for ! BSF_LOCAL instead
1283 of zero addend. Handle partial_inplace properly.
1284 (mips_elf64_got16_reloc): Check for ! BSF_LOCAL instead of zero
1286 (mips_elf64_gprel16_reloc): Likewise.
1287 (mips_elf64_literal_reloc): Likewise.
1288 (mips_elf64_gprel32_reloc): Likewise. Use the same GP assignment
1289 logic as in the other *_gprel*_reloc functions. Handle
1290 partial_inplace properly.
1291 (mips_elf64_shift6_reloc): Check for ! BSF_LOCAL instead of zero
1292 addend. Handle partial_inplace properly.
1293 (mips16_gprel_reloc): Likewise. Do addend handling directly instead
1294 of calling _bfd_mips_elf_gprel16_with_gp.
1295 * elfn32-mips.c (mips_elf_got16_reloc): Check for BSF_LOCAL.
1296 (mips_elf_gprel32_reloc): Check for ! BSF_LOCAL instead
1298 (mips_elf_shift6_reloc): Handle partial_inplace properly.
1299 (mips16_gprel_reloc): Likewise. Do addend handling directly instead
1300 of calling _bfd_mips_elf_gprel16_with_gp.
1301 * elfxx-mips.c (_bfd_mips_elf_gprel16_with_gp): Handle
1302 partial_inplace properly. Fix wrong addend handling. Fix overflow
1304 (_bfd_mips_elf_sign_extend): Renamed from mips_elf_sign_extend and
1306 (mips_elf_calculate_relocation): Use _bfd_mips_elf_sign_extend.
1307 (_bfd_mips_elf_relocate_section): Likewise.
1308 (mips_elf_create_dynamic_relocation): Update sec_info_type access.
1309 * elfxx-mips.h (_bfd_mips_relax_section): Fix prototype declaration.
1310 (_bfd_mips_elf_sign_extend): New prototype.
1312 2003-06-11 Federico G. Schwindt <fgsch@lodoss.net>
1314 * config.bfd (sparc-*-openbsd[0-2].* | sparc-*-openbsd3.[0-1]):
1315 New target (was sparc-*-openbsd* before).
1316 (sparc-*-openbsd*): Change to use bfd_elf32_sparc_vec.
1318 * configure.in (vax-*-openbsd*): Set COREFILE to netbsd-core.lo.
1319 * configure: Regenerate.
1321 2003-06-11 H.J. Lu <hongjiu.lu@intel.com>
1323 * po/Make-in (DESTDIR): New.
1324 (install-data-yes): Support $(DESTDIR).
1325 (uninstall): Likewise.
1327 2003-06-11 Alan Modra <amodra@bigpond.net.au>
1329 * Makefile.am (config.status): Depend on version.h.
1331 * Makefile.in: Regenerate.
1332 * po/SRC-POTFILES.in: Regenerate.
1334 2003-06-10 Alan Modra <amodra@bigpond.net.au>
1335 Gary Hade <garyhade@us.ibm.com>
1337 * elf64-ppc.c (ppc64_elf_relocate_section <*_DS>): Special case lq.
1339 2003-06-10 Richard Sandiford <rsandifo@redhat.com>
1341 * archures.c (bfd_mach_h8300sxn): New architecture.
1342 * bfd-in2.h: Regenerate.
1343 * cpu-h8300.c (h8300_scan): Check for 'sxn'.
1344 (h8300sxn_info_struct): New.
1345 (h8300sx_info_struct): Link to it.
1346 * elf32-h8300.c (elf32_h8_mach): Add h8300sxn case.
1347 (elf32_h8_final_write_processing): Likewise.
1349 2003-06-08 Alan Modra <amodra@bigpond.net.au>
1351 * elf64-ppc.c: Move TARGET_LITTLE_SYM and other macros used by
1352 elfxx-target.h so that we can use elf_backend_got_header_size.
1353 (ELF_MACHINE_ALT1, ELF_MACHINE_ALT2): Delete.
1354 (GLINK_CALL_STUB_SIZE): Modify. Define new glink call stub and
1356 (ppc64_elf_howto_raw <GOT_TPREL16_DS, GOT_TPREL16_LO_DS>): Correct
1358 (enum ppc_stub_type): Add ppc_stub_long_branch_r2off and
1359 ppc_stub_plt_branch_r2off.
1360 (struct ppc_stub_hash_entry): Reorganize.
1361 (struct ppc_link_hash_table): Add no_multi_toc, multi_toc_needed,
1362 toc_curr, toc_off and emit_stub_syms.
1363 (ppc64_elf_link_hash_table_create): Init them.
1364 (ppc_stub_name): Correct string size.
1365 (ppc64_elf_check_relocs): Set has_gp_reloc on GOT and TOC relocs.
1366 (ppc64_elf_size_dynamic_sections): Set no_multi_toc if GOT entries
1368 (ppc_type_of_stub): Tweak root.type test.
1369 (build_plt_stub): Remove glink code. Adjust for insn macro changes.
1370 (ppc_size_one_stub): Handle ppc_stub_long_branch_r2off and
1371 ppc_stub_plt_branch_r2off.
1372 (ppc_build_one_stub): Likewise. Fix var shadowing. Correct addis,addi
1373 range test. Use toc_off to calculte r2 values. Handle emit_stub_syms.
1374 (ppc64_elf_setup_section_lists): Remove htab creator flavour test.
1375 Initialize elf_gp and toc_curr.
1376 (ppc64_elf_next_toc_section, ppc64_elf_reinit_toc): New functions.
1377 (ppc64_elf_next_input_section): Set toc_off.
1378 (group_sections): Ensure groups have the same TOC.
1379 (ppc64_elf_size_stubs): Check whether we need a TOC adjusting stub.
1380 (ppc64_elf_build_stubs): Add emit_stub_syms param, and stash in htab.
1381 Build new glink stub.
1382 (ppc64_elf_relocate_section): Handle multiple TOCs. Fix comments.
1383 (ppc64_elf_finish_dynamic_sections): Adjust DT_PPC64_GLINK.
1384 * elf64-ppc.h (ppc64_elf_build_stubs): Update prototype.
1385 (ppc64_elf_next_toc_section, ppc64_elf_reinit_toc): Declare.
1386 * section.c (struct sec): Rename flag12 to has_gp_reloc.
1387 (STD_SECTION): Update.
1388 * ecoff.c (bfd_debug_section): Update comment.
1389 * bfd-in2.h: Regenerate.
1391 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
1393 * elfcode.h (elf_slurp_reloc_table_from_section): Don't dereference
1394 NULL function pointers.
1396 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
1398 * simple.c (bfd_simple_get_relocated_section_contents): Call
1399 _bfd_generic_link_add_symbols instead of bfd_link_add_symbols.
1401 2003-06-04 Svein E. Seldal <Svein.Seldal@solidas.com>
1403 * coff-tic54x.c: Removed the ticoff0_bad_format_hook() and
1404 ticoff1_bad_format_hook() functions. Removed the coff0 and coff1
1406 * coff-tic4x.c: Ditto
1407 * coffcode.h: Added extra arguments to CREATE_BIG_COFF_TARGET_VEC
1408 and CREATE_LITTLE_COFF_TARGET_VEC. Created the macro
1409 CREATE_BIGHDR_COFF_TARGET_VEC. Created the ticoff0_bad_format_hook(),
1410 ticoff1_bad_format_hook() functions. Created the coff0 and coff1
1412 * coff-tic4x.c: Adopted new CREATE_xxx_COFF_TARGET_VEC macros.
1413 * coff-a29k.c: Append COFF_SWAP_TABLE argument
1414 * coff-apollo.c: Ditto
1416 * coff-h8300.c: Ditto
1417 * coff-h8500.c: Ditto
1418 * coff-i960.c: Ditto
1419 * coff-m68k.c: Ditto
1420 * coff-m88k.c: Ditto
1421 * coff-mcore.c: Ditto
1423 * coff-sparc.c: Ditto
1424 * coff-tic80.c: Ditto
1425 * coff-we32k.c: Ditto
1429 2003-06-04 Svein E. Seldal <Svein.Seldal@solidas.com>
1431 * coff-tic4x.c (ticoff0_swap_table, ticoff1_swap_table): Fixed
1434 2003-06-03 Jakub Jelinek <jakub@redhat.com>
1436 * elf.c (_bfd_elf_print_private_bfd_data): Handle PT_GNU_STACK.
1437 (bfd_section_from_phdr): Likewise.
1438 (map_sections_to_segments): Create PT_GNU_STACK segment header.
1439 (get_program_header_size): Count with PT_GNU_STACK.
1440 * elf-bfd.h (struct elf_obj_tdata): Add stack_flags.
1441 * elflink.h (bfd_elfNN_size_dynamic_sections): Set stack_flags.
1443 2003-06-03 H.J. Lu <hongjiu.lu@intel.com>
1445 * elflink.h (elf_link_input_bfd): Call linker error_handler
1446 for discarded definitions.
1448 2003-06-03 Elias Athanasopoulos <elathan@phys.uoa.gr>
1450 * syms.c (decode_section_type): Return 'n' if section flags are
1451 SEC_HAS_CONTENTS && SEC_READONLY.
1453 2003-06-03 Nick Clifton <nickc@redhat.com>
1455 * elf32-v850.c (v850_elf_howto_t): Rename R_V850_32to
1456 R_V850_ABS32. Add entry for R_V850_REL32.
1457 (v850_elf_reloc_map): Likewise.
1458 (v850_elf_check_relocs): Likewise.
1459 (v850_elf_perform_relocation): Likewise.
1460 (v850_elf_final_link_relocate): Likewise. Include computation
1461 to make R_V850_REl32 pc-relative.
1463 2003-06-03 Kaz Kojima <kkojima@rr.iij4u.or.jp>
1465 * elf32-sh.c (sh_elf_size_dynamic_sections): Create .interp section
1466 and DT_DEBUG dynamic tag even for position independent executables.
1467 * elf64-sh64.c (sh64_elf64_size_dynamic_sections): Likewize.
1469 2003-06-02 Daniel Jacobowitz <drow@mvista.com>
1471 * config.bfd: Move obsolete entries out of the range of the
1472 targmatch sed script.
1474 2003-06-02 Daniel Jacobowitz <drow@mvista.com>
1476 * config.bfd (mips*-dec-bsd*, mips*-*-pe*): Mark as obsolete.
1478 2003-05-31 Jakub Jelinek <jakub@redhat.com>
1480 * elf32-ppc.c (allocate_dynrelocs): Use single slot for first 8192
1481 plt entries, not just 8191.
1483 2003-05-30 Daniel Jacobowitz <drow@mvista.com>
1485 * elfxx-mips.c (_bfd_mips_elf_discard_info): Correct loop index.
1486 Reported by Ken Faiczak <kfaiczak@SANDVINE.com>.
1488 2003-05-30 Ulrich Drepper <drepper@redhat.com>
1489 Jakub Jelinek <jakub@redhat.com>
1491 * elflink.h (elf_link_add_object_symbols): Use !info->executable
1492 instead of info->shared where appropriate.
1493 (bfd_elfNN_size_dynamic_sections, elf_link_output_extsym): Likewise.
1494 * elflink.c (_bfd_elf_create_got_section): Likewise.
1495 (_bfd_elf_link_create_dynamic_sections): Likewise.
1496 (_bfd_elf_link_assign_sym_version): Likewise.
1497 * elf32-i386.c (elf_i386_size_dynamic_sections): Create .interp section
1498 and DT_DEBUG dynamic tag even for position independent executables.
1499 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise.
1500 * elf32-s390.c (elf_s390_size_dynamic_sections: Likewise.
1501 * elf64-ppc.c (ppc64_elf_size_dynamic_sections: Likewise.
1502 * elf64-s390.c (elf_s390_size_dynamic_sections: Likewise.
1503 * elf64-x86-64.c (elf64_x86_64_size_dynamic_sections: Likewise.
1504 * elfxx-ia64.c (elfNN_ia64_size_dynamic_sections: Likewise.
1505 * elf32-sparc.c (elf32_sparc_size_dynamic_sections: Likewise.
1506 * elf64-alpha.c (elf64_alpha_size_dynamic_sections: Likewise.
1507 * elf64-sparc.c (sparc64_elf_size_dynamic_sections: Likewise.
1509 2003-05-30 Kris Warkentin <kewarken@qnx.com>
1511 * elf.c (elfcore_grok_nto_status): Only set lwpid for the active or
1513 (elfcore_grok_nto_gregs): Only make .reg section for the active thread.
1515 2003-05-29 Nick Clifton <nickc@redhat.com>
1517 * pef.c: Include "safe-ctype.h" instead of <ctype.h>.
1519 * Makefile.am: Add dependency on safe-ctype.h.
1520 * Makefile.in: Regenerate.
1522 2003-05-29 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1524 * elfxx-mips.c: Don't force symbols local unconditionally.
1526 2003-05-28 Alan Modra <amodra@bigpond.net.au>
1528 * elf32-hppa.c (elf32_hppa_relocate_section): Delete bogus
1529 undefined_symbol call.
1531 2003-05-27 Richard Sandiford <rsandifo@redhat.com>
1533 * elfxx-mips.c (mips_elf_hash_sort_data): Fix formattting.
1534 (mips_elf_link_hash_table): Likewise.
1536 2003-05-22 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1538 * elf64-mips.c (elf_mips_gnu_rel16_s2): Add internally used
1539 R_MIPS_GNU_REL16_S2 support.
1540 (bfd_elf64_bfd_reloc_type_lookup): Use it.
1541 (mips_elf64_rtype_to_howto): Use it.
1542 * elfn32-mips.c (elf_mips_gnu_rel16_s2): Add internally used
1543 R_MIPS_GNU_REL16_S2 support.
1544 (bfd_elf32_bfd_reloc_type_lookup): Use it.
1545 (mips_elf_n32_rtype_to_howto): Use it.
1547 2003-05-21 Stuart F. Downing <sdowning@fame.com>
1549 * som.h: Define PA_2_0 before including a.out.h
1551 2003-05-07 Eric Christopher <echristo@redhat.com>
1552 Alexandre Oliva <aoliva@redhat.com>
1554 * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Adjust
1555 pic tests, change to warning.
1556 (_bfd_mips_elf_final_link): Remove EF_MIPS_CPIC flag setting.
1558 2003-05-21 Marcus Comstedt <marcus@mc.pp.se>
1560 * config.bfd: Check for a target triplet of shl-...-netbsdelf as
1561 well as shle-...-netbsdelf. Remove duplicate entry.
1563 2003-05-21 Nick Clifton <nickc@redhat.com>
1565 * elf32-xstormy16.c (xstormy16_elf_howto_table): Fix dst_mask
1566 for X_STORMY16_REL_12 reloc.
1568 * elf.c (bfd_elf_get_needed_list): Use is_elf_hash_table to check
1569 the type of the hash table in the bfd_link_info structure.
1570 (bfd_elf_get_runpath_list): Likewise.
1572 2003-05-19 Roland McGrath <roland@redhat.com>
1574 * elf.c (bfd_elf_bfd_from_remote_memory): New function.
1575 * bfd-in.h: Declare it.
1576 * bfd-in2.h: Regenerated.
1577 * elfcode.h (NAME(_bfd_elf,bfd_from_remote_memory)): New function.
1578 * elf-bfd.h (struct elf_backend_data): New function pointer member
1579 elf_backend_bfd_from_remote_memory.
1580 (_bfd_elf32_bfd_from_remote_memory, _bfd_elf64_bfd_from_remote_memory):
1582 * elfxx-target.h (elf_backend_bfd_from_remote_memory): New macro.
1583 (elfNN_bed): Add that to the initializer.
1585 2003-05-15 Roland McGrath <roland@redhat.com>
1587 * elf.c (elfcore_grok_note): Grok NT_AUXV note, make ".auxv" section.
1589 2003-05-20 Jakub Jelinek <jakub@redhat.com>
1591 * elflink.h (elf_link_output_extsym): Only issue error about !=
1592 STV_DEFAULT symbols if they are bfd_link_hash_undefined.
1594 2003-05-20 H.J. Lu <hongjiu.lu@intel.com>
1596 * elflink.c (_bfd_elf_merge_symbol): Check ELF_LINK_DYNAMIC_DEF
1597 when removing the old definition for symbols with non-default
1600 2003-05-18 Jason Eckhardt <jle@rice.edu>
1602 * elf32-i860.c (elf32_i860_relocate_highadj): Simplify calculation.
1604 2003-05-17 Andreas Schwab <schwab@suse.de>
1606 * elf32-m68k.c (elf_m68k_check_relocs): Cache reloc section in
1607 elf_section_data during processing of pc-relative and absolute
1609 (elf_m68k_relocate_section): Use the cached reloc section instead
1610 of computing it again. Fix handling of visibility. Don't modify
1611 addend when copying over a relocation into the output.
1613 2003-05-17 Alan Modra <amodra@bigpond.net.au>
1615 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL
1616 to trim plt entries. Move undefweak non-default visibility test..
1617 (allocate_dynrelocs): ..from here.
1618 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Don't test
1619 dynamic_sections_created here. Update comment. Move undefweak
1620 non-default visibility test..
1621 (allocate_dynrelocs): ..from here. Fix comment.
1622 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL
1623 to trim plt entries. Move undefweak non-default visibility test..
1624 (allocate_dynrelocs): ..from here. Fix comment.
1625 * elflink.h (elf_link_output_extsym): Compare ELF_ST_VISIBILITY with
1626 STV_DEFAULT rather than comparing with zero.
1627 * elflink.c (_bfd_elf_merge_symbol): Likewise.
1628 (_bfd_elf_fix_symbol_flags): Likewise. Format comment.
1630 2003-05-17 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1632 * bfd.c (_bfd_get_gp_value): Prevent illegal access for abfd null
1634 (_bfd_set_gp_value): Likewise.
1636 2003-05-16 Michael Snyder <msnyder@redhat.com>
1637 From Bernd Schmidt <bernds@redhat.com>
1638 * archures.c (bfd_mach_h8300sx): New.
1639 * bfd-in2.h: Regenerate.
1640 * cpu-h8300.c (h8300_scan)): Add support for h8300sx.
1641 (h8300sx_info_struct): New.
1642 (h8300s_info_struct): Link to it.
1643 * elf32-h8300.c (elf32_h8_mach): Add support for h8300sx.
1644 (elf32_h8_final_write_processing): Likewise.
1645 (elf32_h8_relax_section): Likewise.
1647 2003-05-16 Kelley Cook <kelleycook@wideopenwest.com>
1649 * config.bfd: Accept i[3-7]86 variants.
1650 * configure.host: Likewise.
1651 * configure.in: Likewise.
1652 * configure: Regenerate.
1654 2003-05-15 H.J. Lu <hongjiu.lu@intel.com>
1656 * elflink.c (_bfd_elf_fix_symbol_flags): Also hide protected
1659 2003-05-15 H.J. Lu <hongjiu.lu@intel.com>
1661 * elflink.h (elf_link_check_versioned_symbol): Also allow
1664 2003-05-15 Alan Modra <amodra@bigpond.net.au>
1665 H.J. Lu <hongjiu.lu@intel.com>
1667 * elf32-i386.c (allocate_dynrelocs): Use SYMBOL_CALLS_LOCAL.
1668 (elf_i386_relocate_section): Likewise.
1669 * elf32-ppc.c (allocate_dynrelocs): Likewise.
1670 (ppc_elf_relocate_section): Likewise.
1671 * elf64-ppc.c (allocate_dynrelocs): Likewise.
1672 (ppc64_elf_relocate_section): Likewise.
1674 2003-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1676 * elf32-mips.c (gprel32_with_gp): Remove useless N64 ABI case.
1678 2003-05-13 Stephane Carrez <stcarrez@nerim.fr>
1680 * elf32-m68hc1x.c (_bfd_m68hc11_elf_merge_private_bfd_data): Check for
1681 processor capability, allow merge of HC12 and HCS12 in some cases.
1682 (m68hc11_elf_hash_table_create): Use bfd_malloc instead of bfd_zalloc.
1683 * cpu-m68hc12.c (bfd_m68hc12s_arch): New struct.
1684 (bfd_m68hc12_arch): Link it.
1685 (scan_mach): New function.
1687 2003-05-13 Andrew Haley <aph@redhat.com>
1689 * elf.c (bfd_elf_hash): Mask lower 32 bits of hash.
1691 2003-05-13 Alan Modra <amodra@bigpond.net.au>
1692 H.J. Lu <hongjiu.lu@intel.com>
1694 * elf-bfd.h (SYMBOL_REFERENCES_LOCAL, SYMBOL_CALLS_LOCAL): Move from
1695 elf32-ppc.c. Add ELF_LINK_FORCED_LOCAL check.
1696 * elf32-ppc.c: (SYMBOL_REFERENCES_LOCAL, SYMBOL_CALLS_LOCAL): Delete.
1697 (allocate_dynrelocs): Use SYMBOL_REFERENCES_LOCAL for dynreloc check.
1698 (ppc_elf_relocate_section): Likewise.
1699 * elf64-ppc.c (allocate_dynrelocs): Likewise.
1700 (ppc64_elf_relocate_section): Likewise. Use for .got relocs too.
1701 (ppc64_elf_adjust_dynamic_symbol): Don't assume symbols with .plt
1702 relocs need no other types.
1703 * elf32-i386.c (allocate_dynrelocs): Use SYMBOL_REFERENCES_LOCAL for
1705 (elf_i386_relocate_section): Likewise. Use for .got relocs too.
1706 (elf_i386_finish_dynamic_symbol): Use SYMBOL_REFERENCES_LOCAL for
1709 2003-05-13 Kaz Kojima <kkojima@rr.iij4u.or.jp>
1711 * elf32-sh.c (sh_elf_adjust_dynamic_symbol): For weak symbols,
1712 copy ELF_LINK_NON_GOT_REF from weakdef.
1713 (allocate_dynrelocs): For undef weak syms with non-default
1714 visibility, a) don't allocate plt entries, b) don't allocate
1715 .got relocs, c) discard dyn rel space
1716 (sh_elf_relocate_section): d) don't generate .got relocs, e)
1717 don't generate dynamic relocs.
1718 (sh_elf_copy_indirect_symbol): Don't copy ELF_LINK_NON_GOT_REF
1719 for weakdefs when symbol already adjusted.
1721 2003-05-12 Nick Clifton <nickc@redhat.com>
1723 * elf32-xstormy16.c (xstormy16_elf_howto_table): use 'bitfield'
1724 overflow detection for R_XSTORMY16_16 reloc.
1726 2003-05-12 Paul Clarke <paulc@senet.com.au>
1728 * elf32-h8300.c: Fix typo in name of R_H8_DIR8 reloc.
1730 2003-05-11 Jason Eckhardt <jle@rice.edu>
1732 * elf32-i860.c (elf32_i860_relocate_highadj): Properly
1734 (elf32_i860_relocate_splitn): Obtain upper 5 bits from the
1736 (elf32_i860_relocate_pc16): Obtain upper 5 bits from the
1739 2003-05-11 Andreas Schwab <schwab@suse.de>
1741 * elf32-m68k.c (elf_m68k_relocate_section): Replace ugly
1742 complicated tests for unresolvable relocs with a simple direct
1743 scheme using "unresolved_reloc" var. Report some detail on
1744 bfd_reloc_outofrange and similar errors.
1746 2003-05-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
1748 * elf32-s390.c (allocate_dynrelocs, elf_s390_relocate_section):
1749 Fix WILL_CALL_FINISH_DYNAMIC_SYMBOL call.
1750 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Pass SHARED instead of INFO.
1751 * elf64-s390.c: Likewise.
1753 2003-05-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
1755 * elf32-s390.c (ELIMINATE_COPY_RELOCS): Define as one.
1756 (elf_s390_adjust_dynamic_symbol): For weak symbols, copy
1757 ELF_LINK_NON_GOT_REF from weakdef.
1758 (elf_s390_copy_indirect_symbol): Test whether the weakdef sym has
1759 already been adjusted before treating it specially.
1760 * el64-s390.c: Likwise.
1762 2003-05-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
1764 * elf32-s390.c (allocate_dynrelocs): For undef weak syms with
1765 non-default visibility, a) don't make them dynamic, b) discard
1766 space for dynamic relocs.
1767 (elf_s390_relocate_section): Initialize the GOT entries and skip
1768 R_390_{8,16,32}/R_390_PC{16,16DBL,32DBL,32} for weak undefined
1769 symbols with non-default visibility.
1770 * elf64-s390.c: Likewise.
1772 2003-05-09 Alan Modra <amodra@bigpond.net.au>
1774 * cpu-arm.c (arm_check_note): Warning fix.
1775 * elf32-iq2000.c (iq2000_elf_check_relocs): Warning fixes. Arrange
1776 to keep relocs if edited.
1777 (iq2000_elf_print_private_bfd_data): Return TRUE.
1778 * elfxx-ia64.c (elfNN_ia64_relax_section): Use ELFNN_R_SYM, not
1780 (elfNN_ia64_relax_ldxmov): Warning fix.
1781 * xtensa-isa.c (xtensa_add_isa): Warning fix.
1782 * xtensa-modules.c (get_num_opcodes): Warning fix.
1784 2003-05-09 Andrey Petrov <petrov@netbsd.org>
1786 * elf.c (elf_fake_sections): Use correct cast for sh_name.
1788 2003-05-09 Alan Modra <amodra@bigpond.net.au>
1790 * elflink.c (_bfd_elf_link_create_dynamic_sections): Move from
1791 elflink.h. Replace LOG_FILE_ALIGN with bed->s->log_file_align.
1792 (_bfd_elf_create_dynamic_sections): Use bed->s->log_file_align.
1793 (bfd_elf_record_link_assignment): Move from elflink.h.
1794 (_bfd_elf_merge_symbol): Likewise.
1795 (_bfd_elf_add_default_symbol): Likewise.
1796 (_bfd_elf_export_symbol): Likewise.
1797 (_bfd_elf_link_find_version_dependencies): Likewise.
1798 (_bfd_elf_link_assign_sym_version): Likewise.
1799 (_bfd_elf_link_read_relocs): Likewise.
1800 (_bfd_elf_link_size_reloc_section): Likewise.
1801 (_bfd_elf_fix_symbol_flags): Likewise.
1802 (_bfd_elf_adjust_dynamic_symbol): Likewise.
1803 (_bfd_elf_link_sec_merge_syms): Likewise.
1804 (elf_link_read_relocs_from_section): Likewise. Use bed->s->sizeof_rel
1805 and bed->s->sizeof_rela.
1806 (_bfd_elf_link_output_relocs): Likewise.
1807 * elf-bfd.h (struct elf_size_info): Rename file_align to
1809 (struct elf_info_failed): Move from elflink.h.
1810 (struct elf_assign_sym_version_info): Likewise.
1811 (struct elf_find_verdep_info): Likewise.
1812 (_bfd_elf_create_dynamic_sections): Delete duplicate declaration.
1813 (_bfd_elf_merge_symbol, _bfd_elf_add_default_symbol,
1814 _bfd_elf_export_symbol, _bfd_elf_link_find_version_dependencies,
1815 _bfd_elf_link_assign_sym_version,
1816 _bfd_elf_link_create_dynamic_sections, _bfd_elf_link_read_relocs,
1817 _bfd_elf_link_size_reloc_section, _bfd_elf_link_output_relocs,
1818 _bfd_elf_fix_symbol_flags, _bfd_elf_adjust_dynamic_symbol,
1819 _bfd_elf_link_sec_merge_syms): Declare.
1820 (bfd_elf32_link_create_dynamic_sections): Don't declare.
1821 (_bfd_elf32_link_read_relocs): Likewise.
1822 (bfd_elf64_link_create_dynamic_sections): Likewise.
1823 (_bfd_elf64_link_read_relocs): Likewise.
1824 * elflink.h: Move lots o' stuff elsewhere.
1825 * bfd-in.h (bfd_elf32_record_link_assignment): Don't declare.
1826 (bfd_elf64_record_link_assignment): Likewise.
1827 (bfd_elf_record_link_assignment): Declare.
1828 * bfd-in2.h: Regenerate.
1829 * elfcode.h (elf_link_create_dynamic_sections): Don't declare.
1830 (NAME(_bfd_elf,size_info)): Adjust for log_file_align.
1831 * elf.c (_bfd_elf_init_reloc_shdr): Adjust for bed->s->log_file_align.
1832 (assign_file_positions_for_segments): Likewise.
1833 (assign_file_positions_except_relocs): Likewise.
1834 (swap_out_syms, elfcore_write_note): Likewise.
1835 * elf-m10200.c: Adjust for changed function names.
1836 * elf-m10300.c: Likewise.
1837 * elf32-arm.h: Likewise.
1838 * elf32-h8300.c: Likewise.
1839 * elf32-hppa.c: Likewise.
1840 * elf32-ip2k.c: Likewise.
1841 * elf32-m32r.c: Likewise.
1842 * elf32-m68hc11.c: Likewise.
1843 * elf32-m68hc1x.c: Likewise.
1844 * elf32-m68k.c: Likewise.
1845 * elf32-mips.c: Likewise.
1846 * elf32-ppc.c: Likewise.
1847 * elf32-sh.c: Likewise.
1848 * elf32-v850.c: Likewise.
1849 * elf32-xtensa.c: Likewise.
1850 * elf64-alpha.c: Likewise.
1851 * elf64-hppa.c: Likewise.
1852 * elf64-mmix.c: Likewise.
1853 * elf64-ppc.c: Likewise.
1854 * elf64-sh64.c: Likewise.
1855 * elfxx-ia64.c: Likewise.
1856 * elfxx-mips.c: Likewise.
1857 (MIPS_ELF_LOG_FILE_ALIGN): Use log_file_align.
1858 * elf64-alpha.c (alpha_elf_size_info): Adjust for log_file_align.
1859 * elf64-hppa.c (hppa64_elf_size_info): Likewise.
1860 * elf64-mips.c (mips_elf64_size_info): Likewise.
1861 * elf64-s390.c (s390_elf64_size_info): Likewise.
1862 * elf64-sparc.c (sparc64_elf_size_info): Likewise.
1864 2003-05-08 H.J. Lu <hongjiu.lu@intel.com>
1866 * elflink.h (elf_add_default_symbol): After skipping the
1867 unversioned symbol, go to non-default one.
1869 2003-05-07 H.J. Lu <hongjiu.lu@intel.com>
1871 * elfxx-ia64.c (_bfd_elf_link_hash_hide_symbol): Also clear the
1873 (elfNN_ia64_relocate_section): Don't do dynamic symbol lookup
1874 for symbols with non-default visibility.
1876 2003-05-07 H.J. Lu <hongjiu.lu@intel.com>
1878 * elflink.h (elf_link_check_versioned_symbol): Also handle the
1879 case that a DSO references a hidden symbol which may be
1880 satisfied by a versioned symbol in another DSO.
1881 (elf_link_output_extsym): Check versioned definition for hidden
1882 symbol referenced by a DSO.
1884 2003-05-07 Nick Clifton <nickc@redhat.com>
1886 * elf32-xstormy16.c (xstormy16_elf_howto_table): Reset
1887 R_XSTORMY16_16 reloc to ignore overflows.
1889 2003-05-06 Alexandre Oliva <aoliva@redhat.com>
1891 * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Improve
1892 error message for mixing different-endian files. Check for ABI
1893 compatibility of input files with the selected emulation.
1895 2003-05-05 Alan Modra <amodra@bigpond.net.au>
1897 * elf32-i386.c (allocate_dynrelocs): For undef weak syms with
1898 non-default visibility, a) don't make them dynamic, b) discard
1899 space for dynamic relocs.
1900 * elf64-x86-64.c (allocate_dynrelocs): Likewise.
1902 * elf32-ppc.c (allocate_dynrelocs): For undef weak syms with
1903 non-default visibility, a) don't allocate plt entries, b) don't
1904 allocate .got relocs, c) discard dyn rel space,
1905 (ppc_elf_relocate_section): d) don't generate .got relocs, e)
1906 don't generate dynamic relocs.
1907 * elf64-ppc.c (allocate_dynrelocs): As above.
1908 (ppc64_elf_relocate_section): As above.
1910 2003-05-05 Andreas Jaeger <aj@suse.de>
1912 * elf64-x86-64.c (allocate_dynrelocs): Don't allocate dynamic
1913 relocation entries for weak undefined symbols with non-default
1915 (elf64_x86_64_relocate_section): Initialize the GOT entries and
1916 skip R_386_32/R_386_PC32 for weak undefined symbols with
1917 non-default visibility.
1919 2003-05-04 H.J. Lu <hjl@gnu.org>
1921 * elf32-i386.c (allocate_dynrelocs): Don't allocate dynamic
1922 relocation entries for weak undefined symbols with non-default
1924 (elf_i386_relocate_section): Initialize the GOT entries and
1925 skip R_386_32/R_386_PC32 for weak undefined symbols with
1926 non-default visibility.
1928 * elfxx-ia64.c (allocate_fptr): Don't allocate function
1929 descriptors for weak undefined symbols with non-default
1931 (allocate_dynrel_entries): Don't allocate relocation entries
1932 for symbols resolved to 0.
1933 (set_got_entry): Don't install dynamic relocation for weak
1934 undefined symbols with non-default visibility.
1935 (set_pltoff_entry): Likewise.
1937 * elflink.h (elf_fix_symbol_flags): Hide weak undefined symbols
1938 with non-default visibility.
1939 (elf_link_output_extsym): Don't make weak undefined symbols
1940 with non-default visibility dynamic.
1942 2003-05-04 H.J. Lu <hjl@gnu.org>
1944 * elflink.h (elf_merge_symbol): Correctly handle weak definiton.
1946 2003-05-04 H.J. Lu <hjl@gnu.org>
1948 * elflink.h (elf_merge_symbol): Don't record a hidden/internal
1949 symbol dynamic. Check indirection when removing the old
1950 definition for symbols with non-default visibility.
1951 (elf_add_default_symbol): Skip when told by elf_merge_symbol.
1953 2003-05-02 Nick Clifton <nickc@redhat.com>
1955 * elf32-xstormy16.c (xstormy16_elf_howto_table): Make the
1956 R_XSTORMY16_8 and R_XSTORMY16_16 relocs detect and complain about
1959 2003-05-02 Andreas Jaeger <aj@suse.de>
1961 * elf64-x86-64.c (elf_x86_64_copy_indirect_symbol): Don't copy
1962 ELF_LINK_NON_GOT_REF for weakdefs when symbol already adjusted.
1963 (ELIMINATE_COPY_RELOCS): Define as one. Use throughout.
1964 (elf_x86_64_adjust_dynamic_symbol): For weak symbols, copy
1965 ELF_LINK_NON_GOT_REF from weakdef.
1967 2003-05-02 Charles Lepple <clepple@ghz.cc>
1968 Nick Clifton <nickc@redhat.com>
1970 * acinclude.m4: Fix name of --enable-install-libbfd switch.
1971 * aclocal.m4: Regenerate.
1972 * configure: Regenerate.
1973 * Makefile.in: Regenerate.
1975 2003-05-01 Alan Modra <amodra@bigpond.net.au>
1977 * elf32-ppc.c (ppc_elf_copy_indirect_symbol): Test whether the
1978 weakdef sym has already been adjusted before treating it specially.
1979 * elf32-i386.c (elf_i386_copy_indirect_symbol): Don't copy
1980 ELF_LINK_NON_GOT_REF for weakdefs when symbol already adjusted.
1981 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
1982 (ppc64_elf_check_relocs): Set ELF_LINK_NON_GOT_REF.
1984 2003-04-28 H.J. Lu <hjl@gnu.org>
1986 * elfxx-ia64.c (elfNN_ia64_relax_section): Relax ldxmov during
1987 the relax finalize pass.
1989 * section.c (struct sec): Add need_finalize_relax and remove
1991 (STD_SECTION): Update struct sec initializer.
1992 * bfd-in2.h: Regenerated.
1994 2003-04-28 H.J. Lu <hjl@gnu.org>
1996 * elflink.h (elf_merge_symbol): Call elf_backend_copy_indirect_symbol
1997 to copy any information related to dynamic linking when we flip
2000 2003-04-27 H.J. Lu <hjl@gnu.org>
2002 * elf-bfd.h (ELF_LINK_DYNAMIC_DEF): New.
2003 (ELF_LINK_DYNAMIC_WEAK): New.
2005 * elflink.h (elf_merge_symbol): Add one argument to indicate if
2006 a symbol should be skipped. Ignore definitions in dynamic
2007 objects for symbols with non-default visibility.
2008 (elf_add_default_symbol): Adjusted.
2009 (elf_link_add_object_symbols): Check if a symbol should be
2010 skipped. Don't merge the visibility field with the one from
2012 (elf_link_check_versioned_symbol): Use undef_bfd.
2013 (elf_link_output_extsym): Warn if a forced local symbol is
2014 referenced from dynamic objects. Make non-weak undefined symbol
2015 with non-default visibility a fatal error.
2017 2003-04-27 Daniel Jacobowitz <drow@mvista.com>
2019 * configure.in: Bump version on HEAD to 2.14.90.
2020 * configure: Regenerated.
2022 2003-04-26 Stephane Carrez <stcarrez@nerim.fr>
2025 * elf32-m68hc11.c (m68hc11_elf_relax_section): Clear prev_insn_group
2026 when we couldn't relax something.
2028 2003-04-25 Alan Modra <amodra@bigpond.net.au>
2030 * elflink.h (elf_merge_symbol): When we find a regular definition
2031 for an indirect symbol, flip the indirection so that the old
2032 direct symbol now points to the new definition.
2034 2003-04-24 Roland McGrath <roland@redhat.com>
2036 * elf.c (bfd_section_from_phdr): Map PT_GNU_EH_FRAME to "eh_frame_hdr".
2038 2003-04-24 Alan Modra <amodra@bigpond.net.au>
2040 * elf32-ppc.c: Formatting and comment fixes.
2041 (ELIMINATE_COPY_RELOCS): Move before ppc_elf_copy_indirect_symbol.
2042 (ppc_elf_copy_indirect_symbol): Copy flags here for weakdefs.
2044 2003-04-24 Dhananjay Deshpande <dhananjayd@kpitcummins.com>
2046 * archures.c (bfd_mach_h8300hn, bfd_mach_h8300sn): Added.
2047 * bfd-in2.h: Rebuilt.
2048 * coff-h8300.c (BADMAG): Add check for H8300HNBADMAG & H8300SNBADMAG.
2049 * coffcode.h (coff_set_arch_mach_hook): Add case for H8300HNMAGIC
2051 (coff_set_flags): Add case for bfd_mach_h8300hn & bfd_mach_h8300sn.
2052 * cpu-h8300.c (h8300_scan): Handle h8300hn, h8300sn.
2053 (h8300sn_info_struct, h8300hn_info_struct): New.
2054 * elf32-h8300.c (elf32_h8_mach): Handle case for h8300hn & h8300sn
2055 (elf32_h8_final_write_processing): Likewise.
2057 2003-04-23 Kaz Kojima <kkojima@rr.iij4u.or.jp>
2059 * elf32-sh.c (tpoff): New.
2060 (struct elf_sh_dyn_relocs): Remove tls_tpoff32.
2061 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Pass SHARED instead of INFO.
2062 (allocate_dynrelocs): Don't make unnecessary dynamic TLS
2063 relocations. Adjust WILL_CALL_FINISH_DYNAMIC_SYMBOL uses.
2064 (sh_elf_relocate_section): Likewise. Remove unnecessary tests.
2065 (dtpoff_base): Fix wrong indentation.
2066 (sh_elf_check_relocs): Don't set DF_STATIC_TLS flag with non-TLS
2067 relocations. Don't set tls_tpoff32 flag. Don't make unnecessary
2068 R_SH_TLS_TPOFF32 relocations.
2070 2003-04-23 J"orn Rennecke <joern.rennecke@superh.com>
2072 * archures.c (enum bfd_architecture): Amend comment to refer to SuperH.
2073 * cpu-sh.c: Likewise.
2074 * elf32-sh.c: Likewise.
2075 * reloc.c (bfd_reloc_code_real): Likewise.
2076 * elf32-sh64-com.c: Change comment to refer to SuperH.
2077 * elf32-sh64.c: Likewise.
2078 * elf64-sh64.c: Likewise.
2079 * bfd-in2.h (enum bfd_architecture): Regenerate.
2081 2003-04-23 Alan Modra <amodra@bigpond.net.au>
2083 From Julien LEMOINE <speedblue@debian.org>
2084 * elf32-i386.c (elf_i386_info_to_howto): Delete.
2085 (elf_info_to_howto): Define as elf_i386_info_to_howto_rel.
2087 2003-04-22 Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
2089 * archures.c: Replace references to Mitsubishi M32R with references
2091 * relocs.c: Likewise.
2092 * bfd-in2.h: Regenerate.
2094 2003-04-21 Richard Henderson <rth@redhat.com>
2096 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Return false for an
2097 executable when a symbol is defined both regular and dynamic.
2099 2003-04-21 Stephane Carrez <stcarrez@nerim.fr>
2101 * Makefile.am (BFD32_BACKENDS): Add elf32-m68hc1x.lo.
2102 (elf32-m68hc1x.lo): Update dependencies
2103 * configure.in: Add elf32-m68hc1x.lo.
2104 * configure: Rebuild.
2105 * Makefile.in: Rebuild.
2107 2003-04-21 Stephane Carrez <stcarrez@nerim.fr>
2109 * elf32-m68hc1x.c: New file (from elf32-m68hc11.c and elf32-m68hc12.c)
2110 (m68hc11_elf_hash_table_create): New function.
2111 (elf32_m68hc11_link_hash_table_free): New function.
2112 (stub_hash_newfunc): New function.
2113 (m68hc11_add_stub): New function.
2114 (elf32_m68hc11_add_symbol_hook): New function.
2115 (elf32_m68hc11_setup_section_lists): New function.
2116 (elf32_m68hc11_next_input_section): New function.
2117 (elf32_m68hc11_size_stubs): New function.
2118 (elf32_m68hc11_build_stubs): New function.
2119 (m68hc11_get_relocation_value): New function.
2120 (elf32_m68hc11_relocate_section): Call the above to redirect
2121 some relocations to the trampoline code.
2122 (m68hc11_elf_export_one_stub): New function.
2123 (m68hc11_elf_set_symbol): New function.
2124 (elf32_m68hc11_build_stubs): Call it via bfd_hash_traverse.
2125 (m68hc11_elf_get_bank_parameters): Get parameters only when the info
2126 is not yet initialized.
2128 * elf32-m68hc1x.h: New file (from elf32-m68hc11.c and elf32-m68hc12.c)
2129 (elf32_m68hc11_stub_hash_entry): New struct.
2130 (m68hc11_page_info): Add trampoline handler address.
2131 (m68hc11_elf_link_hash_table): Add stubs generation members.
2132 (elf32_m68hc11_add_symbol_hook): Declare.
2133 (elf32_m68hc11_setup_section_lists): Declare.
2134 (elf32_m68hc11_size_stubs): Declare.
2135 (elf32_m68hc11_build_stubs): Declare.
2137 * elf32-m68hc11.c (m68hc11_elf_ignore_reloc): Move to elf32-m68hc1x.c.
2138 (elf32_m68hc11_gc_mark_hook, elf32_m68hc11_gc_sweep_hook): Likewise.
2139 (elf32_m68hc11_check_relocs, elf32_m68hc11_relocate_section): Ditto.
2140 (_bfd_m68hc11_elf_set_private_flags): Ditto.
2141 (_bfd_m68hc11_elf_merge_private_bfd_data): Ditto.
2142 (_bfd_m68hc11_elf_print_private_bfd_data): Ditto.
2143 (bfd_elf32_bfd_link_hash_table_create): Define.
2144 (elf_backend_add_symbol_hook): Define.
2145 (m68hc11_elf_bfd_link_hash_table_create): New function.
2146 (m68hc11_elf_build_one_stub): New function.
2147 (m68hc11_elf_size_one_stub): New function.
2148 (m68hc11_elf_bfd_link_hash_table_create): Install the above.
2149 (bfd_elf32_bfd_link_hash_table_create): Define.
2151 * elf32-m68hc12.c (m68hc11_elf_ignore_reloc): Remove.
2152 (m68hc12_addr_is_banked): Remove, use m68hc11_addr_is_banked.
2153 (m68hc12_phys_addr): Ditto.
2154 (m68hc12_phys_page): Ditto.
2155 (m68hc12_elf_special_reloc): Move to elf32-m68hc1x.c.
2156 (elf32_m68hc11_gc_mark_hook): Likewise.
2157 (elf32_m68hc11_gc_sweep_hook): Likewise.
2158 (elf32_m68hc11_check_relocs): Likewise.
2159 (elf32_m68hc11_relocate_section): Likewise.
2160 (_bfd_m68hc12_elf_set_private_flags): Likewise.
2161 (_bfd_m68hc12_elf_merge_private_bfd_data): Likewise.
2162 (_bfd_m68hc12_elf_print_private_bfd_data): Likewise.
2163 (m68hc12_elf_build_one_stub): New function.
2164 (m68hc12_elf_size_one_stub): New function.
2165 (m68hc12_elf_bfd_link_hash_table_create): New function, use the above.
2166 (elf_backend_add_symbol_hook): Define.
2167 (elf_m68hc11_howto_table): Use TRUE for pcrel relocs; fix masks.
2169 2003-04-18 Nick Clifton <nickc@redhat.com>
2171 * format.c (bfd_check_format_matches): Only check associated
2172 vector if the matching_vector has been created.
2174 2003-04-15 Alexandre Oliva <aoliva@redhat.com>
2176 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Fix typo in
2177 2003-04-09's change.
2179 2003-04-15 Brian Ford <ford@vss.fsi.com>
2181 * peicode.h (coff_swap_scnhdr_in): If a section holds
2182 uninitialized data and is from an object file or from an
2183 executable image that has not initialized the s_size field, or if
2184 the physical size is padded, use the virtual size (stored in
2187 2003-04-15 H.J. Lu <hjl@gnu.org>
2189 * elflink.h (elf_link_add_object_symbols): Properly report
2190 filename for alignment reduction.
2192 2003-04-15 Rohit Kumar Srivastava <rohits@kpitcummins.com>
2194 * archures.c: Replace occurrances of 'Hitachi' with 'Renesas'.
2195 * reloc.c: Likewise.
2196 * coff-h8300.c: Likewise.
2197 * coff-h8500.c: Likewise.
2198 * coff-sh.c: Likewise.
2199 * cpu-h8300.c: Likewise.
2200 * cpu-sh.c: Likewise.
2201 * elf32-h8300.c: Likewise.
2202 * elf32-sh.c: Likewise.
2203 * elf32-sh64-com.c: Likewise.
2204 * elf32-sh64.c: Likewise.
2205 * elf64-sh64.c: Likewise.
2206 * bfd-in2.h: Regenerate.
2208 2003-04-14 H.J. Lu <hjl@gnu.org>
2210 * elflink.h (elf_link_add_object_symbols): Maintain maximum
2211 alignment for common symbols. Warn reducing alignment for
2212 common symbols. Report old filename when symbol size changes.
2214 2003-04-12 Alexandre Oliva <aoliva@redhat.com>
2216 * elfxx-mips.c (mips_elf_calculate_relocation): Adjust two other
2217 occurrences of the same test changed in the previous patch.
2220 2003-04-11 Alexandre Oliva <aoliva@redhat.com>
2222 * elfxx-mips.c (mips_elf_get_global_gotsym_index): New.
2223 (mips_elf_calculate_relocation): Decay GOT_PAGE/GOT_OFST to
2224 GOT_DISP/addend only if the symbol got a global GOT entry.
2226 2003-04-10 Alexandre Oliva <aoliva@redhat.com>
2228 * elfxx-mips.c (mips_elf_calculate_relocation): Decay
2229 GOT_PAGE/GOT_OFST referencing overridable symbol to
2231 (_bfd_mips_elf_check_relocs): Handle GOT_PAGE referencing
2232 global symbol as GOT_DISP.
2234 2003-04-10 Bob Wilson <bob.wilson@acm.org>
2236 * elf32-xtensa.c (elf_xtensa_relocate_section): Don't continue to the
2237 next relocation on an undefined symbol.
2239 2003-04-09 Richard Henderson <rth@redhat.com>
2241 * elf64-alpha.c (elf64_alpha_relocate_section) <R_ALPHA_GPREL32>:
2242 Ignore relocations against r_symndx == 0.
2244 2003-04-09 H.J. Lu <hjl@gnu.org>
2246 * elf64-alpha.c (elf64_alpha_relocate_section): Don't return
2247 FALSE for undefined symbols.
2248 * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
2250 2003-04-09 Alexandre Oliva <aoliva@redhat.com>
2252 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Try DWARF3-standard
2253 and IRIX-specific shift-to-64-bit 4-byte lengths before following
2256 2003-04-08 Alexandre Oliva <aoliva@redhat.com>
2258 * elf32-mips.c (bfd_elf32_bfd_reloc_type_lookup): Detect (ctor)
2259 pointer size from ABI, not arch_bits_per_address.
2261 2003-04-07 Kevin Buettner <kevinb@redhat.com>
2263 * elfn32-mips.c (elf32_mips_grok_prstatus): Adjust core file related
2264 constants for n32 ABI.
2266 2003-04-06 Andrew Cagney <cagney@redhat.com>
2268 * simple.c (bfd_simple_get_relocated_section_contents): Disable
2269 free that leads to GDB vs BFD memory corruption.
2271 2003-04-04 Stephane Carrez <stcarrez@nerim.fr>
2273 * elf32-m68hc11.c (m68hc11_elf_relax_delete_bytes): Also adjust
2274 symbols that mark the end of the section.
2275 (m68hc11_elf_relax_section): Use R_M68HC11_PCREL_8 relocs when
2276 converting to a relative branch so that the offset is computed after
2277 the relaxation; also relocate a jsr into a bsr if possible but don't
2278 relax them if they are to a far symbol as we need to call the
2280 (elf_m68hc11_howto_table): Set pcrel_offset to true.
2282 2003-04-04 Svein E. Seldal <Svein.Seldal@solidas.com>
2284 * archures.c: Namespace cleanup. Rename bfd_mach_c3x to
2285 bfd_mach_tic3x and bfd_mach_c4x to bfd_mach_tic4x
2286 * bfd-in2.h: Regenerate
2287 * coff-tic4x.c: Namespace cleanup. Replace s/c4x/tic4x/
2288 * cpu-tic4x.c: Ditto
2290 2003-04-03 Nick Clifton <nickc@redhat.com>
2292 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Compute ps and ss
2293 differently for object files and executables.
2294 * peicode.h (coff_swap_scnhdr_in): Only set the s_size field
2295 for object files or for executables who have not already
2296 initialised the field.
2297 * libpei.h (bfd_pe_executable_p): New macro. Return true if
2298 the PE format bfd is an executable.
2300 2003-04-03 Alan Modra <amodra@bigpond.net.au>
2302 * elf32-ppc.c (ppc_elf_check_relocs): Don't use SYMBOL_REFERENCES_LOCAL
2303 here as it's too early to reliably determine locality.
2304 (ppc_elf_gc_sweep_hook): Likewise.
2305 (SYMBOL_REFERENCES_LOCAL): Expand comment.
2307 2003-04-02 Bob Wilson <bob.wilson@acm.org>
2309 * xtensa-modules.c: Remove comment indicating that this is a
2312 2003-04-02 Alan Modra <amodra@bigpond.net.au>
2314 * elfxx-mips.c (_bfd_mips_elf_hide_symbol): Test for NULL dynobj.
2316 2003-04-01 Bob Wilson <bob.wilson@acm.org>
2318 * Makefile.am (ALL_MACHINES): Add cpu-xtensa.lo.
2319 (ALL_MACHINES_CFILES): Add cpu-xtensa.c.
2320 (BFD32_BACKENDS): Add elf32-xtensa.lo, xtensa-isa.lo, and
2322 (BFD32_BACKENDS_CFILES): Add elf32-xtensa.c, xtensa-isa.c, and
2324 (cpu-xtensa.lo): New target.
2325 (elf32-xtensa.lo): Likewise.
2326 (xtensa-isa.lo): Likewise.
2327 (xtensa-modules.lo): Likewise.
2328 * Makefile.in: Regenerate.
2329 * archures.c (bfd_architecture): Add bfd_{arch,mach}_xtensa.
2330 (bfd_archures_list): Add bfd_xtensa_arch.
2331 * config.bfd: Handle xtensa-*-*.
2332 * configure.in: Handle bfd_elf32_xtensa_{le,be}_vec.
2333 * configure: Regenerate.
2334 * reloc.c: Add BFD_RELOC_XTENSA_{RTLD,GLOB_DAT,JMP_SLOT,RELATIVE,
2335 PLT,OP0,OP1,OP2,ASM_EXPAND,ASM_SIMPLIFY}.
2336 * targets.c (bfd_elf32_xtensa_be_vec): Declare.
2337 (bfd_elf32_xtensa_le_vec): Likewise.
2338 (bfd_target_vector): Add bfd_elf32_xtensa_{be,le}_vec.
2339 * cpu-xtensa.c: New file.
2340 * elf32-xtensa.c: Likewise.
2341 * xtensa-isa.c: Likewise.
2342 * xtensa-modules.c: Likewise.
2343 * libbfd.h: Regenerate.
2344 * bfd-in2.h: Likewise.
2346 2003-04-01 Nick Clifton <nickc@redhat.com>
2348 * archures.c (bfd_mach_arm_unknown): Define.
2349 * bfd-in.h (bfd_arm_merge_machines, bfd_arm+update_notes,
2350 bfd_arm_get_mach_from_notes): Prototype.
2351 * bfd-in2.h: Regenerate.
2352 * coff-arm.c (coff_arm_merge_private_bfd_data): Call
2353 bfd_arm_merge_machines.
2354 (coff_arm_final_link_postscript): Call bfd_arm_update_notes.
2355 * coffcode.h (coff_set_arch_mach_hook): Call
2356 bfd_arm_get_mach_from_notes.
2357 * coffgen.c (coff_real_object_p): Revert previous delta.
2358 * cpu_arm.c (arm_check_note): New function. Examine a note in a
2360 (bfd_arm_merge_machines): New function: Handle the merging of ARM
2361 binaries compiled for different architectures..
2362 (bfd_arm_update_notes): New function: Update an ARM note section.
2363 (bfd_arm_get_mach_from_notes): New function: Extract a bfd machine
2364 number from an ARM note section.
2365 * elf32-arm.h (elf32_arm_object_p): Use
2366 bfd_arm_get_mach_from_notes.
2367 (elf32_arm_merge_private_bfd_data): Use bfd_arm_merge_machines.
2368 (elf32_arm_final_write_processing): Use bfd_arm_update_notes.
2370 2003-04-01 Ben Elliston <bje@wasabisystems.com>
2372 * dwarf2.c (read_attribute_value): Correct typo in comment.
2374 2003-04-01 Nick Clifton <nickc@redhat.com>
2376 * dwarf2.c (concat_filename): Use bfd_malloc() and strdup()
2377 instead of concat().
2378 (decode_line_info): Only free filename if it is not NULL.
2379 (add_line_info): Make a copy of the filename when storing it into
2382 2003-03-31 Andreas Schwab <schwab@suse.de>
2383 Daniel Jacobowitz <drow@mvista.com>
2385 * simple.c (bfd_simple_get_relocated_section_contents): Add
2386 parameter symbol_table. Optionally use it instead of the symbol
2387 table from the bfd. Save and restore output offsets and output
2388 sections around bfd_get_relocated_section_contents. Fix a memory
2390 (simple_save_output_info, simple_restore_output_info): New
2392 * bfd-in2.h: Regenerate.
2393 * dwarf2.c (read_abbrevs): Use
2394 bfd_simple_get_relocated_section_contents instead of
2395 bfd_get_section_contents.
2396 (decode_line_info): Likewise.
2397 (_bfd_dwarf2_find_nearest_line): Likewise. Don't call
2399 (find_rela_addend): Remove.
2400 * elfxx-ia64.c (elfNN_ia64_reloc): Weaken sanity check for
2402 (elfNN_ia64_hash_table_create): Create the hash table with malloc,
2405 2003-03-31 David Heine <dlheine@suif.stanford.edu>
2407 * aoutx.h (aout_link_hash_table_create): Use bfd_malloc instead of
2409 * dwarf2.c (concat_filename): Always allocate space for the
2411 (decode_line_info): Free the allocated filename returned by
2413 * elf-eh-frame.c (bfd_elf_write_section_eh_frame): Fix memory leaks.
2414 * elf.c (copy_private_bfd_data): Likewise.
2415 (_bfd_elf_slurp_version_tables): Fix bug freeing contents pointer.
2416 * elflink.h (elf_link_sort_relocs): Fix memory leak.
2417 * format.c (bfd_check_format_matches): Likewise.
2418 * linker.c (bfd_generic_final_link): Likewise.
2419 * opncls.c (find_separate_debug_info): Likewise.
2420 * simple.c (bfd_simple_get_relocated_section_contents): Likewise.
2422 2003-03-28 H.J. Lu <hjl@gnu.org>
2424 * elflink.h (elf_link_add_object_symbols): Correctly combine
2427 2003-03-27 Jakub Jelinek <jakub@redhat.com>
2429 * elfxx-ia64.c (elfNN_ia64_relax_section): Reset self_dtpmod_offset
2430 to -1 before recomputing got offsets.
2432 2003-03-26 Andreas Schwab <schwab@suse.de>
2434 * elf32-m68k.c (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
2435 (elf_m68k_relocate_section): Use it to correctly handle symbols
2437 (elf_m68k_finish_dynamic_symbol): Emit RELATIVE reloc for got
2438 entries for symbols that are forced to be local.
2440 2003-03-25 Alexandre Oliva <aoliva@redhat.com>
2442 * elfxx-mips.c (_bfd_mips_relax_section): New function.
2443 * elfxx-mips.h (_bfd_mips_relax_section): Declare.
2444 * elfn32-mips.c, elf64-mips.c: Use it.
2446 2003-03-25 Stan Cox <scox@redhat.com>
2447 Nick Clifton <nickc@redhat.com>
2449 Contribute support for Intel's iWMMXt chip - an ARM variant:
2451 * archures.c: Add bfd_mach_arm_iWMMXt.
2452 * reloc.c: Add BFD_RELOC_ARM_CP_OFF_IMM_S2.
2453 * bfd-in2.h: Regenerate.
2454 * libbfd.h: Regenerate.
2455 * coff-arm.c (coff_arm_merge_private_bfd_data): Allow iWMMXt
2456 object files to be linked with XScale ones.
2457 (coff_arm_final_link_postscript): Update note section.
2458 * coffcode.h (coff_set_arch_mach_hook): Handle note section.
2459 * coffgen.c (coff_real_object_p): Call bfd_coff_set_arch_mach_hook
2460 after identifying a coff binary.
2461 * cpu-arm.c (processors): Add iWMMXt.
2462 (arch_inf): Likewise.
2463 * elf32-arm.h (arm_object_p): Handle note section.
2464 (elf32_arm_merge_private_bfd_data): Allow iWMMXt object files to
2465 be linked with XScale ones.
2466 (elf32_arm_section_flags): New function: Set flags on note section.
2467 (elf32_arm_final_write_processing): Handle note section.
2469 2003-03-21 DJ Delorie <dj@redhat.com>
2471 * elf32-xstormy16.c (elf32_xstormy16_relocate_section): Call
2472 _bfd_elf_rela_local_sym.
2474 2003-03-20 H.J. Lu <hjl@gnu.org>
2476 * elfxx-ia64.c (elfNN_ia64_relax_section): Don't try relax for
2479 2003-03-20 Nick Clifton <nickc@redhat.com>
2481 * peXXigen.c (_bfd_XXi_swap_aouthdr_out): Initialise $idata2 and
2482 $idata5 in case bfd_coff_final_link is not called.
2484 2003-03-19 Jakub Jelinek <jakub@redhat.com>
2486 * elf64-sparc.c (struct sparc64_elf_section_data): Add reloc_count
2488 (canon_reloc_count): Define.
2489 (sparc64_elf_slurp_one_reloc_table, sparc64_elf_slurp_reloc_table,
2490 sparc64_elf_canonicalize_dynamic_reloc): Use it instead of
2492 (sparc64_elf_canonicalize_reloc): New routine.
2493 (bfd_elf64_canonicalize_reloc): Define.
2495 2003-03-18 Jakub Jelinek <jakub@redhat.com>
2497 * elfxx-ia64.c (elfNN_ia64_relax_section): Handle relaxation
2498 againt mergeable sections. Take r_addend into account when caching
2501 2003-03-18 Richard Henderson <rth@redhat.com>
2503 * elfxx-ia64.c (get_dyn_sym_info): Return NULL gracefully for
2504 local symbols that have no dyninfo.
2506 2003-03-14 Gene Smith <gene.smith@siemens.com>
2508 * ieee.c (ieee_write_expression): Handle the case where symbol is
2510 General formatting improvements.
2512 2003-03-13 Nick Clifton <nickc@redhat.com>
2514 * configure.in (LINGUAS): Add zh_CN.
2515 * configure: Regenerate.
2516 * po/zh_CN.po: New file.
2518 2003-03-13 Elias Athanasopoulos <elathan@phys.uoa.gr>
2520 * aout-cris.c (BYTES_IN_WORD): Don't define.
2521 aout-encap.c: Likewise.
2522 aout-ns32k.c: Likewise.
2523 aout-tic30.c: Likewise.
2524 hp300bsd.c: Likewise.
2525 i386aout.c: Likewise.
2526 i386dynix.c: Likewise.
2527 i386linux.c: Likewise.
2528 i386lynx.c: Likewise.
2529 i386mach3.c: Likewise.
2530 m68k4knetbsd.c: Likewise.
2531 m68klinux.c: Likewise.
2532 m68klynx.c: Likewise.
2533 m68knetbsd.c: Likewise.
2534 m88kmach3.c: Likewise.
2535 mipsbsd.c: Likewise.
2536 newsos3.c: Likewise.
2537 sparclinux.c: Likewise.
2538 sparclynx.c: Likewise.
2539 sparcnetbsd.c: Likewise.
2540 vaxbsd.c: Likewise. Fix comment formatting.
2542 2003-03-12 Alexandre Oliva <aoliva@redhat.com>
2544 * Reverted 2003-03-02's patch.
2546 * elfxx-target.h (bfd_elfNN_canonicalize_reloc): Make it
2548 * elf64-mips.c (mips_elf64_canonicalize_reloc,
2549 mips_elf64_get_dynamic_reloc_upper_bound,
2550 mips_elf64_canonicalize_dynamic_reloc): New, adapted from elf.c.
2551 (bfd_elf64_get_canonicalize_reloc,
2552 bfd_elf64_get_dynamic_reloc_upper_bound,
2553 bfd_elf64_canonicalize_dynamic_reloc): Define.
2554 (mips_elf64_slurp_reloc_table): Support dynamic.
2555 (mips_elf64_slurp_one_reloc_table): Adjust.
2557 2003-03-12 Nick Clifton <nickc@redhat.com>
2559 * xsym.c (bfd_sym_fetch_type_information_table_entry): Change
2560 'index' to 'offset' in test for zero value.
2562 2003-03-11 Alexandre Oliva <aoliva@redhat.com>
2564 * elfxx-mips.c (mips_elf_create_dynamic_relocation): Do not create
2565 dynamic relocations pointing to local or section symbols, use the
2566 NULL symbol instead. Document the choice to not emit an
2567 additional R_MIPS_64 relocation.
2569 2003-03-11 Alan Modra <amodra@bigpond.net.au>
2571 * elf32-ppc.c (ppc_elf_relocate_section): Subtract tls seg vma from
2572 zero index dynamic tls relocs generated for the GOT. Tidy code.
2573 Set "relocation" to 1 on DTPMOD32 relocs. Optimize HA adjustment.
2574 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
2576 2003-03-07 Alan Modra <amodra@bigpond.net.au>
2578 * elf32-ppc.c (ppc_elf_relocate_section): Don't look for a nop after
2579 a tls_get_addr call.
2581 * elf32-ppc.c (ELIMINATE_COPY_RELOCS): Define as one.
2582 (ppc_elf_adjust_dynamic_symbol): For weak symbols, copy
2583 ELF_LINK_NON_GOT_REF from weakdef.
2584 * elf64-ppc.c (ELIMINATE_COPY_RELOCS): Define as one.
2585 (ppc64_elf_adjust_dynamic_symbol): For weak symbols, copy
2586 ELF_LINK_NON_GOT_REF from weakdef.
2587 * elf32-i386.c (ELIMINATE_COPY_RELOCS): Define as one. Use throughout.
2588 (elf_i386_adjust_dynamic_symbol): For weak symbols, copy
2589 ELF_LINK_NON_GOT_REF from weakdef.
2591 2003-03-06 Jakub Jelinek <jakub@redhat.com>
2592 Andrew Haley <aph@redhat.com>
2594 * elflink.h (elf_bfd_discard_info): Don't process eh frames if
2595 output is relocateable.
2597 2003-03-06 Steven Konopa <skonopa@kgo.csc.com>
2599 * som.c (som_fixup_formats): Correct formats for R_AUX_UNWIND and
2602 2003-03-06 Alan Modra <amodra@bigpond.net.au>
2604 * elf32-ppc.c (ppc_elf_create_linker_section): Don't capitalize
2606 (ELIMINATE_COPY_RELOCS): Define to zero.
2607 (ppc_elf_relocate_section): Don't deref htab->tls_sec when calculating
2608 TLSLD relocs. Report reloc types on a number of errors. Optimize
2609 LOCAL24PC check for non-local syms. Don't capitalize error messages.
2610 * elf64-ppc.c (ELIMINATE_COPY_RELOCS): Define to zero.
2611 (ppc64_elf_relocate_section): Don't deref htab->tls_sec when
2612 calculating TLSLD relocs. Report reloc types on a number of errors.
2613 Don't capitalize error messages.
2615 2003-03-03 H.J. Lu <hjl@gnu.org>
2617 * elfxx-ia64.c (USE_BRL): Removed.
2620 2003-03-03 J"orn Rennecke <joern.rennecke@superh.com>
2622 * elf32-sh.c (sh_elf_howto_tab): Make R_SH_IND12W into an ordinary
2623 relocation (no special function), and make it non-partial_inplace.
2624 (sh_elf_relax_section): When creating a bsr, use a consistent value
2625 no matter if the symbol is extern or not; set addend to -4.
2626 Don't swap load / non-load instructions for SH4.
2627 (sh_elf_relax_delete_bytes): In R_SH_IND12W case, check the offset
2628 rather than if the symbol is external to determine if adjusting the
2629 offset makes sense. Adjust the addend too if appropriate.
2630 (sh_elf_relocate_section): In R_SH_IND12W, don't fiddle with the
2633 2003-03-03 Nick Clifton <nickc@redhat.com>
2635 * po/da.po: Installed latest translation.
2637 2003-03-02 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2639 * elf32-mips.c (elf_mips_howto_table_rel): Change definition of
2640 R_MIPS_PC16 to rightshift 2.
2641 (elf_reloc_map mips_reloc_map): Map to rightshifted BFD reloc.
2642 (bfd_elf32_bfd_reloc_type_lookup): Support
2643 BFD_RELOC_MIPSEMB_16_PCREL_S2.
2644 * elf64-mips.c (mips_elf64_howto_table_rel): Change definition of
2645 R_MIPS_PC16 to rightshift 2.
2646 (mips_elf64_howto_table_rela): Likewise.
2647 (mips_reloc_map): Map to rightshifted BFD reloc.
2648 * elfn32-mips.c: The same as in elf64-mips.c.
2649 * elfxx-mips.c (mips_elf_got_for_ibfd): Typo in comment.
2650 (mips_elf_calculate_relocation): Handle rightshifted addends for
2652 * reloc.c (BFD_RELOC_MIPSEMB_16_PCREL_S2): New BFD relocation for
2653 MIPS Embedded PIC. Remove superfluous empty COMMENT.
2654 * libbfd.h: Regenerate.
2655 * bfd-in2.h: Regenerate.
2657 2003-02-28 Richard Henderson <rth@redhat.com>
2659 * elfxx-ia64.c (elfNN_ia64_relax_section): Correct bounds
2660 for ltoff22x relaxation.
2662 2003-03-01 Alan Modra <amodra@bigpond.net.au>
2664 * bfd-in.h (_bfd): Don't define.
2665 * bfd.c: Rename occurrences of "struct _bfd" to "struct bfd".
2667 * bfd-in2.h: Regenerate.
2669 2003-02-27 Richard Henderson <rth@redhat.com>
2671 * elfxx-ia64.c (struct elfNN_ia64_dyn_sym_info): Add want_gotx;
2672 (elfNN_ia64_check_relocs): Set it.
2673 (allocate_global_data_got): Check it.
2674 (allocate_local_got): Likewise.
2675 (allocate_dynrel_entries): Likewise.
2676 (elfNN_ia64_relax_ldxmov): New.
2677 (elfNN_ia64_relax_section): Handle LTOFF22X, LDXMOV.
2678 (elfNN_ia64_choose_gp): Split out from ...
2679 (elfNN_ia64_final_link): ... here.
2681 2003-02-27 Andrew Cagney <cagney@redhat.com>
2683 * bfd.c (struct bfd): Rename "struct _bfd".
2684 * bfd-in.h: Update copyright.
2685 (struct bfd): Rename "struct _bfd".
2686 (_bfd): Define for backward compatibility.
2687 * bfd-in2.h: Regenerate.
2689 2003-02-25 Alan Modra <amodra@bigpond.net.au>
2691 * elflink.h (elf_bfd_final_link): Apportion reloc counts to rel_hdr
2692 and rel_hdr2 when initially counting input relocs rather than after
2693 creating output reloc sections.
2694 (elf_link_read_relocs_from_section): Don't abort with wrong reloc
2697 * Makefile.am: Run "make dep-am".
2698 * Makefile.in: Regenerate.
2700 2003-02-24 Kris Warkentin <kewarken@qnx.com>
2702 * elf.c (elfcore_read_notes): Add check for QNX style core file.
2703 (elfcore_grog_nto_note): New function.
2704 (elfcore_grog_nto_gregs): New function.
2705 (elfcore_grog_nto_status): New function.
2707 2003-02-24 Alan Modra <amodra@bigpond.net.au>
2709 * elflink.c (_bfd_elf_create_got_section): Check existing .got
2710 section flags before concluding that we've already been called.
2711 Don't use register keyword.
2712 (_bfd_elf_create_dynamic_sections): Don't use register keyword.
2713 (_bfd_elf_create_linker_section): Formatting.
2715 2003-02-20 jmc <jmc@prioris.mini.pw.edu.pl>
2717 * coff-h8300.c: Fix typo: intial -> initial.
2718 * coff-ppc.c: Likewise.
2720 2003-02-20 Alan Modra <amodra@bigpond.net.au>
2722 * elf32-ppc.c: Formatting.
2723 (allocate_dynrelocs): LD and GD relocs against the same sym need
2724 separate GOT entries.
2725 (ppc_elf_relocate_section): Correct GOT handling for multiple GOT
2728 2003-02-19 Alan Modra <amodra@bigpond.net.au>
2730 * elf32-hppa.c (elf32_hppa_gc_sweep_hook): Simplify dynamic reloc
2731 removal. Localize vars. Remove unnecessary dynobj test.
2732 * elf32-i386 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Pass SHARED instead
2734 (allocate_dynrelocs): Adjust WILL_CALL_FINISH_DYNAMIC_SYMBOL uses,
2736 (elf_i386_relocate_section): Likewise.
2737 (elf_i386_gc_sweep_hook): Simplify dyn reloc removal. Localize vars.
2738 * elf32-s390.c (elf_s390_gc_sweep_hook): Likewise.
2739 * elf32-sh.c (sh_elf_gc_sweep_hook): Likewise.
2740 * elf64-s390.c (elf_s390_gc_sweep_hook): Likewise.
2741 * elf64-x86-64.c (elf64_x86_64_gc_sweep_hook): Likewise.
2742 * elf32-sparc.c (elf32_sparc_gc_sweep_hook): Likewise. Remove
2743 local_dynrel for section too. Don't touch HIPLT22, LOPLT10, PCPLT32
2744 or PCPLT10 relocs. Don't subtract twice on PLT32 relocs.
2747 * elf64-ppc.c (ELIMINATE_COPY_RELOCS): Define.
2748 (ppc64_elf_check_relocs): Use it. Correct comment. Move SEC_ALLOC
2750 (ppc64_elf_adjust_dynamic_symbol): Use ELIMINATE_COPY_RELOCS.
2751 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Pass SHARED instead of INFO.
2752 (allocate_dynrelocs): Adjust WILL_CALL_FINISH_DYNAMIC_SYMBOL uses,
2753 and optimize. Use ELIMINATE_COPY_RELOCS.
2754 (ppc64_elf_relocate_section): Likewise.
2756 * elf32-ppc.c (struct ppc_elf_dyn_relocs): Add pc_count field.
2757 (ppc_elf_copy_indirect_symbol): Copy pc_count field.
2758 (ELIMINATE_COPY_RELOCS): Define.
2759 (ppc_elf_adjust_dynamic_symbol): Convert copy relocs to dynamic.
2760 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Pass SHARED instead of INFO.
2761 (MUST_BE_DYN_RELOC): Define.
2762 (allocate_dynrelocs): Adjust WILL_CALL_FINISH_DYNAMIC_SYMBOL uses,
2763 and optimize. Trim dyn_relocs.
2764 (ppc_elf_check_relocs): Don't generate dyn_relocs when we know they'll
2765 not be used. Do generate dyn_relocs for copy reloc avoidance. Keep
2766 track of pc_rel dyn relocs.
2767 (ppc_elf_relocate_section): Remove "will_become_local". Adjust
2768 WILL_CALL_FINISH_DYNAMIC_SYMBOL use. Trim dyn relocs as per
2769 allocate_dynrelocs. Don't recalculate "sec".
2771 2003-02-18 Alan Modra <amodra@bigpond.net.au>
2773 * elf32-ppc.c (ppc_elf_relocate_section): Remove unnecessary test.
2774 * elf64-ppc.c (ppc64_elf_tls_optimize): Decrement tlsld_got.refcount
2775 on invalid LD relocs.
2776 (allocate_dynrelocs): Invalid LD relocs don't use tlsld_got entry.
2777 (ppc64_elf_relocate_section): Unify new handling of LD relocs and
2778 tlsld_got entry. Use IS_PPC64_TLS_RELOC.
2780 * elf32-ppc.h: New file.
2781 * elf32-ppc.c: Include elf32-ppc.h.
2782 (NOP, CROR_151515, CROR_313131, TP_OFFSET, DTP_OFFSET): Define.
2783 (struct ppc_elf_link_hash_entry): Rename "root" to "elf". Adjust uses.
2784 Add "tls_mask" field.
2785 (TLS_GD, TLS_LD, TLS_TPREL, TLS_DTPREL, TLS_TLS, TLS_TPRELGD): Define.
2786 (struct ppc_elf_link_hash_table): Rename "root" to "elf". Adjust uses.
2787 Add got, relgot, plt, relplt, dynbss, relbss, dynsbss, relsbss,
2788 sdata, sdata2, tls_sec, tls_get_addr, tlsld_got fields.
2789 Make use of htab shortcuts throughout file.
2790 (ppc_elf_link_hash_newfunc): Init tls_mask field.
2791 (ppc_elf_link_hash_table_create): Init new fields.
2792 (ppc_elf_copy_indirect_symbol): Copy tls_mask.
2793 (ppc_elf_howto_raw): Add tls relocs.
2794 (ppc_elf_reloc_type_lookup): Handle them.
2795 (ppc_elf_unhandled_reloc): New function.
2796 (ppc_elf_create_got): Stash got section pointer in hash table,
2797 return status. Make .rela.got too.
2798 (ppc_elf_create_dynamic_sections): Stash section pointers in htab.
2799 (ppc_elf_adjust_dynamic_symbol): Only set up copy relocs when
2800 NON_GOT_REF set. Don't allocate space in .plt here..
2801 (allocate_dynrelocs): ..do so here instead, properly ref-counting and
2802 not allocating plt entries unnecessarily. Allocate got entries here.
2803 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
2804 (ppc_elf_size_dynamic_sections): Allocate local got entries. Pass
2805 "info" during allocate_dynrelocs hash traversal. Use htab section
2806 shortcuts rather than searching for named sections. Get rid of
2807 "plt" and "strip" booleans.
2808 (update_local_sym_info, bad_shared_reloc): New functions.
2809 (ppc_elf_check_relocs): Handle TLS relocs. Move .rela.got creation to
2810 ppc_elf_create_got. Don't mark got or plt reloc syms dynamic, do so
2811 in allocate_dynreloc. Use update_local_sym_info and bad_shared_reloc.
2812 Disallow R_PPC_EMB_RELSDA, R_PPC_EMB_NADDR32, R_PPC_EMB_NADDR16,
2813 R_PPC_EMB_NADDR16_LO, R_PPC_EMB_NADDR16_HI and R_PPC_EMB_NADDR16_HA
2814 in shared libs. R_PPC_PLTREL32 is a plt reloc too. Refcount all
2815 relocs that might use a plt entry. Set NON_GOT_REF too.
2816 Enumerate all do-nothing relocs.
2817 (ppc_elf_gc_sweep_hook): Simplify removal of dynrelocs. Handle
2818 tls relocs and all plt relocs.
2819 (ppc_elf_tls_setup, ppc_elf_tls_optimize): New functions.
2820 (ppc_elf_finish_dynamic_symbol): Don't build got entries here.
2821 (ppc_elf_finish_dynamic_sections): Rewrite tag code using htab
2823 (ppc_elf_relocate_section): Tidy. Handle TLS relocs. Use
2824 bfd_elf_local_sym_name. Simplify unresolved reloc code. Build got
2825 entries and got relocs here. Warn on non-zero got reloc addend.
2826 Split out branch taken/not taken reloc code into a separate switch
2827 and correct offset calculation. Allow BRTAKEN/BRNTAKEN dynamic relocs.
2828 Split out HA reloc adjustments to separate switch statement. Don't
2829 warn on reloc overflow if we've already warned about undefined.
2830 Don't rebuild sym name when reporting errors. Report all possible
2831 errors from _bfd_final_link_relocate.
2832 (bfd_elf32_bfd_final_link): Don't define.
2834 2003-02-18 Alan Modra <amodra@bigpond.net.au>
2836 * elf64-ppc.c (ppc64_elf_relocate_section): Don't init "r". Don't
2837 rebuild sym name when reporting errors.
2839 2003-02-17 Nick Clifton <nickc@redhat.com>
2841 * elflink.h (elf_link_output_extsym): Only check
2842 allow_shlib_undefined for shared libraries.
2843 * elf32-i386.c (elf_i386_relocate_section): Remove bogus check
2844 of allow_shlib_undefined.
2845 * elf32-cris.c (cris_elf_relocate_section): Likewise.
2846 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
2847 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
2848 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
2849 * elf32-s390.c (elf_s390_relocate_section): Likewise.
2850 * elf32-sh.c (sh_elf_relocate_section): Likewise.
2851 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
2852 * elf32-vax.c (elf_vax_relocate_section): Likewise.
2853 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
2854 * elf64-hppa.c (elf64_hppa_relocate_section): Likewise.
2855 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
2856 * elf64-s390.c (elf_s390_relocate_section): Likewise.
2857 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
2858 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
2859 * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
2860 * elfxx-mips.c (_bfd_mips_elf_relocate_section): Likewise.
2862 2003-02-17 Nick Clifton <nickc@redhat.com>
2864 * elf.c (SEGMENT_AFTER_SEGMENT): Add third parameter - the
2865 address field to use in the comparison.
2866 (SEGMENT_OVERLAPS): Check that LMAs overlap as well.
2868 2003-02-14 Bob Wilson <bob.wilson@acm.org>
2870 * elfcore.h (elf_core_file_p): Compare alternate machine codes for ELF
2871 backends when checking if the generic ELF target should be used.
2873 * syms.c (_bfd_stab_section_find_nearest_line): For line number stabs
2874 outside of functions, treat values as absolute addresses.
2876 * bfd.c: Change embedded documentation to use consistent indentation
2877 and to split up long lines. Change informal style of description
2878 for functions lacking real documentation.
2879 * coffcode.h: Break up long lines in embedded documentation.
2880 * format.c: Likewise.
2881 * targets.c: Likewise.
2882 * libcoff.h: Regenerate.
2883 * bfd-in2.h: Regenerate.
2885 2003-02-14 Alan Modra <amodra@bigpond.net.au>
2887 * elf64-ppc.c (ppc64_elf_link_hash_table_create): Init tls_get_addr.
2888 (ppc64_elf_copy_indirect_symbol): Merge tls_mask too.
2889 (ppc64_elf_gc_sweep_hook): Simplify removal of dyn_relocs.
2890 (allocate_dynrelocs): Don't treat undefined and undefweak specially.
2891 (ppc_size_one_stub): Fix warning, and tighten plt entry check.
2892 (group_sections): Don't share a stub section if stubs are for a large
2893 section. Adjust comment.
2894 (ppc64_elf_size_stubs): Roughly double the size left for stubs if
2895 !stubs_always_before_branch.
2896 (ppc64_elf_relocate_section): Initialize tlsld GOT entry once. Don't
2897 treat undefined and undefweak specially when processing dyn relocs.
2899 2003-02-13 Jakub Jelinek <jakub@redhat.com>
2901 * elflink.h (elf_link_add_object_symbols): Handle .symver x, x@FOO.
2903 2003-02-13 Nick Clifton <nickc@redhat.com>
2905 * elf32-arm.h (elf32_thumb_to_arm_stub): Include section VMAs
2906 in computation of offset to insert into BL instruction.
2908 2003-02-11 Uwe Stieber <uwe@wwws.de>
2910 * config.bfd: Add support for kaOS as cross build target system.
2912 2003-02-11 Alan Modra <amodra@bigpond.net.au>
2914 * elf64-ppc.c (ppc64_elf_check_relocs): Match versioned
2915 .__tls_get_addr too.
2916 (ppc64_elf_tls_setup): Ensure cached tls_get_addr is not indirect.
2918 2003-02-10 Kaz kojima <kkojima@rr.iij4u.or.jp>
2920 * elf32-sh.c (elf_sh_dyn_relocs): Add tls_tpoff32 field.
2921 (elf_sh_link_hash_entry): Remove tls_tpoff32 field.
2922 (sh_elf_link_hash_newfunc): Remove the initialization of
2924 (allocate_dynrelocs): Keep dyn_relocs if it includes the entry
2925 for which tls_tpoff32 flag is set.
2926 (sh_elf_relocate_section): Covert to LE only if the dyn_relocs
2927 of the symbol includes the entry matched with the input_section
2928 and having tls_tpoff32 flag on. When linking statically, set
2929 symbol index of R_SH_TLS_TPOFF32 relocation to zero if the symbol
2930 is defined in this executable.
2931 (sh_elf_check_relocs): Set tls_tpoff32 flag appropriately.
2933 2003-02-10 Jakub Jelinek <jakub@redhat.com>
2935 * elf32-s390.c (elf_s390_size_dynamic_sections): Set relocs to TRUE
2936 even if there is just non-empty .rela.plt.
2938 2003-02-10 Nick Clifton <nickc@redhat.com>
2940 * archures.c (bfd_mach_arm_ep9312): Define.
2941 * bfd-in2.h: Regenerate.
2942 * cpu-arm.c (processors[]): Add ep9312.
2943 (bfd_arm_arch): Add ep9312.
2944 * elf32-arm.h (elf32_arm_merge_private_data): Update error
2945 messages and add test for Maverick floating point support.
2946 (elf32_arm_print_private_bfd_data): Handle
2947 EF_ARM_MAVERICK_FLOAT flag.
2948 (elf32_arm_object_p): New function.
2949 (elf_backend_object_p): Define.
2951 2003-02-10 Alan Modra <amodra@bigpond.net.au>
2953 * elf64-ppc.c: Rename assorted occurrences of tls_type and similar
2954 variables, structure fields or function params to tls_mask or
2955 similar to better reflect usage.
2956 (struct got_entry): Comment.
2957 (struct ppc_link_hash_entry): Expand comment, and renumber TLS_*.
2958 (get_tls_mask): Rename from get_tls_type.
2960 2003-02-09 Alan Modra <amodra@bigpond.net.au>
2962 * elf64-ppc.c (TLS_GD_LD): Don't define..
2963 (TLS_GD): ..define this instead and update all uses.
2964 (TLS_TPRELGD): Define.
2965 (ppc64_elf_link_hash_table_create): Tweak initialization of
2966 init_refcount and init_offset.
2967 (ppc64_elf_check_relocs): Add one extra element to t_symndx array.
2968 Mark second slot of GD or LD toc entries.
2969 (get_tls_type): Return an int. Distinguish toc GD and LD entries
2970 from other tls types.
2971 (ppc64_elf_tls_setup): New function, split out from..
2972 (ppc64_elf_tls_optimize): ..here. Don't optimize when symbols are
2973 defined in a dynamic object. Fix LD optimization. Don't set TLS_TPREL
2974 on GD->IE optimization, use TLS_TPRELGD instead. Use get_tls_type
2975 return value to properly decide whether toc GD and LD entries can
2976 optimize away __tls_get_addr call. Check next reloc after DTPMOD64
2977 to determine GD or LD rather than looking at TLS_LD flag. Don't
2978 attempt to adjust got entry tls_type here..
2979 (allocate_dynrelocs): ..instead, adjust got entry tls_type here, and
2980 look for possible merges.
2981 (ppc64_elf_size_dynamic_sections): Adjust local got entries for
2983 (ppc64_elf_size_stubs): Tweak __tls_get_addr fudge.
2984 (ppc64_elf_relocate_section): Rename some vars to better reflect usage.
2985 Make use of return value from get_tls_type to properly detect GD and
2986 LD optimizations. Split tlsld/gd hi/ha from lo/ds case. Don't
2987 handle tls_get_addr removal when looking at REL24 relocs, do it when
2988 looking at the previous reloc. Check reloc after DTPMOD64 to determine
2990 * elf64-ppc.h (ppc64_elf_tls_setup): Declare.
2992 2003-02-08 Alan Modra <amodra@bigpond.net.au>
2994 * elf32-hppa.c (group_sections): Don't share a stub section if
2995 stubs are for a large section.
2997 * elf32-hppa.c (elf32_hppa_size_stubs): Double the size left for
2998 stubs if !stubs_always_before_branch.
3000 2003-02-07 Nick Clifton <nickc@redhat.com>
3002 * elf.c (swap_out_syms): Generate an error message if an
3003 equivalent output section cannot be found for a symbol.
3005 2003-02-07 Jakub Jelinek <jakub@redhat.com>
3007 * elf64-alpha.c (elf64_alpha_relax_section): Don't crash if
3008 local_got_entries is NULL.
3010 2003-02-06 Andreas Schwab <schwab@suse.de>
3012 * elf-eh-frame.c (get_DW_EH_PE_signed): Define.
3013 (read_value): Add parameter is_signed, use signed extraction if
3014 the value is signed.
3015 (_bfd_elf_write_section_eh_frame): Pass signed flag of the
3016 encoding to read_value.
3018 2003-02-06 Alan Modra <amodra@bigpond.net.au>
3020 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Don't copy got and
3021 plt info when called to transfer weak sym info.
3023 2003-02-05 Alan Modra <amodra@bigpond.net.au>
3025 * reloc.c: Add PPC and PPC64 TLS relocs.
3026 * libbfd.h: Regenerate.
3027 * bfd-in2.h: Regenerate.
3028 * elf64-ppc.c (TP_OFFSET, DTP_OFFSET): Declare.
3029 (ppc64_elf_howto_raw): Add TLS howto's. Adjust R_PPC64_NONE to be
3030 against a 32 bit field.
3031 (ppc64_elf_reloc_type_lookup): Handle TLS relocs.
3032 (_ppc64_elf_section_data): Add t_symndx and comments.
3033 (ppc64_elf_section_data): Use elf_section_data macro.
3034 (ppc64_elf_new_section_hook): American spelling.
3035 (struct got_entry, struct plt_entry): New.
3036 (MUST_BE_DYN_RELOC): Rename from IS_ABSOLUTE_RELOC.
3037 (struct ppc_stub_hash_entry): Add "addend" field.
3038 (struct ppc_link_hash_entry): Add "tls_type".
3039 (TLS_TLS, TLS_GD_LD, TLS_LD, TLS_TPREL, TLS_DTPREL,
3040 TLS_EXPLICIT): Define.
3041 (struct ppc_link_hash_table): Add tls_sec, tls_get_addr, tlsld_got.
3042 (link_hash_newfunc): Init new fields.
3043 (ppc64_elf_link_hash_table_create): Likewise. Set init_refcount and
3044 init_offset to NULL.
3045 (ppc64_elf_copy_indirect_symbol): Copy got and plt info. Don't call
3046 _bfd_elf_link_hash_copy_indirect, rather insert relevant code from
3048 (update_local_sym_info, update_plt_info): New functions.
3049 (ppc64_elf_check_relocs): Use them. Handle TLS relocs. Adjust GOT
3050 handling to use got.glist rather than got.refcount. Likewise for PLT.
3051 (ppc64_elf_gc_sweep_hook): Handle TLS relocs, new GOT and PLT lists.
3052 (func_desc_adjust): Adjust for new PLT list.
3053 (ppc64_elf_adjust_dynamic_symbol): Likewise.
3054 (get_sym_h, get_tls_type): New functions.
3055 (ppc64_elf_edit_opd): Remove unused variable. Use get_sym_h.
3056 (ppc64_elf_tls_optimize): New function.
3057 (allocate_dynrelocs): Adjust for new PLT and GOT lists. Allocate
3059 (ppc64_elf_size_dynamic_sections): Likewise.
3060 (ppc_type_of_stub): Adjust for new PLT list.
3061 (ppc_build_one_stub): Likewise.
3062 (ppc64_elf_size_stubs): Likewise. Use get_sym_h. Treat __tls_get_addr
3064 (ppc64_elf_relocate_section): Adjust for new GOT and PLT lists. Handle
3065 TLS relocs. Report local syms using bfd_elf_local_sym_name. Don't
3066 init GOT entries that have a reloc. Generate GOT relocs here..
3067 (ppc64_elf_finish_dynamic_symbol): ..not here. Adjust for PLT list.
3068 * elf64-ppc.h (ppc64_elf_tls_optimize): Declare.
3070 2003-02-04 Andreas Schwab <schwab@suse.de>
3072 * elf32-m68k.c (elf_m68k_hash_entry): Define.
3073 (elf_m68k_link_hash_traverse): Remove.
3074 (elf_m68k_link_hash_newfunc): Use struct bfd_hash_entry and
3075 elf_m68k_hash_entry instead of struct elf_m68k_link_hash_entry to
3077 (elf_m68k_check_relocs): Use elf_m68k_hash_entry instead of
3079 (elf_m68k_size_dynamic_sections): Use elf_link_hash_traverse
3080 instead of elf_m68k_link_hash_traverse.
3081 (elf_m68k_discard_copies): Change first parameter to pointer to
3082 struct elf_link_hash_entry and use elf_m68k_hash_entry when struct
3083 elf_m68k_link_hash_entry is needed.
3085 2003-02-04 Alan Modra <amodra@bigpond.net.au>
3087 * elf-bfd.h (struct got_entry, struct plt_entry): Forward declare.
3088 (struct elf_link_hash_entry): Add "glist" and "plist" fields to
3089 "got" union, and declare as gotplt_union. Use gotplt_uinion for
3091 (struct elf_link_hash_table): Make "init_refcount" a gotplt_union.
3092 Add "init_offset" field.
3093 (struct elf_obj_tdata <local_got>): Add "struct got_entry **" to union.
3094 (elf_local_got_ents): Declare.
3095 * elf.c (_bfd_elf_link_hash_newfunc): Adjust initialization of "got"
3097 (_bfd_elf_link_hash_hide_symbol): Use "init_offset".
3098 (_bfd_elf_link_hash_table_init): Set "init_offset".
3099 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set init_refcount
3101 (elf_adjust_dynamic_symbol): Set plt and got offsets using init_offset.
3103 * elf.c (bfd_elf_local_sym_name): Split out from..
3104 (group_signature): ..here.
3105 * elf-bfd.h (bfd_elf_local_sym_name): Declare.
3107 2003-02-04 Alan Modra <amodra@bigpond.net.au>
3109 * elf-bfd.h (enum elf_link_info_type): Remove.
3110 (struct bfd_elf_section_data): Move sec_info_type, use_rela_p fields
3111 to struct sec. Remove linkonce_p field.
3112 (elf_linkonce_p): Delete.
3113 (elf_discarded_section): Update for sec_info_type change.
3114 * section.c (struct sec): Add sec_info_type, use_rela_p, has_tls_reloc,
3115 flag11, flag12, flag13, flag14, flag15, flag16, flag20, flag24.
3116 (ELF_INFO_TYPE_NONE): Define.
3117 (ELF_INFO_TYPE_STABS): Define.
3118 (ELF_INFO_TYPE_MERGE): Define.
3119 (ELF_INFO_TYPE_EH_FRAME): Define.
3120 (ELF_INFO_TYPE_JUST_SYMS): Define.
3121 (STD_SECTION): Update struct sec initializer.
3122 * ecoff.c (bfd_debug_section): Likewise.
3123 * elf.c: Likewise. Update occurrences of sec_info_type and use_rela_p.
3124 * elflink.h: Likewise.
3125 * elf-eh-frame.c: Likewise.
3126 * elf64-alpha.c: Likewise.
3127 * elfxx-ia64.c: Likewise.
3128 * elfxx-mips.c: Likewise.
3129 * bfd-in2.h: Regenerate.
3131 * elf32-sparc.c (sec_do_relax): Use elf_section_data macro rather than
3132 referring to used_by_bfd.
3133 * elf64-sparc.c (sec_do_relax): Likewise.
3134 * elf64-mmix.c (mmix_elf_section_data): Likewise.
3135 * elfxx-mips.c (mips_elf_section_data): Likewise.
3136 * ieee.c (ieee_slurp_section_data): Use ieee_per_section macro.
3137 (ieee_get_section_contents): Likewise.
3138 (ieee_new_section_hook): Formatting.
3139 (ieee_canonicalize_reloc): Remove commented out code.
3140 * mmo.c (mmo_section_data): Define. Use throughout file.
3141 * oasys.c (oasys_get_section_contents): Use oasys_per_section macro.
3143 2003-01-31 Graydon Hoare <graydon@redhat.com>
3145 * Makefile.am (opncls.lo): Add dependency upon libiberty.h.
3146 * Makefile.in: Regenerate.
3147 * opncls.c (calc_crc32, get_debug_link_info,
3148 seperate_debug_file_exists, find_seperate_debug_file): New
3150 (bfd_follow_gnu_debuglink): New function. Follow the pointer
3151 contained inside a .gnu_debuglink section.
3152 * bfd-in2.h: Regenerate.
3154 2003-01-29 Alexandre Oliva <aoliva@redhat.com>
3156 * elfxx-mips.c (mips_elf_got_entry_hash): Don't dereference
3157 entry->abfd when it's NULL.
3159 2003-01-27 Alexandre Oliva <aoliva@redhat.com>
3161 * elfxx-mips.c (mips_elf_create_dynamic_relocation): Handle
3162 _bfd_elf_section_offset returning -2 the same way as -1.
3164 * elfxx-mips.c (mips_elf_multi_got): New function.
3165 (struct mips_got_entry): Make symndx and gotidx signed. Moved
3166 addend into union along with address and link hash entry.
3167 (struct mips_got_info): Added bfd2got and next.
3168 (struct mips_elf_hash_sort_data): Added max_unref_got_dynindx.
3169 (mips_elf_got_section, mips_elf_create_got_section): Use
3170 SEC_EXCLUDE bit to tell whether we really need the got
3171 section. Take boolean arguments to disregard an excluded
3172 section, or to create it as excluded. Adjust all callers.
3173 Use mips_elf_got_section all over.
3174 (mips_elf_local_got_index, mips_elf_got_page,
3175 mips_elf_got16_entry): Take input bfd as argument, and pass it
3176 on to mips_elf_create_local_got_entry.
3177 (mips_elf_global_got_index, mips_elf_create_local_got_entry):
3178 Take input bfd as argument, and manage entries in the
3180 (mips_elf_got_offset_from_index): Take input bfd as argument,
3181 and use it to adjust the GP offset of the bfd.
3182 (mips_elf_sort_hash_table, mips_elf_sort_hash_table_f): Move
3183 unreferenced GOT entries of global symbols to the end.
3184 (mips_elf_record_global_got_symbol): Take input bfd as
3185 argument. Add entries to the master GOT hash table.
3186 (struct mips_elf_bfd2got_hash): New.
3187 (struct mips_elf_got_per_bfd_arg): New.
3188 (struct mips_elf_set_global_got_offset_arg): New.
3189 (mips_elf_hash_bfd_vma, mips_elf_multi_got_entry_hash,
3190 mips_elf_multi_got_entry_eq, mips_elf_bfd2got_entry_hash,
3191 mips_elf_bfd2got_entry_eq, mips_elf_make_got_per_bfd,
3192 mips_elf_merge_gots, mips_elf_set_global_got_offset,
3193 mips_elf_resolve_final_got_entry,
3194 mips_elf_resolve_final_got_entries, mips_elf_adjust_gp,
3195 mips_elf_got_for_ibfd): New functions.
3196 (ELF_MIPS_GP_OFFSET): Don't depend on SGI_COMPAT.
3197 (MIPS_ELF_GOT_MAX_SIZE): New macro.
3198 (STUB_LW): Generate 64-bit stub regardless of SGI_COMPAT.
3199 (mips_elf_got_entry_hash): Take new fields into account. Use
3200 mips_elf_hash_bfd_vma.
3201 (mips_elf_got_entry_eq): Take new fields into account.
3202 (mips_elf_create_got_section): Initialize new fields.
3203 (mips_elf_calculate_relocation): Pass input_bfd to functions
3204 that now take it. Adjust gp for the input_bfd.
3205 (mips_elf_allocate_dynamic_relocation,
3206 mips_elf_create_dynamic_relocation,
3207 _bfd_mips_elf_create_dynamic_sections): Use...
3208 (mips_elf_rel_dyn_section): New function. Borrow code from...
3209 (_bfd_mips_elf_check_relocs): Pass input_bfd to functions that
3210 now take it. Create the got section if needed, even if
3211 excluded, before recording a global got symbol. Move some
3213 (mips_elf_record_local_got_symbol): New fn.
3214 (_bfd_mips_elf_size_dynamic_sections): Disable combreloc.
3215 Compute multi-got global entries offsets. Move GOT code to...
3216 (_bfd_mips_elf_always_size_sections): Call mips_elf_multi_got
3217 if the GOT is too big.
3218 (_bfd_mips_elf_finish_dynamic_symbol): Set got entry of
3219 undefweak symbol to zero. Generate dynamic relocations for
3220 non-primary GOT entries for global symbols.
3221 (_bfd_mips_elf_finish_dynamic_sections): Handle multi-got
3222 case. Generate dynamic relocations for local got entries.
3223 Sort dynamic relocations on N64 too, using...
3224 (sort_dynamic_relocs_64): New fns.
3225 (_bfd_mips_elf_hide_symbol): Adjust multi-got counters.
3226 (_bfd_mips_elf_merge_private_bfd_data): Ignore EF_MIPS_XGOT.
3228 2003-01-27 Alexandre Oliva <aoliva@redhat.com>
3230 * bfd.c (struct _bfd): Added id field.
3231 * opncls.c (_bfd_id_counter): New static variable.
3232 (_bfd_new_bfd): Use it.
3233 * bfd-in2.h: Rebuilt.
3235 2003-01-25 Alan Modra <amodra@bigpond.net.au>
3237 * elf32-sparc.c (bfd_elf32_new_section_hook): Define.
3239 2003-01-25 Jakub Jelinek <jakub@redhat.com>
3241 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Add TLS relocs.
3242 (elf32_sparc_rev32_howto): New variable.
3243 (sparc_reloc_map): Add TLS relocs.
3244 (elf32_sparc_reloc_type_lookup, elf32_sparc_info_to_howto):
3246 (sparc_elf_hix22_reloc, sparc_elf_lox10_reloc, elf32_sparc_mkobject):
3248 (struct elf32_sparc_dyn_relocs, struct elf32_sparc_link_hash_entry,
3249 struct elf32_sparc_link_hash_table):
3251 (elf32_sparc_tdata, elf32_sparc_local_got_tls_type,
3252 elf32_sparc_hash_table): Define.
3253 (link_hash_newfunc, elf32_sparc_link_hash_table_create,
3254 create_got_section, elf32_sparc_create_dynamic_sections,
3255 elf32_sparc_copy_indirect_symbol, elf32_sparc_tls_transition): New
3257 (elf32_sparc_check_relocs): Handle TLS relocs. Add dynamic reloc
3259 (elf32_sparc_gc_sweep_hook): Likewise.
3260 (elf32_sparc_adjust_dynamic_symbol): Likewise.
3261 (elf32_sparc_size_dynamic_sections): Likewise.
3262 (elf32_sparc_relocate_section): Likewise.
3263 (allocate_dynrelocs, readonly_dynrelocs, dtpoff_base, tpoff):
3265 (elf32_sparc_object_p): Allocate backend private object data.
3266 (bfd_elf32_bfd_link_hash_table_create,
3267 elf_backend_copy_indirect_symbol, bfd_elf32_mkobject,
3268 elf_backend_can_refcount): Define.
3269 (elf_backend_create_dynamic_sections): Define to
3270 elf32_sparc_create_dynamic_sections.
3271 * reloc.c: Add SPARC TLS relocs.
3272 * bfd-in2.h, libbfd.h: Rebuilt.
3273 * elf64-sparc.c (sparc64_elf_howto_table): Add TLS relocs.
3274 (sparc_reloc_map): Likewise.
3276 2003-01-24 Martin Schwidefsky <schwidefsky@de.ibm.com>
3278 * bfd-in2.h: Regenerate.
3279 * elf32-s390.c (elf_s390_mkobject, elf_s390_tls_transition,
3280 s390_tls_reloc, dtpoff_base, tpoff, invalid_tls_insn): New functions.
3281 (elf_howto_table): Add TLS relocs.
3282 (elf_s390_reloc_type_lookup): Likewise.
3283 (elf_s390_link_hash_entry): Add tls_type.
3284 (elf_s390_hash_entry, elf_s390_obj_tdata, elf_s390_local_got_tls_type):
3286 (elf_s390_link_hash_table): Add tls_ldm_got.
3287 (link_hash_newfunc): Initialize tls_type.
3288 (elf_s390_link_hash_table_create): Initialize refcount of tls_ldm_got.
3289 (elf_s390_copy_indirect_symbol): Copy tls_type information.
3290 (elf_s390_check_relocs): Support TLS relocs.
3291 (elf_s390_gc_sweep_hook): Likewise.
3292 (allocate_dynrelocs): Likewise.
3293 (elf_s390_size_dynamic_sections): Likewise.
3294 (elf_s390_relocate_section): Likewise.
3295 (elf_s390_finish_dynamic_symbol): Likewise.
3296 (bfd_elf32_mkobject): Define for TLS.
3297 * elf64-s390.c: Same changes as for elf32-s390.c.
3298 * libbfd.h: Regenerate.
3299 * reloc.c: Add s390 TLS relocations.
3301 2003-01-24 Charles Lepple <clepple@ghz.cc>
3303 * aclocal.m4: Fix name of --enable-install-libbfd switch.
3305 2003-01-23 Nick Clifton <nickc@redhat.com>
3308 2002-04-02 Elena Zannoni <ezannoni@redhat.com>
3309 * archures.c (bfd_mach_sh2e): Added.
3310 * bfd-in2.h: Rebuilt.
3311 * cpu-sh.c (arch_info_struct): Added SH2e.
3312 * elf32-sh.c (sh_elf_set_mach_from_flags): Handle EF_SH2E.
3314 2003-01-23 Alan Modra <amodra@bigpond.net.au>
3316 * elf-bfd.h (struct bfd_elf_section_data): Remove tdata. Change
3317 dynindx to an int. Rearrange for better packing.
3318 * elf.c (_bfd_elf_new_section_hook): Don't alloc if already done.
3319 * elf32-mips.c (bfd_elf32_new_section_hook): Define.
3320 * elf32-sh64.h: New. Split out from include/elf/sh.h.
3321 (struct _sh64_elf_section_data): New struct.
3322 (sh64_elf_section_data): Don't dereference sh64_info (was tdata).
3323 * elf32-sh64-com.c: Include elf32-sh64.h.
3324 * elf32-sh64.c: Likewise.
3325 (sh64_elf_new_section_hook): New function.
3326 (bfd_elf32_new_section_hook): Define.
3327 (sh64_elf_fake_sections): Adjust for sh64_elf_section_data change.
3328 (sh64_bfd_elf_copy_private_section_data): Likewise.
3329 (sh64_elf_final_write_processing): Likewise.
3330 * elf32-sparc.c (struct elf32_sparc_section_data): New.
3331 (elf32_sparc_new_section_hook): New function.
3332 (SET_SEC_DO_RELAX, SEC_DO_RELAX): Delete.
3333 (sec_do_relax): Define.
3334 (elf32_sparc_relax_section): Adjust to use sec_do_relax.
3335 (elf32_sparc_relocate_section): Likewise.
3336 * elf64-mips.c (bfd_elf64_new_section_hook): Define.
3337 * elf64-mmix.c (struct _mmix_elf_section_data): New.
3338 (mmix_elf_section_data): Define. Use throughout file.
3339 (mmix_elf_new_section_hook): New function.
3340 (bfd_elf64_new_section_hook): Define.
3341 * elf64-ppc.c (struct _ppc64_elf_section_data): New.
3342 (ppc64_elf_section_data): Define. Use throughout.
3343 (ppc64_elf_new_section_hook): New function.
3344 (bfd_elf64_new_section_hook): Define.
3345 * elf64-sparc.c (struct sparc64_elf_section_data): New.
3346 (sparc64_elf_new_section_hook): New function.
3347 (SET_SEC_DO_RELAX, SEC_DO_RELAX): Delete.
3348 (sec_do_relax): Define.
3349 (sparc64_elf_relax_section): Adjust to use sec_do_relax.
3350 (sparc64_elf_relocate_section): Likewise.
3351 (bfd_elf64_new_section_hook): Define.
3352 * elfn32-mips.c (bfd_elf32_new_section_hook): Define.
3353 * elfxx-mips.c (struct _mips_elf_section_data): New.
3354 (mips_elf_section_data): Define. Use throughout.
3355 (_bfd_mips_elf_new_section_hook): New function.
3356 (mips_elf_create_got_section): Don't alloc used_by_bfd.
3357 * elfxx-mips.h (_bfd_mips_elf_new_section_hook): Declare.
3358 * elfxx-target.h (bfd_elfNN_new_section_hook): Add #ifndef.
3359 * Makefile.am: Run "make dep-am".
3360 * Makefile.in: Regenerate.
3362 2003-01-21 Richard Henderson <rth@redhat.com>
3364 * elf64-alpha.c (ALPHA_ELF_LINK_HASH_PLT_LOC): New.
3365 (struct alpha_elf_link_hash_entry): Add plt_old_section, plt_old_value.
3366 (elf64_alpha_adjust_dynamic_symbol): Set them.
3367 (elf64_alpha_size_plt_section_1): Reset them when plt entry removed.
3368 (elf64_alpha_relax_tls_get_addr): Handle LDM relocs. Frob the
3369 symbol index when relaxing LDM to TPREL.
3370 (elf64_alpha_relax_section): Likewise. Allow relaxation of GD
3371 relocs, even if the target isn't locally defined.
3372 (elf64_alpha_check_relocs): Frob LDM reloc symndx to zero.
3373 (elf64_alpha_relocate_section): Likewise. Force TP-relative
3374 relocs vs symndx 0 to the tp base.
3376 2003-01-21 Fabio Alemagna <falemagn@aros.org>
3378 * config.bfd: Handle i[3456]86-*-aros*.
3380 2003-01-21 Andreas Schwab <schwab@suse.de>
3382 * elf32-ppc.c (struct ppc_elf_dyn_relocs): Define.
3383 (struct ppc_elf_link_hash_entry): Define.
3384 (ppc_elf_hash_entry): New function.
3385 (struct ppc_elf_link_hash_table): Define.
3386 (ppc_elf_hash_table): New function.
3387 (ppc_elf_link_hash_newfunc): New function.
3388 (ppc_elf_link_hash_table_create): New function.
3389 (ppc_elf_copy_indirect_symbol): New function.
3390 (allocate_dynrelocs): New function.
3391 (readonly_dynrelocs): New function.
3392 (ppc_elf_size_dynamic_sections): Allocate space for dynamic
3393 relocs and determine DT_TEXTREL.
3394 (ppc_elf_check_relocs): Don't do that here, just count the
3396 (ppc_elf_gc_sweep_hook): Discard any dynamic relocs against the
3398 (bfd_elf32_bfd_link_hash_table_create): Define.
3399 (elf_backend_copy_indirect_symbol): Define.
3401 2003-01-21 Richard Henderson <rth@redhat.com>
3403 * elf64-alpha.c (alpha_dynamic_entries_for_reloc): GOTTPREL and
3404 TPREL also get a reloc if shared. Remove SREL support.
3405 (elf64_alpha_emit_dynrel): New.
3406 (elf64_alpha_relocate_section): Use it. Resolve dynamic TPREL
3407 and GOTTPREL relocs to local symbols against the tp base.
3408 (elf64_alpha_finish_dynamic_symbol): Use elf64_alpha_emit_dynrel.
3410 * elf64-alpha.c (elf64_alpha_relax_got_load): Decrement got
3411 use count before clobbering r_type.
3412 (elf64_alpha_relax_tls_get_addr): Don't use pos[1] if insn
3413 ordering would mean dataflow inspection is necessary.
3415 2003-01-20 Svein E. Seldal <Svein.Seldal@solidas.com>
3417 * coffcode.h (coff_set_flags): Added get/set arch hooks.
3419 2003-01-20 Fabio Alemagna <falemagn@aros.org>
3421 * elf32-sh.c: Treat elfNN_bed like other macros defined in
3422 elfxx-target.h and #undef it before #define'ing it.
3423 * elf32-i386.c: Likewise.
3424 * elf32-sh64.c: Likewise.
3425 * elf64-alpha.c: Likewise.
3426 * elf64-sh64.c: Likewise.
3428 2003-01-20 Martin Schwidefsky <schwidefsky@de.ibm.com>
3430 * bfd-in2.h: Regenerate.
3431 * elf32-s390.c (elf_s390_adjust_gotplt): New prototype.
3432 (elf_howto_table): Rename R_390_GOTOFF to R_390_GOTOFF32. Add
3433 R_390_GOTOFF16, R_390_GOTOFF64, R_390_GOTPLT12, R_390_GOTPLT16,
3434 R_390_GOTPLT32, R_390_GOTPLT64, R_390_GOTPLTENT, R_390_PLTOFF16,
3435 R_390_PLTOFF32 and R_390_PLTOFF64.
3436 (elf_s390_reloc_type_lookup): Likewise.
3437 (struct elf_s390_link_hash_entry): Add gotplt_refcount to keep track
3438 of GOTPLT references to a function.
3439 (link_hash_newfunc): Initialize gotplt_refcount.
3440 (elf_s390_check_relocs): Move allocation of local_got_refcounts array
3441 and creation of the got section out of the main switch. Add support
3442 for the gotoff, gotplt and pltoff relocations.
3443 (elf_s390_gc_sweep_hook): Add reference counting for gotoff, gotplt
3445 (elf_s390_adjust_gotplt): New function.
3446 (elf_s390_adjust_dynamic_symbol): Adjust gotplt refcount for removed
3448 (allocate_dynrelocs): Add comment.
3449 (elf_s390_relocate_section): Change r_type to unsigned. Add support
3450 for gotoff, gotplt and pltoff relocations.
3451 * elf64-s390.c: Same changes as for elf32-s390.c.
3452 * libbfd.h: Regenerate.
3453 * reloc.c: Add BFD_RELOC_390_GOTOFF64, BFD_RELOC_390_GOTPLT12,
3454 BFD_RELOC_390_GOTPLT16, BFD_RELOC_390_GOTPLT32, BFD_RELOC_390_GOTPLT64,
3455 BFD_RELOC_390_GOTPLTENT, BFD_RELOC_390_PLTOFF16, BFD_RELOC_390_PLTOFF32
3456 and BFD_RELOC_390_PLTOFF64.
3458 2003-01-18 Jakub Jelinek <jakub@redhat.com>
3460 * elfxx-ia64.c (elfNN_ia64_relocate_section): Handle
3461 R_IA64_TPREL64[LM]SB against non-global symbol properly.
3463 2003-01-16 Jakub Jelinek <jakub@redhat.com>
3465 * elfxx-ia64.c (struct elfNN_ia64_link_hash_table): Add
3466 self_dtpmod_done and self_dtpmod_offset.
3467 (allocate_global_data_got): Only use one got entry for all
3468 dtpmod relocs against local symbols.
3469 (allocate_dynrel_entries): Only need .rela.got entry for
3470 dtpmod against global symbol.
3471 (elfNN_ia64_size_dynamic_sections): Initialize self_dtpmod_offset.
3472 Reserve space in .rela.got for the local dtpmod entry.
3473 (set_got_entry): Initialize the common local dtpmod .got entry.
3474 (elfNN_ia64_relocate_section): Handle R_IA_64_DTPREL64LSB
3475 and R_IA_64_DTPREL64MSB.
3477 2003-01-16 Alan Modra <amodra@bigpond.net.au>
3479 * elf64-ppc.c: Include elf/ppc64.h rather than elf/ppc.h.
3480 (R_PPC_*): Rename all occurrences to R_PPC64_*.
3481 (R_PPC64_ADDR30): Rename all occurrences to R_PPC64_REL30.
3482 (enum elf_ppc_reloc_type): Ditto to enum elf_ppc64_reloc_type.
3483 (ppc64_elf_gc_sweep_hook): Handle R_PPC64_REL30 along with other
3484 relative relocs, not with absolute ones.
3485 * Makefile.am: Run "make dep-am".
3486 * Makefile.in: Regenerate.
3487 * po/SRC-POTFILES.in: Regenerate.
3489 2003-01-15 Andreas Schwab <schwab@suse.de>
3491 * elf32-ppc.c (ppc_elf_check_relocs): Don't set DF_TEXTREL for a
3492 relocation against a non-allocated readonly section.
3494 2003-01-10 Alan Modra <amodra@bigpond.net.au>
3496 * elf32-ppc.c (ppc_elf_relocate_section): Adjust addend for GOT16_HA.
3497 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise. PLTGOT16_HA too.
3499 2002-01-08 Klee Dienes <kdienes@apple.com>
3501 * Makefile.am (ALL_MACHINES): Use cpu-msp430.lo, not cpu-msp430.c.
3502 (BFD32_BACKENDS): Use elf32-msp430.lo, not elf32-msp430.c.
3503 * Makefile.in: Regenerate.
3505 2003-01-08 Alexandre Oliva <aoliva@redhat.com>
3507 * elfn32-mips.c (prev_reloc_section): New.
3508 (GET_RELOC_ADDEND): Use it. Parenthesize macro arguments.
3509 (SET_RELOC_ADDEND): Parenthesize macro argument.
3511 2003-01-07 John David Anglin <dave.anglin@nrc.gc.ca>
3513 * elf32-hppa.c (final_link_relocate): For all DP relative relocations,
3514 adjust addil instructions if the symbol has no section.
3516 2003-01-07 DJ Delorie <dj@redhat.com>
3518 * elf32-xstormy16.c (xstormy16_elf_howto_table): Make REL_12 not
3521 2003-01-07 Andreas Schwab <schwab@suse.de>
3523 * elf32-m68k.c (elf_m68k_check_relocs): Don't set DF_TEXTREL for
3524 PC relative relocations.
3525 (elf_m68k_discard_copies): Set it here instead.
3527 2002-01-02 Ben Elliston <bje@redhat.com>
3528 Jeff Johnston <jjohnstn@redhat.com>
3530 * Makefile.am (ALL_MACHINES): Add cpu-iq2000.lo.
3531 (ALL_MACHINES_CFILES): Add cpu-iq2000.c.
3532 (BFD32_BACKENDS): Add elf32-iq2000.lo.
3533 (BFD32_BACKENDS_CFILES): Add elf32-iq2000.c.
3534 (cpu-iq2000.lo): New target.
3535 * Makefile.in: Regenerate.
3536 * config.bfd: Handle iq2000-*-elf.
3537 * archures.c (bfd_architecture): Add bfd_{arch,mach}_iq2000.
3538 (bfd_archures_list): Add bfd_iq2000_arch.
3539 * configure.in: Handle bfd_elf32_iq2000_vec.
3540 * configure: Regenerate.
3541 * reloc.c: Add BFD_RELOC_IQ2000_OFFSET_16, BFD_RELOC_IQ2000_OFFSET_21,
3542 and BFD_RELOC_IQ2000_UHI16.
3543 * targets.c (bfd_elf32_iq2000_vec): Declare.
3544 (bfd_target_vector): Add bfd_elf32_iq2000_vec.
3545 * elf.c (prep_headers): Set e_machine to EM_IQ2000.
3546 * cpu-iq2000.c: New file.
3547 * elf32-iq2000.c: Likewise.
3548 * libbfd.h: Regenerate.
3549 * bfd-in2.h: Likewise.
3551 2003-01-02 Richard Sandiford <rsandifo@redhat.com>
3553 * elfxx-mips.c: Include libiberty.h.
3554 (elf_mips_isa, _bfd_mips_elf_mach_extends_p): Remove.
3555 (mips_set_isa_flags): New function, split out from...
3556 (_bfd_mips_elf_final_write_processing): ...here. Only call
3557 mips_set_isa_flags if the EF_MIPS_MACH bits are clear.
3558 (mips_mach_extensions): New array.
3559 (mips_32bit_flags_p): New function.
3560 (_bfd_mips_elf_merge_private_bfd_data): Rework architecture checks.
3561 Use mips_32bit_flags_p to check if one binary is 32-bit and the
3562 other is 64-bit. When adopting IBFD's architecture, adopt the
3563 bfd_mach as well as the flags.
3565 2003-01-02 Nick Kelsey <nickk@ubicom.com>
3567 * elf32-ip2k.c: Re-work of linker relaxation code for the ip2k to
3568 fix internal errors, fix bad code generation, fix incorrect stabs
3569 information, and improve ability to eliminate redundant page
3570 instructions. Added code to ip2k_final_link_relocate to self-verify
3571 the linker relaxation. Fix formatting problems.
3573 2002-12-30 Chris Demetriou <cgd@broadcom.com>
3575 * aoutx.h (NAME(aout,machine_type)): Add bfd_mach_mipsisa32r2 case.
3576 * archures.c (bfd_mach_mipsisa32r2): New define.
3577 * bfd-in2.h: Regenerate.
3578 * cpu-mips.c (I_mipsisa32r2): New enum value.
3579 (arch_info_struct): Add entry for I_mipsisa32r2.
3580 * elfxx-mips.c (elf_mips_isa, _bfd_elf_mips_mach)
3581 (_bfd_mips_elf_print_private_bfd_data): Handle E_MIPS_ARCH_32R2.
3582 (_bfd_mips_elf_final_write_processing): Add
3583 bfd_mach_mipsisa32r2 case.
3584 (_bfd_mips_elf_merge_private_bfd_data): Handle merging of
3585 binaries marked as using MIPS32 Release 2.
3587 2002-12-30 Dmitry Diky <diwil@mail.ru>
3589 * Makefile.am: Add msp430 target.
3590 * configure.in: Likewise.
3591 * Makefile.in: Regenerate.
3592 * configure: Regenerate.
3593 * archures.c: Add msp430 architecture vector.
3594 * config.bfd: Likewise.
3595 * reloc.c: Add msp430 relocs.
3596 * targets.c: Add msp320 target.
3597 * cpu-msp430.c: New file: msp430 cpu detection.
3598 * elf32-msp430.c: New file: msp430 reloc processing.
3599 * bfd-in2.h: Regenerate.
3600 * libbfd.h: Regenerate.
3602 2002-12-28 Jakub Jelinek <jakub@redhat.com>
3604 * elf.c (elf_sort_sections): Don't reorder .tbss.
3605 (assign_file_positions_for_segments): Only adjust off/voff
3606 for increased alignment in PT_LOAD or PT_NOTE segment,
3607 but adjust p_filesz for .tbss too. in PT_LOAD consider
3608 .tbss to have zero memory size.
3609 (copy_private_bfd_data) [SECTION_SIZE]: Define.
3610 [IS_CONTAINED_BY_VMA, IS_CONTAINED_BY_LMA]: Use it.
3611 [INCLUDE_SECTION_IN_SEGMENT]: Only put SHF_TLS sections
3612 into PT_TLS segment. Never put SHF_TLS sections in
3613 segments other than PT_TLS or PT_LOAD.
3615 * elf64-alpha.c (elf64_alpha_finish_dynamic_sections): Clear .plt
3618 2002-12-23 DJ Delorie <dj@redhat.com>
3620 * coff64-rs6000.c (xcoff64_ppc_relocate_section): Fix logic reversal.
3622 2002-12-23 Alan Modra <amodra@bigpond.net.au>
3624 * elflink.h (elf_link_output_extsym): Heed strip_discarded.
3626 2002-12-23 Nick Clifton <nickc@redhat.com>
3628 * archures.c (bfd_arch_get_compatible): Add third parameter
3629 'accept_unknowns'. Only accept unknown format BFDs if
3630 accept_unknowns is true, or if the format is "binary".
3631 * bfd-in2.h: Regenerate.
3633 2002-12-21 Nick Clifton <nickc@redhat.com>
3635 * coff-arm.c (coff_arm_relocate_section): Disable WINCE workaround
3636 that subtracted 8 from pc relative relocations.
3638 2002-12-20 Kazu Hirata <kazu@cs.umass.edu>
3640 * coff-h8300.c: Fix comment typos.
3641 * coffcode.h: Likewise.
3642 * cpu-cris.c: Likewise.
3643 * elf32-vax.c: Likewise.
3644 * genlink.h: Likewise.
3645 * linker.c: Likewise.
3647 * tekhex.c: Likewise.
3648 * vms-misc.c: Likewise.
3650 2002-12-20 DJ Delorie <dj@redhat.com>
3652 * reloc.c: Add BFD_RELOC_XSTORMY16_12.
3653 * libbfd.h: Regenerate.
3654 * bfd-in2.h: Regenerate.
3655 * elf32-xstormy16.c (xstormy16_elf_howto): Add R_XSTORMY16_12.
3656 (xstormy16_reloc_map): Add R_XSTORMY16_12.
3658 2002-12-19 Kazu Hirata <kazu@cs.umass.edu>
3660 * doc/bfdint.texi: Fix typos.
3662 2002-12-20 Paul Eggert <eggert@twinsun.com>
3664 Port to POSIX 1003.1-2001.
3665 * acinclude.m4 (AM_INSTALL_LIBBFD): Do not rely on "test -o".
3666 * configure.in (build-warnings): Likewise.
3667 (Horrible hacks to build DLLs on Windows): Do not rely on "tail -1".
3668 * aclocal.m4: Regenerate.
3669 * config.in: Regenerate.
3670 * configure: Regenerate.
3672 2002-12-19 Alan Modra <amodra@bigpond.net.au>
3674 * coff-h8300.c: Include libiberty.h.
3675 (h8300_reloc16_extra_cases): Check the hash table creator before
3676 referencing h8300 specific fields. Stash the hash table pointer
3677 in a local var. Comment typo fixes.
3678 (h8300_bfd_link_add_symbols): Likewise.
3680 * reloc.c (struct reloc_howto_struct): Revise src_mask and
3682 * bfd-in2.h: Regenerate.
3684 2002-12-18 Alan Modra <amodra@bigpond.net.au>
3686 * elf32-ppc.c (ppc_elf_relocate_section): Reorganize dynamic reloc
3687 code a little. Comment on dynamic relocs against section symbols.
3689 2002-12-17 Roger Sayle <roger@eyesopen.com>
3691 * configure.host (ia64-*-hpux*): Support 64 bit targets using
3692 the HP compiler's "long long".
3694 2002-12-16 Andrew MacLeod <amacleod@redhat.com>
3696 * elf32-xstormy16.c (xstormy16_elf_howto): Add R_XSTORMY16_LO16
3697 and R_XSTORMY16_HI16) howto entries.
3698 (xstormy16_reloc_map): Map R_XSTORMY16_{LO,HI}16 to BFD_RELOC_{LO,HI}16.
3699 (xstormy16_info_to_howto_rela): Use R_XSTORMY16_GNU_VTINHERIT to
3700 determine the start of the second reloc table.
3702 2002-12-16 Nathan Tallent <eraxxon@alumni.rice.edu>
3704 * ecofflink.c: Fix the reading of the debugging information
3705 of Tru64/Alpha binaries that are produced by recent Compaq
3707 (mk_fdrtab): Fix error in creating the FDR (file descriptor)
3709 (lookup_line): Because of the strange information sometimes
3710 generated by Compaq's recent compilers, change how the FDR
3711 table is searched so that PDRs (procedure descriptors) are
3712 correctly found. Note that this change is really more of a hack;
3713 however, I have included extensive documentation as to why
3714 this is the best solution short of an extensive rewrite or
3716 (fdrtab_lookup): Add comments to explain the algorithm.
3718 2002-12-12 Alexandre Oliva <aoliva@redhat.com>
3720 * elf-m10300.c (elf32_mn10300_link_hash_newfunc): Reorder
3721 initializers to match struct declaration.
3723 2002-12-12 Alan Modra <amodra@bigpond.net.au>
3725 * dwarf2.c (comp_unit_contains_address): Comment typo fix.
3726 * elf.c (get_program_header_size): Likewise.
3727 * elf32-m32r.c (m32r_elf_lo16_reloc): Likewise.
3728 (m32r_elf_generic_reloc): Likewise.
3729 * elf32-ppc.c (ppc_elf_howto_init): Likewise.
3730 * elflink.h (elf_bfd_discard_info): Likewise.
3732 2002-12-12 Alan Modra <amodra@bigpond.net.au>
3734 * elf32-i386.c (elf_i386_finish_dynamic_sections): Add output_offset
3735 to DT_JMPREL. Use srelplt input section size for DT_PLTRELSZ and
3736 DT_RELSZ adjustment, not output section. Avoid writing tags when
3737 unchanged. Don't assume linker script is sane, adjust DT_REL too.
3738 * elf32-hppa.c (elf32_hppa_finish_dynamic_sections): Just use raw
3739 size of srelplt for DT_PLTRELSZ. Use srelplt input section size for
3740 DT_RELASZ adjustment, not output section. Avoid writing tags when
3741 unchanged. Adjust DT_RELA.
3742 * elf64-ppc.c (ppc64_elf_finish_dynamic_sections): Tweaks for better
3743 formatting. Avoid writing tags when unchanged. Adjust DT_RELA.
3745 2002-12-12 Alexandre Oliva <aoliva@redhat.com>
3747 * elfxx-mips.c (mips_elf_calculate_relocation): Don't divide
3750 2002-12-12 Alexandre Oliva <aoliva@redhat.com>
3752 * elfxx-mips.c (struct mips_got_entry): New.
3753 (struct mips_got_info): Added got_entries field.
3754 (mips_elf_got_entry_hash, mips_elf_got_entry_eq): New functions.
3755 (mips_elf_local_got_index, mips_elf_got_page,
3756 mips_elf_got16_entry): Re-implement in terms of new...
3757 (mips_elf_create_local_got_entry): Rewrite to use got_entries.
3759 (mips_elf_highest): Warning clean-up.
3760 (mips_elf_create_got_section): Initialize got_entries.
3761 (_bfd_mips_elf_check_relocs): Use got_entries to estimate
3763 (_bfd_mips_elf_size_dynamic_sections): Do not account for
3764 GOT_PAGE entries, since we now reuse GOT16 entries.
3766 2002-12-10 Jason Thorpe <thorpej@wasabisystems.com>
3768 * aoutx.h (set_section_contents): Allow an otherwise unrepresentable
3769 read-only section that lies after .text and before .data to be
3770 written into the output file and included in a_text.
3771 (translate_to_native_sym_flags): If an otherwise unrepresentable
3772 section was merged with .text, convert its symbols to N_TEXT
3774 * libaout.h (aout_section_merge_with_text_p): New macro.
3776 2002-12-08 Alan Modra <amodra@bigpond.net.au>
3778 * bfd-in.h: Comment typo fix. Formatting.
3779 * bfd-in2.h: Regenerate.
3780 * coff64-rs6000.c (xcoff64_openr_next_archived_file): Warning fix.
3781 * elf32-m68hc12.c (m68hc12_elf_set_mach_from_flags): Prototype.
3782 * elf64-mmix.c (mmix_dump_bpo_gregs): Warning fix.
3784 2002-12-05 Richard Henderson <rth@redhat.com>
3786 * elfxx-ia64.c (elfNN_ia64_relax_section): Handle PCREL21BI.
3787 Only send PCREL21B though the plt. Fix installed reloc type.
3788 (elfNN_ia64_relocate_section): Give error for dynamic reloc
3789 against PCREL22 or PCREL64I; clean up error messages for
3792 2002-12-04 Kevin Buettner <kevinb@redhat.com>
3794 * elf64-mips.c (elf64_mips_grok_prstatus, elf64_mips_grok_psinfo):
3796 (elf_backend_grok_prstatus, elf_backend_grok_psinfo): Define.
3798 2002-12-04 David Mosberger <davidm@hpl.hp.com>
3800 * cpu-ia64-opc.c: Add operand constant "ar.csd".
3802 2002-12-04 H.J. Lu <hjl@gnu.org>
3804 * elfxx-ia64.c (get_local_sym_hash): Use section ID instead of
3805 BFD address when constructing local name.
3807 2002-12-04 Andreas Schwab <schwab@suse.de>
3809 * elf32-m68k.c (struct elf_m68k_link_hash_table): Add sym_sec
3811 (elf_m68k_link_hash_table_create): Initialize it.
3812 (elf_m68k_check_relocs): Handle symbols that are forced to be
3813 local due to visibility changes.
3814 (elf_m68k_adjust_dynamic_symbol): Likewise.
3815 (elf_m68k_size_dynamic_sections): Likewise.
3816 (elf_m68k_discard_copies): Likewise.
3817 (elf_m68k_relocate_section): Likewise.
3819 2002-12-04 Alan Modra <amodra@bigpond.net.au>
3821 * elf64-ppc.c (ppc64_elf_edit_opd): Correct typo.
3823 2002-12-04 Alan Modra <amodra@bigpond.net.au>
3825 * srec.c (srec_write_symbols): Restore '$' prefix to address
3826 accidentally removed in 2002-04-04 change.
3827 (srec_get_symtab): Use 0 instead of `(long) FALSE'.
3829 2002-12-03 Nick Clifton <nickc@redhat.com>
3831 * elf32-ppc.c (apuinfo_list_init): New function.
3832 (apuinfo_list_add): New function: Add a value to the list.
3833 (apuinfo_list_length): New function: Return the number of
3835 (apuinfo_list_element): New function: Return a value on the
3837 (apuinfo_list_finish): New function: Free the resources used
3839 (ppc_elf_begin_write_processing): New function. Scan the
3840 input bfds for apuinfo sections.
3841 (ppc_elf_write_section): New function: Delay the creation of
3842 the contents of an apuinfo section in an output bfd.
3843 (ppc_elf_final_write_processing): New function. Create the
3844 contents of an apuinfo section in an output bfd.
3845 (elf_backend_begin_write_processing): Define.
3846 (elf_backend_final_write_processing): Define.
3847 (elf_backend_write_section): Define.
3849 2002-12-03 Richard Henderson <rth@redhat.com>
3851 * cpu-ia64-opc.c (elf64_ia64_operands): Add ldxmov entry.
3853 2002-12-01 Stephane Carrez <stcarrez@nerim.fr>
3855 Fix PR savannah/1417:
3856 * elf32-m68hc11.c (m68hc11_elf_relax_delete_bytes): Don't adjust
3857 branch if it goes to the start of the deleted region.
3859 2002-12-01 Stephane Carrez <stcarrez@nerim.fr>
3861 * bfd-in2.h (bfd_mach_m6812): Rebuild.
3862 * archures.c (bfd_mach_m6812_default, bfd_mach_m6812,
3863 bfd_mach_m6812s): Declare.
3865 * elf32-m68hc12.c (m68hc12_elf_set_mach_from_flags): New function.
3866 (_bfd_m68hc12_elf_set_private_flags): Call it.
3867 (_bfd_m68hc12_elf_print_private_bfd_data): Report processor version.
3868 (_bfd_m68hc12_elf_merge_private_bfd_data): Merge the flags and
3869 report microcontroller incompatibilities (HC12 vs HCS12).
3870 (elf_backend_object_p): Update.
3872 2002-11-30 Alan Modra <amodra@bigpond.net.au>
3874 * bfd-in.h (TRUE_FALSE_ALREADY_DEFINED, BFD_TRUE_FALSE): Delete.
3875 (enum bfd_boolean, boolean): Delete.
3876 (bfd_boolean): Typedef to an int.
3877 (FALSE, TRUE): Define.
3878 * aix386-core.c, aix5ppc-core.c, aout-adobe.c, aout-arm.c, aout-cris.c,
3879 aout-encap.c, aout-ns32k.c, aout-target.h, aout-tic30.c, aoutf1.h,
3880 aoutx.h, archive.c, archive64.c, archures.c, bfd-in.h, bfd.c, bfdwin.c,
3881 binary.c, bout.c, cache.c, cisco-core.c, coff-a29k.c, coff-alpha.c,
3882 coff-apollo.c, coff-arm.c, coff-aux.c, coff-h8300.c, coff-h8500.c,
3883 coff-i386.c, coff-i860.c, coff-i960.c, coff-ia64.c, coff-m68k.c,
3884 coff-m88k.c, coff-mcore.c, coff-mips.c, coff-or32.c, coff-ppc.c,
3885 coff-rs6000.c, coff-sh.c, coff-sparc.c, coff-stgo32.c, coff-tic30.c,
3886 coff-tic4x.c, coff-tic54x.c, coff-tic80.c, coff-w65.c, coff-we32k.c,
3887 coff-z8k.c, coff64-rs6000.c, coffcode.h, coffgen.c, cofflink.c,
3888 corefile.c, cpu-a29k.c, cpu-alpha.c, cpu-arc.c, cpu-arm.c, cpu-avr.c,
3889 cpu-cris.c, cpu-d10v.c, cpu-d30v.c, cpu-dlx.c, cpu-fr30.c, cpu-frv.c,
3890 cpu-h8300.c, cpu-h8500.c, cpu-hppa.c, cpu-i370.c, cpu-i386.c,
3891 cpu-i860.c, cpu-i960.c, cpu-ia64.c, cpu-ip2k.c, cpu-m10200.c,
3892 cpu-m10300.c, cpu-m32r.c, cpu-m68hc11.c, cpu-m68hc12.c, cpu-m68k.c,
3893 cpu-m88k.c, cpu-mcore.c, cpu-mips.c, cpu-mmix.c, cpu-ns32k.c,
3894 cpu-openrisc.c, cpu-or32.c, cpu-pdp11.c, cpu-pj.c, cpu-powerpc.c,
3895 cpu-rs6000.c, cpu-s390.c, cpu-sh.c, cpu-sparc.c, cpu-tic30.c,
3896 cpu-tic4x.c, cpu-tic54x.c, cpu-tic80.c, cpu-v850.c, cpu-vax.c,
3897 cpu-w65.c, cpu-we32k.c, cpu-xstormy16.c, cpu-z8k.c, dwarf1.c,
3898 dwarf2.c, ecoff.c, ecofflink.c, efi-app-ia32.c, efi-app-ia64.c,
3899 elf-bfd.h, elf-eh-frame.c, elf-hppa.h, elf-m10200.c, elf-m10300.c,
3900 elf-strtab.c, elf.c, elf32-arc.c, elf32-arm.h, elf32-avr.c,
3901 elf32-cris.c, elf32-d10v.c, elf32-d30v.c, elf32-dlx.c, elf32-fr30.c,
3902 elf32-frv.c, elf32-gen.c, elf32-h8300.c, elf32-hppa.c, elf32-hppa.h,
3903 elf32-i370.c, elf32-i386.c, elf32-i860.c, elf32-i960.c, elf32-ip2k.c,
3904 elf32-m32r.c, elf32-m68hc11.c, elf32-m68hc12.c, elf32-m68k.c,
3905 elf32-mcore.c, elf32-mips.c, elf32-openrisc.c, elf32-or32.c,
3906 elf32-pj.c, elf32-ppc.c, elf32-s390.c, elf32-sh.c, elf32-sh64-com.c,
3907 elf32-sh64.c, elf32-sparc.c, elf32-v850.c, elf32-vax.c,
3908 elf32-xstormy16.c, elf64-alpha.c, elf64-gen.c, elf64-hppa.c,
3909 elf64-mips.c, elf64-mmix.c, elf64-ppc.c, elf64-ppc.h, elf64-s390.c,
3910 elf64-sh64.c, elf64-sparc.c, elf64-x86-64.c, elfarm-nabi.c,
3911 elfarm-oabi.c, elfcode.h, elfcore.h, elflink.c, elflink.h,
3912 elfn32-mips.c, elfxx-ia64.c, elfxx-mips.c, elfxx-mips.h,
3913 elfxx-target.h, format.c, freebsd.h, genlink.h, hash.c, hp300hpux.c,
3914 hppabsd-core.c, hpux-core.c, i386aout.c, i386linux.c, i386lynx.c,
3915 i386mach3.c, i386msdos.c, i386os9k.c, ieee.c, ihex.c, irix-core.c,
3916 libaout.h, libbfd-in.h, libbfd.c, libcoff-in.h, libecoff.h, libieee.h,
3917 libnlm.h, liboasys.h, libpei.h, libxcoff.h, linker.c, lynx-core.c,
3918 m68klinux.c, m68klynx.c, mach-o.c, mach-o.h, merge.c, mipsbsd.c,
3919 mmo.c, netbsd-core.c, netbsd.h, nlm.c, nlm32-alpha.c, nlm32-i386.c,
3920 nlm32-ppc.c, nlm32-sparc.c, nlmcode.h, oasys.c, opncls.c, osf-core.c,
3921 pc532-mach.c, pdp11.c, pe-arm.c, pe-i386.c, pe-mcore.c, pe-mips.c,
3922 pe-sh.c, peXXigen.c, pef.c, pei-arm.c, pei-i386.c, pei-mcore.c,
3923 pei-mips.c, pei-sh.c, peicode.h, ppcboot.c, ptrace-core.c, reloc.c,
3924 reloc16.c, riscix.c, rs6000-core.c, sco5-core.c, section.c, simple.c,
3925 som.c, som.h, sparclinux.c, sparclynx.c, srec.c, stabs.c, sunos.c,
3926 syms.c, targets.c, tekhex.c, ticoff.h, trad-core.c, versados.c,
3927 vms-gsd.c, vms-hdr.c, vms-misc.c, vms-tir.c, vms.c, vms.h,
3928 xcoff-target.h, xcofflink.c, xsym.c, xsym.h: Replace boolean with
3929 bfd_boolean, true with TRUE, false with FALSE. Simplify comparisons
3930 of bfd_boolean vars with TRUE/FALSE. Formatting.
3931 * bfd-in2.h, libbfd.h, libcoff.h: Regenerate
3933 2002-11-28 Alan Modra <amodra@bigpond.net.au>
3935 * elf-bfd.h: Replace occurrences of Elf32_Internal_* and
3936 Elf64_Internal_* with Elf_Internal_*. Replace Elf_Internal_Rel
3937 with Elf_Internal_Rela.
3938 * elf-hppa.h, elf-m10200.c, elf-m10300.c, elf32-arc.c, elf32-arm.h,
3939 elf32-avr.c, elf32-cris.c, elf32-d10v.c, elf32-d30v.c, elf32-dlx.c,
3940 elf32-fr30.c, elf32-frv.c, elf32-gen.c, elf32-h8300.c, elf32-hppa.c,
3941 elf32-i370.c, elf32-i386.c, elf32-i860.c, elf32-i960.c, elf32-ip2k.c,
3942 elf32-m32r.c, elf32-m68hc11.c, elf32-m68hc12.c, elf32-m68k.c,
3943 elf32-mcore.c, elf32-mips.c, elf32-openrisc.c, elf32-or32.c,
3944 elf32-ppc.c, elf32-s390.c, elf32-sh.c, elf32-v850.c, elf32-vax.c,
3945 elf32-xstormy16.c, elf64-alpha.c, elf64-gen.c, elf64-hppa.c,
3946 elf64-mips.c, elf64-mmix.c, elf64-ppc.c, elf64-s390.c, elf64-sh64.c,
3947 elf64-sparc.c, elf64-x86-64.c, elfarm-nabi.c, elfarm-oabi.c,
3948 elfcode.h, elflink.h, elfn32-mips.c, elfxx-ia64.c, elfxx-mips.c: Ditto.
3949 * elf-hppa.h (elf_hppa_internal_shdr): Delete. Use Elf_Internal_Shdr
3951 * elf.c (_bfd_elf_no_info_to_howto_rel): Delete.
3952 * elfcode.h (elf_swap_reloca_in): Pass source operand as a bfd_byte *.
3953 Remove INLINE keyword.
3954 (elf_swap_reloc_in): Likewise. Also clear r_addend.
3955 (elf_swap_reloc_out, elf_swap_reloca_out): Pass destination operand
3957 (elf_write_relocs): Consolidate REL and RELA code.
3958 (elf_slurp_reloc_table_from_section): Simplify REL code.
3959 (NAME(_bfd_elf,size_info)): Populate reloc swap entries.
3960 * elf-bfd.h (MAX_INT_RELS_PER_EXT_REL): Define.
3961 * elflink.h (elf_link_read_relocs_from_section): Consolidate REL and
3963 (elf_link_adjust_relocs): Likewise. Don't malloc space for temp
3964 reloc array, use a fixed size of MAX_INT_RELS_PER_EXT_REL.
3965 (elf_link_output_relocs): Likewise.
3966 (elf_reloc_link_order): Likewise.
3967 (elf_finish_pointer_linker_section): Likewise.
3968 (struct elf_link_sort_rela): Remove union.
3969 (elf_link_sort_cmp1): Update to suit.
3970 (elf_link_sort_cmp2): Here too.
3971 (elf_link_sort_relocs): Consolidate REL and RELA code. Fix memory
3972 over-allocation for int_rels_per_ext_rel != 1 case.
3973 * elf32-arm.h: Update all bfd_elf32_swap_reloc_out calls.
3974 * elf32-i386.c: Likewise.
3975 * elf32-cris.c: Likewise for bfd_elf32_swap_reloca_out.
3976 * elf32-hppa.c, elf32-i370.c, elf32-m68k.c, elf32-ppc.c, elf32-s390.c,
3977 elf32-sh.c, elf32-vax.c, elfxx-mips.c: Likewise.
3978 * elf64-alpha.c: Likewise for bfd_elf64_swap_reloca_out.
3979 * elf64-hppa.c, elf64-mips.c, elf64-ppc.c, elf64-s390.c, elf64-sh64.c,
3980 elf64-sparc.c, elf64-x86-64.c: Likewise.
3981 * elfxx-ia64.c: Likewise for bfd_elfNN_swap_reloca_out.
3982 * elfxx-mips.c (sort_dynamic_relocs): Likewise for
3983 bfd_elf32_swap_reloc_in.
3985 * elf32-arm.h: Update elf32_arm_info_to_howto calls.
3986 * elf32-mips.c: Likewise for mips_info_to_howto_rel.
3987 (mips_elf64_swap_reloc_in): Zero r_addend.
3988 (mips_elf64_be_swap_reloc_in): Likewise.
3989 (mips_elf64_slurp_one_reloc_table): Simplify.
3991 * elf64-alpha.c (alpha_elf_size_info): Populate reloc swap entries.
3992 * elf64-hppa.c (hppa64_elf_size_info): Likewise.
3993 * elf64-sparc.c (sparc64_elf_size_info): Likewise.
3995 2002-11-28 Kaz Kojima <kkojima@rr.iij4u.or.jp>
3997 * elf32-sh.c (sh_elf_relocate_section): Don't complain about
3998 unresolved debugging relocs in dynamic applications.
3999 * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
4001 2002-11-26 Alan Modra <amodra@bigpond.net.au>
4003 * elf-eh-frame.c (ENSURE_NO_RELOCS): Disregard R_*_NONE relocs.
4004 (_bfd_elf_discard_section_eh_frame): Don't discard duplicate CIEs
4005 on a relocatable link. Comment typos.
4006 * elf.c (_bfd_elf_link_hash_newfunc): Assign elements of structure
4007 in the order they are declared. Clear elf_hash_value too.
4008 (_bfd_elf_link_hash_table_init): Likewise assign in order. Clear
4009 eh_info and tls_segment.
4010 * elflink.h (elf_link_input_bfd <emit_relocs>): Keep reloc offsets
4011 sorted when discarding relocs by turning them into R_*_NONE.
4013 * libbfd.c (warn_deprecated): Comment spelling.
4014 * po/SRC-POTFILES.in: Regenerate.
4016 2002-11-21 Richard Henderson <rth@redhat.com>
4018 * elflink.h (elf_link_add_object_symbols): Don't overwrite the
4019 arch's st_other bits when merging visibilities.
4020 (elf_link_output_extsym): Tidy clearing of visibility field.
4022 2002-11-21 Alan Modra <amodra@bigpond.net.au>
4024 * coff-mcore.c (SWAP_IN_RELOC_OFFSET): Define.
4025 (SWAP_OUT_RELOC_OFFSET): Define.
4027 2002-11-20 Alexandre Oliva <aoliva@redhat.com>
4029 * elf.c (_bfd_elf_link_hash_table_init): Make sure
4030 can_refcount is properly extended to the type of
4033 2002-11-19 Alexandre Oliva <aoliva@redhat.com>
4035 * elfxx-mips.c (MIPS_RELOC_RELA_P): New macro.
4036 (_bfd_mips_elf_relocate_section): Use it.
4038 * elfxx-mips.c (MNAME): New macro.
4039 (_bfd_mips_elf_check_relocs): Use it.
4040 (_bfd_mips_elf_discard_info): Likewise.
4041 (_bfd_mips_elf_final_link): Likewise.
4043 2002-11-19 Alan Modra <amodra@bigpond.net.au>
4045 * elf64-ppc.c (ppc64_elf_edit_opd): When deleting relocs, adjust
4046 rel_hdr.sh_size too.
4048 2002-11-18 Klee Dienes <kdienes@apple.com>
4050 * Makefile.am (BFD32_LIBS): Add bfdwin.lo, bfdio.lo.
4051 (BFD32_LIBS_CFILES): Add bfdwin.c, bfdio.c.
4052 (BFD_H_FILES): Add bfdwin.c, bfdio.c.
4053 (LIBBFD_H_FILES): Add bfdwin.c, bfdio.c.
4054 Add dependencies for bfdwin.c, bfdio.c.
4055 * bfd.c: Remove bfd_get_mtime, bfd_get_size.
4056 * libbfd.c: Remove real_read, bfd_bread, _bfd_window_internal,
4057 bfd_init_window, bfd_free_window, bfd_get_file_window, bfd_bwrite,
4058 bfd_tell, bfd_flush, bfd_stat, bfd_seek.
4059 * bfdio.c: New file. Contains real_read, bfd_bread, bfd_write,
4060 bfd_tell, bfd_flush, bfd_stat, bfd_seek, bfd_ge_mtime,
4061 bfd_get_size (moved from libbfd.c and bfd.c).
4062 * bfdwin.c New file. Contains _bfd_window_internal,
4063 bfd_init_window, bfd_free_window, bfd_get_file_window (moved from
4064 libbfd.c and bfd.c).
4065 * po/SRC-POTFILES.in: Regenerate.
4066 * po/bfd.pot: Regenerate.
4067 * libbfd.h: Regenerate.
4068 * bfd-in2.h: Regenerate.
4069 * aclocal.m4: Regenerate.
4070 * Makefile.in: Regenerate.
4071 * configure: Regenerate.
4073 2002-11-18 Klee Dienes <kdienes@apple.com>
4075 * bfd.c (bfd_preserve_save): Don't zero BFD_IN_MEMORY.
4077 2002-11-15 Kazu Hirata <kazu@cs.umass.edu>
4079 * coff-h8300.c (h8300_reloc16_estimate): Do not optimize away
4080 jsr after a short jump.
4081 * elf32-h8300.c (elf32_h8_relax_section): Likewise.
4083 2002-11-15 Klee Dienes <kdienes@apple.com>
4085 * pef.c (bfd_pef_convert_architecture): Move declaration of
4086 ARCH_POWERPC and ARCH_M68K to the start of the function.
4088 2002-11-14 Svein E. Seldal <Svein.Seldal@solidas.com>
4090 * coff-tic4x.c (tic4x_howto_table): Formatting fixup
4092 2002-11-14 Hans-Peter Nilsson <hp@bitrange.com>
4094 * elf64-mmix.c (_bfd_mmix_finalize_linker_allocated_gregs):
4095 For bpo_gregs_section->contents, allocate _raw_size, not
4098 2002-11-13 Klee Dienes <kdienes@apple.com>
4100 * config.bfd: Add entries for powerpc-*-darwin and cousins.
4102 2002-11-13 H.J. Lu <hjl@gnu.org>
4104 * elfcode.h (elf_object_p): Don't restore abfd->arch_info.
4106 2002-11-13 Klee Dienes <kdienes@apple.com>
4107 Alan Modra <amodra@bigpond.net.au>
4109 * bfd.c (struct bfd_preserve): New.
4110 (bfd_preserve_save): New function.
4111 (bfd_preserve_restore): Ditto.
4112 (bfd_preserve_finish): Ditto.
4113 * bfd-in2.h: Regenerate.
4114 * mach-o.c: Formatting.
4115 (bfd_mach_o_scan_read_symtab_symbol): Make "value" unsigned.
4116 (bfd_mach_o_object_p): Use bfd_preserve_save/restore/finish.
4117 (bfd_mach_o_core_p): Ditto.
4118 (bfd_mach_o_scan): Pass in mdata.
4119 * mach-o.h (bfd_mach_o_scan): Update prototype.
4120 * pef.c: Formatting.
4121 (bfd_pef_object_p): Use bfd_preserve_save/restore/finish.
4122 (bfd_pef_xlib_object_p): Ditto.
4123 (bfd_pef_scan): Pass in mdata. Move version check to bfd_pef_object_p.
4124 * pef.h (bfd_pef_scan): Update prototype.
4125 * xsym.c: Formatting, K&R fixes.
4126 (bfd_sym_object_p): Use bfd_preserve_save/restore/finish.
4127 (bfd_sym_scan): New function split out from bfd_sym_object_p.
4128 * xsym.h (bfd_sym_scan): Declare.
4129 * elfcode.h (elf_object_p): Use bfd_preserve_save/restore/finish.
4130 * elfcore.h (elf_core_file_p): Likewise.
4131 * targets.c (_bfd_target_vector): Revert 2002-11-08 change.
4133 2002-11-12 Nick Clifton <nickc@redhat.com>
4135 * po/da.po: Updated Danish translation.
4137 2002-11-12 Alan Modra <amodra@bigpond.net.au>
4139 * elflink.h (elf_link_add_object_symbols): Optimize stabs for
4140 relocatable link too.
4141 (elf_link_input_bfd): When emitting relocs, adjust offsets for
4142 eh_frame and stab sections. Zap deleted relocs.
4143 (elf_reloc_symbol_deleted_p): Return true for zero r_symndx.
4144 (elf_bfd_discard_info): Run for relocatable link too.
4145 * elf64-ppc.c (ppc64_elf_edit_opd): Rename from edit_opd. Make global.
4147 (ppc64_elf_size_dynamic_sections): Don't call edit_opd from here.
4148 * elf64-ppc.h (ppc64_elf_edit_opd): Declare.
4150 * elf-bfd.h (struct cie_header): Move from elf_eh-frame.c.
4151 (struct cie, struct eh_cie_fde, struct eh_frame_sec_info): Likewise.
4152 (struct eh_frame_array_ent, struct eh_frame_hdr_info): Likewise.
4153 (enum elf_link_info_type): Remove ELF_INFO_TYPE_EH_FRAME_HDR.
4154 (struct eh_frame_hdr_info): Add "hdr_sec", remove "split".
4155 (struct elf_link_hash_table): Add eh_info.
4156 (struct elf_obj_tdata): Change eh_frame_hdr to an asection *.
4157 (_bfd_elf_discard_section_eh_frame): Update prototype.
4158 (_bfd_elf_discard_section_eh_frame_hdr): Likewise.
4159 (_bfd_elf_write_section_eh_frame): Likewise.
4160 (_bfd_elf_write_section_eh_frame_hdr): Likewise.
4161 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Remove "ehdrsec"
4162 param. Get "hdr_info" from link hash table.
4163 (_bfd_elf_discard_section_eh_frame_hdr): Remove "sec" param. Get
4164 header section from link hash table. Save header section to elf_tdata.
4165 (_bfd_elf_maybe_strip_eh_frame_hdr): Remove local "sec". Use
4166 header section from link hash table. Don't alloc hdr_info. Clear
4167 hdr_sec instead of setting "strip".
4168 (_bfd_elf_eh_frame_section_offset): Formatting.
4169 (_bfd_elf_write_section_eh_frame): Remove "ehdrsec", add "info" param.
4170 Get header section from link hash table.
4171 (_bfd_elf_write_section_eh_frame_hdr): Remove "sec", add "info" param.
4172 Get header section from link hash table.
4173 * elf.c (map_sections_to_segments): Use cached eh_frame_hdr.
4174 (get_program_header_size): Likewise.
4175 (_bfd_elf_section_offset): Formatting.
4176 * elflink.h (elf_link_create_dynamic_sections): Stash eh frame header
4177 section pointer in link hash table.
4178 (elf_bfd_final_link): Adjust _bfd_elf_write_section_eh_frame_hdr
4179 and _bfd_elf_write_section_eh_frame calls. Update comment about
4181 (elf_bfd_discard_info): Adjust _bfd_elf_discard_section_eh_frame and
4182 _bfd_elf_discard_section_eh_frame_hdr calls. Remove "ehdr".
4184 * po/SRC-POTFILES.in: Regenerate.
4186 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't zero
4187 relocs for discarded FDEs. Remove dead code.
4188 (_bfd_elf_write_section_eh_frame_hdr): Remove dead code.
4189 * elflink.h (elf_bfd_discard_info): Don't save edited relocs.
4190 Tidy conditions under which stabs are edited. Formatting.
4191 * elf64-sparc.c (sparc64_elf_relocate_section): Ignore overflows
4192 from discarded relocs.
4193 * elfxx-ia64.c (elfNN_ia64_install_dyn_reloc): Add reloc output
4194 section adjustments after testing magic values.
4196 2002-11-12 Thomas Moestl <tmm@FreeBSD.org>
4198 * elf64-sparc.c (sparc64_elf_adjust_dynamic_symbol): Correct
4199 references to large plt symbols.
4201 2002-11-12 Klee Dienes <kdienes@apple.com>
4203 * mach-o.c (bfd_mach_o_scan_read_thread): Don't re-use 'i' when
4204 looking for an unused section name.
4206 2002-11-11 Kazu Hirata <kazu@cs.umass.edu>
4208 * coff-h8300.c: Fix formatting.
4209 * elf32-h8300.c: Likewise.
4210 * reloc16.c: Likewise.
4212 2002-11-09 Jeroen Dobbelaere <jeroen.dobbelaere@acunia.com>
4214 * elf32-arm.h (elf32_arm_size_dynamic_sections): Don't strip output
4215 section when dynamic section unused; _bfd_strip_section_from_output
4218 2002-11-08 Alan Modra <amodra@bigpond.net.au>
4220 * targets.c (_bfd_target_vector): Disable pef_vec, pef_xlib_vec
4223 * dwarf2.c: Revert last change.
4225 2002-11-07 Michal Ludvig <mludvig@suse.cz>
4227 * dwarf2.c (read_indirect_string, read_abbrevs, decode_line_info,
4228 _bfd_dwarf2_find_nearest_line): Use
4229 bfd_simple_get_relocated_section_contents() instead of
4230 bfd_get_section_contents().
4231 * reloc.c (bfd_perform_relocation): Add sanity check.
4232 * simple.c (simple_get_relocated_section_contents): If the section
4233 does not have any relocs associated with it, just return the
4234 unadjusted contents.
4236 2002-11-07 Hans-Peter Nilsson <hp@axis.com>
4238 * elf32-cris.c (cris_elf_relocate_section) <case R_CRIS_16_GOT,
4239 case R_CRIS_32_GOT>: Correct test for filling in constant .got
4240 contents, enabling for a non-DSO, for symbols defined in the
4241 program with --export-dynamic.
4243 2002-11-07 Alan Modra <amodra@bigpond.net.au>
4245 * elf64-ppc.c: Comment typo fixes.
4246 (ppc64_elf_merge_private_bfd_data): Allow BFD_ENDIAN_UNKNOWN input.
4248 2002-11-07 Nick Clifton <nickc@redhat.com>
4250 * po/da.po: Updated Danish translation.
4252 2002-11-06 Alexandre Oliva <aoliva@redhat.com>
4254 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Generate
4255 exactly three internal relocs per external reloc. Set reloc_count
4256 to the external reloc count.
4258 2002-11-06 Klee Dienes <kdienes@apple.com>
4260 * coff-stgo32.c (stub_bytes): Mark as const.
4261 Fix comment formatting.
4263 2002-11-06 Klee Dienes <kdienes@apple.com>
4265 * Makefile.am (BFD32_BACKENDS): Add mach-o.lo, pef.lo, and
4267 (BFD32_BACKENDS_CFILES): Add mach-o.c, pef.c, and xsym.c.
4268 (SOURCE_HFILES): Add mach-o.h, pef.h, pef-traceback.h, xsym.h
4269 * archures.c (enum bfd_architecture): Add bfd_arch_m98k.
4270 * bfd.c (struct bfd): Add private data for mach-o, pef, and sym.
4271 * targets.c (enum bfd_flavour): Add flavours for mach-o, pef, and
4273 (_bfd_target_vector): Add target vectors for mach-o, pef, and sym.
4274 * Makefile.in: Regenerate.
4275 * doc/Makefile.in: Regenerate.
4276 * bfd-in2.h: Regenerate.
4277 * xsym.c: New file. Contains support for the Apple/Metrowerks
4278 xSYM debugging format.
4280 * pef.c: New file. Contains support for the Apple Code Fragment
4281 Manager Preferred Executable Format
4283 * pef-traceback.h: New file. Contains support for parsing PowerPC
4284 traceback tables as used by PEF executables (and perhaps other
4286 * mach-o.c: New file. Contains support for the Mach-O object file
4288 * mach-o.h: New file.
4289 * mach-o-target.c: New file. Declares the mach-o targets
4290 themselves. Included three times by mach-o.c; each time with a
4291 different set of macros set.
4293 2002-11-06 Graeme Peterson <gp@qnx.com>
4295 * Makefile.am: Remove entries for elf32-qnx.[ch].
4296 * Makefile.in: Regenerate.
4297 * config.bfd: Change arm-nto to use bfd_elf32_{big|little}arm_vec,
4298 ppc-nto to use bfd_elf32_powerpc{le}_vec, sh-nto to use
4299 bfd_elf32_sh{l}_vec, and i386-nto to use bfd_elf32_i386_vec.
4300 * configure.in: Remove support for bfd_elf32_sh{l}qnx_vec,
4301 bfd_elf32_powerpc{le}qnx_vec, bfd_elf32_{big|little}armqnx_vec,
4302 and bfd_elf32_i386qnx_vec, and removed elf32-qnx.lo from other targets.
4303 bfd_elf32_sh{l}_vec, and i386-nto to use bfd_elf32_i386_vec.
4304 * configure: Regenerate.
4305 * elf32-qnx.c: Remove.
4306 * elf32-qnx.h: Remove.
4307 * elf.c: Remove calls to QNX specific set_nonloadable_filepos,
4308 is_contained_by_filepos, and copy_private_bfd_data_p.
4309 * elf-bfd.h (struct elf_backend_data): Remove set_nonloadable_filepos,
4310 is_contained_by_filepos, and copy_private_bfd_data_p.
4311 * elf32-i386.c: Remove QNX extended bfd support.
4312 * elf32-ppc.c: Remove QNX extended bfd support.
4313 * elf32-sh.c: Remove QNX extended bfd support.
4314 * elfarm-nabi.c: Remove QNX extended bfd support.
4315 * targets.c: Remove qnx vectors.
4316 * elfxx-target.h (elf_backend_set_nonloadable_filepos): Remove
4317 (elf_backend_is_contained_by_filepos): Remove.
4318 (elf_backend_copy_private_bfd_data_p): Remove.
4319 * po/SRC-POTFILES.in: Regenerate.
4321 2002-11-06 David O'Brien <obrien@FreeBSD.org>
4322 Alan Modra <amodra@bigpond.net.au>
4324 * elf64-sparc.c (sparc64_elf_relocate_section): Adjust addend of
4325 dynamic relocs against section symbols for the output section vma.
4327 2002-11-05 Alan Modra <amodra@bigpond.net.au>
4329 * elf32-arm.h (t2a1_push_insn, t2a2_ldr_insn, t2a3_mov_insn,
4330 t2a4_bx_insn, t2a5_pop_insn, t2a6_bx_insn): Remove.
4332 2002-11-05 Kaz Kojima <kkojima@rr.iij4u.or.jp>
4333 Alan Modra <amodra@bigpond.net.au>
4335 * config.bfd (sh-*-linux*): Use bfd_elf*_sh64*lin_vec as sh64
4336 vectors in target_selvecs.
4337 (shle-*-netbsdelf*): Use bfd_elf*_sh64*nbsd_vec as sh64 vectors
4339 (sh-*-netbsdelf*): Likewise.
4340 * configure.in (assocvecs): New variable. Handle assocvecs like
4342 * configure: Regenerate.
4343 * format.c (bfd_check_format_matches): Store bfd_target pointers
4344 in matching_vector instead of target names. Select first target
4345 from bfd_associated_vector that matches a list of ambiguous targets.
4346 * targets.c (_bfd_associated_vector): New array.
4347 (bfd_associated_vector): New variable.
4348 (_bfd_target_vector): Add bfd_elf*_sh64*lin_vec.
4349 * libbfd-in.h (bfd_associated_vector): Declare.
4350 * libbfd.h: Regenerate.
4352 2002-11-05 Elias Athanasopoulos <eathan@otenet.gr>
4354 * vms-gsd.c (_bfd_vms_write_gsd): Check that symbol->udata.p is
4355 non-NULL before dereferencing.
4357 2002-11-04 Kaz Kojima <kkojima@rr.iij4u.or.jp>
4359 * vms.c (vms_object_p): Restore the start address when returning
4362 2002-11-04 Alan Modra <amodra@bigpond.net.au>
4363 Hans-Peter Nilsson <hp@axis.com>
4365 * elflink.h (struct elf_final_link_info): Add shndxbuf_size.
4366 (elf_bfd_final_link): Don't bother zeroing symtab_hdr fields.
4367 Set up a larger symshndxbuf, and write it out. Free it on
4368 exit rather than freeing symbuf twice. Correct section index
4369 on output section symbol loop.
4370 (elf_link_output_sym): Accumulate symbol extension section
4371 indices, reallocating symshndxbuf rather than writing it out.
4372 (elf_link_flush_output_syms): Don't flush symshndxbuf.
4373 * elf.c (assign_section_numbers): Init i_shdrp to all zero.
4374 Use bfd_zalloc to clear i_shdrp[0] too.
4376 2002-11-03 Stephen Clarke <stephen.clarke@earthling.net>
4378 * elf32-sh64-com.c (sh64_address_in_cranges): Use
4379 _raw_size of cranges section if _cooked_size not yet set.
4381 2002-11-03 Hans-Peter Nilsson <hp@axis.com>
4383 * elf32-v850.c (v850_elf_relax_delete_bytes): Correct parameters
4384 for bfd_elf32_swap_symbol_out.
4386 2002-10-31 David O'Brien <obrien@FreeBSD.org>
4388 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't mix
4389 signed and unsigned in comparison.
4391 2002-10-30 Daniel Jacobowitz <drow@mvista.com>
4393 * coffcode.h: Remove extraneous '\'.
4395 2002-10-28 H.J. Lu <hjl@gnu.org>
4397 * Makefile.am (targets.lo): Depend on Makefile instead of
4399 (archures.lo): Likewise.
4400 * Makefile.in: Regenerated.
4402 2002-10-25 Jason Thorpe <thorpej@wasabisystems.com>
4404 * config.bfd (mips*el-*-netbsd*, mips*-*-netbsd*): Add
4405 bfd_elf64_bigmips_vec and bfd_elf64_littlemips_vec to
4408 2002-10-25 Jim Wilson <wilson@redhat.com>
4410 * elf64-sh64.c (sh_elf64_relocate_section): Call
4411 _bfd_elf_rela_local_sym. Handle relocs against STT_SECTION symbol
4412 of SHF_MERGE section.
4414 2002-10-25 Hans-Peter Nilsson <hp@axis.com>
4416 * simple.c: Correct placement of ATTRIBUTE_UNUSED.
4418 2002-10-24 John David Anglin <dave@hiauly1.hia.nrc.ca>
4420 * aoutx.h (NAME(aout,swap_ext_reloc_in)): Cast bytes->r_index to
4421 unsigned int. Cast RELOC_BASE10, RELOC_BASE13 and RELOC_BASE22 to
4423 (NAME(aout,final_link)): Cast enum used in assignment.
4424 (aout_link_write_symbols): Cast enums in comparisons, int values to
4425 boolean, enums in assignments to int.
4426 (aout_link_input_section_std): Cast rel->r_index to unsigned int.
4427 (aout_link_input_section_ext): Likewise. Cast enums used in
4428 comparisons with unsigned ints.
4429 (aout_link_reloc_link_order): Cast enum to int in assignment.
4430 * archive.c (_bfd_generic_read_ar_hdr_mag): Cast result of memchr
4432 * bfd-in.h (bfd_set_section_vma): Cast enum true to unsigned int in
4434 * bfd-in2.h (bfd_set_section_vma): Likewise.
4435 * bfd.c (bfd_record_phdr): Cast enums in assignments.
4436 * binary.c (bfd_alloc): Cast enum to long.
4437 * coffgen.c (_bfd_coff_is_local_label_name): Cast return to boolean.
4438 * dwarf2.c (read_abbrevs): Add casts to enum types.
4439 (read_attribute_value): Likewise.
4440 (arange_add): Cast result of bfd_zalloc call.
4441 (comp_unit_contains_address): Return true and false.
4442 (comp_unit_find_nearest_line): Cast return to boolean.
4443 * format.c (bfd_check_format_matches, bfd_set_format): Likewise.
4444 * gen-aout.c: define macro '_' if not defined.
4445 * libbfd.c (bfd_realloc): Cast malloc and realloc to PTR.
4446 (bfd_bwrite): Cast bfd_realloc to bfd_byte *.
4447 (bfd_write_bigendian_4byte_int): Cast return to boolean.
4448 (bfd_seek): Cast bfd_realloc to bfd_byte *.
4449 (bfd_generic_is_local_label_name): Cast return to boolean.
4450 * libcoff.h (_bfd_coff_adjust_symndx): Remove extraneous '\'.
4451 * linker.c (_bfd_link_hash_newfunc): Cast bfd_hash_allocate result to
4452 struct bfd_hash_entry *.
4453 (_bfd_generic_link_hash_newfunc): likewise.
4454 (_bfd_generic_final_link): Cast enum to unsigned int.
4455 * merge.c (sec_merge_emit): Cast return to boolean.
4456 (merge_strings): Add casts to const unsigned char *.
4457 * reloc.c (bfd_get_reloc_code_name): Cast enums in comparison to int.
4458 (bfd_generic_get_relocated_section_content): Cast enum to unsigned int.
4459 * section.c (bfd_section_hash_newfunc): Cast bfd_hash_allocate result
4460 to struct bfd_hash_entry *.
4461 (bfd_set_section_content): Add cast to PTR in comparison.
4462 * simple.c (simple_dummy_warning, simple_dummy_undefined_symbol,
4463 simple_dummy_reloc_overflow, simple_dummy_reloc_dangerous,
4464 simple_dummy_unattached_reloc,
4465 bfd_simple_get_relocated_section_contents): Add K&R declarations and
4466 function definitions.
4467 * srec.c (S3Forced): Initialize to false.
4468 (srec_get_symtab): Cast return value from bfd_alloc to asymbol *.
4469 * stabs.c (_bfd_link_section_stabs): Cast enum to int in comparisons.
4470 (_bfd_discard_section_stabs): Likewise. Also cast return to boolean.
4471 * syms.c (bfd_is_undefined_symclass): Cast return to boolean.
4472 (_bfd_stab_section_find_nearest_line): Cast enum to bfd_byte in
4475 2002-10-23 Jakub Jelinek <jakub@redhat.com>
4477 * elf64-alpha.c (elf64_alpha_check_relocs): Only put maybe_dynamic
4478 relocs into shared lib non-allocated reloc sections.
4480 2002-10-23 Nathan Tallent <eraxxon@alumni.rice.edu>
4482 * dwarf2.c (add_line_info): Ensure that the line_info_table is
4483 sorted even when given an out-of-order line sequence.
4484 (lookup_address_in_line_info_table): When an exact VMA match is
4485 not found, return line information with the closest VMA.
4487 2002-10-23 Ross Alexander <ross.alexander@uk.neceur.com>
4489 * elf64-hppa.c: Force DT_FLAGS to always be set. Required by
4490 HPUX 11.00 patch PHSS_26559.
4492 2002-10-22 Alexandre Oliva <aoliva@redhat.com>
4494 * elfxx-mips.c (_bfd_mips_elf_modify_segment_map): Don't move
4495 the options section into a separate section unless IRIX 6
4496 compatibility is enabled.
4498 2002-10-22 Alexandre Oliva <aoliva@redhat.com>
4500 * elflink.h (struct elf_link_sort_rela): Turn rel and rela
4502 (elf_link_sort_cmp1, elf_link_sort_cmp2): Adjust.
4503 (elf_link_sort_relocs): Likewise. Take int_rels_per_ext_rel
4505 * elfxx-mips.c (mips_elf_create_dynamic_relocation): Compose
4506 R_MIPS_REL32 with R_MIPS64 if ABI_64_P.
4508 2002-10-21 Graeme Peterson <gp@qnx.com>
4510 * targets.c (_bfd_target_vector): Add missing qnx vectors.
4512 2002-10-21 Alan Modra <amodra@bigpond.net.au>
4514 * targets.c (bfd_target_list): Don't return the default target twice.
4516 2002-10-21 Elias Athanasopoulos <eathan@otenet.gr>
4518 * archive.c (_bfd_archive_bsd_update_armap_timestamp): Replace
4519 perror with bfd_perror.
4521 2002-10-19 H.J. Lu <hjl@gnu.org>
4523 * elflink.h (elf_link_add_object_symbols): Correctly handle
4524 DT_RPATH and DT_RUNPATH.
4526 2002-10-19 Mark Kettenis <kettenis@gnu.org>
4528 * elf.c (elfcore_grok_note): Fix recognition on NT_PRXFPREG notes.
4530 2002-10-17 Denis Chertykov <denisc@overta.ru>
4532 * elf32-ip2k.c (ELF_MACHINE_ALT1): Define alternate machine code
4535 2002-10-17 Alan Modra <amodra@bigpond.net.au>
4537 * elfxx-target.h (USE_REL): Don't define as 1.
4538 * elf32-arm.h (USE_REL): Provide a default define of 0.
4539 Use #if rather than #ifdef when testing USE_REL.
4540 * elf32-m32r.c: Likewise.
4542 * elf32-arc.c (USE_REL): Define as 1.
4543 * elf32-d10v.c (USE_REL): Likewise.
4544 * elf32-m32r.c (USE_REL): Likewise.
4545 * elf32-m68hc11.c (USE_REL): Likewise.
4546 * elf32-m68hc12.c (USE_REL): Likewise.
4547 * elf32-or32.c (USE_REL): Likewise.
4548 * elfarm-nabi.c (USE_REL): Likewise.
4550 2002-10-16 Jakub Jelinek <jakub@redhat.com>
4552 * config.bfd (s390-*-linux*): Add targ64_selvecs.
4553 (s390x-*-linux*): Add targ_selvecs.
4555 2002-10-16 Alan Modra <amodra@bigpond.net.au>
4557 * Makefile.am (BFD32_BACKENDS): Remove elfarmqnx-nabi.lo,
4558 elf32-i386-fbsd.lo, elf32-i386qnx.lo, elf32-ppcqnx.lo,
4559 elf32-sh-lin.lo, elf32-sh64-lin.lo, elf32-sh-nbsd.lo,
4560 elf32-sh64-nbsd.lo, elf32-shqnx.lo. Add elf32-qnx.lo.
4561 (BFD32_BACKENDS_CFILES): Likewise for corresponding C files.
4562 (BFD64_BACKENDS): Remove elf64-sh64-lin.lo, elf64-sh64-nbsd.lo.
4563 (BFD64_BACKENDS_CFILES): Likewise for corresponding C files.
4564 (SOURCE_HFILES): Add elf32-qnx.h.
4565 (BUILD_HFILES): Add bfdver.h.
4567 * Makefile.in: Regenerate.
4568 * configure.in Update bfd vector dependencies.
4569 * configure: Regenerate.
4570 * elf32-i386-fbsd.c: Delete. Move code to elf32-i386.c.
4571 * elf32-i386qnx.c: Likewise.
4572 * elf32-ppcqnx.c: Delete. Move code to elf32-ppc.c.
4573 * elf32-sh-nbsd.c: Delete. Move code to elf32-sh.c.
4574 * elf32-sh-lin.c: Likewise.
4575 * elf32-shqnx.c: Likewise.
4576 * elf32-sh64-lin.c: Delete. Move code to elf32-sh64.c.
4577 * elf32-sh64-nbsd.c: Likewise.
4578 * elf64-sh64-lin.c: Delete. Move code to elf64-sh64.c.
4579 * elf64-sh64-nbsd.c: Likewise.
4580 * elfarmqnx-nabi.c: Delete. Move code to elfarm-nabi.c.
4581 * elf32-arm.h (ELF_MAXPAGESIZE): Always define.
4582 * elf32-i386.c: Remove ELF_ARCH and ELF32_I386_C_INCLUDED tests.
4583 * elf32-ppc.c: Remove ELF32_PPC_C_INCLUDED tests.
4584 * elf32-qnx.h (elf_backend_set_nonloadable_filepos): Always define.
4585 (elf_backend_is_contained_by_filepos): Likewise.
4586 (elf_backend_copy_private_bfd_data_p): Likewise.
4587 Globalize and move functions to..
4588 * elf32-qnx.c: ..here. New file.
4589 * elf32-sh.c: Remove ELF_ARCH and ELF32_SH_C_INCLUDED tests. Don't
4590 emit target vectors when INCLUDE_SHMEDIA.
4591 * elf32-sh64.c: Remove ELF_ARCH test. Move TARGET_* etc. defines to
4593 * elf64-sh64.c: Remove ELF_ARCH test.
4594 * elfarm-nabi.c: Remove ELFARM_NABI_C_INCLUDED test.
4595 * po/BLD-POTFILES.in: Regenerate.
4596 * po/SRC-POTFILES.in: Regenerate.
4598 2002-10-16 Alan Modra <amodra@bigpond.net.au>
4600 * elflink.h (elf_link_add_object_symbols): Error out on dynamic objects
4601 loaded with --just-symbols.
4603 * elf32-i386qnx.c (TARGET_LITTLE_NAME): Define.
4604 * elf32-ppcqnx.c (TARGET_LITTLE_NAME, TARGET_BIG_NAME): Define.
4605 * elf32-shqnx.c (TARGET_LITTLE_NAME, TARGET_BIG_NAME): Define.
4606 * elfarmqnx-nabi.c (TARGET_LITTLE_NAME, TARGET_BIG_NAME): Define.
4608 2002-10-15 Richard Henderson <rth@redhat.com>
4610 * Makefile.am (BFD64_BACKENDS): Remove elf64-alpha-fbsd.
4611 (BFD64_BACKENDS_CFILES): Likewise.
4612 * configure.in (bfd_elf64_alpha_freebsd_vec): Use elf64-alpha.
4613 * elf64-alpha-fbsd.c: Remove file, move code ...
4614 * elf64-alpha.c: ... here.
4615 * Makefile.in, configure: Rebuild.
4617 2002-10-14 Richard Henderson <rth@redhat.com>
4619 * elf64-alpha.c (elf64_alpha_relocate_section) [BRSGP]: Increment
4622 2002-10-14 Stephen Clarke <stephen.clarke@superh.com>
4624 * elf32-sh.c (elf_sh_link_hash_entry): Replace
4625 datalabel_got_offset with union of datalabel_got
4626 offset and refcount.
4627 (sh_elf_link_hash_newfunc): Initialize datalabel_got.refcount.
4628 (allocate_dynrelocs): Delete unnecessary code for
4629 STT_DATALABEL type. Create entry in got for
4630 datalabel version of symbol if datalabel_got.refcount > 0.
4631 (sh_elf_relocate_section): Use datalabel_got union.
4632 (sh_elf_gc_sweep_hook): Pull common code to initialize
4633 h and eh out of switch statement. Declare seen_stt_datalabel.
4634 Initialize it. Decrement datalabel_got.refcount for
4635 got relocs when seen_stt_datalabel is true.
4636 Decrement local_got_refcounts entry for datalabel got relocs
4638 (sh_elf_copy_indirect_symbol): Copy datalabel_got field over.
4639 (sh_elf_check_relocs): Declare seen_stt_datalabel.
4640 Initialize it. When seen_stt_datalabel is true, increment
4641 datalabel_got refcount rather than got.refcount.
4642 (sh_elf_finish_dynamic_symbol): Create relocs to
4643 initialize got entry for datalabel version of symbol.
4645 2002-10-14 Alan Modra <amodra@bigpond.net.au>
4647 * Makefile.am: Run "make dep-am".
4648 (BFD_H_FILES): Remove version.h.
4649 * bfd-in.h (BFD_VERSION, BFD_VERSION_DATE, BFD_VERSION_STRING): Move..
4650 * version.h: ..to here.
4651 * configure.in (bfd_version_date): Remove.
4652 (AC_OUTPUT): Make bfdver.h from version.h.
4653 * bfd.c: #include "bfdver.h".
4654 * vms-hdr.c: Likewise.
4655 * Makefile.in: Regenerate.
4656 * bfd-in2.h: Regenerate.
4657 * configure: Regenerate.
4658 * po/SRC-POTFILES.in: Regenerate.
4660 2002-10-14 Alan Modra <amodra@bigpond.net.au>
4662 * archures.c (bfd_mach_i386_i386, bfd_mach_i386_i8086,
4663 bfd_mach_i386_i386_intel_syntax, bfd_mach_x86_64,
4664 bfd_mach_x86_64_intel_syntax bfd_mach_ppc, bfd_mach_ppc64,
4665 bfd_mach_rs6k, bfd_mach_d10v, bfd_mach_sh, bfd_mach_v850,
4666 bfd_mach_arc_5, bfd_mach_arc_6, bfd_mach_arc_7, bfd_mach_arc_8,
4667 bfd_mach_m32r, bfd_mach_frv, bfd_mach_frvsimple,
4668 bfd_mach_ia64_elf64, bfd_mach_ia64_elf32,
4669 bfd_mach_ip2022, bfd_mach_ip2022ext,
4670 bfd_mach_s390_31, bfd_mach_s390_64, bfd_mach_xstormy16): Renumber.
4671 * bfd-in2.h: Regenerate.
4673 2002-10-14 Kaz Kojima <kkojima@rr.iij4u.or.jp>
4675 * config.bfd (sh*eb-*-linux*, sh*-*-linux*): Add the alternative
4676 endian vector to targ_selvecs.
4678 2002-10-13 Alexandre Oliva <aoliva@redhat.com>
4680 * elfxx-mips.c (mips_elf_calculate_relocation): Take
4681 save_addend argument. Don't apply the 32-bit mask to a
4682 GPREL32 value if it's to be used in another relocation. Don't
4683 use forced-check computation of local_p to decide whether to
4684 add gp0 to GPREL16 value. Don't use only the lowest 16 bits
4685 of the addend of a non-in-place GPREL16 relocation.
4686 (_bfd_mips_elf_relocate_section): Pass use_saved_addend_p to
4687 mips_elf_calculate_relocation().
4689 2002-10-12 Stephane Carrez <stcarrez@nerim.fr>
4691 * elf32-m68hc11.c (m68hc11_elf_relax_section): Don't treat relocs
4692 with symbols in other sections if we relaxed something; the sections
4693 output offsets must be re-computed before.
4695 2002-10-12 Stephane Carrez <stcarrez@nerim.fr>
4697 * elf32-m68hc11.c (m68hc11_elf_relax_section): Update symbols
4698 handling to use Elf_Internal_Sym.
4699 (m68hc11_elf_relax_delete_bytes): Likewise.
4701 2002-10-11 Kaz Kojima <kkojima@rr.iij4u.or.jp>
4703 * elf32-sh.c (sh_elf_optimized_tls_reloc, sh_elf_mkobject,
4704 sh_elf_object_p, dtpoff_base): New functions.
4705 (sh_elf_howto_table): Add TLS relocs.
4706 (sh_reloc_map): Likewise.
4707 (sh_elf_info_to_howto): Support TLS relocs.
4708 (elf_sh_link_hash_entry): Add tls_type and tls_tpoff32.
4709 (sh_elf_hash_entry, sh_elf_tdata, sh_elf_local_got_tls_type):
4711 (sh_elf_obj_tdata): New.
4712 (elf_sh_link_hash_table): Add tls_ldm_got.
4713 (sh_elf_link_hash_table_create): Clear refcount of tls_ldm_got.
4714 (allocate_dynrelocs): Support TLS relocs.
4715 (sh_elf_size_dynamic_sections): Likewise.
4716 (sh_elf_relocate_section): Support TLS relocs. Don't try to find
4717 .rela.got section when found already. Return false after printing
4718 error about unresolvable relocation.
4719 (sh_elf_gc_sweep_hook): Support TLS relocs.
4720 (sh_elf_check_relocs): Likewise.
4721 (sh_elf_finish_dynamic_symbol): Likewise.
4722 (bfd_elf32_mkobject, elf_backend_object_p): Define for TLS case.
4723 * reloc.c: Add SH TLS relocs.
4724 * bfd-in2.h, libbfd.h: Regenerate.
4726 2002-10-11 Daniel Jacobowitz <drow@mvista.com>
4728 * Makefile.in: Regenerated.
4730 2002-10-11 Daniel Jacobowitz <drow@mvista.com>
4732 * Makefile.am: Run dep-am.
4733 (BFD_H_DEP): Add simple.c and linker.c.
4734 (BFD32_LIBS): Add simple.lo.
4735 (BFD32_LIBS_CFILES): Add simple.c.
4736 * Makefile.in: Regenerated.
4737 * bfd-in2.h: Regenerated.
4738 * simple.c: New file.
4740 2002-10-11 Alan Modra <amodra@bigpond.net.au>
4742 * coff-arm.c (record_arm_to_thumb_glue): Avoid type-punned pointers.
4743 (record_thumb_to_arm_glue): Likewise.
4744 * ecoff.c (ecoff_link_add_externals): Likewise.
4745 * elf32-arm.h (record_arm_to_thumb_glue): Likewise.
4746 (record_thumb_to_arm_glue): Likewise.
4747 * elf32-m32r.c (m32r_elf_add_symbol_hook): Likewise.
4748 * elf32-sh.c (sh_elf_create_dynamic_sections): Likewise.
4749 * elf32-sh64.c (sh64_elf_add_symbol_hook): Likewise.
4750 * elf64-alpha.c (elf64_alpha_create_dynamic_sections): Likewise.
4751 * elf64-ppc.c (func_desc_adjust): Likewise.
4752 * elf64-sh64.c (sh64_elf64_add_symbol_hook): Likewise.
4753 (sh64_elf64_create_dynamic_sections): Likewise.
4754 * elflink.c (_bfd_elf_create_got_section): Likewise.
4755 (_bfd_elf_create_dynamic_sections): Likewise.
4756 (_bfd_elf_create_linker_section): Likewise.
4757 * elflink.h (elf_add_default_symbol): Likewise.
4758 (elf_link_create_dynamic_sections): Likewise.
4759 (NAME(bfd_elf,size_dynamic_sections)): Likewise.
4760 * elfxx-ia64.c (elfNN_ia64_aix_add_symbol_hook): Likewise.
4761 * elfxx-mips.c (mips_elf_create_got_section): Likewise.
4762 (_bfd_mips_elf_add_symbol_hook): Likewise.
4763 (_bfd_mips_elf_create_dynamic_sections): Likewise.
4764 * linker.c (generic_link_add_symbol_list): Likewise.
4765 * xcofflink.c (xcoff_link_add_symbols): Likewise.
4767 * elfxx-ia64.c (oor_brl, oor_ip): Conditionally define.
4769 * elf64-ppc.c (edit_opd): Only zero opd syms when function is
4770 completely removed. Correct local sym adjustment.
4772 2002-10-10 Stephen Clarke <stephen.clarke@superh.com>
4774 * elf32-sh.c (elf_sh_pic_plt_entry_be, elf_sh_pic_plt_entry_le):
4775 Correct mistake in calculation of address of .got.
4776 * elf64-sh64.c (elf_sh64_pic_plt_entry_be,
4777 elf_sh64_pic_plt_entry_le): Likewise.
4779 2002-10-09 Richard Shann <richard.shann@superh.com>
4780 Stephen Clarke <stephen.clarke@superh.com>
4782 * Makefile.am: Add entries for elf32-sh64-lin.c and
4783 elf64-sh64-lin.c. Regenerate.
4784 * Makefile.in: Regenerate.
4785 * config.bfd: Change sh64eb-*-linux* and sh64-*-linux*
4786 to use sh64 vectors rather than sh vectors.
4787 * configure.in: Add bfd_elf32_sh64lin_vec, bfd_elf32_sh64blin_vec,
4788 bfd_elf64_sh64lin_vec, bfd_elf64_sh64blin_vec.
4789 * configure: Regenerate.
4790 * elf32-sh64-lin.c: New file.
4791 * elf64-sh64-lin.c: New file.
4792 * targets.c: Add bfd_elf32_sh64lin_vec, bfd_elf32_sh64blin_vec,
4793 bfd_elf64_sh64lin_vec, bfd_elf64_sh64blin_vec.
4795 2002-10-08 H.J. Lu <hjl@gnu.org>
4797 * elf32-i386.c (elf_i386_relocate_section): Re-arrange the
4798 IE->LE transition for R_386_TLS_IE.
4800 2002-10-08 Alan Modra <amodra@bigpond.net.au>
4802 * elf64-ppc.c (edit_opd): Correct test for discarded sections.
4804 2002-10-07 Mark Elbrecht <snowball3@softhome.net>
4806 * cofflink.c (mark_relocs): Don't mark relocations in excluded
4809 2002-10-07 Alan Modra <amodra@bigpond.net.au>
4811 * elflink.h (elf_link_input_bfd): Remove BFD_VERSION_DATE dependent
4814 * elf64-ppc.c (ppc64_elf_build_stubs): Increment .glink indx.
4816 2002-10-06 Alan Modra <amodra@bigpond.net.au>
4818 * opncls.c: Formatting.
4819 (_bfd_new_bfd): Use a smaller section hash table.
4821 2002-10-05 Alexandre Oliva <aoliva@redhat.com>
4823 * elfxx-mips.c (mips_elf_create_dynamic_relocation): Set the type
4824 of the other two relocations packed with a REL32 to NONE.
4826 2002-10-02 Stephen Clarke <stephen.clarke@superh.com>
4828 * elf32-sh.c (elf_sh_link_hash_entry): Add gotplt_refcount.
4829 (sh_elf_link_hash_newfunc): Initialize it.
4830 (allocate_dynrelocs): Transfer gotplt refs from plt.refcount
4831 to got.refcount for symbols that are forced local or when
4832 we have direct got refs.
4833 (sh_elf_gc_sweep_hook): Adjust gotplt_refcount. Use it
4834 to correctly adjust got.refcount and plt.refcount.
4835 (sh_elf_copy_indirect_symbol): Copy gotplt_refcount across.
4836 (sh_elf_check_relocs): Increment gotplt_refcount.
4838 2002-10-01 Jakub Jelinek <jakub@redhat.com>
4840 * elf32-i386.c (elf_i386_relocate_section): Fix
4841 movl foo@indntpoff, %eax IE->LE transition.
4843 2002-10-01 Jakub Jelinek <jakub@redhat.com>
4845 * elf64-x86-64.c (elf64_x86_64_relocate_section): Change TLSGD
4846 sequence and its transitions.
4848 2002-10-01 Jakub Jelinek <jakub@redhat.com>
4850 * elf32-i386.c (elf_i386_relocate_section): Resolve R_386_TLS_LDO_32
4851 to st_value + addend in non-code sections.
4852 * elf64-x86-64.c (elf64_x86_64_relocate_section): Resolve
4853 R_X86_64_DTPOFF32 to st_value + addend in non-code sections.
4855 2002-09-30 Gavin Romig-Koch <gavin@redhat.com>
4856 Ken Raeburn <raeburn@cygnus.com>
4857 Aldy Hernandez <aldyh@redhat.com>
4858 Eric Christopher <echristo@redhat.com>
4859 Richard Sandiford <rsandifo@redhat.com>
4861 * archures.c (bfd_mach_mips4120, bfd_mach_mips5400): New.
4862 (bfd_mach_mips5500): New.
4863 * cpu-mips.c (I_mips4120, I_mips5400, I_mips5500): New.
4864 (arch_info_struct): Add corresponding entries here.
4865 * elfxx-mips.c (_bfd_elf_mips_mach): Handle E_MIPS_MACH_4120,
4866 E_MIPS_MACH_5400 and E_MIPS_MACH_5500.
4867 (_bfd_mips_elf_final_write_processing): Handle bfd_mach_mips4120,
4868 bfd_mach_mips5400 and bfd_mach_mips5500.
4869 (_bfd_mips_elf_mach_extends_p): New function.
4870 (_bfd_mips_elf_merge_private_bfd_data): Use it to help merge
4871 the EF_MIPS_MACH flags.
4872 * bfd-in2.h: Regenerate.
4874 2002-09-28 Jason Thorpe <thorpej@wasabisystems.com>
4876 * elf32-vax.c (elf_vax_size_dynamic_section): Don't strip
4879 2002-09-28 Alan Modra <amodra@bigpond.net.au>
4881 * elf.c (map_sections_to_segments): Correct test for start of
4882 writable section in the same page as end of read-only section.
4884 2002-09-27 Matt Thomas <matt@3am-software.com>
4886 * elf32-vax.c (elf_vax_check_relocs): Remove unused
4887 local_got_refcounts usage. Remove allocation of got slot.
4888 (elf_vax_gc_sweep_hook): Remove unused local_got_refcounts usage.
4889 Remove de-allocation of got slot.
4890 (elf_vax_size_dynamic_section): Fix some indentation. Add hash
4891 traversal for elf_vax_instantiate_got_entries. Allow empty .got
4892 sections to be GC'ed.
4893 (elf_vax_instantiate_got_entries): New function.
4894 (elf_vax_relocate_section): Simplify R_VAX_GOT32 handling. Remove
4895 tests that are now handled by elf_vax_instantiate_got_entries.
4896 Assert GOT entry falls within .got section size. Remove redundant
4897 comparisions. Fix comments.
4899 2002-09-27 Jakub Jelinek <jakub@redhat.com>
4901 * reloc.c: Add x86-64 TLS relocs.
4902 * bfd-in2.h, libbfd.h: Rebuilt.
4903 * elf64-x86-64.c (x86_64_elf_howto): Fix size fields for 32-bit
4904 relocs. Add TLS relocs.
4905 (x86_64_reloc_map): Add TLS relocs.
4906 (elf64_x86_64_info_to_howto): Adjust for added TLS relocs.
4907 (struct elf64_x86_64_link_hash_entry): Add tls_type field.
4908 (GOT_UNKNOWN, GOT_NORMAL, GOT_TLS_GD, GOT_TLS_IE): Define.
4909 (elf64_x86_64_hash_entry): Define.
4910 (struct elf64_x86_64_obj_tdata): New.
4911 (elf64_x86_64_tdata, elf64_x86_64_local_got_tls_type): Define.
4912 (struct elf64_x86_64_link_hash_table): Add tls_ld_got.
4913 (link_hash_newfunc): Initialize tls_type.
4914 (elf64_x86_64_link_hash_table_create): Initialize tls_ld_got.
4915 (elf64_x86_64_copy_indirect_symbol): Swap tls_type if necessary.
4916 (elf64_x86_64_mkobject): New.
4917 (elf64_x86_64_elf_object_p): Allocate struct elf64_x86_64_obj_tdata.
4918 (elf64_x86_64_tls_transition): New.
4919 (elf64_x86_64_check_relocs): Add r_type variable and use it.
4921 (elf64_x86_64_gc_sweep_hook): Handle TLS relocs.
4922 (allocate_dynrelocs): Allocate GOT space for TLS relocs.
4923 (elf64_x86_64_size_dynamic_sections): Likewise.
4924 (dtpoff_base, tpoff): New.
4925 (elf64_x86_64_relocate_section): Handle TLS relocs.
4926 (elf64_x86_64_finish_dynamic_symbol): Only handle non-TLS GOT
4928 (bfd_elf64_mkobject): Define.
4930 * elf32-i386.c (elf_i386_check_relocs) [R_386_TLS_LE]: Set
4931 DF_STATIC_TLS if shared.
4933 2002-09-26 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
4935 * elfxx-mips.c (_bfd_mips_elf_fake_sections): Don't emit unneeded
4936 empty relocation sections.
4938 2002-09-26 Alan Modra <amodra@bigpond.net.au>
4940 * elf64-ppc.c (ppc_build_one_stub): Don't build glink stubs here.
4941 (ppc64_elf_build_stubs): Build them here instead.
4943 2002-09-24 Jakub Jelinek <jakub@redhat.com>
4945 * elf32-sparc.c (elf32_sparc_relocate_section): Put R_SPARC_RELATIVE
4946 addend into r_addend, not *r_offset.
4947 (elf32_sparc_finish_dynamic_symbol): Likewise.
4948 * elf64-sparc.c (sparc64_elf_finish_dynamic_symbol): Clear xword at
4949 R_SPARC_RELATIVE's r_offset.
4951 2002-09-23 Nathan Tallent <eraxxon@alumni.rice.edu>
4953 * dwarf2.c (decode_line_info): Update to correctly decode
4954 the (non-standard DWARF2) out-of-order address sequences
4955 generated by the Intel C++ 6.0 compiler for ia64-Linux.
4957 2002-09-23 Mark Elbrecht <snowball3@softhome.net>
4959 * config.bfd: For DJGPP targets, match with any cpu and any machine.
4961 2002-09-23 Alan Modra <amodra@bigpond.net.au>
4963 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Zero relocs
4964 for discarded FDEs. Remove redundant assignment.
4965 * elflink.h (elf_bfd_discard_info): Save edited relocs.
4967 2002-09-22 H.J. Lu <hjl@gnu.org>
4969 * elf64-alpha.c (elf64_alpha_merge_ind_symbols): Don't merge
4970 the relocation count between different .reloc sections.
4972 2002-09-21 Alan Modra <amodra@bigpond.net.au>
4974 * elf32-ppc.c (ppc_elf_relocate_section): Allow ".sbss.*" and
4975 ".sdata.*" for R_PPC_SDAREL16, ".sbss2*" and ".sdata2*" for
4976 R_PPC_EMB_SDA2REL. Similarly for R_PPC_EMB_SDA21 and
4979 * elfcode.h (elf_slurp_reloc_table_from_section): Make "symcount"
4980 unsigned. Move "symcount" assignment out of loop.
4981 * Makefile.am: Run "make dep-am".
4982 * Makefile.in: Regenerate.
4983 * configure: Regenerate.
4984 * po/SRC-POTFILES.in: Regnerate.
4986 2002-09-19 Nathan Tallent <eraxxon@alumni.rice.edu>
4988 * dwarf2.c (_bfd_dwarf2_find_nearest_line): If address length is
4989 zero, set it to 8 for (non-standard) 64-bit DWARF2 formats
4992 2002-09-19 Jakub Jelinek <jakub@redhat.com>
4994 * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Clear .got word
4995 even if generating R_PPC_RELATIVE reloc.
4996 (ppc_elf_relocate_section): Make sure relocation is performed
4997 if skip == -2. Clear memory at r_offset when creating dynamic
5000 2002-09-19 Jakub Jelinek <jakub@redhat.com>
5002 * reloc.c (BFD_RELOC_386_TLS_TPOFF, BFD_RELOC_386_TLS_IE,
5003 BFD_RELOC_386_TLS_GOTIE): Add.
5004 * bfd-in2.h, libbfd.h: Rebuilt.
5005 * elf32-i386.c (elf_howto_table): Add R_386_TLS_TPOFF, R_386_TLS_IE
5006 and R_386_TLS_GOTIE.
5007 (elf_i386_reloc_type_lookup): Handle it.
5008 (struct elf_i386_link_hash_entry): Change tls_type type to unsigned
5009 char instead of enum, change GOT_* into defines.
5010 (GOT_TLS_IE_POS, GOT_TLS_IE_NEG, GOT_TLS_IE_BOTH): Define.
5011 (elf_i386_tls_transition): Handle R_386_TLS_IE and R_386_TLS_GOTIE.
5012 (elf_i386_check_relocs): Likewise. Avoid crash if local symbol is
5013 accessed both as normal and TLS symbol. Move R_386_TLS_LDM and
5014 R_386_PLT32 cases so that R_386_TLS_IE can fall through.
5015 Handle R_386_TLS_LE_32 and R_386_TLS_LE in shared libs.
5016 (elf_i386_gc_sweep_hook): Handle R_386_TLS_IE and R_386_TLS_GOTIE.
5017 Handle R_386_TLS_LE_32 and R_386_TLS_LE in shared libs.
5018 (allocate_dynrelocs): Allocate 2 .got and 2 .rel.got entries if
5019 tls_type is GOT_TLS_IE_BOTH.
5020 (elf_i386_size_dynamic_sections): Likewise.
5021 (elf_i386_relocate_section): Handle R_386_TLS_IE and R_386_TLS_GOTIE.
5022 Handle R_386_TLS_LE_32 and R_386_TLS_LE in shared libs.
5023 (elf_i386_finish_dynamic_symbol): Use tls_type & GOT_TLS_IE to catch
5024 all 4 GOT_TLS_* TLS types.
5026 2002-09-19 Nick Clifton <nickc@redhat.com>
5028 * elflink.h (elf_fix_symbol_flags): When examining weak symbols,
5029 follow indirect links.
5031 2002-09-19 Nathan Tallent <eraxxon@alumni.rice.edu>
5033 * ecoffswap.h (ecoff_swap_pdr_in) <isym, iline>: Update to
5034 correctly sign-extend 32-bit ECOFF null values (0xffffffff, -1)
5036 (ecoff_swap_sym_in) <iss>: Likewise.
5037 * ecoff.c (_bfd_ecoff_slurp_symbolic_info): Fix error reading
5038 ECOFF information: 'ioptMax' refers to the actual *size*
5039 of the optimization symtab, not the number of entries.
5041 2002-09-19 Daniel Jacobowitz <drow@mvista.com>
5043 * elf32-arm.h (elf32_arm_adjust_dynamic_symbol): Update
5044 ELF_LINK_HASH_NEEDS_PLT logic.
5046 2002-09-18 Daniel Jacobowitz <drow@mvista.com>
5048 * elfcode.h (elf_slurp_reloc_table_from_section): Check
5049 correct relocation count.
5051 2002-09-17 Daniel Jacobowitz <drow@mvista.com>
5053 * bfd-in.h (bfd_get_dynamic_symcount): Define.
5054 * bfd.c (struct _bfd): Add dynsymcount.
5055 * bfd-in2.h: Regenerated.
5056 * elf.c (_bfd_elf_canonicalize_dynamic_symtab): Set
5058 * elfcode.h (elf_slurp_reloc_table_from_section): Check
5061 2002-09-17 Stan Cox <scox@redhat.com>
5063 * elf64-mips.c (mips_elf64_be_swap_reloca_out): Handle type2 and type3.
5064 (mips_elf64_final_gp): Don't make up gp value.
5065 * elfn32-mips.c (mips_elf_final_gp): Likewise.
5066 * elfxx-mips.c (_bfd_mips_elf_final_link): Always create
5067 .MIPS.options/.options section.
5069 2002-09-17 David O'Brien <obrien@FreeBSD.org>
5071 * elf32-i386-fbsd.c: Always label using the EI_OSABI method.
5072 It is benign for FreeBSD < 4.1. Minor reformatting.
5073 * elf64-alpha-fbsd.c: Likewise.
5075 2002-09-17 Jakub Jelinek <jakub@redhat.com>
5077 * elf32-i386.c (elf_i386_relocate_section) [R_386_TLS_TPOFF32]: Negate
5080 2002-09-17 Alan Modra <amodra@bigpond.net.au>
5082 * elf64-alpha.c (alpha_elf_size_info): Make static.
5084 2002-09-17 Svein E. Seldal <Svein.Seldal@solidas.com>
5086 * coff-tic4x.c: Add function declarations and ATTRIBUTE_UNUSED.
5087 * cpu-tic4x.c: Ditto.
5089 2002-09-17 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
5091 * elf64-mips.c (define elf_backend_ignore_discarded_relocs): Remove
5094 2002-09-16 Bruno Haible <bruno@clisp.org>
5096 * elf32-i386.c: Don't defined ELF_ARCH etc. if this file is included
5097 by a target variant implementation.
5098 * elf64-alpha.c: Likewise.
5099 * elf32-i386-fbsd.c: New file.
5100 * elf64-alpha-fbsd.c: New file.
5101 * targets.c: Support bfd_elf32_i386_freebsd_vec and
5102 bfd_elf64_alpha_freebsd_vec.
5103 * configure.in: Accept the vectors bfd_elf32_i386_freebsd_vec,
5104 bfd_elf64_alpha_freebsd_vec.
5105 * Makefile.am (BFD32_BACKENDS): Add elf32-i386-fbsd.lo.
5106 (BFD32_BACKENDS_CFILES): Add elf32-i386-fbsd.c.
5107 (BFD64_BACKENDS): Add elf64-alpha-fbsd.lo.
5108 (BFD64_BACKENDS_CFILES): Add elf64-alpha-fbsd.c.
5109 (elf32-i386-fbsd.lo, elf64-alpha-fbsd.lo): Add dependencies.
5110 * config.bfd: For FreeBSD targets, set targ_defvec to a FreeBSD
5111 specific targets. Define OLD_FREEBSD_ABI_LABEL if appropriate.
5113 2002-09-12 Jakub Jelinek <jakub@redhat.com>
5115 * elf32-i386.c (dtpoff_base, tpoff): Don't crash if tls_segment is
5117 (elf_i386_relocate_section): Return false after printing error about
5118 unresolvable relocation.
5120 2002-09-12 Nick Clifton <nickc@redhat.com>
5122 * elf32-arm.h (elf32_arm_final_link_relocate): Fix handling of
5125 2002-09-11 Jeffrey Law <law@redhat.com>
5127 * elf32-h8300.c (elf32_h8_relax_section): Fix typo.
5129 2002-09-11 Andrew Haley <aph@cambridge.redhat.com>
5131 * elf.c (_bfd_elf_find_nearest_line): Check functionname_ptr and
5132 line_ptr before deciding we've found a symbol.
5134 2002-09-11 Nick Clifton <nickc@redhat.com>
5136 * po/da.po: New Danish translation file.
5137 * configure.in (LINGUAS): Add 'da'.
5138 * configure: Regenerate.
5140 2002-09-10 Michael Snyder <msnyder@redhat.com>
5142 * irix-core.c (do_sections, do_sections64): New functions.
5143 (irix_core_core_file_p): Call new functions do_sections,
5144 do_sections64, depending on corefile (32-bit or 64-bit).
5146 2002-09-09 Richard Henderson <rth@redhat.com>
5148 * elfxx-ia64.c (elfNN_ia64_relax_section): Handle PCREL21M
5149 and PCREL21F like PCREL21B.
5151 2002-09-04 Kevin Buettner <kevinb@redhat.com>
5153 * config.bfd (mips*-*-irix6*): Add new ABI vectors. Make n32 default
5156 2002-09-02 Nick Clifton <nickc@redhat.com>
5158 * elf32-v850.c (v850_elf_final_link_relocate): Use helpful
5159 names instead of cryptically overloaded bfd_reloc error
5161 (v850_elf_relocate_section): Likewise.
5162 (v850_elf_relax_section): Replace caching of external symbols
5163 with caching of internal symbols obtained from calling
5164 bfd_elf_get_elf_syms().
5165 Fixup problems with freeing cached allocated memory blocks.
5167 2002-09-02 Alan Modra <amodra@bigpond.net.au>
5169 * cpu-pj.c (scan_mach, compatible, arch_info_struct): Remove.
5170 (bfd_pj_arch): Use bfd_default_scan.
5171 * cpu-v850.c (scan): Remove.
5172 (N): Use bfd_default_scan.
5173 * cpu-z8k.c (scan_mach): Remove.
5174 (arch_info_struct, bfd_z8k_arch): Reorganize so that the default is
5175 first. Use bfd_default_scan.
5177 * ecoff.c (_bfd_ecoff_set_arch_mach_hook): Don't use hard-coded
5179 (ecoff_get_magic): Likewise.
5180 * elf32-v850.c (v850_elf_object_p): Likewise.
5181 (v850_elf_final_write_processing): Likewise.
5182 * mipsbsd.c (MY(set_arch_mach)): Likewise.
5183 (MY(write_object_contents)): Likewise.
5184 * coff64-rs6000.c (xcoff64_write_object_contents): Likewise.
5185 * coffcode.h (coff_write_object_contents): Likewise.
5186 (coff_set_arch_mach_hook): Add comment describing machine == 0.
5187 Remove unnecessary "machine" assignments.
5188 (coff_write_relocs): Test for the absolute section sym by testing
5191 * aoutx.h (NAME(aout,machine_type)): Recognize bfd_mach_i386_i386
5192 and bfd_mach_i386_i386_intel_syntax.
5193 * pdp11.c (NAME(aout,machine_type)): Likewise.
5195 2002-08-30 John David Anglin <dave@hiauly1.hia.nrc.ca>
5197 * bfd-in.h (align_power): Cast constants to bfd_vma type.
5198 * bfd-in2.h (align_power): Likewise.
5200 2002-08-30 Alan Modra <amodra@bigpond.net.au>
5202 * Makefile.am: Run "make dep-am".
5203 * Makefile.in: Regenerate.
5205 * cpu-avr.c (compatible): Don't use hard-coded mach constants.
5206 * cpu-powerpc.c (powerpc_compatible): Likewise.
5207 * cpu-rs6000.c (rs6000_compatible): Likewise.
5209 2002-08-28 Catherine Moore <clm@redhat.com>
5211 * elf32-v850.c (v850_elf_reloc_map): Add new relocs.
5212 (v850-elf-reloc): Don't resolve pc relative relocs.
5213 (v850_elf_ignore_reloc): New routine.
5214 (v850_elf_final_link_relocate): Handle new relocs.
5215 (v850_elf_relax_delete_bytes ): New routine.
5216 (v850_elf_relax_section): New routine.
5217 (bfd_elf32_bfd_relax_section): Define.
5218 (HOWTO): New entries for new relocs.
5219 * reloc.c (BFD_RELOC_V850_LONGCALL): New reloc.
5220 (BFD_RELOC_V850_LONGJUMP): New reloc.
5221 (BFD_RELOC_V850_ALIGN): New reloc.
5222 * archures.c: Remove redundant v850ea architecture.
5223 * cpu-v850.c: Remove redundant v850ea support.
5224 * libbfd.h: Regenerate.
5225 * bfd-in2.h: Regenerated.
5227 2002-08-28 Svein E. Seldal <Svein.Seldal@solidas.com>
5229 * config.bfd: Add tic4x-*-*coff* and c4x-*-*coff* target.
5230 * configure.in: Add tic4x_coff vector files.
5231 * configure: Regenerate.
5232 * Makefile.am: Add tic4x target.
5233 * Makefile.in: Regenerate.
5235 2002-08-27 Michael Hayes <m.hayes@elec.canterbury.ac.nz>
5237 * archures.c: Add the BFD arch type tic4x.
5238 * bfd-in.h: Add BFD_IN_MEMORY flag.
5239 * coff-tic4x.c: New file.
5240 * coffswap.h (coff_swap_sym_out): Add preadjuster.
5241 * cpu-tic4x.c: New file.
5242 * targets.c: Added tic4x- in list of xvecs.
5243 * ticoff.h: New file.
5244 * bfd-in2.h: Regenerate.
5246 2002-08-27 Adam Nemet <anemet@lnxw.com>
5248 * elf32-arm.h (elf32_arm_finish_dynamic_sections): Set the last
5249 bit of DT_INIT and DT_FINI for Thumb functions.
5251 2002-08-26 Alan Modra <amodra@bigpond.net.au>
5253 * coffcode.h (coff_set_arch_mach_hook): Handle W65MAGIC.
5255 2002-08-26 Alan Modra <amodra@bigpond.net.au>
5257 * aoutx.h (NAME(aout,reloc_type_lookup)): Handle BFD_RELOC_8.
5259 2002-08-24 Kaz Kojima <kkojima@rr.iij4u.or.jp>
5261 * elf32-sh.c (sh_elf_copy_indirect_symbol): New.
5262 (create_got_section, allocate_dynrelocs, readonly_dynrelocs):
5264 (struct elf_sh_pcrel_relocs_copied): Removed.
5265 (struct elf_sh_dyn_relocs): New.
5266 (struct elf_sh_link_hash_entry): Replace pcrel_relocs_copied
5267 field with dyn_relocs.
5268 (struct elf_sh_link_hash_table): Add short-cuts to get dynamic
5269 sections and sym_sec.
5270 (sh_elf_link_hash_newfunc): Clear dyn_relocs.
5271 (sh_elf_link_hash_table_create): Clear shorts-cuts and sym_sec.
5272 (sh_elf_create_dynamic_sections): Use create_got_section instead
5273 of _bfd_elf_create_got_section.
5274 (sh_elf_check_relocs): Likewise.
5275 (sh_elf_create_dynamic_sections): Use short-cuts to the dynamic
5277 (sh_elf_adjust_dynamic_symbol, sh_elf_size_dynamic_sections,
5278 sh_elf_relocate_section, sh_elf_check_relocs,
5279 sh_elf_finish_dynamic_symbol, sh_elf_finish_dynamic_sections):
5281 (sh_elf_adjust_dynamic_symbol): Handle nocopyreloc. Keep the
5282 dynamic relocations and avoiding the copy relocation when we
5283 didn't find any dynamic relocations in the section which has
5284 contents or is read-only.
5285 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
5286 (sh_elf_size_dynamic_sections): Don't reset the size of
5287 .rela.got section even if dynamic_sections_created flag is off.
5288 Don't use sh_elf_discard_copies. Scan all input bfd and use
5289 allocate_dynrelocs. Call readonly_dynrelocs to determine
5290 whether we need DT_TEXTREL.
5291 (sh_elf_adjust_dynamic_symbol): Use plt.refcount to determine
5292 whether the symbol was never referred to.
5293 (sh_elf_relocate_section): Use WILL_CALL_FINISH_DYNAMIC_SYMBOL.
5294 (sh_elf_gc_sweep_hook): Fill with the real sweep function.
5295 (sh_elf_check_relocs): Call create_got_section if the short-cut
5296 to .got is null. Increment reference counters only instead of
5297 allocating space on dynamic sections here. Don't conditionalize
5298 uninitialized got.offset value when marking the symbol as a
5299 global offset table entry. Keep relocations for symbols satisfied
5300 by a dynamic library to avoid copy relocations for the symbol.
5301 Set dynobj field of an elf hash table if needed.
5302 (sh_elf_finish_dynamic_sections): Handle null section pointer
5304 (elf_backend_copy_indirect_symbol): Defined.
5305 (elf_backend_can_refcount): Defined.
5307 2002-08-23 Nick Clifton <nickc@redhat.com>
5309 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Undo
5310 previous change. Add comment explaining why.
5312 2002-08-23 Stephen Clarke <stephen.clarke@superh.com>
5314 * elf32-sh.c (elf_sh_plt0_entry_be, elf_sh_plt0_entry_le): Copy
5315 contents of .got.plt[2] to tr0, not address of .got.plt.
5316 (sh_elf_finish_dynamic_symbol): Do not apply GOT_BIAS when
5317 patching absolute plt entry. For shmedia plt entry, set bottom bit
5318 of branch to plt0 as this is a branch to an shmedia instruction.
5319 * elf64-sh64.c (elf_sh64_plt0_entry_be, elf_sh64_plt0_entry_le):
5320 Copy contents of .got.plt[2] to tr0, not address of .got.plt.
5321 (elf_sh64_plt_entry_be, elf_sh64_plt_entry_le): Use ptrel to
5323 (sh64_elf64_finish_dynamic_symbol): Do not apply GOT_BIAS when
5324 patching absolute plt entry. For shmedia plt entry, branch to
5325 plt0 is now ptrel, so use relative offset. Set bottom bit of
5326 branch target as it is a branch to an shmedia instruction.
5328 2002-08-23 Stephen Clarke <stephen.clarke@superh.com>,
5329 Richard Shann <richard.shann@superh.com>
5331 * elf32-sh.c (sh_elf_finish_dynamic_sections): Set LSB of DT_INIT
5332 value if .init is an SHmedia function. Similarly for DT_FINI.
5333 * elf64-sh64.c (sh64_elf64_finish_dynamic_sections): Likewise.
5335 2002-08-23 Stephen Clarke <stephen.clarke@superh.com>
5337 * elf32-sh.c (sh_elf_size_dynamic_sections): Zero initialize
5339 * elf64-sh64.c (sh64_elf64_size_dynamic_sections): Likewise.
5341 2002-08-22 Kaz Kojima <kkojima@rr.iij4u.or.jp>
5343 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Use a simple
5344 byte read when reading the return address register column.
5346 2002-08-22 Nick Clifton <nickc@redhat.com>
5348 * config.bfd: Add powepc64-*-*bsd* target.
5350 2002-08-22 Graeme Peterson <gp@qnx.com>
5352 * Makefile.am: Add entries for elf32-shqnx.c
5353 * Makefile.in: Regenerate.
5354 * config.bfd: Add support sh-*-nto* target.
5355 * configure.in: Add support for bfd_elf32_sh{l}qnx_vec.
5356 * configure: Regenerate.
5357 * elf32-qnx.h: Changed typo "elf_i386qnx_*" to "elf_qnx_*" .
5358 * elf32-sh.c: Do not include elf32-target.h if
5359 ELF32_SH_C_INCLUDED is defined.
5360 * elf32-shqnx.c: New file: Support for QNX.
5361 * targets.c: Add bfd_elf32_sh{l}qnx_vec.
5363 2002-08-22 Nick Clifton <nickc@redhat.com>
5365 * po/tr.po: Updated Turkish translation.
5367 * syms.c (_bfd_generic_read_minisymbols): Set bfd_error if the
5368 symbols are not read.
5370 2002-08-22 Alan Modra <amodra@bigpond.net.au>
5372 * elf32-m68hc11.c: Formatting fixes.
5373 (elf32_m68hc11_gc_mark_hook): Correct params. Remove unnecessary test.
5374 * elf32-m68hc12.c: Formatting fixes.
5375 (elf32_m68hc11_gc_mark_hook): Correct params. Remove unnecessary test.
5377 2002-08-22 Alan Modra <amodra@bigpond.net.au>
5379 * coff-rs6000.c (rs6000coff_vec <object_flags>): Add SEC_CODE and
5381 (pmac_xcoff_vec): Likewise.
5382 * coff64-rs6000.c (rs6000coff64_vec): Likewise.
5383 (aix5coff64_vec): Likewise.
5385 2002-08-22 Alan Modra <amodra@bigpond.net.au>
5387 * elf-bfd.h (struct elf_backend_data): Add struct elf_backend_data
5388 param to elf_backend_copy_indirect_symbol.
5389 (_bfd_elf_link_hash_copy_indirect): Likewise.
5390 * elflink.h (elf_add_default_symbol, elf_fix_symbol_flags): Adjust
5391 calls to copy_indirect_symbol.
5392 * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Likewise.
5393 * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
5394 * elf32-s390.c (elf_s390_copy_indirect_symbol): Likewise.
5395 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
5396 * elf64-s390.c (elf_s390_copy_indirect_symbol): Likewise.
5397 * elf64-x86-64.c (elf64_x86_64_copy_indirect_symbol): Likewise.
5398 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
5399 * elfxx-mips.c (_bfd_mips_elf_copy_indirect_symbol): Likewise.
5400 * elfxx-mips.h (_bfd_mips_elf_copy_indirect_symbol): Likewise.
5401 * elf.c (_bfd_elf_link_hash_copy_indirect): Likewise. Properly
5402 test refcounts for "used" values.
5404 2002-08-21 John David Anglin <dave@hiauly1.hia.nrc.ca>
5406 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Add PARAMS to
5407 argument declaration.
5409 2002-08-19 Elena Zannoni <ezannoni@redhat.com>
5411 * archures.c (bfd_mach_ppc_e500): Added.
5412 * bfd-in2.h: Rebuilt.
5413 * cpu-powerpc.c (bfd_powerpc_archs): Added e500.
5415 2002-08-19 Alan Modra <amodra@bigpond.net.au>
5417 * elf32-m68hc12.c (elf_backend_can_gc_sections): False.
5419 2002-08-17 Andrew Cagney <ac131313@redhat.com>
5421 * elf.c (bfd_elf_get_elf_syms): Change type of `esym' to
5424 2002-08-17 Stan Cox <scox@redhat.com>
5426 * elfxx-mips.c (_bfd_mips_elf_modify_segment_map): Use the
5427 IRIX 6 segment layout for NEWABI.
5429 2002-08-16 Stephen Clarke <stephen.clarke@superh.com>
5431 * elf32-sh.c (sh_elf_gc_mark_hook): For sh64, skip indirect
5432 symbols when looking for section referred to by a relocation.
5433 * elf64-sh.c (sh_elf64_gc_mark_hook): Likewise.
5435 2002-08-15 Alan Modra <amodra@bigpond.net.au>
5437 * elf32-i370.c: Move reloc enum to include/elf/i370.h.
5439 2002-08-15 Hans-Peter Nilsson <hp@axis.com>
5441 * elf32-cris.c (elf_cris_discard_excess_program_dynamics): Add
5442 missing check for whether the symbol is referenced by DSO before
5443 unexporting it as an unneeded dynamic symbol.
5445 2002-08-14 H.J. Lu <hjl@gnu.org>
5447 * libbfd.h: Regenerate.
5449 2002-08-14 H.J. Lu <hjl@gnu.org>
5451 * config.bfd: Always add 64bit vectors to 32bit Linux/mips.
5453 2002-08-14 Stephane Carrez <stcarrez@nerim.fr>
5455 * elf32-m68hc11.c (m68hc11_relax_group): New to relax group of
5457 (m68hc11_direct_relax): New to define table of relaxable instructions.
5458 (find_relaxable_insn): New, find a relaxable insn.
5459 (compare_reloc): New to compare two relocs.
5460 (m68hc11_elf_relax_section): New, relax text sections.
5461 (m68hc11_elf_relax_delete_bytes): New, delete bytes and adjust branchs.
5462 (elf32_m68hc11_check_relocs): New function for GC support.
5463 (elf32_m68hc11_relocate_section): New function for GC support.
5464 (bfd_elf32_bfd_relax_section): Define to support linker relaxation.
5465 (elf_backend_check_relocs): Likewise.
5466 (elf_backend_relocate_section): Likewise.
5468 2002-08-13 H.J. Lu <hjl@gnu.org>
5470 * elflink.h (NAME(bfd_elf,size_dynamic_sections): Don't count
5471 definitions in shared objects when checking symbol with
5474 2002-08-13 Stephane Carrez <stcarrez@nerim.fr>
5476 * elf32-m68hc11.c (elf32_m68hc11_gc_mark_hook): New for section GC.
5477 (elf32_m68hc11_gc_sweep_hook): Likewise.
5478 (elf_backend_gc_mark_hook): Define for GC section support.
5479 (elf_backend_gc_sweep_hook): Likewise.
5480 (elf_backend_can_gc_sections): Likewise.
5482 * elf32-m68hc12.c: Likewise.
5484 2002-08-13 Stephane Carrez <stcarrez@nerim.fr>
5486 * elf32-m68hc11.c (_bfd_m68hc11_elf_print_private_bfd_data): New.
5487 (_bfd_m68hc11_elf_merge_private_bfd_data): New function.
5488 (_bfd_m68hc11_elf_set_private_flags): New function.
5489 Use them to set/check/print ELF flags specific to 68HC11.
5491 * elf32-m68hc12.c (_bfd_m68hc12_elf_print_private_bfd_data): New.
5492 (_bfd_m68hc12_elf_merge_private_bfd_data): New function.
5493 (_bfd_m68hc12_elf_set_private_flags): New function.
5494 Use them to set/check/print ELF flags specific to 68HC12.
5496 2002-08-13 Stephane Carrez <stcarrez@nerim.fr>
5498 * elf32-m68hc11.c (elf_m68hc11_howto_table): Add the new relocs;
5499 fix masks for PC-rel relocs.
5500 (m68hc11_elf_ignore_reloc): New function.
5502 * elf32-m68hc12.c (m68hc12_elf_special_reloc): New to handle specific
5503 68HC12 banked addressing relocs.
5504 (m68hc12_phys_addr): New to compute physical address of banked memory.
5505 (m68hc12_phys_page): Likewise for page.
5506 (m68hc12_addr_is_banked): New to see if address is in banked area.
5507 (elf_m68hc12_howto_table): Add new relocs and rename to xx12.
5509 2002-08-13 Stephane Carrez <stcarrez@nerim.fr>
5511 * reloc.c (BFD_RELOC_M68HC11_RL_JUMP, BFD_RELOC_M68HC11_RL_GROUP,
5512 BFD_RELOC_M68HC11_LO16, BFD_RELOC_M68HC11_PAGE,
5513 BFD_RELOC_M68HC11_24): New relocs for 68HC11/68HC12.
5514 * bfd-in2.h: Regenerate.
5516 2002-08-12 H.J. Lu <hjl@gnu.org>
5518 * elflink.h (elf_add_default_symbol): Preserve section across
5521 2002-08-09 Graeme Peterson <gp@qnx.com>
5523 * Makefile.am: Add entries for elf32-ppcqnx.c, and add
5524 elf32-qnx.h dependency to elfarmqnx-nabi.c and elf32-i386qnx.c.
5525 * Makefile.in: Regenerate.
5526 * config.bfd: Add support for powerpc{le}-*-nto targets.
5527 * configure.in: Add support for bfd_elf32_powerpc{le}qnx_vec.
5528 * configure: Regenerate.
5529 * elf32-i386qnx.c: Moved backend functions into a QNX specific
5530 common file "elf32-qnx.h", and now include that file.
5531 * elf32-qnx.h: New file: QNX specific common elf backend.
5532 * elf32-ppc.c: Do not include elf32-target.h if
5533 ELF32_PPC_C_INCLUDED is defined.
5534 * elf32-ppcqnx.c: New file: Support for QNX.
5535 * elfarmqnx-nabi.c: Include elf32-qnx.h for qnx elf backend.
5536 * targets.c: Add bfd_elf32_powerpc{le}qnx_vec.
5538 2002-08-09 Nick Clifton <nickc@redhat.com>
5540 * po/sv.po: Updated Swedish translation.
5542 2002-08-09 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
5544 * elfxx-mips.c (mips_elf_global_got_index): Avoid segfault if
5545 g->global_gotsym is NULL.
5547 2002-08-08 H.J. Lu <hjl@gnu.org>
5549 * elflink.h (elf_add_default_symbol): Don't warn if a definition
5550 overrides an indirect versioned symbol.
5552 2002-08-08 Jakub Jelinek <jakub@redhat.com>
5554 * elf32-i386.c (elf_i386_relocate_section): Fill in proper addend
5555 for R_386_TLS_TPOFF32 relocs against symndx 0.
5557 2002-08-07 H.J. Lu <hjl@gnu.org>
5559 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Check symbol
5560 with undefined version if needed.
5561 (elf_link_assign_sym_version): Match a default symbol with a
5562 version without definition. No need to hide the default
5563 definition separately.
5565 2002-08-08 Alan Modra <amodra@bigpond.net.au>
5567 * elflink.h (elf_link_output_extsym): Don't output symbols from
5568 SEC_EXCLUDE sections.
5570 * aoutx.h (aout_link_write_symbols): Correct handling of warning syms.
5572 2002-08-07 Alan Modra <amodra@bigpond.net.au>
5574 * elf64-ppc.c (edit_opd): Arrange to drop symbols for discarded .opd
5577 2002-08-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
5579 * elfxx-mips.c (mips_elf_create_dynamic_relocation): Cast signedness
5582 2002-08-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
5584 * elfxx-mips.c (ABI_64_P): Remove superfluous check.
5586 2002-08-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
5588 * elf32-mips.c (mips_reloc_map): Fix typo.
5590 2002-08-06 Alan Modra <amodra@bigpond.net.au>
5592 * xcofflink.c (xcoff_write_global_symbol): Set n_scnum for abs_section.
5594 2002-08-06 Alan Modra <amodra@bigpond.net.au>
5596 * elf64-ppc.c (ppc64_elf_howto_raw): Zero all src_mask entries.
5598 2002-08-06 Alan Modra <amodra@bigpond.net.au>
5600 * libxcoff.h: Use PARAMS on function declarations.
5601 * coff-rs6000.c (xcoff_generate_rtinit): Simplify size calc.
5602 * coff64-rs6000.c (xcoff64_generate_rtinit): Likewise.
5604 * coff-rs6000.c: (xcoff_rtype2howto): Don't place reloc address in
5606 * coff64-rs6000.c: (xcoff64_rtype2howto): Likewise.
5608 2002-08-06 Alan Modra <amodra@bigpond.net.au>
5610 * coff-rs6000.c: Formatting fixes.
5611 (xcoff_calculate_relocation): Use PARAMS in declaration.
5612 (xcoff_complain_overflow): Likewise.
5613 (xcoff_ppc_relocate_section): Use old-style function pointer call.
5614 (bfd_xcoff_backend_data): Remove useless comments.
5615 (rs6000coff_vec): Likewise.
5616 (bfd_pmac_xcoff_backend_data): Likewise.
5617 (pmac_xcoff_vec): Likewise.
5619 * coff64-rs6000.c: Formatting fixes.
5620 (xcoff64_calculate_relocation): Use PARAMS in declaration.
5621 (xcoff64_ppc_relocate_section): Use old-style function pointer call.
5622 (bfd_xcoff_backend_data): Remove useless comments.
5623 (rs6000coff64_vec): Likewise.
5624 (bfd_xcoff_aix5_backend_data): Likewise.
5625 (aix5coff64_vec): Likewise.
5627 2002-08-06 Alan Modra <amodra@bigpond.net.au>
5629 * coff-rs6000.c (xcoff_howto_table): Revert some of last change to
5630 mask entries. Use complain_overflow_dont for R_REF.
5631 (xcoff_reloc_type_ba): Revert last change.
5632 (xcoff_reloc_type_br): Likewise.
5633 (xcoff_reloc_type_crel): Likewise.
5634 (xcoff_ppc_relocate_section): Likewise.
5635 * coff64-rs6000.c (xcoff64_reloc_type_br): Likewise.
5636 (xcoff64_ppc_relocate_section): Likewise.
5637 (xcoff64_howto_table): Revert some of last change to mask entries.
5638 Use complain_overflow_dont for R_REF.
5640 * coff-rs6000.c (xcoff_howto_table): Fix src_mask entries. Make all
5641 relocs with bitsize == 16 have size = 1.
5642 (xcoff_reloc_type_ba): Correct src_mask and dst_mask adjustment.
5643 (xcoff_reloc_type_br): Likewise.
5644 (xcoff_reloc_type_crel): Likewise.
5645 (xcoff_ppc_relocate_section): Set up src_mask and dst_mask correctly.
5646 * coff64-rs6000.c (xcoff64_reloc_type_br): Correct src_mask and
5647 dst_mask adjustment.
5648 (xcoff64_ppc_relocate_section): Set up src_mask and dst_mask correctly.
5649 (xcoff64_howto_table): Fix src_mask entries. Make all relocs with
5650 bitsize == 16 have size = 1.
5652 2002-08-01 Denis Chertykov <denisc@overta.ru>
5654 * elf32-ip2k.c: Processor manufacturer changed to Ubicom.
5655 (struct misc): New field isymbuf. All free_* fields removed.
5656 (symbol_value): Pass in internal syms. No need to swap syms in.
5657 (ip2k_elf_relax_section): Use bfd_elf_get_elf_syms. Properly free
5658 possibly cached info.
5659 (tidyup_after_error): Removed.
5660 (ip2k_elf_relax_section_pass1): Don't use removed fields of struct
5661 misc. Use new field.
5662 (adjust_all_relocations): Use internal syms. No need to swap syms
5664 (add_page_insn): Don't use removed fields of struct misc.
5666 2002-08-01 Nick Clifton <nickc@redhat.com>
5668 * elf32-arm.h: Revert previous delta.
5670 2002-08-01 Nick Clifton <nickc@redhat.com>
5672 * configure.in (AM_INIT_AUTOMAKE): Bump version number.
5673 * configure: Regenerate.
5675 2002-07-31 H.J. Lu <hjl@gnu.org>
5677 * config.bfd: Add x86-64 vector to Linux/i386 if 64bit BFD is
5680 2002-07-31 H.J. Lu <hjl@gnu.org>
5682 * config.bfd: Add n32 vectors to 32bit Linux/mips if 64bit BFD
5685 2002-07-31 Jakub Jelinek <jakub@redhat.com>
5687 * elf32-i386.c (elf_i386_copy_indirect_symbol): Swap tls_type
5688 if _bfd_elf_link_hash_copy_indirect will swap got.refcount.
5690 2002-07-31 Ian Dall <ian@sibyl.beware.dropbear.id.au>
5692 * cpu-ns32k.c (_bfd_ns32k_put_immdeiate, _bfd_ns32k_get_immediate):
5693 There is no 8 byte relocation type for this architecture.
5694 (do_ns32k_reloc): Use bfd_vma instead of native types.
5695 (bfd_ns32k_put_immediate, _bfd_ns32k_relocate_contents) put_data
5697 (_bfd_ns32k_put_displacement): Don't check for overflow. We can
5698 rely on generic code to do that.
5699 * aout-ns32k.c (howto_table): Add appropriate overflow detection
5700 to all table entries.
5701 (_bfd_ns32k_relocate_contents): put_data returns void.
5702 * ns32k.h: (_bfd_ns32k_put_displacement, _bfd_ns32k_put_immediate)
5703 (_bfd_do_ns32k_reloc_contents): Fix prototypes. put data functions
5706 2002-07-31 Ian Dall <ian@sibyl.beware.dropbear.id.au>
5708 * aoutx.h (aout_link_check_ar_symbols): Whether to include an
5709 archive object is target dependant.
5711 2002-07-31 Adam Nemet <anemet@lnxw.com>
5713 * elf32-arm.h (ARM_PLT_ENTRY_SIZE): Rename PLT_ENTRY_SIZE.
5714 (THUMB_PLT_ENTRY_SIZE): New macro.
5715 (PLT_ENTRY_SIZE): Return the appropriate *_PLT_ENTRY_SIZE.
5716 (elf32_arm_plt0_entry): Rename PLT_ENTRY_SIZE to
5718 (elf32_arm_plt_entry): Likewise.
5719 (elf_backend_plt_header_size): Likewise.
5720 (elf32_thumb_plt0_entry): New global.
5721 (elf32_arm_finish_dynamic_sections): Use it. Put Thumb entries
5723 (elf32_thumb_plt_entry): New global.
5724 (elf32_arm_finish_dynamic_symbol): Use it. Use .thumb.plt for
5725 Thumb entries. Set the bottom bit of the corresponding GOT entry
5726 for a Thumb PLT entry.
5727 (struct elf32_arm_plt_entry_info): New structure.
5728 (struct elf32_arm_link_hash_entry, plt_info): New member of this
5730 (elf32_arm_link_hash_newfunc): Initialize new member.
5731 (elf32_arm_final_link_relocate, R_ARM_THM_PC22 case): Handle
5732 relocations against the PLT.
5733 (elf32_arm_check_relocs, case R_ARM_PLT32 case): Set
5734 first_rel_type if this is the first time we encounter the symbol.
5735 (elf32_arm_check_relocs, case R_ARM_THM_PC22 case): New case.
5736 Determine if relocation needs a PLT entry. Set first_rel_type if
5737 this is the first time we encounter the symbol
5738 (elf32_arm_adjust_dynamic_symbol): Create PLT entries for Thumb
5740 (elf32_arm_size_dynamic_sections): Handle .plt.thumb like .plt.
5741 (elf32_arm_create_dynamic_sections): New function. Create the
5743 (elf_backend_create_dynamic_sections): Call it.
5745 2002-07-31 Nick Clifton <nickc@redhat.com>
5747 * bfd.c (bfd_alt_mach_code): Rename parameter 'index' to
5748 'alternative' in order to avoid shadowing global symbol of the
5750 * bfd-in2.h: Regenerate.
5751 * libbfd.h: Regenerate.
5752 * libcoff.h: Regenerate.
5754 2002-07-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
5756 * Makefile.am: Add n32 ABI support.
5757 * Makefile.in: Regenerate.
5758 * config.bfd: Add n32 vectors to mips64*-*-linux* targets. Treat 64
5759 bit vectors for mips*-*-linux targets as optional.
5760 * configure.in: Add n32 ABI vectors.
5761 * configure: Regenerate.
5762 * elf32-mips.c (mips_elf32_object_p): Reject n32 ABI files.
5763 * elfn32-mips.c: New file, n32 ABI support.
5764 * targets.c: Add n32 ABI vectors.
5766 2002-07-30 Graeme Peterson <gp@qnx.com>
5768 * elfarmqnx-nabi.c: New file: Support for QNX.
5769 * config.bfd: Add support for arm-*-nto target.
5770 * configure.in: Add support for bfd_elf32_{big|little}armqnx_vec.
5771 * configure: Regenerate.
5772 * Makefile.am: Add entries for elfarmqnx-nabi.c.
5773 * Makefile.in: Regenerate.
5774 * elf32-arm.h (ELF_MAXPAGESIZE): Do not define if already defined.
5775 Do not define global function if ELFARM_NABI_C_INCLUDED is defined.
5776 * elfarm-nabi.c: Do not include elf32-arm.h if
5777 ELFARM_NABI_C_INCLUDED is defined.
5778 * targets.c: Add bfd_elf32_{big|little}armqnx_vec.
5780 2002-07-30 Nick Clifton <nickc@redhat.com>
5782 * po/sv.po: Updated Swedish translation.
5784 2002-07-30 Jakub Jelinek <jakub@redhat.com>
5786 * elf.c (elf_fake_sections): Fix up .tbss sh_size and sh_type.
5788 2002-07-30 Alan Modra <amodra@bigpond.net.au>
5790 * aoutx.h (some_aout_object_p): Clean up tdata properly on error.
5791 * archive.c (bfd_generic_archive_p): Likewise.
5792 * coff-rs6000.c (_bfd_xcoff_archive_p): Likewise.
5793 (_bfd_xcoff_archive_p): Use bfd_scan_vma in place of strtol.
5794 * coff64-rs6000.c (xcoff64_slurp_armap): Likewise.
5795 (xcoff64_archive_p): Likewise.
5796 (xcoff64_openr_next_archived_file): Likewise.
5797 (xcoff64_archive_p): Clean up tdata properly on error.
5798 * coffgen.c (coff_real_object_p): Likewise.
5799 (coff_object_p): Release filehdr and opthdr.
5800 * ecoff.c (_bfd_ecoff_archive_p): Clean up tdata properly on error.
5801 * ieee.c (ieee_archive_p): Likewise.
5802 * ihex.c (ihex_object_p): Likewise.
5803 (ihex_mkobject): Always allocate tdata.
5804 * peicode.h (pe_ILF_object_p): Release bfd_alloc'd buffer on error.
5805 * srec.c (srec_mkobject): Always allocate tdata.
5806 (srec_object_p): Clean up tdata properly on error.
5807 (symbolsrec_object_p): Likewise.
5808 * versados.c (versados_object_p): Likewise.
5809 * vms-misc.c (_bfd_vms_get_record): Use bfd_malloc instead of malloc,
5810 and bfd_realloc instead of realloc.
5811 (add_new_contents): Use bfd_alloc instead of bfd_malloc for sections.
5812 * vms.c (vms_initialize): Always allocate tdata. Use bfd_alloc in
5813 place of bfd_malloc, simplifying error freeing. Free hash table too.
5814 (vms_object_p): Clean up tdata on error.
5815 (vms_mkobject): Don't complain on stderr if vms_initialize fails.
5816 (vms_close_and_cleanup): Adjust for bfd_alloc use.
5818 2002-07-30 Alan Modra <amodra@bigpond.net.au>
5820 * elfxx-ia64.c (elfNN_ia64_final_write_processing): Set e_flags.
5822 2002-07-26 Chris Demetriou <cgd@broadcom.com>
5824 * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Merge ASE
5825 flags into resulting BFD.
5827 2002-07-26 Alan Modra <amodra@bigpond.net.au>
5829 From John Reiser <jreiser@BitWagon.com>
5830 * elf32-i386.c (elf_i386_link_hash_table_create): Clear
5831 tls_ldm_got.refcount.
5833 2002-07-25 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
5835 * elf64-mips.c: Update TODO comment.
5836 (mips_elf64_higher_reloc,mips_elf64_highest_reloc,
5837 mips_elf64_gprel16_reloca): Remove prototypes.
5838 (mips16_jump_reloc,mips16_gprel_reloc): Add functions.
5839 (UNUSED_RELOC): Replace by EMPTY_RELOC.
5840 (mips_elf64_howto_table_rel): Use special R_MIPS_HI16 handling. Remove
5841 wrong comments. Remove disfunctional support of R_MIPS_HIGHER and
5843 (mips_elf64_howto_table_rela): Fix handling of R_MIPS_GPREL16 and
5844 R_MIPS_GOT16. Remove wrong comments.
5845 (elf_mips16_jump_howto,elf_mips16_gprel_howto,
5846 elf_mips_gnu_vtinherit_howto,elf_mips_gnu_vtentry_howto): New, code
5848 (mips_elf64_hi16_reloc): Fix formatting.
5849 (mips_elf64_higher_reloc,mips_elf64_highest_reloc): Remove.
5850 (mips_elf64_got16_reloc): Fix formatting. Remove superfluous code.
5851 Better comment. Fall back to R_MIPS_GOT_DISP instead of abort().
5852 (mips_elf64_gprel16_reloc): Make static. Add check for
5854 (mips_elf64_gprel16_reloca): Remove.
5855 (mips_elf64_literal_reloc): New function.
5856 (mips_elf64_gprel32_reloc): Fix formatting.
5857 (mips_elf64_shift6_reloc): Fix comment. Make static.
5858 (mips16_jump_reloc,mips16_gprel_reloc): New functions, code from
5860 (elf_reloc_map,mips_reloc_map): New mapping table, similiar as in
5862 (bfd_elf64_bfd_reloc_type_lookup): Use the mapping table. Enable GNU
5863 specific relocations.
5864 (mips_elf64_rtype_to_howto): Enable GNU specific relocations.
5865 (mips_elf64_object_p): Invert logic to check for SGI-ish ABI.
5866 (ELF_MAXPAGESIZE): Add comment.
5868 2002-07-25 Nick Clifton <nickc@redhat.com>
5870 * po/sv.po: Updated Swedish translation.
5871 * po/es.po: Updated Spanish translation.
5872 * po/fr.po: Updated French translation.
5874 2002-07-25 Alan Modra <amodra@bigpond.net.au>
5876 * elf-bfd.h (_bfd_elf32_link_record_local_dynamic_symbol): Define
5877 as elf_link_record_local_dynamic_symbol.
5878 (_bfd_elf64_link_record_local_dynamic_symbol): Likewise.
5879 (elf_link_record_local_dynamic_symbol): Declare. Now returns int.
5880 * elflink.h (elf_link_record_local_dynamic_symbol): Move to..
5881 * elflink.c: .. here. Use bfd_elf_get_elf_syms. Check whether an
5882 attempt is made to record a symbol in a discarded section, and
5883 return `2' in that case.
5885 2002-07-24 Nick Clifton <nickc@redhat.com>
5887 * po/sv.po: Updated Swedish translation.
5888 * po/es.po: Updated Spanish translation.
5890 2002-07-23 Alan Modra <amodra@bigpond.net.au>
5892 * po/SRC-POTFILES.in: Regenerate.
5894 * elf-hppa.h (elf_hppa_relocate_section): If relocatable, return
5895 immediately. Remove code handling relocatable linking.
5896 * elf32-avr.c (elf32_avr_relocate_section): Likewise.
5897 * elf32-cris.c (cris_elf_relocate_section): Likewise.
5898 * elf32-fr30.c (elf32_frv_relocate_section): Likewise.
5899 * elf32-frv.c (elf32_frv_relocate_section): Likewise.
5900 * elf32-h8300.c (elf32_h8_relocate_section): Likewise.
5901 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
5902 * elf32-ip2k.c (ip2k_elf_relocate_section): Likewise.
5903 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
5904 * elf32-v850.c (v850_elf_relocate_section): Likewise.
5905 * elf32-vax.c (elf_vax_relocate_section): Likewise.
5906 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
5907 * elf32-avr.c (elf_backend_rela_normal): Define.
5908 * elf32-cris.c: Likewise.
5909 * elf32-fr30.c: Likewise.
5910 * elf32-frv.c: Likewise.
5911 * elf32-h8300.c: Likewise.
5912 * elf32-hppa.c: Likewise.
5913 * elf32-ip2k.c: Likewise.
5914 * elf32-sparc.c: Likewise.
5915 * elf32-v850.c: Likewise.
5916 * elf32-vax.c: Likewise.
5917 * elf64-hppa.c: Likewise.
5918 * elf64-sparc.c: Likewise.
5919 * elf32-fr30.c (elf32_frv_relocate_section): Edit comment.
5920 * elf32-frv.c (elf32_frv_relocate_section): Likewise.
5921 * elf32-i860.c (elf32_i860_relocate_section): Likewise.
5922 * elf32-ip2k.c (ip2k_elf_relocate_section): Likewise.
5923 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
5924 * elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
5925 * elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
5926 * elf-m10200.c (USE_RELA): Don't define.
5927 * elf-m10300.c: Likewise.
5928 * elfarm-oabi.c: Likewise.
5929 * elf32-i370.c: Likewise.
5930 * elf32-ip2k.c: Likewise.
5931 * elf32-m68k.c: Likewise.
5932 * elf32-mcore.c: Likewise.
5933 * elf32-ppc.c: Likewise.
5934 * elf32-s390.c: Likewise.
5935 * elf32-vax.c: Likewise.
5936 * elf64-ppc.c: Likewise.
5937 * elf64-s390.c: Likewise.
5938 * elf64-x86-64.c: Likewise.
5939 * elfxx-ia64.c: Likewise.
5940 * elf32-avr.c (USE_REL): Don't undef.
5941 * elf32-ip2k.c: Likewise.
5943 2002-07-23 Nick Clifton <nickc@redhat.com>
5945 * elf-bfd.h (struct elf_backend_data): Add new bitfield
5946 'want_p_paddr_set_to_zero'.
5947 * elfxx-target.h: Set default value for want_p_paddr_set_to_zero
5949 * elfxx-ia64.c: Set want_p_paddr_set_zero for HPUX target.
5950 * elf.c (copy_private_bfd_data): Test want_p_paddr_set_zero.
5952 2002-07-23 Gabor Keresztfalvi <keresztg@mail.com>
5954 * nlmcode.h (nlm_swap_auxiliary_headers_out): Swapped the order of
5955 the MeSsAgEs and CoPyRiGhT tags to make >=NW4.x NLM loaders to
5956 show the Copyright string.
5957 Minor formatting tidy ups.
5959 2002-07-23 Nick Clifton <nickc@redhat.com>
5961 * po/fr.po: Updated French translation.
5962 * po/sv.po: Updated Swedish translation.
5964 2002-07-23 Alan Modra <amodra@bigpond.net.au>
5966 * elflink.h (elf_link_input_bfd): Don't change internal symbols
5967 when outputting relocs.
5969 2002-07-20 Jason Thorpe <thorpej@wasabisystems.com>
5971 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Only insert
5972 DT_PLTGOT into the dynamic section if there is a PLT.
5974 2002-07-19 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
5976 * elfxx-mips.c (_bfd_mips_elf_discard_info): New function, code from
5978 (_bfd_mips_elf_write_section): Likewise.
5979 * elfxx-mips.h (_bfd_mips_elf_discard_info): New prototype.
5980 (_bfd_mips_elf_write_section): Likewise.
5981 * elf32-mips.c (elf32_mips_discard_info): Move to elfxx-mips.c.
5982 (elf32_mips_write_section): Likewise.
5983 * elf64-mips.c (_bfd_mips_elf_ignore_discarded_relocs): Use it.
5984 (_bfd_mips_elf_write_section): Likewise.
5986 2002-07-19 Alan Modra <amodra@bigpond.net.au>
5988 * elfxx-ia64.c: (elfNN_ia64_modify_segment_map): Properly scan
5989 PT_IA_64_UNWIND segments for a given section.
5991 2002-07-17 H.J. Lu <hjl@gnu.org>
5993 * Makefile.am: Fix a typo.
5994 * Makefile.in: Regenerate.
5996 2002-07-15 Denis Chertykov <denisc@overta.ru>
5997 Frank Ch. Eigler <fche@redhat.com>
5998 Ben Elliston <bje@redhat.com>
5999 Alan Lehotsky <alehotsky@cygnus.com>
6000 John Healy <jhealy@redhat.com>
6001 Graham Stott <grahams@redhat.com>
6002 Jeff Johnston <jjohnstn@redhat.com>
6004 * Makefile.am: Add support for ip2k.
6005 * Makefile.in: Regenerate.
6006 * doc/Makefile.in: Regenerate.
6007 * archures.c: Add support for ip2k.
6008 * config.bfd: Add support for ip2k.
6009 * configure.in: Add support for ip2k.
6010 * configure: Regenerate.
6011 * reloc.c: Add support for ip2k.
6012 * targets.c: Add support for ip2k.
6013 * bfd-in2.h: Regenerate.
6014 * libbfd.h: Regenerate.
6015 * cpu-ip2k.c: New file.
6016 * elf32-ip2k.c: New file.
6018 2002-07-17 Ian Rickards <irickard@arm.com>
6020 * dwarf2.c (concat_filename): If we can't establish the directory
6021 just return the filename.
6023 2002-07-16 Moritz Jodeit <moritz@jodeit.org>
6025 * peXXigen.c (_bfd_XXi_swap_aouthdr_out): Correct order of memset args.
6027 2002-07-16 Alan Modra <amodra@bigpond.net.au>
6029 * elflink.h: Formatting fixes, tidy prototypes.
6030 (elf_link_assign_sym_version): Move common code out of loop.
6032 2002-07-16 Alan Modra <amodra@bigpond.net.au>
6034 * elflink.h (elf_link_input_bfd): Don't call reloc_emitter when
6035 reloc section size is zero. Correct reloc output location.
6037 2002-07-16 John David Anglin <dave@hiauly1.hia.nrc.ca>
6039 * elf-hppa.h (elf_hppa_reloc_final_type): Use R_PARISC_PCREL16F as
6040 the final type for the e_fsel selector when generating PA2.0W code.
6041 (elf_hppa_relocate_insn): Provide support for PA2.0W 16-bit format 1
6044 2002-07-14 H.J. Lu <hjl@gnu.org>
6046 * elflink.h (elf_link_assign_sym_version): Hide the default
6047 definition if there is a hidden versioned definition.
6049 2002-07-12 Hans-Peter Nilsson <hp@axis.com>
6051 * elf32-cris.c (cris_elf_relocate_section): Drop nonsensical
6052 dynamic reference test in assertion when initializing GOT with
6053 static contents. Just assert that there are either no dynamic
6054 sections, the symbol is defined in the regular objects or that the
6055 symbol is undef weak. Tweak comment.
6056 (elf_cris_finish_dynamic_symbol): Emit .got reloc for a program
6057 only if the symbol isn't defined in the program and isn't undef
6059 (elf_cris_adjust_dynamic_symbol): Simplify condition for getting
6060 rid of PLT entry: only do it if the symbol isn't defined in a DSO.
6061 When doing so, clear ELF_LINK_HASH_NEEDS_PLT. Tweak comments.
6062 (elf_cris_discard_excess_program_dynamics): Don't consider
6063 ELF_LINK_HASH_REF_DYNAMIC when omitting .got runtime relocs.
6065 2002-07-11 Alan Modra <amodra@bigpond.net.au>
6067 * elf32-i386.c (elf_i386_relocate_section): Don't complain about
6068 unresolved debugging relocs in dynamic applications.
6069 * elf32-s390.c (elf_s390_relocate_section): Likewise.
6070 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
6071 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
6072 * elf64-s390.c (elf_s390_relocate_section): Likewise.
6073 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
6074 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
6076 2002-07-10 Alan Modra <amodra@bigpond.net.au>
6078 * elf64-ppc.c (ONES): Define.
6079 (ppc64_elf_howto_table): Use ONES here to avoid warnings. Fill in
6080 missing src_mask fields. Tweak R_PPC64_NONE, R_PPC64_COPY. Fill
6081 in missing dst_mask fields on R_PPC64_PLT32, R_PPC64_PLTREL32.
6083 * elf64-ppc.c (ppc64_elf_get_symbol_info): Delete.
6084 (ppc64_elf_set_private_flags): Delete.
6085 (ppc64_elf_section_from_shdr): Delete.
6086 (ppc64_elf_merge_private_bfd_data): Remove flag checking/merging code.
6087 (ppc64_elf_fake_sections): Delete.
6088 (bfd_elf64_bfd_set_private_flags): Don't define.
6089 (bfd_elf64_get_symbol_info): Likewise.
6090 (elf_backend_section_from_shdr): Likewise.
6091 (elf_backend_fake_sections): Likewise.
6093 2002-07-10 Marco Walther <Marco.Walther@sun.com>
6095 * elf.c: (assign_section_numbers) Set sh_entsize for .stab only
6096 when not already set.
6097 * elf64-sparc.c: (sparc64_elf_fake_sections): New function.
6098 (elf_backend_fake_sections): Define.
6100 2002-07-10 Alan Modra <amodra@bigpond.net.au>
6102 * merge.c (_bfd_merge_section): Remove redundant output_section check.
6104 (_bfd_merge_sections): Don't set SEC_EXCLUDE on unused sections.
6106 2002-07-09 Hans-Peter Nilsson <hp@axis.com>
6108 * elf32-cris.c (cris_elf_relocate_section): Move sanity-check for
6109 NULL sym_hashes to just before use.
6110 <case R_CRIS_32_GOTREL>: In test for local symbol, accept also
6111 symbol with non-default visibility.
6112 <case R_CRIS_32_GOTREL, case R_CRIS_32_PLT_GOTREL>: Ditto.
6113 <case R_CRIS_8_PCREL, case R_CRIS_16_PCREL, case R_CRIS_32_PCREL>:
6115 (cris_elf_gc_sweep_hook): Only decrease h->plt.refcount for
6116 symbol with non-default visibility.
6117 (cris_elf_check_relocs): At tests for local symbol before
6118 increasing h->plt.refcount, also check for non-default
6119 visibility. Ditto when checking for local symbol to eliminate
6120 pc-relative runtime relocs.
6122 2002-07-08 Alan Modra <amodra@bigpond.net.au>
6124 * elf.c: Formatting.
6125 (IS_SOLARIS_PT_INTERP): Add p_paddr and p_memsz checks.
6126 (INCLUDE_SECTION_IN_SEGMENT): Remove IS_SOLARIS_PT_INTERP.
6127 (copy_private_bfd_data): Set p_vaddr on broken Solaris PT_INTERP
6130 2002-07-07 Mark Mitchell <mark@codesourcery.com>
6131 Alan Modra <amodra@bigpond.net.au>
6133 * cofflink.c (_bfd_coff_final_link): On PE COFF systems, take into
6134 account the impact of relocation count overflow when computing
6136 * coffcode.h (coff_write_relocs): Use obj_pe when deciding whether
6137 or not to apply the PE COFF reloc overflow handling. Fix a
6138 fencepost error in deciding whether or not to use that technique.
6140 2002-07-07 Alan Modra <amodra@bigpond.net.au>
6142 * elf-bfd.h (struct elf_reloc_cookie): Remove locsym_shndx,
6143 change type of locsyms.
6144 (bfd_elf_get_elf_syms): Declare.
6145 * elf.c (bfd_elf_get_elf_syms): New function.
6146 (group_signature): Use bfd_elf_get_elf_syms.
6147 (bfd_section_from_r_symndx): Likewise.
6148 * elfcode.h (elf_slurp_symbol_table): Likewise.
6149 * elflink.h (elf_link_is_defined_archive_symbol): Likewise.
6150 (elf_link_add_object_symbols): Likewise. Reorganise to increase
6151 locality of various data structures. Properly free internal relocs.
6152 (elf_bfd_final_link): Properly free internal relocs.
6153 (elf_link_check_versioned_symbol): Use bfd_elf_get_elf_syms.
6154 (elf_link_input_bfd): Likewise.
6155 (elf_gc_mark): Likewise. Properly free internal relocs.
6156 (elf_gc_sweep): Properly free internal relocs.
6157 (elf_reloc_symbol_deleted_p): No need to swap syms in.
6158 (elf_bfd_discard_info): Use bfd_elf_get_elf_syms. Properly free
6160 * elf-m10200.c (mn10200_elf_relax_section): Use bfd_elf_get_elf_syms.
6161 Properly free possibly cached info.
6162 (mn10200_elf_relax_delete_bytes): Remove symbol swapping code.
6163 (mn10200_elf_symbol_address_p): Pass in internal syms. Remove
6164 symbol swapping code.
6165 (mn10200_elf_get_relocated_section_contents): Use bfd_elf_get_elf_syms.
6166 Properly free possibly cached info.
6167 * elf-m10300.c (mn10300_elf_relax_section): As above for elf-m10200.c.
6168 (mn10300_elf_relax_delete_bytes): Likewise.
6169 (mn10300_elf_symbol_address_p): Likewise.
6170 (mn10300_elf_get_relocated_section_contents): Likewise.
6171 * elf32-h8300.c (elf32_h8_relax_section): As above for elf-m10200.c.
6172 (elf32_h8_relax_delete_bytes): Likewise.
6173 (elf32_h8_symbol_address_p): Likewise.
6174 (elf32_h8_get_relocated_section_contents): Likewise.
6175 * elf32-m32r.c (m32r_elf_relax_section): As above for elf-m10200.c.
6176 (m32r_elf_relax_delete_bytes): Likewise.
6177 (m32r_elf_get_relocated_section_contents): Likewise.
6178 * elf32-sh.c (sh_elf_reloc_loop): Free section contents using
6179 elf_section_data to determine whether cached.
6180 (sh_elf_relax_section): As above for elf-m10200.c.
6181 (sh_elf_relax_delete_bytes): Likewise.
6182 (sh_elf_get_relocated_section_contents): Likewise.
6183 * elf32-xstormy16.c (xstormy16_elf_relax_section): As above.
6184 * elf64-alpha.c (elf64_alpha_relax_section): As above. Also delay
6185 reading of local syms.
6186 * elf64-mmix.c (mmix_elf_relax_section): Likewise.
6187 * elf64-sh64.c (sh_elf64_get_relocated_section_contents): As above.
6188 * elfxx-ia64.c (elfNN_ia64_relax_section): As above.
6189 * elfxx-mips.c (_bfd_mips_elf_check_relocs): Properly free internal
6191 * elf32-arm.h (bfd_elf32_arm_process_before_allocation): Properly
6192 free internal relocs and section contents. Don't read symbols.
6193 * elf32-hppa.c (get_local_syms): Use bfd_elf_get_elf_syms.
6194 (elf32_hppa_size_stubs): Don't free local syms.
6195 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Delay
6196 reading of local syms. Use bfd_elf_get_elf_syms. Properly free
6197 possibly cached info.
6198 * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): Likewise.
6199 * elf64-hppa.c (elf64_hppa_check_relocs): Use bfd_elf_get_elf_syms.
6200 * elf64-ppc.c (struct ppc_link_hash_table): Delete bfd_count and
6202 (get_local_syms): Delete function.
6203 (edit_opd): Use bfd_elf_get_elf_syms. Free on error exit. Cache
6205 (ppc64_elf_size_stubs): Use bfd_elf_get_elf_syms. Free/cache on exit.
6207 2002-07-05 Jim Wilson <wilson@redhat.com>
6209 * syms.c (decode_section_type): New.
6210 (bfd_decode_symclass): Call decode_section_type.
6212 2002-07-04 Jakub Jelinek <jakub@redhat.com>
6214 * merge.c (_bfd_merged_section_offset): Avoid accessing byte before
6215 section content start.
6216 Reported by Michael Schumacher <mike@hightec-rt.com>.
6218 2002-07-04 Alan Modra <amodra@bigpond.net.au>
6220 * section.c (_bfd_strip_section_from_output): Remove unnecessary
6221 link order code. Don't actually remove the output section here;
6222 Just set a flag for the linker to do so.
6223 * elflink.c (_bfd_elf_link_renumber_dynsyms): Test for removed
6224 sections when setting up output section dynsyms.
6226 2002-07-04 Alan Modra <amodra@bigpond.net.au>
6228 * elflink.h (elf_link_add_object_symbols): Revert 1999-09-02 hpux
6230 * elf.c (bfd_section_from_shdr): Work around broken hpux shared
6233 2002-07-02 Martin Schwidefsky <schwidefsky@de.ibm.com>
6235 * elf64-s390.c (create_got_section): Set .got section alignment to
6237 (elf_s390_check_relocs): Set .rela.dyn section alignment to 8 bytes.
6239 2002-07-02 Alan Modra <amodra@bigpond.net.au>
6241 * elf.c (_bfd_elf_reloc_type_class): Fix comment grammar.
6243 2002-07-01 Matt Thomas <matt@3am-software.com>
6245 * elf32-vax.c (elf32_vax_print_private_bfd_data): Change EF_*
6248 2002-07-01 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
6250 * elfxx-mips.c (ABI_64_P): Fix comment.
6251 (MIPS_ELF_OPTIONS_SECTION_NAME,MIPS_ELF_STUB_SECTION_NAME): Use the
6252 new section names for N64 ABI.
6253 (mips_elf_output_extsym): No special _gp_disp handling for NewABI.
6254 (mips_elf_calculate_relocation): Code formatting.
6255 (mips_elf_create_dynamic_relocation): Likewise.
6256 (_bfd_mips_elf_fake_sections): IRIX6 needs this hack, too.
6257 (_bfd_mips_elf_size_dynamic_sections): Handle GOT_PAGE for any NewABI.
6258 (_bfd_mips_elf_relocate_section): No special handling for R_MIPS_64
6260 (_bfd_mips_elf_finish_dynamic_symbol): No special _gp_disp handling
6262 (_bfd_mips_elf_modify_segment_map): Handle any N64 ABI.
6263 (_bfd_mips_elf_gc_sweep_hook): NewABI GOT relocs should be handled
6266 2002-07-01 Andreas Schwab <schwab@suse.de>
6268 * elf64-x86-64.c (elf64_x86_64_relocate_section): Only convert
6269 R_X86_64_64 to R_X86_64_RELATIVE.
6271 2002-07-01 John David Anglin <dave@hiauly1.hia.nrc.ca>
6273 * vaxbsd.c: New BFD backend for VAX BSD and Ultrix.
6274 * Makefile.am (BFD32_BACKENDS, BFD32_BACKENDS_CFILES): Add new backend.
6276 * config.bfd (vax-*-bsd* | vax-*-ultrix*): Use vaxbsd_vec instead of
6278 * configure.in (vaxbsd_vec): Add.
6279 * targets.c (vaxbsd_vec): Add.
6280 * Makefile.in: Rebuild.
6281 * configure: Rebuild.
6282 * po/SRC-POTFILES.in: Rebuild.
6284 2002-07-01 Alan Modra <amodra@bigpond.net.au>
6286 * elflink.h (elf_gc_mark): Pass in the section whose relocs we are
6287 examining to gc_mark_hook, rather than the bfd.
6288 (elf_gc_sections): Adjust.
6289 * elf-bfd.h (struct elf_backend_data <gc_mark_hook>): Likewise.
6290 * elf-m10300.c (mn10300_elf_gc_mark_hook): Likewise.
6291 * elf32-arm.h (elf32_arm_gc_mark_hook): Likewise.
6292 * elf32-avr.c (elf32_avr_gc_mark_hook): Likewise.
6293 * elf32-cris.c (cris_elf_gc_mark_hook): Likewise.
6294 * elf32-d10v.c (elf32_d10v_gc_mark_hook): Likewise.
6295 * elf32-fr30.c (fr30_elf_gc_mark_hook): Likewise.
6296 * elf32-hppa.c (elf32_hppa_gc_mark_hook): Likewise.
6297 * elf32-i386.c (elf_i386_gc_mark_hook): Likewise.
6298 * elf32-m32r.c (m32r_elf_gc_mark_hook): Likewise.
6299 * elf32-m68k.c (elf_m68k_gc_mark_hook): Likewise.
6300 * elf32-mcore.c (mcore_elf_gc_mark_hook): Likewise.
6301 * elf32-openrisc.c (openrisc_elf_gc_mark_hook): Likewise.
6302 * elf32-ppc.c (ppc_elf_gc_mark_hook): Likewise.
6303 * elf32-s390.c (elf_s390_gc_mark_hook): Likewise.
6304 * elf32-sh.c (sh_elf_gc_mark_hook): Likewise.
6305 * elf32-sparc.c (elf32_sparc_gc_mark_hook): Likewise.
6306 * elf32-v850.c (v850_elf_gc_mark_hook): Likewise.
6307 * elf32-vax.c (elf_vax_gc_mark_hook): Likewise.
6308 * elf32-xstormy16.c (xstormy16_elf_gc_mark_hook): Likewise.
6309 * elf64-mmix.c (mmix_elf_gc_mark_hook): Likewise.
6310 * elf64-ppc.c (ppc64_elf_gc_mark_hook): Likewise.
6311 * elf64-s390.c (elf_s390_gc_mark_hook): Likewise.
6312 * elf64-sh64.c (sh_elf64_gc_mark_hook): Likewise.
6313 * elfxx-mips.c (_bfd_mips_elf_gc_mark_hook): Likewise.
6314 * elfxx-mips.h (_bfd_mips_elf_gc_mark_hook): Likewise.
6315 * elf64-x86-64.c (elf64_x86_64_gc_mark_hook): Likewise.
6316 * elf32-frv.c (elf32_frv_gc_mark_hook): Likewise. Also remove
6317 redundant local sym tests.
6318 * elf64-ppc.c (struct ppc_link_hash_entry): Add is_entry.
6319 (link_hash_newfunc): Init is_entry.
6320 (ppc64_elf_copy_indirect_symbol): Copy is_entry.
6321 (ppc64_elf_link_hash_table_create): Init all_local_syms.
6322 (create_linkage_sections): Use bfd_make_section_anyway rather than
6324 (ppc64_elf_mark_entry_syms): New function.
6325 (ppc64_elf_check_relocs): Don't bother testing elf_bad_symtab. Set
6326 up opd entry to function section map.
6327 (ppc64_elf_gc_mark_hook): Special case opd section relocs, and
6328 relocs that reference the opd section.
6329 (edit_opd): New function.
6330 (ppc64_elf_size_dynamic_sections): Call get_local_syms and edit_opd.
6331 (ppc64_elf_setup_section_lists): Don't calculate htab->bfd_count here.
6332 (get_local_syms): Do so here. Exit if we already have local syms.
6333 Remove bogus comment imported from elf32-hppa.c. Don't attempt to
6334 read local syms on non-ELF input.
6335 (ppc64_elf_size_stubs): Call _bfd_elf64_link_read_relocs rather
6336 than duplicating it's function here. Adjust free of internal
6338 (ppc64_elf_relocate_section): Adjust local syms in opd section.
6339 * elf64-ppc.h (ppc64_elf_mark_entry_syms): Declare.
6340 * elf32-hppa.c (elf32_hppa_size_stubs): Call
6341 _bfd_elf32_link_read_relocs rather than duplicating it's function
6342 here. Adjust free of internal relocs to suit.
6344 2002-07-01 Andreas Jaeger <aj@suse.de>
6346 * elf64-x86-64.c (elf64_x86_64_check_relocs): Certain relocations
6347 are not allowed in shared libs code, enforce -fPIC.
6349 2002-06-29 Hans-Peter Nilsson <hp@bitrange.com>
6351 * mmo.c (mmo_write_loc_chunk): Don't eliminate leading and
6352 trailing zero-sequences when there's previous left-over data.
6354 2002-06-27 John David Anglin <dave@hiauly1.hia.nrc.ca>
6356 * elf64-hppa.c (elf64_hppa_reloc_type_class): New function.
6357 (elf64_hppa_finish_dynamic_sections): Check other_rel_sec, dlt_rel_sec
6358 and opd_rel_sec in order for starting rela section. Check _raw_size.
6359 (elf_backend_reloc_type_class): Define.
6361 2002-06-27 Kevin Buettner <kevinb@redhat.com>
6363 * dwarf2.c (decode_line_info): Handle older, non-standard, 64-bit
6366 2002-06-27 Alan Modra <amodra@bigpond.net.au>
6368 * cpu-powerpc.c: Comment on ordering of arch_info.
6369 * elf32-ppc.c (ppc_elf_object_p): New function.
6370 (elf_backend_object_p): Define.
6371 * elf64-ppc.c (ppc64_elf_object_p): New function.
6372 (elf_backend_object_p): Define.
6374 2002-06-26 Jason Thorpe <thorpej@wasabisystems.com>
6376 * configure.in (vax-*-netbsd*): Set COREFILE to netbsd-core.lo.
6377 * configure: Regenerate.
6379 2002-06-25 Jason Eckhardt <jle@rice.edu>
6381 * dwarf2.c (decode_line_info): Check unit->addr_size
6382 to read in the proper number of prologue bytes.
6384 2002-06-25 Nick Clifton <nickc@cambridge.redhat.com>
6386 * config.bfd (powerpc-*-aix5*): Only create a selvecs for
6387 aix5coff64_vec if 64-bit bfd support has been enabled.
6388 (powerpc64-*-aix5*): Only define if 64-bit bfd support has
6391 * targets.c (_bfd_target_vector[]): Only include
6392 aix5coff64_vec if 64-bit bfd support has been enabled.
6394 2002-06-25 Alan Modra <amodra@bigpond.net.au>
6396 * elf64-ppc.c (ppc_add_stub): Replace strcpy/strncpy with memcpy.
6397 * elf32-hppa.c (hppa_add_stub): Likewise.
6398 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Likewise.
6399 * elflink.h (elf_add_default_symbol): Fix comment typo.
6400 (elf_add_default_symbol): Replace strcpy and strncpy with memcpy.
6401 (elf_link_add_object_symbols): Likewise.
6402 (elf_link_assign_sym_version): Likewise.
6403 * hash.c (bfd_hash_lookup): Likewise.
6404 * linker.c (_bfd_generic_link_add_one_symbol): Likewise.
6405 * section.c (bfd_get_unique_section_name): Likewise.
6406 * syms.c (_bfd_stab_section_find_nearest_line): Likewise.
6407 * elf.c (_bfd_elf_make_section_from_phdr): Likewise.
6408 (assign_section_numbers): Likewise.
6409 (_bfd_elfcore_make_pseudosection): Likewise.
6410 (elfcore_grok_lwpstatus): Likewise.
6411 (elfcore_grok_win32pstatus): Likewise.
6412 (elfcore_write_note): Constify input params. Use PTR instead of
6413 void *. Include terminating NUL in namesz. Correct padding.
6414 Support NULL "name" param. Use memcpy instead of strcpy.
6415 (elfcore_write_prpsinfo): Constify input params.
6416 (elfcore_write_prstatus): Likewise. Use PTR instead of void *.
6417 (elfcore_write_lwpstatus): Likewise.
6418 (elfcore_write_pstatus): Likewise.
6419 (elfcore_write_prfpreg): Likewise.
6420 (elfcore_write_prxfpreg): Likewise.
6421 * elf-bfd.h (elfcore_write_note): Update declaration.
6422 (elfcore_write_prpsinfo): Likewise.
6423 (elfcore_write_prstatus): Likewise.
6424 (elfcore_write_pstatus): Likewise.
6425 (elfcore_write_prfpreg): Likewise.
6426 (elfcore_write_prxfpreg): Likewise.
6427 (elfcore_write_lwpstatus): Likewise.
6429 2002-06-25 Jason Eckhardt <jle@rice.edu>
6431 * ecoff.c (ecoff_set_symbol_info): Set BSF_FUNCTION for
6432 symbols of type stProc and stStaticProc.
6434 2002-06-25 Nick Clifton <nickc@redhat.com>
6436 * ecoff.c: VArious formatting fixes.
6438 2002-06-25 Alan Modra <amodra@bigpond.net.au>
6440 * coff-rs6000.c (xcoff_generate_rtinit): Fix typo.
6442 2002-06-25 Alan Modra <amodra@bigpond.net.au>
6444 * aout-adobe.c: Don't compare against "true" or "false.
6445 * aout-target.h: Likewise.
6446 * aoutx.h: Likewise.
6447 * archive.c: Likewise.
6449 * cache.c: Likewise.
6450 * coff-a29k.c: Likewise.
6451 * coff-alpha.c: Likewise.
6452 * coff-i386.c: Likewise.
6453 * coff-mips.c: Likewise.
6454 * coff-or32.c: Likewise.
6455 * coff64-rs6000.c: Likewise.
6456 * coffcode.h: Likewise.
6457 * coffgen.c: Likewise.
6458 * cpu-ns32k.c: Likewise.
6459 * ecoff.c: Likewise.
6460 * ecofflink.c: Likewise.
6462 * elf32-arm.h: Likewise.
6463 * elf32-cris.c: Likewise.
6464 * elf32-d30v.c: Likewise.
6465 * elf32-i386.c: Likewise.
6466 * elf32-mcore.c: Likewise.
6467 * elf32-ppc.c: Likewise.
6468 * elf32-sh.c: Likewise.
6469 * elf32-sh64.c: Likewise.
6470 * elf32-v850.c: Likewise.
6471 * elf64-alpha.c: Likewise.
6472 * elf64-sh64.c: Likewise.
6473 * elfcode.h: Likewise.
6474 * elfcore.h: Likewise.
6475 * elflink.h: Likewise.
6476 * elfxx-mips.c: Likewise.
6477 * i386os9k.c: Likewise.
6479 * libbfd.c: Likewise.
6480 * linker.c: Likewise.
6482 * nlm32-alpha.c: Likewise.
6483 * nlm32-i386.c: Likewise.
6484 * nlm32-ppc.c: Likewise.
6485 * nlm32-sparc.c: Likewise.
6486 * nlmcode.h: Likewise.
6487 * oasys.c: Likewise.
6488 * pdp11.c: Likewise.
6489 * peicode.h: Likewise.
6490 * reloc.c: Likewise.
6493 * tekhex.c: Likewise.
6495 * xcofflink.c: Likewise.
6496 * elf64-sparc.c: Edit comment to not use "== false".
6498 * aoutf1.h: Don't use "? true : false".
6499 * ecoff.c: Likewise.
6500 * format.c: Likewise.
6502 * linker.c: Likewise.
6504 * oasys.c: Likewise.
6506 2002-06-23 H.J. Lu <hjl@gnu.org>
6508 * elflink.h (elf_link_add_archive_symbols): For the default
6509 version, check references with only one `@' first.
6511 2002-06-23 John David Anglin <dave@hiauly1.hia.nrc.ca>
6513 * elf64-hppa.c (elf64_hppa_mark_milli_and_exported_functions): New
6515 (allocate_global_data_dlt): Don't add millicode symbols to dynamic
6517 (allocate_global_data_opd, allocate_dynrel_entries): Likewise.
6518 (elf64_hppa_size_dynamic_sections): Revise to use
6519 elf64_hppa_mark_milli_and_exported_functions.
6520 (elf64_hppa_finish_dynamic_symbol): Remove code to keep millicode
6521 symbols out of dynamic symbol table.
6523 2002-06-23 Alan Modra <amodra@bigpond.net.au>
6525 * Makefile.in: Regenerate.
6526 * libbfd.h: Regenerate.
6527 * bfd-in2.h: Regenerate.
6528 * configure: Regenerate.
6529 * po/SRC-POTFILES.in: Regenerate.
6531 * elflink.h: Comment typo fixes.
6533 2002-06-23 H.J. Lu <hjl@gnu.org>
6535 * elf-bfd.h (elf_link_loaded_list): New structure.
6536 (elf_link_hash_table): Add "loaded".
6537 * elf.c (_bfd_elf_link_hash_table_init): Initialize "loaded".
6538 * elflink.h (elf_link_check_versioned_symbol): New function.
6539 (elf_link_output_extsym): Call elf_link_check_versioned_symbol.
6541 2002-06-19 Nick Clifton <nickc@cambridge.redhat.com>
6543 * elflink.h (size_dynamic_sections): If the target does not
6544 support an ELF style hash table, return true, indicating that
6545 nothing needed to be done, rather than false, indicating that the
6546 section's size could not be computed.
6548 2002-06-18 Dave Brolley <brolley@redhat.com>
6550 From Catherine Moore, Michael Meissner, Dave Brolley:
6551 * po/SRC-POTFILES.in: Add cpu-frv.c and elf32-frv.c
6552 * targets.c: Support bfd_elf32_frv_vec.
6553 * reloc.c: Add FRV relocs.
6554 * configure.in: Add support for bfd-elf32-frv-vec.
6555 * config.bfd (targ_cpu): Add support for frv-*-elf.
6556 * archures.c: Add frv arch and machines.
6557 * Makefile.am (ALL_MACHINES): Add cpu-frv.lo.
6558 (ALL_MACHINES_CFILES): Add cpu-frv.c.
6559 (BFD32_BACKENDS): Add elf32-frv.lo.
6560 (BFD32_BACKENDS_CFILES): Add elf32-frv.c
6561 (cpu-frv.lo): New target.
6562 (elf32-frv.lo): New target.
6563 * cpu-frv.c: New file.
6564 * elf32-frv.c: New file.
6566 2002-06-18 Jakub Jelinek <jakub@redhat.com>
6568 * elfcode.h (elf_object_p): Sanity check eh_shoff == 0 implies
6570 Only read the first section header if e_shoff is non-zero.
6571 Don't consider e_shstrndx if there are no sections.
6573 2002-06-17 Tom Rix <trix@redhat.com>
6575 * elf32-d10v.c (elf_d10v_howto_table): Change R_D10V_10_PCREL_R,
6576 R_D10V_10_PCREL_L and R_D10V_18_PCREL to use
6577 complain_overflow_bitfield.
6579 2002-06-17 Alan Modra <amodra@bigpond.net.au>
6581 * opncls.c (bfd_openr): Remove redundant bfd_set_error.
6582 (bfd_fdopenr): Likewise.
6583 (bfd_openstreamr): Likewise.
6584 (bfd_openw): Likewise.
6586 * targets.c: Sort target vecs.
6587 (_bfd_target_vector): Add aix5coff64_vec, bfd_elf32_sh64_vec,
6588 bfd_elf32_sh64l_vec, bfd_elf32_sh64lnbsd_vec,
6589 bfd_elf32_sh64nbsd_vec, bfd_elf64_sh64_vec, bfd_elf64_sh64l_vec,
6590 bfd_elf64_sh64lnbsd_vec, bfd_elf64_sh64nbsd_vec.
6591 * configure.in: Sort target vecs. Add m88kmach3_vec.
6592 * configure: Regenerate.
6594 2002-06-16 Hans-Peter Nilsson <hp@bitrange.com>
6596 * elf64-mmix.c (bpo_reloc_request_sort_fn): Use member
6597 bpo_reloc_no to break sort order ties, not address of items.
6599 2002-06-16 John David Anglin <dave@hiauly1.hia.nrc.ca>
6601 * elf-hppa.h (elf_hppa_final_link): Fix formatting in comment.
6602 Skip excluded sections in determing __gp value.
6603 (elf_hppa_final_link_relocate): Use the symbol's address in
6604 R_PARISC_FPTR64 relocations that don't need an opd entry.
6605 * elf64-hppa.c (allocate_dynrel_entries): Simplify code.
6606 (elf64_hppa_finalize_dynreloc): Likewise.
6607 (elf64_hppa_size_dynamic_sections): Move comments and fix typo.
6608 (elf64_hppa_finish_dynamic_symbol): Break up assert.
6610 2002-06-14 Sergey Grigoriev <serge@leopold.Physik.Uni-Augsburg.DE>
6612 * pei-i386.c (COFF_SECTION_ALIGNMENT_ENTRIES): Enable 16 byte
6613 alignment for .bss, .data and .text sections so that sse and sse2
6615 * pe-i386.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
6617 2002-06013 J"orn Rennecke <joern.rennecke@superh.com>
6619 config.bfd: Add support for sh[1234]l*-*-elf* | sh3el*-*-elf*,
6622 2002-06-12 John David Anglin <dave@hiauly1.hia.nrc.ca>
6624 * elflink.h (elf_bfd_final_link): Improve error handling for missing
6627 * elf64-hppa.c (allocate_global_data_opd): We don't need an opd entry
6628 for a symbol that has no output section.
6629 (allocate_dynrel_entries): Correct comment.
6630 (elf64_hppa_finalize_dynreloc): Likewise. Don't create an opd entry
6632 (elf64_hppa_finalize_opd): Prevent segfault if dyn_h is NULL.
6633 (elf64_hppa_finalize_dlt): Likewise. Prevent segfault for symbols
6634 with no section. Remove unnecessary parentheses.
6636 2002-06-11 Tom Rix <trix@redhat.com>
6638 * coffcode.h (coff_compute_section_file_positions): Add data
6639 section to AIX loader alignment check.
6641 * coff-rs6000.c (_bfd_xcoff_mkobject): Set default text section
6642 alignment to 4 bytes.
6643 (_bfd_xcoff_copy_private_bfd_data): Use text and data alignment
6644 power accessor macro.
6645 (do_shared_object_padding): Remove invalid assertion.
6647 2002-06-10 Richard Sandiford <rsandifo@redhat.com>
6649 * section.c (_bfd_strip_section_from_output): Set SEC_EXCLUDE
6650 for removed output sections.
6652 2002-06-10 Geoffrey Keating <geoffk@redhat.com>
6654 * merge.c (merge_strings): Use htab_create_alloc with calloc, not
6656 * elf-strtab.c (_bfd_elf_strtab_finalize): Likewise.
6658 2002-06-08 H.J. Lu <hjl@gnu.org>
6660 * elf.c (copy_private_bfd_data): Don't cast to bfd_size_type to
6661 work around a long long bug in gcc 2.96 on mips.
6663 2002-06-08 Jason Thorpe <thorpej@wasabisystems.com>
6665 * Makefile.am (BFD32_BACKENDS): Add vax1knetbsd.lo.
6666 (BFD32_BACKENDS_CFILES): Add vax1knetbsd.c.
6667 Regenerate dependency lists.
6668 * Makefile.in: Regenerate.
6669 * config.bfd (vax-*-netbsdelf*, vax-*-netbsdaout*): Add
6670 vax1knetbsd_vec to targ_selvecs.
6671 * configure.in: Add vax1knetbsd_vec.
6672 * configure: Regenerate.
6673 * targets.c (_bfd_target_vector): Add vax1knetbsd_vec.
6674 * vax1knetbsd.c: New file.
6675 * vaxnetbsd.c: Update copyright years.
6676 (TARGET_PAGE_SIZE): Set to 0x1000.
6677 (DEFAULT_MID): Set to M_VAX4K_NETBSD.
6679 2002-06-08 Matt Thomas <matt@3am-software.com>
6681 * libaout.h (enum machine_type): Add M_VAX4K_NETBSD.
6683 2002-06-08 Alan Modra <amodra@bigpond.net.au>
6685 * elf64-sh64.c (sh64_elf64_link_output_symbol_hook): Make static.
6687 2002-06-08 Alan Modra <amodra@bigpond.net.au>
6689 * Makefile.am: Run "make dep-am".
6690 * Makefile.in: Regenerate.
6692 * armnetbsd.c: Replace CONST with const.
6693 * corefile.c: Likewise.
6694 * elf32-dlx.c: Likewise.
6695 * elf64-mips.c: Likewise.
6697 * ns32knetbsd.c: Likewise.
6699 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Check the hash
6700 table is elf64-sparc.
6702 2002-06-08 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
6704 * elfxx-mips.c (_bfd_mips_elf_relocate_section): Simplify code.
6705 Fix RELA addends to get not shifted in the result. Don't do special
6706 handling of R_MIPS_64 for NewABI.
6708 2002-06-07 Alan Modra <amodra@bigpond.net.au>
6710 * aoutx.h (NAME(aout,slurp_symbol_table)): Use bfd_zmalloc.
6711 (NAME(aout,slurp_reloc_table)): Likewise.
6712 * coff-mips.c (mips_relax_section): Use bfd_zalloc.
6713 * coff-rs6000.c (xcoff_write_armap_big): Use bfd_zmalloc.
6714 (xcoff_write_archive_contents_big): Likewise.
6715 (xcoff_generate_rtinit): Likewise.
6716 (xcoff_generate_rtinit): Likewise, and check error return.
6717 * coff64-rs6000.c (xcoff64_generate_rtinit): Likewise.
6718 * coffgen.c (coff_section_symbol): Use bfd_zalloc.
6719 (coff_get_normalized_symtab): Likewise.
6720 (coff_make_empty_symbol): Likewise.
6721 (bfd_coff_set_symbol_class): Likewise.
6722 * cofflink.c (coff_link_add_symbols): Likewise.
6723 * ecoff.c (_bfd_ecoff_make_empty_symbol): Likewise.
6724 * ecofflink.c (ecoff_write_shuffle): Use bfd_zmalloc.
6725 (bfd_ecoff_write_accumulated_debug): Likewise.
6726 * elf64-alpha.c (get_got_entry): Use bfd_zalloc.
6727 * i386linux.c (bfd_i386linux_size_dynamic_sections): Likewise.
6728 * i386lynx.c (NAME(lynx,slurp_reloc_table)): Use bfd_zmalloc.
6729 * ieee.c (do_with_relocs): Use bfd_zalloc.
6730 * m68klinux.c (bfd_m68klinux_size_dynamic_sections): Likewise.
6731 * pdp11.c (NAME(aout,slurp_symbol_table)): Use bfd_zmalloc.
6732 (NAME(aout,slurp_reloc_table)): Likewise.
6733 (NAME(aout,squirt_out_relocs)): Don't memset when zalloc'd.
6734 * reloc16.c (bfd_coff_reloc16_relax_section): Use bfd_zmalloc.
6735 * som.c (som_build_and_write_symbol_table): Likewise.
6736 (som_slurp_string_table): Likewise.
6737 (som_slurp_symbol_table): Likewise.
6738 (som_bfd_ar_write_symbol_stuff): Likewise.
6739 * sparclinux.c (bfd_sparclinux_size_dynamic_sections): Use bfd_zalloc.
6740 * sunos.c (bfd_sunos_size_dynamic_sections): Likewise.
6741 * tekhex.c (find_chunk): Likewise. Get rid of unused "sname".
6742 * vms-gsd.c (_bfd_vms_slurp_gsd): Use bfd_zmalloc.
6743 * xcofflink.c (xcoff_link_add_symbols): Use bfd_zalloc/bfd_zmalloc.
6745 2002-06-07 Alan Modra <amodra@bigpond.net.au>
6747 * elf-bfd.h (struct bfd_elf_section_data <group_name>): Replace with
6749 (elf_group_name): Update.
6750 (elf_group_id): Define.
6751 (bfd_elf_set_group_contents): Declare.
6752 * elf.c (elf_fake_sections): Qualify use of elf_group_name.
6753 (set_group_contents): Rename to bfd_elf_set_group_contents. Remove
6754 ATTRIBUTE_UNUSED from failedptrarg. If elf_group_id is set, use
6755 that sym for the signature.
6756 (_bfd_elf_compute_section_file_positions): Don't call
6757 set_group_contents for "ld -r" case.
6758 (swap_out_syms): Use bfd_zalloc.
6759 * elflink.h (elf_link_add_archive_symbols): Likewise.
6760 (NAME(bfd_elf,size_dynamic_sections)): Likewise.
6761 (elf_bfd_final_link): Call bfd_elf_set_group_contents.
6763 2002-06-07 Alan Modra <amodra@bigpond.net.au>
6765 * elf64-ppc.c (ppc64_elf_relocate_section): Allow unresolved
6766 relocs in opd for non-shared too.
6768 2002-06-06 Jeffrey Law <law@redhat.com>
6770 * elf32-h8300.c (elf32_h8_relax_section): Ignore uninteresting
6773 2002-06-06 Nick Clifton <nickc@cambridge.redhat.com>
6775 * merge.c: Include libiberty.h.
6776 * elf-strtab.c: Include libiberty.h.
6778 2002-06-06 Elias Athanasopoulos <eathan@otenet.gr>
6780 * peXXigen.c (pe_print_idata): Remove unused variable.
6782 2002-06-06 David Heine <dlheine@tensilica.com>
6784 * elf.c (assign_file_positions_for_segments): Remove unallocated
6785 sections from the section to segment mapping for PT_LOAD segments.
6786 Update comment about empty loadable segments.
6788 2002-06-06 Richard Sandiford <rsandifo@redhat.com>
6790 * stabs.c (_bfd_link_section_stabs): Check that the symbol offset
6791 is within the .stabstr section.
6793 2002-06-06 Alan Modra <amodra@bigpond.net.au>
6795 * elf-bfd.h (struct elf_size_info <swap_symbol_in>): Function args
6796 are "const PTR", not "const PTR *".
6797 (bfd_elf32_swap_symbol_in): Likewise.
6798 (bfd_elf64_swap_symbol_in): Likewise.
6799 * elfcode.h (elf_swap_symbol_in): Change input args to const PTR.
6800 (elf_slurp_symbol_table): Adjust call to elf_swap_symbol_in.
6801 * elflink.h (elf_link_is_defined_archive_symbol): Likewise.
6802 (elf_link_add_object_symbols): Likewise.
6803 (elf_link_record_local_dynamic_symbol): Likewise.
6804 (elf_link_input_bfd): Likewise.
6805 (elf_gc_mark): Likewise.
6806 (elf_reloc_symbol_deleted_p): Likewise.
6807 * elf-m10200.c (mn10200_elf_relax_section): Likewise.
6808 (mn10200_elf_relax_delete_bytes): Likewise.
6809 (mn10200_elf_symbol_address_p): Likewise.
6810 (mn10200_elf_get_relocated_section_contents): Likewise.
6811 * elf-m10300.c (mn10300_elf_relax_section): Likewise.
6812 (mn10300_elf_relax_section): Likewise.
6813 (mn10300_elf_relax_delete_bytes): Likewise.
6814 (mn10300_elf_symbol_address_p): Likewise.
6815 (mn10300_elf_get_relocated_section_contents): Likewise.
6816 * elf32-h8300.c (elf32_h8_relax_section): Likewise.
6817 (elf32_h8_relax_delete_bytes): Likewise.
6818 (elf32_h8_symbol_address_p): Likewise.
6819 (elf32_h8_get_relocated_section_contents): Likewise.
6820 * elf32-hppa.c (get_local_syms): Likewise.
6821 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Likewise.
6822 * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): Likewise.
6823 * elf32-sh.c (sh_elf_relax_section): Likewise.
6824 (sh_elf_relax_delete_bytes): Likewise.
6825 (sh_elf_get_relocated_section_contents): Likewise.
6826 * elf32-xstormy16.c (xstormy16_elf_relax_section): Likewise.
6827 * elf64-alpha.c (elf64_alpha_relax_section): Likewise.
6828 * elf64-hppa.c (elf64_hppa_check_relocs): Likewise.
6829 * elf64-mmix.c (mmix_elf_relax_section): Likewise.
6830 * elf64-ppc.c (get_local_syms): Likewise.
6831 * elf64-sh64.c (sh_elf64_get_relocated_section_contents): Likewise.
6832 * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
6834 2002-06-05 J"orn Rennecke <joern.rennecke@superh.com>
6836 * config.bfd (sh64l*-*-elf*, shl*-*-elf*): New configurations.
6838 2002-06-05 Alan Modra <amodra@bigpond.net.au>
6840 * elf.c (group_signature): Swap in the whole symbol, and handle
6841 extracting section symbol names.
6842 (setup_group): Add comment.
6843 (set_group_contents): When called from objcopy or ld, arrange for
6844 section contents to be written. Write group member output section
6845 indices to allow objcopy to reorganize sections.
6846 (_bfd_elf_copy_private_section_data): Copy group info.
6848 * elf-bfd.h (struct elf_size_info): Add swap_symbol_in field.
6849 (bfd_elf32_swap_symbol_in): Update prototype.
6850 (bfd_elf64_swap_symbol_in): Likewise.
6851 * elfcode.h (elf_swap_symbol_in): Change input args to const PTR *.
6852 (elf_slurp_symbol_table): Adjust call to elf_swap_symbol_in.
6853 * elflink.h (elf_link_is_defined_archive_symbol): Likewise.
6854 (elf_link_add_object_symbols): Likewise.
6855 (elf_link_record_local_dynamic_symbol): Likewise.
6856 (elf_link_input_bfd): Likewise.
6857 (elf_gc_mark): Likewise.
6858 (elf_reloc_symbol_deleted_p): Likewise.
6859 * elf-m10200.c (mn10200_elf_relax_section): Likewise.
6860 (mn10200_elf_relax_delete_bytes): Likewise.
6861 (mn10200_elf_symbol_address_p): Likewise.
6862 (mn10200_elf_get_relocated_section_contents): Likewise.
6863 * elf-m10300.c (mn10300_elf_relax_section): Likewise.
6864 (mn10300_elf_relax_section): Likewise.
6865 (mn10300_elf_relax_delete_bytes): Likewise.
6866 (mn10300_elf_symbol_address_p): Likewise.
6867 (mn10300_elf_get_relocated_section_contents): Likewise.
6868 * elf32-h8300.c (elf32_h8_relax_section): Likewise.
6869 (elf32_h8_relax_delete_bytes): Likewise.
6870 (elf32_h8_symbol_address_p): Likewise.
6871 (elf32_h8_get_relocated_section_contents): Likewise.
6872 * elf32-hppa.c (get_local_syms): Likewise.
6873 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Likewise.
6874 * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): Likewise.
6875 * elf32-sh.c (sh_elf_relax_section): Likewise.
6876 (sh_elf_relax_delete_bytes): Likewise.
6877 (sh_elf_get_relocated_section_contents): Likewise.
6878 * elf32-xstormy16.c (xstormy16_elf_relax_section): Likewise.
6879 * elf64-alpha.c (elf64_alpha_relax_section): Likewise.
6880 * elf64-hppa.c (elf64_hppa_check_relocs): Likewise.
6881 * elf64-mmix.c (mmix_elf_relax_section): Likewise.
6882 * elf64-ppc.c (get_local_syms): Likewise.
6883 * elf64-sh64.c (sh_elf64_get_relocated_section_contents): Likewise.
6884 * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
6885 * elfcode.h (NAME(_bfd_elf,size_info)): Update initialiser.
6886 * elf64-alpha.c (alpha_elf_size_info): Likewise.
6887 * elf64-hppa.c (hppa64_elf_size_info): Likewise.
6888 * elf64-mips.c (mips_elf64_size_info): Likewise.
6889 * elf64-s390.c (s390_elf64_size_info): Likewise.
6890 * elf64-sparc.c (sparc64_elf_size_info): Likewise.
6892 2002-06-05 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
6894 * elf32-mips.c (elf32_mips_ignore_discarded_relocs): Move to...
6895 elfxx-mips.c (_bfd_mips_elf_ignore_discarded_relocs): ... here.
6896 elf64-mips.c (elf_backend_ignore_discarded_relocs): Use
6897 _bfd_mips_elf_ignore_discarded_relocs.
6898 elfxx-mips.h (_bfd_mips_elf_ignore_discarded_relocs): Declare.
6900 2002-06-05 H.J. Lu <hjl@gnu.org>
6902 * elfxx-mips.c (mips_elf_calculate_relocation): Call
6903 _bfd_elf_rel_local_sym for STT_SECTION relocations against
6904 the SEC_MERGE section.
6906 2002-06-05 Alan Modra <amodra@bigpond.net.au>
6908 * coff-alpha.c: Update copyright date.
6909 * coff-mips.c: Likewise.
6910 * xcoff-target.h: Likewise.
6912 * bfd-in.h: Remove "taken from the source" comment.
6913 * libbfd-in.h: Likewise.
6914 * libcoff-in.h: Likewise.
6915 * bfd-in2.h: Regenerate.
6916 * libbfd.h: Regenerate.
6917 * libcoff.h: Regenerate.
6919 * elf.c (bfd_elf_discard_group): Return true.
6920 * elf-bfd.h (bfd_elf_discard_group): Declare.
6921 * bfd-in.h (bfd_elf_discard_group): Don't declare here.
6922 * section.c (bfd_discard_group): Rename to bfd_generic_discard_group.
6923 * bfd.c (bfd_discard_group): Define.
6924 * targets.c (struct bfd_target): Add _bfd_discard_group.
6925 (BFD_JUMP_TABLE_LINK): Here too.
6926 * libbfd-in.h (_bfd_nolink_bfd_discard_group): Define.
6927 * aout-adobe.c (aout_32_bfd_discard_group): Define.
6928 * aout-target.h (MY_bfd_discard_group): Define.
6929 * aout-tic30.c (MY_bfd_discard_group): Define.
6930 * binary.c (binary_bfd_discard_group): Define.
6931 * bout.c (b_out_bfd_discard_group): Define.
6932 * coff-alpha.c (_bfd_ecoff_bfd_discard_group): Define.
6933 * coffcode.h (coff_bfd_discard_group): Define.
6934 * coff-mips.c (_bfd_ecoff_bfd_discard_group): Define.
6935 * elfxx-target.h (bfd_elfNN_bfd_discard_group): Define.
6936 * i386msdos.c (msdos_bfd_discard_group): Define.
6937 * i386os9k.c (os9k_bfd_discard_group): Define.
6938 * ieee.c (ieee_bfd_discard_group): Define.
6939 * ihex.c (ihex_bfd_discard_group): Define.
6940 * mmo.c (mmo_bfd_discard_group): Define.
6941 * nlm-target.h (nlm_bfd_discard_group): Define.
6942 * oasys.c (oasys_bfd_discard_group): Define.
6943 * ppcboot.c (ppcboot_bfd_discard_group): Define.
6944 * som.c (som_bfd_discard_group): Define.
6945 * srec.c (srec_bfd_discard_group): Define.
6946 * tekhex.c (tekhex_bfd_discard_group): Define.
6947 * versados.c (versados_bfd_discard_group): Define.
6948 * vms.c (vms_bfd_discard_group): Define.
6949 * xcoff-target.h (_bfd_xcoff_bfd_discard_group): Define.
6950 * coff64-rs6000.c (rs6000coff64_vec): Update initialiser.
6951 (aix5coff64_vec): Likewise.
6952 * coff-rs6000.c (rs6000coff_vec, pmac_xcoff_vec): Likewise.
6954 2002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
6956 * Makefile.am (BFD32_BACKENDS): Add elf32-sh64-com.lo.
6957 (BFD32_BACKENDS_CFILES): Add elf32-sh64-com.c.
6958 (elf32-sh64-com.lo): New dependency list.
6959 * Makefile.in: Regenerate.
6960 * configure.in (bfd_elf32_sh64_vec, bfd_elf32_sh64l_vec)
6961 (bfd_elf32_sh64nbsd_vec, bfd_elf32_sh64lnbsd_vec): Add
6963 * configure: Regenerate.
6964 * elf32-sh64.c (sh64_address_in_cranges)
6965 (sh64_get_contents_type, sh64_address_is_shmedia): Move to...
6966 (crange_qsort_cmpb, crange_qsort_cmpl, crange_bsearch_cmpb):
6967 (crange_bsearch_cmpl): Prepend _bfd_sh64_ to name and move to...
6968 * elf32-sh64-com.c: ...here. New file.
6970 2002-06-04 Alan Modra <amodra@bigpond.net.au>
6972 * elf32-openrisc.c (openrisc_elf_gc_mark_hook): Remove
6973 ATTRIBUTE_UNUSED on used params.
6974 * elf32-vax.c (elf_vax_gc_mark_hook): Remove unnecessary checks
6975 before calling bfd_section_from_elf_index on local syms.
6976 * elf64-sh64.c (sh_elf64_gc_mark_hook): Likewise.
6978 2002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
6980 * Makefile.am (BFD32_BACKENDS): Add elf32-sh64-nbsd.lo.
6981 (BFD32_BACKENDS_CFILES): Add elf32-sh64-nbsd.c.
6982 (BFD64_BACKENDS): Add elf64-sh64-nbsd.lo.
6983 (BFD64_BACKENDS_CFILES): Add elf64-sh64-nbsd.c.
6984 (elf32-sh64-nbsd.lo, elf64-sh64-nbsd.lo): New rules.
6985 * Makefile.in: Regenerate.
6986 * config.bfd (sh5le-*-netbsd*, sh5-*-netbsd*, sh64le-*-netbsd*)
6987 (sh64-*-netbsd*): New targets.
6988 * configure.in: Add bfd_elf32_sh64nbsd_vec, bfd_elf32_sh64lnbsd_vec,
6989 bfd_elf64_sh64nbsd_vec, and bfd_elf64_sh64lnbsd_vec.
6990 * configure: Regenerate.
6991 * elf32-sh64-nbsd.c: New file.
6992 * elf64-sh64-nbsd.c: New file.
6993 * targets.c: Add extern decls for bfd_elf32_sh64nbsd_vec,
6994 bfd_elf32_sh64lnbsd_vec, bfd_elf64_sh64nbsd_vec, and
6995 bfd_elf64_sh64lnbsd_vec.
6997 2002-06-04 Alan Modra <amodra@bigpond.net.au>
6999 * elf.c (setup_group): Set SEC_LINK_ONCE on GRP_COMDAT groups.
7000 (bfd_section_from_shdr): Likewise. Set section name of group
7001 sections from signature.
7002 (group_signature): Split out from setup_group. Ensure symbol table
7004 (bfd_elf_discard_group): New function.
7005 (_bfd_elf_make_section_from_shdr): Don't set SEC_LINK_ONCE on
7006 .gnu.linkonce* sections if they are members of a group.
7007 (set_group_contents): Set GRP_COMDAT flag.
7008 * section.c (bfd_discard_group): New function.
7009 * bfd-in.h (bfd_elf_discard_group): Declare.
7010 * bfd-in2.h: Regenerate.
7011 * elf-bfd.h (struct bfd_elf_section_data): Add linkonce_p field.
7012 (elf_linkonce_p): Define.
7014 2002-06-04 Alan Modra <amodra@bigpond.net.au>
7016 * elf.c (bfd_section_from_shdr): Make "name" const.
7017 * elf-bfd.h (elf_backend_section_from_shdr): Likewise.
7018 * elf32-i370.c (i370_elf_section_from_shdr): Likewise.
7019 * elf32-ppc.c (ppc_elf_section_from_shdr): Likewise.
7020 * elf32-sh64.c (sh64_backend_section_from_shdr): Likewise.
7021 * elf32-v850.c (v850_elf_section_from_shdr): Likewise.
7022 * elf64-alpha.c (elf64_alpha_section_from_shdr): Likewise.
7023 * elf64-hppa.c (elf64_hppa_section_from_shdr): Likewise.
7024 * elf64-ppc.c (ppc64_elf_section_from_shdr): Likewise.
7025 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Likewise.
7026 * elfxx-mips.c (_bfd_mips_elf_section_from_shdr): Likewise.
7027 * elfxx-mips.h (_bfd_mips_elf_section_from_shdr): Likewise.
7029 2002-06-03 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
7031 * elfxx-mips.c (ABI_64_P): Use backend's data to determine the
7034 2002-06-02 Kazu Hirata <kazu@cs.umass.edu>
7036 * elf32-arc.c: Fix formatting.
7037 * elf32-arm.h: Likewise.
7038 * elf32-cris.c: Likewise.
7039 * elf32-dlx.c: Likewise.
7040 * elf32-hppa.c: Likewise.
7041 * elf32-i386.c: Likewise.
7042 * elf32-i386qnx.c: Likewise.
7043 * elf32-or32.c: Likewise.
7044 * elf32-s390.c: Likewise.
7045 * elf32-sh64.c: Likewise.
7046 * elf32-vax.c: Likewise.
7047 * elf32-xstormy16.c: Likewise.
7048 * elf64-alpha.c: Likewise.
7049 * elf64-mmix.c: Likewise.
7050 * elf64-ppc.c: Likewise.
7051 * elf64-s390.c: Likewise.
7052 * elf64-sh64.c: Likewise.
7053 * elf64-x86-64.c: Likewise.
7055 2002-06-02 Richard Henderson <rth@redhat.com>
7057 * elf64-alpha.c (elf64_alpha_relocate_section): Don't dereference
7058 null when there are no got entries for a symbol.
7059 (elf64_alpha_relax_find_tls_segment): Rearrange to avoid
7060 uninitialized variable warning.
7062 2002-06-01 Richard Henderson <rth@redhat.com>
7064 * elf64-alpha.c (elf64_alpha_relax_with_lituse): Don't test for
7065 undefined symbols here.
7066 (elf64_alpha_relax_section): Do it here. Also test for not
7067 defined in the current module.
7068 (elf64_alpha_relocate_section_r): Split out of ...
7069 (elf64_alpha_relocate_section): ... here. Don't dereference
7070 NULL when looking up local got entries.
7072 2002-06-01 Richard Henderson <rth@redhat.com>
7074 * elf64-alpha.c (elf64_alpha_relax_with_lituse): Reject undefined
7075 symbols from JSR relaxation.
7076 (elf64_alpha_size_plt_section_1): New.
7077 (elf64_alpha_calc_dynrel_sizes): Split out .rela.got bits ...
7078 (elf64_alpha_size_rela_got_1): ... here.
7079 (elf64_alpha_size_dynamic_sections): Split out .rela.got bits ...
7080 (elf64_alpha_size_rela_got_section): ... here.
7081 (elf64_alpha_size_plt_section): New.
7082 (elf64_alpha_relax_section): Call them.
7083 (elf64_alpha_size_got_sections): Remove output_bfd arg.
7084 (elf64_alpha_finish_dynamic_symbol): Check gotent use_count.
7086 2002-06-01 Richard Henderson <rth@redhat.com>
7088 * elf64-alpha.c (alpha_get_dtprel_base, alpha_get_tprel_base): New.
7089 (elf64_alpha_relocate_section): Use them. Reject LE TLS relocs
7090 in shared libraries. Fix DTPRELHI and TPRELHI value.
7091 (INSN_ADDQ, INSN_RDUNIQ): New.
7092 (struct alpha_relax_info): Add symtab_hdr, tls_segment, first_gotent.
7093 (elf64_alpha_relax_with_lituse): Return boolean. Remove irelend
7094 argument. Reject dynamic symbols. Use LITUSE symbolic constants.
7095 (elf64_alpha_relax_got_load): Rename from relax_without_lituse.
7096 Handle GOTDTPREL and GOTTPREL relocations.
7097 (elf64_alpha_relax_gprelhilo): New.
7098 (elf64_alpha_relax_tls_get_addr): New.
7099 (elf64_alpha_relax_find_tls_segment): New.
7100 (elf64_alpha_relax_section): Handle TLS relocations.
7101 (ALPHA_ELF_LINK_HASH_TLS_IE): New.
7102 (elf64_alpha_check_relocs): Set it.
7104 2002-06-01 Richard Henderson <rth@redhat.com>
7106 * elf64-alpha.c (elf64_alpha_relax_section): Don't store computed gp.
7108 * elf64-alpha.c (elf64_alpha_check_relocs): Fix typo on maybe_dynamic
7109 check; don't suppress dynamic relocs for non-allocated sections.
7111 * elf64-alpha.c: Remove dead code.
7113 2002-05-31 Alan Modra <amodra@bigpond.net.au>
7115 * bfd-in2.h: Regenerate.
7116 * libbfd.h: Regenerate.
7117 * po/SRC-POTFILES.in: Regenerate.
7119 * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Don't allocate
7122 2002-05-31 Graeme Peterson <gp@qnx.com>
7124 * Makefile.am (BFD32_BACKENDS): Add elf32-i386qnx.lo.
7125 (BFD32_BACKENDS_CFILES): Add elf32-i386qnx.c.
7127 * Makefile.in: Regenerate.
7128 * config.bfd: Add i[3456]86-*-nto-qnx* support.
7129 * configure.in: Add bfd_elf32_i386qnx_vec support.
7130 * configure: Regenerate.
7131 * elf-bfd.h (struct elf_backend_data): Add set_nonloadable_filepos,
7132 is_contained_by_filepos, and copy_private_bfd_data_p.
7133 * elf.c (assign_file_positions_for_segments): Call backend
7134 set_nonloadable_filepos. Fix non-K&R call to _bfd_error_handler.
7135 (IS_CONTAINED_BY_FILEPOS): Define.
7136 (INCLUDE_SECTION_IN_SEGMENT): Also test IS_CONTAINED_BY_FILEPOS.
7137 (copy_private_bfd_data): Use IS_CONTAINED_BY_FILEPOS. Typo fix.
7138 Fix non-K&R call to _bfd_error_handler.
7139 (_bfd_elf_copy_private_section_data): Use backend
7140 copy_private_bfd_data_p.
7141 * elf32-i386.c: Don't include elfxx-target.h when
7142 ELF32_I386_C_INCLUDED is defined.
7143 * elf32-i386qnx.c: New QNX elf backend file.
7144 * elfxx-target.h: Add elf_backend_set_nonloadable_filepos,
7145 elf_backend_is_contained_by_filepos, and
7146 elf_backend_do_copy_private_bfd_data.
7147 * targets.c: Add bfd_target bfd_elf32_i386qnx_vec.
7149 2002-05-31 Alan Modra <amodra@bigpond.net.au>
7151 * elfarm-oabi.c (bfd_elf32_arm_add_glue_sections_to_bfd): Define.
7152 Move other similar defines to start of file.
7154 2002-05-30 Tom Rix <trix@redhat.com>
7156 * coff-rs6000.c (xcoff_rtype2howto): Handle 16 bit R_RBA.
7157 * coff64-rs6000.c (xcoff64_rtype2howto): Same.
7159 2002-05-30 Richard Henderson <rth@redhat.com>
7161 * elf64-alpha.c (ALPHA_ELF_LINK_HASH_LU_TLSGD,
7162 ALPHA_ELF_LINK_HASH_LU_TLSLDM, ALPHA_ELF_LINK_HASH_LU_FUNC): New.
7163 (ALPHA_ELF_GOT_ENTRY_RELOCS_DONE): Remove.
7164 (ALPHA_ELF_GOT_ENTRY_RELOCS_XLATED): Remove.
7165 (struct alpha_elf_got_entry): Add reloc_type, reloc_done, reloc_xlated.
7166 (struct alpha_elf_obj_tdata): Rename total_got_entries and
7167 n_local_got_entries to total_got_size and local_got_size.
7168 (elf64_alpha_howto, elf64_alpha_reloc_map): Update for TLS relocs.
7169 (alpha_got_entry_size): New.
7170 (elf64_alpha_relax_with_lituse): Use it.
7171 (elf64_alpha_relax_without_lituse): Likewise.
7172 (MAX_GOT_SIZE): Rename from MAX_GOT_ENTRIES.
7173 (get_got_entry): New.
7174 (elf64_alpha_check_relocs): Handle TLS relocs. Reorganize.
7175 (elf64_alpha_adjust_dynamic_symbol): Test LU_FUNC as a mask.
7176 (elf64_alpha_merge_ind_symbols): Check gotent->reloc_type.
7177 (elf64_alpha_can_merge_gots, elf64_alpha_merge_gots): Likewise.
7178 (elf64_alpha_calc_got_offsets_for_symbol): Use alpha_got_entry_size.
7179 (elf64_alpha_calc_got_offsets): Likewise.
7180 (alpha_dynamic_entries_for_reloc): New.
7181 (elf64_alpha_calc_dynrel_sizes): Use it.
7182 (elf64_alpha_size_dynamic_sections): Likewise.
7183 (elf64_alpha_relocate_section): Handle TLS relocations.
7184 * reloc.c: Add Alpha TLS relocations.
7185 * bfd-in2.h, libbfd.h: Rebuild.
7187 2002-05-29 Ralf Habacker <ralf.habacker@freenet.de>
7189 * peXXigen.c (pe_print_idata): Remove double printed
7190 import table lines; add Bound-To comment.
7192 2002-05-29 Matt Thomas <matt@3am-software.com>
7194 * Makefile.am (BFD32_BACKENDS): Add elf32-vax.lo.
7195 (BFD32_BACKENDS_CFILES): Add elf32-vax.c.
7196 (elf32-vax.lo): New rule.
7197 * Makefile.in: Regenerate.
7198 * configure.in (bfd_elf32_vax_vec)
7199 (vaxnetbsd_vec): New vectors.
7200 * configure: Regenerate.
7201 * config.bfd (vax-*-netbsdelf*)
7203 (vax-*-netbsd*): New targets.
7204 * elf32-vax.c: New file.
7205 * reloc.c: Add VAX relocations.
7206 * bfd-in2.h: Regenerate.
7207 * targets.c (_bfd_target_vector): Add bfd_elf32_vax_vec.
7209 2002-05-29 Jason Thorpe <thorpej@wasabisystems.com>
7211 * config.bfd (arm-*-netbsd*): Add bfd_elf32_littlearm_vec
7212 and bfd_elf32_bigarm_vec to targ_selvecs.
7214 2002-05-29 Ralf Habacker <ralf.habacker@freenet.de>
7216 * peXXigen.c (pe_print_idata): Fix seg faults on printing import tables
7217 with auto-imported symbols.
7219 2002-05-29 Adam Nemet <anemet@lnxw.com>
7221 * elf32-arm.h (bfd_elf32_arm_get_bfd_for_interworking): Don't add glue
7222 sections only record bfd.
7223 (bfd_elf32_arm_add_glue_sections_to_bfd): New function.
7224 * bfd-in.h (bfd_elf32_arm_add_glue_sections_to_bfd): Declare it.
7225 * bfd-in2.h: Regenerate.
7227 2002-05-28 Nick Clifton <nickc@cambridge.redhat.com>
7229 * syms.c (_bfd_stab_section_find_nearest_line): Move
7230 declaration and initialisation of saw_line and saw_func out of
7233 2002-05-29 Alan Modra <amodra@bigpond.net.au>
7235 * elf64-ppc.c (ppc64_elf_get_symbol_info): New function.
7236 (bfd_elf64_get_symbol_info): Define.
7237 * elfxx-target.h (bfd_elfNN_get_symbol_info): Only define if undef.
7239 2002-05-29 Andrey Volkov <avolkov@transas.com>
7241 * cpu-h8300.c: Make default h8300 machine first in machine list.
7243 2002-05-28 Kuang Hwa Lin <kuang@sbcglobal.net>
7245 * config.bfd: Added DLX configuraton.
7246 * Makefile.am: Added DLX configuraton.
7247 * configure.in: Added DLX configuraton.
7248 * archures.c: Add DLX architecure.
7249 * reloc.c: Add DLX relocs.
7250 * targets.c: Added DLX target vector.
7251 * configure: Regenerate.
7252 * Makefile.in: Regenreate.
7253 * bfd-in2.h: Regenreate.
7254 * elf32-dlx.c: New file: Support DLX target.
7255 * cpu-dlx.c: New file: Support DLX target.
7257 2002-05-25 Alan Modra <amodra@bigpond.net.au>
7259 * elf32-m68k.c (elf32_m68k_print_private_bfd_data): Formatting.
7261 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Revert last change.
7262 (ppc64_elf_check_relocs): Don't set up function descriptor symbol
7263 strings to point inside function code sym string.
7264 (func_desc_adjust): Likewise.
7265 (ppc64_elf_hide_symbol): Rewrite code to look up function code sym.
7267 2002-05-24 Michal Ludvig <mludvig@suse.cz>
7269 * elf64-x86-64.c (elf64_x86_64_grok_prstatus): Added.
7270 (elf64_x86_64_grok_psinfo): Added.
7272 2002-05-24 TAMURA Kent <kent@netbsd.org>
7274 * config.bfd: Add a target for i386-netbsdpe.
7276 2002-05-24 Alan Modra <amodra@bigpond.net.au>
7278 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Don't copy is_func
7279 and is_func_descriptor.
7280 (func_desc_adjust): Hide function code sym in shared libs unless
7281 there is a matching exported function descriptor sym.
7283 2002-05-23 Jakub Jelinek <jakub@redhat.com>
7285 * elf.c (_bfd_elf_make_section_from_shdr): Set SEC_THREAD_LOCAL
7286 for symbols from SHF_TLS section.
7287 (_bfd_elf_print_private_bfd_data): Add PT_TLS.
7288 (elf_fake_sections): Set SHF_TLS for SEC_THREAD_LOCAL sections.
7289 (map_sections_to_segments): Build PT_TLS segment if necessary.
7290 (assign_file_positions_for_segments): Likewise.
7291 (get_program_header_size): Account for PT_TLS segment.
7292 (swap_out_syms): Set type of BSF_THREAD_LOCAL symbols and symbols from
7293 SEC_THREAD_LOCAL sections to STT_TLS.
7294 * reloc.c: Add 386 and IA-64 TLS relocs.
7295 * section.c (SEC_THREAD_LOCAL): Define.
7296 (SEC_CONSTRUCTOR_TEXT, SEC_CONSTRUCTOR_DATA, SEC_CONSTRUCTOR_BSS):
7298 * elflink.h (elf_link_add_object_symbols): Support .tcommon.
7299 (size_dynamic_sections): If DF_STATIC_TLS, set DF_FLAGS
7301 (struct elf_final_link_info): Add first_tls_sec.
7302 (elf_bfd_final_link): Set first_tls_sec.
7303 Compute elf_hash_table (info)->tls_segment.
7304 (elf_link_output_extsym): Handle STT_TLS symbols.
7305 (elf_link_input_bfd): Likewise.
7306 * syms.c (BSF_THREAD_LOCAL): Define.
7307 * bfd-in2.h: Rebuilt.
7308 * libbfd.h: Rebuilt.
7309 * elf32-i386.c (elf_i386_tls_transition, dtpoff_base, tpoff,
7310 elf_i386_mkobject, elf_i386_object_p): New functions.
7311 (elf_howto_table): Add TLS relocs.
7312 (elf_i386_reloc_type_lookup): Support TLS relocs.
7313 (elf_i386_info_to_howto_rel): Likewise.
7314 (struct elf_i386_link_hash_entry): Add tls_type.
7315 (struct elf_i386_obj_tdata): New.
7316 (elf_i386_hash_entry, elf_i386_tdata, elf_i386_local_got_tls_type):
7318 (struct elf_i386_link_hash_table): Add tls_ldm_got.
7319 (link_hash_newfunc): Clear tls_type.
7320 (elf_i386_check_relocs): Support TLS relocs.
7321 (elf_i386_gc_sweep_hook): Likewise.
7322 (allocate_dynrelocs): Likewise.
7323 (elf_i386_size_dynamic_sections): Likewise.
7324 (elf_i386_relocate_section): Likewise.
7325 (elf_i386_finish_dynamic_symbol): Likewise.
7326 (bfd_elf32_mkobject, elf_backend_object_p): Define.
7327 * elfxx-ia64.c (struct elfNN_ia64_dyn_sym_info): Add tprel_offset,
7328 dtpmod_offset, dtprel_offset, tprel_done, dtpmod_done, dtprel_done,
7329 want_tprel, want_dtpmod, want_dtprel.
7330 (elfNN_ia64_tprel_base, elfNN_ia64_dtprel_base): New functions.
7331 (ia64_howto_table): Add TLS relocs, rename R_IA64_LTOFF_TP22 to
7332 R_IA64_LTOFF_TPREL22.
7333 (elf_code_to_howto_index): Add TLS relocs.
7334 (elfNN_ia64_check_relocs): Support TLS relocs.
7335 (allocate_global_data_got): Account for TLS .got data.
7336 (allocate_dynrel_entries): Account for TLS dynamic relocations.
7337 (elfNN_ia64_install_value): Supprt TLS relocs.
7338 (set_got_entry): Support TLS relocs.
7339 (elfNN_ia64_relocate_section): Likewise.
7341 2002-05-23 Nick Clifton <nickc@cambridge.redhat.com>
7343 * elf32-arm.h (elf32_arm_final_link_relocate): For the Thumb
7344 BLX reloc round the relocation up rather than down.
7345 * coff-arm.c (coff_arm_relocate_section): Likewise.
7347 2002-05-21 H.J. Lu (hjl@gnu.org)
7349 * linker.c (_bfd_generic_link_add_one_symbol): Allow multiple
7352 2002-05-22 Alan Modra <amodra@bigpond.net.au>
7354 * elf64-ppc.c (ppc64_elf_size_stubs): Don't strip .branch_lt.
7355 (ppc64_elf_relocate_section): Handle unresolved relocs in opd.
7357 2002-05-22 Alan Modra <amodra@bigpond.net.au>
7359 * elf64-ppc.c (ppc64_elf_relocate_section): Return false for
7361 (ppc64_elf_size_dynamic_sections): Check for splt NULL.
7363 2002-05-21 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
7365 * bfd.c (bfd_get_arch_size): Remove bfd_set_error call for
7368 2002-05-21 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
7370 * elf-bfd.h (elf_backend_emit_relocs): Change prototype to return
7372 * elflink.h (elf_link_output_relocs): Likewise. Improve error message.
7373 return with false on error.
7374 (elf_link_input_bfd): Check reloc_emitter return value.
7376 2002-05-21 Jason Thorpe <thorpej@wasabisystems.com>
7378 * config.bfd (armeb-*-netbsdelf*): New target.
7380 2002-05-20 Alan Modra <amodra@bigpond.net.au>
7382 * elf64-ppc.c (ppc_build_one_stub): Point undefined function syms
7383 at the plt call stub.
7385 2002-05-19 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
7387 * cpu-mips.c (mips_compatible): Don't try to check machine
7390 2002-05-18 Tom Rix <trix@redhat.com>
7392 * coff64-rs6000.c (_bfd_xcoff64_swap_aux_out): Fix C_FILE auxent.
7394 2002-05-17 Alan Modra <amodra@bigpond.net.au>
7396 * elf64-ppc.c (ppc64_elf_info_to_howto): Formatting.
7397 (ppc64_elf_relocate_section): Don't warn about reloc overflow when
7398 we've already warned about an undefined symbol. Report more
7399 detail on reloc errors.
7401 2002-05-17 Alan Modra <amodra@bigpond.net.au>
7403 * acinclude.m4 (AM_INSTALL_LIBBFD): New.
7404 * configure.in: Invoke AM_INSTALL_LIBBFD.
7405 * Makefile.am (install-data-local): Revert 2002-05-13. Move to..
7406 (install_libbfd): .. New target.
7407 (uninstall_libbfd): Likewise.
7408 (install-bfdlibLTLIBRARIES): Likewise.
7409 (uninstall-bfdlibLTLIBRARIES): Likewise.
7411 (bfdincludedir): New.
7412 (lib_LTLIBRARIES): Rename to bfdlib_LTLIBRARIES.
7413 * aclocal.m4: Regenerate.
7414 * configure: Regenerate.
7415 * Makefile.in: Regenerate.
7417 2002-05-17 Stuart Balfour <sbalfour@cisco.com>
7419 * hash.c (bfd_hash_lookup): Remove computation of len from inside
7422 2002-05-16 Nick Clifton <nickc@cambridge.redhat.com>
7424 * config.bfd: Add targets for sh64-linux (little endian and
7427 2002-05-15 Laurent Pinchart <laurent.pinchart@skynet.be>
7429 * peXXigen.c (pe_print_idata): Do not assume that the first thunk
7430 is located in the same section as the import table. Instead
7431 check, and if necessary load the section containing the thunk.
7433 2002-05-15 Nick Clifton <nickc@cambridge.redhat.com>
7435 * aix5ppc-core.c (xcoff64_core_p): Replace bfd_read with
7437 (xcoff64_core_file_matches_executable_p): Replace bfd_read
7440 2002-05-15 Alan Modra <amodra@bigpond.net.au>
7442 * aix5ppc-core.c: Warning fixes.
7443 * aout-adobe.c (aout_32_bfd_link_just_syms): Define.
7444 * aout-target.h (MY_bfd_link_just_syms): Define.
7445 * aout-tic30.c (MY_bfd_link_just_syms): Define.
7446 * bfd.c (bfd_link_just_syms): Define.
7447 * binary.c (binary_bfd_link_just_syms): Define.
7448 * bout.c (b_out_bfd_link_just_syms): Define.
7449 * coff-rs6000.c (rs6000coff_vec, pmac_xcoff_vec): Update initializer.
7450 * coff64-rs6000.c (rs6000coff64_vec, aix5coff64_vec): Likewise.
7451 * coffcode.h (coff_bfd_link_just_syms): Define.
7452 * elf-bfd.h (enum elf_link_info_type): Add ELF_INFO_TYPE_JUST_SYMS.
7453 (elf_discarded_section): Check for ELF_INFO_TYPE_JUST_SYMS.
7454 (_bfd_elf_link_just_syms): Declare.
7455 * elf.c (_bfd_elf_link_just_syms): New function.
7456 * elf-eh-frame.c (_bfd_elf_maybe_strip_eh_frame_hdr): Check that
7457 sections haven't already been discarded by the linker.
7458 * elflink.h (elf_link_add_object_symbols): Likewise for stab
7459 sections and SEC_MERGE sections.
7460 (elf_bfd_discard_info): Similarly here.
7461 * elfxx-target.h (bfd_elfNN_bfd_link_just_syms): Define.
7462 * i386msdos.c (msdos_bfd_link_just_syms): Define.
7463 * i386os9k.c (os9k_bfd_link_just_syms): Define.
7464 * ieee.c (ieee_bfd_link_just_syms): Define.
7465 * ihex.c (ihex_bfd_link_just_syms): Define.
7466 * libbfd-in.h (_bfd_nolink_bfd_link_just_syms): Define.
7467 (_bfd_generic_link_just_syms): Declare.
7468 * libecoff.h (_bfd_ecoff_bfd_link_just_syms): Define.
7469 * linker.c (_bfd_generic_link_just_syms): New function.
7470 * mmo.c (mmo_bfd_link_just_syms): Define.
7471 * nlm-target.h (nlm_bfd_link_just_syms): Define.
7472 * oasys.c (oasys_bfd_link_just_syms): Define.
7473 * ppcboot.c (ppcboot_bfd_link_just_syms): Define.
7474 * som.c (som_bfd_link_just_syms): Define.
7475 * srec.c (srec_bfd_link_just_syms): Define.
7476 * targets.c (struct bfd_target): Add _bfd_link_just_syms.
7477 (BFD_JUMP_TABLE_LINK): And here.
7478 * tekhex.c (tekhex_bfd_link_just_syms): Define.
7479 * versados.c (versados_bfd_link_just_syms): Define.
7480 * vms.c (vms_bfd_link_just_syms): Define.
7481 * libbfd.h: Regenerate.
7482 * bfd-in2.h: Regenerate.
7484 2002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
7486 * elf32-mips.c: Remove superfluous definitions copied from
7488 (bfd_elf32_bigmips_vec,bfd_elf32_littlemips_vec): Use the
7489 SGIish vectors to check the special case.
7490 (mips_elf_hi16_reloc): Fix comment.
7491 (mips_elf_got16_reloc): Likewise.
7492 (_bfd_mips_elf32_gprel16_reloc): Likewise.
7493 (elf_reloc_map): Code cleanup.
7494 (mips_reloc_map): Add comment.
7495 (bfd_elf23_bfd_reloc_type_lookup): Code cleanup.
7496 (mips_elf32_rtype_to_howto): Likewise.
7497 (mips_elf32_discard_info): Likewise.
7498 (elf32_mips_irix_compat): Invert logic: Only SGIish vectors
7499 lead to IRIX compatibility now.
7501 2002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
7503 * elfxx-mips.c: Call it IRIX, not Irix in comments.
7505 2002-05-13 Jason Thorpe <thorpej@wasabisystems.com>
7507 * config.bfd (shle-*-netbsdelf*): Add target which includes
7510 2002-05-13 David Edelsohn <edelsohn@gnu.org>
7512 * configure.in: Revert 2002-04-07. Instead, auto-configure
7514 * configure: Regenerate.
7515 * config.in: Regenerate.
7516 * rs6000-core.c (CNEW_IMPL): Guard use of c_impl with HAVE_ST_C_IMPL
7519 2002-05-11 Federico G. Schwindt <fgsch@olimpo.com.br>
7521 * configure.in (sparc*-*-openbsd*): Support sparc64-openbsd
7523 * configure: Regenerate.
7525 2002-05-13 Alan Modra <amodra@bigpond.net.au>
7527 * Makefile.am (install-data-local): Install headers to
7528 $(exec_prefix)/include.
7529 * Makefile.in: Regenerate.
7531 2002-05-11 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
7532 Daniel Jacobowitz <drow@mvista.com>
7534 * coff-sh.c (sh_reloc_map): Map to R_SH_IMM32 for non-PE. Don't
7537 2002-05-11 Federico G. Schwindt <fgsch@olimpo.com.br>
7539 * config.bfd (alpha*-*-openbsd*, sparc64*-*-openbsd*,
7540 hppa*-*-openbsd*): New targets.
7541 * configure.in (alpha*-*-openbsd*): Set COREFILE.
7542 * configure: Regenerate.
7544 2002-05-10 Tom Rix <trix@redhat.com>
7546 * coff64-rs6000.c (xcoff64_reloc_type_br): New function for
7547 xcoff64_ppc_relocate_section.
7548 * coff-rs6000.c : Extern common xcoff_reloc_type functions.
7549 * libxcoff.h: Common xcoff_reloc_type function declaration.
7551 2002-05-10 Alan Modra <amodra@bigpond.net.au>
7553 * elf32-i386.c (elf_i386_relocate_section): Remove overflow checks
7554 added in 2002-05-09 commit.
7556 * elf32-hppa.c (elf32_hppa_size_stubs): Revert part of 2002-05-04,
7557 don't look for stubs on all undefined syms.
7559 2002-05-09 Alan Modra <amodra@bigpond.net.au>
7561 * elf64-ppc.c (RA_REGISTER_MASK, RA_REGISTER_SHIFT): Delete.
7562 (ppc64_elf_howto_raw <R_PPC64_RELATIVE>): Not pc_relative or
7565 * elf32-i386.c (elf_howto_table): Comments.
7566 (elf_i386_relocate_section): Handle more relocs for relocatable
7567 linking and against SEC_MERGE sections.
7569 2002-05-08 Alan Modra <amodra@bigpond.net.au>
7571 * elf32-ppc.c (ppc_elf_create_got): New function.
7572 (ppc_elf_create_dynamic_sections): Call ppc_elf_create_got before
7573 _bfd_elf_create_dynamic_sections. Correct .plt flags.
7574 (ppc_elf_check_relocs): Use ppc_elf_create_got in place of
7575 _bfd_elf_create_got_section.
7577 2002-05-07 Alan Modra <amodra@bigpond.net.au>
7579 * elf-bfd.h (struct elf_backend_data): Add rela_normal.
7580 * elfxx-target.h (elf_backend_rela_normal): Define.
7581 (elfNN_bed): Init rela_normal.
7582 * elflink.h (elf_link_input_bfd <emit_relocs>): Handle adjustment
7583 for section symbols here if rela_normal. Simplify abs section test.
7584 * elf-m10200.c (mn10200_elf_relocate_section): If relocatable,
7585 return immediately. Remove code handling relocatable linking.
7586 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
7587 * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
7588 * elf32-i370.c (i370_elf_relocate_section): Likewise.
7589 * elf32-i860.c (elf32_i860_relocate_section): Likewise.
7590 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
7591 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
7592 * elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
7593 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
7594 * elf32-s390.c (elf_s390_relocate_section): Likewise.
7595 * elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
7596 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
7597 * elf64-s390.c (elf_s390_relocate_section): Likewise.
7598 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
7599 * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
7600 * elf32-arm.h (elf32_arm_relocate_section): Likewise #ifndef USE_REL.
7601 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
7602 * elf-m10200.c (elf_backend_rela_normal): Define.
7603 * elf-m10300.c (elf_backend_rela_normal): Define.
7604 * elf32-fr30.c (elf_backend_rela_normal): Define.
7605 * elf32-i370.c (elf_backend_rela_normal): Define.
7606 * elf32-i860.c (elf_backend_rela_normal): Define.
7607 * elf32-m68k.c (elf_backend_rela_normal): Define.
7608 * elf32-mcore.c (elf_backend_rela_normal): Define.
7609 * elf32-openrisc.c (elf_backend_rela_normal): Define.
7610 * elf32-ppc.c (elf_backend_rela_normal): Define.
7611 * elf32-s390.c (elf_backend_rela_normal): Define.
7612 * elf32-xstormy16.c (elf_backend_rela_normal): Define.
7613 * elf64-ppc.c (elf_backend_rela_normal): Define.
7614 * elf64-s390.c (elf_backend_rela_normal): Define.
7615 * elf64-x86-64.c (elf_backend_rela_normal): Define.
7616 * elfxx-ia64.c (elf_backend_rela_normal): Define.
7617 * elf32-arm.h (elf_backend_rela_normal): Define #ifndef USE_REL.
7618 * elf32-m32r.c (elf_backend_rela_normal): Likewise.
7620 2002-05-06 Nick Clifton <nickc@cambridge.redhat.com>
7622 * elf32-arm.h (elf32_arm_final_link_relocate): Convert
7623 'reloc_signed_max' and 'reloc_signed_min' into half-word offsets.
7625 2002-05-06 Alan Modra <amodra@bigpond.net.au>
7627 * elflink.h (elf_link_input_bfd <emit_relocs>): Adjust r_offset
7628 when not relocatable. Fix reloc_emitter call for K&R.
7630 2002-05-04 Alan Modra <amodra@bigpond.net.au>
7632 * elf64-ppc.c (ppc64_elf_relocate_section): Reinstate code
7633 reloading local sym addend mistakenly removed in 2002-05-01 change.
7635 * dwarf2.c (struct line_head): Make prologue_length a bfd_vma.
7636 (read_abbrevs): Change "offset" param to bfd_vma.
7637 (parse_comp_unit): Change "version" and addr_size to unsigned ints.
7638 Change "abbrev_offset" to bfd_vma.
7639 (read_indirect_string): Use correct conversion chars in error
7640 message format string, cast bfd_vma's to unsigned long.
7641 (read_abbrevs): Likewise.
7642 (read_attribute_value): Likewise.
7643 (decode_line_info): Likewise.
7644 (scan_unit_for_functions): Likewise.
7645 (parse_comp_unit): Likewise.
7647 2002-05-04 Tom Rix <trix@redhat.com>
7649 * coffswap.h (coff_swap_reloc_in): Remove XCOFF support.
7650 (coff_swap_reloc_out): Same.
7651 * coff-rs6000.c: (xcoff_swap_reloc_in): Moved from coffswap.h.
7652 (xcoff_swap_reloc_out): Same.
7653 (xcoff_rtype2howto): Renamed from _bfd_xcoff_rtype2howto. Special
7654 case some 16 bit relocs. Add reloc value to output.
7655 (xcoff_howto_table): Remove 64 bit R_POS, add 16 bit
7656 R_RBR. Improve names.
7657 (_bfd_xcoff_reloc_type_lookup): Adjust for removal of 64 bit R_POS.
7658 (bfd_xcoff_backend_data): Update with new reloc swap names.
7659 (bfd_pmac_xcoff_backend_data) : Same.
7660 * coff64-rs6000.c: (xcoff64_swap_reloc_in): Moved from coffswap.h.
7661 (xcoff64_swap_reloc_out): Same.
7662 (xcoff64_rtype2howto): Special case some 16 bit relocs and 32 bit
7663 R_POS. Add reloc value to output.
7664 (xcoff64_howto_table): Move 64 bit R_POS to first entry. Add 16
7665 bit R_RBR. Improve names, masks.
7666 (xcoff64_reloc_type_lookup): Adjust for move of 64 bit R_POS.
7667 (bfd_xcoff_backend_data): Update with new reloc swap names.
7668 (bfd_xcoff_aix5_backend_data) : Same.
7670 2002-05-04 Alan Modra <amodra@bigpond.net.au>
7672 * elf32-hppa.c (struct elf32_hppa_link_hash_table): Add
7673 bfd_count top_index, input_list, all_local_syms.
7674 (elf32_hppa_setup_section_lists): New function, split from
7675 elf32_hppa_size_stubs.
7676 (elf32_hppa_next_input_section): Likewise.
7677 (group_sections): Likewise.
7678 (get_local_syms): Likewise.
7679 (elf32_hppa_size_stubs): Adjust for split out functions. Look for
7680 stubs on undefined syms too.
7681 (elf32_hppa_set_gp): Use bfd_link_hash* instead of elf_link_hash*.
7682 Only access htab elf fields when we have an elf hash table.
7683 * elf32-hppa.h (elf32_hppa_setup_section_lists): Declare.
7684 (elf32_hppa_next_input_section): Declare.
7686 2002-05-04 Bob Byrnes <byrnes@curl.com>
7688 * opncls.c (_bfd_new_bfd_contained_in): Check return value of
7691 2002-05-03 H.J. Lu (hjl@gnu.org)
7693 * elfxx-mips.c (mips_elf_link_hash_entry): Add forced_local.
7694 (mips_elf_link_hash_newfunc): Initialize forced_local to false.
7695 (mips_elf_record_global_got_symbol): Call _bfd_mips_elf_hide_symbol
7696 to hide a global symbol.
7697 (_bfd_mips_elf_hide_symbol): Return if forced_local is true. Set
7698 forced_local to true.
7700 2002-05-02 Richard Henderson <rth@redhat.com>
7702 * elf64-alpha.c (elf64_alpha_relocate_section): Force relative relocs
7703 vs SHN_UNDEF to zero.
7705 2002-05-02 Alan Modra <amodra@bigpond.net.au>
7707 * elf64-ppc.c (ppc64_elf_howto_raw <R_PPC64_SECTOFF>): Change to a
7709 <R_PPC64_SECTOFF_DS>: Likewise.
7710 (ppc64_elf_reloc_type_lookup): Map from BFD_RELOC_16_BASEREL to
7712 * elf32-ppc.c (ppc_elf_howto_raw <R_PPC_SECTOFF>): Correct.
7713 (ppc_elf_reloc_type_lookup): Map from BFD_RELOC_16_BASEREL to
7716 * elf64-ppc.c (ppc64_elf_addr16_ha_reloc): Delete.
7717 (ppc64_elf_ha_reloc): New function.
7718 (ppc64_elf_brtaken_reloc): New function.
7719 (ppc64_elf_sectoff_reloc): New function.
7720 (ppc64_elf_sectoff_ha_reloc): New function.
7721 (ppc64_elf_toc_reloc): New function.
7722 (ppc64_elf_toc_ha_reloc): New function.
7723 (ppc64_elf_toc64_reloc): New function.
7724 (ppc64_elf_unhandled_reloc): New function.
7725 (ppc64_elf_howto_raw): Use the above.
7726 <R_PPC64_RELATIVE>: Mark pc_relative, pcrel_offset.
7727 <R_PPC64_SECTOFF>: Not pc_relative or pcrel_offset. Fix dst_mask.
7728 <R_PPC64_SECTOFF_DS>: Likewise.
7729 (IS_ABSOLUTE_RELOC): Update.
7730 (struct ppc_link_hash_table): Add have_undefweak.
7731 (ppc64_elf_link_hash_table_create): Init.
7732 (func_desc_adjust): Set have_undefweak.
7733 (ppc64_elf_func_desc_adjust): Call func_desc_adjust earlier. Only
7734 add the .sfpr blr when have_undefweak.
7735 (ppc64_elf_setup_section_lists): Check hash table flavour.
7736 (ppc64_elf_next_input_section): Move output_section->owner test to
7738 (ppc64_elf_set_toc): Rename to ppc64_elf_toc, remove info param
7739 and relocatable test. Return TOCstart and don't set elf_gp.
7740 (ppc64_elf_relocate_section): Correct BRTAKEN/BRNTAKEN branch
7741 offset calculation. Add assert on weak sym branch tweaks.
7742 * elf64-ppc.h (ppc64_elf_set_toc): Delete.
7743 (ppc64_elf_toc): Declare.
7744 (ppc64_elf_next_input_section): Update.
7746 2002-05-01 Alan Modra <amodra@bigpond.net.au>
7748 * syms.c (_bfd_stab_section_find_nearest_line): Don't bomb on NULL
7751 2002-05-01 Alan Modra <amodra@bigpond.net.au>
7753 * elf64-ppc.c (CROR_151515, CROR_313131): Define.
7754 (ppc64_elf_relocate_section): Use them. Don't look for plt calls
7755 on R_PPC64_ADDR24 relocs. Require a nop or no link reg on plt
7756 call branches. Correct undefined weak destination.
7757 (ppc64_elf_func_desc_adjust): Always create at least one blr in
7758 .sfpr, and correct case where either only savef* or restf* is
7761 Long branch stubs, multiple stub sections.
7762 * elf64-ppc.h (ppc64_elf_setup_section_lists): Declare.
7763 (ppc64_elf_next_input_section): Declare.
7764 * elf64-ppc.c: Move linker-only prototypes.
7765 (STUB_SUFFIX): Define.
7766 (enum ppc_stub_type): New.
7767 (struct ppc_stub_hash_entry): New.
7768 (struct ppc_branch_hash_entry): New.
7769 (struct ppc_link_hash_entry): Add stub_cache, oh.
7770 (struct ppc_link_hash_table): Add stub_hash_table etc. Remove
7771 sstub. Add sbrlt, srelbrlt, has_14bit_branch, stub_iteration.
7772 Rename plt_overflow to stub_error.
7773 (ppc_stub_hash_lookup): Define.
7774 (ppc_branch_hash_lookup): Define.
7775 (stub_hash_newfunc): New function.
7776 (branch_hash_newfunc): New function.
7777 (link_hash_newfunc): Init new fields.
7778 (ppc64_elf_link_hash_table_create): Likewise.
7779 (ppc64_elf_link_hash_table_free): New function.
7780 (ppc_stub_name): New function.
7781 (ppc_get_stub_entry): New function.
7782 (ppc_add_stub): New function.
7783 (create_linkage_sections): Use bfd_make_section_anyway. Create
7784 .branch_lt and .rela.branch_lt sections. Don't create .stub.
7785 (ppc64_elf_check_relocs): Set has_14bit_branch on R_PPC64_REL14*,
7786 and set up for plt call stubs. Link func and func desc syms.
7787 (ppc64_elf_gc_sweep_hook): Handle REL14* as per REL24.
7788 (func_desc_adjust): Avoid hash lookup when func desc sym available
7789 via shortcut, and set links when processing.
7790 (ppc64_elf_hide_symbol): Likewise.
7791 (allocate_dynrelocs): Don't allocate stub section here.
7792 (ppc64_elf_size_dynamic_sections): Handle sbrlt and srelbrlt.
7794 (ppc_type_of_stub): New function.
7795 (build_one_stub): Delete.
7796 (ppc_build_one_stub): New function.
7797 (ppc_size_one_stub): New function.
7798 (ppc64_elf_setup_section_lists): New function.
7799 (ppc64_elf_next_input_section): New function.
7800 (group_sections): New function.
7801 (get_local_syms): New function.
7802 (ppc64_elf_size_stubs): Rewrite.
7803 (ppc64_elf_build_stubs): Rewrite.
7804 (ppc64_elf_relocate_section): Look up stub entry for REL24
7805 relocs. Don't propagate REL14* to dynamic objects. Look for long
7806 branch stubs if REL14* or REL24 relocs won't reach.
7807 (bfd_elf64_bfd_link_hash_table_free): Define.
7809 2002-04-30 Mark Mitchell <mark@codesourcery.com>
7811 * config.bfd: Add support for powerpc-*-windiss.
7813 2002-04-30 Tom Rix <trix@redhat.com>
7815 * xcofflink.c (xcoff_link_add_symbols): Always copy undef C_EXT
7816 symbol names into the hash table.
7818 2002-04-28 Tom Rix <trix@redhat.com>
7820 * coff-rs6000.c (xcoff_calculate_relocation) : Function table for
7821 calulating relocations.
7822 (xcoff_complain_overflow) : Function table for relocation errors.
7823 (xcoff_ppc_relocate_section): Use relocation and complain function
7825 (xcoff_complain_overflow_unsigned_func): New complain function.
7826 (xcoff_complain_overflow_signed_func): Same.
7827 (xcoff_complain_overflow_bitfield_func): Same.
7828 (xcoff_complain_overflow_dont_func): Same.
7829 (xcoff_reloc_type_crel): New recot function.
7830 (xcoff_reloc_type_br): Same.
7831 (xcoff_reloc_type_ba): Same.
7832 (xcoff_reloc_type_toc): Same.
7833 (xcoff_reloc_type_rel): Same.
7834 (xcoff_reloc_type_neg): Same.
7835 (xcoff_reloc_type_pos): Same.
7836 (xcoff_reloc_type_fail): Same.
7837 (xcoff_reloc_type_noop): Same.
7838 * libxcoff.h : Declare common parts for xcoff64.
7839 * coff64-rs6000.c (xcoff64_ppc_relocate_section): Use relocation
7840 and complain function tables.
7842 2002-04-28 Alan Modra <amodra@bigpond.net.au>
7844 * elf64-x86-64.c (struct elf64_x86_64_dyn_relocs): Comment typo.
7845 * elf32-hppa.c (elf32_hppa_final_link): Formatting.
7847 2002-04-26 Alan Modra <amodra@bigpond.net.au>
7849 * opncls.c (bfd_make_readable): Call bfd_section_list_clear.
7850 * xcofflink.c (xcoff_link_add_dynamic_symbols): Likewise.
7852 * elflink.h (elf_bfd_final_link): Ensure input bfd class is the
7853 same as the output before calling elf_link_input_bfd.
7855 * coffcode.h (coff_compute_section_file_positions): Set
7856 section_tail after shuffling section list.
7858 2002-04-24 Christian Groessler <chris@groessler.org>
7860 * coff-z8k.c (extra_case): Fix R_IMM32 relocations: The
7861 addresses are 23bit with a special layout, not plain 32bit
7862 values. Prevent relocation of immediate values.
7864 2002-04-24 Chris G. Demetriou <cgd@broadcom.com>
7866 * elfxx-mips.c (_bfd_mips_elf_print_private_bfd_data): If MDMX or
7867 MIPS-16 ASE flags are set, print something to indicate that.
7869 2002-04-23 Alan Modra <amodra@bigpond.net.au>
7871 * elf32-hppa.c (hppa_type_of_stub): Correct and simplify condition
7872 under which a plt call stub is used.
7873 (final_link_relocate): Similarly.
7874 (allocate_plt_static): Clear h-plabel except when plt entry is
7875 exclusively used for a plabel.
7876 (allocate_dynrelocs): Use the above to simplify plt sizing.
7877 (struct elf32_hppa_link_hash_table): Add has_22bit_branch.
7878 (elf32_hppa_link_hash_table_create): Init.
7880 (hppa_build_one_stub): Use BL22_RP if has_22bit_branch.
7881 (elf32_hppa_check_relocs): Set has_22bit_branch.
7883 * elf32-hppa.c (elf32_hppa_check_relocs): Remove debug message.
7884 (final_link_relocate): Likewise.
7886 2002-04-22 Jakub Jelinek <jakub@redhat.com>
7888 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't build
7889 search table if some FDE is DW_EH_PE_aligned encoded either.
7890 (_bfd_elf_write_section_eh_frame): Handle terminating FDE specially.
7892 2002-04-22 Richard Smith <richard@ex-parrot.com>
7893 Jakub Jelinek <jakub@redhat.com>
7895 * elf-eh-frame.c (struct eh_cie_fde): Add per_encoding_relative.
7896 (_bfd_elf_discard_section_eh_frame): Set it for CIEs with pcrel
7897 encoded personality.
7898 (_bfd_elf_write_section_eh_frame): Adjust pcrel encoded personality
7899 for CIE/FDE removal.
7901 2002-04-20 Tom Rix <trix@redhat.com>
7903 * coff64-rs6000.c (_bfd_xcoff64_swap_aux_in): Fix C_FILE auxent.
7905 2002-04-20 Alan Modra <amodra@bigpond.net.au>
7907 * archures.c (bfd_lookup_arch): Move the list order comment..
7908 (struct bfd_arch_info): ..to where it belongs.
7909 * bfd-in2.h: Regenerate.
7911 * archures.c (bfd_lookup_arch): Add comment on list order.
7912 (bfd_default_set_arch_mach): Use bfd_lookup_arch.
7913 * cpu-powerpc.c (bfd_powerpc_archs): Re-order so that the default
7914 is always at head of list.
7916 2002-04-18 Nick Clifton <nickc@cambridge.redhat.com>
7918 * coff-arm.c (coff_thumb_pcrel_12, coff_thumb_pcrel_9,
7919 insert_thumb_branch, record_thumb_to_arm_glue): Suppress
7920 definition of these functions for ARM_WINCE builds as they are
7922 (SWAP_IN_RELOC_OFFSET, SWAP_OUT_RELOC_OFFSET): Do not define
7923 for ARM_WINCE builds.
7925 2002-04-18 Nick Clifton <nickc@cambridge.redhat.com>
7927 * coff-arm.c (bfd_arm_process_before_allocation):
7929 2002-04-17 J"orn Rennecke <joern.rennecke@superh.com>
7931 * cpu-sh.c (scan_mach): Delete.
7932 (arch_info_struct): Replace scan_mach with bfd_default_scan.
7933 (bfd_sh_arch): Likewise.
7935 2002-04-16 Nick Clifton <nickc@cambridge.redhat.com>
7937 * ihex.c (ihex_write_object_contents): Fix check for records
7938 crossing 64K boundaries.
7940 2002-04-16 Alan Modra <amodra@bigpond.net.au>
7942 * elf32-m32r.c (m32r_elf_add_symbol_hook): Check the hash table
7943 type rather than just assuming entries are ELF.
7944 * elf32-sh64.c (sh64_elf_add_symbol_hook): Likewise.
7945 * elf64-sh64.c (sh64_elf64_add_symbol_hook): Likewise.
7946 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Likewise.
7947 * elf64-mmix.c (mmix_elf_add_symbol_hook): Use bfd_link_hash_entry
7948 rather than elf_link_hash_entry.
7950 2002-04-15 Richard Henderson <rth@redhat.com>
7952 * elf32-mips.c (mips_elf32_object_p): Revert 0404 fragment: allow
7955 2002-04-15 Michael Snyder <msnyder@redhat.com>
7957 * opncls.c (bfd_close): Write contents if writeable.
7958 Minor formatting tidy-ups.
7960 2002-04-15 Alan Modra <amodra@bigpond.net.au>
7962 * elf32-ppc.c (ppc_elf_add_symbol_hook): Check the hash table type.
7964 2002-04-12 Michael Snyder <msnyder@redhat.com>
7966 * bfd-in.h (bfd_get_section_lma): New access macro.
7967 Minor white-space fix-up.
7969 2002-04-12 Alan Modra <amodra@bigpond.net.au>
7971 * elf.c (prep_headers): Don't zero EI_OSABI, EI_ABIVERSION or
7974 2002-04-09 DJ Delorie <dj@redhat.com>
7976 * elfarm-nabi.c (elf32_arm_howto_table): Fix ABS16 masks.
7978 2002-04-09 Casper S. Hornstrup <chorns@users.sourceforge.net>
7980 * coffcode.h (coff_read_word): New.
7981 (coff_compute_checksum): New.
7982 (coff_apply_checksum): New.
7983 (coff_write_object_contents): Call coff_apply_checksum () to
7984 apply checksum to PE image.
7986 2002-04-08 Randolph Chung <tausq@debian.org>
7988 * elf32-hppa.c (hppa_unwind_entry_compare): Move to elf-hppa.h.
7989 (elf32_hppa_final_link): Split out sorting logic to..
7990 * elf-hppa.h (elf_hppa_sort_unwind): ..here.
7991 (elf_hppa_final_link): Call elf_hppa_sort_unwind.
7993 2002-04-07 Andrew Cagney <ac131313@redhat.com>
7995 * configure.in: Add missing ``|'' to powerpc-*-aix4.[4-9]*
7997 * configure: Re-generate.
7999 2002-04-07 Andrew Cagney <ac131313@redhat.com>
8001 * configure.in: Only define AIX_CORE_DUMPX_CORE when AIX version
8002 is greater or equal to 4.3.3.
8003 * configure: Regenerate.
8006 2002-04-05 Hans-Peter Nilsson <hp@axis.com>
8008 * elf32-cris.c (cris_elf_howto_table) <R_CRIS_16_PCREL,
8009 R_CRIS_32_PCREL>: Fix typo in name.
8010 (cris_elf_check_relocs): Always create .rela.got here when
8011 R_CRIS_16_GOTPLT or R_CRIS_32_GOTPLT is seen.
8012 (elf_cris_adjust_gotplt_to_got): Don't create .rela.got here;
8013 assume it's created.
8015 2002-04-04 Daniel Jacobowitz <drow@mvista.com>
8017 * aout-adobe.c (aout_32_bfd_link_hash_table_free): Define.
8018 * aout-target.h (MY_bfd_link_hash_table_free): Conditionally
8020 * aout-tic30.c (MY_bfd_link_hash_table_free): Likewise.
8021 * bfd.c (bfd_link_hash_table_free): Define.
8022 * binary.c (binary_bfd_link_hash_table_free): Define.
8023 * bout.c (b_out_bfd_link_hash_table_free): Define.
8024 * coff-rs6000.c (rs6000coff_vec): Include
8025 _bfd_generic_link_hash_table_free.
8026 (pmac_xcoff_vec): Likewise.
8027 * coff64-rs6000.c (rs6000coff64_vec): Likewise.
8028 (aix5coff64_vec): Likewise.
8029 * coffcode.h (coff_bfd_link_hash_table_free): Conditionally define.
8030 * elf-m10300.c (elf32_mn10300_link_hash_table_free): New function.
8031 (bfd_elf32_bfd_link_hash_table_free): Define.
8032 * elf32-hppa.c (elf32_hppa_link_hash_table_free): New function.
8033 (bfd_elf32_bfd_link_hash_table_free): Define.
8034 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_free): Conditionally
8036 * i386msdos.c (msdos_bfd_link_hash_table_free): Define.
8037 * i386os9k.c (os9k_bfd_link_hash_table_free): Define.
8038 * ieee.c (ieee_bfd_link_hash_table_free): Define.
8039 * ihex.c (ihex_bfd_link_hash_table_free): Define.
8040 * libbfd-in.h (_bfd_nolink_bfd_link_hash_table_free): Define.
8041 (_bfd_generic_link_hash_table_free): Add prototype.
8042 * libcoff-in.h (_bfd_xcoff_bfd_link_hash_table_free): Add prototype.
8043 * libecoff.h (_bfd_ecoff_bfd_link_hash_table_free): Define.
8044 * linker.c (_bfd_generic_link_hash_table_free): New function.
8045 * mmo.c (mmo_bfd_link_hash_table_free): Define.
8046 * nlm-target.h (nlm_bfd_link_hash_table_free): Define.
8047 * oasys.c (oasys_bfd_link_hash_table_free): Define.
8048 * ppcboot.c (ppcboot_bfd_link_hash_table_free): Define.
8049 * som.c (som_bfd_link_hash_table_free): Define.
8050 * srec.c (srec_bfd_link_hash_table_free): Define.
8051 * tekhex.c (tekhex_bfd_link_hash_table_free): Define.
8052 * versados.c (versados_bfd_link_hash_table_free): Define.
8053 * vms.c (vms_bfd_link_hash_table_free): New function.
8054 * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_free): New function.
8056 * coff-arm.c (coff_arm_link_hash_table_create): Use bfd_malloc
8057 instead of bfd_alloc.
8058 * coff-h8300.c (h8300_coff_link_hash_table_create): Likewise.
8059 * coff-mcore.c (coff_mcore_link_hash_table_create): Likewise.
8060 * coff-ppc.c (ppc_coff_link_hash_table_create): Likewise.
8061 * cofflink.c (_bfd_coff_link_hash_table_create): Likewise.
8062 * ecoff.c (_bfd_ecoff_bfd_link_hash_table_create): Likewise.
8063 * elf-m10300.c (elf32_mn10300_link_hash_table_create): Likewise.
8064 * elf.c (_bfd_elf_link_hash_table_create): Likewise.
8065 * elf32-arm.h (elf32_arm_link_hash_table_create): Likewise.
8066 * elf32-cris.c (elf_cris_link_hash_table_create): Likewise.
8067 * elf32-hppa.c (elf32_hppa_link_hash_table_create): Likewise.
8068 * elf32-i386.c (elf_i386_link_hash_table_create): Likewise.
8069 * elf32-m68k.c (elf_m68k_link_hash_table_create): Likewise.
8070 * elf32-s390.c (elf_s390_link_hash_table_create): Likewise.
8071 * elf32-sh.c (sh_elf_link_hash_table_create): Likewise.
8072 * elf64-alpha.c (elf64_alpha_bfd_link_hash_table_create): Likewise.
8073 * elf64-ppc.c (ppc64_elf_link_hash_table_create): Likewise.
8074 * elf64-s390.c (elf_s390_link_hash_table_create): Likewise.
8075 * elf64-sh64.c (sh64_elf64_link_hash_table_create): Likewise.
8076 * elf64-sparc.c (sparc64_elf_bfd_link_hash_table_create): Likewise.
8077 * elf64-x86-64.c (elf64_x86_64_link_hash_table_create): Likewise.
8078 * elfxx-mips.c (_bfd_mips_elf_link_hash_table_create): Likewise.
8079 * linker.c (_bfd_generic_link_hash_table_create): Likewise.
8080 * m68klinux.c (linux_link_hash_table_create): Likewise.
8081 * sparclinux.c (linux_link_hash_table_create): Likewise.
8082 * sunos.c (sunos_link_hash_table_create): Likewise.
8083 * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_create): Likewise.
8085 * targets.c: Add _bfd_link_hash_table_free to xvec.
8087 * bfd-in2.h: Regenerate.
8088 * libbfd.h: Regenerate.
8089 * libcoff.h: Regenerate.
8091 2002-04-04 Alan Modra <amodra@bigpond.net.au>
8093 * dep-in.sed: Cope with absolute paths.
8094 * Makefile.am (dep.sed): Subst TOPDIR, and not INCDIR.
8096 * Makefile.in: Regenerate.
8097 * coff-arm.c: Fix copyright date.
8098 * cpu-h8300.c: Likewise.
8099 * cpu-i370.c: Likewise.
8100 * cpu-s390.c: Likewise.
8101 * cpu-mips.c: Likewise.
8102 * po/SRC-POTFILES.in: Regenerate.
8104 2002-04-04 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
8106 * Makefile.am: Add elfxx-mips.c to the known backends.
8107 (elf32-mips.lo): remove dependency to coff/external.h.
8108 * Makefile.in: Regenerate.
8109 * configure.in: Add elfxx-mips.lo to all vectors using elf32-mips.lo
8110 Remove elf32-mips.lo from 64 bit vectors. Update dependencies
8112 * configure: Regenerate.
8113 * elf-bfd.h: Move all MIPS ELF specific prototypes to elfxx-mips.h.
8114 (irix_compat_t): IRIX compatibility level, moved from elf32-mips.c.
8115 (elf_backend_mips_irix_compat, elf_backend_mips_rtype_to_howto): New
8116 MIPS specific backend functions.
8117 * elf32-mips.c: Moved most code to elfxx-mips.c.
8118 (mips_elf_hi16_reloc): Rename from _bfd_mips_elf_hi16_reloc and make
8120 (mips_elf_lo16_reloc): Likewise, was _bfd_mips_elf_lo16_reloc.
8121 (mips_elf_got16_reloc): Likewise, was _bfd_mips_elf_got16_reloc.
8122 (mips_elf_gprel32_reloc): Likewise, was _bfd_mips_elf_gprel32_reloc.
8123 (mips_elf32_rtype_to_howto): Rename from mips_rtype_to_howto. Changed
8124 interface to allow selection of the right REL or RELA howto table.
8125 (mips_elf32_object_p): Rename from _bfd_mips_elf_object_p and made
8126 static. Let it refuse n32 objects.
8127 (elf32_mips_grok_prstatus): Rename from _bfd_elf32_mips_grok_prstatus.
8128 (elf32_mips_grok_psinfo): Rename from _bfd_elf32_mips_grok_psinfo.
8129 (elf32_mips_discard_info): Rename from _bfd_elf32_mips_discard_info.
8130 (elf32_mips_ignore_discarded_relocs): Rename from
8131 _bfd_elf32_mips_ignore_discarded_relocs.
8132 (elf32_mips_write_section): Rename from _bfd_elf32_mips_write_section.
8133 (elf32_mips_irix_compat): New function, replaces IRIX_COMPAT.
8134 (elf_mips_howto_table_rela): Remove.
8135 * elf64-mips.c: Moved most code to elfxx-mips.c.
8136 (bfd_elf64_bfd_reloc_type_lookup): Make static.
8137 (mips_elf64_rtype_to_howto): New function.
8138 (mips_elf64_object_p): Likewise.
8139 (elf64_mips_irix_compat): Likewise.
8140 * elfxx-mips.c: New file containing common code merged together from
8141 elf32-mips.c and elf64-mips.c.
8142 * elfxx-mips.h: New file containing MIPS specific prototypes from
8144 * elfxx-target.h: Add handling for elf_backend_mips_irix_compat and
8145 elf_backend_mips_rtype_to_howto.
8147 2002-04-04 Alan Modra <amodra@bigpond.net.au>
8149 * srec.c (MAXCHUNK, Chunk): Revise comments.
8150 (srec_write_record): Correct buffer size.
8151 (srec_write_header): Do without intermediate buffer.
8152 (srec_write_section): Validate Chunk.
8153 (srec_write_terminator): Pass NULL instead of dummy buffer.
8154 (srec_write_symbols): Pass file and symbol names directly to
8155 bfd_bwrite so sprintf won't overflow buffer.
8157 2002-04-03 Jakub Jelinek <jakub@redhat.com>
8159 * elf32-sparc.c (elf32_sparc_relocate_section): Don't emit dynamic
8160 PC relative relocs against hidden symbols.
8161 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
8163 2002-04-03 Alan Modra <amodra@bigpond.net.au>
8165 * elf.c (_bfd_elf_make_section_from_shdr): When setting section
8166 LMAs, loop over segments until p_vaddr and p_memsz specify an
8167 extent enclosing the section.
8169 2002-04-02 Nick Clifton <nickc@cambridge.redhat.com>
8171 * ihex.c (ihex_write_object_contents): Do not allow records to
8172 cross a 64K boundary - wrap if necessary.
8174 2002-04-01 Nathan Williams <nathanw@wasabisystems.com>
8176 * elf.c (elfcore_netbsd_get_lwpid): Fix off-by-one error
8177 which caused the returned LWP ID to always be 0.
8179 2002-04-01 Richard Henderson <rth@redhat.com>
8181 * elf32-sparc.c (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
8182 (elf32_sparc_relocate_section): Use it to figure out when to
8183 initialize .got entries.
8184 * elf64-sparc.c: Similarly.
8186 2002-03-28 Alan Modra <amodra@bigpond.net.au>
8188 * linker.c (link_action): Ignore duplicate warning syms.
8189 (_bfd_generic_link_write_global_symbol): Follow warning symbol link.
8190 * elflink.h (elf_adjust_dynstr_offsets): Likewise.
8191 (elf_adjust_dynamic_symbol): Likewise.
8192 (elf_export_symbol): Likewise.
8193 (elf_link_find_version_dependencies): Likewise.
8194 (elf_link_assign_sym_version): Likewise.
8195 (elf_link_sec_merge_syms): Likewise.
8196 (elf_link_output_extsym): Likewise.
8197 (elf_gc_sweep_symbol): Likewise.
8198 (elf_gc_propagate_vtable_entries_used): Likewise.
8199 (elf_gc_smash_unused_vtentry_relocs): Likewise.
8200 (elf_gc_allocate_got_offsets): Likewise.
8201 (elf_collect_hash_codes): Likewise.
8202 * elflink.c (elf_link_renumber_hash_table_dynsyms): Likewise.
8203 * elf-hppa.h (elf_hppa_unmark_useless_dynamic_symbols): Likewise.
8204 (elf_hppa_remark_useless_dynamic_symbols): Likewise.
8205 * elf-m10300.c (elf32_mn10300_finish_hash_table_entry): Likewise.
8206 * elf32-arm.h (elf32_arm_discard_copies): Likewise.
8207 * elf32-cris.c (elf_cris_adjust_gotplt_to_got): Likewise.
8208 (elf_cris_discard_excess_dso_dynamics): Likewise.
8209 * elf32-hppa.c (clobber_millicode_symbols): Likewise.
8210 (mark_PIC_calls): Likewise.
8211 (allocate_plt_static): Likewise.
8212 (allocate_dynrelocs): Likewise.
8213 (readonly_dynrelocs): Likewise.
8214 * elf32-i386.c (allocate_dynrelocs): Likewise.
8215 (readonly_dynrelocs): Likewise.
8216 * elf32-i370.c (i370_elf_adjust_dynindx): Likewise.
8217 * elf32-m68k.c (elf_m68k_discard_copies): Likewise.
8218 * elf32-mips.c (mips_elf_output_extsym): Likewise.
8219 (mips_elf_sort_hash_table_f): Likewise.
8220 (mips_elf_check_mips16_stubs): Likewise.
8221 * elf32-s390.c (allocate_dynrelocs): Likewise.
8222 (readonly_dynrelocs): Likewise.
8223 * elf32-sh.c (sh_elf_discard_copies): Likewise.
8224 * elf32-xstormy16.c (xstormy16_relax_plt_check): Likewise.
8225 (xstormy16_relax_plt_realloc): Likewise.
8226 * elf64-alpha.c (elf64_alpha_calc_got_offsets_for_symbol): Likewise.
8227 (elf64_alpha_output_extsym): Likewise.
8228 * elf64-hppa.c (elf64_hppa_mark_exported_functions): Likewise.
8229 * elf64-mips.c (mips_elf64_sort_hash_table_f): Likewise.
8230 (mips_elf64_check_mips16_stubs): Likewise.
8231 (mips_elf64_output_extsym): Likewise.
8232 * elf64-ppc.c (func_desc_adjust): Likewise.
8233 (allocate_dynrelocs): Likewise.
8234 (readonly_dynrelocs): Likewise.
8235 * elf64-s390.c (allocate_dynrelocs): Likewise.
8236 (readonly_dynrelocs): Likewise.
8237 * elf64-sh64.c (sh64_elf64_discard_copies): Likewise.
8238 * elf64-x86-64.c (allocate_dynrelocs): Likewise.
8239 (readonly_dynrelocs): Likewise.
8240 * elfxx-ia64.c (elfNN_ia64_global_dyn_sym_thunk): Likewise.
8241 * aoutx.h (aout_link_write_other_symbol): Likewise.
8242 * cofflink.c (_bfd_coff_write_task_globals): Likewise.
8243 (_bfd_coff_write_global_sym): Likewise.
8244 * i386linux.c (linux_tally_symbols): Likewise.
8245 * m68klinux.c (linux_tally_symbols): Likewise.
8246 * sparclinux.c (linux_tally_symbols): Likewise.
8247 * pdp11.c (aout_link_write_other_symbol): Likewise.
8248 * sunos.c (sunos_scan_dynamic_symbol): Likewise.
8249 * xcofflink.c (xcoff_build_ldsyms): Likewise.
8250 (xcoff_write_global_symbol): Likewise.
8252 * cofflink.c (_bfd_coff_final_link): Formatting.
8253 * cpu-mips.c (mips_compatible): Make static, prototype.
8254 * elf32-i386.c (elf_i386_check_relocs): Formatting.
8255 * elf32-sh.c (sh_elf_size_dynamic_sections): Likewise.
8256 * elf64-alpha.c (elf64_alpha_output_extsym): Likewise.
8257 * elf64-mips.c (mips_elf64_sort_hash_table): Likewise.
8258 (mips_elf64_final_link): Likewise.
8259 * elflink.h (elf_link_find_version_dependencies): Remove duplicate
8262 2002-03-27 Nick Clifton <nickc@cambridge.redhat.com>
8264 * coff-arm.c (SWAP_IN_RELOC_OFFSET): Define.
8265 (SWAP_OUT_RELOC_OFFSET): Define.
8267 2002-03-27 Gregory Steuck <greg@nest.cx>
8269 * elf.c (_bfd_elf_get_symtab_upper_bound): Leave space for
8270 terminating NULL if empty symbol table.
8271 (_bfd_elf_get_dynamic_symtab_upper_bound): Likewise.
8273 2002-03-26 H.J. Lu (hjl@gnu.org)
8275 * elflink.h (elf_link_input_bfd): Revert the last change since
8276 the gcc exception handling isn't fixed yet.
8278 2002-03-26 H.J. Lu (hjl@gnu.org)
8280 * elflink.h (elf_link_input_bfd): Complain about relocations
8281 against local symbols in discarded sections.
8283 2002-03-26 Alan Modra <amodra@bigpond.net.au>
8285 * elflink.h (elf_gc_mark): Don't recurse into non-ELF sections.
8287 2002-03-23 Alan Modra <amodra@bigpond.net.au>
8289 * elf.c (_bfd_elf_make_section_from_shdr): Don't set lma based on
8290 section file offset for !SEC_LOAD sections.
8292 2002-03-21 Richard Earnshaw <rearnsha@arm.com>
8294 * elf32-arm.h (elf32_arm_final_link_relocate <case R_ARM_GOTOFF>,
8295 <case R_ARM_GOT>): Handle relocations to Thumb functions.
8297 2002-03-21 Alan Modra <amodra@bigpond.net.au>
8299 * coff64-rs6000.c (_bfd_xcoff64_put_symbol_name): Prototype.
8301 * archive.c: Update copyright date.
8302 * bfd-in2.h: Regenerate.
8303 * libbfd.h: Regenerate.
8304 * Makefile.am: Run "make dep-am"
8305 * Makefile.in: Regenerate.
8306 * po/SRC-POTFILES.in: Regenerate.
8308 2002-03-20 Daniel Jacobowitz <drow@mvista.com>
8310 * dwarf2.c (struct funcinfo): Move up.
8311 (lookup_address_in_function_table): New argument function_ptr.
8313 (lookup_address_in_line_table): New argument function. If function
8314 is non-NULL, use it to handle ``addr'' before the first line note of
8316 (comp_unit_find_nearest_line): Update and swap calls to
8317 lookup_address_in_function_table and lookup_address_in_line_table.
8318 * syms.c (_bfd_stab_section_find_nearest_line): Use the first
8319 N_SLINE encountered if we see an N_FUN before any N_SLINE.
8321 2002-03-20 Tom Rix <trix@redhat.com>
8323 * coff-rs6000.c (_bfd_xcoff_stat_arch_elt): Renamed from
8324 _bfd_xcoff_generic_stat_arch_elt. Fix format check.
8325 * coff64-rs6000.c : Use _bfd_xcoff_stat_arch_elt.
8327 2002-03-19 Tom Rix <trix@redhat.com>
8329 * xcofflink.c (_bfd_xcoff_bfd_link_add_symbols): Look through all
8330 dynamic objects in archives.
8332 2002-03-19 Hans-Peter Nilsson <hp@bitrange.com>
8334 * elflink.h (NAME(bfd_elf,record_link_assignment)): Don't set
8335 STT_NOTYPE symbols to STT_OBJECT.
8337 2002-03-18 Jan Hubicka <jh@suse.cz>
8339 * cpu-i386.c (bfd_x86_64_arch): Rename to "i386:x86-64"
8341 2002-03-18 Tom Rix <trix@redhat.com>
8343 * aix5ppc.core.c : New file for AIX 5 64 bit core support.
8344 * bfd-in.h : Add bfd_xcoff_ar_archive_set_magic declaration.
8345 * coff-rs6000 (do_pad) : New function for archive padding.
8346 (do_copy) : New function for object file copying in archives.
8347 (do_shared_object_padding) : New function for padding shared
8348 objects to their text section alignment in archives.
8349 (bfd_xcoff_ar_achive_set_magic) : Stub.
8350 (xcoff_write_armap_big) : Use do_copy and do_pad.
8351 (xcoff_write_archive_contents_big) : Use do_shared_object_padding,
8353 * coff64-rs6000.c (xcoff64_write_ojbect_contents) : Use
8354 bfd_xcoff_magic_number.
8355 (xcoff64_bad_format_hook) : New function for _bfd_bad_format_hook
8357 (xcoff_backend_data_r) : Use xcoff64_bad_format_hook.
8358 (bfd_xcoff_aix5_backend_data) : New Aix 5 backend data.
8359 (aix5coff64_vec) : New Aix 5 target aix5coff64-rs6000.
8360 * rs6000-core.c : Update copyright date.
8361 * xcofflink.c (bfd_xcoff_size_dynamic_sections): Check for NULL
8363 * coffcode.h (coff_new_section_hook) : Use new accessor macros.
8364 (coff_set_arch_mach_hook) : Add Aix 5 U64_TOCMAGIC magic #.
8365 (coff_set_flags) : Use bfd_xcoff_magic_number.
8366 * libxcoff.h (bfd_xcoff_is_xcoff64): Add U64_TOCMAGIC.
8367 * configure.in : Add powerpc-*-aix5 and rs6000-*-aix5 support.
8368 * Makefile.am : Same.
8369 * config.bfd : Same.
8371 * configure : Regnerate.
8372 * Makefile.in : Same.
8375 2002-03-18 Nick Clifton <nickc@cambridge.redhat.com>
8377 * po/fr.po: Updated version.
8379 2002-03-18 Alan Modra <amodra@bigpond.net.au>
8381 * libbfd.c (bfd_write_bigendian_4byte_int): Return true iff success.
8382 * libbfd.h: Regenerate.
8383 * archive.c (coff_write_armap): Pass on failures from
8384 bfd_write_bigendian_4byte_int.
8386 2002-03-14 H.J. Lu <hjl@gnu.org>
8388 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set the BFD
8389 error to bfd_error_nonrepresentable_section for reinit_array
8392 2002-03-14 Nick Clifton <nickc@cambridge.redhat.com>
8394 * coffcode.h (coff_slurp_symbol_table): When adding BSF_WEAK flag,
8395 OR it in rather than replacing previously selected flags.
8397 * elfxx-target.h (TARGET_BIG_SYM): Set ar_max_namelen to 15.
8398 (TARGET_LITTLE_SYM): Set ar_max_namelen to 15.
8400 2002-03-14 Alan Modra <amodra@bigpond.net.au>
8402 * cpu-mips.c (mips_compatible): New. Don't check bits_per_word.
8404 * elflink.h (elf_bfd_final_link): Revert last change. Instead,
8405 ensure reloc size matches before calling elf_link_input_bfd.
8406 Add an assert to check reloc size when counting output relocs.
8408 2002-03-14 Nick Clifton <nickc@cambridge.redhat.com>
8410 * mmo.c (mmo_get_loc): Return NULL rather than false.
8412 2002-03-13 Nick Clifton <nickc@cambridge.redhat.com>
8414 * po/fr.po: Updated version.
8416 2002-03-13 Alan Modra <amodra@bigpond.net.au>
8418 * archures.c (bfd_default_compatible): Test bits_per_word.
8419 * cpu-i386.c (i386_compatible): Remove. Replace occurrences with
8420 bfd_default_compatible.
8421 * cpu-i370.c (i370_compatible): Likewise.
8422 * cpu-sparc.c (sparc_compatible): Likewise.
8423 * cpu-h8300.c (compatible): Test in->arch == out->arch.
8425 * elflink.h: Formatting fixes.
8426 (elf_link_output_extsym): Merge undefined and undef weak cases.
8428 * elflink.h (elf_bfd_final_link): Only call elf_link_input_bfd
8429 when word size of input matches output word size.
8431 2002-03-12 Andreas Jaeger <aj@suse.de>
8433 * cpu-i386.c (i386_compatible): New. Use it instead of
8434 bfd_default_compatible.
8436 2002-03-07 H.J. Lu (hjl@gnu.org)
8438 * coff-sh.c (shcoff_reloc_map): Use bfd_reloc_code_real_type
8439 as the type for bfd_reloc_val.
8441 2002-03-05 John David Anglin <dave@hiauly1.hia.nrc.ca>
8443 * elf-hppa.h (elf_hppa_is_dynamic_loader_symbol): New function.
8444 (elf_hppa_relocate_section): Ignore undefined dynamic loader symbols.
8445 (elf_hppa_final_link_relocate): Correct relocations for indirect
8446 references to local data through the DLT. Fix .opd creation for
8447 local symbols using R_PARISC_LTOFF_FPTR32 and R_PARISC_FPTR64
8448 relocations. Use e_lsel selector for R_PARISC_DLTIND21L,
8449 R_PARISC_LTOFF_FPTR21L and R_PARISC_LTOFF_TP21L as per
8450 "Processor-Specific ELF for PA_RISC, Version 1.43" document.
8451 Similarly, use e_rsel for DLT and LTOFF 'R' relocations.
8452 * elf32-hppa.c (final_link_relocate): Revise relocation selectors
8453 as per "Processor-Specific ELF for PA_RISC, Version 1.43" document.
8455 2002-03-05 Jakub Jelinek <jakub@redhat.com>
8457 * merge.c (_bfd_merge_sections): Don't segfault if there
8458 is nothing to merge due to GC.
8460 2002-03-05 Alan Modra <amodra@bigpond.net.au>
8462 * elf32-hppa.c (clobber_millicode_symbols): Remove hack to keep
8463 symbols that have been forced local.
8465 * elflink.h (elf_bfd_final_link): Call elf_link_output_extsym
8466 to output forced local syms for non-shared link.
8467 (elf_link_output_extsym): Tweak condition for calling backend
8468 adjust_dynamic_symbol so that previous behaviour is kept.
8469 Whitespace changes throughout file.
8471 2002-03-04 H.J. Lu <hjl@gnu.org>
8473 * elf.c (bfd_section_from_shdr): Handle special sections,
8474 .init_array, .fini_array and .preinit_array.
8475 (elf_fake_sections): Likewise.
8477 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Create the
8478 DT entry only if the section is in output for .init_array,
8479 .fini_array and .preinit_array. Complain about .preinit_array
8481 (elf_bfd_final_link): Warn zero size for .init_array,
8482 .fini_array and .preinit_array sections.
8484 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Remove
8485 SHT_INIT_ARRAY, SHT_FINI_ARRAY and SHT_PREINIT_ARRAY.
8486 (elfNN_ia64_fake_sections): Remove .init_array, .fini_array and
8489 2002-03-04 Alan Modra <amodra@bigpond.net.au>
8491 * configure.in (WIN32LIBADD): Don't eval PICFLAG assignment.
8492 * configure: Regenerate.
8494 2002-03-02 Tom Rix <trix@redhat.com>
8496 * coff64-rs6000.c (xcoff64_howto_table): Replace howto types with
8498 * coff-rs6000.c (xcoff_howto_table): Same.
8500 2002-03-01 David Mosberger <davidm@hpl.hp.com>
8502 * elflink.h (size_dynamic_sections): If section named
8503 ".preinit_array" exists, create DT_PREINIT_ARRAY and
8504 DT_PREINIT_ARRAYSZ entries in dynamic table. Analogously for
8505 ".init_array" and ".fini_array".
8506 (elf_bfd_final_link): Handle DT_PREINIT_ARRAYSZ, DT_INIT_ARRAYSZ,
8507 DT_FINI_ARRAYSZ, DT_PREINIT_ARRAY, DT_INIT_ARRAY, and
8510 2002-02-26 Andrew Macleod <amacleod@cygnus.com>
8512 * elflink.h (elf_bfd_final_link): Don't crash on SHN_UNDEF local
8515 2002-02-25 Alan Modra <amodra@bigpond.net.au>
8517 * elf64-hppa.h: Update copyright date.
8519 * elf64-ppc.c (ppc64_elf_check_relocs): Warning fix.
8520 (ppc64_elf_relocate_section): Don't generate power4 style branch
8521 hints for *_BRTAKEN and *_BRNTAKEN relocs.
8523 2002-02-22 Jakub Jelinek <jakub@redhat.com>
8525 * elf64-sh64.c (sh_elf64_relocate_section): Fix a typo from my
8527 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
8529 2002-02-21 Andreas Jaeger <aj@suse.de>
8531 * elf64-x86-64.c: Major rework that introduces all recent changes
8532 to the x86-64 backend. Get a closer match to elf32-i386.
8533 (struct elf64_x86_64_dyn_relocs): Rename from
8534 elf64_x86_64_pcrel_relocs_copied, add additional fields. Change
8536 (struct elf64_x86_64_link_hash_table): Add short cuts to some
8538 (link_hash_newfunc): Rename from elf64_x86_64_link_hash_newfunc,
8539 remove casts, initialize new hash members.
8540 (create_got_section): New.
8541 (elf64_x86_64_create_dynamic_sections): New.
8542 (elf64_x86_64_copy_indirect_symbol): New.
8543 (elf64_x86_64_check_relocs): Don't allocate space for dynamic
8544 relocs, .got or .relgot here but do it in allocate_dynrelocs.
8545 Reference count possible .plt and .got entries. Don't test input
8546 section SEC_READONLY here to try to avoid copy relocs, and keep
8547 dyn_relocs regardless of ELF_LINK_NON_GOT_REF. Don't set
8548 DF_TEXTREL here. Delay setting of variables until needed. Cache
8549 pointer to "sreloc" section in elf_section_data. Tweak condition
8550 under which .got created. Report files with bad relocation
8552 (elf64_x86_64_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
8553 Reference count possible .plt entries. Don't deallocate .got and
8555 (elf64_x86_64_adjust_dynamic_symbol): Handle nocopyreloc. Don't
8556 do copy reloc processing for weakdefs. Remove redundant casts and
8557 aborts. Delay setting of vars until needed. Move creation of
8558 dynamic symbols and allocation of .plt and .rela.plt to
8559 allocate_dynrelocs. Replace BFD_ASSERT with abort.
8560 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
8561 (allocate_dynrelocs): New.
8562 (readonly_dynrelocs): New.
8563 (elf64_x86_64_size_dynamic_sections): Call readonly_dynrelocs.
8564 Allocate space for dyn relocs. Replace BFD_ASSERT with abort.
8565 Zero out the dynamic allocated content space.
8566 (elf64_x86_64_discard_copies): Removed.
8567 (elf64_x86_64_relocate_section): Make use of dynamic section
8568 short-cuts. Localise vars, and delay setting. Better error
8569 reporting, replace BFD_ASSERT with abort. Check
8570 ELF_LINK_HASH_DEF_DYNAMIC to see if a symbol is not defined in the
8571 regular object file and tread the weak definition as the normal
8572 one. Don't discard relocs for undefweak or undefined symbols and
8573 check !DEF_REGULAR as well as DEF_DYNAMIC in test for avoided copy
8575 (elf64_x86_64_finish_dynamic_symbol): Don't copy relocs for
8576 symbols that have been forced local. Use same test to decide if
8577 we can use a relative reloc for got as relocate_section. Expand
8578 SHN_UNDEF comment. Move expressions out of function calls.
8579 Replace BFD_ASSERT with abort.
8580 (bfd_elf64_bfd_final_link): Removed.
8581 (elf_backend_copy_indirect_symbol): Define.
8583 2002-02-20 Tom Rix <trix@redhat.com>
8585 * coff-rs6000.c (xcoff_howto_table): Add 16 bit R_BA.
8586 (_bfd_xcoff_reloc_type_lookup): Use it.
8587 * coff64-rs6000.c (xcoff64_howto_table): Same.
8588 (xcoff64_reloc_type_lookup): Same.
8590 2002-02-20 Peter Schauer <pes@regent.e-technik.tu-muenchen.de>
8592 * osf-core.c (osf_core_vec): OSF/1 (Digital Unix) core files are
8595 2002-02-19 Martin Schwidefsky <schwidefsky@de.ibm.com>
8597 * archures.c (bfd_mach_s390_esa): Rename to bfd_mach_s390_31.
8598 (bfd_mach_s390_esame): Rename to bfd_mach_s390_64.
8599 * bfd-in2.h: Regenerate.
8600 * cpu-s390.c (arch_info_struct): Use renamed architecture defines.
8601 Replace architecture name "s390" with "s390:31-bit" and "s390:esame"
8603 * elf32-s390.c (elf_howto_table): Add 32 bit pc relative relocations.
8604 (elf_s390_reloc_type_lookup): Likewise.
8605 (elf_s390_check_relocs): Likewise.
8606 (elf_s390_gc_sweep_hook): Likewise.
8607 (elf_s390_relocate_section): Likewise.
8608 (elf_s390_object_p): Use renamed architecture define.
8609 * elf64-s390.c (elf_s390_object_p): Use renamed architecture define.
8611 2002-02-19 Frank Ch. Eigler <fche@redhat.com>
8613 * syms.c (stt[]): Sorted. Added .init/.fini -> "t" mapping.
8615 2002-02-19 Jakub Jelinek <jakub@redhat.com>
8617 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Enable
8618 absptr -> pcrel optimization for shared libs.
8619 Only create minimal .eh_frame_hdr if absptr FDE encoding in shared
8620 library cannot be converted to pcrel.
8621 (_bfd_elf_eh_frame_section_offset): Return -2 if making absptr
8623 * elf32-i386.c (elf_i386_relocate_section): If
8624 _bfd_elf_section_offset returned -2, skip, but make sure the
8625 relocation is installed.
8626 * elf32-arm.h (elf32_arm_final_link_relocate): Likewise.
8627 * elf32-cris.c (cris_elf_relocate_section): Likewise.
8628 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
8629 * elf32-i370.c (i370_elf_relocate_section): Likewise.
8630 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
8631 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
8632 * elf32-s390.c (elf_s390_relocate_section): Likewise.
8633 * elf32-sh.c (sh_elf_relocate_section): Likewise.
8634 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
8635 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
8636 * elf64-s390.c (elf_s390_relocate_section): Likewise.
8637 * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
8638 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
8639 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
8640 * elf64-alpha.c (elf64_alpha_relocate_section): Handle
8641 _bfd_elf_section_offset returning -2 the same way as -1.
8642 * elfxx-ia64.c (elfNN_ia64_install_dyn_reloc): Likewise.
8643 * elf32-mips.c (mips_elf_create_dynamic_relocation): Add FIXME
8645 * elf64-mips.c (mips_elf64_create_dynamic_relocation): Likewise.
8647 2002-02-18 Tom Rix <trix@redhat.com>
8649 * xcofflink.c (bfd_xcoff_link_gernate_rtinit): Add -brtl support.
8650 (bfd_xcoff_size_dynamic_sections): Same.
8651 * bfd-in.h (bfd_xcoff_link_generate_rtinit): Same.
8652 (bfd_xcoff_size_dynamic_sections): Same.
8653 * coff-rs6000.c (xcoff_generate_rtinit): Same.
8654 * coff-rs646000.c (xcoff64_generate_rtinit): Same.
8655 * libxcoff.h (struct xcoff_backend_data_rec): Same.
8656 * xcofflink.c (xcoff_build_ldsyms, xcoff_link_add_symbols): Clean.
8657 * bfd-in2.h: Regenerate.
8659 2002-02-18 Alan Modra <amodra@bigpond.net.au>
8661 * elf64-ppc.c (STFD_FR0_0R1, LFD_FR0_0R1, BLR): Define.
8662 (struct ppc_link_hash_table): Add sfpr.
8663 (ppc64_elf_link_hash_table_create): Init it.
8664 (ppc64_elf_create_dynamic_sections): Split creation of .stub and
8666 (create_linkage_sections): ..here. Make .sfpr too.
8667 (ppc64_elf_check_relocs): Call create_linkage_sections, and set
8669 (MIN_SAVE_FPR, MAX_SAVE_FPR): Define.
8670 (ppc64_elf_func_desc_adjust): Look for missing ._savef* and
8671 ._restf* functions, and create as needed.
8672 (func_desc_adjust): Only force_local for shared libs.
8674 2002-02-18 David O'Brien <obrien@FreeBSD.org>
8676 * configure.in: Bump version number post 2.12 branching.
8677 * configure: Regenerate.
8679 2002-02-17 Hans-Peter Nilsson <hp@bitrange.com>
8681 * mmo.c: Correct and improve comments.
8682 (mmo_write_chunk): Store trailing byte in bfd buffer; don't
8683 zero-pad. Use input to fill up non-empty bfd buffer.
8684 (mmo_flush_chunk): New function.
8685 (mmo_write_loc_chunk): Add parameter last_vmap, all callers
8686 changed. Don't emit location specifier if VMA is same as
8687 *LAST_VMAP after omitting leading zero contents. Call
8688 mmo_flush_chunk before emitting location specifier.
8689 (mmo_write_loc_chunk_list): Call mmo_flush_chunk when finished
8690 with mmo_write_loc_chunk calls.
8691 (mmo_internal_write_section): Call mmo_flush_chunk after
8693 (mmo_write_symbols_and_terminator): Move :Main to first position
8694 in symbol array. Add faked one if it does not exist if there are
8695 other symbols. Don't add it if there are no symbols at all. Move
8696 out test for value of :Main from symbol loop. Rename table
8697 fakemain to maintable and variable mainsym to fakemain.
8699 2002-02-15 Richard Henderson <rth@redhat.com>
8701 * elf64-alpha.c (elf64_alpha_relocate_section) [BRSGP]: A target
8702 section with no got matches any got. Simplify error generaion.
8704 2002-02-15 Alan Modra <amodra@bigpond.net.au>
8706 Support arbitrary length fill patterns.
8707 * linker.c (bfd_new_link_order): Zero all fields with bfd_zalloc.
8708 (_bfd_default_link_order): Remove bfd_fill_link_order code.
8709 Call default_data_link_order.
8710 (default_fill_link_order): Delete.
8711 (default_data_link_order): New function.
8712 * elf32-mips.c (_bfd_mips_elf_final_link): Replace occurrences
8713 of bfd_fill_link_order with bfd_data_link_order.
8714 * elf64-alpha.c (elf64_alpha_final_link): Likewise.
8715 * elf64-mips.c (mips_elf64_final_link): Likewise.
8717 * bfd.c (bfd_scan_vma): Clamp overflows to max bfd_vma value.
8718 Correct value returned in "end" for "0x<non-hex>".
8720 2002-02-14 Nick Clifton <nickc@cambridge.redhat.com>
8722 * cpu-arm.c (processors): Replace 'arch' field with 'mach'.
8723 (scan): Test against 'mach' field in info structure.
8725 2002-02-14 Alan Modra <amodra@bigpond.net.au>
8727 * elf.c (elf_fake_sections): Use SHT_NOBITS when SEC_NEVER_LOAD.
8729 2002-02-14 Matt Fredette <fredette@netbsd.org>
8731 * elf32-m68k.c (elf32_m68k_print_private_bfd_data): Recognize
8734 2002-02-13 Nick Clifton <nickc@cambridge.redhat.com>
8736 * elf.c (_bfd_elf_make_section_from_shdr): Do not insist on
8737 non-zero physical addresses when adjusting the LMAs of new
8740 2002-02-12 John David Anglin <dave@hiauly1.hia.nrc.ca>
8742 * elf-hppa.h (elf_hppa_reloc_final_type): New function stripped
8743 from _bfd_elf_hppa_gen_reloc_type.
8744 (_bfd_elf_hppa_gen_reloc_type): Remove duplicate prototype.
8745 * elf32-hppa.h (elf32_hppa_reloc_final_type): Add protptype.
8746 * elf32-hppa.c: Include elf32-hppa.h before elf-hppa.h.
8747 * elf64-hppa.h (elf64_hppa_reloc_final_type): Add protptype.
8749 2002-02-12 Alexandre Oliva <aoliva@redhat.com>
8751 * elf-m10300.c (mn10300_elf_relax_section): Skip section before
8752 loading its contents if there's nothing to do in it.
8754 2002-02-12 Alan Modra <amodra@bigpond.net.au>
8756 * elf64-ppc.c (ppc64_elf_size_stubs): Correct test for crossing
8759 * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Add dynamic
8760 DT_PPC64_OPD and DT_PPC64_OPDSZ tags.
8761 (ppc64_elf_finish_dynamic_sections): Set values for them.
8763 2002-02-11 Michael Snyder <msnyder@redhat.com>
8765 * elf-bfd.h (elfcore_write_lwpstatus): Add prototype.
8766 * elf.c (elfcore_grok_pstatus): Add prototype.
8767 (elfcore_grok_lwpstatus): Add prototype.
8768 (elfcore_write_lwpstatus): New function.
8769 (elfcore_write_pstatus): Fix typo, eliminate unnecessary memcpy.
8771 2002-02-11 Alexandre Oliva <aoliva@redhat.com>
8773 * elf32-sh.c: Added missing prototypes.
8774 * elf32-sh64.c: Likewise.
8775 (sh_elf_align_loads): Mark unused args as such.
8776 * elf64-sh64.c: Added missing prototypes.
8777 (struct elf_sh64_link_hash_entry): Fix typo.
8778 (sh_elf64_relocate_section): Fix info argument passed to
8779 _bfd_elf_section_offset.
8781 2002-02-11 Alan Modra <amodra@bigpond.net.au>
8783 * Makefile.am: "make dep-am".
8784 * Makefile.in: Regenerate.
8785 * aclocal.m4: Regenerate.
8786 * config.in: Regenerate.
8787 * configure: Regenerate.
8789 2002-02-10 Daniel Jacobowitz <drow@mvista.com>
8791 * coff-rs6000.c (xcoff_generate_rtinit): Silence uninitialized
8793 * elf32-sh.c (sh_elf_relax_section): Silence signed/unsigned
8795 * trad-core.c (trad_unix_core_file_p): Silence pointer/integer
8796 cast warnings for the common case.
8798 2002-02-10 Hans-Peter Nilsson <hp@bitrange.com>
8800 * config.bfd (sh-*-linux*, sh-*-elf* | sh-*-rtemself*): Add sh64
8802 (sh-*-netbsdelf*): New, to trump sh*-*-netbsdelf* and add sh64
8805 2002-02-09 Richard Henderson <rth@redhat.com>
8807 * elf64-alpha.c (elf64_alpha_howto): Add R_ALPHA_BRSGP.
8808 (elf64_alpha_reloc_map, elf64_alpha_check_relocs): Likewise.
8809 (elf64_alpha_relocate_section): Likewise.
8810 * reloc.c (BFD_RELOC_ALPHA_BRSGP): New.
8811 * bfd-in2.h, libbfd.h: Rebuild.
8813 2002-02-09 Hans-Peter Nilsson <hp@bitrange.com>
8815 * elf64-mmix.c (_bfd_mmix_finalize_linker_allocated_gregs): Check
8816 that base-plus-offset reloc accounting is consistent.
8817 (mmix_elf_relax_section): Keep base-plus-offset reloc accounting
8818 up to date for undefined symbols.
8820 2002-02-08 Eric Christopher <echristo@redhat.com>
8822 From Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
8824 * elf32-mips.c (_bfd_mips_elf_fake_sections): Don't create .rela
8825 sections for the O32 ABI.
8827 2002-02-08 Chris Demetriou <cgd@broadcom.com>
8829 * elf32-arm.h: Fix formatting of _("...").
8830 * elf32-d10v.c: Likewise.
8831 * elf32-m68k.c: Likewise.
8832 * elf32-mips.c: Likewise.
8834 2002-02-08 Ivan Guzvinec <ivang@opencores.org>
8836 * coff-or32.c: Fix compile time warning messages.
8838 2002-02-08 Alexandre Oliva <aoliva@redhat.com>
8840 Contribute sh64-elf.
8841 2002-01-23 Alexandre Oliva <aoliva@redhat.com>
8842 * reloc.c (R_SH_GOTPLT32, R_SH_GOT_LOW16, R_SH_GOT_MEDLOW16,
8843 R_SH_GOT_MEDHI16, R_SH_GOT_HI16, R_SH_GOTPLT_LOW16,
8844 R_SH_GOTPLT_MEDLOW16, R_SH_GOTPLT_MEDHI16, R_SH_GOTPLT_HI16,
8845 R_SH_PLT_LOW16, R_SH_PLT_MEDLOW16, R_SH_PLT_MEDHI16,
8846 R_SH_PLT_HI16, R_SH_GOTOFF_LOW16, R_SH_GOTOFF_MEDLOW16,
8847 R_SH_GOTOFF_MEDHI16, R_SH_GOTOFF_HI16, R_SH_GOTPC_LOW16,
8848 R_SH_GOTPC_MEDLOW16, R_SH_GOTPC_MEDHI16, R_SH_GOTPC_HI16,
8849 R_SH_GOT10BY4, R_SH_GOTPLT10BY4, R_SH_GOT10BY8, R_SH_GOTPLT10BY8,
8850 R_SH_COPY64, R_SH_GLOB_DAT64, R_SH_JMP_SLOT64, R_SH_RELATIVE64):
8852 * libbfd.h, bfd-in2.h: Rebuilt.
8853 * elf32-sh.c (sh_elf_howto_table): Define new relocs.
8854 (sh_reloc_map): Map them.
8855 (PLT_ENTRY_SIZE, elf_sh_plt0_entry_be, elf_sh_plt0_entry_le,
8856 elf_sh_plt_entry_be, elf_sh_plt_entry_le, elf_sh_pic_plt_entry_be,
8857 elf_sh_pic_plt_entry_le, elf_sh_plt0_entry, elf_sh_plt_entry,
8858 elf_sh_pic_plt_entry, elf_sh_sizeof_plt, elf_sh_plt_plt0_offset,
8859 elf_sh_plt0_gotplt_offset, elf_sh_plt_temp_offset,
8860 elf_sh_plt_symbol_offset, elf_sh_plt_reloc_offset,
8861 movi_shori_putval) [INCLUDE_SHMEDIA]: New.
8862 (elf_sh_link_hash_entry) [INCLUDE_SHMEDIA]: Add
8863 datalabel_got_offset.
8864 (sh_elf_link_hash_newfunc): Initialize it.
8865 (sh_elf_relocate_section): Augment the scope of
8866 seen_stt_datalabel. Introduce GOTPLT support. Extend GOTPC, PLT,
8867 GOT and GOTOFF handling to new SHmedia relocation types. Support
8869 (sh_elf_check_relocs): Likewise.
8870 (sh_elf_finish_dynamic_symbol) [TARGET_SHMEDIA]: Set up values in
8871 PLT entries using movi_shori_putval. Support GOT_BIAS.
8872 (sh_elf_finish_dynamic_sections): Likewise.
8873 * elf32-sh64.c (shmedia_prepare_reloc): Do not add addend to
8874 relocation, it's now done by the caller.
8876 * elf64-sh64.c (GOT_BIAS, PLT_ENTRY_SIZE, elf_sh64_sizeof_plt,
8877 elf_sh64_plt_plt0_offset, elf_sh64_plt0_gotplt_offset,
8878 elf_sh64_plt_temp_offset, elf_sh64_plt_symbol_offset,
8879 elf_sh64_plt_reloc_offset, ELF_DYNAMIC_INTERPRETER,
8880 elf_sh64_pcrel_relocs_copied, elf_sh64_link_hash_entry,
8881 elf_sh64_link_hash_table, sh64_elf64_link_hash_traverse,
8882 sh64_elf64_hash_table): New.
8883 (sh_elf64_howto_table): Introduce new relocs.
8884 (sh_elf64_info_to_howto): Accept new PIC relocs.
8885 (sh_elf64_relocate_section): Augment the scope of
8886 seen_stt_datalabel. Support new PIC relocs.
8887 (sh_elf64_check_relocs): Support new PIC relocs.
8888 (elf_sh64_plt0_entry_be, elf_sh64_plt0_entry_le,
8889 elf_sh64_plt_entry_be, elf_sh64_plt_entry_le,
8890 elf_sh64_pic_plt_entry_be, elf_sh64_pic_plt_entry_le,
8891 elf_sh64_plt0_entry, elf_sh64_plt_entry, elf_sh64_pic_plt_entry,
8892 sh64_elf64_link_hash_newfunc, sh64_elf64_link_hash_table_create,
8893 movi_shori_putval, movi_3shori_putval,
8894 sh64_elf64_create_dynamic_sections,
8895 sh64_elf64_adjust_dynamic_symbol, sh64_elf64_discard_copies,
8896 sh64_elf64_size_dynamic_sections,
8897 sh64_elf64_finish_dynamic_symbol,
8898 sh64_elf64_finish_dynamic_sections): New.
8899 (elf_backend_create_dynamic-sections,
8900 bfd_elf64_bfd_link_hash_table_create,
8901 elf_backend_adjust_dynamic_symbol,
8902 elf_backend_size_dynamic_sections,
8903 elf_backend_finish_dynamic_symbol,
8904 elf_backend_finish_dynamic_sections, elf_backend_want_got_plt,
8905 elf_backend_plt_readonly, elf_backend_want_plt_sym,
8906 elf_backend_got_header_size, elf_backend_plt_header_size):
8908 2001-05-16 Alexandre Oliva <aoliva@redhat.com>
8909 * elf32-sh.c: Renumbered and renamed some SH5 relocations to
8910 match official numbers and names; moved unmaching ones to the
8912 * elf32-sh64.c, elf64-sh64.c: Likewise.
8913 2001-03-12 DJ Delorie <dj@redhat.com>
8914 * elf32-sh.c (sh_elf_relax_section): Don't relax SHmedia
8916 2001-03-12 DJ Delorie <dj@redhat.com>
8917 * elf32-sh64.c (shmedia_prepare_reloc): Validate relocs that must
8919 * elf64-sh64.c (sh_elf64_relocate_section): Ditto.
8920 2001-01-14 Hans-Peter Nilsson <hpn@cygnus.com>
8921 * elf32-sh64.c (bfd_elf32_bfd_copy_private_section_data): Define.
8922 (sh64_elf_fake_sections): Set type to SHT_SH5_CR_SORTED for a
8923 .cranges section with SEC_SORT_ENTRIES set.
8924 (sh64_backend_section_from_shdr): Set SEC_SORT_ENTRIES on an
8925 incoming sorted .cranges section.
8926 (sh64_bfd_elf_copy_private_section_data): New.
8927 (sh64_elf_final_write_processing): Only sort .cranges and modify
8928 start address if called by linker.
8929 2001-01-08 Ben Elliston <bje@redhat.com>
8930 * elf32-sh64.c (sh64_elf_final_write_processing): Activate
8931 Hans-Peter Nilsson's set bit 0 patch from 2001-01-06.
8932 * elf64-sh64.c (sh64_elf64_final_write_processing): Ditto.
8933 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
8934 * elf64-sh64.c (sh_elf64_howto_table): No open brace at start of
8935 line. Add comments before all entries.
8936 <R_SH_PT_16, R_SH_SHMEDIA_CODE>: Correct and clarify describing
8938 (sh_elf64_reloc): Correct head comment.
8939 (sh_elf64_relocate_section): Correct spacing.
8940 <relocating for a local symbol>: Do not honour STO_SH5_ISA32;
8941 instead call reloc_dangerous callback.
8942 <case R_SH_SHMEDIA_CODE>: New case.
8943 (sh_elf64_gc_mark_hook): Correct spacing.
8944 (sh_elf64_check_relocs): Ditto.
8945 * elf32-sh64.c (shmedia_prepare_reloc) <case R_SH_SHMEDIA_CODE>:
8947 * elf32-sh.c: Correct #endif comments for #ifndef-wrapped
8949 (sh_elf_howto_table) <R_SH_PT_16, R_SH_SHMEDIA_CODE>: Correct,
8950 clarify describing comment. Add comments before all entries.
8951 (sh_elf_relocate_section) <relocating for a local symbol>: Do not
8952 honour STO_SH5_ISA32; instead call reloc_dangerous callback.
8953 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
8954 Sort .cranges section in final link. Prepare to set bit 0 on
8956 * elf32-sh64.c (struct sh64_find_section_vma_data): New.
8957 (sh64_elf_link_output_symbol_hook): Fix typo in prototype.
8958 (sh64_elf_set_mach_from_flags): Set SEC_DEBUGGING on incoming
8960 (sh64_backend_section_from_shdr): New, to recognize
8961 SHT_SH5_CR_SORTED on incoming .cranges section.
8962 (elf_backend_section_from_shdr): Define.
8963 (sh64_elf_final_write_processing): Sort outgoing .cranges
8964 section. (New, temporarily disabled:) Set bit 0 on entry address
8965 according to ISA type.
8966 (sh64_find_section_for_address): New.
8967 (crange_qsort_cmpb, crange_qsort_cmpl, crange_bsearch_cmpb,
8968 crange_bsearch_cmpl): Move here from opcodes/sh64-dis.c.
8969 (sh64_address_in_cranges): Move here from opcodes/sh64-dis.c. Use
8970 bfd_malloc, not xmalloc.
8971 (sh64_get_contents_type): Move here from opcodes/sh64-dis.c. Make
8973 * elf32-sh64.c (sh64_elf64_final_write_processing): New, (but
8974 temporarily disabled) setting bit 0 on entry address.
8975 (elf_backend_final_write_processing): Define.
8976 2001-01-05 Hans-Peter Nilsson <hpn@cygnus.com>
8977 * elf32-sh.c (sh_elf_howto_table) <R_SH_PT_16>: Adjust fields to
8978 be a proper relocation for PTA and PTB rather than a marker.
8979 <R_SH_IMMU5, R_SH_IMMS6, R_SH_IMMU6, R_SH_IMMS10, R_SH_IMMS10BY2,
8980 R_SH_IMMS10BY4, R_SH_IMMS10BY8, R_SH_IMMS16, R_SH_IMMU16,
8981 R_SH_IMM_LOW16, R_SH_IMM_LOW16_PCREL, R_SH_IMM_MEDLOW16,
8982 R_SH_IMM_MEDLOW16_PCREL, R_SH_IMM_MEDHI16, R_SH_IMM_MEDHI16_PCREL,
8983 R_SH_IMM_HI16, R_SH_IMM_HI16_PCREL, R_SH_64, R_SH_64_PCREL>:
8985 * elf64-sh64.c: Ditto.
8986 (sh_elf64_relocate_section) <case R_SH_PT_16>: New case.
8987 * elf32-sh64.c: Include opcodes/sh64-opc.h
8988 (shmedia_prepare_reloc): Take a bfd_link_info pointer as first
8989 argument. Drop const qualifiers from "bfd *" and "bfd_byte *"
8990 parameters. No unused parameters. Caller changed.
8991 <case R_SH_PT_16>: New case.
8992 * Makefile.am (elf32-sh64.lo): Add dependency on sh64-opc.h.
8993 * Makefile.in: Regenerate.
8994 2000-12-30 Hans-Peter Nilsson <hpn@cygnus.com>
8995 * elf64-sh64.c (sh64_elf64_fake_sections): Set SHF_SH5_ISA32 for
8997 (sh_elf64_set_mach_from_flags): Change from EF_SH64 to EF_SH5.
8998 (sh64_elf_merge_private_data): Ditto.
8999 * elf32-sh64.c (sh64_elf_fake_sections): Use sh64_elf_section_data
9000 to access stored section flags.
9001 (sh64_elf_final_write_processing): Return immediately unless
9002 called by linker. Use sh64_elf_section_data (cranges) to get size
9003 of linker-generated cranges entries.
9004 (sh64_elf_copy_private_data): Add missing "return true".
9005 (sh64_elf_set_mach_from_flags): Change from EF_SH64 to EF_SH5.
9006 (sh_elf64_merge_private_data): Ditto.
9007 2000-12-19 Hans-Peter Nilsson <hpn@cygnus.com>
9008 * elf64-sh64.c (sh64_elf64_fake_sections): New, copy of
9009 elf64-sh64.c:sh64_elf_fake_sections.
9010 (elf_backend_fake_sections): Define as sh64_elf64_fake_sections.
9011 2000-12-18 Hans-Peter Nilsson <hpn@cygnus.com>
9012 * elf32-sh64.c (sh64_elf_copy_private_data_internal): Delete.
9013 (sh64_elf_final_write_processing): New.
9014 (elf_backend_final_write_processing): Define.
9015 (sh64_elf_fake_sections): Get header flags from tdata field.
9016 (sh64_elf_copy_private_data): Do not call
9017 sh64_elf_copy_private_data_internal, just copy e_flags field.
9018 (sh64_elf_merge_private_data): Do not call
9019 sh64_elf_copy_private_data_internal.
9020 2000-12-12 Hans-Peter Nilsson <hpn@cygnus.com>
9021 Remove EF_SH64_ABI64, let ELF size make difference.
9022 Remove SH64-specific BFD section flag.
9023 * elf32-sh64.c (sh64_elf_fake_sections): Recognize section as
9024 containing SHmedia through elf_section_data (asect)->tdata
9025 non-zero, not using a BFD section flag.
9026 (sh64_elf_set_mach_from_flags): Don't recognize EF_SH64_ABI64.
9027 (sh64_elf_merge_private_data): Similar.
9028 (elf_backend_section_flags): Don't define.
9029 (sh64_elf_backend_section_flags): Delete.
9030 * elf64-sh64.c (sh_elf64_set_mach_from_flags): Recognize EF_SH64,
9032 (sh_elf64_merge_private_data): Similar.
9033 * section.c (Section flags definitions): Don't define
9035 (bfd-in2.h): Regenerate.
9036 2000-12-09 Hans-Peter Nilsson <hpn@cygnus.com>
9037 Make DataLabel references work with partial linking.
9038 * elf32-sh64.c: Fix formatting.
9039 (sh64_elf_link_output_symbol_hook): New.
9040 (elf_backend_link_output_symbol_hook): Define to
9041 sh64_elf_link_output_symbol_hook.
9042 (sh64_elf_add_symbol_hook): Make DataLabel symbol just global
9043 undefined if partial linking. Adjust sanity check.
9044 * elf64-sh64.c (sh64_elf64_link_output_symbol_hook): New.
9045 (elf_backend_link_output_symbol_hook): Define to
9046 sh64_elf64_link_output_symbol_hook.
9047 (sh64_elf64_add_symbol_hook): Make DataLabel symbol just global
9048 undefined if partial linking. Adjust sanity check.
9049 2000-12-07 Hans-Peter Nilsson <hpn@cygnus.com>
9050 Implement semantics for inter-file DataLabel references.
9051 * elf64-sh64.c (DATALABEL_SUFFIX): Define.
9052 (sh64_elf64_add_symbol_hook): New.
9053 (sh_elf64_relocate_section): If passing an indirect symbol with
9054 st_type STT_DATALABEL on the way to a symbol with st_other
9055 STO_SH5_ISA32, do not bitor 1 to the relocation.
9056 (elf_backend_add_symbol_hook): Define to
9057 sh64_elf64_add_symbol_hook.
9058 * elf64-sh32.c: Tweak comments.
9059 (DATALABEL_SUFFIX): Define.
9060 (sh64_elf_add_symbol_hook): New.
9061 (elf_backend_add_symbol_hook): Define to sh64_elf_add_symbol_hook.
9062 * elf32-sh.c (sh_elf_relocate_section): If passing an indirect
9063 symbol with st_type STT_DATALABEL on the way to a symbol with
9064 st_other STO_SH5_ISA32, do not bitor 1 to the relocation.
9065 2000-12-05 Hans-Peter Nilsson <hpn@cygnus.com>
9066 Pass through STT_DATALABEL.
9067 * elf32-sh64.c (sh64_elf_get_symbol_type): New.
9068 (elf_backend_get_symbol_type): Define.
9069 * elf64-sh64.c (sh64_elf64_get_symbol_type): New.
9070 (elf_backend_get_symbol_type): Define.
9071 2000-11-30 Hans-Peter Nilsson <hpn@cygnus.com>
9072 * elf32-sh64.c: Tweak comments.
9073 (sh64_elf_copy_private_data_internal): Add prototype.
9074 (bfd_elf32_bfd_set_private_flags): Define.
9075 (sh64_elf_copy_private_data_internal): Compare machine name, not
9076 textual BFD target name, to check whether to copy section flag
9078 (sh64_elf_merge_private_data): Validize bfd_get_arch_size.
9079 Tweak section-contents-type-mismatch message.
9080 (shmedia_prepare_reloc): Add ATTRIBUTE_UNUSED markers.
9081 Validize reloc-types.
9082 * elf64-sh64.c: New file.
9083 * targets.c (bfd_elf64_sh64_vec, bfd_elf64_sh64l_vec): Declare.
9084 * Makefile.am (BFD64_BACKENDS): Add elf64-sh64.lo.
9085 (BFD64_BACKENDS_CFILES): Add elf64-sh64.c.
9086 Regenerate dependencies.
9087 * Makefile.in: Regenerate.
9088 * config.bfd (sh64-*-elf*): Add bfd_elf64_sh64_vec and
9089 bfd_elf64_sh64l_vec.
9090 * configure.in: Handle bfd_elf64_sh64_vec and
9091 bfd_elf64_sh64l_vec.
9092 * configure: Regenerate.
9093 * po/POTFILES.in: Regenerate.
9094 * po/bfd.pot: Regenerate.
9095 2000-11-29 Hans-Peter Nilsson <hpn@cygnus.com>
9096 * elf32-sh64.c (sh64_elf_set_mach_from_flags): Do not recognize
9097 anything else but EF_SH64 and EF_SH64_ABI64.
9098 (sh64_elf_merge_private_data): Emit error for anything else but
9099 EF_SH64 and EF_SH64_ABI64.
9100 * config.bfd: Remove bfd_elf32_shblin_vec and bfd_elf32_shlin_vec
9102 * configure.in: Add cofflink.lo to bfd_elf32_sh64_vec and
9103 bfd_elf32_sh64l_vec as a temporary measure.
9104 * configure: Regenerate.
9105 2000-11-27 Hans-Peter Nilsson <hpn@cygnus.com>
9106 * cpu-sh.c (arch_info_struct): Include sh5 item
9108 * config.bfd (sh64-*-elf*): Do not set targ_cflags.
9109 Add targ_selvecs bfd_elf32_sh_vec, bfd_elf32_shl_vec,
9110 bfd_elf32_shblin_vec and bfd_elf32_shlin_vec.
9111 * elf32-sh64.c: Tweak comments.
9112 (sh64_elf_set_mach_from_flags): Recognize all machine flags that
9113 are proper subsets of SH64 as bfd_mach_sh5. Add EF_SH64_ABI64.
9114 (sh64_elf_copy_private_data_internal): Wrap long line.
9115 (sh64_elf_merge_private_data): Rewrite to allow objects from
9116 SH64 subsets to be linked together.
9117 (INCLUDE_SHMEDIA): Define.
9118 * elf32-sh.c (sh_elf_relocate_section) <local symbol>:
9119 Parenthesize plus-expression inside or-expression.
9120 <global symbol>: Ditto.
9121 (sh_elf_set_mach_from_flags): Remove code refusing
9122 deleted EF_SH64_32BIT_ABI flag.
9123 2000-11-26 Hans-Peter Nilsson <hpn@cygnus.com>
9124 * elf32-sh.c (sh_elf_howto_table) <R_SH_IMM_LOW16_PCREL,
9125 R_SH_IMM_MEDLOW16_PCREL, R_SH_IMM_MEDHI16_PCREL,
9126 R_SH_IMM_HI16_PCREL, R_SH_64_PCREL>: Set pcrel_offset to true.
9127 (sh_elf_relocate_section) <local symbol>: Or 1 in
9128 calculation of relocation if sym->st_other & STO_SH5_ISA32.
9129 <global symbol>: Ditto if h->other & STO_SH5_ISA32.
9130 * elf32-sh64.c (shmedia_prepare_reloc): Add rel->r_addend to
9132 2000-11-24 Hans-Peter Nilsson <hpn@cygnus.com>
9133 * Makefile.am (BFD32_BACKENDS): Add elf32-sh64.lo.
9134 (BFD32_BACKENDS_CFILES): Add elf32-sh64.c.
9135 Regenerate dependencies.
9136 * Makefile.in: Regenerate.
9137 * archures.c: Add bfd_mach_sh5.
9138 * config.bfd: Map targ_cpu sh* to bfd_sh_arch.
9139 Handle sh64-*-elf*. Set targ_cflags to -DINCLUDE_SHMEDIA.
9140 * configure.in: Handle bfd_elf32_sh64_vec and bfd_elf32_sh64l_vec.
9141 * configure: Regenerate.
9142 * reloc.c (BFD_RELOC_SH_SHMEDIA_CODE, BFD_RELOC_SH_IMMU5,
9143 BFD_RELOC_SH_IMMS6, BFD_RELOC_SH_IMMS6BY32, BFD_RELOC_SH_IMMU6,
9144 BFD_RELOC_SH_IMMS10, BFD_RELOC_SH_IMMS10BY2,
9145 BFD_RELOC_SH_IMMS10BY4, BFD_RELOC_SH_IMMS10BY8,
9146 BFD_RELOC_SH_IMMS16, BFD_RELOC_SH_IMMU16, BFD_RELOC_SH_IMM_LOW16,
9147 BFD_RELOC_SH_IMM_LOW16_PCREL, BFD_RELOC_SH_IMM_MEDLOW16,
9148 BFD_RELOC_SH_IMM_MEDLOW16_PCREL, BFD_RELOC_SH_IMM_MEDHI16,
9149 BFD_RELOC_SH_IMM_MEDHI16_PCREL, BFD_RELOC_SH_IMM_HI16,
9150 BFD_RELOC_SH_IMM_HI16_PCREL, BFD_RELOC_SH_PT_16): New relocations.
9151 * cpu-sh.c [INCLUDE_SHMEDIA] (arch_info_struct): Define and link
9153 * elf32-sh.c [INCLUDE_SHMEDIA] (sh_elf_howto_table): Add howto items
9155 [INCLUDE_SHMEDIA] (sh_rel): Add mappings for SHmedia relocs.
9156 [INCLUDE_SHMEDIA] (sh_elf_relocate_section) [default]: Call
9157 shmedia_prepare_reloc, goto final_link_relocate if it returns
9158 non-zero, else fail as before.
9159 (sh_elf_set_mach_from_flags): Provide function only if not defined
9160 as macro. Do not recognize objects with EF_SH64_32BIT_ABI set.
9161 (sh_elf_set_private_flags): Provide function only if not defined
9163 (sh_elf_copy_private_data): Similar.
9164 (sh_elf_merge_private_data): Similar.
9165 * section.c (SEC_SH_ISA_SHMEDIA): New.
9166 * targets.c (bfd_elf32_sh64_vec, bfd_elf32_sh64l_vec): Declare.
9167 * elf32-sh64.c: New file.
9168 * libbfd.h: Regenerate.
9169 * bfd-in2.h: Regenerate.
9170 * po/POTFILES.in: Regenerate.
9171 * po/bfd.pot: Regenerate.
9172 * bfd-in2.h: Regenerate.
9173 * libbfd.h: Regenerate.
9175 2002-02-07 Daniel Jacobowitz <drow@mvista.com>
9177 * bfd-in.h: Update <stdbool.h> check to only see if <stdbool.h> has
9178 been included, not drag it in.
9179 * bfd-in2.h: Regenerate.
9181 2002-02-06 H.J. Lu (hjl@gnu.org)
9183 * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Update
9184 the mach and ISA fields if necessary.
9186 2002-02-06 Nick Clifton <nickc@cambridge.redhat.com>
9188 * coffcode.h (coff_set_arch_mach_hook): Select the highest known
9189 ARM architecture when an F_ARM_5 flag is detected, since we cannot
9190 be sure exactly which architecture this represents.
9192 2002-02-05 Nick Clifton <nickc@redhat.com>
9194 * po/tr.po: Updated translation.
9196 2002-02-05 Alan Modra <amodra@bigpond.net.au>
9198 From Jimi X <jimix@watson.ibm.com>
9199 * archures (bfd_mach_ppc64): Define.
9200 (bfd_powerpc_arch): Rename to bfd_powerpc_archs.
9201 (bfd_powerpc_arch): Define.
9202 * bfd-in2.h: Regenerate.
9203 * cpu-powerpc.c (arch_info_struct): Rename to bfd_powerpc_archs.
9204 (bfd_powerpc_arch): Move to tail of bfd_powerpc_archs.
9205 (bfd_powerpc_archs): Add default powerpc64 arch.
9207 2002-02-05 Alan Modra <amodra@bigpond.net.au>
9209 * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Check for relocs
9210 against section syms in readonly sections. Don't do the global
9211 sym check if we find one.
9212 * elf64-s390.c (elf_s390_size_dynamic_sections): Likewise.
9213 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Likewise.
9214 * elf32-i386.c (elf_i386_size_dynamic_sections): Likewise.
9215 * elf32-s390.c (elf_s390_size_dynamic_sections): Likewise.
9216 (elf_s390_grok_prstatus): Add missing prototype.
9218 2002-02-04 Hans-Peter Nilsson <hp@bitrange.com>
9220 * elf64-mmix.c (mmix_dump_bpo_gregs): New function.
9221 (mmix_elf_check_common_relocs) <case R_MMIX_BASE_PLUS_OFFSET>:
9222 Call bfd_get_section_by_name only once. Initialize
9223 bpodata->n_bpo_relocs_this_section.
9224 (_bfd_mmix_prepare_linker_allocated_gregs): Remove comment
9226 (bpo_reloc_request_sort_fn): Don't use difference of values as
9229 2002-02-02 David O'Brien <obrien@FreeBSD>
9231 * configure.in: Tweak the FreeBSD 4.x recognition more. Only treat
9232 version 4.5 and later the same as 5-CURRENT.
9233 * configure: Re-generate.
9235 2002-02-02 Jason Thorpe <thorpej@wasabisystems.com>
9237 * config.bfd (hppa*-*-netbsd*): New target.
9239 2002-01-31 Philipp Thomas <pthomas@suse.de>
9241 * coff-arm.c (coff_arm_merge_private_bfd_data): Move ERROR
9242 to front of message. Unify messages with elf32-arm.h. Use
9243 commas where neccessary.
9244 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Use all upcase
9245 ERROR in messages. Unify messages with coff-arm.c. Correct
9246 VFP/FPA error message.
9247 (elf32_arm_print_private_bfd_data): Don't mark APCS-26 and
9248 APCS-32 for translation.
9250 2002-02-01 Hans-Peter Nilsson <hp@bitrange.com>
9252 Perform on-demand global register allocation from
9253 R_MMIX_BASE_PLUS_OFFSET relocs.
9254 * elf64-mmix.c (struct bpo_reloc_section_info, struct
9255 bpo_reloc_request, struct bpo_greg_section_info): New.
9256 (mmix_elf_check_common_relocs, mmix_elf_gc_sweep_hook,
9257 bpo_reloc_request_sort_fn, mmix_elf_relax_section,
9258 _bfd_mmix_check_all_relocs,
9259 _bfd_mmix_prepare_linker_allocated_gregs,
9260 _bfd_mmix_finalize_linker_allocated_gregs): New functions.
9261 (elf_mmix_howto_table): Correct src_mask for most relocs.
9262 (mmix_elf_perform_relocation) <case R_MMIX_BASE_PLUS_OFFSET>: New
9264 (mmix_final_link_relocate) <case R_MMIX_BASE_PLUS_OFFSET>: New
9265 case. Fix typo in comment. New label do_mmix_reloc.
9266 (mmix_elf_check_relocs): Abuse bfd_link_info member base_file to
9267 store first object file with a base-plus-offset reloc. Call
9268 mmix_elf_check_common_relocs for the part common with mmo.
9269 (mmix_elf_final_link): Write out linker-allocated register
9271 (elf_backend_gc_sweep_hook): Define.
9272 (bfd_elf64_bfd_relax_section): Define.
9274 * mmo.c: Don't include <ctype.h>
9275 (mmo_init): Correct init-once logic.
9277 2002-02-01 Tom Rix <trix@redhat.com>
9279 * config.bfd: Conditionally support <aiaff> for pre AIX 4.3.
9281 2002-02-01 Alan Modra <amodra@bigpond.net.au>
9283 * Makefile.am: Run "make dep-am"
9284 * Makefile.in: Regenerate.
9286 2002-01-31 David O'Brien <obrien@FreeBSD>
9288 * configure.in: Recognize the differences in core files from FreeBSD
9289 4.{0,1} and later versions of 4.x. This treats 4.2+ the same as
9291 * configure: Regenerate.
9293 2002-01-31 Ivan Guzvinec <ivang@opencores.org>
9295 * coff-or32.c: New file.
9296 * cpu-or32.c: New file.
9297 * elf32-or32.c: New file.
9298 * archures.c: Add support for or32.
9299 * targets.c: Add support for or32.
9300 * bfd-in2.h: Regenerate.
9301 * coffcode.h (coff_set_arch_mach_hook, coff_set_flags,
9302 coff_write_object_contents): Add support for or32.
9303 * config.bfd: Add target.
9304 * configure.in: Add support for or32.
9305 * configure: Regenerate.
9306 * Makefile.am: Add support for or32.
9307 * Makefile.in: Regenerate.
9308 * po/SRC-POTFILES.in: Add or32 files.
9309 * po/bfd.pot: Regenerate.
9311 2002-01-31 Nick Clifton <nickc@cambridge.redhat.com>
9312 Don Lindsay <lindsayd@cisco.com>
9314 * elf32-mips.c (mips_elf_calculate_relocation): Replace 'return
9315 false' with a return of a bfd_reloc_ error code.
9317 2002-01-31 Hans-Peter Nilsson <hp@axis.com>
9319 * elf32-cris.c (elf_cris_discard_excess_program_dynamics): Don't
9320 unexport unreferenced symbols when --export-dynamic. Call
9321 _bfd_elf_strtab_delref when unexporting.
9323 2002-01-30 Daniel Jacobowitz <drow@mvista.com>
9325 * bfd-in.h: Include <stdbool.h> if it is available.
9326 * bfd-in2.h: Regenerated.
9328 2002-01-31 Alan Modra <amodra@bigpond.net.au>
9330 * elf64-ppc.c (func_desc_adjust): STV_PROTECTED functions should
9333 2002-01-30 Nick Clifton <nickc@cambridge.redhat.com>
9335 * archures.c: Tidy up formatting of embedded comments.
9336 * bfd.c: Tidy up formatting of embedded comments.
9337 * bfd-in.h: Fix formatting of comments.
9338 * reloc.c: Tidy up formatting of ordinary & embedded comments.
9339 * section.c: Tidy up formatting of embedded comments.
9340 * syms.c: Tidy up formatting of embedded comments.
9341 * targets.c: Tidy up formatting of embedded comments.
9343 * bfd-in2.h: Regenerate.
9345 2002-01-30 Nick Clifton <nickc@cambridge.redhat.com>
9347 * vms-tir.c (cmd_name): New function.
9348 (tir_cmd_name): New function.
9349 (etir_sta, etir_sto, etir_opr, etir_stc): Use cmd_name().
9350 (tir_opr, tir_ctl, tir_cmd): use tir_cmd_name().
9353 * peXXigen.c (pe_print_idata): Rearrange message to aid in
9355 (pe_print_pdata): Rearrange message to aid in translation.
9357 * libbfd.c (warn_deprecated): Rearrange error message to aid in
9360 * ihex.c (ihex_write_object_contents): Fix spelling typo.
9362 * ieee.c (ieee_slurp_external_symbols): Remove spurious space.
9364 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Rearrange error
9365 message to aid in translation.
9367 * elf64-mmix.c (mmix_final_link_relocate): Rearrange error message
9368 to aid in translation.
9370 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix typo.
9372 2002-01-30 Philipp Thomas <pthomas@suse.de>
9374 * coff-arm.c, elf32-elf.h: Unify messages.
9376 2002-01-30 Nick Clifton <nickc@redhat.com>
9378 * po/sv.po: Updated translation.
9380 2002-01-30 Philipp Thomas <pthomas@suse.de>
9382 * dwarf2.c (read_abbrev): Use full section name in error message.
9383 (decode_line_info): Likewise.
9385 * elf.c (_bfd_elf_symbol_from_bfd_symbol): Don't translate debugging
9388 2002-01-30 Alan Modra <amodra@bigpond.net.au>
9390 * elf64-ppc.c (func_desc_adjust): Only provide missing function
9391 descriptor symbols for undefined function code syms. Clear
9392 ELF_LINK_NON_ELF so that they can stay weak.
9394 2002-01-29 Chris Demetriou <cgd@broadcom.com>
9395 Mitch Lichtenberg <mpl@broadcom.com>
9397 * bfd-in.h (bfd_mips_elf32_create_embedded_relocs): New prototype.
9398 * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): New function
9399 to handle 32-bit ELF embedded reloc (ld --embedded-relocs)
9401 * bfd-in2.h: Regenerate.
9403 2002-01-29 Chris Demetriou <cgd@broadcom.com>
9405 * elf32-mips.c: Add additional comments about HI16 relocation
9407 (_bfd_mips_elf_hi16_reloc): Don't subtract address here for
9408 pc-relative relocations. (Reverts change made on 2001-10-31.)
9409 (_bfd_mips_elf_lo16_reloc): Subtract address of LO16 part here
9410 for pc-relative relocations.
9411 (mips_elf_calculate_relocation): Add a comment about a kludge
9412 in the R_MIPS_GNU_REL_HI16 handling.
9413 (_bfd_mips_elf_relocate_section): Implement that kludge;
9414 adjust pc-relative HI16 relocation for difference in HI16 and
9415 LO16 addresses, since it can't easily be done in
9416 mips_elf_calculate_relocation.
9418 2002-01-29 Martin Schwidefsky <schwidefsky@de.ibm.com>
9420 * elf32-i386 (elf_i386_adjust_dynamic_symbol): Do not replace PLT32
9421 relocations with PC32 relocations for undefined or weak symbols.
9422 * elf32-s390 (elf_i386_adjust_dynamic_symbol): Likewise.
9423 * elf64-s390x (elf_i386_adjust_dynamic_symbol): Likewise.
9425 2002-01-28 Jason Thorpe <thorpej@wasabisystems.com>
9427 * elfcore.h (elf_core_file_p): Improve comment for last change.
9429 2002-01-27 Daniel Jacobowitz <drow@mvista.com>
9431 * configure: Regenerated.
9433 2002-01-27 Jason Thorpe <thorpej@wasabisystems.com>
9435 * elfcore.h (elf_core_file_p): Set the machine architecture
9436 before processing the program headers.
9438 2002-01-26 Hans-Peter Nilsson <hp@bitrange.com>
9440 * configure.in <64-bit configuration>: If using gcc, check and
9441 emit error for egcs-1.1.2.
9442 * configure: Regenerate.
9444 2002-01-26 Egor Duda <deo@logos-m.ru>
9446 * elf.c (elfcore_grok_win32pstatus): Copy only as much information
9447 as possible to avoid stack corruption.
9449 2002-01-26 Richard Henderson <rth@redhat.com>
9451 * elf64-alpha.c (elf64_alpha_check_relocs): Don't set reltext
9452 for non-allocated sections.
9454 2002-01-25 Mark Kettenis <kettenis@gnu.org>
9456 * elf.c (elfcore_write_prstatus): Make sure we pass the address of
9457 prstat.pr_reg even if it is a struct.
9459 2002-01-25 Steve Ellcey <sje@cup.hp.com>
9461 * elfxx-ia64.c: Reset AIX vector function overrides for HP-UX.
9463 2002-01-25 Philipp Thomas <pthomas@suse.de>
9465 * coffgen.c (coff_print_symbol): Don't mark info message
9468 2002-01-25 Nick Clifton <nickc@redhat.com>
9470 * po/fr.po: Updated translation.
9471 * po/es.po: Updated translation.
9473 2002-01-25 Philipp Thomas <pthomas@suse.de>
9475 * coff-alpha.c (alpha_relocate_section): Unify warning message
9476 for GP relative relocations without GP defined.
9477 * coff-mips.c (mips_relocate_section): Likewise.
9479 2002-01-25 Alan Modra <amodra@bigpond.net.au>
9481 * elf-eh-frame.c (_bfd_elf_eh_frame_section_offset): Avoid
9482 unsigned overflow when new_offset < old_offset.
9484 2002-01-24 Philipp Thomas <pthomas@suse.de>
9486 * bfd.c (_bfd_abort): Fix typo.
9488 2002-01-23 Richard Henderson <rth@redhat.com>
9490 * elf64-alpha.c (elf64_alpha_adjust_dynamic_symbol): Don't suppress
9491 plt entries for undefweak symbols.
9493 2002-01-23 Steve Ellcey <sje@cup.hp.com>
9495 * targets.c (bfd_elf32_ia64_hpux_big_vec): Add to DEFAULT_VECTOR.
9496 (bfd_elf64_ia64_hpux_big_vec): Ditto.
9497 (bfd_elf32_h8300_vec): Ditto.
9499 2002-01-23 Alan Modra <amodra@bigpond.net.au>
9501 * elf64-ppc.c: Remove stale part of ABI comment.
9502 (NO_OPD_RELOCS): Define.
9503 (ppc64_elf_check_relocs): Use it.
9504 (ppc64_elf_relocate_section): Here too.
9505 (build_one_stub): Don't point function syms at the stub. Instead,
9507 (ppc64_elf_relocate_section): Check whether REL24 relocs should
9508 really go to the stub. Make all dynamic relocs in opd against
9510 (ppc64_elf_finish_dynamic_symbol): Allow for non-standard use of
9513 2002-01-22 Richard Henderson <rth@redhat.com>
9515 * elf64-alpha.c (INSN_UNOP): Encode with RB as $sp.
9517 2002-01-22 Alan Modra <amodra@bigpond.net.au>
9519 * elf64-ppc.c (ppc64_elf_finish_dynamic_sections): Correct sign of
9520 TOC_BASE_OFF adjustment.
9522 * Makefile.am: Run "make dep-am".
9523 * Makefile.in: Regenerate.
9524 * po/SRC-POTFILES.in: Regenerate.
9526 2002-01-22 John David Anglin <dave@hiauly1.hia.nrc.ca>
9528 * configure.host (hppa*64*-*-hpux*, hppa*64*-*-linux*): Add new
9531 2002-01-21 Hans-Peter Nilsson <hp@axis.com>
9533 * elf32-cris.c (cris_elf_relocate_section) <case R_CRIS_32_GOTREL>:
9534 Check for and emit error if sgot is NULL at this point.
9536 2002-01-21 Jason Thorpe <thorpej@wasabisystems.com>
9538 * config.bfd (ia64*-*-netbsd*): New target.
9540 2002-01-21 Thomas Klausner <wiz@danbala.ifoer.tuwien.ac.at>
9542 * som.c (som_write_space_strings): Comment typo fix.
9544 2002-01-21 Alan Modra <amodra@bigpond.net.au>
9546 * elf64-ppc.c (struct ppc_link_hash_entry): Add is_func and
9547 is_func_descriptor fields.
9548 (link_hash_newfunc): Init them.
9549 (ppc64_elf_check_relocs): Only R_PPC24_REL24 syms starting with a
9550 dot are candidates for plt entries. When processing .opd relocs,
9551 set function descriptor strings to point inside function code
9552 string, and set new ppc_link_hash_entry fields.
9553 (ppc64_elf_gc_sweep_hook): Don't sweep R_PPC64_REL24 relocs.
9554 (ppc64_elf_adjust_dynamic_symbol): Remove most code dealing with
9555 function descriptors. It's now done in..
9556 (func_desc_adjust): New.
9557 (ppc64_elf_func_desc_adjust): New.
9558 (define elf_backend_always_size_sections): Define.
9559 (ppc64_elf_hide_symbol): New.
9560 (define elf_backend_hide_symbol): Define.
9561 (allocate_dynrelocs): Remove code looking up function descriptors
9562 as that has been done earlier.
9563 (ppc64_elf_size_dynamic_sections): Use htab shortcut to elf hash
9565 (ppc64_elf_finish_dynamic_symbol): Likewise. Remove code looking
9566 up function descriptor.
9567 (build_one_stub): Look up the function code sym. Check for
9568 invalid plt offsets.
9569 (ppc64_elf_relocate_section): Tweak calls to undefined weak syms.
9570 Convert R_PPC64_TOC relocs to R_PPC64_RELATIVE in shared libs.
9572 * elf-bfd.h (elf_backend_data <elf_backend_hide_symbol>): Add
9574 (_bfd_elf_link_hash_hide_symbol): Likewise.
9575 * elflink.h (elf_link_add_object_symbols): Adjust call to
9576 elf_backend_hide_symbol.
9577 (elf_fix_symbol_flags): Likewise.
9578 (elf_link_assign_sym_version): Likewise. Use bfd_malloc rather
9580 * elf.c (_bfd_elf_link_hash_hide_symbol): Add "force_local" param.
9581 Set ELF_LINK_FORCED_LOCAL and call _bfd_elf_strtab_delref.
9582 * elf32-hppa.c (elf32_hppa_hide_symbol): Likewise.
9583 (clobber_millicode_symbols): Adjust to suit new hide_symbol.
9584 * elf32-cris.c (elf_cris_hide_symbol): Add "force_local" param
9586 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Likewise, and call
9587 _bfd_elf_link_hash_hide_symbol rather than duplicating code.
9588 * elfxx-ia64.c (elfNN_ia64_hash_hide_symbol): Likewise.
9590 2002-01-18 Alan Modra <amodra@bigpond.net.au>
9592 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Test for a
9593 dynamic function descriptor symbol, not the associated function
9596 2002-01-17 Eric Christopher <echristo@redhat.com>
9598 * elf32-mips.c (mips_elf_calculate_relocation): Fix typo.
9600 2002-01-17 Nick Clifton <nickc@cambridge.redhat.com>
9602 * po/bfd.pot: Regenerate.
9603 * po/fr.po: Regenerate.
9605 2002-01-17 Alan Modra <amodra@bigpond.net.au>
9607 * elf-bfd.h (elf_backend_data <elf_backend_section_from_bfd_section>):
9608 Remove "Elf_Internal_Shdr *" param.
9609 (_bfd_mips_elf_section_from_bfd_section): Ditto.
9610 * elf32-mips.c (_bfd_mips_elf_section_from_bfd_section): Ditto.
9611 * elf32-m32r.c (_bfd_m32r_elf_section_from_bfd_section): Ditto.
9612 * elf32-v850.c (v850_elf_section_from_bfd_section): Ditto.
9613 * elf64-mmix.c (mmix_elf_section_from_bfd_section): Ditto.
9614 * elfxx-ia64.c (elfNN_hpux_backend_section_from_bfd_section): Ditto.
9615 * elf.c (_bfd_elf_section_from_bfd_section): Allow backend
9616 function to override special sections. Remove hdr arg from
9617 backend call, and don't loop.
9619 2002-01-16 Eric Christopher <echristo@redhat.com>
9621 * elf32-mips.c (mips_elf_calculate_relocation): Set require_jalxp
9622 on R_MIPS_26 and target is 16bit. Add R_MIPS16_GPREL to list of
9623 relocations requiring gp0 and gp.
9625 2002-01-16 Richard Earnshaw <rearnsha@arm.com>
9627 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Handle
9629 (elf32_arm_print_private_bfd_data): Likewise.
9631 2002-01-16 Nick Clifton <nickc@cambridge.redhat.com>
9633 * po/tr.po: Import new version.
9635 2002-01-16 Alan Modra <amodra@bigpond.net.au>
9637 * elf64-ppc.c (ppc64_elf_howto_raw): Remove stale FIXMEs.
9638 (ppc64_elf_reloc_type_lookup): Use proper CTOR reloc.
9639 (ORI_R0_R0_0): Correct.
9641 2002-01-16 Alan Modra <amodra@bigpond.net.au>
9643 * elflink.c (_bfd_elf_create_dynamic_sections): Don't set SEC_CODE
9644 when plt_not_loaded.
9645 * elf64-ppc.c (ppc64_elf_create_dynamic_sections): No need to
9646 clear .plt SEC_CODE here. Create .stub and correct .glink flags.
9647 (PLT_INITIAL_ENTRY_SIZE): Set to 24.
9648 (ppc64_elf_glink_code): Delete.
9649 (PPC64_ELF_GLINK_SIZE): Delete.
9650 (ADDIS_R12_R2, STD_R2_40R1, LD_R11_0R12, LD_R2_0R12, MTCTR_R11,
9651 BCTR, ADDIS_R12_R12_1, LD_R2_40R1, NOP, LI_R0_0, B_DOT, LIS_R0_0,
9652 ORI_R0_R0_0): Define.
9653 (PLT_CALL_STUB_SIZE, GLINK_CALL_STUB_SIZE): Define.
9654 (struct ppc_link_hash_table): Add sstub and plt_overflow.
9655 (ppc64_elf_link_hash_table_create): Init them.
9656 (ppc64_elf_check_relocs <R_PPC64_REL24>): Refcount .plt entry.
9657 Don't copy to shared lib.
9658 (ppc64_elf_check_relocs): Call bfd_set_error on errors.
9659 (ppc64_elf_gc_sweep_hook <R_PPC64_REL24>): Sweep plt refcount.
9660 (allocate_dynrelocs <plt>): Don't change function sym here. Make
9661 room for .stub and .glink code.
9662 (ppc64_elf_size_dynamic_sections): Handle .stub. Make entry for
9664 (ppc64_elf_final_link): Rename to ppc64_elf_set_toc. Don't call
9665 bfd_elf64_bfd_final_link.
9666 (bfd_elf64_bfd_final_link): Don't define.
9667 (ppc64_elf_size_stubs): New.
9668 (build_plt_stub): New.
9669 (build_one_stub): New.
9670 (ppc64_elf_build_stubs): New.
9671 (ppc64_elf_relocate_section <toc relocs>): Remove assert.
9672 (ppc64_elf_relocate_section): Don't copy R_PPC64_REL24 relocs.
9673 (ppc64_elf_finish_dynamic_symbol): Don't build stubs here. Set
9674 DT_PPC64_GLINK entry. Tweak DT_PLTGOT, DT_JMPREL, DT_PLTRELSZ in
9675 case output sections not separate. Adjust DT_RELASZ to not
9676 include plt relocs. Set reserved got entry. Set got and plt
9678 (elf_backend_got_header_size): Set to 8.
9679 * elf64-ppc.h: New file.
9681 2002-01-16 Alan Modra <amodra@bigpond.net.au>
9683 * elf32-arm.h (elf32_arm_size_dynamic_sections): When removing
9684 sections, use bfd_section_list_remove.
9685 * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise.
9686 * elflink.h (elf_link_add_object_symbols): When removing all
9687 sections, use bfd_section_list_clear.
9689 2002-01-15 Nick Clifton <nickc@cambridge.redhat.com>
9691 * po/sv.po: New file: Swedish translation.
9692 * configure.in (ALL_LINGUAS): Add sv.
9693 * configure: Regenerate.
9695 2002-01-15 Jakub Jelinek <jakub@redhat.com>
9697 * elflink.h (elf_link_input_bfd): Back out 2002-01-07 change.
9698 * elf.c (merge_sections_remove_hook): New function.
9699 (_bfd_elf_merge_sections): Pass it as 3rd argument to
9700 _bfd_merge_sections.
9701 * libbfd-in.h (_bfd_merge_sections): Add 3rd argument.
9702 * libbfd.h: Rebuilt.
9703 * merge.c (_bfd_merge_sections): Add remove_hook argument.
9704 Call remove_hook if a SEC_EXCLUDE section is encountered.
9706 2002-01-15 Nick Clifton <nickc@cambridge.redhat.com>
9708 * elf32-xstormy16.c (xstormy16_reloc_map): Add new field 'table'.
9709 (xstormy16_reloc_map): Initialise new field with correct howto
9711 (xstormy16_reloc_type_lookup): Use 'table' field to locate correct
9714 2002-01-10 Michael Snyder <msnyder@redhat.com>
9716 * elf.c (elfcore_write_prstatus): Use long instead of pid_t;
9717 (elfcore_write_pstatus): Use long instead of pid_t;
9718 * elf-bfd.h: Change prototypes to use long instead of pid_t;
9720 2002-01-09 Jason Thorpe <thorpej@wasabisystems.com>
9722 * elf.c: Update copyright years.
9723 (elfcore_grok_netbsd_note): Use NT_NETBSDCORE_PROCINFO
9724 and NT_NETBSDCORE_FIRSTMACH. Improve a comment.
9726 2002-01-08 Michael Snyder <msnyder@redhat.com>
9728 Add capability to write corefile note sections, for gdb.
9729 * elf.c (elfcore_write_note): New function.
9730 (elfcore_write_prpsinfo): New function.
9731 (elfcore_write_prstatus): New function.
9732 (elfcore_write_pstatus): New function.
9733 (elfcore_write_prfpreg): New function.
9734 (elfcore_write_prxfpreg): New function.
9735 * elf-bfd.h: Add prototypes for above functions.
9737 2002-01-08 Alexandre Oliva <aoliva@redhat.com>
9739 * elf.c (elf_fake_sections): Propagate errors from
9740 elf_backend_fake_section.
9742 2002-01-07 Jason Thorpe <thorpej@wasabisystems.com>
9744 * Makefile.am (BFD32_BACKENDS): Add elf32-sh-nbsd.lo.
9745 (BFD32_BACKENDS_CFILES): Add elf32-sh-nbsd.c.
9746 (elf32-sh-nbsd.lo): New rule.
9747 * Makefile.in: Regenerate.
9748 * config.bfd (sh*le-*-netbsdelf*): New target.
9749 (sh*-*-netbsdelf*): New target.
9750 * configure.in: Include netbsd-core.lo for native sh*-*-netbsd*.
9751 (bfd_elf32_shnbsd_vec): New vector.
9752 (bfd_elf32_shlnbsd_vec): New vector.
9753 * configure: Regenerate.
9754 * elf32-sh-nbsd.c: New file.
9755 * targets.c: Update copyright years.
9756 (_bfd_target_vector): Add bfd_elf32_shlnbsd_vec and
9757 bfd_elf32_shnbsd_vec.
9759 2002-01-07 Aldy Hernandez <aldyh@redhat.com>
9761 * coff-rs6000.c (READ20): Use bfd_scan_vma.
9763 2002-01-07 Geoffrey Keating <geoffk@redhat.com>
9765 * elflink.h (elf_link_input_bfd): Don't ask for the merged offset
9766 of a symbol in a section that will be deleted.
9768 2002-01-07 Nick Clifton <nickc@cambridge.redhat.com>
9770 * po/es.po: New file: Spanish translation.
9771 * configure.in (ALL_LINGUAS): Add es.
9772 * configure: Regenerate.
9774 2002-01-06 Steve Ellcey <sje@cup.hp.com>
9776 * elfxx-ia64.c (is_unwind_section_name): Add target vector as
9777 argument so we can handle HP-UX specially.
9778 (elfNN_ia64_hpux_vec): New for use in is_unwind_section_name.
9779 (elfNN_hpux_backend_section_from_bfd_section): New for support
9780 of SHN_IA_64_ANSI_COMMON.
9781 (elfNN_ia64_relax_section): Add support for SHN_IA_64_ANSI_COMMON.
9782 (is_unwind_section_name): Add special HP-UX support.
9783 (elfNN_ia64_section_from_shdr): Add support for more sections.
9784 (elfNN_ia64_fake_sections): Modify is_unwind_section_name call and
9785 add support for more sections.
9786 (elfNN_ia64_additional_program_headers): Modify
9787 is_unwind_section_name call.
9788 (elfNN_ia64_modify_segment_map): Remove assumption that there is
9789 only one unwind section in segment.
9791 2002-01-06 Alan Modra <amodra@bigpond.net.au>
9793 * syms.c (_bfd_generic_make_empty_symbol): New function.
9794 * libbfd-in.h (_bfd_nosymbols_make_empty_symbol): Define as
9795 _bfd_generic_make_empty_symbol.
9796 * libbfd.h: Regenerate.
9797 * bfd-in2.h: Regenerate.
9798 * hppabsd-core.c (hppabsd_core_make_empty_symbol): Delete function.
9799 (hppabsd_core_get_symtab_upper_bound): Don't define.
9800 (hppabsd_core_get_symtab): Likewise.
9801 (hppabsd_core_print_symbol): Likewise.
9802 (hppabsd_core_get_symbol_info): Likewise.
9803 (hppabsd_core_bfd_is_local_label_name): Likewise.
9804 (hppabsd_core_get_lineno): Likewise.
9805 (hppabsd_core_find_nearest_line): Likewise.
9806 (hppabsd_core_bfd_make_debug_symbol): Likewise.
9807 (hppabsd_core_read_minisymbols): Likewise.
9808 (hppabsd_core_minisymbol_to_symbol): Likewise.
9809 (hppabsd_core_vec): Use BFD_JUMP_TABLE_SYMBOLS (_bfd_nosymbols).
9811 * hpux-core.c: Similarly.
9812 * irix-core.c: Similarly.
9813 * osf-core.c: Similarly.
9814 * sco5-core.c: Similarly.
9815 * binary.c (binary_make_empty_symbol): Remove function, define as
9816 _bfd_generic_make_empty_symbol.
9817 * ihex.c (ihex_make_empty_symbol): Likewise.
9818 * mmo.c (mmo_make_empty_symbol): Likewise.
9819 * ppcboot.c (ppcboot_make_empty_symbol): Likewise.
9820 * srec.c (srec_make_empty_symbol): Likewise.
9821 * versados.c (versados_make_empty_symbol): Likewise.
9822 * vms.c (_bfd_vms_make_empty_symbol): Remove.
9823 (vms_make_empty_symbol): Define as _bfd_generic_make_empty_symbol.
9824 * vms-gsd.c (_bfd_vms_slurp_gsd): Call bfd_make_empty_symbol
9825 rather than _bfd_vms_make_empty_symbol.
9826 * vms-misc.c (new_symbol): Likewise.
9828 2002-01-05 Alan Modra <amodra@bigpond.net.au>
9830 * section.c (bfd_section_init): Remove unnecessary initialisations.
9831 (bfd_section_list_clear): New function.
9832 (bfd_section_list_remove, bfd_section_list_insert): New macros.
9833 (_bfd_strip_section_from_output): Use them.
9834 * coffcode.h (coff_set_alignment_hook): Likewise.
9835 * elf32-mips.c (_bfd_mips_elf_final_link): Likewise.
9836 * elf64-mips.c (mips_elf64_final_link): Likewise.
9837 * elf64-mmix.c (mmix_elf_final_link): Likewise.
9838 * sunos.c (sunos_add_dynamic_symbols): Likewise.
9839 * xcofflink.c (_bfd_xcoff_bfd_final_link): Likewise.
9840 * bfd-in2.h: Regenerate.
9842 * netbsd-core.c (netbsd_core_file_p): Use bfd_make_section_anyway
9843 rather than doing our own section handling. Clean up after errors
9844 with bfd_release and bfd_section_list_clear. Handle unexpected
9846 * aoutf1.h (sunos4_core_file_p): Likewise.
9847 * aix386-core.c (aix386_core_file_p): Likewise.
9848 * cisco-core.c (cisco_core_file_validate): Likewise.
9849 * ptrace-core.c (ptrace_unix_core_file_p): Likewise.
9850 * trad-core.c (trad_unix_core_file_p): Likewise.
9852 * hppabsd-core.c (hppabsd_core_core_file_p): Clean up after errors
9853 with bfd_release and bfd_section_list_clear.
9854 * hpux-core.c (hpux_core_core_file_p): Likewise.
9855 * irix-core.c (irix_core_core_file_p): Likewise.
9856 * lynx-core.c (lynx_core_file_p): Likewise.
9857 * osf-core.c (osf_core_core_file_p): Likewise.
9858 * rs6000-core.c (rs6000coff_core_p): Likewise.
9859 * sco5-core.c (sco5_core_file_p): Likewise.
9861 * elf32-mips.c (_bfd_mips_elf_lo16_reloc): Simplify, and perform
9862 sign extension adjustments without conditionals.
9864 2002-01-04 Jakub Jelinek <jakub@redhat.com>
9866 * elf-eh-frame.c (_bfd_elf_write_section_eh_frame): Don't crash if
9867 CIE at .eh_frame start is removed due to no FDEs referencing it.
9869 2002-01-04 Jason Thorpe <thorpej@wasabisystems.com>
9871 * config.bfd (x86_64-*-netbsd*): New target.
9872 * configure.in (x86_64-*-netbsd*): Set COREFILE
9874 * configure: Regenerated.
9876 2002-01-03 Tom Rix <trix@redhat.com>
9878 * xcofflink.c (_bfd_xcoff_bfd_final_link): Update .pad section ordering
9879 for recent bfd_make_section_anyway change.
9881 2002-01-03 Nick Clifton <nickc@cambridge.redhat.com>
9883 * elf32-arm.h (elf32_arm_final_link_relocate): Handle
9884 R_ARM_THM_PC11 reloc.
9886 2002-01-02 Nick Clifton <nickc@cambridge.redhat.com>
9888 * configure.in (LINGUAS): Add ja.
9889 * configure: Regenerate.
9890 * po/ja.po: Import from translation project's web site.
9892 2002-01-02 Nick Clifton <nickc@cambridge.redhat.com>
9894 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Reformat error
9895 messages to ease translation into other languages.
9897 For older changes see ChangeLog-0001
9903 version-control: never