1 2001-11-02 Hans-Peter Nilsson <hp@axis.com>
3 * elfcore.h (elf_core_file_p): Preserve and clear abfd section
4 information. Save bfd arch and mach values. Restore on error.
6 2001-11-02 Alan Modra <amodra@bigpond.net.au>
8 * elf32-hppa.c (hppa_handle_PIC_calls): Rename to mark_PIC_calls.
9 (allocate_PIC_calls): New function.
10 (allocate_dynrelocs): Don't allocate pic_call plt entries here.
11 (elf32_hppa_size_dynamic_sections): Call allocate_PIC_calls.
12 (elf32_hppa_finish_dynamic_symbol): Remove dead code.
14 2001-11-02 Hans-Peter Nilsson <hp@axis.com>
16 * elf32-cris.c (cris_elf_grok_prstatus): New function.
17 (cris_elf_grok_psinfo): New function.
18 (elf_backend_grok_prstatus): Define.
19 (elf_backend_grok_psinfo): Define.
21 2001-11-01 Alan Modra <amodra@bigpond.net.au>
23 * elf64-ppc.c (ppc64_elf_relocate_section): Correct branch
26 2001-10-31 Chris Demetriou <cgd@demetriou.com>
28 * elf32-mips.c (_bfd_mips_elf_hi16_reloc): Handle PC-relative
31 2001-10-31 H.J. Lu <hjl@gnu.org>
33 * elflink.h (elf_link_output_extsym): Don't clear the visibility
34 field for relocateable.
36 2001-11-01 Alan Modra <amodra@bigpond.net.au>
38 * elf32-hppa.c (elf32_hppa_finish_dynamic_sections): Don't count
39 .plt relocs in DT_RELASZ.
41 2001-10-29 NIIBE Yutaka <gniibe@m17n.org>
43 * config.bfd: Supports sh3/sh4/sh3eb/sh4eb-unknown-linux-gnu
46 2001-10-31 Nick Clifton <nickc@cambridge.redhat.com>
48 * targets.c: Fix typo: bfd_mmo_mmix_vec => bfd_mmo_vec.
50 2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
52 * Makefile.am (ALL_MACHINES): Add cpu-mmix.lo.
53 (BFD64_BACKENDS): Add elf64-mmix.lo and mmo.lo.
54 (BFD64_BACKENDS_CFILES): Add elf64-mmix.c and mmo.c.
55 Regenerate dependencies.
56 * configure.in (bfd_elf64_mmix_vec, bfd_mmo_vec): New vectors.
57 * config.bfd: [BFD64] (mmix-*-*): New case.
58 * cpu-mmix.c, mmo.c, elf64-mmix.c: New files.
59 * archures.c (enum bfd_architecture): Add bfd_arch_mmix.
60 (bfd_mmix_arch): Declare.
61 (bfd_archures_list): Add bfd_mmix_arch.
62 * targets.c (enum bfd_flavour): Add bfd_target_mmo_flavour.
63 (bfd_elf64_mmix_vec, bfd_mmo_vec): Declare.
64 (bfd_target_vect) [BFD64]: Add bfd_elf64_mmix_vec and
66 * reloc.c: Add MMIX relocations.
67 * bfd.c (struct _bfd, tdata): Add mmo_data.
68 * Makefile.in: Regenerate.
69 * configure: Regenerate.
70 * libbfd.h: Regenerate.
71 * bfd-in2.h: Regenerate.
74 2001-10-30 Richard Earnshaw (rearnsha@arm.com)
76 * elf.c (_bfd_elf_make_section_from_shdr): Set the LMA based on the
77 p_paddr of the segment that contains it.
78 (copy_private_bfd_data): If the LMA for a segment is known, use it
79 for matching sections to segments.
80 (assign_file_positions_for_segments): Use the LMA when adjusting
81 for inter-section alignment padding.
83 2001-10-29 Kazu Hirata <kazu@hxi.com>
87 2001-10-24 Richard Henderson <rth@redhat.com>
89 * peXXigen.c (_bfd_XX_print_private_bfd_data_common): Copy
90 timestamp to time_t for ctime.
92 2001-10-24 Hans-Peter Nilsson <hp@axis.com>
94 * elf32-cris.c (cris_reloc_type_lookup): Change loop to use
95 unsigned, increasing index.
97 2001-10-23 H.J. Lu <hjl@gnu.org>
99 * elf32-mips.c (_bfd_mips_elf_modify_segment_map): Check
100 m != NULL before accessing it.
102 2001-10-23 Alan Modra <amodra@bigpond.net.au>
104 * elflink.h (elf_link_input_bfd): Zero the reloc instead of doing
105 bfd_reloc_type_lookup (bfd, BFD_RELOC_NONE) as bfd_reloc_type_lookup
106 doesn't accept BFD_RELOC_* on some targets, eg. hppa.
108 * elf32-hppa.c (elf32_hppa_link_hash_entry): Remove plt_abs.
109 (hppa_link_hash_newfunc): Likewise.
110 (elf32_hppa_finish_dynamic_symbol): Likewise.
111 (allocate_dynrelocs): Always allocate .got relocs if shared.
112 (elf32_hppa_relocate_section): Output them too. Similarly
113 consolidate .plt reloc code, and no longer initialise .plt
114 when a reloc is output.
115 (elf32_hppa_finish_dynamic_symbol): Only initialise .plt entries
116 when no reloc is output.
118 From Herbert Xu <herbert@gondor.apana.org.au>
119 * elf32-hppa.c (final_link_relocate): Call bfd_set_error for
120 unreachable branches.
122 2001-10-22 H.J. Lu <hjl@gnu.org>
124 * configure.in (WIN32LIBADD): Use -L../libiberty for
126 * configure: Rebuild.
128 2001-10-21 H.J. Lu <hjl@gnu.org>
130 * configure.in (WIN32LIBADD): Include -L../libiberty/pic -liberty
131 if shared library is enabled only for Linux hosts.
132 * configure: Rebuild.
134 2001-10-21 H.J. Lu <hjl@gnu.org>
136 * configure.in (WIN32LIBADD): Check if PICFLAG is defined in
137 ../libiberty/Makefile instead of $enable_shared.
138 * configure: Rebuild.
140 2001-10-21 H.J. Lu <hjl@gnu.org>
142 * elf32-cris.c (cris_reloc_type_lookup): Use int for index. Cover
145 2001-10-20 H.J. Lu <hjl@gnu.org>
147 * configure.in (WIN32LIBADD): Include -L../libiberty/pic -liberty
148 if shared library is enabled.
149 * configure: Rebuild.
151 2001-10-20 H.J. Lu <hjl@gnu.org>
153 * elf32-cris.c (cris_reloc_type_lookup): Allow index 0.
155 2001-10-19 H.J. Lu <hjl@gnu.org>
157 * elfcode.h (elf_object_p): Don't clear D_PAGED if the section
160 2001-10-18 H.J. Lu <hjl@gnu.org>
162 * elf32-i370.c (i370_elf_relocate_section): Ignore R_XXX_NONE.
163 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
165 2001-10-18 Jakub Jelinek <jakub@redhat.com>
167 * section.c (_bfd_strip_section_from_output): Don't count
168 SEC_EXCLUDE sections as references. Set SEC_EXCLUDE.
170 2001-10-17 Alan Modra <amodra@bigpond.net.au>
172 * elf-m10200.c (mn10200_elf_relax_section): Cast assignment to
173 Elf_Internal_Shdr.contents now that it's no longer a PTR.
174 * elf-m10300.c (mn10300_elf_relax_section): Likewise.
175 * elf32-h8300.c (elf32_h8_relax_section): Likewise.
176 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Likewise.
177 * elf32-sh.c (sh_elf_relax_section): Likewise.
178 * elf64-alpha.c (elf64_alpha_relax_section): Likewise.
179 * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
180 * elf.c (setup_group): Warning fixes.
181 * elflink.h (elf_link_sort_relocs): Likewise.
182 * pdp11.c (slurp_reloc_table): Likewise.
184 2001-10-16 Jeff Holcomb <jeffh@redhat.com>
186 * elflink.h (elf_link_sort_relocs): Remove unnecessary pointer
189 2001-10-15 H.J. Lu <hjl@gnu.org>
191 * elflink.h (elf_link_input_bfd): Set type to BFD_RELOC_NONE
192 for relocations against discarded link-once section.
194 2001-10-15 Alan Modra <amodra@bigpond.net.au>
196 * elf32-i386.c (elf_i386_relocate_section): Report some detail on
197 bfd_reloc_outofrange and similar errors.
199 * elf.c (_bfd_elf_link_hash_copy_indirect): Test ind->root.type
200 rather than ind->weakdef.
201 * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Likewise.
202 * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
203 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Likewise.
204 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
205 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
207 2001-10-15 Alan Modra <amodra@bigpond.net.au>
208 H.J. Lu <hjl@gnu.org>
210 * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Merge dyn_reloc
211 counts for aliases instead of aborting.
212 * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
213 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
215 * elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Set plt.offset
216 to -1 for non-function symbols.
217 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Likewise.
218 * elf32-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
219 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
220 * elf64-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
221 * elf64-x86-64.c (elf64_x86_64_adjust_dynamic_symbol): Likewise.
222 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Refer to
223 plt.offset instead of plt.refcount when setting to -1.
225 2001-10-12 Nick Clifton <nickc@cambridge.redhat.com>
227 * elf32-arm.h (elf32_arm_relocate_section): Treat R_ARM_THM_PC22
228 like R_ARM_PC24. Include reloc number in error message about
231 2001-10-10 Jakub Jelinek <jakub@redhat.com>
233 * elflink.h (elf_link_sort_cmp2): Don't mix PLT and non-PLT
234 relocations against the same symbol in .rel{,a}.dyn section.
236 2001-10-10 Kazu Hirata <kazu@hxi.com>
238 * aout-encap.c: Fix comment typos.
240 * archive.c: Likewise.
242 * coff64-rs6000.c: Likewise.
243 * coffcode.h: Likewise.
244 * coffgen.c: Likewise.
245 * cofflink.c: Likewise.
246 * coff-mips.c: Likewise.
248 * elf32-m32r.c: Likewise.
249 * libcoff-in.h: Likewise.
250 * libecoff.h: Likewise.
251 * libxcoff.h: Likewise.
252 * nlm32-i386.c: Likewise.
254 * section.c: Likewise.
257 * bfd-in2.h: Regenerate.
258 * libcoff.h: Likewise.
260 2001-10-10 Alan Modra <amodra@bigpond.net.au>
262 * elf.c (elf_map_symbols): Don't create new section symbols; Use
263 existing section syms. Update comments.
264 (copy_private_bfd_data): Formatting fixes.
265 (elfcore_grok_win32pstatus): Likewise.
266 (swap_out_syms): Likewise. Remove unnecessary level of braces.
268 2001-10-09 Alan Modra <amodra@bigpond.net.au>
270 * elf-bfd.h (struct bfd_elf_section_data): Rename "group" to
272 (elf_group_name): Define.
273 (elf_next_in_group): Define.
274 * elf.c: Make use of elf_group_name and elf_next_in_group throughout.
275 (setup_group): Don't use sec->lineno for SHT_GROUP section to store
276 first member section; Instead use elf_next_in_group.
277 (bfd_section_from_shdr): Likewise.
278 (set_group_contents): Likewise. Use elf_section_syms, not sec->symbol.
280 2001-10-09 Alan Modra <amodra@bigpond.net.au>
282 * elf-bfd.h (struct bfd_elf_section_data): Add "group" and
283 "next_in_group". Fix gp and gp_size comments.
284 * elf.c (union elf_internal_group): New.
285 (setup_group): New function.
286 (_bfd_elf_make_section_from_shdr): Set BFD flags for SHT_GROUP.
287 Call setup_group for SHF_GROUP sections.
288 (bfd_section_from_shdr): Build a BFD section for SHT_GROUP.
289 (elf_fake_sections): Set header type for SEC_GROUP, and header
290 flags for sections in a group.
291 (set_group_contents): New function.
292 (_bfd_elf_compute_section_file_positions): Call it.
293 (assign_section_numbers): Set sh_link for SHT_GROUP.
295 * elflink.h (gc_mark_hook): Handle section groups.
296 * elfxx-target.h: Add SEC_GROUP to applicable_flags.
297 * section.c (SEC_GROUP): Define.
298 (struct sec): Comment fixes.
299 * bfd-in2.h: Regenerate.
301 * elf.c (bfd_elf_print_symbol): Formatting fix; migrate expression
302 out of function args.
303 (_bfd_elf_canonicalize_reloc): Similarly.
304 (_bfd_elf_get_symtab): Here too.
305 (_bfd_elf_canonicalize_dynamic_symtab): And here.
306 * elfcode.h (elf_slurp_symbol_table): Don't recalculate size for
307 bfd_bread, and remove unnecessary cast.
309 2001-10-08 Aldy Hernandez <aldyh@redhat.com>
311 * bfd/config.bfd (targ_cpu): Add arm9e-*-elf.
313 2001-10-06 Stephane Carrez <Stephane.Carrez@worldnet.fr>
315 * dwarf2.c (comp_unit_find_nearest_line): Check for end of
318 2001-10-06 Alan Modra <amodra@bigpond.net.au>
320 * bfd.c (bfd_assert): Report bfd version.
321 (_bfd_abort): Likewise.
323 * elflink.h (elf_link_input_bfd): Don't zero discarded link-once
324 section sym values. Instead replace any relocs against them with
325 relocs against STN_UNDEF, which has a zero value.
327 * elf32-arc.c (elf_arc_howto_table): Set partial_inplace for all
330 2001-10-05 Jeff Law <law@redhat.com>
332 * som.h (som_exec_data): New field "version_id".
333 * som.c (som_object_setup): Record the version_id if it
335 (som_prep_headers): Do not initialize version_id here.
336 (som_finish_writing): Initialize version_id here.
338 2000-10-05 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
340 * elf32-mips.c (elf_mips_howto_table): Fix some relocation howtos
341 according to the MIPS/SGI ELF64 ABI Draft.
342 (mips_elf_sort_hash_table): Typo.
344 2001-10-04 Alan Modra <amodra@bigpond.net.au>
346 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Comment typo.
348 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Bail out after
349 copying flags if this is a weakdef.
351 2001-10-04 Alan Modra <amodra@bigpond.net.au>
353 * elf-bfd.h (struct elf_link_hash_entry): Reorganise for better
356 * elf32-mips.c (mips_elf_record_global_got_symbol): Set got.offset
357 to 1 rather than 0 to avoid confusing copy_indirect_symbol.
358 (mips_elf_sort_hash_table_f): Compare got.offset against 1.
360 * Makefile.am (BFD_H_DEPS): Add symcat.h. Ensure everything
361 depends on $(BFD_H) $(BFD_H_DEPS) $(LOCAL_H_DEPS), not just those
362 backends we configure. Run "make dep-am".
363 (install-data-local): Install symcat.h.
364 * dep-in.sed: Remove symcat.h from dependencies.
365 * Makefile.in: Regenerate.
367 2001-10-03 Vassili Karpov <malc@pulsesoft.com>
369 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Handle nocopyreloc.
371 2001-10-03 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
373 * elf64-mips.c (elf_backend_may_use_rela_p): New define.
374 (elf_backend_default_use_rela_p): New define.
376 2001-10-03 Alan Modra <amodra@bigpond.net.au>
378 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Fix typos in last
381 * configure.in (AC_OUTPUT <bfd-in3.h>): Remove version.h.
382 * configure: Regenerate.
383 * Makefile.am (BFD_H_FILES): Add version.h.
384 * Makefile.in: Regenerate.
385 * po/SRC-POTFILES.in: Regenerate.
387 * elflink.h (elf_fix_symbol_flags): Copy flags to weakdef using
388 elf_backend_copy_indirect_symbol so that backend has a chance to
389 copy other necessary fields.
390 * elf-bfd.h (struct elf_backend_data): Update description of
391 elf_backend_copy_indirect_symbol.
392 * elf.c (_bfd_elf_link_hash_copy_indirect): Bail out after
393 copying flags if this is a weakdef.
394 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
395 (elfNN_ia64_aix_add_symbol_hook): Use elf_link_hash_lookup rather
396 than bfd_link_hash_lookup.
397 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Don't do copy
398 reloc processing for weakdefs.
399 * elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Likewise.
400 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
402 2001-10-02 Alan Modra <amodra@bigpond.net.au>
404 * elf64-ppc.c (ppc64_elf_check_relocs): Use a local var and cast
405 result of ELF64_R_TYPE to enum before using in a switch.
406 (ppc64_elf_gc_mark_hook): Likewise.
407 (ppc64_elf_gc_sweep_hook): Likewise.
408 (ppc64_elf_reloc_type_class): Likewise.
410 2001-10-02 Alan Modra <amodra@bigpond.net.au>
412 * version.h: New file.
413 * bfd-in.h: (BFD_VERSION): Substitute bfd_version.
414 (BFD_VERSION_DATE): Define.
415 (BFD_VERSION_STRING): Define.
416 * configure.in: AC_SUBST bfd_version, bfd_version_date and
418 (AC_OUTPUT <bfd-in3.h>): Depend on version.h.
419 * bfd-in2.h: Regenerate.
420 * configure: Regenerate.
421 * Makefile.am: Run "make dep-am".
422 * Makefile.in: Regenerate.
424 * bfd-in.h: Include "symcat.h".
425 (CONCAT4): Redefine as for old CAT4.
426 * aout-arm.c: Use equivalent CONCAT* macro in place of CAT* macros.
427 Add warning regarding whitespace.
428 * aout-cris.c: Likewise.
429 * aout-ns32k.c: Likewise.
430 * aout-sparcle.c: Likewise.
431 * aout-tic30.c: Likewise.
433 * armnetbsd.c: Likewise.
434 * demo64.c: Likewise.
435 * elf-bfd.h: Likewise.
436 * gen-aout.c: Likewise.
437 * host-aout.c: Likewise.
438 * hp300bsd.c: Likewise.
439 * hp300hpux.c: Likewise.
440 * i386aout.c: Likewise.
441 * i386bsd.c: Likewise.
442 * i386dynix.c: Likewise.
443 * i386freebsd.c: Likewise.
444 * i386linux.c: Likewise.
445 * i386lynx.c: Likewise.
446 * i386mach3.c: Likewise.
447 * i386netbsd.c: Likewise.
448 * libaout.h: Likewise.
449 * m68k4knetbsd.c: Likewise.
450 * m68klinux.c: Likewise.
451 * m68klynx.c: Likewise.
452 * m68knetbsd.c: Likewise.
453 * m88kmach3.c: Likewise.
454 * mipsbsd.c: Likewise.
455 * newsos3.c: Likewise.
456 * ns32knetbsd.c: Likewise.
457 * pc532-mach.c: Likewise.
459 * riscix.c: Likewise.
460 * sparclinux.c: Likewise.
461 * sparclynx.c: Likewise.
462 * sparcnetbsd.c: Likewise.
464 * targets.c: Likewise.
465 * vaxnetbsd.c: Likewise.
466 * vms-hdr.c: Likewise.
468 2001-10-01 Alan Modra <amodra@bigpond.net.au>
470 * bfd-in.h: Remove comments regarding generated files.
471 * libbfd-in.h: Likewise.
472 * libcoff-in.h: Likewise.
473 * bfd-in2.h: Regenerate.
474 * libbfd.h: Likewise.
475 * libcoff.h: Likewise.
477 2001-09-30 kaz Kojima <kkojima@rr.iij4u.or.jp>
478 Hans-Peter Nilsson <hp@bitrange.com>
480 * elf32-sh.c (sh_elf_howto_table, R_SH_REL32): Make
481 partial_inplace, matching assembler output. Set src_mask to
483 (sh_elf_relocate_section): Delete misplaced comment.
484 For relocatable linking against section symbol, call
485 _bfd_relocate_contents for partial_inplace relocs and adjust
486 rel->r_addend for others.
487 <case R_SH_DIR32, R_SH_REL32>: Fetch partial_inplace addend with
488 bfd_get_32, not at rel->r_addend.
490 2001-09-30 Alan Modra <amodra@bigpond.net.au>
492 * elf.c (_bfd_elf_link_hash_copy_indirect): Set ind refcounts to
493 the old dir refcount, so we indirectly set them to init_refcount.
494 Short-circuit asserts when we've just verified they are true.
496 2001-09-29 Alan Modra <amodra@bigpond.net.au>
498 * section.c (struct sec): Remove kept_section.
499 (STD_SECTION): Remove kept_section initialisation.
500 (bfd_make_section_anyway): Here too.
501 * ecoff.c (bfd_debug_section): Remove kept_section initialisation.
502 * cofflink.c (_bfd_coff_link_input_bfd): Don't test kept_section.
503 * elflink.h (elf_link_input_bfd): Set discarded link-once section
504 symbols to zero, and remove all code involved with kept_section
505 and tracking section symbol values.
506 * bfd-in2.h: Regenerate.
507 * configure.in: Bump version number.
508 * configure: Regenerate.
510 2001-09-29 Alan Modra <amodra@bigpond.net.au>
512 * elf64-ppc.c (struct ppc_dyn_relocs): New.
513 (IS_ABSOLUTE_RELOC): Define.
514 (struct ppc_link_hash_entry): New.
515 (struct ppc_link_hash_table): New.
516 (ppc_hash_table): Define.
517 (link_hash_newfunc): New function.
518 (ppc64_elf_link_hash_table_create): New function.
519 (create_got_section): New function.
520 (ppc64_elf_create_dynamic_sections): Call create_got_section. Stash
521 pointers to our dynamic sections in hash table.
522 (ppc64_elf_copy_indirect_symbol): New function.
523 (ppc64_elf_check_relocs): Remove DEBUG code. Use short-cuts to
524 dynamic sections. Localise vars. Modify code for refcounts
525 starting from zero. Don't allocate here, or force symbols dynamic.
526 Don't copy all relocs if shared, select ones we need. Add code
527 to track possible copy relocs for non-shared link.
528 (ppc64_elf_gc_mark_hook): Update comment.
529 (ppc64_elf_gc_sweep_hook): Sweep dynrelocs too.
530 (ppc64_elf_adjust_dynamic_symbol): Remove DEBUG code. Rewrite .plt
531 code for reference counting garbage collection. Don't create .plt
532 entries for functions that don't comply with ABI naming convention,
533 and don't allocate .plt space here. Use short-cuts to dynamic
534 sections. If possible, keep dynamic relocations instead of using
535 copy relocs. Remove confused comments.
536 (ppc_adjust_dynindx): Delete.
537 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
538 (allocate_dynrelocs): New function.
539 (readonly_dynrelocs): New function.
540 (ppc64_elf_size_dynamic_sections): Rewrite. Allocate local .got
541 space here, and call allocate_dynrelocs to allocate space for
542 global .plt, .got and reloc sections. Use short-cuts to dynamic
543 sections. Call readonly_dynrelocs to determine whether we need
544 DT_TEXTREL. Don't generate section symbols here, the generic
545 ELF linker code does it for us.
546 (ppc64_elf_final_link): Call regular ELF backend linker rather than
547 gc variety, since we do our own .got handling.
548 (ppc64_elf_relocate_section): Remove DEBUG code. Make use of
549 dynamic section short-cuts. Localise vars, and delay setting.
550 Handle unknown relocs in main switch statement. Replace ugly
551 complicated tests for unresolvable relocs with a simple direct
552 scheme using "unresolved_reloc" var. Test ELF_ST_VISIBILITY
553 before allowing an undefined sym in a shared lib. Do R_*_DS tests
554 after main switch, when we've set addend. Do non-addend insn
555 tweaks before main swithc. Ignore input_section->vma when
556 calculating reloc offsets as it's always zero. Rewrite dynamic
557 reloc handling. Consolidate R_*_HA handling. Handle more relocs.
558 (ppc64_elf_finish_dynamic_symbol): Remove DEBUG code. Make use
559 of dynamic section short-cuts. Reorganise .plt handling code.
560 Remove confused comments. Take note of ELF_LINK_FORCED_LOCAL.
561 Move expressions out of swap_reloca_out function calls.
562 (ppc64_elf_reloc_type_class): New function.
563 (ppc64_elf_info_to_howto): Move common expression to local var.
564 (ppc64_elf_finish_dynamic_sections): Remove DEBUG code. Make use
565 of dynamic section short-cuts. Don't fiddle with section syms
566 here as the ELF linker does it for us.
567 (elf_backend_can_refcount): Define.
568 (bfd_elf64_bfd_link_hash_table_create): Define.
569 (elf_backend_copy_indirect_symbol): Define.
570 (elf_backend_reloc_type_class): Define.
571 (elf_backend_*, bfd_elf64_bfd_* defines): Sort.
573 2001-09-29 Alan Modra <amodra@bigpond.net.au>
575 * elf-bfd.h (struct elf_link_local_dynamic_entry): Add init_refcount.
576 (struct elf_backend_data): Add can_refcount.
577 * elf.c (_bfd_elf_link_hash_newfunc): Get rid of a few casts. Set
578 got.refcount and plt.refcount from init_refcount.
579 (_bfd_elf_link_hash_table_init): Set up init_refcount.
580 (_bfd_elf_link_hash_copy_indirect): Reference got/plt.refcount
581 rather than got/plt.offset, and test for <= 0 rather than -1.
582 * elflink.h (size_dynamic_sections): Set init_refcount to -1.
583 * elfxx-target.h (elf_backend_can_refcount): Define.
584 (elfNN_bed): Init can_refcount.
585 * linker.c (_bfd_link_hash_newfunc): Get rid of a few casts.
586 (_bfd_generic_link_hash_newfunc): Likewise.
587 * elf32-cris.c (cris_elf_check_relocs): Modify for refcounts
589 (elf_backend_can_refcount): Define.
590 * elf32-hppa.c (elf32_hppa_check_relocs): Modify for refcounts
592 (elf32_hppa_copy_indirect_symbol): Make static to agree with
594 (elf_backend_can_refcount): Define.
595 * elf32-i386.c (elf_i386_check_relocs): Modify for refcounts
597 (allocate_dynrelocs): Set plt/got.offset rather than *.refcount.
598 (elf_i386_finish_dynamic_symbol): Expand SHN_UNDEF comment.
599 (elf_i386_finish_dynamic_sections): Use local var so line < 80 chars.
600 (elf_backend_can_refcount): Define.
601 (elf_i386_copy_indirect_symbol): Make static to agree with
602 prototype. Formatting fix.
603 * elf32-m68k.c (elf_m68k_check_relocs): Modify for refcounts
605 (elf_backend_can_refcount): Define.
606 * elf32-ppc.c (ppc_elf_check_relocs): Modify for refcounts
608 (elf_backend_can_refcount): Define.
609 * elf32-s390.c (elf_s390_check_relocs): Modify for refcounts
611 (elf_backend_can_refcount): Define.
612 * elf64-s390.c (elf_s390_check_relocs): Modify for refcounts
614 (elf_backend_can_refcount): Define.
615 * elf64-x86-64.c (elf64_x86_64_check_relocs): Modify for refcounts
617 (elf_backend_can_refcount): Define.
619 * som.c (som_write_symbol_strings): Cast current_offset in
620 bfd_seek call to match param type.
622 2001-09-28 J. Brobecker <brobecker@gnat.com>
624 * som.c (som_write_symbol_strings): Fix incorrect type of
625 current_offset to match the function definition. Fixes a build
626 failure on HPUX-11.00.
628 2001-09-28 Richard Henderson <rth@redhat.com>
630 * elfxx-target.h [section_flags]: Add SEC_ARCH_BIT_0, SEC_SMALL_DATA,
631 SEC_MERGE, SEC_STRINGS.
633 * section.c (SEC_ARCH_BIT_0): New; replace unused SEC_BALIGN.
634 * bfd-in2.h: Rebuild.
636 2001-09-28 Alan Modra <amodra@bigpond.net.au>
638 * elf64-x86-64.c (elf64_x86_64_reloc_type_lookup): Don't map bfd
639 reloc code using x86_64_reloc_map.
641 * elf32-hppa.c (elf32_hppa_check_relocs): Update comment since we
642 no longer allocate here. Localise some vars to blocks where they
644 (elf32_hppa_adjust_dynamic_symbol): Correct a comment. Delay
645 setting of vars until needed.
646 (allocate_dynrelocs): Don't create a .plt entry without a reloc
647 when symbol visibilty makes a function local.
648 (elf32_hppa_finish_dynamic_symbol): Move expressions out of
649 swap_reloca_out function calls.
650 (elf32_hppa_relocate_section): Likewies. Comment typo fix.
651 (elf32_hppa_finish_dynamic_sections): Migrate common code out of
654 * elf32-i386.c (elf_i386_check_relocs): Update comment since we
655 no longer allocate here. Localise some vars to blocks where they
656 are used. Remove separate switch stmt for creating .got sec.
657 (elf_i386_adjust_dynamic_symbol): Correct a comment. Remove
658 redundant casts and aborts. Delay setting of vars until needed.
659 (allocate_dynrelocs): Remove redundant casts and aborts.
660 (elf_i386_size_dynamic_sections): Move comment.
661 (elf_i386_finish_dynamic_symbol): Move expressions out of function
663 (elf_i386_relocate_section): Likewise. Comment typo fix.
664 (elf_i386_finish_dynamic_sections): Migrate common code out of
666 (elf_backend_* defines): Sort.
668 * elf32-i386.c (allocate_dynrelocs): Don't create a .plt entry
669 without a reloc when symbol visibilty makes a function local.
671 2001-09-27 Nick Clifton <nickc@cambridge.redhat.com>
673 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix detection of
674 conflicting float flags.
676 2001-09-26 Alan Modra <amodra@bigpond.net.au>
678 * elf32-i386 (elf_i386_copy_indirect_symbol): New function.
679 (elf_backend_copy_indirect_symbol): Define.
680 (struct elf_i386_link_hash_entry): Rename "root" to "elf".
681 (struct elf_i386_link_hash_table): Likewise.
682 (link_hash_newfunc): Get rid of unnecessary casts.
683 (elf_i386_link_hash_table_create): Likewise.
684 (elf_i386_check_relocs): Initialise local_got_refcounts to 0.
685 Don't test input section SEC_READONLY here to try to avoid copy
686 relocs, and keep dyn_relocs regardleas of ELF_LINK_NON_GOT_REF.
687 (elf_i386_adjust_dynamic_symbol): Check output section SEC_READONLY
688 here to properly test whether we need copy relocs. Do so for weak
691 * elf32-hppa (elf32_hppa_copy_indirect_symbol): New function.
692 (elf_backend_copy_indirect_symbol): Define.
693 (struct elf32_hppa_link_hash_table): Rename "root" to "elf".
694 (stub_hash_newfunc): Get rid of unnecessary casts.
695 (hppa_link_hash_newfunc): Likewise.
696 (elf32_hppa_check_relocs): Initialise local_got_refcounts to 0.
697 Don't test input section SEC_READONLY here to try to avoid copy
698 relocs, and keep dyn_relocs regardleas of ELF_LINK_NON_GOT_REF.
699 (elf32_hppa_adjust_dynamic_symbol): Check output section SEC_READONLY
700 here to properly test whether we need copy relocs. Do so for weak
703 2001-09-26 Alan Modra <amodra@bigpond.net.au>
705 * bfd.c (_bfd_default_error_handlerl): Define using VPARAMS,
706 VA_OPEN, VA_FIXEDARG, VA_CLOSE.
707 (bfd_archive_filename): Cast bfd_malloc arg to the correct size.
709 2001-09-25 Jakub Jelinek <jakub@redhat.com>
711 * elf64-sparc.c (sparc64_elf_build_plt): Fix .plt[32768+] slot
714 2001-09-25 H.J. Lu <hjl@gnu.org>
716 * bfd-in2.h: Regenerated.
718 2001-09-25 Alan Modra <amodra@bigpond.net.au>
720 * elf32-i386.c: Add comment re linker function names and ordering.
721 (elf_i386_link_hash_newfunc): Rename to link_hash_newfunc.
722 (elf_i386_grok_prstatus): Move before linker functions.
723 (elf_i386_grok_psinfo): Likewise.
724 (elf_i386_fake_sections): Move so that functions are ordered.
725 (elf_i386_reloc_type_class): Likewise. Comment function purpose.
727 2001-09-25 Alan Modra <amodra@bigpond.net.au>
729 * elf32-hppa.c: Rename occurrences of "hplink" to "htab"
732 * elf32-hppa.c: (LONG_BRANCH_PIC_IN_SHLIB): Delete. Remove all
733 code handling this option.
734 (LONG_BRANCH_VIA_PLT): Likewise.
735 (RELATIVE_DYNRELOCS): Define as zero.
736 (struct elf32_hppa_dyn_reloc_entry): Add "sec", and
737 "pc_count" fields. Remove "section" field.
738 (elf32_hppa_link_hash_entry): Rename reloc_entries to dyn_relocs.
739 (elf32_hppa_check_relocs): Don't allocate space for dynamic
740 relocs here. Instead, record all needed dynamic relocs via
741 dyn_relocs and local_dynrel. Cache pointer to "sreloc" section
743 (elf32_hppa_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
744 (allocate_plt_and_got_and_discard_relocs): Rename to
745 allocate_dynrelocs. Allocate rather than discarding dyn relocs.
746 (readonly_dynrelocs): New function.
747 (elf32_hppa_size_dynamic_sections): Mark output_bfd unused.
748 Call readonly_dynrelocs to determine need for DT_TEXTREL.
749 Rename "i" to "ibfd". Allocate space for local dyn relocs.
750 (elf32_hppa_relocate_section): Make use of cached sreloc.
751 (elf32_hppa_reloc_type_class): New function.
752 (elf_backend_reloc_type_class): Define.
754 2001-09-25 Alan Modra <amodra@bigpond.net.au>
756 * elf-bfd.h (struct bfd_elf_section_data): Add "local_dynrel"
758 * elf32-i386.c (struct elf_i386_dyn_relocs): Add "sec", and
759 "pc_count" fields. Remove "section" field.
760 (elf_i386_check_relocs): Don't set DF_TEXTREL here. Don't
761 allocate space for dynamic relocs here. Instead, record all
762 needed dynamic relocs via dyn_relocs and local_dynrel. Cache
763 pointer to "sreloc" section in elf_section_data.
764 (elf_i386_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
765 (allocate_plt_and_got_and_discard_relocs): Rename to
766 allocate_dynrelocs. Allocate rather than discarding dyn relocs.
767 (readonly_dynrelocs): New function.
768 (elf_i386_size_dynamic_sections): Call readonly_dynrelocs.
769 Rename "i" to "ibfd". Allocate space for local dyn relocs.
770 (elf_i386_relocate_section): Make use of cached sreloc.
772 2001-09-24 Alan Modra <amodra@bigpond.net.au>
774 * elf-bfd.h (elf_backend_reloc_type_class): Pass in the entire
775 reloc rather than just the type.
776 (_bfd_elf_reloc_type_class): Likewise.
777 * elf.c (_bfd_elf_reloc_type_class): Likewise.
778 * elf32-arm.h (elf32_arm_reloc_type_class): Likewise.
779 * elf32-cris.c (elf_cris_reloc_type_class): Likewise.
780 * elf32-i386.c (elf_i386_reloc_type_class): Likewise.
781 * elf32-m68k.c (elf32_m68k_reloc_type_class): Likewise.
782 * elf32-ppc.c (ppc_elf_reloc_type_class): Likewise.
783 * elf32-s390.c (elf_s390_reloc_type_class): Likewise.
784 * elf32-sh.c (sh_elf_reloc_type_class): Likewise.
785 * elf32-sparc.c (elf32_sparc_reloc_type_class): Likewise.
786 * elf64-alpha.c (elf64_alpha_reloc_type_class): Likewise.
787 * elf64-s390.c (elf_s390_reloc_type_class): Likewise.
788 * elf64-sparc.c (sparc64_elf_reloc_type_class): Likewise.
789 * elf64-x86-64.c (elf64_x86_64_reloc_type_class): Likewise.
790 * elfxx-ia64.c (elfNN_ia64_reloc_type_class): Likewise.
791 * elflink.h: Formatting fixes.
792 (elf_link_sort_relocs): Make "count" and "size" bfd_size_type.
793 Call bfd_zmalloc rather than calloc. Remove unnecessary cast of
794 o->contents to PTR. Update call to elf_backend_reloc_type_class.
796 2001-09-22 John Reiser <jreiser@BitWagon.com>
798 * elfcode.h (elf_object_p): Allow for no section header at all in
799 non-ET_REL files. Honor 0 for e_shnum, e_shstrndx, e_shoff.
801 2001-09-21 Nick Clifton <nickc@cambridge.redhat.com>
803 * elfxx-ia64.c: Fix compile time warning messages.
804 * coff-mcore.c: Fix compile time warning messages.
805 * coff-ppc.c: Fix compile time warning messages.
806 * coffcode.h: Fix compile time warning messages.
807 * elf32-mips.c: Fix compile time warning messages.
808 * elf64-alpha.c: Fix compile time warning messages.
809 * libbfd.c: Fix compile time warning messages.
810 * bfd-in2.h: Regenerate.
812 2001-09-21 Alan Modra <amodra@bigpond.net.au>
814 * Makefile.am: Run "make dep-am".
815 * Makefile.in: Regenerate.
817 * aoutx.h: Formatting fixes.
818 * merge.c (_bfd_merged_section_offset): Break line at 80 chars.
820 * linker.c: Replace bfd_get_filename with bfd_archive_filename
823 2001-09-21 Alan Modra <amodra@bigpond.net.au>
825 * bfd.c (bfd_archive_filename): New function.
826 * bfd-in2.h: Regenerate.
827 * aout-adobe.c: Replace bfd_get_filename with bfd_archive_filename
828 in error messages where the bfd is an input bfd.
829 * aout-cris.c: Likewise.
830 * coff-arm.c: Likewise.
831 * coff-mcore.c: Likewise.
832 * coff-ppc.c: Likewise.
833 * coff-rs6000.c: Likewise.
834 * coff-sh.c: Likewise.
835 * coff-tic54x.c: Likewise.
836 * coff-tic80.c: Likewise.
837 * coff64-rs6000.c: Likewise.
838 * coffcode.h: Likewise.
839 * coffgen.c: Likewise.
840 * cofflink.c: Likewise.
841 * ecofflink.c: Likewise.
842 * elf-hppa.h: Likewise.
844 * elf32-arm.h: Likewise.
845 * elf32-cris.c: Likewise.
846 * elf32-gen.c: Likewise.
847 * elf32-hppa.c: Likewise.
848 * elf32-i370.c: Likewise.
849 * elf32-i386.c: Likewise.
850 * elf32-m32r.c: Likewise.
851 * elf32-mcore.c: Likewise.
852 * elf32-mips.c: Likewise.
853 * elf32-ppc.c: Likewise.
854 * elf32-s390.c: Likewise.
855 * elf32-sh.c: Likewise.
856 * elf32-sparc.c: Likewise.
857 * elf32-v850.c: Likewise.
858 * elf64-alpha.c: Likewise.
859 * elf64-gen.c: Likewise.
860 * elf64-ppc.c: Likewise.
861 * elf64-s390.c: Likewise.
862 * elf64-sparc.c: Likewise.
863 * elf64-x86-64.c: Likewise.
864 * elflink.h: Likewise.
865 * elfxx-ia64.c: Likewise.
868 * libbfd.c: Likewise.
870 * pe-mips.c: Likewise.
871 * peicode.h: Likewise.
873 * xcofflink.c: Likewise.
875 * elf32-arm.h: Make _bfd_error_handler calls K&R compatible.
877 * elflink.c (_bfd_elf_create_linker_section): Better grammar for
880 * coff-mcore.c (coff_mcore_relocate_section): Internalionalise
883 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Constify stt_types.
884 Consolidate error messages, and split long messages to two lines.
886 2001-09-20 John Reiser <jreiser@BitWagon.com>
888 * elf32-i386.c (elf_i386_relocate_section): Coordinate info->symbolic
889 and info->allow_shlib_undefined.
890 * elf32-cris.c: Likewise.
891 * elf32-hppa.c: Likewise.
892 * elf32-m68k.c: Likewise.
893 * elf32-mips.c: Likewise.
894 * elf32-ppc.c: Likewise.
895 * elf32-s390.c: Likewise.
896 * elf32-sh.c: Likewise.
897 * elf32-sparc.c: Likewise.
898 * elf64-alpha.c: Likewise.
899 * elf64-hppa.c: Likewise.
900 * elf64-ppc.c: Likewise.
901 * elf64-s390.c: Likewise.
902 * elf64-sparc.c: Likewise.
903 * elf64-x86-64.c: Likewise.
904 * elfxx-ia64.c: Likewise.
906 2001-09-18 Bruno Haible <haible@clisp.cons.org>
908 * aoutx.h: Include "safe-ctype.h" instead of <ctype.h>.
909 (aout_link_write_symbols): Use ISDIGIT instead of isdigit.
910 * archive.c: Include "safe-ctype.h" instead of <ctype.h>.
911 (_bfd_generic_read_ar_hdr_mag): Use ISDIGIT instead of isdigit.
912 * archures.c: Include "safe-ctype.h" instead of <ctype.h>.
913 (bfd_default_scan): Use ISDIGIT instead of isdigit.
914 * bfd.c: Include "safe-ctype.h" instead of <ctype.h>.
915 (bfd_scan_vma): Use ISXDIGIT/ISDIGIT/ISLOWER instead of
916 isxdigit/isdigit/islower.
917 * binary.c: Include "safe-ctype.h" instead of <ctype.h>.
918 (mangle_name): Use ISALNUM instead of isalnum.
919 * cpu-v850.c: Include "safe-ctype.h" instead of <ctype.h>.
920 (scan): Use ISDIGIT instead of isdigit.
921 * hosts/alphavms.h: Don't include <ctype.h>.
922 * ieee.c: Include "safe-ctype.h" instead of <ctype.h>.
923 (ieee_object_p): Use TOUPPER instead of toupper.
924 * ihex.c: Include "safe-ctype.h" instead of <ctype.h>.
925 (ihex_bad_byte): Use ISPRINT instead of isprint.
926 * merge.c: Don't include <ctype.h>.
927 * oasys.c: Include "safe-ctype.h" instead of <ctype.h>.
928 (oasys_write_sections): Use ISDIGIT instead of isdigit.
929 * pdp11.c: Include "safe-ctype.h" instead of <ctype.h>.
930 (aout_link_write_symbols): Use ISDIGIT instead of isdigit.
931 * ppcboot.c: Include "safe-ctype.h" instead of <ctype.h>.
932 (mangle_name): Use ISALNUM instead of isalnum.
933 * som.c: Include "safe-ctype.h" instead of <ctype.h>.
934 (som_set_reloc_info): Use ISUPPER/ISLOWER/ISDIGIT instead of
935 isupper/islower/isdigit.
936 (som_decode_symclass): Use TOUPPER instead of toupper.
937 * srec.c: Include "safe-ctype.h" instead of <ctype.h>.
938 (srec_bad_byte): Use ISPRINT instead of isprint.
939 (srec_scan): Use ISSPACE instead of isspace.
940 * stabs.c: Include "safe-ctype.h" instead of <ctype.h>.
941 (_bfd_link_section_stabs): Use ISDIGIT instead of isdigit.
942 * syms.c: Include "safe-ctype.h"
943 (islower, toupper): Remove macro definitions.
944 (bfd_decode_symclass): Use TOUPPER instead of toupper.
945 * vms-gsd.c: Don't include <ctype.h>.
946 * vms-hdr.c: Include "safe-ctype.h" instead of <ctype.h>.
947 (_bfd_vms_write_hdr): Use ISLOWER/TOUPPER instead of
949 * vms-tir.c: Don't include <ctype.h>.
951 2001-09-18 Alan Modra <amodra@bigpond.net.au>
953 * libbfd.c (bfd_bread): New function replacing bfd_read without
954 redundant params. Allow reads up to (size_t) -2 in length.
955 (bfd_bwrite): Similarly for bfd_write.
956 (real_read): Return a size_t.
957 (bfd_read): Call bfd_bread.
958 (bfd_write): Call bfd_bwrite.
959 (warn_deprecated): New function to annoy everybody.
960 (bfd_get_file_window): Don't call bfd_set_error unnecessarily.
961 * bfd-in.h (bfd_bread, bfd_bwrite, warn_deprecated): Declare.
962 (bfd_read, bfd_write): Define as macro.
963 * aix386-core.c: Replace calls to bfd_read with bfd_bread, and
964 likewise for bfd_write. Ensure function args are correct size by
965 using casts or local vars. In some cases, remove unnecessary
966 casts. Formatting fixes, in some cases removing a large expression
967 from function args by using a local var. Replace CONST with const.
968 Modify variable types to avoid warings. Use casts to avoid
969 warnings when using negative numbers in unsigned expressions.
970 * aout-adobe.c: Likewise.
971 * aout-arm.c: Likewise.
972 * aout-cris.c: Likewise.
973 * aout-encap.c: Likewise.
974 * aout-ns32k.c: Likewise.
975 * aout-target.h: Likewise.
976 * aout-tic30.c: Likewise.
977 * aoutf1.h: Likewise.
979 * archive.c: Likewise.
980 * archures.c: Likewise.
981 * bfd-in.h: Likewise.
983 * binary.c: Likewise.
986 * cisco-core.c: Likewise.
987 * coff-a29k.c: Likewise.
988 * coff-alpha.c: Likewise.
989 * coff-arm.c: Likewise.
990 * coff-h8300.c: Likewise.
991 * coff-h8500.c: Likewise.
992 * coff-i386.c: Likewise.
993 * coff-i860.c: Likewise.
994 * coff-i960.c: Likewise.
995 * coff-ia64.c: Likewise.
996 * coff-m68k.c: Likewise.
997 * coff-m88k.c: Likewise.
998 * coff-mcore.c: Likewise.
999 * coff-mips.c: Likewise.
1000 * coff-ppc.c: Likewise.
1001 * coff-rs6000.c: Likewise.
1002 * coff-sh.c: Likewise.
1003 * coff-sparc.c: Likewise.
1004 * coff-stgo32.c: Likewise.
1005 * coff-tic30.c: Likewise.
1006 * coff-tic54x.c: Likewise.
1007 * coff-tic80.c: Likewise.
1008 * coff-w65.c: Likewise.
1009 * coff-z8k.c: Likewise.
1010 * coff64-rs6000.c: Likewise.
1011 * coffcode.h: Likewise.
1012 * coffgen.c: Likewise.
1013 * cofflink.c: Likewise.
1014 * coffswap.h: Likewise.
1015 * corefile.c: Likewise.
1016 * cpu-arc.c: Likewise.
1017 * cpu-h8300.c: Likewise.
1018 * cpu-h8500.c: Likewise.
1019 * cpu-i960.c: Likewise.
1020 * cpu-ia64-opc.c: Likewise.
1021 * cpu-ns32k.c: Likewise.
1022 * cpu-pdp11.c: Likewise.
1023 * cpu-pj.c: Likewise.
1024 * cpu-sh.c: Likewise.
1025 * cpu-w65.c: Likewise.
1026 * cpu-z8k.c: Likewise.
1027 * dwarf1.c: Likewise.
1028 * dwarf2.c: Likewise.
1029 * ecoff.c: Likewise.
1030 * ecofflink.c: Likewise.
1031 * ecoffswap.h: Likewise.
1032 * elf-bfd.h: Likewise.
1033 * elf-hppa.h: Likewise.
1034 * elf-m10200.c: Likewise.
1035 * elf-m10300.c: Likewise.
1037 * elf32-arc.c: Likewise.
1038 * elf32-arm.h: Likewise.
1039 * elf32-avr.c: Likewise.
1040 * elf32-cris.c: Likewise.
1041 * elf32-fr30.c: Likewise.
1042 * elf32-gen.c: Likewise.
1043 * elf32-h8300.c: Likewise.
1044 * elf32-hppa.c: Likewise.
1045 * elf32-i370.c: Likewise.
1046 * elf32-i386.c: Likewise.
1047 * elf32-i860.c: Likewise.
1048 * elf32-m32r.c: Likewise.
1049 * elf32-m68k.c: Likewise.
1050 * elf32-mcore.c: Likewise.
1051 * elf32-mips.c: Likewise.
1052 * elf32-openrisc.c: Likewise.
1053 * elf32-pj.c: Likewise.
1054 * elf32-ppc.c: Likewise.
1055 * elf32-s390.c: Likewise.
1056 * elf32-sh-lin.c: Likewise.
1057 * elf32-sh.c: Likewise.
1058 * elf32-sparc.c: Likewise.
1059 * elf32-v850.c: Likewise.
1060 * elf64-alpha.c: Likewise.
1061 * elf64-hppa.c: Likewise.
1062 * elf64-mips.c: Likewise.
1063 * elf64-ppc.c: Likewise.
1064 * elf64-s390.c: Likewise.
1065 * elf64-sparc.c: Likewise.
1066 * elf64-x86-64.c: Likewise.
1067 * elfarm-nabi.c: Likewise.
1068 * elfcode.h: Likewise.
1069 * elfcore.h: Likewise.
1070 * elflink.c: Likewise.
1071 * elflink.h: Likewise.
1072 * elfxx-ia64.c: Likewise.
1073 * elfxx-target.h: Likewise.
1074 * format.c: Likewise.
1076 * hp300hpux.c: Likewise.
1077 * hppabsd-core.c: Likewise.
1078 * hpux-core.c: Likewise.
1079 * i386aout.c: Likewise.
1080 * i386dynix.c: Likewise.
1081 * i386linux.c: Likewise.
1082 * i386lynx.c: Likewise.
1083 * i386mach3.c: Likewise.
1084 * i386msdos.c: Likewise.
1085 * i386os9k.c: Likewise.
1088 * irix-core.c: Likewise.
1089 * libaout.h: Likewise.
1090 * libbfd-in.h: Likewise.
1091 * libbfd.c: Likewise.
1092 * libcoff-in.h: Likewise.
1093 * libecoff.h: Likewise.
1094 * libieee.h: Likewise.
1095 * libnlm.h: Likewise.
1096 * libpei.h: Likewise.
1097 * libxcoff.h: Likewise.
1098 * linker.c: Likewise.
1099 * lynx-core.c: Likewise.
1100 * m68klinux.c: Likewise.
1101 * merge.c: Likewise.
1102 * mipsbsd.c: Likewise.
1103 * netbsd-core.c: Likewise.
1105 * nlm32-alpha.c: Likewise.
1106 * nlm32-i386.c: Likewise.
1107 * nlm32-ppc.c: Likewise.
1108 * nlm32-sparc.c: Likewise.
1109 * nlmcode.h: Likewise.
1110 * nlmswap.h: Likewise.
1111 * ns32k.h: Likewise.
1112 * oasys.c: Likewise.
1113 * opncls.c: Likewise.
1114 * osf-core.c: Likewise.
1115 * pc532-mach.c: Likewise.
1116 * pdp11.c: Likewise.
1117 * pe-mips.c: Likewise.
1118 * peXXigen.c: Likewise.
1119 * peicode.h: Likewise.
1120 * ppcboot.c: Likewise.
1121 * ptrace-core.c: Likewise.
1122 * reloc.c: Likewise.
1123 * reloc16.c: Likewise.
1124 * riscix.c: Likewise.
1125 * rs6000-core.c: Likewise.
1126 * sco5-core.c: Likewise.
1127 * section.c: Likewise.
1129 * sparclinux.c: Likewise.
1130 * sparclynx.c: Likewise.
1132 * stabs.c: Likewise.
1133 * sunos.c: Likewise.
1135 * targets.c: Likewise.
1136 * tekhex.c: Likewise.
1137 * trad-core.c: Likewise.
1138 * versados.c: Likewise.
1139 * vms-gsd.c: Likewise.
1140 * vms-hdr.c: Likewise.
1141 * vms-misc.c: Likewise.
1142 * vms-tir.c: Likewise.
1145 * xcofflink.c: Likewise.
1146 * bfd-in2.h: Regenerate.
1147 * libbfd.h: Regenerate.
1148 * libcoff.h: Regenerate.
1150 * bfd.c (struct _bfd): Make "where" and "origin" unsigned.
1151 * bfd-in.h (file_ptr): Change from a long int to a bfd_signed_vma.
1152 (ufile_ptr): Define.
1153 (bfd_tell): Return a ufile_ptr.
1154 * libbfd.c (bfd_tell): Likewise.
1155 (bfd_seek): Use bfd_size_type locals. Don't call bfd_set_error
1157 * aix386-core.c: Test != 0 for bfd_seek errors rather than < 0.
1158 * aoutf1.h: Likewise.
1160 * cache.c (bfd_cache_lookup_worker): Guard against abfd->where
1161 larger than unsigned long can represent.
1163 * libbfd.c (bfd_malloc): Take a bfd_size_type arg. Error if
1164 size overflows size_t.
1165 (bfd_realloc): Likewise.
1166 (bfd_zmalloc): Likewise.
1167 * opncls.c (bfd_alloc): Likewise.
1168 (bfd_zalloc): Likewise.
1169 * libbfd-in.h (bfd_malloc, bfd_realloc, bfd_zmalloc): Update.
1170 (bfd_alloc, bfd_zalloc): Update.
1172 * libbfd.c (bfd_get_8): Mask with 0xff in case char is more than
1174 (bfd_get_signed_8): Likewise.
1175 (H_PUT_64, H_PUT_32, H_PUT_16, H_PUT_8,
1176 H_PUT_S64, H_PUT_S32, H_PUT_S16, H_PUT_S8,
1177 H_GET_64, H_GET_32, H_GET_16, H_GET_8,
1178 H_GET_S64, H_GET_S32, H_GET_S16, H_GET_S8): Define and use.
1179 * libaout.h: Likewise define and use here.
1180 * aout-adobe.c: Use H_GET_* and H_PUT_* macros.
1181 * aout-arm.c: Likewise.
1182 * aout-encap.c: Likewise.
1183 * aout-ns32k.c: Likewise.
1184 * aout-tic30.c: Likewise.
1185 * aoutf1.h: Likewise.
1186 * aoutx.h: Likewise.
1188 * coff-alpha.c: Likewise.
1189 * coff-h8300.c: Likewise.
1190 * coff-h8500.c: Likewise.
1191 * coff-i960.c: Likewise.
1192 * coff-ia64.c: Likewise.
1193 * coff-m88k.c: Likewise.
1194 * coff-mips.c: Likewise.
1195 * coff-ppc.c: Likewise.
1196 * coff-rs6000.c: Likewise.
1197 * coff-sh.c: Likewise.
1198 * coff-sparc.c: Likewise.
1199 * coff-stgo32.c: Likewise.
1200 * coff-tic30.c: Likewise.
1201 * coff-tic80.c: Likewise.
1202 * coff-w65.c: Likewise.
1203 * coff-z8k.c: Likewise.
1204 * coff64-rs6000.c: Likewise.
1205 * coffgen.c: Likewise.
1206 * cofflink.c: Likewise.
1207 * coffswap.h: Likewise.
1208 * ecoff.c: Likewise.
1209 * ecoffswap.h: Likewise.
1211 * elf32-mips.c: Likewise.
1212 * elf64-mips.c: Likewise.
1213 * hp300hpux.c: Likewise.
1214 * i386dynix.c: Likewise.
1215 * i386lynx.c: Likewise.
1216 * i386msdos.c: Likewise.
1217 * i386os9k.c: Likewise.
1218 * libpei.h: Likewise.
1219 * nlm32-alpha.c: Likewise.
1220 * nlm32-i386.c: Likewise.
1221 * nlm32-ppc.c: Likewise.
1222 * nlmcode.h: Likewise.
1223 * nlmswap.h: Likewise.
1224 * oasys.c: Likewise.
1225 * pdp11.c: Likewise.
1226 * pe-mips.c: Likewise.
1227 * peXXigen.c: Likewise.
1228 * peicode.h: Likewise.
1229 * riscix.c: Likewise.
1230 * sunos.c: Likewise.
1231 * xcofflink.c: Likewise.
1232 * elfcode.h: (put_word, get_word, put_signed_word, get_signed_word):
1233 Rename to H_PUT_WORD, H_GET_WORD, H_PUT_SIGNED_WORD, H_GET_SIGNED_WORD.
1234 * coff-rs6000.c (PUTWORD, PUTHALF, PUTBYTE): Don't define. Use
1235 equivalent H_PUT_* macro instead.
1236 (GETWORD, GETHALF, GETBYTE): Similarly.
1237 * coff64-rs6000.c (PUTWORD, PUTHALF, PUTBYTE): Likewise.
1238 (GETWORD, GETHALF, GETBYTE): Likewise.
1239 * coffswap.h (PUTWORD, PUTHALF, PUTBYTE): Likewise.
1241 * bfd-in.h (struct orl): Change "pos" to a union.
1242 * archive.c (_bfd_compute_and_write_armap): Use it instead of casts.
1243 (bsd_write_armap): Here too.
1244 (coff_write_armap): And here.
1245 * coff-rs6000.c (xcoff_write_armap_old): And here.
1246 (xcoff_write_one_armap_big): And here.
1247 (xcoff_write_armap_big): And here.
1248 * ecoff.c (_bfd_ecoff_write_armap): And here.
1249 * elf64-mips.c (mips_elf64_write_armap): And here.
1251 * aoutf1.h (sunos_set_arch_mach): Make "mach" param an enum.
1252 * elf-m10300.c (elf_mn10300_mach): Return an unsigned long.
1253 * elf32-h8300.c (elf32_h8_mach): Likewise.
1254 * elf32-mips.c (elf_mips_mach): Likewise.
1255 * sparclynx.c (NAME(lynx,set_arch_mach)): Likewise.
1257 * aix386-core.c (aix386_core_file_p): Remove redundant bfd_release
1259 (aix386_core_vec): Typo fix.
1261 * aout-arm.c: Include libaout.h and aout/aout64.h after N_TXTADDR
1262 etc. to avoid redefined macro warning.
1263 (MY(put_reloc)): Use bfd_vma for "value" rather than long.
1264 (MY(fix_pcrel_26)): Likewise.
1265 * aout-ns32k.c (MY(put_reloc)): Likewise.
1266 * aout-cris.c (MY(swap_ext_reloc_out)): Likewise for r_addend.
1267 * aoutx.h (NAME(aout,swap_ext_reloc_out)): Likewise.
1268 * coff-arm.c (coff_arm_relocate_section): Likewise for my_offset.
1270 * aout-encap.c: Include "file", not <file> for binutils headers.
1271 (encap_object_p): Half baked attempt to fix compile errors in
1272 code dealing with "magic".
1274 * aout-ns32k.c: Include "file", not <file> for binutils headers.
1275 (_bfd_ns32k_relocate_contents): get_data and put_data manipulate
1276 bfd_vma's rather than longs.
1277 * cpu-ns32k.c (ns32k_sign_extend): Delete.
1278 (_bfd_ns32k_get_displacement): Return a bfd_vma, don't pass in offset.
1279 (_bfd_ns32k_get_immediate): Likewise. Add code for 8 byte values,
1281 (_bfd_ns32k_put_displacement): Accept a bfd_vma, don't pass in offset.
1282 Use unsigned comparisons.
1283 (bfd_ns32k_put_immediate): Likewise, and add code for 8 byte values.
1284 (do_ns32k_reloc): get_data and put_data operate on bfd_vma's.
1285 (_bfd_do_ns32k_reloc_contents): Likewise.
1286 * ns32k.h (_bfd_ns32k_get_displacement): Update prototype.
1287 (_bfd_ns32k_get_immediate): Likewise.
1288 (_bfd_ns32k_put_displacement): Likewise.
1289 (_bfd_ns32k_put_immediate): Likewise.
1290 (bfd_reloc_status_type): Likewise.
1292 * aoutx.h (NAME(aout,find_nearest_line)): Rename 'p' to 'colon'
1294 * pdp11.c (NAME(aout,find_nearest_line)): Likewise.
1295 * coff-h8300.c (h8300_reloc16_extra_cases): Remove shadowing "value".
1296 * coff-ppc.c (enum ref_category): Rename "data" to "tocdata" to
1298 (record_toc): Use a bfd_signed_vma for our_toc_offset.
1299 * coffcode.h (coff_write_relocs): Rename "i" to avoid shadowing.
1300 * elf.c (bfd_elf_get_bfd_needed_list): Rename "link" var to avoid
1302 (_bfd_elfcore_strndup): Likewise for "dup".
1303 * elf32-cris.c (cris_elf_relocate_section): "symname" instead of
1304 "name" to avoid shadowing.
1305 * elf32-hppa.c (elf32_hppa_relocate_section): Remove duplicate
1306 definition of "off".
1307 * elf32-i386.c (elf_i386_relocate_section): Likewise.
1308 * elf32-mips.c (_bfd_mips_elf_modify_segment_map): Remove duplicate
1310 (_bfd_mips_elf_final_link): Rename "i" to "j". Remove duplicate
1312 * elf64-x86-64.c (elf64_x86_64_relocate_section): Rename inner "indx"
1314 * elflink.h (elf_link_add_object_symbols): Rename "link" to "shlink"
1316 (elf_link_input_bfd): Likewise.
1317 (elf_bfd_final_link): Remove duplicate innermost "off" var.
1318 * oasys.c (oasys_write_data): Rename innermost "p" to "sym".
1319 * reloc16.c (bfd_coff_reloc16_relax_section): Rename "i" param to
1321 * som.c (som_prep_for_fixups): Rename inner "i" to "j".
1322 * sunos.c (sunos_add_dynamic_symbols): Localise "s" var.
1323 (sunos_write_dynamic_symbol): Remove unused vars.
1324 * syms.c (_bfd_stab_section_find_nearest_line): Remove duplicate
1325 innermost "directory_name" and "file_name" vars.
1326 * tekhex.c (first_phase): Rename local var "type" to "stype".
1327 (tekhex_write_object_contents): Rename innermost "s" to "sym".
1328 * vms-gsd.c (vms_secflag_by_name): Change "size" param to "hassize",
1329 doing comparison at caller.
1330 (vms_esecflag_by_name): Likewise.
1331 * vms-tir.c (etir_sto): Rename innermost "psect" to "psect1".
1332 * xcofflink.c (xcoff_link_input_bfd): Delete duplicate innermost "o".
1333 (xcoff_write_global_symbol): Rename "p" param to "inf".
1335 * cisco-core.c: Add missing prototypes.
1336 (cisco_core_file_failing_command): Add ATTRIBUTE_UNUSED.
1337 (cisco_core_file_failing_signal): Likewise.
1338 (cisco_core_file_matches_executable_p): Likewise.
1339 * hpux-core.c (hpux_core_core_file_failing_signal): Likewise.
1340 * netbsd-core.c (netbsd_core_file_matches_executable_p): Likewise.
1341 * osf-core.c (osf_core_core_file_matches_executable_p): Likewise.
1342 * sco5-core.c (sco5_core_file_matches_executable_p): Likewise.
1344 * coff-arm.c (coff_arm_link_hash_table): Use bfd_size_type for
1345 thumb_glue_size and arm_glue_size.
1346 * elf32-arm.h (elf32_arm_link_hash_table): Likewise here.
1348 * coff64-rs6000.c: Group prototypes together.
1350 * coffcode.h (coff_set_arch_mach): Add ATTRIBUTE_UNUSED.
1351 (buy_and_read): Remove "seek" param. Change "size" to bfd_size_type.
1353 * cpu-arc.c: Add missing prototypes.
1354 * cpu-h8500.c: Likewise.
1355 * cpu-i960.c: Likewise.
1356 * cpu-pj.c: Likewise.
1357 * cpu-sh.c: Likewise.
1358 * cpu-w65.c: Likewise.
1359 * cpu-z8k.c: Likewise.
1360 * elf32-fr30.c: Likewise.
1361 * elf32-h8300.c: Likewise.
1362 * elf32-i370.c: Likewise.
1363 * hpux-core.c: Likewise.
1364 * versados.c: Likewise.
1366 * cpu-h8300.c (bfd_default_scan_num_mach): Don't declare.
1367 * cpu-h8500.c: Likewise.
1368 * cpu-i960.c: Likewise.
1369 * cpu-z8k.c: Likewise.
1371 * cpu-ia64-opc.c: Correct comment.
1373 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Remove unused var.
1375 * elf-bfd.h (elf_size_info): Change count param of write_out_phdrs
1377 (bfd_elf32_write_out_phdrs): Likewise.
1378 (bfd_elf64_write_out_phdrs): Likewise.
1379 (elf_linker_section_pointers): Change addend to bfd_vma.
1380 (_bfd_elf_find_pointer_linker_section): Likewise.
1381 (_bfd_elfcore_make_pseudosection): Change size param to size_t and
1382 filepos to unsigned file_ptr.
1383 (_bfd_elfcore_strndup): Change max param to size_t.
1384 * elf.c (_bfd_elfcore_make_pseudosection): As above.
1385 (_bfd_elfcore_strndup): Likewise.
1386 (_bfd_elf_find_pointer_linker_section): Likewise.
1388 * elf-hppa.h (elf_hppa_relocate_insn): Return an int, and change
1389 insn and sym_value to ints.
1391 * elf.c (elf_read): Make "offset" param a file_ptr, "size" a
1393 (elfcore_read_notes): Likewise.
1395 * elf32-arm.h (elf32_arm_final_link_relocate): Change sym_flags
1396 param from unsigned char to int.
1397 (elf32_arm_relocate_section): If USE_REL, cast "rel" appropriately
1398 for info_to_howto call.
1399 (add_dynamic_entry): Define macro.
1400 (elf32_arm_size_dynamic_sections): Use add_dynamic_entry.
1402 * elf32-cris.c (add_dynamic_entry): Define macro.
1403 (elf_cris_size_dynamic_sections): Use add_dynamic_entry.
1405 * elf32-h8300.c (elf32_h8_final_write_processing): Make static.
1406 (elf32_h8_object_p): Likewise.
1407 (elf32_h8_merge_private_bfd_data): Likewise.
1408 (elf32_h8_relax_section): Cast gap to int so signed comparisons work.
1410 * elf32-hppa.c (add_dynamic_entry): Define macro.
1411 (elf32_hppa_size_dynamic_sections): Use it.
1412 * elf32-i370.c (add_dynamic_entry): Define macro.
1413 (i370_elf_size_dynamic_sections): Use it.
1414 (i370_noop): Make static.
1415 * elf32-i386.c (add_dynamic_entry): Define macro.
1416 (elf_i386_size_dynamic_sections): Use it.
1417 * elf32-m68k.c (add_dynamic_entry): Define macro.
1418 (elf_m68k_size_dynamic_sections): Use it.
1419 * elf32-ppc.c (add_dynamic_entry): Define macro.
1420 (ppc_elf_size_dynamic_sections): Use it.
1421 * elf32-s390.c (add_dynamic_entry): Define macro.
1422 (elf_s390_size_dynamic_sections): Use it.
1423 * elf64-alpha.c (add_dynamic_entry): Define macro.
1424 (elf64_alpha_size_dynamic_sections): Use it.
1425 * elf64-hppa.c (add_dynamic_entry): Define macro.
1426 (elf64_hppa_size_dynamic_sections): Use it.
1427 * elf64-ppc.c (add_dynamic_entry): Define macro.
1428 (ppc64_elf_size_dynamic_sections): Use it.
1429 * elf64-s390.c (add_dynamic_entry): Define macro.
1430 (elf_s390_size_dynamic_sections): Use it.
1431 * elf64-sparc.c (add_dynamic_entry): Define macro.
1432 (sparc64_elf_size_dynamic_sections): Use it.
1433 * elf64-x86-64.c (add_dynamic_entry): Define macro.
1434 (elf64_x86_64_size_dynamic_sections): Use it.
1435 * elfxx-ia64.c (add_dynamic_entry): Define macro.
1436 (elfNN_ia64_size_dynamic_sections): Use it.
1438 * elf32-v850.c (SEXT24): Modify to avoid signed/unsigned warning.
1439 (v850_elf_perform_relocation): Make "r_type" param unsigned.
1441 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Just return
1442 false if the first malloc fails rather than going via error_return.
1444 * elf64-sparc.c (sparc64_elf_plt_entry_offset): Use a bfd_vma for
1446 (sparc64_elf_plt_ptr_offset): Likewise, and for "max" param too.
1448 * elflink.h (elf_link_input_bfd): s/ingored/ignored/ in error message.
1450 * elfxx-ia64.c (global_sym_index): Return a long.
1452 * ieee.c (get_symbol): Use int rather than char param.
1453 (ieee_slurp_sections): Move "section" var to inner blocks.
1454 (copy_expression): Don't init "value" to zero or worry about
1455 clearing to zero after using.
1456 (ieee_write_debug_part): Rename "output_buffer" to "obuff" to avoid
1459 * ihex.c (ihex_write_record): Make "count" var a size_t, "addr" an
1462 * libbfd-in.h (BFD_ALIGN): Add cast to avoid signed/unsigned warning.
1463 (bfd_write_bigendian_4byte_int): Pass an unsigned int value param.
1465 * mipsbsd.c (mips_fix_jmp_addr): Add "error_message" param.
1467 * pc532-mach.c (MYNSX): Delete.
1468 (ns32kaout_bfd_reloc_type_lookup): Define prototype without MYNSX.
1469 (write_object_contents): Correct prototype.
1471 * peicode.h (pe_ILF_build_a_bfd): Use an unsigned int param rather
1472 than unsigned short.
1474 * section.c (bfd_set_section_contents): Remove redundant
1475 "offset < 0" test. Check that "count" doesn't overflow size_t.
1476 (bfd_get_section_contents): Likewise.
1478 * som.c (som_fixup_formats): Add missing braces.
1479 (som_reloc_addend): Pass a bfd_vma for "addend".
1481 * srec.c (srec_write_record): Pass "type" as an unsigned int.
1482 (srec_write_symbols): Remove an unnecessary var.
1484 * targets.c (_bfd_target_vector): Sort entries. Sort externs
1486 * configure.in: Sort to match. Bump version number.
1487 * configure: Regenerate.
1489 * tekhex.c (move_section_contents): Assert offset == 0.
1491 * versados.c (new_symbol_string): Constify arg.
1492 (process_esd): Use bfd_und_section_ptr rather than &bfd_und_section.
1493 (versados_get_symbol_info): Make static.
1494 (versados_print_symbol): Likewise.
1495 (versados_get_reloc_upper_bound): Likewise.
1496 (versados_canonicalize_reloc): Likewise.
1498 2001-09-18 Nick Clifton <nickc@cambridge.redhat.com>
1500 * elflink.h (elf_link_input_bfd): Fix typo in error message.
1502 2001-09-17 H.J. Lu <hjl@gnu.org>
1504 * dwarf1.c (parse_die): Take a new arg for the end of the
1505 section. Return false if die is beyond the section.
1506 (parse_functions_in_unit): Pass the end of the section to
1508 (_bfd_dwarf1_find_nearest_line): Likewise.
1510 2001-09-14 Michael Rauch <mrauch@netbsd.org>
1512 * elf32-sparc.c (elf32_sparc_relocate_section): Treat R_SPARC_UA32
1513 just like R_SPARC_32.
1515 2001-09-14 Kevin Lo <kevlo@openbsd.org>
1517 * configure.bfd: Add arm-openbsd target.
1519 2001-09-14 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1521 * config.bfd: Change machine triplets from mips*el*-* to mips*el-*.
1522 Add support for mips64.
1524 2001-09-13 Alexandre Oliva <aoliva@redhat.com>
1526 * elf32-openrisc.c (ELF_MACHINE_ALT1): Define as EM_OPENRISC_OLD.
1528 2001-09-12 Alexandre Oliva <aoliva@redhat.com>
1530 * elf.c (prep_headers): Get the machine code from the elf
1532 * elf-m10200.c (ELF_MACHINE_CODE): Redefine to EM_MN10200.
1533 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_MN10200.
1534 * elf-m10300.c (ELF_MACHINE_CODE): Redefine to EM_MN10300.
1535 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_MN10300.
1536 * elf-arc.c (arc_elf_final_write_processing): Don't override
1537 e_machine, it's now properly set in prep_headers.
1538 * elf32-avr.c (elf32_avr_object_p): Accept both EM_AVR and
1540 (ELF_MACHINE_ALT1): Define to EM_AVR_OLD.
1541 * elf-d10v.c (ELF_MACHINE_CODE): Redefine to EM_D10V.
1542 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_D10V.
1543 * elf-d30v.c (ELF_MACHINE_CODE): Redefine to EM_D30V.
1544 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_D30V.
1545 * elf-fr30.c (ELF_MACHINE_CODE): Redefine to EM_FR30.
1546 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_FR30.
1547 * elf-m32r.c (ELF_MACHINE_CODE): Redefine to EM_M32R.
1548 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_M32R.
1549 * elf32-pj.c (ELF_MACHINE_ALT1): DEfine to EM_PJ_OLD.
1550 * elf-v850.c (ELF_MACHINE_CODE): Redefine to EM_V850.
1551 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_V850.
1553 2001-09-11 Richard Henderson <rth@redhat.com>
1555 * elf64-alpha.c (elf64_alpha_section_flags): New.
1556 (elf64_alpha_fake_sections): Map SEC_SMALL_DATA to SHF_ALPHA_GPREL.
1558 2001-09-11 Richard Henderson <rth@redhat.com>
1560 * elf64-alpha.c (elf64_alpha_relocate_section): Do not
1561 apply HINT relocations against dynamic symbols.
1563 2001-09-11 H.J. Lu <hjl@gnu.org>
1565 * linker.c (link_action): Change COMMON_ROW\defw from CREF to COM.
1567 2001-09-09 Richard Henderson <rth@redhat.com>
1569 * elf64-alpha.c: Delete all unused ERIC_neverdef and rth_notdef code.
1571 * elf64-alpha.c (elf64_alpha_relax_with_lituse): Nop out gpdisp
1572 following a call to a near function.
1574 2001-09-08 Richard Henderson <rth@redhat.com>
1576 * elf64-alpha.c (elf64_alpha_relocate_section): Soft fail
1577 relocation errors. Fail gp-relative relocations against
1580 2001-09-08 Alan Modra <amodra@bigpond.net.au>
1582 * elf32-i386.c (elf_i386_relocate_section): Check !DEF_REGULAR
1583 as well as DEF_DYNAMIC in test for avoided copy relocs.
1584 (allocate_plt_and_got_and_discard_relocs): Likewise.
1585 * elf32-hppa.c (elf_i386_relocate_section): Likewise.
1586 (allocate_plt_and_got_and_discard_relocs): Likewise.
1588 2001-09-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1590 * elf32-mips.c (mips_elf_calculate_relocation): Fix overflow handling
1593 2001-09-06 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1595 * elf64-mips.c (mips_elf64_howto_table_rel): Fix relocation HOWTO
1597 (mips_elf64_howto_table_rel): Likewise.
1599 2001-09-05 Tom Rix <trix@redhat.com>
1601 * xcofflink.c (bfd_xcoff_import_symbol): Handle import file XMC_XO
1602 and syscall symbols.
1603 (write_global_symbol) : Same.
1604 (bfd_xcoff_export_symbol): Remove unused syscall param.
1605 * libxcoff.h: Change prototype of bfd_xcoff_export symbol and
1606 bfd_xcoff_import_symbol.
1608 * bfd-in2.h : Regenerate.
1610 2001-09-04 Richard Henderson <rth@redhat.com>
1612 * elf64-alpha.c (SKIP_HOWTO): New.
1613 (elf64_alpha_howto_table): Use it to remove dead ECOFF relocs.
1614 Fix sizes of 16-bit mem format relocs.
1615 (elf64_alpha_reloc_map): Update to match.
1616 (elf64_alpha_relax_with_lituse): Use GPREL16 as appropriate.
1617 (elf64_alpha_relax_without_lituse): Likewise.
1618 (elf64_alpha_check_relocs): Handle GPREL16.
1619 (elf64_alpha_relocate_section): Likewise.
1620 * reloc.c (BFD_RELOC_ALPHA_USER_*): Remove.
1621 (BFD_RELOC_ALPHA_GPREL_HI16, BFD_RELOC_ALPHA_GPREL_LO16): New.
1622 * bfd-in2.h, libbfd.h: Rebuild.
1624 2001-09-04 Jeff Law <law@redhat.com>
1626 * elf32-h8300.c (elf32_h8_relax_section): New function.
1627 (elf32_h8_relax_delete_bytes): Likewise.
1628 (elf32_h8_symbol_address_p): Likewise.
1629 (elf32_h8_get_relocated_section_contents): Likewise.
1630 (bfd_elf32_bfd_relax_section): Define.
1631 (bfd_elf32_bfd_get_relocated_section_contents): Likewise.
1633 * elf32-h8300.c (special): New function.
1634 (h8_elf_howto_table): Use it for SPECIAL_FUNCTION field in
1636 (elf32_h8_final_link_relocate): Treat R_H8_DIR24A8 like 32bit
1637 relocations. Fix problems with the true 24bit reloc R_H8_DIR24R8.
1638 Fix minor problems with 8bit and 16bit PC relative relocations.
1640 2001-09-01 Andreas Jaeger <aj@suse.de>
1642 * vms-tir.c: Add missing prototypes.
1643 * vms-hdr.c: Likewise.
1644 * vms-gsd.c: Likewise.
1645 * vms-misc.c: Likewise.
1647 2001-08-31 H.J. Lu <hjl@gnu.org>
1649 * elf32-mips.c (_bfd_mips_elf_check_relocs): Report filename
1650 with bad relocation.
1652 2001-08-31 Eric Christopher <echristo@redhat.com>
1653 Jason Eckhardt <jle@redhat.com>
1655 * bfd/archures.c: Add mipsisa32 and mipsisa64. Remove mips32,
1656 mips32_4k and mips64.
1657 * bfd/aoutx.h: Remove bfd_mach_mips32, bfd_mach_mips32_4k,
1658 bfd_mach_mips64. Add bfd_mach_mipsisa32, bfd_mach_mipsisa64.
1659 * bfd/cpu-mips.c: Ditto.
1660 * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing): Ditto.
1661 * bfd/bfd-in2.h: Regenerate.
1663 2001-08-31 Jakub Jelinek <jakub@redhat.com>
1665 * elf64-alpha.c (elf64_alpha_relocate_section): Duplicate memory
1666 value into R_ALPHA_RELATIVE's addend.
1667 (elf64_alpha_finish_dynamic_symbol): Likewise.
1669 2001-08-31 Nick Clifton <nickc@cambridge.redhat.com>
1671 * elf32-arm.h (elf32_arm_relocate_section): Do not rightshift
1672 recomputed addend during relocatable link if not USE_REL.
1674 * elflink.h (elf_gc_propagate_vtable_entries_used): Fix off-by-one
1677 2001-08-30 H.J. Lu <hjl@gnu.org>
1679 * elf32-mips.c (mips_elf_calculate_relocation): Revert the last
1681 (_bfd_mips_elf_adjust_dynamic_symbol): Allocate dynamic
1682 relocations for weak definitions.
1684 2001-08-30 H.J. Lu <hjl@gnu.org>
1686 * Makefile.am (BFD32_BACKENDS): Add elf32-h8300.lo.
1687 (BFD32_BACKENDS_CFILES): Add elf32-h8300.c.
1688 * Makefile.in: Rebuild.
1690 2001-08-30 H.J. Lu <hjl@gnu.org>
1692 * elf32-mips.c (mips_elf_calculate_relocation): Don't create
1693 dynamic relocation for undefined weak symbols when creating
1694 executables. Check h->root.root.type, instead of h->root.type.
1696 2001-08-29 Joel Sherrill <joel@OARcorp.com>
1698 * config.bfd (i[3456]86-*-rtems*, m68*-*-rtems*): Change
1699 default from coff to elf.
1701 2001-08-29 Jeff Law <law@redhat.com>
1703 * elf32-h8300.c (h8_elf_howto_table): Add new PC relative
1705 (h8_reloc_map): Similarly.
1706 (elf32_h8_final_link_relocate): Remove incorrect overflow tests.
1707 Add support for PC relative relocations.
1709 * elf32-h8300.c: Put all prototypes together.
1710 (elf32_h8_info_to_howto): Parameter elf_reloc is used.
1711 (elf32_h8_final_link_relocate): New function for linker.
1712 (elf32_h8_relocate_section): Similarly.
1713 (elf_backend_relocate_section): Define.
1715 * cpu-h8300.c (h8300_scan, compatible): Prototype.
1716 (h8300_scan): Handle architecture:machine encodings typically
1717 found in linker scripts.
1718 * elf.c (prep_headers): Do not try to do H8 machine recognition
1720 * elf32-h8300.c: Add some missing prototypes.
1721 (elf32_h8_mach, elf32_h8_final_write_processing): New functions.
1722 (elf32_h8_object_p): Similarly.
1724 2001-08-29 Tom Rix <trix@redhat.com>
1726 * xcofflink.c (xcoff_link_add_symbols): Fix XTY_LD symbol that
1727 does not follow a XTY_SD.
1729 2001-08-29 Alan Modra <amodra@bigpond.net.au>
1731 * targmatch.sed: Delete case statements.
1732 * config.bfd <powerpc-*-aix* entry>: Select 64 bit xcoff for
1735 Wed Aug 29 02:27:36 2001 J"orn Rennecke <amylaar@redhat.com>
1737 * Makefile.am (elf32-h8300.lo): New target.
1738 * config.bfd (h8300*-*-elf): New case.
1739 * configure.in (bfd_elf32_h8300_vec): New case.
1740 * elf.c (prep_headers): Add case for bfd_arch_h8300.
1741 * reloc.c (BFD_RELOC_H8_DIR16A8): New relocation.
1742 (BFD_RELOC_H8_DIR16R8, BFD_RELOC_H8_DIR24A8): Likewise.
1743 (BFD_RELOC_H8_DIR24R8, BFD_RELOC_H8_DIR32A16): Likewise.
1744 * targets.c (bfd_target bfd_elf32_h8300_vec): New extern declaration.
1745 * elf32-h8300.c: New file.
1746 * Makefile.in, bfd-in2.h, libbfd.h, configure: Regenerated.
1748 2001-08-28 Nick Clifton <nickc@cambridge.redhat.com>
1750 * sparclynx.c: Add missing prototypes.
1751 * coff-mcore.c: Add missing prototypes.
1752 * elf32-pj.c: Add missing prototypes.
1753 * nlm32-sparc.c: Add missing prototypes.
1754 * oasys.c: Add missing prototypes.
1755 * pdp11.c: Add missing prototypes.
1756 * pe-mips.c: Add missing prototypes.
1757 * riscix.c: Add missing prototypes.
1759 2001-08-27 Daniel Jacobowitz <drow@mvista.com>
1761 * elf32-i386.c: Add missing prototypes.
1762 * elf32-ppc.c: Likewise.
1763 * elf32-sh-lin.c: Likewise.
1764 * elfarm-nabi.c: Likewise.
1766 2001-08-27 Daniel Jacobowitz <drow@mvista.com>
1768 * elf32-i386.c (elf_i386_grok_prstatus): New function.
1769 (elf_i386_grok_psinfo): New function.
1770 (elf_backend_grok_prstatus): Define.
1771 (elf_backend_grok_psinfo): Likewise.
1772 * elf32-ppc.c (ppc_elf_grok_prstatus): New function.
1773 (ppc_elf_grok_psinfo): New function.
1774 (elf_backend_grok_prstatus): Define.
1775 (elf_backend_grok_psinfo): Likewise.
1776 * elf32-sh-lin.c (elf32_shlin_grok_prstatus): New function.
1777 (elf32_shlin_grok_psinfo): New function.
1778 (elf_backend_grok_prstatus): Define.
1779 (elf_backend_grok_psinfo): Likewise.
1780 * elfarm-nabi.c (elf32_arm_nabi_grok_prstatus): New function.
1781 (elf32_arm_nabi_grok_psinfo): New function.
1782 (elf_backend_grok_prstatus): Define.
1783 (elf_backend_grok_psinfo): Likewise.
1785 2001-08-27 H.J. Lu <hjl@gnu.org>
1787 * elf32-mips.c (mips_elf_create_dynamic_relocation): Add more
1789 (mips_elf_calculate_relocation): Create dynamic relocation for
1790 symbols with weak definition or the ELF_LINK_HASH_DEF_REGULAR
1793 2001-08-27 H.J. Lu <hjl@gnu.org>
1795 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Add prototype.
1796 (_bfd_mips_elf_copy_indirect_symbol): Likewise.
1797 (_bfd_elf32_mips_grok_prstatus): Likewise.
1798 (_bfd_elf32_mips_grok_psinfo): Likewise.
1799 (_bfd_mips_elf_hide_symbol): Make it static and cast to
1800 `struct mips_elf_link_hash_entry *'.
1801 (_bfd_mips_elf_copy_indirect_symbol): Make it static.
1803 2001-08-27 Nick Clifton <nickc@cambridge.redhat.com>
1805 * mipsbsd.c: Add missing prototypes.
1806 * hp300hpux.c: Add missing prototypes.
1807 * i386aout.c: Add missing prototypes.
1808 * i386lynx.c: Add missing prototypes.
1809 * i386mach3.c: Add missing prototypes.
1810 * i386msdos.c: Add missing prototypes.
1811 * i386os9k.c: Add missing prototypes.
1813 2001-08-27 Linus Nordberg <linus@swox.se>
1814 Torbjorn Granlund <tege@swox.com>
1815 Staffan Ulfberg <staffanu@swox.se>
1816 Alan Modra <amodra@bigpond.net.au>
1818 * config.bfd: Add powerpc64 target. Add powerpc64 vectors to
1819 targ64_selvecs for 32 bit powerpc targets.
1820 * Makefile.am (BFD64_BACKENDS): Add elf64-ppc.lo.
1821 (BFD64_BACKENDS_CFILES): Add elf64-ppc.c.
1823 * Makefile.in: Regenerate.
1824 * configure.in: Add elf64_powerpc vecs.
1825 * configure: Regenerate.
1826 * cpu-powerpc.c: Default to bfd_mach_ppc_620 entry for 64 bit.
1827 * elf.c (prep_headers): EM_PPC64 for 64 bit ppc elf target.
1828 * targets.c: Add bfd_elf64_powerpc_vec and bfd_elf64_powerpcle_vec.
1829 * elf64-ppc.c: New file.
1830 * reloc.c: Add powerpc64 relocs.
1831 * libbfd.h: Regenerate.
1832 * bfd-in2.h: Regenerate.
1834 2001-08-27 Andreas Schwab <schwab@suse.de>
1836 * elf32-m68k.c (elf32_m68k_check_relocs): Set DF_TEXTREL if the
1837 reloc is against read-only section.
1838 (elf32_m68k_size_dynamic_sections): Use DF_TEXTREL flag instead of
1839 looking up section names for DT_TEXTREL.
1840 (elf32_m68k_reloc_type_class): New function.
1841 (elf_backend_reloc_type_class): Define.
1843 2001-08-27 Andreas Jaeger <aj@suse.de>
1845 * elf64-s390.c (elf_s390_check_relocs): Set DF_TEXTREL if the
1846 reloc is against read-only section.
1847 (elf_s390_size_dynamic_sections): Use DF_TEXTREL flag instead of
1848 looking up section names for DT_TEXTREL.
1849 (elf_s390_reloc_type_class): New.
1850 (elf_backend_reloc_type_class): Define.
1852 * elf32-s390.c (elf_s390_check_relocs): Set DF_TEXTREL if the
1853 reloc is against read-only section.
1854 (elf_s390_size_dynamic_sections): Use DF_TEXTREL flag instead of
1855 looking up section names for DT_TEXTREL.
1856 (elf_s390_reloc_type_class): New.
1857 (elf_backend_reloc_type_class): Define.
1859 * elf32-ppc.c (ppc_elf_check_relocs): Set DF_TEXTREL if the reloc
1860 is against read-only section.
1861 (ppc_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
1862 looking up section names for DT_TEXTREL.
1863 (ppc_elf_reloc_type_class): New.
1864 (elf_backend_reloc_type_class): Define.
1866 2001-08-26 Andreas Jaeger <aj@suse.de>
1868 * elf32-cris.c (cris_elf_check_relocs): Set DF_TEXTREL if the
1869 reloc is against read-only section.
1870 (elf_cris_size_dynamic_sections): Use DF_TEXTREL flag instead of
1871 looking up section names for DT_TEXTREL.
1872 (elf_cris_reloc_type_class): New.
1873 (elf_backend_reloc_type_class): Define.
1875 * elf32-sh.c (sh_elf_check_relocs): Set DF_TEXTREL if the reloc is
1876 against read-only section.
1877 (elf_backend_reloc_type_class): Define.
1878 (sh_elf_reloc_type_class): New.
1879 (sh_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
1880 looking up section names for DT_TEXTREL.
1882 * elf32-arm.h (elf32_arm_check_relocs): Set DF_TEXTREL if the
1883 reloc is against read-only section.
1884 (elf32_arm_size_dynamic_sections): Use DF_TEXTREL flag instead of
1885 looking up section names for DT_TEXTREL.
1886 (elf32_arm_reloc_type_class): New.
1887 (elf_backend_reloc_type_class): Define.
1889 2001-08-25 Andreas Jaeger <aj@suse.de>
1891 * oasys.c: Add missing prototypes.
1893 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Add unused
1894 attribute for parameter.
1895 * elf.c (_bfd_elf_reloc_type_class): Likewise.
1897 * versados.c (get_4): Make static.
1898 (get_10): Make static.
1899 Add missing prototypes.
1900 (process_esd): Fix call to versados_new_symbol.
1902 2001-08-25 Nick Clifton <nickc@cambridge.redhat.com>
1904 * coff-a29k.c: Add missing prototypes.
1905 * coff-apollo.c: Add missing prototypes.
1906 * coff-arm.c: Add missing prototypes.
1907 * coff-i860.c: Add missing prototypes.
1908 * coff-rs6000.c: Add missing prototypes.
1909 * coff-tic80.c: Add missing prototypes.
1910 * elf-m10200.c: Add missing prototypes.
1911 * elf-m10300.c: Add missing prototypes.
1912 * elf32-arm.h: Add missing prototypes.
1913 * elf32-d10v.c: Add missing prototypes.
1914 * elf32-m32r.c: Add missing prototypes.
1915 * elf32-mcore.c: Add missing prototypes.
1916 * elf32-openrisc.c: Add missing prototypes.
1917 * elf32-sh.c: Add missing prototypes.
1918 * elf32-sparc.c: Add missing prototypes.
1919 * elf32-v850.c: Add missing prototypes.
1920 * elfarm-nabi.c: Add missing prototypes.
1921 * elfarm-oabi.c: Add missing prototypes.
1923 2001-08-25 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1925 * elf32-mips.c (elf_mips_abi_name): Return the right ABI string for
1926 E_MIPS_ABI_O64 and E_MIPS_ABI_EABI64
1928 2001-08-24 H.J. Lu <hjl@gnu.org>
1930 * elf.c (_bfd_elf_merge_sections): Fail if not using an ELF
1933 2001-08-24 Nick Clifton <nickc@cambridge.redhat.com>
1935 * elf-bfd.h (elf_hash_table): Revert definition.
1936 (is_elf_hash_table): New macro.
1937 * elflink.h (elf_link_add_object_symbols): Test
1938 is_elf_hash_table before accessing ELF only fields in hash
1940 (elf_link_create_dynamic_sections): Fail if not using an ELF
1942 (elf_add_dynamic_entry): Fail if not using an ELF hash
1944 (elf_link_record_local_dynamic_symbol): Fail if not using an
1946 (size_dynamic_sections): Fail if not using an ELF hash
1948 (elf_adjust_dynamic_symbol): Fail if not using an ELF
1950 (elf_bfd_final_link): Fail if not using an ELF hash
1953 2001-08-24 H.J. Lu <hjl@gnu.org>
1955 * elf-bfd.h (elf_hash_table): Return NULL if the linker hash
1956 table is not an ELF linker hash table.
1958 * elf.c (_bfd_elf_link_hash_table_init): Set the linker hash
1959 table type to bfd_link_elf_hash_table.
1961 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_create): Revert
1964 * linker.c (_bfd_link_hash_table_init): Set the linker hash
1965 table type to bfd_link_generic_hash_table.
1967 2001-08-24 Alexandre Oliva <aoliva@redhat.com>
1969 * bfd.c (bfd_alt_mach_code): New function.
1970 * bfd-in2.h: Rebuilt.
1972 2001-08-24 Alexandre Oliva <aoliva@redhat.com>
1974 * elf-m10300.c (mn10300_elf_relocate_section): Test the right
1975 `type' field in the hash entry when deciding whether to follow a
1978 2001-08-24 Jakub Jelinek <jakub@redhat.com>
1980 * elflink.h (elf_link_sort_cmp1): Sort RELATIVE relocs first, not
1982 (elf_link_sort_relocs): Adjust accordingly.
1984 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Add reltext flag.
1985 (elf64_alpha_check_relocs): Set it if section this reloc is against
1986 is read-only. Set DF_TEXTREL if a RELATIVE reloc is needed against
1988 (elf64_alpha_calc_dynrel_sizes): Set DF_TEXTREL flag if relocation
1989 is is against read-only section.
1990 (elf64_alpha_size_dynamic_sections): Use DF_TEXTREL flag, don't
1991 check section names.
1992 (elf64_alpha_reloc_type_class): New.
1993 (elf_backend_reloc_type_class): Define.
1995 2001-08-24 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1997 * linker.c (_bfd_generic_link_add_archive_symbols): Replace alloca()
2000 2001-08-23 Andreas Jaeger <aj@suse.de>
2002 * elf64-x86-64.c (elf64_x86_64_check_relocs): Set DF_TEXTREL if
2003 the reloc is against read-only section.
2004 (elf64_x86_64_size_dynamic_sections): Use DF_TEXTREL flag instead
2005 of looking up section names for DT_TEXTREL.
2006 (elf64_x86_64_reloc_type_class): New.
2007 (elf_backend_reloc_type_class): Define.
2009 2001-08-23 H.J. Lu <hjl@gnu.org>
2011 * syms.c (bfd_print_symbol_vandf): Add abfd to arg.
2012 * bfd-in2.h (bfd_print_symbol_vandf): Regenerated.
2014 * aoutx.h (NAME(aout,print_symbol)): Pass abfd to
2015 bfd_print_symbol_vandf.
2016 * coffgen.c (coff_print_symbol): Likewise.
2017 * elf.c (bfd_elf_print_symbol): Likewise.
2018 * ieee.c (ieee_print_symbol): Likewise.
2019 * nlmcode.h (nlm_print_symbol): Likewise.
2020 * oasys.c (oasys_print_symbol): Likewise.
2021 * pdp11.c (NAME(aout,print_symbol)): Likewise.
2022 * som.c (som_print_symbol): Likewise.
2023 * srec.c (srec_print_symbol): Likewise.
2024 * tekhex.c (tekhex_print_symbol): Likewise.
2025 * versados.c (versados_print_symbol): Likewise.
2026 * vms.c (vms_print_symbol): Likewise.
2028 * elf.c (_bfd_elf_print_private_bfd_data): Replace fprintf_vma
2029 with bfd_fprintf_vma.
2030 (bfd_elf_print_symbol): Likewise.
2031 * syms.c (bfd_print_symbol_vandf): Likewise.
2033 2001-08-23 Nick Clifton <nickc@cambridge.redhat.com>
2035 * aoutf1.h (sunos_write_object_contents): Silence compile time
2037 * libaout.h (N_SET_DYNAMIC): Silence compile time warning.
2039 * bout.c: Add missing function prototypes. Fix formatting.
2040 * coff-z8k.c: Add missing function prototypes. Fix formatting.
2041 * coff-w65.c: Add missing function prototypes. Fix formatting.
2042 * coff-h8500.c: Add missing function prototypes. Fix formatting.
2043 * coff-h8300.c: Add missing function prototypes. Fix formatting.
2044 * coff-tic54x.c: Add missing function prototypes. Fix formatting.
2045 * coff-tic30.c: Add missing function prototypes. Fix formatting.
2046 * coff-m68k.c: Add missing function prototypes. Fix formatting.
2047 * coff-rs6000.c: Add missing function prototypes. Fix formatting.
2048 * coff-sh.c: Add missing function prototypes. Fix formatting.
2050 2001-08-23 Jakub Jelinek <jakub@redhat.com>
2052 * elf-bfd.h (enum elf_reloc_type_class): New.
2053 (struct elf_backend_data): Add elf_backend_reloc_type_class.
2054 (_bfd_elf_reloc_type_class): New.
2055 * elfxx-target.h (elf_backend_reloc_type_class): Define.
2056 (elfNN_bed): Add elf_backend_reloc_type_class.
2057 * elf.c (_bfd_elf_reloc_type_class): New.
2058 * elf32-i386.c (elf_i386_check_relocs): Set DF_TEXTREL if the reloc
2059 is against read-only section.
2060 (elf_i386_size_dynamic_sections): Use DF_TEXTREL flag instead of
2061 looking up section names for DT_TEXTREL.
2062 (elf_i386_reloc_type_class): New.
2063 (elf_backend_reloc_type_class): Define.
2064 * elf32-sparc.c (elf32_sparc_check_relocs): Set DF_TEXTREL if the
2065 reloc is against read-only section.
2066 (elf32_sparc_size_dynamic_sections): Use DF_TEXTREL flag instead of
2067 looking up section names for DT_TEXTREL.
2068 (elf32_sparc_reloc_type_class): New.
2069 (elf_backend_reloc_type_class): Define.
2070 * elf64-sparc.c (sparc64_elf_check_relocs): Set DF_TEXTREL if the
2071 reloc is against read-only section.
2072 (sparc64_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
2073 looking up section names for DT_TEXTREL.
2074 (sparc64_elf_reloc_type_class): New.
2075 (elf_backend_reloc_type_class): Define.
2076 * elfxx-ia64.c (struct elfNN_ia64_link_hash_table): Add reltext field.
2077 (elfNN_ia64_hash_table_create): Clear ia64_info.
2078 (get_reloc_section): Set DF_TEXTREL if the reloc is against read-only
2080 (elfNN_ia64_size_dynamic_sections): Use ia64_info->reltext flag
2081 instead of looking up section names for DT_TEXTREL.
2082 (elfNN_ia64_reloc_type_class): New.
2083 (elf_backend_reloc_type_class): Define.
2084 * elflink.h (size_dynamic_sections): Add spare DT_NULL tags.
2085 (struct elf_link_sort_rela): New.
2086 (elf_link_sort_cmp1, elf_link_sort_cmp2, elf_link_sort_relocs): New.
2087 (elf_bfd_final_link): Call elf_link_sort_relocs.
2088 Convert one spare DT_NULL into DT_RELCOUNT resp. DT_RELACOUNT if
2091 2001-08-23 Nick Clifton <nickc@cambridge.redhat.com>
2093 * configure.in (x86-bsdi): No corefile support.
2094 * configure: Regenerate.
2096 2001-08-22 Nick Clifton <nickc@cambridge.redhat.com>
2098 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Add missing
2101 2001-08-21 Mark Elbrecht <snowball3@bigfoot.com>
2103 * coff-go32.c: Make DWARF2 sections use an alignment of 0. Set
2104 the alignment of dwarf2 linkonce sections to 0.
2105 * coff-sto32.c: Likewise.
2107 2001-08-20 Andreas Jaeger <aj@suse.de>
2109 * coff-sparc.c: Add missing prototypes.
2110 * elf32-s390.c: Likewise.
2111 * elf32-i960.c: Likewise.
2112 * aout-target.h: Likewise.
2114 2001-08-20 H.J. Lu <hjl@gnu.org>
2116 * elf-bfd.h (elf_obj_tdata): Add num_section_syms.
2117 (elf_num_section_syms): New for num_section_syms.
2119 * elf.c (elf_map_symbols): Set num_section_syms.
2120 (_bfd_elf_symbol_from_bfd_symbol): Check num_section_syms for
2121 the section symbol index.
2123 2001-08-20 Nick Clifton <nickc@cambridge.redhat.com>
2125 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_create): Never
2126 select the generic has table creator. All elf backends need elf
2127 specific fields in the hash table.
2129 2001-08-20 Alan Modra <amodra@bigpond.net.au>
2131 * archive.c (offsetof): Remove define.
2134 * sysdep.h (offsetof): Define.
2136 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2138 * bfd.c (bfd_get_gp_size): Return an unsigned int.
2139 (bfd_set_gp_size): Make param unsigned.
2140 * bfd-in2.h: Regenerate.
2141 * elf32-ppc.c (ppc_elf_add_symbol_hook): Use elf_gp_size rather
2142 than calling bfd_get_gp_size.
2143 * elf64-alpha.c (elf64_alpha_add_symbol_hook): Likewise.
2144 * elfxx-ia64.c (elfNN_ia64_add_symbol_hook): Likewise.
2146 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2148 * linker.c (default_fill_link_order): Handle four byte fill value.
2150 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2152 * elf64-sparc.c (sparc64_elf_output_arch_syms): Add missing
2154 * nlm32-alpha.c (nlm_alpha_write_external): Fix warning.
2156 * elf64-mips.c (UNUSED_RELOC): Define.
2157 (mips_elf64_howto_table_rel): Use it.
2158 (mips_elf64_howto_table_rela): Here too.
2159 (mips_elf64_write_relocs): Fix signed/unsigned warning.
2161 * coffcode.h (coff_write_object_contents): Add ATTRIBUTE_UNUSED to
2163 * coffgen.c (coff_print_symbol): Fix warnings.
2164 (coff_find_nearest_line): Likewise.
2165 * cofflink.c (_bfd_coff_link_input_bfd): Likewise.
2166 * coff-alpha.c (alpha_convert_external_reloc): Likewise.
2167 * format.c (bfd_check_format_matches): Likewise.
2168 (bfd_set_format): Likewise.
2169 * coff-ia64.c: Add missing prototypes.
2170 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Make addend
2171 signed to silence warnings.
2172 (elf64_alpha_relocate_section): Likewise.
2173 (elf64_alpha_find_reloc_at_ofs): Fix warnings.
2174 (elf64_alpha_add_symbol_hook): Likewise.
2175 (elf64_alpha_final_link): Likewise.
2176 (elf64_alpha_relax_section): Remove redundant assign to info.gotent.
2177 (elf64_alpha_merge_gots): Add ATTRIBUTE_UNUSED to unused args.
2178 (elf64_alpha_size_got_sections): Likewise.
2179 * elfxx-ia64.c: Add missing prototypes.
2180 (elfNN_ia64_relocate_section): Fix warning.
2181 (elfNN_ia64_unwind_entry_compare): Make params const.
2183 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2185 * config.bfd (targ64_selvecs): New.
2186 <powerpc-*-aix* entry>: Use it here instead of ineffectual #ifdef.
2188 * bfd-in.h (BFD_VERSION): Remove wrong comment.
2189 (BFD_DEFAULT_TARGET_SIZE): New.
2190 (BFD_ARCH_SIZE): Comment.
2191 * configure.in (target_size): New. Set instead of target64 in
2192 selvecs case statement. Set target64 from it.
2193 (bfd_default_target_size): New. Set from taget_size. AC_SUBST.
2194 * bfd-in2.h: Regenerate.
2195 * configure: Regenerate.
2197 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2199 * bfd.c (enum bfd_error): Add bfd_error_wrong_object_format.
2200 (bfd_errmsgs): Add corresponding message.
2201 * archive.c (bfd_generic_archive_p): Don't release bfd_ardata when
2202 finding an archive that contains different format object files.
2203 Return bfd_error_wrong_object_format for this case.
2204 * format.c: Formatting fixes. s/CONST/const/.
2205 (bfd_check_format_matches): Accept archives that give
2206 bfd_error_wrong_object_format if no full match is found. Tidy
2207 code handling matching_vector. Don't return a pointer to freed
2208 memory in `matching'. Handle ambiguous matches as for partial
2210 * bfd-in2.h: Regenerate.
2212 2001-08-15 Alan Modra <amodra@bigpond.net.au>
2214 * libieee.h (common_header_type): Add last_byte field.
2216 * ieee.c: Add missing prototypes. Some format fixes.
2217 (struct output_buffer_struct): Move for availability to prototypes.
2218 (ieee_part_after): New function.
2219 (ieee_slurp_debug): Use it here.
2220 (ieee_seek): Pass in ieee_data_struct rather than bfd. Use
2221 ieee_part_after to set last_byte to one past end of current part.
2223 (ieee_pos): Pass in ieee_data_struct rather than bfd.
2225 (parse_expression): Don't go beyond the end of the current part.
2226 (ieee_slurp_external_symbols): Correct type passed to read_2bytes.
2227 (ieee_get_symtab_upper_bound, ieee_get_symtab,
2228 ieee_get_symbol_info, ieee_print_symbol, ieee_new_section_hook,
2229 ieee_get_reloc_upper_bound, ieee_canonicalize_reloc, block,
2230 ieee_set_section_contents, ieee_write_object_contents,
2231 ieee_make_empty_symbol): Make static.
2232 (ieee_archive_p): Correct comments regarding bfd_read.
2233 (ieee_object_p): Similarly.
2234 (ieee_mkobject): Move it. Clear output_ptr_start, output_ptr,
2235 output_ptr_end, input_ptr_start, input_ptr, input_ptr_end,
2236 input_bfd, output_bfd, output_buffer.
2237 (do_as_repeat): Write out ieee_set_current_pc_enum value as for
2238 do_with_relocs, ie. as a symbol for relocatable files.
2239 (ieee_vec): Add comments showing functions referenced by macros.
2241 2001-08-14 Nick Clifton <nickc@cambridge.redhat.com>
2243 * aout-tic30.c: Add missing prototypes. Fix formatting.
2244 * aout-ns32k.c: Add missing prototypes. Fix formatting.
2245 * peXXigen.c: Add missining prototypes. Fix formatting.
2246 * aout-adobe.c: Add missining prototypes. Fix formatting.
2248 2001-08-13 Nick Clifton <nickc@cambridge.redhat.com>
2250 * elf32-v850.c: Add missing function prototypes.
2251 Fix some formatting.
2253 * cpu-v850.c: Add missing function prototype.
2254 Fix some formatting.
2256 2001-08-11 Nick Clifton <nickc@cambridge.redhat.com>
2258 * elf-bfd.h (struct elf_backend_data): Add new fields
2259 'elf_backend_sprintf_vma' and 'elf_backend_fprintf_vma'.
2260 (bfd_elf_sprintf_vma): Rename function prototype to
2261 '_bfd_elf_sprintf_vma'.
2262 (bfd_elf_fprintf_vma): Rename function prototype to
2263 '_bfd_elf_fprintf_vma'.
2264 * bfd.c (bfd_sprintf_vma): Do not invoke bfd_elf_sprintf_vma
2265 directly, instead indirect via the elf_backend_data structure.
2266 (bfd_fprintf_vma): Do not invoke bfd_elf_fprintf_vma directly,
2267 instead indirect via the elf_backend_data structure.
2268 * elf.c (bfd_elf_sprintf_vma): Rename to _bfd_elf_sprintf_vma.
2269 (bfd_elf_fprintf_vma): Rename to _bfd_elf_fprintf_vma.
2270 * elfxx-target.h (elf_backend_sprintf_vma): Initialise if not
2272 (elf_backend_fprintf_vma): Initialise if not already defined.
2273 (struct elf_backend_data): Initialise the
2274 elf_backend_sprintf_vma and elf_backend_fprintf_vma fields.
2276 2001-08-10 Andreas Jaeger <aj@suse.de>
2278 * elf64-sparc.c: Add missing prototypes.
2279 * elf32-cris.c: Likewise.
2280 * elf32-i370.c: Likewise.
2281 * elf64-hppa.c: Likewise.
2282 * elf64-s390.c: Likewise.
2284 2001-08-10 Andreas Jaeger <aj@suse.de>
2286 * elf64-x86-64.c (elf64_x86_64_elf_object_p): Make static.
2287 Add prototypes where needed.
2289 2001-08-10 H.J. Lu <hjl@gnu.org>
2291 * bfd.c (bfd_sprintf_vma): Fix a typo in the last change.
2292 (bfd_fprintf_vma): Likewise.
2294 2001-08-10 H.J. Lu <hjl@gnu.org>
2296 * bfd.c (bfd_sprintf_vma): Don't return void.
2297 (bfd_fprintf_vma): Likewise.
2299 2001-08-10 Andreas Jaeger <aj@suse.de>
2301 * configure.in: Add -Wstrict-prototypes and -Wmissing-prototypes
2303 * configure: Regenerate.
2305 2001-08-10 Alan Modra <amodra@bigpond.net.au>
2307 * elf.c (bfd_elf_sprintf_vma): Add ATTRIBUTE_UNUSED to quiet
2308 warning if not BFD64. Add braces so emacs auto format works.
2309 (bfd_elf_fprintf_vma): Likewise.
2311 * libxcoff.h (struct xcoff_backend_data_rec): Constify src param
2313 * coff-rs6000.c (xcoff_swap_ldhdr_in): Modify type of external
2314 param to agree with libxcoff.h.
2315 (xcoff_swap_ldhdr_out): Likewise.
2316 (xcoff_swap_ldsym_in): Likewise.
2317 (xcoff_swap_ldsym_out): Likewise.
2318 (xcoff_swap_ldrel_in): Likewise.
2319 (xcoff_swap_ldrel_out): Likewise.
2320 (xcoff_create_csect_from_smclas): Likewise.
2321 * coff64-rs6000.c: Add missing prototypes.
2322 (xcoff64_swap_ldhdr_in): Modify type of external param to agree
2324 (xcoff64_swap_ldhdr_out): Likewise.
2325 (xcoff64_swap_ldsym_in): Likewise.
2326 (xcoff64_swap_ldsym_out): Likewise.
2327 (xcoff64_swap_ldrel_in): Likewise.
2328 (xcoff64_swap_ldrel_out): Likewise.
2329 (xcoff64_ppc_relocate_section): Make static.
2330 (xcoff64_slurp_armap): Likewise.
2331 (xcoff64_archive_p): Likewise.
2332 (xcoff64_openr_next_archived_file): Likewise.
2333 (xcoff64_sizeof_headers): Likewise.
2334 (xcoff64_is_lineno_count_overflow): Likewise.
2335 (xcoff64_is_reloc_count_overflow): Likewise.
2336 (xcoff64_loader_symbol_offset): Likewise.
2337 (xcoff64_loader_reloc_offset): Likewise.
2338 * elf64-gen.c: Add missing prototypes.
2340 2001-08-09 H.J. Lu <hjl@gnu.org>
2342 * elf.c (bfd_elf_sprintf_vma): Check ELFCLASS64 only in BFD64.
2343 (bfd_elf_fprintf_vma): Likewise.
2345 2001-08-09 H.J. Lu <hjl@gnu.org>
2347 * bfd-in.h (bfd_elf_sprintf_vma, bfd_elf_fprintf_vma): Moved
2350 * bfd-in2.h: Regenerated.
2352 2001-08-09 H.J. Lu <hjl@gnu.org>
2354 * bfd-in.h (bfd_sprintf_vma): New prototype.
2355 (bfd_fprintf_vma): Likewise.
2356 (bfd_elf_sprintf_vma): Likewise.
2357 (bfd_elf_fprintf_vma): Likewise.
2358 (bfd_printf_vma): New. Defined with bfd_fprintf_vma.
2359 * bfd-in2.h: Regenerated.
2361 * bfd.c (bfd_sprintf_vma): New. Defined.
2362 (bfd_fprintf_vma): Likewise.
2364 * elf.c (bfd_elf_sprintf_vma): New. Defined.
2365 (bfd_elf_fprintf_vma): Likewise.
2367 2001-08-09 Alan Modra <amodra@bigpond.net.au>
2369 * coff-rs6000.c: Add missing prototypes.
2370 (xcoff_ppc_relocate_section, xcoff_is_lineno_count_overflow,
2371 xcoff_is_reloc_count_overflow, xcoff_loader_symbol_offset,
2372 xcoff_loader_reloc_offset): Make static.
2373 * dwarf1.c: Add missing prototypes.
2374 * dwarf2.c: Add missing prototypes.
2375 (struct abbrev_info): Move definition.
2376 (struct attr_abbrev, ABBREV_HASH_SIZE, ATTR_ALLOC_CHUNK): Likewise.
2377 * elf.c: Add missing prototypes.
2378 * elf32-gen.c: Likewise.
2379 * elf32-i386.c: Likewise.
2380 * elf32-ppc.c: Likewise.
2381 (ppc_elf_sort_rela): Use PTR instead of "void *".
2382 * elflink.h: Add missing prototypes. Formatting fixes.
2383 * merge.c: Add missing prototypes.
2384 (last4_eq): Use PTR instead of "void *".
2385 (last_eq): Likewise.
2386 * syms.c: Add missing prototypes.
2388 2001-08-09 Nick Clifton <nickc@cambridge.redhat.com>
2390 * bfd.c: Fix formatting.
2391 * bfd-in2.h: Regenerate.
2393 2001-08-09 Nick Clifton <nickc@cambridge.redhat.com>
2395 * elf32-arc.c (R_ARC_B22_PCREL): Change 'partial_inplace' to
2396 true (this target uses REL relocations) and 'pcrel_offset' to
2397 false (the PC is implied, not stored in the offset).
2399 2001-08-08 Alan Modra <amodra@bigpond.net.au>
2401 1999-10-19 Linus Nordberg <linus@swox.se>
2402 * elf-bfd.h (struct elf_backend_data): Add want_got_sym.
2403 * elfxx-target.h (elf_backend_want_got_sym): Define.
2404 (elfNN_bed): Add elf_backend_want_got_sym.
2405 * elflink.c (_bfd_elf_create_got_section): Define
2406 _GLOBAL_OFFSET_TABLE_ only if bed->want_got_sym.
2408 2001-08-08 Alexandre Oliva <aoliva@redhat.com>
2410 * dwarf2.c (struct dwarf2_debug): Add sec, sec_info_ptr and syms.
2411 (find_rela_addend): New function.
2412 (parse_comp_unit): Call it to find the abbrev offset addend.
2413 (_bfd_dwarf2_find_nearest_line): Initialize and maintain the new
2414 members of dwarf2_debug as debugging information is read.
2416 2001-08-07 Nick Clifton <nickc@cambridge.redhat.com>
2418 * coff-sh.c (sh_coff_reloc_type_lookup): Provide for sh-coff
2419 targets as well as sh-pe.
2421 2001-08-03 Ben Harris <bjh21@netbsd.org>
2423 * elf32-arm.h (elf32_arm_final_link_relocate): Include offset of
2424 reloc from start of section when computing value for R_ARM_REL32
2427 2001-08-03 Alan Modra <amodra@bigpond.net.au>
2429 From H.J. Lu <hjl@gnu.org>
2430 * elf32-i386.c (allocate_plt_and_got_and_discard_relocs): Don't
2431 keep relocs for undefined syms if there are no dynamic sections in
2433 * elf32-hppa.c (allocate_plt_and_got_and_discard_relocs): Likewise.
2435 2001-08-02 Paul Sokolovsky <paul.sokolovsky@technologist.com>
2437 * cofflink.c (coff_link_check_ar_symbols): also search for
2438 __imp__symbol as well as _symbol.
2439 * linker.c (_bfd_generic_link_add_archive_symbols): also
2440 search for __imp__symbol as well as _symbol.
2442 2001-08-01 Adam Nemet <anemet@lnxw.com>
2444 * elf.c (elf_sort_sections): Return zero only as the last step.
2446 2001-08-01 Nick Clifton <nickc@cambridge.redhat.com>
2448 * config.bfd (arm-vxworks): Change name of define from VXWORKS to
2450 (arm-epoc-pe): Define ARM_COFF_BUGFIX.
2451 coff-arm.c (coff_arm_relocate_section): Replace VXWORKS with
2454 2001-07-30 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
2456 * libecoff.h (_bfd_ecoff_styp_to_sec_flags): Changed return type
2457 to match corresponding bfd_coff_backend data member.
2459 2001-07-24 Alan Modra <amodra@bigpond.net.au>
2461 * Makefile.am: Update dependencies with "make dep-am".
2462 * Makefile.in: Regenerate
2464 2001-07-15 H.J. Lu <hjl@gnu.org>
2466 * Makefile.am (po/SRC-POTFILES.in): Use tmp.src instead of tmp.
2467 (po/BLD-POTFILES.in): Use tmp.bld instead of tmp.
2468 * Makefile.in: Regenerate.
2470 2001-07-11 H.J. Lu <hjl@gnu.org>
2472 * elf64-alpha.c (elf64_alpha_check_relocs): Set the ALLOC|LOAD
2473 flags when creating the reloc section if the ALLOC flag in the
2474 source section is set.
2476 2001-07-11 Steve Ellcey <sje@cup.hp.com>
2478 * reloc.c (bfd_reloc_code_type): Add IA64 relocs
2479 BFD_RELOC_IA64_LTOFF_FPTR32MSB and BFD_RELOC_IA64_LTOFF_FPTR32LSB
2480 * bfd-in2.h: Regenerate.
2481 * libbfd.h: Regenerate.
2482 * elfxx-ia64.c (ia64_howto_table): Define how to handle
2484 (elfNN_ia64_reloc_type_lookup): Handle new relocations.
2485 (elfNN_ia64_check_relocs): Likewise.
2486 (elfNN_ia64_install_value): Likewise.
2487 (elfNN_ia64_relocate_section): Likewise.
2489 2001-07-11 Jakub Jelinek <jakub@redhat.com>
2491 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Remove support for
2493 (elf32_sparc_check_relocs): Likewise.
2494 Only create .rela section for alloced sections in shared libraries.
2495 (elf32_sparc_relocate_section): Likewise.
2496 Remove redundant check.
2497 Optimize unaligned reloc usage.
2498 * elf64-sparc.c (sparc64_elf_relocate_section): Remove redundant
2501 2001-07-11 H.J. Lu <hjl@gnu.org>
2503 * elf64-alpha.c (elf64_alpha_check_relocs): Only use the same
2504 ALLOC|LOAD flags as the source section for debugging sections
2505 when creating the reloc section.
2507 2001-07-05 Jim Wilson <wilson@redhat.com>
2509 * linker.c (_bfd_generic_link_add_one_symbol, case BIG): Use
2510 the section of the bigger symbol.
2512 * syms.c (bfd_is_local_label): Return false if BSF_SECTION_SYM.
2514 2001-07-05 Nick Clifton <nickc@cambridge.redhat.com>
2516 * peicode.h (coff_swap_scnhdr_in): For sections containing
2517 uninitialised data, only set their size to s_paddr if this does
2518 not reset their size to zero. MS's latest compilers will set
2521 2001-07-04 H.J. Lu <hjl@gnu.org>
2523 * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing):
2524 Handle bfd_mach_mips4400, bfd_mach_mips4600 and
2527 2001-07-03 Mark Elbrecht <snowball3@softhome.net>
2529 * bfd.c (bfd_get_sign_extend_vma): Support DJGPP COFF targets.
2531 * cofflink.c (_bfd_coff_link_input_bfd): Skip section symbols from
2532 sections being discarded.
2534 2001-06-30 Alan Modra <amodra@bigpond.net.au>
2536 * elfcore.h (elf_core_file_p): Call bfd_section_from_phdr directly
2537 instead of _bfd_elfcore_section_from_phdr.
2538 * elf-bfd.h (_bfd_elfcore_section_from_phdr): Remove.
2539 * elf.c (_bfd_elfcore_section_from_phdr): Remove.
2540 (_bfd_elfcore_make_pseudosection): Expedite tail-call.
2541 (elfcore_grok_prstatus): Likewise.
2542 (elfcore_grok_lwpstatus): Likewise.
2543 (bfd_get_elf_phdr_upper_bound): Likewise.
2544 (elfcore_make_note_pseudosection): Formatting.
2545 (_bfd_elfcore_strndup): Formatting.
2546 * elf32-mips.c (mips_elf_sym_is_global): Formatting.
2547 (_bfd_elf32_mips_grok_prstatus): Expedite tail-call.
2549 2001-06-29 Daniel Jacobowitz <drow@mvista.com>
2551 * elf-bfd.h: Add prototypes for _bfd_elfcore_make_pseudosection
2552 and _bfd_elfcore_strndup.
2553 (struct elf_backend_data): Add elf_backend_grok_prstatus
2554 and elf_backend_grok_psinfo.
2555 * elf.c (_bfd_elfcore_make_pseudosection): New function.
2556 (elfcore_grok_prstatus): Use it.
2557 (elfcore_make_note_pseudosection): Likewise.
2558 (elfcore_strndup): Rename to...
2559 (_bfd_elfcore_strndup): Here, and make global.
2560 (elfcore_grok_psinfo): Use _bfd_elfcore_strndup.
2561 (elfcore_grok_note): Call elf_backend_grok_prstatus
2562 and elf_backend_grok_psinfo if available.
2563 * elf32-mips.c (_bfd_elf32_mips_grok_prstatus): New function.
2564 (_bfd_elf32_mips_grok_psinfo): New function.
2565 (elf_backend_grok_prstatus): Define.
2566 (elf_backend_grok_psinfo): Define.
2567 * elfxx-target.h (elf_backend_grok_prstatus): Default to NULL.
2568 (elf_backend_grok_psinfo): Likewise.
2569 (elfNN_bed): Include elf_backend_grok_prstatus and
2570 elf_backend_grok_psinfo.
2572 2001-06-29 H.J. Lu <hjl@gnu.org>
2574 * elf32-hppa.c (elf32_hppa_finish_dynamic_sections): Check if
2575 hplink->sgot is NULL before filling GOT. Check if hplink->splt
2576 is NULL before filling PLT.
2578 2001-06-29 Alan Modra <amodra@bigpond.net.au>
2580 * elflink.h (elf_link_output_extsym): Revert 1999-04-10.
2582 2001-06-27 Alan Modra <amodra@bigpond.net.au>
2584 * elf32-hppa.c (elf32_hppa_check_relocs): Don't make syms dynamic
2586 (elf32_hppa_adjust_dynamic_symbol): ..nor here..
2587 (allocate_plt_and_got_and_discard_relocs): .. instead do so here
2590 * elf32-hppa.c (RELATIVE_DYNAMIC_RELOCS): Delete.
2591 (IS_ABSOLUTE_RELOC): Define.
2592 (elf32_hppa_link_hash_entry): Always include reloc_entries field.
2593 (hppa_link_hash_newfunc): Always init it.
2594 (elf32_hppa_check_relocs): Mark symbols as ELF_LINK_NON_GOT_REF to
2595 create COPY relocs only when the reloc is in a read-only section.
2596 Instead, allocate space for a dynamic reloc to reference the
2597 library symbol directly. Keep track of space we allocate using
2599 (hppa_discard_copies): Delete, and move code to..
2600 (allocate_plt_and_got): ..here. Rename to
2601 allocate_plt_and_got_and_discard_relocs. Remove unneeded dynamic
2602 relocs for non-shared link.
2603 (elf32_hppa_size_dynamic_sections): Update calls to above.
2604 (elf32_hppa_relocate_section): Write out the dynamic relocs used
2605 in lieu of COPY relocs.
2607 * elf32-i386.c (elf_i386_check_relocs): Don't make syms dynamic
2609 (elf_i386_adjust_dynamic_symbol): ..nor here..
2610 (allocate_plt_and_got_and_discard_relocs): .. instead do so here
2612 (elf_i386_size_dynamic_sections): Fix a comment.
2613 (elf_i386_relocate_section <R_386_32, R_386_PC32>): Rearrange code
2614 involved in writing reloc out.
2616 2001-06-25 Alan Modra <amodra@bigpond.net.au>
2618 * elf32-i386.c (elf_i386_check_relocs <R_386_32, R_386_PC32>):
2619 Ensure syms are dynamic if we might be emitting a reloc.
2620 (allocate_plt_and_got_and_discard_relocs): Don't discard relocs
2621 for undefweak or undefined syms..
2622 (elf_i386_relocate_section <R_386_32, R_386_PC32>): .. and emit.
2624 * elf32-i386.c (allocate_plt_and_got_and_discard_relocs): Discard
2625 relocs without ELF_LINK_HASH_DEF_DYNAMIC set.
2626 (elf_i386_relocate_section <R_386_32, R_386_PC32>): Remove
2627 redundant bfd_link_hash_defined, bfd_link_hash_defweak test.
2629 2001-06-24 H.J. Lu <hjl@gnu.org>
2631 * cpu-i960.c (scan_960_mach): Don't modify const char *. Use
2632 strncasecmp/strcasecmp instead of strncmp/strcmp.
2634 2001-06-23 H.J. Lu <hjl@gnu.org>
2636 * elf32-i386.c (elf_i386_relocate_section <R_386_32, R_386_PC32>):
2637 Check ELF_LINK_HASH_DEF_DYNAMIC to see if a symbol is not defined
2638 in the regular object file and treat the weak definition as
2641 2001-06-23 Alan Modra <amodra@bigpond.net.au>
2643 * elf32-i386.c (elf_i386_relocate_section <R_386_GOT32>): Tighten
2644 unresolved_reloc test to exclude cases where we use "relocation"
2645 before setting it to point into the .got. Reinstate fudge for
2646 unresolved relocs in debugging sections.
2648 * elf32-i386.c (elf_i386_relocate_section): Replace ugly
2649 complicated tests for unresolvable relocs with a simple direct
2650 scheme using "unresolved_reloc" var.
2652 * elf32-i386.c (struct elf_i386_pcrel_relocs_copied): Rename to
2653 elf_i386_dyn_relocs. Update comment.
2654 (struct elf_i386_link_hash_entry): Rename pcrel_relocs_copied to
2656 (elf_i386_adjust_dynamic_symbol): Remove a BFD_ASSERT, change
2658 (allocate_plt_and_got_and_discard_relocs): Replace BFD_ASSERT with
2660 (elf_i386_size_dynamic_sections): Likewise.
2661 (elf_i386_finish_dynamic_symbol): Likewise.
2662 (elf_i386_finish_dynamic_sections): Likewise.
2663 (elf_i386_relocate_section): Likewise. Tidy R_386_GOT32 and error
2666 Avoid creating COPY relocs if possible.
2667 * elf32-i386.c (elf_i386_check_relocs): Tweak condition under
2668 which .got created. Mark symbols used by R_386_32 and R_386_PC32
2669 relocs as ELF_LINK_NON_GOT_REF to create COPY relocs only when the
2670 reloc is in a read-only section. Instead, allocate space for a
2671 dynamic reloc to reference the library symbol directly. Keep
2672 track of space we allocate using pcrel_relocs_copied.
2673 (discard_copies): Delete, and move code to ..
2674 (allocate_plt_and_got): ..here. Rename to
2675 allocate_plt_and_got_and_discard_relocs. Remove unneeded dynamic
2676 relocs for non-shared link.
2677 (elf_i386_size_dynamic_sections): Update calls to above functions.
2678 (elf_i386_relocate_section): Write out the dynamic relocs. Add
2679 more ugly logic to avoid "unresolvable relocation" error. Use
2680 htab shortcut in place of elf_hash_table macro.
2681 (elf_i386_finish_dynamic_sections): Allow that dynamic .got may
2682 not always be created now.
2684 2001-06-20 Bo Thorsen <bo@suse.co.uk>
2686 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix linking of
2689 2001-06-18 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2691 * configure.host (mips64-*-linux): Reformat.
2693 2001-06-21 Alan Modra <amodra@bigpond.net.au>
2695 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Always
2696 allocate local .got space. Use shortcuts from hash table for .got
2697 and .plt rather than comparing section names.
2698 (elf32_hppa_check_relocs): Use local_plt_refcounts var rather than
2699 adjusting index into local_got_refcounts to document what we are
2701 (elf32_hppa_relocate_section): Similarly for local_plt_offsets.
2702 Tidy .got and .plt error checking.
2704 2001-06-20 Catherine Moore <clm@redhat.com>
2706 * elf-bfd.h (struct elf_backend_data):
2707 elf_backend_emit_relocs: New field: Function for emitting
2709 elf_backend_count_relocs: New field: Function for determining
2710 the number of relocs to be emitted.
2711 * elfxx-target.h: Provide default (NULL) values for
2712 elf_backend_emit_relocs and elf_backend_count_relocs.
2713 * elflink.h (elf_link_size_reloc_section): Make the hash table
2714 big enough to hold the relocs counted by either reloc_count or
2716 (elf_bfd_final_link) emit_relocs: New boolean, set if relocs
2717 should be emitted, either because of a command line option
2718 stored in the info structure or because the target provides a
2719 special reloc emitting function.
2720 If the target provides a reloc counting function use it,
2721 unless performing a relocatable link or emitting all relocs.
2722 Also set the SEC_RELOC flag on any output section which will
2724 (elf_link_input_bfd): emit_relocs: New boolean, set if relocs
2725 should be emitted, either because of a command line option
2726 stored in the info structure or because the target provides a
2727 special reloc emitting function.
2728 If the target provides a reloc emitting function, use it,
2729 unless performing a relocatable link or emitting all relocs.
2731 2001-06-20 H.J. Lu <hjl@gnu.org>
2733 * elf32-i386.c (elf_i386_size_dynamic_sections): Always
2734 allocate local .got space.
2736 2001-06-19 Andreas Jaeger <aj@suse.de>
2738 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix creation of
2741 2001-06-18 Hans-Peter Nilsson <hp@axis.com>
2743 * elflink.h (struct elf_assign_sym_version_info): Remove member
2744 export_dynamic. All users changed to use info member.
2745 NAME(bfd_elf,size_dynamic_sections)): Remove parameter
2746 export_dynamic, instead use member in parameter info.
2747 * bfd-in.h (bfd_elf32_size_dynamic_sections,
2748 bfd_elf64_size_dynamic_sections): Update prototype.
2749 * bfd-in2.h: Regenerate.
2751 2001-06-18 H.J. Lu <hjl@gnu.org>
2753 * elflink.h (elf_info_failed): Add a new field, verdefs.
2754 (NAME(bfd_elf,size_dynamic_sections): Pass verdefs to
2756 (elf_export_symbol): Check eif->verdefs to decide if a symbol
2759 2001-06-17 H.J. Lu <hjl@gnu.org>
2761 * elf32-mips.c (mips_elf_link_hash_entry): Add a new field,
2762 readonly_reloc, to record if a relocation in the .rel.dyn
2763 section is against a read-only section.
2764 (mips_elf_link_hash_newfunc): Initialize the readonly_reloc
2766 (_bfd_mips_elf_check_relocs): Record if there is a relocation
2767 in the .rel.dyn section against a read-only section by setting
2768 DF_TEXTREL or readonly_reloc.
2769 (_bfd_mips_elf_copy_indirect_symbol): Copy readonly_reloc if
2771 (_bfd_mips_elf_adjust_dynamic_symbol): Record DF_TEXTREL if
2772 there is a relocation in the .rel.dyn section against a
2774 (_bfd_mips_elf_size_dynamic_sections): Set DT_TEXTREL if
2777 2001-06-12 Nick Clifton <nickc@cambridge.redhat.com>
2779 * coffcode.h (styp_flags_to_sec_flags): Change to a boolean
2780 function. Move flagword result into parameter list. Remove
2781 comment about setting bfd_error_handler to intercept failure
2783 * coffgen.c (make_a_section_from_file): Examine result of
2784 calling bfd_coff_styp_to_sec_flags and pass a failure back to
2786 * ecoff.h (styp_flags_to_sec_flags): Change to a boolean
2787 function. Move flagword result into parameter list.
2788 * libcoff.h: Regenerate.
2789 * libecoff.h: Regenerate.
2791 2001-06-13 Nick Clifton <nickc@cambridge.redhat.com>
2793 * aoutx.h (adjust_z_magic): Only pad the tesxt section if the data
2794 section is going to follow it.
2796 2001-06-12 Catherine Moore <clm@redhat.com>
2798 * elflink.h (elf_gc_propagate_vtable_entries): Replace FILE_ALIGN
2799 with the file_align entry from elf_backend_data.
2800 (elf_gc_smash_unused_vtentry_relocs): Likewise.
2801 (elf_gc_record_vtentry): Likewise.
2803 2001-06-10 Alan Modra <amodra@bigpond.net.au>
2805 * elflink.h: Whitespace changes.
2806 (elf_link_read_relocs_from_section): Use "unsigned int" iterator
2807 rather than "unsigned char".
2808 (elf_link_output_relocs): Likewise.
2809 (elf_link_input_bfd): Likewise.
2810 (elf_reloc_link_order): LIkewise.
2811 * elf.c: s/CONST/const/. Whitespace changes.
2812 * elf32-mips.c: Formatting fix.
2814 * Makefile.am (SOURCE_HFILES): Include xcoff-target.h, remove xcoff.h.
2815 * Makefile.in: Regenerate.
2816 * po/Make-in: Remove trailing tab.
2818 2001-06-09 Philip Blundell <philb@gnu.org>
2820 * elf32-arm.h (elf32_arm_plt0_entry): Correct error in last
2822 (elf32_arm_plt_entry): Likewise.
2824 2001-06-08 H.J. Lu <hjl@gnu.org>
2826 * elf.c (swap_out_syms): Keep names for global section symbols.
2828 2001-06-07 H.J. Lu <hjl@gnu.org>
2830 * config.bfd: Put back ecoff for Linux/mips. Firmwares on some
2831 MIPS-based machines need it.
2833 2001-06-07 H.J. Lu <hjl@gnu.org>
2835 * elf32-mips.c (_bfd_mips_elf_object_p): Set the bad symtab
2838 * config.bfd: Remove ecoff from Linux/mips.
2840 2001-06-07 Andreas Jaeger <aj@suse.de>
2842 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_symbol): Add an
2844 (elf64_x86_64_check_relocs): Fix VTENTRY relocation; set an
2845 alignment of 8 for .rela sections; handle further relocations.
2847 2001-06-06 Christian Groessler <cpg@aladdin.de>
2849 * coff-z8k.c: Fix formatting.
2850 Fix howtos: howto->size was always 1.
2852 2001-06-05 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2854 * configure.host (mips64*-*-linux*): Define.
2856 2001-06-05 Alan Modra <amodra@bigpond.net.au>
2858 * elf32-i386.c (elf_i386_discard_copies): Rename to
2859 discard_copies, and use elf_link_hash_entry arg rather than
2860 elf_i386_link_hash_entry.
2861 (elf_i386_link_hash_traverse): Delete.
2862 (elf_i386_size_dynamic_sections): Adjust call to discard_copies.
2863 Tidy sizing of dynamic sections.
2864 (elf_i386_check_relocs <R_386_32, R_386_PC32>): Reference count
2865 possible .plt entries.
2866 (elf_i386_gc_sweep_hook): Likewise.
2867 (elf_i386_adjust_dynamic_symbol): Discard .plt entries for
2868 everything with plt.refcount <= 0.
2870 * elf32-i386.c (elf_i386_check_relocs): Don't allocate .got and
2872 (elf_i386_gc_sweep_hook): ..and no need to deallocate here..
2873 (elf_i386_adjust_dynamic_symbol): ..and don't allocate .plt and
2875 (allocate_plt_and_got): ..instead do it all here. New function.
2876 (elf_i386_size_dynamic_sections): Allocate local .got space and
2877 call allocate_plt_and_got. No need to zap .relgot if not dynamic.
2878 (bfd_elf32_bfd_final_link): Delete. (ie. use regular final link
2879 rather than gc variety).
2880 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
2881 (elf_i386_relocate_section): Use it here and correct handling of
2882 R_386_GOT32. Provide section and offset for "unresolvable
2883 relocation" error message.
2884 (elf_i386_finish_dynamic_symbol): Correct handling of R_386_GOT32.
2886 * elf32-i386.c (struct elf_i386_link_hash_table): Add sgot,
2887 sgotplt, srelgot, splt, srelplt, sdynbss, srelbss fields.
2888 (elf_i386_link_hash_table_create): Init them.
2889 (create_got_section): New function.
2890 (elf_i386_create_dynamic_sections): New function.
2891 (elf_backend_create_dynamic_sections): Set to above.
2892 (elf_i386_check_relocs): Use shortcuts from hash table rather than
2893 calling bfd_get_section_by_name.
2894 (elf_i386_gc_sweep_hook): Likewise.
2895 (elf_i386_adjust_dynamic_symbol): Likewise.
2896 (elf_i386_size_dynamic_sections): Likewise.
2897 (elf_i386_relocate_section): Likewise.
2898 (elf_i386_finish_dynamic_sections): Likewise.
2900 * elf32-hppa.c (allocate_plt_and_got): Skip indirect and warning syms.
2902 2001-06-02 H.J. Lu <hjl@gnu.org>
2904 * elf32-hppa.c (elf32_hppa_object_p): Check ELFOSABI_LINUX
2906 * elf64-hppa.c (elf64_hppa_object_p): Likewise.
2908 2001-06-02 H.J. Lu <hjl@gnu.org>
2910 * aout-cris.c (MACHTYPE_OK): New. Defined.
2912 2001-06-02 Hans-Peter Nilsson <hp@axis.com>
2914 * section.c (_bfd_strip_section_from_output): Handle NULL
2917 2001-06-02 H.J. Lu <hjl@gnu.org>
2919 * config.bfd (powerpc-*-aix*, powerpc-*-beos*, rs6000-*-*): Add
2920 rs6000coff64_vec only if BFD64 is defined.
2921 (powerpc64-*-aix*): Enable only if BFD64 is defined.
2923 2001-06-02 H.J. Lu <hjl@gnu.org>
2925 * coff-ia64.c (ia64coff_object_p): Rewrite with
2926 external_PEI_DOS_hdr and external_PEI_IMAGE_hdr.
2928 2001-06-01 Andreas Jaeger <aj@suse.de>
2930 * elf64-x86-64.c (elf64_x86_64_relocate_section): Add PC8
2931 relocation, small reformatting.
2933 2001-05-29 Andreas Jaeger <aj@suse.de>
2935 * elf64-x86-64.c (elf64_x86_64_check_relocs): Handle R_X86_64_64.
2936 (elf64_x86_64_relocate_section): Likewise.
2938 2001-05-30 Alan Modra <amodra@one.net.au>
2940 * elf32-hppa.c (elf32_hppa_check_relocs): Don't NEED_PLT for
2941 millicode. Don't allocate .got and .rela.got space here..
2942 (elf32_hppa_gc_sweep_hook): ..and no need to deallocate here..
2943 (elf32_hppa_adjust_dynamic_symbol): ..and don't allocate .plt and
2945 (hppa_handle_PIC_calls): ..nor here..
2946 (allocate_plt_and_got): ..instead do it all here. New function.
2947 (elf32_hppa_size_dynamic_sections): Allocate local .got space and
2948 call allocate_plt_and_got. No need to zap .got if not dynamic.
2949 (elf32_hppa_final_link): Call regular bfd_final_link instead of
2950 gc_common_final_link.
2951 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
2952 (elf32_hppa_relocate_section): Use it here.
2953 (elf32_hppa_finish_dynamic_symbol): Remove superfluous test of
2954 dynamic_sections_created.
2955 (hppa_type_of_stub): Don't LONG_BRANCH_VIA_PLT if millicode sym.
2957 2001-05-28 Andreas Jaeger <aj@suse.de>
2959 * elf64-x86-64.c (elf64_86_64_size_info): Remove, we can use the
2960 generic version since we want a hashsize of 4.
2961 (elf_backend_size_info): Likewise.
2963 2001-05-28 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2965 * elflink.h (elf_link_size_reloc_section): Use bfd_zmalloc instead of
2967 (elf_link_output_relocs): Handle MIPS ELF64 relocations correctly.
2968 (elf_link_input_bfd): Likewise.
2969 (elf_reloc_link_order): Likewise.
2970 (elf_finish_pointer_linker_section): Typo. Handle MIPS ELF64
2971 relocations correctly.
2973 2001-05-28 Nicolas Pitre <nico@cam.org>
2975 * elf32-arm.h: fix PLT generation for big endian ARM
2977 2001-05-28 Alan Modra <amodra@one.net.au>
2979 * elf32-hppa.c (elf32_hppa_relocate_section): Set up .plt entries
2980 for symbols forced local that need plabels.
2981 (elf32_hppa_adjust_dynamic_symbol): Don't allocate space in
2982 .plt.rela for local syms if non-shared.
2983 (hppa_build_one_stub): Mask lsb of plt.offset.
2984 (elf32_hppa_finish_dynamic_symbol): Abort if lsb of plt.offset set.
2985 (clobber_millicode_symbols): Correct comment.
2986 (elf32_hppa_relocate_section): Likewise.
2987 (elf32_hppa_finish_dynamic_symbol): Likewise.
2989 2001-05-28 Jeff Sturm <jsturm@one-point.com>
2991 * reloc.c: Add BFD_RELOC_SPARC_UA16 and BFD_RELOC_SPARC_UA64.
2992 * bfd-in2.h: Regenerate.
2993 * libbfd.h: Regenerate.
2994 * elf32-sparc.c: Enable BFD_RELOC_SPARC_UA16, BFD_RELOC_SPARC_UA32
2995 and BFD_RELOC_SPARC_UA64 mapping
2996 * elf64-sparc.c: Likewise.
2998 2001-05-25 H.J. Lu <hjl@gnu.org>
3000 * Makefile.am (BFD32_BACKENDS): Remove coff-pmac.lo.
3001 (BFD32_BACKENDS_CFILES): Remove coff-pmac.c.
3002 (coff-rs6000.lo): Remove the old dependency.
3003 * Makefile.in: Rebuild.
3005 * configure.in (pmac_xcoff_vec): Replace coff-pmac.lo with
3008 2001-05-25 H.J. Lu <hjl@gnu.org>
3010 * coff-rs6000.c (rs6000coff_vec): Use rs6000coff_core_p,
3011 rs6000coff_core_file_matches_executable_p,
3012 rs6000coff_core_file_failing_command and
3013 rs6000coff_core_file_failing_signal only if AIX_CORE is
3015 (pmac_xcoff_vec): Likewise.
3016 * coff64-rs6000.c (rs6000coff64_vec): Likewise.
3018 2001-05-25 Timothy Wall <twall@redhat.com>
3020 * elfxx-ia64.c (allocate_dynrel_entries): Don't allocate an entry
3021 for __GLOB_DATA_PTR on AIX5. Clean up some relocation bugs.
3023 2001-05-25 H.J. Lu <hjl@gnu.org>
3025 * bfd-in2.h: Regenerated.
3026 * libcoff.h: Likewise.
3028 2001-05-25 Alan Modra <amodra@one.net.au>
3030 * elf32-hppa.c (elf32_hppa_relocate_section): Don't allow
3031 undefined millicode syms in shared libs.
3032 (hppa_build_one_stub): Turn BFD_ASSERTs into aborts.
3033 (elf32_hppa_check_relocs): Likewise.
3034 (elf32_hppa_adjust_dynamic_symbol): Likewise.
3035 (elf32_hppa_size_dynamic_sections): Likewise.
3036 (elf32_hppa_relocate_section): Likewise.
3037 (elf32_hppa_finish_dynamic_symbol): Likewise.
3038 (elf32_hppa_finish_dynamic_sections): Likewise.
3040 2001-05-24 Tom Rix <trix@redhat.com>
3042 * Makefile.am coff-pmac bfd now defined in coff-rs6000.c
3043 xcoff-target.h not used to define rs6000 or ppc bfd.
3046 * bfd-in.h : (struct lineno_cache_entry) promote element "offset"
3049 * coff-rs6000.c : Many changes for 64 bit support. Move common
3050 32/64 code to xcofflink.c. Explictly define the rs6000coff_vec
3053 * coff64-rs6000.c : Many changes for 64 bit support. 64 bit
3054 linker now supported. Explictly define the rs6000coff64_vec.
3056 * coffcode.h : (coff_set_arch_mach_hook) xcoff 64 bit support
3057 (coff_print_aux) same
3058 (coff_write_object_contents) same
3059 (coff_slurp_line_table) same
3061 * coffgen.c : (coff_fix_symbol_name) formatting
3062 (coff_mangle_symbols) xcoff 64 bit support
3063 (coff_write_symbol) same
3064 (coff_write_alien_symbol) same
3065 (coff_write_native_symbol) same
3066 (coff_write_symbols) same
3067 (coff_get_symbol_info) same
3068 (bfd_coff_get_syment) same
3069 (coff_print_symbol) same
3071 * config.bfd : add powerpc64-*-aix* target
3073 * libcoff-in.h : formatting
3075 * libcoff.h : move xcoff extern declarations to libxcoff.h
3077 * libxcoff.h : New file
3079 * xcofflink.c : Many changes for xcoff64 support. Move common
3080 structures to include/coff/xcoff.h. Move specific structure to
3081 backends coff-rs6000.c and coff64-rs6000.c. Use new backend
3082 functions, defined in libxcoff.h, to isolate 32/64 dependencies.
3084 (bfd_xcoff_size_dynamic_sections) : special __rtinit symbol for
3087 (xcoff_build_ldsyms) : handle special __rtinit symbol.
3089 2001-05-23 Alexandre Oliva <aoliva@redhat.com>
3091 * elf64-sparc.c (sparc64_elf_slurp_reloc_table): Fix typo
3094 2001-05-23 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3096 * reloc.c (bfd_reloc_code_real): Add MIPS ELF64 relocations.
3097 * libbfd.h: Regenerate.
3098 * bfd-in2.h: Regenerate.
3100 * aoutx.h (aout_@var{size}_machine_type): Add MIPS r12k support.
3101 * archures.c (bfd_mach_mips12000): Define.
3102 * cpu-mips.c (arch_info_struct): Add MIPS r12k support.
3103 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Add MIPS r12k
3105 (_bfd_mips_elf_size_dynamic_sections): Use official bfd typedef.
3106 * bfd-in2.h: Regenerate.
3107 * elfxx-target.h: Do not redefine bfd_elfNN_bfd_make_debug_symbol.
3109 2001-05-23 kaz Kojima <kkojima@rr.iij4u.or.jp>
3111 * elf32-sh.c (elf_sh_plt0_entry_be, elf_sh_plt0_entry,
3112 elf_sh_plt_entry_be, elf_sh_plt_entry, elf_sh_pic_plt_entry_be,
3113 elf_sh_pic_plt_entry): New PLT code, that does not use r2, since
3114 that is used by GCC.
3116 2001-05-23 Nick Clifton <nickc@cambridge.redhat.com>
3118 * elf-bfd.h (NUM_SHDR_ENTRIES): New macro: compute the number
3119 of entries in a structured section.
3120 * elf.c: Use new macro.
3121 * elf32-i386.c: Use new macro.
3122 * elf32-mips.c: Use new macro.
3123 * elf64-alpha.c: Use new macro.
3124 * elf64-sparc.c: Use new macro.
3125 * elfcode.h: Use new macro.
3126 * elflink.h: Use new macro.
3128 2001-05-23 Nick Clifton <nickc@cambridge.redhat.com>
3130 * bfdint.texi: Replace -oformat with --oformat.
3132 2001-05-21 Andreas Jaeger <aj@suse.de>
3134 * dwarf2.c (decode_line_info): Fix error message.
3135 (read_abbrevs): Fix test for offset as suggested by Alan Modra and
3136 adjust error message.
3138 2001-05-18 H.J. Lu <hjl@gnu.org>
3140 * elflink.h (elf_link_add_object_symbols): Revert the last
3143 2001-05-17 Alan Modra <amodra@one.net.au>
3145 * elf32-hppa.c (clobber_millicode_symbols): Temporarily set
3146 ELF_LINK_FORCED_LOCAL to suit 2001-04-30 change.
3147 (hppa_build_one_stub): Add an assert to check plt.offset.
3149 2001-05-17 H.J. Lu <hjl@gnu.org>
3151 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set the
3152 version definition to basename of the output filename.
3154 2001-05-17 H.J. Lu <hjl@gnu.org>
3156 * elflink.h (elf_link_add_object_symbols): Set DT_NEEDED to
3157 basename of the bfd filename.
3159 2001-05-16 Alan Modra <amodra@one.net.au>
3161 * section.c (asection): Add linker_has_input field.
3162 (STD_SECTION): Adjust initialization to suit.
3163 * ecoff.c (bfd_debug_section): Likewise.
3164 * bfd-in2.h: Regenerate.
3166 2001-05-15 Alexandre Oliva <aoliva@redhat.com>
3168 * elf-m10300.c (mn10300_elf_relax_section): Don't relax
3169 negative 32-bit operands to 16 operands when the operand is
3170 going to be zero-extended by the modified opcode.
3172 2001-05-12 Peter Targett <peter.targett@arccores.com>
3174 * cpu-arc.c (arch_info_struct): Add entry 'base' representing old
3175 name for 'arc5' core versions.
3176 (bfd_arc_arch): Make bfd_mach_arc_6 default.
3178 * elf32-arc.c (arc_elf_object_p): Make E_ARC_MACH_ARC6 default
3180 (arc_elf_final_write_processing): Make bfd_mach_arc_6 default.
3182 2001-05-11 Jakub Jelinek <jakub@redhat.com>
3184 * elfxx-ia64.c (is_unwind_section_name): Consider linkonce unwind
3186 (elfNN_ia64_final_write_processing): Map .gnu.linkonce.ia64unw.FOO
3187 to .gnu.linkonce.t.FOO text section.
3189 2001-05-11 Jakub Jelinek <jakub@redhat.com>
3191 * merge.c (struct sec_merge_hash_entry): Add u.entsize and u.suffix
3192 fields, change sec into secinfo.
3193 (struct sec_merge_info): Add chain, remove last fields.
3194 (struct sec_merge_sec_info): Add next, sec, psecinfo fields.
3195 (sec_merge_hash_lookup): If lookup could not use a string only
3196 because it has bad alignment, mark the old string for deletion.
3197 (sec_merge_add): Add secinfo argument. Don't compute entry's
3198 position, instead record the section.
3199 (sec_merge_emit): Update for the sec into secinfo change in
3200 struct sec_merge_hash_entry.
3201 (_bfd_merge_section): Only record the section for merging, defer
3202 putting strings into the hash table.
3203 (cmplengthentry, last4_eq, last_eq, record_section, merge_strings,
3204 _bfd_merge_sections): New functions.
3205 (_bfd_merged_section_offset): Update for the sec_merge_hash_entry
3207 * libbfd-in.h (_bfd_merge_sections): Add prototype.
3208 (_bfd_nolink_bfd_merge_sections): Define.
3209 * libbfd.h: Likewise.
3210 (bfd_generic_merge_sections): Add prototype.
3211 * targets.c (BFD_JUMP_TABLE_LINK): Add _bfd_merge_sections.
3212 (struct bfd_target): Likewise.
3213 * bfd.c (bfd_merge_sections): Define.
3214 * bfd-in2.h: Rebuilt.
3215 * elf.c (_bfd_elf_merge_sections): New function.
3216 * elf-bfd.h (_bfd_elf_merge_sections): Add prototype.
3217 * elfxx-target.h (bfd_elfNN_bfd_merge_sections): Define.
3218 * reloc.c (bfd_generic_merge_sections): New function.
3219 * vms.c (vms_bfd_merge_sections): New function.
3220 * aout-adobe.c (aout_32_bfd_merge_sections): Define.
3221 * aout-target.h (MY_bfd_merge_sections): Define.
3222 * aout-tic30.c (MY_bfd_merge_sections): Define.
3223 * binary.c (binary_bfd_merge_sections): Define.
3224 * bout.c (b_out_bfd_merge_sections): Define.
3225 * coff-alpha.c (_bfd_ecoff_bfd_merge_sections): Define.
3226 * coffcode.c (coff_bfd_merge_sections): Define.
3227 * coff-mips.c (_bfd_ecoff_bfd_merge_sections): Define.
3228 * i386msdos.c (msdos_bfd_merge_sections): Define.
3229 * i386os9k.c (os9k_bfd_merge_sections): Define.
3230 * ieee.c (ieee_bfd_merge_sections): Define.
3231 * ihex.c (ihex_bfd_merge_sections): Define.
3232 * nlm-target.h (nlm_bfd_merge_sections): Define.
3233 * oasys.c (oasys_bfd_merge_sections): Define.
3234 * ppcboot.c (ppcboot_bfd_merge_sections): Define.
3235 * som.c (som_bfd_merge_sections): Define.
3236 * srec.c (srec_bfd_merge_sections): Define.
3237 * tekhex.c (tekhex_bfd_merge_sections): Define.
3238 * versados.c (versados_bfd_merge_sections): Define.
3239 * xcoff-target.h (_bfd_xcoff_bfd_merge_sections): Define.
3241 2001-05-11 Nick Clifton <nickc@cambridge.redhat.com>
3243 * dwarf1.c (_bfd_dwarf1_find_nearest_line): Change type of 'addr'
3244 to be unsigned long, in order to match its use.
3246 2001-05-10 H.J. Lu <hjl@gnu.org>
3248 * linker.c (_bfd_generic_link_add_one_symbol): Check loop on
3251 2001-05-09 H.J. Lu <hjl@gnu.org>
3253 * elflink.h (elf_link_add_object_symbols): Fix a typo. Allocate
3254 versymhdr->sh_size bytes for extversym instead of hdr->sh_size.
3255 Remove the unused veriable `dynver'.
3257 2001-05-08 Ian Lance Taylor <ian@zembu.com>
3259 * coff-i386.c (coff_i386_reloc): Don't dump core if output_bfd is
3260 NULL or is not COFF.
3261 (coff_i386_rtype_to_howto): Don't dump core if output section
3264 2001-05-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3266 * ecoff.c (bfd_debug_section): Fix initialization.
3267 * elf.c (_bfd_elf_slurp_version_tables): Change maxidx to unsigned, it
3268 is always a positive integer. Cast away sign mismatch.
3269 * elf32-mips.c: Fix misleading comment and typo.
3270 (_bfd_mips_elf_section_from_bfd_section): Remove unused attribute, use
3272 * elflink.c: Fix typo.
3273 (_bfd_elf_create_dynamic_sections): Remove superfluous initialization.
3274 * ecoffswap.h (ecoff_swap_fdr_in): Cast away sign mismatch.
3276 2001-05-04 Richard Henderson <rth@redhat.com>
3278 * elf64-alpha.c (SREL16, SREL32, SREL64): Set pcrel_offset true.
3280 2001-05-04 Nick Clifton <nickc@cambridge.redhat.com>
3282 * elf32-arm.h (elf32_arm_final_link_relocate): Set
3283 EF_ARM_HASENTRY if the start address is set.
3285 2001-05-03 Nick Clifton <nickc@cambridge.redhat.com>
3287 * targets.c (_bfd_target_vector_entries): Compute value based on
3288 the size of the _bfd_target_vector and not bfd_target_vector.
3290 2001-05-03 H.J. Lu <hjl@gnu.org>
3292 * elfcode.h: Include "libiberty.h".
3294 * elflink.h (elf_link_add_object_symbols): Set
3295 elf_dt_name (abfd) to basename of the bfd filename.
3296 (NAME(bfd_elf,size_dynamic_sections)): Set vn_file to basename
3297 of the bfd filename.
3299 2001-05-03 Andreas Jaeger <aj@suse.de>
3301 * elf64-gen.c (elf_generic_info_to_howto): Add unused attribute.
3302 (elf_generic_info_to_howto_rel): Likewise.
3303 * coff-alpha.c (reloc_nil): Likewise.
3304 (alpha_ecoff_bad_format_hook): Likewise.
3305 (alpha_adjust_reloc_out): Likewise.
3306 (alpha_bfd_reloc_type_lookup): Likewise.
3307 (alpha_convert_external_reloc): Likewise.
3308 * elf64-alpha.c (elf64_alpha_reloc_nil): Likewise.
3309 (elf64_alpha_reloc_bad): Likewise.
3310 (elf64_alpha_reloc_gpdisp): Likewise.
3311 (elf64_alpha_bfd_reloc_type_lookup): Likewise.
3312 (elf64_alpha_info_to_howto): Likewise.
3313 (elf64_alpha_add_symbol_hook): Likewise.
3314 (elf64_alpha_create_got_section): Likewise.
3315 (elf64_alpha_is_local_label_name): Likewise.
3316 (elf64_alpha_merge_ind_symbols): Likewise.
3317 * elf64-mips.c (mips_elf64_reloc_type_lookup): Likewise.
3318 (mips_elf64_get_reloc_upper_bound): Likewise.
3319 * nlm32-alpha.c (nlm_alpha_mangle_relocs): Likewise.
3320 (nlm_alpha_get_public_offset): Likewise.
3322 2001-05-02 Johan Rydberg <jrydberg@opencores.org>
3324 * elf32-openrisc.c (openrisc_elf_howto_table): Do not complain
3325 about overflow in R_OPENRISC_LO_16_IN_INSN and
3326 R_OPENRISC_HI_16_IN_INSN.Index: bfd/elf32-openrisc.c
3328 2001-04-30 H.J. Lu <hjl@gnu.org>
3330 * elf.c (_bfd_elf_link_hash_hide_symbol): Set dynindx to -1
3331 only for ELF_LINK_FORCED_LOCAL.
3332 * elf32-hppa.c (elf32_hppa_hide_symbol): Likewise.
3333 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Likewise.
3334 * elfxx-ia64.c (elfNN_ia64_hash_hide_symbol): Likewise.
3336 * elflink.h (elf_fix_symbol_flags): Set ELF_LINK_FORCED_LOCAL
3337 if the symbol has hidden or internal visibility.
3339 2001-04-30 Alan Modra <amodra@one.net.au>
3341 * elf32-hppa.c (final_link_relocate): Branch to .+8 for
3342 calls to undefined weak symbols.
3344 2001-04-30 Andreas Jaeger <aj@suse.de>, Andreas Schwab <schwab@suse.de>
3346 * elf64-x86-64.c (elf64_x86_64_relocate_section): Correct test for
3347 R_X86_64_GOTPCREL, don't use assignments instead of comparisons.
3349 2001-04-27 Andreas Jaeger <aj@suse.de>
3351 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_sections): Only swap
3352 out handled entries.
3353 (elf64_x86_64_finish_dynamic_symbol): Set up GOT entries.
3354 (elf64_x86_64_relocate_section): Fix GOTPCREL calculation.
3355 (elf64_x86_64_relocate_section): Merge entries for GOTPCREL and
3358 2001-04-27 Sean McNeil <sean@mcneil.com>
3360 * config.bfd: Add arm-vxworks target.
3361 * coff-arm (coff_arm_relocate_section): Add in symbol value to
3362 addend (fro VXworks targets).
3364 2001-04-26 H.J. Lu <hjl@gnu.org>
3366 * elf32-i386.c (elf_i386_check_relocs): Verify if r_symndx is
3369 2001-04-25 Frank Ch. Eigler <fche@redhat.com>
3371 * bfd-in.h (bfd_cache_close): Declare newly exported function.
3372 * bfd-in2.h: Regenerated.
3374 2001-04-24 Jakub Jelinek <jakub@redhat.com>
3376 * merge.c (struct sec_merge_hash_entry): Add alignment field.
3377 (struct sec_merge_hash): Remove alignment_power.
3378 (sec_merge_hash_newfunc): Clear alignment.
3379 (sec_merge_hash_lookup): Pass alignment as argument.
3380 Use hashp->root.next, not hashp->next to walk the hash chain.
3381 If a string already in the hashtable does not have required
3382 alignment, create a new hashtable entry.
3383 (sec_merge_init): Remove alignment_power argument.
3384 (sec_merge_add): Add alignment argument.
3385 (sec_merge_emit): Alignment is now a per-entity thing, not per
3387 (_bfd_merge_section): Sanity check even non-SEC_STRINGS sections
3388 for proper alignment.
3389 Pass alignment information to sec_merge_add.
3391 2001-04-24 Christian Groessler <cpg@aladdin.de>
3393 * coff-z8k.c (extra_case): added handler for R_DISP7, R_CALLR
3394 and R_REL16 reloc types; accept odd values for R_REL16 type
3396 2001-04-24 Johan Rydberg <jrydberg@opencores.org>
3398 * cpu-openrisc.c: New file.
3399 * elf32-openrisc.c: Likewise.
3401 * Makefile.am (ALL_MACHINES): Add cpu-openrisc.lo.
3402 (ALL_MACHINES_CFILES): Add cpu-openrisc.c.
3403 (BFD32_BACKENDS): Add elf32-openrisc.lo.
3404 (BFD32_BACKENDS_CFILES): Add elf32-openrisc.c.
3405 (cpu-openrisc.lo, elf32-openrisc.lo): New rules.
3406 * Makefile.in: Regenerated.
3407 * config.bfd: (openrisc-*-elf): New target.
3408 * configure.in (bfd_elf32_openrisc_vec): New vector.
3409 * configure: Regenerated.
3410 * libbfd.h: Regenerated.
3411 * bfd-in2.h: Regenerated.
3412 * reloc.c: Add OpenRISC relocations.
3413 * targets.c (bfd_elf32_openrisc_vec): Declare.
3414 (bfd_target_vect): Add bfd_elf32_openrisc_vec.
3415 * archures.c (enum bfd_architecture): Add bfd_arch_openrisc.
3416 (bfd_openrisc_arch): Declare.
3417 (bfd_archures_list): Add bfd_openrisc_arch.
3418 * elf.c (prep_headers): Add bfd_arch_openrisc.
3420 2001-04-23 Bo Thorsen <bo@suse.de>
3422 * elf64-x86-64.c: Add c++ vtable hack.
3423 Small whitespace and comment changes.
3425 2001-04-19 Andreas Jaeger <aj@suse.de>
3427 * elf64-x86-64.c (elf64_x86_64_plt0_entry): Fix instructions.
3428 (elf64_x86_64_plt_entry): Likewise.
3429 (elf64_x86_64_finish_dynamic_sections): Fix PLT0 generation.
3430 (elf64_x86_64_finish_dynamic_symbol): Fix PLT generation.
3432 2001-04-17 Hans-Peter Nilsson <hp@axis.com>
3434 * elf32-cris.c: Tweak comments related to dynamic linking.
3435 (cris_elf_relocate_section): When not creating shared object, fill
3436 in the .got table for any symbol not in the dynamic symbol table.
3437 (elf_cris_finish_dynamic_symbol): When not creating shared object,
3438 only emit a .got.rela reloc if the symbol is in the dynamic symbol
3440 (cris_elf_check_relocs): Use variable r_type in all places rather
3441 than the original expression. Add default case in switch for
3443 (elf_cris_size_dynamic_sections): Iterate over
3444 elf_cris_discard_excess_program_dynamics when not creating shared
3446 (elf_cris_discard_excess_dso_dynamics): Renamed from
3447 elf_cris_discard_copies. Correct typo, s/Rel/Rela/.
3448 (elf_cris_discard_excess_program_dynamics): New.
3450 2001-04-14 Mark Elbrecht <snowball3@bigfoot.com>
3452 * coffcode.h (coff_write_object_contents): Use
3453 bfd_coff_swap_filehdr_out instead of coff_swap_filehdr_out.
3455 2001-04-14 H.J. Lu <hjl@gnu.org>
3457 * bfd-in2.h: Regenerate.
3459 2001-04-14 Jakub Jelinek <jakub@redhat.com>
3461 * section.c (STD_SECTION): Add entsize.
3463 2001-04-13 H.J. Lu <hjl@gnu.org>
3465 * section.c (SEC_MERGE): Define new flag for merging.
3466 (SEC_STRINGS): Likewise.
3467 (entsize): New field.
3469 2001-04-13 Roger Sayle <roger@metaphorics.com>
3471 * coff-i386.c (TARGET_SYM): SEC_READONLY is an applicable section
3472 flag on pe-i386 targets.
3474 2001-04-13 Jakub Jelinek <jakub@redhat.com>
3476 * libbfd-in.h (_bfd_merge_section): New.
3477 (_bfd_write_merged_section): New.
3478 (_bfd_merged_section_offset): New.
3479 * libbfd.h: Rebuilt.
3480 * linker.c (_bfd_generic_link_output_symbols): Handle
3482 * aoutx.h (aout_link_write_symbols): Likewise.
3483 * pdp11.c (aout_link_write_symbols): Likewise.
3484 * elflink.h (elf_link_add_object_symbols): Call _bfd_merge_section.
3485 (elf_bfd_final_link): Adjust global symbols pointing into SEC_MERGE
3487 (elf_link_sec_merge_syms): New.
3488 (elf_link_input_bfd): Call _bfd_merged_section_offset
3489 and _bfd_write_merged_section.
3490 Handle discard_sec_merge.
3491 * elf-bfd.h (struct elf_link_hash_table): Add merge_info
3493 (struct bfd_elf_section_data): Likewise.
3494 * elf.c (_bfd_elf_make_section_from_shdr): Set SEC_MERGE and
3495 SEC_STRINGS section flags and entsize from their ELF counterparts.
3496 (_bfd_elf_link_hash_table_init): Initialize merge_info.
3497 (elf_fake_sections): Set SHF_MERGE, SHF_STRINGS and sh_entsize
3498 from their BFD counterparts.
3499 * merge.c: New file.
3500 * Makefile.am: Add strtab.lo.
3501 * Makefile.in: Rebuilt.
3503 2001-04-09 Hans-Peter Nilsson <hp@axis.com>
3505 * elflink.h (elf_fix_symbol_flags): For non-default visibilities,
3506 only hide symbols marked STV_INTERNAL or STV_HIDDEN.
3508 2001-04-05 Steven J. Hill <sjhill@cotw.com>
3510 * config.bfd (mips*el*-*-linux-gnu*): Use traditional little
3511 endian MIPS ELF target.
3512 * config.bfd (mips*-*-linux-gnu*): Use traditional big endian
3515 * configure.in (bfd_elf64_tradbigmips_vec): New. Traditional
3516 64bit big endian MIPS ELF target.
3517 (bfd_elf64_tradlittlemips_vec): New. Traditional 64bit little
3518 endian MIPS ELF target.
3519 * configure: Regenerated.
3521 * elf32-mips.c (IRIX_COMPAT): Handle traditional 64bit and
3522 little endian targets.
3523 (mips_elf_sym_is_global): Handle traditional targets.
3525 * elf64-mips.c (bfd_elf64_tradbigmips_vec): New. Traditional
3526 64bit big endian MIPS ELF target.
3527 (bfd_elf64_tradlittlemips_vec): New. Traditional 64bit little
3528 endian MIPS ELF target.
3530 * targets.c: (_bfd_target_vector): Add bfd_elf64_tradbigmips_vec
3531 and bfd_elf64_tradlittlemips_vec.
3533 2001-04-05 David Mosberger <davidm@hpl.hp.com>
3535 * elf32-i386.c (elf_i386_fake_sections): Treat ".reloc" as an
3536 ordinary "progbits" section.
3538 2001-04-04 Alan Modra <alan@linuxcare.com.au>
3540 * elflink.h (elf_fix_symbol_flags): Call elf_backend_hide_symbol
3541 when -Bsymbolic causes a symbol to no longer need a .plt entry.
3543 2001-04-03 David Mosberger <davidm@hpl.hp.com>
3545 * efi-app-ia32.c (ALIGN_SECTIONS_IN_FILE): Deleted.
3547 2001-03-30 H.J. Lu <hjl@gnu.org>
3549 * efi-app-ia32.c (PEI_TARGET_SUBSYSTEM): Rename from ...
3550 (PEI_DEFAULT_TARGET_SUBSYSTEM): This.
3552 2001-03-26 H.J. Lu <hjl@gnu.org>
3554 * elf32-gen.c (elf32_generic_link_add_symbols): New. Check
3555 if there are any relocations for generic ELF.
3556 (bfd_elf32_bfd_link_add_symbols): Defined to
3557 elf32_generic_link_add_symbols.
3558 * elf64-gen.c (elf64_generic_link_add_symbols): New. Check
3559 if there are any relocations for generic ELF.
3560 (bfd_elf64_bfd_link_add_symbols): Defined to
3561 elf64_generic_link_add_symbols.
3563 2001-03-23 Nick Clifton <nickc@redhat.com>
3565 * Makefile.am (BUILD_CFILES): New variable: List of C source
3566 files created in build directory.
3567 (BUILD_HFILES): New variable: List of header files created in
3570 (po/POTFILES.in): Replace rule with empty entry.
3571 (po/SRC-POTFILES.in): New rule: Create a list of source files
3572 in the source directory.
3573 (po/BLD-POTFILES.in): New rule: Create a list of source files
3574 in the build directory.
3575 (MOSTLYCLEAN): Do not delete source files created in build
3577 * Makefile.in: Regenerate.
3578 * configure.in: Insert SRC-POTFILES.in and BLD-POTFILES.in
3580 * configure: Regenerate.
3582 * po/Make-in: Replace occurrences of POTFILES with SRC-POTFILES
3584 Add .. to the search path when building bfd.pot.
3585 Delete POTFILES when performing distclean.
3586 Add comment describing why distclean is broken in maintainer mode.
3587 * po/POTFILES.in: Delete.
3588 * po/SRC-POTFILES.in: New file.
3589 * po/BLD-POTFILES.in: New file.
3590 * po/bfd.pot: Regenerate.
3592 2001-03-22 Hans-Peter Nilsson <hp@axis.com>
3594 * elf32-cris.c: Shlib and PIC support. PCREL tweaks.
3595 (elf_cris_discard_copies, elf_cris_adjust_gotplt_to_got,
3596 elf_cris_try_fold_plt_to_got, elf_cris_link_hash_newfunc,
3597 elf_cris_link_hash_table_create, elf_cris_adjust_dynamic_symbol,
3598 elf_cris_size_dynamic_sections, elf_cris_finish_dynamic_symbol,
3599 elf_cris_finish_dynamic_sections,elf_cris_hide_symbol): New
3601 (cris_elf_howto_table) <R_CRIS_8_PCREL, R_CRIS_16_PCREL,
3602 R_CRIS_32_PCREL>: Correct comments. Set pcrel_offset to false.
3603 <R_CRIS_COPY, R_CRIS_GLOB_DAT, R_CRIS_JUMP_SLOT, R_CRIS_RELATIVE,
3604 R_CRIS_16_GOT, R_CRIS_32_GOT, R_CRIS_16_GOTPLT, R_CRIS_32_GOTPLT,
3605 R_CRIS_32_GOTREL, R_CRIS_32_PLT_GOTREL, R_CRIS_32_PLT_PCREL>:
3606 New HOWTO members for new relocs.
3607 (cris_reloc_map): Map new relocs.
3608 (ELF_DYNAMIC_INTERPRETER): Define.
3609 (PLT_ENTRY_SIZE): Define.
3610 (elf_cris_plt0_entry, elf_cris_plt_entry, elf_cris_pic_plt0_entry,
3611 elf_cris_pic_plt_entry): New, PLT templates.
3612 (struct elf_cris_pcrel_relocs_copied, struct
3613 elf_cris_link_hash_entry, struct elf_cris_link_hash_table): New.
3614 (elf_cris_link_hash_traverse, elf_cris_hash_table): Define.
3615 (cris_final_link_relocate): Check that 16-bit GOT relocs have
3616 positive values. Adjust PCREL relocs to be relative to location
3618 (cris_elf_relocate_section): Handle relocations to dynamic
3619 objects. Handle new relocations. Call error handler when seeing
3620 non-PIC relocation for read-only sections while generating shared
3622 (cris_elf_check_relocs): Set reference counts for GOT and PLT
3624 (bfd_elf32_bfd_link_hash_table_create,
3625 elf_backend_adjust_dynamic_symbol,
3626 elf_backend_size_dynamic_sections,
3627 elf_backend_finish_dynamic_symbol,
3628 elf_backend_finish_dynamic_sections,
3629 elf_backend_create_dynamic_sections, bfd_elf32_bfd_final_link,
3630 elf_backend_hide_symbol, elf_backend_want_got_plt,
3631 elf_backend_plt_readonly, elf_backend_want_plt_sym,
3632 elf_backend_got_header_size, elf_backend_plt_header_size):
3635 * reloc.c: (BFD_RELOC_CRIS_COPY, BFD_RELOC_CRIS_GLOB_DAT,
3636 BFD_RELOC_CRIS_JUMP_SLOT, BFD_RELOC_CRIS_RELATIVE,
3637 BFD_RELOC_CRIS_32_GOT, BFD_RELOC_CRIS_16_GOT,
3638 BFD_RELOC_CRIS_32_GOTPLT, BFD_RELOC_CRIS_16_GOTPLT,
3639 BFD_RELOC_CRIS_32_GOTREL, BFD_RELOC_CRIS_32_PLT_GOTREL,
3640 BFD_RELOC_CRIS_32_PLT_PCREL): New relocs.
3641 * bfd-in2.h, libbfd.h: Regenerate.
3643 2001-03-21 Diego Novillo <dnovillo@redhat.com>
3645 (_bfd_mips_elf_relocate_section): Give a better error message when
3646 a relocation is not recognized.
3648 2001-03-21 Alan Modra <alan@linuxcare.com.au>
3650 * elf32-hppa.c (elf32_hppa_set_gp): Check sec->output_section
3651 non-NULL before attempting to dereference.
3653 2001-03-20 H.J. Lu <hjl@gnu.org>
3655 * configure.in: Remove the redundent AC_ARG_PROGRAM.
3656 * configure: Rebuild.
3658 2001-03-20 Andreas Schwab <schwab@suse.de>
3660 * elf32-m68k.c (elf_m68k_relocate_section): Don't need the
3661 relocation value when resolving a reference from a debugging
3664 2001-03-16 Scott Thomason <SThomaso@hii.com>
3666 * coff64-rs6000.c (xcoff64_swap_sym_out): Fix syntax errors.
3667 (xcoff64_swap_sym_out): Fix syntax errors.
3669 2001-03-16 Richard Sandiford <rsandifo@redhat.com>
3671 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix warning.
3673 2001-03-15 Alan Modra <alan@linuxcare.com.au>
3675 * elf32-hppa.c (elf32_hppa_link_hash_entry): Add maybe_pic_call.
3676 (hppa_link_hash_newfunc): Init it.
3677 (hppa_type_of_stub): Only use non-PIC to PIC call stub if caller
3678 section appears to be non-PIC.
3679 (final_link_relocate): Likewise.
3680 (elf32_hppa_adjust_dynamic_symbol): Set maybe_pic_call for any
3681 possible candidate function, and set pic_call for those that will
3682 only have a .plt entry for the PIC call stub.
3683 (hppa_handle_PIC_calls): Set maybe_pic_call.
3685 2001-03-12 DJ Delorie <dj@redhat.com>
3687 * elf32-sh.c (sh_elf_relocate_section): Only relocation
3688 R_SH_DIR8WP* relocs if they're against external symbols, else
3689 they're just for relaxing. Validate the reloc values.
3691 2001-03-12 Stefan Geuken <mail@stefan-geuken.de>
3693 * binary.c (bfd_external_binary_architecture): Declare.
3694 (binary_object_p): If bfd_external_binary_architecture is defined,
3695 set the architecture to this string.
3697 2001-03-11 Philip Blundell <philb@gnu.org>
3699 * elf32-arm.h (elf32_arm_finish_dynamic_symbol): Don't make PLT
3700 entries that could serve as a definition for a weak symbol.
3702 2001-03-08 Nick Clifton <nickc@redhat.com>
3704 * Most files: Update copyright notices using Perl script created
3705 by Kevin Buettner <kevinb@redhat.com>.
3707 2001-03-07 Nick Clifton <nickc@redhat.com>
3709 * elf32-arm.h (elf32_arm_final_link_relocate): Conditionalise
3710 prior patch on ! defined OLD_ARM_ABI.
3712 2001-03-07 Andreas Jaeger <aj@suse.de>
3714 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix handling of
3715 some relocation values.
3717 2001-03-06 Nick Clifton <nickc@redhat.com>
3719 * elf32-arm.h (elf32_arm_final_link_relocate): Clear bit zero
3720 of offset in BLX(1) instruction.
3721 * coff-arm.c (coff_arm_relocate_section): Clear bit zero of
3722 offset in BLX(1) instruction.
3725 2001-03-06 Nick Clifton <nickc@redhat.com>
3727 * coff-arm.c (coff_arm_reloc_type_lookup): Add
3728 BFD_RELOC_THUMB_PCREL_BLX.
3730 2001-03-06 Igor Shevlyakov <igor@windriver.com>
3732 * archures.c (bfd_default_scan): Add Coldfire CPUs.
3733 * bfd-in2.h: Regenerate.
3734 * cpu-m68k.c: Add Coldfire CPUs for arch table.
3735 * ieee.c (ieee_write_processor): Set proper id for
3738 2001-03-01 D.J. Barrow <djbarrow@de.ibm.com,barrow_dj@yahoo.com>
3740 * configure.in: Add s390 target.
3741 * configure: Regenerate.
3743 2001-02-28 Andreas Jaeger <aj@suse.de>
3745 * elf64-x86-64.c (elf64_x86_64_relocate_section): Add relocation
3748 2001-02-28 Philip Blundell <pb@futuretv.com>
3750 * elf32-arm.h: Update mentions of renamed EF_xx constants.
3751 (elf32_arm_print_private_bfd_data): Handle ARM EABI version 2.
3753 2001-02-27 H.J. Lu <hjl@gnu.org>
3755 * aoutx.h (NAME(aout,bfd_free_cached_info)): Return true if
3756 abfd->tdata.aout_data == NULL.
3758 2001-02-27 Alan Modra <alan@linuxcare.com.au>
3760 * elf32-hppa.c: Correct field selector in stub comments.
3761 (clobber_millicode_symbols): Formatting fix.
3763 * configure.in: Bump version to 2.11.90.
3764 * configure: Regenerate.
3765 * Makefile.am (CFILES): Rename to SOURCE_CFILES.
3766 (CFILES): $SOURCE_CFILES + generated C files.
3767 (POTFILES): Include $HFILES not $SOURCE_HFILES.
3769 * Makefile.in: Regenerate.
3770 * doc/Makefile.in: This too.
3772 2001-02-26 Timothy Wall <twall@cygnus.com>
3774 * elfxx-ia64.c (elfNN_ia64_aix_add_symbol_hook): Remove obsolete
3777 2001-02-26 Nick Clifton <nickc@redhat.com>
3779 * coffcode.h (styp_to_sec_flags) [COFF_WITH_PE version]: Tidy
3780 up, replacing multiple if statements with a switch.
3781 (handle_COMDAT): New function.
3783 2001-02-26 H.J. Lu <hjl@gnu.org>
3785 * coffcode.h (styp_to_sec_flags) [COFF_WITH_PE version]: Issue
3786 a warning for section flags we do not handle instead of
3789 2001-02-26 Andreas Jaeger <aj@suse.de>
3791 * elf64-x86-64.c (x86_64_elf_howto_table): Fix order of entries.
3793 2001-02-22 Timothy Wall <twall@cygnus.com>
3795 * config.bfd (targ_cpu): Add vectors for ia64-*-aix* (aka Monterey).
3796 * configure.in: Add objects for elf64_ia64_aix vectors.
3797 * configure: Regenerated.
3798 * configure.host: Recognize ia64-*-aix*.
3799 * elfxx-ia64.c: Add hooks for ELF64 on AIX5. Define new vectors
3800 for AIX. AIX5 requires most relocations to be dynamic (*all*
3801 binaries are somewhat similar to shared libraries).
3802 * targets.c: Add elf64_ia64_aix vectors.
3804 2001-02-21 David Mosberger <davidm@hpl.hp.com>
3806 * cpu-ia64-opc.c (elf64_ia64_operands}: Fix typo: error string for
3807 C8 said "1" instead of "8". Clarify error string for IMM22:
3808 "signed integer" instead of just "integer".
3810 2001-02-20 Andreas Jaeger <aj@suse.de>
3812 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_symbol): Don't make
3813 PLT entries that could serve as a definition for a weak symbol.
3815 2001-02-19 Jakub Jelinek <jakub@redhat.com>
3817 * elf32-sparc.c (elf32_sparc_finish_dynamic_symbol): Don't make PLT
3818 entries that could serve as a definition for a weak symbol.
3819 * elf64-sparc.c (sparc64_elf_finish_dynamic_symbol): Likewise.
3821 2001-02-18 David O'Brien <obrien@FreeBSD>
3823 * configure.in: Recognize FreeBSD/arm, FreeBSD/PowerPC, and treat
3824 FreeBSD/i386-CURRENT differently until I can figure out the needed
3826 * configure: Regenerate.
3827 * config.bfd: Recognize FreeBSD/x86-64, FreeBSD/ia64, FreeBSD/arm,
3828 FreeBSD/PowerPC, and FreeBSD/sparc64.
3830 2001-02-18 lars brinkhoff <lars@nocrew.org>
3832 * Makefile.am: Add PDP-11 a.out target.
3833 * config.bfd: Likewise.
3834 * configure.in: Likewise.
3835 * targets.c: Likewise.
3836 * archures.c: Likewise.
3837 * bfd-in2.h: Likewise. Add PDP-11 relocations.
3838 * libbfd.h: Add PDP-11 relocations.
3839 * reloc.c: Likewise.
3840 * cpu-pdp11.c: New file.
3841 * pdp11.c: New file.
3843 * libaout.h (GET_WORD) [ARCH_SIZE==16]: Define.
3844 (GET_SWORD) [ARCH_SIZE==16]: Likewise.
3845 (GET_SWORD) [ARCH_SIZE==16]: Likewise.
3846 (PUT_WORD) [ARCH_SIZE==16]: Likewise.
3847 (GET_MAGIC): New macro.
3848 (PUT_MAGIC): Likewise.
3849 * aout-target.h (MY(object_p)): Use GET_MAGIC to read magic word.
3851 2001-02-18 Jim Kingdon <jkingdon@engr.sgi.com>
3853 * irix-core.c (irix_core_core_file_p): Set the architecture (GDB
3854 multiarch needs it).
3856 2001-02-18 H.J. Lu <hjl@gnu.org>
3858 * elflink.h (elf_link_input_bfd): Ignore invalid section symbol
3861 2001-02-18 Kazu Hirata <kazu@hxi.com>
3863 * vms-misc.c: Fix formatting.
3865 2001-02-16 Kazu Hirata <kazu@hxi.com>
3867 * vms.c: Fix formatting.
3869 2001-02-14 H.J. Lu <hjl@gnu.org>
3871 * elf.c (elf_find_function): New function.
3872 (_bfd_elf_find_nearest_line): Call elf_find_function () to find
3873 the file name and function name.
3875 2001-02-14 Nick Clifton <nickc@redhat.com>
3877 * ecoff.c (bfd_debug_section): Update to initialise new fields in
3880 * Makefile.am (BFD32_BACKENDS_CFILES): Remove peigen.c
3881 (BFD64_BACKENDS): Add pepigen.c
3882 Add rules to create peigen.c and pepigen.c from peXXigen.c.
3884 * Makefile.in: Regenerate.
3885 * configure: Regenerate.
3886 * po/POTFILES.in: Regenerate.
3887 * po/bfd.pot: Regenerate.
3889 2001-02-14 H.J. Lu <hjl@gnu.org>
3891 * libcoff-in.h (pe_tdata): Add members target_subsystem and
3892 force_minimum_alignment.
3894 2001-02-14 Bo Thorsen <bo@suse.de>
3896 * elf64-x86-64.c: Small formatting fixes and rearrangements of code.
3897 (elf64_86_64_size_info): Struct added to fix a problem
3898 with the hashtable string entries.
3899 (elf64_x86_64_adjust_dynamic_symbol): Add generation of .got.plt.
3900 (elf64_x86_64_size_dynamic_sections): A FIXME removed.
3901 (elf64_x86_64_size_dynamic_sections): Fix a dynamic entry and
3902 remove the FIXME for this.
3903 (elf64_x86_64_adjust_dynamic_symbol): Fix check for unneeded .plt
3904 section. Also removed the FIXME for it.
3905 (x86_64_elf_howto_table): Use bfd_elf_generic_reloc.
3906 (ELF_DYNAMIC_INTERPRETER): Fix the name of the dynamic linker.
3907 (elf64_x86_64_finish_dynamic_sections): Enable .got.plt writing.
3909 2001-02-13 Richard Henderson <rth@redhat.com>
3911 * elfxx-ia64.c (elfNN_ia64_final_link): Set __gp if required
3912 and not user provided.
3914 2001-02-13 Kazu Hirata <kazu@hxi.com>
3916 * vms.c (vms_print_symbol): Remove unreachable code.
3918 * rs6000-core.c: Fix formatting.
3920 2001-02-13 David Mosberger <davidm@hpl.hp.com>
3922 * peicode.h (coff_swap_filehdr_out) [COFF_IMAGE_WITH_PE]: Define
3923 as _bfd_XXi_only_swap_filehdr_out.
3924 (pe_mkobject) [PEI_FORCE_MINIMUM_ALIGNMENT]: Set
3925 pe->force_minimum_alignment to TRUE.
3926 (pe_mkobject) [PEI_TARGET_SUBSYSTEM]: Set pe->target_subsystem to
3927 PEI_TARGET_SUBSYSTEM.
3928 (pe_print_private_bfd_data): Call
3929 _bfd_XX_print_private_bfd_data_common() instead of
3930 _bfd_pe_print_private_bfd_data_common().
3931 (pe_bfd_copy_private_bfd_data): Call
3932 _bfd_XX_bfd_copy_private_bfd_data_common() instead of
3933 _bfd_pe_bfd_copy_private_bfd_data_common().
3934 (coff_bfd_copy_private_section_data): Define as
3935 _bfd_XX_bfd_copy_private_section_data instead of
3936 _bfd_pe_bfd_copy_private_section_data.
3937 (coff_get_symbol_info): Define as _bfd_XX_get_symbol_info instead
3938 of a _bfd_pe_get_symbol_info.
3942 * peXXigen.c: Renamed from peigen.c.
3943 (COFF_WITH_XX): Define this macro (will get expanded into
3944 COFF_WITH_pep or COFF_WITH_pe, depending on whether this is being
3945 compiled as peigen.c or pepigen.c.
3946 [COFF_WITH_pep]: Include "coff/ia64.h" instead of "coff/i386.h" to
3947 define the canonical PEP structures and definitions.
3948 (_bfd_XXi_swap_aouthdr_out): If pe->force_minimum_alignment is in
3949 effect, enforce minimum file and section alignments. If
3950 extra->Subsystem is IMAGE_SUBSYSTEM_UNKNOWN, set it to
3951 pe->target_subsystem (this defaults to IMAGE_SUBSYSTEM_UNKNOWN,
3952 so, by default, this is a no-op).
3954 * libpei.h: Rename COFF_WITH_PEP to COFF_WITH_pep.
3955 (_bfd_XX_bfd_copy_private_bfd_data_common): Add macros to map
3956 _bfd_XXfoo to _bfd_pepfoo if COFF_WIT_PEP is defined and to
3957 _bfd_pefoo if it's not defined. Use these macros to define
3960 * libcoff.h (pe_tdata): Add members target_subsystem and
3961 force_minimum_alignment.
3963 * efi-app-ia64.c (COFF_WITH_pep): Rename COFF_WITH_PEP to
3965 (PEI_TARGET_SUBSYSTEM): Rename from PEI_DEFAULT_TARGET_SUBSYSTEM.
3967 * configure.in (bfd_efi_app_ia64_vec): Use pepigen.lo instead of
3970 * coff-ia64.c: Rename COFF_WITH_PEP to COFF_WITH_pep.
3971 (AOUTSZ): Rename PEP64AOUTSZ and PEP64AOUTHDR to PEPAOUTSZ and
3974 * Makefile.in (BFD64_BACKENDS): Mention pepigen.lo.
3975 (BFD64_BACKENDS_CFILES): Mention pepigen.c
3976 (peigen.c): Add rule to generate from peXXigen.c.
3978 (pepigen.lo): List dependencies for pepigen.lo.
3980 2001-02-13 Alan Modra <alan@linuxcare.com.au>
3982 * elf32-hppa.c (elf32_hppa_set_gp): Handle weak $global$. If
3983 $global$ referenced but not defined, set its value here.
3985 2001-02-09 Bo Thorsen <bo@suse.de>
3987 * elf64-x86-64.c (elf64_x86_64_check_relocs): Set .rela.got section
3989 (elf64_x86_64_check_relocs): Write R_X86_64_GOTPCREL GOT entry
3991 (elf64_x86_64_relocate_section): Fix formatting.
3992 (elf64_x86_64_relocate_section): Fix addend for relocation of
3993 R_X86_64_(8|16|32|PC8|PC16|PC32).
3995 2001-02-12 Jan Hubicka <jh@suse.cz>
3997 * elf64-x86-64.c (x86_64_elf_howto): Fix name of R_X86_64_GOTPCREL.
3999 2001-02-11 H.J. Lu <hjl@gnu.org>
4001 * elflink.h (elf_bfd_final_link): Use file_align for SYMTAB
4004 2001-02-11 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
4006 * elf32-mips.c (mips_elf_create_dynamic_relocation): Undo patch
4007 from 2000-10-13. Do not add the symbol's value for R_MIPS_REL32
4008 relocations against dynsym symbols.
4010 * elf32-mips.c (elf_mips_howto_table): Fix the comment on
4011 the R_MIPS_26 relocation.
4012 (mips_elf_calculate_relocation): Use (p + 4) instead of p for
4013 the R_MIPS_26 relocation.
4014 (mips_elf_perform_relocation): Fix the comment on the R_MIPS16_26
4016 * elf64-mips.c (mips_elf64_howto_table_rel): Fix the comment on
4017 the R_MIPS_26 relocation.
4018 (mips_elf64_howto_table_rela): Likewise.
4020 * elf32-mips.c (struct mips_elf_link_hash_entry): Added no_fn_stub
4021 member to mark symbols that have non-CALL relocations against
4023 (mips_elf_link_hash_newfunc): Initialize no_fn_stub.
4024 (mips_elf_calculate_relocation): Handle R_MIPS_CALL16 like
4026 (_bfd_mips_elf_check_relocs): Set no_fn_stub for a symbol if a
4027 non-CALL relocation against it is encountered.
4028 (_bfd_mips_elf_copy_indirect_symbol): Merge no_fn_stub as well.
4029 (_bfd_mips_elf_adjust_dynamic_symbol): Only create a stub if
4030 no_fn_stub is not set.
4032 * elf32-mips.c (mips_elf_output_extsym): Get the output section
4033 information from the real symbol for indirect ones.
4034 Check no_fn_stub to find out if a symbol has a function stub
4037 2001-02-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
4039 * Makefile.am (stamp-lib): ranlib the libbfd.a in the build directory.
4040 * Makefile.in: Regenerate.
4042 2001-02-09 David Mosberger <davidm@hpl.hp.com>
4044 * elfxx-ia64.c (is_unwind_section_name): New function. Returns
4045 true if section name is an unwind table section name.
4046 (elfNN_ia64_additional_program_headers): Count each unwind section
4048 (elfNN_ia64_modify_segment_map): Install one unwind program header
4049 for each unwind separate section. Note: normally the linker
4050 script merges the unwind sections that go into a single segment,
4051 so this still generates at most one unwind program header per
4054 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Accept any section
4055 name for SHT_IA_64_UNWIND, not just .IA_64.unwind.
4056 (elfNN_ia64_fake_sections): Mark sections with names that start
4057 with .IA_64.unwind but not with .IA_64.unwind_info as an IA-64
4060 * elfxx-ia64.c (elfNN_ia64_final_write_processing): New function.
4061 Use it to make sh_info in unwind section point to the text section
4064 2001-02-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
4066 * Makefile.am: Add linux target for S/390.
4067 * archures.c: Likewise.
4068 * bfd-in2.h: Likewise.
4069 * config.bfd: Likewise.
4070 * configure.in: Likewise.
4072 * libbfd.h: Likewise.
4073 * targets.c: Likewise.
4074 * cpu-s390.c: New file.
4075 * elf32-s390.c: New file.
4076 * elf64-s390.c: New file.
4078 2001-02-09 Nick Clifton <nickc@redhat.com>
4080 * peigen.c (_bfd_pe_get_symbol_info): Suppress addition of
4081 ImageBase. This has already been done by coff_swap_hdr_in.
4083 2001-02-09 Jakub Jelinek <jakub@redhat.com>
4085 * elf64-sparc.c (sparc64_elf_copy_private_bfd_data): New function.
4087 2001-02-09 Jakub Jelinek <jakub@redhat.com>
4089 * elf64-sparc.c (sparc64_elf_check_relocs): Don't trust reloc_count.
4090 (sparc64_elf_relocate_section): Likewise.
4092 2001-02-09 Mark Kettenis <kettenis@gnu.org>
4094 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Treat R_SPARC_UA32
4095 similar to R_SPARC_32.
4096 * elf64-sparc.c (sparc64_elf_howto_table): Likewise.
4098 2001-02-08 H.J. Lu <hjl@gnu.org>
4100 * elf32-i386.c (elf_i386_check_relocs): Reserve R_386_PC32
4101 relocation entries for weak definitions when building DSO with
4104 2001-02-08 Richard Henderson <rth@redhat.com>
4106 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Respect weakness
4107 before visibility. Locally defined protected symbols are not
4110 2001-02-08 Geoffrey Keating <geoffk@redhat.com>
4112 * config.bfd: Enable coff64 for rs6000-*. Patch from
4113 <hzoli@austin.ibm.com>.
4115 2001-02-07 Mark Elbrecht <snowball3@bigfoot.com>
4117 * coffgen.c (coff_find_nearest_line): If stabs info is successfully
4118 found, do not attempt to find dwarf2 info before returning.
4120 2001-02-07 Jakub Jelinek <jakub@redhat.com>
4122 * elflink.h (is_global_symbol_definition): Rename to
4123 is_global_data_symbol_definition and have it reject function
4125 (elf_link_is_defined_archive_symbol): Use renamed function.
4127 2001-02-07 Todd Vierling <tv@wasabisystems.com>
4129 * libbfd-in.h (bfd_target_vector): Change extern array to pointer.
4130 * libbfd.h (bfd_target_vector): Likewise.
4131 * targets.c (bfd_target_vector): Rename to _bfd_target_vector and
4132 make static; create pointer reference named bfd_target_vector.
4133 (_bfd_target_vector_entries): Calculate this based on the array
4134 typed _bfd_target_vector.
4136 2001-02-06 H.J. Lu <hjl@gnu.org>
4138 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Only hidden and
4139 internal symbols are not dynamic.
4140 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise.
4142 2001-02-06 Nick Clifton <nickc@redhat.com>
4144 * Makefile.am (BFD64_BACKENDS_CFILES): Remove elf64-ia64.c, so
4145 that it will not be pulled into the list of files that make up
4147 * Makefile.in: Regenerate.
4148 * po/bfd.pot: Regenerate.
4150 2001-02-06 H.J. Lu <hjl@gnu.org>
4152 * peicode.h (coff_swap_filehdr_in): Remove the e_magic
4154 (pe_bfd_object_p): Rewrite with external_PEI_DOS_hdr and
4155 external_PEI_IMAGE_hdr.
4157 2001-02-06 Kazu Hirata <kazu@hxi.com>
4159 * elf-m10200.c: Fix formatting.
4161 2001-02-04 Nick Clifton <nickc@redhat.com>
4163 * elf32-v850.c (v850_elf_reloc): Do not convert reloc addend to PC
4164 rel, it will be handled later on.
4166 2001-02-02 Fred Fish <fnf@ninemoons.com>
4168 * Makefile.in: Fix typo.
4170 2001-02-01 Kazu Hirata <kazu@hxi.com>
4172 * elf-m10300.c: Fix formatting.
4174 2001-01-30 Alan Modra <alan@linuxcare.com.au>
4176 * elf64-hppa.c (elf64_hppa_elf_get_symbol_type): New function.
4177 (elf_backend_get_symbol_type): Define.
4178 (elf64_hppa_object_p): Set architecture and machine from elf
4181 2001-01-30 Curtis L. Janssen <cljanss@ca.sandia.gov>
4183 * elf64-alpha.c (elf64_alpha_find_nearest_line): Query dwarf2
4186 2001-01-26 Richard Henderson <rth@redhat.com>
4188 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Return false
4189 for non-default visibility.
4190 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise, but
4191 delete ugly macro and replace with pretty function.
4193 2001-01-25 Mark Elbrecht <snowball3@bigfoot.com>
4195 * coff-go32.c: Update copyright.
4196 * coff-stgo32.c: Likewise.
4197 * coff-go32.c (COFF_LONG_FILENAMES): Define.
4198 * coff-stgo32.c (COFF_LONG_FILENAMES): Likewise.
4199 * coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Remove .bss entry.
4200 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
4202 2001-01-25 Kazu Hirata <kazu@hxi.com>
4204 * bfd-in2.h: Rebuild.
4205 * libbfd.h: Likewise.
4207 2001-01-23 H.J. Lu <hjl@gnu.org>
4209 * bfd-in2.h: Rebuild.
4211 2001-01-23 H.J. Lu <hjl@gnu.org>
4213 * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_buf)
4214 is NULL or PRIV(vms_rec) is outside of the buffer.
4216 2001-01-23 Kazu Hirata <kazu@hxi.com>
4218 * coff64-rs6000.c: Fix formatting.
4219 * coff-arm.c: Likewise.
4220 * coffgen.c: Likewise.
4221 * cofflink.c: Likewise.
4222 * coff-mcore.c: Likewise.
4223 * coff-mips.c: Likewise.
4224 * coff-pmac.c: Likewise.
4225 * coff-ppc.c: Likewise.
4226 * coff-rs6000.c: Likewise.
4227 * elf32.c: Likewise.
4228 * elf32-fr30.c: Likewise.
4229 * elf32-i370.c: Likewise.
4230 * elf32-i860.c: Likewise.
4231 * elf32-m32r.c: Likewise.
4232 * elf32-m68k.c: Likewise.
4233 * elf32-mcore.c: Likewise.
4234 * elf32-ppc.c: Likewise.
4235 * elf32-sh.c: Likewise.
4236 * elf32-v850.c: Likewise.
4237 * elf64-alpha.c: Likewise.
4238 * elf64-sparc.c: Likewise.
4239 * elflink.c: Likewise.
4240 * elflink.h: Likewise.
4241 * elf-m10200.c: Likewise.
4242 * elf-m10300.c: Likewise.
4243 * elfxx-ia64.c: Likewise.
4245 * aoutx.h: Fix formatting.
4247 * bfd-in2.h: Likewise.
4248 * bfd-in.h: Likewise.
4249 * cpu-i386.c: Likewise.
4250 * cpu-m68hc11.c: Likewise.
4251 * dwarf2.c: Likewise.
4252 * elf64-x86-64.c: Likewise.
4253 * format.c: Likewise.
4254 * freebsd.h: Likewise.
4256 * hp300hpux.c: Likewise.
4257 * hppabsd-core.c: Likewise.
4258 * hpux-core.c: Likewise.
4260 2001-01-22 Bo Thorsen <bo@suse.de>
4262 * elf64-x86-64.c: Added PIC support for X86-64.
4263 (elf64_x86_64_link_hash_newfunc): Function added.
4264 (elf64_x86_64_link_hash_table_create): Likewise.
4265 (elf64_x86_64_check_relocs): Likewise.
4266 (elf64_x86_64_gc_mark_hook): Likewise.
4267 (elf64_x86_64_gc_sweep_hook): Likewise.
4268 (elf64_x86_64_adjust_dynamic_symbol): Likewise.
4269 (elf64_x86_64_size_dynamic_sections): Likewise.
4270 (elf64_x86_64_discard_copies): Likewise.
4271 (elf64_x86_64_finish_dynamic_symbol): Likewise.
4272 (elf64_x86_64_finish_dynamic_sections): Likewise.
4273 (elf64_x86_64_relocate_section): Add relocation of PIC sections.
4275 2001-01-21 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
4277 * Makefile.am (install-data-local): Make use of $(DESTDIR).
4278 * Makefile.in: Regenerate.
4280 2001-01-21 Kazu Hirata <kazu@hxi.com>
4282 * coff-a29k.c: Fix formatting.
4284 2001-01-19 H.J. Lu <hjl@gnu.org>
4286 * elf32-i386.c (elf_i386_check_relocs): Report files with bad
4287 relocation section names.
4288 (elf_i386_relocate_section): Report files with bad relocation
4289 section names and return false.
4291 2001-01-17 Bo Thorsen <bo@suse.de>
4293 * targets.c: Alphabetize list of xvecs.
4295 2001-01-14 Alan Modra <alan@linuxcare.com.au>
4297 * config.bfd: Add linux target variant for elfxx-hppa.
4298 * configure.in: Recognize bfd_elf32_hppa_linux_vec and
4299 bfd_elf64_hppa_linux_vec.
4300 * configure: Regenerate.
4301 * elf64-hppa.c: Include elf64-target.h again to support linux
4303 (elf64_hppa_post_process_headers): Set ELFOSABI_LINUX for linux.
4304 * elf32-hppa.c: Include elf32-target.h again to support linux
4306 (elf32_hppa_post_process_headers): New function.
4307 (elf_backend_post_process_headers): Define.
4308 * targets.c (bfd_target_vector): Add bfd_elf64_hppa_linux_vec and
4309 bfd_elf32_hppa_linux_vec.
4311 * elf32-hppa.c (elf32_hppa_link_hash_table): Add text_segment_base,
4312 and data_segment_base fields.
4313 (elf32_hppa_link_hash_table_create ): Init them.
4314 (elf32_hppa_check_relocs): Update comments.
4315 (hppa_record_segment_addr): New function.
4316 (elf32_hppa_relocate_section): Call it.
4317 (final_link_relocate): Handle R_PARISC_SEGREL32.
4318 (elf32_hppa_final_link): New function.
4319 (bfd_elf32_bfd_final_link): Define to call it.
4320 (hppa_unwind_entry_compare): New function.
4321 * cache.c (bfd_open_file): Create files in write+read mode.
4323 * elf-hppa.h (elf_hppa_howto_table): Set bitsize value for
4324 SEGREL32 and numerous other relocs. Change duplicate
4325 R_PARISC_NONE relocs to R_PARISC_UNIMPLEMENTED.
4327 * opncls.c (bfd_fdopenr): Add parens like the comment says around
4330 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Don't create
4331 .plt entries for DT_INIT and DT_FINI.
4332 (elf32_hppa_finish_dynamic_sections): Remove special handling of
4333 DT_INIT and DT_FINI.
4335 * elf64-hppa.c (elf64_hppa_finish_dynamic_symbol): Use 16-bit
4336 offsets for stub .plt access if wide mode. Check offset in range.
4338 2001-01-13 Nick Clifton <nickc@redhat.com>
4340 * elf32-fr30.c (fr30_elf_howto_table): Remove spurious blank
4343 * coffcode.h (coff_canonicalize_reloc): Remove spurious blank
4346 2001-01-12 Alan Modra <alan@linuxcare.com.au>
4348 * configure.in ([bfd_elf64_x86_64_vec]): Set target64.
4349 * configure: Regenerate.
4351 2001-01-11 Peter Targett <peter.targett@arccores.com>
4353 * bfd-in2.h (bfd_architecture): Add bfd_mach_arc_5,
4354 bfd_mach_arc_6, bfd_mach_arc_7, bfd_mach_arc_8 for ARC variants.
4355 * cpu-arc.c (arch_info_struct): Add entries for variants.
4356 (bfd_arc_arch) Set default to bfd_mach_arc_5.
4357 (arc_get_mach) Don't assume machine names prefixed arc- before
4359 * elf32-arc.c (arc_elf_object_p): Set machine number based on new
4361 (arc_elf_final_write_processing) Likewise.
4362 (ELF_MACHINE_CODE) Use EM_ARC.
4364 2001-01-10 Nick Clifton <nickc@redhat.com>
4366 * coff-arm.c (LOCAL_LABEL_PREFIX): Change definition to "".
4368 2001-01-07 Philip Blundell <philb@gnu.org>
4370 * README: Replace `bug-gnu-utils@gnu.org' with
4371 `bug-binutils@gnu.org'.
4373 2001-01-04 Kazu Hirata <kazu@hxi.com>
4375 * som.c: Fix formatting.
4377 2001-01-03 Kazu Hirata <kazu@hxi.com>
4379 * ecoffswap.h: Fix formatting.
4380 * elf-bfd.h: Likewise.
4381 * elfarm-nabi.c: Likewise.
4382 * elfarm-oabi.c: Likewise.
4383 * elfcode.h: Likewise.
4384 * elfcore.h: Likewise.
4385 * elflink.c: Likewise.
4386 * elflink.h: Likewise.
4387 * elfxx-ia64.c: Likewise.
4388 * elfxx-target.h: Likewise.
4389 * libbfd.c: Likewise
4390 * linker.c: Likewise.
4391 * lynx-core.c: Likewise.
4393 2001-01-02 Kazu Hirata <kazu@hxi.com>
4395 * pc532-mach.c: Fix formatting.
4396 * pe-arm.c: Likewise.
4397 * pe-i386.c: Likewise.
4398 * pe-mips.c: Likewise.
4399 * pe-ppc.c: Likewise.
4400 * pe-sh.c: Likewise.
4401 * pei-mips.c: Likewise.
4402 * pei-sh.c: Likewise.
4403 * peicode.h: Likewise.
4404 * ppcboot.c: Likewise.
4405 * ptrace-core.c: Likewise.
4407 2001-01-01 Kazu Hirata <kazu@hxi.com>
4409 * reloc.c: Fix formatting.
4410 * riscix.c: Likewise.
4411 * rs6000-core.c: Likewise.
4412 * xcoff-target.h: Likewise.
4414 2000-12-29 Hans-Peter Nilsson <hp@bitrange.com>
4416 * elfcode.h (elf_object_p): Also restore the bfd mach field on
4417 error, by calling bfd_default_set_arch_mach with incoming
4420 2000-12-26 Kazu Hirata <kazu@hxi.com>
4422 * vaxnetbsd.c: Fix formatting.
4423 * versados.c: Likewise.
4424 * vms-gsd.c: Likewise.
4425 * vms-hdr.c: Likewise.
4426 * vms-misc.c: Likewise.
4428 2000-12-25 Alexandre Oliva <aoliva@redhat.com>
4430 * archive.c (coff_write_armap): Don't write more than symbol_count
4431 `archive_member_file_ptr's.
4433 2000-12-25 Kazu Hirata <kazu@hxi.com>
4435 * vms-tir.c: Fix formatting.
4437 2000-12-23 Kazu Hirata <kazu@hxi.com>
4439 * vms.c: Fix formatting.
4442 2000-12-21 Santeri Paavolainen <santtu@ssh.com>
4444 * vms-hdr.c: Include alloca.h if HAVE_ALLOCA_H is defined.
4446 * peicode.h (pe_ILF_object_p): Add const to import of TARGET_LITTLE_SYM.
4448 * elf32-m32r.c (m32r_elf_generic_reloc): Add cast to avoid (void *)
4451 * elf32-fr30.c: Add casts to avoid (void *) arithmetic.
4453 * coffcode.h (styp_to_sec_flags): Add empty statement after label.
4455 2000-12-21 Richard Sandiford <rsandifo@redhat.com>
4457 * libbfd.c (bfd_get_bits): Added
4458 (bfd_put_bits): Likewise
4459 * bfd-in.h: Declared the above.
4460 * bfd-in2.h: Regenerated.
4462 2000-12-20 Kazu Hirata <kazu@hxi.com>
4464 * targets.c: Fix formatting.
4465 * tekhex.c: Likewise.
4466 * trad-core.c: Likewise.
4468 2000-12-19 Kazu Hirata <kazu@hxi.com>
4470 * sco5-core.c: Fix formatting.
4471 * section.c: Likewise.
4472 * sparclinux.c: Likewise.
4473 * sparclynx.c: Likewise.
4474 * sparcnetbsd.c: Likewise.
4476 * stabs.c: Likewise.
4477 * stab-syms.c: Likewise.
4478 * sunos.c: Likewise.
4480 * sysdep.h: Likewise.
4482 2000-12-18 Nick Clifton <nickc@redhat.com>
4484 * coff-arm.c (EXTRA_S_FLAGS): Only define if not already
4486 * epoc-pe-arm.c (EXTRA_S_FLAGS): Define.
4487 * epoc-pei-arm.c (EXTRA_S_FLAGS): Define.
4489 2000-12-18 Nick Clifton <nickc@redhat.com>
4491 * vms-misc.c (_bfd_vms_get_record): Add default case to
4494 2000-12-15 Miloslav Trmac <mitr@volny.cz>
4496 * elfcore.h (elf_core_file_p): Move to the start of the program
4497 headers before attempting to read them.
4499 2000-12-14 Kazu Hirata <kazu@hxi.com>
4501 * peigen.c: Fix formatting.
4505 2000-12-13 Kazu Hirata <kazu@hxi.com>
4507 * peigen.c: Fix formatting.
4509 2000-12-12 Jim Wilson <wilson@redhat.com>
4511 * elfxx-ia64.c (get_dyn_sym_info): Cast %p argument to void *.
4513 2000-12-08 Mark Salter <msalter@redhat.com>
4515 * binary.c (binary_set_section_contents): Ignore sections
4518 2000-12-12 Kazu Hirata <kazu@hxi.com>
4520 * m68klinux.c: Fix formatting.
4521 * m68knetbsd.c: Likewise.
4522 * mipsbsd.c: Likewise.
4523 * netbsd-core.c: Likewise.
4524 * netbsd.h: Likewise.
4525 * newsos3.c: Likewise.
4526 * nlm32-alpha.c: Likewise.
4527 * nlm32-i386.c: Likewise.
4528 * nlm32-ppc.c: Likewise.
4529 * nlm32-sparc.c: Likewise.
4530 * nlmcode.h: Likewise.
4531 * nlmswap.h: Likewise.
4532 * nlm-target.h: Likewise.
4533 * ns32knetbsd.c: Likewise.
4535 2000-12-10 Fred Fish <fnf@be.com>
4537 * elflink.h (elf_link_output_extsym): Don't complain about undefined
4538 symbols in shared objects if allow_shlib_undefined is true.
4540 2000-12-12 Nick Clifton <nickc@redhat.com>
4542 * cpu-sh.c: Fix formattng.
4543 * elf.c: Fix formattng.
4544 * elf32-mips.c: Fix formattng.
4545 * elf32-sh.c: Fix formattng.
4546 * elf64-alpha.c: Fix formattng.
4548 2000-12-09 Nick Clifton <nickc@redhat.com>
4550 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Pass
4551 dwarf2_find_line_info as last parameter to invocation of
4552 _bfd_dwarf2_find_nearest_line.
4553 * elf32-arm.h (elf32_arm_find_nearest_line): Pass
4554 dwarf2_find_line_info as last parameter to invocation of
4555 _bfd_dwarf2_find_nearest_line.
4557 2000-12-08 Mark Elbrecht <snowball3@bigfoot.com>
4559 * Makefile.am (BFD32_BACKENDS): Move dwarf2.lo from here...
4560 (BFD_LIBS): ...to here.
4561 (BFD32_BACKENDS_CFILES): Move dwarf2.c from here...
4562 (BFD_LIBS_CFILES): ...to here.
4563 * Makefile.in: Regenerate.
4564 * configure.in: Remove dwarf.lo from the elf shell variable.
4565 * configure: Regenerate.
4566 * libcoff-in.h (coff_tdata): Add pointer dwarf2_find_line_info.
4567 * libcoff.h: Regenerate.
4568 * coffgen.c (coff_find_nearest_line): Call
4569 _bfd_dwarf2_find_nearest_line.
4570 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Add parameter. Update
4572 (read_abbrevs): Likewise
4573 (decode_line_info): Likewise.
4574 (parse_comp_unit): Likewise.
4575 (comp_unit_find_nearest_line): Likewise.
4576 * libbfd-in.h (_bfd_dwarf2_find_nearest_line): Update prototype.
4577 * libbfd.h: Regenerate.
4578 * elf.c (_bfd_elf_find_nearest_line): Update call.
4579 * elf-bfd.h (elf_obj_tdata): Change dwarf2_find_line_info to type PTR.
4580 * dwarf2.c (concat_filename): Use IS_ABSOLUTE_PATH.
4581 * coffcode.h (STYP_XCOFF_DEBUG, STYP_DEBUG_INFO): New macros.
4582 (sec_to_styp_flags): Use them. Handle DWARF2 sections.
4583 (styp_to_sec_flags): Handle DWARF2 sections.
4584 * elf32-arm.h (elf32_arm_find_nearest_line): Add parameter to call
4585 to _bfd_find_nearest_line.
4586 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Add parameter to
4587 call to _bfd_find_nearest_line.
4589 2000-12-08 Kazu Hirata <kazu@hxi.com>
4591 * coffgen.c: Fix formatting.
4592 * elf-m10300.c: Likewise.
4593 * elf32-i386.c: Likewise.
4594 * elf32-i960.c: Likewise.
4595 * elf32-m68k.c: Likewise.
4596 * elf32-mcore.c: Likewise.
4597 * elf32-ppc.c: Likewise.
4598 * elf32-sh.c: Likewise.
4599 * elf32-sparc.c: Likewise.
4600 * elf32-v850.c: Likewise.
4601 * elf64-alpha.c: Likewise.
4602 * elf64-hppa.c: Likewise.
4603 * elf64-mips.c: Likewise.
4604 * elf64-sparc.c: Likewise.
4606 2000-12-07 Kazu Hirata <kazu@hxi.com>
4608 * elf32-ppc.c: Fix formatting.
4609 * elf64-x86-64.c: Likewise.
4611 2000-12-06 Ulf Carlsson <ulfc@engr.sgi.com>
4613 From Ralf Baechle <ralf@gnu.org>
4615 * elf32-mips.c (elf32_mips_merge_private_bfd_data): Always permit
4616 BFDs containing no sections or empty .text, .data or .bss sections
4617 to be merged, regardless of their flags.
4619 2000-12-06 Kazu Hirata <kazu@hxi.com>
4621 * elf32-m32r.c: Fix formatting.
4622 * elf32-m68hc11.c: Likewise.
4623 * elf32-m68hc12.c: Likewise.
4624 * elf32-m68k.c: Likewise.
4625 * elf32-mcore.c: Likewise.
4626 * elf32-pj.c: Likewise.
4627 * elf32-ppc.c: Likewise.
4629 2000-12-05 Kazu Hirata <kazu@hxi.com>
4631 * elf32-fr30.c: Fix formatting.
4632 * elf32-hppa.c: Likewise.
4633 * elf32-i370.c: Likewise.
4634 * elf32-i386.c: Likewise.
4635 * elf32-i860.c: Likewise.
4636 * elf32-i960.c: Likewise.
4638 2000-12-03 Kazu Hirata <kazu@hxi.com>
4640 * elf32-arm.h: Fix formatting.
4641 * elf32-avr.c: Likewise.
4642 * elf32-cris.c: Likewise.
4643 * elf32-d10v.c: Likewise.
4644 * elf32-d30v.c: Likewise.
4645 * elf-hppa.h: Likewise.
4646 * elf-m10200.c: Likewise.
4647 * elf-m10300.c: Likewise.
4649 2000-12-01 Chris Demetriou <cgd@sibyte.com>
4651 * aoutx.h (NAME(aout,machine_type)): Add bfd_mach_mips32 and
4652 bfd_mach_mips32_4k. Update FIXME comment.
4653 * archures.c (bfd_mach_mips32): New constant.
4654 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
4655 the latter, renumber it.
4656 * bfd-in2.h (bfd_mach_mips32): New constant.
4657 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
4658 the latter, renumber it.
4659 * cpu-mips.c (I_mips32): New constant.
4660 (I_mips4K, I_mips32_4k): Rename the former to the latter.
4661 (arch_info_struct): Add bfd_mach_mips32 entry, replace
4662 bfd_mach_mips4K entry with bfd_mach_mips32_4k entry.
4663 * elf32-mips.c (elf_mips_isa): Add E_MIPS_ARCH_32 case.
4664 (elf_mips_mach): Likewise. Also, replace E_MIPS_MACH_MIPS32
4665 with E_MIPS_MACH_MIPS32_4K.
4666 (_bfd_mips_elf_final_write_processing): Replace
4667 bfd_mach_mips4K with bfd_mach_mips32_4k case, add
4668 bfd_mach_mips32 case.
4669 (_bfd_mips_elf_merge_private_bfd_data): Generalize ISA mixing
4670 comparison with support for MIPS32.
4671 (_bfd_mips_elf_print_private_bfd_data): Print ISA name for
4674 * aoutx.h (NAME(aout,machine_type)): Add cases for
4675 bfd_mach_mips5 and bfd_mach_mips64.
4676 * archures.c (bfd_mach_mips5, bfd_mach_mips64): New constants.
4677 * bfd-in2.h (bfd_mach_mips5, bfd_mach_mips64): Likewise.
4678 * cpu_mips.c (I_mips5, I_mips64): New definitions.
4679 (arch_info_struct): Add entries for bfd_mach_mips5 and
4681 * elf32-mips.c (elf_mips_isa, elf_mips_mach,
4682 _bfd_mips_elf_print_private_bfd_data): Add cases for
4683 E_MIPS_ARCH_5 and E_MIPS_ARCH_64.
4684 (_bfd_mips_elf_final_write_processing): Add cases for
4685 bfd_mach_mips5 and bfd_mach_mips64.
4687 * aoutx.h (NAME(aout,machine_type)): Add a
4688 bfd_mach_mips_sb1 case.
4689 * archures.c (bfd_mach_mips_sb1): New constant.
4690 * bfd-in2.h (bfd_mach_mips_sb1): New constant.
4691 * cpu-mips.c (I_sb1): New constant.
4692 (arch_info_struct): Add entry for bfd_mach_mips_sb1.
4693 * elf32-mips.c (elf_mips_mach): Add case for
4695 (_bfd_mips_elf_final_write_processing): Add case for
4698 2000-12-01 Joel Sherrill <joel@OARcorp.com>
4700 * config.bfd (arm-*-rtems*, a29k-*rtems*): New targets.
4701 (sparc*-*-rtemself*, sparc*-*-rtemsaout*): New targets.
4702 (sparc*-*-rtems*): Switched from a.out to ELF.
4704 2000-11-30 Jan Hubicka <jh@suse.cz>
4706 * Makefile.am (BFD64_BACKENDS): Add elf64-x86-64.lo
4707 BFD64_BACKENDS_CFILES): Add elf64-x86-64.c
4708 (elf64-x86-64.lo): Add dependencies.
4709 * archures.c (DESCRIPTION): Add bfd_mach_x86_64,
4710 bfd_mach_x86_64_intel_syntax.
4711 * elf.c (prep_headers): Use EM_x86_64 for 64bit output.
4712 * config.bfd (x86_64): Add.
4713 * configure.in: Add support for bfd_elf64_x86_64_vec.
4714 * cpu-i386.c (bfd_x86_64_arch_intel_syntax, bfd_x86_64_arch): Add.
4715 (bfd_i386_arch, i8086_ar): Link in.
4716 * elf64-x86-64.c: New file.
4717 * reloc.c (ENUMDOC): Add BFD_RELOC_X86_64*.
4718 * targets.c (bfd_elf64_x86_64_vec): Add.
4719 (bfd_target_vect): Add bfd_elf64_x86_64_vec.
4721 2000-11-30 Kazu Hirata <kazu@hxi.com>
4723 * xcofflink.c: Fix formatting.
4725 2000-11-28 Kazu Hirata <kazu@hxi.com>
4727 * aoutx.h: Fix formatting.
4728 * bfd-in.h: Likewise.
4729 * bfd-in2.h: Likewise.
4730 * cache.c: Likewise.
4731 * cisco-core.c: Likewise.
4732 * coff64-rs6000.c: Likewise.
4733 * coffcode.h: Likewise.
4734 * coffswap.h: Likewise.
4735 * corefile.c: Likewise.
4736 * elf32-mips.c: Likewise.
4738 2000-11-27 Kazu Hirata <kazu@hxi.com>
4740 * aout-adobe.c: Fix formatting.
4741 * coff64-rs6000.c: Likewise.
4742 * coffgen.c: Likewise.
4743 * cofflink.c: Likewise.
4745 2000-11-27 Philip Blundell <pb@futuretv.com>
4747 * libcoff-in.h (coff_tdata): Add `strings_written' flag.
4748 (obj_coff_strings_written): New accessor macro for above.
4749 * libcoff.h: Regenerate.
4750 * cofflink.c (_bfd_coff_final_link): Say that we wrote the
4752 * coffcode.h (coff_write_object_contents): No need to write out
4753 the string table if it's already been done.
4755 2000-11-22 Philip Blundell <pb@futuretv.com>
4757 * cofflink.c (_bfd_coff_generic_relocate_section): Don't object to
4758 weak undefined symbols.
4760 2000-11-24 Nick Clifton <nickc@redhat.com>
4762 * archures.c (bfd_mach_arm_5TE): Define.
4763 (bfd_mach_arm+XScale): Define.
4764 * bfd-in2.h: Regenerate.
4766 * coff-arm.c (coff_arm_reloc_type_lookup): Accept
4767 BFD_RELOC_ARM_PCREL_BLX.
4769 * coffcode.h (coff_set_flags): Set flags for 5t, 5te and
4770 XScale machine numbers.
4772 * config.bfd (xscale-elf): Add target.
4773 (xscale-coff): Add target.
4775 * cpu-arm.c: Add xscale machine name.
4776 Add v5t, v5te and XScale machine numbers.
4778 2000-11-23 Kazu Hirata <kazu@hxi.com>
4780 * aix386-core.c: Fix formatting.
4782 2000-11-22 Jim Wilson <wilson@redhat.com>
4784 * coff-ia64.c (howto_table): Use EMPTY_HOWTO.
4785 (in_reloc_p): Add ATTRIBUTE_UNUSED to unused parameters.
4786 * cpu-ia64-opc.c (ins_rsvd, ext_rsvd, ins_const, ext_const): Likewise.
4787 (ins_imms_scaled): Initialize sign_bit at function entry.
4788 (elf64_ia64_operands): Add missing initializers.
4789 * elfxx-ia64.c (elfNN_ia64_reloc, elfNN_ia64_reloc_type_lookup,
4790 elfNN_ia64_info_to_howto, elfNN_ia64_fake_sections,
4791 elfNN_ia64_add_symbol_hook, elfNN_ia64_is_local_label_name,
4792 elfNN_ia64_local_hash_table_init, get_fptr, get_pltoff,
4793 elfNN_ia64_adjust_dynamic_symbol): Add ATTRIBUTE_UNUSED for unused
4795 (elfNN_ia64_info_to_howto): Initialize free_relocs, free_contents,
4796 and free_extsyms at function entry.
4797 (elfNN_add_symbol_hook): Add unsigned cast to bfd_get_gp_size result.
4798 (elfNN_ia64_create_dynamic_sections): Delete unused local h.
4799 (get_got): Delete unused local srel.
4800 (elfNN_ia64_check_relocs): Initialize dynrel_type when declared.
4801 (elfNN_ia64_relocate_section): Delete unused local dynindx.
4803 2000-11-21 Kazu Hirata <kazu@hxi.com>
4805 * coff-a29k.c: Fix formatting.
4806 * coff-h8500.c: Likewise.
4807 * coff-i960.c: Likewise.
4808 * coff-ppc.c: Likewise.
4809 * coff-rs6000.c: Likewise.
4810 * coff-stgo32.c: Likewise.
4811 * coff-tic54x.c: Likewise.
4812 * coff-w65.c: Likewise.
4813 * cpu-h8500.c: Likewise.
4814 * cpu-hppa.c: Likewise.
4815 * cpu-ns32k.c: Likewise.
4816 * ecoff.c: Likewise.
4817 * ecofflink.c: Likewise.
4819 2000-11-21 Nick Clifton <nickc@redhat.com>
4821 * elf32-sh.c (sh_elf_reloc_loop): Fix compile time warning, and
4822 remove possibility of infinite loop.
4824 2000-11-20 Kazu Hirata <kazu@hxi.com>
4826 * aix386-core.c: Fix formatting.
4827 * aout-adobe.c: Likewise.
4828 * aout-arm.c: Likewise.
4829 * aout-encap.c: Likewise.
4830 * aout-ns32k.c: Likewise.
4831 * aout-target.h: Likewise.
4832 * aout-tic30.c: Likewise.
4833 * aoutf1.h: Likewise.
4834 * aoutx.h: Likewise.
4835 * archive.c: Likewise.
4836 * bfd-in.h: Likewise.
4837 * bfd-in2.h: Likewise.
4841 2000-11-17 H.J. Lu <hjl@gnu.org>
4843 * elfxx-ia64.c (elfNN_ia64_size_dynamic_sections): Don't create
4844 pltoff entries for DT_INIT and DT_FINI.
4845 (elfNN_ia64_final_link): Don't set DT_INIT/FINI entries.
4846 (elfNN_ia64_finish_dynamic_sections): Don't fill in DT_INIT/FINI
4849 2000-11-16 Richard Henderson <rth@redhat.com>
4851 * elfxx-ia64.c (elfNN_ia64_check_relocs): Handle IPLT relocs.
4852 (allocate_dynrel_entries): Likewise.
4853 (elfNN_ia64_relocate_section): Likewise. Set REL addends correctly.
4854 (set_pltoff_entry): Likewise.
4855 (ia64_howto_table): Remove R_IA64_SEGBASE, and R_IA64_EPLT[ML]SB
4856 (elfNN_ia64_reloc_type_lookup): Likewise.
4857 (elfNN_ia64_install_value): Likewise.
4858 (elfNN_ia64_relocate_section): Likewise.
4859 * reloc.c (BFD_RELOC_IA64_SEGBASE): Remove.
4860 (BFD_RELOC_IA64_EPLTMSB, BFD_RELOC_IA64_EPLTLSB): Remove.
4862 2000-11-16 Kazu Hirata <kazu@hxi.com>
4864 * cpu-a29k.c: Fix formatting.
4865 * cpu-alpha.c: Likewise.
4866 * cpu-arm.c: Likewise.
4867 * cpu-avr.c: Likewise.
4868 * cpu-d10v.c: Likewise.
4869 * cpu-h8500.c: Likewise.
4870 * cpu-hppa.c: Likewise.
4871 * cpu-i370.c: Likewise.
4872 * cpu-i386.c: Likewise.
4873 * cpu-i960.c: Likewise.
4874 * cpu-ia64-opc.c: Likewise.
4875 * cpu-ia64.c: Likewise.
4876 * cpu-m32r.c: Likewise.
4877 * cpu-m68hc11.c: Likewise.
4878 * cpu-m68hc12.c: Likewise.
4879 * cpu-m68k.c: Likewise.
4880 * cpu-m88k.c: Likewise.
4881 * cpu-mips.c: Likewise.
4882 * cpu-ns32k.c: Likewise.
4883 * cpu-pj.c: Likewise.
4884 * cpu-powerpc.c: Likewise.
4885 * cpu-sh.c: Likewise.
4886 * cpu-sparc.c: Likewise.
4887 * cpu-tic54x.c: Likewise.
4888 * cpu-v850.c: Likewise.
4889 * cpu-vax.c: Likewise.
4890 * cpu-w65.c: Likewise.
4891 * cpu-we32k.c: Likewise.
4892 * cpu-z8k.c: Likewise.
4893 * dwarf1.c: Likewise.
4894 * dwarf2.c: Likewise.
4896 2000-11-15 Kazu Hirata <kazu@hxi.com>
4898 * coff-arm.c: Fix formatting.
4899 * coff-ppc.c: Likewise.
4900 * coff-rs6000.c: Likewise.
4901 * coff-sh.c: Likewise.
4902 * coff-sparc.c: Likewise.
4903 * coff-tic30.c: Likewise.
4904 * coff-tic54x.c: Likewise.
4905 * coff-tic80.c: Likewise.
4906 * coff-w65.c: Likewise.
4907 * coff-we32k.c: Likewise.
4908 * coff-z8k.c: Likewise.
4910 2000-11-15 Richard Henderson <rth@redhat.com>
4912 * elf64-alpha.c (elf64_alpha_check_relocs): Create the reloc
4913 section with the same ALLOC|LOAD flags as the source section.
4915 2000-11-14 Jakub Jelinek <jakub@redhat.com>
4917 * elf64-alpha.c (elf64_alpha_relax_opt_call): Only check bits used
4918 by STO_ALPHA constants.
4920 2000-11-14 Kazu Hirata <kazu@hxi.com>
4922 * coff-pmac.c: Fix formatting.
4923 * coff-ppc.c: Likewise.
4925 2000-11-13 H.J. Lu <hjl@gnu.org>
4927 * elflink.h (elf_link_add_object_symbols): Also add indirect
4928 symbols for common symbols with the default version.
4930 2000-11-09 Philip Blundell <pb@futuretv.com>
4932 * section.c (STD_SECTION): Set gc_mark flag.
4934 2000-11-11 Kazu Hirata <kazu@hxi.com>
4936 * coff-i960.c: Likewise.
4937 * coff-m68k.c: Likewise.
4938 * coff-m88k.c: Likewise.
4939 * coff-mcore.c: Likewise.
4940 * coff-mips.c: Likewise.
4942 2000-11-11 Bernd Schmidt <bernds@cygnus.co.uk>
4944 * elf32-sh.c (sh_elf_relocate_section): Ignore R_SH_NONE relocs.
4946 2000-11-10 Kazu Hirata <kazu@hxi.com>
4948 * coff-h8300.c: Fix formatting.
4949 * coff-h8500.c: Likewise.
4950 * coff-i386.c: Likewise.
4951 * coff-i860.c: Likewise.
4952 * coff-i960.c: Likewise.
4953 * coff-ia64.c: Likewise.
4955 2000-11-09 Kazu Hirata <kazu@hxi.com>
4957 * archive.c: Fix formatting.
4958 * archures.c: Likewise.
4960 2000-11-07 Richard Henderson <rth@redhat.com>
4962 * elfxx-ia64.c (elf64_ia64_final_link): New local unwind_output_sec.
4963 Set it before bfd_elf64_bfd_final_link call. Use it after the call.
4964 * section.c (bfd_set_section_contents): Call memcpy if
4965 section->contents set and location not equal to contents plus offset.
4967 2000-11-08 Kazu Hirata <kazu@hxi.com>
4969 * bfd-in.h: Fix formatting.
4970 * bfd-in2.h: Likewise.
4972 * binary.c: Likewise.
4974 * coff-a29k.c: Likewise.
4975 * coff-alpha.c: Likewise.
4976 * coff-apollo.c: Likewise.
4977 * coff-aux.c: Likewise.
4979 2000-11-07 Kazu Hirata <kazu@hxi.com>
4981 * aix386-core.c: Fix formatting.
4982 * aoutf1.h: Likewise.
4983 * aoutx.h: Likewise.
4984 * archures.c: Likewise.
4985 * armnetbsd.c: Likewise.
4987 2000-11-07 Alan Modra <alan@linuxcare.com.au>
4989 * coff-h8300.c (special): Adjust reloc address.
4991 2000-11-06 Steve Ellcey <sje@cup.hp.com>
4993 * archures.c (bfd_mach_ia64_elf64, bfd_mach_ia64_elf32): Add defines
4994 to differentiate elf32 and elf64 on ia64.
4995 * bfd-in2.h: Regenerate.
4996 * config.bfd: Add target for "ia64*-*-hpux*".
4997 * configure.in: Add bfd_elf32_ia64_big_vec to selvecs switch.
4998 * configure: Regenerate.
4999 * cpu-ia64.c (bfd_ia64_elf32_arch): Add elf32 arch info structure.
5000 * targets.c: Add bfd_target bfd_elf32_ia64_big_vec.
5002 * Makefile.am: Make elf32-ia64.c and elf64-ia64.c derived objects
5003 from elfxx-ia64.c. Add depenency rules for making elf32-ia64.lo.
5004 * Makefile.in: Regnerate.
5005 * elf64-ia64.c: Deleted.
5006 * elfxx-ia64.c: New file, paramaterized version of elf64-ia64.c.
5008 2000-11-06 Kazu Hirata <kazu@hxi.com>
5010 * aout-adobe.c: Fix formatting.
5011 * aout-arm.c: Likewise.
5012 * aout-cris.c: Likewise.
5013 * aout-encap.c: Likewise.
5014 * aout-ns32k.c: Likewise.
5015 * aout-target.h: Likewise.
5016 * aout-tic30.c: Likewise.
5018 2000-11-05 Philip Blundell <philb@gnu.org>
5020 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Always permit
5021 BFDs containing no sections to be merged, regardless of their flags.
5023 2000-11-04 Philip Blundell <philb@gnu.org>
5025 * elf32-arm.h (elf32_arm_relocate_section): Suppress error message
5026 if a relocation for an undefined symbol also results in an
5029 2000-11-06 Christopher Faylor <cgf@cygnus.com>
5031 * config.bfd: Add support for Sun Chorus.
5033 2000-11-05 David O'Brien <obrien@FreeBSD.org>
5035 * configure.in: Recognize alpha-*-freebsd*.
5036 * configure: Regenerate.
5038 2000-11-02 Luciano Gemme <ishitawa@yahoo.com>
5040 * srec.c (CHUNK): Rename to DEFAULT_CHUNK.
5041 (Chunk): New global variable set by a parameter in objcopy.c.
5042 (S3Forced): New global variable set by a parameter in
5044 (srec_set_section_contents): If S3Forced is true, always generate
5046 (srec_write_section): Use 'Chunk' to limit maximum length of S
5049 2000-11-02 Per Lundberg <plundis@chaosdev.org>
5051 * config.bfd: Add support for i[3456]86-chaosdev-storm-chaos.
5052 * Makefile.in: Regenerate.
5053 * bfd-in2.h: Regenerate.
5054 * po/bfd.pot: Regenerate.
5056 2000-10-31 Philip Blundell <philb@gnu.org>
5058 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Only handle
5059 EF_SOFT_FLOAT if it is defined.
5061 2000-10-27 Philip Blundell <philb@gnu.org>
5063 * elf32-arm.h (elf32_arm_copy_private_bfd_data): Don't refuse
5064 attempts to mix PIC code with non-PIC, just mark the output as
5065 being position dependent.
5066 (elf32_arm_merge_private_bfd_data): Likewise. Print an error
5067 message for EF_SOFT_FLOAT mismatches. Display diagnostics for
5068 all mismatches, not just the first one.
5070 2000-10-25 Chris Demetriou <cgd@sibyte.com>
5072 * ieee.c (ieee_archive_p): Plug one of many possible
5073 memory leaks in error handling.
5075 2000-10-20 Jakub Jelinek <jakub@redhat.com>
5077 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data,
5078 elf32_sparc_object_p, elf32_sparc_final_write_processing):
5080 * elf64-sparc.c (sparc64_elf_merge_private_bfd_data,
5081 sparc64_elf_object_p): Support v9b.
5082 * archures.c: Declare v8plusb and v9b machines.
5084 * cpu-sparc.c: Ditto.
5086 2000-10-16 Geoffrey Keating <geoffk@shoggoth.cygnus.com>
5088 * elf64-sparc.c (sparc64_elf_relocate_section): Clear the location
5091 * elf32-ppc.c (SYMBOL_REFERENCES_LOCAL): New macro.
5092 (SYMBOL_CALLS_LOCAL): New macro.
5093 (ppc_elf_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL.
5094 (ppc_elf_check_relocs): Use SYMBOL_REFERENCES_LOCAL.
5095 (ppc_elf_finish_dynamic_symbol): Use SYMBOL_REFERENCES_LOCAL.
5096 (ppc_elf_relocate_section): Use flag variable to determine
5097 whether the relocation refers to a local symbol.
5098 Test whether a PLTREL24 reloc will produce a reloc by looking
5099 to see whether a PLT entry was made.
5101 2000-10-14 Geoffrey Keating <geoffk@shoggoth.cygnus.com>
5103 * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Don't make PLT
5104 entries that could serve as a definition for a weak symbol.
5106 2000-10-13 Ulf Carlsson <ulfc@engr.sgi.com>
5108 From Ralf Baechle <ralf@gnu.org>
5110 * elf32-mips.c (mips_elf_create_dynamic_relocation): New argument
5111 local_p. Add symbol value only for non-R_MIPS_REL32 relocations
5112 against local symbols.
5113 (_bfd_mips_elf_finish_dynamic_sections): Undo patch from 2000-10-01.
5115 2000-10-12 Alan Modra <alan@linuxcare.com.au>
5117 * section.c (struct sec): Add kept_section.
5118 (struct bfd_comdat_info): Remove sec, we can use above.
5119 (STD_SECTION): Add initializer.
5120 (bfd_make_section_anyway): Init here too.
5122 * bfd-in2.h: Regenerate.
5124 * elflink.h (elf_link_add_object_symbols): Remove unnecessary
5126 (elf_link_input_bfd): Set all asection->symbol->value's here, and
5127 fudge values for discarded link-once section symbols.
5129 * elf64-hppa.c: Include alloca-conf.h
5131 2000-10-11 Alan Modra <alan@linuxcare.com.au>
5133 * elf.c (swap_out_syms): Revert 2000-10-07 changes.
5135 * ieee.c (ieee_make_empty_symbol): Oops, bfd_zalloc needs another arg.
5137 2000-10-10 Alan Modra <alan@linuxcare.com.au>
5139 * ieee.c (ieee_make_empty_symbol): Use bfd_zalloc, not bfd_zmalloc.
5141 2000-10-10 Tom Rix <trix@redhat.com>
5143 * section.c (bfd_make_section_anyway): Release newsect ptr when
5144 newsect->symbol fails to alloc. Use bfd_release instead of free.
5146 2000-10-09 Richard Henderson <rth@cygnus.com
5148 * elf64-ia64.c (elf64_ia64_unwind_entry_compare_bfd): New.
5149 (elf64_ia64_unwind_entry_compare): New.
5150 (elf64_ia64_final_link): Sort the .IA_64.unwind section.
5152 2000-10-07 Alan Modra <alan@linuxcare.com.au>
5154 * elflink.h (size_dynamic_sections): Don't create various tags if
5155 .dynstr is excluded from the link. Don't set first dynsym entry
5156 if dynsymcount is zero.
5157 (elf_bfd_final_link): Don't try to swap out dynamic syms if
5158 .dynsym excluded from the link. Don't try to write any dynamic
5159 sections excluded from the link.
5161 * elf.c (swap_out_syms): Handle global section symbols.
5163 2000-10-05 DJ Delorie <dj@redhat.com>
5165 * peigen.c (_bfd_pei_swap_scnhdr_out): note extended relocs
5166 * coffcode.h (coff_set_alignment_hook): read extended reloc count
5167 (coff_write_relocs): write extended reloc count
5168 (coff_write_object_contents): account for extended relocs
5170 2000-10-05 Jim Wilson <wilson@cygnus.com>
5172 * elf-bfd.h (struct elf_backend_data): Add elf_backend_section_flags
5174 * elf.c (_bfd_elf_make_section_from_shdr): Call the
5175 elf_backend_section_flags function.
5176 * elf64-ia64.c (elf64_ia64_section_from_shdr): Delete flag conversion
5178 (elf64_ia64_section_flags): New function containing flag conversion
5180 (elf_backend_section_flags): Define to elf64_ia64_section_flags.
5181 * elfxx-target.h (elf_backend_section_flags): Define.
5182 (elfNN_bed): Initialize elf_backend_section_flags field.
5184 2000-10-02 Alan Modra <alan@linuxcare.com.au>
5186 * elf32-hppa.c (elf32_hppa_check_relocs): Correct call to
5187 _bfd_elf32_gc_record_vtable. Correct a comment.
5189 2000-10-01 Ulf Carlsson <ulfc@engr.sgi.com>
5191 From Ralf Baechle <ralf@gnu.org>
5193 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_sections): Mark gld
5194 produces binaries with got[1] = 0x80000001 to differenciate them
5195 for the dynamic linker from the broken binaries produced by old
5198 2000-09-30 Petr Sorfa <petrs@sco.com>
5200 * elf.c (elfcore_grok_pstatus): Check for size of pxstatus_t.
5201 (elfcore_grok_lwpstatus): Check for size of lwpxstatus_t.
5202 * configure.in: Add check for pxstatus_t and lwpxstatus_t.
5203 * configure: Regenerate.
5205 2000-09-27 Hans-Peter Nilsson <hp@axis.com>
5207 Define two bfd_targets for absence and presence of leading
5208 underscore on symbols. Make sure to only link same kind.
5209 * elf32-cris.c (cris_elf_object_p,
5210 cris_elf_final_write_processing, cris_elf_print_private_bfd_data,
5211 cris_elf_merge_private_bfd_data): New.
5212 (elf_backend_object_p, elf_backend_final_write_processing,
5213 bfd_elf32_bfd_print_private_bfd_data,
5214 bfd_elf32_bfd_merge_private_bfd_data): Define.
5215 <Target vector definition>: Include elf32-target.h twice with
5216 different macro settings:
5217 (TARGET_LITTLE_SYM): First as bfd_elf32_cris_vec, then as
5218 bfd_elf32_us_cris_vec.
5219 (TARGET_LITTLE_NAME): First as "elf32-cris", then "elf32-us-cris".
5220 (elf_symbol_leading_char): First as 0, then '_'.
5221 (INCLUDED_TARGET_FILE): Define for second include of elf32-target.h.
5222 * config.bfd (cris-*-*): Add bfd_elf32_us_cris_vec to targ_selvecs.
5223 * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vector.
5224 * configure: Regenerate.
5225 * targets.c: Declare bfd_elf32_us_cris_vec.
5226 * po/bfd.pot: Regenerate.
5228 2000-09-29 Momchil Velikov <velco@fadata.bg>
5230 * elf32-arm.h (arm_add_to_rel): Correctly adjust the addend for
5231 R_ARM_THM_PC22 relocations.
5233 2000-09-29 NIIBE Yutaka <gniibe@chroot.org>
5235 * elflink.h (elf_link_add_object_symbols): Don't bfd_release runpath.
5237 2000-09-29 Momchil Velikov <velco@fadata.bg>
5239 * elf.c (elf_fake_sections): Do not mark the section SHT_NOBITS if
5240 is has the SEC_HAS_CONTENTS flag set.
5242 2000-09-28
\81Örjan Friberg <orjanf@axis.com>
5243 Hans-Peter Nilsson <hp@axis.com>
5245 * aout-cris.c (N_TXTADDR): Define.
5247 2000-09-28 John David Anglin <dave@hiauly1.hia.nrc.ca>
5249 * som.c: Include alloca-conf.h.
5250 * Makefile.am: "make dep-am"
5251 * Makefile.in: Regenerate.
5253 2000-09-27 Alan Modra <alan@linuxcare.com.au>
5255 * elf32-hppa.c (plt_stub): New.
5256 (PLT_STUB_ENTRY): Define.
5257 (elf32_hppa_link_hash_table): Change multi_subspace to packed
5258 boolean. Add need_plt_stub, has_12bit_branch and has_17bit_branch.
5259 (elf32_hppa_link_hash_table_create): Init to suit.
5260 (elf32_hppa_check_relocs): Set has_12bit_branch and
5261 has_17bit_branch as appropriate.
5262 (elf32_hppa_adjust_dynamic_symbol): Set need_plt_stub for
5263 non-local functions.
5264 (elf32_hppa_size_dynamic_sections): Correct setting of reltext.
5265 Add space for plt_stub as needed.
5266 (elf32_hppa_finish_dynamic_symbol): Point .plt entries for global
5267 functions at plt_stub.
5268 (elf32_hppa_finish_dynamic_sections): Write plt_stub.
5269 (elf32_hppa_create_dynamic_sections): Leave .plt executable.
5271 * elf32-hppa.h (elf32_hppa_size_stubs): Add group_size param.
5272 * elf32-hppa.c (elf32_hppa_size_stubs): Likewise. Use it instead
5273 of fixed size, and if negative, disable handling of input sections
5274 before stub section. Set up default stub group size depending
5275 on detected branch relocs.
5276 (hppa_build_one_stub): Use lrsel and rrsel for import stubs to
5277 ensure different offsets from sym_value aren't rounded to
5278 different 2k blocks. Use lrsel and rrsel for other stubs too for
5279 consistency rather than necessity.
5280 (elf32_hppa_check_relocs): Handle R_PARISC_DIR14F.
5281 (final_link_relocate): Likewise.
5282 (elf32_hppa_relocate_section): Likewise.
5284 * elf-hppa.h (elf_hppa_howto_table): Add R_PARISC_DIR14F reloc.
5285 (_bfd_elf_hppa_gen_reloc_type): Generate them.
5286 (elf_hppa_final_link_relocate): Handle them.
5287 (elf_hppa_relocate_insn): Likewise.
5288 (_bfd_elf_hppa_gen_reloc_type): Add missing e_ldsel and e_rdsel cases.
5290 2000-09-26 Hans-Peter Nilsson <hp@axis.com>
5292 * elfcode.h (elf_object_p): Preserve and clear abfd section
5293 information. Restore at error.
5295 2000-09-26 Paul Sokolovsky <Paul.Sokolovsky@technologist.com>
5297 * peigen.c (_bfd_pei_swap_aouthdr_in): If some DataDirectory
5298 is empty, make sure that its rva also 0. NT loader dislikes
5301 2000-09-26 Steve Ellcey <sje@cup.hp.com>
5303 * som.c (som_bfd_derive_misc_symbol_info): Make weak symbols
5306 2000-09-21 Alan Modra <alan@linuxcare.com.au>
5308 * elf32-hppa.c (elf32_hppa_check_relocs): Fix weak sym handling in
5309 currently unused RELATIVE_DYNAMIC_RELOCS code.
5310 (hppa_discard_copies): Likewise.
5311 (elf32_hppa_size_stubs): Size `input_list' array correctly. Correct
5312 comments. Don't check non-code output sections for stub grouping.
5314 2000-09-20 Alan Modra <alan@linuxcare.com.au>
5316 * section.c (bfd_get_unique_section_name): Return NULL if
5319 2000-09-19 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5321 * elf32-m68k.c (elf_cpu32_plt0_entry): Change the PLT entry 0
5322 instruction sequence to actually work.
5323 (elf_m68k_finish_dynamic_sections): Change the patch-in offset
5326 2000-09-18 Alexandre Oliva <aoliva@redhat.com>
5328 * elf32-sh.c (sh_elf_relocate_section): Use
5329 _bfd_final_link_relocate to apply the relocation against a section
5330 symbol, when doing relocatable links.
5332 2000-09-18 Alan Modra <alan@linuxcare.com.au>
5334 * elf32-hppa.c (elf32_hppa_stub_hash_entry): Rename input_section
5336 (stub_hash_newfunc): Here too.
5337 (hppa_add_stub): And here.
5338 (elf32_hppa_link_hash_table): Remove stub_section_created,
5339 reloc_section_created, first_init_sec and first_fini_sec. Add
5341 (elf32_hppa_link_hash_table_create): Init to suit.
5342 (hppa_get_stub_entry): Add support for grouping stub sections.
5343 (hppa_add_stub): Likewise. Remove sec_count param and init/fini
5344 section code. Index stub vars by section->id.
5345 (elf32_hppa_size_stubs): Likewise. Remove duplicated function
5346 exit paths. Zap allocation of above removed vars. Refine
5349 * elf32-hppa.h (elf32_hppa_size_stubs): Add output_bfd param.
5350 * elf32-hppa.c (elf32_hppa_size_stubs): Likewise.
5351 (hppa_get_stub_entry): Pass in pointer to elf32_hppa_link_hash_table
5352 rather than pointer to bfd_link_info.
5353 (hppa_add_stub): Likewise.
5354 (final_link_relocate): Likewise.
5356 2000-09-17 David Huggins-Daines <dhd@linuxcare.com>
5358 (elf32_hppa_size_stubs): Don't try to build stubs for discarded
5361 2000-09-16 Alexandre Oliva <aoliva@redhat.com>
5363 * elf32-sh.c (ELF_MAXPAGESIZE): Define to 128, to match
5364 ld/emulparams/shelf.sh.
5366 2000-09-10 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5368 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): New function.
5369 * bfd-in.h (bfd_m68k_elf32_create_embedded_relocs): Add declaration.
5370 * bfd-in2.h: Regenerate.
5372 2000-09-15 Kenneth Block <Kenneth.Block@compaq.com>
5374 * elf64-alpha.c (elf64_alpha_relax_with_lituse): ld performs
5375 LITUSE relocations incorrectly if -relax is specified on the ld
5376 command line and the displacement field of the load or store
5377 instruction is non-zero. (Patch by paul.winalski@compaq.com)
5379 2000-09-15 Alan Modra <alan@linuxcare.com.au>
5381 * elf32-hppa.c (hppa_add_stub): Dont set first_init_sec and
5382 first_fini_sec here.
5383 (elf32_hppa_size_stubs): Instead correctly find the first .init
5384 and .fini section here.
5386 2000-09-15 David Huggins-Daines <dhd@linuxcare.com>
5388 * elf32-hppa.c (clobber_millicode_symbols): New function.
5389 (elf32_hppa_size_dynamic_sections): Call it.
5391 2000-09-14 Alan Modra <alan@linuxcare.com.au>
5393 * elf32-hppa.c (elf32_hppa_link_hash_entry): Make pic_call
5394 packed. Add plabel, plt_abs packed booleans.
5395 (hppa_link_hash_newfunc): Init new fields.
5396 (PLABEL_PLT_ENTRY_SIZE): Define.
5397 (hppa_stub_name): Use size_t len vars.
5398 (hppa_add_stub): Likewise.
5399 (elf32_hppa_build_stubs): Likewise.
5400 (hppa_build_one_stub): Kill some compiler warnings.
5401 (elf32_hppa_check_relocs): Always generate a plt entry for PLABELs
5402 if dynamic linking. Munge the local plt offsets into
5403 local_got_refcounts. Set h->plabel for all global PLABELs. Use
5404 size_t len vars. Add assert for plabel addend.
5405 (elf32_hppa_gc_sweep_hook): Sweep local plt entries too.
5406 (elf32_hppa_hide_symbol): New function.
5407 (elf_backend_hide_symbol): Define.
5408 (elf32_hppa_adjust_dynamic_symbol): Don't throw away plt entries
5409 with h->plabel set. Don't make plt entries to have dynamic syms
5410 when they have been forced local. If plt entry is used by a
5411 plabel, make it PLABEL_PLT_ENTRY_SIZE.
5412 (elf32_hppa_size_dynamic_sections): Set plt_abs for init fns.
5413 Set up .plt offsets for local syms.
5414 (elf32_hppa_relocate_section): Initialise plt entries for local
5415 syms. Leave weak undefined plabels zero. Make global plabel
5416 relocs against function symbol, and leave the addend zero.
5417 Use *ABS* DIR32 relocs instead of SEGREL32 for dynamic got relocs.
5418 (elf32_hppa_finish_dynamic_symbol): Set up IPLT relocs for
5419 non-dynamic syms. Init extra plt for plabels. Use *ABS* DIR32
5420 relocs instead of SEGREL32 for dynamic got relocs.
5421 (elf32_hppa_finish_dynamic_sections): Reserve one more .got entry.
5422 (elf_backend_got_header_size): Adjust.
5423 (elf32_hppa_set_gp): Calculate an "ideal" LTP.
5425 * elf32-hppa.c (LONG_BRANCH_VIA_PLT): Define.
5426 (hppa_type_of_stub): Use it instead of #if 0
5427 (hppa_discard_copies): Use it here too.
5428 (elf32_hppa_size_dynamic_sections): And here.
5430 * elf32-hppa.c (elf32_hppa_link_hash_table): Remove `offset' field.
5431 (elf32_hppa_link_hash_table_create): And here.
5432 (hppa_build_one_stub): And here. Instead keep track of stub
5433 offset using _raw_size.
5434 (elf32_hppa_size_stubs): Likewise.
5435 (elf32_hppa_build_stubs): Likewise.
5436 (hppa_size_one_stub): Likewise. Resize reloc section too.
5438 * elf32-hppa.c (hppa_add_stub): Correct first_init_sec and
5439 first_fini_sec handling. Don't search for reloc section or set
5440 hplink->reloc_section_created here.
5441 (elf32_hppa_size_stubs): Instead search for reloc sections, and
5442 set reloc_section_created here.
5443 (hppa_handle_PIC_calls): Set ELF_LINK_HASH_NEEDS_PLT.
5444 (elf32_hppa_size_dynamic_sections): Make a .plt entry for DT_INIT
5446 (elf32_hppa_finish_dynamic_sections): Set DT_INIT and DT_FINI.
5448 * elf32-hppa.c (hppa_build_one_stub): Replace `elf_hash_table (info)'
5449 with `hplink->root.'.
5450 (elf32_hppa_check_relocs): Likewise.
5451 (elf32_hppa_gc_sweep_hook): Likewise.
5452 (elf32_hppa_adjust_dynamic_symbol): Likewise.
5453 (hppa_handle_PIC_calls): Likewise.
5454 (elf32_hppa_size_dynamic_sections): Likewise.
5455 (elf32_hppa_set_gp): Likewise.
5456 (elf32_hppa_relocate_section): Likewise.
5457 (elf32_hppa_finish_dynamic_symbol): Likewise.
5458 (elf32_hppa_finish_dynamic_sections): Likewise.
5460 From David Huggins-Daines <dhd@linuxcare.com>
5461 * elf32-hppa.c (hppa_type_of_stub): Generate import stubs for
5462 defined weak symbols in shared links.
5463 (final_link_relocate): Calls to defined weak symbols in shared
5464 objects must go via import stubs, as the target might not be known
5467 2000-09-14 Alexandre Oliva <aoliva@redhat.com>
5469 * elf32-sh.c (sh_elf_howto_table): Moved R_SH_GOT32, R_SH_PLT32,
5470 R_SH_COPY, R_SH_GLOB_DAT, R_SH_JMP_SLOT, R_SH_RELATIVE,
5471 R_SH_GOTOFF, R_SH_GOTPC) to the range from 160 to 167. Replaced
5472 the original entries with EMPTY_HOWTOs, and added new ones to fill
5474 (sh_elf_info_to_howto): Make sure the new gap isn't used.
5475 (sh_elf_relocate_section): Likewise.
5477 2000-09-13 Anders Norlander <anorland@acc.umu.se>
5479 * cpu-mips.c (arch_info_struct): Add mips:4K
5480 * bfd-in2.h (bfd_mach_mips4K): New define.
5481 * archures.c: Add bfd_mach_mips4K to comment.
5482 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Return
5483 E_MIPS_ARCH_2 for bfd_mach_mips4K.
5485 2000-09-13 Marco Franzen <marcof@thyron.com>
5487 * som.c (som_write_symbol_strings): Do not used fixed buffers,
5488 use size_t as a counter.
5489 (som_write_space_strings): Similarly.
5491 2000-09-12 Jason Eckhardt <jle@cygnus.com>
5493 * elf32-i860.c (elf32_i860_relocate_pc26): New function
5495 (elf32_i860_relocate_section): Invoke new function from here.
5497 2000-09-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5499 * elf.c (_bfd_elf_make_section_from_shdr): Make debug_sec_names
5502 2000-09-10 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5504 * coff-m68k.c (bfd_m68k_coff_create_embedded_relocs): Emit 8 NULs for
5505 target section name instead of dumping core when the target symbol is
5508 2000-09-09 Kazu Hirata <kazu@hxi.com>
5510 * riscix.c: Remove DEFUN.
5512 2000-09-08 Nick Clifton <nickc@redhat.com>
5514 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Do not
5515 initialise flags in output bfd if the input bfd is the default
5516 architecture with the default flags.
5518 2000-09-08 Kazu Hirata <kazu@hxi.com>
5520 * archive.c: Fix formatting.
5521 * coff-arm.c: Likewise.
5522 * doc/chew.c: Likewise.
5524 2000-09-08 Alan Modra <alan@linuxcare.com.au>
5526 * section.c (bfd_get_unique_section_name): Put a dot before the
5529 2000-09-07 Kazu Hirata <kazu@hxi.com>
5531 * doc/chew.c: Remove all uses of DEFUN and DEFUN_VOID.
5532 * elf.c: Fix formatting.
5534 2000-09-07 Alexandre Oliva <aoliva@redhat.com>
5536 * config.bfd (sh-*-linux*): Added.
5537 * configure.in (bfd_elf32_shlin_vec, bfd_elf32_shblin_vec): New.
5538 * targets.c: Declare them.
5539 * elf32-sh-lin.c: New file.
5540 * Makefile.am: Compile it.
5541 * elf32-sh.c: Don't override defines from elf32-sh-lin.c.
5542 * configure, Makefile.in: Rebuilt.
5544 2000-09-06 Geoffrey Keating <geoffk@cygnus.com>
5546 * xcofflink.c (xcoff_link_input_bfd): Include the .tocbss
5547 pseduo-section when determining where the TOC ends.
5549 * coff-rs6000.c (_bfd_xcoff_swap_aux_out): Use bfd_h_put_16 to
5550 output x_tvndx as it is only two bytes wide.
5552 * coff-rs6000.c (xcoff_howto_table): A modifiable branch-absolute
5553 reloc is 26 or 32 bits wide.
5555 * coff-rs6000.c (_bfd_xcoff_rtype2howto): The bitsize is irrelevant
5556 for relocs that don't change anything. Also look at the full
5559 2000-09-06 Philip Blundell <philb@gnu.org>
5561 * config.bfd (arm*-*-uclinux*): New target.
5563 2000-09-06 Alexandre Oliva <aoliva@redhat.com>
5565 * configure: Rebuilt with new libtool.m4.
5567 2000-09-06 Alan Modra <alan@linuxcare.com.au>
5569 * section.c (bfd_get_unique_section_name): Avoid c++ reserved
5570 word for variable name.
5571 * bfd-in2.h: Regenerate.
5573 2000-09-05 Nick Clifton <nickc@redhat.com>
5575 * config.in: Regenerate.
5576 * libbfd.h: Regenerate.
5577 * po/bfd.pot: Regenerate.
5578 * doc/bfdint.texi: Remove CVS date string - it foils compares with
5581 2000-09-05 Steven Johnson <sbjohnson@ozemail.com.au>
5583 * cpu-powerpc.c (arch_info_struct): Added MPC860 Family entry.
5585 2000-09-05 Alan Modra <alan@linuxcare.com.au>
5587 Shared library and PIC support.
5588 * elf32-hppa.c (PLT_ENTRY_SIZE): New.
5589 (GOT_ENTRY_SIZE): New.
5590 (ELF_DYNAMIC_INTERPRETER): New.
5591 (STUB_SUFFIX): Define.
5592 (LONG_BRANCH_PIC_IN_SHLIB): Define.
5593 (RELATIVE_DYNAMIC_RELOCS): Define.
5594 (enum elf32_hppa_stub_type): New.
5595 (struct elf32_hppa_stub_hash_entry): Rename offset to
5596 stub_offset. Add a number of new fields.
5597 (struct elf32_hppa_link_hash_entry): New.
5598 (struct elf32_hppa_link_hash_table): Add numerous fields. Remove
5600 (elf32_hppa_hash_table): Rename to hppa_link_hash_table.
5601 (elf32_hppa_stub_hash_lookup): Rename to hppa_stub_hash_lookup.
5602 (elf32_hppa_stub_hash_newfunc): Rename to stub_hash_newfunc. Init
5604 (hppa_link_hash_newfunc): New function.
5605 (elf32_hppa_link_hash_table_create): Use above function. Init new
5607 (elf32_hppa_stub_name): Rename to hppa_stub_name. Pass in reloc
5608 instead of addend, and remove sym_name from args. Don't use
5609 symbol name for local syms, instead use sym index.
5610 (elf32_hppa_size_of_stub): Rename to hppa_type_of_stub, and return
5611 stub type rather than size. Pass in hash and handle import stub
5612 case. Also pass in reloc instead of offset so we can calculate
5613 PCREL22F and PCREL12F branches properly.
5614 (elf32_hppa_build_one_stub): Rename to hppa_build_one_stub. Build
5615 import and export stubs too.
5616 (elf32_hppa_size_one_stub): Rename to hppa_size_one_stub. Handle
5617 import and export stub sizing.
5618 (elf32_hppa_check_relocs): New function.
5619 (elf32_hppa_adjust_dynamic_symbol): New function.
5620 (hppa_discard_copies): New function.
5621 (elf32_hppa_size_dynamic_sections): New function.
5622 (elf_backend_size_dynamic_sections): Define.
5623 (elf32_hppa_finish_dynamic_symbol): New function.
5624 (elf_backend_finish_dynamic_symbol): Define.
5625 (elf32_hppa_size_stubs): Stash params in link hash table, and move
5626 some local vars into the link hash table too. For shared links,
5627 trundle over function syms, generating export stubs. Handle
5628 PCREL22F branches. Break out stub creation code from here..
5629 (hppa_add_stub): .. to here. New function.
5630 (elf32_hppa_final_link): Rename to elf32_hppa_set_gp, and don't
5631 call the bfd linker. Use elf_gp to record global pointer.
5632 Calculate a value from sections if $global$ is missing.
5633 (bfd_elf32_bfd_final_link): Define as _bfd_elf32_gc_common_final_link.
5634 (elf32_hppa_gc_mark_hook): New function.
5635 (elf_backend_gc_mark_hook): Define.
5636 (elf32_hppa_gc_sweep_hook): New function.
5637 (elf_backend_gc_sweep_hook): Define.
5638 (elf32_hppa_bfd_final_link_relocate): Rename to final_link_relocate.
5639 Add rel to args, and remove howto, input_bfd, offset, addend,
5640 sym_name as we can recalculate these locally. Handle calls to
5641 dynamic objects, extra PIC relocs, PCREL22F branches. Change
5642 handling of undefined weak syms. Check that stubs are in range.
5643 Only look for import stubs on PCREL17F and PCREL22F relocs. Add
5644 message on hitting a DPREL21L reloc that needs fixing. Subtract
5645 off PC for PCREL14F. Break out code that does a stub lookup from
5647 (hppa_get_stub_entry): ..to here. New function.
5648 (elf32_hppa_relocate_insn): Merge into final_link_relocate.
5649 (elf32_hppa_relocate_section): Handle got and plt relocs, dynamic
5651 (elf32_hppa_finish_dynamic_sections): New function.
5652 (elf_backend_finish_dynamic_sections): Define.
5653 (elf_backend_final_write_processing) Define.
5654 (hppa_handle_PIC_calls): New function.
5655 (elf32_hppa_build_stubs): Call it. Pass link_info to
5656 hppa_build_one_stub.
5657 (elf32_hppa_create_dynamic_sections): New function
5658 to create .plt and .got then set .plt flags correctly.
5659 (elf_backend_create_dynamic_sections): Define.
5660 (elf32_hppa_object_p): New function.
5661 (elf_backend_object_p): Define.
5662 (elf32_hppa_elf_get_symbol_type): New function.
5663 (elf_backend_get_symbol_type): Define.
5664 (elf_backend_can_gc_sections): Define.
5665 (elf_backend_want_got_plt): Define.
5666 (elf_backend_plt_alignment): Set to 2.
5667 (elf_backend_plt_readonly): Define.
5668 (elf_backend_want_plt_sym): Define.
5669 (elf_backend_got_header_size): Reserve one entry.
5671 * elf32-hppa.h (elf32_hppa_build_stubs): Don't pass stub bfd.
5672 (elf32_hppa_size_stubs): Pass in multi_subspace.
5673 (elf32_hppa_set_gp): Declare.
5675 * section.c (SEC_HAS_GOT_REF): Define new flag for asection.
5676 (bfd_get_unique_section_name): New function.
5677 * bfd-in2.h: Regenerate.
5679 * elf64-hppa.c (elf64_hppa_check_relocs): Handle R_PARISC_PCREL12F.
5680 (elf64_hppa_size_dynamic_sections): Remove the FIXME at bfd_zalloc
5683 From David Huggins-Daines <dhd@linuxcare.com>
5684 * elf64-hppa.c (elf64_hppa_check_relocs): Fix a warning.
5685 (elf64_hppa_mark_exported_functions): Set dyn_h->st_shndx.
5686 (elf64_hppa_link_output_symbol_hook): Test dyn_h->st_shndx has
5687 been updated in finish_dynamic_symbol before modifying function
5690 * elf-hppa.h (elf_hppa_howto_table): Restructure into groups of
5691 eight entries. Replace NULL with bfd_elf_generic_reloc. Add
5692 R_PARISC_GNU_VTENTRY, R_PARISC_GNU_VTINHERIT and R_PARISC_PCREL12F.
5693 (_bfd_elf_hppa_gen_reloc_type): Handle R_PARISC_GNU_VT*. Add some
5694 comments. Handle format == 12 for R_HPPA_PCREL_CALL.
5695 (elf_hppa_final_link_relocate): Handle R_PARISC_PCREL12F.
5696 (elf_hppa_relocate_insn): Likewise. Reformat some comments.
5697 (elf_hppa_final_write_processing): Expose it for ARCH_SIZE == 32.
5699 From David Huggins-Daines <dhd@linuxcare.com>
5700 * elf-hppa.h (elf_hppa_is_local_label_name): Accept the SysV/ELF
5701 style of local labels as well.
5703 2000-09-03 Philip Blundell <philb@gnu.org>
5705 * elf32-arm.h (elf32_arm_relocate_section): Don't try to relocate
5706 references to undefined symbols in debugging sections.
5708 2000-09-02 H.J. Lu <hjl@gnu.org>
5710 * reloc.c (BFD_RELOC_SH_COPY, BFD_RELOC_SH_GLOB_DAT,
5711 BFD_RELOC_SH_JMP_SLOT, BFD_RELOC_SH_RELATIVE,
5712 BFD_RELOC_SH_GOTPC): Move them from the MIPS section to the SH
5715 2000-09-02 Jason Eckhardt <jle@cygnus.com>
5717 * elf32-i860.c (bfd_elf32_bfd_is_local_label_name): Define macro.
5718 (elf32_i860_is_local_label_name): New function and prototype.
5720 2000-09-02 Nick Clifton <nickc@redhat.com>
5722 * configure.in: Increase version number to 2.10.91.
5723 * configure: Regenerate.
5724 * aclocal.m4: Regenerate.
5725 * config.in: Regenerate.
5726 * po/bfd.pot: Regenerate.
5728 2000-09-02 Daniel Berlin <dberlin@redhat.com>
5730 * elf.c (_bfd_elf_make_section_from_shdr): Add
5731 .gnu.linkobce.wi. to the list of debug section names.
5733 2000-09-02 Nick Clifton <nickc@redhat.com>
5735 * dwarf2.c (find_debug_info): New function: Locate a section
5736 containing dwarf2 debug information.
5737 (bfd_dwarf2_find_nearest_line): Find all sections containing
5738 debug information and include them in the stash.
5740 2000-09-01 Niibe Yutaka <gniibe@m17n.org>, Kaz Kojima <kkojima@rr.iij4u.or.jp>, Alexandre Oliva <aoliva@redhat.com>
5742 * elf32-sh.c (R_SH_GOT32, R_SH_PLT32, R_SH_COPY, R_SH_GLOB_DAT,
5743 R_SH_JMP_SLOT, R_SH_RELATIVE, R_SH_GOTOFF, R_SH_GOTPC): New.
5744 (sh_reloc_map): Add new relocs.
5745 (sh_elf_check_relocs, sh_elf_link_hash_newfunc,
5746 sh_elf_link_hash_table_create, sh_elf_adjust_dynamic_symbol,
5747 sh_elf_size_dynamic_sections, sh_elf_finish_dynamic_symbol,
5748 sh_elf_finishe_dynamic_sections, sh_elf_discard_copies): New
5750 (ELF_DYNAMIC_INTERPRETER, PLT_ENTRY_SIZE): Define.
5751 (elf_sh_plt0_entry_be, elf_sh_plt0_entry_le,
5752 elf_sh_plt_entry_be, elf_sh_plt_entry_le,
5753 elf_sh_pic_plt_entry_be, elf_sh_pic_plt_entry_le):
5754 New array constants.
5755 (elf_sh_plt0_entry, elf_sh_plt_entry, elf_sh_pic_plt_entry):
5757 (elf_sh_sizeof_plt, elf_sh_plt_plt0_offset,
5758 elf_sh_plt0_linker_offset, elf_sh_plt0_gotid_offset,
5759 elf_sh_plt_temp_offset, elf_sh_plt_symbol_offset,
5760 elf_sh_plt_reloc_offset): Define.
5761 (elf_sh_pcrel_relocs_copied, elf_sh_link_hash_entry,
5762 elf_sh_link_hash_table): New structs.
5763 (sh_elf_link_hash_traverse, sh_elf_hash_table): New macros.
5764 (sh_elf_relocate_section, sh_elf_check_relocs): Handle new
5766 (elf_backend_create_dynamic_sections,
5767 bfd_elf32_bfd_link_hash_table_create,
5768 elf_backend_adjust_dynamic_symbol,
5769 elf_backend_size_dynamic_sections,
5770 elf_backend_finish_dynamic_symbol,
5771 elf_backend_finish_dynamic_sections, elf_backend_want_got_plt,
5772 elf_backend_plt_readonly, elf_backend_want_plt_sym,
5773 elf_backend_got_header_size, elf_backend_plt_header_size):
5775 * reloc.c (BFD_RELOC_SH_COPY, BFD_RELOC_SH_GLOB_DAT,
5776 BFD_RELOC_SH_JMP_SLOT, BFD_RELOC_SH_RELATIVE, BFD_RELOC_SH_GOTPC):
5778 * bfd-in2.h, libbfd.h: Rebuilt.
5780 2000-09-01 Alan Modra <alan@linuxcare.com.au>
5782 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Revert 2000-08-27
5785 2000-08-31 J"orn Rennecke <amylaar@cygnus.co.uk>
5787 * elf32-sh.c (sh_elf_merge_private_data): If ibfd's elf header flags
5788 not initialized, set them to indicate the SH1 instruction set.
5790 2000-08-31 Alexandre Oliva <aoliva@redhat.com>
5792 * acinclude.m4: Include libtool and gettext macros from the
5794 * aclocal.m4, configure: Rebuilt.
5796 2000-08-29 Michael Snyder <msnyder@seadog.cygnus.com>
5798 * elf.c: Eliminate references to __sparcv9 macro; replace with
5799 autoconf variables HAVE_PSINFO32_T etc.
5800 * configure.in: Auto-configure HAVE_PSINFO_32_T, HAVE_PRPSINFO32_T,
5801 HAVE_PSTATUS32_T, HAVE_PRSTATUS32_T, HAVE_PRSTATUS32_T_PR_WHO.
5803 * acinclude.m4 (BFD_HAVE_SYS_PROCFS_TYPE) define _SYSCALL32 so it can
5804 detect the above typedefs. (BFD_HAVE_SYS_PROCFS_TYPE_MEMBER): Ditto.
5805 * aclocal.m4: Ditto.
5806 * configure: Regenerate.
5808 2000-08-27 Alan Modra <alan@linuxcare.com.au>
5810 * elf32-i386.c (elf_i386_check_relocs): Keep info on relocs copied
5811 for any shared link, not just shared -Bsymbolic.
5812 (elf_i386_size_dynamic_sections): Call elf_i386_discard_copies on
5813 any shared link, and pass link info to it.
5814 (elf_i386_size_dynamic_sections): Update comment.
5815 (elf_i386_discard_copies): Modify to discard relocs for symbols
5816 that have been forced local.
5817 (elf_i386_finish_dynamic_symbol): Don't copy relocs for symbols
5818 that have been forced local.
5820 2000-08-24 Denis Chertykov <denisc@overta.ru> & Nick Clifton <nickc@redhat.com>
5822 * elflink.h (elf_link_add_object_symbols): Allow common
5823 symbols to have an alignment of 1 if explicitly requested, and
5824 not overridden by other definitions.
5826 2000-08-22 Doug Kwan <dkwan@transmeta.com>
5828 * coff-w65.c (CREATE_LITTLE_COFF_TARGET): Fix typo.
5829 * coffcode.h (coff_set_flags): Add detection of w65 architecture.
5831 2000-08-22 H.J. Lu <hjl@gnu.org>
5833 * elf-bfd.h (elf_link_hash_table): Add runpath.
5835 * bfd-in.h (bfd_elf_get_runpath_list): New prototype.
5836 * bfd-in2.h: Rebuilt.
5838 * elf.c (_bfd_elf_link_hash_table_init): Initialize the
5839 "runpath" field to NULL.
5840 (bfd_elf_get_runpath_list): New function.
5842 * elflink.h (elf_link_add_object_symbols): Record DT_RPATH and
5845 2000-08-22 Alexandre Oliva <aoliva@redhat.com>
5847 * elf32-sh.c (sh_elf_relocate_section) [R_SH_IND12W,
5848 R_SH_DIR8WPN, R_SH_DIR8WPZ, R_SH_DIR8WPL]: Handle them
5849 explicitly. Improve validation of r_type.
5851 2000-08-21 H.J. Lu <hjl@gnu.org>
5853 * elf32-i386.c (elf_i386_size_dynamic_sections): Zero out the
5854 dynamic allocated content space. Add a comment to remind us that
5855 one day this ought to be fixed.
5856 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
5857 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
5858 * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
5860 2000-08-21 Jason Eckhardt <jle@cygnus.com>
5862 * elf32-i860.c (elf32_i860_relocate_pc16): Just write the immediate
5863 field with the newly relocated value instead of adding it to the
5864 existing immediate field.
5865 (elf32_i860_relocate_splitn): Likewise.
5866 (elf32_i860_relocate_highadj): Likewise.
5868 2000-08-16 Jason Eckhardt <jle@cygnus.com>
5870 * elf32-i860.c (elf32_i860_relocate_pc16): Implemented function (it
5871 was previously just a stub).
5873 2000-08-16 Alexandre Oliva <aoliva@redhat.com>
5875 * elflink.c (_bfd_elf_create_got_section): Don't abort().
5877 (_bfd_elf_create_dynamic_sections): Likewise.
5879 2000-08-16 Andrew Macleod <amacleod@cygnus.com>
5881 * elf64-sparc.c (sparc64_elf_relocate_section): Set relocation address
5882 for undefined symbols to be the beginning of the section.
5884 * elf64-sparc.c (sparc64_elf_adjust_dynamic_symbol): Don't allocate
5885 four extra entries at the beginning of the .rela.plt section.
5886 (sparc64_elf_finish_dynamic_symbol): Adjust the offset in the .rela.plt
5887 section to account for the four reserved entries in the .plt section.
5889 2000-08-15 Geoffrey Keating <geoffk@cygnus.com>
5891 * xcofflink.c (_bfd_ppc_xcoff_relocate_section): Add ori r0,r0,0
5892 to the list of NOPs we recognize after a branch-and-link.
5893 Use the ori NOP when one is needed.
5895 * coff-rs6000.c (_bfd_xcoff_slurp_armap): Finish implementation
5898 2000-08-14 Jim Wilson <wilson@cygnus.com>
5900 * elf64-ia64.c (elf64_ia64_merge_private_bfd_data): Handle
5901 EF_IA_64_REDUCEDFP, EF_IA_64_CONS_GP, and EF_IA_64_NOFUNCDESC_CONS_GP.
5902 (elf64_ia64_print_private_bfd_data): Likewise. Also handle
5905 2000-08-11 Alexandre Oliva <aoliva@redhat.com>
5907 * elf32-sh.c (sh_elf_set_mach_from_flags): Make it static.
5909 2000-08-10 Jason Eckhardt <jle@cygnus.com>
5911 * elf32-i860.c (elf32_i860_relocate_section): New function.
5912 (i860_final_link_relocate): New function.
5913 (elf32_i860_relocate_splitn): New function.
5914 (elf32_i860_relocate_pc16): New function.
5915 (elf32_i860_relocate_highadj): New function.
5916 (elf32_i860_howto): Minor adjustments to some relocations.
5917 (elf_info_to_howto_rel): Define.
5918 (elf_backend_relocate_section): Define.
5920 2000-08-10 Nick Clifton <nickc@cygnus.com>
5922 * elf32-arm.h: Fix formatting.
5924 2000-08-10 Bernd Schmidt <bernds@cygnus.co.uk>
5926 * elf32-sh.c (sh_elf_reloc_loop): Make LAST_SYMBOL_SECTION static.
5928 2000-08-08 Jason Eckhardt <jle@cygnus.com>
5930 * elf32-i860.c (elf32_i860_howto_table): Updated some fields.
5932 2000-08-07 Kazu Hirata <kazu@hxi.com>
5934 * ieee.c (ieee_write_debug_part): Rewrite a comment.
5935 * elf64-ia64.c: Fix a typo.
5937 2000-08-05 Jason Eckhardt <jle@cygnus.com>
5939 * elf32-i860.c (elf32_i860_howto_table): New structure.
5940 (lookup_howto): New function.
5941 (elf32_i860_reloc_type_lookup): New function.
5942 (elf32_i860_info_to_howto_rela): New function.
5943 (elf_code_to_howto_index): New structure.
5944 (elf_info_to_howto): Re-define as elf32_i860_info_to_howto_rela.
5945 (bfd_elf32_bfd_reloc_type_lookup): Re-define as
5946 elf32_i860_reloc_type_lookup.
5948 2000-08-04 Rodney Brown <RodneyBrown@pmsc.com>
5950 * som.c (struct fixup_format): Constify `format'.
5951 (som_hppa_howto_table): Use SOM_HOWTO macro.
5952 (try_prev_fixup, hppa_som_reloc): Decorate unused parameter.
5953 (som_bfd_reloc_type_lookup): Likewise.
5954 (compare_subspaces): Remove unused `count1', `count2'.
5955 (som_begin_writing): Remove unused `total_reloc_size'.
5956 (som_bfd_derive_misc_symbol_info): Decorate unused parameter.
5957 (som_print_symbol, som_bfd_is_local_label_name): Likewise.
5958 (som_set_reloc_info): Constify `cp'. Remove unused `addend'.
5959 (som_find_nearest_line): Decorate unused parameter(s).
5960 (som_sizeof_headers, som_get_symbol_info, som_write_armap): Likewise.
5961 (som_bfd_link_split_section): Likewise.
5963 2000-08-03 Nick Clifton <nickc@cygnus.com>
5965 * section.c: Restore backed out code.
5966 * elf.c: Restore backed out code.
5967 (copy_private_bfd_data): Fix bug preventing stipped dynamic
5968 binaries from working.
5969 * bfd-in2.h: Regenerate.
5971 2000-08-03 H.J. Lu <hjl@gnu.org>
5973 * section.c: Back out the change made by Nick Clifton
5974 <nickc@cygnus.com> on 2000-07-31. It breaks stripping dynamic
5976 * bfd-in2.h: Likewise.
5979 2000-08-03 Alexandre Oliva <aoliva@redhat.com>
5981 * elf32-sh.c (sh_elf_reloc_loop): Warning removal.
5983 2000-07-31 Jason Eckhardt <jle@cygnus.com>
5985 * reloc.c (BFD_RELOC_860_*): New bfd relocs for i860.
5986 * bfd-in2.h, libbfd.h: Regenerate.
5988 2000-07-31 Nick Clifton <nickc@cygnus.com>
5990 * section.c (struct sec): Add new boolean field 'segment_mark'.
5991 (STD_SECTION): Initialise new field to zero.
5993 * bfd-in2.h: Regenerate.
5995 * elf.c (copy_private_bfd_data): Reorganise section to segment
5996 mapping to cope with moved sections requiring new segments,
5997 and overlapping segments.
5998 (SEGMENT_END): New macro: Return the end address of a segment.
5999 (IS_CONTAINED_BY_VMA): New macro: Determine if a segment
6000 contains a section by comparing their VMA addresses.
6001 (IS_CONTAINED_BY_LMA): New macro: Determine if a segment
6002 contains a section by comparing their LMA addresses.
6003 (INCLUDE_SECTION_IN_SEGMENT): New macro: Determine if a
6004 section should be included in a segment.
6005 (SEGMENT_AFTER_SEGMENT): New macro: Determine if one segment
6006 follows another in memory.
6007 (SEGMENT_OVERLAPS_SEGMENT): New macro: Determine if two
6010 2000-07-22 Jason Eckhardt <jle@cygnus.com>
6012 * cpu-i860.c: Added comments.
6014 * elf32-i860.c (TARGET_LITTLE_SYM): Defined to
6015 bfd_elf32_i860_little_vec.
6016 (TARGET_LITTLE_NAME): Defined to "elf32-i860-little".
6017 (ELF_MAXPAGESIZE): Changed to 4096.
6019 * targets.c (bfd_elf32_i860_little_vec): Declaration of
6021 (bfd_target_vector): Added bfd_elf32_i860_little_vec.
6023 * config.bfd (i860-stardent-sysv4*, i860-stardent-elf*): Added
6024 config for little endian elf32 i860.
6025 (targ_defvec): Define for the new config above
6026 as "bfd_elf32_i860_little_vec".
6027 (targ_selvecs): Define for the new config above
6028 as "bfd_elf32_i860_vec bfd_elf32_i860_little_vec"
6030 * configure.in (bfd_elf32_i860_little_vec): Added recognition
6033 * configure: Regenerated.
6035 2000-07-27 H.J. Lu <hjl@gnu.org>
6037 * elflink.h (elf_merge_symbol): Take one more argument,
6038 dt_needed, to indicate if the symbol comes from a DT_NEEDED
6039 entry. Don't overide the existing weak definition if dt_needed
6041 (elf_link_add_object_symbols): Pass dt_needed to
6042 elf_merge_symbol ().
6044 2000-07-27 Nick Clifton <nickc@cygnus.com>
6046 * elflink.h (elf_link_size_reloc_section): Zeroes the section's
6049 2000-07-25 Geoffrey Keating <geoffk@cygnus.com>
6051 * configure.host (*-*-aix*): AIX has 'long long' always.
6053 * coff-rs6000.c (xcoff_write_one_armap_big): New procedure.
6054 (xcoff_write_armap_big): Write both 32-bit and 64-bit armaps.
6055 (xcoff_write_archive_contents_big): Don't update the offset
6056 of the symbol table, xcoff_write_armap will do it.
6058 2000-07-23 Ulf Carlsson <ulfc@engr.sgi.com>
6060 * elf32-mips.c (_bfd_mips_elf_check_relocs): Use abfd instead
6061 of dynobj for SGI_COMPAT checks.
6063 2000-07-21 Michael Sokolov <msokolov@ivan.Harhan.ORG>
6065 * coff-m68k.c (bfd_m68k_coff_create_embedded_relocs): New function.
6066 * bfd-in.h (bfd_m68k_coff_create_embedded_relocs): Add declaration.
6067 * bfd-in2.h: Regenerate.
6069 2000-07-21 Nick Clifton <nickc@cygnus.com>
6071 * elf32-mips.c (_bfd_mips_elf_check_relocs): Detect out of
6072 range symbol indices in relocs and issue an error message.
6074 2000-07-20 H.J. Lu <hjl@gnu.org>
6076 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Don't check
6077 info->new_dtags when setting DT_FLAGS_1. It will only be set
6078 by the new linker options. It shouldn't break anything.
6080 2000-07-20 H.J. Lu <hjl@gnu.org>
6082 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set DT_FLAGS_1
6083 only if info->new_dtags is true.
6085 2000-07-20 H.J. Lu <hjl@gnu.org>
6087 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set
6088 DT_RUNPATH and DT_FLAGS only if info->new_dtags is true.
6090 2000-07-20 Hans-Peter Nilsson <hp@axis.com>
6092 * Makefile.am (ALL_MACHINES): Add cpu-cris.lo.
6093 (ALL_MACHINES_CFILES): Add cpu-cris.c.
6094 (BFD32_BACKENDS): Add aout-cris.lo and elf32-cris.lo.
6095 (BFD32_BACKENDS_CFILES): Add aout-cris.c and elf32-cris.c.
6096 (cpu-cris.lo, aout-cris.lo, elf32-cris.lo): New rules.
6097 * Makefile.in: Rebuild.
6098 * aclocal.m4: Rebuild.
6099 * aoutx.h (NAME(aout,machine_type)): Add case for bfd_arch_cris.
6100 * archures.c (enum bfd_architecture): Add bfd_arch_cris.
6101 (bfd_cris_arch): Declare.
6102 (bfd_archures_list): Add bfd_cris_arch.
6103 * bfd-in2.h: Rebuild.
6104 * config.bfd: (cris-*-*): New target.
6105 * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vectors.
6106 * configure: Rebuild.
6107 * elf.c (prep_headers): Add bfd_arch_cris.
6108 * libbfd.h: Rebuild.
6109 * libaout.h (enum machine_type): Add M_CRIS.
6110 * reloc.c: Add CRIS relocations.
6111 * targets.c (bfd_elf32_cris_vec, cris_aout_vec): Declare.
6112 (bfd_target_vect): Add bfd_elf32_cris_vec and cris_aout_vec.
6113 * cpu-cris.c, aout-cris.c, elf32-cris.c: New files.
6114 * po/POTFILES.in, po/bfd.pot: Regenerate.
6116 2000-07-19 H.J. Lu <hjl@gnu.org>
6118 * elf32-arm.h (elf32_arm_size_dynamic_sections): Also set
6119 DF_TEXTREL if DT_TEXTREL is set.
6120 * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise.
6121 * elf32-i386.c (elf_i386_size_dynamic_sections): Likewise.
6122 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
6123 * elf32-mips.c (_bfd_mips_elf_size_dynamic_sections): Likewise.
6124 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise.
6125 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
6126 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Likewise.
6127 * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
6128 * elf64-ia64.c (elf64_ia64_size_dynamic_sections): Likewise.
6129 * elf64-sparc.c (sparc64_elf_size_dynamic_sections): Likewise.
6131 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Also
6132 set DF_SYMBOLIC for symbolic link. Also set DT_RUNPATH if
6134 Set the DT_FLAGS and DT_FLAGS_1 entries if necessary.
6136 2000-07-19 H.J. Lu <hjl@gnu.org>
6138 * bfd-in.h (bfd_elf_set_dt_needed_soname): New.
6139 * bfd-in2.h: Rebuild.
6141 * elf-bfd.h (elf_obj_tdata): Add dt_soname.
6142 (elf_dt_soname): New.
6144 * elf.c (bfd_elf_set_dt_needed_soname): New.
6146 * elflink.h (elf_link_add_object_symbols): Add the DT_NEEDED
6147 entry if the shared object loaded by DT_NEEDED is used to
6148 resolve the reference in a regular object.
6150 2000-07-19 H.J. Lu <hjl@gnu.org>
6152 * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_CONFIG,
6153 DT_DEPAUDIT and DT_AUDIT as strings.
6155 2000-07-19 Nick Clifton <nickc@cygnus.com>
6157 * format.c: Fix formatting.
6159 2000-07-19 H.J. Lu <hjl@gnu.org>
6161 * elf.c (_bfd_elf_print_private_bfd_data): Fix DT_CHECKSUM.
6163 2000-07-19 H.J. Lu <hjl@gnu.org>
6165 * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_BIND_NOW,
6166 DT_INIT_ARRAY, DT_FINI_ARRAY, DT_INIT_ARRAYSZ, DT_FINI_ARRAYSZ,
6167 DT_RUNPATH, DT_FLAGS, DT_PREINIT_ARRAY, DT_PREINIT_ARRAYSZ,
6168 DT_PLTPADSZ, DT_MOVEENT, DT_MOVESZ, DT_FEATURE, DT_POSFLAG_1,
6169 DT_SYMINSZ, DT_SYMINENT, DT_CONFIG, DT_DEPAUDIT, DT_AUDIT,
6170 DT_PLTPAD, DT_MOVETAB, DT_SYMINFO, DT_RELACOUNT, DT_RELCOUNT,
6171 DT_FLAGS_1, DT_USED and DT_CHECKSUM.
6173 2000-07-18 Andrew Cagney <cagney@b1.cygnus.com>
6175 * elf.c (bfd_elf_get_sign_extend_vma, bfd_elf_get_arch_size): Move
6176 renamed functions from here...
6177 (assign_section_numbers): Use renamed functions.
6178 (prep_headers): Use renamed functions.
6180 * bfd.c (bfd_get_sign_extend_vma, bfd_get_arch_size): ...To here.
6181 * bfd-in.h (bfd_get_sign_extend_vma, bfd_get_arch_size): Update.
6182 * bfd-in2.h: Regenerate.
6184 2000-07-18 Ulf Carlsson <ulfc@engr.sgi.com>
6186 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Add
6187 parenthesis in if statement.
6189 2000-07-17 Koundinya K <kk@ddeorg.soft.net>
6191 Enable the support for Traditional MIPS.
6192 * elf32-mips.c (IRIX_COMPAT): Recognize bfd_elf32_tradbigmips_vecand
6193 return ict_none appropriately for traditional mips targets.
6194 (STUB_LW): Change 0x8f998000 to 0x8f998010 for traditional mips.
6195 (STUB_MOVE): Conditionalize for traditonal mips.
6196 (STUB_LI16): Likewise.
6197 (_bfd_mips_elf_modify_segment_map): Conditionalize to avoid making
6198 room for RTPROC header.
6199 (_bfd_mips_elf_modify_segment_map): For a normal mips executable set
6200 the permission for the PT_DYNAMIC as read, write and execute.
6201 (mips_elf_calculate_relocation): Check for the symbol _DYNAMIC_LINKING
6202 for traditonal mips.
6203 (_bfd_mips_elf_create_dynamic_sections): Add the symbol
6204 _DYNAMIC_LINKING for traditonal mips.
6205 (_bfd_mips_elf_create_dynamic_sections): Add the symbol __RLD_MAP
6206 in case of traditonal mips.
6207 (_bfd_mips_elf_adjust_dynamic_symbol): Create a stub only if a PLT
6208 entry is required. For a function if PLT is not required then set the
6209 corresponding hash table entry to 0.
6210 (_bfd_mips_elf_size_dynamic_sections): Add DT_DEBUG entry for
6212 (_bfd_mips_elf_finish_dynamic_symbol): for a undefined symbol in a
6213 shared object set the value to 0.
6214 (_bfd_mips_elf_finish_dynamic_symbol): Check for the symbol
6215 _DYNAMIC_LINKING for traditonal mips.
6216 (_bfd_mips_elf_finish_dynamic_symbol): Check for the symbol __RLD_MAP
6217 for traditonal mips.
6219 2000-07-15 H.J. Lu <hjl@gnu.org>
6221 * aoutx.h (translate_to_native_sym_flags): Handle BSF_LOCAL.
6223 2000-07-12 Charles Wilson <cwilson@ece.gatech.edu>
6225 * libbfd.c (bfd_seek): fix 'seek beyond EOF' error when writing
6226 out a structure that is BFD_IN_MEMORY.
6228 2000-07-11 Alan Modra <alan@linuxcare.com.au>
6230 * elf64-hppa.c (get_dyn_name): Pass in section pointer instead of
6231 bfd pointer. Print section id instead of bfd pointer for local
6232 syms. Prefix addend with `+' for global syms as well as local.
6233 Correct calculation of name component lengths.
6234 (elf64_hppa_check_relocs): Update call to get_dyn_name.
6236 From David Huggins-Daines <dhd@linuxcare.com>
6237 * elf-hppa.h (elf_hppa_relocate_section): Update calls here too.
6238 * elf64-hppa.c (elf64_hppa_check_relocs): Fix some warnings.
6239 (elf64_hppa_modify_segment_map): Likewise.
6241 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
6243 * elf.c (bfd_elf_get_sign_extend_vma): Return tendency of VMA
6244 addresses to be "naturally" sign extended. Return -1 if unknown.
6245 * bfd-in.h (bfd_elf_get_sign_extend_vma): Add declaration.
6246 * bfd-in2.h: Regenerate.
6248 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
6250 * ecoffswap.h (ecoff_get_off, ecoff_put_off): Add ECOFF_SIGNED_32
6251 and ECOF_SIGNED_64 to list ways to extract an offset.
6252 (ecoff_swap_fdr_in, ecoff_swap_fdr_out, ecoff_swap_pdr_in,
6253 ecoff_swap_pdr_out, ecoff_swap_ext_in, ecoff_swap_ext_out):
6255 * elf64-mips.c (ECOFF_SIGNED_64): Define instead of ECOFF_64.
6256 * elf32-mips.c (ECOFF_SIGNED_32): Define instead of ECOFF_32.
6258 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
6260 * elfcode.h (elf_object_p): Use bfd_set_start_address and not
6261 bfd_get_start_address.
6262 (elf_swap_ehdr_in): Sign extend e_entry when applicable.
6263 (elf_swap_ehdr_out): Ditto.
6265 2000-07-10 Alexander Aganichev <AAganichev@hypercom.com>
6267 * archures.c (bfd_default_scan): Add set of bfd_mach_ cases for
6268 compatibility with older binutils.
6270 2000-07-10 Alan Modra <alan@linuxcare.com.au>
6272 * section.c (bfd_make_section_anyway): Start section_id at 0x10.
6273 (STD_SECTION): Avoid negative ids, instead use 0 to 3.
6275 From Ryan Bradetich <rbradetich@uswest.net>
6276 * dwarf1.c (parse_die): Cure signed/unsigned char warnings.
6277 (parse_line_table): Ditto.
6278 (_bfd_dwarf1_find_nearest_line): Ditto.
6279 * syms.c (cmpindexentry): Remove extra `*' from params.
6281 2000-07-09 Koundinya K <kk@ddeorg.soft.net>
6283 * elf32-mips.c (sort_dynamic_relocs): New Function.
6284 (_bfd_mips_elf_finish_dynamic_sections): Call sort_dynamic_relocs
6285 via qsort to sort the dynamic relocations in increasing r_symndx
6288 2000-07-09 Alan Modra <alan@linuxcare.com.au>
6290 * elf64-hppa.c (elf64_hppa_dyn_hash_table_init): Add
6291 ATTRIBUTE_UNUSED to unused args.
6292 (get_opd): Likewise.
6293 (get_plt): Likewise.
6294 (get_dlt): Likewise.
6295 (get_stub): Likewise.
6296 (elf64_hppa_adjust_dynamic_symbol): Likewise.
6297 (elf64_hppa_link_output_symbol_hook): Likewise.
6298 (elf64_hppa_check_relocs): Delete unused var.
6299 (elf64_hppa_size_dynamic_sections): Likewise.
6300 (elf64_hppa_finalize_opd): Likewise.
6301 (elf64_hppa_finalize_dynreloc): Likewise.
6302 (elf64_hppa_modify_segment_map): Likewise.
6303 (elf64_hppa_finish_dynamic_sections): Likewise.
6305 * elf-hppa.h (elf_hppa_final_write_processing): Add
6306 ATTRIBUTE_UNUSED to unused args.
6307 (elf_hppa_final_link_relocate): Likewise.
6308 (elf_hppa_record_segment_addrs): Add paretheses.
6309 (elf_hppa_relocate_section): Constify dyn_name.
6311 From David Huggins-Daines <dhd@linuxcare.com>
6312 * config.bfd: Add hppa*64*-*-linux-gnu 64-bit target, and
6313 rearrange case statement so that it gets preferred to 32-bit ones.
6315 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Use
6316 asection->id instead of address of asection structure.
6317 (elf32_hppa_size_stubs): Likewise.
6319 * elf32-hppa.c (elf32_hppa_size_stubs): Use just one stub section
6320 for .init* and .fini*.
6322 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Mask pointers
6323 and addends used in stub names to 32 bits.
6324 (elf32_hppa_size_stubs): Likewise.
6326 * elf-hppa.h (elf_hppa_final_link_relocate): Don't sum addend
6327 twice for R_PARISC_GPREL64. Use bfd_put_32 for R_PARISC_PCREL32,
6328 not bfd_put_64. Fix minor comment typo and formatting.
6330 Changes to create multiple linker stubs, positioned immediately
6331 before the section where they are required.
6332 * elf32-hppa.c: Don't include hppa_stubs.h.
6333 (elf32_hppa_stub_hash_entry): Add a pointer to the stub section.
6334 (elf32_hppa_stub_hash_table): Delete.
6335 (elf32_hppa_link_hash_entry): Delete.
6336 (elf32_hppa_link_hash_table): Use plain bfd_hash_table for
6337 stub_hash_table, and store the struct here rather than a pointer.
6338 Delete output_symbol_count. Add offset array. Change
6339 global_value to a bfd_vma.
6340 (elf32_hppa_stub_hash_lookup): Use table instead of table->root.
6341 (elf32_hppa_stub_hash_traverse): Delete.
6342 (elf32_hppa_name_of_stub): Delete.
6343 (elf32_hppa_link_hash_lookup): Delete.
6344 (elf32_hppa_link_hash_traverse): Delete.
6345 (elf32_hppa_stub_hash_table_init): Delete.
6346 (elf32_hppa_size_of_stub): Pass input section and offset rather
6347 than location and calculate location here. Don't pass name as all
6348 stubs are now the same size.
6349 (elf32_hppa_stub_hash_newfunc): Init new fields.
6350 (elf32_hppa_link_hash_table_create): Likewise, and stub_hash_table
6352 (elf32_hppa_bfd_final_link_relocate): Cast enums to int before
6353 comparing against ints. Rewrite stub handling code.
6354 (elf32_hppa_relocate_section): Make r_type and r_symndx unsigned.
6355 Case enums to int before comparing against ints. Remove
6356 bfd_reloc_dangerous case.
6357 (elf32_hppa_build_one_stub): Rewrite.
6358 (elf32_hppa_size_one_stub): New function.
6359 (elf32_hppa_build_stubs): Rewrite.
6360 (elf32_hppa_size_stubs): Pass in linker call-back functions.
6361 Rewrite stub-handling specific code.
6363 * elf32-hppa.h (elf32_hppa_size_stubs): Update prototype.
6365 * elf64-hppa.c (elf64_hppa_dyn_hash_entry): Fix a comment typo.
6367 * hppa_stubs.h: Delete.
6368 * Makefile.am (SOURCE_HFILES): Remove hppa_stubs.h
6369 (elf32-hppa.lo): Remove hppa_stubs.h from dependencies.
6370 * Makefile.in: Regenerate.
6372 * elf-hppa.h (_bfd_elf_hppa_gen_reloc_type): Handle e_nlsel and
6375 * libhppa.h (hppa_field_adjust): Correct e_nsel case.
6377 * elf32-hppa.c (elf32_hppa_relocate_section): Mention the offset
6378 and section name for bfd_reloc_notsupported error message.
6379 (elf32_hppa_bfd_final_link_relocate): Print reasons for returning
6380 bfd_reloc_notsupported.
6381 (elf32_hppa_relocate_section): Add ATTRIBUTE_UNUSED to output_bfd.
6383 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Handle
6384 undefined weak symbols for all relocs.
6385 (elf32_hppa_size_of_stub): Adjust calculation by 8 since branch
6386 offsets are relative to one past the delay slot.
6387 (elf32_hppa_size_stubs): Account for reloc addend when calculating
6388 branch destination. Put addend into stub name too.
6389 (elf32_hppa_bfd_final_link_relocate): Account for reloc addend and
6390 adjust by 8 when deciding whether a linker stub is needed. Put
6391 addend into stub name as for above.
6393 * elf32-hppa.c (hppa_elf_relocate_insn): Change signed/unsigned on
6394 various args and vars.
6395 (elf32_hppa_bfd_final_link_relocate): Here too.
6396 (elf32_hppa_size_stubs): Rename index -> indx. Use e_indx for
6397 inner block var to avoid shadowing.
6399 * elf32-hppa.h (_bfd_elf32_hppa_gen_reloc_type): Make `field' arg
6401 * elf64-hppa.h (_bfd_elf64_hppa_gen_reloc_type): Ditto.
6402 * elf-hppa.h (_bfd_elf_hppa_gen_reloc_type): Ditto.
6403 (elf_hppa_fake_sections): Rename local var to avoid shadowing.
6405 * libhppa.h: Change practically all unsigned ints to plain ints.
6406 Remove tests on gcc version. Instead use ATTRIBUTE_UNUSED for
6409 From Ryan Bradetich <rbradetich@uswest.net>
6410 * libhppa.h (hppa_opcode_type): New enum to replace #define's.
6411 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Modify to
6413 From David Huggins-Daines <dhd@linuxcare.com>
6414 * elf-hppa.h (elf_hppa_relocate_insn): Update the opcode constants
6415 to the new OP_* ones.
6417 * elf32-hppa.c (elf32_hppa_size_stubs): Consolidate freeing on
6418 error exit. Bail out earlier on plabel relocs that we aren't
6419 interested in. Don't tell elf32_hppa_stub_hash_lookup to copy
6420 string, and then don't free our copy.
6421 (elf32_hppa_build_one_stub): Make insn unsigned int.
6423 * libhppa.h (bfd_hppa_insn2fmt): 22 bit branches are only
6424 available with BL, not BE and BLE.
6426 * elf32-hppa.c (hppa_elf_relocate_insn): Add some more example
6427 code for elf arg relocs.
6428 (elf32_hppa_bfd_final_link_relocate): Replace boolean is_local
6429 argument with elf_link_hash_entry h. Handle undefined weak
6430 symbols. Move $global$ lookup from here...
6431 (elf32_hppa_relocate_section): ...to here. Return correct error
6432 message for non-handled relocs.
6433 (elf32_hppa_size_of_stub): Correctly test branch range. Previous
6434 wrong test was -0x3ffff to +0x40000.
6436 * elf-hppa.h (elf_hppa_final_link_relocate): R_PARISC_DIR17R,
6437 R_PARISC_DIR17F, and R_PARISC_DIR21L are for absolute branches;
6438 Handle them as such.
6439 (elf_hppa_relocate_insn): Fix a typo.
6441 * libhppa.h (GET_FIELD, GET_BIT, MASK, CATENATE, ELEVEN): Delete.
6442 (assemble_3, assemble_6, assemble_12, assemble_16, assemble_16a,
6443 assemble_17, assemble_21): Delete.
6444 Supply defines for all 64 possible opcodes.
6445 (bfd_hppa_insn2fmt): Add bfd argument, and use to select wide mode
6446 formats. Handle COMICLR.
6447 (hppa_rebuild_insn): Delete bfd argument. Handle formats 10, -11,
6450 * elf32-hppa.c (hppa_elf_relocate_insn): Complete rewrite.
6451 (elf32_hppa_bfd_final_link_relocate): Major rewrite.
6452 (elf32_hppa_build_one_stub): Modify hppa_elf_relocate_insn calls
6454 (elf32_hppa_size_stubs): Don't free stub_name twice. Read in all
6455 the local syms - did this code get deleted accidentally? Ignore
6456 undefined and undefweak syms.
6458 * elf-hppa.h (elf_hppa_final_link): Move hppa_info to outermost
6459 block. Use it instead of elf64_hppa_hash_table (info).
6460 (elf_hppa_final_link_relocate): Use hppa_info instead of
6461 elf64_hppa_hash_table (info).
6463 * libhppa.h (re_assemble_3, re_assemble_12, re_assemble_16,
6464 re_assemble_17, re_assemble_21, re_assemble_22): Don't mask insn.
6465 (hppa_rebuild_insn): Mask immediate bits here instead.
6466 * elf-hppa.h (elf_hppa_relocate_insn): Mask here too.
6468 2000-07-08 Alan Modra <alan@linuxcare.com.au>
6470 * section.c (struct sec): Add id field. Tidy comment formatting.
6471 (bfd_make_section_anyway): Set id.
6472 (STD_SECTION): Init id too.
6473 Change CONST to const throughout.
6474 * archures.c (bfd_arch_info): Tidy comment.
6475 (bfd_arch_list): Change a CONST to const.
6476 * libbfd-in.h: Tidy comments and replace CONST with const.
6477 * elf-bfd.h: Likewise.
6478 * libbfd.h: Regenerate.
6479 * bfd-in2.h: Regenerate.
6480 * libcoff.h: Regenerate.
6482 2000-07-07 DJ Delorie <dj@redhat.com>
6484 * archive.c (_bfd_write_archive_contents): Add an informative
6487 2000-07-06 Kazu Hirata <kazu@hxi.com>
6489 * srec.c: Fix formatting.
6491 2000-06-05 DJ Delorie <dj@redhat.com>
6495 2000-07-04 Alexandre Oliva <aoliva@redhat.com>
6497 * coff-arm.c (coff_arm_relocate_section): Do not ignore the symbol
6498 value of PC-relative offsets.
6500 2000-07-03 Jim Wilson <wilson@cygnus.com>
6502 * elf64-alpha.c (alpha_elf_size_info): New.
6503 (elf_backend_size_info): Define to alpha_elf_size_info.
6504 * elfcode.h (elf_size_info): Change hash bucket size to 4.
6506 2000-07-03 Ulf Carlsson <ulfc@engr.sgi.com>
6508 * elf32-mips.c: Include elf32-target.h again for the traditional
6511 2000-07-03 Marek Michalkiewicz <marekm@linux.org.pl>
6513 * elf32-avr.c (bfd_elf32_bfd_reloc_type_lookup):
6514 Add ATTRIBUTE_UNUSED to unused arguments to avoid warnings.
6515 (avr_info_to_howto_rela): Likewise.
6516 (elf32_avr_gc_mark_hook): Likewise.
6517 (elf32_avr_gc_sweep_hook): Likewise.
6518 (elf32_avr_relocate_section): Likewise.
6520 2000-07-03 Mark Elbrecht <snowball3@bigfoot.com>
6522 * cofflink.c (_bfd_coff_write_global_sym): Turn a weak symbol into
6523 an external symbol for a non-shared, non-relocatable link.
6525 2000-07-03 Nick Clifton <nickc@redhat.com>
6527 * cofflink.c (IS_EXTERNAL): New macro: Return true if the symbol
6528 is an external symbol.
6529 (IS_WEAK_EXTERNAL): New macro: Return true if the symbol is a weak
6532 2000-07-03 Kazu Hirata <kazu@hxi.com>
6534 * reloc16.c: Fix formatting.
6536 2000-07-01 Koundinya K <kk@ddeorg.soft.net>
6538 * config.bfd: Change targ_defvec and targ_selvecs for mips*-*-sysv4*
6539 to add a new target for traditional mips i.e
6540 bfd_elf32_tradbigmips_vec and bfd_elf32_tradlittlemips_vec.
6541 * configure.in: Likewise.
6542 * configure: Rebuild.
6543 * targets.c (bfd_elf32_tradbigmips_vec): Declare and put in
6545 (bfd_elf32_tradlittlemips_vec): Likewise.
6546 * elfxx-target.h: Add macro INCLUDED_TARGET_FILE which is more a test
6547 to see that elfNN_bed does not get redefined even if the target file
6548 is included twice for a chip. See elf32-mips.c.
6550 2000-07-01 Alan Modra <alan@linuxcare.com.au>
6552 * Makefile.am (DEP): Fix 2000-06-22. grep after running dep.sed
6553 (CLEANFILES): Add DEPA.
6554 * Makefile.in: Regenerate.
6556 2000-06-30 DJ Delorie <dj@cygnus.com>
6558 * peicode.h (coff_swap_filehdr_in): can't use e_magic because we
6559 can't assume the PE header is at 0x80.
6561 2000-06-29 Mark Elbrecht <snowball3@bigfoot.com>
6563 * syms.c (_bfd_stab_section_find_nearest_line): Use IS_ABSOLUTE_PATH.
6565 2000-06-28 Mark Elbrecht <snowball3@bigfoot.com>
6567 * go32stub.h: Update stub.
6569 2000-06-26 Marek Michalkiewicz <marekm@linux.org.pl>
6571 * archures.c (bfd_mach_avr5): Define.
6572 * bfd-in2.h (bfd_mach_avr5): Define.
6573 * cpu-avr.c (arch_info_struct): Rename bfd_mach_avr4 to
6574 bfd_mach_avr5, add bfd_mach_avr4. Update comments.
6575 (compatible): Update comment. Add missing test.
6576 * elf32-avr.c (avr_final_link_relocate): Support 8K wrap
6577 for avr2 and avr4. Simplify 8K wrap code.
6578 (bfd_elf_avr_final_write_processing): Recognize bfd_mach_avr5.
6579 (elf32_avr_object_p): Recognize E_AVR_MACH_AVR5.
6581 2000-06-26 Kazu Hirata <kazu@hxi.com>
6583 * coff-h8300.c: Fix formatting.
6584 * cpu-h8300.c: Likewise.
6586 2000-06-24 Alexandre Oliva <aoliva@redhat.com>
6588 * elf32-arm.h (elf32_arm_final_link_relocate): Print `(local)'
6589 for local symbols whose names are unknown.
6591 2000-06-22 Alan Modra <alan@linuxcare.com.au>
6593 * Makefile.am (DEP): grep for leading `/' in DEP1, and fail if we
6595 * Makefile.in: Regenerate.
6596 * doc/Makefile.in: Regenerate.
6598 2000-06-20 H.J. Lu <hjl@gnu.org>
6600 * Makefile.am: Rebuild dependency.
6601 * Makefile.in: Rebuild.
6603 2000-06-20 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
6605 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): New function.
6606 (elf_backend_copy_indirect_symbol): Map to the new function.
6608 2000-06-20 Alan Modra <alan@linuxcare.com.au>
6610 * archive.c (normalize): Correct pointer comparison when checking
6612 (bfd_bsd_truncate_arname): Likewise.
6613 (bfd_gnu_truncate_arname): Likewise.
6615 2000-06-20 Ulf Carlsson <ulfc@engr.sgi.com>
6617 * elf-bfd.h (struct elf_obj_tdata): Define per BFD Irix 5 virtual
6618 sections elf_{text,data}_{section,symbol}.
6619 * elf32-mips.c: mips_elf_{text,data}_{section,symbol}{,_ptr}: Remove.
6620 (_bfd_mips_elf_hide_symbol): New function.
6621 (elf_backend_hide_symbol): Map to the new function.
6622 (_bfd_mips_elf_add_symbol_hook): Change to use new per BFD
6623 definitions of mips_elf_{text,data}_{section,symbol}.
6624 (mips_elf_local_relocation_p): Try to find the direct symbol
6625 based on new check_forced argument.
6626 (mips_elf_calculate_relocation): Use new version of
6627 mips_elf_local_relocation_p.
6628 (mips_elf_relocate_section): Likewise.
6629 (_bfd_mips_elf_relocate_section): Likewise.
6630 (mips_elf_sort_hash_table): Only assert that have enough GOT
6632 (mips_elf_got16_entry): Match all 32 bits to the existing GOT
6633 entry if the relocation based on the new external argument.
6634 (mips_elf_create_dynamic_relocation): Assert that we have a
6635 section contents allocated where we can swap out the dynamic
6637 (mips_elf_calculate_relocation): Find the real hash-table entry
6638 correctly by using h->root.root.type. Only create a dynamic
6639 relocation entry if the symbol is defined in a shared library.
6640 Create an external GOT entry for the GOT16 relocation if the
6641 symbol was forced local.
6642 (_bfd_mips_elf_finish_dynamic_symbol): Don't assert there is a
6643 dynamic index if the symbol was forced local.
6645 2000-06-20 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
6647 * elf32-mips.c: Fix typos in comments.
6649 2000-06-19 Mark Kettenis <kettenis@gnu.org>
6651 * rs6000-core.c: Wrap definition of `union VmInfo' within #ifdef
6654 2000-06-18 Stephane Carrez <stcarrez@worldnet.fr>
6656 * Makefile.in, bfd-in2.h, libbfd.h, configure: Rebuild.
6657 * Makefile.am (ALL_MACHINES, ALL_MACHINES_CFILES, BFD32_BACKENDS,
6658 BFD32_BACKENDS_CFILES): Add 68hc12, 68hc11 files.
6659 * configure.in (bfd_elf32_m68hc12_vec): Recognize.
6660 (bfd_elf32_m68hc11_vec): Likewise.
6661 * config.bfd (targ_cpu): Recognize 68hc12 and 68hc11.
6662 Supports 68hc11 & 68hc12 at the same time.
6663 * targets.c (bfd_elf32_m68hc12_vec): Declare and put in
6665 (bfd_elf32_m68hc11_vec): Likewise.
6666 * elf.c (prep_headers): Recognize bfd_arch_m68hc12 and 68hc11.
6667 * archures.c (bfd_m68hc12_arch): Define and register in global list
6668 (bfd_m68hc11_arch): Likewise.
6669 * reloc.c (BFD_RELOC_M68HC11_HI8, BFD_RELOC_M68HC11_LO8,
6670 BFD_RELOC_M68HC11_3B): Define.
6671 * cpu-m68hc12.c, elf32-m68hc12.c: New files for 68hc12 support.
6672 * cpu-m68hc11.c, elf32-m68hc11.c: New files for 68hc11 support.
6674 2000-06-18 Ulf Carlsson <ulfc@engr.sgi.com>
6676 * elf_bfd.h (struct elf_backend_data): Add info argument to
6677 elf_backend_hide_symbol.
6678 (_bfd_elf_link_hash_hide_symbol): Likewise.
6679 * elf.c (_bfd_elf_link_hash_hide_symbol): Likewise.
6680 * elf64-ia64.c (elf64_ia64_hash_hide_symbol): Likewise.
6681 * elflink.h (elf_link_add_object_symbols): Likewise.
6682 (elf_link_assign_sym_version): Likewise.
6684 2000-06-18 H.J. Lu <hjl@gnu.org>
6686 * coff-i386.c (coff_i386_reloc): Don't return in case of
6687 output_bfd == (bfd *) NULL if COFF_WITH_PE is defined.
6688 Compensate PE relocations when linking with non-PE object
6689 files to generate a non-PE executable.
6691 2000-06-17 Ulf Carlsson <ulfc@engr.sgi.com>
6693 * elf32-mips.c (mips_elf_calculate_relocation): Explicitly write
6694 GOT entries if we're doing a static link or -Bsymbolic link.
6696 2000-06-15 Ulf Carlsson <ulfc@engr.sgi.com>
6698 * elflink.h (elf_link_adjust_relocs): Check for and call backend
6699 specifific swap_reloc_{in,out} and swap_reloca_{in,out} if
6701 (elf_link_output_relocs): Likewise.
6702 (elf_reloc_link_order): Likewise.
6704 2000-06-16 Nicholas Duffek <nsd@redhat.com>
6706 * archures.c (enum bfd_architecture): #define constants for
6707 PowerPc and RS6000 machine numbers.
6708 * bfd-in2.h: Regenerate.
6709 * coffcode.h (coff_set_arch_mach_hook): #ifdef XCOFF64, set arch
6710 to bfd_arch_powerpc instead of bfd_arch_rs6000. Refer to PowerPc
6711 and RS6000 machine numbers using #defined constants from
6713 * cpu-powerpc.c (arch_info_struct): Refer to PowerPc and RS6000
6714 machine numbers using #defined constants from archures.c. Add
6715 entries for EC603e, 630, A35, RS64II, RS64III, 7400. Specify
6716 64-bit words in 620 entry.
6717 * cpu-rs6000.c (arch_info_struct): Create with entries for RS1,
6719 (bfd_rs6000_arch): Change default machine to 0 (bfd_mach_rs6k).
6721 2000-06-16 Nicholas Duffek <nsd@cygnus.com>
6723 * coffcode.h (coff_mkobject_hook): Set xcoff_tdata.xcoff64.
6724 * libcoff-in.h (struct xcoff_tdata): Define xcoff64 field.
6725 * libcoff.h (struct xcoff_tdata): Define xcoff64 field.
6727 2000-06-16 Nicholas Duffek <nsd@redhat.com>
6729 * bfd-in.h (bfd_family_coff): Define.
6730 * bfd-in2.h: Regenerate.
6731 * coffgen.c (coff_count_linenumbers, coff_symbol_from,
6732 coff_find_nearest_line): Check COFFness using bfd_family_coff()
6733 instead of bfd_target_coff_flavour.
6734 * cofflink.c (_bfd_coff_final_link): Likewise.
6735 * cpu-ns32k.c (do_ns32k_reloc): Don't strcmp() target name to
6736 exclude XCOFF files.
6737 * reloc.c (bfd_perform_relocation, bfd_install_relocation):
6739 * targets.c (enum bfd_flavour): Add bfd_target_xcoff_flavour.
6740 * xcoff-target.h (TARGET_SYM): Use bfd_target_xcoff_flavour.
6741 * xcofflink.c (XCOFF_XVECP): Delete.
6742 (bfd_xcoff_link_record_set, bfd_xcoff_import_symbol,
6743 bfd_xcoff_export_symbol, bfd_xcoff_link_count_reloc,
6744 bfd_xcoff_record_link_assignment,
6745 bfd_xcoff_size_dynamic_sections): Replace XCOFF_XVECP() with
6746 check for bfd_target_xcoff_flavour.
6748 2000-06-16 Nicholas Duffek <nsd@redhat.com>
6750 * rs6000-core.c: Support 64-bit core files, support pre-4.3 core
6752 (read_hdr): New function.
6753 (rs6000coff_core_p): Store mstsave or __context64 struct instead
6754 of trying to extract individual registers. Set abfd->arch_info
6755 to match the architecture that created the core file.
6756 (rs6000coff_get_section_contents): Delete.
6757 * xcoff-target.h (rs6000coff_get_section_contents): Delete.
6759 2000-06-14 H.J. Lu <hjl@gnu.org>
6761 * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_rec)
6764 2000-06-13 H.J. Lu <hjl@gnu.org>
6766 * configure: Regenerate.
6768 2000-06-13 J"orn Rennecke <amylaar@cygnus.co.uk>
6770 * peicode.h (pe_ILF_object_p): Use TARGET_LITTLE_SYM instead of
6773 2000-06-08 David O'Brien <obrien@FreeBSD.org>
6775 * configure.in (VERSION): Update to show this is the CVS mainline.
6777 2000-06-07 Alan Modra <alan@linuxcare.com.au>
6779 * elf32-d10v.c: Include elf/d10v.h
6780 (enum reloc_type): Delete.
6781 * elf32-d30v.c: Include elf/d30v.h
6782 (enum reloc_type): Delete.
6784 * Makefile.am: Run "make dep-am" to regenerate dependencies.
6785 * Makefile.in: Regenerate.
6787 * elf32-i386.c (elf_howto_table): Remove EMPTY_HOWTOs.
6788 (elf32_i386_vtinherit_howto, elf32_i386_vtentry_howto): Delete and
6789 move HOWTOs into elf_howto_table.
6790 (R_386_standard, R_386_ext_offset): Define.
6791 (R_386_ext, R_386_vt_offset, R_386_vt): Define.
6792 (elf_i386_reloc_type_lookup): Modify calculation of index into
6793 elf_howto_table since we've removed the padding.
6794 (elf_i386_info_to_howto_rel): Likewise.
6795 (elf_i386_relocate_section): Likewise.
6797 2000-06-06 Michael Snyder <msnyder@seadog.cygnus.com>
6799 * elf.c (elf_grok_pr_status): Eliminate reference to prgregset_t.
6801 2000-06-05 H.J. Lu <hjl@gnu.org>
6803 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Don't flag
6804 an error when seeing an undefined symbol with hidden/internal
6805 attribute. It is handled in *_relocate_section ().
6807 2000-06-05 H.J. Lu <hjl@gnu.org>
6809 * elflink.h (elf_fix_symbol_flags): Follow the link for the
6810 indirect symbol for the ELF_LINK_NON_ELF bit.
6811 (elf_link_output_extsym): Don't output the indirect symbol even
6812 if the ELF_LINK_NON_ELF bit is set.
6814 2000-06-01 J.T. Conklin <jtc@redback.com>
6816 * config.bfd (i[3456]86-*-netbsdelf*): New target.
6817 (i[3456]86-*-netbsdaout*): New target.
6818 (i[3456]86-*-netbsd*): Add bfd_elf32_i386_vec to targ_selvecs.
6819 (i[3456]86-*-openbsd*): Likewise.
6821 2000-05-30 Andrew Cagney <cagney@b1.cygnus.com>
6823 * trad-core.c: From hpux-core.c, include <dirent.h> or
6824 <sys/ndir.h> when possible.
6826 2000-05-31 Ulrich Drepper <drepper@redhat.com>
6828 * elf.c (_bfd_elf_slurp_version_tables): Correct reading of version
6829 definitions. We must not assume they are sorted in the file
6830 according to their index numbers.
6832 2000-05-31 Alan Modra <alan@linuxcare.com.au>
6834 * elf-hppa.h: (elf_hppa_final_link_relocate): Use e_rsel field
6835 selector for R_PARISC_PCREL17R. R_PARISC_DIR17R and
6836 R_PARISC_DIR17F are for absolute branches; Handle them as such.
6838 2000-05-30 Nick Clifton <nickc@cygnus.com>
6840 * cpu-i960.c (scan_960_mach): Accept 80960KA, 80960KB,
6841 80960CA, 80960MC as valid machine names.
6843 2000-05-30 H.J. Lu <hjl@gnu.org>
6845 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Clear the
6846 visibility bits if the symbol is undefined. Correctly handle
6847 weak undefined symbols with hidden and internal attributes.
6849 * elflink.h (elf_link_add_object_symbols): Always turn the
6850 symbol into local if it has the hidden or internal attribute.
6852 2000-05-29 Philip Blundell <philb@gnu.org>
6854 * ppcboot.c: Add packed attribute if compiling with GCC.
6856 2000-05-29 Anatoly Vorobey <mellon@pobox.com>
6858 * elf.c (_bfd_elf_link_hash_table_init): Initialize dynlocal.
6860 2000-05-26 Michael Snyder <msnyder@seadog.cygnus.com>
6862 * elf.c (elfcore_grok_prstatus, elfcore_grok_pstatus,
6863 elfcore_grok_psinfo): Add code to allow debugging a 32-bit
6864 corefile on a 64-bit (Sparc Solaris) host. Also clean up
6867 2000-05-26 Alan Modra <alan@linuxcare.com.au>
6869 * Makefile.am: Update dependencies with "make dep-am"
6870 * Makefile.in: Regenerate.
6872 * sysdep.h (gettext, dgettext, dcgettext, textdomain,
6873 bindtextdomain): Replace defines with those from intl/libgettext.h
6874 to quieten gcc warnings.
6876 2000-05-26 Eli Zaretskii <eliz@is.elta.co.il>
6878 * aoutx.h (find_nearest_line): Use IS_ABSOLUTE_PATH.
6880 * archive.c (normalize, bfd_bsd_truncate_arname,
6881 bfd_gnu_truncate_arname) [HAVE_DOS_BASED_FILE_SYSTEM]: Support
6882 file names with backslashes.
6884 * cache.c (bfd_open_file) [__MSDOS__]: Don't unlink the file
6887 * sysdep.h: Include filenames.h.
6889 2000-05-26 Alan Modra <alan@linuxcare.com.au>
6891 * opncls.c (bfd_close_all_done): Mask file perms with 0777 not 0x777.
6893 2000-05-26 Jakub Jelinek <jakub@redhat.com>
6895 * elf64-sparc.c (sparc64_elf_relax_section): New.
6896 (sparc64_elf_relocate_section): Optimize tail call into branch always
6898 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
6899 (elf32_sparc_relax_section): New.
6901 2000-05-26 Jakub Jelinek <jakub@redhat.com>
6903 * elf64-sparc.c: Add ATTRIBUTE_UNUSED to unused function parameters.
6904 Remove unusued variables.
6905 (sparc64_elf_relocate_section): Change r_symndx type to unsigned long.
6906 (sparc64_elf_merge_private_bfd_data): Fix shared library case from
6907 previous fix, so that shared libs really don't influence targets
6908 extension mask and memory model.
6910 2000-05-23 H.J. Lu <hjl@gnu.org>
6912 * elf64-alpha.c (elf64_alpha_relocate_section): Check
6913 h->root.other not h->other.
6914 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
6916 * elf32-ppc.c (ppc_elf_relocate_section): Fix a typo.
6918 2000-05-23 H.J. Lu <hjl@gnu.org>
6920 * elf32-i386.c (elf_i386_relocate_section): Don't allow the
6921 undefined symbol with the non-default visibility attributes.
6922 * elf-hppa.h (elf_hppa_relocate_section): Likewise.
6923 * elf32-arm.h (elf32_arm_relocate_section): Likewise.
6924 * elf32-i370.c (i370_elf_relocate_section): Likewise.
6925 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
6926 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
6927 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
6928 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
6929 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
6930 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
6931 * elf64-ia64.c (elf64_ia64_relocate_section): Likewise.
6932 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
6934 2000-05-22 Richard Henderson <rth@cygnus.com>
6936 * elf64-ia64.c (ia64_howto_table): Add PCREL60B, PCREL21BI,
6937 PCREL22, PCREL64I. Zero size of special relocs.
6938 (elf64_ia64_reloc_type_lookup): Likewise.
6939 (USE_BRL, oor_brl, oor_ip): New.
6940 (elf64_ia64_relax_section): New.
6941 (elf64_ia64_check_relocs): Handle PCREL60B, PCREL22, PCREL64I.
6942 (elf64_ia64_install_value): Likewise, plus PCREL21BI.
6943 (elf64_ia64_relocate_section): Likewise.
6944 (bfd_elf64_bfd_relax_section): New.
6945 * reloc.c (BFD_RELOC_IA64_PCREL21BI): New.
6946 (BFD_RELOC_IA64_{PCREL22,PCREL60B,PCREL64I}): New.
6947 * bfd-in2.h, libbfd.h: Regenerate.
6949 2000-05-22 Nick Clifton <nickc@cygnus.com>
6951 * configure.in : Add peigen.lo to MIPS PE targets.
6952 * configure: Regenerate.
6954 2000-05-22 Momchil Velikov <velco@fadata.bg>
6956 * libbfd.c (_bfd_generic_verify_endian_match): Compare endianess
6957 only if it is known for both input and output bfds. Separate
6958 error message strings as in some languages, it may be necessary
6959 to change more than one place in the string to change between
6962 * elf32-ppc.c (ppc_elf_merge_private_bfd_data): Remove inline
6963 endianess checks, call _bfd_generic_verify_endian_match() instead.
6965 * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Likewise.
6967 * elf32-mcore.c (mcore_elf_merge_private_bfd_data): Likewise.
6969 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Likewise. Verify
6970 endianess before checking bfd flavours.
6972 2000-05-22 H.J. Lu <hjl@gnu.org>
6974 * elflink.h (elf_link_output_extsym): Clear the visibility
6975 field for symbols not defined locally.
6977 2000-05-18 Alan Modra <alan@linuxcare.com.au>
6979 * libhppa.h (re_assemble_3, re_assemble_12, re_assemble_16,
6980 re_assemble_17, re_assemble_21, re_assemble_22): Don't mask insn.
6981 (hppa_rebuild_insn): Mask immediate bits here instead.
6982 * elf-hppa.h (elf_hppa_relocate_insn): Mask here too.
6984 2000-05-18 Momchil Velikov <velco@fadata.bg>
6986 * elflink.h (elf_bfd_final_link, elf_link_input_bfd): When emiting
6987 relocs for an executable, ensure that they are virtual addresses.
6989 2000-05-18 Jeffrey A Law (law@cygnus.com)
6991 * config.bfd (hppa*64*-*-hpux11*): New target triplet.
6993 2000-05-17 S. Bharadwaj Yadavalli <sby@scrugs.lkg.dec.com>
6994 Rick Gorton <gorton@scrugs.lkg.dec.com>
6996 * elflink.h: Add emitrelocations support: when enabled, relocation
6997 information and relocation sections are put into final output
6998 executables. If the emitrelocations flag is set, do the following:
6999 (elf_bfd_final_link): Emit relocation sections.
7000 (elf_link_input_bfd): Compute relocation section contents.
7001 (elf_gc_sections): Don't clean relocation sections.
7003 2000-05-16 Catherine Moore <clm@cygnus.com>
7005 * som.c (som_decode_symclass): Recognize weak symbols.
7007 2000-05-16 Szabolcs Szakacsits <szaka@F-Secure.com>
7009 * peigen.c (pe_print_idata): Undo part of 2000-05-12 change that
7010 read idata section only from dataoff.
7011 (pe_print_edata): Correctly check for valid eat_member.
7013 2000-05-16 J"orn Rennecke <amylaar@cygnus.co.uk>
7015 * elf32-sh.c (sh_elf_relax_delete_bytes): Handle R_SH_SWITCH8.
7017 2000-05-14 Philip Blundell <philb@gnu.org>
7019 * config.bfd (armeb-*-elf, arm*b-*-linux-gnu*): New targets.
7021 2000-05-12 Alan Modra <alan@linuxcare.com.au>
7023 * targets.c (bfd_target_vector): #ifdef BFD64 rs6000coff64_vec
7025 * peigen.c (pe_print_idata): Look for .idata section and print
7026 info even if data directory has zero entries. Read idata section
7027 starting from dataoff, and adjust all data offsets to suit. Cast
7028 all bfd_vma vars to unsigned long before passing to fprintf.
7029 * peigen.c (pe_print_edata): Similarly, look for .edata section
7030 and print info even if data directory has zero entries. Cast
7031 all bfd_vma vars to unsigned long before passing to fprintf.
7033 From Szabolcs Szakacsits <szaka@F-Secure.com>
7034 * peigen.c (pe_print_idata): Use bfd_section_size rather than data
7035 directory size which may be bogus.
7036 * peigen.c (pe_print_edata): Similarly.
7038 2000-05-09 Alan Modra <alan@linuxcare.com.au>
7040 * elf.c (bfd_section_from_shdr): Don't set use_rela_p if rela
7042 (copy_private_bfd_data): Allow for space possibly taken up by elf
7043 headers when calculating segment physical address from lma.
7045 2000-05-08 Alan Modra <alan@linuxcare.com.au>
7047 * versados.c (versados_scan): Init stringlen and pass_2_done.
7049 * trad-core.c (trad_unix_core_file_p): Return
7050 bfd_error_wrong_format rather than bfd_error_file_truncated.
7052 * peigen.c (_bfd_pei_swap_aouthdr_out): Pass ImageBase to
7053 add_data_entry. DataDirectory virtual address is relative.
7054 (pe_print_idata): Account for relative DataDirectory virtual
7055 addresses. Don't trash datasize inside POWERPC_LE_PE code.
7056 (pe_print_edata): Similarly.
7058 From Szabolcs Szakacsits <szaka@F-Secure.com>
7059 * peigen.c (dir_names): Add Delay Import Directory.
7060 (pe_print_idata): Always search for bfd section containing
7061 idata address rather than looking up section name. Print this
7062 section name rather than .idata.
7063 (pe_print_edata): Similarly. Also print some fields as %08lx.
7064 (_bfd_pe_print_private_bfd_data_common): Print Reserved1 field as
7067 2000-05-05 Clinton Popetz <cpopetz@cygnus.com>
7069 * xcoff.h: Rename to xcoff-target.h
7070 * Makefile.am: Change all instances of xcoff.h to xcoff-target.h
7071 * coff-rs6000.c: Ditto.
7072 * coff64-rs6000.c: Ditto.
7073 * coff-pmac.c: Ditto.
7074 * Makefile.in: Regenerate.
7076 2000-05-05 Clinton Popetz <cpopetz@cygnus.com>
7078 * coffcode.h (coff_set_arch_mach_hook, coff_set_flags):
7079 Change U802TOC64MAGIC to U803XTOCMAGIC.
7081 2000-05-04 Michael Snyder <msnyder@seadog.cygnus.com>
7083 * elf.c (bfd_elf_get_arch_size): New function, return 32 | 64 | -1.
7084 * bfd-in.h: Prototype bfd_elf_get_arch_size.
7085 * bfd-in2.h: Prototype bfd_elf_get_arch_size.
7087 2000-05-04 Alan Modra <alan@linuxcare.com.au>
7089 * libhppa.h (HPPA_R_CONSTANT): Cast argument to bfd_signed_vma.
7091 2000-05-03 Martin v. L
\81öwis <loewis@informatik.hu-berlin.de>
7093 * elflink.h (elf_link_add_object_symbols): Reset dynindx for
7094 hidden and internal symbols.
7095 (elf_fix_symbol_flags): Clear NEEDS_PLT for symbols with
7097 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Do not
7098 assign a PLT or GOT entry to symbols with hidden and
7099 internal visibility.
7101 2000-05-03 Mark Elbrecht <snowball3@bigfoot.com>
7103 * coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Add entry for
7105 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
7107 2000-05-02 H.J. Lu <hjl@gnu.org>
7109 * elf.c (prep_headers): Use ELFOSABI_NONE instead of
7112 2000-05-02 Alan Modra <alan@linuxcare.com.au>
7114 * targets.c (bfd_target_vector): Restore bfd_elf32_hppa_vec.
7115 * Makefile.am (BFD32_BACKENDS): Restore elf32-hppa.lo. Regenerate
7117 * Makefile.in: Regenerate.
7119 2000-05-01 Jim Wilson <wilson@cygnus.com>
7121 * Makefile.am (BFD32_BACKENDS): Add efi-app-ia32.lo.
7122 (BFD32_BACKENDS_CFILES): Add efi-app-ia32.c.
7123 (BFD64_BACKENDS): Delete coff-ia64.lo. Add efi-app-ia64.lo.
7124 (BFD64_BACKENDS_CFILES): Delete coff-ia64.c. Add efi-app-ia64.c.
7125 * Makefile.in: Rebuild.
7127 2000-05-02 Alan Modra <alan@linuxcare.com.au>
7129 * config.bfd: Re-enable elf32-hppa. It now compiles, even if it
7130 doesn't work very well.
7132 * elf-hppa.h (elf_hppa_internal_shdr): Define.
7133 (elf_hppa_fake_sections): hdr is elf_hppa_internal_shdr.
7134 Set hdr->s_type to 1 if ARCH_SIZE == 32.
7135 (_bfd_elf_hppa_gen_reloc_type): Add prototype.
7136 (elf_hppa_info_to_howto): Likewise.
7137 (elf_hppa_info_to_howto_rel): Likewise.
7138 (elf_hppa_reloc_type_lookup): Likewise.
7139 (elf_hppa_is_local_label_name): Likewise.
7140 (elf_hppa_fake_sections): Likewise.
7141 (elf_hppa_final_write_processing): Likewise.
7142 (elf_hppa_howto_table): Fully initialise all entries.
7143 (_bfd_elf_hppa_gen_reloc_type): Add ATTRIBUTE_UNUSED to args.
7144 (elf_hppa_info_to_howto): Likewise.
7145 (elf_hppa_info_to_howto_rel): Likewise.
7146 (elf_hppa_reloc_type_lookup): Likewise.
7147 (elf_hppa_final_write_processing, elf_hppa_add_symbol_hook,
7148 elf_hppa_unmark_useless_dynamic_symbols,
7149 elf_hppa_remark_useless_dynamic_symbols,
7150 elf_hppa_record_segment_addrs, elf_hppa_final_link,
7151 elf_hppa_relocate_section, elf_hppa_final_link_relocate,
7152 elf_hppa_relocate_insn): Compile only if ARCH_SIZE == 64 until
7153 elf32-hppa.c mess is cleaned up.
7154 (elf_hppa_final_link_relocate): Make insn and r_type unsigned
7155 int. Delete r_field. In case R_PARISC_PCREL21L, don't set
7156 r_field then call hppa_field_adjust inline func with variable
7157 r_field arg, instead call hppa_field_adjust with fixed arg.
7158 In case R_PARISC_PCREL22F, don't set r_field.
7159 (elf_hppa_relocate_insn): Change args and return type to unsigned
7160 int. Call re_assemble_* funcs to do the work.
7162 * elf32-hppa.c (hppa_elf_relocate_insn): Don't assume 32 bit when
7165 * libhppa.h (HPPA_R_CONSTANT): Don't assume 32 bit when sign
7167 (sign_extend): Mask first before sign extending.
7168 (low_sign_extend): Rewrite without condition expression.
7169 (ones, dis_assemble_3, dis_assemble_12, dis_assemble_16,
7170 dis_assemble_17, dis_assemble_21, dis_assemble_22): Delete.
7171 (assemble_3, assemble_6, assemble_12, assemble_16, assemble_16a,
7172 assemble_17, assemble_21, sign_unext, low_sign_unext): Return
7173 result as function return value rather than through pointer arg.
7174 Accept unsigned int args, and return unsigned int.
7175 (re_assemble_3): New. Combines function of dis_assemble_3 with
7176 re-assembly of opcode and immediate.
7177 (re_assemble_12): Likewise.
7178 (re_assemble_16): Likewise.
7179 (re_assemble_17): Likewise.
7180 (re_assemble_21): Likewise.
7181 (re_assemble_22): Likewise.
7182 (hppa_field_adjust): Rewrite and document, paying attention to
7183 size of types and signed/unsigned issues.
7184 (get_opcode): Shift before masking.
7185 (FDLW): Rename to FLDW.
7186 (bfd_hppa_insn2fmt): Change arg to unsigned int. Delete fmt.
7187 (hppa_rebuild_insn): Change args and return value to unsigned
7188 int. Make use of re_assemble_*. Correct case 11.
7190 * dep-in.sed: Handle ../opcodes/.
7191 * Makefile.am (SOURCE_HFILES): Add elf-hppa.h, elf32-hppa.h,
7192 elf64-hppa.h, hppa_stubs.h, xcoff.h.
7193 (BFD32_BACKENDS_CFILES): Restore elf32-hppa.c.
7194 Remove elf64-hppa.lo, cpu-ia64.lo, elf64-ia64.lo, elfarm-oabi.lo,
7195 elfarm-nabi.lo dependencies outside of auto-dependency area.
7196 Regenerate dependencies.
7197 * Makefile.in: Regenerate.
7199 * configure.in (TRAD_HEADER): Test non-null before
7201 * configure: Regenerate.
7203 * reloc.c: Fix mis-spelling in comment.
7205 2000-05-01 Alan Modra <alan@linuxcare.com.au>
7207 * coff-sh.c (bfd_coff_small_swap_table): Fix Fri Apr 28 change.
7208 * vms.c (vms_openr_next_archived_file): Return NULL.
7210 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7212 * coffcode.h Copy changes mistakenly done to libcoff.h in
7215 2000-04-29 Andreas Jaeger <aj@suse.de>
7217 * libbfd-in.h: Correctly check GCC version.
7218 * bfd-in.h: Likewise.
7219 * libhppa.h: Likewise.
7220 * libbfd.h: Regenerate.
7221 * bfd-in2.h: Regenerate.
7223 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7225 * Makefile.am (BFD64_BACKENDS, BFD64_BACKENDS_CFILES): Add
7226 coffdu-rs6000.{lo,c}.
7227 (coff-pmac.lo, coff-rs6000.lo, coff64-rs6000.lo): Add dependency
7229 * Makefile.in: Regenerate.
7230 * xcoff.h: New file.
7231 * coff-pmac.c: Use xcoff.h instead of coff-rs6000.c.
7232 * coff-rs6000.c: Move all declarations and defines that are
7233 common to the xcoff backends into xcoff.h
7234 * coff64-rs6000.c: Ditto,
7236 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7238 * coff-mips.c (mips_ecoff_backend_data): Add initialization of
7239 _bfd_coff_force_symnames in strings and
7240 _bfd_coff_debug_string_prefix_length to their default values.
7241 * coff-sh.c: (bfd_coff_small_swap_table): Ditto.
7243 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7245 * coff-alpha.c (alpha_ecoff_backend_data): Add initialization of
7246 _bfd_coff_force_symnames in strings and
7247 _bfd_coff_debug_string_prefix_length to their default values.
7249 2000-04-27 Alan Modra <alan@linuxcare.com.au>
7251 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Return if dynobj NULL.
7252 Check local_got_refcounts before dereferencing.
7254 * elf32-ppc.c (ppc_elf_relocate_section): Check splt != NULL
7255 before deciding we don't need R_PPC_PLT32 relocation.
7256 (ppc_elf_gc_sweep_hook): Check local_got_refcounts before
7259 * elflink.h (elf_gc_common_finalize_got_offsets): Fix comment.
7261 * elf32-i386.c (elf_i386_check_relocs): Reference count .got and
7263 (elf_i386_gc_sweep_hook): Garbage collect .got and .plt entries.
7264 (elf_i386_adjust_dynamic_symbol): Recognize unused .plt entries.
7265 (elf_i386_relocate_section): Allow for .plt to go missing.
7266 (elf_i386_finish_dynamic_symbol): Use same test to decide if we
7267 can use a relative reloc for got as elf_i386_relocate_section.
7268 (bfd_elf32_bfd_final_link): Define to use gc form of final link.
7270 2000-04-26 Clinton Popetz <cpopetz@cygnus.com>
7272 * config.bfd: Remove extraneous bfd_powerpc_64_arch.
7274 2000-04-24 Clinton Popetz <cpopetz@cygnus.com>
7276 * Makefile.am (coff64-rs6000.lo): New rule.
7277 * Makefile.in: Regenerate.
7278 * coff-rs6000.c (xcoff_mkobject, xcoff_copy_private_bfd_data,
7279 xcoff_is_local_label_name, xcoff_rtype2howto,
7280 xcoff_reloc_type_lookup, xcoff_slurp_armap, xcoff_archive_p,
7281 xcoff_read_ar_hdr, xcoff_openr_next_archived_file, xcoff_write_armap,
7282 xcoff_write_archive_contents): No longer static, and prefix with _bfd_.
7283 (NO_COFF_SYMBOLS): Define.
7284 (xcoff64_swap_sym_in, xcoff64_swap_sym_out, xcoff64_swap_aux_in,
7285 xcoff64_swap_aux_out): New functions; handle xcoff symbol tables
7287 (MINUS_ONE): New macro.
7288 (xcoff_howto_tabl, xcoff_reloc_type_lookup): Add 64 bit POS
7290 (coff_SWAP_sym_in, coff_SWAP_sym_out, coff_SWAP_aux_in,
7291 coff_SWAP_aux_out): Map to the new functions.
7292 * coff64-rs6000.c: New file.
7293 * libcoff.h (bfd_coff_backend_data): Add new fields
7294 _bfd_coff_force_symnames_in_strings and
7295 _bfd_coff_debug_string_prefix_length.
7296 (bfd_coff_force_symnames_in_strings,
7297 bfd_coff_debug_string_prefix_length): New macros for above fields.
7298 * coffcode.h (coff_set_arch_mach_hook): Handle XCOFF64 magic.
7299 Set machine to 620 for XCOFF64. Use bfd_coff_swap_sym_in instead
7300 of using coff_swap_sym_in directly.
7301 (FORCE_SYMNAMES_IN_STRINGS): New macro, defined for XCOFF64.
7302 (coff_set_flags) Set magic for XCOFF64.
7303 (coff_compute_section_file_positions): Add symbol name length to
7304 string section length if bfd_coff_debug_string_prefix_length is
7306 (coff_write_object_contents): Don't do reloc overflow for XCOFF64.
7307 (coff_slurp_line_table): Use bfd_coff_swap_lineno_in instead of
7308 using coff_swap_lineno_in directly.
7309 (bfd_coff_backend_data): Add _bfd_coff_force_symnames_in_strings
7310 and _bfd_coff_debug_string_prefix_length fields.
7311 * coffgen.c (coff_fix_symbol_name, coff_write_symbols): Force
7312 symbol names into strings table when
7313 bfd_coff_force_symnames_in_strings is true.
7314 * coffswap.h (MAX_SCNHDR_NRELOC, MAX_SCNHDR_NLNNO, GET_RELOC_VADDR,
7315 SET_RELOC_VADDR): New macros.
7316 (coff_swap_reloc_in, coff_swap_reloc_out): Use above macros.
7317 (coff_swap_aux_in, coff_swap_aux_out): Remove RS6000COFF_C
7319 (coff_swap_aouthdr_in, coff_swap_aouthdr_out): Handle XCOFF64
7320 changes within RS6000COFF_C specific code.
7321 (coff_swap_scnhdr_out): Use PUT_SCNHDR_NLNNO, PUT_SCNHDR_NRELOC,
7322 MAX_SCNHDR_NRELOC, and MAX_SCNHDR_NLNNO.
7323 * reloc.c (bfd_perform_relocation, bfd_install_relocation):
7324 Extend existing hack on target name.
7325 * xcofflink.c (XCOFF_XVECP): Extend existing hack on
7327 * coff-tic54x.c (ticof): Keep up to date with new fields
7328 in bfd_coff_backend_data.
7329 * config.bfd: Add bfd_powerpc_64_arch to targ_arch and define
7330 targ_selvecs to include rs6000coff64_vec for rs6000.
7331 * configure.in: Add rs6000coff64_vec case.
7332 * cpu-powerpc.c: New bfd_arch_info_type.
7334 2000-04-24 Jeffrey A Law (law@cygnus.com)
7336 * config.bfd: Only disable elf32-hppa vectors, not all of the
7337 BSD and OSF configuration support. Provide (disabled) clauses
7339 * configure.in: Add clause for PA64 support.
7340 * configure: Rebuilt.
7342 * targets.c (bfd_target_vector): Add bfd_elf64_hppa_vec.
7343 (bfd_elf64_hppa_vec): Declare.
7345 * Makefile.am (BFD64_BACKENDS): Add elf64-hppa.lo
7346 (BFD64_BACKENDS_CFILES): Add elf64-hppa.c
7347 (elf64-hppa.lo): Add dependencies.
7348 * Makefile.in: Rebuilt.
7350 * elf64-hppa.c, elf64-hppa.h: New files with PA64 support.
7352 2000-04-24 Jason Eckhardt <jle@cygnus.com>
7354 * libhppa.h (dis_assemble_16): New function.
7355 (pa_arch): Added pa20w element.
7357 2000-04-24 Ulrich Drepper <drepper@cygnus.com>
7359 * elf-bfd.h: Add prototypes for bfd_elf32_write_relocs,
7360 bfd_elf32_slurp_reloc_table, bfd_elf64_write_relocs, and
7361 bfd_elf64_slurp_reloc_table.
7363 * elfcode.h (elf_write_relocs, elf_slurp_reloc_table): New
7364 definitions to get external names.
7365 (elf_write_relocs): Renamed from write_relocs and make global.
7366 (elf_slurp_reloc_table): Make global.
7367 (_bfd_elf,size_info): Use elf_write_relocs instead of write_relocs.
7369 * archive.c (hpux_uid_gid_encode): New function.
7370 (bfd_ar_hdr_from_filesystem): Use it if HPUX_LARGE_AR_IDS is
7371 defined and the ID is greater than 99999.
7372 (bfd_generic_stat_arch_elt): If HPUX_LARGE_AR_IDS is defined decode
7373 special uid/gid fields into 32 bit values.
7375 2000-04-21 Matthew Green <mrg@cygnus.com>
7377 * config.bfd: Add NetBSD/sparc64 support.
7379 Fri Apr 21 13:20:53 2000 Richard Henderson <rth@cygnus.com>
7380 David Mosberger <davidm@hpl.hp.com>
7381 Timothy Wall <twall@cygnus.com>
7382 Jim Wilson <wilson@cygnus.com>
7384 * Makefile.am (ALL_MACHINES): Add cpu-ia64.lo.
7385 (ALL_MACHINES_CFILES): Add cpu-ia64.c.
7386 (BFD64_BACKENDS): Add elf64-ia64.lo.
7387 (BFD64_BACKENDS_CFILES): Add elf64-ia64.c.
7388 (cpu-ia64.lo, elf64-ia64.lo): New rules.
7389 * Makefile.in: Rebuild.
7390 * archures.c (enum bfd_architecture): Add bfd_arch_ia64.
7391 (bfd_ia64_arch): Declare.
7392 (bfd_archures_list): Add bfd_ia64_arch.
7393 * bfd-in2.h: Rebuild.
7394 * config.bfd: (ia64*-*-linux-gnu*, ia64*-*-elf*): New targets.
7395 * configure: Rebuild.
7396 * configure.host: (ia64-*-linux*): New host.
7397 * configure.in (bfd_elf64_ia64_little_vec, bfd_elf64_ia64_big_vec,
7398 bfd_efi_app_ia64_vec, bfd_efi_app_ia64_vec): New vectors.
7399 * elf.c (prep_headers): Add bfd_arch_ia64.
7400 * libbfd.h: Rebuild.
7401 * reloc.c: Add IA-64 relocations.
7402 * targets.c (bfd_elf64_ia64_little_vec, bfd_elf64_ia64_big_vec):
7404 (bfd_target_vect): Add bfd_elf64_ia64_little_vec.
7405 * cpu-ia64-opc.c, cpu-ia64.c, elf64-ia64.c: New files.
7407 2000-04-21 Richard Henderson <rth@cygnus.com>
7409 * elf32-d30v.c (bfd_elf_d30v_reloc): Don't modify section
7410 contents when performing a partial link.
7411 (bfd_elf_d30v_reloc_21): Likewise.
7413 2000-04-20 H.J. Lu <hjl@gnu.org>
7415 * elf32-i386.c (elf_i386_relocate_section): Restrict 1998-12-10
7416 patch to symbols defined by a shared object.
7417 * elf32-ppc.c (ppc_elf_relocate_section): Similarly.
7419 2000-04-19 Michael Sokolov <msokolov@ivan.Harhan.ORG>
7422 * dwarf2.c (concat_filename): Avoid string literal concatenation.
7423 * ieee.c (ieee_get_symtab): Don't initialise union in struct.
7425 Mon Apr 17 19:14:36 2000 David Mosberger <davidm@hpl.hp.com>
7427 * Makefile.am (BFD64_BACKENDS): Mention coff-ia64.lo.
7428 (BFD64_BACKENDS_CFILES): Mention coff-ia64.c
7429 (coff-ia64.lo): Add dependency.
7430 * Makefile.in: Regenerate.
7431 * coff-ia64.c: New file.
7432 * efi-app-ia32.c: Ditto.
7433 * efi-app-ia64.c: Ditto.
7434 * coffcode.h (coff_set_arch_mach_hook): Handle IA64MAGIC.
7435 (coff_set_flags): Ditto.
7436 (coff_write_object_contents) [IA64]: Set magic number to ZMAGIC.
7437 * config.bfd (i[3456]86-*-linux-gnu*): Mention bfd_efi_app_ia32_vec.
7438 * configure.in (elf): Handle bfd_efi_app_ia32 and bfd_efi_app_ia64_vec.
7439 * configure: Regenerate.
7440 * libpei.h (GET_OPTHDR_IMAGE_BASE): New macro.
7441 (PUT_OPTHDR_IMAGE_BASE): Ditto.
7442 (GET_OPTHDR_SIZE_OF_STACK_RESERVE): Ditto.
7443 (PUT_OPTHDR_SIZE_OF_STACK_RESERVE): Ditto.
7444 (GET_OPTHDR_SIZE_OF_STACK_COMMIT): Ditto.
7445 (PUT_OPTHDR_SIZE_OF_STACK_COMMIT): Ditto.
7446 (GET_OPTHDR_SIZE_OF_HEAP_RESERVE): Ditto.
7447 (PUT_OPTHDR_SIZE_OF_HEAP_RESERVE): Ditto.
7448 (GET_OPTHDR_SIZE_OF_HEAP_COMMIT): Ditto.
7449 (PUT_OPTHDR_SIZE_OF_HEAP_COMMIT): Ditto.
7450 (GET_PDATA_ENTRY): Ditto.
7451 * peigen.c (_bfd_pei_swap_aouthdr_in) [COFF_WITH_PEP64]: Don't read
7452 data_start. Use above macros to read fields that are 64 bit wide for
7453 COFF_WITH_PEP64. Don't truncate entry and text_start to 32 bits.
7454 (_bfd_pei_swap_aouthdr_out) [PEI_FORCE_MINIMUM_ALIGNMENT]: Force
7455 FileAlignment and SectionAlignment to minimum alignment if they
7457 (_bfd_pei_swap_aouthdr_out) [PEI_DEFAULT_TARGET_SUBSYSTEM]: Set
7458 Subsystem to default PEI_DEFAULT_TARGET_SUBSYSTEM.
7459 (_bfd_pei_swap_aouthdr_out) [COFF_WITH_PEP64]: Don't set data_start.
7460 Use above macros to write fields that are 64 bit wide for
7462 (pe_print_pdata): Set PDATA_ROW_SIZE to 3*8 for COFF_WITH_PEP64,
7463 5*4 otherwise. This should be right for IA-32 and IA-64, but may
7464 be wrong for platforms. Use PDATA_ROW_SIZE instead of hardcoded
7465 value of 20 bytes. Modify printing for COFF_WITH_PEP64 to print
7466 begin address, end address, and unwind info address only. Use
7467 GET_PDATA_ENTRY() to read .pdata entries. Use fprintf_vma() to
7469 (tbl): Add SECTION, REL32, RESERVED1, MIPS_JMPADDR16, DIR64, and
7470 HIGH3ADJ relocation names.
7471 (_bfd_pe_print_private_bfd_data): Print Subsystem name in legible form.
7472 * targets.c: Declare bfd_efi_app_ia32_vec and
7473 bfd_efi_app_ia64_vec.
7474 (bfd_target_vector): Mention bfd_efi_app_ia32_vec and
7475 bfd_efi_app_ia64_vec.
7477 2000-04-17 Timothy Wall <twall@cygnus.com>
7479 * bfd-in2.h: Add prototypes for tic54x load page access.
7480 * bfd-in.h: Regenerate.
7481 * coff-tic54x.c: Add load page functions; allow bfd_arch_unknown
7482 in customized _set_arch_mach function.
7483 * coffcode.h (coff_set_alignment_hook): Set section load page if
7484 the appropriate macro is defined.
7485 (write_object_contents): Read section load page.
7487 2000-04-13 Alan Modra <alan@linuxcare.com.au>
7489 * elf32-hppa.h: Update copyright date.
7491 * elf32-fr30.c (fr30_elf_i20_reloc): Don't use U suffix.
7492 * elf32-mips.c (_bfd_mips_elf_relocate_section): And here.
7494 * elf32-d30v.c (MAX32): Don't use LL suffix.
7495 (MIN32): Define in terms of MAX32.
7496 (bfd_elf_d30v_reloc): Make relocation a bfd_signed_vma.
7498 * coff-a29k.c (SIGN_EXTEND_HWORD): Replace with more concise
7501 * peicode.h (pe_ILF_build_a_bfd): Remove UL from hex constants.
7503 2000-04-12 Alan Modra <alan@linuxcare.com.au>
7505 * dep-in.sed: Match space before file name, not after.
7506 * Makefile.am: Regenerate dependencies.
7507 * Makefile.in: Regenerate.
7509 * reloc.c (_bfd_relocate_contents): In complain_overflow_bitfield
7510 case, allow address wrap-around stupidly removed 2000-03-17. Sign
7511 extend without an if statement.
7513 2000-04-11 Alan Modra <alan@linuxcare.com.au>
7515 * coff-mips.c (mips_gprel_reloc): Test for 16 bit range using
7517 * elf32-mips.c (gprel16_with_gp): Likewise.
7518 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Test range
7519 here using -0x40000, not (int)0xfffc0000.
7520 (elf32_hppa_size_of_stub): Likewise.
7522 2000-04-11 Timothy Wall <twall@cygnus.com>
7524 * coff-tic54x.c: Now builds with all targets.
7525 * Makefile.am: Add coff/tic54x.h to coff-tic54x.o dependencies.
7526 * Makefile.in: Regenerate.
7527 * coffcode.h (coff_set_arch_mach_hook): Eliminate warning on
7528 unitialized variable.
7530 Fri Apr 7 15:56:57 2000 Andrew Cagney <cagney@b1.cygnus.com>
7532 * configure.in (WARN_CFLAGS): Set to -W -Wall by default. Add
7533 --enable-build-warnings option.
7534 * Makefile.am (AM_CFLAGS, WARN_CFLAGS): Add definitions.
7535 * Makefile.in, configure: Re-generate.
7537 2000-04-07 Nick Clifton <nickc@cygnus.com>
7539 * reloc.c: Add BFD_RELOC_ARM_PCREL_BLX and
7540 BFD_RELOC_THUMB_PCREL_BLX.
7542 * elf32-arm.h (elf32_arm_final_link_relocate): Handle
7543 R_ARM_XPC25 and R_ARM_THM_PC22.
7545 * elfarm-nabi.c (elf32_arm_howto_): Fix definitions of
7546 R_ARM_XPC25 and R_ARM_THM_XPC22.
7547 (elf32_arm_reloc_map): Make BFD_RELOC_{ARM|THUMB}_PCREL_BLX to
7548 R_ARM_[XPC25|THM_XPC22].
7550 * elfarm-oabi.c: Define OLD_ARM_ABI and change include from
7551 elf/arm-oabi.h to elf/arm.h
7553 * Makefile.am: Fix dependency for elfarm-oabi.c
7554 * Makefile.in: Regenerate.
7556 * bfd-in2.h: Regenerate.
7557 * libbfd.h: Regenerate.
7559 2000-04-06 Michael Snyder <msnyder@seadog.cygnus.com>
7561 * elfcore.h (elf_core_file_p): preserve value of tdata at entry,
7562 and restore it on failure. Release newly allocated tdata on
7565 Fri Apr 7 11:33:47 2000 Jim Wilson <wilson@cygnus.com>
7567 * dwarf2.c (struct dwarf2_debug): New field dwarf_line_size.
7568 (decode_line_info): Set it. Report error if unit->line_offset is
7569 equal to or larger than it.
7571 2000-04-07 Timothy Wall <twall@cygnus.com>
7573 * targets.c: Added vecs for tic54x.
7574 * reloc.c: Added relocs for tic54x.
7575 * libbfd.h: Regenerated.
7576 * configure: Add TI COFF vecs for tic54x.
7577 * configure.in: Ditto.
7578 * config.bfd (targ_cpu): Recognize new tic54x target.
7579 * coffcode.h (coff_slurp_symbol_table): Additions for TI COFF handling.
7580 * bfd-in2.h: Add tic54x target and relocations.
7581 * Makefile.am, Makefile.in: Add tic54x target.
7582 * archures.c (bfd_archures_list): Add tic54x target.
7583 * coff-tic54x.c: New.
7584 * cpu-tic54x.c: New.
7586 2000-04-06 Michael Snyder <msnyder@seadog.cygnus.com>
7588 * elfcore.h (elf_core_file_p): call backend_object_p which
7589 thereby gets an opportunity to update the arch/machine type.
7591 2000-04-06 Timothy Wall <twall@cygnus.com>
7593 * coffcode.h (coff_slurp_symbol_table): Handle C_STATLAB storage
7594 class. Handle SEC_CLINK and SEC_BLOCK flags.
7595 * section.c: Add SEC_CLINK and SEC_BLOCK flags.
7596 * bfd-in2.h: Add SEC_CLINK and SEC_BLOCK flags.
7598 2000-04-06 Nick Clifton <nickc@cygnus.com>
7600 * elf32-arm.h (elf32_arm_set_private_flags): Only check for
7601 EF_INTERWORK if this is an unknown EABI.
7602 (elf32_arm_merge_private_bfd_data): Check EABI version
7603 numbers. Only check EF_xxx flags if the EABI version number
7605 (elf32_arm_check_private_bfd_data): Only check EF_xxx flags
7606 if the EABI version number is unknown.
7607 (elf32_arm_print_private_bfd_data): Only decode EF_xxx flags
7608 if the EABI version number is unknown.
7610 Wed Apr 5 22:04:20 2000 J"orn Rennecke <amylaar@cygnus.co.uk>
7612 * reloc.c (_bfd_relocate_contents): Add BFD_RELOC_SH_LOOP_START and
7613 BFD_RELOC_SH_LOOP_END.
7614 * elf32-sh.c (sh_elf_howto_tab): Change special_func to
7615 sh_elf_ignore_reloc for all entries that sh_elf_reloc used to ignore.
7616 Add entries for R_SH_LOOP_START and R_SH_LOOP_END.
7617 (sh_elf_reloc_loop): New function.
7618 (sh_elf_reloc): No need to test for always-to-be-ignored relocs
7620 (sh_rel): Add entries for BFD_RELOC_SH_LOOP_{START,END}.
7621 (sh_elf_relocate_section): Handle BFD_RELOC_SH_LOOP_{START,END}.
7622 * bfd-in2.h, libbfd.h: Regenerate.
7624 2000-04-04 Alan Modra <alan@linuxcare.com.au>
7626 * po/bfd.pot: Regenerate.
7628 * Makefile.am: Remove extraneous mkdep comment.
7629 (MKDEP): Use gcc -MM rather than mkdep.
7630 (DEP): Quote when passing vars to sub-make. Add warning
7632 (DEP1): Rewrite for "gcc -MM".
7633 (CLEANFILES): Add DEP2.
7634 Update dependencies.
7635 * Makefile.in: Regenerate.
7637 2000-04-03 Kevin Buettner <kevinb@redhat.com>
7639 * configure.in: Added corefile support for AIX 4.3. In particular,
7640 AIX_CORE_DUMPX_CORE will be defined in addition to AIX_CORE when
7641 compiling rs6000-core.c.
7642 * configure: Regenerated.
7644 2000-04-03 H.J. Lu <hjl@gnu.org>
7646 * cache.c (bfd_open_file): Unlink the output file only if
7647 it has non-zero size.
7649 2000-04-01 Ken Block USG <block@zk3.dec.com>
7651 * elf64-alpha.c (elf64_alpha_relocate_section): Don't emit
7652 relative relocations for non-loaded sections in shared objects.
7653 (elf64_alpha_check_relocs): Similarly.
7655 Mon Apr 3 13:37:15 2000 Hans-Peter Nilsson <hp@axis.com>
7657 * aoutx.h (NAME(aout,reloc_type_lookup)): Add BFD_RELOC_8 and
7658 BFD_RELOC_16 to switch for extended relocs.
7659 (MY_swap_ext_reloc_in): New.
7660 (MY_swap_ext_reloc_out): New.
7661 (NAME(aout,slurp_reloc_table)): Use MY_swap_ext_reloc_in rather
7662 than NAME(aout,swap_ext_reloc_in) for extended relocs.
7663 (NAME(aout,squirt_out_relocs)): Similarly use
7664 MY_swap_ext_reloc_out.
7665 (aout_link_reloc_link_order): Use MY_put_ext_reloc if defined.
7667 2000-04-03 Kazu Hirata <kazu@hxi.com>
7669 * coff-h8300.c (h8300_reloc16_extra_cases): Add bsr:16 -> bsr:8 to
7670 the R_PCRWORD_B case.
7672 2000-03-31 Thomas de Lellis <tdel@wrs.com>
7674 * srec.c : Set CHUNK size to 16 bytes to prevent download failures
7678 Wed Mar 30 15:28:00 2000 Donald Lindsay <dlindsay@cygnus.com>
7680 * elf32-m32r.c (m32r_elf_generic_reloc): new function. All
7681 HOWTO references to bfd_elf_generic_reloc, that have
7682 partial_inplace == true, now use the new function. The function
7683 is based on the recent rewrite of m32r_elf_lo16_reloc(), and
7684 extends its fixes to the R_M32R_{16,24,32} relocs.
7685 The new logic in m32r_elf_lo16_reloc() has been removed, and
7686 it instead calls the new routine to obtain that functionality.
7688 2000-03-27 Alan Modra <alan@linuxcare.com.au>
7690 * elf32-avr.c (elf32_avr_gc_mark_hook, elf32_avr_gc_sweep_hook,
7691 elf32_avr_check_relocs, avr_final_link_relocate,
7692 elf32_avr_relocate_section, bfd_elf_avr_final_write_processing,
7693 elf32_avr_object_p): Add prototypes.
7694 (elf32_avr_gc_mark_hook): Add default for h->root.type.
7695 (bfd_elf_avr_final_write_processing): Make static.
7697 2000-03-27 Denis Chertykov <denisc@overta.ru>
7699 * cpu-avr.c: New file. BFD support routines for AVR architecture.
7700 * archures.c (bfd_architecture): Add AVR architecture.
7701 (bfd_archures_list): Add reference to AVR architecture info.
7702 * elf.c (prep_headers): Handle bfd_arch_avr.
7703 * reloc.c: Add various AVR relocation enums.
7704 * targets.c (bfd_elf32_avr_vec): Declare and add to target vector
7706 * Makefile.am: Add support for AVR elf.
7707 * configure.in: Likewise.
7708 * config.bfd: Likewise.
7709 * Makefile.in: Regenerate.
7710 * configure: This too.
7711 * bfd-in2.h: And this.
7712 * libbfd.h: And this.
7714 2000-03-24 H.J. Lu <hjl@gnu.org>
7716 * elf64-alpha.c (elf64_alpha_merge_ind_symbols): Add prototype.
7717 (elf64_alpha_find_reloc_at_ofs): Likewise.
7719 2000-03-17 Alan Modra <alan@linuxcare.com.au>
7721 * reloc.c (bfd_check_overflow): In case complain_overflow_bitfield,
7722 flag an overflow if the bitfield is outside -2**n to 2**n-1. The
7723 allowable range used to be -2**(n-1) to 2**n-1.
7724 * reloc.c (_bfd_relocate_contents): Same here. Also replace
7725 "boolean overflow" with "bfd_reloc_status_type flag".
7727 2000-03-14 Doug Evans <dje@casey.transmeta.com>
7729 * elf32-m32r.c (m32r_elf_lo16_reloc): Rewrite.
7731 2000-03-14 Kazu Hirata <kazu@hxi.com>
7733 * reloc16.c (bfd_coff_reloc16_relax_section): Count the total number
7734 of shrinks properly, including the last reloc.
7736 2000-03-13 Kazu Hirata <kazu@hxi.com>
7738 * coff-h8300.c (h8300_reloc16_extra_cases): Fix the sanity
7741 2000-03-11 Alan Modra <alan@linuxcare.com.au>
7743 * ieee.c (ieee_archive_p): Return bfd_error_wrong_format on
7744 a format mismatch rather than an "error" from bfd_read such as
7745 bfd_error_file_truncated.
7747 2000-03-10 Geoff Keating <geoffk@cygnus.com>
7749 * elf32-mips.c (_bfd_mips_elf_relocate_section): Do proper
7750 sign-extension and big-endian compensation for
7751 R_MIPS_64 even in ld -r.
7753 2000-03-10 Geoffrey Keating <geoffk@cygnus.com>
7755 * elf32-mips.c (mips_elf_next_relocation): Rename from
7756 mips_elf_next_lo16_relocation, and generalize to look
7757 for any relocation type.
7758 (elf_mips_howto_table): Make R_MIPS_PC16 pcrel_offset.
7759 (elf_mips_gnu_rel_hi16): Howto for R_MIPS_GNU_REL_HI16.
7760 (elf_mips_gnu_rel_lo16): Howto for R_MIPS_GNU_REL_LO16.
7761 (elf_mips_gnu_rel16_s2): Howto for R_MIPS_GNU_REL16_S2.
7762 (elf_mips_gnu_pcrel64): Howto for R_MIPS_PC64.
7763 (elf_mips_gnu_pcrel32): Howto for R_MIPS_PC32.
7764 (bfd_elf32_bfd_reloc_type_lookup): Add new relocs.
7765 (mips_rtype_to_howto): Likewise.
7766 (mips_elf_calculate_relocation): Handle new relocs.
7767 (_bfd_mips_elf_relocate_section): REL_HI16/REL_LO16 relocs
7768 are paired. The addend for R_MIPS_GNU_REL16_S2
7769 is shifted right two bits.
7771 2000-03-10 Alan Modra <alan@linuxcare.com.au>
7773 * reloc.c (bfd_perform_relocation): Undo emacs formatting of
7774 comment, and ensure it doesn't happen again.
7775 (bfd_install_relocation): Same here.
7776 (_bfd_relocate_contents): Don't bother assigning unused signmask
7777 shift result. Fix typos in comments.
7778 Remove trailing whitespace throughout file.
7780 2000-03-07 Doug Evans <dje@casey.transmeta.com>
7782 * reloc.c (reloc_howto_struct): Fix partial_inplace comment.
7783 * bfd-in2.h: Rebuild.
7785 2000-03-06 Nick Clifton <nickc@cygnus.com>
7787 * peicode.h (struct pe_ILF_vars): Add sym_ptr_table and
7789 (SIZEOF_ILF_SYM_PTR_TABLE): Define.
7790 (SIZEOF_ILF_STRINGS): Redefine.
7791 (pe_ILF_make_a_symbol-reloc): New function. Creates a symbol
7792 relative reloc, as opposed to a section relative reloc.
7793 (pe_ILF_make_a_symbol): Set the class of local symbols to C_STAT
7795 Add length of symbol's prefix to string pointer.
7796 Store a pointer to the symbol in the symbol pointer table.
7797 (pe_ILF_build_a_bfd): Do not build .idata$2 or .idata$7.
7798 Initialise the symbol pointer table.
7799 Store the hint in the Hint/Name table.
7800 Make the jump reloc be symbol realtive, not section relative.
7801 Create an import symbol for imported code.
7803 2000-03-06 Catherine Moore <clm@cygnus.com>
7805 * elf.c (swap_out_syms): Check for null type_ptr.
7807 2000-03-01 Hans-Peter Nilsson <hp@axis.com>
7809 * aout-target.h (MY(write_object_contents)): Remove unused
7810 and unusable "#if CHOOSE_RELOC_SIZE".
7811 * pc532-mach.c (MY(write_object_contents)): Ditto.
7812 * netbsd.h (MY(write_object_contents)): Ditto.
7813 * hp300hpux.c (MY(write_object_contents)): Ditto.
7814 * freebsd.h (MY(write_object_contents)): Ditto.
7815 * aout-tic30.c (tic30_aout_write_object_contents): Ditto.
7817 2000-02-29 H.J. Lu <hjl@gnu.org>
7819 * peicode.h (jtab): Make it static.
7821 * coff-sh.c (sh_align_load_span): Declared if COFF_WITH_PE is
7822 defined and COFF_IMAGE_WITH_PE is not defined.
7823 (_bfd_sh_align_load_span): Defined as sh_align_load_span if
7824 COFF_WITH_PE is defined and COFF_IMAGE_WITH_PE is not defined.
7826 2000-03-01 Nick Clifton <nickc@cygnus.com>
7828 * coff-arm.c (bfd_arm_process_before_allocation): Make
7829 'symndx' signed to prevent compile time warning.
7831 * coff-mcore.c: Remove unused prototype for pe_object_p.
7833 * coff-sh.c: Add "#ifndef COFF_IMAGE_WITH_PE" around static
7834 functions that are not used when COFF_IMAGE_WITH_PE is
7836 (struct sh_opcode): Change type of 'flags' field to unsigned
7837 long so that it can hold the USESAS flag.
7839 * coffcode.h (styp_to_sec_flags): Initialise 'target_name'.
7841 * elf-m10300.c (mn10300_elf_relax_section): Initialise
7844 * elf32-i370.c: Add ATTRIBUTE_UNUSED to unused function
7846 Remove unusued variables and code.
7847 (elf_backend_add_symbol_hook): Fix prototype.
7849 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Initialise 'sgot' and
7852 * elf32-mcore.c (mcore_elf_relocate_section): Initialise
7855 * elf32-mips.c: Add ATTRIBUTE_UNUSED to unused function
7857 Remove unusued variables and code.
7858 (elf_backend_add_symbol_hook): Fix prototype.
7860 * elf32-sh.c (sh_elf_set_mach_from_flags): Use 'flags'.
7862 * elflink.h (elf_bfd_link_add_symbols): Add ATTRIBUTE_UNUSED
7863 to unused function parameter.
7865 * pe-mips.c: Add ATTRIBUTE_UNUSED to unused function
7867 Use EMPTY_HOWTO to initialise empty howto slots.
7868 Remove unused variables.
7870 * peicode.h (pe_ILF_build_a_bfd): Initialise id6.
7872 2000-03-01 H.J. Lu <hjl@gnu.org>
7874 * aoutx.h (aout_link_input_section_std): Pass "true" to
7875 the undefined_symbol callback.
7876 (aout_link_input_section_ext): Likewise.
7877 * bout.c (get_value): Likewise.
7878 * coff-a29k.c (coff_a29k_relocate_section): Likewise.
7879 * coff-alpha.c (alpha_ecoff_get_relocated_section_conten):
7881 (alpha_relocate_section): Likewise.
7882 * coff-arm.c (coff_arm_relocate_section): Likewise.
7883 * coff-i960.c (coff_i960_relocate_section): Likewise.
7884 * coff-mcore.c (coff_mcore_relocate_section): Likewise.
7885 * coff-mips.c (mips_relocate_section): Likewise.
7886 * coff-ppc.c (coff_ppc_relocate_section): Likewise.
7887 * coff-sh.c (sh_relocate_section): Likewise.
7888 * coff-tic80.c (coff_tic80_relocate_section): Likewise.
7889 * cofflink.c (_bfd_coff_generic_relocate_section): Likewise.
7890 * elf-m10200.c (mn10200_elf_relocate_section): Likewise.
7891 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
7892 * elf32-d10v.c (elf32_d10v_relocate_section): Likewise.
7893 * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
7894 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
7895 * elf32-i370.c (i370_elf_relocate_section): Likewise.
7896 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
7897 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
7898 * elf32-sh.c (sh_elf_relocate_section): Likewise.
7899 * elf32-v850.c (v850_elf_relocate_section): Likewise.
7900 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Likewise.
7901 * elflink.h (elf_link_output_extsym): Likewise.
7902 * pe-mips.c (coff_pe_mips_relocate_section): Likewise.
7903 * reloc.c (bfd_generic_get_relocated_section_conten): Likewise.
7904 * reloc16.c (_bfd_ppc_xcoff_relocate_section): Likewise.
7906 * elf-hppa.h (elf_hppa_relocate_section): Pass "false" to the
7907 undefined_symbol callback when building shared library with
7908 -Bsymbolic and undefined symbols are allowed. Otherwise, pass
7910 * elf32-arm.h (elf32_arm_relocate_section): Likewise.
7911 * elf32-i386.c (elf_i386_relocate_section): Likewise.
7912 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
7913 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
7914 (elf32_mips_get_relocated_section_content): Likewise.
7915 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
7916 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
7917 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
7918 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
7920 2000-02-28 Nick Clifton <nickc@cygnus.com>
7922 * Makefile.am: Add rules to build pe[i]-{sh|mips}.lo objects.
7923 * Makefile.in: Regenerate.
7925 * configure.in: Add support for mips and sh pe vectors.
7926 * configure: regenerate.
7928 * config.bfd: Add support for arm-wince, mips-pe and sh-pe
7931 * targets.c: Add mips and sh pe vectors.
7933 * libpei.h (coff_final_link_postscript): Only define if not
7936 * coffcode.h: Add support for WinCE magic numbers.
7938 * peigen.c (pe_print_reloc): Update comment and rearrange
7939 appending of newline character.
7941 * peicode.h: Add support for Image Library Format.
7942 (pe_ILF_vars): Structure containing data used by ILF code.
7943 (pe_ILF_make_a_section): New function. Create a section based
7945 (pe_ILF_make_a_reloc): New function. Create a reloc based on
7947 (pe_ILF_make_a_symbol): New function. Create a symbol based
7949 (pe_ILF_save_relocs): New function. Store the relocs created
7950 by pe_ILF_make_a_reloc in a section.
7951 (pe_ILF_build_a_bfd): New function. Create a BFD describing
7953 (pe_ILF_object_p): New function. Return a bfd_target pointer
7955 (pe_bfd_object_p): If an ILF object is detected call
7956 pe_ILF_object_p on it.
7958 * coff-arm.c: Add support for WinCE relocs which are different
7959 from normal ARM COFF relocs.
7960 * pe-arm.c: Unset TARGET_UNDERSCORE for a WinCE target.
7962 * coff-sh.c: Add support for sh-pe target.
7963 * pe-sh.c: New file. Support code for sh-pe target.
7964 * pei-sh.c: New file. Support code for sh-pe target.
7966 * pe-mips.c: New file. Support code for mips-pe target.
7967 * pei-mips.c: New file. Support code for mips-pe target.
7969 2000-02-27 Jakub Jelinek <jakub@redhat.com>
7971 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data): Don't bump
7972 architecture if the object causing the bump is dynamic.
7973 * elf64-sparc.c (sparc64_elf_merge_private_bfd_data): Likewise,
7974 and also don't it for memory ordering.
7975 (sparc64_elf_write_relocs): Take src_rela out of the loop.
7977 2000-02-27 Ian Lance Taylor <ian@zembu.com>
7979 * dwarf2.c (read_abbrevs): Use _raw_size directly rather than
7980 calling bfd_get_section_size_before_reloc.
7981 (decode_line_info): Likewise.
7982 (_bfd_dwarf2_find_nearest_line): Likewise.
7984 2000-02-27 Eli Zaretskii <eliz@is.elta.co.il>
7986 * Makefile.am (stamp-lib): Use $(LIBTOOL) --config to get the
7987 name of the libtool directory.
7988 * Makefile.in: Rebuild.
7990 Fri Feb 25 18:39:26 2000 Rodney Brown (RodneyBrown@pmsc.com)
7992 * som.c (SOM_HOWTO): Define.
7993 (som_hppa_howto_table): Use it.
7995 2000-02-25 Alexandre Oliva <oliva@lsd.ic.unicamp.br>
7997 * config.bfd: Enable 64 bit support for GNU/Linux/sparc.
7999 * config.bfd: Enable 64 bit support for Solaris7+/sparc.
8001 2000-02-24 Catherine Moore <clm@cygnus.com>
8003 * som.c (som_misc_symbol_info): Add field
8005 (som_bfd_derive_misc_symbol_info): Initialize
8007 (som_build_and_write_symbol_table): Keep track
8008 of secondary_def field.
8009 (som_slurp_symbol_table): Set BSF_WEAK symbol flag
8010 if secondary_def field is set.
8011 (som_bfd_ar_write_symbol_stuff): Initialize
8014 2000-02-23 Stephane Carrez <stcarrez@worldnet.fr>
8016 * dwarf2.c (read_address): Read 16-bits addresses.
8017 (parse_comp_unit): Accept addr_size == 2.
8019 2000-02-23 Alan Modra <alan@spri.levels.unisa.edu.au>
8021 * bfd-in.h: Update copyright date.
8023 2000-02-23 Linas Vepstas <linas@linas.org>
8025 * cpu-i370.c: New file.
8026 * elf32-i370.c: New file.
8027 * archures.c (enum bfd_architecture): Add bfd_arch_i370.
8028 (bfd_i370_arch): New.
8029 (bfd_archures_list): Add bfd_i370_arch.
8030 * elf.c (prep_headers): Add bfd_arch_i370.
8031 * Makefile.am: Add support for IBM 370 elf.
8032 * config.bfd: Likewise.
8033 * configure.in: Likewise.
8034 * libbfd.h (bfd_reloc_code_real_names): Likewise.
8035 * reloc.c (bfd_reloc_code_type): Likewise.
8036 * targets.c: Likewise.
8038 * Makefile.in: Regenerate.
8039 * configure: Regenerate.
8040 * bfd-in2.h: Regenerate.
8042 2000-02-22 Ian Lance Taylor <ian@zembu.com>
8044 * elf32-i386.c (elf_i386_info_to_howto_rel): Give a warning for
8045 invalid relocation types, and change them to R_386_NONE.
8047 2000-02-22 H.J. Lu <hjl@gnu.org>
8049 * elflink.h (elf_link_add_object_symbols): If a version symbol is
8050 not defined, don't add a second ELF_VER_CHR.
8052 * elflink.h (elf_bfd_final_link): Call output_extsym for global
8053 symbols converted to local symbols even when stripping all
8055 (elf_link_output_extsym): Process global symbols converted to
8056 local symbols even if they are being stripped.
8058 2000-02-21 Alan Modra <alan@spri.levels.unisa.edu.au>
8060 * archures.c (bfd_octets_per_byte): Return unsigned int.
8061 (bfd_arch_mach_octets_per_byte): Ditto.
8062 * libbfd.c (bfd_read, bfd_seek): Quell signed vs. unsigned
8064 * section.c (bfd_get_section_size_before_reloc): Quell signed
8065 vs. unsigned comparison warning.
8066 (bfd_get_section_size_after_reloc): Same here. Fix parentheses too.
8067 * trad-core.c (trad_unix_core_file_p): Correct 2000-01-27
8068 change. What was I thinking?
8069 * bfd-in2.h: Regenerate.
8071 * elflink.h (elf_gc_sweep): Skip non-elf input bfds.
8072 (elf_gc_sections): Same here.
8073 (elf_gc_common_finalize_got_offsets): And here.
8075 2000-02-21 Ian Lance Taylor <ian@zembu.com>
8077 ELF HPPA doesn't work at present; remove it until it does.
8078 * config.bfd: Comment out setting targ_defvec to
8080 * Makefile.am: Rebuild dependencies.
8081 (BFD32_BACKENDS): Remove elf32-hppa.lo.
8082 (BFD32_BACKENDS_CFILES): Remove elf32-hppa.c.
8083 (SOURCE_HFILES): Remove elf32-hppa.h and hppa_stubs.h.
8084 * Makefile.in: Rebuild.
8085 * targets.c (bfd_target_vector): Comment out bfd_elf32_hppa_vec.
8087 2000-02-18 Geoff Keating <geoffk@cygnus.com>
8089 * coffcode.h (coff_set_arch_mach_hook): Use free(), because there
8090 is no bfd_free(). Revert bfd_free part of previous change.
8092 2000-02-18 Geoff Keating <geoffk@cygnus.com>
8094 * coffcode.h (coff_set_arch_mach_hook): Don't use variable-size
8096 (coff_compute_section_file_positions): Use bfd_free to pair
8098 (coff_write_object_contents): Likewise.
8100 * coff-rs6000.c (xcoff_howto_table_16): New variable.
8101 (xcoff_rtype2howto): Handle 16-bit variants of 32-bit relocs.
8103 2000-02-18 Ulrich Drepper <drepper@cygnus.com>
8105 * coff-rs6000.c (XCOFFARMAGBIG): New macro.
8106 (xcoff_ar_file_hdr_big): New structure.
8107 (SIZEOF_AR_FILE_HDR_BIG): New macro.
8108 (xcoff_ar_hdr_big): New structure.
8109 (SIZEOF_AR_HDR_BIG): New macro.
8110 (xcoff_big_format_p): New macro.
8111 (xcoff_ardata_big): New macro.
8112 (arch_xhdr_big): New macro.
8113 (xcoff_slurp_armap): Handle large archives.
8114 (xcoff_archive_p): Detect large archives.
8115 (xcoff_read_ar_hdr): Handle large archives.
8116 (xcoff_openr_next_archived_file): Handle large archives.
8117 (xcoff_generic_stat_arch_elt): Handle large archives.
8118 (xcoff_write_armap_old): Rename from xcoff_write_armap.
8119 (xcoff_write_armap_big): New function.
8120 (xcoff_write_armap): New function, dispatch to _old or _big.
8121 (xcoff_write_archive_contents_old): Rename from
8122 xcoff_write_archive_contents.
8123 (xcoff_write_archive_contents_big): New function.
8124 (xcoff_write_archive_contents): New function, dispatch to _old or
8127 2000-02-18 Richard Henderson <rth@cygnus.com>
8129 * elf-bfd.h (struct elf_link_hash_table): Remove copy_indirect
8130 and hide_symbol members.
8131 (elf_link_hash_copy_indirect): Remove.
8132 (elf_link_hash_hide_symbol): Remove.
8133 (struct elf_backend_data): Add elf_backend_copy_indirect_symbol
8134 and elf_backend_hide_symbol.
8135 (_bfd_elf_link_hash_copy_indirect): Declare.
8136 (_bfd_elf_link_hash_hide_symbol): Declare.
8137 * elf.c (_bfd_elf_link_hash_copy_indirect): Remove table argument.
8138 (_bfd_elf_link_hash_hide_symbol): Likewise.
8139 (_bfd_elf_link_hash_table_init): Don't init killed members.
8140 * elflink.h (elf_link_add_object_symbols): Use the bed function
8141 pointers not elf_link_hash_{copy_indirect,hide_symbol}.
8142 (elf_link_assign_sym_version): Likewise.
8143 * elfxx-target.h (elf_backend_copy_indirect_symbol): Default.
8144 (elf_backend_hide_symbol): Likewise.
8145 (elfNN_bed): Update for new members.
8147 2000-02-17 Kevin Buettner <kevinb@redhat.com>
8149 * rs6000-core.c (CORE_DATA_SIZE_FIELD, CORE_COMM_FIELD, SAVE_FIELD,
8150 STACK_END_ADDR): Define for new core file format.
8151 (LOADER_OFFSET_FIELD, LOADER_REGION_SIZE, CORE_DUMP): New defines
8152 for handling the vagaries of the various core file structures used
8153 by AIX over the years.
8154 (rs6000coff_core_p, rs6000coff_core_file_matches_executable,
8155 Rs6kCorData): Use above defines to adapt code to use AIX 4.3's
8156 core_dumpx structure.
8158 Thu Feb 17 00:04:48 2000 J"orn Rennecke <amylaar@cygnus.co.uk>
8160 * archures.c (bfd_mach_sh2, bfd_mach_sh_dsp): New macros.
8161 (bfd_mach_sh3_dsp): Likewise.
8162 (bfd_mach_sh4): Reinstate.
8163 (bfd_default_scan): Recognize 7410, 7708, 7729 and 7750.
8164 * bfd-in2.h: Regenerate.
8165 * coff-sh.c (struct sh_opcode): flags is no longer short.
8166 (USESAS, USESAS_REG, USESR8, SETSAS, SETSAS_REG): New macros.
8167 (sh_opcode41, sh_opcode42): Integrate as sh_opcode41.
8168 (sh_opcode01, sh_opcode02, sh_opcode40): Add sh-dsp opcodes.
8169 (sh_opcode41, sh_opcode4, sh_opcode80): Likewise.
8170 (sh_opcodes): No longer const.
8171 (sh_dsp_opcodef0, sh_dsp_opcodef): New arrays.
8172 (sh_insn_uses_reg): Check for USESAS and USESR8.
8173 (sh_insn_sets_reg, sh_insns_conflict): Check for SETSAS.
8174 (_bfd_sh_align_load_span): Return early for SH4.
8175 Modify sh_opcodes lookup table for sh-dsp / sh3-dsp.
8176 Take into account that field b of a parallel processing insn
8177 could be mistaken for a separate insn.
8178 * cpu-sh.c (arch_info_struct): New array elements for
8179 sh2, sh-dsp and sh3-dsp.
8180 Reinstate element for sh4.
8181 (SH2_NEXT, SH_DSP_NEXT, SH3_DSP_NEXT): New macros.
8182 (SH4_NEXT): Reinstate.
8183 (SH3_NEXT, SH3E_NEXT): Adjust.
8184 * elf-bfd.h (_sh_elf_set_mach_from_flags): Declare.
8185 * elf32-sh.c (sh_elf_set_private_flags): New function.
8186 (sh_elf_copy_private_data, sh_elf_set_mach_from_flags): Likewise.
8187 (sh_elf_merge_private_data): New function.
8188 (elf_backend_object_p, bfd_elf32_bfd_set_private_bfd_flags): Define.
8189 (bfd_elf32_bfd_copy_private_bfd_data): Define.
8190 (bfd_elf32_bfd_merge_private_bfd_data): Change to
8191 sh_elf_merge_private_data.
8193 2000-02-13 Richard Henderson <rth@cygnus.com>
8195 * elf-bfd.h (struct elf_link_hash_table): Add copy_indirect and
8196 hide_symbol members.
8197 (elf_link_hash_copy_indirect): New.
8198 (elf_link_hash_hide_symbol): New.
8199 * elflink.h (elf_link_add_object_symbols): Break out copy from
8200 indirect new new symbol to elf.c.
8201 (elf_link_assign_sym_version): Break out privatization of
8202 non-exported symbol to elf.c.
8203 * elf.c (_bfd_elf_link_hash_copy_indirect): New.
8204 (_bfd_elf_link_hash_hide_symbol): New.
8205 (_bfd_elf_link_hash_table_init): Init copy_indirect and hide_symbol.
8207 2000-02-13 Ian Lance Taylor <ian@zembu.com>
8209 * section.c (_bfd_strip_section_from_output): Add info parameter.
8210 If it passed as non-NULL, use it to check whether any input BFD
8211 has an input section which uses this output section. Change all
8213 * bfd-in2.h: Rebuild.
8215 * bfd-in.h: Move declarations of bfd_get_elf_phdr_upper_bound and
8216 bfd_get_elf_phdrs in from bfd-in2.h, correcting patch of
8218 * bfd-in2.h: Rebuild.
8220 2000-02-10 Timothy Wall <twall@cygnus.com>
8222 * coffswap.h (coff_swap_sym_in): Add hook SWAP_SYM_IN_POST to
8223 allow final modifications of swapped-in symbol.
8224 (coff_swap_sym_out): Ditto with SWAP_SYM_OUT_POST.
8225 * coffcode.h (coff_write_relocs): Use macro
8226 SECTION_RELATIVE_ABSOLUTE_SYMBOL_P if defined to determine whether
8227 symbol index should be set to -1.
8229 Thu Feb 10 20:07:50 GMT 2000 Toshiyasu Morita (toshi.morita@sega.com)
8231 * coff-sh.c (USES1_REG, USES2_REG, SETS1_REG, SETS2_REG,
8232 USESF1_REG, USESF2_REG, SETSF1_REG, SETSF2_REG): New macros.
8233 * (sh_insn_sets_reg, sh_insn_sets_freg): New prototypes.
8234 * (sh_insn_sets_reg, sh_insn_uses_or_sets_reg, sh_insns_sets_freg,
8235 sh_insns_uses_or_sets_freg): New functions.
8236 * (sh_insn_uses_reg, sh_insn_uses_freg): Use new macros.
8237 * (sh_insns_conflict): Use new functions and new macros to
8238 detect conflicts when two instructions both set same integer registers,
8239 both set same fp register, and both set special register.
8241 2000-02-09 Timothy Wall <twall@cygnus.com>
8243 * coffgen.c (coff_real_object_p): Set arch/mach info prior to
8244 swapping in sections, so that the swapping routines have access to
8247 2000-02-08 Mark Elbrecht <snowball3@bigfoot.com>
8249 * coff-go32.c: Update comment. Update copyright.
8251 2000-01-27 Thomas de Lellis <tdel@windriver.com>
8253 * syms.c (bfd_decode_symclass)
8254 Two new class characters were added - 'V' and 'v'. The
8255 meaning of 'W' is now restricted to just weak non-object
8256 symbols. This allows differentiation between, for example,
8257 weak functions vs weak objects. nm for example now dumps:
8259 'w' = weak unresolved
8260 'V' = weak global object
8261 'v' = weak unresolved object
8263 (bfd_is_undefined_symclass): New function. Return true if the
8264 given symbol class represents and undefined/unresolved symbol.
8266 (bfd_symbol_info): Use bfd_is_undefined_symclass to check for
8269 * bfd-in2.h: Add prototype for bfd_is_undefined_symbol().
8271 * elf32-arm.h (elf32_arm_get_symbol_type): If a symbol has the
8272 STT_ARM_16BIT flag set, but it is not attached to a data object
8273 return STT_ARM_16BIT so that it will be treated as code by the
8276 2000-01-27 Alan Modra <alan@spri.levels.unisa.edu.au>
8278 * coff-i386.c (i3coff_object_p): Remove prototype.
8281 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Add const
8282 to name. Update copyright.
8284 * trad-core.c (trad_unix_core_file_p): Cast core_regsec
8285 assignment to avoid warning. Update copyright.
8287 2000-01-24 Robert Lipe (robertl@sco.com)
8289 * coffcode.h (coff_write_object_contents): Get buff via bfd_malloc
8290 instead of using GNU C extension.
8292 2000-01-21 Nick Clifton <nickc@cygnus.com>
8294 * libbfd.c (bfd_read): Do not attempt to get a negativly sized
8295 amount from a bfd_in_memory structure.
8296 (bfd_seek): Do not allow seeks past the end of a bfd_in_memory
8299 2000-01-14 Nick Clifton <nickc@cygnus.com>
8301 * linker.c (default_indirect_link_order): oops - fix incorrectly
8302 applied patch from Tim Wall.
8304 2000-01-13 Timothy Wall (twall@tiac.net>
8306 * coffcode.h: Use bfd_coff_xxx instead of the macro XXX (where xxx
8307 = scnhsz, filhsz, relsz, aoutsz, etc)
8309 * coffswap.h: Ditto.
8311 2000-01-13 Nick Clifton <nickc@cygnus.com>
8313 * elf32-arm.h (elf32_thumb_to_arm_stub): Fix offset in branch to
8314 interwork thumb to arm stub.
8316 2000-01-13 Timothy Wall (twall@tiac.net>
8318 * archures.c (bfd_octets_per_byte): New function: Return
8320 (bfd_arch_mach_octets_per_byte): New function: Return target
8323 * section.c: Distinguish between octets and bytes for usage of
8324 _cooked_size, _raw_size, and output_offset. Clarify
8325 description of bfd_set_section_contents.
8327 * bfd-in2.h: Regenerate.
8329 * coffgen.c: Indicate that the offset parameter is in bytes, not
8332 * cofflink.c (bfd_coff_link_input_bfd): Use bfd_octets_per_byte
8333 where appropriate to get the octet offset when calling
8334 bfd_set_section_contents.
8335 (bfd_coff_reloc_link_order): Ditto.
8337 * linker.c (bfd_generic_reloc_link_order): Ditto.
8338 (_bfd_default_link_order): Ditto.
8340 * reloc.c (bfd_perform_relocation): Distinguish between octets
8341 and bytes. Use octets when indexing into octet data; use bytes
8342 when calculating target addresses.
8343 (bfd_install_relocation): Ditto.
8345 * srec.c (srec_write_section): Ditto.
8347 2000-01-13 Nick Clifton <nickc@cygnus.com>
8349 * coff-mcore.c (COFF_DEFAULT_SECTION_ALIGNMENT_POWER): Change from
8350 3 to 2. This allows 4 byte sized sections, which is necessary for
8351 dlltool to build functioning DLLs.
8353 2000-01-10 Philip Blundell <pb@futuretv.com>
8355 * config.bfd (arm*-*-linux-gnu*): Match instead of arm*-*-linux-gnu.
8356 (arm*-*-conix*): New target.
8358 2000-01-10 Egor Duda <deo@logos-m.ru>
8360 * config.bfd: Include elf32_i386 vector to target list for cygwin
8363 * config.in: Undefine HAVE_WIN32_PSTATUS_T.
8364 * configure.in: Test for structure win32_pstatus_t in
8366 * configure: Regenerate.
8368 * elf.c (elfcore_grok_win32pstatus): New function: process
8369 win32_pstatus_t notes in elf core file.
8370 (elfcore_grok_note): Detect win32_pstatus notes.
8372 2000-01-03 Martin v. Loewis <loewis@informatik.hu-berlin.de>
8374 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Process symbol
8376 * elflink.h (elf_link_add_object_symbols): Combine visibilities.
8377 * elf.c (bfd_elf_print_symbol): Interpret st_other as visibility.
8379 For older changes see ChangeLog-9899
8385 version-control: never