1 2001-11-21 Nick Clifton <nickc@cambridge.redhat.com>
3 * po/Make-in (distclean): Move SRC-POTFILES.in and
4 BLD-POTFILES.in to maintainer-clean target.
6 2001-11-21 Alan Modra <amodra@bigpond.net.au>
8 * elfxx-ia64.c (elfNN_ia64_relocate_section): Test r_symndx rather
9 than sym_sec->output_section to detect relocs against discarded
12 2001-11-19 H.J. Lu <hjl@gnu.org>
14 * elflink.h (elf_link_input_bfd): Assert r_symndx != 0 when
15 discarding relocations.
17 2001-11-19 Nick Clifton <nickc@cambridge.redhat.com>
19 * section.c (bfd_is_const_section): New macro. Return true if the
20 given seciton is one of the special, constant, sections.
21 * bfd-in2.h: Regenerate.
22 * coffgen.c (coff_count_linenumbers): Use bfd_is_const_section.
23 (coff_write_native_symbol): Use bfd_is_const_section.
25 2001-11-19 Alan Modra <amodra@bigpond.net.au>
27 * elf32-hppa.c (clobber_millicode_symbols): Dec dynstr refcount.
29 * elf32-hppa.c (elf32_hppa_size_stubs): Don't consider undefined
30 millicode syms as candidates for import stubs.
32 * elf32-hppa.c (PLABEL_PLT_ENTRY_SIZE): Delete.
33 (allocate_PIC_calls): Rename to allocate_plt_static.
34 (allocate_dynrelocs): Move most of code handling .plt entries to..
35 (allocate_plt_static): ..here. Don't drop plabel entries.
37 2001-11-19 Hans-Peter Nilsson <hp@bitrange.com>
39 * mmo.c: Adjust documentation tags to use texinfo 4 features.
41 2001-11-16 Nick Clifton <nickc@cambridge.redhat.com>
43 * section.c (bfd_is_const_section): New macro. Return true if the
44 section pointer refers to one of the special, constant sections.
45 * bfd-in2.h: Regenerate.
47 * coffgen.c (coff_count_linenumbers): Only update the line number
48 count in non-special sections.
49 (coff_write_native_symbol): Only update the line number file
50 position in non-special sections.
52 2001-11-15 Daniel Jacobowitz <drow@mvista.com>
54 * elflink.h (elf_reloc_symbol_deleted_p): Catch all relocs against
55 local syms from discarded sections. Update comment.
57 2001-11-15 Alan Modra <amodra@bigpond.net.au>
59 * po/SRC-POTFILES.in: Regenerate.
61 * elflink.h (elf_link_input_bfd): Complain about all relocs
62 against local syms from discarded sections. K&R fixes.
63 (elf_reloc_symbol_deleted_p): Don't try to swap in external syms.
66 2001-11-15 Alexandre Oliva <aoliva@redhat.com>
68 * elf64-sparc.c (sparc64_elf_relocate_section): Disregard
69 overflows in the .stab section.
71 2001-11-14 Daniel Jacobowitz <drow@mvista.com>
73 * bfd-in.h (bfd_elf32_discard_info): Add prototype.
74 (bfd_elf64_discard_info): Likewise.
75 * bfd-in2.h: Regenerate.
76 * elf-bfd.h (struct elf_reloc_cookie): New.
77 (struct elf_backend_data): Add elf_backend_discard_info,
78 elf_backend_ignore_discarded_relocs, and elf_backend_write_section.
79 (_bfd_elf32_reloc_symbol_deleted_p): Add prototype.
80 (_bfd_elf64_reloc_symbol_deleted_p): Likewise.
81 * elf32-mips.c (_bfd_elf32_mips_discard_info): New.
82 (_bfd_elf32_mips_ignore_discarded_relocs): New.
83 (_bfd_elf32_mips_write_section): New.
84 (elf_backend_discard_info): Define.
85 (elf_backend_ignore_discarded_relocs): Define.
86 (elf_backend_write_section): Define.
87 * elfcode.h (elf_bfd_discard_info): Define.
88 (elf_reloc_symbol_deleted_p): Define.
89 * elflink.h (elf_link_input_bfd): Check
90 elf_section_ignore_discarded_relocs. Call
91 bed->elf_backend_write_section if available.
92 (elf_reloc_symbol_deleted_p): New.
93 (elf_bfd_discard_info): New.
94 (elf_section_ignore_discarded_relocs): New.
95 * elfxx-target.h (elf_backend_discard_info): Define.
96 (elf_backend_ignore_discarded_relocs): Define.
97 (elf_backend_write_section): Define.
98 (elfNN_bed): Add elf_backend_discard_info,
99 elf_backend_ignore_discarded_relocs, and
100 elf_backend_write_section.
101 * libbfd-in.h (_bfd_discard_section_stabs): Add prototype.
102 * libbfd.h: Regenerate.
103 * stabs.c (_bfd_discard_section_stabs): New.
105 2001-11-14 Martin Schwidefsky <schwidefsky@de.ibm.com>
107 * elf32-s390.c (elf_s390_relocate_section): Use the "unresolved_reloc"
108 scheme to get rid of an ugly complicated test.
109 * elf64-s390.c (elf_s390_relocate_section): Likewise.
111 2001-11-14 Andreas Jaeger <aj@suse.de>
113 * cpu-i386.c (bfd_x86_64_arch_intel_syntax,bfd_x86_64_arch): Use
116 2001-11-14 Jakub Jelinek <jakub@redhat.com>
118 * dwarf2.c (struct line_head) [total_length]: Change type to
120 (struct dwarf2_debug): Add dwarf_str_buffer and dwarf_str_size.
121 (struct comp_unit): Add stash and offset_size.
122 (read_8_bytes): Return bfd_vma.
123 (read_indirect_string): New.
124 (read_attribute): Handle DW_FORM_strp.
125 (decode_line_info): Support 64-bit DWARF format.
126 (_bfd_dwarf2_find_nearest_line): Likewise.
127 (parse_comp_unit): Set offset_size and stash.
129 2001-11-13 Keith Walker <keith.walker@arm.com>
131 * dwarf2.c (read_attribute_value): New function to handle
133 (read_attribute): Use it.
135 2001-11-13 Geoffrey Keating <geoffk@redhat.com>
137 * dwarf2.c (decode_line_info): Properly deal with unknown standard
140 2001-11-13 John Marshall <jmarshall@acm.org>
141 Alan Modra <amodra@bigpond.net.au>
143 * section.c (bfd_make_section_anyway): Don't increment section_id
144 and the BFD's section_count if adding the section failed.
145 * vms.c (vms_new_section_hook): Adjust for bfd_make_section_anyway
148 2001-11-12 Orjan Friberg <orjanf@axis.com>
150 * elf32-cris.c (cris_elf_grok_prstatus): Adjust values to match new
153 2001-11-11 H.J. Lu <hjl@gnu.org>
155 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_sections): Call
156 _bfd_elf_strtab_size instead of _bfd_stringtab_size.
158 * elf64-sparc.c (sparc64_elf_size_dynamic_sections): Change
159 dynstr type to `struct elf_strtab_hash *'.
161 2001-11-11 Hans-Peter Nilsson <hp@bitrange.com>
163 * elf-strtab.c (_bfd_elf_strtab_finalize): Make first variable i
164 size_t. Rename second i to j.
166 Sat Nov 10 08:56:02 2001 Jeffrey A Law (law@cygnus.com)
168 * binary.c: Include safe-ctype.h after bfd.h and sysdep.h.
170 2001-11-10 Alan Modra <amodra@bigpond.net.au>
172 * elf32-arm.h (elf32_arm_final_link_relocate): Don't copy STN_UNDEF
173 relocs into shared libs.
174 * elf32-cris.c (cris_elf_relocate_section): Likewise.
175 * elf32-i370.c (i370_elf_relocate_section): Likewise.
176 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
177 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
178 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
179 * elf32-sh.c (sh_elf_relocate_section): Likewise.
180 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
181 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
182 * elf64-s390.c (elf_s390_relocate_section): Likewise.
183 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
184 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
185 * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
187 * elf.c (bfd_section_from_r_symndx): New function.
188 * elf-bfd.h (LOCAL_SYM_CACHE_SIZE): Define.
189 (struct sym_sec_cache): New.
190 (bfd_section_from_r_symndx): Declare.
191 (struct bfd_elf_section_data): Change local_dynrel type to PTR.
192 * elflink.h (elf_link_input_bfd): Don't test for removed linkonce
193 relocs when relocatable. Don't zero entire reloc, just zero the
195 * elf32-hppa.c (struct elf32_hppa_link_hash_table): Add sym_sec.
196 (elf32_hppa_link_hash_table_create): Init it.
197 (elf32_hppa_check_relocs): Track dynamic relocs needed for local
198 syms on a per-section basis as we do for globals.
199 (elf32_hppa_gc_sweep_hook): Update for local_dynrel change.
200 (allocate_dynrelocs): Warning fix.
201 (elf32_hppa_size_dynamic_sections): Don't allocate relocs when
202 section has been discarded.
203 (elf32_hppa_relocate_section): Don't copy STN_UNDEF relocs
205 * elf32-i386.c (struct elf_i386_link_hash_table): Add sym_sec.
206 (elf_i386_link_hash_table_create): Init it.
207 (elf_i386_check_relocs): Track dynamic relocs needed for local
208 syms on a per-section basis as we do for globals.
209 (elf_i386_gc_sweep_hook): Update for local_dynrel change.
211 (allocate_dynrelocs): Warning fix.
212 (elf_i386_size_dynamic_sections): Don't allocate relocs when
213 section has been discarded.
214 (elf_i386_relocate_section): Don't copy STN_UNDEF relocs
216 * elf32-s390.c (struct elf_s390_link_hash_table): Add sym_sec.
217 (elf_s390_link_hash_table_create): Init it.
218 (elf_s390_check_relocs): Track dynamic relocs needed for local
219 syms on a per-section basis as we do for globals.
220 (elf_s390_gc_sweep_hook): Update for local_dynrel change.
222 (allocate_dynrelocs): Warning fix.
223 (elf_s390_size_dynamic_sections): Don't allocate relocs when
224 section has been discarded.
225 (elf_s390_relocate_section): Don't copy STN_UNDEF relocs
227 * elf64-ppc.c (struct ppc_link_hash_table): Add sym_sec.
228 (ppc64_link_hash_table_create): Init it.
229 (ppc64_elf_check_relocs): Track dynamic relocs needed for local
230 syms on a per-section basis as we do for globals.
231 (ppc64_elf_gc_sweep_hook): Update for local_dynrel change.
232 (allocate_dynrelocs): Call the correct record_dynamic_dymbol
233 function. Warning fix.
234 (ppc64_elf_size_dynamic_sections): Don't allocate relocs when
235 section has been discarded.
236 (ppc64_elf_relocate_section): Don't copy STN_UNDEF relocs
238 * elf64-s390.c (struct elf_s390_link_hash_table): Add sym_sec.
239 (elf_s390_link_hash_table_create): Init it.
240 (elf_s390_check_relocs): Track dynamic relocs needed for local
241 syms on a per-section basis as we do for globals.
242 (elf_s390_gc_sweep_hook): Update for local_dynrel change.
244 (allocate_dynrelocs): Warning fix.
245 (elf_s390_size_dynamic_sections): Don't allocate relocs when
246 section has been discarded.
247 (elf_s390_relocate_section): Don't copy STN_UNDEF relocs
250 2001-11-08 Martin Schwidefsky <schwidefsky@de.ibm.com>
252 * elf32-s390: Major rework that introduces all recent changes to
253 the s390 backends. Get a closer match to elf32-i386.
254 (elf_s390_relocate_section): Make use of dynamic section short-cuts.
255 Localise vars, and delay setting. Better error reporting, replace
256 BFD_ASSERT with abort. Check ELF_LINK_HASH_DEF_DYNAMIC to see if a
257 symbol is not defined in the regular object file and tread the weak
258 definition as the normal one. Don't discard relocs for undefweak or
259 undefined symbols and check !DEF_REGULAR as well as DEF_DYNAMIC in
260 test for avoided copy relocs. Reinstate fudge for unresolved relocs
261 in debugging sections.
262 (elf32_s390_adjust_dynamic_symbol): Handle nocopyreloc. Don't do copy
263 reloc processing for weakdefs. Remove redundant casts and aborts.
264 Delay setting of vars until needed. Move creation of dynamic symbols
265 and allocation of .plt and .rela.plt to allocate_dynrelocs. Replace
266 BFD_ASSERT with abort. Discard .plt entries for everything with
268 (elf_s390_check_relocs): Don't allocate space for dynamic relocs,
269 .got or .relgot here but do it in allocate_dynrelocs. Reference count
270 possible .plt and .got entries. Don't test input section SEC_READONLY
271 here to try to avoid copy relocs, and keep dyn_relocs regardless of
272 ELF_LINK_NON_GOT_REF. Don't set DF_TEXTREL here. Delay setting of
273 variables until needed. Remove separate switch stmt for creating .got
274 section. Initialise local_got_refcounts to 0. Cache pointer to
275 "sreloc" section in elf_section_data. Tweak condition under which .got
276 created. Report files with bad relocation section names.
277 (elf_s390_finish_dynamic_symbol): Don't copy relocs for symbols that
278 have been forced local. Use same test to decide if we can use a
279 relative reloc for got as elf_s390_relocate_section. Expand SHN_UNDEF
280 comment. Move expressions out of function calls. Replace BFD_ASSERT
282 (elf_s390_finish_dynamic_sections): Migrate common code out of switch
283 statement. Replace BFD_ASSERT with abort.
284 (elf_s390_size_dynamic_sections): Call readonly_dynrelocs. Rename "i"
285 to "ibfd". Allocate space for local dyn relocs. Use DF_TEXTREL flag
286 instead of looking up section names for DT_TEXTREL. Replace
287 BFD_ASSERT with abort. Zero out the dynamic allocated content space.
288 Add a comment to remind us that one day this ought to be fixed.
289 (struct elf_s390_link_hash_entry): Rename "root" to "elf".
290 (struct elf_s390_link_hash_table): Likewise.
291 (elf_s390_link_hash_newfunc): Rename to link_hash_newfunc and get
292 rid of unnecessary casts.
293 (struct elf_s390_dyn_relocs): Add "sec", and "pc_count" fields.
294 Remove "section" field.
295 (elf_s390_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
296 Reference count possible .plt entries. Don't deallocate .got and
298 (struct elf_s390_pcrel_relocs_copied): Rename to elf_s390_dyn_relocs.
300 (struct elf_s390_link_hash_entry): Rename pcrel_relocs_copied to
302 (elf_s390_discard_copies): Delete.
303 (elf_s390_link_hash_traverse): Delete.
304 (bfd_elf32_bfd_final_link): Delete. (ie. use regular final link
305 rather than gc variety).
306 (struct elf_s390_link_hash_table): Add sgot, sgotplt, srelgot, splt,
307 srelplt, sdynbss, srelbss fields.
308 (elf_s390_link_hash_table_create): Init them.
309 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
310 (allocate_dynrelocs): New function.
311 (create_got_section): New function.
312 (elf_backend_can_refcount): Define.
313 (elf_backend_copy_indirect_symbol): Define.
314 (elf_s390_copy_indirect_symbol): New function.
315 (elf_s390_create_dynamic_sections): New function.
316 (readonly_dynrelocs): New function.
317 * elf64-s390.c: Likewise.
319 2001-11-07 Jakub Jelinek <jakub@redhat.com>
321 * Makefile.am (BFD32_BACKENDS): Add elf-strtab.lo.
322 (BFD32_BACKENDS_CFILES): Add elf-strtab.c.
323 (elf-strtab.lo): Add rule.
324 * Makefile.in: Rebuilt.
325 * configure.in (elf): Add elf-strtab.lo.
326 * configure: Rebuilt.
327 * elf-bfd.h (elf_strtab_hash): Forward declare.
328 (struct elf_link_hash_table): Change dynstr type to
329 struct elf_strtab_hash *.
330 (struct elf_obj_tdata): Change strtab_ptr type to
331 struct elf_strtab_hash *.
332 (_bfd_elf_strtab_init, _bfd_elf_strtab_free, _bfd_elf_strtab_add,
333 _bfd_elf_strtab_addref, _bfd_elf_strtab_delref,
334 _bfd_elf_strtab_clear_all_refs, _bfd_elf_strtab_size,
335 _bfd_elf_strtab_offset, _bfd_elf_strtab_emit,
336 _bfd_elf_strtab_finalize): New prototypes.
337 * elf-strtab.c: New file.
338 * elflink.h (elf_link_add_object_symbols): Use _bfd_elf_strtab_add
339 and _bfd_elf_strtab_size instead of _bfd_stringtab calls.
340 Call _bfd_elf_strtab_delref if DT_NEEDED entry is not needed or
341 when forcing dynamic symbol to local.
342 (elf_link_create_dynamic_sections): Call
343 _bfd_elf_strtab_init instead of elf_stringtab_init.
344 (elf_link_record_local_dynamic_symbol): Likewise, change
345 dynstr type. Use _bfd_elf_strtab functions instead of
346 _bfd_stringtab calls.
347 (size_dynamic_sections): Use _bfd_elf_strtab functions instead of
348 _bfd_stringtab calls. For DT_RUNPATH and Verdaux vda_name fields,
349 call _bfd_elf_strtab_addref. Call elf_finalize_dynstr.
350 (elf_adjust_dynstr_offsets, elf_finalize_dynstr): New functions.
351 (elf_fix_symbol_flags): Call _bfd_elf_strtab_delref when forcing
352 dynamic symbol to local.
353 (elf_link_assign_sym_version): Likewise.
354 (elf_bfd_final_link): Call _bfd_elf_strtab_emit instead of
356 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Change dynstr
357 type. Call _bfd_elf_strtab functions instead of
358 _bfd_stringtab functions.
359 * elf64-sparc.c (sparc64_elf_size_dynamic_sections): Likewise.
360 * elf.c (_bfd_elf_init_reloc_shdr): Likewise.
361 (elf_fake_sections): Likewise.
362 (assign_section_numbers): Call _bfd_elf_strtab_clear_all_refs
363 on shstrtab hash table, call _bfd_elf_strtab_addref on each section
364 name in the output. Call _bfd_elf_strtab_finalize and
365 use _bfd_elf_strtab_offset to finalize sh_name section header fields.
366 (_bfd_elf_compute_section_file_positions): Use _bfd_elf_strtab_size
367 instead of _bfd_stringtab_size.
368 (prep_headers): Change shstrtab type.
369 Use _bfd_elf_strtab calls instead of _bfd_stringtab calls.
371 2001-11-07 Alan Modra <amodra@bigpond.net.au>
373 * elflink.h (elf_link_input_bfd <removed linkonce relocs>): Fix
374 bad symtab segfault. Formatting and warning fixes. Improve
375 error message for internationalisation.
377 2001-11-06 H.J. Lu (hjl@gnu.org)
379 * elflink.h (elf_link_input_bfd): Complain about relocs against
382 2001-11-03 Alan Modra <amodra@bigpond.net.au>
384 * elfxx-target.h (elfNN_bed): Correct want_got_sym, want_dynbss order.
386 2001-11-02 H.J. Lu <hjl@gnu.org>
388 * elf32-mips.c (mips_elf_calculate_relocation): Don't create
389 dynamic relocation for symbols defined in regular objects when
390 creating executables.
392 2001-11-02 Nick Clifton <nickc@cambridge.redhat.com>
394 * configure.in (ALL_LINGUAS): Add "fr".
395 * configure: Regenerate.
396 * po/fr.po: New file.
398 * coffgen.c (coff_object_p): Add comment to H.J.'s recent patch.
400 2001-11-02 John David Anglin <dave@hiauly1.hia.nrc.ca>
402 * som.c (setup_sections): Initialize subspace_sections.
404 2001-11-02 H.J. Lu (hjl@gnu.org)
406 * coffgen.c (coff_object_p): Return 0 if the header is too big.
408 2001-11-02 Hans-Peter Nilsson <hp@axis.com>
410 * elfcore.h (elf_core_file_p): Preserve and clear abfd section
411 information. Save bfd arch and mach values. Restore on error.
413 2001-11-02 Alan Modra <amodra@bigpond.net.au>
415 * elf32-hppa.c (hppa_handle_PIC_calls): Rename to mark_PIC_calls.
416 (allocate_PIC_calls): New function.
417 (allocate_dynrelocs): Don't allocate pic_call plt entries here.
418 (elf32_hppa_size_dynamic_sections): Call allocate_PIC_calls.
419 (elf32_hppa_finish_dynamic_symbol): Remove dead code.
421 2001-11-02 Hans-Peter Nilsson <hp@axis.com>
423 * elf32-cris.c (cris_elf_grok_prstatus): New function.
424 (cris_elf_grok_psinfo): New function.
425 (elf_backend_grok_prstatus): Define.
426 (elf_backend_grok_psinfo): Define.
428 2001-11-01 Alan Modra <amodra@bigpond.net.au>
430 * elf64-ppc.c (ppc64_elf_relocate_section): Correct branch
433 2001-10-31 Chris Demetriou <cgd@demetriou.com>
435 * elf32-mips.c (_bfd_mips_elf_hi16_reloc): Handle PC-relative
436 relocations properly.
438 2001-10-31 H.J. Lu <hjl@gnu.org>
440 * elflink.h (elf_link_output_extsym): Don't clear the visibility
441 field for relocateable.
443 2001-11-01 Alan Modra <amodra@bigpond.net.au>
445 * elf32-hppa.c (elf32_hppa_finish_dynamic_sections): Don't count
446 .plt relocs in DT_RELASZ.
448 2001-10-29 NIIBE Yutaka <gniibe@m17n.org>
450 * config.bfd: Supports sh3/sh4/sh3eb/sh4eb-unknown-linux-gnu
453 2001-10-31 Nick Clifton <nickc@cambridge.redhat.com>
455 * targets.c: Fix typo: bfd_mmo_mmix_vec => bfd_mmo_vec.
457 2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
459 * Makefile.am (ALL_MACHINES): Add cpu-mmix.lo.
460 (BFD64_BACKENDS): Add elf64-mmix.lo and mmo.lo.
461 (BFD64_BACKENDS_CFILES): Add elf64-mmix.c and mmo.c.
462 Regenerate dependencies.
463 * configure.in (bfd_elf64_mmix_vec, bfd_mmo_vec): New vectors.
464 * config.bfd: [BFD64] (mmix-*-*): New case.
465 * cpu-mmix.c, mmo.c, elf64-mmix.c: New files.
466 * archures.c (enum bfd_architecture): Add bfd_arch_mmix.
467 (bfd_mmix_arch): Declare.
468 (bfd_archures_list): Add bfd_mmix_arch.
469 * targets.c (enum bfd_flavour): Add bfd_target_mmo_flavour.
470 (bfd_elf64_mmix_vec, bfd_mmo_vec): Declare.
471 (bfd_target_vect) [BFD64]: Add bfd_elf64_mmix_vec and
473 * reloc.c: Add MMIX relocations.
474 * bfd.c (struct _bfd, tdata): Add mmo_data.
475 * Makefile.in: Regenerate.
476 * configure: Regenerate.
477 * libbfd.h: Regenerate.
478 * bfd-in2.h: Regenerate.
479 * configure: Rebuild.
481 2001-10-30 Richard Earnshaw (rearnsha@arm.com)
483 * elf.c (_bfd_elf_make_section_from_shdr): Set the LMA based on the
484 p_paddr of the segment that contains it.
485 (copy_private_bfd_data): If the LMA for a segment is known, use it
486 for matching sections to segments.
487 (assign_file_positions_for_segments): Use the LMA when adjusting
488 for inter-section alignment padding.
490 2001-10-29 Kazu Hirata <kazu@hxi.com>
492 * README: Fix a typo.
494 2001-10-24 Richard Henderson <rth@redhat.com>
496 * peXXigen.c (_bfd_XX_print_private_bfd_data_common): Copy
497 timestamp to time_t for ctime.
499 2001-10-24 Hans-Peter Nilsson <hp@axis.com>
501 * elf32-cris.c (cris_reloc_type_lookup): Change loop to use
502 unsigned, increasing index.
504 2001-10-23 H.J. Lu <hjl@gnu.org>
506 * elf32-mips.c (_bfd_mips_elf_modify_segment_map): Check
507 m != NULL before accessing it.
509 2001-10-23 Alan Modra <amodra@bigpond.net.au>
511 * elflink.h (elf_link_input_bfd): Zero the reloc instead of doing
512 bfd_reloc_type_lookup (bfd, BFD_RELOC_NONE) as bfd_reloc_type_lookup
513 doesn't accept BFD_RELOC_* on some targets, eg. hppa.
515 * elf32-hppa.c (elf32_hppa_link_hash_entry): Remove plt_abs.
516 (hppa_link_hash_newfunc): Likewise.
517 (elf32_hppa_finish_dynamic_symbol): Likewise.
518 (allocate_dynrelocs): Always allocate .got relocs if shared.
519 (elf32_hppa_relocate_section): Output them too. Similarly
520 consolidate .plt reloc code, and no longer initialise .plt
521 when a reloc is output.
522 (elf32_hppa_finish_dynamic_symbol): Only initialise .plt entries
523 when no reloc is output.
525 From Herbert Xu <herbert@gondor.apana.org.au>
526 * elf32-hppa.c (final_link_relocate): Call bfd_set_error for
527 unreachable branches.
529 2001-10-22 H.J. Lu <hjl@gnu.org>
531 * configure.in (WIN32LIBADD): Use -L../libiberty for
533 * configure: Rebuild.
535 2001-10-21 H.J. Lu <hjl@gnu.org>
537 * configure.in (WIN32LIBADD): Include -L../libiberty/pic -liberty
538 if shared library is enabled only for Linux hosts.
539 * configure: Rebuild.
541 2001-10-21 H.J. Lu <hjl@gnu.org>
543 * configure.in (WIN32LIBADD): Check if PICFLAG is defined in
544 ../libiberty/Makefile instead of $enable_shared.
545 * configure: Rebuild.
547 2001-10-21 H.J. Lu <hjl@gnu.org>
549 * elf32-cris.c (cris_reloc_type_lookup): Use int for index. Cover
552 2001-10-20 H.J. Lu <hjl@gnu.org>
554 * configure.in (WIN32LIBADD): Include -L../libiberty/pic -liberty
555 if shared library is enabled.
556 * configure: Rebuild.
558 2001-10-20 H.J. Lu <hjl@gnu.org>
560 * elf32-cris.c (cris_reloc_type_lookup): Allow index 0.
562 2001-10-19 H.J. Lu <hjl@gnu.org>
564 * elfcode.h (elf_object_p): Don't clear D_PAGED if the section
567 2001-10-18 H.J. Lu <hjl@gnu.org>
569 * elf32-i370.c (i370_elf_relocate_section): Ignore R_XXX_NONE.
570 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
572 2001-10-18 Jakub Jelinek <jakub@redhat.com>
574 * section.c (_bfd_strip_section_from_output): Don't count
575 SEC_EXCLUDE sections as references. Set SEC_EXCLUDE.
577 2001-10-17 Alan Modra <amodra@bigpond.net.au>
579 * elf-m10200.c (mn10200_elf_relax_section): Cast assignment to
580 Elf_Internal_Shdr.contents now that it's no longer a PTR.
581 * elf-m10300.c (mn10300_elf_relax_section): Likewise.
582 * elf32-h8300.c (elf32_h8_relax_section): Likewise.
583 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Likewise.
584 * elf32-sh.c (sh_elf_relax_section): Likewise.
585 * elf64-alpha.c (elf64_alpha_relax_section): Likewise.
586 * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
587 * elf.c (setup_group): Warning fixes.
588 * elflink.h (elf_link_sort_relocs): Likewise.
589 * pdp11.c (slurp_reloc_table): Likewise.
591 2001-10-16 Jeff Holcomb <jeffh@redhat.com>
593 * elflink.h (elf_link_sort_relocs): Remove unnecessary pointer
596 2001-10-15 H.J. Lu <hjl@gnu.org>
598 * elflink.h (elf_link_input_bfd): Set type to BFD_RELOC_NONE
599 for relocations against discarded link-once section.
601 2001-10-15 Alan Modra <amodra@bigpond.net.au>
603 * elf32-i386.c (elf_i386_relocate_section): Report some detail on
604 bfd_reloc_outofrange and similar errors.
606 * elf.c (_bfd_elf_link_hash_copy_indirect): Test ind->root.type
607 rather than ind->weakdef.
608 * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Likewise.
609 * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
610 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Likewise.
611 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
612 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
614 2001-10-15 Alan Modra <amodra@bigpond.net.au>
615 H.J. Lu <hjl@gnu.org>
617 * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Merge dyn_reloc
618 counts for aliases instead of aborting.
619 * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
620 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
622 * elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Set plt.offset
623 to -1 for non-function symbols.
624 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Likewise.
625 * elf32-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
626 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
627 * elf64-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
628 * elf64-x86-64.c (elf64_x86_64_adjust_dynamic_symbol): Likewise.
629 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Refer to
630 plt.offset instead of plt.refcount when setting to -1.
632 2001-10-12 Nick Clifton <nickc@cambridge.redhat.com>
634 * elf32-arm.h (elf32_arm_relocate_section): Treat R_ARM_THM_PC22
635 like R_ARM_PC24. Include reloc number in error message about
638 2001-10-10 Jakub Jelinek <jakub@redhat.com>
640 * elflink.h (elf_link_sort_cmp2): Don't mix PLT and non-PLT
641 relocations against the same symbol in .rel{,a}.dyn section.
643 2001-10-10 Kazu Hirata <kazu@hxi.com>
645 * aout-encap.c: Fix comment typos.
647 * archive.c: Likewise.
649 * coff64-rs6000.c: Likewise.
650 * coffcode.h: Likewise.
651 * coffgen.c: Likewise.
652 * cofflink.c: Likewise.
653 * coff-mips.c: Likewise.
655 * elf32-m32r.c: Likewise.
656 * libcoff-in.h: Likewise.
657 * libecoff.h: Likewise.
658 * libxcoff.h: Likewise.
659 * nlm32-i386.c: Likewise.
661 * section.c: Likewise.
664 * bfd-in2.h: Regenerate.
665 * libcoff.h: Likewise.
667 2001-10-10 Alan Modra <amodra@bigpond.net.au>
669 * elf.c (elf_map_symbols): Don't create new section symbols; Use
670 existing section syms. Update comments.
671 (copy_private_bfd_data): Formatting fixes.
672 (elfcore_grok_win32pstatus): Likewise.
673 (swap_out_syms): Likewise. Remove unnecessary level of braces.
675 2001-10-09 Alan Modra <amodra@bigpond.net.au>
677 * elf-bfd.h (struct bfd_elf_section_data): Rename "group" to
679 (elf_group_name): Define.
680 (elf_next_in_group): Define.
681 * elf.c: Make use of elf_group_name and elf_next_in_group throughout.
682 (setup_group): Don't use sec->lineno for SHT_GROUP section to store
683 first member section; Instead use elf_next_in_group.
684 (bfd_section_from_shdr): Likewise.
685 (set_group_contents): Likewise. Use elf_section_syms, not sec->symbol.
687 2001-10-09 Alan Modra <amodra@bigpond.net.au>
689 * elf-bfd.h (struct bfd_elf_section_data): Add "group" and
690 "next_in_group". Fix gp and gp_size comments.
691 * elf.c (union elf_internal_group): New.
692 (setup_group): New function.
693 (_bfd_elf_make_section_from_shdr): Set BFD flags for SHT_GROUP.
694 Call setup_group for SHF_GROUP sections.
695 (bfd_section_from_shdr): Build a BFD section for SHT_GROUP.
696 (elf_fake_sections): Set header type for SEC_GROUP, and header
697 flags for sections in a group.
698 (set_group_contents): New function.
699 (_bfd_elf_compute_section_file_positions): Call it.
700 (assign_section_numbers): Set sh_link for SHT_GROUP.
702 * elflink.h (gc_mark_hook): Handle section groups.
703 * elfxx-target.h: Add SEC_GROUP to applicable_flags.
704 * section.c (SEC_GROUP): Define.
705 (struct sec): Comment fixes.
706 * bfd-in2.h: Regenerate.
708 * elf.c (bfd_elf_print_symbol): Formatting fix; migrate expression
709 out of function args.
710 (_bfd_elf_canonicalize_reloc): Similarly.
711 (_bfd_elf_get_symtab): Here too.
712 (_bfd_elf_canonicalize_dynamic_symtab): And here.
713 * elfcode.h (elf_slurp_symbol_table): Don't recalculate size for
714 bfd_bread, and remove unnecessary cast.
716 2001-10-08 Aldy Hernandez <aldyh@redhat.com>
718 * bfd/config.bfd (targ_cpu): Add arm9e-*-elf.
720 2001-10-06 Stephane Carrez <Stephane.Carrez@worldnet.fr>
722 * dwarf2.c (comp_unit_find_nearest_line): Check for end of
725 2001-10-06 Alan Modra <amodra@bigpond.net.au>
727 * bfd.c (bfd_assert): Report bfd version.
728 (_bfd_abort): Likewise.
730 * elflink.h (elf_link_input_bfd): Don't zero discarded link-once
731 section sym values. Instead replace any relocs against them with
732 relocs against STN_UNDEF, which has a zero value.
734 * elf32-arc.c (elf_arc_howto_table): Set partial_inplace for all
737 2001-10-05 Jeff Law <law@redhat.com>
739 * som.h (som_exec_data): New field "version_id".
740 * som.c (som_object_setup): Record the version_id if it
742 (som_prep_headers): Do not initialize version_id here.
743 (som_finish_writing): Initialize version_id here.
745 2000-10-05 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
747 * elf32-mips.c (elf_mips_howto_table): Fix some relocation howtos
748 according to the MIPS/SGI ELF64 ABI Draft.
749 (mips_elf_sort_hash_table): Typo.
751 2001-10-04 Alan Modra <amodra@bigpond.net.au>
753 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Comment typo.
755 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Bail out after
756 copying flags if this is a weakdef.
758 2001-10-04 Alan Modra <amodra@bigpond.net.au>
760 * elf-bfd.h (struct elf_link_hash_entry): Reorganise for better
763 * elf32-mips.c (mips_elf_record_global_got_symbol): Set got.offset
764 to 1 rather than 0 to avoid confusing copy_indirect_symbol.
765 (mips_elf_sort_hash_table_f): Compare got.offset against 1.
767 * Makefile.am (BFD_H_DEPS): Add symcat.h. Ensure everything
768 depends on $(BFD_H) $(BFD_H_DEPS) $(LOCAL_H_DEPS), not just those
769 backends we configure. Run "make dep-am".
770 (install-data-local): Install symcat.h.
771 * dep-in.sed: Remove symcat.h from dependencies.
772 * Makefile.in: Regenerate.
774 2001-10-03 Vassili Karpov <malc@pulsesoft.com>
776 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Handle nocopyreloc.
778 2001-10-03 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
780 * elf64-mips.c (elf_backend_may_use_rela_p): New define.
781 (elf_backend_default_use_rela_p): New define.
783 2001-10-03 Alan Modra <amodra@bigpond.net.au>
785 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Fix typos in last
788 * configure.in (AC_OUTPUT <bfd-in3.h>): Remove version.h.
789 * configure: Regenerate.
790 * Makefile.am (BFD_H_FILES): Add version.h.
791 * Makefile.in: Regenerate.
792 * po/SRC-POTFILES.in: Regenerate.
794 * elflink.h (elf_fix_symbol_flags): Copy flags to weakdef using
795 elf_backend_copy_indirect_symbol so that backend has a chance to
796 copy other necessary fields.
797 * elf-bfd.h (struct elf_backend_data): Update description of
798 elf_backend_copy_indirect_symbol.
799 * elf.c (_bfd_elf_link_hash_copy_indirect): Bail out after
800 copying flags if this is a weakdef.
801 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
802 (elfNN_ia64_aix_add_symbol_hook): Use elf_link_hash_lookup rather
803 than bfd_link_hash_lookup.
804 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Don't do copy
805 reloc processing for weakdefs.
806 * elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Likewise.
807 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
809 2001-10-02 Alan Modra <amodra@bigpond.net.au>
811 * elf64-ppc.c (ppc64_elf_check_relocs): Use a local var and cast
812 result of ELF64_R_TYPE to enum before using in a switch.
813 (ppc64_elf_gc_mark_hook): Likewise.
814 (ppc64_elf_gc_sweep_hook): Likewise.
815 (ppc64_elf_reloc_type_class): Likewise.
817 2001-10-02 Alan Modra <amodra@bigpond.net.au>
819 * version.h: New file.
820 * bfd-in.h: (BFD_VERSION): Substitute bfd_version.
821 (BFD_VERSION_DATE): Define.
822 (BFD_VERSION_STRING): Define.
823 * configure.in: AC_SUBST bfd_version, bfd_version_date and
825 (AC_OUTPUT <bfd-in3.h>): Depend on version.h.
826 * bfd-in2.h: Regenerate.
827 * configure: Regenerate.
828 * Makefile.am: Run "make dep-am".
829 * Makefile.in: Regenerate.
831 * bfd-in.h: Include "symcat.h".
832 (CONCAT4): Redefine as for old CAT4.
833 * aout-arm.c: Use equivalent CONCAT* macro in place of CAT* macros.
834 Add warning regarding whitespace.
835 * aout-cris.c: Likewise.
836 * aout-ns32k.c: Likewise.
837 * aout-sparcle.c: Likewise.
838 * aout-tic30.c: Likewise.
840 * armnetbsd.c: Likewise.
841 * demo64.c: Likewise.
842 * elf-bfd.h: Likewise.
843 * gen-aout.c: Likewise.
844 * host-aout.c: Likewise.
845 * hp300bsd.c: Likewise.
846 * hp300hpux.c: Likewise.
847 * i386aout.c: Likewise.
848 * i386bsd.c: Likewise.
849 * i386dynix.c: Likewise.
850 * i386freebsd.c: Likewise.
851 * i386linux.c: Likewise.
852 * i386lynx.c: Likewise.
853 * i386mach3.c: Likewise.
854 * i386netbsd.c: Likewise.
855 * libaout.h: Likewise.
856 * m68k4knetbsd.c: Likewise.
857 * m68klinux.c: Likewise.
858 * m68klynx.c: Likewise.
859 * m68knetbsd.c: Likewise.
860 * m88kmach3.c: Likewise.
861 * mipsbsd.c: Likewise.
862 * newsos3.c: Likewise.
863 * ns32knetbsd.c: Likewise.
864 * pc532-mach.c: Likewise.
866 * riscix.c: Likewise.
867 * sparclinux.c: Likewise.
868 * sparclynx.c: Likewise.
869 * sparcnetbsd.c: Likewise.
871 * targets.c: Likewise.
872 * vaxnetbsd.c: Likewise.
873 * vms-hdr.c: Likewise.
875 2001-10-01 Alan Modra <amodra@bigpond.net.au>
877 * bfd-in.h: Remove comments regarding generated files.
878 * libbfd-in.h: Likewise.
879 * libcoff-in.h: Likewise.
880 * bfd-in2.h: Regenerate.
881 * libbfd.h: Likewise.
882 * libcoff.h: Likewise.
884 2001-09-30 kaz Kojima <kkojima@rr.iij4u.or.jp>
885 Hans-Peter Nilsson <hp@bitrange.com>
887 * elf32-sh.c (sh_elf_howto_table, R_SH_REL32): Make
888 partial_inplace, matching assembler output. Set src_mask to
890 (sh_elf_relocate_section): Delete misplaced comment.
891 For relocatable linking against section symbol, call
892 _bfd_relocate_contents for partial_inplace relocs and adjust
893 rel->r_addend for others.
894 <case R_SH_DIR32, R_SH_REL32>: Fetch partial_inplace addend with
895 bfd_get_32, not at rel->r_addend.
897 2001-09-30 Alan Modra <amodra@bigpond.net.au>
899 * elf.c (_bfd_elf_link_hash_copy_indirect): Set ind refcounts to
900 the old dir refcount, so we indirectly set them to init_refcount.
901 Short-circuit asserts when we've just verified they are true.
903 2001-09-29 Alan Modra <amodra@bigpond.net.au>
905 * section.c (struct sec): Remove kept_section.
906 (STD_SECTION): Remove kept_section initialisation.
907 (bfd_make_section_anyway): Here too.
908 * ecoff.c (bfd_debug_section): Remove kept_section initialisation.
909 * cofflink.c (_bfd_coff_link_input_bfd): Don't test kept_section.
910 * elflink.h (elf_link_input_bfd): Set discarded link-once section
911 symbols to zero, and remove all code involved with kept_section
912 and tracking section symbol values.
913 * bfd-in2.h: Regenerate.
914 * configure.in: Bump version number.
915 * configure: Regenerate.
917 2001-09-29 Alan Modra <amodra@bigpond.net.au>
919 * elf64-ppc.c (struct ppc_dyn_relocs): New.
920 (IS_ABSOLUTE_RELOC): Define.
921 (struct ppc_link_hash_entry): New.
922 (struct ppc_link_hash_table): New.
923 (ppc_hash_table): Define.
924 (link_hash_newfunc): New function.
925 (ppc64_elf_link_hash_table_create): New function.
926 (create_got_section): New function.
927 (ppc64_elf_create_dynamic_sections): Call create_got_section. Stash
928 pointers to our dynamic sections in hash table.
929 (ppc64_elf_copy_indirect_symbol): New function.
930 (ppc64_elf_check_relocs): Remove DEBUG code. Use short-cuts to
931 dynamic sections. Localise vars. Modify code for refcounts
932 starting from zero. Don't allocate here, or force symbols dynamic.
933 Don't copy all relocs if shared, select ones we need. Add code
934 to track possible copy relocs for non-shared link.
935 (ppc64_elf_gc_mark_hook): Update comment.
936 (ppc64_elf_gc_sweep_hook): Sweep dynrelocs too.
937 (ppc64_elf_adjust_dynamic_symbol): Remove DEBUG code. Rewrite .plt
938 code for reference counting garbage collection. Don't create .plt
939 entries for functions that don't comply with ABI naming convention,
940 and don't allocate .plt space here. Use short-cuts to dynamic
941 sections. If possible, keep dynamic relocations instead of using
942 copy relocs. Remove confused comments.
943 (ppc_adjust_dynindx): Delete.
944 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
945 (allocate_dynrelocs): New function.
946 (readonly_dynrelocs): New function.
947 (ppc64_elf_size_dynamic_sections): Rewrite. Allocate local .got
948 space here, and call allocate_dynrelocs to allocate space for
949 global .plt, .got and reloc sections. Use short-cuts to dynamic
950 sections. Call readonly_dynrelocs to determine whether we need
951 DT_TEXTREL. Don't generate section symbols here, the generic
952 ELF linker code does it for us.
953 (ppc64_elf_final_link): Call regular ELF backend linker rather than
954 gc variety, since we do our own .got handling.
955 (ppc64_elf_relocate_section): Remove DEBUG code. Make use of
956 dynamic section short-cuts. Localise vars, and delay setting.
957 Handle unknown relocs in main switch statement. Replace ugly
958 complicated tests for unresolvable relocs with a simple direct
959 scheme using "unresolved_reloc" var. Test ELF_ST_VISIBILITY
960 before allowing an undefined sym in a shared lib. Do R_*_DS tests
961 after main switch, when we've set addend. Do non-addend insn
962 tweaks before main swithc. Ignore input_section->vma when
963 calculating reloc offsets as it's always zero. Rewrite dynamic
964 reloc handling. Consolidate R_*_HA handling. Handle more relocs.
965 (ppc64_elf_finish_dynamic_symbol): Remove DEBUG code. Make use
966 of dynamic section short-cuts. Reorganise .plt handling code.
967 Remove confused comments. Take note of ELF_LINK_FORCED_LOCAL.
968 Move expressions out of swap_reloca_out function calls.
969 (ppc64_elf_reloc_type_class): New function.
970 (ppc64_elf_info_to_howto): Move common expression to local var.
971 (ppc64_elf_finish_dynamic_sections): Remove DEBUG code. Make use
972 of dynamic section short-cuts. Don't fiddle with section syms
973 here as the ELF linker does it for us.
974 (elf_backend_can_refcount): Define.
975 (bfd_elf64_bfd_link_hash_table_create): Define.
976 (elf_backend_copy_indirect_symbol): Define.
977 (elf_backend_reloc_type_class): Define.
978 (elf_backend_*, bfd_elf64_bfd_* defines): Sort.
980 2001-09-29 Alan Modra <amodra@bigpond.net.au>
982 * elf-bfd.h (struct elf_link_local_dynamic_entry): Add init_refcount.
983 (struct elf_backend_data): Add can_refcount.
984 * elf.c (_bfd_elf_link_hash_newfunc): Get rid of a few casts. Set
985 got.refcount and plt.refcount from init_refcount.
986 (_bfd_elf_link_hash_table_init): Set up init_refcount.
987 (_bfd_elf_link_hash_copy_indirect): Reference got/plt.refcount
988 rather than got/plt.offset, and test for <= 0 rather than -1.
989 * elflink.h (size_dynamic_sections): Set init_refcount to -1.
990 * elfxx-target.h (elf_backend_can_refcount): Define.
991 (elfNN_bed): Init can_refcount.
992 * linker.c (_bfd_link_hash_newfunc): Get rid of a few casts.
993 (_bfd_generic_link_hash_newfunc): Likewise.
994 * elf32-cris.c (cris_elf_check_relocs): Modify for refcounts
996 (elf_backend_can_refcount): Define.
997 * elf32-hppa.c (elf32_hppa_check_relocs): Modify for refcounts
999 (elf32_hppa_copy_indirect_symbol): Make static to agree with
1001 (elf_backend_can_refcount): Define.
1002 * elf32-i386.c (elf_i386_check_relocs): Modify for refcounts
1004 (allocate_dynrelocs): Set plt/got.offset rather than *.refcount.
1005 (elf_i386_finish_dynamic_symbol): Expand SHN_UNDEF comment.
1006 (elf_i386_finish_dynamic_sections): Use local var so line < 80 chars.
1007 (elf_backend_can_refcount): Define.
1008 (elf_i386_copy_indirect_symbol): Make static to agree with
1009 prototype. Formatting fix.
1010 * elf32-m68k.c (elf_m68k_check_relocs): Modify for refcounts
1012 (elf_backend_can_refcount): Define.
1013 * elf32-ppc.c (ppc_elf_check_relocs): Modify for refcounts
1015 (elf_backend_can_refcount): Define.
1016 * elf32-s390.c (elf_s390_check_relocs): Modify for refcounts
1018 (elf_backend_can_refcount): Define.
1019 * elf64-s390.c (elf_s390_check_relocs): Modify for refcounts
1021 (elf_backend_can_refcount): Define.
1022 * elf64-x86-64.c (elf64_x86_64_check_relocs): Modify for refcounts
1024 (elf_backend_can_refcount): Define.
1026 * som.c (som_write_symbol_strings): Cast current_offset in
1027 bfd_seek call to match param type.
1029 2001-09-28 J. Brobecker <brobecker@gnat.com>
1031 * som.c (som_write_symbol_strings): Fix incorrect type of
1032 current_offset to match the function definition. Fixes a build
1033 failure on HPUX-11.00.
1035 2001-09-28 Richard Henderson <rth@redhat.com>
1037 * elfxx-target.h [section_flags]: Add SEC_ARCH_BIT_0, SEC_SMALL_DATA,
1038 SEC_MERGE, SEC_STRINGS.
1040 * section.c (SEC_ARCH_BIT_0): New; replace unused SEC_BALIGN.
1041 * bfd-in2.h: Rebuild.
1043 2001-09-28 Alan Modra <amodra@bigpond.net.au>
1045 * elf64-x86-64.c (elf64_x86_64_reloc_type_lookup): Don't map bfd
1046 reloc code using x86_64_reloc_map.
1048 * elf32-hppa.c (elf32_hppa_check_relocs): Update comment since we
1049 no longer allocate here. Localise some vars to blocks where they
1051 (elf32_hppa_adjust_dynamic_symbol): Correct a comment. Delay
1052 setting of vars until needed.
1053 (allocate_dynrelocs): Don't create a .plt entry without a reloc
1054 when symbol visibilty makes a function local.
1055 (elf32_hppa_finish_dynamic_symbol): Move expressions out of
1056 swap_reloca_out function calls.
1057 (elf32_hppa_relocate_section): Likewies. Comment typo fix.
1058 (elf32_hppa_finish_dynamic_sections): Migrate common code out of
1061 * elf32-i386.c (elf_i386_check_relocs): Update comment since we
1062 no longer allocate here. Localise some vars to blocks where they
1063 are used. Remove separate switch stmt for creating .got sec.
1064 (elf_i386_adjust_dynamic_symbol): Correct a comment. Remove
1065 redundant casts and aborts. Delay setting of vars until needed.
1066 (allocate_dynrelocs): Remove redundant casts and aborts.
1067 (elf_i386_size_dynamic_sections): Move comment.
1068 (elf_i386_finish_dynamic_symbol): Move expressions out of function
1070 (elf_i386_relocate_section): Likewise. Comment typo fix.
1071 (elf_i386_finish_dynamic_sections): Migrate common code out of
1073 (elf_backend_* defines): Sort.
1075 * elf32-i386.c (allocate_dynrelocs): Don't create a .plt entry
1076 without a reloc when symbol visibilty makes a function local.
1078 2001-09-27 Nick Clifton <nickc@cambridge.redhat.com>
1080 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix detection of
1081 conflicting float flags.
1083 2001-09-26 Alan Modra <amodra@bigpond.net.au>
1085 * elf32-i386 (elf_i386_copy_indirect_symbol): New function.
1086 (elf_backend_copy_indirect_symbol): Define.
1087 (struct elf_i386_link_hash_entry): Rename "root" to "elf".
1088 (struct elf_i386_link_hash_table): Likewise.
1089 (link_hash_newfunc): Get rid of unnecessary casts.
1090 (elf_i386_link_hash_table_create): Likewise.
1091 (elf_i386_check_relocs): Initialise local_got_refcounts to 0.
1092 Don't test input section SEC_READONLY here to try to avoid copy
1093 relocs, and keep dyn_relocs regardleas of ELF_LINK_NON_GOT_REF.
1094 (elf_i386_adjust_dynamic_symbol): Check output section SEC_READONLY
1095 here to properly test whether we need copy relocs. Do so for weak
1098 * elf32-hppa (elf32_hppa_copy_indirect_symbol): New function.
1099 (elf_backend_copy_indirect_symbol): Define.
1100 (struct elf32_hppa_link_hash_table): Rename "root" to "elf".
1101 (stub_hash_newfunc): Get rid of unnecessary casts.
1102 (hppa_link_hash_newfunc): Likewise.
1103 (elf32_hppa_check_relocs): Initialise local_got_refcounts to 0.
1104 Don't test input section SEC_READONLY here to try to avoid copy
1105 relocs, and keep dyn_relocs regardleas of ELF_LINK_NON_GOT_REF.
1106 (elf32_hppa_adjust_dynamic_symbol): Check output section SEC_READONLY
1107 here to properly test whether we need copy relocs. Do so for weak
1110 2001-09-26 Alan Modra <amodra@bigpond.net.au>
1112 * bfd.c (_bfd_default_error_handlerl): Define using VPARAMS,
1113 VA_OPEN, VA_FIXEDARG, VA_CLOSE.
1114 (bfd_archive_filename): Cast bfd_malloc arg to the correct size.
1116 2001-09-25 Jakub Jelinek <jakub@redhat.com>
1118 * elf64-sparc.c (sparc64_elf_build_plt): Fix .plt[32768+] slot
1121 2001-09-25 H.J. Lu <hjl@gnu.org>
1123 * bfd-in2.h: Regenerated.
1125 2001-09-25 Alan Modra <amodra@bigpond.net.au>
1127 * elf32-i386.c: Add comment re linker function names and ordering.
1128 (elf_i386_link_hash_newfunc): Rename to link_hash_newfunc.
1129 (elf_i386_grok_prstatus): Move before linker functions.
1130 (elf_i386_grok_psinfo): Likewise.
1131 (elf_i386_fake_sections): Move so that functions are ordered.
1132 (elf_i386_reloc_type_class): Likewise. Comment function purpose.
1134 2001-09-25 Alan Modra <amodra@bigpond.net.au>
1136 * elf32-hppa.c: Rename occurrences of "hplink" to "htab"
1139 * elf32-hppa.c: (LONG_BRANCH_PIC_IN_SHLIB): Delete. Remove all
1140 code handling this option.
1141 (LONG_BRANCH_VIA_PLT): Likewise.
1142 (RELATIVE_DYNRELOCS): Define as zero.
1143 (struct elf32_hppa_dyn_reloc_entry): Add "sec", and
1144 "pc_count" fields. Remove "section" field.
1145 (elf32_hppa_link_hash_entry): Rename reloc_entries to dyn_relocs.
1146 (elf32_hppa_check_relocs): Don't allocate space for dynamic
1147 relocs here. Instead, record all needed dynamic relocs via
1148 dyn_relocs and local_dynrel. Cache pointer to "sreloc" section
1149 in elf_section_data.
1150 (elf32_hppa_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
1151 (allocate_plt_and_got_and_discard_relocs): Rename to
1152 allocate_dynrelocs. Allocate rather than discarding dyn relocs.
1153 (readonly_dynrelocs): New function.
1154 (elf32_hppa_size_dynamic_sections): Mark output_bfd unused.
1155 Call readonly_dynrelocs to determine need for DT_TEXTREL.
1156 Rename "i" to "ibfd". Allocate space for local dyn relocs.
1157 (elf32_hppa_relocate_section): Make use of cached sreloc.
1158 (elf32_hppa_reloc_type_class): New function.
1159 (elf_backend_reloc_type_class): Define.
1161 2001-09-25 Alan Modra <amodra@bigpond.net.au>
1163 * elf-bfd.h (struct bfd_elf_section_data): Add "local_dynrel"
1164 and "sreloc" fields.
1165 * elf32-i386.c (struct elf_i386_dyn_relocs): Add "sec", and
1166 "pc_count" fields. Remove "section" field.
1167 (elf_i386_check_relocs): Don't set DF_TEXTREL here. Don't
1168 allocate space for dynamic relocs here. Instead, record all
1169 needed dynamic relocs via dyn_relocs and local_dynrel. Cache
1170 pointer to "sreloc" section in elf_section_data.
1171 (elf_i386_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
1172 (allocate_plt_and_got_and_discard_relocs): Rename to
1173 allocate_dynrelocs. Allocate rather than discarding dyn relocs.
1174 (readonly_dynrelocs): New function.
1175 (elf_i386_size_dynamic_sections): Call readonly_dynrelocs.
1176 Rename "i" to "ibfd". Allocate space for local dyn relocs.
1177 (elf_i386_relocate_section): Make use of cached sreloc.
1179 2001-09-24 Alan Modra <amodra@bigpond.net.au>
1181 * elf-bfd.h (elf_backend_reloc_type_class): Pass in the entire
1182 reloc rather than just the type.
1183 (_bfd_elf_reloc_type_class): Likewise.
1184 * elf.c (_bfd_elf_reloc_type_class): Likewise.
1185 * elf32-arm.h (elf32_arm_reloc_type_class): Likewise.
1186 * elf32-cris.c (elf_cris_reloc_type_class): Likewise.
1187 * elf32-i386.c (elf_i386_reloc_type_class): Likewise.
1188 * elf32-m68k.c (elf32_m68k_reloc_type_class): Likewise.
1189 * elf32-ppc.c (ppc_elf_reloc_type_class): Likewise.
1190 * elf32-s390.c (elf_s390_reloc_type_class): Likewise.
1191 * elf32-sh.c (sh_elf_reloc_type_class): Likewise.
1192 * elf32-sparc.c (elf32_sparc_reloc_type_class): Likewise.
1193 * elf64-alpha.c (elf64_alpha_reloc_type_class): Likewise.
1194 * elf64-s390.c (elf_s390_reloc_type_class): Likewise.
1195 * elf64-sparc.c (sparc64_elf_reloc_type_class): Likewise.
1196 * elf64-x86-64.c (elf64_x86_64_reloc_type_class): Likewise.
1197 * elfxx-ia64.c (elfNN_ia64_reloc_type_class): Likewise.
1198 * elflink.h: Formatting fixes.
1199 (elf_link_sort_relocs): Make "count" and "size" bfd_size_type.
1200 Call bfd_zmalloc rather than calloc. Remove unnecessary cast of
1201 o->contents to PTR. Update call to elf_backend_reloc_type_class.
1203 2001-09-22 John Reiser <jreiser@BitWagon.com>
1205 * elfcode.h (elf_object_p): Allow for no section header at all in
1206 non-ET_REL files. Honor 0 for e_shnum, e_shstrndx, e_shoff.
1208 2001-09-21 Nick Clifton <nickc@cambridge.redhat.com>
1210 * elfxx-ia64.c: Fix compile time warning messages.
1211 * coff-mcore.c: Fix compile time warning messages.
1212 * coff-ppc.c: Fix compile time warning messages.
1213 * coffcode.h: Fix compile time warning messages.
1214 * elf32-mips.c: Fix compile time warning messages.
1215 * elf64-alpha.c: Fix compile time warning messages.
1216 * libbfd.c: Fix compile time warning messages.
1217 * bfd-in2.h: Regenerate.
1219 2001-09-21 Alan Modra <amodra@bigpond.net.au>
1221 * Makefile.am: Run "make dep-am".
1222 * Makefile.in: Regenerate.
1224 * aoutx.h: Formatting fixes.
1225 * merge.c (_bfd_merged_section_offset): Break line at 80 chars.
1227 * linker.c: Replace bfd_get_filename with bfd_archive_filename
1230 2001-09-21 Alan Modra <amodra@bigpond.net.au>
1232 * bfd.c (bfd_archive_filename): New function.
1233 * bfd-in2.h: Regenerate.
1234 * aout-adobe.c: Replace bfd_get_filename with bfd_archive_filename
1235 in error messages where the bfd is an input bfd.
1236 * aout-cris.c: Likewise.
1237 * coff-arm.c: Likewise.
1238 * coff-mcore.c: Likewise.
1239 * coff-ppc.c: Likewise.
1240 * coff-rs6000.c: Likewise.
1241 * coff-sh.c: Likewise.
1242 * coff-tic54x.c: Likewise.
1243 * coff-tic80.c: Likewise.
1244 * coff64-rs6000.c: Likewise.
1245 * coffcode.h: Likewise.
1246 * coffgen.c: Likewise.
1247 * cofflink.c: Likewise.
1248 * ecofflink.c: Likewise.
1249 * elf-hppa.h: Likewise.
1251 * elf32-arm.h: Likewise.
1252 * elf32-cris.c: Likewise.
1253 * elf32-gen.c: Likewise.
1254 * elf32-hppa.c: Likewise.
1255 * elf32-i370.c: Likewise.
1256 * elf32-i386.c: Likewise.
1257 * elf32-m32r.c: Likewise.
1258 * elf32-mcore.c: Likewise.
1259 * elf32-mips.c: Likewise.
1260 * elf32-ppc.c: Likewise.
1261 * elf32-s390.c: Likewise.
1262 * elf32-sh.c: Likewise.
1263 * elf32-sparc.c: Likewise.
1264 * elf32-v850.c: Likewise.
1265 * elf64-alpha.c: Likewise.
1266 * elf64-gen.c: Likewise.
1267 * elf64-ppc.c: Likewise.
1268 * elf64-s390.c: Likewise.
1269 * elf64-sparc.c: Likewise.
1270 * elf64-x86-64.c: Likewise.
1271 * elflink.h: Likewise.
1272 * elfxx-ia64.c: Likewise.
1275 * libbfd.c: Likewise.
1276 * pdp11.c: Likewise.
1277 * pe-mips.c: Likewise.
1278 * peicode.h: Likewise.
1280 * xcofflink.c: Likewise.
1282 * elf32-arm.h: Make _bfd_error_handler calls K&R compatible.
1284 * elflink.c (_bfd_elf_create_linker_section): Better grammar for
1287 * coff-mcore.c (coff_mcore_relocate_section): Internalionalise
1290 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Constify stt_types.
1291 Consolidate error messages, and split long messages to two lines.
1293 2001-09-20 John Reiser <jreiser@BitWagon.com>
1295 * elf32-i386.c (elf_i386_relocate_section): Coordinate info->symbolic
1296 and info->allow_shlib_undefined.
1297 * elf32-cris.c: Likewise.
1298 * elf32-hppa.c: Likewise.
1299 * elf32-m68k.c: Likewise.
1300 * elf32-mips.c: Likewise.
1301 * elf32-ppc.c: Likewise.
1302 * elf32-s390.c: Likewise.
1303 * elf32-sh.c: Likewise.
1304 * elf32-sparc.c: Likewise.
1305 * elf64-alpha.c: Likewise.
1306 * elf64-hppa.c: Likewise.
1307 * elf64-ppc.c: Likewise.
1308 * elf64-s390.c: Likewise.
1309 * elf64-sparc.c: Likewise.
1310 * elf64-x86-64.c: Likewise.
1311 * elfxx-ia64.c: Likewise.
1313 2001-09-18 Bruno Haible <haible@clisp.cons.org>
1315 * aoutx.h: Include "safe-ctype.h" instead of <ctype.h>.
1316 (aout_link_write_symbols): Use ISDIGIT instead of isdigit.
1317 * archive.c: Include "safe-ctype.h" instead of <ctype.h>.
1318 (_bfd_generic_read_ar_hdr_mag): Use ISDIGIT instead of isdigit.
1319 * archures.c: Include "safe-ctype.h" instead of <ctype.h>.
1320 (bfd_default_scan): Use ISDIGIT instead of isdigit.
1321 * bfd.c: Include "safe-ctype.h" instead of <ctype.h>.
1322 (bfd_scan_vma): Use ISXDIGIT/ISDIGIT/ISLOWER instead of
1323 isxdigit/isdigit/islower.
1324 * binary.c: Include "safe-ctype.h" instead of <ctype.h>.
1325 (mangle_name): Use ISALNUM instead of isalnum.
1326 * cpu-v850.c: Include "safe-ctype.h" instead of <ctype.h>.
1327 (scan): Use ISDIGIT instead of isdigit.
1328 * hosts/alphavms.h: Don't include <ctype.h>.
1329 * ieee.c: Include "safe-ctype.h" instead of <ctype.h>.
1330 (ieee_object_p): Use TOUPPER instead of toupper.
1331 * ihex.c: Include "safe-ctype.h" instead of <ctype.h>.
1332 (ihex_bad_byte): Use ISPRINT instead of isprint.
1333 * merge.c: Don't include <ctype.h>.
1334 * oasys.c: Include "safe-ctype.h" instead of <ctype.h>.
1335 (oasys_write_sections): Use ISDIGIT instead of isdigit.
1336 * pdp11.c: Include "safe-ctype.h" instead of <ctype.h>.
1337 (aout_link_write_symbols): Use ISDIGIT instead of isdigit.
1338 * ppcboot.c: Include "safe-ctype.h" instead of <ctype.h>.
1339 (mangle_name): Use ISALNUM instead of isalnum.
1340 * som.c: Include "safe-ctype.h" instead of <ctype.h>.
1341 (som_set_reloc_info): Use ISUPPER/ISLOWER/ISDIGIT instead of
1342 isupper/islower/isdigit.
1343 (som_decode_symclass): Use TOUPPER instead of toupper.
1344 * srec.c: Include "safe-ctype.h" instead of <ctype.h>.
1345 (srec_bad_byte): Use ISPRINT instead of isprint.
1346 (srec_scan): Use ISSPACE instead of isspace.
1347 * stabs.c: Include "safe-ctype.h" instead of <ctype.h>.
1348 (_bfd_link_section_stabs): Use ISDIGIT instead of isdigit.
1349 * syms.c: Include "safe-ctype.h"
1350 (islower, toupper): Remove macro definitions.
1351 (bfd_decode_symclass): Use TOUPPER instead of toupper.
1352 * vms-gsd.c: Don't include <ctype.h>.
1353 * vms-hdr.c: Include "safe-ctype.h" instead of <ctype.h>.
1354 (_bfd_vms_write_hdr): Use ISLOWER/TOUPPER instead of
1356 * vms-tir.c: Don't include <ctype.h>.
1358 2001-09-18 Alan Modra <amodra@bigpond.net.au>
1360 * libbfd.c (bfd_bread): New function replacing bfd_read without
1361 redundant params. Allow reads up to (size_t) -2 in length.
1362 (bfd_bwrite): Similarly for bfd_write.
1363 (real_read): Return a size_t.
1364 (bfd_read): Call bfd_bread.
1365 (bfd_write): Call bfd_bwrite.
1366 (warn_deprecated): New function to annoy everybody.
1367 (bfd_get_file_window): Don't call bfd_set_error unnecessarily.
1368 * bfd-in.h (bfd_bread, bfd_bwrite, warn_deprecated): Declare.
1369 (bfd_read, bfd_write): Define as macro.
1370 * aix386-core.c: Replace calls to bfd_read with bfd_bread, and
1371 likewise for bfd_write. Ensure function args are correct size by
1372 using casts or local vars. In some cases, remove unnecessary
1373 casts. Formatting fixes, in some cases removing a large expression
1374 from function args by using a local var. Replace CONST with const.
1375 Modify variable types to avoid warings. Use casts to avoid
1376 warnings when using negative numbers in unsigned expressions.
1377 * aout-adobe.c: Likewise.
1378 * aout-arm.c: Likewise.
1379 * aout-cris.c: Likewise.
1380 * aout-encap.c: Likewise.
1381 * aout-ns32k.c: Likewise.
1382 * aout-target.h: Likewise.
1383 * aout-tic30.c: Likewise.
1384 * aoutf1.h: Likewise.
1385 * aoutx.h: Likewise.
1386 * archive.c: Likewise.
1387 * archures.c: Likewise.
1388 * bfd-in.h: Likewise.
1390 * binary.c: Likewise.
1392 * cache.c: Likewise.
1393 * cisco-core.c: Likewise.
1394 * coff-a29k.c: Likewise.
1395 * coff-alpha.c: Likewise.
1396 * coff-arm.c: Likewise.
1397 * coff-h8300.c: Likewise.
1398 * coff-h8500.c: Likewise.
1399 * coff-i386.c: Likewise.
1400 * coff-i860.c: Likewise.
1401 * coff-i960.c: Likewise.
1402 * coff-ia64.c: Likewise.
1403 * coff-m68k.c: Likewise.
1404 * coff-m88k.c: Likewise.
1405 * coff-mcore.c: Likewise.
1406 * coff-mips.c: Likewise.
1407 * coff-ppc.c: Likewise.
1408 * coff-rs6000.c: Likewise.
1409 * coff-sh.c: Likewise.
1410 * coff-sparc.c: Likewise.
1411 * coff-stgo32.c: Likewise.
1412 * coff-tic30.c: Likewise.
1413 * coff-tic54x.c: Likewise.
1414 * coff-tic80.c: Likewise.
1415 * coff-w65.c: Likewise.
1416 * coff-z8k.c: Likewise.
1417 * coff64-rs6000.c: Likewise.
1418 * coffcode.h: Likewise.
1419 * coffgen.c: Likewise.
1420 * cofflink.c: Likewise.
1421 * coffswap.h: Likewise.
1422 * corefile.c: Likewise.
1423 * cpu-arc.c: Likewise.
1424 * cpu-h8300.c: Likewise.
1425 * cpu-h8500.c: Likewise.
1426 * cpu-i960.c: Likewise.
1427 * cpu-ia64-opc.c: Likewise.
1428 * cpu-ns32k.c: Likewise.
1429 * cpu-pdp11.c: Likewise.
1430 * cpu-pj.c: Likewise.
1431 * cpu-sh.c: Likewise.
1432 * cpu-w65.c: Likewise.
1433 * cpu-z8k.c: Likewise.
1434 * dwarf1.c: Likewise.
1435 * dwarf2.c: Likewise.
1436 * ecoff.c: Likewise.
1437 * ecofflink.c: Likewise.
1438 * ecoffswap.h: Likewise.
1439 * elf-bfd.h: Likewise.
1440 * elf-hppa.h: Likewise.
1441 * elf-m10200.c: Likewise.
1442 * elf-m10300.c: Likewise.
1444 * elf32-arc.c: Likewise.
1445 * elf32-arm.h: Likewise.
1446 * elf32-avr.c: Likewise.
1447 * elf32-cris.c: Likewise.
1448 * elf32-fr30.c: Likewise.
1449 * elf32-gen.c: Likewise.
1450 * elf32-h8300.c: Likewise.
1451 * elf32-hppa.c: Likewise.
1452 * elf32-i370.c: Likewise.
1453 * elf32-i386.c: Likewise.
1454 * elf32-i860.c: Likewise.
1455 * elf32-m32r.c: Likewise.
1456 * elf32-m68k.c: Likewise.
1457 * elf32-mcore.c: Likewise.
1458 * elf32-mips.c: Likewise.
1459 * elf32-openrisc.c: Likewise.
1460 * elf32-pj.c: Likewise.
1461 * elf32-ppc.c: Likewise.
1462 * elf32-s390.c: Likewise.
1463 * elf32-sh-lin.c: Likewise.
1464 * elf32-sh.c: Likewise.
1465 * elf32-sparc.c: Likewise.
1466 * elf32-v850.c: Likewise.
1467 * elf64-alpha.c: Likewise.
1468 * elf64-hppa.c: Likewise.
1469 * elf64-mips.c: Likewise.
1470 * elf64-ppc.c: Likewise.
1471 * elf64-s390.c: Likewise.
1472 * elf64-sparc.c: Likewise.
1473 * elf64-x86-64.c: Likewise.
1474 * elfarm-nabi.c: Likewise.
1475 * elfcode.h: Likewise.
1476 * elfcore.h: Likewise.
1477 * elflink.c: Likewise.
1478 * elflink.h: Likewise.
1479 * elfxx-ia64.c: Likewise.
1480 * elfxx-target.h: Likewise.
1481 * format.c: Likewise.
1483 * hp300hpux.c: Likewise.
1484 * hppabsd-core.c: Likewise.
1485 * hpux-core.c: Likewise.
1486 * i386aout.c: Likewise.
1487 * i386dynix.c: Likewise.
1488 * i386linux.c: Likewise.
1489 * i386lynx.c: Likewise.
1490 * i386mach3.c: Likewise.
1491 * i386msdos.c: Likewise.
1492 * i386os9k.c: Likewise.
1495 * irix-core.c: Likewise.
1496 * libaout.h: Likewise.
1497 * libbfd-in.h: Likewise.
1498 * libbfd.c: Likewise.
1499 * libcoff-in.h: Likewise.
1500 * libecoff.h: Likewise.
1501 * libieee.h: Likewise.
1502 * libnlm.h: Likewise.
1503 * libpei.h: Likewise.
1504 * libxcoff.h: Likewise.
1505 * linker.c: Likewise.
1506 * lynx-core.c: Likewise.
1507 * m68klinux.c: Likewise.
1508 * merge.c: Likewise.
1509 * mipsbsd.c: Likewise.
1510 * netbsd-core.c: Likewise.
1512 * nlm32-alpha.c: Likewise.
1513 * nlm32-i386.c: Likewise.
1514 * nlm32-ppc.c: Likewise.
1515 * nlm32-sparc.c: Likewise.
1516 * nlmcode.h: Likewise.
1517 * nlmswap.h: Likewise.
1518 * ns32k.h: Likewise.
1519 * oasys.c: Likewise.
1520 * opncls.c: Likewise.
1521 * osf-core.c: Likewise.
1522 * pc532-mach.c: Likewise.
1523 * pdp11.c: Likewise.
1524 * pe-mips.c: Likewise.
1525 * peXXigen.c: Likewise.
1526 * peicode.h: Likewise.
1527 * ppcboot.c: Likewise.
1528 * ptrace-core.c: Likewise.
1529 * reloc.c: Likewise.
1530 * reloc16.c: Likewise.
1531 * riscix.c: Likewise.
1532 * rs6000-core.c: Likewise.
1533 * sco5-core.c: Likewise.
1534 * section.c: Likewise.
1536 * sparclinux.c: Likewise.
1537 * sparclynx.c: Likewise.
1539 * stabs.c: Likewise.
1540 * sunos.c: Likewise.
1542 * targets.c: Likewise.
1543 * tekhex.c: Likewise.
1544 * trad-core.c: Likewise.
1545 * versados.c: Likewise.
1546 * vms-gsd.c: Likewise.
1547 * vms-hdr.c: Likewise.
1548 * vms-misc.c: Likewise.
1549 * vms-tir.c: Likewise.
1552 * xcofflink.c: Likewise.
1553 * bfd-in2.h: Regenerate.
1554 * libbfd.h: Regenerate.
1555 * libcoff.h: Regenerate.
1557 * bfd.c (struct _bfd): Make "where" and "origin" unsigned.
1558 * bfd-in.h (file_ptr): Change from a long int to a bfd_signed_vma.
1559 (ufile_ptr): Define.
1560 (bfd_tell): Return a ufile_ptr.
1561 * libbfd.c (bfd_tell): Likewise.
1562 (bfd_seek): Use bfd_size_type locals. Don't call bfd_set_error
1564 * aix386-core.c: Test != 0 for bfd_seek errors rather than < 0.
1565 * aoutf1.h: Likewise.
1567 * cache.c (bfd_cache_lookup_worker): Guard against abfd->where
1568 larger than unsigned long can represent.
1570 * libbfd.c (bfd_malloc): Take a bfd_size_type arg. Error if
1571 size overflows size_t.
1572 (bfd_realloc): Likewise.
1573 (bfd_zmalloc): Likewise.
1574 * opncls.c (bfd_alloc): Likewise.
1575 (bfd_zalloc): Likewise.
1576 * libbfd-in.h (bfd_malloc, bfd_realloc, bfd_zmalloc): Update.
1577 (bfd_alloc, bfd_zalloc): Update.
1579 * libbfd.c (bfd_get_8): Mask with 0xff in case char is more than
1581 (bfd_get_signed_8): Likewise.
1582 (H_PUT_64, H_PUT_32, H_PUT_16, H_PUT_8,
1583 H_PUT_S64, H_PUT_S32, H_PUT_S16, H_PUT_S8,
1584 H_GET_64, H_GET_32, H_GET_16, H_GET_8,
1585 H_GET_S64, H_GET_S32, H_GET_S16, H_GET_S8): Define and use.
1586 * libaout.h: Likewise define and use here.
1587 * aout-adobe.c: Use H_GET_* and H_PUT_* macros.
1588 * aout-arm.c: Likewise.
1589 * aout-encap.c: Likewise.
1590 * aout-ns32k.c: Likewise.
1591 * aout-tic30.c: Likewise.
1592 * aoutf1.h: Likewise.
1593 * aoutx.h: Likewise.
1595 * coff-alpha.c: Likewise.
1596 * coff-h8300.c: Likewise.
1597 * coff-h8500.c: Likewise.
1598 * coff-i960.c: Likewise.
1599 * coff-ia64.c: Likewise.
1600 * coff-m88k.c: Likewise.
1601 * coff-mips.c: Likewise.
1602 * coff-ppc.c: Likewise.
1603 * coff-rs6000.c: Likewise.
1604 * coff-sh.c: Likewise.
1605 * coff-sparc.c: Likewise.
1606 * coff-stgo32.c: Likewise.
1607 * coff-tic30.c: Likewise.
1608 * coff-tic80.c: Likewise.
1609 * coff-w65.c: Likewise.
1610 * coff-z8k.c: Likewise.
1611 * coff64-rs6000.c: Likewise.
1612 * coffgen.c: Likewise.
1613 * cofflink.c: Likewise.
1614 * coffswap.h: Likewise.
1615 * ecoff.c: Likewise.
1616 * ecoffswap.h: Likewise.
1618 * elf32-mips.c: Likewise.
1619 * elf64-mips.c: Likewise.
1620 * hp300hpux.c: Likewise.
1621 * i386dynix.c: Likewise.
1622 * i386lynx.c: Likewise.
1623 * i386msdos.c: Likewise.
1624 * i386os9k.c: Likewise.
1625 * libpei.h: Likewise.
1626 * nlm32-alpha.c: Likewise.
1627 * nlm32-i386.c: Likewise.
1628 * nlm32-ppc.c: Likewise.
1629 * nlmcode.h: Likewise.
1630 * nlmswap.h: Likewise.
1631 * oasys.c: Likewise.
1632 * pdp11.c: Likewise.
1633 * pe-mips.c: Likewise.
1634 * peXXigen.c: Likewise.
1635 * peicode.h: Likewise.
1636 * riscix.c: Likewise.
1637 * sunos.c: Likewise.
1638 * xcofflink.c: Likewise.
1639 * elfcode.h: (put_word, get_word, put_signed_word, get_signed_word):
1640 Rename to H_PUT_WORD, H_GET_WORD, H_PUT_SIGNED_WORD, H_GET_SIGNED_WORD.
1641 * coff-rs6000.c (PUTWORD, PUTHALF, PUTBYTE): Don't define. Use
1642 equivalent H_PUT_* macro instead.
1643 (GETWORD, GETHALF, GETBYTE): Similarly.
1644 * coff64-rs6000.c (PUTWORD, PUTHALF, PUTBYTE): Likewise.
1645 (GETWORD, GETHALF, GETBYTE): Likewise.
1646 * coffswap.h (PUTWORD, PUTHALF, PUTBYTE): Likewise.
1648 * bfd-in.h (struct orl): Change "pos" to a union.
1649 * archive.c (_bfd_compute_and_write_armap): Use it instead of casts.
1650 (bsd_write_armap): Here too.
1651 (coff_write_armap): And here.
1652 * coff-rs6000.c (xcoff_write_armap_old): And here.
1653 (xcoff_write_one_armap_big): And here.
1654 (xcoff_write_armap_big): And here.
1655 * ecoff.c (_bfd_ecoff_write_armap): And here.
1656 * elf64-mips.c (mips_elf64_write_armap): And here.
1658 * aoutf1.h (sunos_set_arch_mach): Make "mach" param an enum.
1659 * elf-m10300.c (elf_mn10300_mach): Return an unsigned long.
1660 * elf32-h8300.c (elf32_h8_mach): Likewise.
1661 * elf32-mips.c (elf_mips_mach): Likewise.
1662 * sparclynx.c (NAME(lynx,set_arch_mach)): Likewise.
1664 * aix386-core.c (aix386_core_file_p): Remove redundant bfd_release
1666 (aix386_core_vec): Typo fix.
1668 * aout-arm.c: Include libaout.h and aout/aout64.h after N_TXTADDR
1669 etc. to avoid redefined macro warning.
1670 (MY(put_reloc)): Use bfd_vma for "value" rather than long.
1671 (MY(fix_pcrel_26)): Likewise.
1672 * aout-ns32k.c (MY(put_reloc)): Likewise.
1673 * aout-cris.c (MY(swap_ext_reloc_out)): Likewise for r_addend.
1674 * aoutx.h (NAME(aout,swap_ext_reloc_out)): Likewise.
1675 * coff-arm.c (coff_arm_relocate_section): Likewise for my_offset.
1677 * aout-encap.c: Include "file", not <file> for binutils headers.
1678 (encap_object_p): Half baked attempt to fix compile errors in
1679 code dealing with "magic".
1681 * aout-ns32k.c: Include "file", not <file> for binutils headers.
1682 (_bfd_ns32k_relocate_contents): get_data and put_data manipulate
1683 bfd_vma's rather than longs.
1684 * cpu-ns32k.c (ns32k_sign_extend): Delete.
1685 (_bfd_ns32k_get_displacement): Return a bfd_vma, don't pass in offset.
1686 (_bfd_ns32k_get_immediate): Likewise. Add code for 8 byte values,
1688 (_bfd_ns32k_put_displacement): Accept a bfd_vma, don't pass in offset.
1689 Use unsigned comparisons.
1690 (bfd_ns32k_put_immediate): Likewise, and add code for 8 byte values.
1691 (do_ns32k_reloc): get_data and put_data operate on bfd_vma's.
1692 (_bfd_do_ns32k_reloc_contents): Likewise.
1693 * ns32k.h (_bfd_ns32k_get_displacement): Update prototype.
1694 (_bfd_ns32k_get_immediate): Likewise.
1695 (_bfd_ns32k_put_displacement): Likewise.
1696 (_bfd_ns32k_put_immediate): Likewise.
1697 (bfd_reloc_status_type): Likewise.
1699 * aoutx.h (NAME(aout,find_nearest_line)): Rename 'p' to 'colon'
1701 * pdp11.c (NAME(aout,find_nearest_line)): Likewise.
1702 * coff-h8300.c (h8300_reloc16_extra_cases): Remove shadowing "value".
1703 * coff-ppc.c (enum ref_category): Rename "data" to "tocdata" to
1705 (record_toc): Use a bfd_signed_vma for our_toc_offset.
1706 * coffcode.h (coff_write_relocs): Rename "i" to avoid shadowing.
1707 * elf.c (bfd_elf_get_bfd_needed_list): Rename "link" var to avoid
1709 (_bfd_elfcore_strndup): Likewise for "dup".
1710 * elf32-cris.c (cris_elf_relocate_section): "symname" instead of
1711 "name" to avoid shadowing.
1712 * elf32-hppa.c (elf32_hppa_relocate_section): Remove duplicate
1713 definition of "off".
1714 * elf32-i386.c (elf_i386_relocate_section): Likewise.
1715 * elf32-mips.c (_bfd_mips_elf_modify_segment_map): Remove duplicate
1717 (_bfd_mips_elf_final_link): Rename "i" to "j". Remove duplicate
1719 * elf64-x86-64.c (elf64_x86_64_relocate_section): Rename inner "indx"
1721 * elflink.h (elf_link_add_object_symbols): Rename "link" to "shlink"
1723 (elf_link_input_bfd): Likewise.
1724 (elf_bfd_final_link): Remove duplicate innermost "off" var.
1725 * oasys.c (oasys_write_data): Rename innermost "p" to "sym".
1726 * reloc16.c (bfd_coff_reloc16_relax_section): Rename "i" param to
1728 * som.c (som_prep_for_fixups): Rename inner "i" to "j".
1729 * sunos.c (sunos_add_dynamic_symbols): Localise "s" var.
1730 (sunos_write_dynamic_symbol): Remove unused vars.
1731 * syms.c (_bfd_stab_section_find_nearest_line): Remove duplicate
1732 innermost "directory_name" and "file_name" vars.
1733 * tekhex.c (first_phase): Rename local var "type" to "stype".
1734 (tekhex_write_object_contents): Rename innermost "s" to "sym".
1735 * vms-gsd.c (vms_secflag_by_name): Change "size" param to "hassize",
1736 doing comparison at caller.
1737 (vms_esecflag_by_name): Likewise.
1738 * vms-tir.c (etir_sto): Rename innermost "psect" to "psect1".
1739 * xcofflink.c (xcoff_link_input_bfd): Delete duplicate innermost "o".
1740 (xcoff_write_global_symbol): Rename "p" param to "inf".
1742 * cisco-core.c: Add missing prototypes.
1743 (cisco_core_file_failing_command): Add ATTRIBUTE_UNUSED.
1744 (cisco_core_file_failing_signal): Likewise.
1745 (cisco_core_file_matches_executable_p): Likewise.
1746 * hpux-core.c (hpux_core_core_file_failing_signal): Likewise.
1747 * netbsd-core.c (netbsd_core_file_matches_executable_p): Likewise.
1748 * osf-core.c (osf_core_core_file_matches_executable_p): Likewise.
1749 * sco5-core.c (sco5_core_file_matches_executable_p): Likewise.
1751 * coff-arm.c (coff_arm_link_hash_table): Use bfd_size_type for
1752 thumb_glue_size and arm_glue_size.
1753 * elf32-arm.h (elf32_arm_link_hash_table): Likewise here.
1755 * coff64-rs6000.c: Group prototypes together.
1757 * coffcode.h (coff_set_arch_mach): Add ATTRIBUTE_UNUSED.
1758 (buy_and_read): Remove "seek" param. Change "size" to bfd_size_type.
1760 * cpu-arc.c: Add missing prototypes.
1761 * cpu-h8500.c: Likewise.
1762 * cpu-i960.c: Likewise.
1763 * cpu-pj.c: Likewise.
1764 * cpu-sh.c: Likewise.
1765 * cpu-w65.c: Likewise.
1766 * cpu-z8k.c: Likewise.
1767 * elf32-fr30.c: Likewise.
1768 * elf32-h8300.c: Likewise.
1769 * elf32-i370.c: Likewise.
1770 * hpux-core.c: Likewise.
1771 * versados.c: Likewise.
1773 * cpu-h8300.c (bfd_default_scan_num_mach): Don't declare.
1774 * cpu-h8500.c: Likewise.
1775 * cpu-i960.c: Likewise.
1776 * cpu-z8k.c: Likewise.
1778 * cpu-ia64-opc.c: Correct comment.
1780 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Remove unused var.
1782 * elf-bfd.h (elf_size_info): Change count param of write_out_phdrs
1784 (bfd_elf32_write_out_phdrs): Likewise.
1785 (bfd_elf64_write_out_phdrs): Likewise.
1786 (elf_linker_section_pointers): Change addend to bfd_vma.
1787 (_bfd_elf_find_pointer_linker_section): Likewise.
1788 (_bfd_elfcore_make_pseudosection): Change size param to size_t and
1789 filepos to unsigned file_ptr.
1790 (_bfd_elfcore_strndup): Change max param to size_t.
1791 * elf.c (_bfd_elfcore_make_pseudosection): As above.
1792 (_bfd_elfcore_strndup): Likewise.
1793 (_bfd_elf_find_pointer_linker_section): Likewise.
1795 * elf-hppa.h (elf_hppa_relocate_insn): Return an int, and change
1796 insn and sym_value to ints.
1798 * elf.c (elf_read): Make "offset" param a file_ptr, "size" a
1800 (elfcore_read_notes): Likewise.
1802 * elf32-arm.h (elf32_arm_final_link_relocate): Change sym_flags
1803 param from unsigned char to int.
1804 (elf32_arm_relocate_section): If USE_REL, cast "rel" appropriately
1805 for info_to_howto call.
1806 (add_dynamic_entry): Define macro.
1807 (elf32_arm_size_dynamic_sections): Use add_dynamic_entry.
1809 * elf32-cris.c (add_dynamic_entry): Define macro.
1810 (elf_cris_size_dynamic_sections): Use add_dynamic_entry.
1812 * elf32-h8300.c (elf32_h8_final_write_processing): Make static.
1813 (elf32_h8_object_p): Likewise.
1814 (elf32_h8_merge_private_bfd_data): Likewise.
1815 (elf32_h8_relax_section): Cast gap to int so signed comparisons work.
1817 * elf32-hppa.c (add_dynamic_entry): Define macro.
1818 (elf32_hppa_size_dynamic_sections): Use it.
1819 * elf32-i370.c (add_dynamic_entry): Define macro.
1820 (i370_elf_size_dynamic_sections): Use it.
1821 (i370_noop): Make static.
1822 * elf32-i386.c (add_dynamic_entry): Define macro.
1823 (elf_i386_size_dynamic_sections): Use it.
1824 * elf32-m68k.c (add_dynamic_entry): Define macro.
1825 (elf_m68k_size_dynamic_sections): Use it.
1826 * elf32-ppc.c (add_dynamic_entry): Define macro.
1827 (ppc_elf_size_dynamic_sections): Use it.
1828 * elf32-s390.c (add_dynamic_entry): Define macro.
1829 (elf_s390_size_dynamic_sections): Use it.
1830 * elf64-alpha.c (add_dynamic_entry): Define macro.
1831 (elf64_alpha_size_dynamic_sections): Use it.
1832 * elf64-hppa.c (add_dynamic_entry): Define macro.
1833 (elf64_hppa_size_dynamic_sections): Use it.
1834 * elf64-ppc.c (add_dynamic_entry): Define macro.
1835 (ppc64_elf_size_dynamic_sections): Use it.
1836 * elf64-s390.c (add_dynamic_entry): Define macro.
1837 (elf_s390_size_dynamic_sections): Use it.
1838 * elf64-sparc.c (add_dynamic_entry): Define macro.
1839 (sparc64_elf_size_dynamic_sections): Use it.
1840 * elf64-x86-64.c (add_dynamic_entry): Define macro.
1841 (elf64_x86_64_size_dynamic_sections): Use it.
1842 * elfxx-ia64.c (add_dynamic_entry): Define macro.
1843 (elfNN_ia64_size_dynamic_sections): Use it.
1845 * elf32-v850.c (SEXT24): Modify to avoid signed/unsigned warning.
1846 (v850_elf_perform_relocation): Make "r_type" param unsigned.
1848 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Just return
1849 false if the first malloc fails rather than going via error_return.
1851 * elf64-sparc.c (sparc64_elf_plt_entry_offset): Use a bfd_vma for
1853 (sparc64_elf_plt_ptr_offset): Likewise, and for "max" param too.
1855 * elflink.h (elf_link_input_bfd): s/ingored/ignored/ in error message.
1857 * elfxx-ia64.c (global_sym_index): Return a long.
1859 * ieee.c (get_symbol): Use int rather than char param.
1860 (ieee_slurp_sections): Move "section" var to inner blocks.
1861 (copy_expression): Don't init "value" to zero or worry about
1862 clearing to zero after using.
1863 (ieee_write_debug_part): Rename "output_buffer" to "obuff" to avoid
1866 * ihex.c (ihex_write_record): Make "count" var a size_t, "addr" an
1869 * libbfd-in.h (BFD_ALIGN): Add cast to avoid signed/unsigned warning.
1870 (bfd_write_bigendian_4byte_int): Pass an unsigned int value param.
1872 * mipsbsd.c (mips_fix_jmp_addr): Add "error_message" param.
1874 * pc532-mach.c (MYNSX): Delete.
1875 (ns32kaout_bfd_reloc_type_lookup): Define prototype without MYNSX.
1876 (write_object_contents): Correct prototype.
1878 * peicode.h (pe_ILF_build_a_bfd): Use an unsigned int param rather
1879 than unsigned short.
1881 * section.c (bfd_set_section_contents): Remove redundant
1882 "offset < 0" test. Check that "count" doesn't overflow size_t.
1883 (bfd_get_section_contents): Likewise.
1885 * som.c (som_fixup_formats): Add missing braces.
1886 (som_reloc_addend): Pass a bfd_vma for "addend".
1888 * srec.c (srec_write_record): Pass "type" as an unsigned int.
1889 (srec_write_symbols): Remove an unnecessary var.
1891 * targets.c (_bfd_target_vector): Sort entries. Sort externs
1893 * configure.in: Sort to match. Bump version number.
1894 * configure: Regenerate.
1896 * tekhex.c (move_section_contents): Assert offset == 0.
1898 * versados.c (new_symbol_string): Constify arg.
1899 (process_esd): Use bfd_und_section_ptr rather than &bfd_und_section.
1900 (versados_get_symbol_info): Make static.
1901 (versados_print_symbol): Likewise.
1902 (versados_get_reloc_upper_bound): Likewise.
1903 (versados_canonicalize_reloc): Likewise.
1905 2001-09-18 Nick Clifton <nickc@cambridge.redhat.com>
1907 * elflink.h (elf_link_input_bfd): Fix typo in error message.
1909 2001-09-17 H.J. Lu <hjl@gnu.org>
1911 * dwarf1.c (parse_die): Take a new arg for the end of the
1912 section. Return false if die is beyond the section.
1913 (parse_functions_in_unit): Pass the end of the section to
1915 (_bfd_dwarf1_find_nearest_line): Likewise.
1917 2001-09-14 Michael Rauch <mrauch@netbsd.org>
1919 * elf32-sparc.c (elf32_sparc_relocate_section): Treat R_SPARC_UA32
1920 just like R_SPARC_32.
1922 2001-09-14 Kevin Lo <kevlo@openbsd.org>
1924 * configure.bfd: Add arm-openbsd target.
1926 2001-09-14 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1928 * config.bfd: Change machine triplets from mips*el*-* to mips*el-*.
1929 Add support for mips64.
1931 2001-09-13 Alexandre Oliva <aoliva@redhat.com>
1933 * elf32-openrisc.c (ELF_MACHINE_ALT1): Define as EM_OPENRISC_OLD.
1935 2001-09-12 Alexandre Oliva <aoliva@redhat.com>
1937 * elf.c (prep_headers): Get the machine code from the elf
1939 * elf-m10200.c (ELF_MACHINE_CODE): Redefine to EM_MN10200.
1940 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_MN10200.
1941 * elf-m10300.c (ELF_MACHINE_CODE): Redefine to EM_MN10300.
1942 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_MN10300.
1943 * elf-arc.c (arc_elf_final_write_processing): Don't override
1944 e_machine, it's now properly set in prep_headers.
1945 * elf32-avr.c (elf32_avr_object_p): Accept both EM_AVR and
1947 (ELF_MACHINE_ALT1): Define to EM_AVR_OLD.
1948 * elf-d10v.c (ELF_MACHINE_CODE): Redefine to EM_D10V.
1949 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_D10V.
1950 * elf-d30v.c (ELF_MACHINE_CODE): Redefine to EM_D30V.
1951 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_D30V.
1952 * elf-fr30.c (ELF_MACHINE_CODE): Redefine to EM_FR30.
1953 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_FR30.
1954 * elf-m32r.c (ELF_MACHINE_CODE): Redefine to EM_M32R.
1955 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_M32R.
1956 * elf32-pj.c (ELF_MACHINE_ALT1): DEfine to EM_PJ_OLD.
1957 * elf-v850.c (ELF_MACHINE_CODE): Redefine to EM_V850.
1958 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_V850.
1960 2001-09-11 Richard Henderson <rth@redhat.com>
1962 * elf64-alpha.c (elf64_alpha_section_flags): New.
1963 (elf64_alpha_fake_sections): Map SEC_SMALL_DATA to SHF_ALPHA_GPREL.
1965 2001-09-11 Richard Henderson <rth@redhat.com>
1967 * elf64-alpha.c (elf64_alpha_relocate_section): Do not
1968 apply HINT relocations against dynamic symbols.
1970 2001-09-11 H.J. Lu <hjl@gnu.org>
1972 * linker.c (link_action): Change COMMON_ROW\defw from CREF to COM.
1974 2001-09-09 Richard Henderson <rth@redhat.com>
1976 * elf64-alpha.c: Delete all unused ERIC_neverdef and rth_notdef code.
1978 * elf64-alpha.c (elf64_alpha_relax_with_lituse): Nop out gpdisp
1979 following a call to a near function.
1981 2001-09-08 Richard Henderson <rth@redhat.com>
1983 * elf64-alpha.c (elf64_alpha_relocate_section): Soft fail
1984 relocation errors. Fail gp-relative relocations against
1987 2001-09-08 Alan Modra <amodra@bigpond.net.au>
1989 * elf32-i386.c (elf_i386_relocate_section): Check !DEF_REGULAR
1990 as well as DEF_DYNAMIC in test for avoided copy relocs.
1991 (allocate_plt_and_got_and_discard_relocs): Likewise.
1992 * elf32-hppa.c (elf_i386_relocate_section): Likewise.
1993 (allocate_plt_and_got_and_discard_relocs): Likewise.
1995 2001-09-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1997 * elf32-mips.c (mips_elf_calculate_relocation): Fix overflow handling
2000 2001-09-06 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2002 * elf64-mips.c (mips_elf64_howto_table_rel): Fix relocation HOWTO
2004 (mips_elf64_howto_table_rel): Likewise.
2006 2001-09-05 Tom Rix <trix@redhat.com>
2008 * xcofflink.c (bfd_xcoff_import_symbol): Handle import file XMC_XO
2009 and syscall symbols.
2010 (write_global_symbol) : Same.
2011 (bfd_xcoff_export_symbol): Remove unused syscall param.
2012 * libxcoff.h: Change prototype of bfd_xcoff_export symbol and
2013 bfd_xcoff_import_symbol.
2015 * bfd-in2.h : Regenerate.
2017 2001-09-04 Richard Henderson <rth@redhat.com>
2019 * elf64-alpha.c (SKIP_HOWTO): New.
2020 (elf64_alpha_howto_table): Use it to remove dead ECOFF relocs.
2021 Fix sizes of 16-bit mem format relocs.
2022 (elf64_alpha_reloc_map): Update to match.
2023 (elf64_alpha_relax_with_lituse): Use GPREL16 as appropriate.
2024 (elf64_alpha_relax_without_lituse): Likewise.
2025 (elf64_alpha_check_relocs): Handle GPREL16.
2026 (elf64_alpha_relocate_section): Likewise.
2027 * reloc.c (BFD_RELOC_ALPHA_USER_*): Remove.
2028 (BFD_RELOC_ALPHA_GPREL_HI16, BFD_RELOC_ALPHA_GPREL_LO16): New.
2029 * bfd-in2.h, libbfd.h: Rebuild.
2031 2001-09-04 Jeff Law <law@redhat.com>
2033 * elf32-h8300.c (elf32_h8_relax_section): New function.
2034 (elf32_h8_relax_delete_bytes): Likewise.
2035 (elf32_h8_symbol_address_p): Likewise.
2036 (elf32_h8_get_relocated_section_contents): Likewise.
2037 (bfd_elf32_bfd_relax_section): Define.
2038 (bfd_elf32_bfd_get_relocated_section_contents): Likewise.
2040 * elf32-h8300.c (special): New function.
2041 (h8_elf_howto_table): Use it for SPECIAL_FUNCTION field in
2043 (elf32_h8_final_link_relocate): Treat R_H8_DIR24A8 like 32bit
2044 relocations. Fix problems with the true 24bit reloc R_H8_DIR24R8.
2045 Fix minor problems with 8bit and 16bit PC relative relocations.
2047 2001-09-01 Andreas Jaeger <aj@suse.de>
2049 * vms-tir.c: Add missing prototypes.
2050 * vms-hdr.c: Likewise.
2051 * vms-gsd.c: Likewise.
2052 * vms-misc.c: Likewise.
2054 2001-08-31 H.J. Lu <hjl@gnu.org>
2056 * elf32-mips.c (_bfd_mips_elf_check_relocs): Report filename
2057 with bad relocation.
2059 2001-08-31 Eric Christopher <echristo@redhat.com>
2060 Jason Eckhardt <jle@redhat.com>
2062 * bfd/archures.c: Add mipsisa32 and mipsisa64. Remove mips32,
2063 mips32_4k and mips64.
2064 * bfd/aoutx.h: Remove bfd_mach_mips32, bfd_mach_mips32_4k,
2065 bfd_mach_mips64. Add bfd_mach_mipsisa32, bfd_mach_mipsisa64.
2066 * bfd/cpu-mips.c: Ditto.
2067 * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing): Ditto.
2068 * bfd/bfd-in2.h: Regenerate.
2070 2001-08-31 Jakub Jelinek <jakub@redhat.com>
2072 * elf64-alpha.c (elf64_alpha_relocate_section): Duplicate memory
2073 value into R_ALPHA_RELATIVE's addend.
2074 (elf64_alpha_finish_dynamic_symbol): Likewise.
2076 2001-08-31 Nick Clifton <nickc@cambridge.redhat.com>
2078 * elf32-arm.h (elf32_arm_relocate_section): Do not rightshift
2079 recomputed addend during relocatable link if not USE_REL.
2081 * elflink.h (elf_gc_propagate_vtable_entries_used): Fix off-by-one
2084 2001-08-30 H.J. Lu <hjl@gnu.org>
2086 * elf32-mips.c (mips_elf_calculate_relocation): Revert the last
2088 (_bfd_mips_elf_adjust_dynamic_symbol): Allocate dynamic
2089 relocations for weak definitions.
2091 2001-08-30 H.J. Lu <hjl@gnu.org>
2093 * Makefile.am (BFD32_BACKENDS): Add elf32-h8300.lo.
2094 (BFD32_BACKENDS_CFILES): Add elf32-h8300.c.
2095 * Makefile.in: Rebuild.
2097 2001-08-30 H.J. Lu <hjl@gnu.org>
2099 * elf32-mips.c (mips_elf_calculate_relocation): Don't create
2100 dynamic relocation for undefined weak symbols when creating
2101 executables. Check h->root.root.type, instead of h->root.type.
2103 2001-08-29 Joel Sherrill <joel@OARcorp.com>
2105 * config.bfd (i[3456]86-*-rtems*, m68*-*-rtems*): Change
2106 default from coff to elf.
2108 2001-08-29 Jeff Law <law@redhat.com>
2110 * elf32-h8300.c (h8_elf_howto_table): Add new PC relative
2112 (h8_reloc_map): Similarly.
2113 (elf32_h8_final_link_relocate): Remove incorrect overflow tests.
2114 Add support for PC relative relocations.
2116 * elf32-h8300.c: Put all prototypes together.
2117 (elf32_h8_info_to_howto): Parameter elf_reloc is used.
2118 (elf32_h8_final_link_relocate): New function for linker.
2119 (elf32_h8_relocate_section): Similarly.
2120 (elf_backend_relocate_section): Define.
2122 * cpu-h8300.c (h8300_scan, compatible): Prototype.
2123 (h8300_scan): Handle architecture:machine encodings typically
2124 found in linker scripts.
2125 * elf.c (prep_headers): Do not try to do H8 machine recognition
2127 * elf32-h8300.c: Add some missing prototypes.
2128 (elf32_h8_mach, elf32_h8_final_write_processing): New functions.
2129 (elf32_h8_object_p): Similarly.
2131 2001-08-29 Tom Rix <trix@redhat.com>
2133 * xcofflink.c (xcoff_link_add_symbols): Fix XTY_LD symbol that
2134 does not follow a XTY_SD.
2136 2001-08-29 Alan Modra <amodra@bigpond.net.au>
2138 * targmatch.sed: Delete case statements.
2139 * config.bfd <powerpc-*-aix* entry>: Select 64 bit xcoff for
2142 Wed Aug 29 02:27:36 2001 J"orn Rennecke <amylaar@redhat.com>
2144 * Makefile.am (elf32-h8300.lo): New target.
2145 * config.bfd (h8300*-*-elf): New case.
2146 * configure.in (bfd_elf32_h8300_vec): New case.
2147 * elf.c (prep_headers): Add case for bfd_arch_h8300.
2148 * reloc.c (BFD_RELOC_H8_DIR16A8): New relocation.
2149 (BFD_RELOC_H8_DIR16R8, BFD_RELOC_H8_DIR24A8): Likewise.
2150 (BFD_RELOC_H8_DIR24R8, BFD_RELOC_H8_DIR32A16): Likewise.
2151 * targets.c (bfd_target bfd_elf32_h8300_vec): New extern declaration.
2152 * elf32-h8300.c: New file.
2153 * Makefile.in, bfd-in2.h, libbfd.h, configure: Regenerated.
2155 2001-08-28 Nick Clifton <nickc@cambridge.redhat.com>
2157 * sparclynx.c: Add missing prototypes.
2158 * coff-mcore.c: Add missing prototypes.
2159 * elf32-pj.c: Add missing prototypes.
2160 * nlm32-sparc.c: Add missing prototypes.
2161 * oasys.c: Add missing prototypes.
2162 * pdp11.c: Add missing prototypes.
2163 * pe-mips.c: Add missing prototypes.
2164 * riscix.c: Add missing prototypes.
2166 2001-08-27 Daniel Jacobowitz <drow@mvista.com>
2168 * elf32-i386.c: Add missing prototypes.
2169 * elf32-ppc.c: Likewise.
2170 * elf32-sh-lin.c: Likewise.
2171 * elfarm-nabi.c: Likewise.
2173 2001-08-27 Daniel Jacobowitz <drow@mvista.com>
2175 * elf32-i386.c (elf_i386_grok_prstatus): New function.
2176 (elf_i386_grok_psinfo): New function.
2177 (elf_backend_grok_prstatus): Define.
2178 (elf_backend_grok_psinfo): Likewise.
2179 * elf32-ppc.c (ppc_elf_grok_prstatus): New function.
2180 (ppc_elf_grok_psinfo): New function.
2181 (elf_backend_grok_prstatus): Define.
2182 (elf_backend_grok_psinfo): Likewise.
2183 * elf32-sh-lin.c (elf32_shlin_grok_prstatus): New function.
2184 (elf32_shlin_grok_psinfo): New function.
2185 (elf_backend_grok_prstatus): Define.
2186 (elf_backend_grok_psinfo): Likewise.
2187 * elfarm-nabi.c (elf32_arm_nabi_grok_prstatus): New function.
2188 (elf32_arm_nabi_grok_psinfo): New function.
2189 (elf_backend_grok_prstatus): Define.
2190 (elf_backend_grok_psinfo): Likewise.
2192 2001-08-27 H.J. Lu <hjl@gnu.org>
2194 * elf32-mips.c (mips_elf_create_dynamic_relocation): Add more
2196 (mips_elf_calculate_relocation): Create dynamic relocation for
2197 symbols with weak definition or the ELF_LINK_HASH_DEF_REGULAR
2200 2001-08-27 H.J. Lu <hjl@gnu.org>
2202 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Add prototype.
2203 (_bfd_mips_elf_copy_indirect_symbol): Likewise.
2204 (_bfd_elf32_mips_grok_prstatus): Likewise.
2205 (_bfd_elf32_mips_grok_psinfo): Likewise.
2206 (_bfd_mips_elf_hide_symbol): Make it static and cast to
2207 `struct mips_elf_link_hash_entry *'.
2208 (_bfd_mips_elf_copy_indirect_symbol): Make it static.
2210 2001-08-27 Nick Clifton <nickc@cambridge.redhat.com>
2212 * mipsbsd.c: Add missing prototypes.
2213 * hp300hpux.c: Add missing prototypes.
2214 * i386aout.c: Add missing prototypes.
2215 * i386lynx.c: Add missing prototypes.
2216 * i386mach3.c: Add missing prototypes.
2217 * i386msdos.c: Add missing prototypes.
2218 * i386os9k.c: Add missing prototypes.
2220 2001-08-27 Linus Nordberg <linus@swox.se>
2221 Torbjorn Granlund <tege@swox.com>
2222 Staffan Ulfberg <staffanu@swox.se>
2223 Alan Modra <amodra@bigpond.net.au>
2225 * config.bfd: Add powerpc64 target. Add powerpc64 vectors to
2226 targ64_selvecs for 32 bit powerpc targets.
2227 * Makefile.am (BFD64_BACKENDS): Add elf64-ppc.lo.
2228 (BFD64_BACKENDS_CFILES): Add elf64-ppc.c.
2230 * Makefile.in: Regenerate.
2231 * configure.in: Add elf64_powerpc vecs.
2232 * configure: Regenerate.
2233 * cpu-powerpc.c: Default to bfd_mach_ppc_620 entry for 64 bit.
2234 * elf.c (prep_headers): EM_PPC64 for 64 bit ppc elf target.
2235 * targets.c: Add bfd_elf64_powerpc_vec and bfd_elf64_powerpcle_vec.
2236 * elf64-ppc.c: New file.
2237 * reloc.c: Add powerpc64 relocs.
2238 * libbfd.h: Regenerate.
2239 * bfd-in2.h: Regenerate.
2241 2001-08-27 Andreas Schwab <schwab@suse.de>
2243 * elf32-m68k.c (elf32_m68k_check_relocs): Set DF_TEXTREL if the
2244 reloc is against read-only section.
2245 (elf32_m68k_size_dynamic_sections): Use DF_TEXTREL flag instead of
2246 looking up section names for DT_TEXTREL.
2247 (elf32_m68k_reloc_type_class): New function.
2248 (elf_backend_reloc_type_class): Define.
2250 2001-08-27 Andreas Jaeger <aj@suse.de>
2252 * elf64-s390.c (elf_s390_check_relocs): Set DF_TEXTREL if the
2253 reloc is against read-only section.
2254 (elf_s390_size_dynamic_sections): Use DF_TEXTREL flag instead of
2255 looking up section names for DT_TEXTREL.
2256 (elf_s390_reloc_type_class): New.
2257 (elf_backend_reloc_type_class): Define.
2259 * elf32-s390.c (elf_s390_check_relocs): Set DF_TEXTREL if the
2260 reloc is against read-only section.
2261 (elf_s390_size_dynamic_sections): Use DF_TEXTREL flag instead of
2262 looking up section names for DT_TEXTREL.
2263 (elf_s390_reloc_type_class): New.
2264 (elf_backend_reloc_type_class): Define.
2266 * elf32-ppc.c (ppc_elf_check_relocs): Set DF_TEXTREL if the reloc
2267 is against read-only section.
2268 (ppc_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
2269 looking up section names for DT_TEXTREL.
2270 (ppc_elf_reloc_type_class): New.
2271 (elf_backend_reloc_type_class): Define.
2273 2001-08-26 Andreas Jaeger <aj@suse.de>
2275 * elf32-cris.c (cris_elf_check_relocs): Set DF_TEXTREL if the
2276 reloc is against read-only section.
2277 (elf_cris_size_dynamic_sections): Use DF_TEXTREL flag instead of
2278 looking up section names for DT_TEXTREL.
2279 (elf_cris_reloc_type_class): New.
2280 (elf_backend_reloc_type_class): Define.
2282 * elf32-sh.c (sh_elf_check_relocs): Set DF_TEXTREL if the reloc is
2283 against read-only section.
2284 (elf_backend_reloc_type_class): Define.
2285 (sh_elf_reloc_type_class): New.
2286 (sh_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
2287 looking up section names for DT_TEXTREL.
2289 * elf32-arm.h (elf32_arm_check_relocs): Set DF_TEXTREL if the
2290 reloc is against read-only section.
2291 (elf32_arm_size_dynamic_sections): Use DF_TEXTREL flag instead of
2292 looking up section names for DT_TEXTREL.
2293 (elf32_arm_reloc_type_class): New.
2294 (elf_backend_reloc_type_class): Define.
2296 2001-08-25 Andreas Jaeger <aj@suse.de>
2298 * oasys.c: Add missing prototypes.
2300 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Add unused
2301 attribute for parameter.
2302 * elf.c (_bfd_elf_reloc_type_class): Likewise.
2304 * versados.c (get_4): Make static.
2305 (get_10): Make static.
2306 Add missing prototypes.
2307 (process_esd): Fix call to versados_new_symbol.
2309 2001-08-25 Nick Clifton <nickc@cambridge.redhat.com>
2311 * coff-a29k.c: Add missing prototypes.
2312 * coff-apollo.c: Add missing prototypes.
2313 * coff-arm.c: Add missing prototypes.
2314 * coff-i860.c: Add missing prototypes.
2315 * coff-rs6000.c: Add missing prototypes.
2316 * coff-tic80.c: Add missing prototypes.
2317 * elf-m10200.c: Add missing prototypes.
2318 * elf-m10300.c: Add missing prototypes.
2319 * elf32-arm.h: Add missing prototypes.
2320 * elf32-d10v.c: Add missing prototypes.
2321 * elf32-m32r.c: Add missing prototypes.
2322 * elf32-mcore.c: Add missing prototypes.
2323 * elf32-openrisc.c: Add missing prototypes.
2324 * elf32-sh.c: Add missing prototypes.
2325 * elf32-sparc.c: Add missing prototypes.
2326 * elf32-v850.c: Add missing prototypes.
2327 * elfarm-nabi.c: Add missing prototypes.
2328 * elfarm-oabi.c: Add missing prototypes.
2330 2001-08-25 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2332 * elf32-mips.c (elf_mips_abi_name): Return the right ABI string for
2333 E_MIPS_ABI_O64 and E_MIPS_ABI_EABI64
2335 2001-08-24 H.J. Lu <hjl@gnu.org>
2337 * elf.c (_bfd_elf_merge_sections): Fail if not using an ELF
2340 2001-08-24 Nick Clifton <nickc@cambridge.redhat.com>
2342 * elf-bfd.h (elf_hash_table): Revert definition.
2343 (is_elf_hash_table): New macro.
2344 * elflink.h (elf_link_add_object_symbols): Test
2345 is_elf_hash_table before accessing ELF only fields in hash
2347 (elf_link_create_dynamic_sections): Fail if not using an ELF
2349 (elf_add_dynamic_entry): Fail if not using an ELF hash
2351 (elf_link_record_local_dynamic_symbol): Fail if not using an
2353 (size_dynamic_sections): Fail if not using an ELF hash
2355 (elf_adjust_dynamic_symbol): Fail if not using an ELF
2357 (elf_bfd_final_link): Fail if not using an ELF hash
2360 2001-08-24 H.J. Lu <hjl@gnu.org>
2362 * elf-bfd.h (elf_hash_table): Return NULL if the linker hash
2363 table is not an ELF linker hash table.
2365 * elf.c (_bfd_elf_link_hash_table_init): Set the linker hash
2366 table type to bfd_link_elf_hash_table.
2368 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_create): Revert
2371 * linker.c (_bfd_link_hash_table_init): Set the linker hash
2372 table type to bfd_link_generic_hash_table.
2374 2001-08-24 Alexandre Oliva <aoliva@redhat.com>
2376 * bfd.c (bfd_alt_mach_code): New function.
2377 * bfd-in2.h: Rebuilt.
2379 2001-08-24 Alexandre Oliva <aoliva@redhat.com>
2381 * elf-m10300.c (mn10300_elf_relocate_section): Test the right
2382 `type' field in the hash entry when deciding whether to follow a
2385 2001-08-24 Jakub Jelinek <jakub@redhat.com>
2387 * elflink.h (elf_link_sort_cmp1): Sort RELATIVE relocs first, not
2389 (elf_link_sort_relocs): Adjust accordingly.
2391 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Add reltext flag.
2392 (elf64_alpha_check_relocs): Set it if section this reloc is against
2393 is read-only. Set DF_TEXTREL if a RELATIVE reloc is needed against
2395 (elf64_alpha_calc_dynrel_sizes): Set DF_TEXTREL flag if relocation
2396 is is against read-only section.
2397 (elf64_alpha_size_dynamic_sections): Use DF_TEXTREL flag, don't
2398 check section names.
2399 (elf64_alpha_reloc_type_class): New.
2400 (elf_backend_reloc_type_class): Define.
2402 2001-08-24 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2404 * linker.c (_bfd_generic_link_add_archive_symbols): Replace alloca()
2407 2001-08-23 Andreas Jaeger <aj@suse.de>
2409 * elf64-x86-64.c (elf64_x86_64_check_relocs): Set DF_TEXTREL if
2410 the reloc is against read-only section.
2411 (elf64_x86_64_size_dynamic_sections): Use DF_TEXTREL flag instead
2412 of looking up section names for DT_TEXTREL.
2413 (elf64_x86_64_reloc_type_class): New.
2414 (elf_backend_reloc_type_class): Define.
2416 2001-08-23 H.J. Lu <hjl@gnu.org>
2418 * syms.c (bfd_print_symbol_vandf): Add abfd to arg.
2419 * bfd-in2.h (bfd_print_symbol_vandf): Regenerated.
2421 * aoutx.h (NAME(aout,print_symbol)): Pass abfd to
2422 bfd_print_symbol_vandf.
2423 * coffgen.c (coff_print_symbol): Likewise.
2424 * elf.c (bfd_elf_print_symbol): Likewise.
2425 * ieee.c (ieee_print_symbol): Likewise.
2426 * nlmcode.h (nlm_print_symbol): Likewise.
2427 * oasys.c (oasys_print_symbol): Likewise.
2428 * pdp11.c (NAME(aout,print_symbol)): Likewise.
2429 * som.c (som_print_symbol): Likewise.
2430 * srec.c (srec_print_symbol): Likewise.
2431 * tekhex.c (tekhex_print_symbol): Likewise.
2432 * versados.c (versados_print_symbol): Likewise.
2433 * vms.c (vms_print_symbol): Likewise.
2435 * elf.c (_bfd_elf_print_private_bfd_data): Replace fprintf_vma
2436 with bfd_fprintf_vma.
2437 (bfd_elf_print_symbol): Likewise.
2438 * syms.c (bfd_print_symbol_vandf): Likewise.
2440 2001-08-23 Nick Clifton <nickc@cambridge.redhat.com>
2442 * aoutf1.h (sunos_write_object_contents): Silence compile time
2444 * libaout.h (N_SET_DYNAMIC): Silence compile time warning.
2446 * bout.c: Add missing function prototypes. Fix formatting.
2447 * coff-z8k.c: Add missing function prototypes. Fix formatting.
2448 * coff-w65.c: Add missing function prototypes. Fix formatting.
2449 * coff-h8500.c: Add missing function prototypes. Fix formatting.
2450 * coff-h8300.c: Add missing function prototypes. Fix formatting.
2451 * coff-tic54x.c: Add missing function prototypes. Fix formatting.
2452 * coff-tic30.c: Add missing function prototypes. Fix formatting.
2453 * coff-m68k.c: Add missing function prototypes. Fix formatting.
2454 * coff-rs6000.c: Add missing function prototypes. Fix formatting.
2455 * coff-sh.c: Add missing function prototypes. Fix formatting.
2457 2001-08-23 Jakub Jelinek <jakub@redhat.com>
2459 * elf-bfd.h (enum elf_reloc_type_class): New.
2460 (struct elf_backend_data): Add elf_backend_reloc_type_class.
2461 (_bfd_elf_reloc_type_class): New.
2462 * elfxx-target.h (elf_backend_reloc_type_class): Define.
2463 (elfNN_bed): Add elf_backend_reloc_type_class.
2464 * elf.c (_bfd_elf_reloc_type_class): New.
2465 * elf32-i386.c (elf_i386_check_relocs): Set DF_TEXTREL if the reloc
2466 is against read-only section.
2467 (elf_i386_size_dynamic_sections): Use DF_TEXTREL flag instead of
2468 looking up section names for DT_TEXTREL.
2469 (elf_i386_reloc_type_class): New.
2470 (elf_backend_reloc_type_class): Define.
2471 * elf32-sparc.c (elf32_sparc_check_relocs): Set DF_TEXTREL if the
2472 reloc is against read-only section.
2473 (elf32_sparc_size_dynamic_sections): Use DF_TEXTREL flag instead of
2474 looking up section names for DT_TEXTREL.
2475 (elf32_sparc_reloc_type_class): New.
2476 (elf_backend_reloc_type_class): Define.
2477 * elf64-sparc.c (sparc64_elf_check_relocs): Set DF_TEXTREL if the
2478 reloc is against read-only section.
2479 (sparc64_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
2480 looking up section names for DT_TEXTREL.
2481 (sparc64_elf_reloc_type_class): New.
2482 (elf_backend_reloc_type_class): Define.
2483 * elfxx-ia64.c (struct elfNN_ia64_link_hash_table): Add reltext field.
2484 (elfNN_ia64_hash_table_create): Clear ia64_info.
2485 (get_reloc_section): Set DF_TEXTREL if the reloc is against read-only
2487 (elfNN_ia64_size_dynamic_sections): Use ia64_info->reltext flag
2488 instead of looking up section names for DT_TEXTREL.
2489 (elfNN_ia64_reloc_type_class): New.
2490 (elf_backend_reloc_type_class): Define.
2491 * elflink.h (size_dynamic_sections): Add spare DT_NULL tags.
2492 (struct elf_link_sort_rela): New.
2493 (elf_link_sort_cmp1, elf_link_sort_cmp2, elf_link_sort_relocs): New.
2494 (elf_bfd_final_link): Call elf_link_sort_relocs.
2495 Convert one spare DT_NULL into DT_RELCOUNT resp. DT_RELACOUNT if
2498 2001-08-23 Nick Clifton <nickc@cambridge.redhat.com>
2500 * configure.in (x86-bsdi): No corefile support.
2501 * configure: Regenerate.
2503 2001-08-22 Nick Clifton <nickc@cambridge.redhat.com>
2505 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Add missing
2508 2001-08-21 Mark Elbrecht <snowball3@bigfoot.com>
2510 * coff-go32.c: Make DWARF2 sections use an alignment of 0. Set
2511 the alignment of dwarf2 linkonce sections to 0.
2512 * coff-sto32.c: Likewise.
2514 2001-08-20 Andreas Jaeger <aj@suse.de>
2516 * coff-sparc.c: Add missing prototypes.
2517 * elf32-s390.c: Likewise.
2518 * elf32-i960.c: Likewise.
2519 * aout-target.h: Likewise.
2521 2001-08-20 H.J. Lu <hjl@gnu.org>
2523 * elf-bfd.h (elf_obj_tdata): Add num_section_syms.
2524 (elf_num_section_syms): New for num_section_syms.
2526 * elf.c (elf_map_symbols): Set num_section_syms.
2527 (_bfd_elf_symbol_from_bfd_symbol): Check num_section_syms for
2528 the section symbol index.
2530 2001-08-20 Nick Clifton <nickc@cambridge.redhat.com>
2532 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_create): Never
2533 select the generic has table creator. All elf backends need elf
2534 specific fields in the hash table.
2536 2001-08-20 Alan Modra <amodra@bigpond.net.au>
2538 * archive.c (offsetof): Remove define.
2541 * sysdep.h (offsetof): Define.
2543 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2545 * bfd.c (bfd_get_gp_size): Return an unsigned int.
2546 (bfd_set_gp_size): Make param unsigned.
2547 * bfd-in2.h: Regenerate.
2548 * elf32-ppc.c (ppc_elf_add_symbol_hook): Use elf_gp_size rather
2549 than calling bfd_get_gp_size.
2550 * elf64-alpha.c (elf64_alpha_add_symbol_hook): Likewise.
2551 * elfxx-ia64.c (elfNN_ia64_add_symbol_hook): Likewise.
2553 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2555 * linker.c (default_fill_link_order): Handle four byte fill value.
2557 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2559 * elf64-sparc.c (sparc64_elf_output_arch_syms): Add missing
2561 * nlm32-alpha.c (nlm_alpha_write_external): Fix warning.
2563 * elf64-mips.c (UNUSED_RELOC): Define.
2564 (mips_elf64_howto_table_rel): Use it.
2565 (mips_elf64_howto_table_rela): Here too.
2566 (mips_elf64_write_relocs): Fix signed/unsigned warning.
2568 * coffcode.h (coff_write_object_contents): Add ATTRIBUTE_UNUSED to
2570 * coffgen.c (coff_print_symbol): Fix warnings.
2571 (coff_find_nearest_line): Likewise.
2572 * cofflink.c (_bfd_coff_link_input_bfd): Likewise.
2573 * coff-alpha.c (alpha_convert_external_reloc): Likewise.
2574 * format.c (bfd_check_format_matches): Likewise.
2575 (bfd_set_format): Likewise.
2576 * coff-ia64.c: Add missing prototypes.
2577 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Make addend
2578 signed to silence warnings.
2579 (elf64_alpha_relocate_section): Likewise.
2580 (elf64_alpha_find_reloc_at_ofs): Fix warnings.
2581 (elf64_alpha_add_symbol_hook): Likewise.
2582 (elf64_alpha_final_link): Likewise.
2583 (elf64_alpha_relax_section): Remove redundant assign to info.gotent.
2584 (elf64_alpha_merge_gots): Add ATTRIBUTE_UNUSED to unused args.
2585 (elf64_alpha_size_got_sections): Likewise.
2586 * elfxx-ia64.c: Add missing prototypes.
2587 (elfNN_ia64_relocate_section): Fix warning.
2588 (elfNN_ia64_unwind_entry_compare): Make params const.
2590 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2592 * config.bfd (targ64_selvecs): New.
2593 <powerpc-*-aix* entry>: Use it here instead of ineffectual #ifdef.
2595 * bfd-in.h (BFD_VERSION): Remove wrong comment.
2596 (BFD_DEFAULT_TARGET_SIZE): New.
2597 (BFD_ARCH_SIZE): Comment.
2598 * configure.in (target_size): New. Set instead of target64 in
2599 selvecs case statement. Set target64 from it.
2600 (bfd_default_target_size): New. Set from taget_size. AC_SUBST.
2601 * bfd-in2.h: Regenerate.
2602 * configure: Regenerate.
2604 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2606 * bfd.c (enum bfd_error): Add bfd_error_wrong_object_format.
2607 (bfd_errmsgs): Add corresponding message.
2608 * archive.c (bfd_generic_archive_p): Don't release bfd_ardata when
2609 finding an archive that contains different format object files.
2610 Return bfd_error_wrong_object_format for this case.
2611 * format.c: Formatting fixes. s/CONST/const/.
2612 (bfd_check_format_matches): Accept archives that give
2613 bfd_error_wrong_object_format if no full match is found. Tidy
2614 code handling matching_vector. Don't return a pointer to freed
2615 memory in `matching'. Handle ambiguous matches as for partial
2617 * bfd-in2.h: Regenerate.
2619 2001-08-15 Alan Modra <amodra@bigpond.net.au>
2621 * libieee.h (common_header_type): Add last_byte field.
2623 * ieee.c: Add missing prototypes. Some format fixes.
2624 (struct output_buffer_struct): Move for availability to prototypes.
2625 (ieee_part_after): New function.
2626 (ieee_slurp_debug): Use it here.
2627 (ieee_seek): Pass in ieee_data_struct rather than bfd. Use
2628 ieee_part_after to set last_byte to one past end of current part.
2630 (ieee_pos): Pass in ieee_data_struct rather than bfd.
2632 (parse_expression): Don't go beyond the end of the current part.
2633 (ieee_slurp_external_symbols): Correct type passed to read_2bytes.
2634 (ieee_get_symtab_upper_bound, ieee_get_symtab,
2635 ieee_get_symbol_info, ieee_print_symbol, ieee_new_section_hook,
2636 ieee_get_reloc_upper_bound, ieee_canonicalize_reloc, block,
2637 ieee_set_section_contents, ieee_write_object_contents,
2638 ieee_make_empty_symbol): Make static.
2639 (ieee_archive_p): Correct comments regarding bfd_read.
2640 (ieee_object_p): Similarly.
2641 (ieee_mkobject): Move it. Clear output_ptr_start, output_ptr,
2642 output_ptr_end, input_ptr_start, input_ptr, input_ptr_end,
2643 input_bfd, output_bfd, output_buffer.
2644 (do_as_repeat): Write out ieee_set_current_pc_enum value as for
2645 do_with_relocs, ie. as a symbol for relocatable files.
2646 (ieee_vec): Add comments showing functions referenced by macros.
2648 2001-08-14 Nick Clifton <nickc@cambridge.redhat.com>
2650 * aout-tic30.c: Add missing prototypes. Fix formatting.
2651 * aout-ns32k.c: Add missing prototypes. Fix formatting.
2652 * peXXigen.c: Add missining prototypes. Fix formatting.
2653 * aout-adobe.c: Add missining prototypes. Fix formatting.
2655 2001-08-13 Nick Clifton <nickc@cambridge.redhat.com>
2657 * elf32-v850.c: Add missing function prototypes.
2658 Fix some formatting.
2660 * cpu-v850.c: Add missing function prototype.
2661 Fix some formatting.
2663 2001-08-11 Nick Clifton <nickc@cambridge.redhat.com>
2665 * elf-bfd.h (struct elf_backend_data): Add new fields
2666 'elf_backend_sprintf_vma' and 'elf_backend_fprintf_vma'.
2667 (bfd_elf_sprintf_vma): Rename function prototype to
2668 '_bfd_elf_sprintf_vma'.
2669 (bfd_elf_fprintf_vma): Rename function prototype to
2670 '_bfd_elf_fprintf_vma'.
2671 * bfd.c (bfd_sprintf_vma): Do not invoke bfd_elf_sprintf_vma
2672 directly, instead indirect via the elf_backend_data structure.
2673 (bfd_fprintf_vma): Do not invoke bfd_elf_fprintf_vma directly,
2674 instead indirect via the elf_backend_data structure.
2675 * elf.c (bfd_elf_sprintf_vma): Rename to _bfd_elf_sprintf_vma.
2676 (bfd_elf_fprintf_vma): Rename to _bfd_elf_fprintf_vma.
2677 * elfxx-target.h (elf_backend_sprintf_vma): Initialise if not
2679 (elf_backend_fprintf_vma): Initialise if not already defined.
2680 (struct elf_backend_data): Initialise the
2681 elf_backend_sprintf_vma and elf_backend_fprintf_vma fields.
2683 2001-08-10 Andreas Jaeger <aj@suse.de>
2685 * elf64-sparc.c: Add missing prototypes.
2686 * elf32-cris.c: Likewise.
2687 * elf32-i370.c: Likewise.
2688 * elf64-hppa.c: Likewise.
2689 * elf64-s390.c: Likewise.
2691 2001-08-10 Andreas Jaeger <aj@suse.de>
2693 * elf64-x86-64.c (elf64_x86_64_elf_object_p): Make static.
2694 Add prototypes where needed.
2696 2001-08-10 H.J. Lu <hjl@gnu.org>
2698 * bfd.c (bfd_sprintf_vma): Fix a typo in the last change.
2699 (bfd_fprintf_vma): Likewise.
2701 2001-08-10 H.J. Lu <hjl@gnu.org>
2703 * bfd.c (bfd_sprintf_vma): Don't return void.
2704 (bfd_fprintf_vma): Likewise.
2706 2001-08-10 Andreas Jaeger <aj@suse.de>
2708 * configure.in: Add -Wstrict-prototypes and -Wmissing-prototypes
2710 * configure: Regenerate.
2712 2001-08-10 Alan Modra <amodra@bigpond.net.au>
2714 * elf.c (bfd_elf_sprintf_vma): Add ATTRIBUTE_UNUSED to quiet
2715 warning if not BFD64. Add braces so emacs auto format works.
2716 (bfd_elf_fprintf_vma): Likewise.
2718 * libxcoff.h (struct xcoff_backend_data_rec): Constify src param
2720 * coff-rs6000.c (xcoff_swap_ldhdr_in): Modify type of external
2721 param to agree with libxcoff.h.
2722 (xcoff_swap_ldhdr_out): Likewise.
2723 (xcoff_swap_ldsym_in): Likewise.
2724 (xcoff_swap_ldsym_out): Likewise.
2725 (xcoff_swap_ldrel_in): Likewise.
2726 (xcoff_swap_ldrel_out): Likewise.
2727 (xcoff_create_csect_from_smclas): Likewise.
2728 * coff64-rs6000.c: Add missing prototypes.
2729 (xcoff64_swap_ldhdr_in): Modify type of external param to agree
2731 (xcoff64_swap_ldhdr_out): Likewise.
2732 (xcoff64_swap_ldsym_in): Likewise.
2733 (xcoff64_swap_ldsym_out): Likewise.
2734 (xcoff64_swap_ldrel_in): Likewise.
2735 (xcoff64_swap_ldrel_out): Likewise.
2736 (xcoff64_ppc_relocate_section): Make static.
2737 (xcoff64_slurp_armap): Likewise.
2738 (xcoff64_archive_p): Likewise.
2739 (xcoff64_openr_next_archived_file): Likewise.
2740 (xcoff64_sizeof_headers): Likewise.
2741 (xcoff64_is_lineno_count_overflow): Likewise.
2742 (xcoff64_is_reloc_count_overflow): Likewise.
2743 (xcoff64_loader_symbol_offset): Likewise.
2744 (xcoff64_loader_reloc_offset): Likewise.
2745 * elf64-gen.c: Add missing prototypes.
2747 2001-08-09 H.J. Lu <hjl@gnu.org>
2749 * elf.c (bfd_elf_sprintf_vma): Check ELFCLASS64 only in BFD64.
2750 (bfd_elf_fprintf_vma): Likewise.
2752 2001-08-09 H.J. Lu <hjl@gnu.org>
2754 * bfd-in.h (bfd_elf_sprintf_vma, bfd_elf_fprintf_vma): Moved
2757 * bfd-in2.h: Regenerated.
2759 2001-08-09 H.J. Lu <hjl@gnu.org>
2761 * bfd-in.h (bfd_sprintf_vma): New prototype.
2762 (bfd_fprintf_vma): Likewise.
2763 (bfd_elf_sprintf_vma): Likewise.
2764 (bfd_elf_fprintf_vma): Likewise.
2765 (bfd_printf_vma): New. Defined with bfd_fprintf_vma.
2766 * bfd-in2.h: Regenerated.
2768 * bfd.c (bfd_sprintf_vma): New. Defined.
2769 (bfd_fprintf_vma): Likewise.
2771 * elf.c (bfd_elf_sprintf_vma): New. Defined.
2772 (bfd_elf_fprintf_vma): Likewise.
2774 2001-08-09 Alan Modra <amodra@bigpond.net.au>
2776 * coff-rs6000.c: Add missing prototypes.
2777 (xcoff_ppc_relocate_section, xcoff_is_lineno_count_overflow,
2778 xcoff_is_reloc_count_overflow, xcoff_loader_symbol_offset,
2779 xcoff_loader_reloc_offset): Make static.
2780 * dwarf1.c: Add missing prototypes.
2781 * dwarf2.c: Add missing prototypes.
2782 (struct abbrev_info): Move definition.
2783 (struct attr_abbrev, ABBREV_HASH_SIZE, ATTR_ALLOC_CHUNK): Likewise.
2784 * elf.c: Add missing prototypes.
2785 * elf32-gen.c: Likewise.
2786 * elf32-i386.c: Likewise.
2787 * elf32-ppc.c: Likewise.
2788 (ppc_elf_sort_rela): Use PTR instead of "void *".
2789 * elflink.h: Add missing prototypes. Formatting fixes.
2790 * merge.c: Add missing prototypes.
2791 (last4_eq): Use PTR instead of "void *".
2792 (last_eq): Likewise.
2793 * syms.c: Add missing prototypes.
2795 2001-08-09 Nick Clifton <nickc@cambridge.redhat.com>
2797 * bfd.c: Fix formatting.
2798 * bfd-in2.h: Regenerate.
2800 2001-08-09 Nick Clifton <nickc@cambridge.redhat.com>
2802 * elf32-arc.c (R_ARC_B22_PCREL): Change 'partial_inplace' to
2803 true (this target uses REL relocations) and 'pcrel_offset' to
2804 false (the PC is implied, not stored in the offset).
2806 2001-08-08 Alan Modra <amodra@bigpond.net.au>
2808 1999-10-19 Linus Nordberg <linus@swox.se>
2809 * elf-bfd.h (struct elf_backend_data): Add want_got_sym.
2810 * elfxx-target.h (elf_backend_want_got_sym): Define.
2811 (elfNN_bed): Add elf_backend_want_got_sym.
2812 * elflink.c (_bfd_elf_create_got_section): Define
2813 _GLOBAL_OFFSET_TABLE_ only if bed->want_got_sym.
2815 2001-08-08 Alexandre Oliva <aoliva@redhat.com>
2817 * dwarf2.c (struct dwarf2_debug): Add sec, sec_info_ptr and syms.
2818 (find_rela_addend): New function.
2819 (parse_comp_unit): Call it to find the abbrev offset addend.
2820 (_bfd_dwarf2_find_nearest_line): Initialize and maintain the new
2821 members of dwarf2_debug as debugging information is read.
2823 2001-08-07 Nick Clifton <nickc@cambridge.redhat.com>
2825 * coff-sh.c (sh_coff_reloc_type_lookup): Provide for sh-coff
2826 targets as well as sh-pe.
2828 2001-08-03 Ben Harris <bjh21@netbsd.org>
2830 * elf32-arm.h (elf32_arm_final_link_relocate): Include offset of
2831 reloc from start of section when computing value for R_ARM_REL32
2834 2001-08-03 Alan Modra <amodra@bigpond.net.au>
2836 From H.J. Lu <hjl@gnu.org>
2837 * elf32-i386.c (allocate_plt_and_got_and_discard_relocs): Don't
2838 keep relocs for undefined syms if there are no dynamic sections in
2840 * elf32-hppa.c (allocate_plt_and_got_and_discard_relocs): Likewise.
2842 2001-08-02 Paul Sokolovsky <paul.sokolovsky@technologist.com>
2844 * cofflink.c (coff_link_check_ar_symbols): also search for
2845 __imp__symbol as well as _symbol.
2846 * linker.c (_bfd_generic_link_add_archive_symbols): also
2847 search for __imp__symbol as well as _symbol.
2849 2001-08-01 Adam Nemet <anemet@lnxw.com>
2851 * elf.c (elf_sort_sections): Return zero only as the last step.
2853 2001-08-01 Nick Clifton <nickc@cambridge.redhat.com>
2855 * config.bfd (arm-vxworks): Change name of define from VXWORKS to
2857 (arm-epoc-pe): Define ARM_COFF_BUGFIX.
2858 coff-arm.c (coff_arm_relocate_section): Replace VXWORKS with
2861 2001-07-30 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
2863 * libecoff.h (_bfd_ecoff_styp_to_sec_flags): Changed return type
2864 to match corresponding bfd_coff_backend data member.
2866 2001-07-24 Alan Modra <amodra@bigpond.net.au>
2868 * Makefile.am: Update dependencies with "make dep-am".
2869 * Makefile.in: Regenerate
2871 2001-07-15 H.J. Lu <hjl@gnu.org>
2873 * Makefile.am (po/SRC-POTFILES.in): Use tmp.src instead of tmp.
2874 (po/BLD-POTFILES.in): Use tmp.bld instead of tmp.
2875 * Makefile.in: Regenerate.
2877 2001-07-11 H.J. Lu <hjl@gnu.org>
2879 * elf64-alpha.c (elf64_alpha_check_relocs): Set the ALLOC|LOAD
2880 flags when creating the reloc section if the ALLOC flag in the
2881 source section is set.
2883 2001-07-11 Steve Ellcey <sje@cup.hp.com>
2885 * reloc.c (bfd_reloc_code_type): Add IA64 relocs
2886 BFD_RELOC_IA64_LTOFF_FPTR32MSB and BFD_RELOC_IA64_LTOFF_FPTR32LSB
2887 * bfd-in2.h: Regenerate.
2888 * libbfd.h: Regenerate.
2889 * elfxx-ia64.c (ia64_howto_table): Define how to handle
2891 (elfNN_ia64_reloc_type_lookup): Handle new relocations.
2892 (elfNN_ia64_check_relocs): Likewise.
2893 (elfNN_ia64_install_value): Likewise.
2894 (elfNN_ia64_relocate_section): Likewise.
2896 2001-07-11 Jakub Jelinek <jakub@redhat.com>
2898 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Remove support for
2900 (elf32_sparc_check_relocs): Likewise.
2901 Only create .rela section for alloced sections in shared libraries.
2902 (elf32_sparc_relocate_section): Likewise.
2903 Remove redundant check.
2904 Optimize unaligned reloc usage.
2905 * elf64-sparc.c (sparc64_elf_relocate_section): Remove redundant
2908 2001-07-11 H.J. Lu <hjl@gnu.org>
2910 * elf64-alpha.c (elf64_alpha_check_relocs): Only use the same
2911 ALLOC|LOAD flags as the source section for debugging sections
2912 when creating the reloc section.
2914 2001-07-05 Jim Wilson <wilson@redhat.com>
2916 * linker.c (_bfd_generic_link_add_one_symbol, case BIG): Use
2917 the section of the bigger symbol.
2919 * syms.c (bfd_is_local_label): Return false if BSF_SECTION_SYM.
2921 2001-07-05 Nick Clifton <nickc@cambridge.redhat.com>
2923 * peicode.h (coff_swap_scnhdr_in): For sections containing
2924 uninitialised data, only set their size to s_paddr if this does
2925 not reset their size to zero. MS's latest compilers will set
2928 2001-07-04 H.J. Lu <hjl@gnu.org>
2930 * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing):
2931 Handle bfd_mach_mips4400, bfd_mach_mips4600 and
2934 2001-07-03 Mark Elbrecht <snowball3@softhome.net>
2936 * bfd.c (bfd_get_sign_extend_vma): Support DJGPP COFF targets.
2938 * cofflink.c (_bfd_coff_link_input_bfd): Skip section symbols from
2939 sections being discarded.
2941 2001-06-30 Alan Modra <amodra@bigpond.net.au>
2943 * elfcore.h (elf_core_file_p): Call bfd_section_from_phdr directly
2944 instead of _bfd_elfcore_section_from_phdr.
2945 * elf-bfd.h (_bfd_elfcore_section_from_phdr): Remove.
2946 * elf.c (_bfd_elfcore_section_from_phdr): Remove.
2947 (_bfd_elfcore_make_pseudosection): Expedite tail-call.
2948 (elfcore_grok_prstatus): Likewise.
2949 (elfcore_grok_lwpstatus): Likewise.
2950 (bfd_get_elf_phdr_upper_bound): Likewise.
2951 (elfcore_make_note_pseudosection): Formatting.
2952 (_bfd_elfcore_strndup): Formatting.
2953 * elf32-mips.c (mips_elf_sym_is_global): Formatting.
2954 (_bfd_elf32_mips_grok_prstatus): Expedite tail-call.
2956 2001-06-29 Daniel Jacobowitz <drow@mvista.com>
2958 * elf-bfd.h: Add prototypes for _bfd_elfcore_make_pseudosection
2959 and _bfd_elfcore_strndup.
2960 (struct elf_backend_data): Add elf_backend_grok_prstatus
2961 and elf_backend_grok_psinfo.
2962 * elf.c (_bfd_elfcore_make_pseudosection): New function.
2963 (elfcore_grok_prstatus): Use it.
2964 (elfcore_make_note_pseudosection): Likewise.
2965 (elfcore_strndup): Rename to...
2966 (_bfd_elfcore_strndup): Here, and make global.
2967 (elfcore_grok_psinfo): Use _bfd_elfcore_strndup.
2968 (elfcore_grok_note): Call elf_backend_grok_prstatus
2969 and elf_backend_grok_psinfo if available.
2970 * elf32-mips.c (_bfd_elf32_mips_grok_prstatus): New function.
2971 (_bfd_elf32_mips_grok_psinfo): New function.
2972 (elf_backend_grok_prstatus): Define.
2973 (elf_backend_grok_psinfo): Define.
2974 * elfxx-target.h (elf_backend_grok_prstatus): Default to NULL.
2975 (elf_backend_grok_psinfo): Likewise.
2976 (elfNN_bed): Include elf_backend_grok_prstatus and
2977 elf_backend_grok_psinfo.
2979 2001-06-29 H.J. Lu <hjl@gnu.org>
2981 * elf32-hppa.c (elf32_hppa_finish_dynamic_sections): Check if
2982 hplink->sgot is NULL before filling GOT. Check if hplink->splt
2983 is NULL before filling PLT.
2985 2001-06-29 Alan Modra <amodra@bigpond.net.au>
2987 * elflink.h (elf_link_output_extsym): Revert 1999-04-10.
2989 2001-06-27 Alan Modra <amodra@bigpond.net.au>
2991 * elf32-hppa.c (elf32_hppa_check_relocs): Don't make syms dynamic
2993 (elf32_hppa_adjust_dynamic_symbol): ..nor here..
2994 (allocate_plt_and_got_and_discard_relocs): .. instead do so here
2997 * elf32-hppa.c (RELATIVE_DYNAMIC_RELOCS): Delete.
2998 (IS_ABSOLUTE_RELOC): Define.
2999 (elf32_hppa_link_hash_entry): Always include reloc_entries field.
3000 (hppa_link_hash_newfunc): Always init it.
3001 (elf32_hppa_check_relocs): Mark symbols as ELF_LINK_NON_GOT_REF to
3002 create COPY relocs only when the reloc is in a read-only section.
3003 Instead, allocate space for a dynamic reloc to reference the
3004 library symbol directly. Keep track of space we allocate using
3006 (hppa_discard_copies): Delete, and move code to..
3007 (allocate_plt_and_got): ..here. Rename to
3008 allocate_plt_and_got_and_discard_relocs. Remove unneeded dynamic
3009 relocs for non-shared link.
3010 (elf32_hppa_size_dynamic_sections): Update calls to above.
3011 (elf32_hppa_relocate_section): Write out the dynamic relocs used
3012 in lieu of COPY relocs.
3014 * elf32-i386.c (elf_i386_check_relocs): Don't make syms dynamic
3016 (elf_i386_adjust_dynamic_symbol): ..nor here..
3017 (allocate_plt_and_got_and_discard_relocs): .. instead do so here
3019 (elf_i386_size_dynamic_sections): Fix a comment.
3020 (elf_i386_relocate_section <R_386_32, R_386_PC32>): Rearrange code
3021 involved in writing reloc out.
3023 2001-06-25 Alan Modra <amodra@bigpond.net.au>
3025 * elf32-i386.c (elf_i386_check_relocs <R_386_32, R_386_PC32>):
3026 Ensure syms are dynamic if we might be emitting a reloc.
3027 (allocate_plt_and_got_and_discard_relocs): Don't discard relocs
3028 for undefweak or undefined syms..
3029 (elf_i386_relocate_section <R_386_32, R_386_PC32>): .. and emit.
3031 * elf32-i386.c (allocate_plt_and_got_and_discard_relocs): Discard
3032 relocs without ELF_LINK_HASH_DEF_DYNAMIC set.
3033 (elf_i386_relocate_section <R_386_32, R_386_PC32>): Remove
3034 redundant bfd_link_hash_defined, bfd_link_hash_defweak test.
3036 2001-06-24 H.J. Lu <hjl@gnu.org>
3038 * cpu-i960.c (scan_960_mach): Don't modify const char *. Use
3039 strncasecmp/strcasecmp instead of strncmp/strcmp.
3041 2001-06-23 H.J. Lu <hjl@gnu.org>
3043 * elf32-i386.c (elf_i386_relocate_section <R_386_32, R_386_PC32>):
3044 Check ELF_LINK_HASH_DEF_DYNAMIC to see if a symbol is not defined
3045 in the regular object file and treat the weak definition as
3048 2001-06-23 Alan Modra <amodra@bigpond.net.au>
3050 * elf32-i386.c (elf_i386_relocate_section <R_386_GOT32>): Tighten
3051 unresolved_reloc test to exclude cases where we use "relocation"
3052 before setting it to point into the .got. Reinstate fudge for
3053 unresolved relocs in debugging sections.
3055 * elf32-i386.c (elf_i386_relocate_section): Replace ugly
3056 complicated tests for unresolvable relocs with a simple direct
3057 scheme using "unresolved_reloc" var.
3059 * elf32-i386.c (struct elf_i386_pcrel_relocs_copied): Rename to
3060 elf_i386_dyn_relocs. Update comment.
3061 (struct elf_i386_link_hash_entry): Rename pcrel_relocs_copied to
3063 (elf_i386_adjust_dynamic_symbol): Remove a BFD_ASSERT, change
3065 (allocate_plt_and_got_and_discard_relocs): Replace BFD_ASSERT with
3067 (elf_i386_size_dynamic_sections): Likewise.
3068 (elf_i386_finish_dynamic_symbol): Likewise.
3069 (elf_i386_finish_dynamic_sections): Likewise.
3070 (elf_i386_relocate_section): Likewise. Tidy R_386_GOT32 and error
3073 Avoid creating COPY relocs if possible.
3074 * elf32-i386.c (elf_i386_check_relocs): Tweak condition under
3075 which .got created. Mark symbols used by R_386_32 and R_386_PC32
3076 relocs as ELF_LINK_NON_GOT_REF to create COPY relocs only when the
3077 reloc is in a read-only section. Instead, allocate space for a
3078 dynamic reloc to reference the library symbol directly. Keep
3079 track of space we allocate using pcrel_relocs_copied.
3080 (discard_copies): Delete, and move code to ..
3081 (allocate_plt_and_got): ..here. Rename to
3082 allocate_plt_and_got_and_discard_relocs. Remove unneeded dynamic
3083 relocs for non-shared link.
3084 (elf_i386_size_dynamic_sections): Update calls to above functions.
3085 (elf_i386_relocate_section): Write out the dynamic relocs. Add
3086 more ugly logic to avoid "unresolvable relocation" error. Use
3087 htab shortcut in place of elf_hash_table macro.
3088 (elf_i386_finish_dynamic_sections): Allow that dynamic .got may
3089 not always be created now.
3091 2001-06-20 Bo Thorsen <bo@suse.co.uk>
3093 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix linking of
3096 2001-06-18 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3098 * configure.host (mips64-*-linux): Reformat.
3100 2001-06-21 Alan Modra <amodra@bigpond.net.au>
3102 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Always
3103 allocate local .got space. Use shortcuts from hash table for .got
3104 and .plt rather than comparing section names.
3105 (elf32_hppa_check_relocs): Use local_plt_refcounts var rather than
3106 adjusting index into local_got_refcounts to document what we are
3108 (elf32_hppa_relocate_section): Similarly for local_plt_offsets.
3109 Tidy .got and .plt error checking.
3111 2001-06-20 Catherine Moore <clm@redhat.com>
3113 * elf-bfd.h (struct elf_backend_data):
3114 elf_backend_emit_relocs: New field: Function for emitting
3116 elf_backend_count_relocs: New field: Function for determining
3117 the number of relocs to be emitted.
3118 * elfxx-target.h: Provide default (NULL) values for
3119 elf_backend_emit_relocs and elf_backend_count_relocs.
3120 * elflink.h (elf_link_size_reloc_section): Make the hash table
3121 big enough to hold the relocs counted by either reloc_count or
3123 (elf_bfd_final_link) emit_relocs: New boolean, set if relocs
3124 should be emitted, either because of a command line option
3125 stored in the info structure or because the target provides a
3126 special reloc emitting function.
3127 If the target provides a reloc counting function use it,
3128 unless performing a relocatable link or emitting all relocs.
3129 Also set the SEC_RELOC flag on any output section which will
3131 (elf_link_input_bfd): emit_relocs: New boolean, set if relocs
3132 should be emitted, either because of a command line option
3133 stored in the info structure or because the target provides a
3134 special reloc emitting function.
3135 If the target provides a reloc emitting function, use it,
3136 unless performing a relocatable link or emitting all relocs.
3138 2001-06-20 H.J. Lu <hjl@gnu.org>
3140 * elf32-i386.c (elf_i386_size_dynamic_sections): Always
3141 allocate local .got space.
3143 2001-06-19 Andreas Jaeger <aj@suse.de>
3145 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix creation of
3148 2001-06-18 Hans-Peter Nilsson <hp@axis.com>
3150 * elflink.h (struct elf_assign_sym_version_info): Remove member
3151 export_dynamic. All users changed to use info member.
3152 NAME(bfd_elf,size_dynamic_sections)): Remove parameter
3153 export_dynamic, instead use member in parameter info.
3154 * bfd-in.h (bfd_elf32_size_dynamic_sections,
3155 bfd_elf64_size_dynamic_sections): Update prototype.
3156 * bfd-in2.h: Regenerate.
3158 2001-06-18 H.J. Lu <hjl@gnu.org>
3160 * elflink.h (elf_info_failed): Add a new field, verdefs.
3161 (NAME(bfd_elf,size_dynamic_sections): Pass verdefs to
3163 (elf_export_symbol): Check eif->verdefs to decide if a symbol
3166 2001-06-17 H.J. Lu <hjl@gnu.org>
3168 * elf32-mips.c (mips_elf_link_hash_entry): Add a new field,
3169 readonly_reloc, to record if a relocation in the .rel.dyn
3170 section is against a read-only section.
3171 (mips_elf_link_hash_newfunc): Initialize the readonly_reloc
3173 (_bfd_mips_elf_check_relocs): Record if there is a relocation
3174 in the .rel.dyn section against a read-only section by setting
3175 DF_TEXTREL or readonly_reloc.
3176 (_bfd_mips_elf_copy_indirect_symbol): Copy readonly_reloc if
3178 (_bfd_mips_elf_adjust_dynamic_symbol): Record DF_TEXTREL if
3179 there is a relocation in the .rel.dyn section against a
3181 (_bfd_mips_elf_size_dynamic_sections): Set DT_TEXTREL if
3184 2001-06-12 Nick Clifton <nickc@cambridge.redhat.com>
3186 * coffcode.h (styp_flags_to_sec_flags): Change to a boolean
3187 function. Move flagword result into parameter list. Remove
3188 comment about setting bfd_error_handler to intercept failure
3190 * coffgen.c (make_a_section_from_file): Examine result of
3191 calling bfd_coff_styp_to_sec_flags and pass a failure back to
3193 * ecoff.h (styp_flags_to_sec_flags): Change to a boolean
3194 function. Move flagword result into parameter list.
3195 * libcoff.h: Regenerate.
3196 * libecoff.h: Regenerate.
3198 2001-06-13 Nick Clifton <nickc@cambridge.redhat.com>
3200 * aoutx.h (adjust_z_magic): Only pad the tesxt section if the data
3201 section is going to follow it.
3203 2001-06-12 Catherine Moore <clm@redhat.com>
3205 * elflink.h (elf_gc_propagate_vtable_entries): Replace FILE_ALIGN
3206 with the file_align entry from elf_backend_data.
3207 (elf_gc_smash_unused_vtentry_relocs): Likewise.
3208 (elf_gc_record_vtentry): Likewise.
3210 2001-06-10 Alan Modra <amodra@bigpond.net.au>
3212 * elflink.h: Whitespace changes.
3213 (elf_link_read_relocs_from_section): Use "unsigned int" iterator
3214 rather than "unsigned char".
3215 (elf_link_output_relocs): Likewise.
3216 (elf_link_input_bfd): Likewise.
3217 (elf_reloc_link_order): LIkewise.
3218 * elf.c: s/CONST/const/. Whitespace changes.
3219 * elf32-mips.c: Formatting fix.
3221 * Makefile.am (SOURCE_HFILES): Include xcoff-target.h, remove xcoff.h.
3222 * Makefile.in: Regenerate.
3223 * po/Make-in: Remove trailing tab.
3225 2001-06-09 Philip Blundell <philb@gnu.org>
3227 * elf32-arm.h (elf32_arm_plt0_entry): Correct error in last
3229 (elf32_arm_plt_entry): Likewise.
3231 2001-06-08 H.J. Lu <hjl@gnu.org>
3233 * elf.c (swap_out_syms): Keep names for global section symbols.
3235 2001-06-07 H.J. Lu <hjl@gnu.org>
3237 * config.bfd: Put back ecoff for Linux/mips. Firmwares on some
3238 MIPS-based machines need it.
3240 2001-06-07 H.J. Lu <hjl@gnu.org>
3242 * elf32-mips.c (_bfd_mips_elf_object_p): Set the bad symtab
3245 * config.bfd: Remove ecoff from Linux/mips.
3247 2001-06-07 Andreas Jaeger <aj@suse.de>
3249 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_symbol): Add an
3251 (elf64_x86_64_check_relocs): Fix VTENTRY relocation; set an
3252 alignment of 8 for .rela sections; handle further relocations.
3254 2001-06-06 Christian Groessler <cpg@aladdin.de>
3256 * coff-z8k.c: Fix formatting.
3257 Fix howtos: howto->size was always 1.
3259 2001-06-05 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3261 * configure.host (mips64*-*-linux*): Define.
3263 2001-06-05 Alan Modra <amodra@bigpond.net.au>
3265 * elf32-i386.c (elf_i386_discard_copies): Rename to
3266 discard_copies, and use elf_link_hash_entry arg rather than
3267 elf_i386_link_hash_entry.
3268 (elf_i386_link_hash_traverse): Delete.
3269 (elf_i386_size_dynamic_sections): Adjust call to discard_copies.
3270 Tidy sizing of dynamic sections.
3271 (elf_i386_check_relocs <R_386_32, R_386_PC32>): Reference count
3272 possible .plt entries.
3273 (elf_i386_gc_sweep_hook): Likewise.
3274 (elf_i386_adjust_dynamic_symbol): Discard .plt entries for
3275 everything with plt.refcount <= 0.
3277 * elf32-i386.c (elf_i386_check_relocs): Don't allocate .got and
3279 (elf_i386_gc_sweep_hook): ..and no need to deallocate here..
3280 (elf_i386_adjust_dynamic_symbol): ..and don't allocate .plt and
3282 (allocate_plt_and_got): ..instead do it all here. New function.
3283 (elf_i386_size_dynamic_sections): Allocate local .got space and
3284 call allocate_plt_and_got. No need to zap .relgot if not dynamic.
3285 (bfd_elf32_bfd_final_link): Delete. (ie. use regular final link
3286 rather than gc variety).
3287 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
3288 (elf_i386_relocate_section): Use it here and correct handling of
3289 R_386_GOT32. Provide section and offset for "unresolvable
3290 relocation" error message.
3291 (elf_i386_finish_dynamic_symbol): Correct handling of R_386_GOT32.
3293 * elf32-i386.c (struct elf_i386_link_hash_table): Add sgot,
3294 sgotplt, srelgot, splt, srelplt, sdynbss, srelbss fields.
3295 (elf_i386_link_hash_table_create): Init them.
3296 (create_got_section): New function.
3297 (elf_i386_create_dynamic_sections): New function.
3298 (elf_backend_create_dynamic_sections): Set to above.
3299 (elf_i386_check_relocs): Use shortcuts from hash table rather than
3300 calling bfd_get_section_by_name.
3301 (elf_i386_gc_sweep_hook): Likewise.
3302 (elf_i386_adjust_dynamic_symbol): Likewise.
3303 (elf_i386_size_dynamic_sections): Likewise.
3304 (elf_i386_relocate_section): Likewise.
3305 (elf_i386_finish_dynamic_sections): Likewise.
3307 * elf32-hppa.c (allocate_plt_and_got): Skip indirect and warning syms.
3309 2001-06-02 H.J. Lu <hjl@gnu.org>
3311 * elf32-hppa.c (elf32_hppa_object_p): Check ELFOSABI_LINUX
3313 * elf64-hppa.c (elf64_hppa_object_p): Likewise.
3315 2001-06-02 H.J. Lu <hjl@gnu.org>
3317 * aout-cris.c (MACHTYPE_OK): New. Defined.
3319 2001-06-02 Hans-Peter Nilsson <hp@axis.com>
3321 * section.c (_bfd_strip_section_from_output): Handle NULL
3324 2001-06-02 H.J. Lu <hjl@gnu.org>
3326 * config.bfd (powerpc-*-aix*, powerpc-*-beos*, rs6000-*-*): Add
3327 rs6000coff64_vec only if BFD64 is defined.
3328 (powerpc64-*-aix*): Enable only if BFD64 is defined.
3330 2001-06-02 H.J. Lu <hjl@gnu.org>
3332 * coff-ia64.c (ia64coff_object_p): Rewrite with
3333 external_PEI_DOS_hdr and external_PEI_IMAGE_hdr.
3335 2001-06-01 Andreas Jaeger <aj@suse.de>
3337 * elf64-x86-64.c (elf64_x86_64_relocate_section): Add PC8
3338 relocation, small reformatting.
3340 2001-05-29 Andreas Jaeger <aj@suse.de>
3342 * elf64-x86-64.c (elf64_x86_64_check_relocs): Handle R_X86_64_64.
3343 (elf64_x86_64_relocate_section): Likewise.
3345 2001-05-30 Alan Modra <amodra@one.net.au>
3347 * elf32-hppa.c (elf32_hppa_check_relocs): Don't NEED_PLT for
3348 millicode. Don't allocate .got and .rela.got space here..
3349 (elf32_hppa_gc_sweep_hook): ..and no need to deallocate here..
3350 (elf32_hppa_adjust_dynamic_symbol): ..and don't allocate .plt and
3352 (hppa_handle_PIC_calls): ..nor here..
3353 (allocate_plt_and_got): ..instead do it all here. New function.
3354 (elf32_hppa_size_dynamic_sections): Allocate local .got space and
3355 call allocate_plt_and_got. No need to zap .got if not dynamic.
3356 (elf32_hppa_final_link): Call regular bfd_final_link instead of
3357 gc_common_final_link.
3358 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
3359 (elf32_hppa_relocate_section): Use it here.
3360 (elf32_hppa_finish_dynamic_symbol): Remove superfluous test of
3361 dynamic_sections_created.
3362 (hppa_type_of_stub): Don't LONG_BRANCH_VIA_PLT if millicode sym.
3364 2001-05-28 Andreas Jaeger <aj@suse.de>
3366 * elf64-x86-64.c (elf64_86_64_size_info): Remove, we can use the
3367 generic version since we want a hashsize of 4.
3368 (elf_backend_size_info): Likewise.
3370 2001-05-28 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3372 * elflink.h (elf_link_size_reloc_section): Use bfd_zmalloc instead of
3374 (elf_link_output_relocs): Handle MIPS ELF64 relocations correctly.
3375 (elf_link_input_bfd): Likewise.
3376 (elf_reloc_link_order): Likewise.
3377 (elf_finish_pointer_linker_section): Typo. Handle MIPS ELF64
3378 relocations correctly.
3380 2001-05-28 Nicolas Pitre <nico@cam.org>
3382 * elf32-arm.h: fix PLT generation for big endian ARM
3384 2001-05-28 Alan Modra <amodra@one.net.au>
3386 * elf32-hppa.c (elf32_hppa_relocate_section): Set up .plt entries
3387 for symbols forced local that need plabels.
3388 (elf32_hppa_adjust_dynamic_symbol): Don't allocate space in
3389 .plt.rela for local syms if non-shared.
3390 (hppa_build_one_stub): Mask lsb of plt.offset.
3391 (elf32_hppa_finish_dynamic_symbol): Abort if lsb of plt.offset set.
3392 (clobber_millicode_symbols): Correct comment.
3393 (elf32_hppa_relocate_section): Likewise.
3394 (elf32_hppa_finish_dynamic_symbol): Likewise.
3396 2001-05-28 Jeff Sturm <jsturm@one-point.com>
3398 * reloc.c: Add BFD_RELOC_SPARC_UA16 and BFD_RELOC_SPARC_UA64.
3399 * bfd-in2.h: Regenerate.
3400 * libbfd.h: Regenerate.
3401 * elf32-sparc.c: Enable BFD_RELOC_SPARC_UA16, BFD_RELOC_SPARC_UA32
3402 and BFD_RELOC_SPARC_UA64 mapping
3403 * elf64-sparc.c: Likewise.
3405 2001-05-25 H.J. Lu <hjl@gnu.org>
3407 * Makefile.am (BFD32_BACKENDS): Remove coff-pmac.lo.
3408 (BFD32_BACKENDS_CFILES): Remove coff-pmac.c.
3409 (coff-rs6000.lo): Remove the old dependency.
3410 * Makefile.in: Rebuild.
3412 * configure.in (pmac_xcoff_vec): Replace coff-pmac.lo with
3415 2001-05-25 H.J. Lu <hjl@gnu.org>
3417 * coff-rs6000.c (rs6000coff_vec): Use rs6000coff_core_p,
3418 rs6000coff_core_file_matches_executable_p,
3419 rs6000coff_core_file_failing_command and
3420 rs6000coff_core_file_failing_signal only if AIX_CORE is
3422 (pmac_xcoff_vec): Likewise.
3423 * coff64-rs6000.c (rs6000coff64_vec): Likewise.
3425 2001-05-25 Timothy Wall <twall@redhat.com>
3427 * elfxx-ia64.c (allocate_dynrel_entries): Don't allocate an entry
3428 for __GLOB_DATA_PTR on AIX5. Clean up some relocation bugs.
3430 2001-05-25 H.J. Lu <hjl@gnu.org>
3432 * bfd-in2.h: Regenerated.
3433 * libcoff.h: Likewise.
3435 2001-05-25 Alan Modra <amodra@one.net.au>
3437 * elf32-hppa.c (elf32_hppa_relocate_section): Don't allow
3438 undefined millicode syms in shared libs.
3439 (hppa_build_one_stub): Turn BFD_ASSERTs into aborts.
3440 (elf32_hppa_check_relocs): Likewise.
3441 (elf32_hppa_adjust_dynamic_symbol): Likewise.
3442 (elf32_hppa_size_dynamic_sections): Likewise.
3443 (elf32_hppa_relocate_section): Likewise.
3444 (elf32_hppa_finish_dynamic_symbol): Likewise.
3445 (elf32_hppa_finish_dynamic_sections): Likewise.
3447 2001-05-24 Tom Rix <trix@redhat.com>
3449 * Makefile.am coff-pmac bfd now defined in coff-rs6000.c
3450 xcoff-target.h not used to define rs6000 or ppc bfd.
3453 * bfd-in.h : (struct lineno_cache_entry) promote element "offset"
3456 * coff-rs6000.c : Many changes for 64 bit support. Move common
3457 32/64 code to xcofflink.c. Explictly define the rs6000coff_vec
3460 * coff64-rs6000.c : Many changes for 64 bit support. 64 bit
3461 linker now supported. Explictly define the rs6000coff64_vec.
3463 * coffcode.h : (coff_set_arch_mach_hook) xcoff 64 bit support
3464 (coff_print_aux) same
3465 (coff_write_object_contents) same
3466 (coff_slurp_line_table) same
3468 * coffgen.c : (coff_fix_symbol_name) formatting
3469 (coff_mangle_symbols) xcoff 64 bit support
3470 (coff_write_symbol) same
3471 (coff_write_alien_symbol) same
3472 (coff_write_native_symbol) same
3473 (coff_write_symbols) same
3474 (coff_get_symbol_info) same
3475 (bfd_coff_get_syment) same
3476 (coff_print_symbol) same
3478 * config.bfd : add powerpc64-*-aix* target
3480 * libcoff-in.h : formatting
3482 * libcoff.h : move xcoff extern declarations to libxcoff.h
3484 * libxcoff.h : New file
3486 * xcofflink.c : Many changes for xcoff64 support. Move common
3487 structures to include/coff/xcoff.h. Move specific structure to
3488 backends coff-rs6000.c and coff64-rs6000.c. Use new backend
3489 functions, defined in libxcoff.h, to isolate 32/64 dependencies.
3491 (bfd_xcoff_size_dynamic_sections) : special __rtinit symbol for
3494 (xcoff_build_ldsyms) : handle special __rtinit symbol.
3496 2001-05-23 Alexandre Oliva <aoliva@redhat.com>
3498 * elf64-sparc.c (sparc64_elf_slurp_reloc_table): Fix typo
3501 2001-05-23 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3503 * reloc.c (bfd_reloc_code_real): Add MIPS ELF64 relocations.
3504 * libbfd.h: Regenerate.
3505 * bfd-in2.h: Regenerate.
3507 * aoutx.h (aout_@var{size}_machine_type): Add MIPS r12k support.
3508 * archures.c (bfd_mach_mips12000): Define.
3509 * cpu-mips.c (arch_info_struct): Add MIPS r12k support.
3510 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Add MIPS r12k
3512 (_bfd_mips_elf_size_dynamic_sections): Use official bfd typedef.
3513 * bfd-in2.h: Regenerate.
3514 * elfxx-target.h: Do not redefine bfd_elfNN_bfd_make_debug_symbol.
3516 2001-05-23 kaz Kojima <kkojima@rr.iij4u.or.jp>
3518 * elf32-sh.c (elf_sh_plt0_entry_be, elf_sh_plt0_entry,
3519 elf_sh_plt_entry_be, elf_sh_plt_entry, elf_sh_pic_plt_entry_be,
3520 elf_sh_pic_plt_entry): New PLT code, that does not use r2, since
3521 that is used by GCC.
3523 2001-05-23 Nick Clifton <nickc@cambridge.redhat.com>
3525 * elf-bfd.h (NUM_SHDR_ENTRIES): New macro: compute the number
3526 of entries in a structured section.
3527 * elf.c: Use new macro.
3528 * elf32-i386.c: Use new macro.
3529 * elf32-mips.c: Use new macro.
3530 * elf64-alpha.c: Use new macro.
3531 * elf64-sparc.c: Use new macro.
3532 * elfcode.h: Use new macro.
3533 * elflink.h: Use new macro.
3535 2001-05-23 Nick Clifton <nickc@cambridge.redhat.com>
3537 * bfdint.texi: Replace -oformat with --oformat.
3539 2001-05-21 Andreas Jaeger <aj@suse.de>
3541 * dwarf2.c (decode_line_info): Fix error message.
3542 (read_abbrevs): Fix test for offset as suggested by Alan Modra and
3543 adjust error message.
3545 2001-05-18 H.J. Lu <hjl@gnu.org>
3547 * elflink.h (elf_link_add_object_symbols): Revert the last
3550 2001-05-17 Alan Modra <amodra@one.net.au>
3552 * elf32-hppa.c (clobber_millicode_symbols): Temporarily set
3553 ELF_LINK_FORCED_LOCAL to suit 2001-04-30 change.
3554 (hppa_build_one_stub): Add an assert to check plt.offset.
3556 2001-05-17 H.J. Lu <hjl@gnu.org>
3558 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set the
3559 version definition to basename of the output filename.
3561 2001-05-17 H.J. Lu <hjl@gnu.org>
3563 * elflink.h (elf_link_add_object_symbols): Set DT_NEEDED to
3564 basename of the bfd filename.
3566 2001-05-16 Alan Modra <amodra@one.net.au>
3568 * section.c (asection): Add linker_has_input field.
3569 (STD_SECTION): Adjust initialization to suit.
3570 * ecoff.c (bfd_debug_section): Likewise.
3571 * bfd-in2.h: Regenerate.
3573 2001-05-15 Alexandre Oliva <aoliva@redhat.com>
3575 * elf-m10300.c (mn10300_elf_relax_section): Don't relax
3576 negative 32-bit operands to 16 operands when the operand is
3577 going to be zero-extended by the modified opcode.
3579 2001-05-12 Peter Targett <peter.targett@arccores.com>
3581 * cpu-arc.c (arch_info_struct): Add entry 'base' representing old
3582 name for 'arc5' core versions.
3583 (bfd_arc_arch): Make bfd_mach_arc_6 default.
3585 * elf32-arc.c (arc_elf_object_p): Make E_ARC_MACH_ARC6 default
3587 (arc_elf_final_write_processing): Make bfd_mach_arc_6 default.
3589 2001-05-11 Jakub Jelinek <jakub@redhat.com>
3591 * elfxx-ia64.c (is_unwind_section_name): Consider linkonce unwind
3593 (elfNN_ia64_final_write_processing): Map .gnu.linkonce.ia64unw.FOO
3594 to .gnu.linkonce.t.FOO text section.
3596 2001-05-11 Jakub Jelinek <jakub@redhat.com>
3598 * merge.c (struct sec_merge_hash_entry): Add u.entsize and u.suffix
3599 fields, change sec into secinfo.
3600 (struct sec_merge_info): Add chain, remove last fields.
3601 (struct sec_merge_sec_info): Add next, sec, psecinfo fields.
3602 (sec_merge_hash_lookup): If lookup could not use a string only
3603 because it has bad alignment, mark the old string for deletion.
3604 (sec_merge_add): Add secinfo argument. Don't compute entry's
3605 position, instead record the section.
3606 (sec_merge_emit): Update for the sec into secinfo change in
3607 struct sec_merge_hash_entry.
3608 (_bfd_merge_section): Only record the section for merging, defer
3609 putting strings into the hash table.
3610 (cmplengthentry, last4_eq, last_eq, record_section, merge_strings,
3611 _bfd_merge_sections): New functions.
3612 (_bfd_merged_section_offset): Update for the sec_merge_hash_entry
3614 * libbfd-in.h (_bfd_merge_sections): Add prototype.
3615 (_bfd_nolink_bfd_merge_sections): Define.
3616 * libbfd.h: Likewise.
3617 (bfd_generic_merge_sections): Add prototype.
3618 * targets.c (BFD_JUMP_TABLE_LINK): Add _bfd_merge_sections.
3619 (struct bfd_target): Likewise.
3620 * bfd.c (bfd_merge_sections): Define.
3621 * bfd-in2.h: Rebuilt.
3622 * elf.c (_bfd_elf_merge_sections): New function.
3623 * elf-bfd.h (_bfd_elf_merge_sections): Add prototype.
3624 * elfxx-target.h (bfd_elfNN_bfd_merge_sections): Define.
3625 * reloc.c (bfd_generic_merge_sections): New function.
3626 * vms.c (vms_bfd_merge_sections): New function.
3627 * aout-adobe.c (aout_32_bfd_merge_sections): Define.
3628 * aout-target.h (MY_bfd_merge_sections): Define.
3629 * aout-tic30.c (MY_bfd_merge_sections): Define.
3630 * binary.c (binary_bfd_merge_sections): Define.
3631 * bout.c (b_out_bfd_merge_sections): Define.
3632 * coff-alpha.c (_bfd_ecoff_bfd_merge_sections): Define.
3633 * coffcode.c (coff_bfd_merge_sections): Define.
3634 * coff-mips.c (_bfd_ecoff_bfd_merge_sections): Define.
3635 * i386msdos.c (msdos_bfd_merge_sections): Define.
3636 * i386os9k.c (os9k_bfd_merge_sections): Define.
3637 * ieee.c (ieee_bfd_merge_sections): Define.
3638 * ihex.c (ihex_bfd_merge_sections): Define.
3639 * nlm-target.h (nlm_bfd_merge_sections): Define.
3640 * oasys.c (oasys_bfd_merge_sections): Define.
3641 * ppcboot.c (ppcboot_bfd_merge_sections): Define.
3642 * som.c (som_bfd_merge_sections): Define.
3643 * srec.c (srec_bfd_merge_sections): Define.
3644 * tekhex.c (tekhex_bfd_merge_sections): Define.
3645 * versados.c (versados_bfd_merge_sections): Define.
3646 * xcoff-target.h (_bfd_xcoff_bfd_merge_sections): Define.
3648 2001-05-11 Nick Clifton <nickc@cambridge.redhat.com>
3650 * dwarf1.c (_bfd_dwarf1_find_nearest_line): Change type of 'addr'
3651 to be unsigned long, in order to match its use.
3653 2001-05-10 H.J. Lu <hjl@gnu.org>
3655 * linker.c (_bfd_generic_link_add_one_symbol): Check loop on
3658 2001-05-09 H.J. Lu <hjl@gnu.org>
3660 * elflink.h (elf_link_add_object_symbols): Fix a typo. Allocate
3661 versymhdr->sh_size bytes for extversym instead of hdr->sh_size.
3662 Remove the unused veriable `dynver'.
3664 2001-05-08 Ian Lance Taylor <ian@zembu.com>
3666 * coff-i386.c (coff_i386_reloc): Don't dump core if output_bfd is
3667 NULL or is not COFF.
3668 (coff_i386_rtype_to_howto): Don't dump core if output section
3671 2001-05-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3673 * ecoff.c (bfd_debug_section): Fix initialization.
3674 * elf.c (_bfd_elf_slurp_version_tables): Change maxidx to unsigned, it
3675 is always a positive integer. Cast away sign mismatch.
3676 * elf32-mips.c: Fix misleading comment and typo.
3677 (_bfd_mips_elf_section_from_bfd_section): Remove unused attribute, use
3679 * elflink.c: Fix typo.
3680 (_bfd_elf_create_dynamic_sections): Remove superfluous initialization.
3681 * ecoffswap.h (ecoff_swap_fdr_in): Cast away sign mismatch.
3683 2001-05-04 Richard Henderson <rth@redhat.com>
3685 * elf64-alpha.c (SREL16, SREL32, SREL64): Set pcrel_offset true.
3687 2001-05-04 Nick Clifton <nickc@cambridge.redhat.com>
3689 * elf32-arm.h (elf32_arm_final_link_relocate): Set
3690 EF_ARM_HASENTRY if the start address is set.
3692 2001-05-03 Nick Clifton <nickc@cambridge.redhat.com>
3694 * targets.c (_bfd_target_vector_entries): Compute value based on
3695 the size of the _bfd_target_vector and not bfd_target_vector.
3697 2001-05-03 H.J. Lu <hjl@gnu.org>
3699 * elfcode.h: Include "libiberty.h".
3701 * elflink.h (elf_link_add_object_symbols): Set
3702 elf_dt_name (abfd) to basename of the bfd filename.
3703 (NAME(bfd_elf,size_dynamic_sections)): Set vn_file to basename
3704 of the bfd filename.
3706 2001-05-03 Andreas Jaeger <aj@suse.de>
3708 * elf64-gen.c (elf_generic_info_to_howto): Add unused attribute.
3709 (elf_generic_info_to_howto_rel): Likewise.
3710 * coff-alpha.c (reloc_nil): Likewise.
3711 (alpha_ecoff_bad_format_hook): Likewise.
3712 (alpha_adjust_reloc_out): Likewise.
3713 (alpha_bfd_reloc_type_lookup): Likewise.
3714 (alpha_convert_external_reloc): Likewise.
3715 * elf64-alpha.c (elf64_alpha_reloc_nil): Likewise.
3716 (elf64_alpha_reloc_bad): Likewise.
3717 (elf64_alpha_reloc_gpdisp): Likewise.
3718 (elf64_alpha_bfd_reloc_type_lookup): Likewise.
3719 (elf64_alpha_info_to_howto): Likewise.
3720 (elf64_alpha_add_symbol_hook): Likewise.
3721 (elf64_alpha_create_got_section): Likewise.
3722 (elf64_alpha_is_local_label_name): Likewise.
3723 (elf64_alpha_merge_ind_symbols): Likewise.
3724 * elf64-mips.c (mips_elf64_reloc_type_lookup): Likewise.
3725 (mips_elf64_get_reloc_upper_bound): Likewise.
3726 * nlm32-alpha.c (nlm_alpha_mangle_relocs): Likewise.
3727 (nlm_alpha_get_public_offset): Likewise.
3729 2001-05-02 Johan Rydberg <jrydberg@opencores.org>
3731 * elf32-openrisc.c (openrisc_elf_howto_table): Do not complain
3732 about overflow in R_OPENRISC_LO_16_IN_INSN and
3733 R_OPENRISC_HI_16_IN_INSN.Index: bfd/elf32-openrisc.c
3735 2001-04-30 H.J. Lu <hjl@gnu.org>
3737 * elf.c (_bfd_elf_link_hash_hide_symbol): Set dynindx to -1
3738 only for ELF_LINK_FORCED_LOCAL.
3739 * elf32-hppa.c (elf32_hppa_hide_symbol): Likewise.
3740 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Likewise.
3741 * elfxx-ia64.c (elfNN_ia64_hash_hide_symbol): Likewise.
3743 * elflink.h (elf_fix_symbol_flags): Set ELF_LINK_FORCED_LOCAL
3744 if the symbol has hidden or internal visibility.
3746 2001-04-30 Alan Modra <amodra@one.net.au>
3748 * elf32-hppa.c (final_link_relocate): Branch to .+8 for
3749 calls to undefined weak symbols.
3751 2001-04-30 Andreas Jaeger <aj@suse.de>, Andreas Schwab <schwab@suse.de>
3753 * elf64-x86-64.c (elf64_x86_64_relocate_section): Correct test for
3754 R_X86_64_GOTPCREL, don't use assignments instead of comparisons.
3756 2001-04-27 Andreas Jaeger <aj@suse.de>
3758 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_sections): Only swap
3759 out handled entries.
3760 (elf64_x86_64_finish_dynamic_symbol): Set up GOT entries.
3761 (elf64_x86_64_relocate_section): Fix GOTPCREL calculation.
3762 (elf64_x86_64_relocate_section): Merge entries for GOTPCREL and
3765 2001-04-27 Sean McNeil <sean@mcneil.com>
3767 * config.bfd: Add arm-vxworks target.
3768 * coff-arm (coff_arm_relocate_section): Add in symbol value to
3769 addend (fro VXworks targets).
3771 2001-04-26 H.J. Lu <hjl@gnu.org>
3773 * elf32-i386.c (elf_i386_check_relocs): Verify if r_symndx is
3776 2001-04-25 Frank Ch. Eigler <fche@redhat.com>
3778 * bfd-in.h (bfd_cache_close): Declare newly exported function.
3779 * bfd-in2.h: Regenerated.
3781 2001-04-24 Jakub Jelinek <jakub@redhat.com>
3783 * merge.c (struct sec_merge_hash_entry): Add alignment field.
3784 (struct sec_merge_hash): Remove alignment_power.
3785 (sec_merge_hash_newfunc): Clear alignment.
3786 (sec_merge_hash_lookup): Pass alignment as argument.
3787 Use hashp->root.next, not hashp->next to walk the hash chain.
3788 If a string already in the hashtable does not have required
3789 alignment, create a new hashtable entry.
3790 (sec_merge_init): Remove alignment_power argument.
3791 (sec_merge_add): Add alignment argument.
3792 (sec_merge_emit): Alignment is now a per-entity thing, not per
3794 (_bfd_merge_section): Sanity check even non-SEC_STRINGS sections
3795 for proper alignment.
3796 Pass alignment information to sec_merge_add.
3798 2001-04-24 Christian Groessler <cpg@aladdin.de>
3800 * coff-z8k.c (extra_case): added handler for R_DISP7, R_CALLR
3801 and R_REL16 reloc types; accept odd values for R_REL16 type
3803 2001-04-24 Johan Rydberg <jrydberg@opencores.org>
3805 * cpu-openrisc.c: New file.
3806 * elf32-openrisc.c: Likewise.
3808 * Makefile.am (ALL_MACHINES): Add cpu-openrisc.lo.
3809 (ALL_MACHINES_CFILES): Add cpu-openrisc.c.
3810 (BFD32_BACKENDS): Add elf32-openrisc.lo.
3811 (BFD32_BACKENDS_CFILES): Add elf32-openrisc.c.
3812 (cpu-openrisc.lo, elf32-openrisc.lo): New rules.
3813 * Makefile.in: Regenerated.
3814 * config.bfd: (openrisc-*-elf): New target.
3815 * configure.in (bfd_elf32_openrisc_vec): New vector.
3816 * configure: Regenerated.
3817 * libbfd.h: Regenerated.
3818 * bfd-in2.h: Regenerated.
3819 * reloc.c: Add OpenRISC relocations.
3820 * targets.c (bfd_elf32_openrisc_vec): Declare.
3821 (bfd_target_vect): Add bfd_elf32_openrisc_vec.
3822 * archures.c (enum bfd_architecture): Add bfd_arch_openrisc.
3823 (bfd_openrisc_arch): Declare.
3824 (bfd_archures_list): Add bfd_openrisc_arch.
3825 * elf.c (prep_headers): Add bfd_arch_openrisc.
3827 2001-04-23 Bo Thorsen <bo@suse.de>
3829 * elf64-x86-64.c: Add c++ vtable hack.
3830 Small whitespace and comment changes.
3832 2001-04-19 Andreas Jaeger <aj@suse.de>
3834 * elf64-x86-64.c (elf64_x86_64_plt0_entry): Fix instructions.
3835 (elf64_x86_64_plt_entry): Likewise.
3836 (elf64_x86_64_finish_dynamic_sections): Fix PLT0 generation.
3837 (elf64_x86_64_finish_dynamic_symbol): Fix PLT generation.
3839 2001-04-17 Hans-Peter Nilsson <hp@axis.com>
3841 * elf32-cris.c: Tweak comments related to dynamic linking.
3842 (cris_elf_relocate_section): When not creating shared object, fill
3843 in the .got table for any symbol not in the dynamic symbol table.
3844 (elf_cris_finish_dynamic_symbol): When not creating shared object,
3845 only emit a .got.rela reloc if the symbol is in the dynamic symbol
3847 (cris_elf_check_relocs): Use variable r_type in all places rather
3848 than the original expression. Add default case in switch for
3850 (elf_cris_size_dynamic_sections): Iterate over
3851 elf_cris_discard_excess_program_dynamics when not creating shared
3853 (elf_cris_discard_excess_dso_dynamics): Renamed from
3854 elf_cris_discard_copies. Correct typo, s/Rel/Rela/.
3855 (elf_cris_discard_excess_program_dynamics): New.
3857 2001-04-14 Mark Elbrecht <snowball3@bigfoot.com>
3859 * coffcode.h (coff_write_object_contents): Use
3860 bfd_coff_swap_filehdr_out instead of coff_swap_filehdr_out.
3862 2001-04-14 H.J. Lu <hjl@gnu.org>
3864 * bfd-in2.h: Regenerate.
3866 2001-04-14 Jakub Jelinek <jakub@redhat.com>
3868 * section.c (STD_SECTION): Add entsize.
3870 2001-04-13 H.J. Lu <hjl@gnu.org>
3872 * section.c (SEC_MERGE): Define new flag for merging.
3873 (SEC_STRINGS): Likewise.
3874 (entsize): New field.
3876 2001-04-13 Roger Sayle <roger@metaphorics.com>
3878 * coff-i386.c (TARGET_SYM): SEC_READONLY is an applicable section
3879 flag on pe-i386 targets.
3881 2001-04-13 Jakub Jelinek <jakub@redhat.com>
3883 * libbfd-in.h (_bfd_merge_section): New.
3884 (_bfd_write_merged_section): New.
3885 (_bfd_merged_section_offset): New.
3886 * libbfd.h: Rebuilt.
3887 * linker.c (_bfd_generic_link_output_symbols): Handle
3889 * aoutx.h (aout_link_write_symbols): Likewise.
3890 * pdp11.c (aout_link_write_symbols): Likewise.
3891 * elflink.h (elf_link_add_object_symbols): Call _bfd_merge_section.
3892 (elf_bfd_final_link): Adjust global symbols pointing into SEC_MERGE
3894 (elf_link_sec_merge_syms): New.
3895 (elf_link_input_bfd): Call _bfd_merged_section_offset
3896 and _bfd_write_merged_section.
3897 Handle discard_sec_merge.
3898 * elf-bfd.h (struct elf_link_hash_table): Add merge_info
3900 (struct bfd_elf_section_data): Likewise.
3901 * elf.c (_bfd_elf_make_section_from_shdr): Set SEC_MERGE and
3902 SEC_STRINGS section flags and entsize from their ELF counterparts.
3903 (_bfd_elf_link_hash_table_init): Initialize merge_info.
3904 (elf_fake_sections): Set SHF_MERGE, SHF_STRINGS and sh_entsize
3905 from their BFD counterparts.
3906 * merge.c: New file.
3907 * Makefile.am: Add strtab.lo.
3908 * Makefile.in: Rebuilt.
3910 2001-04-09 Hans-Peter Nilsson <hp@axis.com>
3912 * elflink.h (elf_fix_symbol_flags): For non-default visibilities,
3913 only hide symbols marked STV_INTERNAL or STV_HIDDEN.
3915 2001-04-05 Steven J. Hill <sjhill@cotw.com>
3917 * config.bfd (mips*el*-*-linux-gnu*): Use traditional little
3918 endian MIPS ELF target.
3919 * config.bfd (mips*-*-linux-gnu*): Use traditional big endian
3922 * configure.in (bfd_elf64_tradbigmips_vec): New. Traditional
3923 64bit big endian MIPS ELF target.
3924 (bfd_elf64_tradlittlemips_vec): New. Traditional 64bit little
3925 endian MIPS ELF target.
3926 * configure: Regenerated.
3928 * elf32-mips.c (IRIX_COMPAT): Handle traditional 64bit and
3929 little endian targets.
3930 (mips_elf_sym_is_global): Handle traditional targets.
3932 * elf64-mips.c (bfd_elf64_tradbigmips_vec): New. Traditional
3933 64bit big endian MIPS ELF target.
3934 (bfd_elf64_tradlittlemips_vec): New. Traditional 64bit little
3935 endian MIPS ELF target.
3937 * targets.c: (_bfd_target_vector): Add bfd_elf64_tradbigmips_vec
3938 and bfd_elf64_tradlittlemips_vec.
3940 2001-04-05 David Mosberger <davidm@hpl.hp.com>
3942 * elf32-i386.c (elf_i386_fake_sections): Treat ".reloc" as an
3943 ordinary "progbits" section.
3945 2001-04-04 Alan Modra <alan@linuxcare.com.au>
3947 * elflink.h (elf_fix_symbol_flags): Call elf_backend_hide_symbol
3948 when -Bsymbolic causes a symbol to no longer need a .plt entry.
3950 2001-04-03 David Mosberger <davidm@hpl.hp.com>
3952 * efi-app-ia32.c (ALIGN_SECTIONS_IN_FILE): Deleted.
3954 2001-03-30 H.J. Lu <hjl@gnu.org>
3956 * efi-app-ia32.c (PEI_TARGET_SUBSYSTEM): Rename from ...
3957 (PEI_DEFAULT_TARGET_SUBSYSTEM): This.
3959 2001-03-26 H.J. Lu <hjl@gnu.org>
3961 * elf32-gen.c (elf32_generic_link_add_symbols): New. Check
3962 if there are any relocations for generic ELF.
3963 (bfd_elf32_bfd_link_add_symbols): Defined to
3964 elf32_generic_link_add_symbols.
3965 * elf64-gen.c (elf64_generic_link_add_symbols): New. Check
3966 if there are any relocations for generic ELF.
3967 (bfd_elf64_bfd_link_add_symbols): Defined to
3968 elf64_generic_link_add_symbols.
3970 2001-03-23 Nick Clifton <nickc@redhat.com>
3972 * Makefile.am (BUILD_CFILES): New variable: List of C source
3973 files created in build directory.
3974 (BUILD_HFILES): New variable: List of header files created in
3977 (po/POTFILES.in): Replace rule with empty entry.
3978 (po/SRC-POTFILES.in): New rule: Create a list of source files
3979 in the source directory.
3980 (po/BLD-POTFILES.in): New rule: Create a list of source files
3981 in the build directory.
3982 (MOSTLYCLEAN): Do not delete source files created in build
3984 * Makefile.in: Regenerate.
3985 * configure.in: Insert SRC-POTFILES.in and BLD-POTFILES.in
3987 * configure: Regenerate.
3989 * po/Make-in: Replace occurrences of POTFILES with SRC-POTFILES
3991 Add .. to the search path when building bfd.pot.
3992 Delete POTFILES when performing distclean.
3993 Add comment describing why distclean is broken in maintainer mode.
3994 * po/POTFILES.in: Delete.
3995 * po/SRC-POTFILES.in: New file.
3996 * po/BLD-POTFILES.in: New file.
3997 * po/bfd.pot: Regenerate.
3999 2001-03-22 Hans-Peter Nilsson <hp@axis.com>
4001 * elf32-cris.c: Shlib and PIC support. PCREL tweaks.
4002 (elf_cris_discard_copies, elf_cris_adjust_gotplt_to_got,
4003 elf_cris_try_fold_plt_to_got, elf_cris_link_hash_newfunc,
4004 elf_cris_link_hash_table_create, elf_cris_adjust_dynamic_symbol,
4005 elf_cris_size_dynamic_sections, elf_cris_finish_dynamic_symbol,
4006 elf_cris_finish_dynamic_sections,elf_cris_hide_symbol): New
4008 (cris_elf_howto_table) <R_CRIS_8_PCREL, R_CRIS_16_PCREL,
4009 R_CRIS_32_PCREL>: Correct comments. Set pcrel_offset to false.
4010 <R_CRIS_COPY, R_CRIS_GLOB_DAT, R_CRIS_JUMP_SLOT, R_CRIS_RELATIVE,
4011 R_CRIS_16_GOT, R_CRIS_32_GOT, R_CRIS_16_GOTPLT, R_CRIS_32_GOTPLT,
4012 R_CRIS_32_GOTREL, R_CRIS_32_PLT_GOTREL, R_CRIS_32_PLT_PCREL>:
4013 New HOWTO members for new relocs.
4014 (cris_reloc_map): Map new relocs.
4015 (ELF_DYNAMIC_INTERPRETER): Define.
4016 (PLT_ENTRY_SIZE): Define.
4017 (elf_cris_plt0_entry, elf_cris_plt_entry, elf_cris_pic_plt0_entry,
4018 elf_cris_pic_plt_entry): New, PLT templates.
4019 (struct elf_cris_pcrel_relocs_copied, struct
4020 elf_cris_link_hash_entry, struct elf_cris_link_hash_table): New.
4021 (elf_cris_link_hash_traverse, elf_cris_hash_table): Define.
4022 (cris_final_link_relocate): Check that 16-bit GOT relocs have
4023 positive values. Adjust PCREL relocs to be relative to location
4025 (cris_elf_relocate_section): Handle relocations to dynamic
4026 objects. Handle new relocations. Call error handler when seeing
4027 non-PIC relocation for read-only sections while generating shared
4029 (cris_elf_check_relocs): Set reference counts for GOT and PLT
4031 (bfd_elf32_bfd_link_hash_table_create,
4032 elf_backend_adjust_dynamic_symbol,
4033 elf_backend_size_dynamic_sections,
4034 elf_backend_finish_dynamic_symbol,
4035 elf_backend_finish_dynamic_sections,
4036 elf_backend_create_dynamic_sections, bfd_elf32_bfd_final_link,
4037 elf_backend_hide_symbol, elf_backend_want_got_plt,
4038 elf_backend_plt_readonly, elf_backend_want_plt_sym,
4039 elf_backend_got_header_size, elf_backend_plt_header_size):
4042 * reloc.c: (BFD_RELOC_CRIS_COPY, BFD_RELOC_CRIS_GLOB_DAT,
4043 BFD_RELOC_CRIS_JUMP_SLOT, BFD_RELOC_CRIS_RELATIVE,
4044 BFD_RELOC_CRIS_32_GOT, BFD_RELOC_CRIS_16_GOT,
4045 BFD_RELOC_CRIS_32_GOTPLT, BFD_RELOC_CRIS_16_GOTPLT,
4046 BFD_RELOC_CRIS_32_GOTREL, BFD_RELOC_CRIS_32_PLT_GOTREL,
4047 BFD_RELOC_CRIS_32_PLT_PCREL): New relocs.
4048 * bfd-in2.h, libbfd.h: Regenerate.
4050 2001-03-21 Diego Novillo <dnovillo@redhat.com>
4052 (_bfd_mips_elf_relocate_section): Give a better error message when
4053 a relocation is not recognized.
4055 2001-03-21 Alan Modra <alan@linuxcare.com.au>
4057 * elf32-hppa.c (elf32_hppa_set_gp): Check sec->output_section
4058 non-NULL before attempting to dereference.
4060 2001-03-20 H.J. Lu <hjl@gnu.org>
4062 * configure.in: Remove the redundent AC_ARG_PROGRAM.
4063 * configure: Rebuild.
4065 2001-03-20 Andreas Schwab <schwab@suse.de>
4067 * elf32-m68k.c (elf_m68k_relocate_section): Don't need the
4068 relocation value when resolving a reference from a debugging
4071 2001-03-16 Scott Thomason <SThomaso@hii.com>
4073 * coff64-rs6000.c (xcoff64_swap_sym_out): Fix syntax errors.
4074 (xcoff64_swap_sym_out): Fix syntax errors.
4076 2001-03-16 Richard Sandiford <rsandifo@redhat.com>
4078 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix warning.
4080 2001-03-15 Alan Modra <alan@linuxcare.com.au>
4082 * elf32-hppa.c (elf32_hppa_link_hash_entry): Add maybe_pic_call.
4083 (hppa_link_hash_newfunc): Init it.
4084 (hppa_type_of_stub): Only use non-PIC to PIC call stub if caller
4085 section appears to be non-PIC.
4086 (final_link_relocate): Likewise.
4087 (elf32_hppa_adjust_dynamic_symbol): Set maybe_pic_call for any
4088 possible candidate function, and set pic_call for those that will
4089 only have a .plt entry for the PIC call stub.
4090 (hppa_handle_PIC_calls): Set maybe_pic_call.
4092 2001-03-12 DJ Delorie <dj@redhat.com>
4094 * elf32-sh.c (sh_elf_relocate_section): Only relocation
4095 R_SH_DIR8WP* relocs if they're against external symbols, else
4096 they're just for relaxing. Validate the reloc values.
4098 2001-03-12 Stefan Geuken <mail@stefan-geuken.de>
4100 * binary.c (bfd_external_binary_architecture): Declare.
4101 (binary_object_p): If bfd_external_binary_architecture is defined,
4102 set the architecture to this string.
4104 2001-03-11 Philip Blundell <philb@gnu.org>
4106 * elf32-arm.h (elf32_arm_finish_dynamic_symbol): Don't make PLT
4107 entries that could serve as a definition for a weak symbol.
4109 2001-03-08 Nick Clifton <nickc@redhat.com>
4111 * Most files: Update copyright notices using Perl script created
4112 by Kevin Buettner <kevinb@redhat.com>.
4114 2001-03-07 Nick Clifton <nickc@redhat.com>
4116 * elf32-arm.h (elf32_arm_final_link_relocate): Conditionalise
4117 prior patch on ! defined OLD_ARM_ABI.
4119 2001-03-07 Andreas Jaeger <aj@suse.de>
4121 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix handling of
4122 some relocation values.
4124 2001-03-06 Nick Clifton <nickc@redhat.com>
4126 * elf32-arm.h (elf32_arm_final_link_relocate): Clear bit zero
4127 of offset in BLX(1) instruction.
4128 * coff-arm.c (coff_arm_relocate_section): Clear bit zero of
4129 offset in BLX(1) instruction.
4132 2001-03-06 Nick Clifton <nickc@redhat.com>
4134 * coff-arm.c (coff_arm_reloc_type_lookup): Add
4135 BFD_RELOC_THUMB_PCREL_BLX.
4137 2001-03-06 Igor Shevlyakov <igor@windriver.com>
4139 * archures.c (bfd_default_scan): Add Coldfire CPUs.
4140 * bfd-in2.h: Regenerate.
4141 * cpu-m68k.c: Add Coldfire CPUs for arch table.
4142 * ieee.c (ieee_write_processor): Set proper id for
4145 2001-03-01 D.J. Barrow <djbarrow@de.ibm.com,barrow_dj@yahoo.com>
4147 * configure.in: Add s390 target.
4148 * configure: Regenerate.
4150 2001-02-28 Andreas Jaeger <aj@suse.de>
4152 * elf64-x86-64.c (elf64_x86_64_relocate_section): Add relocation
4155 2001-02-28 Philip Blundell <pb@futuretv.com>
4157 * elf32-arm.h: Update mentions of renamed EF_xx constants.
4158 (elf32_arm_print_private_bfd_data): Handle ARM EABI version 2.
4160 2001-02-27 H.J. Lu <hjl@gnu.org>
4162 * aoutx.h (NAME(aout,bfd_free_cached_info)): Return true if
4163 abfd->tdata.aout_data == NULL.
4165 2001-02-27 Alan Modra <alan@linuxcare.com.au>
4167 * elf32-hppa.c: Correct field selector in stub comments.
4168 (clobber_millicode_symbols): Formatting fix.
4170 * configure.in: Bump version to 2.11.90.
4171 * configure: Regenerate.
4172 * Makefile.am (CFILES): Rename to SOURCE_CFILES.
4173 (CFILES): $SOURCE_CFILES + generated C files.
4174 (POTFILES): Include $HFILES not $SOURCE_HFILES.
4176 * Makefile.in: Regenerate.
4177 * doc/Makefile.in: This too.
4179 2001-02-26 Timothy Wall <twall@cygnus.com>
4181 * elfxx-ia64.c (elfNN_ia64_aix_add_symbol_hook): Remove obsolete
4184 2001-02-26 Nick Clifton <nickc@redhat.com>
4186 * coffcode.h (styp_to_sec_flags) [COFF_WITH_PE version]: Tidy
4187 up, replacing multiple if statements with a switch.
4188 (handle_COMDAT): New function.
4190 2001-02-26 H.J. Lu <hjl@gnu.org>
4192 * coffcode.h (styp_to_sec_flags) [COFF_WITH_PE version]: Issue
4193 a warning for section flags we do not handle instead of
4196 2001-02-26 Andreas Jaeger <aj@suse.de>
4198 * elf64-x86-64.c (x86_64_elf_howto_table): Fix order of entries.
4200 2001-02-22 Timothy Wall <twall@cygnus.com>
4202 * config.bfd (targ_cpu): Add vectors for ia64-*-aix* (aka Monterey).
4203 * configure.in: Add objects for elf64_ia64_aix vectors.
4204 * configure: Regenerated.
4205 * configure.host: Recognize ia64-*-aix*.
4206 * elfxx-ia64.c: Add hooks for ELF64 on AIX5. Define new vectors
4207 for AIX. AIX5 requires most relocations to be dynamic (*all*
4208 binaries are somewhat similar to shared libraries).
4209 * targets.c: Add elf64_ia64_aix vectors.
4211 2001-02-21 David Mosberger <davidm@hpl.hp.com>
4213 * cpu-ia64-opc.c (elf64_ia64_operands}: Fix typo: error string for
4214 C8 said "1" instead of "8". Clarify error string for IMM22:
4215 "signed integer" instead of just "integer".
4217 2001-02-20 Andreas Jaeger <aj@suse.de>
4219 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_symbol): Don't make
4220 PLT entries that could serve as a definition for a weak symbol.
4222 2001-02-19 Jakub Jelinek <jakub@redhat.com>
4224 * elf32-sparc.c (elf32_sparc_finish_dynamic_symbol): Don't make PLT
4225 entries that could serve as a definition for a weak symbol.
4226 * elf64-sparc.c (sparc64_elf_finish_dynamic_symbol): Likewise.
4228 2001-02-18 David O'Brien <obrien@FreeBSD>
4230 * configure.in: Recognize FreeBSD/arm, FreeBSD/PowerPC, and treat
4231 FreeBSD/i386-CURRENT differently until I can figure out the needed
4233 * configure: Regenerate.
4234 * config.bfd: Recognize FreeBSD/x86-64, FreeBSD/ia64, FreeBSD/arm,
4235 FreeBSD/PowerPC, and FreeBSD/sparc64.
4237 2001-02-18 lars brinkhoff <lars@nocrew.org>
4239 * Makefile.am: Add PDP-11 a.out target.
4240 * config.bfd: Likewise.
4241 * configure.in: Likewise.
4242 * targets.c: Likewise.
4243 * archures.c: Likewise.
4244 * bfd-in2.h: Likewise. Add PDP-11 relocations.
4245 * libbfd.h: Add PDP-11 relocations.
4246 * reloc.c: Likewise.
4247 * cpu-pdp11.c: New file.
4248 * pdp11.c: New file.
4250 * libaout.h (GET_WORD) [ARCH_SIZE==16]: Define.
4251 (GET_SWORD) [ARCH_SIZE==16]: Likewise.
4252 (GET_SWORD) [ARCH_SIZE==16]: Likewise.
4253 (PUT_WORD) [ARCH_SIZE==16]: Likewise.
4254 (GET_MAGIC): New macro.
4255 (PUT_MAGIC): Likewise.
4256 * aout-target.h (MY(object_p)): Use GET_MAGIC to read magic word.
4258 2001-02-18 Jim Kingdon <jkingdon@engr.sgi.com>
4260 * irix-core.c (irix_core_core_file_p): Set the architecture (GDB
4261 multiarch needs it).
4263 2001-02-18 H.J. Lu <hjl@gnu.org>
4265 * elflink.h (elf_link_input_bfd): Ignore invalid section symbol
4268 2001-02-18 Kazu Hirata <kazu@hxi.com>
4270 * vms-misc.c: Fix formatting.
4272 2001-02-16 Kazu Hirata <kazu@hxi.com>
4274 * vms.c: Fix formatting.
4276 2001-02-14 H.J. Lu <hjl@gnu.org>
4278 * elf.c (elf_find_function): New function.
4279 (_bfd_elf_find_nearest_line): Call elf_find_function () to find
4280 the file name and function name.
4282 2001-02-14 Nick Clifton <nickc@redhat.com>
4284 * ecoff.c (bfd_debug_section): Update to initialise new fields in
4287 * Makefile.am (BFD32_BACKENDS_CFILES): Remove peigen.c
4288 (BFD64_BACKENDS): Add pepigen.c
4289 Add rules to create peigen.c and pepigen.c from peXXigen.c.
4291 * Makefile.in: Regenerate.
4292 * configure: Regenerate.
4293 * po/POTFILES.in: Regenerate.
4294 * po/bfd.pot: Regenerate.
4296 2001-02-14 H.J. Lu <hjl@gnu.org>
4298 * libcoff-in.h (pe_tdata): Add members target_subsystem and
4299 force_minimum_alignment.
4301 2001-02-14 Bo Thorsen <bo@suse.de>
4303 * elf64-x86-64.c: Small formatting fixes and rearrangements of code.
4304 (elf64_86_64_size_info): Struct added to fix a problem
4305 with the hashtable string entries.
4306 (elf64_x86_64_adjust_dynamic_symbol): Add generation of .got.plt.
4307 (elf64_x86_64_size_dynamic_sections): A FIXME removed.
4308 (elf64_x86_64_size_dynamic_sections): Fix a dynamic entry and
4309 remove the FIXME for this.
4310 (elf64_x86_64_adjust_dynamic_symbol): Fix check for unneeded .plt
4311 section. Also removed the FIXME for it.
4312 (x86_64_elf_howto_table): Use bfd_elf_generic_reloc.
4313 (ELF_DYNAMIC_INTERPRETER): Fix the name of the dynamic linker.
4314 (elf64_x86_64_finish_dynamic_sections): Enable .got.plt writing.
4316 2001-02-13 Richard Henderson <rth@redhat.com>
4318 * elfxx-ia64.c (elfNN_ia64_final_link): Set __gp if required
4319 and not user provided.
4321 2001-02-13 Kazu Hirata <kazu@hxi.com>
4323 * vms.c (vms_print_symbol): Remove unreachable code.
4325 * rs6000-core.c: Fix formatting.
4327 2001-02-13 David Mosberger <davidm@hpl.hp.com>
4329 * peicode.h (coff_swap_filehdr_out) [COFF_IMAGE_WITH_PE]: Define
4330 as _bfd_XXi_only_swap_filehdr_out.
4331 (pe_mkobject) [PEI_FORCE_MINIMUM_ALIGNMENT]: Set
4332 pe->force_minimum_alignment to TRUE.
4333 (pe_mkobject) [PEI_TARGET_SUBSYSTEM]: Set pe->target_subsystem to
4334 PEI_TARGET_SUBSYSTEM.
4335 (pe_print_private_bfd_data): Call
4336 _bfd_XX_print_private_bfd_data_common() instead of
4337 _bfd_pe_print_private_bfd_data_common().
4338 (pe_bfd_copy_private_bfd_data): Call
4339 _bfd_XX_bfd_copy_private_bfd_data_common() instead of
4340 _bfd_pe_bfd_copy_private_bfd_data_common().
4341 (coff_bfd_copy_private_section_data): Define as
4342 _bfd_XX_bfd_copy_private_section_data instead of
4343 _bfd_pe_bfd_copy_private_section_data.
4344 (coff_get_symbol_info): Define as _bfd_XX_get_symbol_info instead
4345 of a _bfd_pe_get_symbol_info.
4349 * peXXigen.c: Renamed from peigen.c.
4350 (COFF_WITH_XX): Define this macro (will get expanded into
4351 COFF_WITH_pep or COFF_WITH_pe, depending on whether this is being
4352 compiled as peigen.c or pepigen.c.
4353 [COFF_WITH_pep]: Include "coff/ia64.h" instead of "coff/i386.h" to
4354 define the canonical PEP structures and definitions.
4355 (_bfd_XXi_swap_aouthdr_out): If pe->force_minimum_alignment is in
4356 effect, enforce minimum file and section alignments. If
4357 extra->Subsystem is IMAGE_SUBSYSTEM_UNKNOWN, set it to
4358 pe->target_subsystem (this defaults to IMAGE_SUBSYSTEM_UNKNOWN,
4359 so, by default, this is a no-op).
4361 * libpei.h: Rename COFF_WITH_PEP to COFF_WITH_pep.
4362 (_bfd_XX_bfd_copy_private_bfd_data_common): Add macros to map
4363 _bfd_XXfoo to _bfd_pepfoo if COFF_WIT_PEP is defined and to
4364 _bfd_pefoo if it's not defined. Use these macros to define
4367 * libcoff.h (pe_tdata): Add members target_subsystem and
4368 force_minimum_alignment.
4370 * efi-app-ia64.c (COFF_WITH_pep): Rename COFF_WITH_PEP to
4372 (PEI_TARGET_SUBSYSTEM): Rename from PEI_DEFAULT_TARGET_SUBSYSTEM.
4374 * configure.in (bfd_efi_app_ia64_vec): Use pepigen.lo instead of
4377 * coff-ia64.c: Rename COFF_WITH_PEP to COFF_WITH_pep.
4378 (AOUTSZ): Rename PEP64AOUTSZ and PEP64AOUTHDR to PEPAOUTSZ and
4381 * Makefile.in (BFD64_BACKENDS): Mention pepigen.lo.
4382 (BFD64_BACKENDS_CFILES): Mention pepigen.c
4383 (peigen.c): Add rule to generate from peXXigen.c.
4385 (pepigen.lo): List dependencies for pepigen.lo.
4387 2001-02-13 Alan Modra <alan@linuxcare.com.au>
4389 * elf32-hppa.c (elf32_hppa_set_gp): Handle weak $global$. If
4390 $global$ referenced but not defined, set its value here.
4392 2001-02-09 Bo Thorsen <bo@suse.de>
4394 * elf64-x86-64.c (elf64_x86_64_check_relocs): Set .rela.got section
4396 (elf64_x86_64_check_relocs): Write R_X86_64_GOTPCREL GOT entry
4398 (elf64_x86_64_relocate_section): Fix formatting.
4399 (elf64_x86_64_relocate_section): Fix addend for relocation of
4400 R_X86_64_(8|16|32|PC8|PC16|PC32).
4402 2001-02-12 Jan Hubicka <jh@suse.cz>
4404 * elf64-x86-64.c (x86_64_elf_howto): Fix name of R_X86_64_GOTPCREL.
4406 2001-02-11 H.J. Lu <hjl@gnu.org>
4408 * elflink.h (elf_bfd_final_link): Use file_align for SYMTAB
4411 2001-02-11 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
4413 * elf32-mips.c (mips_elf_create_dynamic_relocation): Undo patch
4414 from 2000-10-13. Do not add the symbol's value for R_MIPS_REL32
4415 relocations against dynsym symbols.
4417 * elf32-mips.c (elf_mips_howto_table): Fix the comment on
4418 the R_MIPS_26 relocation.
4419 (mips_elf_calculate_relocation): Use (p + 4) instead of p for
4420 the R_MIPS_26 relocation.
4421 (mips_elf_perform_relocation): Fix the comment on the R_MIPS16_26
4423 * elf64-mips.c (mips_elf64_howto_table_rel): Fix the comment on
4424 the R_MIPS_26 relocation.
4425 (mips_elf64_howto_table_rela): Likewise.
4427 * elf32-mips.c (struct mips_elf_link_hash_entry): Added no_fn_stub
4428 member to mark symbols that have non-CALL relocations against
4430 (mips_elf_link_hash_newfunc): Initialize no_fn_stub.
4431 (mips_elf_calculate_relocation): Handle R_MIPS_CALL16 like
4433 (_bfd_mips_elf_check_relocs): Set no_fn_stub for a symbol if a
4434 non-CALL relocation against it is encountered.
4435 (_bfd_mips_elf_copy_indirect_symbol): Merge no_fn_stub as well.
4436 (_bfd_mips_elf_adjust_dynamic_symbol): Only create a stub if
4437 no_fn_stub is not set.
4439 * elf32-mips.c (mips_elf_output_extsym): Get the output section
4440 information from the real symbol for indirect ones.
4441 Check no_fn_stub to find out if a symbol has a function stub
4444 2001-02-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
4446 * Makefile.am (stamp-lib): ranlib the libbfd.a in the build directory.
4447 * Makefile.in: Regenerate.
4449 2001-02-09 David Mosberger <davidm@hpl.hp.com>
4451 * elfxx-ia64.c (is_unwind_section_name): New function. Returns
4452 true if section name is an unwind table section name.
4453 (elfNN_ia64_additional_program_headers): Count each unwind section
4455 (elfNN_ia64_modify_segment_map): Install one unwind program header
4456 for each unwind separate section. Note: normally the linker
4457 script merges the unwind sections that go into a single segment,
4458 so this still generates at most one unwind program header per
4461 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Accept any section
4462 name for SHT_IA_64_UNWIND, not just .IA_64.unwind.
4463 (elfNN_ia64_fake_sections): Mark sections with names that start
4464 with .IA_64.unwind but not with .IA_64.unwind_info as an IA-64
4467 * elfxx-ia64.c (elfNN_ia64_final_write_processing): New function.
4468 Use it to make sh_info in unwind section point to the text section
4471 2001-02-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
4473 * Makefile.am: Add linux target for S/390.
4474 * archures.c: Likewise.
4475 * bfd-in2.h: Likewise.
4476 * config.bfd: Likewise.
4477 * configure.in: Likewise.
4479 * libbfd.h: Likewise.
4480 * targets.c: Likewise.
4481 * cpu-s390.c: New file.
4482 * elf32-s390.c: New file.
4483 * elf64-s390.c: New file.
4485 2001-02-09 Nick Clifton <nickc@redhat.com>
4487 * peigen.c (_bfd_pe_get_symbol_info): Suppress addition of
4488 ImageBase. This has already been done by coff_swap_hdr_in.
4490 2001-02-09 Jakub Jelinek <jakub@redhat.com>
4492 * elf64-sparc.c (sparc64_elf_copy_private_bfd_data): New function.
4494 2001-02-09 Jakub Jelinek <jakub@redhat.com>
4496 * elf64-sparc.c (sparc64_elf_check_relocs): Don't trust reloc_count.
4497 (sparc64_elf_relocate_section): Likewise.
4499 2001-02-09 Mark Kettenis <kettenis@gnu.org>
4501 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Treat R_SPARC_UA32
4502 similar to R_SPARC_32.
4503 * elf64-sparc.c (sparc64_elf_howto_table): Likewise.
4505 2001-02-08 H.J. Lu <hjl@gnu.org>
4507 * elf32-i386.c (elf_i386_check_relocs): Reserve R_386_PC32
4508 relocation entries for weak definitions when building DSO with
4511 2001-02-08 Richard Henderson <rth@redhat.com>
4513 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Respect weakness
4514 before visibility. Locally defined protected symbols are not
4517 2001-02-08 Geoffrey Keating <geoffk@redhat.com>
4519 * config.bfd: Enable coff64 for rs6000-*. Patch from
4520 <hzoli@austin.ibm.com>.
4522 2001-02-07 Mark Elbrecht <snowball3@bigfoot.com>
4524 * coffgen.c (coff_find_nearest_line): If stabs info is successfully
4525 found, do not attempt to find dwarf2 info before returning.
4527 2001-02-07 Jakub Jelinek <jakub@redhat.com>
4529 * elflink.h (is_global_symbol_definition): Rename to
4530 is_global_data_symbol_definition and have it reject function
4532 (elf_link_is_defined_archive_symbol): Use renamed function.
4534 2001-02-07 Todd Vierling <tv@wasabisystems.com>
4536 * libbfd-in.h (bfd_target_vector): Change extern array to pointer.
4537 * libbfd.h (bfd_target_vector): Likewise.
4538 * targets.c (bfd_target_vector): Rename to _bfd_target_vector and
4539 make static; create pointer reference named bfd_target_vector.
4540 (_bfd_target_vector_entries): Calculate this based on the array
4541 typed _bfd_target_vector.
4543 2001-02-06 H.J. Lu <hjl@gnu.org>
4545 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Only hidden and
4546 internal symbols are not dynamic.
4547 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise.
4549 2001-02-06 Nick Clifton <nickc@redhat.com>
4551 * Makefile.am (BFD64_BACKENDS_CFILES): Remove elf64-ia64.c, so
4552 that it will not be pulled into the list of files that make up
4554 * Makefile.in: Regenerate.
4555 * po/bfd.pot: Regenerate.
4557 2001-02-06 H.J. Lu <hjl@gnu.org>
4559 * peicode.h (coff_swap_filehdr_in): Remove the e_magic
4561 (pe_bfd_object_p): Rewrite with external_PEI_DOS_hdr and
4562 external_PEI_IMAGE_hdr.
4564 2001-02-06 Kazu Hirata <kazu@hxi.com>
4566 * elf-m10200.c: Fix formatting.
4568 2001-02-04 Nick Clifton <nickc@redhat.com>
4570 * elf32-v850.c (v850_elf_reloc): Do not convert reloc addend to PC
4571 rel, it will be handled later on.
4573 2001-02-02 Fred Fish <fnf@ninemoons.com>
4575 * Makefile.in: Fix typo.
4577 2001-02-01 Kazu Hirata <kazu@hxi.com>
4579 * elf-m10300.c: Fix formatting.
4581 2001-01-30 Alan Modra <alan@linuxcare.com.au>
4583 * elf64-hppa.c (elf64_hppa_elf_get_symbol_type): New function.
4584 (elf_backend_get_symbol_type): Define.
4585 (elf64_hppa_object_p): Set architecture and machine from elf
4588 2001-01-30 Curtis L. Janssen <cljanss@ca.sandia.gov>
4590 * elf64-alpha.c (elf64_alpha_find_nearest_line): Query dwarf2
4593 2001-01-26 Richard Henderson <rth@redhat.com>
4595 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Return false
4596 for non-default visibility.
4597 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise, but
4598 delete ugly macro and replace with pretty function.
4600 2001-01-25 Mark Elbrecht <snowball3@bigfoot.com>
4602 * coff-go32.c: Update copyright.
4603 * coff-stgo32.c: Likewise.
4604 * coff-go32.c (COFF_LONG_FILENAMES): Define.
4605 * coff-stgo32.c (COFF_LONG_FILENAMES): Likewise.
4606 * coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Remove .bss entry.
4607 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
4609 2001-01-25 Kazu Hirata <kazu@hxi.com>
4611 * bfd-in2.h: Rebuild.
4612 * libbfd.h: Likewise.
4614 2001-01-23 H.J. Lu <hjl@gnu.org>
4616 * bfd-in2.h: Rebuild.
4618 2001-01-23 H.J. Lu <hjl@gnu.org>
4620 * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_buf)
4621 is NULL or PRIV(vms_rec) is outside of the buffer.
4623 2001-01-23 Kazu Hirata <kazu@hxi.com>
4625 * coff64-rs6000.c: Fix formatting.
4626 * coff-arm.c: Likewise.
4627 * coffgen.c: Likewise.
4628 * cofflink.c: Likewise.
4629 * coff-mcore.c: Likewise.
4630 * coff-mips.c: Likewise.
4631 * coff-pmac.c: Likewise.
4632 * coff-ppc.c: Likewise.
4633 * coff-rs6000.c: Likewise.
4634 * elf32.c: Likewise.
4635 * elf32-fr30.c: Likewise.
4636 * elf32-i370.c: Likewise.
4637 * elf32-i860.c: Likewise.
4638 * elf32-m32r.c: Likewise.
4639 * elf32-m68k.c: Likewise.
4640 * elf32-mcore.c: Likewise.
4641 * elf32-ppc.c: Likewise.
4642 * elf32-sh.c: Likewise.
4643 * elf32-v850.c: Likewise.
4644 * elf64-alpha.c: Likewise.
4645 * elf64-sparc.c: Likewise.
4646 * elflink.c: Likewise.
4647 * elflink.h: Likewise.
4648 * elf-m10200.c: Likewise.
4649 * elf-m10300.c: Likewise.
4650 * elfxx-ia64.c: Likewise.
4652 * aoutx.h: Fix formatting.
4654 * bfd-in2.h: Likewise.
4655 * bfd-in.h: Likewise.
4656 * cpu-i386.c: Likewise.
4657 * cpu-m68hc11.c: Likewise.
4658 * dwarf2.c: Likewise.
4659 * elf64-x86-64.c: Likewise.
4660 * format.c: Likewise.
4661 * freebsd.h: Likewise.
4663 * hp300hpux.c: Likewise.
4664 * hppabsd-core.c: Likewise.
4665 * hpux-core.c: Likewise.
4667 2001-01-22 Bo Thorsen <bo@suse.de>
4669 * elf64-x86-64.c: Added PIC support for X86-64.
4670 (elf64_x86_64_link_hash_newfunc): Function added.
4671 (elf64_x86_64_link_hash_table_create): Likewise.
4672 (elf64_x86_64_check_relocs): Likewise.
4673 (elf64_x86_64_gc_mark_hook): Likewise.
4674 (elf64_x86_64_gc_sweep_hook): Likewise.
4675 (elf64_x86_64_adjust_dynamic_symbol): Likewise.
4676 (elf64_x86_64_size_dynamic_sections): Likewise.
4677 (elf64_x86_64_discard_copies): Likewise.
4678 (elf64_x86_64_finish_dynamic_symbol): Likewise.
4679 (elf64_x86_64_finish_dynamic_sections): Likewise.
4680 (elf64_x86_64_relocate_section): Add relocation of PIC sections.
4682 2001-01-21 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
4684 * Makefile.am (install-data-local): Make use of $(DESTDIR).
4685 * Makefile.in: Regenerate.
4687 2001-01-21 Kazu Hirata <kazu@hxi.com>
4689 * coff-a29k.c: Fix formatting.
4691 2001-01-19 H.J. Lu <hjl@gnu.org>
4693 * elf32-i386.c (elf_i386_check_relocs): Report files with bad
4694 relocation section names.
4695 (elf_i386_relocate_section): Report files with bad relocation
4696 section names and return false.
4698 2001-01-17 Bo Thorsen <bo@suse.de>
4700 * targets.c: Alphabetize list of xvecs.
4702 2001-01-14 Alan Modra <alan@linuxcare.com.au>
4704 * config.bfd: Add linux target variant for elfxx-hppa.
4705 * configure.in: Recognize bfd_elf32_hppa_linux_vec and
4706 bfd_elf64_hppa_linux_vec.
4707 * configure: Regenerate.
4708 * elf64-hppa.c: Include elf64-target.h again to support linux
4710 (elf64_hppa_post_process_headers): Set ELFOSABI_LINUX for linux.
4711 * elf32-hppa.c: Include elf32-target.h again to support linux
4713 (elf32_hppa_post_process_headers): New function.
4714 (elf_backend_post_process_headers): Define.
4715 * targets.c (bfd_target_vector): Add bfd_elf64_hppa_linux_vec and
4716 bfd_elf32_hppa_linux_vec.
4718 * elf32-hppa.c (elf32_hppa_link_hash_table): Add text_segment_base,
4719 and data_segment_base fields.
4720 (elf32_hppa_link_hash_table_create ): Init them.
4721 (elf32_hppa_check_relocs): Update comments.
4722 (hppa_record_segment_addr): New function.
4723 (elf32_hppa_relocate_section): Call it.
4724 (final_link_relocate): Handle R_PARISC_SEGREL32.
4725 (elf32_hppa_final_link): New function.
4726 (bfd_elf32_bfd_final_link): Define to call it.
4727 (hppa_unwind_entry_compare): New function.
4728 * cache.c (bfd_open_file): Create files in write+read mode.
4730 * elf-hppa.h (elf_hppa_howto_table): Set bitsize value for
4731 SEGREL32 and numerous other relocs. Change duplicate
4732 R_PARISC_NONE relocs to R_PARISC_UNIMPLEMENTED.
4734 * opncls.c (bfd_fdopenr): Add parens like the comment says around
4737 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Don't create
4738 .plt entries for DT_INIT and DT_FINI.
4739 (elf32_hppa_finish_dynamic_sections): Remove special handling of
4740 DT_INIT and DT_FINI.
4742 * elf64-hppa.c (elf64_hppa_finish_dynamic_symbol): Use 16-bit
4743 offsets for stub .plt access if wide mode. Check offset in range.
4745 2001-01-13 Nick Clifton <nickc@redhat.com>
4747 * elf32-fr30.c (fr30_elf_howto_table): Remove spurious blank
4750 * coffcode.h (coff_canonicalize_reloc): Remove spurious blank
4753 2001-01-12 Alan Modra <alan@linuxcare.com.au>
4755 * configure.in ([bfd_elf64_x86_64_vec]): Set target64.
4756 * configure: Regenerate.
4758 2001-01-11 Peter Targett <peter.targett@arccores.com>
4760 * bfd-in2.h (bfd_architecture): Add bfd_mach_arc_5,
4761 bfd_mach_arc_6, bfd_mach_arc_7, bfd_mach_arc_8 for ARC variants.
4762 * cpu-arc.c (arch_info_struct): Add entries for variants.
4763 (bfd_arc_arch) Set default to bfd_mach_arc_5.
4764 (arc_get_mach) Don't assume machine names prefixed arc- before
4766 * elf32-arc.c (arc_elf_object_p): Set machine number based on new
4768 (arc_elf_final_write_processing) Likewise.
4769 (ELF_MACHINE_CODE) Use EM_ARC.
4771 2001-01-10 Nick Clifton <nickc@redhat.com>
4773 * coff-arm.c (LOCAL_LABEL_PREFIX): Change definition to "".
4775 2001-01-07 Philip Blundell <philb@gnu.org>
4777 * README: Replace `bug-gnu-utils@gnu.org' with
4778 `bug-binutils@gnu.org'.
4780 2001-01-04 Kazu Hirata <kazu@hxi.com>
4782 * som.c: Fix formatting.
4784 2001-01-03 Kazu Hirata <kazu@hxi.com>
4786 * ecoffswap.h: Fix formatting.
4787 * elf-bfd.h: Likewise.
4788 * elfarm-nabi.c: Likewise.
4789 * elfarm-oabi.c: Likewise.
4790 * elfcode.h: Likewise.
4791 * elfcore.h: Likewise.
4792 * elflink.c: Likewise.
4793 * elflink.h: Likewise.
4794 * elfxx-ia64.c: Likewise.
4795 * elfxx-target.h: Likewise.
4796 * libbfd.c: Likewise
4797 * linker.c: Likewise.
4798 * lynx-core.c: Likewise.
4800 2001-01-02 Kazu Hirata <kazu@hxi.com>
4802 * pc532-mach.c: Fix formatting.
4803 * pe-arm.c: Likewise.
4804 * pe-i386.c: Likewise.
4805 * pe-mips.c: Likewise.
4806 * pe-ppc.c: Likewise.
4807 * pe-sh.c: Likewise.
4808 * pei-mips.c: Likewise.
4809 * pei-sh.c: Likewise.
4810 * peicode.h: Likewise.
4811 * ppcboot.c: Likewise.
4812 * ptrace-core.c: Likewise.
4814 2001-01-01 Kazu Hirata <kazu@hxi.com>
4816 * reloc.c: Fix formatting.
4817 * riscix.c: Likewise.
4818 * rs6000-core.c: Likewise.
4819 * xcoff-target.h: Likewise.
4821 2000-12-29 Hans-Peter Nilsson <hp@bitrange.com>
4823 * elfcode.h (elf_object_p): Also restore the bfd mach field on
4824 error, by calling bfd_default_set_arch_mach with incoming
4827 2000-12-26 Kazu Hirata <kazu@hxi.com>
4829 * vaxnetbsd.c: Fix formatting.
4830 * versados.c: Likewise.
4831 * vms-gsd.c: Likewise.
4832 * vms-hdr.c: Likewise.
4833 * vms-misc.c: Likewise.
4835 2000-12-25 Alexandre Oliva <aoliva@redhat.com>
4837 * archive.c (coff_write_armap): Don't write more than symbol_count
4838 `archive_member_file_ptr's.
4840 2000-12-25 Kazu Hirata <kazu@hxi.com>
4842 * vms-tir.c: Fix formatting.
4844 2000-12-23 Kazu Hirata <kazu@hxi.com>
4846 * vms.c: Fix formatting.
4849 2000-12-21 Santeri Paavolainen <santtu@ssh.com>
4851 * vms-hdr.c: Include alloca.h if HAVE_ALLOCA_H is defined.
4853 * peicode.h (pe_ILF_object_p): Add const to import of TARGET_LITTLE_SYM.
4855 * elf32-m32r.c (m32r_elf_generic_reloc): Add cast to avoid (void *)
4858 * elf32-fr30.c: Add casts to avoid (void *) arithmetic.
4860 * coffcode.h (styp_to_sec_flags): Add empty statement after label.
4862 2000-12-21 Richard Sandiford <rsandifo@redhat.com>
4864 * libbfd.c (bfd_get_bits): Added
4865 (bfd_put_bits): Likewise
4866 * bfd-in.h: Declared the above.
4867 * bfd-in2.h: Regenerated.
4869 2000-12-20 Kazu Hirata <kazu@hxi.com>
4871 * targets.c: Fix formatting.
4872 * tekhex.c: Likewise.
4873 * trad-core.c: Likewise.
4875 2000-12-19 Kazu Hirata <kazu@hxi.com>
4877 * sco5-core.c: Fix formatting.
4878 * section.c: Likewise.
4879 * sparclinux.c: Likewise.
4880 * sparclynx.c: Likewise.
4881 * sparcnetbsd.c: Likewise.
4883 * stabs.c: Likewise.
4884 * stab-syms.c: Likewise.
4885 * sunos.c: Likewise.
4887 * sysdep.h: Likewise.
4889 2000-12-18 Nick Clifton <nickc@redhat.com>
4891 * coff-arm.c (EXTRA_S_FLAGS): Only define if not already
4893 * epoc-pe-arm.c (EXTRA_S_FLAGS): Define.
4894 * epoc-pei-arm.c (EXTRA_S_FLAGS): Define.
4896 2000-12-18 Nick Clifton <nickc@redhat.com>
4898 * vms-misc.c (_bfd_vms_get_record): Add default case to
4901 2000-12-15 Miloslav Trmac <mitr@volny.cz>
4903 * elfcore.h (elf_core_file_p): Move to the start of the program
4904 headers before attempting to read them.
4906 2000-12-14 Kazu Hirata <kazu@hxi.com>
4908 * peigen.c: Fix formatting.
4912 2000-12-13 Kazu Hirata <kazu@hxi.com>
4914 * peigen.c: Fix formatting.
4916 2000-12-12 Jim Wilson <wilson@redhat.com>
4918 * elfxx-ia64.c (get_dyn_sym_info): Cast %p argument to void *.
4920 2000-12-08 Mark Salter <msalter@redhat.com>
4922 * binary.c (binary_set_section_contents): Ignore sections
4925 2000-12-12 Kazu Hirata <kazu@hxi.com>
4927 * m68klinux.c: Fix formatting.
4928 * m68knetbsd.c: Likewise.
4929 * mipsbsd.c: Likewise.
4930 * netbsd-core.c: Likewise.
4931 * netbsd.h: Likewise.
4932 * newsos3.c: Likewise.
4933 * nlm32-alpha.c: Likewise.
4934 * nlm32-i386.c: Likewise.
4935 * nlm32-ppc.c: Likewise.
4936 * nlm32-sparc.c: Likewise.
4937 * nlmcode.h: Likewise.
4938 * nlmswap.h: Likewise.
4939 * nlm-target.h: Likewise.
4940 * ns32knetbsd.c: Likewise.
4942 2000-12-10 Fred Fish <fnf@be.com>
4944 * elflink.h (elf_link_output_extsym): Don't complain about undefined
4945 symbols in shared objects if allow_shlib_undefined is true.
4947 2000-12-12 Nick Clifton <nickc@redhat.com>
4949 * cpu-sh.c: Fix formattng.
4950 * elf.c: Fix formattng.
4951 * elf32-mips.c: Fix formattng.
4952 * elf32-sh.c: Fix formattng.
4953 * elf64-alpha.c: Fix formattng.
4955 2000-12-09 Nick Clifton <nickc@redhat.com>
4957 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Pass
4958 dwarf2_find_line_info as last parameter to invocation of
4959 _bfd_dwarf2_find_nearest_line.
4960 * elf32-arm.h (elf32_arm_find_nearest_line): Pass
4961 dwarf2_find_line_info as last parameter to invocation of
4962 _bfd_dwarf2_find_nearest_line.
4964 2000-12-08 Mark Elbrecht <snowball3@bigfoot.com>
4966 * Makefile.am (BFD32_BACKENDS): Move dwarf2.lo from here...
4967 (BFD_LIBS): ...to here.
4968 (BFD32_BACKENDS_CFILES): Move dwarf2.c from here...
4969 (BFD_LIBS_CFILES): ...to here.
4970 * Makefile.in: Regenerate.
4971 * configure.in: Remove dwarf.lo from the elf shell variable.
4972 * configure: Regenerate.
4973 * libcoff-in.h (coff_tdata): Add pointer dwarf2_find_line_info.
4974 * libcoff.h: Regenerate.
4975 * coffgen.c (coff_find_nearest_line): Call
4976 _bfd_dwarf2_find_nearest_line.
4977 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Add parameter. Update
4979 (read_abbrevs): Likewise
4980 (decode_line_info): Likewise.
4981 (parse_comp_unit): Likewise.
4982 (comp_unit_find_nearest_line): Likewise.
4983 * libbfd-in.h (_bfd_dwarf2_find_nearest_line): Update prototype.
4984 * libbfd.h: Regenerate.
4985 * elf.c (_bfd_elf_find_nearest_line): Update call.
4986 * elf-bfd.h (elf_obj_tdata): Change dwarf2_find_line_info to type PTR.
4987 * dwarf2.c (concat_filename): Use IS_ABSOLUTE_PATH.
4988 * coffcode.h (STYP_XCOFF_DEBUG, STYP_DEBUG_INFO): New macros.
4989 (sec_to_styp_flags): Use them. Handle DWARF2 sections.
4990 (styp_to_sec_flags): Handle DWARF2 sections.
4991 * elf32-arm.h (elf32_arm_find_nearest_line): Add parameter to call
4992 to _bfd_find_nearest_line.
4993 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Add parameter to
4994 call to _bfd_find_nearest_line.
4996 2000-12-08 Kazu Hirata <kazu@hxi.com>
4998 * coffgen.c: Fix formatting.
4999 * elf-m10300.c: Likewise.
5000 * elf32-i386.c: Likewise.
5001 * elf32-i960.c: Likewise.
5002 * elf32-m68k.c: Likewise.
5003 * elf32-mcore.c: Likewise.
5004 * elf32-ppc.c: Likewise.
5005 * elf32-sh.c: Likewise.
5006 * elf32-sparc.c: Likewise.
5007 * elf32-v850.c: Likewise.
5008 * elf64-alpha.c: Likewise.
5009 * elf64-hppa.c: Likewise.
5010 * elf64-mips.c: Likewise.
5011 * elf64-sparc.c: Likewise.
5013 2000-12-07 Kazu Hirata <kazu@hxi.com>
5015 * elf32-ppc.c: Fix formatting.
5016 * elf64-x86-64.c: Likewise.
5018 2000-12-06 Ulf Carlsson <ulfc@engr.sgi.com>
5020 From Ralf Baechle <ralf@gnu.org>
5022 * elf32-mips.c (elf32_mips_merge_private_bfd_data): Always permit
5023 BFDs containing no sections or empty .text, .data or .bss sections
5024 to be merged, regardless of their flags.
5026 2000-12-06 Kazu Hirata <kazu@hxi.com>
5028 * elf32-m32r.c: Fix formatting.
5029 * elf32-m68hc11.c: Likewise.
5030 * elf32-m68hc12.c: Likewise.
5031 * elf32-m68k.c: Likewise.
5032 * elf32-mcore.c: Likewise.
5033 * elf32-pj.c: Likewise.
5034 * elf32-ppc.c: Likewise.
5036 2000-12-05 Kazu Hirata <kazu@hxi.com>
5038 * elf32-fr30.c: Fix formatting.
5039 * elf32-hppa.c: Likewise.
5040 * elf32-i370.c: Likewise.
5041 * elf32-i386.c: Likewise.
5042 * elf32-i860.c: Likewise.
5043 * elf32-i960.c: Likewise.
5045 2000-12-03 Kazu Hirata <kazu@hxi.com>
5047 * elf32-arm.h: Fix formatting.
5048 * elf32-avr.c: Likewise.
5049 * elf32-cris.c: Likewise.
5050 * elf32-d10v.c: Likewise.
5051 * elf32-d30v.c: Likewise.
5052 * elf-hppa.h: Likewise.
5053 * elf-m10200.c: Likewise.
5054 * elf-m10300.c: Likewise.
5056 2000-12-01 Chris Demetriou <cgd@sibyte.com>
5058 * aoutx.h (NAME(aout,machine_type)): Add bfd_mach_mips32 and
5059 bfd_mach_mips32_4k. Update FIXME comment.
5060 * archures.c (bfd_mach_mips32): New constant.
5061 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
5062 the latter, renumber it.
5063 * bfd-in2.h (bfd_mach_mips32): New constant.
5064 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
5065 the latter, renumber it.
5066 * cpu-mips.c (I_mips32): New constant.
5067 (I_mips4K, I_mips32_4k): Rename the former to the latter.
5068 (arch_info_struct): Add bfd_mach_mips32 entry, replace
5069 bfd_mach_mips4K entry with bfd_mach_mips32_4k entry.
5070 * elf32-mips.c (elf_mips_isa): Add E_MIPS_ARCH_32 case.
5071 (elf_mips_mach): Likewise. Also, replace E_MIPS_MACH_MIPS32
5072 with E_MIPS_MACH_MIPS32_4K.
5073 (_bfd_mips_elf_final_write_processing): Replace
5074 bfd_mach_mips4K with bfd_mach_mips32_4k case, add
5075 bfd_mach_mips32 case.
5076 (_bfd_mips_elf_merge_private_bfd_data): Generalize ISA mixing
5077 comparison with support for MIPS32.
5078 (_bfd_mips_elf_print_private_bfd_data): Print ISA name for
5081 * aoutx.h (NAME(aout,machine_type)): Add cases for
5082 bfd_mach_mips5 and bfd_mach_mips64.
5083 * archures.c (bfd_mach_mips5, bfd_mach_mips64): New constants.
5084 * bfd-in2.h (bfd_mach_mips5, bfd_mach_mips64): Likewise.
5085 * cpu_mips.c (I_mips5, I_mips64): New definitions.
5086 (arch_info_struct): Add entries for bfd_mach_mips5 and
5088 * elf32-mips.c (elf_mips_isa, elf_mips_mach,
5089 _bfd_mips_elf_print_private_bfd_data): Add cases for
5090 E_MIPS_ARCH_5 and E_MIPS_ARCH_64.
5091 (_bfd_mips_elf_final_write_processing): Add cases for
5092 bfd_mach_mips5 and bfd_mach_mips64.
5094 * aoutx.h (NAME(aout,machine_type)): Add a
5095 bfd_mach_mips_sb1 case.
5096 * archures.c (bfd_mach_mips_sb1): New constant.
5097 * bfd-in2.h (bfd_mach_mips_sb1): New constant.
5098 * cpu-mips.c (I_sb1): New constant.
5099 (arch_info_struct): Add entry for bfd_mach_mips_sb1.
5100 * elf32-mips.c (elf_mips_mach): Add case for
5102 (_bfd_mips_elf_final_write_processing): Add case for
5105 2000-12-01 Joel Sherrill <joel@OARcorp.com>
5107 * config.bfd (arm-*-rtems*, a29k-*rtems*): New targets.
5108 (sparc*-*-rtemself*, sparc*-*-rtemsaout*): New targets.
5109 (sparc*-*-rtems*): Switched from a.out to ELF.
5111 2000-11-30 Jan Hubicka <jh@suse.cz>
5113 * Makefile.am (BFD64_BACKENDS): Add elf64-x86-64.lo
5114 BFD64_BACKENDS_CFILES): Add elf64-x86-64.c
5115 (elf64-x86-64.lo): Add dependencies.
5116 * archures.c (DESCRIPTION): Add bfd_mach_x86_64,
5117 bfd_mach_x86_64_intel_syntax.
5118 * elf.c (prep_headers): Use EM_x86_64 for 64bit output.
5119 * config.bfd (x86_64): Add.
5120 * configure.in: Add support for bfd_elf64_x86_64_vec.
5121 * cpu-i386.c (bfd_x86_64_arch_intel_syntax, bfd_x86_64_arch): Add.
5122 (bfd_i386_arch, i8086_ar): Link in.
5123 * elf64-x86-64.c: New file.
5124 * reloc.c (ENUMDOC): Add BFD_RELOC_X86_64*.
5125 * targets.c (bfd_elf64_x86_64_vec): Add.
5126 (bfd_target_vect): Add bfd_elf64_x86_64_vec.
5128 2000-11-30 Kazu Hirata <kazu@hxi.com>
5130 * xcofflink.c: Fix formatting.
5132 2000-11-28 Kazu Hirata <kazu@hxi.com>
5134 * aoutx.h: Fix formatting.
5135 * bfd-in.h: Likewise.
5136 * bfd-in2.h: Likewise.
5137 * cache.c: Likewise.
5138 * cisco-core.c: Likewise.
5139 * coff64-rs6000.c: Likewise.
5140 * coffcode.h: Likewise.
5141 * coffswap.h: Likewise.
5142 * corefile.c: Likewise.
5143 * elf32-mips.c: Likewise.
5145 2000-11-27 Kazu Hirata <kazu@hxi.com>
5147 * aout-adobe.c: Fix formatting.
5148 * coff64-rs6000.c: Likewise.
5149 * coffgen.c: Likewise.
5150 * cofflink.c: Likewise.
5152 2000-11-27 Philip Blundell <pb@futuretv.com>
5154 * libcoff-in.h (coff_tdata): Add `strings_written' flag.
5155 (obj_coff_strings_written): New accessor macro for above.
5156 * libcoff.h: Regenerate.
5157 * cofflink.c (_bfd_coff_final_link): Say that we wrote the
5159 * coffcode.h (coff_write_object_contents): No need to write out
5160 the string table if it's already been done.
5162 2000-11-22 Philip Blundell <pb@futuretv.com>
5164 * cofflink.c (_bfd_coff_generic_relocate_section): Don't object to
5165 weak undefined symbols.
5167 2000-11-24 Nick Clifton <nickc@redhat.com>
5169 * archures.c (bfd_mach_arm_5TE): Define.
5170 (bfd_mach_arm+XScale): Define.
5171 * bfd-in2.h: Regenerate.
5173 * coff-arm.c (coff_arm_reloc_type_lookup): Accept
5174 BFD_RELOC_ARM_PCREL_BLX.
5176 * coffcode.h (coff_set_flags): Set flags for 5t, 5te and
5177 XScale machine numbers.
5179 * config.bfd (xscale-elf): Add target.
5180 (xscale-coff): Add target.
5182 * cpu-arm.c: Add xscale machine name.
5183 Add v5t, v5te and XScale machine numbers.
5185 2000-11-23 Kazu Hirata <kazu@hxi.com>
5187 * aix386-core.c: Fix formatting.
5189 2000-11-22 Jim Wilson <wilson@redhat.com>
5191 * coff-ia64.c (howto_table): Use EMPTY_HOWTO.
5192 (in_reloc_p): Add ATTRIBUTE_UNUSED to unused parameters.
5193 * cpu-ia64-opc.c (ins_rsvd, ext_rsvd, ins_const, ext_const): Likewise.
5194 (ins_imms_scaled): Initialize sign_bit at function entry.
5195 (elf64_ia64_operands): Add missing initializers.
5196 * elfxx-ia64.c (elfNN_ia64_reloc, elfNN_ia64_reloc_type_lookup,
5197 elfNN_ia64_info_to_howto, elfNN_ia64_fake_sections,
5198 elfNN_ia64_add_symbol_hook, elfNN_ia64_is_local_label_name,
5199 elfNN_ia64_local_hash_table_init, get_fptr, get_pltoff,
5200 elfNN_ia64_adjust_dynamic_symbol): Add ATTRIBUTE_UNUSED for unused
5202 (elfNN_ia64_info_to_howto): Initialize free_relocs, free_contents,
5203 and free_extsyms at function entry.
5204 (elfNN_add_symbol_hook): Add unsigned cast to bfd_get_gp_size result.
5205 (elfNN_ia64_create_dynamic_sections): Delete unused local h.
5206 (get_got): Delete unused local srel.
5207 (elfNN_ia64_check_relocs): Initialize dynrel_type when declared.
5208 (elfNN_ia64_relocate_section): Delete unused local dynindx.
5210 2000-11-21 Kazu Hirata <kazu@hxi.com>
5212 * coff-a29k.c: Fix formatting.
5213 * coff-h8500.c: Likewise.
5214 * coff-i960.c: Likewise.
5215 * coff-ppc.c: Likewise.
5216 * coff-rs6000.c: Likewise.
5217 * coff-stgo32.c: Likewise.
5218 * coff-tic54x.c: Likewise.
5219 * coff-w65.c: Likewise.
5220 * cpu-h8500.c: Likewise.
5221 * cpu-hppa.c: Likewise.
5222 * cpu-ns32k.c: Likewise.
5223 * ecoff.c: Likewise.
5224 * ecofflink.c: Likewise.
5226 2000-11-21 Nick Clifton <nickc@redhat.com>
5228 * elf32-sh.c (sh_elf_reloc_loop): Fix compile time warning, and
5229 remove possibility of infinite loop.
5231 2000-11-20 Kazu Hirata <kazu@hxi.com>
5233 * aix386-core.c: Fix formatting.
5234 * aout-adobe.c: Likewise.
5235 * aout-arm.c: Likewise.
5236 * aout-encap.c: Likewise.
5237 * aout-ns32k.c: Likewise.
5238 * aout-target.h: Likewise.
5239 * aout-tic30.c: Likewise.
5240 * aoutf1.h: Likewise.
5241 * aoutx.h: Likewise.
5242 * archive.c: Likewise.
5243 * bfd-in.h: Likewise.
5244 * bfd-in2.h: Likewise.
5248 2000-11-17 H.J. Lu <hjl@gnu.org>
5250 * elfxx-ia64.c (elfNN_ia64_size_dynamic_sections): Don't create
5251 pltoff entries for DT_INIT and DT_FINI.
5252 (elfNN_ia64_final_link): Don't set DT_INIT/FINI entries.
5253 (elfNN_ia64_finish_dynamic_sections): Don't fill in DT_INIT/FINI
5256 2000-11-16 Richard Henderson <rth@redhat.com>
5258 * elfxx-ia64.c (elfNN_ia64_check_relocs): Handle IPLT relocs.
5259 (allocate_dynrel_entries): Likewise.
5260 (elfNN_ia64_relocate_section): Likewise. Set REL addends correctly.
5261 (set_pltoff_entry): Likewise.
5262 (ia64_howto_table): Remove R_IA64_SEGBASE, and R_IA64_EPLT[ML]SB
5263 (elfNN_ia64_reloc_type_lookup): Likewise.
5264 (elfNN_ia64_install_value): Likewise.
5265 (elfNN_ia64_relocate_section): Likewise.
5266 * reloc.c (BFD_RELOC_IA64_SEGBASE): Remove.
5267 (BFD_RELOC_IA64_EPLTMSB, BFD_RELOC_IA64_EPLTLSB): Remove.
5269 2000-11-16 Kazu Hirata <kazu@hxi.com>
5271 * cpu-a29k.c: Fix formatting.
5272 * cpu-alpha.c: Likewise.
5273 * cpu-arm.c: Likewise.
5274 * cpu-avr.c: Likewise.
5275 * cpu-d10v.c: Likewise.
5276 * cpu-h8500.c: Likewise.
5277 * cpu-hppa.c: Likewise.
5278 * cpu-i370.c: Likewise.
5279 * cpu-i386.c: Likewise.
5280 * cpu-i960.c: Likewise.
5281 * cpu-ia64-opc.c: Likewise.
5282 * cpu-ia64.c: Likewise.
5283 * cpu-m32r.c: Likewise.
5284 * cpu-m68hc11.c: Likewise.
5285 * cpu-m68hc12.c: Likewise.
5286 * cpu-m68k.c: Likewise.
5287 * cpu-m88k.c: Likewise.
5288 * cpu-mips.c: Likewise.
5289 * cpu-ns32k.c: Likewise.
5290 * cpu-pj.c: Likewise.
5291 * cpu-powerpc.c: Likewise.
5292 * cpu-sh.c: Likewise.
5293 * cpu-sparc.c: Likewise.
5294 * cpu-tic54x.c: Likewise.
5295 * cpu-v850.c: Likewise.
5296 * cpu-vax.c: Likewise.
5297 * cpu-w65.c: Likewise.
5298 * cpu-we32k.c: Likewise.
5299 * cpu-z8k.c: Likewise.
5300 * dwarf1.c: Likewise.
5301 * dwarf2.c: Likewise.
5303 2000-11-15 Kazu Hirata <kazu@hxi.com>
5305 * coff-arm.c: Fix formatting.
5306 * coff-ppc.c: Likewise.
5307 * coff-rs6000.c: Likewise.
5308 * coff-sh.c: Likewise.
5309 * coff-sparc.c: Likewise.
5310 * coff-tic30.c: Likewise.
5311 * coff-tic54x.c: Likewise.
5312 * coff-tic80.c: Likewise.
5313 * coff-w65.c: Likewise.
5314 * coff-we32k.c: Likewise.
5315 * coff-z8k.c: Likewise.
5317 2000-11-15 Richard Henderson <rth@redhat.com>
5319 * elf64-alpha.c (elf64_alpha_check_relocs): Create the reloc
5320 section with the same ALLOC|LOAD flags as the source section.
5322 2000-11-14 Jakub Jelinek <jakub@redhat.com>
5324 * elf64-alpha.c (elf64_alpha_relax_opt_call): Only check bits used
5325 by STO_ALPHA constants.
5327 2000-11-14 Kazu Hirata <kazu@hxi.com>
5329 * coff-pmac.c: Fix formatting.
5330 * coff-ppc.c: Likewise.
5332 2000-11-13 H.J. Lu <hjl@gnu.org>
5334 * elflink.h (elf_link_add_object_symbols): Also add indirect
5335 symbols for common symbols with the default version.
5337 2000-11-09 Philip Blundell <pb@futuretv.com>
5339 * section.c (STD_SECTION): Set gc_mark flag.
5341 2000-11-11 Kazu Hirata <kazu@hxi.com>
5343 * coff-i960.c: Likewise.
5344 * coff-m68k.c: Likewise.
5345 * coff-m88k.c: Likewise.
5346 * coff-mcore.c: Likewise.
5347 * coff-mips.c: Likewise.
5349 2000-11-11 Bernd Schmidt <bernds@cygnus.co.uk>
5351 * elf32-sh.c (sh_elf_relocate_section): Ignore R_SH_NONE relocs.
5353 2000-11-10 Kazu Hirata <kazu@hxi.com>
5355 * coff-h8300.c: Fix formatting.
5356 * coff-h8500.c: Likewise.
5357 * coff-i386.c: Likewise.
5358 * coff-i860.c: Likewise.
5359 * coff-i960.c: Likewise.
5360 * coff-ia64.c: Likewise.
5362 2000-11-09 Kazu Hirata <kazu@hxi.com>
5364 * archive.c: Fix formatting.
5365 * archures.c: Likewise.
5367 2000-11-07 Richard Henderson <rth@redhat.com>
5369 * elfxx-ia64.c (elf64_ia64_final_link): New local unwind_output_sec.
5370 Set it before bfd_elf64_bfd_final_link call. Use it after the call.
5371 * section.c (bfd_set_section_contents): Call memcpy if
5372 section->contents set and location not equal to contents plus offset.
5374 2000-11-08 Kazu Hirata <kazu@hxi.com>
5376 * bfd-in.h: Fix formatting.
5377 * bfd-in2.h: Likewise.
5379 * binary.c: Likewise.
5381 * coff-a29k.c: Likewise.
5382 * coff-alpha.c: Likewise.
5383 * coff-apollo.c: Likewise.
5384 * coff-aux.c: Likewise.
5386 2000-11-07 Kazu Hirata <kazu@hxi.com>
5388 * aix386-core.c: Fix formatting.
5389 * aoutf1.h: Likewise.
5390 * aoutx.h: Likewise.
5391 * archures.c: Likewise.
5392 * armnetbsd.c: Likewise.
5394 2000-11-07 Alan Modra <alan@linuxcare.com.au>
5396 * coff-h8300.c (special): Adjust reloc address.
5398 2000-11-06 Steve Ellcey <sje@cup.hp.com>
5400 * archures.c (bfd_mach_ia64_elf64, bfd_mach_ia64_elf32): Add defines
5401 to differentiate elf32 and elf64 on ia64.
5402 * bfd-in2.h: Regenerate.
5403 * config.bfd: Add target for "ia64*-*-hpux*".
5404 * configure.in: Add bfd_elf32_ia64_big_vec to selvecs switch.
5405 * configure: Regenerate.
5406 * cpu-ia64.c (bfd_ia64_elf32_arch): Add elf32 arch info structure.
5407 * targets.c: Add bfd_target bfd_elf32_ia64_big_vec.
5409 * Makefile.am: Make elf32-ia64.c and elf64-ia64.c derived objects
5410 from elfxx-ia64.c. Add depenency rules for making elf32-ia64.lo.
5411 * Makefile.in: Regnerate.
5412 * elf64-ia64.c: Deleted.
5413 * elfxx-ia64.c: New file, paramaterized version of elf64-ia64.c.
5415 2000-11-06 Kazu Hirata <kazu@hxi.com>
5417 * aout-adobe.c: Fix formatting.
5418 * aout-arm.c: Likewise.
5419 * aout-cris.c: Likewise.
5420 * aout-encap.c: Likewise.
5421 * aout-ns32k.c: Likewise.
5422 * aout-target.h: Likewise.
5423 * aout-tic30.c: Likewise.
5425 2000-11-05 Philip Blundell <philb@gnu.org>
5427 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Always permit
5428 BFDs containing no sections to be merged, regardless of their flags.
5430 2000-11-04 Philip Blundell <philb@gnu.org>
5432 * elf32-arm.h (elf32_arm_relocate_section): Suppress error message
5433 if a relocation for an undefined symbol also results in an
5436 2000-11-06 Christopher Faylor <cgf@cygnus.com>
5438 * config.bfd: Add support for Sun Chorus.
5440 2000-11-05 David O'Brien <obrien@FreeBSD.org>
5442 * configure.in: Recognize alpha-*-freebsd*.
5443 * configure: Regenerate.
5445 2000-11-02 Luciano Gemme <ishitawa@yahoo.com>
5447 * srec.c (CHUNK): Rename to DEFAULT_CHUNK.
5448 (Chunk): New global variable set by a parameter in objcopy.c.
5449 (S3Forced): New global variable set by a parameter in
5451 (srec_set_section_contents): If S3Forced is true, always generate
5453 (srec_write_section): Use 'Chunk' to limit maximum length of S
5456 2000-11-02 Per Lundberg <plundis@chaosdev.org>
5458 * config.bfd: Add support for i[3456]86-chaosdev-storm-chaos.
5459 * Makefile.in: Regenerate.
5460 * bfd-in2.h: Regenerate.
5461 * po/bfd.pot: Regenerate.
5463 2000-10-31 Philip Blundell <philb@gnu.org>
5465 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Only handle
5466 EF_SOFT_FLOAT if it is defined.
5468 2000-10-27 Philip Blundell <philb@gnu.org>
5470 * elf32-arm.h (elf32_arm_copy_private_bfd_data): Don't refuse
5471 attempts to mix PIC code with non-PIC, just mark the output as
5472 being position dependent.
5473 (elf32_arm_merge_private_bfd_data): Likewise. Print an error
5474 message for EF_SOFT_FLOAT mismatches. Display diagnostics for
5475 all mismatches, not just the first one.
5477 2000-10-25 Chris Demetriou <cgd@sibyte.com>
5479 * ieee.c (ieee_archive_p): Plug one of many possible
5480 memory leaks in error handling.
5482 2000-10-20 Jakub Jelinek <jakub@redhat.com>
5484 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data,
5485 elf32_sparc_object_p, elf32_sparc_final_write_processing):
5487 * elf64-sparc.c (sparc64_elf_merge_private_bfd_data,
5488 sparc64_elf_object_p): Support v9b.
5489 * archures.c: Declare v8plusb and v9b machines.
5491 * cpu-sparc.c: Ditto.
5493 2000-10-16 Geoffrey Keating <geoffk@shoggoth.cygnus.com>
5495 * elf64-sparc.c (sparc64_elf_relocate_section): Clear the location
5498 * elf32-ppc.c (SYMBOL_REFERENCES_LOCAL): New macro.
5499 (SYMBOL_CALLS_LOCAL): New macro.
5500 (ppc_elf_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL.
5501 (ppc_elf_check_relocs): Use SYMBOL_REFERENCES_LOCAL.
5502 (ppc_elf_finish_dynamic_symbol): Use SYMBOL_REFERENCES_LOCAL.
5503 (ppc_elf_relocate_section): Use flag variable to determine
5504 whether the relocation refers to a local symbol.
5505 Test whether a PLTREL24 reloc will produce a reloc by looking
5506 to see whether a PLT entry was made.
5508 2000-10-14 Geoffrey Keating <geoffk@shoggoth.cygnus.com>
5510 * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Don't make PLT
5511 entries that could serve as a definition for a weak symbol.
5513 2000-10-13 Ulf Carlsson <ulfc@engr.sgi.com>
5515 From Ralf Baechle <ralf@gnu.org>
5517 * elf32-mips.c (mips_elf_create_dynamic_relocation): New argument
5518 local_p. Add symbol value only for non-R_MIPS_REL32 relocations
5519 against local symbols.
5520 (_bfd_mips_elf_finish_dynamic_sections): Undo patch from 2000-10-01.
5522 2000-10-12 Alan Modra <alan@linuxcare.com.au>
5524 * section.c (struct sec): Add kept_section.
5525 (struct bfd_comdat_info): Remove sec, we can use above.
5526 (STD_SECTION): Add initializer.
5527 (bfd_make_section_anyway): Init here too.
5529 * bfd-in2.h: Regenerate.
5531 * elflink.h (elf_link_add_object_symbols): Remove unnecessary
5533 (elf_link_input_bfd): Set all asection->symbol->value's here, and
5534 fudge values for discarded link-once section symbols.
5536 * elf64-hppa.c: Include alloca-conf.h
5538 2000-10-11 Alan Modra <alan@linuxcare.com.au>
5540 * elf.c (swap_out_syms): Revert 2000-10-07 changes.
5542 * ieee.c (ieee_make_empty_symbol): Oops, bfd_zalloc needs another arg.
5544 2000-10-10 Alan Modra <alan@linuxcare.com.au>
5546 * ieee.c (ieee_make_empty_symbol): Use bfd_zalloc, not bfd_zmalloc.
5548 2000-10-10 Tom Rix <trix@redhat.com>
5550 * section.c (bfd_make_section_anyway): Release newsect ptr when
5551 newsect->symbol fails to alloc. Use bfd_release instead of free.
5553 2000-10-09 Richard Henderson <rth@cygnus.com
5555 * elf64-ia64.c (elf64_ia64_unwind_entry_compare_bfd): New.
5556 (elf64_ia64_unwind_entry_compare): New.
5557 (elf64_ia64_final_link): Sort the .IA_64.unwind section.
5559 2000-10-07 Alan Modra <alan@linuxcare.com.au>
5561 * elflink.h (size_dynamic_sections): Don't create various tags if
5562 .dynstr is excluded from the link. Don't set first dynsym entry
5563 if dynsymcount is zero.
5564 (elf_bfd_final_link): Don't try to swap out dynamic syms if
5565 .dynsym excluded from the link. Don't try to write any dynamic
5566 sections excluded from the link.
5568 * elf.c (swap_out_syms): Handle global section symbols.
5570 2000-10-05 DJ Delorie <dj@redhat.com>
5572 * peigen.c (_bfd_pei_swap_scnhdr_out): note extended relocs
5573 * coffcode.h (coff_set_alignment_hook): read extended reloc count
5574 (coff_write_relocs): write extended reloc count
5575 (coff_write_object_contents): account for extended relocs
5577 2000-10-05 Jim Wilson <wilson@cygnus.com>
5579 * elf-bfd.h (struct elf_backend_data): Add elf_backend_section_flags
5581 * elf.c (_bfd_elf_make_section_from_shdr): Call the
5582 elf_backend_section_flags function.
5583 * elf64-ia64.c (elf64_ia64_section_from_shdr): Delete flag conversion
5585 (elf64_ia64_section_flags): New function containing flag conversion
5587 (elf_backend_section_flags): Define to elf64_ia64_section_flags.
5588 * elfxx-target.h (elf_backend_section_flags): Define.
5589 (elfNN_bed): Initialize elf_backend_section_flags field.
5591 2000-10-02 Alan Modra <alan@linuxcare.com.au>
5593 * elf32-hppa.c (elf32_hppa_check_relocs): Correct call to
5594 _bfd_elf32_gc_record_vtable. Correct a comment.
5596 2000-10-01 Ulf Carlsson <ulfc@engr.sgi.com>
5598 From Ralf Baechle <ralf@gnu.org>
5600 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_sections): Mark gld
5601 produces binaries with got[1] = 0x80000001 to differenciate them
5602 for the dynamic linker from the broken binaries produced by old
5605 2000-09-30 Petr Sorfa <petrs@sco.com>
5607 * elf.c (elfcore_grok_pstatus): Check for size of pxstatus_t.
5608 (elfcore_grok_lwpstatus): Check for size of lwpxstatus_t.
5609 * configure.in: Add check for pxstatus_t and lwpxstatus_t.
5610 * configure: Regenerate.
5612 2000-09-27 Hans-Peter Nilsson <hp@axis.com>
5614 Define two bfd_targets for absence and presence of leading
5615 underscore on symbols. Make sure to only link same kind.
5616 * elf32-cris.c (cris_elf_object_p,
5617 cris_elf_final_write_processing, cris_elf_print_private_bfd_data,
5618 cris_elf_merge_private_bfd_data): New.
5619 (elf_backend_object_p, elf_backend_final_write_processing,
5620 bfd_elf32_bfd_print_private_bfd_data,
5621 bfd_elf32_bfd_merge_private_bfd_data): Define.
5622 <Target vector definition>: Include elf32-target.h twice with
5623 different macro settings:
5624 (TARGET_LITTLE_SYM): First as bfd_elf32_cris_vec, then as
5625 bfd_elf32_us_cris_vec.
5626 (TARGET_LITTLE_NAME): First as "elf32-cris", then "elf32-us-cris".
5627 (elf_symbol_leading_char): First as 0, then '_'.
5628 (INCLUDED_TARGET_FILE): Define for second include of elf32-target.h.
5629 * config.bfd (cris-*-*): Add bfd_elf32_us_cris_vec to targ_selvecs.
5630 * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vector.
5631 * configure: Regenerate.
5632 * targets.c: Declare bfd_elf32_us_cris_vec.
5633 * po/bfd.pot: Regenerate.
5635 2000-09-29 Momchil Velikov <velco@fadata.bg>
5637 * elf32-arm.h (arm_add_to_rel): Correctly adjust the addend for
5638 R_ARM_THM_PC22 relocations.
5640 2000-09-29 NIIBE Yutaka <gniibe@chroot.org>
5642 * elflink.h (elf_link_add_object_symbols): Don't bfd_release runpath.
5644 2000-09-29 Momchil Velikov <velco@fadata.bg>
5646 * elf.c (elf_fake_sections): Do not mark the section SHT_NOBITS if
5647 is has the SEC_HAS_CONTENTS flag set.
5649 2000-09-28 �Örjan Friberg <orjanf@axis.com>
5650 Hans-Peter Nilsson <hp@axis.com>
5652 * aout-cris.c (N_TXTADDR): Define.
5654 2000-09-28 John David Anglin <dave@hiauly1.hia.nrc.ca>
5656 * som.c: Include alloca-conf.h.
5657 * Makefile.am: "make dep-am"
5658 * Makefile.in: Regenerate.
5660 2000-09-27 Alan Modra <alan@linuxcare.com.au>
5662 * elf32-hppa.c (plt_stub): New.
5663 (PLT_STUB_ENTRY): Define.
5664 (elf32_hppa_link_hash_table): Change multi_subspace to packed
5665 boolean. Add need_plt_stub, has_12bit_branch and has_17bit_branch.
5666 (elf32_hppa_link_hash_table_create): Init to suit.
5667 (elf32_hppa_check_relocs): Set has_12bit_branch and
5668 has_17bit_branch as appropriate.
5669 (elf32_hppa_adjust_dynamic_symbol): Set need_plt_stub for
5670 non-local functions.
5671 (elf32_hppa_size_dynamic_sections): Correct setting of reltext.
5672 Add space for plt_stub as needed.
5673 (elf32_hppa_finish_dynamic_symbol): Point .plt entries for global
5674 functions at plt_stub.
5675 (elf32_hppa_finish_dynamic_sections): Write plt_stub.
5676 (elf32_hppa_create_dynamic_sections): Leave .plt executable.
5678 * elf32-hppa.h (elf32_hppa_size_stubs): Add group_size param.
5679 * elf32-hppa.c (elf32_hppa_size_stubs): Likewise. Use it instead
5680 of fixed size, and if negative, disable handling of input sections
5681 before stub section. Set up default stub group size depending
5682 on detected branch relocs.
5683 (hppa_build_one_stub): Use lrsel and rrsel for import stubs to
5684 ensure different offsets from sym_value aren't rounded to
5685 different 2k blocks. Use lrsel and rrsel for other stubs too for
5686 consistency rather than necessity.
5687 (elf32_hppa_check_relocs): Handle R_PARISC_DIR14F.
5688 (final_link_relocate): Likewise.
5689 (elf32_hppa_relocate_section): Likewise.
5691 * elf-hppa.h (elf_hppa_howto_table): Add R_PARISC_DIR14F reloc.
5692 (_bfd_elf_hppa_gen_reloc_type): Generate them.
5693 (elf_hppa_final_link_relocate): Handle them.
5694 (elf_hppa_relocate_insn): Likewise.
5695 (_bfd_elf_hppa_gen_reloc_type): Add missing e_ldsel and e_rdsel cases.
5697 2000-09-26 Hans-Peter Nilsson <hp@axis.com>
5699 * elfcode.h (elf_object_p): Preserve and clear abfd section
5700 information. Restore at error.
5702 2000-09-26 Paul Sokolovsky <Paul.Sokolovsky@technologist.com>
5704 * peigen.c (_bfd_pei_swap_aouthdr_in): If some DataDirectory
5705 is empty, make sure that its rva also 0. NT loader dislikes
5708 2000-09-26 Steve Ellcey <sje@cup.hp.com>
5710 * som.c (som_bfd_derive_misc_symbol_info): Make weak symbols
5713 2000-09-21 Alan Modra <alan@linuxcare.com.au>
5715 * elf32-hppa.c (elf32_hppa_check_relocs): Fix weak sym handling in
5716 currently unused RELATIVE_DYNAMIC_RELOCS code.
5717 (hppa_discard_copies): Likewise.
5718 (elf32_hppa_size_stubs): Size `input_list' array correctly. Correct
5719 comments. Don't check non-code output sections for stub grouping.
5721 2000-09-20 Alan Modra <alan@linuxcare.com.au>
5723 * section.c (bfd_get_unique_section_name): Return NULL if
5726 2000-09-19 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5728 * elf32-m68k.c (elf_cpu32_plt0_entry): Change the PLT entry 0
5729 instruction sequence to actually work.
5730 (elf_m68k_finish_dynamic_sections): Change the patch-in offset
5733 2000-09-18 Alexandre Oliva <aoliva@redhat.com>
5735 * elf32-sh.c (sh_elf_relocate_section): Use
5736 _bfd_final_link_relocate to apply the relocation against a section
5737 symbol, when doing relocatable links.
5739 2000-09-18 Alan Modra <alan@linuxcare.com.au>
5741 * elf32-hppa.c (elf32_hppa_stub_hash_entry): Rename input_section
5743 (stub_hash_newfunc): Here too.
5744 (hppa_add_stub): And here.
5745 (elf32_hppa_link_hash_table): Remove stub_section_created,
5746 reloc_section_created, first_init_sec and first_fini_sec. Add
5748 (elf32_hppa_link_hash_table_create): Init to suit.
5749 (hppa_get_stub_entry): Add support for grouping stub sections.
5750 (hppa_add_stub): Likewise. Remove sec_count param and init/fini
5751 section code. Index stub vars by section->id.
5752 (elf32_hppa_size_stubs): Likewise. Remove duplicated function
5753 exit paths. Zap allocation of above removed vars. Refine
5756 * elf32-hppa.h (elf32_hppa_size_stubs): Add output_bfd param.
5757 * elf32-hppa.c (elf32_hppa_size_stubs): Likewise.
5758 (hppa_get_stub_entry): Pass in pointer to elf32_hppa_link_hash_table
5759 rather than pointer to bfd_link_info.
5760 (hppa_add_stub): Likewise.
5761 (final_link_relocate): Likewise.
5763 2000-09-17 David Huggins-Daines <dhd@linuxcare.com>
5765 (elf32_hppa_size_stubs): Don't try to build stubs for discarded
5768 2000-09-16 Alexandre Oliva <aoliva@redhat.com>
5770 * elf32-sh.c (ELF_MAXPAGESIZE): Define to 128, to match
5771 ld/emulparams/shelf.sh.
5773 2000-09-10 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5775 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): New function.
5776 * bfd-in.h (bfd_m68k_elf32_create_embedded_relocs): Add declaration.
5777 * bfd-in2.h: Regenerate.
5779 2000-09-15 Kenneth Block <Kenneth.Block@compaq.com>
5781 * elf64-alpha.c (elf64_alpha_relax_with_lituse): ld performs
5782 LITUSE relocations incorrectly if -relax is specified on the ld
5783 command line and the displacement field of the load or store
5784 instruction is non-zero. (Patch by paul.winalski@compaq.com)
5786 2000-09-15 Alan Modra <alan@linuxcare.com.au>
5788 * elf32-hppa.c (hppa_add_stub): Dont set first_init_sec and
5789 first_fini_sec here.
5790 (elf32_hppa_size_stubs): Instead correctly find the first .init
5791 and .fini section here.
5793 2000-09-15 David Huggins-Daines <dhd@linuxcare.com>
5795 * elf32-hppa.c (clobber_millicode_symbols): New function.
5796 (elf32_hppa_size_dynamic_sections): Call it.
5798 2000-09-14 Alan Modra <alan@linuxcare.com.au>
5800 * elf32-hppa.c (elf32_hppa_link_hash_entry): Make pic_call
5801 packed. Add plabel, plt_abs packed booleans.
5802 (hppa_link_hash_newfunc): Init new fields.
5803 (PLABEL_PLT_ENTRY_SIZE): Define.
5804 (hppa_stub_name): Use size_t len vars.
5805 (hppa_add_stub): Likewise.
5806 (elf32_hppa_build_stubs): Likewise.
5807 (hppa_build_one_stub): Kill some compiler warnings.
5808 (elf32_hppa_check_relocs): Always generate a plt entry for PLABELs
5809 if dynamic linking. Munge the local plt offsets into
5810 local_got_refcounts. Set h->plabel for all global PLABELs. Use
5811 size_t len vars. Add assert for plabel addend.
5812 (elf32_hppa_gc_sweep_hook): Sweep local plt entries too.
5813 (elf32_hppa_hide_symbol): New function.
5814 (elf_backend_hide_symbol): Define.
5815 (elf32_hppa_adjust_dynamic_symbol): Don't throw away plt entries
5816 with h->plabel set. Don't make plt entries to have dynamic syms
5817 when they have been forced local. If plt entry is used by a
5818 plabel, make it PLABEL_PLT_ENTRY_SIZE.
5819 (elf32_hppa_size_dynamic_sections): Set plt_abs for init fns.
5820 Set up .plt offsets for local syms.
5821 (elf32_hppa_relocate_section): Initialise plt entries for local
5822 syms. Leave weak undefined plabels zero. Make global plabel
5823 relocs against function symbol, and leave the addend zero.
5824 Use *ABS* DIR32 relocs instead of SEGREL32 for dynamic got relocs.
5825 (elf32_hppa_finish_dynamic_symbol): Set up IPLT relocs for
5826 non-dynamic syms. Init extra plt for plabels. Use *ABS* DIR32
5827 relocs instead of SEGREL32 for dynamic got relocs.
5828 (elf32_hppa_finish_dynamic_sections): Reserve one more .got entry.
5829 (elf_backend_got_header_size): Adjust.
5830 (elf32_hppa_set_gp): Calculate an "ideal" LTP.
5832 * elf32-hppa.c (LONG_BRANCH_VIA_PLT): Define.
5833 (hppa_type_of_stub): Use it instead of #if 0
5834 (hppa_discard_copies): Use it here too.
5835 (elf32_hppa_size_dynamic_sections): And here.
5837 * elf32-hppa.c (elf32_hppa_link_hash_table): Remove `offset' field.
5838 (elf32_hppa_link_hash_table_create): And here.
5839 (hppa_build_one_stub): And here. Instead keep track of stub
5840 offset using _raw_size.
5841 (elf32_hppa_size_stubs): Likewise.
5842 (elf32_hppa_build_stubs): Likewise.
5843 (hppa_size_one_stub): Likewise. Resize reloc section too.
5845 * elf32-hppa.c (hppa_add_stub): Correct first_init_sec and
5846 first_fini_sec handling. Don't search for reloc section or set
5847 hplink->reloc_section_created here.
5848 (elf32_hppa_size_stubs): Instead search for reloc sections, and
5849 set reloc_section_created here.
5850 (hppa_handle_PIC_calls): Set ELF_LINK_HASH_NEEDS_PLT.
5851 (elf32_hppa_size_dynamic_sections): Make a .plt entry for DT_INIT
5853 (elf32_hppa_finish_dynamic_sections): Set DT_INIT and DT_FINI.
5855 * elf32-hppa.c (hppa_build_one_stub): Replace `elf_hash_table (info)'
5856 with `hplink->root.'.
5857 (elf32_hppa_check_relocs): Likewise.
5858 (elf32_hppa_gc_sweep_hook): Likewise.
5859 (elf32_hppa_adjust_dynamic_symbol): Likewise.
5860 (hppa_handle_PIC_calls): Likewise.
5861 (elf32_hppa_size_dynamic_sections): Likewise.
5862 (elf32_hppa_set_gp): Likewise.
5863 (elf32_hppa_relocate_section): Likewise.
5864 (elf32_hppa_finish_dynamic_symbol): Likewise.
5865 (elf32_hppa_finish_dynamic_sections): Likewise.
5867 From David Huggins-Daines <dhd@linuxcare.com>
5868 * elf32-hppa.c (hppa_type_of_stub): Generate import stubs for
5869 defined weak symbols in shared links.
5870 (final_link_relocate): Calls to defined weak symbols in shared
5871 objects must go via import stubs, as the target might not be known
5874 2000-09-14 Alexandre Oliva <aoliva@redhat.com>
5876 * elf32-sh.c (sh_elf_howto_table): Moved R_SH_GOT32, R_SH_PLT32,
5877 R_SH_COPY, R_SH_GLOB_DAT, R_SH_JMP_SLOT, R_SH_RELATIVE,
5878 R_SH_GOTOFF, R_SH_GOTPC) to the range from 160 to 167. Replaced
5879 the original entries with EMPTY_HOWTOs, and added new ones to fill
5881 (sh_elf_info_to_howto): Make sure the new gap isn't used.
5882 (sh_elf_relocate_section): Likewise.
5884 2000-09-13 Anders Norlander <anorland@acc.umu.se>
5886 * cpu-mips.c (arch_info_struct): Add mips:4K
5887 * bfd-in2.h (bfd_mach_mips4K): New define.
5888 * archures.c: Add bfd_mach_mips4K to comment.
5889 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Return
5890 E_MIPS_ARCH_2 for bfd_mach_mips4K.
5892 2000-09-13 Marco Franzen <marcof@thyron.com>
5894 * som.c (som_write_symbol_strings): Do not used fixed buffers,
5895 use size_t as a counter.
5896 (som_write_space_strings): Similarly.
5898 2000-09-12 Jason Eckhardt <jle@cygnus.com>
5900 * elf32-i860.c (elf32_i860_relocate_pc26): New function
5902 (elf32_i860_relocate_section): Invoke new function from here.
5904 2000-09-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5906 * elf.c (_bfd_elf_make_section_from_shdr): Make debug_sec_names
5909 2000-09-10 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5911 * coff-m68k.c (bfd_m68k_coff_create_embedded_relocs): Emit 8 NULs for
5912 target section name instead of dumping core when the target symbol is
5915 2000-09-09 Kazu Hirata <kazu@hxi.com>
5917 * riscix.c: Remove DEFUN.
5919 2000-09-08 Nick Clifton <nickc@redhat.com>
5921 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Do not
5922 initialise flags in output bfd if the input bfd is the default
5923 architecture with the default flags.
5925 2000-09-08 Kazu Hirata <kazu@hxi.com>
5927 * archive.c: Fix formatting.
5928 * coff-arm.c: Likewise.
5929 * doc/chew.c: Likewise.
5931 2000-09-08 Alan Modra <alan@linuxcare.com.au>
5933 * section.c (bfd_get_unique_section_name): Put a dot before the
5936 2000-09-07 Kazu Hirata <kazu@hxi.com>
5938 * doc/chew.c: Remove all uses of DEFUN and DEFUN_VOID.
5939 * elf.c: Fix formatting.
5941 2000-09-07 Alexandre Oliva <aoliva@redhat.com>
5943 * config.bfd (sh-*-linux*): Added.
5944 * configure.in (bfd_elf32_shlin_vec, bfd_elf32_shblin_vec): New.
5945 * targets.c: Declare them.
5946 * elf32-sh-lin.c: New file.
5947 * Makefile.am: Compile it.
5948 * elf32-sh.c: Don't override defines from elf32-sh-lin.c.
5949 * configure, Makefile.in: Rebuilt.
5951 2000-09-06 Geoffrey Keating <geoffk@cygnus.com>
5953 * xcofflink.c (xcoff_link_input_bfd): Include the .tocbss
5954 pseduo-section when determining where the TOC ends.
5956 * coff-rs6000.c (_bfd_xcoff_swap_aux_out): Use bfd_h_put_16 to
5957 output x_tvndx as it is only two bytes wide.
5959 * coff-rs6000.c (xcoff_howto_table): A modifiable branch-absolute
5960 reloc is 26 or 32 bits wide.
5962 * coff-rs6000.c (_bfd_xcoff_rtype2howto): The bitsize is irrelevant
5963 for relocs that don't change anything. Also look at the full
5966 2000-09-06 Philip Blundell <philb@gnu.org>
5968 * config.bfd (arm*-*-uclinux*): New target.
5970 2000-09-06 Alexandre Oliva <aoliva@redhat.com>
5972 * configure: Rebuilt with new libtool.m4.
5974 2000-09-06 Alan Modra <alan@linuxcare.com.au>
5976 * section.c (bfd_get_unique_section_name): Avoid c++ reserved
5977 word for variable name.
5978 * bfd-in2.h: Regenerate.
5980 2000-09-05 Nick Clifton <nickc@redhat.com>
5982 * config.in: Regenerate.
5983 * libbfd.h: Regenerate.
5984 * po/bfd.pot: Regenerate.
5985 * doc/bfdint.texi: Remove CVS date string - it foils compares with
5988 2000-09-05 Steven Johnson <sbjohnson@ozemail.com.au>
5990 * cpu-powerpc.c (arch_info_struct): Added MPC860 Family entry.
5992 2000-09-05 Alan Modra <alan@linuxcare.com.au>
5994 Shared library and PIC support.
5995 * elf32-hppa.c (PLT_ENTRY_SIZE): New.
5996 (GOT_ENTRY_SIZE): New.
5997 (ELF_DYNAMIC_INTERPRETER): New.
5998 (STUB_SUFFIX): Define.
5999 (LONG_BRANCH_PIC_IN_SHLIB): Define.
6000 (RELATIVE_DYNAMIC_RELOCS): Define.
6001 (enum elf32_hppa_stub_type): New.
6002 (struct elf32_hppa_stub_hash_entry): Rename offset to
6003 stub_offset. Add a number of new fields.
6004 (struct elf32_hppa_link_hash_entry): New.
6005 (struct elf32_hppa_link_hash_table): Add numerous fields. Remove
6007 (elf32_hppa_hash_table): Rename to hppa_link_hash_table.
6008 (elf32_hppa_stub_hash_lookup): Rename to hppa_stub_hash_lookup.
6009 (elf32_hppa_stub_hash_newfunc): Rename to stub_hash_newfunc. Init
6011 (hppa_link_hash_newfunc): New function.
6012 (elf32_hppa_link_hash_table_create): Use above function. Init new
6014 (elf32_hppa_stub_name): Rename to hppa_stub_name. Pass in reloc
6015 instead of addend, and remove sym_name from args. Don't use
6016 symbol name for local syms, instead use sym index.
6017 (elf32_hppa_size_of_stub): Rename to hppa_type_of_stub, and return
6018 stub type rather than size. Pass in hash and handle import stub
6019 case. Also pass in reloc instead of offset so we can calculate
6020 PCREL22F and PCREL12F branches properly.
6021 (elf32_hppa_build_one_stub): Rename to hppa_build_one_stub. Build
6022 import and export stubs too.
6023 (elf32_hppa_size_one_stub): Rename to hppa_size_one_stub. Handle
6024 import and export stub sizing.
6025 (elf32_hppa_check_relocs): New function.
6026 (elf32_hppa_adjust_dynamic_symbol): New function.
6027 (hppa_discard_copies): New function.
6028 (elf32_hppa_size_dynamic_sections): New function.
6029 (elf_backend_size_dynamic_sections): Define.
6030 (elf32_hppa_finish_dynamic_symbol): New function.
6031 (elf_backend_finish_dynamic_symbol): Define.
6032 (elf32_hppa_size_stubs): Stash params in link hash table, and move
6033 some local vars into the link hash table too. For shared links,
6034 trundle over function syms, generating export stubs. Handle
6035 PCREL22F branches. Break out stub creation code from here..
6036 (hppa_add_stub): .. to here. New function.
6037 (elf32_hppa_final_link): Rename to elf32_hppa_set_gp, and don't
6038 call the bfd linker. Use elf_gp to record global pointer.
6039 Calculate a value from sections if $global$ is missing.
6040 (bfd_elf32_bfd_final_link): Define as _bfd_elf32_gc_common_final_link.
6041 (elf32_hppa_gc_mark_hook): New function.
6042 (elf_backend_gc_mark_hook): Define.
6043 (elf32_hppa_gc_sweep_hook): New function.
6044 (elf_backend_gc_sweep_hook): Define.
6045 (elf32_hppa_bfd_final_link_relocate): Rename to final_link_relocate.
6046 Add rel to args, and remove howto, input_bfd, offset, addend,
6047 sym_name as we can recalculate these locally. Handle calls to
6048 dynamic objects, extra PIC relocs, PCREL22F branches. Change
6049 handling of undefined weak syms. Check that stubs are in range.
6050 Only look for import stubs on PCREL17F and PCREL22F relocs. Add
6051 message on hitting a DPREL21L reloc that needs fixing. Subtract
6052 off PC for PCREL14F. Break out code that does a stub lookup from
6054 (hppa_get_stub_entry): ..to here. New function.
6055 (elf32_hppa_relocate_insn): Merge into final_link_relocate.
6056 (elf32_hppa_relocate_section): Handle got and plt relocs, dynamic
6058 (elf32_hppa_finish_dynamic_sections): New function.
6059 (elf_backend_finish_dynamic_sections): Define.
6060 (elf_backend_final_write_processing) Define.
6061 (hppa_handle_PIC_calls): New function.
6062 (elf32_hppa_build_stubs): Call it. Pass link_info to
6063 hppa_build_one_stub.
6064 (elf32_hppa_create_dynamic_sections): New function
6065 to create .plt and .got then set .plt flags correctly.
6066 (elf_backend_create_dynamic_sections): Define.
6067 (elf32_hppa_object_p): New function.
6068 (elf_backend_object_p): Define.
6069 (elf32_hppa_elf_get_symbol_type): New function.
6070 (elf_backend_get_symbol_type): Define.
6071 (elf_backend_can_gc_sections): Define.
6072 (elf_backend_want_got_plt): Define.
6073 (elf_backend_plt_alignment): Set to 2.
6074 (elf_backend_plt_readonly): Define.
6075 (elf_backend_want_plt_sym): Define.
6076 (elf_backend_got_header_size): Reserve one entry.
6078 * elf32-hppa.h (elf32_hppa_build_stubs): Don't pass stub bfd.
6079 (elf32_hppa_size_stubs): Pass in multi_subspace.
6080 (elf32_hppa_set_gp): Declare.
6082 * section.c (SEC_HAS_GOT_REF): Define new flag for asection.
6083 (bfd_get_unique_section_name): New function.
6084 * bfd-in2.h: Regenerate.
6086 * elf64-hppa.c (elf64_hppa_check_relocs): Handle R_PARISC_PCREL12F.
6087 (elf64_hppa_size_dynamic_sections): Remove the FIXME at bfd_zalloc
6090 From David Huggins-Daines <dhd@linuxcare.com>
6091 * elf64-hppa.c (elf64_hppa_check_relocs): Fix a warning.
6092 (elf64_hppa_mark_exported_functions): Set dyn_h->st_shndx.
6093 (elf64_hppa_link_output_symbol_hook): Test dyn_h->st_shndx has
6094 been updated in finish_dynamic_symbol before modifying function
6097 * elf-hppa.h (elf_hppa_howto_table): Restructure into groups of
6098 eight entries. Replace NULL with bfd_elf_generic_reloc. Add
6099 R_PARISC_GNU_VTENTRY, R_PARISC_GNU_VTINHERIT and R_PARISC_PCREL12F.
6100 (_bfd_elf_hppa_gen_reloc_type): Handle R_PARISC_GNU_VT*. Add some
6101 comments. Handle format == 12 for R_HPPA_PCREL_CALL.
6102 (elf_hppa_final_link_relocate): Handle R_PARISC_PCREL12F.
6103 (elf_hppa_relocate_insn): Likewise. Reformat some comments.
6104 (elf_hppa_final_write_processing): Expose it for ARCH_SIZE == 32.
6106 From David Huggins-Daines <dhd@linuxcare.com>
6107 * elf-hppa.h (elf_hppa_is_local_label_name): Accept the SysV/ELF
6108 style of local labels as well.
6110 2000-09-03 Philip Blundell <philb@gnu.org>
6112 * elf32-arm.h (elf32_arm_relocate_section): Don't try to relocate
6113 references to undefined symbols in debugging sections.
6115 2000-09-02 H.J. Lu <hjl@gnu.org>
6117 * reloc.c (BFD_RELOC_SH_COPY, BFD_RELOC_SH_GLOB_DAT,
6118 BFD_RELOC_SH_JMP_SLOT, BFD_RELOC_SH_RELATIVE,
6119 BFD_RELOC_SH_GOTPC): Move them from the MIPS section to the SH
6122 2000-09-02 Jason Eckhardt <jle@cygnus.com>
6124 * elf32-i860.c (bfd_elf32_bfd_is_local_label_name): Define macro.
6125 (elf32_i860_is_local_label_name): New function and prototype.
6127 2000-09-02 Nick Clifton <nickc@redhat.com>
6129 * configure.in: Increase version number to 2.10.91.
6130 * configure: Regenerate.
6131 * aclocal.m4: Regenerate.
6132 * config.in: Regenerate.
6133 * po/bfd.pot: Regenerate.
6135 2000-09-02 Daniel Berlin <dberlin@redhat.com>
6137 * elf.c (_bfd_elf_make_section_from_shdr): Add
6138 .gnu.linkobce.wi. to the list of debug section names.
6140 2000-09-02 Nick Clifton <nickc@redhat.com>
6142 * dwarf2.c (find_debug_info): New function: Locate a section
6143 containing dwarf2 debug information.
6144 (bfd_dwarf2_find_nearest_line): Find all sections containing
6145 debug information and include them in the stash.
6147 2000-09-01 Niibe Yutaka <gniibe@m17n.org>, Kaz Kojima <kkojima@rr.iij4u.or.jp>, Alexandre Oliva <aoliva@redhat.com>
6149 * elf32-sh.c (R_SH_GOT32, R_SH_PLT32, R_SH_COPY, R_SH_GLOB_DAT,
6150 R_SH_JMP_SLOT, R_SH_RELATIVE, R_SH_GOTOFF, R_SH_GOTPC): New.
6151 (sh_reloc_map): Add new relocs.
6152 (sh_elf_check_relocs, sh_elf_link_hash_newfunc,
6153 sh_elf_link_hash_table_create, sh_elf_adjust_dynamic_symbol,
6154 sh_elf_size_dynamic_sections, sh_elf_finish_dynamic_symbol,
6155 sh_elf_finishe_dynamic_sections, sh_elf_discard_copies): New
6157 (ELF_DYNAMIC_INTERPRETER, PLT_ENTRY_SIZE): Define.
6158 (elf_sh_plt0_entry_be, elf_sh_plt0_entry_le,
6159 elf_sh_plt_entry_be, elf_sh_plt_entry_le,
6160 elf_sh_pic_plt_entry_be, elf_sh_pic_plt_entry_le):
6161 New array constants.
6162 (elf_sh_plt0_entry, elf_sh_plt_entry, elf_sh_pic_plt_entry):
6164 (elf_sh_sizeof_plt, elf_sh_plt_plt0_offset,
6165 elf_sh_plt0_linker_offset, elf_sh_plt0_gotid_offset,
6166 elf_sh_plt_temp_offset, elf_sh_plt_symbol_offset,
6167 elf_sh_plt_reloc_offset): Define.
6168 (elf_sh_pcrel_relocs_copied, elf_sh_link_hash_entry,
6169 elf_sh_link_hash_table): New structs.
6170 (sh_elf_link_hash_traverse, sh_elf_hash_table): New macros.
6171 (sh_elf_relocate_section, sh_elf_check_relocs): Handle new
6173 (elf_backend_create_dynamic_sections,
6174 bfd_elf32_bfd_link_hash_table_create,
6175 elf_backend_adjust_dynamic_symbol,
6176 elf_backend_size_dynamic_sections,
6177 elf_backend_finish_dynamic_symbol,
6178 elf_backend_finish_dynamic_sections, elf_backend_want_got_plt,
6179 elf_backend_plt_readonly, elf_backend_want_plt_sym,
6180 elf_backend_got_header_size, elf_backend_plt_header_size):
6182 * reloc.c (BFD_RELOC_SH_COPY, BFD_RELOC_SH_GLOB_DAT,
6183 BFD_RELOC_SH_JMP_SLOT, BFD_RELOC_SH_RELATIVE, BFD_RELOC_SH_GOTPC):
6185 * bfd-in2.h, libbfd.h: Rebuilt.
6187 2000-09-01 Alan Modra <alan@linuxcare.com.au>
6189 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Revert 2000-08-27
6192 2000-08-31 J"orn Rennecke <amylaar@cygnus.co.uk>
6194 * elf32-sh.c (sh_elf_merge_private_data): If ibfd's elf header flags
6195 not initialized, set them to indicate the SH1 instruction set.
6197 2000-08-31 Alexandre Oliva <aoliva@redhat.com>
6199 * acinclude.m4: Include libtool and gettext macros from the
6201 * aclocal.m4, configure: Rebuilt.
6203 2000-08-29 Michael Snyder <msnyder@seadog.cygnus.com>
6205 * elf.c: Eliminate references to __sparcv9 macro; replace with
6206 autoconf variables HAVE_PSINFO32_T etc.
6207 * configure.in: Auto-configure HAVE_PSINFO_32_T, HAVE_PRPSINFO32_T,
6208 HAVE_PSTATUS32_T, HAVE_PRSTATUS32_T, HAVE_PRSTATUS32_T_PR_WHO.
6210 * acinclude.m4 (BFD_HAVE_SYS_PROCFS_TYPE) define _SYSCALL32 so it can
6211 detect the above typedefs. (BFD_HAVE_SYS_PROCFS_TYPE_MEMBER): Ditto.
6212 * aclocal.m4: Ditto.
6213 * configure: Regenerate.
6215 2000-08-27 Alan Modra <alan@linuxcare.com.au>
6217 * elf32-i386.c (elf_i386_check_relocs): Keep info on relocs copied
6218 for any shared link, not just shared -Bsymbolic.
6219 (elf_i386_size_dynamic_sections): Call elf_i386_discard_copies on
6220 any shared link, and pass link info to it.
6221 (elf_i386_size_dynamic_sections): Update comment.
6222 (elf_i386_discard_copies): Modify to discard relocs for symbols
6223 that have been forced local.
6224 (elf_i386_finish_dynamic_symbol): Don't copy relocs for symbols
6225 that have been forced local.
6227 2000-08-24 Denis Chertykov <denisc@overta.ru> & Nick Clifton <nickc@redhat.com>
6229 * elflink.h (elf_link_add_object_symbols): Allow common
6230 symbols to have an alignment of 1 if explicitly requested, and
6231 not overridden by other definitions.
6233 2000-08-22 Doug Kwan <dkwan@transmeta.com>
6235 * coff-w65.c (CREATE_LITTLE_COFF_TARGET): Fix typo.
6236 * coffcode.h (coff_set_flags): Add detection of w65 architecture.
6238 2000-08-22 H.J. Lu <hjl@gnu.org>
6240 * elf-bfd.h (elf_link_hash_table): Add runpath.
6242 * bfd-in.h (bfd_elf_get_runpath_list): New prototype.
6243 * bfd-in2.h: Rebuilt.
6245 * elf.c (_bfd_elf_link_hash_table_init): Initialize the
6246 "runpath" field to NULL.
6247 (bfd_elf_get_runpath_list): New function.
6249 * elflink.h (elf_link_add_object_symbols): Record DT_RPATH and
6252 2000-08-22 Alexandre Oliva <aoliva@redhat.com>
6254 * elf32-sh.c (sh_elf_relocate_section) [R_SH_IND12W,
6255 R_SH_DIR8WPN, R_SH_DIR8WPZ, R_SH_DIR8WPL]: Handle them
6256 explicitly. Improve validation of r_type.
6258 2000-08-21 H.J. Lu <hjl@gnu.org>
6260 * elf32-i386.c (elf_i386_size_dynamic_sections): Zero out the
6261 dynamic allocated content space. Add a comment to remind us that
6262 one day this ought to be fixed.
6263 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
6264 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
6265 * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
6267 2000-08-21 Jason Eckhardt <jle@cygnus.com>
6269 * elf32-i860.c (elf32_i860_relocate_pc16): Just write the immediate
6270 field with the newly relocated value instead of adding it to the
6271 existing immediate field.
6272 (elf32_i860_relocate_splitn): Likewise.
6273 (elf32_i860_relocate_highadj): Likewise.
6275 2000-08-16 Jason Eckhardt <jle@cygnus.com>
6277 * elf32-i860.c (elf32_i860_relocate_pc16): Implemented function (it
6278 was previously just a stub).
6280 2000-08-16 Alexandre Oliva <aoliva@redhat.com>
6282 * elflink.c (_bfd_elf_create_got_section): Don't abort().
6284 (_bfd_elf_create_dynamic_sections): Likewise.
6286 2000-08-16 Andrew Macleod <amacleod@cygnus.com>
6288 * elf64-sparc.c (sparc64_elf_relocate_section): Set relocation address
6289 for undefined symbols to be the beginning of the section.
6291 * elf64-sparc.c (sparc64_elf_adjust_dynamic_symbol): Don't allocate
6292 four extra entries at the beginning of the .rela.plt section.
6293 (sparc64_elf_finish_dynamic_symbol): Adjust the offset in the .rela.plt
6294 section to account for the four reserved entries in the .plt section.
6296 2000-08-15 Geoffrey Keating <geoffk@cygnus.com>
6298 * xcofflink.c (_bfd_ppc_xcoff_relocate_section): Add ori r0,r0,0
6299 to the list of NOPs we recognize after a branch-and-link.
6300 Use the ori NOP when one is needed.
6302 * coff-rs6000.c (_bfd_xcoff_slurp_armap): Finish implementation
6305 2000-08-14 Jim Wilson <wilson@cygnus.com>
6307 * elf64-ia64.c (elf64_ia64_merge_private_bfd_data): Handle
6308 EF_IA_64_REDUCEDFP, EF_IA_64_CONS_GP, and EF_IA_64_NOFUNCDESC_CONS_GP.
6309 (elf64_ia64_print_private_bfd_data): Likewise. Also handle
6312 2000-08-11 Alexandre Oliva <aoliva@redhat.com>
6314 * elf32-sh.c (sh_elf_set_mach_from_flags): Make it static.
6316 2000-08-10 Jason Eckhardt <jle@cygnus.com>
6318 * elf32-i860.c (elf32_i860_relocate_section): New function.
6319 (i860_final_link_relocate): New function.
6320 (elf32_i860_relocate_splitn): New function.
6321 (elf32_i860_relocate_pc16): New function.
6322 (elf32_i860_relocate_highadj): New function.
6323 (elf32_i860_howto): Minor adjustments to some relocations.
6324 (elf_info_to_howto_rel): Define.
6325 (elf_backend_relocate_section): Define.
6327 2000-08-10 Nick Clifton <nickc@cygnus.com>
6329 * elf32-arm.h: Fix formatting.
6331 2000-08-10 Bernd Schmidt <bernds@cygnus.co.uk>
6333 * elf32-sh.c (sh_elf_reloc_loop): Make LAST_SYMBOL_SECTION static.
6335 2000-08-08 Jason Eckhardt <jle@cygnus.com>
6337 * elf32-i860.c (elf32_i860_howto_table): Updated some fields.
6339 2000-08-07 Kazu Hirata <kazu@hxi.com>
6341 * ieee.c (ieee_write_debug_part): Rewrite a comment.
6342 * elf64-ia64.c: Fix a typo.
6344 2000-08-05 Jason Eckhardt <jle@cygnus.com>
6346 * elf32-i860.c (elf32_i860_howto_table): New structure.
6347 (lookup_howto): New function.
6348 (elf32_i860_reloc_type_lookup): New function.
6349 (elf32_i860_info_to_howto_rela): New function.
6350 (elf_code_to_howto_index): New structure.
6351 (elf_info_to_howto): Re-define as elf32_i860_info_to_howto_rela.
6352 (bfd_elf32_bfd_reloc_type_lookup): Re-define as
6353 elf32_i860_reloc_type_lookup.
6355 2000-08-04 Rodney Brown <RodneyBrown@pmsc.com>
6357 * som.c (struct fixup_format): Constify `format'.
6358 (som_hppa_howto_table): Use SOM_HOWTO macro.
6359 (try_prev_fixup, hppa_som_reloc): Decorate unused parameter.
6360 (som_bfd_reloc_type_lookup): Likewise.
6361 (compare_subspaces): Remove unused `count1', `count2'.
6362 (som_begin_writing): Remove unused `total_reloc_size'.
6363 (som_bfd_derive_misc_symbol_info): Decorate unused parameter.
6364 (som_print_symbol, som_bfd_is_local_label_name): Likewise.
6365 (som_set_reloc_info): Constify `cp'. Remove unused `addend'.
6366 (som_find_nearest_line): Decorate unused parameter(s).
6367 (som_sizeof_headers, som_get_symbol_info, som_write_armap): Likewise.
6368 (som_bfd_link_split_section): Likewise.
6370 2000-08-03 Nick Clifton <nickc@cygnus.com>
6372 * section.c: Restore backed out code.
6373 * elf.c: Restore backed out code.
6374 (copy_private_bfd_data): Fix bug preventing stipped dynamic
6375 binaries from working.
6376 * bfd-in2.h: Regenerate.
6378 2000-08-03 H.J. Lu <hjl@gnu.org>
6380 * section.c: Back out the change made by Nick Clifton
6381 <nickc@cygnus.com> on 2000-07-31. It breaks stripping dynamic
6383 * bfd-in2.h: Likewise.
6386 2000-08-03 Alexandre Oliva <aoliva@redhat.com>
6388 * elf32-sh.c (sh_elf_reloc_loop): Warning removal.
6390 2000-07-31 Jason Eckhardt <jle@cygnus.com>
6392 * reloc.c (BFD_RELOC_860_*): New bfd relocs for i860.
6393 * bfd-in2.h, libbfd.h: Regenerate.
6395 2000-07-31 Nick Clifton <nickc@cygnus.com>
6397 * section.c (struct sec): Add new boolean field 'segment_mark'.
6398 (STD_SECTION): Initialise new field to zero.
6400 * bfd-in2.h: Regenerate.
6402 * elf.c (copy_private_bfd_data): Reorganise section to segment
6403 mapping to cope with moved sections requiring new segments,
6404 and overlapping segments.
6405 (SEGMENT_END): New macro: Return the end address of a segment.
6406 (IS_CONTAINED_BY_VMA): New macro: Determine if a segment
6407 contains a section by comparing their VMA addresses.
6408 (IS_CONTAINED_BY_LMA): New macro: Determine if a segment
6409 contains a section by comparing their LMA addresses.
6410 (INCLUDE_SECTION_IN_SEGMENT): New macro: Determine if a
6411 section should be included in a segment.
6412 (SEGMENT_AFTER_SEGMENT): New macro: Determine if one segment
6413 follows another in memory.
6414 (SEGMENT_OVERLAPS_SEGMENT): New macro: Determine if two
6417 2000-07-22 Jason Eckhardt <jle@cygnus.com>
6419 * cpu-i860.c: Added comments.
6421 * elf32-i860.c (TARGET_LITTLE_SYM): Defined to
6422 bfd_elf32_i860_little_vec.
6423 (TARGET_LITTLE_NAME): Defined to "elf32-i860-little".
6424 (ELF_MAXPAGESIZE): Changed to 4096.
6426 * targets.c (bfd_elf32_i860_little_vec): Declaration of
6428 (bfd_target_vector): Added bfd_elf32_i860_little_vec.
6430 * config.bfd (i860-stardent-sysv4*, i860-stardent-elf*): Added
6431 config for little endian elf32 i860.
6432 (targ_defvec): Define for the new config above
6433 as "bfd_elf32_i860_little_vec".
6434 (targ_selvecs): Define for the new config above
6435 as "bfd_elf32_i860_vec bfd_elf32_i860_little_vec"
6437 * configure.in (bfd_elf32_i860_little_vec): Added recognition
6440 * configure: Regenerated.
6442 2000-07-27 H.J. Lu <hjl@gnu.org>
6444 * elflink.h (elf_merge_symbol): Take one more argument,
6445 dt_needed, to indicate if the symbol comes from a DT_NEEDED
6446 entry. Don't overide the existing weak definition if dt_needed
6448 (elf_link_add_object_symbols): Pass dt_needed to
6449 elf_merge_symbol ().
6451 2000-07-27 Nick Clifton <nickc@cygnus.com>
6453 * elflink.h (elf_link_size_reloc_section): Zeroes the section's
6456 2000-07-25 Geoffrey Keating <geoffk@cygnus.com>
6458 * configure.host (*-*-aix*): AIX has 'long long' always.
6460 * coff-rs6000.c (xcoff_write_one_armap_big): New procedure.
6461 (xcoff_write_armap_big): Write both 32-bit and 64-bit armaps.
6462 (xcoff_write_archive_contents_big): Don't update the offset
6463 of the symbol table, xcoff_write_armap will do it.
6465 2000-07-23 Ulf Carlsson <ulfc@engr.sgi.com>
6467 * elf32-mips.c (_bfd_mips_elf_check_relocs): Use abfd instead
6468 of dynobj for SGI_COMPAT checks.
6470 2000-07-21 Michael Sokolov <msokolov@ivan.Harhan.ORG>
6472 * coff-m68k.c (bfd_m68k_coff_create_embedded_relocs): New function.
6473 * bfd-in.h (bfd_m68k_coff_create_embedded_relocs): Add declaration.
6474 * bfd-in2.h: Regenerate.
6476 2000-07-21 Nick Clifton <nickc@cygnus.com>
6478 * elf32-mips.c (_bfd_mips_elf_check_relocs): Detect out of
6479 range symbol indices in relocs and issue an error message.
6481 2000-07-20 H.J. Lu <hjl@gnu.org>
6483 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Don't check
6484 info->new_dtags when setting DT_FLAGS_1. It will only be set
6485 by the new linker options. It shouldn't break anything.
6487 2000-07-20 H.J. Lu <hjl@gnu.org>
6489 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set DT_FLAGS_1
6490 only if info->new_dtags is true.
6492 2000-07-20 H.J. Lu <hjl@gnu.org>
6494 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set
6495 DT_RUNPATH and DT_FLAGS only if info->new_dtags is true.
6497 2000-07-20 Hans-Peter Nilsson <hp@axis.com>
6499 * Makefile.am (ALL_MACHINES): Add cpu-cris.lo.
6500 (ALL_MACHINES_CFILES): Add cpu-cris.c.
6501 (BFD32_BACKENDS): Add aout-cris.lo and elf32-cris.lo.
6502 (BFD32_BACKENDS_CFILES): Add aout-cris.c and elf32-cris.c.
6503 (cpu-cris.lo, aout-cris.lo, elf32-cris.lo): New rules.
6504 * Makefile.in: Rebuild.
6505 * aclocal.m4: Rebuild.
6506 * aoutx.h (NAME(aout,machine_type)): Add case for bfd_arch_cris.
6507 * archures.c (enum bfd_architecture): Add bfd_arch_cris.
6508 (bfd_cris_arch): Declare.
6509 (bfd_archures_list): Add bfd_cris_arch.
6510 * bfd-in2.h: Rebuild.
6511 * config.bfd: (cris-*-*): New target.
6512 * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vectors.
6513 * configure: Rebuild.
6514 * elf.c (prep_headers): Add bfd_arch_cris.
6515 * libbfd.h: Rebuild.
6516 * libaout.h (enum machine_type): Add M_CRIS.
6517 * reloc.c: Add CRIS relocations.
6518 * targets.c (bfd_elf32_cris_vec, cris_aout_vec): Declare.
6519 (bfd_target_vect): Add bfd_elf32_cris_vec and cris_aout_vec.
6520 * cpu-cris.c, aout-cris.c, elf32-cris.c: New files.
6521 * po/POTFILES.in, po/bfd.pot: Regenerate.
6523 2000-07-19 H.J. Lu <hjl@gnu.org>
6525 * elf32-arm.h (elf32_arm_size_dynamic_sections): Also set
6526 DF_TEXTREL if DT_TEXTREL is set.
6527 * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise.
6528 * elf32-i386.c (elf_i386_size_dynamic_sections): Likewise.
6529 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
6530 * elf32-mips.c (_bfd_mips_elf_size_dynamic_sections): Likewise.
6531 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise.
6532 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
6533 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Likewise.
6534 * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
6535 * elf64-ia64.c (elf64_ia64_size_dynamic_sections): Likewise.
6536 * elf64-sparc.c (sparc64_elf_size_dynamic_sections): Likewise.
6538 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Also
6539 set DF_SYMBOLIC for symbolic link. Also set DT_RUNPATH if
6541 Set the DT_FLAGS and DT_FLAGS_1 entries if necessary.
6543 2000-07-19 H.J. Lu <hjl@gnu.org>
6545 * bfd-in.h (bfd_elf_set_dt_needed_soname): New.
6546 * bfd-in2.h: Rebuild.
6548 * elf-bfd.h (elf_obj_tdata): Add dt_soname.
6549 (elf_dt_soname): New.
6551 * elf.c (bfd_elf_set_dt_needed_soname): New.
6553 * elflink.h (elf_link_add_object_symbols): Add the DT_NEEDED
6554 entry if the shared object loaded by DT_NEEDED is used to
6555 resolve the reference in a regular object.
6557 2000-07-19 H.J. Lu <hjl@gnu.org>
6559 * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_CONFIG,
6560 DT_DEPAUDIT and DT_AUDIT as strings.
6562 2000-07-19 Nick Clifton <nickc@cygnus.com>
6564 * format.c: Fix formatting.
6566 2000-07-19 H.J. Lu <hjl@gnu.org>
6568 * elf.c (_bfd_elf_print_private_bfd_data): Fix DT_CHECKSUM.
6570 2000-07-19 H.J. Lu <hjl@gnu.org>
6572 * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_BIND_NOW,
6573 DT_INIT_ARRAY, DT_FINI_ARRAY, DT_INIT_ARRAYSZ, DT_FINI_ARRAYSZ,
6574 DT_RUNPATH, DT_FLAGS, DT_PREINIT_ARRAY, DT_PREINIT_ARRAYSZ,
6575 DT_PLTPADSZ, DT_MOVEENT, DT_MOVESZ, DT_FEATURE, DT_POSFLAG_1,
6576 DT_SYMINSZ, DT_SYMINENT, DT_CONFIG, DT_DEPAUDIT, DT_AUDIT,
6577 DT_PLTPAD, DT_MOVETAB, DT_SYMINFO, DT_RELACOUNT, DT_RELCOUNT,
6578 DT_FLAGS_1, DT_USED and DT_CHECKSUM.
6580 2000-07-18 Andrew Cagney <cagney@b1.cygnus.com>
6582 * elf.c (bfd_elf_get_sign_extend_vma, bfd_elf_get_arch_size): Move
6583 renamed functions from here...
6584 (assign_section_numbers): Use renamed functions.
6585 (prep_headers): Use renamed functions.
6587 * bfd.c (bfd_get_sign_extend_vma, bfd_get_arch_size): ...To here.
6588 * bfd-in.h (bfd_get_sign_extend_vma, bfd_get_arch_size): Update.
6589 * bfd-in2.h: Regenerate.
6591 2000-07-18 Ulf Carlsson <ulfc@engr.sgi.com>
6593 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Add
6594 parenthesis in if statement.
6596 2000-07-17 Koundinya K <kk@ddeorg.soft.net>
6598 Enable the support for Traditional MIPS.
6599 * elf32-mips.c (IRIX_COMPAT): Recognize bfd_elf32_tradbigmips_vecand
6600 return ict_none appropriately for traditional mips targets.
6601 (STUB_LW): Change 0x8f998000 to 0x8f998010 for traditional mips.
6602 (STUB_MOVE): Conditionalize for traditonal mips.
6603 (STUB_LI16): Likewise.
6604 (_bfd_mips_elf_modify_segment_map): Conditionalize to avoid making
6605 room for RTPROC header.
6606 (_bfd_mips_elf_modify_segment_map): For a normal mips executable set
6607 the permission for the PT_DYNAMIC as read, write and execute.
6608 (mips_elf_calculate_relocation): Check for the symbol _DYNAMIC_LINKING
6609 for traditonal mips.
6610 (_bfd_mips_elf_create_dynamic_sections): Add the symbol
6611 _DYNAMIC_LINKING for traditonal mips.
6612 (_bfd_mips_elf_create_dynamic_sections): Add the symbol __RLD_MAP
6613 in case of traditonal mips.
6614 (_bfd_mips_elf_adjust_dynamic_symbol): Create a stub only if a PLT
6615 entry is required. For a function if PLT is not required then set the
6616 corresponding hash table entry to 0.
6617 (_bfd_mips_elf_size_dynamic_sections): Add DT_DEBUG entry for
6619 (_bfd_mips_elf_finish_dynamic_symbol): for a undefined symbol in a
6620 shared object set the value to 0.
6621 (_bfd_mips_elf_finish_dynamic_symbol): Check for the symbol
6622 _DYNAMIC_LINKING for traditonal mips.
6623 (_bfd_mips_elf_finish_dynamic_symbol): Check for the symbol __RLD_MAP
6624 for traditonal mips.
6626 2000-07-15 H.J. Lu <hjl@gnu.org>
6628 * aoutx.h (translate_to_native_sym_flags): Handle BSF_LOCAL.
6630 2000-07-12 Charles Wilson <cwilson@ece.gatech.edu>
6632 * libbfd.c (bfd_seek): fix 'seek beyond EOF' error when writing
6633 out a structure that is BFD_IN_MEMORY.
6635 2000-07-11 Alan Modra <alan@linuxcare.com.au>
6637 * elf64-hppa.c (get_dyn_name): Pass in section pointer instead of
6638 bfd pointer. Print section id instead of bfd pointer for local
6639 syms. Prefix addend with `+' for global syms as well as local.
6640 Correct calculation of name component lengths.
6641 (elf64_hppa_check_relocs): Update call to get_dyn_name.
6643 From David Huggins-Daines <dhd@linuxcare.com>
6644 * elf-hppa.h (elf_hppa_relocate_section): Update calls here too.
6645 * elf64-hppa.c (elf64_hppa_check_relocs): Fix some warnings.
6646 (elf64_hppa_modify_segment_map): Likewise.
6648 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
6650 * elf.c (bfd_elf_get_sign_extend_vma): Return tendency of VMA
6651 addresses to be "naturally" sign extended. Return -1 if unknown.
6652 * bfd-in.h (bfd_elf_get_sign_extend_vma): Add declaration.
6653 * bfd-in2.h: Regenerate.
6655 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
6657 * ecoffswap.h (ecoff_get_off, ecoff_put_off): Add ECOFF_SIGNED_32
6658 and ECOF_SIGNED_64 to list ways to extract an offset.
6659 (ecoff_swap_fdr_in, ecoff_swap_fdr_out, ecoff_swap_pdr_in,
6660 ecoff_swap_pdr_out, ecoff_swap_ext_in, ecoff_swap_ext_out):
6662 * elf64-mips.c (ECOFF_SIGNED_64): Define instead of ECOFF_64.
6663 * elf32-mips.c (ECOFF_SIGNED_32): Define instead of ECOFF_32.
6665 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
6667 * elfcode.h (elf_object_p): Use bfd_set_start_address and not
6668 bfd_get_start_address.
6669 (elf_swap_ehdr_in): Sign extend e_entry when applicable.
6670 (elf_swap_ehdr_out): Ditto.
6672 2000-07-10 Alexander Aganichev <AAganichev@hypercom.com>
6674 * archures.c (bfd_default_scan): Add set of bfd_mach_ cases for
6675 compatibility with older binutils.
6677 2000-07-10 Alan Modra <alan@linuxcare.com.au>
6679 * section.c (bfd_make_section_anyway): Start section_id at 0x10.
6680 (STD_SECTION): Avoid negative ids, instead use 0 to 3.
6682 From Ryan Bradetich <rbradetich@uswest.net>
6683 * dwarf1.c (parse_die): Cure signed/unsigned char warnings.
6684 (parse_line_table): Ditto.
6685 (_bfd_dwarf1_find_nearest_line): Ditto.
6686 * syms.c (cmpindexentry): Remove extra `*' from params.
6688 2000-07-09 Koundinya K <kk@ddeorg.soft.net>
6690 * elf32-mips.c (sort_dynamic_relocs): New Function.
6691 (_bfd_mips_elf_finish_dynamic_sections): Call sort_dynamic_relocs
6692 via qsort to sort the dynamic relocations in increasing r_symndx
6695 2000-07-09 Alan Modra <alan@linuxcare.com.au>
6697 * elf64-hppa.c (elf64_hppa_dyn_hash_table_init): Add
6698 ATTRIBUTE_UNUSED to unused args.
6699 (get_opd): Likewise.
6700 (get_plt): Likewise.
6701 (get_dlt): Likewise.
6702 (get_stub): Likewise.
6703 (elf64_hppa_adjust_dynamic_symbol): Likewise.
6704 (elf64_hppa_link_output_symbol_hook): Likewise.
6705 (elf64_hppa_check_relocs): Delete unused var.
6706 (elf64_hppa_size_dynamic_sections): Likewise.
6707 (elf64_hppa_finalize_opd): Likewise.
6708 (elf64_hppa_finalize_dynreloc): Likewise.
6709 (elf64_hppa_modify_segment_map): Likewise.
6710 (elf64_hppa_finish_dynamic_sections): Likewise.
6712 * elf-hppa.h (elf_hppa_final_write_processing): Add
6713 ATTRIBUTE_UNUSED to unused args.
6714 (elf_hppa_final_link_relocate): Likewise.
6715 (elf_hppa_record_segment_addrs): Add paretheses.
6716 (elf_hppa_relocate_section): Constify dyn_name.
6718 From David Huggins-Daines <dhd@linuxcare.com>
6719 * config.bfd: Add hppa*64*-*-linux-gnu 64-bit target, and
6720 rearrange case statement so that it gets preferred to 32-bit ones.
6722 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Use
6723 asection->id instead of address of asection structure.
6724 (elf32_hppa_size_stubs): Likewise.
6726 * elf32-hppa.c (elf32_hppa_size_stubs): Use just one stub section
6727 for .init* and .fini*.
6729 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Mask pointers
6730 and addends used in stub names to 32 bits.
6731 (elf32_hppa_size_stubs): Likewise.
6733 * elf-hppa.h (elf_hppa_final_link_relocate): Don't sum addend
6734 twice for R_PARISC_GPREL64. Use bfd_put_32 for R_PARISC_PCREL32,
6735 not bfd_put_64. Fix minor comment typo and formatting.
6737 Changes to create multiple linker stubs, positioned immediately
6738 before the section where they are required.
6739 * elf32-hppa.c: Don't include hppa_stubs.h.
6740 (elf32_hppa_stub_hash_entry): Add a pointer to the stub section.
6741 (elf32_hppa_stub_hash_table): Delete.
6742 (elf32_hppa_link_hash_entry): Delete.
6743 (elf32_hppa_link_hash_table): Use plain bfd_hash_table for
6744 stub_hash_table, and store the struct here rather than a pointer.
6745 Delete output_symbol_count. Add offset array. Change
6746 global_value to a bfd_vma.
6747 (elf32_hppa_stub_hash_lookup): Use table instead of table->root.
6748 (elf32_hppa_stub_hash_traverse): Delete.
6749 (elf32_hppa_name_of_stub): Delete.
6750 (elf32_hppa_link_hash_lookup): Delete.
6751 (elf32_hppa_link_hash_traverse): Delete.
6752 (elf32_hppa_stub_hash_table_init): Delete.
6753 (elf32_hppa_size_of_stub): Pass input section and offset rather
6754 than location and calculate location here. Don't pass name as all
6755 stubs are now the same size.
6756 (elf32_hppa_stub_hash_newfunc): Init new fields.
6757 (elf32_hppa_link_hash_table_create): Likewise, and stub_hash_table
6759 (elf32_hppa_bfd_final_link_relocate): Cast enums to int before
6760 comparing against ints. Rewrite stub handling code.
6761 (elf32_hppa_relocate_section): Make r_type and r_symndx unsigned.
6762 Case enums to int before comparing against ints. Remove
6763 bfd_reloc_dangerous case.
6764 (elf32_hppa_build_one_stub): Rewrite.
6765 (elf32_hppa_size_one_stub): New function.
6766 (elf32_hppa_build_stubs): Rewrite.
6767 (elf32_hppa_size_stubs): Pass in linker call-back functions.
6768 Rewrite stub-handling specific code.
6770 * elf32-hppa.h (elf32_hppa_size_stubs): Update prototype.
6772 * elf64-hppa.c (elf64_hppa_dyn_hash_entry): Fix a comment typo.
6774 * hppa_stubs.h: Delete.
6775 * Makefile.am (SOURCE_HFILES): Remove hppa_stubs.h
6776 (elf32-hppa.lo): Remove hppa_stubs.h from dependencies.
6777 * Makefile.in: Regenerate.
6779 * elf-hppa.h (_bfd_elf_hppa_gen_reloc_type): Handle e_nlsel and
6782 * libhppa.h (hppa_field_adjust): Correct e_nsel case.
6784 * elf32-hppa.c (elf32_hppa_relocate_section): Mention the offset
6785 and section name for bfd_reloc_notsupported error message.
6786 (elf32_hppa_bfd_final_link_relocate): Print reasons for returning
6787 bfd_reloc_notsupported.
6788 (elf32_hppa_relocate_section): Add ATTRIBUTE_UNUSED to output_bfd.
6790 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Handle
6791 undefined weak symbols for all relocs.
6792 (elf32_hppa_size_of_stub): Adjust calculation by 8 since branch
6793 offsets are relative to one past the delay slot.
6794 (elf32_hppa_size_stubs): Account for reloc addend when calculating
6795 branch destination. Put addend into stub name too.
6796 (elf32_hppa_bfd_final_link_relocate): Account for reloc addend and
6797 adjust by 8 when deciding whether a linker stub is needed. Put
6798 addend into stub name as for above.
6800 * elf32-hppa.c (hppa_elf_relocate_insn): Change signed/unsigned on
6801 various args and vars.
6802 (elf32_hppa_bfd_final_link_relocate): Here too.
6803 (elf32_hppa_size_stubs): Rename index -> indx. Use e_indx for
6804 inner block var to avoid shadowing.
6806 * elf32-hppa.h (_bfd_elf32_hppa_gen_reloc_type): Make `field' arg
6808 * elf64-hppa.h (_bfd_elf64_hppa_gen_reloc_type): Ditto.
6809 * elf-hppa.h (_bfd_elf_hppa_gen_reloc_type): Ditto.
6810 (elf_hppa_fake_sections): Rename local var to avoid shadowing.
6812 * libhppa.h: Change practically all unsigned ints to plain ints.
6813 Remove tests on gcc version. Instead use ATTRIBUTE_UNUSED for
6816 From Ryan Bradetich <rbradetich@uswest.net>
6817 * libhppa.h (hppa_opcode_type): New enum to replace #define's.
6818 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Modify to
6820 From David Huggins-Daines <dhd@linuxcare.com>
6821 * elf-hppa.h (elf_hppa_relocate_insn): Update the opcode constants
6822 to the new OP_* ones.
6824 * elf32-hppa.c (elf32_hppa_size_stubs): Consolidate freeing on
6825 error exit. Bail out earlier on plabel relocs that we aren't
6826 interested in. Don't tell elf32_hppa_stub_hash_lookup to copy
6827 string, and then don't free our copy.
6828 (elf32_hppa_build_one_stub): Make insn unsigned int.
6830 * libhppa.h (bfd_hppa_insn2fmt): 22 bit branches are only
6831 available with BL, not BE and BLE.
6833 * elf32-hppa.c (hppa_elf_relocate_insn): Add some more example
6834 code for elf arg relocs.
6835 (elf32_hppa_bfd_final_link_relocate): Replace boolean is_local
6836 argument with elf_link_hash_entry h. Handle undefined weak
6837 symbols. Move $global$ lookup from here...
6838 (elf32_hppa_relocate_section): ...to here. Return correct error
6839 message for non-handled relocs.
6840 (elf32_hppa_size_of_stub): Correctly test branch range. Previous
6841 wrong test was -0x3ffff to +0x40000.
6843 * elf-hppa.h (elf_hppa_final_link_relocate): R_PARISC_DIR17R,
6844 R_PARISC_DIR17F, and R_PARISC_DIR21L are for absolute branches;
6845 Handle them as such.
6846 (elf_hppa_relocate_insn): Fix a typo.
6848 * libhppa.h (GET_FIELD, GET_BIT, MASK, CATENATE, ELEVEN): Delete.
6849 (assemble_3, assemble_6, assemble_12, assemble_16, assemble_16a,
6850 assemble_17, assemble_21): Delete.
6851 Supply defines for all 64 possible opcodes.
6852 (bfd_hppa_insn2fmt): Add bfd argument, and use to select wide mode
6853 formats. Handle COMICLR.
6854 (hppa_rebuild_insn): Delete bfd argument. Handle formats 10, -11,
6857 * elf32-hppa.c (hppa_elf_relocate_insn): Complete rewrite.
6858 (elf32_hppa_bfd_final_link_relocate): Major rewrite.
6859 (elf32_hppa_build_one_stub): Modify hppa_elf_relocate_insn calls
6861 (elf32_hppa_size_stubs): Don't free stub_name twice. Read in all
6862 the local syms - did this code get deleted accidentally? Ignore
6863 undefined and undefweak syms.
6865 * elf-hppa.h (elf_hppa_final_link): Move hppa_info to outermost
6866 block. Use it instead of elf64_hppa_hash_table (info).
6867 (elf_hppa_final_link_relocate): Use hppa_info instead of
6868 elf64_hppa_hash_table (info).
6870 * libhppa.h (re_assemble_3, re_assemble_12, re_assemble_16,
6871 re_assemble_17, re_assemble_21, re_assemble_22): Don't mask insn.
6872 (hppa_rebuild_insn): Mask immediate bits here instead.
6873 * elf-hppa.h (elf_hppa_relocate_insn): Mask here too.
6875 2000-07-08 Alan Modra <alan@linuxcare.com.au>
6877 * section.c (struct sec): Add id field. Tidy comment formatting.
6878 (bfd_make_section_anyway): Set id.
6879 (STD_SECTION): Init id too.
6880 Change CONST to const throughout.
6881 * archures.c (bfd_arch_info): Tidy comment.
6882 (bfd_arch_list): Change a CONST to const.
6883 * libbfd-in.h: Tidy comments and replace CONST with const.
6884 * elf-bfd.h: Likewise.
6885 * libbfd.h: Regenerate.
6886 * bfd-in2.h: Regenerate.
6887 * libcoff.h: Regenerate.
6889 2000-07-07 DJ Delorie <dj@redhat.com>
6891 * archive.c (_bfd_write_archive_contents): Add an informative
6894 2000-07-06 Kazu Hirata <kazu@hxi.com>
6896 * srec.c: Fix formatting.
6898 2000-06-05 DJ Delorie <dj@redhat.com>
6902 2000-07-04 Alexandre Oliva <aoliva@redhat.com>
6904 * coff-arm.c (coff_arm_relocate_section): Do not ignore the symbol
6905 value of PC-relative offsets.
6907 2000-07-03 Jim Wilson <wilson@cygnus.com>
6909 * elf64-alpha.c (alpha_elf_size_info): New.
6910 (elf_backend_size_info): Define to alpha_elf_size_info.
6911 * elfcode.h (elf_size_info): Change hash bucket size to 4.
6913 2000-07-03 Ulf Carlsson <ulfc@engr.sgi.com>
6915 * elf32-mips.c: Include elf32-target.h again for the traditional
6918 2000-07-03 Marek Michalkiewicz <marekm@linux.org.pl>
6920 * elf32-avr.c (bfd_elf32_bfd_reloc_type_lookup):
6921 Add ATTRIBUTE_UNUSED to unused arguments to avoid warnings.
6922 (avr_info_to_howto_rela): Likewise.
6923 (elf32_avr_gc_mark_hook): Likewise.
6924 (elf32_avr_gc_sweep_hook): Likewise.
6925 (elf32_avr_relocate_section): Likewise.
6927 2000-07-03 Mark Elbrecht <snowball3@bigfoot.com>
6929 * cofflink.c (_bfd_coff_write_global_sym): Turn a weak symbol into
6930 an external symbol for a non-shared, non-relocatable link.
6932 2000-07-03 Nick Clifton <nickc@redhat.com>
6934 * cofflink.c (IS_EXTERNAL): New macro: Return true if the symbol
6935 is an external symbol.
6936 (IS_WEAK_EXTERNAL): New macro: Return true if the symbol is a weak
6939 2000-07-03 Kazu Hirata <kazu@hxi.com>
6941 * reloc16.c: Fix formatting.
6943 2000-07-01 Koundinya K <kk@ddeorg.soft.net>
6945 * config.bfd: Change targ_defvec and targ_selvecs for mips*-*-sysv4*
6946 to add a new target for traditional mips i.e
6947 bfd_elf32_tradbigmips_vec and bfd_elf32_tradlittlemips_vec.
6948 * configure.in: Likewise.
6949 * configure: Rebuild.
6950 * targets.c (bfd_elf32_tradbigmips_vec): Declare and put in
6952 (bfd_elf32_tradlittlemips_vec): Likewise.
6953 * elfxx-target.h: Add macro INCLUDED_TARGET_FILE which is more a test
6954 to see that elfNN_bed does not get redefined even if the target file
6955 is included twice for a chip. See elf32-mips.c.
6957 2000-07-01 Alan Modra <alan@linuxcare.com.au>
6959 * Makefile.am (DEP): Fix 2000-06-22. grep after running dep.sed
6960 (CLEANFILES): Add DEPA.
6961 * Makefile.in: Regenerate.
6963 2000-06-30 DJ Delorie <dj@cygnus.com>
6965 * peicode.h (coff_swap_filehdr_in): can't use e_magic because we
6966 can't assume the PE header is at 0x80.
6968 2000-06-29 Mark Elbrecht <snowball3@bigfoot.com>
6970 * syms.c (_bfd_stab_section_find_nearest_line): Use IS_ABSOLUTE_PATH.
6972 2000-06-28 Mark Elbrecht <snowball3@bigfoot.com>
6974 * go32stub.h: Update stub.
6976 2000-06-26 Marek Michalkiewicz <marekm@linux.org.pl>
6978 * archures.c (bfd_mach_avr5): Define.
6979 * bfd-in2.h (bfd_mach_avr5): Define.
6980 * cpu-avr.c (arch_info_struct): Rename bfd_mach_avr4 to
6981 bfd_mach_avr5, add bfd_mach_avr4. Update comments.
6982 (compatible): Update comment. Add missing test.
6983 * elf32-avr.c (avr_final_link_relocate): Support 8K wrap
6984 for avr2 and avr4. Simplify 8K wrap code.
6985 (bfd_elf_avr_final_write_processing): Recognize bfd_mach_avr5.
6986 (elf32_avr_object_p): Recognize E_AVR_MACH_AVR5.
6988 2000-06-26 Kazu Hirata <kazu@hxi.com>
6990 * coff-h8300.c: Fix formatting.
6991 * cpu-h8300.c: Likewise.
6993 2000-06-24 Alexandre Oliva <aoliva@redhat.com>
6995 * elf32-arm.h (elf32_arm_final_link_relocate): Print `(local)'
6996 for local symbols whose names are unknown.
6998 2000-06-22 Alan Modra <alan@linuxcare.com.au>
7000 * Makefile.am (DEP): grep for leading `/' in DEP1, and fail if we
7002 * Makefile.in: Regenerate.
7003 * doc/Makefile.in: Regenerate.
7005 2000-06-20 H.J. Lu <hjl@gnu.org>
7007 * Makefile.am: Rebuild dependency.
7008 * Makefile.in: Rebuild.
7010 2000-06-20 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
7012 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): New function.
7013 (elf_backend_copy_indirect_symbol): Map to the new function.
7015 2000-06-20 Alan Modra <alan@linuxcare.com.au>
7017 * archive.c (normalize): Correct pointer comparison when checking
7019 (bfd_bsd_truncate_arname): Likewise.
7020 (bfd_gnu_truncate_arname): Likewise.
7022 2000-06-20 Ulf Carlsson <ulfc@engr.sgi.com>
7024 * elf-bfd.h (struct elf_obj_tdata): Define per BFD Irix 5 virtual
7025 sections elf_{text,data}_{section,symbol}.
7026 * elf32-mips.c: mips_elf_{text,data}_{section,symbol}{,_ptr}: Remove.
7027 (_bfd_mips_elf_hide_symbol): New function.
7028 (elf_backend_hide_symbol): Map to the new function.
7029 (_bfd_mips_elf_add_symbol_hook): Change to use new per BFD
7030 definitions of mips_elf_{text,data}_{section,symbol}.
7031 (mips_elf_local_relocation_p): Try to find the direct symbol
7032 based on new check_forced argument.
7033 (mips_elf_calculate_relocation): Use new version of
7034 mips_elf_local_relocation_p.
7035 (mips_elf_relocate_section): Likewise.
7036 (_bfd_mips_elf_relocate_section): Likewise.
7037 (mips_elf_sort_hash_table): Only assert that have enough GOT
7039 (mips_elf_got16_entry): Match all 32 bits to the existing GOT
7040 entry if the relocation based on the new external argument.
7041 (mips_elf_create_dynamic_relocation): Assert that we have a
7042 section contents allocated where we can swap out the dynamic
7044 (mips_elf_calculate_relocation): Find the real hash-table entry
7045 correctly by using h->root.root.type. Only create a dynamic
7046 relocation entry if the symbol is defined in a shared library.
7047 Create an external GOT entry for the GOT16 relocation if the
7048 symbol was forced local.
7049 (_bfd_mips_elf_finish_dynamic_symbol): Don't assert there is a
7050 dynamic index if the symbol was forced local.
7052 2000-06-20 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
7054 * elf32-mips.c: Fix typos in comments.
7056 2000-06-19 Mark Kettenis <kettenis@gnu.org>
7058 * rs6000-core.c: Wrap definition of `union VmInfo' within #ifdef
7061 2000-06-18 Stephane Carrez <stcarrez@worldnet.fr>
7063 * Makefile.in, bfd-in2.h, libbfd.h, configure: Rebuild.
7064 * Makefile.am (ALL_MACHINES, ALL_MACHINES_CFILES, BFD32_BACKENDS,
7065 BFD32_BACKENDS_CFILES): Add 68hc12, 68hc11 files.
7066 * configure.in (bfd_elf32_m68hc12_vec): Recognize.
7067 (bfd_elf32_m68hc11_vec): Likewise.
7068 * config.bfd (targ_cpu): Recognize 68hc12 and 68hc11.
7069 Supports 68hc11 & 68hc12 at the same time.
7070 * targets.c (bfd_elf32_m68hc12_vec): Declare and put in
7072 (bfd_elf32_m68hc11_vec): Likewise.
7073 * elf.c (prep_headers): Recognize bfd_arch_m68hc12 and 68hc11.
7074 * archures.c (bfd_m68hc12_arch): Define and register in global list
7075 (bfd_m68hc11_arch): Likewise.
7076 * reloc.c (BFD_RELOC_M68HC11_HI8, BFD_RELOC_M68HC11_LO8,
7077 BFD_RELOC_M68HC11_3B): Define.
7078 * cpu-m68hc12.c, elf32-m68hc12.c: New files for 68hc12 support.
7079 * cpu-m68hc11.c, elf32-m68hc11.c: New files for 68hc11 support.
7081 2000-06-18 Ulf Carlsson <ulfc@engr.sgi.com>
7083 * elf_bfd.h (struct elf_backend_data): Add info argument to
7084 elf_backend_hide_symbol.
7085 (_bfd_elf_link_hash_hide_symbol): Likewise.
7086 * elf.c (_bfd_elf_link_hash_hide_symbol): Likewise.
7087 * elf64-ia64.c (elf64_ia64_hash_hide_symbol): Likewise.
7088 * elflink.h (elf_link_add_object_symbols): Likewise.
7089 (elf_link_assign_sym_version): Likewise.
7091 2000-06-18 H.J. Lu <hjl@gnu.org>
7093 * coff-i386.c (coff_i386_reloc): Don't return in case of
7094 output_bfd == (bfd *) NULL if COFF_WITH_PE is defined.
7095 Compensate PE relocations when linking with non-PE object
7096 files to generate a non-PE executable.
7098 2000-06-17 Ulf Carlsson <ulfc@engr.sgi.com>
7100 * elf32-mips.c (mips_elf_calculate_relocation): Explicitly write
7101 GOT entries if we're doing a static link or -Bsymbolic link.
7103 2000-06-15 Ulf Carlsson <ulfc@engr.sgi.com>
7105 * elflink.h (elf_link_adjust_relocs): Check for and call backend
7106 specifific swap_reloc_{in,out} and swap_reloca_{in,out} if
7108 (elf_link_output_relocs): Likewise.
7109 (elf_reloc_link_order): Likewise.
7111 2000-06-16 Nicholas Duffek <nsd@redhat.com>
7113 * archures.c (enum bfd_architecture): #define constants for
7114 PowerPc and RS6000 machine numbers.
7115 * bfd-in2.h: Regenerate.
7116 * coffcode.h (coff_set_arch_mach_hook): #ifdef XCOFF64, set arch
7117 to bfd_arch_powerpc instead of bfd_arch_rs6000. Refer to PowerPc
7118 and RS6000 machine numbers using #defined constants from
7120 * cpu-powerpc.c (arch_info_struct): Refer to PowerPc and RS6000
7121 machine numbers using #defined constants from archures.c. Add
7122 entries for EC603e, 630, A35, RS64II, RS64III, 7400. Specify
7123 64-bit words in 620 entry.
7124 * cpu-rs6000.c (arch_info_struct): Create with entries for RS1,
7126 (bfd_rs6000_arch): Change default machine to 0 (bfd_mach_rs6k).
7128 2000-06-16 Nicholas Duffek <nsd@cygnus.com>
7130 * coffcode.h (coff_mkobject_hook): Set xcoff_tdata.xcoff64.
7131 * libcoff-in.h (struct xcoff_tdata): Define xcoff64 field.
7132 * libcoff.h (struct xcoff_tdata): Define xcoff64 field.
7134 2000-06-16 Nicholas Duffek <nsd@redhat.com>
7136 * bfd-in.h (bfd_family_coff): Define.
7137 * bfd-in2.h: Regenerate.
7138 * coffgen.c (coff_count_linenumbers, coff_symbol_from,
7139 coff_find_nearest_line): Check COFFness using bfd_family_coff()
7140 instead of bfd_target_coff_flavour.
7141 * cofflink.c (_bfd_coff_final_link): Likewise.
7142 * cpu-ns32k.c (do_ns32k_reloc): Don't strcmp() target name to
7143 exclude XCOFF files.
7144 * reloc.c (bfd_perform_relocation, bfd_install_relocation):
7146 * targets.c (enum bfd_flavour): Add bfd_target_xcoff_flavour.
7147 * xcoff-target.h (TARGET_SYM): Use bfd_target_xcoff_flavour.
7148 * xcofflink.c (XCOFF_XVECP): Delete.
7149 (bfd_xcoff_link_record_set, bfd_xcoff_import_symbol,
7150 bfd_xcoff_export_symbol, bfd_xcoff_link_count_reloc,
7151 bfd_xcoff_record_link_assignment,
7152 bfd_xcoff_size_dynamic_sections): Replace XCOFF_XVECP() with
7153 check for bfd_target_xcoff_flavour.
7155 2000-06-16 Nicholas Duffek <nsd@redhat.com>
7157 * rs6000-core.c: Support 64-bit core files, support pre-4.3 core
7159 (read_hdr): New function.
7160 (rs6000coff_core_p): Store mstsave or __context64 struct instead
7161 of trying to extract individual registers. Set abfd->arch_info
7162 to match the architecture that created the core file.
7163 (rs6000coff_get_section_contents): Delete.
7164 * xcoff-target.h (rs6000coff_get_section_contents): Delete.
7166 2000-06-14 H.J. Lu <hjl@gnu.org>
7168 * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_rec)
7171 2000-06-13 H.J. Lu <hjl@gnu.org>
7173 * configure: Regenerate.
7175 2000-06-13 J"orn Rennecke <amylaar@cygnus.co.uk>
7177 * peicode.h (pe_ILF_object_p): Use TARGET_LITTLE_SYM instead of
7180 2000-06-08 David O'Brien <obrien@FreeBSD.org>
7182 * configure.in (VERSION): Update to show this is the CVS mainline.
7184 2000-06-07 Alan Modra <alan@linuxcare.com.au>
7186 * elf32-d10v.c: Include elf/d10v.h
7187 (enum reloc_type): Delete.
7188 * elf32-d30v.c: Include elf/d30v.h
7189 (enum reloc_type): Delete.
7191 * Makefile.am: Run "make dep-am" to regenerate dependencies.
7192 * Makefile.in: Regenerate.
7194 * elf32-i386.c (elf_howto_table): Remove EMPTY_HOWTOs.
7195 (elf32_i386_vtinherit_howto, elf32_i386_vtentry_howto): Delete and
7196 move HOWTOs into elf_howto_table.
7197 (R_386_standard, R_386_ext_offset): Define.
7198 (R_386_ext, R_386_vt_offset, R_386_vt): Define.
7199 (elf_i386_reloc_type_lookup): Modify calculation of index into
7200 elf_howto_table since we've removed the padding.
7201 (elf_i386_info_to_howto_rel): Likewise.
7202 (elf_i386_relocate_section): Likewise.
7204 2000-06-06 Michael Snyder <msnyder@seadog.cygnus.com>
7206 * elf.c (elf_grok_pr_status): Eliminate reference to prgregset_t.
7208 2000-06-05 H.J. Lu <hjl@gnu.org>
7210 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Don't flag
7211 an error when seeing an undefined symbol with hidden/internal
7212 attribute. It is handled in *_relocate_section ().
7214 2000-06-05 H.J. Lu <hjl@gnu.org>
7216 * elflink.h (elf_fix_symbol_flags): Follow the link for the
7217 indirect symbol for the ELF_LINK_NON_ELF bit.
7218 (elf_link_output_extsym): Don't output the indirect symbol even
7219 if the ELF_LINK_NON_ELF bit is set.
7221 2000-06-01 J.T. Conklin <jtc@redback.com>
7223 * config.bfd (i[3456]86-*-netbsdelf*): New target.
7224 (i[3456]86-*-netbsdaout*): New target.
7225 (i[3456]86-*-netbsd*): Add bfd_elf32_i386_vec to targ_selvecs.
7226 (i[3456]86-*-openbsd*): Likewise.
7228 2000-05-30 Andrew Cagney <cagney@b1.cygnus.com>
7230 * trad-core.c: From hpux-core.c, include <dirent.h> or
7231 <sys/ndir.h> when possible.
7233 2000-05-31 Ulrich Drepper <drepper@redhat.com>
7235 * elf.c (_bfd_elf_slurp_version_tables): Correct reading of version
7236 definitions. We must not assume they are sorted in the file
7237 according to their index numbers.
7239 2000-05-31 Alan Modra <alan@linuxcare.com.au>
7241 * elf-hppa.h: (elf_hppa_final_link_relocate): Use e_rsel field
7242 selector for R_PARISC_PCREL17R. R_PARISC_DIR17R and
7243 R_PARISC_DIR17F are for absolute branches; Handle them as such.
7245 2000-05-30 Nick Clifton <nickc@cygnus.com>
7247 * cpu-i960.c (scan_960_mach): Accept 80960KA, 80960KB,
7248 80960CA, 80960MC as valid machine names.
7250 2000-05-30 H.J. Lu <hjl@gnu.org>
7252 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Clear the
7253 visibility bits if the symbol is undefined. Correctly handle
7254 weak undefined symbols with hidden and internal attributes.
7256 * elflink.h (elf_link_add_object_symbols): Always turn the
7257 symbol into local if it has the hidden or internal attribute.
7259 2000-05-29 Philip Blundell <philb@gnu.org>
7261 * ppcboot.c: Add packed attribute if compiling with GCC.
7263 2000-05-29 Anatoly Vorobey <mellon@pobox.com>
7265 * elf.c (_bfd_elf_link_hash_table_init): Initialize dynlocal.
7267 2000-05-26 Michael Snyder <msnyder@seadog.cygnus.com>
7269 * elf.c (elfcore_grok_prstatus, elfcore_grok_pstatus,
7270 elfcore_grok_psinfo): Add code to allow debugging a 32-bit
7271 corefile on a 64-bit (Sparc Solaris) host. Also clean up
7274 2000-05-26 Alan Modra <alan@linuxcare.com.au>
7276 * Makefile.am: Update dependencies with "make dep-am"
7277 * Makefile.in: Regenerate.
7279 * sysdep.h (gettext, dgettext, dcgettext, textdomain,
7280 bindtextdomain): Replace defines with those from intl/libgettext.h
7281 to quieten gcc warnings.
7283 2000-05-26 Eli Zaretskii <eliz@is.elta.co.il>
7285 * aoutx.h (find_nearest_line): Use IS_ABSOLUTE_PATH.
7287 * archive.c (normalize, bfd_bsd_truncate_arname,
7288 bfd_gnu_truncate_arname) [HAVE_DOS_BASED_FILE_SYSTEM]: Support
7289 file names with backslashes.
7291 * cache.c (bfd_open_file) [__MSDOS__]: Don't unlink the file
7294 * sysdep.h: Include filenames.h.
7296 2000-05-26 Alan Modra <alan@linuxcare.com.au>
7298 * opncls.c (bfd_close_all_done): Mask file perms with 0777 not 0x777.
7300 2000-05-26 Jakub Jelinek <jakub@redhat.com>
7302 * elf64-sparc.c (sparc64_elf_relax_section): New.
7303 (sparc64_elf_relocate_section): Optimize tail call into branch always
7305 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
7306 (elf32_sparc_relax_section): New.
7308 2000-05-26 Jakub Jelinek <jakub@redhat.com>
7310 * elf64-sparc.c: Add ATTRIBUTE_UNUSED to unused function parameters.
7311 Remove unusued variables.
7312 (sparc64_elf_relocate_section): Change r_symndx type to unsigned long.
7313 (sparc64_elf_merge_private_bfd_data): Fix shared library case from
7314 previous fix, so that shared libs really don't influence targets
7315 extension mask and memory model.
7317 2000-05-23 H.J. Lu <hjl@gnu.org>
7319 * elf64-alpha.c (elf64_alpha_relocate_section): Check
7320 h->root.other not h->other.
7321 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
7323 * elf32-ppc.c (ppc_elf_relocate_section): Fix a typo.
7325 2000-05-23 H.J. Lu <hjl@gnu.org>
7327 * elf32-i386.c (elf_i386_relocate_section): Don't allow the
7328 undefined symbol with the non-default visibility attributes.
7329 * elf-hppa.h (elf_hppa_relocate_section): Likewise.
7330 * elf32-arm.h (elf32_arm_relocate_section): Likewise.
7331 * elf32-i370.c (i370_elf_relocate_section): Likewise.
7332 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
7333 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
7334 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
7335 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
7336 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
7337 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
7338 * elf64-ia64.c (elf64_ia64_relocate_section): Likewise.
7339 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
7341 2000-05-22 Richard Henderson <rth@cygnus.com>
7343 * elf64-ia64.c (ia64_howto_table): Add PCREL60B, PCREL21BI,
7344 PCREL22, PCREL64I. Zero size of special relocs.
7345 (elf64_ia64_reloc_type_lookup): Likewise.
7346 (USE_BRL, oor_brl, oor_ip): New.
7347 (elf64_ia64_relax_section): New.
7348 (elf64_ia64_check_relocs): Handle PCREL60B, PCREL22, PCREL64I.
7349 (elf64_ia64_install_value): Likewise, plus PCREL21BI.
7350 (elf64_ia64_relocate_section): Likewise.
7351 (bfd_elf64_bfd_relax_section): New.
7352 * reloc.c (BFD_RELOC_IA64_PCREL21BI): New.
7353 (BFD_RELOC_IA64_{PCREL22,PCREL60B,PCREL64I}): New.
7354 * bfd-in2.h, libbfd.h: Regenerate.
7356 2000-05-22 Nick Clifton <nickc@cygnus.com>
7358 * configure.in : Add peigen.lo to MIPS PE targets.
7359 * configure: Regenerate.
7361 2000-05-22 Momchil Velikov <velco@fadata.bg>
7363 * libbfd.c (_bfd_generic_verify_endian_match): Compare endianess
7364 only if it is known for both input and output bfds. Separate
7365 error message strings as in some languages, it may be necessary
7366 to change more than one place in the string to change between
7369 * elf32-ppc.c (ppc_elf_merge_private_bfd_data): Remove inline
7370 endianess checks, call _bfd_generic_verify_endian_match() instead.
7372 * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Likewise.
7374 * elf32-mcore.c (mcore_elf_merge_private_bfd_data): Likewise.
7376 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Likewise. Verify
7377 endianess before checking bfd flavours.
7379 2000-05-22 H.J. Lu <hjl@gnu.org>
7381 * elflink.h (elf_link_output_extsym): Clear the visibility
7382 field for symbols not defined locally.
7384 2000-05-18 Alan Modra <alan@linuxcare.com.au>
7386 * libhppa.h (re_assemble_3, re_assemble_12, re_assemble_16,
7387 re_assemble_17, re_assemble_21, re_assemble_22): Don't mask insn.
7388 (hppa_rebuild_insn): Mask immediate bits here instead.
7389 * elf-hppa.h (elf_hppa_relocate_insn): Mask here too.
7391 2000-05-18 Momchil Velikov <velco@fadata.bg>
7393 * elflink.h (elf_bfd_final_link, elf_link_input_bfd): When emiting
7394 relocs for an executable, ensure that they are virtual addresses.
7396 2000-05-18 Jeffrey A Law (law@cygnus.com)
7398 * config.bfd (hppa*64*-*-hpux11*): New target triplet.
7400 2000-05-17 S. Bharadwaj Yadavalli <sby@scrugs.lkg.dec.com>
7401 Rick Gorton <gorton@scrugs.lkg.dec.com>
7403 * elflink.h: Add emitrelocations support: when enabled, relocation
7404 information and relocation sections are put into final output
7405 executables. If the emitrelocations flag is set, do the following:
7406 (elf_bfd_final_link): Emit relocation sections.
7407 (elf_link_input_bfd): Compute relocation section contents.
7408 (elf_gc_sections): Don't clean relocation sections.
7410 2000-05-16 Catherine Moore <clm@cygnus.com>
7412 * som.c (som_decode_symclass): Recognize weak symbols.
7414 2000-05-16 Szabolcs Szakacsits <szaka@F-Secure.com>
7416 * peigen.c (pe_print_idata): Undo part of 2000-05-12 change that
7417 read idata section only from dataoff.
7418 (pe_print_edata): Correctly check for valid eat_member.
7420 2000-05-16 J"orn Rennecke <amylaar@cygnus.co.uk>
7422 * elf32-sh.c (sh_elf_relax_delete_bytes): Handle R_SH_SWITCH8.
7424 2000-05-14 Philip Blundell <philb@gnu.org>
7426 * config.bfd (armeb-*-elf, arm*b-*-linux-gnu*): New targets.
7428 2000-05-12 Alan Modra <alan@linuxcare.com.au>
7430 * targets.c (bfd_target_vector): #ifdef BFD64 rs6000coff64_vec
7432 * peigen.c (pe_print_idata): Look for .idata section and print
7433 info even if data directory has zero entries. Read idata section
7434 starting from dataoff, and adjust all data offsets to suit. Cast
7435 all bfd_vma vars to unsigned long before passing to fprintf.
7436 * peigen.c (pe_print_edata): Similarly, look for .edata section
7437 and print info even if data directory has zero entries. Cast
7438 all bfd_vma vars to unsigned long before passing to fprintf.
7440 From Szabolcs Szakacsits <szaka@F-Secure.com>
7441 * peigen.c (pe_print_idata): Use bfd_section_size rather than data
7442 directory size which may be bogus.
7443 * peigen.c (pe_print_edata): Similarly.
7445 2000-05-09 Alan Modra <alan@linuxcare.com.au>
7447 * elf.c (bfd_section_from_shdr): Don't set use_rela_p if rela
7449 (copy_private_bfd_data): Allow for space possibly taken up by elf
7450 headers when calculating segment physical address from lma.
7452 2000-05-08 Alan Modra <alan@linuxcare.com.au>
7454 * versados.c (versados_scan): Init stringlen and pass_2_done.
7456 * trad-core.c (trad_unix_core_file_p): Return
7457 bfd_error_wrong_format rather than bfd_error_file_truncated.
7459 * peigen.c (_bfd_pei_swap_aouthdr_out): Pass ImageBase to
7460 add_data_entry. DataDirectory virtual address is relative.
7461 (pe_print_idata): Account for relative DataDirectory virtual
7462 addresses. Don't trash datasize inside POWERPC_LE_PE code.
7463 (pe_print_edata): Similarly.
7465 From Szabolcs Szakacsits <szaka@F-Secure.com>
7466 * peigen.c (dir_names): Add Delay Import Directory.
7467 (pe_print_idata): Always search for bfd section containing
7468 idata address rather than looking up section name. Print this
7469 section name rather than .idata.
7470 (pe_print_edata): Similarly. Also print some fields as %08lx.
7471 (_bfd_pe_print_private_bfd_data_common): Print Reserved1 field as
7474 2000-05-05 Clinton Popetz <cpopetz@cygnus.com>
7476 * xcoff.h: Rename to xcoff-target.h
7477 * Makefile.am: Change all instances of xcoff.h to xcoff-target.h
7478 * coff-rs6000.c: Ditto.
7479 * coff64-rs6000.c: Ditto.
7480 * coff-pmac.c: Ditto.
7481 * Makefile.in: Regenerate.
7483 2000-05-05 Clinton Popetz <cpopetz@cygnus.com>
7485 * coffcode.h (coff_set_arch_mach_hook, coff_set_flags):
7486 Change U802TOC64MAGIC to U803XTOCMAGIC.
7488 2000-05-04 Michael Snyder <msnyder@seadog.cygnus.com>
7490 * elf.c (bfd_elf_get_arch_size): New function, return 32 | 64 | -1.
7491 * bfd-in.h: Prototype bfd_elf_get_arch_size.
7492 * bfd-in2.h: Prototype bfd_elf_get_arch_size.
7494 2000-05-04 Alan Modra <alan@linuxcare.com.au>
7496 * libhppa.h (HPPA_R_CONSTANT): Cast argument to bfd_signed_vma.
7498 2000-05-03 Martin v. L�öwis <loewis@informatik.hu-berlin.de>
7500 * elflink.h (elf_link_add_object_symbols): Reset dynindx for
7501 hidden and internal symbols.
7502 (elf_fix_symbol_flags): Clear NEEDS_PLT for symbols with
7504 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Do not
7505 assign a PLT or GOT entry to symbols with hidden and
7506 internal visibility.
7508 2000-05-03 Mark Elbrecht <snowball3@bigfoot.com>
7510 * coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Add entry for
7512 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
7514 2000-05-02 H.J. Lu <hjl@gnu.org>
7516 * elf.c (prep_headers): Use ELFOSABI_NONE instead of
7519 2000-05-02 Alan Modra <alan@linuxcare.com.au>
7521 * targets.c (bfd_target_vector): Restore bfd_elf32_hppa_vec.
7522 * Makefile.am (BFD32_BACKENDS): Restore elf32-hppa.lo. Regenerate
7524 * Makefile.in: Regenerate.
7526 2000-05-01 Jim Wilson <wilson@cygnus.com>
7528 * Makefile.am (BFD32_BACKENDS): Add efi-app-ia32.lo.
7529 (BFD32_BACKENDS_CFILES): Add efi-app-ia32.c.
7530 (BFD64_BACKENDS): Delete coff-ia64.lo. Add efi-app-ia64.lo.
7531 (BFD64_BACKENDS_CFILES): Delete coff-ia64.c. Add efi-app-ia64.c.
7532 * Makefile.in: Rebuild.
7534 2000-05-02 Alan Modra <alan@linuxcare.com.au>
7536 * config.bfd: Re-enable elf32-hppa. It now compiles, even if it
7537 doesn't work very well.
7539 * elf-hppa.h (elf_hppa_internal_shdr): Define.
7540 (elf_hppa_fake_sections): hdr is elf_hppa_internal_shdr.
7541 Set hdr->s_type to 1 if ARCH_SIZE == 32.
7542 (_bfd_elf_hppa_gen_reloc_type): Add prototype.
7543 (elf_hppa_info_to_howto): Likewise.
7544 (elf_hppa_info_to_howto_rel): Likewise.
7545 (elf_hppa_reloc_type_lookup): Likewise.
7546 (elf_hppa_is_local_label_name): Likewise.
7547 (elf_hppa_fake_sections): Likewise.
7548 (elf_hppa_final_write_processing): Likewise.
7549 (elf_hppa_howto_table): Fully initialise all entries.
7550 (_bfd_elf_hppa_gen_reloc_type): Add ATTRIBUTE_UNUSED to args.
7551 (elf_hppa_info_to_howto): Likewise.
7552 (elf_hppa_info_to_howto_rel): Likewise.
7553 (elf_hppa_reloc_type_lookup): Likewise.
7554 (elf_hppa_final_write_processing, elf_hppa_add_symbol_hook,
7555 elf_hppa_unmark_useless_dynamic_symbols,
7556 elf_hppa_remark_useless_dynamic_symbols,
7557 elf_hppa_record_segment_addrs, elf_hppa_final_link,
7558 elf_hppa_relocate_section, elf_hppa_final_link_relocate,
7559 elf_hppa_relocate_insn): Compile only if ARCH_SIZE == 64 until
7560 elf32-hppa.c mess is cleaned up.
7561 (elf_hppa_final_link_relocate): Make insn and r_type unsigned
7562 int. Delete r_field. In case R_PARISC_PCREL21L, don't set
7563 r_field then call hppa_field_adjust inline func with variable
7564 r_field arg, instead call hppa_field_adjust with fixed arg.
7565 In case R_PARISC_PCREL22F, don't set r_field.
7566 (elf_hppa_relocate_insn): Change args and return type to unsigned
7567 int. Call re_assemble_* funcs to do the work.
7569 * elf32-hppa.c (hppa_elf_relocate_insn): Don't assume 32 bit when
7572 * libhppa.h (HPPA_R_CONSTANT): Don't assume 32 bit when sign
7574 (sign_extend): Mask first before sign extending.
7575 (low_sign_extend): Rewrite without condition expression.
7576 (ones, dis_assemble_3, dis_assemble_12, dis_assemble_16,
7577 dis_assemble_17, dis_assemble_21, dis_assemble_22): Delete.
7578 (assemble_3, assemble_6, assemble_12, assemble_16, assemble_16a,
7579 assemble_17, assemble_21, sign_unext, low_sign_unext): Return
7580 result as function return value rather than through pointer arg.
7581 Accept unsigned int args, and return unsigned int.
7582 (re_assemble_3): New. Combines function of dis_assemble_3 with
7583 re-assembly of opcode and immediate.
7584 (re_assemble_12): Likewise.
7585 (re_assemble_16): Likewise.
7586 (re_assemble_17): Likewise.
7587 (re_assemble_21): Likewise.
7588 (re_assemble_22): Likewise.
7589 (hppa_field_adjust): Rewrite and document, paying attention to
7590 size of types and signed/unsigned issues.
7591 (get_opcode): Shift before masking.
7592 (FDLW): Rename to FLDW.
7593 (bfd_hppa_insn2fmt): Change arg to unsigned int. Delete fmt.
7594 (hppa_rebuild_insn): Change args and return value to unsigned
7595 int. Make use of re_assemble_*. Correct case 11.
7597 * dep-in.sed: Handle ../opcodes/.
7598 * Makefile.am (SOURCE_HFILES): Add elf-hppa.h, elf32-hppa.h,
7599 elf64-hppa.h, hppa_stubs.h, xcoff.h.
7600 (BFD32_BACKENDS_CFILES): Restore elf32-hppa.c.
7601 Remove elf64-hppa.lo, cpu-ia64.lo, elf64-ia64.lo, elfarm-oabi.lo,
7602 elfarm-nabi.lo dependencies outside of auto-dependency area.
7603 Regenerate dependencies.
7604 * Makefile.in: Regenerate.
7606 * configure.in (TRAD_HEADER): Test non-null before
7608 * configure: Regenerate.
7610 * reloc.c: Fix mis-spelling in comment.
7612 2000-05-01 Alan Modra <alan@linuxcare.com.au>
7614 * coff-sh.c (bfd_coff_small_swap_table): Fix Fri Apr 28 change.
7615 * vms.c (vms_openr_next_archived_file): Return NULL.
7617 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7619 * coffcode.h Copy changes mistakenly done to libcoff.h in
7622 2000-04-29 Andreas Jaeger <aj@suse.de>
7624 * libbfd-in.h: Correctly check GCC version.
7625 * bfd-in.h: Likewise.
7626 * libhppa.h: Likewise.
7627 * libbfd.h: Regenerate.
7628 * bfd-in2.h: Regenerate.
7630 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7632 * Makefile.am (BFD64_BACKENDS, BFD64_BACKENDS_CFILES): Add
7633 coffdu-rs6000.{lo,c}.
7634 (coff-pmac.lo, coff-rs6000.lo, coff64-rs6000.lo): Add dependency
7636 * Makefile.in: Regenerate.
7637 * xcoff.h: New file.
7638 * coff-pmac.c: Use xcoff.h instead of coff-rs6000.c.
7639 * coff-rs6000.c: Move all declarations and defines that are
7640 common to the xcoff backends into xcoff.h
7641 * coff64-rs6000.c: Ditto,
7643 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7645 * coff-mips.c (mips_ecoff_backend_data): Add initialization of
7646 _bfd_coff_force_symnames in strings and
7647 _bfd_coff_debug_string_prefix_length to their default values.
7648 * coff-sh.c: (bfd_coff_small_swap_table): Ditto.
7650 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7652 * coff-alpha.c (alpha_ecoff_backend_data): Add initialization of
7653 _bfd_coff_force_symnames in strings and
7654 _bfd_coff_debug_string_prefix_length to their default values.
7656 2000-04-27 Alan Modra <alan@linuxcare.com.au>
7658 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Return if dynobj NULL.
7659 Check local_got_refcounts before dereferencing.
7661 * elf32-ppc.c (ppc_elf_relocate_section): Check splt != NULL
7662 before deciding we don't need R_PPC_PLT32 relocation.
7663 (ppc_elf_gc_sweep_hook): Check local_got_refcounts before
7666 * elflink.h (elf_gc_common_finalize_got_offsets): Fix comment.
7668 * elf32-i386.c (elf_i386_check_relocs): Reference count .got and
7670 (elf_i386_gc_sweep_hook): Garbage collect .got and .plt entries.
7671 (elf_i386_adjust_dynamic_symbol): Recognize unused .plt entries.
7672 (elf_i386_relocate_section): Allow for .plt to go missing.
7673 (elf_i386_finish_dynamic_symbol): Use same test to decide if we
7674 can use a relative reloc for got as elf_i386_relocate_section.
7675 (bfd_elf32_bfd_final_link): Define to use gc form of final link.
7677 2000-04-26 Clinton Popetz <cpopetz@cygnus.com>
7679 * config.bfd: Remove extraneous bfd_powerpc_64_arch.
7681 2000-04-24 Clinton Popetz <cpopetz@cygnus.com>
7683 * Makefile.am (coff64-rs6000.lo): New rule.
7684 * Makefile.in: Regenerate.
7685 * coff-rs6000.c (xcoff_mkobject, xcoff_copy_private_bfd_data,
7686 xcoff_is_local_label_name, xcoff_rtype2howto,
7687 xcoff_reloc_type_lookup, xcoff_slurp_armap, xcoff_archive_p,
7688 xcoff_read_ar_hdr, xcoff_openr_next_archived_file, xcoff_write_armap,
7689 xcoff_write_archive_contents): No longer static, and prefix with _bfd_.
7690 (NO_COFF_SYMBOLS): Define.
7691 (xcoff64_swap_sym_in, xcoff64_swap_sym_out, xcoff64_swap_aux_in,
7692 xcoff64_swap_aux_out): New functions; handle xcoff symbol tables
7694 (MINUS_ONE): New macro.
7695 (xcoff_howto_tabl, xcoff_reloc_type_lookup): Add 64 bit POS
7697 (coff_SWAP_sym_in, coff_SWAP_sym_out, coff_SWAP_aux_in,
7698 coff_SWAP_aux_out): Map to the new functions.
7699 * coff64-rs6000.c: New file.
7700 * libcoff.h (bfd_coff_backend_data): Add new fields
7701 _bfd_coff_force_symnames_in_strings and
7702 _bfd_coff_debug_string_prefix_length.
7703 (bfd_coff_force_symnames_in_strings,
7704 bfd_coff_debug_string_prefix_length): New macros for above fields.
7705 * coffcode.h (coff_set_arch_mach_hook): Handle XCOFF64 magic.
7706 Set machine to 620 for XCOFF64. Use bfd_coff_swap_sym_in instead
7707 of using coff_swap_sym_in directly.
7708 (FORCE_SYMNAMES_IN_STRINGS): New macro, defined for XCOFF64.
7709 (coff_set_flags) Set magic for XCOFF64.
7710 (coff_compute_section_file_positions): Add symbol name length to
7711 string section length if bfd_coff_debug_string_prefix_length is
7713 (coff_write_object_contents): Don't do reloc overflow for XCOFF64.
7714 (coff_slurp_line_table): Use bfd_coff_swap_lineno_in instead of
7715 using coff_swap_lineno_in directly.
7716 (bfd_coff_backend_data): Add _bfd_coff_force_symnames_in_strings
7717 and _bfd_coff_debug_string_prefix_length fields.
7718 * coffgen.c (coff_fix_symbol_name, coff_write_symbols): Force
7719 symbol names into strings table when
7720 bfd_coff_force_symnames_in_strings is true.
7721 * coffswap.h (MAX_SCNHDR_NRELOC, MAX_SCNHDR_NLNNO, GET_RELOC_VADDR,
7722 SET_RELOC_VADDR): New macros.
7723 (coff_swap_reloc_in, coff_swap_reloc_out): Use above macros.
7724 (coff_swap_aux_in, coff_swap_aux_out): Remove RS6000COFF_C
7726 (coff_swap_aouthdr_in, coff_swap_aouthdr_out): Handle XCOFF64
7727 changes within RS6000COFF_C specific code.
7728 (coff_swap_scnhdr_out): Use PUT_SCNHDR_NLNNO, PUT_SCNHDR_NRELOC,
7729 MAX_SCNHDR_NRELOC, and MAX_SCNHDR_NLNNO.
7730 * reloc.c (bfd_perform_relocation, bfd_install_relocation):
7731 Extend existing hack on target name.
7732 * xcofflink.c (XCOFF_XVECP): Extend existing hack on
7734 * coff-tic54x.c (ticof): Keep up to date with new fields
7735 in bfd_coff_backend_data.
7736 * config.bfd: Add bfd_powerpc_64_arch to targ_arch and define
7737 targ_selvecs to include rs6000coff64_vec for rs6000.
7738 * configure.in: Add rs6000coff64_vec case.
7739 * cpu-powerpc.c: New bfd_arch_info_type.
7741 2000-04-24 Jeffrey A Law (law@cygnus.com)
7743 * config.bfd: Only disable elf32-hppa vectors, not all of the
7744 BSD and OSF configuration support. Provide (disabled) clauses
7746 * configure.in: Add clause for PA64 support.
7747 * configure: Rebuilt.
7749 * targets.c (bfd_target_vector): Add bfd_elf64_hppa_vec.
7750 (bfd_elf64_hppa_vec): Declare.
7752 * Makefile.am (BFD64_BACKENDS): Add elf64-hppa.lo
7753 (BFD64_BACKENDS_CFILES): Add elf64-hppa.c
7754 (elf64-hppa.lo): Add dependencies.
7755 * Makefile.in: Rebuilt.
7757 * elf64-hppa.c, elf64-hppa.h: New files with PA64 support.
7759 2000-04-24 Jason Eckhardt <jle@cygnus.com>
7761 * libhppa.h (dis_assemble_16): New function.
7762 (pa_arch): Added pa20w element.
7764 2000-04-24 Ulrich Drepper <drepper@cygnus.com>
7766 * elf-bfd.h: Add prototypes for bfd_elf32_write_relocs,
7767 bfd_elf32_slurp_reloc_table, bfd_elf64_write_relocs, and
7768 bfd_elf64_slurp_reloc_table.
7770 * elfcode.h (elf_write_relocs, elf_slurp_reloc_table): New
7771 definitions to get external names.
7772 (elf_write_relocs): Renamed from write_relocs and make global.
7773 (elf_slurp_reloc_table): Make global.
7774 (_bfd_elf,size_info): Use elf_write_relocs instead of write_relocs.
7776 * archive.c (hpux_uid_gid_encode): New function.
7777 (bfd_ar_hdr_from_filesystem): Use it if HPUX_LARGE_AR_IDS is
7778 defined and the ID is greater than 99999.
7779 (bfd_generic_stat_arch_elt): If HPUX_LARGE_AR_IDS is defined decode
7780 special uid/gid fields into 32 bit values.
7782 2000-04-21 Matthew Green <mrg@cygnus.com>
7784 * config.bfd: Add NetBSD/sparc64 support.
7786 Fri Apr 21 13:20:53 2000 Richard Henderson <rth@cygnus.com>
7787 David Mosberger <davidm@hpl.hp.com>
7788 Timothy Wall <twall@cygnus.com>
7789 Jim Wilson <wilson@cygnus.com>
7791 * Makefile.am (ALL_MACHINES): Add cpu-ia64.lo.
7792 (ALL_MACHINES_CFILES): Add cpu-ia64.c.
7793 (BFD64_BACKENDS): Add elf64-ia64.lo.
7794 (BFD64_BACKENDS_CFILES): Add elf64-ia64.c.
7795 (cpu-ia64.lo, elf64-ia64.lo): New rules.
7796 * Makefile.in: Rebuild.
7797 * archures.c (enum bfd_architecture): Add bfd_arch_ia64.
7798 (bfd_ia64_arch): Declare.
7799 (bfd_archures_list): Add bfd_ia64_arch.
7800 * bfd-in2.h: Rebuild.
7801 * config.bfd: (ia64*-*-linux-gnu*, ia64*-*-elf*): New targets.
7802 * configure: Rebuild.
7803 * configure.host: (ia64-*-linux*): New host.
7804 * configure.in (bfd_elf64_ia64_little_vec, bfd_elf64_ia64_big_vec,
7805 bfd_efi_app_ia64_vec, bfd_efi_app_ia64_vec): New vectors.
7806 * elf.c (prep_headers): Add bfd_arch_ia64.
7807 * libbfd.h: Rebuild.
7808 * reloc.c: Add IA-64 relocations.
7809 * targets.c (bfd_elf64_ia64_little_vec, bfd_elf64_ia64_big_vec):
7811 (bfd_target_vect): Add bfd_elf64_ia64_little_vec.
7812 * cpu-ia64-opc.c, cpu-ia64.c, elf64-ia64.c: New files.
7814 2000-04-21 Richard Henderson <rth@cygnus.com>
7816 * elf32-d30v.c (bfd_elf_d30v_reloc): Don't modify section
7817 contents when performing a partial link.
7818 (bfd_elf_d30v_reloc_21): Likewise.
7820 2000-04-20 H.J. Lu <hjl@gnu.org>
7822 * elf32-i386.c (elf_i386_relocate_section): Restrict 1998-12-10
7823 patch to symbols defined by a shared object.
7824 * elf32-ppc.c (ppc_elf_relocate_section): Similarly.
7826 2000-04-19 Michael Sokolov <msokolov@ivan.Harhan.ORG>
7829 * dwarf2.c (concat_filename): Avoid string literal concatenation.
7830 * ieee.c (ieee_get_symtab): Don't initialise union in struct.
7832 Mon Apr 17 19:14:36 2000 David Mosberger <davidm@hpl.hp.com>
7834 * Makefile.am (BFD64_BACKENDS): Mention coff-ia64.lo.
7835 (BFD64_BACKENDS_CFILES): Mention coff-ia64.c
7836 (coff-ia64.lo): Add dependency.
7837 * Makefile.in: Regenerate.
7838 * coff-ia64.c: New file.
7839 * efi-app-ia32.c: Ditto.
7840 * efi-app-ia64.c: Ditto.
7841 * coffcode.h (coff_set_arch_mach_hook): Handle IA64MAGIC.
7842 (coff_set_flags): Ditto.
7843 (coff_write_object_contents) [IA64]: Set magic number to ZMAGIC.
7844 * config.bfd (i[3456]86-*-linux-gnu*): Mention bfd_efi_app_ia32_vec.
7845 * configure.in (elf): Handle bfd_efi_app_ia32 and bfd_efi_app_ia64_vec.
7846 * configure: Regenerate.
7847 * libpei.h (GET_OPTHDR_IMAGE_BASE): New macro.
7848 (PUT_OPTHDR_IMAGE_BASE): Ditto.
7849 (GET_OPTHDR_SIZE_OF_STACK_RESERVE): Ditto.
7850 (PUT_OPTHDR_SIZE_OF_STACK_RESERVE): Ditto.
7851 (GET_OPTHDR_SIZE_OF_STACK_COMMIT): Ditto.
7852 (PUT_OPTHDR_SIZE_OF_STACK_COMMIT): Ditto.
7853 (GET_OPTHDR_SIZE_OF_HEAP_RESERVE): Ditto.
7854 (PUT_OPTHDR_SIZE_OF_HEAP_RESERVE): Ditto.
7855 (GET_OPTHDR_SIZE_OF_HEAP_COMMIT): Ditto.
7856 (PUT_OPTHDR_SIZE_OF_HEAP_COMMIT): Ditto.
7857 (GET_PDATA_ENTRY): Ditto.
7858 * peigen.c (_bfd_pei_swap_aouthdr_in) [COFF_WITH_PEP64]: Don't read
7859 data_start. Use above macros to read fields that are 64 bit wide for
7860 COFF_WITH_PEP64. Don't truncate entry and text_start to 32 bits.
7861 (_bfd_pei_swap_aouthdr_out) [PEI_FORCE_MINIMUM_ALIGNMENT]: Force
7862 FileAlignment and SectionAlignment to minimum alignment if they
7864 (_bfd_pei_swap_aouthdr_out) [PEI_DEFAULT_TARGET_SUBSYSTEM]: Set
7865 Subsystem to default PEI_DEFAULT_TARGET_SUBSYSTEM.
7866 (_bfd_pei_swap_aouthdr_out) [COFF_WITH_PEP64]: Don't set data_start.
7867 Use above macros to write fields that are 64 bit wide for
7869 (pe_print_pdata): Set PDATA_ROW_SIZE to 3*8 for COFF_WITH_PEP64,
7870 5*4 otherwise. This should be right for IA-32 and IA-64, but may
7871 be wrong for platforms. Use PDATA_ROW_SIZE instead of hardcoded
7872 value of 20 bytes. Modify printing for COFF_WITH_PEP64 to print
7873 begin address, end address, and unwind info address only. Use
7874 GET_PDATA_ENTRY() to read .pdata entries. Use fprintf_vma() to
7876 (tbl): Add SECTION, REL32, RESERVED1, MIPS_JMPADDR16, DIR64, and
7877 HIGH3ADJ relocation names.
7878 (_bfd_pe_print_private_bfd_data): Print Subsystem name in legible form.
7879 * targets.c: Declare bfd_efi_app_ia32_vec and
7880 bfd_efi_app_ia64_vec.
7881 (bfd_target_vector): Mention bfd_efi_app_ia32_vec and
7882 bfd_efi_app_ia64_vec.
7884 2000-04-17 Timothy Wall <twall@cygnus.com>
7886 * bfd-in2.h: Add prototypes for tic54x load page access.
7887 * bfd-in.h: Regenerate.
7888 * coff-tic54x.c: Add load page functions; allow bfd_arch_unknown
7889 in customized _set_arch_mach function.
7890 * coffcode.h (coff_set_alignment_hook): Set section load page if
7891 the appropriate macro is defined.
7892 (write_object_contents): Read section load page.
7894 2000-04-13 Alan Modra <alan@linuxcare.com.au>
7896 * elf32-hppa.h: Update copyright date.
7898 * elf32-fr30.c (fr30_elf_i20_reloc): Don't use U suffix.
7899 * elf32-mips.c (_bfd_mips_elf_relocate_section): And here.
7901 * elf32-d30v.c (MAX32): Don't use LL suffix.
7902 (MIN32): Define in terms of MAX32.
7903 (bfd_elf_d30v_reloc): Make relocation a bfd_signed_vma.
7905 * coff-a29k.c (SIGN_EXTEND_HWORD): Replace with more concise
7908 * peicode.h (pe_ILF_build_a_bfd): Remove UL from hex constants.
7910 2000-04-12 Alan Modra <alan@linuxcare.com.au>
7912 * dep-in.sed: Match space before file name, not after.
7913 * Makefile.am: Regenerate dependencies.
7914 * Makefile.in: Regenerate.
7916 * reloc.c (_bfd_relocate_contents): In complain_overflow_bitfield
7917 case, allow address wrap-around stupidly removed 2000-03-17. Sign
7918 extend without an if statement.
7920 2000-04-11 Alan Modra <alan@linuxcare.com.au>
7922 * coff-mips.c (mips_gprel_reloc): Test for 16 bit range using
7924 * elf32-mips.c (gprel16_with_gp): Likewise.
7925 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Test range
7926 here using -0x40000, not (int)0xfffc0000.
7927 (elf32_hppa_size_of_stub): Likewise.
7929 2000-04-11 Timothy Wall <twall@cygnus.com>
7931 * coff-tic54x.c: Now builds with all targets.
7932 * Makefile.am: Add coff/tic54x.h to coff-tic54x.o dependencies.
7933 * Makefile.in: Regenerate.
7934 * coffcode.h (coff_set_arch_mach_hook): Eliminate warning on
7935 unitialized variable.
7937 Fri Apr 7 15:56:57 2000 Andrew Cagney <cagney@b1.cygnus.com>
7939 * configure.in (WARN_CFLAGS): Set to -W -Wall by default. Add
7940 --enable-build-warnings option.
7941 * Makefile.am (AM_CFLAGS, WARN_CFLAGS): Add definitions.
7942 * Makefile.in, configure: Re-generate.
7944 2000-04-07 Nick Clifton <nickc@cygnus.com>
7946 * reloc.c: Add BFD_RELOC_ARM_PCREL_BLX and
7947 BFD_RELOC_THUMB_PCREL_BLX.
7949 * elf32-arm.h (elf32_arm_final_link_relocate): Handle
7950 R_ARM_XPC25 and R_ARM_THM_PC22.
7952 * elfarm-nabi.c (elf32_arm_howto_): Fix definitions of
7953 R_ARM_XPC25 and R_ARM_THM_XPC22.
7954 (elf32_arm_reloc_map): Make BFD_RELOC_{ARM|THUMB}_PCREL_BLX to
7955 R_ARM_[XPC25|THM_XPC22].
7957 * elfarm-oabi.c: Define OLD_ARM_ABI and change include from
7958 elf/arm-oabi.h to elf/arm.h
7960 * Makefile.am: Fix dependency for elfarm-oabi.c
7961 * Makefile.in: Regenerate.
7963 * bfd-in2.h: Regenerate.
7964 * libbfd.h: Regenerate.
7966 2000-04-06 Michael Snyder <msnyder@seadog.cygnus.com>
7968 * elfcore.h (elf_core_file_p): preserve value of tdata at entry,
7969 and restore it on failure. Release newly allocated tdata on
7972 Fri Apr 7 11:33:47 2000 Jim Wilson <wilson@cygnus.com>
7974 * dwarf2.c (struct dwarf2_debug): New field dwarf_line_size.
7975 (decode_line_info): Set it. Report error if unit->line_offset is
7976 equal to or larger than it.
7978 2000-04-07 Timothy Wall <twall@cygnus.com>
7980 * targets.c: Added vecs for tic54x.
7981 * reloc.c: Added relocs for tic54x.
7982 * libbfd.h: Regenerated.
7983 * configure: Add TI COFF vecs for tic54x.
7984 * configure.in: Ditto.
7985 * config.bfd (targ_cpu): Recognize new tic54x target.
7986 * coffcode.h (coff_slurp_symbol_table): Additions for TI COFF handling.
7987 * bfd-in2.h: Add tic54x target and relocations.
7988 * Makefile.am, Makefile.in: Add tic54x target.
7989 * archures.c (bfd_archures_list): Add tic54x target.
7990 * coff-tic54x.c: New.
7991 * cpu-tic54x.c: New.
7993 2000-04-06 Michael Snyder <msnyder@seadog.cygnus.com>
7995 * elfcore.h (elf_core_file_p): call backend_object_p which
7996 thereby gets an opportunity to update the arch/machine type.
7998 2000-04-06 Timothy Wall <twall@cygnus.com>
8000 * coffcode.h (coff_slurp_symbol_table): Handle C_STATLAB storage
8001 class. Handle SEC_CLINK and SEC_BLOCK flags.
8002 * section.c: Add SEC_CLINK and SEC_BLOCK flags.
8003 * bfd-in2.h: Add SEC_CLINK and SEC_BLOCK flags.
8005 2000-04-06 Nick Clifton <nickc@cygnus.com>
8007 * elf32-arm.h (elf32_arm_set_private_flags): Only check for
8008 EF_INTERWORK if this is an unknown EABI.
8009 (elf32_arm_merge_private_bfd_data): Check EABI version
8010 numbers. Only check EF_xxx flags if the EABI version number
8012 (elf32_arm_check_private_bfd_data): Only check EF_xxx flags
8013 if the EABI version number is unknown.
8014 (elf32_arm_print_private_bfd_data): Only decode EF_xxx flags
8015 if the EABI version number is unknown.
8017 Wed Apr 5 22:04:20 2000 J"orn Rennecke <amylaar@cygnus.co.uk>
8019 * reloc.c (_bfd_relocate_contents): Add BFD_RELOC_SH_LOOP_START and
8020 BFD_RELOC_SH_LOOP_END.
8021 * elf32-sh.c (sh_elf_howto_tab): Change special_func to
8022 sh_elf_ignore_reloc for all entries that sh_elf_reloc used to ignore.
8023 Add entries for R_SH_LOOP_START and R_SH_LOOP_END.
8024 (sh_elf_reloc_loop): New function.
8025 (sh_elf_reloc): No need to test for always-to-be-ignored relocs
8027 (sh_rel): Add entries for BFD_RELOC_SH_LOOP_{START,END}.
8028 (sh_elf_relocate_section): Handle BFD_RELOC_SH_LOOP_{START,END}.
8029 * bfd-in2.h, libbfd.h: Regenerate.
8031 2000-04-04 Alan Modra <alan@linuxcare.com.au>
8033 * po/bfd.pot: Regenerate.
8035 * Makefile.am: Remove extraneous mkdep comment.
8036 (MKDEP): Use gcc -MM rather than mkdep.
8037 (DEP): Quote when passing vars to sub-make. Add warning
8039 (DEP1): Rewrite for "gcc -MM".
8040 (CLEANFILES): Add DEP2.
8041 Update dependencies.
8042 * Makefile.in: Regenerate.
8044 2000-04-03 Kevin Buettner <kevinb@redhat.com>
8046 * configure.in: Added corefile support for AIX 4.3. In particular,
8047 AIX_CORE_DUMPX_CORE will be defined in addition to AIX_CORE when
8048 compiling rs6000-core.c.
8049 * configure: Regenerated.
8051 2000-04-03 H.J. Lu <hjl@gnu.org>
8053 * cache.c (bfd_open_file): Unlink the output file only if
8054 it has non-zero size.
8056 2000-04-01 Ken Block USG <block@zk3.dec.com>
8058 * elf64-alpha.c (elf64_alpha_relocate_section): Don't emit
8059 relative relocations for non-loaded sections in shared objects.
8060 (elf64_alpha_check_relocs): Similarly.
8062 Mon Apr 3 13:37:15 2000 Hans-Peter Nilsson <hp@axis.com>
8064 * aoutx.h (NAME(aout,reloc_type_lookup)): Add BFD_RELOC_8 and
8065 BFD_RELOC_16 to switch for extended relocs.
8066 (MY_swap_ext_reloc_in): New.
8067 (MY_swap_ext_reloc_out): New.
8068 (NAME(aout,slurp_reloc_table)): Use MY_swap_ext_reloc_in rather
8069 than NAME(aout,swap_ext_reloc_in) for extended relocs.
8070 (NAME(aout,squirt_out_relocs)): Similarly use
8071 MY_swap_ext_reloc_out.
8072 (aout_link_reloc_link_order): Use MY_put_ext_reloc if defined.
8074 2000-04-03 Kazu Hirata <kazu@hxi.com>
8076 * coff-h8300.c (h8300_reloc16_extra_cases): Add bsr:16 -> bsr:8 to
8077 the R_PCRWORD_B case.
8079 2000-03-31 Thomas de Lellis <tdel@wrs.com>
8081 * srec.c : Set CHUNK size to 16 bytes to prevent download failures
8085 Wed Mar 30 15:28:00 2000 Donald Lindsay <dlindsay@cygnus.com>
8087 * elf32-m32r.c (m32r_elf_generic_reloc): new function. All
8088 HOWTO references to bfd_elf_generic_reloc, that have
8089 partial_inplace == true, now use the new function. The function
8090 is based on the recent rewrite of m32r_elf_lo16_reloc(), and
8091 extends its fixes to the R_M32R_{16,24,32} relocs.
8092 The new logic in m32r_elf_lo16_reloc() has been removed, and
8093 it instead calls the new routine to obtain that functionality.
8095 2000-03-27 Alan Modra <alan@linuxcare.com.au>
8097 * elf32-avr.c (elf32_avr_gc_mark_hook, elf32_avr_gc_sweep_hook,
8098 elf32_avr_check_relocs, avr_final_link_relocate,
8099 elf32_avr_relocate_section, bfd_elf_avr_final_write_processing,
8100 elf32_avr_object_p): Add prototypes.
8101 (elf32_avr_gc_mark_hook): Add default for h->root.type.
8102 (bfd_elf_avr_final_write_processing): Make static.
8104 2000-03-27 Denis Chertykov <denisc@overta.ru>
8106 * cpu-avr.c: New file. BFD support routines for AVR architecture.
8107 * archures.c (bfd_architecture): Add AVR architecture.
8108 (bfd_archures_list): Add reference to AVR architecture info.
8109 * elf.c (prep_headers): Handle bfd_arch_avr.
8110 * reloc.c: Add various AVR relocation enums.
8111 * targets.c (bfd_elf32_avr_vec): Declare and add to target vector
8113 * Makefile.am: Add support for AVR elf.
8114 * configure.in: Likewise.
8115 * config.bfd: Likewise.
8116 * Makefile.in: Regenerate.
8117 * configure: This too.
8118 * bfd-in2.h: And this.
8119 * libbfd.h: And this.
8121 2000-03-24 H.J. Lu <hjl@gnu.org>
8123 * elf64-alpha.c (elf64_alpha_merge_ind_symbols): Add prototype.
8124 (elf64_alpha_find_reloc_at_ofs): Likewise.
8126 2000-03-17 Alan Modra <alan@linuxcare.com.au>
8128 * reloc.c (bfd_check_overflow): In case complain_overflow_bitfield,
8129 flag an overflow if the bitfield is outside -2**n to 2**n-1. The
8130 allowable range used to be -2**(n-1) to 2**n-1.
8131 * reloc.c (_bfd_relocate_contents): Same here. Also replace
8132 "boolean overflow" with "bfd_reloc_status_type flag".
8134 2000-03-14 Doug Evans <dje@casey.transmeta.com>
8136 * elf32-m32r.c (m32r_elf_lo16_reloc): Rewrite.
8138 2000-03-14 Kazu Hirata <kazu@hxi.com>
8140 * reloc16.c (bfd_coff_reloc16_relax_section): Count the total number
8141 of shrinks properly, including the last reloc.
8143 2000-03-13 Kazu Hirata <kazu@hxi.com>
8145 * coff-h8300.c (h8300_reloc16_extra_cases): Fix the sanity
8148 2000-03-11 Alan Modra <alan@linuxcare.com.au>
8150 * ieee.c (ieee_archive_p): Return bfd_error_wrong_format on
8151 a format mismatch rather than an "error" from bfd_read such as
8152 bfd_error_file_truncated.
8154 2000-03-10 Geoff Keating <geoffk@cygnus.com>
8156 * elf32-mips.c (_bfd_mips_elf_relocate_section): Do proper
8157 sign-extension and big-endian compensation for
8158 R_MIPS_64 even in ld -r.
8160 2000-03-10 Geoffrey Keating <geoffk@cygnus.com>
8162 * elf32-mips.c (mips_elf_next_relocation): Rename from
8163 mips_elf_next_lo16_relocation, and generalize to look
8164 for any relocation type.
8165 (elf_mips_howto_table): Make R_MIPS_PC16 pcrel_offset.
8166 (elf_mips_gnu_rel_hi16): Howto for R_MIPS_GNU_REL_HI16.
8167 (elf_mips_gnu_rel_lo16): Howto for R_MIPS_GNU_REL_LO16.
8168 (elf_mips_gnu_rel16_s2): Howto for R_MIPS_GNU_REL16_S2.
8169 (elf_mips_gnu_pcrel64): Howto for R_MIPS_PC64.
8170 (elf_mips_gnu_pcrel32): Howto for R_MIPS_PC32.
8171 (bfd_elf32_bfd_reloc_type_lookup): Add new relocs.
8172 (mips_rtype_to_howto): Likewise.
8173 (mips_elf_calculate_relocation): Handle new relocs.
8174 (_bfd_mips_elf_relocate_section): REL_HI16/REL_LO16 relocs
8175 are paired. The addend for R_MIPS_GNU_REL16_S2
8176 is shifted right two bits.
8178 2000-03-10 Alan Modra <alan@linuxcare.com.au>
8180 * reloc.c (bfd_perform_relocation): Undo emacs formatting of
8181 comment, and ensure it doesn't happen again.
8182 (bfd_install_relocation): Same here.
8183 (_bfd_relocate_contents): Don't bother assigning unused signmask
8184 shift result. Fix typos in comments.
8185 Remove trailing whitespace throughout file.
8187 2000-03-07 Doug Evans <dje@casey.transmeta.com>
8189 * reloc.c (reloc_howto_struct): Fix partial_inplace comment.
8190 * bfd-in2.h: Rebuild.
8192 2000-03-06 Nick Clifton <nickc@cygnus.com>
8194 * peicode.h (struct pe_ILF_vars): Add sym_ptr_table and
8196 (SIZEOF_ILF_SYM_PTR_TABLE): Define.
8197 (SIZEOF_ILF_STRINGS): Redefine.
8198 (pe_ILF_make_a_symbol-reloc): New function. Creates a symbol
8199 relative reloc, as opposed to a section relative reloc.
8200 (pe_ILF_make_a_symbol): Set the class of local symbols to C_STAT
8202 Add length of symbol's prefix to string pointer.
8203 Store a pointer to the symbol in the symbol pointer table.
8204 (pe_ILF_build_a_bfd): Do not build .idata$2 or .idata$7.
8205 Initialise the symbol pointer table.
8206 Store the hint in the Hint/Name table.
8207 Make the jump reloc be symbol realtive, not section relative.
8208 Create an import symbol for imported code.
8210 2000-03-06 Catherine Moore <clm@cygnus.com>
8212 * elf.c (swap_out_syms): Check for null type_ptr.
8214 2000-03-01 Hans-Peter Nilsson <hp@axis.com>
8216 * aout-target.h (MY(write_object_contents)): Remove unused
8217 and unusable "#if CHOOSE_RELOC_SIZE".
8218 * pc532-mach.c (MY(write_object_contents)): Ditto.
8219 * netbsd.h (MY(write_object_contents)): Ditto.
8220 * hp300hpux.c (MY(write_object_contents)): Ditto.
8221 * freebsd.h (MY(write_object_contents)): Ditto.
8222 * aout-tic30.c (tic30_aout_write_object_contents): Ditto.
8224 2000-02-29 H.J. Lu <hjl@gnu.org>
8226 * peicode.h (jtab): Make it static.
8228 * coff-sh.c (sh_align_load_span): Declared if COFF_WITH_PE is
8229 defined and COFF_IMAGE_WITH_PE is not defined.
8230 (_bfd_sh_align_load_span): Defined as sh_align_load_span if
8231 COFF_WITH_PE is defined and COFF_IMAGE_WITH_PE is not defined.
8233 2000-03-01 Nick Clifton <nickc@cygnus.com>
8235 * coff-arm.c (bfd_arm_process_before_allocation): Make
8236 'symndx' signed to prevent compile time warning.
8238 * coff-mcore.c: Remove unused prototype for pe_object_p.
8240 * coff-sh.c: Add "#ifndef COFF_IMAGE_WITH_PE" around static
8241 functions that are not used when COFF_IMAGE_WITH_PE is
8243 (struct sh_opcode): Change type of 'flags' field to unsigned
8244 long so that it can hold the USESAS flag.
8246 * coffcode.h (styp_to_sec_flags): Initialise 'target_name'.
8248 * elf-m10300.c (mn10300_elf_relax_section): Initialise
8251 * elf32-i370.c: Add ATTRIBUTE_UNUSED to unused function
8253 Remove unusued variables and code.
8254 (elf_backend_add_symbol_hook): Fix prototype.
8256 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Initialise 'sgot' and
8259 * elf32-mcore.c (mcore_elf_relocate_section): Initialise
8262 * elf32-mips.c: Add ATTRIBUTE_UNUSED to unused function
8264 Remove unusued variables and code.
8265 (elf_backend_add_symbol_hook): Fix prototype.
8267 * elf32-sh.c (sh_elf_set_mach_from_flags): Use 'flags'.
8269 * elflink.h (elf_bfd_link_add_symbols): Add ATTRIBUTE_UNUSED
8270 to unused function parameter.
8272 * pe-mips.c: Add ATTRIBUTE_UNUSED to unused function
8274 Use EMPTY_HOWTO to initialise empty howto slots.
8275 Remove unused variables.
8277 * peicode.h (pe_ILF_build_a_bfd): Initialise id6.
8279 2000-03-01 H.J. Lu <hjl@gnu.org>
8281 * aoutx.h (aout_link_input_section_std): Pass "true" to
8282 the undefined_symbol callback.
8283 (aout_link_input_section_ext): Likewise.
8284 * bout.c (get_value): Likewise.
8285 * coff-a29k.c (coff_a29k_relocate_section): Likewise.
8286 * coff-alpha.c (alpha_ecoff_get_relocated_section_conten):
8288 (alpha_relocate_section): Likewise.
8289 * coff-arm.c (coff_arm_relocate_section): Likewise.
8290 * coff-i960.c (coff_i960_relocate_section): Likewise.
8291 * coff-mcore.c (coff_mcore_relocate_section): Likewise.
8292 * coff-mips.c (mips_relocate_section): Likewise.
8293 * coff-ppc.c (coff_ppc_relocate_section): Likewise.
8294 * coff-sh.c (sh_relocate_section): Likewise.
8295 * coff-tic80.c (coff_tic80_relocate_section): Likewise.
8296 * cofflink.c (_bfd_coff_generic_relocate_section): Likewise.
8297 * elf-m10200.c (mn10200_elf_relocate_section): Likewise.
8298 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
8299 * elf32-d10v.c (elf32_d10v_relocate_section): Likewise.
8300 * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
8301 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
8302 * elf32-i370.c (i370_elf_relocate_section): Likewise.
8303 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
8304 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
8305 * elf32-sh.c (sh_elf_relocate_section): Likewise.
8306 * elf32-v850.c (v850_elf_relocate_section): Likewise.
8307 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Likewise.
8308 * elflink.h (elf_link_output_extsym): Likewise.
8309 * pe-mips.c (coff_pe_mips_relocate_section): Likewise.
8310 * reloc.c (bfd_generic_get_relocated_section_conten): Likewise.
8311 * reloc16.c (_bfd_ppc_xcoff_relocate_section): Likewise.
8313 * elf-hppa.h (elf_hppa_relocate_section): Pass "false" to the
8314 undefined_symbol callback when building shared library with
8315 -Bsymbolic and undefined symbols are allowed. Otherwise, pass
8317 * elf32-arm.h (elf32_arm_relocate_section): Likewise.
8318 * elf32-i386.c (elf_i386_relocate_section): Likewise.
8319 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
8320 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
8321 (elf32_mips_get_relocated_section_content): Likewise.
8322 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
8323 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
8324 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
8325 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
8327 2000-02-28 Nick Clifton <nickc@cygnus.com>
8329 * Makefile.am: Add rules to build pe[i]-{sh|mips}.lo objects.
8330 * Makefile.in: Regenerate.
8332 * configure.in: Add support for mips and sh pe vectors.
8333 * configure: regenerate.
8335 * config.bfd: Add support for arm-wince, mips-pe and sh-pe
8338 * targets.c: Add mips and sh pe vectors.
8340 * libpei.h (coff_final_link_postscript): Only define if not
8343 * coffcode.h: Add support for WinCE magic numbers.
8345 * peigen.c (pe_print_reloc): Update comment and rearrange
8346 appending of newline character.
8348 * peicode.h: Add support for Image Library Format.
8349 (pe_ILF_vars): Structure containing data used by ILF code.
8350 (pe_ILF_make_a_section): New function. Create a section based
8352 (pe_ILF_make_a_reloc): New function. Create a reloc based on
8354 (pe_ILF_make_a_symbol): New function. Create a symbol based
8356 (pe_ILF_save_relocs): New function. Store the relocs created
8357 by pe_ILF_make_a_reloc in a section.
8358 (pe_ILF_build_a_bfd): New function. Create a BFD describing
8360 (pe_ILF_object_p): New function. Return a bfd_target pointer
8362 (pe_bfd_object_p): If an ILF object is detected call
8363 pe_ILF_object_p on it.
8365 * coff-arm.c: Add support for WinCE relocs which are different
8366 from normal ARM COFF relocs.
8367 * pe-arm.c: Unset TARGET_UNDERSCORE for a WinCE target.
8369 * coff-sh.c: Add support for sh-pe target.
8370 * pe-sh.c: New file. Support code for sh-pe target.
8371 * pei-sh.c: New file. Support code for sh-pe target.
8373 * pe-mips.c: New file. Support code for mips-pe target.
8374 * pei-mips.c: New file. Support code for mips-pe target.
8376 2000-02-27 Jakub Jelinek <jakub@redhat.com>
8378 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data): Don't bump
8379 architecture if the object causing the bump is dynamic.
8380 * elf64-sparc.c (sparc64_elf_merge_private_bfd_data): Likewise,
8381 and also don't it for memory ordering.
8382 (sparc64_elf_write_relocs): Take src_rela out of the loop.
8384 2000-02-27 Ian Lance Taylor <ian@zembu.com>
8386 * dwarf2.c (read_abbrevs): Use _raw_size directly rather than
8387 calling bfd_get_section_size_before_reloc.
8388 (decode_line_info): Likewise.
8389 (_bfd_dwarf2_find_nearest_line): Likewise.
8391 2000-02-27 Eli Zaretskii <eliz@is.elta.co.il>
8393 * Makefile.am (stamp-lib): Use $(LIBTOOL) --config to get the
8394 name of the libtool directory.
8395 * Makefile.in: Rebuild.
8397 Fri Feb 25 18:39:26 2000 Rodney Brown (RodneyBrown@pmsc.com)
8399 * som.c (SOM_HOWTO): Define.
8400 (som_hppa_howto_table): Use it.
8402 2000-02-25 Alexandre Oliva <oliva@lsd.ic.unicamp.br>
8404 * config.bfd: Enable 64 bit support for GNU/Linux/sparc.
8406 * config.bfd: Enable 64 bit support for Solaris7+/sparc.
8408 2000-02-24 Catherine Moore <clm@cygnus.com>
8410 * som.c (som_misc_symbol_info): Add field
8412 (som_bfd_derive_misc_symbol_info): Initialize
8414 (som_build_and_write_symbol_table): Keep track
8415 of secondary_def field.
8416 (som_slurp_symbol_table): Set BSF_WEAK symbol flag
8417 if secondary_def field is set.
8418 (som_bfd_ar_write_symbol_stuff): Initialize
8421 2000-02-23 Stephane Carrez <stcarrez@worldnet.fr>
8423 * dwarf2.c (read_address): Read 16-bits addresses.
8424 (parse_comp_unit): Accept addr_size == 2.
8426 2000-02-23 Alan Modra <alan@spri.levels.unisa.edu.au>
8428 * bfd-in.h: Update copyright date.
8430 2000-02-23 Linas Vepstas <linas@linas.org>
8432 * cpu-i370.c: New file.
8433 * elf32-i370.c: New file.
8434 * archures.c (enum bfd_architecture): Add bfd_arch_i370.
8435 (bfd_i370_arch): New.
8436 (bfd_archures_list): Add bfd_i370_arch.
8437 * elf.c (prep_headers): Add bfd_arch_i370.
8438 * Makefile.am: Add support for IBM 370 elf.
8439 * config.bfd: Likewise.
8440 * configure.in: Likewise.
8441 * libbfd.h (bfd_reloc_code_real_names): Likewise.
8442 * reloc.c (bfd_reloc_code_type): Likewise.
8443 * targets.c: Likewise.
8445 * Makefile.in: Regenerate.
8446 * configure: Regenerate.
8447 * bfd-in2.h: Regenerate.
8449 2000-02-22 Ian Lance Taylor <ian@zembu.com>
8451 * elf32-i386.c (elf_i386_info_to_howto_rel): Give a warning for
8452 invalid relocation types, and change them to R_386_NONE.
8454 2000-02-22 H.J. Lu <hjl@gnu.org>
8456 * elflink.h (elf_link_add_object_symbols): If a version symbol is
8457 not defined, don't add a second ELF_VER_CHR.
8459 * elflink.h (elf_bfd_final_link): Call output_extsym for global
8460 symbols converted to local symbols even when stripping all
8462 (elf_link_output_extsym): Process global symbols converted to
8463 local symbols even if they are being stripped.
8465 2000-02-21 Alan Modra <alan@spri.levels.unisa.edu.au>
8467 * archures.c (bfd_octets_per_byte): Return unsigned int.
8468 (bfd_arch_mach_octets_per_byte): Ditto.
8469 * libbfd.c (bfd_read, bfd_seek): Quell signed vs. unsigned
8471 * section.c (bfd_get_section_size_before_reloc): Quell signed
8472 vs. unsigned comparison warning.
8473 (bfd_get_section_size_after_reloc): Same here. Fix parentheses too.
8474 * trad-core.c (trad_unix_core_file_p): Correct 2000-01-27
8475 change. What was I thinking?
8476 * bfd-in2.h: Regenerate.
8478 * elflink.h (elf_gc_sweep): Skip non-elf input bfds.
8479 (elf_gc_sections): Same here.
8480 (elf_gc_common_finalize_got_offsets): And here.
8482 2000-02-21 Ian Lance Taylor <ian@zembu.com>
8484 ELF HPPA doesn't work at present; remove it until it does.
8485 * config.bfd: Comment out setting targ_defvec to
8487 * Makefile.am: Rebuild dependencies.
8488 (BFD32_BACKENDS): Remove elf32-hppa.lo.
8489 (BFD32_BACKENDS_CFILES): Remove elf32-hppa.c.
8490 (SOURCE_HFILES): Remove elf32-hppa.h and hppa_stubs.h.
8491 * Makefile.in: Rebuild.
8492 * targets.c (bfd_target_vector): Comment out bfd_elf32_hppa_vec.
8494 2000-02-18 Geoff Keating <geoffk@cygnus.com>
8496 * coffcode.h (coff_set_arch_mach_hook): Use free(), because there
8497 is no bfd_free(). Revert bfd_free part of previous change.
8499 2000-02-18 Geoff Keating <geoffk@cygnus.com>
8501 * coffcode.h (coff_set_arch_mach_hook): Don't use variable-size
8503 (coff_compute_section_file_positions): Use bfd_free to pair
8505 (coff_write_object_contents): Likewise.
8507 * coff-rs6000.c (xcoff_howto_table_16): New variable.
8508 (xcoff_rtype2howto): Handle 16-bit variants of 32-bit relocs.
8510 2000-02-18 Ulrich Drepper <drepper@cygnus.com>
8512 * coff-rs6000.c (XCOFFARMAGBIG): New macro.
8513 (xcoff_ar_file_hdr_big): New structure.
8514 (SIZEOF_AR_FILE_HDR_BIG): New macro.
8515 (xcoff_ar_hdr_big): New structure.
8516 (SIZEOF_AR_HDR_BIG): New macro.
8517 (xcoff_big_format_p): New macro.
8518 (xcoff_ardata_big): New macro.
8519 (arch_xhdr_big): New macro.
8520 (xcoff_slurp_armap): Handle large archives.
8521 (xcoff_archive_p): Detect large archives.
8522 (xcoff_read_ar_hdr): Handle large archives.
8523 (xcoff_openr_next_archived_file): Handle large archives.
8524 (xcoff_generic_stat_arch_elt): Handle large archives.
8525 (xcoff_write_armap_old): Rename from xcoff_write_armap.
8526 (xcoff_write_armap_big): New function.
8527 (xcoff_write_armap): New function, dispatch to _old or _big.
8528 (xcoff_write_archive_contents_old): Rename from
8529 xcoff_write_archive_contents.
8530 (xcoff_write_archive_contents_big): New function.
8531 (xcoff_write_archive_contents): New function, dispatch to _old or
8534 2000-02-18 Richard Henderson <rth@cygnus.com>
8536 * elf-bfd.h (struct elf_link_hash_table): Remove copy_indirect
8537 and hide_symbol members.
8538 (elf_link_hash_copy_indirect): Remove.
8539 (elf_link_hash_hide_symbol): Remove.
8540 (struct elf_backend_data): Add elf_backend_copy_indirect_symbol
8541 and elf_backend_hide_symbol.
8542 (_bfd_elf_link_hash_copy_indirect): Declare.
8543 (_bfd_elf_link_hash_hide_symbol): Declare.
8544 * elf.c (_bfd_elf_link_hash_copy_indirect): Remove table argument.
8545 (_bfd_elf_link_hash_hide_symbol): Likewise.
8546 (_bfd_elf_link_hash_table_init): Don't init killed members.
8547 * elflink.h (elf_link_add_object_symbols): Use the bed function
8548 pointers not elf_link_hash_{copy_indirect,hide_symbol}.
8549 (elf_link_assign_sym_version): Likewise.
8550 * elfxx-target.h (elf_backend_copy_indirect_symbol): Default.
8551 (elf_backend_hide_symbol): Likewise.
8552 (elfNN_bed): Update for new members.
8554 2000-02-17 Kevin Buettner <kevinb@redhat.com>
8556 * rs6000-core.c (CORE_DATA_SIZE_FIELD, CORE_COMM_FIELD, SAVE_FIELD,
8557 STACK_END_ADDR): Define for new core file format.
8558 (LOADER_OFFSET_FIELD, LOADER_REGION_SIZE, CORE_DUMP): New defines
8559 for handling the vagaries of the various core file structures used
8560 by AIX over the years.
8561 (rs6000coff_core_p, rs6000coff_core_file_matches_executable,
8562 Rs6kCorData): Use above defines to adapt code to use AIX 4.3's
8563 core_dumpx structure.
8565 Thu Feb 17 00:04:48 2000 J"orn Rennecke <amylaar@cygnus.co.uk>
8567 * archures.c (bfd_mach_sh2, bfd_mach_sh_dsp): New macros.
8568 (bfd_mach_sh3_dsp): Likewise.
8569 (bfd_mach_sh4): Reinstate.
8570 (bfd_default_scan): Recognize 7410, 7708, 7729 and 7750.
8571 * bfd-in2.h: Regenerate.
8572 * coff-sh.c (struct sh_opcode): flags is no longer short.
8573 (USESAS, USESAS_REG, USESR8, SETSAS, SETSAS_REG): New macros.
8574 (sh_opcode41, sh_opcode42): Integrate as sh_opcode41.
8575 (sh_opcode01, sh_opcode02, sh_opcode40): Add sh-dsp opcodes.
8576 (sh_opcode41, sh_opcode4, sh_opcode80): Likewise.
8577 (sh_opcodes): No longer const.
8578 (sh_dsp_opcodef0, sh_dsp_opcodef): New arrays.
8579 (sh_insn_uses_reg): Check for USESAS and USESR8.
8580 (sh_insn_sets_reg, sh_insns_conflict): Check for SETSAS.
8581 (_bfd_sh_align_load_span): Return early for SH4.
8582 Modify sh_opcodes lookup table for sh-dsp / sh3-dsp.
8583 Take into account that field b of a parallel processing insn
8584 could be mistaken for a separate insn.
8585 * cpu-sh.c (arch_info_struct): New array elements for
8586 sh2, sh-dsp and sh3-dsp.
8587 Reinstate element for sh4.
8588 (SH2_NEXT, SH_DSP_NEXT, SH3_DSP_NEXT): New macros.
8589 (SH4_NEXT): Reinstate.
8590 (SH3_NEXT, SH3E_NEXT): Adjust.
8591 * elf-bfd.h (_sh_elf_set_mach_from_flags): Declare.
8592 * elf32-sh.c (sh_elf_set_private_flags): New function.
8593 (sh_elf_copy_private_data, sh_elf_set_mach_from_flags): Likewise.
8594 (sh_elf_merge_private_data): New function.
8595 (elf_backend_object_p, bfd_elf32_bfd_set_private_bfd_flags): Define.
8596 (bfd_elf32_bfd_copy_private_bfd_data): Define.
8597 (bfd_elf32_bfd_merge_private_bfd_data): Change to
8598 sh_elf_merge_private_data.
8600 2000-02-13 Richard Henderson <rth@cygnus.com>
8602 * elf-bfd.h (struct elf_link_hash_table): Add copy_indirect and
8603 hide_symbol members.
8604 (elf_link_hash_copy_indirect): New.
8605 (elf_link_hash_hide_symbol): New.
8606 * elflink.h (elf_link_add_object_symbols): Break out copy from
8607 indirect new new symbol to elf.c.
8608 (elf_link_assign_sym_version): Break out privatization of
8609 non-exported symbol to elf.c.
8610 * elf.c (_bfd_elf_link_hash_copy_indirect): New.
8611 (_bfd_elf_link_hash_hide_symbol): New.
8612 (_bfd_elf_link_hash_table_init): Init copy_indirect and hide_symbol.
8614 2000-02-13 Ian Lance Taylor <ian@zembu.com>
8616 * section.c (_bfd_strip_section_from_output): Add info parameter.
8617 If it passed as non-NULL, use it to check whether any input BFD
8618 has an input section which uses this output section. Change all
8620 * bfd-in2.h: Rebuild.
8622 * bfd-in.h: Move declarations of bfd_get_elf_phdr_upper_bound and
8623 bfd_get_elf_phdrs in from bfd-in2.h, correcting patch of
8625 * bfd-in2.h: Rebuild.
8627 2000-02-10 Timothy Wall <twall@cygnus.com>
8629 * coffswap.h (coff_swap_sym_in): Add hook SWAP_SYM_IN_POST to
8630 allow final modifications of swapped-in symbol.
8631 (coff_swap_sym_out): Ditto with SWAP_SYM_OUT_POST.
8632 * coffcode.h (coff_write_relocs): Use macro
8633 SECTION_RELATIVE_ABSOLUTE_SYMBOL_P if defined to determine whether
8634 symbol index should be set to -1.
8636 Thu Feb 10 20:07:50 GMT 2000 Toshiyasu Morita (toshi.morita@sega.com)
8638 * coff-sh.c (USES1_REG, USES2_REG, SETS1_REG, SETS2_REG,
8639 USESF1_REG, USESF2_REG, SETSF1_REG, SETSF2_REG): New macros.
8640 * (sh_insn_sets_reg, sh_insn_sets_freg): New prototypes.
8641 * (sh_insn_sets_reg, sh_insn_uses_or_sets_reg, sh_insns_sets_freg,
8642 sh_insns_uses_or_sets_freg): New functions.
8643 * (sh_insn_uses_reg, sh_insn_uses_freg): Use new macros.
8644 * (sh_insns_conflict): Use new functions and new macros to
8645 detect conflicts when two instructions both set same integer registers,
8646 both set same fp register, and both set special register.
8648 2000-02-09 Timothy Wall <twall@cygnus.com>
8650 * coffgen.c (coff_real_object_p): Set arch/mach info prior to
8651 swapping in sections, so that the swapping routines have access to
8654 2000-02-08 Mark Elbrecht <snowball3@bigfoot.com>
8656 * coff-go32.c: Update comment. Update copyright.
8658 2000-01-27 Thomas de Lellis <tdel@windriver.com>
8660 * syms.c (bfd_decode_symclass)
8661 Two new class characters were added - 'V' and 'v'. The
8662 meaning of 'W' is now restricted to just weak non-object
8663 symbols. This allows differentiation between, for example,
8664 weak functions vs weak objects. nm for example now dumps:
8666 'w' = weak unresolved
8667 'V' = weak global object
8668 'v' = weak unresolved object
8670 (bfd_is_undefined_symclass): New function. Return true if the
8671 given symbol class represents and undefined/unresolved symbol.
8673 (bfd_symbol_info): Use bfd_is_undefined_symclass to check for
8676 * bfd-in2.h: Add prototype for bfd_is_undefined_symbol().
8678 * elf32-arm.h (elf32_arm_get_symbol_type): If a symbol has the
8679 STT_ARM_16BIT flag set, but it is not attached to a data object
8680 return STT_ARM_16BIT so that it will be treated as code by the
8683 2000-01-27 Alan Modra <alan@spri.levels.unisa.edu.au>
8685 * coff-i386.c (i3coff_object_p): Remove prototype.
8688 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Add const
8689 to name. Update copyright.
8691 * trad-core.c (trad_unix_core_file_p): Cast core_regsec
8692 assignment to avoid warning. Update copyright.
8694 2000-01-24 Robert Lipe (robertl@sco.com)
8696 * coffcode.h (coff_write_object_contents): Get buff via bfd_malloc
8697 instead of using GNU C extension.
8699 2000-01-21 Nick Clifton <nickc@cygnus.com>
8701 * libbfd.c (bfd_read): Do not attempt to get a negativly sized
8702 amount from a bfd_in_memory structure.
8703 (bfd_seek): Do not allow seeks past the end of a bfd_in_memory
8706 2000-01-14 Nick Clifton <nickc@cygnus.com>
8708 * linker.c (default_indirect_link_order): oops - fix incorrectly
8709 applied patch from Tim Wall.
8711 2000-01-13 Timothy Wall (twall@tiac.net>
8713 * coffcode.h: Use bfd_coff_xxx instead of the macro XXX (where xxx
8714 = scnhsz, filhsz, relsz, aoutsz, etc)
8716 * coffswap.h: Ditto.
8718 2000-01-13 Nick Clifton <nickc@cygnus.com>
8720 * elf32-arm.h (elf32_thumb_to_arm_stub): Fix offset in branch to
8721 interwork thumb to arm stub.
8723 2000-01-13 Timothy Wall (twall@tiac.net>
8725 * archures.c (bfd_octets_per_byte): New function: Return
8727 (bfd_arch_mach_octets_per_byte): New function: Return target
8730 * section.c: Distinguish between octets and bytes for usage of
8731 _cooked_size, _raw_size, and output_offset. Clarify
8732 description of bfd_set_section_contents.
8734 * bfd-in2.h: Regenerate.
8736 * coffgen.c: Indicate that the offset parameter is in bytes, not
8739 * cofflink.c (bfd_coff_link_input_bfd): Use bfd_octets_per_byte
8740 where appropriate to get the octet offset when calling
8741 bfd_set_section_contents.
8742 (bfd_coff_reloc_link_order): Ditto.
8744 * linker.c (bfd_generic_reloc_link_order): Ditto.
8745 (_bfd_default_link_order): Ditto.
8747 * reloc.c (bfd_perform_relocation): Distinguish between octets
8748 and bytes. Use octets when indexing into octet data; use bytes
8749 when calculating target addresses.
8750 (bfd_install_relocation): Ditto.
8752 * srec.c (srec_write_section): Ditto.
8754 2000-01-13 Nick Clifton <nickc@cygnus.com>
8756 * coff-mcore.c (COFF_DEFAULT_SECTION_ALIGNMENT_POWER): Change from
8757 3 to 2. This allows 4 byte sized sections, which is necessary for
8758 dlltool to build functioning DLLs.
8760 2000-01-10 Philip Blundell <pb@futuretv.com>
8762 * config.bfd (arm*-*-linux-gnu*): Match instead of arm*-*-linux-gnu.
8763 (arm*-*-conix*): New target.
8765 2000-01-10 Egor Duda <deo@logos-m.ru>
8767 * config.bfd: Include elf32_i386 vector to target list for cygwin
8770 * config.in: Undefine HAVE_WIN32_PSTATUS_T.
8771 * configure.in: Test for structure win32_pstatus_t in
8773 * configure: Regenerate.
8775 * elf.c (elfcore_grok_win32pstatus): New function: process
8776 win32_pstatus_t notes in elf core file.
8777 (elfcore_grok_note): Detect win32_pstatus notes.
8779 2000-01-03 Martin v. Loewis <loewis@informatik.hu-berlin.de>
8781 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Process symbol
8783 * elflink.h (elf_link_add_object_symbols): Combine visibilities.
8784 * elf.c (bfd_elf_print_symbol): Interpret st_other as visibility.
8786 For older changes see ChangeLog-9899
8792 version-control: never