1 2001-11-01 Alan Modra <amodra@bigpond.net.au>
3 * elf64-ppc.c (ppc64_elf_relocate_section): Correct branch
6 2001-10-31 Chris Demetriou <cgd@demetriou.com>
8 * elf32-mips.c (_bfd_mips_elf_hi16_reloc): Handle PC-relative
11 2001-10-31 H.J. Lu <hjl@gnu.org>
13 * elflink.h (elf_link_output_extsym): Don't clear the visibility
14 field for relocateable.
16 2001-11-01 Alan Modra <amodra@bigpond.net.au>
18 * elf32-hppa.c (elf32_hppa_finish_dynamic_sections): Don't count
19 .plt relocs in DT_RELASZ.
21 2001-10-29 NIIBE Yutaka <gniibe@m17n.org>
23 * config.bfd: Supports sh3/sh4/sh3eb/sh4eb-unknown-linux-gnu
26 2001-10-31 Nick Clifton <nickc@cambridge.redhat.com>
28 * targets.c: Fix typo: bfd_mmo_mmix_vec => bfd_mmo_vec.
30 2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
32 * Makefile.am (ALL_MACHINES): Add cpu-mmix.lo.
33 (BFD64_BACKENDS): Add elf64-mmix.lo and mmo.lo.
34 (BFD64_BACKENDS_CFILES): Add elf64-mmix.c and mmo.c.
35 Regenerate dependencies.
36 * configure.in (bfd_elf64_mmix_vec, bfd_mmo_vec): New vectors.
37 * config.bfd: [BFD64] (mmix-*-*): New case.
38 * cpu-mmix.c, mmo.c, elf64-mmix.c: New files.
39 * archures.c (enum bfd_architecture): Add bfd_arch_mmix.
40 (bfd_mmix_arch): Declare.
41 (bfd_archures_list): Add bfd_mmix_arch.
42 * targets.c (enum bfd_flavour): Add bfd_target_mmo_flavour.
43 (bfd_elf64_mmix_vec, bfd_mmo_vec): Declare.
44 (bfd_target_vect) [BFD64]: Add bfd_elf64_mmix_vec and
46 * reloc.c: Add MMIX relocations.
47 * bfd.c (struct _bfd, tdata): Add mmo_data.
48 * Makefile.in: Regenerate.
49 * configure: Regenerate.
50 * libbfd.h: Regenerate.
51 * bfd-in2.h: Regenerate.
54 2001-10-30 Richard Earnshaw (rearnsha@arm.com)
56 * elf.c (_bfd_elf_make_section_from_shdr): Set the LMA based on the
57 p_paddr of the segment that contains it.
58 (copy_private_bfd_data): If the LMA for a segment is known, use it
59 for matching sections to segments.
60 (assign_file_positions_for_segments): Use the LMA when adjusting
61 for inter-section alignment padding.
63 2001-10-29 Kazu Hirata <kazu@hxi.com>
67 2001-10-24 Richard Henderson <rth@redhat.com>
69 * peXXigen.c (_bfd_XX_print_private_bfd_data_common): Copy
70 timestamp to time_t for ctime.
72 2001-10-24 Hans-Peter Nilsson <hp@axis.com>
74 * elf32-cris.c (cris_reloc_type_lookup): Change loop to use
75 unsigned, increasing index.
77 2001-10-23 H.J. Lu <hjl@gnu.org>
79 * elf32-mips.c (_bfd_mips_elf_modify_segment_map): Check
80 m != NULL before accessing it.
82 2001-10-23 Alan Modra <amodra@bigpond.net.au>
84 * elflink.h (elf_link_input_bfd): Zero the reloc instead of doing
85 bfd_reloc_type_lookup (bfd, BFD_RELOC_NONE) as bfd_reloc_type_lookup
86 doesn't accept BFD_RELOC_* on some targets, eg. hppa.
88 * elf32-hppa.c (elf32_hppa_link_hash_entry): Remove plt_abs.
89 (hppa_link_hash_newfunc): Likewise.
90 (elf32_hppa_finish_dynamic_symbol): Likewise.
91 (allocate_dynrelocs): Always allocate .got relocs if shared.
92 (elf32_hppa_relocate_section): Output them too. Similarly
93 consolidate .plt reloc code, and no longer initialise .plt
94 when a reloc is output.
95 (elf32_hppa_finish_dynamic_symbol): Only initialise .plt entries
96 when no reloc is output.
98 From Herbert Xu <herbert@gondor.apana.org.au>
99 * elf32-hppa.c (final_link_relocate): Call bfd_set_error for
100 unreachable branches.
102 2001-10-22 H.J. Lu <hjl@gnu.org>
104 * configure.in (WIN32LIBADD): Use -L../libiberty for
106 * configure: Rebuild.
108 2001-10-21 H.J. Lu <hjl@gnu.org>
110 * configure.in (WIN32LIBADD): Include -L../libiberty/pic -liberty
111 if shared library is enabled only for Linux hosts.
112 * configure: Rebuild.
114 2001-10-21 H.J. Lu <hjl@gnu.org>
116 * configure.in (WIN32LIBADD): Check if PICFLAG is defined in
117 ../libiberty/Makefile instead of $enable_shared.
118 * configure: Rebuild.
120 2001-10-21 H.J. Lu <hjl@gnu.org>
122 * elf32-cris.c (cris_reloc_type_lookup): Use int for index. Cover
125 2001-10-20 H.J. Lu <hjl@gnu.org>
127 * configure.in (WIN32LIBADD): Include -L../libiberty/pic -liberty
128 if shared library is enabled.
129 * configure: Rebuild.
131 2001-10-20 H.J. Lu <hjl@gnu.org>
133 * elf32-cris.c (cris_reloc_type_lookup): Allow index 0.
135 2001-10-19 H.J. Lu <hjl@gnu.org>
137 * elfcode.h (elf_object_p): Don't clear D_PAGED if the section
140 2001-10-18 H.J. Lu <hjl@gnu.org>
142 * elf32-i370.c (i370_elf_relocate_section): Ignore R_XXX_NONE.
143 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
145 2001-10-18 Jakub Jelinek <jakub@redhat.com>
147 * section.c (_bfd_strip_section_from_output): Don't count
148 SEC_EXCLUDE sections as references. Set SEC_EXCLUDE.
150 2001-10-17 Alan Modra <amodra@bigpond.net.au>
152 * elf-m10200.c (mn10200_elf_relax_section): Cast assignment to
153 Elf_Internal_Shdr.contents now that it's no longer a PTR.
154 * elf-m10300.c (mn10300_elf_relax_section): Likewise.
155 * elf32-h8300.c (elf32_h8_relax_section): Likewise.
156 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Likewise.
157 * elf32-sh.c (sh_elf_relax_section): Likewise.
158 * elf64-alpha.c (elf64_alpha_relax_section): Likewise.
159 * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
160 * elf.c (setup_group): Warning fixes.
161 * elflink.h (elf_link_sort_relocs): Likewise.
162 * pdp11.c (slurp_reloc_table): Likewise.
164 2001-10-16 Jeff Holcomb <jeffh@redhat.com>
166 * elflink.h (elf_link_sort_relocs): Remove unnecessary pointer
169 2001-10-15 H.J. Lu <hjl@gnu.org>
171 * elflink.h (elf_link_input_bfd): Set type to BFD_RELOC_NONE
172 for relocations against discarded link-once section.
174 2001-10-15 Alan Modra <amodra@bigpond.net.au>
176 * elf32-i386.c (elf_i386_relocate_section): Report some detail on
177 bfd_reloc_outofrange and similar errors.
179 * elf.c (_bfd_elf_link_hash_copy_indirect): Test ind->root.type
180 rather than ind->weakdef.
181 * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Likewise.
182 * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
183 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Likewise.
184 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
185 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
187 2001-10-15 Alan Modra <amodra@bigpond.net.au>
188 H.J. Lu <hjl@gnu.org>
190 * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Merge dyn_reloc
191 counts for aliases instead of aborting.
192 * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
193 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
195 * elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Set plt.offset
196 to -1 for non-function symbols.
197 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Likewise.
198 * elf32-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
199 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
200 * elf64-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
201 * elf64-x86-64.c (elf64_x86_64_adjust_dynamic_symbol): Likewise.
202 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Refer to
203 plt.offset instead of plt.refcount when setting to -1.
205 2001-10-12 Nick Clifton <nickc@cambridge.redhat.com>
207 * elf32-arm.h (elf32_arm_relocate_section): Treat R_ARM_THM_PC22
208 like R_ARM_PC24. Include reloc number in error message about
211 2001-10-10 Jakub Jelinek <jakub@redhat.com>
213 * elflink.h (elf_link_sort_cmp2): Don't mix PLT and non-PLT
214 relocations against the same symbol in .rel{,a}.dyn section.
216 2001-10-10 Kazu Hirata <kazu@hxi.com>
218 * aout-encap.c: Fix comment typos.
220 * archive.c: Likewise.
222 * coff64-rs6000.c: Likewise.
223 * coffcode.h: Likewise.
224 * coffgen.c: Likewise.
225 * cofflink.c: Likewise.
226 * coff-mips.c: Likewise.
228 * elf32-m32r.c: Likewise.
229 * libcoff-in.h: Likewise.
230 * libecoff.h: Likewise.
231 * libxcoff.h: Likewise.
232 * nlm32-i386.c: Likewise.
234 * section.c: Likewise.
237 * bfd-in2.h: Regenerate.
238 * libcoff.h: Likewise.
240 2001-10-10 Alan Modra <amodra@bigpond.net.au>
242 * elf.c (elf_map_symbols): Don't create new section symbols; Use
243 existing section syms. Update comments.
244 (copy_private_bfd_data): Formatting fixes.
245 (elfcore_grok_win32pstatus): Likewise.
246 (swap_out_syms): Likewise. Remove unnecessary level of braces.
248 2001-10-09 Alan Modra <amodra@bigpond.net.au>
250 * elf-bfd.h (struct bfd_elf_section_data): Rename "group" to
252 (elf_group_name): Define.
253 (elf_next_in_group): Define.
254 * elf.c: Make use of elf_group_name and elf_next_in_group throughout.
255 (setup_group): Don't use sec->lineno for SHT_GROUP section to store
256 first member section; Instead use elf_next_in_group.
257 (bfd_section_from_shdr): Likewise.
258 (set_group_contents): Likewise. Use elf_section_syms, not sec->symbol.
260 2001-10-09 Alan Modra <amodra@bigpond.net.au>
262 * elf-bfd.h (struct bfd_elf_section_data): Add "group" and
263 "next_in_group". Fix gp and gp_size comments.
264 * elf.c (union elf_internal_group): New.
265 (setup_group): New function.
266 (_bfd_elf_make_section_from_shdr): Set BFD flags for SHT_GROUP.
267 Call setup_group for SHF_GROUP sections.
268 (bfd_section_from_shdr): Build a BFD section for SHT_GROUP.
269 (elf_fake_sections): Set header type for SEC_GROUP, and header
270 flags for sections in a group.
271 (set_group_contents): New function.
272 (_bfd_elf_compute_section_file_positions): Call it.
273 (assign_section_numbers): Set sh_link for SHT_GROUP.
275 * elflink.h (gc_mark_hook): Handle section groups.
276 * elfxx-target.h: Add SEC_GROUP to applicable_flags.
277 * section.c (SEC_GROUP): Define.
278 (struct sec): Comment fixes.
279 * bfd-in2.h: Regenerate.
281 * elf.c (bfd_elf_print_symbol): Formatting fix; migrate expression
282 out of function args.
283 (_bfd_elf_canonicalize_reloc): Similarly.
284 (_bfd_elf_get_symtab): Here too.
285 (_bfd_elf_canonicalize_dynamic_symtab): And here.
286 * elfcode.h (elf_slurp_symbol_table): Don't recalculate size for
287 bfd_bread, and remove unnecessary cast.
289 2001-10-08 Aldy Hernandez <aldyh@redhat.com>
291 * bfd/config.bfd (targ_cpu): Add arm9e-*-elf.
293 2001-10-06 Stephane Carrez <Stephane.Carrez@worldnet.fr>
295 * dwarf2.c (comp_unit_find_nearest_line): Check for end of
298 2001-10-06 Alan Modra <amodra@bigpond.net.au>
300 * bfd.c (bfd_assert): Report bfd version.
301 (_bfd_abort): Likewise.
303 * elflink.h (elf_link_input_bfd): Don't zero discarded link-once
304 section sym values. Instead replace any relocs against them with
305 relocs against STN_UNDEF, which has a zero value.
307 * elf32-arc.c (elf_arc_howto_table): Set partial_inplace for all
310 2001-10-05 Jeff Law <law@redhat.com>
312 * som.h (som_exec_data): New field "version_id".
313 * som.c (som_object_setup): Record the version_id if it
315 (som_prep_headers): Do not initialize version_id here.
316 (som_finish_writing): Initialize version_id here.
318 2000-10-05 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
320 * elf32-mips.c (elf_mips_howto_table): Fix some relocation howtos
321 according to the MIPS/SGI ELF64 ABI Draft.
322 (mips_elf_sort_hash_table): Typo.
324 2001-10-04 Alan Modra <amodra@bigpond.net.au>
326 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Comment typo.
328 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Bail out after
329 copying flags if this is a weakdef.
331 2001-10-04 Alan Modra <amodra@bigpond.net.au>
333 * elf-bfd.h (struct elf_link_hash_entry): Reorganise for better
336 * elf32-mips.c (mips_elf_record_global_got_symbol): Set got.offset
337 to 1 rather than 0 to avoid confusing copy_indirect_symbol.
338 (mips_elf_sort_hash_table_f): Compare got.offset against 1.
340 * Makefile.am (BFD_H_DEPS): Add symcat.h. Ensure everything
341 depends on $(BFD_H) $(BFD_H_DEPS) $(LOCAL_H_DEPS), not just those
342 backends we configure. Run "make dep-am".
343 (install-data-local): Install symcat.h.
344 * dep-in.sed: Remove symcat.h from dependencies.
345 * Makefile.in: Regenerate.
347 2001-10-03 Vassili Karpov <malc@pulsesoft.com>
349 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Handle nocopyreloc.
351 2001-10-03 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
353 * elf64-mips.c (elf_backend_may_use_rela_p): New define.
354 (elf_backend_default_use_rela_p): New define.
356 2001-10-03 Alan Modra <amodra@bigpond.net.au>
358 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Fix typos in last
361 * configure.in (AC_OUTPUT <bfd-in3.h>): Remove version.h.
362 * configure: Regenerate.
363 * Makefile.am (BFD_H_FILES): Add version.h.
364 * Makefile.in: Regenerate.
365 * po/SRC-POTFILES.in: Regenerate.
367 * elflink.h (elf_fix_symbol_flags): Copy flags to weakdef using
368 elf_backend_copy_indirect_symbol so that backend has a chance to
369 copy other necessary fields.
370 * elf-bfd.h (struct elf_backend_data): Update description of
371 elf_backend_copy_indirect_symbol.
372 * elf.c (_bfd_elf_link_hash_copy_indirect): Bail out after
373 copying flags if this is a weakdef.
374 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
375 (elfNN_ia64_aix_add_symbol_hook): Use elf_link_hash_lookup rather
376 than bfd_link_hash_lookup.
377 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Don't do copy
378 reloc processing for weakdefs.
379 * elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Likewise.
380 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
382 2001-10-02 Alan Modra <amodra@bigpond.net.au>
384 * elf64-ppc.c (ppc64_elf_check_relocs): Use a local var and cast
385 result of ELF64_R_TYPE to enum before using in a switch.
386 (ppc64_elf_gc_mark_hook): Likewise.
387 (ppc64_elf_gc_sweep_hook): Likewise.
388 (ppc64_elf_reloc_type_class): Likewise.
390 2001-10-02 Alan Modra <amodra@bigpond.net.au>
392 * version.h: New file.
393 * bfd-in.h: (BFD_VERSION): Substitute bfd_version.
394 (BFD_VERSION_DATE): Define.
395 (BFD_VERSION_STRING): Define.
396 * configure.in: AC_SUBST bfd_version, bfd_version_date and
398 (AC_OUTPUT <bfd-in3.h>): Depend on version.h.
399 * bfd-in2.h: Regenerate.
400 * configure: Regenerate.
401 * Makefile.am: Run "make dep-am".
402 * Makefile.in: Regenerate.
404 * bfd-in.h: Include "symcat.h".
405 (CONCAT4): Redefine as for old CAT4.
406 * aout-arm.c: Use equivalent CONCAT* macro in place of CAT* macros.
407 Add warning regarding whitespace.
408 * aout-cris.c: Likewise.
409 * aout-ns32k.c: Likewise.
410 * aout-sparcle.c: Likewise.
411 * aout-tic30.c: Likewise.
413 * armnetbsd.c: Likewise.
414 * demo64.c: Likewise.
415 * elf-bfd.h: Likewise.
416 * gen-aout.c: Likewise.
417 * host-aout.c: Likewise.
418 * hp300bsd.c: Likewise.
419 * hp300hpux.c: Likewise.
420 * i386aout.c: Likewise.
421 * i386bsd.c: Likewise.
422 * i386dynix.c: Likewise.
423 * i386freebsd.c: Likewise.
424 * i386linux.c: Likewise.
425 * i386lynx.c: Likewise.
426 * i386mach3.c: Likewise.
427 * i386netbsd.c: Likewise.
428 * libaout.h: Likewise.
429 * m68k4knetbsd.c: Likewise.
430 * m68klinux.c: Likewise.
431 * m68klynx.c: Likewise.
432 * m68knetbsd.c: Likewise.
433 * m88kmach3.c: Likewise.
434 * mipsbsd.c: Likewise.
435 * newsos3.c: Likewise.
436 * ns32knetbsd.c: Likewise.
437 * pc532-mach.c: Likewise.
439 * riscix.c: Likewise.
440 * sparclinux.c: Likewise.
441 * sparclynx.c: Likewise.
442 * sparcnetbsd.c: Likewise.
444 * targets.c: Likewise.
445 * vaxnetbsd.c: Likewise.
446 * vms-hdr.c: Likewise.
448 2001-10-01 Alan Modra <amodra@bigpond.net.au>
450 * bfd-in.h: Remove comments regarding generated files.
451 * libbfd-in.h: Likewise.
452 * libcoff-in.h: Likewise.
453 * bfd-in2.h: Regenerate.
454 * libbfd.h: Likewise.
455 * libcoff.h: Likewise.
457 2001-09-30 kaz Kojima <kkojima@rr.iij4u.or.jp>
458 Hans-Peter Nilsson <hp@bitrange.com>
460 * elf32-sh.c (sh_elf_howto_table, R_SH_REL32): Make
461 partial_inplace, matching assembler output. Set src_mask to
463 (sh_elf_relocate_section): Delete misplaced comment.
464 For relocatable linking against section symbol, call
465 _bfd_relocate_contents for partial_inplace relocs and adjust
466 rel->r_addend for others.
467 <case R_SH_DIR32, R_SH_REL32>: Fetch partial_inplace addend with
468 bfd_get_32, not at rel->r_addend.
470 2001-09-30 Alan Modra <amodra@bigpond.net.au>
472 * elf.c (_bfd_elf_link_hash_copy_indirect): Set ind refcounts to
473 the old dir refcount, so we indirectly set them to init_refcount.
474 Short-circuit asserts when we've just verified they are true.
476 2001-09-29 Alan Modra <amodra@bigpond.net.au>
478 * section.c (struct sec): Remove kept_section.
479 (STD_SECTION): Remove kept_section initialisation.
480 (bfd_make_section_anyway): Here too.
481 * ecoff.c (bfd_debug_section): Remove kept_section initialisation.
482 * cofflink.c (_bfd_coff_link_input_bfd): Don't test kept_section.
483 * elflink.h (elf_link_input_bfd): Set discarded link-once section
484 symbols to zero, and remove all code involved with kept_section
485 and tracking section symbol values.
486 * bfd-in2.h: Regenerate.
487 * configure.in: Bump version number.
488 * configure: Regenerate.
490 2001-09-29 Alan Modra <amodra@bigpond.net.au>
492 * elf64-ppc.c (struct ppc_dyn_relocs): New.
493 (IS_ABSOLUTE_RELOC): Define.
494 (struct ppc_link_hash_entry): New.
495 (struct ppc_link_hash_table): New.
496 (ppc_hash_table): Define.
497 (link_hash_newfunc): New function.
498 (ppc64_elf_link_hash_table_create): New function.
499 (create_got_section): New function.
500 (ppc64_elf_create_dynamic_sections): Call create_got_section. Stash
501 pointers to our dynamic sections in hash table.
502 (ppc64_elf_copy_indirect_symbol): New function.
503 (ppc64_elf_check_relocs): Remove DEBUG code. Use short-cuts to
504 dynamic sections. Localise vars. Modify code for refcounts
505 starting from zero. Don't allocate here, or force symbols dynamic.
506 Don't copy all relocs if shared, select ones we need. Add code
507 to track possible copy relocs for non-shared link.
508 (ppc64_elf_gc_mark_hook): Update comment.
509 (ppc64_elf_gc_sweep_hook): Sweep dynrelocs too.
510 (ppc64_elf_adjust_dynamic_symbol): Remove DEBUG code. Rewrite .plt
511 code for reference counting garbage collection. Don't create .plt
512 entries for functions that don't comply with ABI naming convention,
513 and don't allocate .plt space here. Use short-cuts to dynamic
514 sections. If possible, keep dynamic relocations instead of using
515 copy relocs. Remove confused comments.
516 (ppc_adjust_dynindx): Delete.
517 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
518 (allocate_dynrelocs): New function.
519 (readonly_dynrelocs): New function.
520 (ppc64_elf_size_dynamic_sections): Rewrite. Allocate local .got
521 space here, and call allocate_dynrelocs to allocate space for
522 global .plt, .got and reloc sections. Use short-cuts to dynamic
523 sections. Call readonly_dynrelocs to determine whether we need
524 DT_TEXTREL. Don't generate section symbols here, the generic
525 ELF linker code does it for us.
526 (ppc64_elf_final_link): Call regular ELF backend linker rather than
527 gc variety, since we do our own .got handling.
528 (ppc64_elf_relocate_section): Remove DEBUG code. Make use of
529 dynamic section short-cuts. Localise vars, and delay setting.
530 Handle unknown relocs in main switch statement. Replace ugly
531 complicated tests for unresolvable relocs with a simple direct
532 scheme using "unresolved_reloc" var. Test ELF_ST_VISIBILITY
533 before allowing an undefined sym in a shared lib. Do R_*_DS tests
534 after main switch, when we've set addend. Do non-addend insn
535 tweaks before main swithc. Ignore input_section->vma when
536 calculating reloc offsets as it's always zero. Rewrite dynamic
537 reloc handling. Consolidate R_*_HA handling. Handle more relocs.
538 (ppc64_elf_finish_dynamic_symbol): Remove DEBUG code. Make use
539 of dynamic section short-cuts. Reorganise .plt handling code.
540 Remove confused comments. Take note of ELF_LINK_FORCED_LOCAL.
541 Move expressions out of swap_reloca_out function calls.
542 (ppc64_elf_reloc_type_class): New function.
543 (ppc64_elf_info_to_howto): Move common expression to local var.
544 (ppc64_elf_finish_dynamic_sections): Remove DEBUG code. Make use
545 of dynamic section short-cuts. Don't fiddle with section syms
546 here as the ELF linker does it for us.
547 (elf_backend_can_refcount): Define.
548 (bfd_elf64_bfd_link_hash_table_create): Define.
549 (elf_backend_copy_indirect_symbol): Define.
550 (elf_backend_reloc_type_class): Define.
551 (elf_backend_*, bfd_elf64_bfd_* defines): Sort.
553 2001-09-29 Alan Modra <amodra@bigpond.net.au>
555 * elf-bfd.h (struct elf_link_local_dynamic_entry): Add init_refcount.
556 (struct elf_backend_data): Add can_refcount.
557 * elf.c (_bfd_elf_link_hash_newfunc): Get rid of a few casts. Set
558 got.refcount and plt.refcount from init_refcount.
559 (_bfd_elf_link_hash_table_init): Set up init_refcount.
560 (_bfd_elf_link_hash_copy_indirect): Reference got/plt.refcount
561 rather than got/plt.offset, and test for <= 0 rather than -1.
562 * elflink.h (size_dynamic_sections): Set init_refcount to -1.
563 * elfxx-target.h (elf_backend_can_refcount): Define.
564 (elfNN_bed): Init can_refcount.
565 * linker.c (_bfd_link_hash_newfunc): Get rid of a few casts.
566 (_bfd_generic_link_hash_newfunc): Likewise.
567 * elf32-cris.c (cris_elf_check_relocs): Modify for refcounts
569 (elf_backend_can_refcount): Define.
570 * elf32-hppa.c (elf32_hppa_check_relocs): Modify for refcounts
572 (elf32_hppa_copy_indirect_symbol): Make static to agree with
574 (elf_backend_can_refcount): Define.
575 * elf32-i386.c (elf_i386_check_relocs): Modify for refcounts
577 (allocate_dynrelocs): Set plt/got.offset rather than *.refcount.
578 (elf_i386_finish_dynamic_symbol): Expand SHN_UNDEF comment.
579 (elf_i386_finish_dynamic_sections): Use local var so line < 80 chars.
580 (elf_backend_can_refcount): Define.
581 (elf_i386_copy_indirect_symbol): Make static to agree with
582 prototype. Formatting fix.
583 * elf32-m68k.c (elf_m68k_check_relocs): Modify for refcounts
585 (elf_backend_can_refcount): Define.
586 * elf32-ppc.c (ppc_elf_check_relocs): Modify for refcounts
588 (elf_backend_can_refcount): Define.
589 * elf32-s390.c (elf_s390_check_relocs): Modify for refcounts
591 (elf_backend_can_refcount): Define.
592 * elf64-s390.c (elf_s390_check_relocs): Modify for refcounts
594 (elf_backend_can_refcount): Define.
595 * elf64-x86-64.c (elf64_x86_64_check_relocs): Modify for refcounts
597 (elf_backend_can_refcount): Define.
599 * som.c (som_write_symbol_strings): Cast current_offset in
600 bfd_seek call to match param type.
602 2001-09-28 J. Brobecker <brobecker@gnat.com>
604 * som.c (som_write_symbol_strings): Fix incorrect type of
605 current_offset to match the function definition. Fixes a build
606 failure on HPUX-11.00.
608 2001-09-28 Richard Henderson <rth@redhat.com>
610 * elfxx-target.h [section_flags]: Add SEC_ARCH_BIT_0, SEC_SMALL_DATA,
611 SEC_MERGE, SEC_STRINGS.
613 * section.c (SEC_ARCH_BIT_0): New; replace unused SEC_BALIGN.
614 * bfd-in2.h: Rebuild.
616 2001-09-28 Alan Modra <amodra@bigpond.net.au>
618 * elf64-x86-64.c (elf64_x86_64_reloc_type_lookup): Don't map bfd
619 reloc code using x86_64_reloc_map.
621 * elf32-hppa.c (elf32_hppa_check_relocs): Update comment since we
622 no longer allocate here. Localise some vars to blocks where they
624 (elf32_hppa_adjust_dynamic_symbol): Correct a comment. Delay
625 setting of vars until needed.
626 (allocate_dynrelocs): Don't create a .plt entry without a reloc
627 when symbol visibilty makes a function local.
628 (elf32_hppa_finish_dynamic_symbol): Move expressions out of
629 swap_reloca_out function calls.
630 (elf32_hppa_relocate_section): Likewies. Comment typo fix.
631 (elf32_hppa_finish_dynamic_sections): Migrate common code out of
634 * elf32-i386.c (elf_i386_check_relocs): Update comment since we
635 no longer allocate here. Localise some vars to blocks where they
636 are used. Remove separate switch stmt for creating .got sec.
637 (elf_i386_adjust_dynamic_symbol): Correct a comment. Remove
638 redundant casts and aborts. Delay setting of vars until needed.
639 (allocate_dynrelocs): Remove redundant casts and aborts.
640 (elf_i386_size_dynamic_sections): Move comment.
641 (elf_i386_finish_dynamic_symbol): Move expressions out of function
643 (elf_i386_relocate_section): Likewise. Comment typo fix.
644 (elf_i386_finish_dynamic_sections): Migrate common code out of
646 (elf_backend_* defines): Sort.
648 * elf32-i386.c (allocate_dynrelocs): Don't create a .plt entry
649 without a reloc when symbol visibilty makes a function local.
651 2001-09-27 Nick Clifton <nickc@cambridge.redhat.com>
653 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix detection of
654 conflicting float flags.
656 2001-09-26 Alan Modra <amodra@bigpond.net.au>
658 * elf32-i386 (elf_i386_copy_indirect_symbol): New function.
659 (elf_backend_copy_indirect_symbol): Define.
660 (struct elf_i386_link_hash_entry): Rename "root" to "elf".
661 (struct elf_i386_link_hash_table): Likewise.
662 (link_hash_newfunc): Get rid of unnecessary casts.
663 (elf_i386_link_hash_table_create): Likewise.
664 (elf_i386_check_relocs): Initialise local_got_refcounts to 0.
665 Don't test input section SEC_READONLY here to try to avoid copy
666 relocs, and keep dyn_relocs regardleas of ELF_LINK_NON_GOT_REF.
667 (elf_i386_adjust_dynamic_symbol): Check output section SEC_READONLY
668 here to properly test whether we need copy relocs. Do so for weak
671 * elf32-hppa (elf32_hppa_copy_indirect_symbol): New function.
672 (elf_backend_copy_indirect_symbol): Define.
673 (struct elf32_hppa_link_hash_table): Rename "root" to "elf".
674 (stub_hash_newfunc): Get rid of unnecessary casts.
675 (hppa_link_hash_newfunc): Likewise.
676 (elf32_hppa_check_relocs): Initialise local_got_refcounts to 0.
677 Don't test input section SEC_READONLY here to try to avoid copy
678 relocs, and keep dyn_relocs regardleas of ELF_LINK_NON_GOT_REF.
679 (elf32_hppa_adjust_dynamic_symbol): Check output section SEC_READONLY
680 here to properly test whether we need copy relocs. Do so for weak
683 2001-09-26 Alan Modra <amodra@bigpond.net.au>
685 * bfd.c (_bfd_default_error_handlerl): Define using VPARAMS,
686 VA_OPEN, VA_FIXEDARG, VA_CLOSE.
687 (bfd_archive_filename): Cast bfd_malloc arg to the correct size.
689 2001-09-25 Jakub Jelinek <jakub@redhat.com>
691 * elf64-sparc.c (sparc64_elf_build_plt): Fix .plt[32768+] slot
694 2001-09-25 H.J. Lu <hjl@gnu.org>
696 * bfd-in2.h: Regenerated.
698 2001-09-25 Alan Modra <amodra@bigpond.net.au>
700 * elf32-i386.c: Add comment re linker function names and ordering.
701 (elf_i386_link_hash_newfunc): Rename to link_hash_newfunc.
702 (elf_i386_grok_prstatus): Move before linker functions.
703 (elf_i386_grok_psinfo): Likewise.
704 (elf_i386_fake_sections): Move so that functions are ordered.
705 (elf_i386_reloc_type_class): Likewise. Comment function purpose.
707 2001-09-25 Alan Modra <amodra@bigpond.net.au>
709 * elf32-hppa.c: Rename occurrences of "hplink" to "htab"
712 * elf32-hppa.c: (LONG_BRANCH_PIC_IN_SHLIB): Delete. Remove all
713 code handling this option.
714 (LONG_BRANCH_VIA_PLT): Likewise.
715 (RELATIVE_DYNRELOCS): Define as zero.
716 (struct elf32_hppa_dyn_reloc_entry): Add "sec", and
717 "pc_count" fields. Remove "section" field.
718 (elf32_hppa_link_hash_entry): Rename reloc_entries to dyn_relocs.
719 (elf32_hppa_check_relocs): Don't allocate space for dynamic
720 relocs here. Instead, record all needed dynamic relocs via
721 dyn_relocs and local_dynrel. Cache pointer to "sreloc" section
723 (elf32_hppa_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
724 (allocate_plt_and_got_and_discard_relocs): Rename to
725 allocate_dynrelocs. Allocate rather than discarding dyn relocs.
726 (readonly_dynrelocs): New function.
727 (elf32_hppa_size_dynamic_sections): Mark output_bfd unused.
728 Call readonly_dynrelocs to determine need for DT_TEXTREL.
729 Rename "i" to "ibfd". Allocate space for local dyn relocs.
730 (elf32_hppa_relocate_section): Make use of cached sreloc.
731 (elf32_hppa_reloc_type_class): New function.
732 (elf_backend_reloc_type_class): Define.
734 2001-09-25 Alan Modra <amodra@bigpond.net.au>
736 * elf-bfd.h (struct bfd_elf_section_data): Add "local_dynrel"
738 * elf32-i386.c (struct elf_i386_dyn_relocs): Add "sec", and
739 "pc_count" fields. Remove "section" field.
740 (elf_i386_check_relocs): Don't set DF_TEXTREL here. Don't
741 allocate space for dynamic relocs here. Instead, record all
742 needed dynamic relocs via dyn_relocs and local_dynrel. Cache
743 pointer to "sreloc" section in elf_section_data.
744 (elf_i386_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
745 (allocate_plt_and_got_and_discard_relocs): Rename to
746 allocate_dynrelocs. Allocate rather than discarding dyn relocs.
747 (readonly_dynrelocs): New function.
748 (elf_i386_size_dynamic_sections): Call readonly_dynrelocs.
749 Rename "i" to "ibfd". Allocate space for local dyn relocs.
750 (elf_i386_relocate_section): Make use of cached sreloc.
752 2001-09-24 Alan Modra <amodra@bigpond.net.au>
754 * elf-bfd.h (elf_backend_reloc_type_class): Pass in the entire
755 reloc rather than just the type.
756 (_bfd_elf_reloc_type_class): Likewise.
757 * elf.c (_bfd_elf_reloc_type_class): Likewise.
758 * elf32-arm.h (elf32_arm_reloc_type_class): Likewise.
759 * elf32-cris.c (elf_cris_reloc_type_class): Likewise.
760 * elf32-i386.c (elf_i386_reloc_type_class): Likewise.
761 * elf32-m68k.c (elf32_m68k_reloc_type_class): Likewise.
762 * elf32-ppc.c (ppc_elf_reloc_type_class): Likewise.
763 * elf32-s390.c (elf_s390_reloc_type_class): Likewise.
764 * elf32-sh.c (sh_elf_reloc_type_class): Likewise.
765 * elf32-sparc.c (elf32_sparc_reloc_type_class): Likewise.
766 * elf64-alpha.c (elf64_alpha_reloc_type_class): Likewise.
767 * elf64-s390.c (elf_s390_reloc_type_class): Likewise.
768 * elf64-sparc.c (sparc64_elf_reloc_type_class): Likewise.
769 * elf64-x86-64.c (elf64_x86_64_reloc_type_class): Likewise.
770 * elfxx-ia64.c (elfNN_ia64_reloc_type_class): Likewise.
771 * elflink.h: Formatting fixes.
772 (elf_link_sort_relocs): Make "count" and "size" bfd_size_type.
773 Call bfd_zmalloc rather than calloc. Remove unnecessary cast of
774 o->contents to PTR. Update call to elf_backend_reloc_type_class.
776 2001-09-22 John Reiser <jreiser@BitWagon.com>
778 * elfcode.h (elf_object_p): Allow for no section header at all in
779 non-ET_REL files. Honor 0 for e_shnum, e_shstrndx, e_shoff.
781 2001-09-21 Nick Clifton <nickc@cambridge.redhat.com>
783 * elfxx-ia64.c: Fix compile time warning messages.
784 * coff-mcore.c: Fix compile time warning messages.
785 * coff-ppc.c: Fix compile time warning messages.
786 * coffcode.h: Fix compile time warning messages.
787 * elf32-mips.c: Fix compile time warning messages.
788 * elf64-alpha.c: Fix compile time warning messages.
789 * libbfd.c: Fix compile time warning messages.
790 * bfd-in2.h: Regenerate.
792 2001-09-21 Alan Modra <amodra@bigpond.net.au>
794 * Makefile.am: Run "make dep-am".
795 * Makefile.in: Regenerate.
797 * aoutx.h: Formatting fixes.
798 * merge.c (_bfd_merged_section_offset): Break line at 80 chars.
800 * linker.c: Replace bfd_get_filename with bfd_archive_filename
803 2001-09-21 Alan Modra <amodra@bigpond.net.au>
805 * bfd.c (bfd_archive_filename): New function.
806 * bfd-in2.h: Regenerate.
807 * aout-adobe.c: Replace bfd_get_filename with bfd_archive_filename
808 in error messages where the bfd is an input bfd.
809 * aout-cris.c: Likewise.
810 * coff-arm.c: Likewise.
811 * coff-mcore.c: Likewise.
812 * coff-ppc.c: Likewise.
813 * coff-rs6000.c: Likewise.
814 * coff-sh.c: Likewise.
815 * coff-tic54x.c: Likewise.
816 * coff-tic80.c: Likewise.
817 * coff64-rs6000.c: Likewise.
818 * coffcode.h: Likewise.
819 * coffgen.c: Likewise.
820 * cofflink.c: Likewise.
821 * ecofflink.c: Likewise.
822 * elf-hppa.h: Likewise.
824 * elf32-arm.h: Likewise.
825 * elf32-cris.c: Likewise.
826 * elf32-gen.c: Likewise.
827 * elf32-hppa.c: Likewise.
828 * elf32-i370.c: Likewise.
829 * elf32-i386.c: Likewise.
830 * elf32-m32r.c: Likewise.
831 * elf32-mcore.c: Likewise.
832 * elf32-mips.c: Likewise.
833 * elf32-ppc.c: Likewise.
834 * elf32-s390.c: Likewise.
835 * elf32-sh.c: Likewise.
836 * elf32-sparc.c: Likewise.
837 * elf32-v850.c: Likewise.
838 * elf64-alpha.c: Likewise.
839 * elf64-gen.c: Likewise.
840 * elf64-ppc.c: Likewise.
841 * elf64-s390.c: Likewise.
842 * elf64-sparc.c: Likewise.
843 * elf64-x86-64.c: Likewise.
844 * elflink.h: Likewise.
845 * elfxx-ia64.c: Likewise.
848 * libbfd.c: Likewise.
850 * pe-mips.c: Likewise.
851 * peicode.h: Likewise.
853 * xcofflink.c: Likewise.
855 * elf32-arm.h: Make _bfd_error_handler calls K&R compatible.
857 * elflink.c (_bfd_elf_create_linker_section): Better grammar for
860 * coff-mcore.c (coff_mcore_relocate_section): Internalionalise
863 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Constify stt_types.
864 Consolidate error messages, and split long messages to two lines.
866 2001-09-20 John Reiser <jreiser@BitWagon.com>
868 * elf32-i386.c (elf_i386_relocate_section): Coordinate info->symbolic
869 and info->allow_shlib_undefined.
870 * elf32-cris.c: Likewise.
871 * elf32-hppa.c: Likewise.
872 * elf32-m68k.c: Likewise.
873 * elf32-mips.c: Likewise.
874 * elf32-ppc.c: Likewise.
875 * elf32-s390.c: Likewise.
876 * elf32-sh.c: Likewise.
877 * elf32-sparc.c: Likewise.
878 * elf64-alpha.c: Likewise.
879 * elf64-hppa.c: Likewise.
880 * elf64-ppc.c: Likewise.
881 * elf64-s390.c: Likewise.
882 * elf64-sparc.c: Likewise.
883 * elf64-x86-64.c: Likewise.
884 * elfxx-ia64.c: Likewise.
886 2001-09-18 Bruno Haible <haible@clisp.cons.org>
888 * aoutx.h: Include "safe-ctype.h" instead of <ctype.h>.
889 (aout_link_write_symbols): Use ISDIGIT instead of isdigit.
890 * archive.c: Include "safe-ctype.h" instead of <ctype.h>.
891 (_bfd_generic_read_ar_hdr_mag): Use ISDIGIT instead of isdigit.
892 * archures.c: Include "safe-ctype.h" instead of <ctype.h>.
893 (bfd_default_scan): Use ISDIGIT instead of isdigit.
894 * bfd.c: Include "safe-ctype.h" instead of <ctype.h>.
895 (bfd_scan_vma): Use ISXDIGIT/ISDIGIT/ISLOWER instead of
896 isxdigit/isdigit/islower.
897 * binary.c: Include "safe-ctype.h" instead of <ctype.h>.
898 (mangle_name): Use ISALNUM instead of isalnum.
899 * cpu-v850.c: Include "safe-ctype.h" instead of <ctype.h>.
900 (scan): Use ISDIGIT instead of isdigit.
901 * hosts/alphavms.h: Don't include <ctype.h>.
902 * ieee.c: Include "safe-ctype.h" instead of <ctype.h>.
903 (ieee_object_p): Use TOUPPER instead of toupper.
904 * ihex.c: Include "safe-ctype.h" instead of <ctype.h>.
905 (ihex_bad_byte): Use ISPRINT instead of isprint.
906 * merge.c: Don't include <ctype.h>.
907 * oasys.c: Include "safe-ctype.h" instead of <ctype.h>.
908 (oasys_write_sections): Use ISDIGIT instead of isdigit.
909 * pdp11.c: Include "safe-ctype.h" instead of <ctype.h>.
910 (aout_link_write_symbols): Use ISDIGIT instead of isdigit.
911 * ppcboot.c: Include "safe-ctype.h" instead of <ctype.h>.
912 (mangle_name): Use ISALNUM instead of isalnum.
913 * som.c: Include "safe-ctype.h" instead of <ctype.h>.
914 (som_set_reloc_info): Use ISUPPER/ISLOWER/ISDIGIT instead of
915 isupper/islower/isdigit.
916 (som_decode_symclass): Use TOUPPER instead of toupper.
917 * srec.c: Include "safe-ctype.h" instead of <ctype.h>.
918 (srec_bad_byte): Use ISPRINT instead of isprint.
919 (srec_scan): Use ISSPACE instead of isspace.
920 * stabs.c: Include "safe-ctype.h" instead of <ctype.h>.
921 (_bfd_link_section_stabs): Use ISDIGIT instead of isdigit.
922 * syms.c: Include "safe-ctype.h"
923 (islower, toupper): Remove macro definitions.
924 (bfd_decode_symclass): Use TOUPPER instead of toupper.
925 * vms-gsd.c: Don't include <ctype.h>.
926 * vms-hdr.c: Include "safe-ctype.h" instead of <ctype.h>.
927 (_bfd_vms_write_hdr): Use ISLOWER/TOUPPER instead of
929 * vms-tir.c: Don't include <ctype.h>.
931 2001-09-18 Alan Modra <amodra@bigpond.net.au>
933 * libbfd.c (bfd_bread): New function replacing bfd_read without
934 redundant params. Allow reads up to (size_t) -2 in length.
935 (bfd_bwrite): Similarly for bfd_write.
936 (real_read): Return a size_t.
937 (bfd_read): Call bfd_bread.
938 (bfd_write): Call bfd_bwrite.
939 (warn_deprecated): New function to annoy everybody.
940 (bfd_get_file_window): Don't call bfd_set_error unnecessarily.
941 * bfd-in.h (bfd_bread, bfd_bwrite, warn_deprecated): Declare.
942 (bfd_read, bfd_write): Define as macro.
943 * aix386-core.c: Replace calls to bfd_read with bfd_bread, and
944 likewise for bfd_write. Ensure function args are correct size by
945 using casts or local vars. In some cases, remove unnecessary
946 casts. Formatting fixes, in some cases removing a large expression
947 from function args by using a local var. Replace CONST with const.
948 Modify variable types to avoid warings. Use casts to avoid
949 warnings when using negative numbers in unsigned expressions.
950 * aout-adobe.c: Likewise.
951 * aout-arm.c: Likewise.
952 * aout-cris.c: Likewise.
953 * aout-encap.c: Likewise.
954 * aout-ns32k.c: Likewise.
955 * aout-target.h: Likewise.
956 * aout-tic30.c: Likewise.
957 * aoutf1.h: Likewise.
959 * archive.c: Likewise.
960 * archures.c: Likewise.
961 * bfd-in.h: Likewise.
963 * binary.c: Likewise.
966 * cisco-core.c: Likewise.
967 * coff-a29k.c: Likewise.
968 * coff-alpha.c: Likewise.
969 * coff-arm.c: Likewise.
970 * coff-h8300.c: Likewise.
971 * coff-h8500.c: Likewise.
972 * coff-i386.c: Likewise.
973 * coff-i860.c: Likewise.
974 * coff-i960.c: Likewise.
975 * coff-ia64.c: Likewise.
976 * coff-m68k.c: Likewise.
977 * coff-m88k.c: Likewise.
978 * coff-mcore.c: Likewise.
979 * coff-mips.c: Likewise.
980 * coff-ppc.c: Likewise.
981 * coff-rs6000.c: Likewise.
982 * coff-sh.c: Likewise.
983 * coff-sparc.c: Likewise.
984 * coff-stgo32.c: Likewise.
985 * coff-tic30.c: Likewise.
986 * coff-tic54x.c: Likewise.
987 * coff-tic80.c: Likewise.
988 * coff-w65.c: Likewise.
989 * coff-z8k.c: Likewise.
990 * coff64-rs6000.c: Likewise.
991 * coffcode.h: Likewise.
992 * coffgen.c: Likewise.
993 * cofflink.c: Likewise.
994 * coffswap.h: Likewise.
995 * corefile.c: Likewise.
996 * cpu-arc.c: Likewise.
997 * cpu-h8300.c: Likewise.
998 * cpu-h8500.c: Likewise.
999 * cpu-i960.c: Likewise.
1000 * cpu-ia64-opc.c: Likewise.
1001 * cpu-ns32k.c: Likewise.
1002 * cpu-pdp11.c: Likewise.
1003 * cpu-pj.c: Likewise.
1004 * cpu-sh.c: Likewise.
1005 * cpu-w65.c: Likewise.
1006 * cpu-z8k.c: Likewise.
1007 * dwarf1.c: Likewise.
1008 * dwarf2.c: Likewise.
1009 * ecoff.c: Likewise.
1010 * ecofflink.c: Likewise.
1011 * ecoffswap.h: Likewise.
1012 * elf-bfd.h: Likewise.
1013 * elf-hppa.h: Likewise.
1014 * elf-m10200.c: Likewise.
1015 * elf-m10300.c: Likewise.
1017 * elf32-arc.c: Likewise.
1018 * elf32-arm.h: Likewise.
1019 * elf32-avr.c: Likewise.
1020 * elf32-cris.c: Likewise.
1021 * elf32-fr30.c: Likewise.
1022 * elf32-gen.c: Likewise.
1023 * elf32-h8300.c: Likewise.
1024 * elf32-hppa.c: Likewise.
1025 * elf32-i370.c: Likewise.
1026 * elf32-i386.c: Likewise.
1027 * elf32-i860.c: Likewise.
1028 * elf32-m32r.c: Likewise.
1029 * elf32-m68k.c: Likewise.
1030 * elf32-mcore.c: Likewise.
1031 * elf32-mips.c: Likewise.
1032 * elf32-openrisc.c: Likewise.
1033 * elf32-pj.c: Likewise.
1034 * elf32-ppc.c: Likewise.
1035 * elf32-s390.c: Likewise.
1036 * elf32-sh-lin.c: Likewise.
1037 * elf32-sh.c: Likewise.
1038 * elf32-sparc.c: Likewise.
1039 * elf32-v850.c: Likewise.
1040 * elf64-alpha.c: Likewise.
1041 * elf64-hppa.c: Likewise.
1042 * elf64-mips.c: Likewise.
1043 * elf64-ppc.c: Likewise.
1044 * elf64-s390.c: Likewise.
1045 * elf64-sparc.c: Likewise.
1046 * elf64-x86-64.c: Likewise.
1047 * elfarm-nabi.c: Likewise.
1048 * elfcode.h: Likewise.
1049 * elfcore.h: Likewise.
1050 * elflink.c: Likewise.
1051 * elflink.h: Likewise.
1052 * elfxx-ia64.c: Likewise.
1053 * elfxx-target.h: Likewise.
1054 * format.c: Likewise.
1056 * hp300hpux.c: Likewise.
1057 * hppabsd-core.c: Likewise.
1058 * hpux-core.c: Likewise.
1059 * i386aout.c: Likewise.
1060 * i386dynix.c: Likewise.
1061 * i386linux.c: Likewise.
1062 * i386lynx.c: Likewise.
1063 * i386mach3.c: Likewise.
1064 * i386msdos.c: Likewise.
1065 * i386os9k.c: Likewise.
1068 * irix-core.c: Likewise.
1069 * libaout.h: Likewise.
1070 * libbfd-in.h: Likewise.
1071 * libbfd.c: Likewise.
1072 * libcoff-in.h: Likewise.
1073 * libecoff.h: Likewise.
1074 * libieee.h: Likewise.
1075 * libnlm.h: Likewise.
1076 * libpei.h: Likewise.
1077 * libxcoff.h: Likewise.
1078 * linker.c: Likewise.
1079 * lynx-core.c: Likewise.
1080 * m68klinux.c: Likewise.
1081 * merge.c: Likewise.
1082 * mipsbsd.c: Likewise.
1083 * netbsd-core.c: Likewise.
1085 * nlm32-alpha.c: Likewise.
1086 * nlm32-i386.c: Likewise.
1087 * nlm32-ppc.c: Likewise.
1088 * nlm32-sparc.c: Likewise.
1089 * nlmcode.h: Likewise.
1090 * nlmswap.h: Likewise.
1091 * ns32k.h: Likewise.
1092 * oasys.c: Likewise.
1093 * opncls.c: Likewise.
1094 * osf-core.c: Likewise.
1095 * pc532-mach.c: Likewise.
1096 * pdp11.c: Likewise.
1097 * pe-mips.c: Likewise.
1098 * peXXigen.c: Likewise.
1099 * peicode.h: Likewise.
1100 * ppcboot.c: Likewise.
1101 * ptrace-core.c: Likewise.
1102 * reloc.c: Likewise.
1103 * reloc16.c: Likewise.
1104 * riscix.c: Likewise.
1105 * rs6000-core.c: Likewise.
1106 * sco5-core.c: Likewise.
1107 * section.c: Likewise.
1109 * sparclinux.c: Likewise.
1110 * sparclynx.c: Likewise.
1112 * stabs.c: Likewise.
1113 * sunos.c: Likewise.
1115 * targets.c: Likewise.
1116 * tekhex.c: Likewise.
1117 * trad-core.c: Likewise.
1118 * versados.c: Likewise.
1119 * vms-gsd.c: Likewise.
1120 * vms-hdr.c: Likewise.
1121 * vms-misc.c: Likewise.
1122 * vms-tir.c: Likewise.
1125 * xcofflink.c: Likewise.
1126 * bfd-in2.h: Regenerate.
1127 * libbfd.h: Regenerate.
1128 * libcoff.h: Regenerate.
1130 * bfd.c (struct _bfd): Make "where" and "origin" unsigned.
1131 * bfd-in.h (file_ptr): Change from a long int to a bfd_signed_vma.
1132 (ufile_ptr): Define.
1133 (bfd_tell): Return a ufile_ptr.
1134 * libbfd.c (bfd_tell): Likewise.
1135 (bfd_seek): Use bfd_size_type locals. Don't call bfd_set_error
1137 * aix386-core.c: Test != 0 for bfd_seek errors rather than < 0.
1138 * aoutf1.h: Likewise.
1140 * cache.c (bfd_cache_lookup_worker): Guard against abfd->where
1141 larger than unsigned long can represent.
1143 * libbfd.c (bfd_malloc): Take a bfd_size_type arg. Error if
1144 size overflows size_t.
1145 (bfd_realloc): Likewise.
1146 (bfd_zmalloc): Likewise.
1147 * opncls.c (bfd_alloc): Likewise.
1148 (bfd_zalloc): Likewise.
1149 * libbfd-in.h (bfd_malloc, bfd_realloc, bfd_zmalloc): Update.
1150 (bfd_alloc, bfd_zalloc): Update.
1152 * libbfd.c (bfd_get_8): Mask with 0xff in case char is more than
1154 (bfd_get_signed_8): Likewise.
1155 (H_PUT_64, H_PUT_32, H_PUT_16, H_PUT_8,
1156 H_PUT_S64, H_PUT_S32, H_PUT_S16, H_PUT_S8,
1157 H_GET_64, H_GET_32, H_GET_16, H_GET_8,
1158 H_GET_S64, H_GET_S32, H_GET_S16, H_GET_S8): Define and use.
1159 * libaout.h: Likewise define and use here.
1160 * aout-adobe.c: Use H_GET_* and H_PUT_* macros.
1161 * aout-arm.c: Likewise.
1162 * aout-encap.c: Likewise.
1163 * aout-ns32k.c: Likewise.
1164 * aout-tic30.c: Likewise.
1165 * aoutf1.h: Likewise.
1166 * aoutx.h: Likewise.
1168 * coff-alpha.c: Likewise.
1169 * coff-h8300.c: Likewise.
1170 * coff-h8500.c: Likewise.
1171 * coff-i960.c: Likewise.
1172 * coff-ia64.c: Likewise.
1173 * coff-m88k.c: Likewise.
1174 * coff-mips.c: Likewise.
1175 * coff-ppc.c: Likewise.
1176 * coff-rs6000.c: Likewise.
1177 * coff-sh.c: Likewise.
1178 * coff-sparc.c: Likewise.
1179 * coff-stgo32.c: Likewise.
1180 * coff-tic30.c: Likewise.
1181 * coff-tic80.c: Likewise.
1182 * coff-w65.c: Likewise.
1183 * coff-z8k.c: Likewise.
1184 * coff64-rs6000.c: Likewise.
1185 * coffgen.c: Likewise.
1186 * cofflink.c: Likewise.
1187 * coffswap.h: Likewise.
1188 * ecoff.c: Likewise.
1189 * ecoffswap.h: Likewise.
1191 * elf32-mips.c: Likewise.
1192 * elf64-mips.c: Likewise.
1193 * hp300hpux.c: Likewise.
1194 * i386dynix.c: Likewise.
1195 * i386lynx.c: Likewise.
1196 * i386msdos.c: Likewise.
1197 * i386os9k.c: Likewise.
1198 * libpei.h: Likewise.
1199 * nlm32-alpha.c: Likewise.
1200 * nlm32-i386.c: Likewise.
1201 * nlm32-ppc.c: Likewise.
1202 * nlmcode.h: Likewise.
1203 * nlmswap.h: Likewise.
1204 * oasys.c: Likewise.
1205 * pdp11.c: Likewise.
1206 * pe-mips.c: Likewise.
1207 * peXXigen.c: Likewise.
1208 * peicode.h: Likewise.
1209 * riscix.c: Likewise.
1210 * sunos.c: Likewise.
1211 * xcofflink.c: Likewise.
1212 * elfcode.h: (put_word, get_word, put_signed_word, get_signed_word):
1213 Rename to H_PUT_WORD, H_GET_WORD, H_PUT_SIGNED_WORD, H_GET_SIGNED_WORD.
1214 * coff-rs6000.c (PUTWORD, PUTHALF, PUTBYTE): Don't define. Use
1215 equivalent H_PUT_* macro instead.
1216 (GETWORD, GETHALF, GETBYTE): Similarly.
1217 * coff64-rs6000.c (PUTWORD, PUTHALF, PUTBYTE): Likewise.
1218 (GETWORD, GETHALF, GETBYTE): Likewise.
1219 * coffswap.h (PUTWORD, PUTHALF, PUTBYTE): Likewise.
1221 * bfd-in.h (struct orl): Change "pos" to a union.
1222 * archive.c (_bfd_compute_and_write_armap): Use it instead of casts.
1223 (bsd_write_armap): Here too.
1224 (coff_write_armap): And here.
1225 * coff-rs6000.c (xcoff_write_armap_old): And here.
1226 (xcoff_write_one_armap_big): And here.
1227 (xcoff_write_armap_big): And here.
1228 * ecoff.c (_bfd_ecoff_write_armap): And here.
1229 * elf64-mips.c (mips_elf64_write_armap): And here.
1231 * aoutf1.h (sunos_set_arch_mach): Make "mach" param an enum.
1232 * elf-m10300.c (elf_mn10300_mach): Return an unsigned long.
1233 * elf32-h8300.c (elf32_h8_mach): Likewise.
1234 * elf32-mips.c (elf_mips_mach): Likewise.
1235 * sparclynx.c (NAME(lynx,set_arch_mach)): Likewise.
1237 * aix386-core.c (aix386_core_file_p): Remove redundant bfd_release
1239 (aix386_core_vec): Typo fix.
1241 * aout-arm.c: Include libaout.h and aout/aout64.h after N_TXTADDR
1242 etc. to avoid redefined macro warning.
1243 (MY(put_reloc)): Use bfd_vma for "value" rather than long.
1244 (MY(fix_pcrel_26)): Likewise.
1245 * aout-ns32k.c (MY(put_reloc)): Likewise.
1246 * aout-cris.c (MY(swap_ext_reloc_out)): Likewise for r_addend.
1247 * aoutx.h (NAME(aout,swap_ext_reloc_out)): Likewise.
1248 * coff-arm.c (coff_arm_relocate_section): Likewise for my_offset.
1250 * aout-encap.c: Include "file", not <file> for binutils headers.
1251 (encap_object_p): Half baked attempt to fix compile errors in
1252 code dealing with "magic".
1254 * aout-ns32k.c: Include "file", not <file> for binutils headers.
1255 (_bfd_ns32k_relocate_contents): get_data and put_data manipulate
1256 bfd_vma's rather than longs.
1257 * cpu-ns32k.c (ns32k_sign_extend): Delete.
1258 (_bfd_ns32k_get_displacement): Return a bfd_vma, don't pass in offset.
1259 (_bfd_ns32k_get_immediate): Likewise. Add code for 8 byte values,
1261 (_bfd_ns32k_put_displacement): Accept a bfd_vma, don't pass in offset.
1262 Use unsigned comparisons.
1263 (bfd_ns32k_put_immediate): Likewise, and add code for 8 byte values.
1264 (do_ns32k_reloc): get_data and put_data operate on bfd_vma's.
1265 (_bfd_do_ns32k_reloc_contents): Likewise.
1266 * ns32k.h (_bfd_ns32k_get_displacement): Update prototype.
1267 (_bfd_ns32k_get_immediate): Likewise.
1268 (_bfd_ns32k_put_displacement): Likewise.
1269 (_bfd_ns32k_put_immediate): Likewise.
1270 (bfd_reloc_status_type): Likewise.
1272 * aoutx.h (NAME(aout,find_nearest_line)): Rename 'p' to 'colon'
1274 * pdp11.c (NAME(aout,find_nearest_line)): Likewise.
1275 * coff-h8300.c (h8300_reloc16_extra_cases): Remove shadowing "value".
1276 * coff-ppc.c (enum ref_category): Rename "data" to "tocdata" to
1278 (record_toc): Use a bfd_signed_vma for our_toc_offset.
1279 * coffcode.h (coff_write_relocs): Rename "i" to avoid shadowing.
1280 * elf.c (bfd_elf_get_bfd_needed_list): Rename "link" var to avoid
1282 (_bfd_elfcore_strndup): Likewise for "dup".
1283 * elf32-cris.c (cris_elf_relocate_section): "symname" instead of
1284 "name" to avoid shadowing.
1285 * elf32-hppa.c (elf32_hppa_relocate_section): Remove duplicate
1286 definition of "off".
1287 * elf32-i386.c (elf_i386_relocate_section): Likewise.
1288 * elf32-mips.c (_bfd_mips_elf_modify_segment_map): Remove duplicate
1290 (_bfd_mips_elf_final_link): Rename "i" to "j". Remove duplicate
1292 * elf64-x86-64.c (elf64_x86_64_relocate_section): Rename inner "indx"
1294 * elflink.h (elf_link_add_object_symbols): Rename "link" to "shlink"
1296 (elf_link_input_bfd): Likewise.
1297 (elf_bfd_final_link): Remove duplicate innermost "off" var.
1298 * oasys.c (oasys_write_data): Rename innermost "p" to "sym".
1299 * reloc16.c (bfd_coff_reloc16_relax_section): Rename "i" param to
1301 * som.c (som_prep_for_fixups): Rename inner "i" to "j".
1302 * sunos.c (sunos_add_dynamic_symbols): Localise "s" var.
1303 (sunos_write_dynamic_symbol): Remove unused vars.
1304 * syms.c (_bfd_stab_section_find_nearest_line): Remove duplicate
1305 innermost "directory_name" and "file_name" vars.
1306 * tekhex.c (first_phase): Rename local var "type" to "stype".
1307 (tekhex_write_object_contents): Rename innermost "s" to "sym".
1308 * vms-gsd.c (vms_secflag_by_name): Change "size" param to "hassize",
1309 doing comparison at caller.
1310 (vms_esecflag_by_name): Likewise.
1311 * vms-tir.c (etir_sto): Rename innermost "psect" to "psect1".
1312 * xcofflink.c (xcoff_link_input_bfd): Delete duplicate innermost "o".
1313 (xcoff_write_global_symbol): Rename "p" param to "inf".
1315 * cisco-core.c: Add missing prototypes.
1316 (cisco_core_file_failing_command): Add ATTRIBUTE_UNUSED.
1317 (cisco_core_file_failing_signal): Likewise.
1318 (cisco_core_file_matches_executable_p): Likewise.
1319 * hpux-core.c (hpux_core_core_file_failing_signal): Likewise.
1320 * netbsd-core.c (netbsd_core_file_matches_executable_p): Likewise.
1321 * osf-core.c (osf_core_core_file_matches_executable_p): Likewise.
1322 * sco5-core.c (sco5_core_file_matches_executable_p): Likewise.
1324 * coff-arm.c (coff_arm_link_hash_table): Use bfd_size_type for
1325 thumb_glue_size and arm_glue_size.
1326 * elf32-arm.h (elf32_arm_link_hash_table): Likewise here.
1328 * coff64-rs6000.c: Group prototypes together.
1330 * coffcode.h (coff_set_arch_mach): Add ATTRIBUTE_UNUSED.
1331 (buy_and_read): Remove "seek" param. Change "size" to bfd_size_type.
1333 * cpu-arc.c: Add missing prototypes.
1334 * cpu-h8500.c: Likewise.
1335 * cpu-i960.c: Likewise.
1336 * cpu-pj.c: Likewise.
1337 * cpu-sh.c: Likewise.
1338 * cpu-w65.c: Likewise.
1339 * cpu-z8k.c: Likewise.
1340 * elf32-fr30.c: Likewise.
1341 * elf32-h8300.c: Likewise.
1342 * elf32-i370.c: Likewise.
1343 * hpux-core.c: Likewise.
1344 * versados.c: Likewise.
1346 * cpu-h8300.c (bfd_default_scan_num_mach): Don't declare.
1347 * cpu-h8500.c: Likewise.
1348 * cpu-i960.c: Likewise.
1349 * cpu-z8k.c: Likewise.
1351 * cpu-ia64-opc.c: Correct comment.
1353 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Remove unused var.
1355 * elf-bfd.h (elf_size_info): Change count param of write_out_phdrs
1357 (bfd_elf32_write_out_phdrs): Likewise.
1358 (bfd_elf64_write_out_phdrs): Likewise.
1359 (elf_linker_section_pointers): Change addend to bfd_vma.
1360 (_bfd_elf_find_pointer_linker_section): Likewise.
1361 (_bfd_elfcore_make_pseudosection): Change size param to size_t and
1362 filepos to unsigned file_ptr.
1363 (_bfd_elfcore_strndup): Change max param to size_t.
1364 * elf.c (_bfd_elfcore_make_pseudosection): As above.
1365 (_bfd_elfcore_strndup): Likewise.
1366 (_bfd_elf_find_pointer_linker_section): Likewise.
1368 * elf-hppa.h (elf_hppa_relocate_insn): Return an int, and change
1369 insn and sym_value to ints.
1371 * elf.c (elf_read): Make "offset" param a file_ptr, "size" a
1373 (elfcore_read_notes): Likewise.
1375 * elf32-arm.h (elf32_arm_final_link_relocate): Change sym_flags
1376 param from unsigned char to int.
1377 (elf32_arm_relocate_section): If USE_REL, cast "rel" appropriately
1378 for info_to_howto call.
1379 (add_dynamic_entry): Define macro.
1380 (elf32_arm_size_dynamic_sections): Use add_dynamic_entry.
1382 * elf32-cris.c (add_dynamic_entry): Define macro.
1383 (elf_cris_size_dynamic_sections): Use add_dynamic_entry.
1385 * elf32-h8300.c (elf32_h8_final_write_processing): Make static.
1386 (elf32_h8_object_p): Likewise.
1387 (elf32_h8_merge_private_bfd_data): Likewise.
1388 (elf32_h8_relax_section): Cast gap to int so signed comparisons work.
1390 * elf32-hppa.c (add_dynamic_entry): Define macro.
1391 (elf32_hppa_size_dynamic_sections): Use it.
1392 * elf32-i370.c (add_dynamic_entry): Define macro.
1393 (i370_elf_size_dynamic_sections): Use it.
1394 (i370_noop): Make static.
1395 * elf32-i386.c (add_dynamic_entry): Define macro.
1396 (elf_i386_size_dynamic_sections): Use it.
1397 * elf32-m68k.c (add_dynamic_entry): Define macro.
1398 (elf_m68k_size_dynamic_sections): Use it.
1399 * elf32-ppc.c (add_dynamic_entry): Define macro.
1400 (ppc_elf_size_dynamic_sections): Use it.
1401 * elf32-s390.c (add_dynamic_entry): Define macro.
1402 (elf_s390_size_dynamic_sections): Use it.
1403 * elf64-alpha.c (add_dynamic_entry): Define macro.
1404 (elf64_alpha_size_dynamic_sections): Use it.
1405 * elf64-hppa.c (add_dynamic_entry): Define macro.
1406 (elf64_hppa_size_dynamic_sections): Use it.
1407 * elf64-ppc.c (add_dynamic_entry): Define macro.
1408 (ppc64_elf_size_dynamic_sections): Use it.
1409 * elf64-s390.c (add_dynamic_entry): Define macro.
1410 (elf_s390_size_dynamic_sections): Use it.
1411 * elf64-sparc.c (add_dynamic_entry): Define macro.
1412 (sparc64_elf_size_dynamic_sections): Use it.
1413 * elf64-x86-64.c (add_dynamic_entry): Define macro.
1414 (elf64_x86_64_size_dynamic_sections): Use it.
1415 * elfxx-ia64.c (add_dynamic_entry): Define macro.
1416 (elfNN_ia64_size_dynamic_sections): Use it.
1418 * elf32-v850.c (SEXT24): Modify to avoid signed/unsigned warning.
1419 (v850_elf_perform_relocation): Make "r_type" param unsigned.
1421 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Just return
1422 false if the first malloc fails rather than going via error_return.
1424 * elf64-sparc.c (sparc64_elf_plt_entry_offset): Use a bfd_vma for
1426 (sparc64_elf_plt_ptr_offset): Likewise, and for "max" param too.
1428 * elflink.h (elf_link_input_bfd): s/ingored/ignored/ in error message.
1430 * elfxx-ia64.c (global_sym_index): Return a long.
1432 * ieee.c (get_symbol): Use int rather than char param.
1433 (ieee_slurp_sections): Move "section" var to inner blocks.
1434 (copy_expression): Don't init "value" to zero or worry about
1435 clearing to zero after using.
1436 (ieee_write_debug_part): Rename "output_buffer" to "obuff" to avoid
1439 * ihex.c (ihex_write_record): Make "count" var a size_t, "addr" an
1442 * libbfd-in.h (BFD_ALIGN): Add cast to avoid signed/unsigned warning.
1443 (bfd_write_bigendian_4byte_int): Pass an unsigned int value param.
1445 * mipsbsd.c (mips_fix_jmp_addr): Add "error_message" param.
1447 * pc532-mach.c (MYNSX): Delete.
1448 (ns32kaout_bfd_reloc_type_lookup): Define prototype without MYNSX.
1449 (write_object_contents): Correct prototype.
1451 * peicode.h (pe_ILF_build_a_bfd): Use an unsigned int param rather
1452 than unsigned short.
1454 * section.c (bfd_set_section_contents): Remove redundant
1455 "offset < 0" test. Check that "count" doesn't overflow size_t.
1456 (bfd_get_section_contents): Likewise.
1458 * som.c (som_fixup_formats): Add missing braces.
1459 (som_reloc_addend): Pass a bfd_vma for "addend".
1461 * srec.c (srec_write_record): Pass "type" as an unsigned int.
1462 (srec_write_symbols): Remove an unnecessary var.
1464 * targets.c (_bfd_target_vector): Sort entries. Sort externs
1466 * configure.in: Sort to match. Bump version number.
1467 * configure: Regenerate.
1469 * tekhex.c (move_section_contents): Assert offset == 0.
1471 * versados.c (new_symbol_string): Constify arg.
1472 (process_esd): Use bfd_und_section_ptr rather than &bfd_und_section.
1473 (versados_get_symbol_info): Make static.
1474 (versados_print_symbol): Likewise.
1475 (versados_get_reloc_upper_bound): Likewise.
1476 (versados_canonicalize_reloc): Likewise.
1478 2001-09-18 Nick Clifton <nickc@cambridge.redhat.com>
1480 * elflink.h (elf_link_input_bfd): Fix typo in error message.
1482 2001-09-17 H.J. Lu <hjl@gnu.org>
1484 * dwarf1.c (parse_die): Take a new arg for the end of the
1485 section. Return false if die is beyond the section.
1486 (parse_functions_in_unit): Pass the end of the section to
1488 (_bfd_dwarf1_find_nearest_line): Likewise.
1490 2001-09-14 Michael Rauch <mrauch@netbsd.org>
1492 * elf32-sparc.c (elf32_sparc_relocate_section): Treat R_SPARC_UA32
1493 just like R_SPARC_32.
1495 2001-09-14 Kevin Lo <kevlo@openbsd.org>
1497 * configure.bfd: Add arm-openbsd target.
1499 2001-09-14 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1501 * config.bfd: Change machine triplets from mips*el*-* to mips*el-*.
1502 Add support for mips64.
1504 2001-09-13 Alexandre Oliva <aoliva@redhat.com>
1506 * elf32-openrisc.c (ELF_MACHINE_ALT1): Define as EM_OPENRISC_OLD.
1508 2001-09-12 Alexandre Oliva <aoliva@redhat.com>
1510 * elf.c (prep_headers): Get the machine code from the elf
1512 * elf-m10200.c (ELF_MACHINE_CODE): Redefine to EM_MN10200.
1513 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_MN10200.
1514 * elf-m10300.c (ELF_MACHINE_CODE): Redefine to EM_MN10300.
1515 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_MN10300.
1516 * elf-arc.c (arc_elf_final_write_processing): Don't override
1517 e_machine, it's now properly set in prep_headers.
1518 * elf32-avr.c (elf32_avr_object_p): Accept both EM_AVR and
1520 (ELF_MACHINE_ALT1): Define to EM_AVR_OLD.
1521 * elf-d10v.c (ELF_MACHINE_CODE): Redefine to EM_D10V.
1522 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_D10V.
1523 * elf-d30v.c (ELF_MACHINE_CODE): Redefine to EM_D30V.
1524 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_D30V.
1525 * elf-fr30.c (ELF_MACHINE_CODE): Redefine to EM_FR30.
1526 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_FR30.
1527 * elf-m32r.c (ELF_MACHINE_CODE): Redefine to EM_M32R.
1528 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_M32R.
1529 * elf32-pj.c (ELF_MACHINE_ALT1): DEfine to EM_PJ_OLD.
1530 * elf-v850.c (ELF_MACHINE_CODE): Redefine to EM_V850.
1531 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_V850.
1533 2001-09-11 Richard Henderson <rth@redhat.com>
1535 * elf64-alpha.c (elf64_alpha_section_flags): New.
1536 (elf64_alpha_fake_sections): Map SEC_SMALL_DATA to SHF_ALPHA_GPREL.
1538 2001-09-11 Richard Henderson <rth@redhat.com>
1540 * elf64-alpha.c (elf64_alpha_relocate_section): Do not
1541 apply HINT relocations against dynamic symbols.
1543 2001-09-11 H.J. Lu <hjl@gnu.org>
1545 * linker.c (link_action): Change COMMON_ROW\defw from CREF to COM.
1547 2001-09-09 Richard Henderson <rth@redhat.com>
1549 * elf64-alpha.c: Delete all unused ERIC_neverdef and rth_notdef code.
1551 * elf64-alpha.c (elf64_alpha_relax_with_lituse): Nop out gpdisp
1552 following a call to a near function.
1554 2001-09-08 Richard Henderson <rth@redhat.com>
1556 * elf64-alpha.c (elf64_alpha_relocate_section): Soft fail
1557 relocation errors. Fail gp-relative relocations against
1560 2001-09-08 Alan Modra <amodra@bigpond.net.au>
1562 * elf32-i386.c (elf_i386_relocate_section): Check !DEF_REGULAR
1563 as well as DEF_DYNAMIC in test for avoided copy relocs.
1564 (allocate_plt_and_got_and_discard_relocs): Likewise.
1565 * elf32-hppa.c (elf_i386_relocate_section): Likewise.
1566 (allocate_plt_and_got_and_discard_relocs): Likewise.
1568 2001-09-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1570 * elf32-mips.c (mips_elf_calculate_relocation): Fix overflow handling
1573 2001-09-06 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1575 * elf64-mips.c (mips_elf64_howto_table_rel): Fix relocation HOWTO
1577 (mips_elf64_howto_table_rel): Likewise.
1579 2001-09-05 Tom Rix <trix@redhat.com>
1581 * xcofflink.c (bfd_xcoff_import_symbol): Handle import file XMC_XO
1582 and syscall symbols.
1583 (write_global_symbol) : Same.
1584 (bfd_xcoff_export_symbol): Remove unused syscall param.
1585 * libxcoff.h: Change prototype of bfd_xcoff_export symbol and
1586 bfd_xcoff_import_symbol.
1588 * bfd-in2.h : Regenerate.
1590 2001-09-04 Richard Henderson <rth@redhat.com>
1592 * elf64-alpha.c (SKIP_HOWTO): New.
1593 (elf64_alpha_howto_table): Use it to remove dead ECOFF relocs.
1594 Fix sizes of 16-bit mem format relocs.
1595 (elf64_alpha_reloc_map): Update to match.
1596 (elf64_alpha_relax_with_lituse): Use GPREL16 as appropriate.
1597 (elf64_alpha_relax_without_lituse): Likewise.
1598 (elf64_alpha_check_relocs): Handle GPREL16.
1599 (elf64_alpha_relocate_section): Likewise.
1600 * reloc.c (BFD_RELOC_ALPHA_USER_*): Remove.
1601 (BFD_RELOC_ALPHA_GPREL_HI16, BFD_RELOC_ALPHA_GPREL_LO16): New.
1602 * bfd-in2.h, libbfd.h: Rebuild.
1604 2001-09-04 Jeff Law <law@redhat.com>
1606 * elf32-h8300.c (elf32_h8_relax_section): New function.
1607 (elf32_h8_relax_delete_bytes): Likewise.
1608 (elf32_h8_symbol_address_p): Likewise.
1609 (elf32_h8_get_relocated_section_contents): Likewise.
1610 (bfd_elf32_bfd_relax_section): Define.
1611 (bfd_elf32_bfd_get_relocated_section_contents): Likewise.
1613 * elf32-h8300.c (special): New function.
1614 (h8_elf_howto_table): Use it for SPECIAL_FUNCTION field in
1616 (elf32_h8_final_link_relocate): Treat R_H8_DIR24A8 like 32bit
1617 relocations. Fix problems with the true 24bit reloc R_H8_DIR24R8.
1618 Fix minor problems with 8bit and 16bit PC relative relocations.
1620 2001-09-01 Andreas Jaeger <aj@suse.de>
1622 * vms-tir.c: Add missing prototypes.
1623 * vms-hdr.c: Likewise.
1624 * vms-gsd.c: Likewise.
1625 * vms-misc.c: Likewise.
1627 2001-08-31 H.J. Lu <hjl@gnu.org>
1629 * elf32-mips.c (_bfd_mips_elf_check_relocs): Report filename
1630 with bad relocation.
1632 2001-08-31 Eric Christopher <echristo@redhat.com>
1633 Jason Eckhardt <jle@redhat.com>
1635 * bfd/archures.c: Add mipsisa32 and mipsisa64. Remove mips32,
1636 mips32_4k and mips64.
1637 * bfd/aoutx.h: Remove bfd_mach_mips32, bfd_mach_mips32_4k,
1638 bfd_mach_mips64. Add bfd_mach_mipsisa32, bfd_mach_mipsisa64.
1639 * bfd/cpu-mips.c: Ditto.
1640 * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing): Ditto.
1641 * bfd/bfd-in2.h: Regenerate.
1643 2001-08-31 Jakub Jelinek <jakub@redhat.com>
1645 * elf64-alpha.c (elf64_alpha_relocate_section): Duplicate memory
1646 value into R_ALPHA_RELATIVE's addend.
1647 (elf64_alpha_finish_dynamic_symbol): Likewise.
1649 2001-08-31 Nick Clifton <nickc@cambridge.redhat.com>
1651 * elf32-arm.h (elf32_arm_relocate_section): Do not rightshift
1652 recomputed addend during relocatable link if not USE_REL.
1654 * elflink.h (elf_gc_propagate_vtable_entries_used): Fix off-by-one
1657 2001-08-30 H.J. Lu <hjl@gnu.org>
1659 * elf32-mips.c (mips_elf_calculate_relocation): Revert the last
1661 (_bfd_mips_elf_adjust_dynamic_symbol): Allocate dynamic
1662 relocations for weak definitions.
1664 2001-08-30 H.J. Lu <hjl@gnu.org>
1666 * Makefile.am (BFD32_BACKENDS): Add elf32-h8300.lo.
1667 (BFD32_BACKENDS_CFILES): Add elf32-h8300.c.
1668 * Makefile.in: Rebuild.
1670 2001-08-30 H.J. Lu <hjl@gnu.org>
1672 * elf32-mips.c (mips_elf_calculate_relocation): Don't create
1673 dynamic relocation for undefined weak symbols when creating
1674 executables. Check h->root.root.type, instead of h->root.type.
1676 2001-08-29 Joel Sherrill <joel@OARcorp.com>
1678 * config.bfd (i[3456]86-*-rtems*, m68*-*-rtems*): Change
1679 default from coff to elf.
1681 2001-08-29 Jeff Law <law@redhat.com>
1683 * elf32-h8300.c (h8_elf_howto_table): Add new PC relative
1685 (h8_reloc_map): Similarly.
1686 (elf32_h8_final_link_relocate): Remove incorrect overflow tests.
1687 Add support for PC relative relocations.
1689 * elf32-h8300.c: Put all prototypes together.
1690 (elf32_h8_info_to_howto): Parameter elf_reloc is used.
1691 (elf32_h8_final_link_relocate): New function for linker.
1692 (elf32_h8_relocate_section): Similarly.
1693 (elf_backend_relocate_section): Define.
1695 * cpu-h8300.c (h8300_scan, compatible): Prototype.
1696 (h8300_scan): Handle architecture:machine encodings typically
1697 found in linker scripts.
1698 * elf.c (prep_headers): Do not try to do H8 machine recognition
1700 * elf32-h8300.c: Add some missing prototypes.
1701 (elf32_h8_mach, elf32_h8_final_write_processing): New functions.
1702 (elf32_h8_object_p): Similarly.
1704 2001-08-29 Tom Rix <trix@redhat.com>
1706 * xcofflink.c (xcoff_link_add_symbols): Fix XTY_LD symbol that
1707 does not follow a XTY_SD.
1709 2001-08-29 Alan Modra <amodra@bigpond.net.au>
1711 * targmatch.sed: Delete case statements.
1712 * config.bfd <powerpc-*-aix* entry>: Select 64 bit xcoff for
1715 Wed Aug 29 02:27:36 2001 J"orn Rennecke <amylaar@redhat.com>
1717 * Makefile.am (elf32-h8300.lo): New target.
1718 * config.bfd (h8300*-*-elf): New case.
1719 * configure.in (bfd_elf32_h8300_vec): New case.
1720 * elf.c (prep_headers): Add case for bfd_arch_h8300.
1721 * reloc.c (BFD_RELOC_H8_DIR16A8): New relocation.
1722 (BFD_RELOC_H8_DIR16R8, BFD_RELOC_H8_DIR24A8): Likewise.
1723 (BFD_RELOC_H8_DIR24R8, BFD_RELOC_H8_DIR32A16): Likewise.
1724 * targets.c (bfd_target bfd_elf32_h8300_vec): New extern declaration.
1725 * elf32-h8300.c: New file.
1726 * Makefile.in, bfd-in2.h, libbfd.h, configure: Regenerated.
1728 2001-08-28 Nick Clifton <nickc@cambridge.redhat.com>
1730 * sparclynx.c: Add missing prototypes.
1731 * coff-mcore.c: Add missing prototypes.
1732 * elf32-pj.c: Add missing prototypes.
1733 * nlm32-sparc.c: Add missing prototypes.
1734 * oasys.c: Add missing prototypes.
1735 * pdp11.c: Add missing prototypes.
1736 * pe-mips.c: Add missing prototypes.
1737 * riscix.c: Add missing prototypes.
1739 2001-08-27 Daniel Jacobowitz <drow@mvista.com>
1741 * elf32-i386.c: Add missing prototypes.
1742 * elf32-ppc.c: Likewise.
1743 * elf32-sh-lin.c: Likewise.
1744 * elfarm-nabi.c: Likewise.
1746 2001-08-27 Daniel Jacobowitz <drow@mvista.com>
1748 * elf32-i386.c (elf_i386_grok_prstatus): New function.
1749 (elf_i386_grok_psinfo): New function.
1750 (elf_backend_grok_prstatus): Define.
1751 (elf_backend_grok_psinfo): Likewise.
1752 * elf32-ppc.c (ppc_elf_grok_prstatus): New function.
1753 (ppc_elf_grok_psinfo): New function.
1754 (elf_backend_grok_prstatus): Define.
1755 (elf_backend_grok_psinfo): Likewise.
1756 * elf32-sh-lin.c (elf32_shlin_grok_prstatus): New function.
1757 (elf32_shlin_grok_psinfo): New function.
1758 (elf_backend_grok_prstatus): Define.
1759 (elf_backend_grok_psinfo): Likewise.
1760 * elfarm-nabi.c (elf32_arm_nabi_grok_prstatus): New function.
1761 (elf32_arm_nabi_grok_psinfo): New function.
1762 (elf_backend_grok_prstatus): Define.
1763 (elf_backend_grok_psinfo): Likewise.
1765 2001-08-27 H.J. Lu <hjl@gnu.org>
1767 * elf32-mips.c (mips_elf_create_dynamic_relocation): Add more
1769 (mips_elf_calculate_relocation): Create dynamic relocation for
1770 symbols with weak definition or the ELF_LINK_HASH_DEF_REGULAR
1773 2001-08-27 H.J. Lu <hjl@gnu.org>
1775 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Add prototype.
1776 (_bfd_mips_elf_copy_indirect_symbol): Likewise.
1777 (_bfd_elf32_mips_grok_prstatus): Likewise.
1778 (_bfd_elf32_mips_grok_psinfo): Likewise.
1779 (_bfd_mips_elf_hide_symbol): Make it static and cast to
1780 `struct mips_elf_link_hash_entry *'.
1781 (_bfd_mips_elf_copy_indirect_symbol): Make it static.
1783 2001-08-27 Nick Clifton <nickc@cambridge.redhat.com>
1785 * mipsbsd.c: Add missing prototypes.
1786 * hp300hpux.c: Add missing prototypes.
1787 * i386aout.c: Add missing prototypes.
1788 * i386lynx.c: Add missing prototypes.
1789 * i386mach3.c: Add missing prototypes.
1790 * i386msdos.c: Add missing prototypes.
1791 * i386os9k.c: Add missing prototypes.
1793 2001-08-27 Linus Nordberg <linus@swox.se>
1794 Torbjorn Granlund <tege@swox.com>
1795 Staffan Ulfberg <staffanu@swox.se>
1796 Alan Modra <amodra@bigpond.net.au>
1798 * config.bfd: Add powerpc64 target. Add powerpc64 vectors to
1799 targ64_selvecs for 32 bit powerpc targets.
1800 * Makefile.am (BFD64_BACKENDS): Add elf64-ppc.lo.
1801 (BFD64_BACKENDS_CFILES): Add elf64-ppc.c.
1803 * Makefile.in: Regenerate.
1804 * configure.in: Add elf64_powerpc vecs.
1805 * configure: Regenerate.
1806 * cpu-powerpc.c: Default to bfd_mach_ppc_620 entry for 64 bit.
1807 * elf.c (prep_headers): EM_PPC64 for 64 bit ppc elf target.
1808 * targets.c: Add bfd_elf64_powerpc_vec and bfd_elf64_powerpcle_vec.
1809 * elf64-ppc.c: New file.
1810 * reloc.c: Add powerpc64 relocs.
1811 * libbfd.h: Regenerate.
1812 * bfd-in2.h: Regenerate.
1814 2001-08-27 Andreas Schwab <schwab@suse.de>
1816 * elf32-m68k.c (elf32_m68k_check_relocs): Set DF_TEXTREL if the
1817 reloc is against read-only section.
1818 (elf32_m68k_size_dynamic_sections): Use DF_TEXTREL flag instead of
1819 looking up section names for DT_TEXTREL.
1820 (elf32_m68k_reloc_type_class): New function.
1821 (elf_backend_reloc_type_class): Define.
1823 2001-08-27 Andreas Jaeger <aj@suse.de>
1825 * elf64-s390.c (elf_s390_check_relocs): Set DF_TEXTREL if the
1826 reloc is against read-only section.
1827 (elf_s390_size_dynamic_sections): Use DF_TEXTREL flag instead of
1828 looking up section names for DT_TEXTREL.
1829 (elf_s390_reloc_type_class): New.
1830 (elf_backend_reloc_type_class): Define.
1832 * elf32-s390.c (elf_s390_check_relocs): Set DF_TEXTREL if the
1833 reloc is against read-only section.
1834 (elf_s390_size_dynamic_sections): Use DF_TEXTREL flag instead of
1835 looking up section names for DT_TEXTREL.
1836 (elf_s390_reloc_type_class): New.
1837 (elf_backend_reloc_type_class): Define.
1839 * elf32-ppc.c (ppc_elf_check_relocs): Set DF_TEXTREL if the reloc
1840 is against read-only section.
1841 (ppc_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
1842 looking up section names for DT_TEXTREL.
1843 (ppc_elf_reloc_type_class): New.
1844 (elf_backend_reloc_type_class): Define.
1846 2001-08-26 Andreas Jaeger <aj@suse.de>
1848 * elf32-cris.c (cris_elf_check_relocs): Set DF_TEXTREL if the
1849 reloc is against read-only section.
1850 (elf_cris_size_dynamic_sections): Use DF_TEXTREL flag instead of
1851 looking up section names for DT_TEXTREL.
1852 (elf_cris_reloc_type_class): New.
1853 (elf_backend_reloc_type_class): Define.
1855 * elf32-sh.c (sh_elf_check_relocs): Set DF_TEXTREL if the reloc is
1856 against read-only section.
1857 (elf_backend_reloc_type_class): Define.
1858 (sh_elf_reloc_type_class): New.
1859 (sh_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
1860 looking up section names for DT_TEXTREL.
1862 * elf32-arm.h (elf32_arm_check_relocs): Set DF_TEXTREL if the
1863 reloc is against read-only section.
1864 (elf32_arm_size_dynamic_sections): Use DF_TEXTREL flag instead of
1865 looking up section names for DT_TEXTREL.
1866 (elf32_arm_reloc_type_class): New.
1867 (elf_backend_reloc_type_class): Define.
1869 2001-08-25 Andreas Jaeger <aj@suse.de>
1871 * oasys.c: Add missing prototypes.
1873 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Add unused
1874 attribute for parameter.
1875 * elf.c (_bfd_elf_reloc_type_class): Likewise.
1877 * versados.c (get_4): Make static.
1878 (get_10): Make static.
1879 Add missing prototypes.
1880 (process_esd): Fix call to versados_new_symbol.
1882 2001-08-25 Nick Clifton <nickc@cambridge.redhat.com>
1884 * coff-a29k.c: Add missing prototypes.
1885 * coff-apollo.c: Add missing prototypes.
1886 * coff-arm.c: Add missing prototypes.
1887 * coff-i860.c: Add missing prototypes.
1888 * coff-rs6000.c: Add missing prototypes.
1889 * coff-tic80.c: Add missing prototypes.
1890 * elf-m10200.c: Add missing prototypes.
1891 * elf-m10300.c: Add missing prototypes.
1892 * elf32-arm.h: Add missing prototypes.
1893 * elf32-d10v.c: Add missing prototypes.
1894 * elf32-m32r.c: Add missing prototypes.
1895 * elf32-mcore.c: Add missing prototypes.
1896 * elf32-openrisc.c: Add missing prototypes.
1897 * elf32-sh.c: Add missing prototypes.
1898 * elf32-sparc.c: Add missing prototypes.
1899 * elf32-v850.c: Add missing prototypes.
1900 * elfarm-nabi.c: Add missing prototypes.
1901 * elfarm-oabi.c: Add missing prototypes.
1903 2001-08-25 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1905 * elf32-mips.c (elf_mips_abi_name): Return the right ABI string for
1906 E_MIPS_ABI_O64 and E_MIPS_ABI_EABI64
1908 2001-08-24 H.J. Lu <hjl@gnu.org>
1910 * elf.c (_bfd_elf_merge_sections): Fail if not using an ELF
1913 2001-08-24 Nick Clifton <nickc@cambridge.redhat.com>
1915 * elf-bfd.h (elf_hash_table): Revert definition.
1916 (is_elf_hash_table): New macro.
1917 * elflink.h (elf_link_add_object_symbols): Test
1918 is_elf_hash_table before accessing ELF only fields in hash
1920 (elf_link_create_dynamic_sections): Fail if not using an ELF
1922 (elf_add_dynamic_entry): Fail if not using an ELF hash
1924 (elf_link_record_local_dynamic_symbol): Fail if not using an
1926 (size_dynamic_sections): Fail if not using an ELF hash
1928 (elf_adjust_dynamic_symbol): Fail if not using an ELF
1930 (elf_bfd_final_link): Fail if not using an ELF hash
1933 2001-08-24 H.J. Lu <hjl@gnu.org>
1935 * elf-bfd.h (elf_hash_table): Return NULL if the linker hash
1936 table is not an ELF linker hash table.
1938 * elf.c (_bfd_elf_link_hash_table_init): Set the linker hash
1939 table type to bfd_link_elf_hash_table.
1941 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_create): Revert
1944 * linker.c (_bfd_link_hash_table_init): Set the linker hash
1945 table type to bfd_link_generic_hash_table.
1947 2001-08-24 Alexandre Oliva <aoliva@redhat.com>
1949 * bfd.c (bfd_alt_mach_code): New function.
1950 * bfd-in2.h: Rebuilt.
1952 2001-08-24 Alexandre Oliva <aoliva@redhat.com>
1954 * elf-m10300.c (mn10300_elf_relocate_section): Test the right
1955 `type' field in the hash entry when deciding whether to follow a
1958 2001-08-24 Jakub Jelinek <jakub@redhat.com>
1960 * elflink.h (elf_link_sort_cmp1): Sort RELATIVE relocs first, not
1962 (elf_link_sort_relocs): Adjust accordingly.
1964 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Add reltext flag.
1965 (elf64_alpha_check_relocs): Set it if section this reloc is against
1966 is read-only. Set DF_TEXTREL if a RELATIVE reloc is needed against
1968 (elf64_alpha_calc_dynrel_sizes): Set DF_TEXTREL flag if relocation
1969 is is against read-only section.
1970 (elf64_alpha_size_dynamic_sections): Use DF_TEXTREL flag, don't
1971 check section names.
1972 (elf64_alpha_reloc_type_class): New.
1973 (elf_backend_reloc_type_class): Define.
1975 2001-08-24 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1977 * linker.c (_bfd_generic_link_add_archive_symbols): Replace alloca()
1980 2001-08-23 Andreas Jaeger <aj@suse.de>
1982 * elf64-x86-64.c (elf64_x86_64_check_relocs): Set DF_TEXTREL if
1983 the reloc is against read-only section.
1984 (elf64_x86_64_size_dynamic_sections): Use DF_TEXTREL flag instead
1985 of looking up section names for DT_TEXTREL.
1986 (elf64_x86_64_reloc_type_class): New.
1987 (elf_backend_reloc_type_class): Define.
1989 2001-08-23 H.J. Lu <hjl@gnu.org>
1991 * syms.c (bfd_print_symbol_vandf): Add abfd to arg.
1992 * bfd-in2.h (bfd_print_symbol_vandf): Regenerated.
1994 * aoutx.h (NAME(aout,print_symbol)): Pass abfd to
1995 bfd_print_symbol_vandf.
1996 * coffgen.c (coff_print_symbol): Likewise.
1997 * elf.c (bfd_elf_print_symbol): Likewise.
1998 * ieee.c (ieee_print_symbol): Likewise.
1999 * nlmcode.h (nlm_print_symbol): Likewise.
2000 * oasys.c (oasys_print_symbol): Likewise.
2001 * pdp11.c (NAME(aout,print_symbol)): Likewise.
2002 * som.c (som_print_symbol): Likewise.
2003 * srec.c (srec_print_symbol): Likewise.
2004 * tekhex.c (tekhex_print_symbol): Likewise.
2005 * versados.c (versados_print_symbol): Likewise.
2006 * vms.c (vms_print_symbol): Likewise.
2008 * elf.c (_bfd_elf_print_private_bfd_data): Replace fprintf_vma
2009 with bfd_fprintf_vma.
2010 (bfd_elf_print_symbol): Likewise.
2011 * syms.c (bfd_print_symbol_vandf): Likewise.
2013 2001-08-23 Nick Clifton <nickc@cambridge.redhat.com>
2015 * aoutf1.h (sunos_write_object_contents): Silence compile time
2017 * libaout.h (N_SET_DYNAMIC): Silence compile time warning.
2019 * bout.c: Add missing function prototypes. Fix formatting.
2020 * coff-z8k.c: Add missing function prototypes. Fix formatting.
2021 * coff-w65.c: Add missing function prototypes. Fix formatting.
2022 * coff-h8500.c: Add missing function prototypes. Fix formatting.
2023 * coff-h8300.c: Add missing function prototypes. Fix formatting.
2024 * coff-tic54x.c: Add missing function prototypes. Fix formatting.
2025 * coff-tic30.c: Add missing function prototypes. Fix formatting.
2026 * coff-m68k.c: Add missing function prototypes. Fix formatting.
2027 * coff-rs6000.c: Add missing function prototypes. Fix formatting.
2028 * coff-sh.c: Add missing function prototypes. Fix formatting.
2030 2001-08-23 Jakub Jelinek <jakub@redhat.com>
2032 * elf-bfd.h (enum elf_reloc_type_class): New.
2033 (struct elf_backend_data): Add elf_backend_reloc_type_class.
2034 (_bfd_elf_reloc_type_class): New.
2035 * elfxx-target.h (elf_backend_reloc_type_class): Define.
2036 (elfNN_bed): Add elf_backend_reloc_type_class.
2037 * elf.c (_bfd_elf_reloc_type_class): New.
2038 * elf32-i386.c (elf_i386_check_relocs): Set DF_TEXTREL if the reloc
2039 is against read-only section.
2040 (elf_i386_size_dynamic_sections): Use DF_TEXTREL flag instead of
2041 looking up section names for DT_TEXTREL.
2042 (elf_i386_reloc_type_class): New.
2043 (elf_backend_reloc_type_class): Define.
2044 * elf32-sparc.c (elf32_sparc_check_relocs): Set DF_TEXTREL if the
2045 reloc is against read-only section.
2046 (elf32_sparc_size_dynamic_sections): Use DF_TEXTREL flag instead of
2047 looking up section names for DT_TEXTREL.
2048 (elf32_sparc_reloc_type_class): New.
2049 (elf_backend_reloc_type_class): Define.
2050 * elf64-sparc.c (sparc64_elf_check_relocs): Set DF_TEXTREL if the
2051 reloc is against read-only section.
2052 (sparc64_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
2053 looking up section names for DT_TEXTREL.
2054 (sparc64_elf_reloc_type_class): New.
2055 (elf_backend_reloc_type_class): Define.
2056 * elfxx-ia64.c (struct elfNN_ia64_link_hash_table): Add reltext field.
2057 (elfNN_ia64_hash_table_create): Clear ia64_info.
2058 (get_reloc_section): Set DF_TEXTREL if the reloc is against read-only
2060 (elfNN_ia64_size_dynamic_sections): Use ia64_info->reltext flag
2061 instead of looking up section names for DT_TEXTREL.
2062 (elfNN_ia64_reloc_type_class): New.
2063 (elf_backend_reloc_type_class): Define.
2064 * elflink.h (size_dynamic_sections): Add spare DT_NULL tags.
2065 (struct elf_link_sort_rela): New.
2066 (elf_link_sort_cmp1, elf_link_sort_cmp2, elf_link_sort_relocs): New.
2067 (elf_bfd_final_link): Call elf_link_sort_relocs.
2068 Convert one spare DT_NULL into DT_RELCOUNT resp. DT_RELACOUNT if
2071 2001-08-23 Nick Clifton <nickc@cambridge.redhat.com>
2073 * configure.in (x86-bsdi): No corefile support.
2074 * configure: Regenerate.
2076 2001-08-22 Nick Clifton <nickc@cambridge.redhat.com>
2078 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Add missing
2081 2001-08-21 Mark Elbrecht <snowball3@bigfoot.com>
2083 * coff-go32.c: Make DWARF2 sections use an alignment of 0. Set
2084 the alignment of dwarf2 linkonce sections to 0.
2085 * coff-sto32.c: Likewise.
2087 2001-08-20 Andreas Jaeger <aj@suse.de>
2089 * coff-sparc.c: Add missing prototypes.
2090 * elf32-s390.c: Likewise.
2091 * elf32-i960.c: Likewise.
2092 * aout-target.h: Likewise.
2094 2001-08-20 H.J. Lu <hjl@gnu.org>
2096 * elf-bfd.h (elf_obj_tdata): Add num_section_syms.
2097 (elf_num_section_syms): New for num_section_syms.
2099 * elf.c (elf_map_symbols): Set num_section_syms.
2100 (_bfd_elf_symbol_from_bfd_symbol): Check num_section_syms for
2101 the section symbol index.
2103 2001-08-20 Nick Clifton <nickc@cambridge.redhat.com>
2105 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_create): Never
2106 select the generic has table creator. All elf backends need elf
2107 specific fields in the hash table.
2109 2001-08-20 Alan Modra <amodra@bigpond.net.au>
2111 * archive.c (offsetof): Remove define.
2114 * sysdep.h (offsetof): Define.
2116 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2118 * bfd.c (bfd_get_gp_size): Return an unsigned int.
2119 (bfd_set_gp_size): Make param unsigned.
2120 * bfd-in2.h: Regenerate.
2121 * elf32-ppc.c (ppc_elf_add_symbol_hook): Use elf_gp_size rather
2122 than calling bfd_get_gp_size.
2123 * elf64-alpha.c (elf64_alpha_add_symbol_hook): Likewise.
2124 * elfxx-ia64.c (elfNN_ia64_add_symbol_hook): Likewise.
2126 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2128 * linker.c (default_fill_link_order): Handle four byte fill value.
2130 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2132 * elf64-sparc.c (sparc64_elf_output_arch_syms): Add missing
2134 * nlm32-alpha.c (nlm_alpha_write_external): Fix warning.
2136 * elf64-mips.c (UNUSED_RELOC): Define.
2137 (mips_elf64_howto_table_rel): Use it.
2138 (mips_elf64_howto_table_rela): Here too.
2139 (mips_elf64_write_relocs): Fix signed/unsigned warning.
2141 * coffcode.h (coff_write_object_contents): Add ATTRIBUTE_UNUSED to
2143 * coffgen.c (coff_print_symbol): Fix warnings.
2144 (coff_find_nearest_line): Likewise.
2145 * cofflink.c (_bfd_coff_link_input_bfd): Likewise.
2146 * coff-alpha.c (alpha_convert_external_reloc): Likewise.
2147 * format.c (bfd_check_format_matches): Likewise.
2148 (bfd_set_format): Likewise.
2149 * coff-ia64.c: Add missing prototypes.
2150 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Make addend
2151 signed to silence warnings.
2152 (elf64_alpha_relocate_section): Likewise.
2153 (elf64_alpha_find_reloc_at_ofs): Fix warnings.
2154 (elf64_alpha_add_symbol_hook): Likewise.
2155 (elf64_alpha_final_link): Likewise.
2156 (elf64_alpha_relax_section): Remove redundant assign to info.gotent.
2157 (elf64_alpha_merge_gots): Add ATTRIBUTE_UNUSED to unused args.
2158 (elf64_alpha_size_got_sections): Likewise.
2159 * elfxx-ia64.c: Add missing prototypes.
2160 (elfNN_ia64_relocate_section): Fix warning.
2161 (elfNN_ia64_unwind_entry_compare): Make params const.
2163 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2165 * config.bfd (targ64_selvecs): New.
2166 <powerpc-*-aix* entry>: Use it here instead of ineffectual #ifdef.
2168 * bfd-in.h (BFD_VERSION): Remove wrong comment.
2169 (BFD_DEFAULT_TARGET_SIZE): New.
2170 (BFD_ARCH_SIZE): Comment.
2171 * configure.in (target_size): New. Set instead of target64 in
2172 selvecs case statement. Set target64 from it.
2173 (bfd_default_target_size): New. Set from taget_size. AC_SUBST.
2174 * bfd-in2.h: Regenerate.
2175 * configure: Regenerate.
2177 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2179 * bfd.c (enum bfd_error): Add bfd_error_wrong_object_format.
2180 (bfd_errmsgs): Add corresponding message.
2181 * archive.c (bfd_generic_archive_p): Don't release bfd_ardata when
2182 finding an archive that contains different format object files.
2183 Return bfd_error_wrong_object_format for this case.
2184 * format.c: Formatting fixes. s/CONST/const/.
2185 (bfd_check_format_matches): Accept archives that give
2186 bfd_error_wrong_object_format if no full match is found. Tidy
2187 code handling matching_vector. Don't return a pointer to freed
2188 memory in `matching'. Handle ambiguous matches as for partial
2190 * bfd-in2.h: Regenerate.
2192 2001-08-15 Alan Modra <amodra@bigpond.net.au>
2194 * libieee.h (common_header_type): Add last_byte field.
2196 * ieee.c: Add missing prototypes. Some format fixes.
2197 (struct output_buffer_struct): Move for availability to prototypes.
2198 (ieee_part_after): New function.
2199 (ieee_slurp_debug): Use it here.
2200 (ieee_seek): Pass in ieee_data_struct rather than bfd. Use
2201 ieee_part_after to set last_byte to one past end of current part.
2203 (ieee_pos): Pass in ieee_data_struct rather than bfd.
2205 (parse_expression): Don't go beyond the end of the current part.
2206 (ieee_slurp_external_symbols): Correct type passed to read_2bytes.
2207 (ieee_get_symtab_upper_bound, ieee_get_symtab,
2208 ieee_get_symbol_info, ieee_print_symbol, ieee_new_section_hook,
2209 ieee_get_reloc_upper_bound, ieee_canonicalize_reloc, block,
2210 ieee_set_section_contents, ieee_write_object_contents,
2211 ieee_make_empty_symbol): Make static.
2212 (ieee_archive_p): Correct comments regarding bfd_read.
2213 (ieee_object_p): Similarly.
2214 (ieee_mkobject): Move it. Clear output_ptr_start, output_ptr,
2215 output_ptr_end, input_ptr_start, input_ptr, input_ptr_end,
2216 input_bfd, output_bfd, output_buffer.
2217 (do_as_repeat): Write out ieee_set_current_pc_enum value as for
2218 do_with_relocs, ie. as a symbol for relocatable files.
2219 (ieee_vec): Add comments showing functions referenced by macros.
2221 2001-08-14 Nick Clifton <nickc@cambridge.redhat.com>
2223 * aout-tic30.c: Add missing prototypes. Fix formatting.
2224 * aout-ns32k.c: Add missing prototypes. Fix formatting.
2225 * peXXigen.c: Add missining prototypes. Fix formatting.
2226 * aout-adobe.c: Add missining prototypes. Fix formatting.
2228 2001-08-13 Nick Clifton <nickc@cambridge.redhat.com>
2230 * elf32-v850.c: Add missing function prototypes.
2231 Fix some formatting.
2233 * cpu-v850.c: Add missing function prototype.
2234 Fix some formatting.
2236 2001-08-11 Nick Clifton <nickc@cambridge.redhat.com>
2238 * elf-bfd.h (struct elf_backend_data): Add new fields
2239 'elf_backend_sprintf_vma' and 'elf_backend_fprintf_vma'.
2240 (bfd_elf_sprintf_vma): Rename function prototype to
2241 '_bfd_elf_sprintf_vma'.
2242 (bfd_elf_fprintf_vma): Rename function prototype to
2243 '_bfd_elf_fprintf_vma'.
2244 * bfd.c (bfd_sprintf_vma): Do not invoke bfd_elf_sprintf_vma
2245 directly, instead indirect via the elf_backend_data structure.
2246 (bfd_fprintf_vma): Do not invoke bfd_elf_fprintf_vma directly,
2247 instead indirect via the elf_backend_data structure.
2248 * elf.c (bfd_elf_sprintf_vma): Rename to _bfd_elf_sprintf_vma.
2249 (bfd_elf_fprintf_vma): Rename to _bfd_elf_fprintf_vma.
2250 * elfxx-target.h (elf_backend_sprintf_vma): Initialise if not
2252 (elf_backend_fprintf_vma): Initialise if not already defined.
2253 (struct elf_backend_data): Initialise the
2254 elf_backend_sprintf_vma and elf_backend_fprintf_vma fields.
2256 2001-08-10 Andreas Jaeger <aj@suse.de>
2258 * elf64-sparc.c: Add missing prototypes.
2259 * elf32-cris.c: Likewise.
2260 * elf32-i370.c: Likewise.
2261 * elf64-hppa.c: Likewise.
2262 * elf64-s390.c: Likewise.
2264 2001-08-10 Andreas Jaeger <aj@suse.de>
2266 * elf64-x86-64.c (elf64_x86_64_elf_object_p): Make static.
2267 Add prototypes where needed.
2269 2001-08-10 H.J. Lu <hjl@gnu.org>
2271 * bfd.c (bfd_sprintf_vma): Fix a typo in the last change.
2272 (bfd_fprintf_vma): Likewise.
2274 2001-08-10 H.J. Lu <hjl@gnu.org>
2276 * bfd.c (bfd_sprintf_vma): Don't return void.
2277 (bfd_fprintf_vma): Likewise.
2279 2001-08-10 Andreas Jaeger <aj@suse.de>
2281 * configure.in: Add -Wstrict-prototypes and -Wmissing-prototypes
2283 * configure: Regenerate.
2285 2001-08-10 Alan Modra <amodra@bigpond.net.au>
2287 * elf.c (bfd_elf_sprintf_vma): Add ATTRIBUTE_UNUSED to quiet
2288 warning if not BFD64. Add braces so emacs auto format works.
2289 (bfd_elf_fprintf_vma): Likewise.
2291 * libxcoff.h (struct xcoff_backend_data_rec): Constify src param
2293 * coff-rs6000.c (xcoff_swap_ldhdr_in): Modify type of external
2294 param to agree with libxcoff.h.
2295 (xcoff_swap_ldhdr_out): Likewise.
2296 (xcoff_swap_ldsym_in): Likewise.
2297 (xcoff_swap_ldsym_out): Likewise.
2298 (xcoff_swap_ldrel_in): Likewise.
2299 (xcoff_swap_ldrel_out): Likewise.
2300 (xcoff_create_csect_from_smclas): Likewise.
2301 * coff64-rs6000.c: Add missing prototypes.
2302 (xcoff64_swap_ldhdr_in): Modify type of external param to agree
2304 (xcoff64_swap_ldhdr_out): Likewise.
2305 (xcoff64_swap_ldsym_in): Likewise.
2306 (xcoff64_swap_ldsym_out): Likewise.
2307 (xcoff64_swap_ldrel_in): Likewise.
2308 (xcoff64_swap_ldrel_out): Likewise.
2309 (xcoff64_ppc_relocate_section): Make static.
2310 (xcoff64_slurp_armap): Likewise.
2311 (xcoff64_archive_p): Likewise.
2312 (xcoff64_openr_next_archived_file): Likewise.
2313 (xcoff64_sizeof_headers): Likewise.
2314 (xcoff64_is_lineno_count_overflow): Likewise.
2315 (xcoff64_is_reloc_count_overflow): Likewise.
2316 (xcoff64_loader_symbol_offset): Likewise.
2317 (xcoff64_loader_reloc_offset): Likewise.
2318 * elf64-gen.c: Add missing prototypes.
2320 2001-08-09 H.J. Lu <hjl@gnu.org>
2322 * elf.c (bfd_elf_sprintf_vma): Check ELFCLASS64 only in BFD64.
2323 (bfd_elf_fprintf_vma): Likewise.
2325 2001-08-09 H.J. Lu <hjl@gnu.org>
2327 * bfd-in.h (bfd_elf_sprintf_vma, bfd_elf_fprintf_vma): Moved
2330 * bfd-in2.h: Regenerated.
2332 2001-08-09 H.J. Lu <hjl@gnu.org>
2334 * bfd-in.h (bfd_sprintf_vma): New prototype.
2335 (bfd_fprintf_vma): Likewise.
2336 (bfd_elf_sprintf_vma): Likewise.
2337 (bfd_elf_fprintf_vma): Likewise.
2338 (bfd_printf_vma): New. Defined with bfd_fprintf_vma.
2339 * bfd-in2.h: Regenerated.
2341 * bfd.c (bfd_sprintf_vma): New. Defined.
2342 (bfd_fprintf_vma): Likewise.
2344 * elf.c (bfd_elf_sprintf_vma): New. Defined.
2345 (bfd_elf_fprintf_vma): Likewise.
2347 2001-08-09 Alan Modra <amodra@bigpond.net.au>
2349 * coff-rs6000.c: Add missing prototypes.
2350 (xcoff_ppc_relocate_section, xcoff_is_lineno_count_overflow,
2351 xcoff_is_reloc_count_overflow, xcoff_loader_symbol_offset,
2352 xcoff_loader_reloc_offset): Make static.
2353 * dwarf1.c: Add missing prototypes.
2354 * dwarf2.c: Add missing prototypes.
2355 (struct abbrev_info): Move definition.
2356 (struct attr_abbrev, ABBREV_HASH_SIZE, ATTR_ALLOC_CHUNK): Likewise.
2357 * elf.c: Add missing prototypes.
2358 * elf32-gen.c: Likewise.
2359 * elf32-i386.c: Likewise.
2360 * elf32-ppc.c: Likewise.
2361 (ppc_elf_sort_rela): Use PTR instead of "void *".
2362 * elflink.h: Add missing prototypes. Formatting fixes.
2363 * merge.c: Add missing prototypes.
2364 (last4_eq): Use PTR instead of "void *".
2365 (last_eq): Likewise.
2366 * syms.c: Add missing prototypes.
2368 2001-08-09 Nick Clifton <nickc@cambridge.redhat.com>
2370 * bfd.c: Fix formatting.
2371 * bfd-in2.h: Regenerate.
2373 2001-08-09 Nick Clifton <nickc@cambridge.redhat.com>
2375 * elf32-arc.c (R_ARC_B22_PCREL): Change 'partial_inplace' to
2376 true (this target uses REL relocations) and 'pcrel_offset' to
2377 false (the PC is implied, not stored in the offset).
2379 2001-08-08 Alan Modra <amodra@bigpond.net.au>
2381 1999-10-19 Linus Nordberg <linus@swox.se>
2382 * elf-bfd.h (struct elf_backend_data): Add want_got_sym.
2383 * elfxx-target.h (elf_backend_want_got_sym): Define.
2384 (elfNN_bed): Add elf_backend_want_got_sym.
2385 * elflink.c (_bfd_elf_create_got_section): Define
2386 _GLOBAL_OFFSET_TABLE_ only if bed->want_got_sym.
2388 2001-08-08 Alexandre Oliva <aoliva@redhat.com>
2390 * dwarf2.c (struct dwarf2_debug): Add sec, sec_info_ptr and syms.
2391 (find_rela_addend): New function.
2392 (parse_comp_unit): Call it to find the abbrev offset addend.
2393 (_bfd_dwarf2_find_nearest_line): Initialize and maintain the new
2394 members of dwarf2_debug as debugging information is read.
2396 2001-08-07 Nick Clifton <nickc@cambridge.redhat.com>
2398 * coff-sh.c (sh_coff_reloc_type_lookup): Provide for sh-coff
2399 targets as well as sh-pe.
2401 2001-08-03 Ben Harris <bjh21@netbsd.org>
2403 * elf32-arm.h (elf32_arm_final_link_relocate): Include offset of
2404 reloc from start of section when computing value for R_ARM_REL32
2407 2001-08-03 Alan Modra <amodra@bigpond.net.au>
2409 From H.J. Lu <hjl@gnu.org>
2410 * elf32-i386.c (allocate_plt_and_got_and_discard_relocs): Don't
2411 keep relocs for undefined syms if there are no dynamic sections in
2413 * elf32-hppa.c (allocate_plt_and_got_and_discard_relocs): Likewise.
2415 2001-08-02 Paul Sokolovsky <paul.sokolovsky@technologist.com>
2417 * cofflink.c (coff_link_check_ar_symbols): also search for
2418 __imp__symbol as well as _symbol.
2419 * linker.c (_bfd_generic_link_add_archive_symbols): also
2420 search for __imp__symbol as well as _symbol.
2422 2001-08-01 Adam Nemet <anemet@lnxw.com>
2424 * elf.c (elf_sort_sections): Return zero only as the last step.
2426 2001-08-01 Nick Clifton <nickc@cambridge.redhat.com>
2428 * config.bfd (arm-vxworks): Change name of define from VXWORKS to
2430 (arm-epoc-pe): Define ARM_COFF_BUGFIX.
2431 coff-arm.c (coff_arm_relocate_section): Replace VXWORKS with
2434 2001-07-30 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
2436 * libecoff.h (_bfd_ecoff_styp_to_sec_flags): Changed return type
2437 to match corresponding bfd_coff_backend data member.
2439 2001-07-24 Alan Modra <amodra@bigpond.net.au>
2441 * Makefile.am: Update dependencies with "make dep-am".
2442 * Makefile.in: Regenerate
2444 2001-07-15 H.J. Lu <hjl@gnu.org>
2446 * Makefile.am (po/SRC-POTFILES.in): Use tmp.src instead of tmp.
2447 (po/BLD-POTFILES.in): Use tmp.bld instead of tmp.
2448 * Makefile.in: Regenerate.
2450 2001-07-11 H.J. Lu <hjl@gnu.org>
2452 * elf64-alpha.c (elf64_alpha_check_relocs): Set the ALLOC|LOAD
2453 flags when creating the reloc section if the ALLOC flag in the
2454 source section is set.
2456 2001-07-11 Steve Ellcey <sje@cup.hp.com>
2458 * reloc.c (bfd_reloc_code_type): Add IA64 relocs
2459 BFD_RELOC_IA64_LTOFF_FPTR32MSB and BFD_RELOC_IA64_LTOFF_FPTR32LSB
2460 * bfd-in2.h: Regenerate.
2461 * libbfd.h: Regenerate.
2462 * elfxx-ia64.c (ia64_howto_table): Define how to handle
2464 (elfNN_ia64_reloc_type_lookup): Handle new relocations.
2465 (elfNN_ia64_check_relocs): Likewise.
2466 (elfNN_ia64_install_value): Likewise.
2467 (elfNN_ia64_relocate_section): Likewise.
2469 2001-07-11 Jakub Jelinek <jakub@redhat.com>
2471 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Remove support for
2473 (elf32_sparc_check_relocs): Likewise.
2474 Only create .rela section for alloced sections in shared libraries.
2475 (elf32_sparc_relocate_section): Likewise.
2476 Remove redundant check.
2477 Optimize unaligned reloc usage.
2478 * elf64-sparc.c (sparc64_elf_relocate_section): Remove redundant
2481 2001-07-11 H.J. Lu <hjl@gnu.org>
2483 * elf64-alpha.c (elf64_alpha_check_relocs): Only use the same
2484 ALLOC|LOAD flags as the source section for debugging sections
2485 when creating the reloc section.
2487 2001-07-05 Jim Wilson <wilson@redhat.com>
2489 * linker.c (_bfd_generic_link_add_one_symbol, case BIG): Use
2490 the section of the bigger symbol.
2492 * syms.c (bfd_is_local_label): Return false if BSF_SECTION_SYM.
2494 2001-07-05 Nick Clifton <nickc@cambridge.redhat.com>
2496 * peicode.h (coff_swap_scnhdr_in): For sections containing
2497 uninitialised data, only set their size to s_paddr if this does
2498 not reset their size to zero. MS's latest compilers will set
2501 2001-07-04 H.J. Lu <hjl@gnu.org>
2503 * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing):
2504 Handle bfd_mach_mips4400, bfd_mach_mips4600 and
2507 2001-07-03 Mark Elbrecht <snowball3@softhome.net>
2509 * bfd.c (bfd_get_sign_extend_vma): Support DJGPP COFF targets.
2511 * cofflink.c (_bfd_coff_link_input_bfd): Skip section symbols from
2512 sections being discarded.
2514 2001-06-30 Alan Modra <amodra@bigpond.net.au>
2516 * elfcore.h (elf_core_file_p): Call bfd_section_from_phdr directly
2517 instead of _bfd_elfcore_section_from_phdr.
2518 * elf-bfd.h (_bfd_elfcore_section_from_phdr): Remove.
2519 * elf.c (_bfd_elfcore_section_from_phdr): Remove.
2520 (_bfd_elfcore_make_pseudosection): Expedite tail-call.
2521 (elfcore_grok_prstatus): Likewise.
2522 (elfcore_grok_lwpstatus): Likewise.
2523 (bfd_get_elf_phdr_upper_bound): Likewise.
2524 (elfcore_make_note_pseudosection): Formatting.
2525 (_bfd_elfcore_strndup): Formatting.
2526 * elf32-mips.c (mips_elf_sym_is_global): Formatting.
2527 (_bfd_elf32_mips_grok_prstatus): Expedite tail-call.
2529 2001-06-29 Daniel Jacobowitz <drow@mvista.com>
2531 * elf-bfd.h: Add prototypes for _bfd_elfcore_make_pseudosection
2532 and _bfd_elfcore_strndup.
2533 (struct elf_backend_data): Add elf_backend_grok_prstatus
2534 and elf_backend_grok_psinfo.
2535 * elf.c (_bfd_elfcore_make_pseudosection): New function.
2536 (elfcore_grok_prstatus): Use it.
2537 (elfcore_make_note_pseudosection): Likewise.
2538 (elfcore_strndup): Rename to...
2539 (_bfd_elfcore_strndup): Here, and make global.
2540 (elfcore_grok_psinfo): Use _bfd_elfcore_strndup.
2541 (elfcore_grok_note): Call elf_backend_grok_prstatus
2542 and elf_backend_grok_psinfo if available.
2543 * elf32-mips.c (_bfd_elf32_mips_grok_prstatus): New function.
2544 (_bfd_elf32_mips_grok_psinfo): New function.
2545 (elf_backend_grok_prstatus): Define.
2546 (elf_backend_grok_psinfo): Define.
2547 * elfxx-target.h (elf_backend_grok_prstatus): Default to NULL.
2548 (elf_backend_grok_psinfo): Likewise.
2549 (elfNN_bed): Include elf_backend_grok_prstatus and
2550 elf_backend_grok_psinfo.
2552 2001-06-29 H.J. Lu <hjl@gnu.org>
2554 * elf32-hppa.c (elf32_hppa_finish_dynamic_sections): Check if
2555 hplink->sgot is NULL before filling GOT. Check if hplink->splt
2556 is NULL before filling PLT.
2558 2001-06-29 Alan Modra <amodra@bigpond.net.au>
2560 * elflink.h (elf_link_output_extsym): Revert 1999-04-10.
2562 2001-06-27 Alan Modra <amodra@bigpond.net.au>
2564 * elf32-hppa.c (elf32_hppa_check_relocs): Don't make syms dynamic
2566 (elf32_hppa_adjust_dynamic_symbol): ..nor here..
2567 (allocate_plt_and_got_and_discard_relocs): .. instead do so here
2570 * elf32-hppa.c (RELATIVE_DYNAMIC_RELOCS): Delete.
2571 (IS_ABSOLUTE_RELOC): Define.
2572 (elf32_hppa_link_hash_entry): Always include reloc_entries field.
2573 (hppa_link_hash_newfunc): Always init it.
2574 (elf32_hppa_check_relocs): Mark symbols as ELF_LINK_NON_GOT_REF to
2575 create COPY relocs only when the reloc is in a read-only section.
2576 Instead, allocate space for a dynamic reloc to reference the
2577 library symbol directly. Keep track of space we allocate using
2579 (hppa_discard_copies): Delete, and move code to..
2580 (allocate_plt_and_got): ..here. Rename to
2581 allocate_plt_and_got_and_discard_relocs. Remove unneeded dynamic
2582 relocs for non-shared link.
2583 (elf32_hppa_size_dynamic_sections): Update calls to above.
2584 (elf32_hppa_relocate_section): Write out the dynamic relocs used
2585 in lieu of COPY relocs.
2587 * elf32-i386.c (elf_i386_check_relocs): Don't make syms dynamic
2589 (elf_i386_adjust_dynamic_symbol): ..nor here..
2590 (allocate_plt_and_got_and_discard_relocs): .. instead do so here
2592 (elf_i386_size_dynamic_sections): Fix a comment.
2593 (elf_i386_relocate_section <R_386_32, R_386_PC32>): Rearrange code
2594 involved in writing reloc out.
2596 2001-06-25 Alan Modra <amodra@bigpond.net.au>
2598 * elf32-i386.c (elf_i386_check_relocs <R_386_32, R_386_PC32>):
2599 Ensure syms are dynamic if we might be emitting a reloc.
2600 (allocate_plt_and_got_and_discard_relocs): Don't discard relocs
2601 for undefweak or undefined syms..
2602 (elf_i386_relocate_section <R_386_32, R_386_PC32>): .. and emit.
2604 * elf32-i386.c (allocate_plt_and_got_and_discard_relocs): Discard
2605 relocs without ELF_LINK_HASH_DEF_DYNAMIC set.
2606 (elf_i386_relocate_section <R_386_32, R_386_PC32>): Remove
2607 redundant bfd_link_hash_defined, bfd_link_hash_defweak test.
2609 2001-06-24 H.J. Lu <hjl@gnu.org>
2611 * cpu-i960.c (scan_960_mach): Don't modify const char *. Use
2612 strncasecmp/strcasecmp instead of strncmp/strcmp.
2614 2001-06-23 H.J. Lu <hjl@gnu.org>
2616 * elf32-i386.c (elf_i386_relocate_section <R_386_32, R_386_PC32>):
2617 Check ELF_LINK_HASH_DEF_DYNAMIC to see if a symbol is not defined
2618 in the regular object file and treat the weak definition as
2621 2001-06-23 Alan Modra <amodra@bigpond.net.au>
2623 * elf32-i386.c (elf_i386_relocate_section <R_386_GOT32>): Tighten
2624 unresolved_reloc test to exclude cases where we use "relocation"
2625 before setting it to point into the .got. Reinstate fudge for
2626 unresolved relocs in debugging sections.
2628 * elf32-i386.c (elf_i386_relocate_section): Replace ugly
2629 complicated tests for unresolvable relocs with a simple direct
2630 scheme using "unresolved_reloc" var.
2632 * elf32-i386.c (struct elf_i386_pcrel_relocs_copied): Rename to
2633 elf_i386_dyn_relocs. Update comment.
2634 (struct elf_i386_link_hash_entry): Rename pcrel_relocs_copied to
2636 (elf_i386_adjust_dynamic_symbol): Remove a BFD_ASSERT, change
2638 (allocate_plt_and_got_and_discard_relocs): Replace BFD_ASSERT with
2640 (elf_i386_size_dynamic_sections): Likewise.
2641 (elf_i386_finish_dynamic_symbol): Likewise.
2642 (elf_i386_finish_dynamic_sections): Likewise.
2643 (elf_i386_relocate_section): Likewise. Tidy R_386_GOT32 and error
2646 Avoid creating COPY relocs if possible.
2647 * elf32-i386.c (elf_i386_check_relocs): Tweak condition under
2648 which .got created. Mark symbols used by R_386_32 and R_386_PC32
2649 relocs as ELF_LINK_NON_GOT_REF to create COPY relocs only when the
2650 reloc is in a read-only section. Instead, allocate space for a
2651 dynamic reloc to reference the library symbol directly. Keep
2652 track of space we allocate using pcrel_relocs_copied.
2653 (discard_copies): Delete, and move code to ..
2654 (allocate_plt_and_got): ..here. Rename to
2655 allocate_plt_and_got_and_discard_relocs. Remove unneeded dynamic
2656 relocs for non-shared link.
2657 (elf_i386_size_dynamic_sections): Update calls to above functions.
2658 (elf_i386_relocate_section): Write out the dynamic relocs. Add
2659 more ugly logic to avoid "unresolvable relocation" error. Use
2660 htab shortcut in place of elf_hash_table macro.
2661 (elf_i386_finish_dynamic_sections): Allow that dynamic .got may
2662 not always be created now.
2664 2001-06-20 Bo Thorsen <bo@suse.co.uk>
2666 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix linking of
2669 2001-06-18 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2671 * configure.host (mips64-*-linux): Reformat.
2673 2001-06-21 Alan Modra <amodra@bigpond.net.au>
2675 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Always
2676 allocate local .got space. Use shortcuts from hash table for .got
2677 and .plt rather than comparing section names.
2678 (elf32_hppa_check_relocs): Use local_plt_refcounts var rather than
2679 adjusting index into local_got_refcounts to document what we are
2681 (elf32_hppa_relocate_section): Similarly for local_plt_offsets.
2682 Tidy .got and .plt error checking.
2684 2001-06-20 Catherine Moore <clm@redhat.com>
2686 * elf-bfd.h (struct elf_backend_data):
2687 elf_backend_emit_relocs: New field: Function for emitting
2689 elf_backend_count_relocs: New field: Function for determining
2690 the number of relocs to be emitted.
2691 * elfxx-target.h: Provide default (NULL) values for
2692 elf_backend_emit_relocs and elf_backend_count_relocs.
2693 * elflink.h (elf_link_size_reloc_section): Make the hash table
2694 big enough to hold the relocs counted by either reloc_count or
2696 (elf_bfd_final_link) emit_relocs: New boolean, set if relocs
2697 should be emitted, either because of a command line option
2698 stored in the info structure or because the target provides a
2699 special reloc emitting function.
2700 If the target provides a reloc counting function use it,
2701 unless performing a relocatable link or emitting all relocs.
2702 Also set the SEC_RELOC flag on any output section which will
2704 (elf_link_input_bfd): emit_relocs: New boolean, set if relocs
2705 should be emitted, either because of a command line option
2706 stored in the info structure or because the target provides a
2707 special reloc emitting function.
2708 If the target provides a reloc emitting function, use it,
2709 unless performing a relocatable link or emitting all relocs.
2711 2001-06-20 H.J. Lu <hjl@gnu.org>
2713 * elf32-i386.c (elf_i386_size_dynamic_sections): Always
2714 allocate local .got space.
2716 2001-06-19 Andreas Jaeger <aj@suse.de>
2718 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix creation of
2721 2001-06-18 Hans-Peter Nilsson <hp@axis.com>
2723 * elflink.h (struct elf_assign_sym_version_info): Remove member
2724 export_dynamic. All users changed to use info member.
2725 NAME(bfd_elf,size_dynamic_sections)): Remove parameter
2726 export_dynamic, instead use member in parameter info.
2727 * bfd-in.h (bfd_elf32_size_dynamic_sections,
2728 bfd_elf64_size_dynamic_sections): Update prototype.
2729 * bfd-in2.h: Regenerate.
2731 2001-06-18 H.J. Lu <hjl@gnu.org>
2733 * elflink.h (elf_info_failed): Add a new field, verdefs.
2734 (NAME(bfd_elf,size_dynamic_sections): Pass verdefs to
2736 (elf_export_symbol): Check eif->verdefs to decide if a symbol
2739 2001-06-17 H.J. Lu <hjl@gnu.org>
2741 * elf32-mips.c (mips_elf_link_hash_entry): Add a new field,
2742 readonly_reloc, to record if a relocation in the .rel.dyn
2743 section is against a read-only section.
2744 (mips_elf_link_hash_newfunc): Initialize the readonly_reloc
2746 (_bfd_mips_elf_check_relocs): Record if there is a relocation
2747 in the .rel.dyn section against a read-only section by setting
2748 DF_TEXTREL or readonly_reloc.
2749 (_bfd_mips_elf_copy_indirect_symbol): Copy readonly_reloc if
2751 (_bfd_mips_elf_adjust_dynamic_symbol): Record DF_TEXTREL if
2752 there is a relocation in the .rel.dyn section against a
2754 (_bfd_mips_elf_size_dynamic_sections): Set DT_TEXTREL if
2757 2001-06-12 Nick Clifton <nickc@cambridge.redhat.com>
2759 * coffcode.h (styp_flags_to_sec_flags): Change to a boolean
2760 function. Move flagword result into parameter list. Remove
2761 comment about setting bfd_error_handler to intercept failure
2763 * coffgen.c (make_a_section_from_file): Examine result of
2764 calling bfd_coff_styp_to_sec_flags and pass a failure back to
2766 * ecoff.h (styp_flags_to_sec_flags): Change to a boolean
2767 function. Move flagword result into parameter list.
2768 * libcoff.h: Regenerate.
2769 * libecoff.h: Regenerate.
2771 2001-06-13 Nick Clifton <nickc@cambridge.redhat.com>
2773 * aoutx.h (adjust_z_magic): Only pad the tesxt section if the data
2774 section is going to follow it.
2776 2001-06-12 Catherine Moore <clm@redhat.com>
2778 * elflink.h (elf_gc_propagate_vtable_entries): Replace FILE_ALIGN
2779 with the file_align entry from elf_backend_data.
2780 (elf_gc_smash_unused_vtentry_relocs): Likewise.
2781 (elf_gc_record_vtentry): Likewise.
2783 2001-06-10 Alan Modra <amodra@bigpond.net.au>
2785 * elflink.h: Whitespace changes.
2786 (elf_link_read_relocs_from_section): Use "unsigned int" iterator
2787 rather than "unsigned char".
2788 (elf_link_output_relocs): Likewise.
2789 (elf_link_input_bfd): Likewise.
2790 (elf_reloc_link_order): LIkewise.
2791 * elf.c: s/CONST/const/. Whitespace changes.
2792 * elf32-mips.c: Formatting fix.
2794 * Makefile.am (SOURCE_HFILES): Include xcoff-target.h, remove xcoff.h.
2795 * Makefile.in: Regenerate.
2796 * po/Make-in: Remove trailing tab.
2798 2001-06-09 Philip Blundell <philb@gnu.org>
2800 * elf32-arm.h (elf32_arm_plt0_entry): Correct error in last
2802 (elf32_arm_plt_entry): Likewise.
2804 2001-06-08 H.J. Lu <hjl@gnu.org>
2806 * elf.c (swap_out_syms): Keep names for global section symbols.
2808 2001-06-07 H.J. Lu <hjl@gnu.org>
2810 * config.bfd: Put back ecoff for Linux/mips. Firmwares on some
2811 MIPS-based machines need it.
2813 2001-06-07 H.J. Lu <hjl@gnu.org>
2815 * elf32-mips.c (_bfd_mips_elf_object_p): Set the bad symtab
2818 * config.bfd: Remove ecoff from Linux/mips.
2820 2001-06-07 Andreas Jaeger <aj@suse.de>
2822 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_symbol): Add an
2824 (elf64_x86_64_check_relocs): Fix VTENTRY relocation; set an
2825 alignment of 8 for .rela sections; handle further relocations.
2827 2001-06-06 Christian Groessler <cpg@aladdin.de>
2829 * coff-z8k.c: Fix formatting.
2830 Fix howtos: howto->size was always 1.
2832 2001-06-05 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2834 * configure.host (mips64*-*-linux*): Define.
2836 2001-06-05 Alan Modra <amodra@bigpond.net.au>
2838 * elf32-i386.c (elf_i386_discard_copies): Rename to
2839 discard_copies, and use elf_link_hash_entry arg rather than
2840 elf_i386_link_hash_entry.
2841 (elf_i386_link_hash_traverse): Delete.
2842 (elf_i386_size_dynamic_sections): Adjust call to discard_copies.
2843 Tidy sizing of dynamic sections.
2844 (elf_i386_check_relocs <R_386_32, R_386_PC32>): Reference count
2845 possible .plt entries.
2846 (elf_i386_gc_sweep_hook): Likewise.
2847 (elf_i386_adjust_dynamic_symbol): Discard .plt entries for
2848 everything with plt.refcount <= 0.
2850 * elf32-i386.c (elf_i386_check_relocs): Don't allocate .got and
2852 (elf_i386_gc_sweep_hook): ..and no need to deallocate here..
2853 (elf_i386_adjust_dynamic_symbol): ..and don't allocate .plt and
2855 (allocate_plt_and_got): ..instead do it all here. New function.
2856 (elf_i386_size_dynamic_sections): Allocate local .got space and
2857 call allocate_plt_and_got. No need to zap .relgot if not dynamic.
2858 (bfd_elf32_bfd_final_link): Delete. (ie. use regular final link
2859 rather than gc variety).
2860 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
2861 (elf_i386_relocate_section): Use it here and correct handling of
2862 R_386_GOT32. Provide section and offset for "unresolvable
2863 relocation" error message.
2864 (elf_i386_finish_dynamic_symbol): Correct handling of R_386_GOT32.
2866 * elf32-i386.c (struct elf_i386_link_hash_table): Add sgot,
2867 sgotplt, srelgot, splt, srelplt, sdynbss, srelbss fields.
2868 (elf_i386_link_hash_table_create): Init them.
2869 (create_got_section): New function.
2870 (elf_i386_create_dynamic_sections): New function.
2871 (elf_backend_create_dynamic_sections): Set to above.
2872 (elf_i386_check_relocs): Use shortcuts from hash table rather than
2873 calling bfd_get_section_by_name.
2874 (elf_i386_gc_sweep_hook): Likewise.
2875 (elf_i386_adjust_dynamic_symbol): Likewise.
2876 (elf_i386_size_dynamic_sections): Likewise.
2877 (elf_i386_relocate_section): Likewise.
2878 (elf_i386_finish_dynamic_sections): Likewise.
2880 * elf32-hppa.c (allocate_plt_and_got): Skip indirect and warning syms.
2882 2001-06-02 H.J. Lu <hjl@gnu.org>
2884 * elf32-hppa.c (elf32_hppa_object_p): Check ELFOSABI_LINUX
2886 * elf64-hppa.c (elf64_hppa_object_p): Likewise.
2888 2001-06-02 H.J. Lu <hjl@gnu.org>
2890 * aout-cris.c (MACHTYPE_OK): New. Defined.
2892 2001-06-02 Hans-Peter Nilsson <hp@axis.com>
2894 * section.c (_bfd_strip_section_from_output): Handle NULL
2897 2001-06-02 H.J. Lu <hjl@gnu.org>
2899 * config.bfd (powerpc-*-aix*, powerpc-*-beos*, rs6000-*-*): Add
2900 rs6000coff64_vec only if BFD64 is defined.
2901 (powerpc64-*-aix*): Enable only if BFD64 is defined.
2903 2001-06-02 H.J. Lu <hjl@gnu.org>
2905 * coff-ia64.c (ia64coff_object_p): Rewrite with
2906 external_PEI_DOS_hdr and external_PEI_IMAGE_hdr.
2908 2001-06-01 Andreas Jaeger <aj@suse.de>
2910 * elf64-x86-64.c (elf64_x86_64_relocate_section): Add PC8
2911 relocation, small reformatting.
2913 2001-05-29 Andreas Jaeger <aj@suse.de>
2915 * elf64-x86-64.c (elf64_x86_64_check_relocs): Handle R_X86_64_64.
2916 (elf64_x86_64_relocate_section): Likewise.
2918 2001-05-30 Alan Modra <amodra@one.net.au>
2920 * elf32-hppa.c (elf32_hppa_check_relocs): Don't NEED_PLT for
2921 millicode. Don't allocate .got and .rela.got space here..
2922 (elf32_hppa_gc_sweep_hook): ..and no need to deallocate here..
2923 (elf32_hppa_adjust_dynamic_symbol): ..and don't allocate .plt and
2925 (hppa_handle_PIC_calls): ..nor here..
2926 (allocate_plt_and_got): ..instead do it all here. New function.
2927 (elf32_hppa_size_dynamic_sections): Allocate local .got space and
2928 call allocate_plt_and_got. No need to zap .got if not dynamic.
2929 (elf32_hppa_final_link): Call regular bfd_final_link instead of
2930 gc_common_final_link.
2931 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
2932 (elf32_hppa_relocate_section): Use it here.
2933 (elf32_hppa_finish_dynamic_symbol): Remove superfluous test of
2934 dynamic_sections_created.
2935 (hppa_type_of_stub): Don't LONG_BRANCH_VIA_PLT if millicode sym.
2937 2001-05-28 Andreas Jaeger <aj@suse.de>
2939 * elf64-x86-64.c (elf64_86_64_size_info): Remove, we can use the
2940 generic version since we want a hashsize of 4.
2941 (elf_backend_size_info): Likewise.
2943 2001-05-28 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2945 * elflink.h (elf_link_size_reloc_section): Use bfd_zmalloc instead of
2947 (elf_link_output_relocs): Handle MIPS ELF64 relocations correctly.
2948 (elf_link_input_bfd): Likewise.
2949 (elf_reloc_link_order): Likewise.
2950 (elf_finish_pointer_linker_section): Typo. Handle MIPS ELF64
2951 relocations correctly.
2953 2001-05-28 Nicolas Pitre <nico@cam.org>
2955 * elf32-arm.h: fix PLT generation for big endian ARM
2957 2001-05-28 Alan Modra <amodra@one.net.au>
2959 * elf32-hppa.c (elf32_hppa_relocate_section): Set up .plt entries
2960 for symbols forced local that need plabels.
2961 (elf32_hppa_adjust_dynamic_symbol): Don't allocate space in
2962 .plt.rela for local syms if non-shared.
2963 (hppa_build_one_stub): Mask lsb of plt.offset.
2964 (elf32_hppa_finish_dynamic_symbol): Abort if lsb of plt.offset set.
2965 (clobber_millicode_symbols): Correct comment.
2966 (elf32_hppa_relocate_section): Likewise.
2967 (elf32_hppa_finish_dynamic_symbol): Likewise.
2969 2001-05-28 Jeff Sturm <jsturm@one-point.com>
2971 * reloc.c: Add BFD_RELOC_SPARC_UA16 and BFD_RELOC_SPARC_UA64.
2972 * bfd-in2.h: Regenerate.
2973 * libbfd.h: Regenerate.
2974 * elf32-sparc.c: Enable BFD_RELOC_SPARC_UA16, BFD_RELOC_SPARC_UA32
2975 and BFD_RELOC_SPARC_UA64 mapping
2976 * elf64-sparc.c: Likewise.
2978 2001-05-25 H.J. Lu <hjl@gnu.org>
2980 * Makefile.am (BFD32_BACKENDS): Remove coff-pmac.lo.
2981 (BFD32_BACKENDS_CFILES): Remove coff-pmac.c.
2982 (coff-rs6000.lo): Remove the old dependency.
2983 * Makefile.in: Rebuild.
2985 * configure.in (pmac_xcoff_vec): Replace coff-pmac.lo with
2988 2001-05-25 H.J. Lu <hjl@gnu.org>
2990 * coff-rs6000.c (rs6000coff_vec): Use rs6000coff_core_p,
2991 rs6000coff_core_file_matches_executable_p,
2992 rs6000coff_core_file_failing_command and
2993 rs6000coff_core_file_failing_signal only if AIX_CORE is
2995 (pmac_xcoff_vec): Likewise.
2996 * coff64-rs6000.c (rs6000coff64_vec): Likewise.
2998 2001-05-25 Timothy Wall <twall@redhat.com>
3000 * elfxx-ia64.c (allocate_dynrel_entries): Don't allocate an entry
3001 for __GLOB_DATA_PTR on AIX5. Clean up some relocation bugs.
3003 2001-05-25 H.J. Lu <hjl@gnu.org>
3005 * bfd-in2.h: Regenerated.
3006 * libcoff.h: Likewise.
3008 2001-05-25 Alan Modra <amodra@one.net.au>
3010 * elf32-hppa.c (elf32_hppa_relocate_section): Don't allow
3011 undefined millicode syms in shared libs.
3012 (hppa_build_one_stub): Turn BFD_ASSERTs into aborts.
3013 (elf32_hppa_check_relocs): Likewise.
3014 (elf32_hppa_adjust_dynamic_symbol): Likewise.
3015 (elf32_hppa_size_dynamic_sections): Likewise.
3016 (elf32_hppa_relocate_section): Likewise.
3017 (elf32_hppa_finish_dynamic_symbol): Likewise.
3018 (elf32_hppa_finish_dynamic_sections): Likewise.
3020 2001-05-24 Tom Rix <trix@redhat.com>
3022 * Makefile.am coff-pmac bfd now defined in coff-rs6000.c
3023 xcoff-target.h not used to define rs6000 or ppc bfd.
3026 * bfd-in.h : (struct lineno_cache_entry) promote element "offset"
3029 * coff-rs6000.c : Many changes for 64 bit support. Move common
3030 32/64 code to xcofflink.c. Explictly define the rs6000coff_vec
3033 * coff64-rs6000.c : Many changes for 64 bit support. 64 bit
3034 linker now supported. Explictly define the rs6000coff64_vec.
3036 * coffcode.h : (coff_set_arch_mach_hook) xcoff 64 bit support
3037 (coff_print_aux) same
3038 (coff_write_object_contents) same
3039 (coff_slurp_line_table) same
3041 * coffgen.c : (coff_fix_symbol_name) formatting
3042 (coff_mangle_symbols) xcoff 64 bit support
3043 (coff_write_symbol) same
3044 (coff_write_alien_symbol) same
3045 (coff_write_native_symbol) same
3046 (coff_write_symbols) same
3047 (coff_get_symbol_info) same
3048 (bfd_coff_get_syment) same
3049 (coff_print_symbol) same
3051 * config.bfd : add powerpc64-*-aix* target
3053 * libcoff-in.h : formatting
3055 * libcoff.h : move xcoff extern declarations to libxcoff.h
3057 * libxcoff.h : New file
3059 * xcofflink.c : Many changes for xcoff64 support. Move common
3060 structures to include/coff/xcoff.h. Move specific structure to
3061 backends coff-rs6000.c and coff64-rs6000.c. Use new backend
3062 functions, defined in libxcoff.h, to isolate 32/64 dependencies.
3064 (bfd_xcoff_size_dynamic_sections) : special __rtinit symbol for
3067 (xcoff_build_ldsyms) : handle special __rtinit symbol.
3069 2001-05-23 Alexandre Oliva <aoliva@redhat.com>
3071 * elf64-sparc.c (sparc64_elf_slurp_reloc_table): Fix typo
3074 2001-05-23 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3076 * reloc.c (bfd_reloc_code_real): Add MIPS ELF64 relocations.
3077 * libbfd.h: Regenerate.
3078 * bfd-in2.h: Regenerate.
3080 * aoutx.h (aout_@var{size}_machine_type): Add MIPS r12k support.
3081 * archures.c (bfd_mach_mips12000): Define.
3082 * cpu-mips.c (arch_info_struct): Add MIPS r12k support.
3083 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Add MIPS r12k
3085 (_bfd_mips_elf_size_dynamic_sections): Use official bfd typedef.
3086 * bfd-in2.h: Regenerate.
3087 * elfxx-target.h: Do not redefine bfd_elfNN_bfd_make_debug_symbol.
3089 2001-05-23 kaz Kojima <kkojima@rr.iij4u.or.jp>
3091 * elf32-sh.c (elf_sh_plt0_entry_be, elf_sh_plt0_entry,
3092 elf_sh_plt_entry_be, elf_sh_plt_entry, elf_sh_pic_plt_entry_be,
3093 elf_sh_pic_plt_entry): New PLT code, that does not use r2, since
3094 that is used by GCC.
3096 2001-05-23 Nick Clifton <nickc@cambridge.redhat.com>
3098 * elf-bfd.h (NUM_SHDR_ENTRIES): New macro: compute the number
3099 of entries in a structured section.
3100 * elf.c: Use new macro.
3101 * elf32-i386.c: Use new macro.
3102 * elf32-mips.c: Use new macro.
3103 * elf64-alpha.c: Use new macro.
3104 * elf64-sparc.c: Use new macro.
3105 * elfcode.h: Use new macro.
3106 * elflink.h: Use new macro.
3108 2001-05-23 Nick Clifton <nickc@cambridge.redhat.com>
3110 * bfdint.texi: Replace -oformat with --oformat.
3112 2001-05-21 Andreas Jaeger <aj@suse.de>
3114 * dwarf2.c (decode_line_info): Fix error message.
3115 (read_abbrevs): Fix test for offset as suggested by Alan Modra and
3116 adjust error message.
3118 2001-05-18 H.J. Lu <hjl@gnu.org>
3120 * elflink.h (elf_link_add_object_symbols): Revert the last
3123 2001-05-17 Alan Modra <amodra@one.net.au>
3125 * elf32-hppa.c (clobber_millicode_symbols): Temporarily set
3126 ELF_LINK_FORCED_LOCAL to suit 2001-04-30 change.
3127 (hppa_build_one_stub): Add an assert to check plt.offset.
3129 2001-05-17 H.J. Lu <hjl@gnu.org>
3131 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set the
3132 version definition to basename of the output filename.
3134 2001-05-17 H.J. Lu <hjl@gnu.org>
3136 * elflink.h (elf_link_add_object_symbols): Set DT_NEEDED to
3137 basename of the bfd filename.
3139 2001-05-16 Alan Modra <amodra@one.net.au>
3141 * section.c (asection): Add linker_has_input field.
3142 (STD_SECTION): Adjust initialization to suit.
3143 * ecoff.c (bfd_debug_section): Likewise.
3144 * bfd-in2.h: Regenerate.
3146 2001-05-15 Alexandre Oliva <aoliva@redhat.com>
3148 * elf-m10300.c (mn10300_elf_relax_section): Don't relax
3149 negative 32-bit operands to 16 operands when the operand is
3150 going to be zero-extended by the modified opcode.
3152 2001-05-12 Peter Targett <peter.targett@arccores.com>
3154 * cpu-arc.c (arch_info_struct): Add entry 'base' representing old
3155 name for 'arc5' core versions.
3156 (bfd_arc_arch): Make bfd_mach_arc_6 default.
3158 * elf32-arc.c (arc_elf_object_p): Make E_ARC_MACH_ARC6 default
3160 (arc_elf_final_write_processing): Make bfd_mach_arc_6 default.
3162 2001-05-11 Jakub Jelinek <jakub@redhat.com>
3164 * elfxx-ia64.c (is_unwind_section_name): Consider linkonce unwind
3166 (elfNN_ia64_final_write_processing): Map .gnu.linkonce.ia64unw.FOO
3167 to .gnu.linkonce.t.FOO text section.
3169 2001-05-11 Jakub Jelinek <jakub@redhat.com>
3171 * merge.c (struct sec_merge_hash_entry): Add u.entsize and u.suffix
3172 fields, change sec into secinfo.
3173 (struct sec_merge_info): Add chain, remove last fields.
3174 (struct sec_merge_sec_info): Add next, sec, psecinfo fields.
3175 (sec_merge_hash_lookup): If lookup could not use a string only
3176 because it has bad alignment, mark the old string for deletion.
3177 (sec_merge_add): Add secinfo argument. Don't compute entry's
3178 position, instead record the section.
3179 (sec_merge_emit): Update for the sec into secinfo change in
3180 struct sec_merge_hash_entry.
3181 (_bfd_merge_section): Only record the section for merging, defer
3182 putting strings into the hash table.
3183 (cmplengthentry, last4_eq, last_eq, record_section, merge_strings,
3184 _bfd_merge_sections): New functions.
3185 (_bfd_merged_section_offset): Update for the sec_merge_hash_entry
3187 * libbfd-in.h (_bfd_merge_sections): Add prototype.
3188 (_bfd_nolink_bfd_merge_sections): Define.
3189 * libbfd.h: Likewise.
3190 (bfd_generic_merge_sections): Add prototype.
3191 * targets.c (BFD_JUMP_TABLE_LINK): Add _bfd_merge_sections.
3192 (struct bfd_target): Likewise.
3193 * bfd.c (bfd_merge_sections): Define.
3194 * bfd-in2.h: Rebuilt.
3195 * elf.c (_bfd_elf_merge_sections): New function.
3196 * elf-bfd.h (_bfd_elf_merge_sections): Add prototype.
3197 * elfxx-target.h (bfd_elfNN_bfd_merge_sections): Define.
3198 * reloc.c (bfd_generic_merge_sections): New function.
3199 * vms.c (vms_bfd_merge_sections): New function.
3200 * aout-adobe.c (aout_32_bfd_merge_sections): Define.
3201 * aout-target.h (MY_bfd_merge_sections): Define.
3202 * aout-tic30.c (MY_bfd_merge_sections): Define.
3203 * binary.c (binary_bfd_merge_sections): Define.
3204 * bout.c (b_out_bfd_merge_sections): Define.
3205 * coff-alpha.c (_bfd_ecoff_bfd_merge_sections): Define.
3206 * coffcode.c (coff_bfd_merge_sections): Define.
3207 * coff-mips.c (_bfd_ecoff_bfd_merge_sections): Define.
3208 * i386msdos.c (msdos_bfd_merge_sections): Define.
3209 * i386os9k.c (os9k_bfd_merge_sections): Define.
3210 * ieee.c (ieee_bfd_merge_sections): Define.
3211 * ihex.c (ihex_bfd_merge_sections): Define.
3212 * nlm-target.h (nlm_bfd_merge_sections): Define.
3213 * oasys.c (oasys_bfd_merge_sections): Define.
3214 * ppcboot.c (ppcboot_bfd_merge_sections): Define.
3215 * som.c (som_bfd_merge_sections): Define.
3216 * srec.c (srec_bfd_merge_sections): Define.
3217 * tekhex.c (tekhex_bfd_merge_sections): Define.
3218 * versados.c (versados_bfd_merge_sections): Define.
3219 * xcoff-target.h (_bfd_xcoff_bfd_merge_sections): Define.
3221 2001-05-11 Nick Clifton <nickc@cambridge.redhat.com>
3223 * dwarf1.c (_bfd_dwarf1_find_nearest_line): Change type of 'addr'
3224 to be unsigned long, in order to match its use.
3226 2001-05-10 H.J. Lu <hjl@gnu.org>
3228 * linker.c (_bfd_generic_link_add_one_symbol): Check loop on
3231 2001-05-09 H.J. Lu <hjl@gnu.org>
3233 * elflink.h (elf_link_add_object_symbols): Fix a typo. Allocate
3234 versymhdr->sh_size bytes for extversym instead of hdr->sh_size.
3235 Remove the unused veriable `dynver'.
3237 2001-05-08 Ian Lance Taylor <ian@zembu.com>
3239 * coff-i386.c (coff_i386_reloc): Don't dump core if output_bfd is
3240 NULL or is not COFF.
3241 (coff_i386_rtype_to_howto): Don't dump core if output section
3244 2001-05-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3246 * ecoff.c (bfd_debug_section): Fix initialization.
3247 * elf.c (_bfd_elf_slurp_version_tables): Change maxidx to unsigned, it
3248 is always a positive integer. Cast away sign mismatch.
3249 * elf32-mips.c: Fix misleading comment and typo.
3250 (_bfd_mips_elf_section_from_bfd_section): Remove unused attribute, use
3252 * elflink.c: Fix typo.
3253 (_bfd_elf_create_dynamic_sections): Remove superfluous initialization.
3254 * ecoffswap.h (ecoff_swap_fdr_in): Cast away sign mismatch.
3256 2001-05-04 Richard Henderson <rth@redhat.com>
3258 * elf64-alpha.c (SREL16, SREL32, SREL64): Set pcrel_offset true.
3260 2001-05-04 Nick Clifton <nickc@cambridge.redhat.com>
3262 * elf32-arm.h (elf32_arm_final_link_relocate): Set
3263 EF_ARM_HASENTRY if the start address is set.
3265 2001-05-03 Nick Clifton <nickc@cambridge.redhat.com>
3267 * targets.c (_bfd_target_vector_entries): Compute value based on
3268 the size of the _bfd_target_vector and not bfd_target_vector.
3270 2001-05-03 H.J. Lu <hjl@gnu.org>
3272 * elfcode.h: Include "libiberty.h".
3274 * elflink.h (elf_link_add_object_symbols): Set
3275 elf_dt_name (abfd) to basename of the bfd filename.
3276 (NAME(bfd_elf,size_dynamic_sections)): Set vn_file to basename
3277 of the bfd filename.
3279 2001-05-03 Andreas Jaeger <aj@suse.de>
3281 * elf64-gen.c (elf_generic_info_to_howto): Add unused attribute.
3282 (elf_generic_info_to_howto_rel): Likewise.
3283 * coff-alpha.c (reloc_nil): Likewise.
3284 (alpha_ecoff_bad_format_hook): Likewise.
3285 (alpha_adjust_reloc_out): Likewise.
3286 (alpha_bfd_reloc_type_lookup): Likewise.
3287 (alpha_convert_external_reloc): Likewise.
3288 * elf64-alpha.c (elf64_alpha_reloc_nil): Likewise.
3289 (elf64_alpha_reloc_bad): Likewise.
3290 (elf64_alpha_reloc_gpdisp): Likewise.
3291 (elf64_alpha_bfd_reloc_type_lookup): Likewise.
3292 (elf64_alpha_info_to_howto): Likewise.
3293 (elf64_alpha_add_symbol_hook): Likewise.
3294 (elf64_alpha_create_got_section): Likewise.
3295 (elf64_alpha_is_local_label_name): Likewise.
3296 (elf64_alpha_merge_ind_symbols): Likewise.
3297 * elf64-mips.c (mips_elf64_reloc_type_lookup): Likewise.
3298 (mips_elf64_get_reloc_upper_bound): Likewise.
3299 * nlm32-alpha.c (nlm_alpha_mangle_relocs): Likewise.
3300 (nlm_alpha_get_public_offset): Likewise.
3302 2001-05-02 Johan Rydberg <jrydberg@opencores.org>
3304 * elf32-openrisc.c (openrisc_elf_howto_table): Do not complain
3305 about overflow in R_OPENRISC_LO_16_IN_INSN and
3306 R_OPENRISC_HI_16_IN_INSN.Index: bfd/elf32-openrisc.c
3308 2001-04-30 H.J. Lu <hjl@gnu.org>
3310 * elf.c (_bfd_elf_link_hash_hide_symbol): Set dynindx to -1
3311 only for ELF_LINK_FORCED_LOCAL.
3312 * elf32-hppa.c (elf32_hppa_hide_symbol): Likewise.
3313 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Likewise.
3314 * elfxx-ia64.c (elfNN_ia64_hash_hide_symbol): Likewise.
3316 * elflink.h (elf_fix_symbol_flags): Set ELF_LINK_FORCED_LOCAL
3317 if the symbol has hidden or internal visibility.
3319 2001-04-30 Alan Modra <amodra@one.net.au>
3321 * elf32-hppa.c (final_link_relocate): Branch to .+8 for
3322 calls to undefined weak symbols.
3324 2001-04-30 Andreas Jaeger <aj@suse.de>, Andreas Schwab <schwab@suse.de>
3326 * elf64-x86-64.c (elf64_x86_64_relocate_section): Correct test for
3327 R_X86_64_GOTPCREL, don't use assignments instead of comparisons.
3329 2001-04-27 Andreas Jaeger <aj@suse.de>
3331 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_sections): Only swap
3332 out handled entries.
3333 (elf64_x86_64_finish_dynamic_symbol): Set up GOT entries.
3334 (elf64_x86_64_relocate_section): Fix GOTPCREL calculation.
3335 (elf64_x86_64_relocate_section): Merge entries for GOTPCREL and
3338 2001-04-27 Sean McNeil <sean@mcneil.com>
3340 * config.bfd: Add arm-vxworks target.
3341 * coff-arm (coff_arm_relocate_section): Add in symbol value to
3342 addend (fro VXworks targets).
3344 2001-04-26 H.J. Lu <hjl@gnu.org>
3346 * elf32-i386.c (elf_i386_check_relocs): Verify if r_symndx is
3349 2001-04-25 Frank Ch. Eigler <fche@redhat.com>
3351 * bfd-in.h (bfd_cache_close): Declare newly exported function.
3352 * bfd-in2.h: Regenerated.
3354 2001-04-24 Jakub Jelinek <jakub@redhat.com>
3356 * merge.c (struct sec_merge_hash_entry): Add alignment field.
3357 (struct sec_merge_hash): Remove alignment_power.
3358 (sec_merge_hash_newfunc): Clear alignment.
3359 (sec_merge_hash_lookup): Pass alignment as argument.
3360 Use hashp->root.next, not hashp->next to walk the hash chain.
3361 If a string already in the hashtable does not have required
3362 alignment, create a new hashtable entry.
3363 (sec_merge_init): Remove alignment_power argument.
3364 (sec_merge_add): Add alignment argument.
3365 (sec_merge_emit): Alignment is now a per-entity thing, not per
3367 (_bfd_merge_section): Sanity check even non-SEC_STRINGS sections
3368 for proper alignment.
3369 Pass alignment information to sec_merge_add.
3371 2001-04-24 Christian Groessler <cpg@aladdin.de>
3373 * coff-z8k.c (extra_case): added handler for R_DISP7, R_CALLR
3374 and R_REL16 reloc types; accept odd values for R_REL16 type
3376 2001-04-24 Johan Rydberg <jrydberg@opencores.org>
3378 * cpu-openrisc.c: New file.
3379 * elf32-openrisc.c: Likewise.
3381 * Makefile.am (ALL_MACHINES): Add cpu-openrisc.lo.
3382 (ALL_MACHINES_CFILES): Add cpu-openrisc.c.
3383 (BFD32_BACKENDS): Add elf32-openrisc.lo.
3384 (BFD32_BACKENDS_CFILES): Add elf32-openrisc.c.
3385 (cpu-openrisc.lo, elf32-openrisc.lo): New rules.
3386 * Makefile.in: Regenerated.
3387 * config.bfd: (openrisc-*-elf): New target.
3388 * configure.in (bfd_elf32_openrisc_vec): New vector.
3389 * configure: Regenerated.
3390 * libbfd.h: Regenerated.
3391 * bfd-in2.h: Regenerated.
3392 * reloc.c: Add OpenRISC relocations.
3393 * targets.c (bfd_elf32_openrisc_vec): Declare.
3394 (bfd_target_vect): Add bfd_elf32_openrisc_vec.
3395 * archures.c (enum bfd_architecture): Add bfd_arch_openrisc.
3396 (bfd_openrisc_arch): Declare.
3397 (bfd_archures_list): Add bfd_openrisc_arch.
3398 * elf.c (prep_headers): Add bfd_arch_openrisc.
3400 2001-04-23 Bo Thorsen <bo@suse.de>
3402 * elf64-x86-64.c: Add c++ vtable hack.
3403 Small whitespace and comment changes.
3405 2001-04-19 Andreas Jaeger <aj@suse.de>
3407 * elf64-x86-64.c (elf64_x86_64_plt0_entry): Fix instructions.
3408 (elf64_x86_64_plt_entry): Likewise.
3409 (elf64_x86_64_finish_dynamic_sections): Fix PLT0 generation.
3410 (elf64_x86_64_finish_dynamic_symbol): Fix PLT generation.
3412 2001-04-17 Hans-Peter Nilsson <hp@axis.com>
3414 * elf32-cris.c: Tweak comments related to dynamic linking.
3415 (cris_elf_relocate_section): When not creating shared object, fill
3416 in the .got table for any symbol not in the dynamic symbol table.
3417 (elf_cris_finish_dynamic_symbol): When not creating shared object,
3418 only emit a .got.rela reloc if the symbol is in the dynamic symbol
3420 (cris_elf_check_relocs): Use variable r_type in all places rather
3421 than the original expression. Add default case in switch for
3423 (elf_cris_size_dynamic_sections): Iterate over
3424 elf_cris_discard_excess_program_dynamics when not creating shared
3426 (elf_cris_discard_excess_dso_dynamics): Renamed from
3427 elf_cris_discard_copies. Correct typo, s/Rel/Rela/.
3428 (elf_cris_discard_excess_program_dynamics): New.
3430 2001-04-14 Mark Elbrecht <snowball3@bigfoot.com>
3432 * coffcode.h (coff_write_object_contents): Use
3433 bfd_coff_swap_filehdr_out instead of coff_swap_filehdr_out.
3435 2001-04-14 H.J. Lu <hjl@gnu.org>
3437 * bfd-in2.h: Regenerate.
3439 2001-04-14 Jakub Jelinek <jakub@redhat.com>
3441 * section.c (STD_SECTION): Add entsize.
3443 2001-04-13 H.J. Lu <hjl@gnu.org>
3445 * section.c (SEC_MERGE): Define new flag for merging.
3446 (SEC_STRINGS): Likewise.
3447 (entsize): New field.
3449 2001-04-13 Roger Sayle <roger@metaphorics.com>
3451 * coff-i386.c (TARGET_SYM): SEC_READONLY is an applicable section
3452 flag on pe-i386 targets.
3454 2001-04-13 Jakub Jelinek <jakub@redhat.com>
3456 * libbfd-in.h (_bfd_merge_section): New.
3457 (_bfd_write_merged_section): New.
3458 (_bfd_merged_section_offset): New.
3459 * libbfd.h: Rebuilt.
3460 * linker.c (_bfd_generic_link_output_symbols): Handle
3462 * aoutx.h (aout_link_write_symbols): Likewise.
3463 * pdp11.c (aout_link_write_symbols): Likewise.
3464 * elflink.h (elf_link_add_object_symbols): Call _bfd_merge_section.
3465 (elf_bfd_final_link): Adjust global symbols pointing into SEC_MERGE
3467 (elf_link_sec_merge_syms): New.
3468 (elf_link_input_bfd): Call _bfd_merged_section_offset
3469 and _bfd_write_merged_section.
3470 Handle discard_sec_merge.
3471 * elf-bfd.h (struct elf_link_hash_table): Add merge_info
3473 (struct bfd_elf_section_data): Likewise.
3474 * elf.c (_bfd_elf_make_section_from_shdr): Set SEC_MERGE and
3475 SEC_STRINGS section flags and entsize from their ELF counterparts.
3476 (_bfd_elf_link_hash_table_init): Initialize merge_info.
3477 (elf_fake_sections): Set SHF_MERGE, SHF_STRINGS and sh_entsize
3478 from their BFD counterparts.
3479 * merge.c: New file.
3480 * Makefile.am: Add strtab.lo.
3481 * Makefile.in: Rebuilt.
3483 2001-04-09 Hans-Peter Nilsson <hp@axis.com>
3485 * elflink.h (elf_fix_symbol_flags): For non-default visibilities,
3486 only hide symbols marked STV_INTERNAL or STV_HIDDEN.
3488 2001-04-05 Steven J. Hill <sjhill@cotw.com>
3490 * config.bfd (mips*el*-*-linux-gnu*): Use traditional little
3491 endian MIPS ELF target.
3492 * config.bfd (mips*-*-linux-gnu*): Use traditional big endian
3495 * configure.in (bfd_elf64_tradbigmips_vec): New. Traditional
3496 64bit big endian MIPS ELF target.
3497 (bfd_elf64_tradlittlemips_vec): New. Traditional 64bit little
3498 endian MIPS ELF target.
3499 * configure: Regenerated.
3501 * elf32-mips.c (IRIX_COMPAT): Handle traditional 64bit and
3502 little endian targets.
3503 (mips_elf_sym_is_global): Handle traditional targets.
3505 * elf64-mips.c (bfd_elf64_tradbigmips_vec): New. Traditional
3506 64bit big endian MIPS ELF target.
3507 (bfd_elf64_tradlittlemips_vec): New. Traditional 64bit little
3508 endian MIPS ELF target.
3510 * targets.c: (_bfd_target_vector): Add bfd_elf64_tradbigmips_vec
3511 and bfd_elf64_tradlittlemips_vec.
3513 2001-04-05 David Mosberger <davidm@hpl.hp.com>
3515 * elf32-i386.c (elf_i386_fake_sections): Treat ".reloc" as an
3516 ordinary "progbits" section.
3518 2001-04-04 Alan Modra <alan@linuxcare.com.au>
3520 * elflink.h (elf_fix_symbol_flags): Call elf_backend_hide_symbol
3521 when -Bsymbolic causes a symbol to no longer need a .plt entry.
3523 2001-04-03 David Mosberger <davidm@hpl.hp.com>
3525 * efi-app-ia32.c (ALIGN_SECTIONS_IN_FILE): Deleted.
3527 2001-03-30 H.J. Lu <hjl@gnu.org>
3529 * efi-app-ia32.c (PEI_TARGET_SUBSYSTEM): Rename from ...
3530 (PEI_DEFAULT_TARGET_SUBSYSTEM): This.
3532 2001-03-26 H.J. Lu <hjl@gnu.org>
3534 * elf32-gen.c (elf32_generic_link_add_symbols): New. Check
3535 if there are any relocations for generic ELF.
3536 (bfd_elf32_bfd_link_add_symbols): Defined to
3537 elf32_generic_link_add_symbols.
3538 * elf64-gen.c (elf64_generic_link_add_symbols): New. Check
3539 if there are any relocations for generic ELF.
3540 (bfd_elf64_bfd_link_add_symbols): Defined to
3541 elf64_generic_link_add_symbols.
3543 2001-03-23 Nick Clifton <nickc@redhat.com>
3545 * Makefile.am (BUILD_CFILES): New variable: List of C source
3546 files created in build directory.
3547 (BUILD_HFILES): New variable: List of header files created in
3550 (po/POTFILES.in): Replace rule with empty entry.
3551 (po/SRC-POTFILES.in): New rule: Create a list of source files
3552 in the source directory.
3553 (po/BLD-POTFILES.in): New rule: Create a list of source files
3554 in the build directory.
3555 (MOSTLYCLEAN): Do not delete source files created in build
3557 * Makefile.in: Regenerate.
3558 * configure.in: Insert SRC-POTFILES.in and BLD-POTFILES.in
3560 * configure: Regenerate.
3562 * po/Make-in: Replace occurrences of POTFILES with SRC-POTFILES
3564 Add .. to the search path when building bfd.pot.
3565 Delete POTFILES when performing distclean.
3566 Add comment describing why distclean is broken in maintainer mode.
3567 * po/POTFILES.in: Delete.
3568 * po/SRC-POTFILES.in: New file.
3569 * po/BLD-POTFILES.in: New file.
3570 * po/bfd.pot: Regenerate.
3572 2001-03-22 Hans-Peter Nilsson <hp@axis.com>
3574 * elf32-cris.c: Shlib and PIC support. PCREL tweaks.
3575 (elf_cris_discard_copies, elf_cris_adjust_gotplt_to_got,
3576 elf_cris_try_fold_plt_to_got, elf_cris_link_hash_newfunc,
3577 elf_cris_link_hash_table_create, elf_cris_adjust_dynamic_symbol,
3578 elf_cris_size_dynamic_sections, elf_cris_finish_dynamic_symbol,
3579 elf_cris_finish_dynamic_sections,elf_cris_hide_symbol): New
3581 (cris_elf_howto_table) <R_CRIS_8_PCREL, R_CRIS_16_PCREL,
3582 R_CRIS_32_PCREL>: Correct comments. Set pcrel_offset to false.
3583 <R_CRIS_COPY, R_CRIS_GLOB_DAT, R_CRIS_JUMP_SLOT, R_CRIS_RELATIVE,
3584 R_CRIS_16_GOT, R_CRIS_32_GOT, R_CRIS_16_GOTPLT, R_CRIS_32_GOTPLT,
3585 R_CRIS_32_GOTREL, R_CRIS_32_PLT_GOTREL, R_CRIS_32_PLT_PCREL>:
3586 New HOWTO members for new relocs.
3587 (cris_reloc_map): Map new relocs.
3588 (ELF_DYNAMIC_INTERPRETER): Define.
3589 (PLT_ENTRY_SIZE): Define.
3590 (elf_cris_plt0_entry, elf_cris_plt_entry, elf_cris_pic_plt0_entry,
3591 elf_cris_pic_plt_entry): New, PLT templates.
3592 (struct elf_cris_pcrel_relocs_copied, struct
3593 elf_cris_link_hash_entry, struct elf_cris_link_hash_table): New.
3594 (elf_cris_link_hash_traverse, elf_cris_hash_table): Define.
3595 (cris_final_link_relocate): Check that 16-bit GOT relocs have
3596 positive values. Adjust PCREL relocs to be relative to location
3598 (cris_elf_relocate_section): Handle relocations to dynamic
3599 objects. Handle new relocations. Call error handler when seeing
3600 non-PIC relocation for read-only sections while generating shared
3602 (cris_elf_check_relocs): Set reference counts for GOT and PLT
3604 (bfd_elf32_bfd_link_hash_table_create,
3605 elf_backend_adjust_dynamic_symbol,
3606 elf_backend_size_dynamic_sections,
3607 elf_backend_finish_dynamic_symbol,
3608 elf_backend_finish_dynamic_sections,
3609 elf_backend_create_dynamic_sections, bfd_elf32_bfd_final_link,
3610 elf_backend_hide_symbol, elf_backend_want_got_plt,
3611 elf_backend_plt_readonly, elf_backend_want_plt_sym,
3612 elf_backend_got_header_size, elf_backend_plt_header_size):
3615 * reloc.c: (BFD_RELOC_CRIS_COPY, BFD_RELOC_CRIS_GLOB_DAT,
3616 BFD_RELOC_CRIS_JUMP_SLOT, BFD_RELOC_CRIS_RELATIVE,
3617 BFD_RELOC_CRIS_32_GOT, BFD_RELOC_CRIS_16_GOT,
3618 BFD_RELOC_CRIS_32_GOTPLT, BFD_RELOC_CRIS_16_GOTPLT,
3619 BFD_RELOC_CRIS_32_GOTREL, BFD_RELOC_CRIS_32_PLT_GOTREL,
3620 BFD_RELOC_CRIS_32_PLT_PCREL): New relocs.
3621 * bfd-in2.h, libbfd.h: Regenerate.
3623 2001-03-21 Diego Novillo <dnovillo@redhat.com>
3625 (_bfd_mips_elf_relocate_section): Give a better error message when
3626 a relocation is not recognized.
3628 2001-03-21 Alan Modra <alan@linuxcare.com.au>
3630 * elf32-hppa.c (elf32_hppa_set_gp): Check sec->output_section
3631 non-NULL before attempting to dereference.
3633 2001-03-20 H.J. Lu <hjl@gnu.org>
3635 * configure.in: Remove the redundent AC_ARG_PROGRAM.
3636 * configure: Rebuild.
3638 2001-03-20 Andreas Schwab <schwab@suse.de>
3640 * elf32-m68k.c (elf_m68k_relocate_section): Don't need the
3641 relocation value when resolving a reference from a debugging
3644 2001-03-16 Scott Thomason <SThomaso@hii.com>
3646 * coff64-rs6000.c (xcoff64_swap_sym_out): Fix syntax errors.
3647 (xcoff64_swap_sym_out): Fix syntax errors.
3649 2001-03-16 Richard Sandiford <rsandifo@redhat.com>
3651 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix warning.
3653 2001-03-15 Alan Modra <alan@linuxcare.com.au>
3655 * elf32-hppa.c (elf32_hppa_link_hash_entry): Add maybe_pic_call.
3656 (hppa_link_hash_newfunc): Init it.
3657 (hppa_type_of_stub): Only use non-PIC to PIC call stub if caller
3658 section appears to be non-PIC.
3659 (final_link_relocate): Likewise.
3660 (elf32_hppa_adjust_dynamic_symbol): Set maybe_pic_call for any
3661 possible candidate function, and set pic_call for those that will
3662 only have a .plt entry for the PIC call stub.
3663 (hppa_handle_PIC_calls): Set maybe_pic_call.
3665 2001-03-12 DJ Delorie <dj@redhat.com>
3667 * elf32-sh.c (sh_elf_relocate_section): Only relocation
3668 R_SH_DIR8WP* relocs if they're against external symbols, else
3669 they're just for relaxing. Validate the reloc values.
3671 2001-03-12 Stefan Geuken <mail@stefan-geuken.de>
3673 * binary.c (bfd_external_binary_architecture): Declare.
3674 (binary_object_p): If bfd_external_binary_architecture is defined,
3675 set the architecture to this string.
3677 2001-03-11 Philip Blundell <philb@gnu.org>
3679 * elf32-arm.h (elf32_arm_finish_dynamic_symbol): Don't make PLT
3680 entries that could serve as a definition for a weak symbol.
3682 2001-03-08 Nick Clifton <nickc@redhat.com>
3684 * Most files: Update copyright notices using Perl script created
3685 by Kevin Buettner <kevinb@redhat.com>.
3687 2001-03-07 Nick Clifton <nickc@redhat.com>
3689 * elf32-arm.h (elf32_arm_final_link_relocate): Conditionalise
3690 prior patch on ! defined OLD_ARM_ABI.
3692 2001-03-07 Andreas Jaeger <aj@suse.de>
3694 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix handling of
3695 some relocation values.
3697 2001-03-06 Nick Clifton <nickc@redhat.com>
3699 * elf32-arm.h (elf32_arm_final_link_relocate): Clear bit zero
3700 of offset in BLX(1) instruction.
3701 * coff-arm.c (coff_arm_relocate_section): Clear bit zero of
3702 offset in BLX(1) instruction.
3705 2001-03-06 Nick Clifton <nickc@redhat.com>
3707 * coff-arm.c (coff_arm_reloc_type_lookup): Add
3708 BFD_RELOC_THUMB_PCREL_BLX.
3710 2001-03-06 Igor Shevlyakov <igor@windriver.com>
3712 * archures.c (bfd_default_scan): Add Coldfire CPUs.
3713 * bfd-in2.h: Regenerate.
3714 * cpu-m68k.c: Add Coldfire CPUs for arch table.
3715 * ieee.c (ieee_write_processor): Set proper id for
3718 2001-03-01 D.J. Barrow <djbarrow@de.ibm.com,barrow_dj@yahoo.com>
3720 * configure.in: Add s390 target.
3721 * configure: Regenerate.
3723 2001-02-28 Andreas Jaeger <aj@suse.de>
3725 * elf64-x86-64.c (elf64_x86_64_relocate_section): Add relocation
3728 2001-02-28 Philip Blundell <pb@futuretv.com>
3730 * elf32-arm.h: Update mentions of renamed EF_xx constants.
3731 (elf32_arm_print_private_bfd_data): Handle ARM EABI version 2.
3733 2001-02-27 H.J. Lu <hjl@gnu.org>
3735 * aoutx.h (NAME(aout,bfd_free_cached_info)): Return true if
3736 abfd->tdata.aout_data == NULL.
3738 2001-02-27 Alan Modra <alan@linuxcare.com.au>
3740 * elf32-hppa.c: Correct field selector in stub comments.
3741 (clobber_millicode_symbols): Formatting fix.
3743 * configure.in: Bump version to 2.11.90.
3744 * configure: Regenerate.
3745 * Makefile.am (CFILES): Rename to SOURCE_CFILES.
3746 (CFILES): $SOURCE_CFILES + generated C files.
3747 (POTFILES): Include $HFILES not $SOURCE_HFILES.
3749 * Makefile.in: Regenerate.
3750 * doc/Makefile.in: This too.
3752 2001-02-26 Timothy Wall <twall@cygnus.com>
3754 * elfxx-ia64.c (elfNN_ia64_aix_add_symbol_hook): Remove obsolete
3757 2001-02-26 Nick Clifton <nickc@redhat.com>
3759 * coffcode.h (styp_to_sec_flags) [COFF_WITH_PE version]: Tidy
3760 up, replacing multiple if statements with a switch.
3761 (handle_COMDAT): New function.
3763 2001-02-26 H.J. Lu <hjl@gnu.org>
3765 * coffcode.h (styp_to_sec_flags) [COFF_WITH_PE version]: Issue
3766 a warning for section flags we do not handle instead of
3769 2001-02-26 Andreas Jaeger <aj@suse.de>
3771 * elf64-x86-64.c (x86_64_elf_howto_table): Fix order of entries.
3773 2001-02-22 Timothy Wall <twall@cygnus.com>
3775 * config.bfd (targ_cpu): Add vectors for ia64-*-aix* (aka Monterey).
3776 * configure.in: Add objects for elf64_ia64_aix vectors.
3777 * configure: Regenerated.
3778 * configure.host: Recognize ia64-*-aix*.
3779 * elfxx-ia64.c: Add hooks for ELF64 on AIX5. Define new vectors
3780 for AIX. AIX5 requires most relocations to be dynamic (*all*
3781 binaries are somewhat similar to shared libraries).
3782 * targets.c: Add elf64_ia64_aix vectors.
3784 2001-02-21 David Mosberger <davidm@hpl.hp.com>
3786 * cpu-ia64-opc.c (elf64_ia64_operands}: Fix typo: error string for
3787 C8 said "1" instead of "8". Clarify error string for IMM22:
3788 "signed integer" instead of just "integer".
3790 2001-02-20 Andreas Jaeger <aj@suse.de>
3792 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_symbol): Don't make
3793 PLT entries that could serve as a definition for a weak symbol.
3795 2001-02-19 Jakub Jelinek <jakub@redhat.com>
3797 * elf32-sparc.c (elf32_sparc_finish_dynamic_symbol): Don't make PLT
3798 entries that could serve as a definition for a weak symbol.
3799 * elf64-sparc.c (sparc64_elf_finish_dynamic_symbol): Likewise.
3801 2001-02-18 David O'Brien <obrien@FreeBSD>
3803 * configure.in: Recognize FreeBSD/arm, FreeBSD/PowerPC, and treat
3804 FreeBSD/i386-CURRENT differently until I can figure out the needed
3806 * configure: Regenerate.
3807 * config.bfd: Recognize FreeBSD/x86-64, FreeBSD/ia64, FreeBSD/arm,
3808 FreeBSD/PowerPC, and FreeBSD/sparc64.
3810 2001-02-18 lars brinkhoff <lars@nocrew.org>
3812 * Makefile.am: Add PDP-11 a.out target.
3813 * config.bfd: Likewise.
3814 * configure.in: Likewise.
3815 * targets.c: Likewise.
3816 * archures.c: Likewise.
3817 * bfd-in2.h: Likewise. Add PDP-11 relocations.
3818 * libbfd.h: Add PDP-11 relocations.
3819 * reloc.c: Likewise.
3820 * cpu-pdp11.c: New file.
3821 * pdp11.c: New file.
3823 * libaout.h (GET_WORD) [ARCH_SIZE==16]: Define.
3824 (GET_SWORD) [ARCH_SIZE==16]: Likewise.
3825 (GET_SWORD) [ARCH_SIZE==16]: Likewise.
3826 (PUT_WORD) [ARCH_SIZE==16]: Likewise.
3827 (GET_MAGIC): New macro.
3828 (PUT_MAGIC): Likewise.
3829 * aout-target.h (MY(object_p)): Use GET_MAGIC to read magic word.
3831 2001-02-18 Jim Kingdon <jkingdon@engr.sgi.com>
3833 * irix-core.c (irix_core_core_file_p): Set the architecture (GDB
3834 multiarch needs it).
3836 2001-02-18 H.J. Lu <hjl@gnu.org>
3838 * elflink.h (elf_link_input_bfd): Ignore invalid section symbol
3841 2001-02-18 Kazu Hirata <kazu@hxi.com>
3843 * vms-misc.c: Fix formatting.
3845 2001-02-16 Kazu Hirata <kazu@hxi.com>
3847 * vms.c: Fix formatting.
3849 2001-02-14 H.J. Lu <hjl@gnu.org>
3851 * elf.c (elf_find_function): New function.
3852 (_bfd_elf_find_nearest_line): Call elf_find_function () to find
3853 the file name and function name.
3855 2001-02-14 Nick Clifton <nickc@redhat.com>
3857 * ecoff.c (bfd_debug_section): Update to initialise new fields in
3860 * Makefile.am (BFD32_BACKENDS_CFILES): Remove peigen.c
3861 (BFD64_BACKENDS): Add pepigen.c
3862 Add rules to create peigen.c and pepigen.c from peXXigen.c.
3864 * Makefile.in: Regenerate.
3865 * configure: Regenerate.
3866 * po/POTFILES.in: Regenerate.
3867 * po/bfd.pot: Regenerate.
3869 2001-02-14 H.J. Lu <hjl@gnu.org>
3871 * libcoff-in.h (pe_tdata): Add members target_subsystem and
3872 force_minimum_alignment.
3874 2001-02-14 Bo Thorsen <bo@suse.de>
3876 * elf64-x86-64.c: Small formatting fixes and rearrangements of code.
3877 (elf64_86_64_size_info): Struct added to fix a problem
3878 with the hashtable string entries.
3879 (elf64_x86_64_adjust_dynamic_symbol): Add generation of .got.plt.
3880 (elf64_x86_64_size_dynamic_sections): A FIXME removed.
3881 (elf64_x86_64_size_dynamic_sections): Fix a dynamic entry and
3882 remove the FIXME for this.
3883 (elf64_x86_64_adjust_dynamic_symbol): Fix check for unneeded .plt
3884 section. Also removed the FIXME for it.
3885 (x86_64_elf_howto_table): Use bfd_elf_generic_reloc.
3886 (ELF_DYNAMIC_INTERPRETER): Fix the name of the dynamic linker.
3887 (elf64_x86_64_finish_dynamic_sections): Enable .got.plt writing.
3889 2001-02-13 Richard Henderson <rth@redhat.com>
3891 * elfxx-ia64.c (elfNN_ia64_final_link): Set __gp if required
3892 and not user provided.
3894 2001-02-13 Kazu Hirata <kazu@hxi.com>
3896 * vms.c (vms_print_symbol): Remove unreachable code.
3898 * rs6000-core.c: Fix formatting.
3900 2001-02-13 David Mosberger <davidm@hpl.hp.com>
3902 * peicode.h (coff_swap_filehdr_out) [COFF_IMAGE_WITH_PE]: Define
3903 as _bfd_XXi_only_swap_filehdr_out.
3904 (pe_mkobject) [PEI_FORCE_MINIMUM_ALIGNMENT]: Set
3905 pe->force_minimum_alignment to TRUE.
3906 (pe_mkobject) [PEI_TARGET_SUBSYSTEM]: Set pe->target_subsystem to
3907 PEI_TARGET_SUBSYSTEM.
3908 (pe_print_private_bfd_data): Call
3909 _bfd_XX_print_private_bfd_data_common() instead of
3910 _bfd_pe_print_private_bfd_data_common().
3911 (pe_bfd_copy_private_bfd_data): Call
3912 _bfd_XX_bfd_copy_private_bfd_data_common() instead of
3913 _bfd_pe_bfd_copy_private_bfd_data_common().
3914 (coff_bfd_copy_private_section_data): Define as
3915 _bfd_XX_bfd_copy_private_section_data instead of
3916 _bfd_pe_bfd_copy_private_section_data.
3917 (coff_get_symbol_info): Define as _bfd_XX_get_symbol_info instead
3918 of a _bfd_pe_get_symbol_info.
3922 * peXXigen.c: Renamed from peigen.c.
3923 (COFF_WITH_XX): Define this macro (will get expanded into
3924 COFF_WITH_pep or COFF_WITH_pe, depending on whether this is being
3925 compiled as peigen.c or pepigen.c.
3926 [COFF_WITH_pep]: Include "coff/ia64.h" instead of "coff/i386.h" to
3927 define the canonical PEP structures and definitions.
3928 (_bfd_XXi_swap_aouthdr_out): If pe->force_minimum_alignment is in
3929 effect, enforce minimum file and section alignments. If
3930 extra->Subsystem is IMAGE_SUBSYSTEM_UNKNOWN, set it to
3931 pe->target_subsystem (this defaults to IMAGE_SUBSYSTEM_UNKNOWN,
3932 so, by default, this is a no-op).
3934 * libpei.h: Rename COFF_WITH_PEP to COFF_WITH_pep.
3935 (_bfd_XX_bfd_copy_private_bfd_data_common): Add macros to map
3936 _bfd_XXfoo to _bfd_pepfoo if COFF_WIT_PEP is defined and to
3937 _bfd_pefoo if it's not defined. Use these macros to define
3940 * libcoff.h (pe_tdata): Add members target_subsystem and
3941 force_minimum_alignment.
3943 * efi-app-ia64.c (COFF_WITH_pep): Rename COFF_WITH_PEP to
3945 (PEI_TARGET_SUBSYSTEM): Rename from PEI_DEFAULT_TARGET_SUBSYSTEM.
3947 * configure.in (bfd_efi_app_ia64_vec): Use pepigen.lo instead of
3950 * coff-ia64.c: Rename COFF_WITH_PEP to COFF_WITH_pep.
3951 (AOUTSZ): Rename PEP64AOUTSZ and PEP64AOUTHDR to PEPAOUTSZ and
3954 * Makefile.in (BFD64_BACKENDS): Mention pepigen.lo.
3955 (BFD64_BACKENDS_CFILES): Mention pepigen.c
3956 (peigen.c): Add rule to generate from peXXigen.c.
3958 (pepigen.lo): List dependencies for pepigen.lo.
3960 2001-02-13 Alan Modra <alan@linuxcare.com.au>
3962 * elf32-hppa.c (elf32_hppa_set_gp): Handle weak $global$. If
3963 $global$ referenced but not defined, set its value here.
3965 2001-02-09 Bo Thorsen <bo@suse.de>
3967 * elf64-x86-64.c (elf64_x86_64_check_relocs): Set .rela.got section
3969 (elf64_x86_64_check_relocs): Write R_X86_64_GOTPCREL GOT entry
3971 (elf64_x86_64_relocate_section): Fix formatting.
3972 (elf64_x86_64_relocate_section): Fix addend for relocation of
3973 R_X86_64_(8|16|32|PC8|PC16|PC32).
3975 2001-02-12 Jan Hubicka <jh@suse.cz>
3977 * elf64-x86-64.c (x86_64_elf_howto): Fix name of R_X86_64_GOTPCREL.
3979 2001-02-11 H.J. Lu <hjl@gnu.org>
3981 * elflink.h (elf_bfd_final_link): Use file_align for SYMTAB
3984 2001-02-11 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
3986 * elf32-mips.c (mips_elf_create_dynamic_relocation): Undo patch
3987 from 2000-10-13. Do not add the symbol's value for R_MIPS_REL32
3988 relocations against dynsym symbols.
3990 * elf32-mips.c (elf_mips_howto_table): Fix the comment on
3991 the R_MIPS_26 relocation.
3992 (mips_elf_calculate_relocation): Use (p + 4) instead of p for
3993 the R_MIPS_26 relocation.
3994 (mips_elf_perform_relocation): Fix the comment on the R_MIPS16_26
3996 * elf64-mips.c (mips_elf64_howto_table_rel): Fix the comment on
3997 the R_MIPS_26 relocation.
3998 (mips_elf64_howto_table_rela): Likewise.
4000 * elf32-mips.c (struct mips_elf_link_hash_entry): Added no_fn_stub
4001 member to mark symbols that have non-CALL relocations against
4003 (mips_elf_link_hash_newfunc): Initialize no_fn_stub.
4004 (mips_elf_calculate_relocation): Handle R_MIPS_CALL16 like
4006 (_bfd_mips_elf_check_relocs): Set no_fn_stub for a symbol if a
4007 non-CALL relocation against it is encountered.
4008 (_bfd_mips_elf_copy_indirect_symbol): Merge no_fn_stub as well.
4009 (_bfd_mips_elf_adjust_dynamic_symbol): Only create a stub if
4010 no_fn_stub is not set.
4012 * elf32-mips.c (mips_elf_output_extsym): Get the output section
4013 information from the real symbol for indirect ones.
4014 Check no_fn_stub to find out if a symbol has a function stub
4017 2001-02-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
4019 * Makefile.am (stamp-lib): ranlib the libbfd.a in the build directory.
4020 * Makefile.in: Regenerate.
4022 2001-02-09 David Mosberger <davidm@hpl.hp.com>
4024 * elfxx-ia64.c (is_unwind_section_name): New function. Returns
4025 true if section name is an unwind table section name.
4026 (elfNN_ia64_additional_program_headers): Count each unwind section
4028 (elfNN_ia64_modify_segment_map): Install one unwind program header
4029 for each unwind separate section. Note: normally the linker
4030 script merges the unwind sections that go into a single segment,
4031 so this still generates at most one unwind program header per
4034 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Accept any section
4035 name for SHT_IA_64_UNWIND, not just .IA_64.unwind.
4036 (elfNN_ia64_fake_sections): Mark sections with names that start
4037 with .IA_64.unwind but not with .IA_64.unwind_info as an IA-64
4040 * elfxx-ia64.c (elfNN_ia64_final_write_processing): New function.
4041 Use it to make sh_info in unwind section point to the text section
4044 2001-02-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
4046 * Makefile.am: Add linux target for S/390.
4047 * archures.c: Likewise.
4048 * bfd-in2.h: Likewise.
4049 * config.bfd: Likewise.
4050 * configure.in: Likewise.
4052 * libbfd.h: Likewise.
4053 * targets.c: Likewise.
4054 * cpu-s390.c: New file.
4055 * elf32-s390.c: New file.
4056 * elf64-s390.c: New file.
4058 2001-02-09 Nick Clifton <nickc@redhat.com>
4060 * peigen.c (_bfd_pe_get_symbol_info): Suppress addition of
4061 ImageBase. This has already been done by coff_swap_hdr_in.
4063 2001-02-09 Jakub Jelinek <jakub@redhat.com>
4065 * elf64-sparc.c (sparc64_elf_copy_private_bfd_data): New function.
4067 2001-02-09 Jakub Jelinek <jakub@redhat.com>
4069 * elf64-sparc.c (sparc64_elf_check_relocs): Don't trust reloc_count.
4070 (sparc64_elf_relocate_section): Likewise.
4072 2001-02-09 Mark Kettenis <kettenis@gnu.org>
4074 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Treat R_SPARC_UA32
4075 similar to R_SPARC_32.
4076 * elf64-sparc.c (sparc64_elf_howto_table): Likewise.
4078 2001-02-08 H.J. Lu <hjl@gnu.org>
4080 * elf32-i386.c (elf_i386_check_relocs): Reserve R_386_PC32
4081 relocation entries for weak definitions when building DSO with
4084 2001-02-08 Richard Henderson <rth@redhat.com>
4086 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Respect weakness
4087 before visibility. Locally defined protected symbols are not
4090 2001-02-08 Geoffrey Keating <geoffk@redhat.com>
4092 * config.bfd: Enable coff64 for rs6000-*. Patch from
4093 <hzoli@austin.ibm.com>.
4095 2001-02-07 Mark Elbrecht <snowball3@bigfoot.com>
4097 * coffgen.c (coff_find_nearest_line): If stabs info is successfully
4098 found, do not attempt to find dwarf2 info before returning.
4100 2001-02-07 Jakub Jelinek <jakub@redhat.com>
4102 * elflink.h (is_global_symbol_definition): Rename to
4103 is_global_data_symbol_definition and have it reject function
4105 (elf_link_is_defined_archive_symbol): Use renamed function.
4107 2001-02-07 Todd Vierling <tv@wasabisystems.com>
4109 * libbfd-in.h (bfd_target_vector): Change extern array to pointer.
4110 * libbfd.h (bfd_target_vector): Likewise.
4111 * targets.c (bfd_target_vector): Rename to _bfd_target_vector and
4112 make static; create pointer reference named bfd_target_vector.
4113 (_bfd_target_vector_entries): Calculate this based on the array
4114 typed _bfd_target_vector.
4116 2001-02-06 H.J. Lu <hjl@gnu.org>
4118 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Only hidden and
4119 internal symbols are not dynamic.
4120 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise.
4122 2001-02-06 Nick Clifton <nickc@redhat.com>
4124 * Makefile.am (BFD64_BACKENDS_CFILES): Remove elf64-ia64.c, so
4125 that it will not be pulled into the list of files that make up
4127 * Makefile.in: Regenerate.
4128 * po/bfd.pot: Regenerate.
4130 2001-02-06 H.J. Lu <hjl@gnu.org>
4132 * peicode.h (coff_swap_filehdr_in): Remove the e_magic
4134 (pe_bfd_object_p): Rewrite with external_PEI_DOS_hdr and
4135 external_PEI_IMAGE_hdr.
4137 2001-02-06 Kazu Hirata <kazu@hxi.com>
4139 * elf-m10200.c: Fix formatting.
4141 2001-02-04 Nick Clifton <nickc@redhat.com>
4143 * elf32-v850.c (v850_elf_reloc): Do not convert reloc addend to PC
4144 rel, it will be handled later on.
4146 2001-02-02 Fred Fish <fnf@ninemoons.com>
4148 * Makefile.in: Fix typo.
4150 2001-02-01 Kazu Hirata <kazu@hxi.com>
4152 * elf-m10300.c: Fix formatting.
4154 2001-01-30 Alan Modra <alan@linuxcare.com.au>
4156 * elf64-hppa.c (elf64_hppa_elf_get_symbol_type): New function.
4157 (elf_backend_get_symbol_type): Define.
4158 (elf64_hppa_object_p): Set architecture and machine from elf
4161 2001-01-30 Curtis L. Janssen <cljanss@ca.sandia.gov>
4163 * elf64-alpha.c (elf64_alpha_find_nearest_line): Query dwarf2
4166 2001-01-26 Richard Henderson <rth@redhat.com>
4168 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Return false
4169 for non-default visibility.
4170 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise, but
4171 delete ugly macro and replace with pretty function.
4173 2001-01-25 Mark Elbrecht <snowball3@bigfoot.com>
4175 * coff-go32.c: Update copyright.
4176 * coff-stgo32.c: Likewise.
4177 * coff-go32.c (COFF_LONG_FILENAMES): Define.
4178 * coff-stgo32.c (COFF_LONG_FILENAMES): Likewise.
4179 * coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Remove .bss entry.
4180 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
4182 2001-01-25 Kazu Hirata <kazu@hxi.com>
4184 * bfd-in2.h: Rebuild.
4185 * libbfd.h: Likewise.
4187 2001-01-23 H.J. Lu <hjl@gnu.org>
4189 * bfd-in2.h: Rebuild.
4191 2001-01-23 H.J. Lu <hjl@gnu.org>
4193 * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_buf)
4194 is NULL or PRIV(vms_rec) is outside of the buffer.
4196 2001-01-23 Kazu Hirata <kazu@hxi.com>
4198 * coff64-rs6000.c: Fix formatting.
4199 * coff-arm.c: Likewise.
4200 * coffgen.c: Likewise.
4201 * cofflink.c: Likewise.
4202 * coff-mcore.c: Likewise.
4203 * coff-mips.c: Likewise.
4204 * coff-pmac.c: Likewise.
4205 * coff-ppc.c: Likewise.
4206 * coff-rs6000.c: Likewise.
4207 * elf32.c: Likewise.
4208 * elf32-fr30.c: Likewise.
4209 * elf32-i370.c: Likewise.
4210 * elf32-i860.c: Likewise.
4211 * elf32-m32r.c: Likewise.
4212 * elf32-m68k.c: Likewise.
4213 * elf32-mcore.c: Likewise.
4214 * elf32-ppc.c: Likewise.
4215 * elf32-sh.c: Likewise.
4216 * elf32-v850.c: Likewise.
4217 * elf64-alpha.c: Likewise.
4218 * elf64-sparc.c: Likewise.
4219 * elflink.c: Likewise.
4220 * elflink.h: Likewise.
4221 * elf-m10200.c: Likewise.
4222 * elf-m10300.c: Likewise.
4223 * elfxx-ia64.c: Likewise.
4225 * aoutx.h: Fix formatting.
4227 * bfd-in2.h: Likewise.
4228 * bfd-in.h: Likewise.
4229 * cpu-i386.c: Likewise.
4230 * cpu-m68hc11.c: Likewise.
4231 * dwarf2.c: Likewise.
4232 * elf64-x86-64.c: Likewise.
4233 * format.c: Likewise.
4234 * freebsd.h: Likewise.
4236 * hp300hpux.c: Likewise.
4237 * hppabsd-core.c: Likewise.
4238 * hpux-core.c: Likewise.
4240 2001-01-22 Bo Thorsen <bo@suse.de>
4242 * elf64-x86-64.c: Added PIC support for X86-64.
4243 (elf64_x86_64_link_hash_newfunc): Function added.
4244 (elf64_x86_64_link_hash_table_create): Likewise.
4245 (elf64_x86_64_check_relocs): Likewise.
4246 (elf64_x86_64_gc_mark_hook): Likewise.
4247 (elf64_x86_64_gc_sweep_hook): Likewise.
4248 (elf64_x86_64_adjust_dynamic_symbol): Likewise.
4249 (elf64_x86_64_size_dynamic_sections): Likewise.
4250 (elf64_x86_64_discard_copies): Likewise.
4251 (elf64_x86_64_finish_dynamic_symbol): Likewise.
4252 (elf64_x86_64_finish_dynamic_sections): Likewise.
4253 (elf64_x86_64_relocate_section): Add relocation of PIC sections.
4255 2001-01-21 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
4257 * Makefile.am (install-data-local): Make use of $(DESTDIR).
4258 * Makefile.in: Regenerate.
4260 2001-01-21 Kazu Hirata <kazu@hxi.com>
4262 * coff-a29k.c: Fix formatting.
4264 2001-01-19 H.J. Lu <hjl@gnu.org>
4266 * elf32-i386.c (elf_i386_check_relocs): Report files with bad
4267 relocation section names.
4268 (elf_i386_relocate_section): Report files with bad relocation
4269 section names and return false.
4271 2001-01-17 Bo Thorsen <bo@suse.de>
4273 * targets.c: Alphabetize list of xvecs.
4275 2001-01-14 Alan Modra <alan@linuxcare.com.au>
4277 * config.bfd: Add linux target variant for elfxx-hppa.
4278 * configure.in: Recognize bfd_elf32_hppa_linux_vec and
4279 bfd_elf64_hppa_linux_vec.
4280 * configure: Regenerate.
4281 * elf64-hppa.c: Include elf64-target.h again to support linux
4283 (elf64_hppa_post_process_headers): Set ELFOSABI_LINUX for linux.
4284 * elf32-hppa.c: Include elf32-target.h again to support linux
4286 (elf32_hppa_post_process_headers): New function.
4287 (elf_backend_post_process_headers): Define.
4288 * targets.c (bfd_target_vector): Add bfd_elf64_hppa_linux_vec and
4289 bfd_elf32_hppa_linux_vec.
4291 * elf32-hppa.c (elf32_hppa_link_hash_table): Add text_segment_base,
4292 and data_segment_base fields.
4293 (elf32_hppa_link_hash_table_create ): Init them.
4294 (elf32_hppa_check_relocs): Update comments.
4295 (hppa_record_segment_addr): New function.
4296 (elf32_hppa_relocate_section): Call it.
4297 (final_link_relocate): Handle R_PARISC_SEGREL32.
4298 (elf32_hppa_final_link): New function.
4299 (bfd_elf32_bfd_final_link): Define to call it.
4300 (hppa_unwind_entry_compare): New function.
4301 * cache.c (bfd_open_file): Create files in write+read mode.
4303 * elf-hppa.h (elf_hppa_howto_table): Set bitsize value for
4304 SEGREL32 and numerous other relocs. Change duplicate
4305 R_PARISC_NONE relocs to R_PARISC_UNIMPLEMENTED.
4307 * opncls.c (bfd_fdopenr): Add parens like the comment says around
4310 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Don't create
4311 .plt entries for DT_INIT and DT_FINI.
4312 (elf32_hppa_finish_dynamic_sections): Remove special handling of
4313 DT_INIT and DT_FINI.
4315 * elf64-hppa.c (elf64_hppa_finish_dynamic_symbol): Use 16-bit
4316 offsets for stub .plt access if wide mode. Check offset in range.
4318 2001-01-13 Nick Clifton <nickc@redhat.com>
4320 * elf32-fr30.c (fr30_elf_howto_table): Remove spurious blank
4323 * coffcode.h (coff_canonicalize_reloc): Remove spurious blank
4326 2001-01-12 Alan Modra <alan@linuxcare.com.au>
4328 * configure.in ([bfd_elf64_x86_64_vec]): Set target64.
4329 * configure: Regenerate.
4331 2001-01-11 Peter Targett <peter.targett@arccores.com>
4333 * bfd-in2.h (bfd_architecture): Add bfd_mach_arc_5,
4334 bfd_mach_arc_6, bfd_mach_arc_7, bfd_mach_arc_8 for ARC variants.
4335 * cpu-arc.c (arch_info_struct): Add entries for variants.
4336 (bfd_arc_arch) Set default to bfd_mach_arc_5.
4337 (arc_get_mach) Don't assume machine names prefixed arc- before
4339 * elf32-arc.c (arc_elf_object_p): Set machine number based on new
4341 (arc_elf_final_write_processing) Likewise.
4342 (ELF_MACHINE_CODE) Use EM_ARC.
4344 2001-01-10 Nick Clifton <nickc@redhat.com>
4346 * coff-arm.c (LOCAL_LABEL_PREFIX): Change definition to "".
4348 2001-01-07 Philip Blundell <philb@gnu.org>
4350 * README: Replace `bug-gnu-utils@gnu.org' with
4351 `bug-binutils@gnu.org'.
4353 2001-01-04 Kazu Hirata <kazu@hxi.com>
4355 * som.c: Fix formatting.
4357 2001-01-03 Kazu Hirata <kazu@hxi.com>
4359 * ecoffswap.h: Fix formatting.
4360 * elf-bfd.h: Likewise.
4361 * elfarm-nabi.c: Likewise.
4362 * elfarm-oabi.c: Likewise.
4363 * elfcode.h: Likewise.
4364 * elfcore.h: Likewise.
4365 * elflink.c: Likewise.
4366 * elflink.h: Likewise.
4367 * elfxx-ia64.c: Likewise.
4368 * elfxx-target.h: Likewise.
4369 * libbfd.c: Likewise
4370 * linker.c: Likewise.
4371 * lynx-core.c: Likewise.
4373 2001-01-02 Kazu Hirata <kazu@hxi.com>
4375 * pc532-mach.c: Fix formatting.
4376 * pe-arm.c: Likewise.
4377 * pe-i386.c: Likewise.
4378 * pe-mips.c: Likewise.
4379 * pe-ppc.c: Likewise.
4380 * pe-sh.c: Likewise.
4381 * pei-mips.c: Likewise.
4382 * pei-sh.c: Likewise.
4383 * peicode.h: Likewise.
4384 * ppcboot.c: Likewise.
4385 * ptrace-core.c: Likewise.
4387 2001-01-01 Kazu Hirata <kazu@hxi.com>
4389 * reloc.c: Fix formatting.
4390 * riscix.c: Likewise.
4391 * rs6000-core.c: Likewise.
4392 * xcoff-target.h: Likewise.
4394 2000-12-29 Hans-Peter Nilsson <hp@bitrange.com>
4396 * elfcode.h (elf_object_p): Also restore the bfd mach field on
4397 error, by calling bfd_default_set_arch_mach with incoming
4400 2000-12-26 Kazu Hirata <kazu@hxi.com>
4402 * vaxnetbsd.c: Fix formatting.
4403 * versados.c: Likewise.
4404 * vms-gsd.c: Likewise.
4405 * vms-hdr.c: Likewise.
4406 * vms-misc.c: Likewise.
4408 2000-12-25 Alexandre Oliva <aoliva@redhat.com>
4410 * archive.c (coff_write_armap): Don't write more than symbol_count
4411 `archive_member_file_ptr's.
4413 2000-12-25 Kazu Hirata <kazu@hxi.com>
4415 * vms-tir.c: Fix formatting.
4417 2000-12-23 Kazu Hirata <kazu@hxi.com>
4419 * vms.c: Fix formatting.
4422 2000-12-21 Santeri Paavolainen <santtu@ssh.com>
4424 * vms-hdr.c: Include alloca.h if HAVE_ALLOCA_H is defined.
4426 * peicode.h (pe_ILF_object_p): Add const to import of TARGET_LITTLE_SYM.
4428 * elf32-m32r.c (m32r_elf_generic_reloc): Add cast to avoid (void *)
4431 * elf32-fr30.c: Add casts to avoid (void *) arithmetic.
4433 * coffcode.h (styp_to_sec_flags): Add empty statement after label.
4435 2000-12-21 Richard Sandiford <rsandifo@redhat.com>
4437 * libbfd.c (bfd_get_bits): Added
4438 (bfd_put_bits): Likewise
4439 * bfd-in.h: Declared the above.
4440 * bfd-in2.h: Regenerated.
4442 2000-12-20 Kazu Hirata <kazu@hxi.com>
4444 * targets.c: Fix formatting.
4445 * tekhex.c: Likewise.
4446 * trad-core.c: Likewise.
4448 2000-12-19 Kazu Hirata <kazu@hxi.com>
4450 * sco5-core.c: Fix formatting.
4451 * section.c: Likewise.
4452 * sparclinux.c: Likewise.
4453 * sparclynx.c: Likewise.
4454 * sparcnetbsd.c: Likewise.
4456 * stabs.c: Likewise.
4457 * stab-syms.c: Likewise.
4458 * sunos.c: Likewise.
4460 * sysdep.h: Likewise.
4462 2000-12-18 Nick Clifton <nickc@redhat.com>
4464 * coff-arm.c (EXTRA_S_FLAGS): Only define if not already
4466 * epoc-pe-arm.c (EXTRA_S_FLAGS): Define.
4467 * epoc-pei-arm.c (EXTRA_S_FLAGS): Define.
4469 2000-12-18 Nick Clifton <nickc@redhat.com>
4471 * vms-misc.c (_bfd_vms_get_record): Add default case to
4474 2000-12-15 Miloslav Trmac <mitr@volny.cz>
4476 * elfcore.h (elf_core_file_p): Move to the start of the program
4477 headers before attempting to read them.
4479 2000-12-14 Kazu Hirata <kazu@hxi.com>
4481 * peigen.c: Fix formatting.
4485 2000-12-13 Kazu Hirata <kazu@hxi.com>
4487 * peigen.c: Fix formatting.
4489 2000-12-12 Jim Wilson <wilson@redhat.com>
4491 * elfxx-ia64.c (get_dyn_sym_info): Cast %p argument to void *.
4493 2000-12-08 Mark Salter <msalter@redhat.com>
4495 * binary.c (binary_set_section_contents): Ignore sections
4498 2000-12-12 Kazu Hirata <kazu@hxi.com>
4500 * m68klinux.c: Fix formatting.
4501 * m68knetbsd.c: Likewise.
4502 * mipsbsd.c: Likewise.
4503 * netbsd-core.c: Likewise.
4504 * netbsd.h: Likewise.
4505 * newsos3.c: Likewise.
4506 * nlm32-alpha.c: Likewise.
4507 * nlm32-i386.c: Likewise.
4508 * nlm32-ppc.c: Likewise.
4509 * nlm32-sparc.c: Likewise.
4510 * nlmcode.h: Likewise.
4511 * nlmswap.h: Likewise.
4512 * nlm-target.h: Likewise.
4513 * ns32knetbsd.c: Likewise.
4515 2000-12-10 Fred Fish <fnf@be.com>
4517 * elflink.h (elf_link_output_extsym): Don't complain about undefined
4518 symbols in shared objects if allow_shlib_undefined is true.
4520 2000-12-12 Nick Clifton <nickc@redhat.com>
4522 * cpu-sh.c: Fix formattng.
4523 * elf.c: Fix formattng.
4524 * elf32-mips.c: Fix formattng.
4525 * elf32-sh.c: Fix formattng.
4526 * elf64-alpha.c: Fix formattng.
4528 2000-12-09 Nick Clifton <nickc@redhat.com>
4530 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Pass
4531 dwarf2_find_line_info as last parameter to invocation of
4532 _bfd_dwarf2_find_nearest_line.
4533 * elf32-arm.h (elf32_arm_find_nearest_line): Pass
4534 dwarf2_find_line_info as last parameter to invocation of
4535 _bfd_dwarf2_find_nearest_line.
4537 2000-12-08 Mark Elbrecht <snowball3@bigfoot.com>
4539 * Makefile.am (BFD32_BACKENDS): Move dwarf2.lo from here...
4540 (BFD_LIBS): ...to here.
4541 (BFD32_BACKENDS_CFILES): Move dwarf2.c from here...
4542 (BFD_LIBS_CFILES): ...to here.
4543 * Makefile.in: Regenerate.
4544 * configure.in: Remove dwarf.lo from the elf shell variable.
4545 * configure: Regenerate.
4546 * libcoff-in.h (coff_tdata): Add pointer dwarf2_find_line_info.
4547 * libcoff.h: Regenerate.
4548 * coffgen.c (coff_find_nearest_line): Call
4549 _bfd_dwarf2_find_nearest_line.
4550 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Add parameter. Update
4552 (read_abbrevs): Likewise
4553 (decode_line_info): Likewise.
4554 (parse_comp_unit): Likewise.
4555 (comp_unit_find_nearest_line): Likewise.
4556 * libbfd-in.h (_bfd_dwarf2_find_nearest_line): Update prototype.
4557 * libbfd.h: Regenerate.
4558 * elf.c (_bfd_elf_find_nearest_line): Update call.
4559 * elf-bfd.h (elf_obj_tdata): Change dwarf2_find_line_info to type PTR.
4560 * dwarf2.c (concat_filename): Use IS_ABSOLUTE_PATH.
4561 * coffcode.h (STYP_XCOFF_DEBUG, STYP_DEBUG_INFO): New macros.
4562 (sec_to_styp_flags): Use them. Handle DWARF2 sections.
4563 (styp_to_sec_flags): Handle DWARF2 sections.
4564 * elf32-arm.h (elf32_arm_find_nearest_line): Add parameter to call
4565 to _bfd_find_nearest_line.
4566 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Add parameter to
4567 call to _bfd_find_nearest_line.
4569 2000-12-08 Kazu Hirata <kazu@hxi.com>
4571 * coffgen.c: Fix formatting.
4572 * elf-m10300.c: Likewise.
4573 * elf32-i386.c: Likewise.
4574 * elf32-i960.c: Likewise.
4575 * elf32-m68k.c: Likewise.
4576 * elf32-mcore.c: Likewise.
4577 * elf32-ppc.c: Likewise.
4578 * elf32-sh.c: Likewise.
4579 * elf32-sparc.c: Likewise.
4580 * elf32-v850.c: Likewise.
4581 * elf64-alpha.c: Likewise.
4582 * elf64-hppa.c: Likewise.
4583 * elf64-mips.c: Likewise.
4584 * elf64-sparc.c: Likewise.
4586 2000-12-07 Kazu Hirata <kazu@hxi.com>
4588 * elf32-ppc.c: Fix formatting.
4589 * elf64-x86-64.c: Likewise.
4591 2000-12-06 Ulf Carlsson <ulfc@engr.sgi.com>
4593 From Ralf Baechle <ralf@gnu.org>
4595 * elf32-mips.c (elf32_mips_merge_private_bfd_data): Always permit
4596 BFDs containing no sections or empty .text, .data or .bss sections
4597 to be merged, regardless of their flags.
4599 2000-12-06 Kazu Hirata <kazu@hxi.com>
4601 * elf32-m32r.c: Fix formatting.
4602 * elf32-m68hc11.c: Likewise.
4603 * elf32-m68hc12.c: Likewise.
4604 * elf32-m68k.c: Likewise.
4605 * elf32-mcore.c: Likewise.
4606 * elf32-pj.c: Likewise.
4607 * elf32-ppc.c: Likewise.
4609 2000-12-05 Kazu Hirata <kazu@hxi.com>
4611 * elf32-fr30.c: Fix formatting.
4612 * elf32-hppa.c: Likewise.
4613 * elf32-i370.c: Likewise.
4614 * elf32-i386.c: Likewise.
4615 * elf32-i860.c: Likewise.
4616 * elf32-i960.c: Likewise.
4618 2000-12-03 Kazu Hirata <kazu@hxi.com>
4620 * elf32-arm.h: Fix formatting.
4621 * elf32-avr.c: Likewise.
4622 * elf32-cris.c: Likewise.
4623 * elf32-d10v.c: Likewise.
4624 * elf32-d30v.c: Likewise.
4625 * elf-hppa.h: Likewise.
4626 * elf-m10200.c: Likewise.
4627 * elf-m10300.c: Likewise.
4629 2000-12-01 Chris Demetriou <cgd@sibyte.com>
4631 * aoutx.h (NAME(aout,machine_type)): Add bfd_mach_mips32 and
4632 bfd_mach_mips32_4k. Update FIXME comment.
4633 * archures.c (bfd_mach_mips32): New constant.
4634 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
4635 the latter, renumber it.
4636 * bfd-in2.h (bfd_mach_mips32): New constant.
4637 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
4638 the latter, renumber it.
4639 * cpu-mips.c (I_mips32): New constant.
4640 (I_mips4K, I_mips32_4k): Rename the former to the latter.
4641 (arch_info_struct): Add bfd_mach_mips32 entry, replace
4642 bfd_mach_mips4K entry with bfd_mach_mips32_4k entry.
4643 * elf32-mips.c (elf_mips_isa): Add E_MIPS_ARCH_32 case.
4644 (elf_mips_mach): Likewise. Also, replace E_MIPS_MACH_MIPS32
4645 with E_MIPS_MACH_MIPS32_4K.
4646 (_bfd_mips_elf_final_write_processing): Replace
4647 bfd_mach_mips4K with bfd_mach_mips32_4k case, add
4648 bfd_mach_mips32 case.
4649 (_bfd_mips_elf_merge_private_bfd_data): Generalize ISA mixing
4650 comparison with support for MIPS32.
4651 (_bfd_mips_elf_print_private_bfd_data): Print ISA name for
4654 * aoutx.h (NAME(aout,machine_type)): Add cases for
4655 bfd_mach_mips5 and bfd_mach_mips64.
4656 * archures.c (bfd_mach_mips5, bfd_mach_mips64): New constants.
4657 * bfd-in2.h (bfd_mach_mips5, bfd_mach_mips64): Likewise.
4658 * cpu_mips.c (I_mips5, I_mips64): New definitions.
4659 (arch_info_struct): Add entries for bfd_mach_mips5 and
4661 * elf32-mips.c (elf_mips_isa, elf_mips_mach,
4662 _bfd_mips_elf_print_private_bfd_data): Add cases for
4663 E_MIPS_ARCH_5 and E_MIPS_ARCH_64.
4664 (_bfd_mips_elf_final_write_processing): Add cases for
4665 bfd_mach_mips5 and bfd_mach_mips64.
4667 * aoutx.h (NAME(aout,machine_type)): Add a
4668 bfd_mach_mips_sb1 case.
4669 * archures.c (bfd_mach_mips_sb1): New constant.
4670 * bfd-in2.h (bfd_mach_mips_sb1): New constant.
4671 * cpu-mips.c (I_sb1): New constant.
4672 (arch_info_struct): Add entry for bfd_mach_mips_sb1.
4673 * elf32-mips.c (elf_mips_mach): Add case for
4675 (_bfd_mips_elf_final_write_processing): Add case for
4678 2000-12-01 Joel Sherrill <joel@OARcorp.com>
4680 * config.bfd (arm-*-rtems*, a29k-*rtems*): New targets.
4681 (sparc*-*-rtemself*, sparc*-*-rtemsaout*): New targets.
4682 (sparc*-*-rtems*): Switched from a.out to ELF.
4684 2000-11-30 Jan Hubicka <jh@suse.cz>
4686 * Makefile.am (BFD64_BACKENDS): Add elf64-x86-64.lo
4687 BFD64_BACKENDS_CFILES): Add elf64-x86-64.c
4688 (elf64-x86-64.lo): Add dependencies.
4689 * archures.c (DESCRIPTION): Add bfd_mach_x86_64,
4690 bfd_mach_x86_64_intel_syntax.
4691 * elf.c (prep_headers): Use EM_x86_64 for 64bit output.
4692 * config.bfd (x86_64): Add.
4693 * configure.in: Add support for bfd_elf64_x86_64_vec.
4694 * cpu-i386.c (bfd_x86_64_arch_intel_syntax, bfd_x86_64_arch): Add.
4695 (bfd_i386_arch, i8086_ar): Link in.
4696 * elf64-x86-64.c: New file.
4697 * reloc.c (ENUMDOC): Add BFD_RELOC_X86_64*.
4698 * targets.c (bfd_elf64_x86_64_vec): Add.
4699 (bfd_target_vect): Add bfd_elf64_x86_64_vec.
4701 2000-11-30 Kazu Hirata <kazu@hxi.com>
4703 * xcofflink.c: Fix formatting.
4705 2000-11-28 Kazu Hirata <kazu@hxi.com>
4707 * aoutx.h: Fix formatting.
4708 * bfd-in.h: Likewise.
4709 * bfd-in2.h: Likewise.
4710 * cache.c: Likewise.
4711 * cisco-core.c: Likewise.
4712 * coff64-rs6000.c: Likewise.
4713 * coffcode.h: Likewise.
4714 * coffswap.h: Likewise.
4715 * corefile.c: Likewise.
4716 * elf32-mips.c: Likewise.
4718 2000-11-27 Kazu Hirata <kazu@hxi.com>
4720 * aout-adobe.c: Fix formatting.
4721 * coff64-rs6000.c: Likewise.
4722 * coffgen.c: Likewise.
4723 * cofflink.c: Likewise.
4725 2000-11-27 Philip Blundell <pb@futuretv.com>
4727 * libcoff-in.h (coff_tdata): Add `strings_written' flag.
4728 (obj_coff_strings_written): New accessor macro for above.
4729 * libcoff.h: Regenerate.
4730 * cofflink.c (_bfd_coff_final_link): Say that we wrote the
4732 * coffcode.h (coff_write_object_contents): No need to write out
4733 the string table if it's already been done.
4735 2000-11-22 Philip Blundell <pb@futuretv.com>
4737 * cofflink.c (_bfd_coff_generic_relocate_section): Don't object to
4738 weak undefined symbols.
4740 2000-11-24 Nick Clifton <nickc@redhat.com>
4742 * archures.c (bfd_mach_arm_5TE): Define.
4743 (bfd_mach_arm+XScale): Define.
4744 * bfd-in2.h: Regenerate.
4746 * coff-arm.c (coff_arm_reloc_type_lookup): Accept
4747 BFD_RELOC_ARM_PCREL_BLX.
4749 * coffcode.h (coff_set_flags): Set flags for 5t, 5te and
4750 XScale machine numbers.
4752 * config.bfd (xscale-elf): Add target.
4753 (xscale-coff): Add target.
4755 * cpu-arm.c: Add xscale machine name.
4756 Add v5t, v5te and XScale machine numbers.
4758 2000-11-23 Kazu Hirata <kazu@hxi.com>
4760 * aix386-core.c: Fix formatting.
4762 2000-11-22 Jim Wilson <wilson@redhat.com>
4764 * coff-ia64.c (howto_table): Use EMPTY_HOWTO.
4765 (in_reloc_p): Add ATTRIBUTE_UNUSED to unused parameters.
4766 * cpu-ia64-opc.c (ins_rsvd, ext_rsvd, ins_const, ext_const): Likewise.
4767 (ins_imms_scaled): Initialize sign_bit at function entry.
4768 (elf64_ia64_operands): Add missing initializers.
4769 * elfxx-ia64.c (elfNN_ia64_reloc, elfNN_ia64_reloc_type_lookup,
4770 elfNN_ia64_info_to_howto, elfNN_ia64_fake_sections,
4771 elfNN_ia64_add_symbol_hook, elfNN_ia64_is_local_label_name,
4772 elfNN_ia64_local_hash_table_init, get_fptr, get_pltoff,
4773 elfNN_ia64_adjust_dynamic_symbol): Add ATTRIBUTE_UNUSED for unused
4775 (elfNN_ia64_info_to_howto): Initialize free_relocs, free_contents,
4776 and free_extsyms at function entry.
4777 (elfNN_add_symbol_hook): Add unsigned cast to bfd_get_gp_size result.
4778 (elfNN_ia64_create_dynamic_sections): Delete unused local h.
4779 (get_got): Delete unused local srel.
4780 (elfNN_ia64_check_relocs): Initialize dynrel_type when declared.
4781 (elfNN_ia64_relocate_section): Delete unused local dynindx.
4783 2000-11-21 Kazu Hirata <kazu@hxi.com>
4785 * coff-a29k.c: Fix formatting.
4786 * coff-h8500.c: Likewise.
4787 * coff-i960.c: Likewise.
4788 * coff-ppc.c: Likewise.
4789 * coff-rs6000.c: Likewise.
4790 * coff-stgo32.c: Likewise.
4791 * coff-tic54x.c: Likewise.
4792 * coff-w65.c: Likewise.
4793 * cpu-h8500.c: Likewise.
4794 * cpu-hppa.c: Likewise.
4795 * cpu-ns32k.c: Likewise.
4796 * ecoff.c: Likewise.
4797 * ecofflink.c: Likewise.
4799 2000-11-21 Nick Clifton <nickc@redhat.com>
4801 * elf32-sh.c (sh_elf_reloc_loop): Fix compile time warning, and
4802 remove possibility of infinite loop.
4804 2000-11-20 Kazu Hirata <kazu@hxi.com>
4806 * aix386-core.c: Fix formatting.
4807 * aout-adobe.c: Likewise.
4808 * aout-arm.c: Likewise.
4809 * aout-encap.c: Likewise.
4810 * aout-ns32k.c: Likewise.
4811 * aout-target.h: Likewise.
4812 * aout-tic30.c: Likewise.
4813 * aoutf1.h: Likewise.
4814 * aoutx.h: Likewise.
4815 * archive.c: Likewise.
4816 * bfd-in.h: Likewise.
4817 * bfd-in2.h: Likewise.
4821 2000-11-17 H.J. Lu <hjl@gnu.org>
4823 * elfxx-ia64.c (elfNN_ia64_size_dynamic_sections): Don't create
4824 pltoff entries for DT_INIT and DT_FINI.
4825 (elfNN_ia64_final_link): Don't set DT_INIT/FINI entries.
4826 (elfNN_ia64_finish_dynamic_sections): Don't fill in DT_INIT/FINI
4829 2000-11-16 Richard Henderson <rth@redhat.com>
4831 * elfxx-ia64.c (elfNN_ia64_check_relocs): Handle IPLT relocs.
4832 (allocate_dynrel_entries): Likewise.
4833 (elfNN_ia64_relocate_section): Likewise. Set REL addends correctly.
4834 (set_pltoff_entry): Likewise.
4835 (ia64_howto_table): Remove R_IA64_SEGBASE, and R_IA64_EPLT[ML]SB
4836 (elfNN_ia64_reloc_type_lookup): Likewise.
4837 (elfNN_ia64_install_value): Likewise.
4838 (elfNN_ia64_relocate_section): Likewise.
4839 * reloc.c (BFD_RELOC_IA64_SEGBASE): Remove.
4840 (BFD_RELOC_IA64_EPLTMSB, BFD_RELOC_IA64_EPLTLSB): Remove.
4842 2000-11-16 Kazu Hirata <kazu@hxi.com>
4844 * cpu-a29k.c: Fix formatting.
4845 * cpu-alpha.c: Likewise.
4846 * cpu-arm.c: Likewise.
4847 * cpu-avr.c: Likewise.
4848 * cpu-d10v.c: Likewise.
4849 * cpu-h8500.c: Likewise.
4850 * cpu-hppa.c: Likewise.
4851 * cpu-i370.c: Likewise.
4852 * cpu-i386.c: Likewise.
4853 * cpu-i960.c: Likewise.
4854 * cpu-ia64-opc.c: Likewise.
4855 * cpu-ia64.c: Likewise.
4856 * cpu-m32r.c: Likewise.
4857 * cpu-m68hc11.c: Likewise.
4858 * cpu-m68hc12.c: Likewise.
4859 * cpu-m68k.c: Likewise.
4860 * cpu-m88k.c: Likewise.
4861 * cpu-mips.c: Likewise.
4862 * cpu-ns32k.c: Likewise.
4863 * cpu-pj.c: Likewise.
4864 * cpu-powerpc.c: Likewise.
4865 * cpu-sh.c: Likewise.
4866 * cpu-sparc.c: Likewise.
4867 * cpu-tic54x.c: Likewise.
4868 * cpu-v850.c: Likewise.
4869 * cpu-vax.c: Likewise.
4870 * cpu-w65.c: Likewise.
4871 * cpu-we32k.c: Likewise.
4872 * cpu-z8k.c: Likewise.
4873 * dwarf1.c: Likewise.
4874 * dwarf2.c: Likewise.
4876 2000-11-15 Kazu Hirata <kazu@hxi.com>
4878 * coff-arm.c: Fix formatting.
4879 * coff-ppc.c: Likewise.
4880 * coff-rs6000.c: Likewise.
4881 * coff-sh.c: Likewise.
4882 * coff-sparc.c: Likewise.
4883 * coff-tic30.c: Likewise.
4884 * coff-tic54x.c: Likewise.
4885 * coff-tic80.c: Likewise.
4886 * coff-w65.c: Likewise.
4887 * coff-we32k.c: Likewise.
4888 * coff-z8k.c: Likewise.
4890 2000-11-15 Richard Henderson <rth@redhat.com>
4892 * elf64-alpha.c (elf64_alpha_check_relocs): Create the reloc
4893 section with the same ALLOC|LOAD flags as the source section.
4895 2000-11-14 Jakub Jelinek <jakub@redhat.com>
4897 * elf64-alpha.c (elf64_alpha_relax_opt_call): Only check bits used
4898 by STO_ALPHA constants.
4900 2000-11-14 Kazu Hirata <kazu@hxi.com>
4902 * coff-pmac.c: Fix formatting.
4903 * coff-ppc.c: Likewise.
4905 2000-11-13 H.J. Lu <hjl@gnu.org>
4907 * elflink.h (elf_link_add_object_symbols): Also add indirect
4908 symbols for common symbols with the default version.
4910 2000-11-09 Philip Blundell <pb@futuretv.com>
4912 * section.c (STD_SECTION): Set gc_mark flag.
4914 2000-11-11 Kazu Hirata <kazu@hxi.com>
4916 * coff-i960.c: Likewise.
4917 * coff-m68k.c: Likewise.
4918 * coff-m88k.c: Likewise.
4919 * coff-mcore.c: Likewise.
4920 * coff-mips.c: Likewise.
4922 2000-11-11 Bernd Schmidt <bernds@cygnus.co.uk>
4924 * elf32-sh.c (sh_elf_relocate_section): Ignore R_SH_NONE relocs.
4926 2000-11-10 Kazu Hirata <kazu@hxi.com>
4928 * coff-h8300.c: Fix formatting.
4929 * coff-h8500.c: Likewise.
4930 * coff-i386.c: Likewise.
4931 * coff-i860.c: Likewise.
4932 * coff-i960.c: Likewise.
4933 * coff-ia64.c: Likewise.
4935 2000-11-09 Kazu Hirata <kazu@hxi.com>
4937 * archive.c: Fix formatting.
4938 * archures.c: Likewise.
4940 2000-11-07 Richard Henderson <rth@redhat.com>
4942 * elfxx-ia64.c (elf64_ia64_final_link): New local unwind_output_sec.
4943 Set it before bfd_elf64_bfd_final_link call. Use it after the call.
4944 * section.c (bfd_set_section_contents): Call memcpy if
4945 section->contents set and location not equal to contents plus offset.
4947 2000-11-08 Kazu Hirata <kazu@hxi.com>
4949 * bfd-in.h: Fix formatting.
4950 * bfd-in2.h: Likewise.
4952 * binary.c: Likewise.
4954 * coff-a29k.c: Likewise.
4955 * coff-alpha.c: Likewise.
4956 * coff-apollo.c: Likewise.
4957 * coff-aux.c: Likewise.
4959 2000-11-07 Kazu Hirata <kazu@hxi.com>
4961 * aix386-core.c: Fix formatting.
4962 * aoutf1.h: Likewise.
4963 * aoutx.h: Likewise.
4964 * archures.c: Likewise.
4965 * armnetbsd.c: Likewise.
4967 2000-11-07 Alan Modra <alan@linuxcare.com.au>
4969 * coff-h8300.c (special): Adjust reloc address.
4971 2000-11-06 Steve Ellcey <sje@cup.hp.com>
4973 * archures.c (bfd_mach_ia64_elf64, bfd_mach_ia64_elf32): Add defines
4974 to differentiate elf32 and elf64 on ia64.
4975 * bfd-in2.h: Regenerate.
4976 * config.bfd: Add target for "ia64*-*-hpux*".
4977 * configure.in: Add bfd_elf32_ia64_big_vec to selvecs switch.
4978 * configure: Regenerate.
4979 * cpu-ia64.c (bfd_ia64_elf32_arch): Add elf32 arch info structure.
4980 * targets.c: Add bfd_target bfd_elf32_ia64_big_vec.
4982 * Makefile.am: Make elf32-ia64.c and elf64-ia64.c derived objects
4983 from elfxx-ia64.c. Add depenency rules for making elf32-ia64.lo.
4984 * Makefile.in: Regnerate.
4985 * elf64-ia64.c: Deleted.
4986 * elfxx-ia64.c: New file, paramaterized version of elf64-ia64.c.
4988 2000-11-06 Kazu Hirata <kazu@hxi.com>
4990 * aout-adobe.c: Fix formatting.
4991 * aout-arm.c: Likewise.
4992 * aout-cris.c: Likewise.
4993 * aout-encap.c: Likewise.
4994 * aout-ns32k.c: Likewise.
4995 * aout-target.h: Likewise.
4996 * aout-tic30.c: Likewise.
4998 2000-11-05 Philip Blundell <philb@gnu.org>
5000 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Always permit
5001 BFDs containing no sections to be merged, regardless of their flags.
5003 2000-11-04 Philip Blundell <philb@gnu.org>
5005 * elf32-arm.h (elf32_arm_relocate_section): Suppress error message
5006 if a relocation for an undefined symbol also results in an
5009 2000-11-06 Christopher Faylor <cgf@cygnus.com>
5011 * config.bfd: Add support for Sun Chorus.
5013 2000-11-05 David O'Brien <obrien@FreeBSD.org>
5015 * configure.in: Recognize alpha-*-freebsd*.
5016 * configure: Regenerate.
5018 2000-11-02 Luciano Gemme <ishitawa@yahoo.com>
5020 * srec.c (CHUNK): Rename to DEFAULT_CHUNK.
5021 (Chunk): New global variable set by a parameter in objcopy.c.
5022 (S3Forced): New global variable set by a parameter in
5024 (srec_set_section_contents): If S3Forced is true, always generate
5026 (srec_write_section): Use 'Chunk' to limit maximum length of S
5029 2000-11-02 Per Lundberg <plundis@chaosdev.org>
5031 * config.bfd: Add support for i[3456]86-chaosdev-storm-chaos.
5032 * Makefile.in: Regenerate.
5033 * bfd-in2.h: Regenerate.
5034 * po/bfd.pot: Regenerate.
5036 2000-10-31 Philip Blundell <philb@gnu.org>
5038 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Only handle
5039 EF_SOFT_FLOAT if it is defined.
5041 2000-10-27 Philip Blundell <philb@gnu.org>
5043 * elf32-arm.h (elf32_arm_copy_private_bfd_data): Don't refuse
5044 attempts to mix PIC code with non-PIC, just mark the output as
5045 being position dependent.
5046 (elf32_arm_merge_private_bfd_data): Likewise. Print an error
5047 message for EF_SOFT_FLOAT mismatches. Display diagnostics for
5048 all mismatches, not just the first one.
5050 2000-10-25 Chris Demetriou <cgd@sibyte.com>
5052 * ieee.c (ieee_archive_p): Plug one of many possible
5053 memory leaks in error handling.
5055 2000-10-20 Jakub Jelinek <jakub@redhat.com>
5057 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data,
5058 elf32_sparc_object_p, elf32_sparc_final_write_processing):
5060 * elf64-sparc.c (sparc64_elf_merge_private_bfd_data,
5061 sparc64_elf_object_p): Support v9b.
5062 * archures.c: Declare v8plusb and v9b machines.
5064 * cpu-sparc.c: Ditto.
5066 2000-10-16 Geoffrey Keating <geoffk@shoggoth.cygnus.com>
5068 * elf64-sparc.c (sparc64_elf_relocate_section): Clear the location
5071 * elf32-ppc.c (SYMBOL_REFERENCES_LOCAL): New macro.
5072 (SYMBOL_CALLS_LOCAL): New macro.
5073 (ppc_elf_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL.
5074 (ppc_elf_check_relocs): Use SYMBOL_REFERENCES_LOCAL.
5075 (ppc_elf_finish_dynamic_symbol): Use SYMBOL_REFERENCES_LOCAL.
5076 (ppc_elf_relocate_section): Use flag variable to determine
5077 whether the relocation refers to a local symbol.
5078 Test whether a PLTREL24 reloc will produce a reloc by looking
5079 to see whether a PLT entry was made.
5081 2000-10-14 Geoffrey Keating <geoffk@shoggoth.cygnus.com>
5083 * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Don't make PLT
5084 entries that could serve as a definition for a weak symbol.
5086 2000-10-13 Ulf Carlsson <ulfc@engr.sgi.com>
5088 From Ralf Baechle <ralf@gnu.org>
5090 * elf32-mips.c (mips_elf_create_dynamic_relocation): New argument
5091 local_p. Add symbol value only for non-R_MIPS_REL32 relocations
5092 against local symbols.
5093 (_bfd_mips_elf_finish_dynamic_sections): Undo patch from 2000-10-01.
5095 2000-10-12 Alan Modra <alan@linuxcare.com.au>
5097 * section.c (struct sec): Add kept_section.
5098 (struct bfd_comdat_info): Remove sec, we can use above.
5099 (STD_SECTION): Add initializer.
5100 (bfd_make_section_anyway): Init here too.
5102 * bfd-in2.h: Regenerate.
5104 * elflink.h (elf_link_add_object_symbols): Remove unnecessary
5106 (elf_link_input_bfd): Set all asection->symbol->value's here, and
5107 fudge values for discarded link-once section symbols.
5109 * elf64-hppa.c: Include alloca-conf.h
5111 2000-10-11 Alan Modra <alan@linuxcare.com.au>
5113 * elf.c (swap_out_syms): Revert 2000-10-07 changes.
5115 * ieee.c (ieee_make_empty_symbol): Oops, bfd_zalloc needs another arg.
5117 2000-10-10 Alan Modra <alan@linuxcare.com.au>
5119 * ieee.c (ieee_make_empty_symbol): Use bfd_zalloc, not bfd_zmalloc.
5121 2000-10-10 Tom Rix <trix@redhat.com>
5123 * section.c (bfd_make_section_anyway): Release newsect ptr when
5124 newsect->symbol fails to alloc. Use bfd_release instead of free.
5126 2000-10-09 Richard Henderson <rth@cygnus.com
5128 * elf64-ia64.c (elf64_ia64_unwind_entry_compare_bfd): New.
5129 (elf64_ia64_unwind_entry_compare): New.
5130 (elf64_ia64_final_link): Sort the .IA_64.unwind section.
5132 2000-10-07 Alan Modra <alan@linuxcare.com.au>
5134 * elflink.h (size_dynamic_sections): Don't create various tags if
5135 .dynstr is excluded from the link. Don't set first dynsym entry
5136 if dynsymcount is zero.
5137 (elf_bfd_final_link): Don't try to swap out dynamic syms if
5138 .dynsym excluded from the link. Don't try to write any dynamic
5139 sections excluded from the link.
5141 * elf.c (swap_out_syms): Handle global section symbols.
5143 2000-10-05 DJ Delorie <dj@redhat.com>
5145 * peigen.c (_bfd_pei_swap_scnhdr_out): note extended relocs
5146 * coffcode.h (coff_set_alignment_hook): read extended reloc count
5147 (coff_write_relocs): write extended reloc count
5148 (coff_write_object_contents): account for extended relocs
5150 2000-10-05 Jim Wilson <wilson@cygnus.com>
5152 * elf-bfd.h (struct elf_backend_data): Add elf_backend_section_flags
5154 * elf.c (_bfd_elf_make_section_from_shdr): Call the
5155 elf_backend_section_flags function.
5156 * elf64-ia64.c (elf64_ia64_section_from_shdr): Delete flag conversion
5158 (elf64_ia64_section_flags): New function containing flag conversion
5160 (elf_backend_section_flags): Define to elf64_ia64_section_flags.
5161 * elfxx-target.h (elf_backend_section_flags): Define.
5162 (elfNN_bed): Initialize elf_backend_section_flags field.
5164 2000-10-02 Alan Modra <alan@linuxcare.com.au>
5166 * elf32-hppa.c (elf32_hppa_check_relocs): Correct call to
5167 _bfd_elf32_gc_record_vtable. Correct a comment.
5169 2000-10-01 Ulf Carlsson <ulfc@engr.sgi.com>
5171 From Ralf Baechle <ralf@gnu.org>
5173 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_sections): Mark gld
5174 produces binaries with got[1] = 0x80000001 to differenciate them
5175 for the dynamic linker from the broken binaries produced by old
5178 2000-09-30 Petr Sorfa <petrs@sco.com>
5180 * elf.c (elfcore_grok_pstatus): Check for size of pxstatus_t.
5181 (elfcore_grok_lwpstatus): Check for size of lwpxstatus_t.
5182 * configure.in: Add check for pxstatus_t and lwpxstatus_t.
5183 * configure: Regenerate.
5185 2000-09-27 Hans-Peter Nilsson <hp@axis.com>
5187 Define two bfd_targets for absence and presence of leading
5188 underscore on symbols. Make sure to only link same kind.
5189 * elf32-cris.c (cris_elf_object_p,
5190 cris_elf_final_write_processing, cris_elf_print_private_bfd_data,
5191 cris_elf_merge_private_bfd_data): New.
5192 (elf_backend_object_p, elf_backend_final_write_processing,
5193 bfd_elf32_bfd_print_private_bfd_data,
5194 bfd_elf32_bfd_merge_private_bfd_data): Define.
5195 <Target vector definition>: Include elf32-target.h twice with
5196 different macro settings:
5197 (TARGET_LITTLE_SYM): First as bfd_elf32_cris_vec, then as
5198 bfd_elf32_us_cris_vec.
5199 (TARGET_LITTLE_NAME): First as "elf32-cris", then "elf32-us-cris".
5200 (elf_symbol_leading_char): First as 0, then '_'.
5201 (INCLUDED_TARGET_FILE): Define for second include of elf32-target.h.
5202 * config.bfd (cris-*-*): Add bfd_elf32_us_cris_vec to targ_selvecs.
5203 * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vector.
5204 * configure: Regenerate.
5205 * targets.c: Declare bfd_elf32_us_cris_vec.
5206 * po/bfd.pot: Regenerate.
5208 2000-09-29 Momchil Velikov <velco@fadata.bg>
5210 * elf32-arm.h (arm_add_to_rel): Correctly adjust the addend for
5211 R_ARM_THM_PC22 relocations.
5213 2000-09-29 NIIBE Yutaka <gniibe@chroot.org>
5215 * elflink.h (elf_link_add_object_symbols): Don't bfd_release runpath.
5217 2000-09-29 Momchil Velikov <velco@fadata.bg>
5219 * elf.c (elf_fake_sections): Do not mark the section SHT_NOBITS if
5220 is has the SEC_HAS_CONTENTS flag set.
5222 2000-09-28
\81Örjan Friberg <orjanf@axis.com>
5223 Hans-Peter Nilsson <hp@axis.com>
5225 * aout-cris.c (N_TXTADDR): Define.
5227 2000-09-28 John David Anglin <dave@hiauly1.hia.nrc.ca>
5229 * som.c: Include alloca-conf.h.
5230 * Makefile.am: "make dep-am"
5231 * Makefile.in: Regenerate.
5233 2000-09-27 Alan Modra <alan@linuxcare.com.au>
5235 * elf32-hppa.c (plt_stub): New.
5236 (PLT_STUB_ENTRY): Define.
5237 (elf32_hppa_link_hash_table): Change multi_subspace to packed
5238 boolean. Add need_plt_stub, has_12bit_branch and has_17bit_branch.
5239 (elf32_hppa_link_hash_table_create): Init to suit.
5240 (elf32_hppa_check_relocs): Set has_12bit_branch and
5241 has_17bit_branch as appropriate.
5242 (elf32_hppa_adjust_dynamic_symbol): Set need_plt_stub for
5243 non-local functions.
5244 (elf32_hppa_size_dynamic_sections): Correct setting of reltext.
5245 Add space for plt_stub as needed.
5246 (elf32_hppa_finish_dynamic_symbol): Point .plt entries for global
5247 functions at plt_stub.
5248 (elf32_hppa_finish_dynamic_sections): Write plt_stub.
5249 (elf32_hppa_create_dynamic_sections): Leave .plt executable.
5251 * elf32-hppa.h (elf32_hppa_size_stubs): Add group_size param.
5252 * elf32-hppa.c (elf32_hppa_size_stubs): Likewise. Use it instead
5253 of fixed size, and if negative, disable handling of input sections
5254 before stub section. Set up default stub group size depending
5255 on detected branch relocs.
5256 (hppa_build_one_stub): Use lrsel and rrsel for import stubs to
5257 ensure different offsets from sym_value aren't rounded to
5258 different 2k blocks. Use lrsel and rrsel for other stubs too for
5259 consistency rather than necessity.
5260 (elf32_hppa_check_relocs): Handle R_PARISC_DIR14F.
5261 (final_link_relocate): Likewise.
5262 (elf32_hppa_relocate_section): Likewise.
5264 * elf-hppa.h (elf_hppa_howto_table): Add R_PARISC_DIR14F reloc.
5265 (_bfd_elf_hppa_gen_reloc_type): Generate them.
5266 (elf_hppa_final_link_relocate): Handle them.
5267 (elf_hppa_relocate_insn): Likewise.
5268 (_bfd_elf_hppa_gen_reloc_type): Add missing e_ldsel and e_rdsel cases.
5270 2000-09-26 Hans-Peter Nilsson <hp@axis.com>
5272 * elfcode.h (elf_object_p): Preserve and clear abfd section
5273 information. Restore at error.
5275 2000-09-26 Paul Sokolovsky <Paul.Sokolovsky@technologist.com>
5277 * peigen.c (_bfd_pei_swap_aouthdr_in): If some DataDirectory
5278 is empty, make sure that its rva also 0. NT loader dislikes
5281 2000-09-26 Steve Ellcey <sje@cup.hp.com>
5283 * som.c (som_bfd_derive_misc_symbol_info): Make weak symbols
5286 2000-09-21 Alan Modra <alan@linuxcare.com.au>
5288 * elf32-hppa.c (elf32_hppa_check_relocs): Fix weak sym handling in
5289 currently unused RELATIVE_DYNAMIC_RELOCS code.
5290 (hppa_discard_copies): Likewise.
5291 (elf32_hppa_size_stubs): Size `input_list' array correctly. Correct
5292 comments. Don't check non-code output sections for stub grouping.
5294 2000-09-20 Alan Modra <alan@linuxcare.com.au>
5296 * section.c (bfd_get_unique_section_name): Return NULL if
5299 2000-09-19 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5301 * elf32-m68k.c (elf_cpu32_plt0_entry): Change the PLT entry 0
5302 instruction sequence to actually work.
5303 (elf_m68k_finish_dynamic_sections): Change the patch-in offset
5306 2000-09-18 Alexandre Oliva <aoliva@redhat.com>
5308 * elf32-sh.c (sh_elf_relocate_section): Use
5309 _bfd_final_link_relocate to apply the relocation against a section
5310 symbol, when doing relocatable links.
5312 2000-09-18 Alan Modra <alan@linuxcare.com.au>
5314 * elf32-hppa.c (elf32_hppa_stub_hash_entry): Rename input_section
5316 (stub_hash_newfunc): Here too.
5317 (hppa_add_stub): And here.
5318 (elf32_hppa_link_hash_table): Remove stub_section_created,
5319 reloc_section_created, first_init_sec and first_fini_sec. Add
5321 (elf32_hppa_link_hash_table_create): Init to suit.
5322 (hppa_get_stub_entry): Add support for grouping stub sections.
5323 (hppa_add_stub): Likewise. Remove sec_count param and init/fini
5324 section code. Index stub vars by section->id.
5325 (elf32_hppa_size_stubs): Likewise. Remove duplicated function
5326 exit paths. Zap allocation of above removed vars. Refine
5329 * elf32-hppa.h (elf32_hppa_size_stubs): Add output_bfd param.
5330 * elf32-hppa.c (elf32_hppa_size_stubs): Likewise.
5331 (hppa_get_stub_entry): Pass in pointer to elf32_hppa_link_hash_table
5332 rather than pointer to bfd_link_info.
5333 (hppa_add_stub): Likewise.
5334 (final_link_relocate): Likewise.
5336 2000-09-17 David Huggins-Daines <dhd@linuxcare.com>
5338 (elf32_hppa_size_stubs): Don't try to build stubs for discarded
5341 2000-09-16 Alexandre Oliva <aoliva@redhat.com>
5343 * elf32-sh.c (ELF_MAXPAGESIZE): Define to 128, to match
5344 ld/emulparams/shelf.sh.
5346 2000-09-10 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5348 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): New function.
5349 * bfd-in.h (bfd_m68k_elf32_create_embedded_relocs): Add declaration.
5350 * bfd-in2.h: Regenerate.
5352 2000-09-15 Kenneth Block <Kenneth.Block@compaq.com>
5354 * elf64-alpha.c (elf64_alpha_relax_with_lituse): ld performs
5355 LITUSE relocations incorrectly if -relax is specified on the ld
5356 command line and the displacement field of the load or store
5357 instruction is non-zero. (Patch by paul.winalski@compaq.com)
5359 2000-09-15 Alan Modra <alan@linuxcare.com.au>
5361 * elf32-hppa.c (hppa_add_stub): Dont set first_init_sec and
5362 first_fini_sec here.
5363 (elf32_hppa_size_stubs): Instead correctly find the first .init
5364 and .fini section here.
5366 2000-09-15 David Huggins-Daines <dhd@linuxcare.com>
5368 * elf32-hppa.c (clobber_millicode_symbols): New function.
5369 (elf32_hppa_size_dynamic_sections): Call it.
5371 2000-09-14 Alan Modra <alan@linuxcare.com.au>
5373 * elf32-hppa.c (elf32_hppa_link_hash_entry): Make pic_call
5374 packed. Add plabel, plt_abs packed booleans.
5375 (hppa_link_hash_newfunc): Init new fields.
5376 (PLABEL_PLT_ENTRY_SIZE): Define.
5377 (hppa_stub_name): Use size_t len vars.
5378 (hppa_add_stub): Likewise.
5379 (elf32_hppa_build_stubs): Likewise.
5380 (hppa_build_one_stub): Kill some compiler warnings.
5381 (elf32_hppa_check_relocs): Always generate a plt entry for PLABELs
5382 if dynamic linking. Munge the local plt offsets into
5383 local_got_refcounts. Set h->plabel for all global PLABELs. Use
5384 size_t len vars. Add assert for plabel addend.
5385 (elf32_hppa_gc_sweep_hook): Sweep local plt entries too.
5386 (elf32_hppa_hide_symbol): New function.
5387 (elf_backend_hide_symbol): Define.
5388 (elf32_hppa_adjust_dynamic_symbol): Don't throw away plt entries
5389 with h->plabel set. Don't make plt entries to have dynamic syms
5390 when they have been forced local. If plt entry is used by a
5391 plabel, make it PLABEL_PLT_ENTRY_SIZE.
5392 (elf32_hppa_size_dynamic_sections): Set plt_abs for init fns.
5393 Set up .plt offsets for local syms.
5394 (elf32_hppa_relocate_section): Initialise plt entries for local
5395 syms. Leave weak undefined plabels zero. Make global plabel
5396 relocs against function symbol, and leave the addend zero.
5397 Use *ABS* DIR32 relocs instead of SEGREL32 for dynamic got relocs.
5398 (elf32_hppa_finish_dynamic_symbol): Set up IPLT relocs for
5399 non-dynamic syms. Init extra plt for plabels. Use *ABS* DIR32
5400 relocs instead of SEGREL32 for dynamic got relocs.
5401 (elf32_hppa_finish_dynamic_sections): Reserve one more .got entry.
5402 (elf_backend_got_header_size): Adjust.
5403 (elf32_hppa_set_gp): Calculate an "ideal" LTP.
5405 * elf32-hppa.c (LONG_BRANCH_VIA_PLT): Define.
5406 (hppa_type_of_stub): Use it instead of #if 0
5407 (hppa_discard_copies): Use it here too.
5408 (elf32_hppa_size_dynamic_sections): And here.
5410 * elf32-hppa.c (elf32_hppa_link_hash_table): Remove `offset' field.
5411 (elf32_hppa_link_hash_table_create): And here.
5412 (hppa_build_one_stub): And here. Instead keep track of stub
5413 offset using _raw_size.
5414 (elf32_hppa_size_stubs): Likewise.
5415 (elf32_hppa_build_stubs): Likewise.
5416 (hppa_size_one_stub): Likewise. Resize reloc section too.
5418 * elf32-hppa.c (hppa_add_stub): Correct first_init_sec and
5419 first_fini_sec handling. Don't search for reloc section or set
5420 hplink->reloc_section_created here.
5421 (elf32_hppa_size_stubs): Instead search for reloc sections, and
5422 set reloc_section_created here.
5423 (hppa_handle_PIC_calls): Set ELF_LINK_HASH_NEEDS_PLT.
5424 (elf32_hppa_size_dynamic_sections): Make a .plt entry for DT_INIT
5426 (elf32_hppa_finish_dynamic_sections): Set DT_INIT and DT_FINI.
5428 * elf32-hppa.c (hppa_build_one_stub): Replace `elf_hash_table (info)'
5429 with `hplink->root.'.
5430 (elf32_hppa_check_relocs): Likewise.
5431 (elf32_hppa_gc_sweep_hook): Likewise.
5432 (elf32_hppa_adjust_dynamic_symbol): Likewise.
5433 (hppa_handle_PIC_calls): Likewise.
5434 (elf32_hppa_size_dynamic_sections): Likewise.
5435 (elf32_hppa_set_gp): Likewise.
5436 (elf32_hppa_relocate_section): Likewise.
5437 (elf32_hppa_finish_dynamic_symbol): Likewise.
5438 (elf32_hppa_finish_dynamic_sections): Likewise.
5440 From David Huggins-Daines <dhd@linuxcare.com>
5441 * elf32-hppa.c (hppa_type_of_stub): Generate import stubs for
5442 defined weak symbols in shared links.
5443 (final_link_relocate): Calls to defined weak symbols in shared
5444 objects must go via import stubs, as the target might not be known
5447 2000-09-14 Alexandre Oliva <aoliva@redhat.com>
5449 * elf32-sh.c (sh_elf_howto_table): Moved R_SH_GOT32, R_SH_PLT32,
5450 R_SH_COPY, R_SH_GLOB_DAT, R_SH_JMP_SLOT, R_SH_RELATIVE,
5451 R_SH_GOTOFF, R_SH_GOTPC) to the range from 160 to 167. Replaced
5452 the original entries with EMPTY_HOWTOs, and added new ones to fill
5454 (sh_elf_info_to_howto): Make sure the new gap isn't used.
5455 (sh_elf_relocate_section): Likewise.
5457 2000-09-13 Anders Norlander <anorland@acc.umu.se>
5459 * cpu-mips.c (arch_info_struct): Add mips:4K
5460 * bfd-in2.h (bfd_mach_mips4K): New define.
5461 * archures.c: Add bfd_mach_mips4K to comment.
5462 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Return
5463 E_MIPS_ARCH_2 for bfd_mach_mips4K.
5465 2000-09-13 Marco Franzen <marcof@thyron.com>
5467 * som.c (som_write_symbol_strings): Do not used fixed buffers,
5468 use size_t as a counter.
5469 (som_write_space_strings): Similarly.
5471 2000-09-12 Jason Eckhardt <jle@cygnus.com>
5473 * elf32-i860.c (elf32_i860_relocate_pc26): New function
5475 (elf32_i860_relocate_section): Invoke new function from here.
5477 2000-09-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5479 * elf.c (_bfd_elf_make_section_from_shdr): Make debug_sec_names
5482 2000-09-10 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5484 * coff-m68k.c (bfd_m68k_coff_create_embedded_relocs): Emit 8 NULs for
5485 target section name instead of dumping core when the target symbol is
5488 2000-09-09 Kazu Hirata <kazu@hxi.com>
5490 * riscix.c: Remove DEFUN.
5492 2000-09-08 Nick Clifton <nickc@redhat.com>
5494 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Do not
5495 initialise flags in output bfd if the input bfd is the default
5496 architecture with the default flags.
5498 2000-09-08 Kazu Hirata <kazu@hxi.com>
5500 * archive.c: Fix formatting.
5501 * coff-arm.c: Likewise.
5502 * doc/chew.c: Likewise.
5504 2000-09-08 Alan Modra <alan@linuxcare.com.au>
5506 * section.c (bfd_get_unique_section_name): Put a dot before the
5509 2000-09-07 Kazu Hirata <kazu@hxi.com>
5511 * doc/chew.c: Remove all uses of DEFUN and DEFUN_VOID.
5512 * elf.c: Fix formatting.
5514 2000-09-07 Alexandre Oliva <aoliva@redhat.com>
5516 * config.bfd (sh-*-linux*): Added.
5517 * configure.in (bfd_elf32_shlin_vec, bfd_elf32_shblin_vec): New.
5518 * targets.c: Declare them.
5519 * elf32-sh-lin.c: New file.
5520 * Makefile.am: Compile it.
5521 * elf32-sh.c: Don't override defines from elf32-sh-lin.c.
5522 * configure, Makefile.in: Rebuilt.
5524 2000-09-06 Geoffrey Keating <geoffk@cygnus.com>
5526 * xcofflink.c (xcoff_link_input_bfd): Include the .tocbss
5527 pseduo-section when determining where the TOC ends.
5529 * coff-rs6000.c (_bfd_xcoff_swap_aux_out): Use bfd_h_put_16 to
5530 output x_tvndx as it is only two bytes wide.
5532 * coff-rs6000.c (xcoff_howto_table): A modifiable branch-absolute
5533 reloc is 26 or 32 bits wide.
5535 * coff-rs6000.c (_bfd_xcoff_rtype2howto): The bitsize is irrelevant
5536 for relocs that don't change anything. Also look at the full
5539 2000-09-06 Philip Blundell <philb@gnu.org>
5541 * config.bfd (arm*-*-uclinux*): New target.
5543 2000-09-06 Alexandre Oliva <aoliva@redhat.com>
5545 * configure: Rebuilt with new libtool.m4.
5547 2000-09-06 Alan Modra <alan@linuxcare.com.au>
5549 * section.c (bfd_get_unique_section_name): Avoid c++ reserved
5550 word for variable name.
5551 * bfd-in2.h: Regenerate.
5553 2000-09-05 Nick Clifton <nickc@redhat.com>
5555 * config.in: Regenerate.
5556 * libbfd.h: Regenerate.
5557 * po/bfd.pot: Regenerate.
5558 * doc/bfdint.texi: Remove CVS date string - it foils compares with
5561 2000-09-05 Steven Johnson <sbjohnson@ozemail.com.au>
5563 * cpu-powerpc.c (arch_info_struct): Added MPC860 Family entry.
5565 2000-09-05 Alan Modra <alan@linuxcare.com.au>
5567 Shared library and PIC support.
5568 * elf32-hppa.c (PLT_ENTRY_SIZE): New.
5569 (GOT_ENTRY_SIZE): New.
5570 (ELF_DYNAMIC_INTERPRETER): New.
5571 (STUB_SUFFIX): Define.
5572 (LONG_BRANCH_PIC_IN_SHLIB): Define.
5573 (RELATIVE_DYNAMIC_RELOCS): Define.
5574 (enum elf32_hppa_stub_type): New.
5575 (struct elf32_hppa_stub_hash_entry): Rename offset to
5576 stub_offset. Add a number of new fields.
5577 (struct elf32_hppa_link_hash_entry): New.
5578 (struct elf32_hppa_link_hash_table): Add numerous fields. Remove
5580 (elf32_hppa_hash_table): Rename to hppa_link_hash_table.
5581 (elf32_hppa_stub_hash_lookup): Rename to hppa_stub_hash_lookup.
5582 (elf32_hppa_stub_hash_newfunc): Rename to stub_hash_newfunc. Init
5584 (hppa_link_hash_newfunc): New function.
5585 (elf32_hppa_link_hash_table_create): Use above function. Init new
5587 (elf32_hppa_stub_name): Rename to hppa_stub_name. Pass in reloc
5588 instead of addend, and remove sym_name from args. Don't use
5589 symbol name for local syms, instead use sym index.
5590 (elf32_hppa_size_of_stub): Rename to hppa_type_of_stub, and return
5591 stub type rather than size. Pass in hash and handle import stub
5592 case. Also pass in reloc instead of offset so we can calculate
5593 PCREL22F and PCREL12F branches properly.
5594 (elf32_hppa_build_one_stub): Rename to hppa_build_one_stub. Build
5595 import and export stubs too.
5596 (elf32_hppa_size_one_stub): Rename to hppa_size_one_stub. Handle
5597 import and export stub sizing.
5598 (elf32_hppa_check_relocs): New function.
5599 (elf32_hppa_adjust_dynamic_symbol): New function.
5600 (hppa_discard_copies): New function.
5601 (elf32_hppa_size_dynamic_sections): New function.
5602 (elf_backend_size_dynamic_sections): Define.
5603 (elf32_hppa_finish_dynamic_symbol): New function.
5604 (elf_backend_finish_dynamic_symbol): Define.
5605 (elf32_hppa_size_stubs): Stash params in link hash table, and move
5606 some local vars into the link hash table too. For shared links,
5607 trundle over function syms, generating export stubs. Handle
5608 PCREL22F branches. Break out stub creation code from here..
5609 (hppa_add_stub): .. to here. New function.
5610 (elf32_hppa_final_link): Rename to elf32_hppa_set_gp, and don't
5611 call the bfd linker. Use elf_gp to record global pointer.
5612 Calculate a value from sections if $global$ is missing.
5613 (bfd_elf32_bfd_final_link): Define as _bfd_elf32_gc_common_final_link.
5614 (elf32_hppa_gc_mark_hook): New function.
5615 (elf_backend_gc_mark_hook): Define.
5616 (elf32_hppa_gc_sweep_hook): New function.
5617 (elf_backend_gc_sweep_hook): Define.
5618 (elf32_hppa_bfd_final_link_relocate): Rename to final_link_relocate.
5619 Add rel to args, and remove howto, input_bfd, offset, addend,
5620 sym_name as we can recalculate these locally. Handle calls to
5621 dynamic objects, extra PIC relocs, PCREL22F branches. Change
5622 handling of undefined weak syms. Check that stubs are in range.
5623 Only look for import stubs on PCREL17F and PCREL22F relocs. Add
5624 message on hitting a DPREL21L reloc that needs fixing. Subtract
5625 off PC for PCREL14F. Break out code that does a stub lookup from
5627 (hppa_get_stub_entry): ..to here. New function.
5628 (elf32_hppa_relocate_insn): Merge into final_link_relocate.
5629 (elf32_hppa_relocate_section): Handle got and plt relocs, dynamic
5631 (elf32_hppa_finish_dynamic_sections): New function.
5632 (elf_backend_finish_dynamic_sections): Define.
5633 (elf_backend_final_write_processing) Define.
5634 (hppa_handle_PIC_calls): New function.
5635 (elf32_hppa_build_stubs): Call it. Pass link_info to
5636 hppa_build_one_stub.
5637 (elf32_hppa_create_dynamic_sections): New function
5638 to create .plt and .got then set .plt flags correctly.
5639 (elf_backend_create_dynamic_sections): Define.
5640 (elf32_hppa_object_p): New function.
5641 (elf_backend_object_p): Define.
5642 (elf32_hppa_elf_get_symbol_type): New function.
5643 (elf_backend_get_symbol_type): Define.
5644 (elf_backend_can_gc_sections): Define.
5645 (elf_backend_want_got_plt): Define.
5646 (elf_backend_plt_alignment): Set to 2.
5647 (elf_backend_plt_readonly): Define.
5648 (elf_backend_want_plt_sym): Define.
5649 (elf_backend_got_header_size): Reserve one entry.
5651 * elf32-hppa.h (elf32_hppa_build_stubs): Don't pass stub bfd.
5652 (elf32_hppa_size_stubs): Pass in multi_subspace.
5653 (elf32_hppa_set_gp): Declare.
5655 * section.c (SEC_HAS_GOT_REF): Define new flag for asection.
5656 (bfd_get_unique_section_name): New function.
5657 * bfd-in2.h: Regenerate.
5659 * elf64-hppa.c (elf64_hppa_check_relocs): Handle R_PARISC_PCREL12F.
5660 (elf64_hppa_size_dynamic_sections): Remove the FIXME at bfd_zalloc
5663 From David Huggins-Daines <dhd@linuxcare.com>
5664 * elf64-hppa.c (elf64_hppa_check_relocs): Fix a warning.
5665 (elf64_hppa_mark_exported_functions): Set dyn_h->st_shndx.
5666 (elf64_hppa_link_output_symbol_hook): Test dyn_h->st_shndx has
5667 been updated in finish_dynamic_symbol before modifying function
5670 * elf-hppa.h (elf_hppa_howto_table): Restructure into groups of
5671 eight entries. Replace NULL with bfd_elf_generic_reloc. Add
5672 R_PARISC_GNU_VTENTRY, R_PARISC_GNU_VTINHERIT and R_PARISC_PCREL12F.
5673 (_bfd_elf_hppa_gen_reloc_type): Handle R_PARISC_GNU_VT*. Add some
5674 comments. Handle format == 12 for R_HPPA_PCREL_CALL.
5675 (elf_hppa_final_link_relocate): Handle R_PARISC_PCREL12F.
5676 (elf_hppa_relocate_insn): Likewise. Reformat some comments.
5677 (elf_hppa_final_write_processing): Expose it for ARCH_SIZE == 32.
5679 From David Huggins-Daines <dhd@linuxcare.com>
5680 * elf-hppa.h (elf_hppa_is_local_label_name): Accept the SysV/ELF
5681 style of local labels as well.
5683 2000-09-03 Philip Blundell <philb@gnu.org>
5685 * elf32-arm.h (elf32_arm_relocate_section): Don't try to relocate
5686 references to undefined symbols in debugging sections.
5688 2000-09-02 H.J. Lu <hjl@gnu.org>
5690 * reloc.c (BFD_RELOC_SH_COPY, BFD_RELOC_SH_GLOB_DAT,
5691 BFD_RELOC_SH_JMP_SLOT, BFD_RELOC_SH_RELATIVE,
5692 BFD_RELOC_SH_GOTPC): Move them from the MIPS section to the SH
5695 2000-09-02 Jason Eckhardt <jle@cygnus.com>
5697 * elf32-i860.c (bfd_elf32_bfd_is_local_label_name): Define macro.
5698 (elf32_i860_is_local_label_name): New function and prototype.
5700 2000-09-02 Nick Clifton <nickc@redhat.com>
5702 * configure.in: Increase version number to 2.10.91.
5703 * configure: Regenerate.
5704 * aclocal.m4: Regenerate.
5705 * config.in: Regenerate.
5706 * po/bfd.pot: Regenerate.
5708 2000-09-02 Daniel Berlin <dberlin@redhat.com>
5710 * elf.c (_bfd_elf_make_section_from_shdr): Add
5711 .gnu.linkobce.wi. to the list of debug section names.
5713 2000-09-02 Nick Clifton <nickc@redhat.com>
5715 * dwarf2.c (find_debug_info): New function: Locate a section
5716 containing dwarf2 debug information.
5717 (bfd_dwarf2_find_nearest_line): Find all sections containing
5718 debug information and include them in the stash.
5720 2000-09-01 Niibe Yutaka <gniibe@m17n.org>, Kaz Kojima <kkojima@rr.iij4u.or.jp>, Alexandre Oliva <aoliva@redhat.com>
5722 * elf32-sh.c (R_SH_GOT32, R_SH_PLT32, R_SH_COPY, R_SH_GLOB_DAT,
5723 R_SH_JMP_SLOT, R_SH_RELATIVE, R_SH_GOTOFF, R_SH_GOTPC): New.
5724 (sh_reloc_map): Add new relocs.
5725 (sh_elf_check_relocs, sh_elf_link_hash_newfunc,
5726 sh_elf_link_hash_table_create, sh_elf_adjust_dynamic_symbol,
5727 sh_elf_size_dynamic_sections, sh_elf_finish_dynamic_symbol,
5728 sh_elf_finishe_dynamic_sections, sh_elf_discard_copies): New
5730 (ELF_DYNAMIC_INTERPRETER, PLT_ENTRY_SIZE): Define.
5731 (elf_sh_plt0_entry_be, elf_sh_plt0_entry_le,
5732 elf_sh_plt_entry_be, elf_sh_plt_entry_le,
5733 elf_sh_pic_plt_entry_be, elf_sh_pic_plt_entry_le):
5734 New array constants.
5735 (elf_sh_plt0_entry, elf_sh_plt_entry, elf_sh_pic_plt_entry):
5737 (elf_sh_sizeof_plt, elf_sh_plt_plt0_offset,
5738 elf_sh_plt0_linker_offset, elf_sh_plt0_gotid_offset,
5739 elf_sh_plt_temp_offset, elf_sh_plt_symbol_offset,
5740 elf_sh_plt_reloc_offset): Define.
5741 (elf_sh_pcrel_relocs_copied, elf_sh_link_hash_entry,
5742 elf_sh_link_hash_table): New structs.
5743 (sh_elf_link_hash_traverse, sh_elf_hash_table): New macros.
5744 (sh_elf_relocate_section, sh_elf_check_relocs): Handle new
5746 (elf_backend_create_dynamic_sections,
5747 bfd_elf32_bfd_link_hash_table_create,
5748 elf_backend_adjust_dynamic_symbol,
5749 elf_backend_size_dynamic_sections,
5750 elf_backend_finish_dynamic_symbol,
5751 elf_backend_finish_dynamic_sections, elf_backend_want_got_plt,
5752 elf_backend_plt_readonly, elf_backend_want_plt_sym,
5753 elf_backend_got_header_size, elf_backend_plt_header_size):
5755 * reloc.c (BFD_RELOC_SH_COPY, BFD_RELOC_SH_GLOB_DAT,
5756 BFD_RELOC_SH_JMP_SLOT, BFD_RELOC_SH_RELATIVE, BFD_RELOC_SH_GOTPC):
5758 * bfd-in2.h, libbfd.h: Rebuilt.
5760 2000-09-01 Alan Modra <alan@linuxcare.com.au>
5762 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Revert 2000-08-27
5765 2000-08-31 J"orn Rennecke <amylaar@cygnus.co.uk>
5767 * elf32-sh.c (sh_elf_merge_private_data): If ibfd's elf header flags
5768 not initialized, set them to indicate the SH1 instruction set.
5770 2000-08-31 Alexandre Oliva <aoliva@redhat.com>
5772 * acinclude.m4: Include libtool and gettext macros from the
5774 * aclocal.m4, configure: Rebuilt.
5776 2000-08-29 Michael Snyder <msnyder@seadog.cygnus.com>
5778 * elf.c: Eliminate references to __sparcv9 macro; replace with
5779 autoconf variables HAVE_PSINFO32_T etc.
5780 * configure.in: Auto-configure HAVE_PSINFO_32_T, HAVE_PRPSINFO32_T,
5781 HAVE_PSTATUS32_T, HAVE_PRSTATUS32_T, HAVE_PRSTATUS32_T_PR_WHO.
5783 * acinclude.m4 (BFD_HAVE_SYS_PROCFS_TYPE) define _SYSCALL32 so it can
5784 detect the above typedefs. (BFD_HAVE_SYS_PROCFS_TYPE_MEMBER): Ditto.
5785 * aclocal.m4: Ditto.
5786 * configure: Regenerate.
5788 2000-08-27 Alan Modra <alan@linuxcare.com.au>
5790 * elf32-i386.c (elf_i386_check_relocs): Keep info on relocs copied
5791 for any shared link, not just shared -Bsymbolic.
5792 (elf_i386_size_dynamic_sections): Call elf_i386_discard_copies on
5793 any shared link, and pass link info to it.
5794 (elf_i386_size_dynamic_sections): Update comment.
5795 (elf_i386_discard_copies): Modify to discard relocs for symbols
5796 that have been forced local.
5797 (elf_i386_finish_dynamic_symbol): Don't copy relocs for symbols
5798 that have been forced local.
5800 2000-08-24 Denis Chertykov <denisc@overta.ru> & Nick Clifton <nickc@redhat.com>
5802 * elflink.h (elf_link_add_object_symbols): Allow common
5803 symbols to have an alignment of 1 if explicitly requested, and
5804 not overridden by other definitions.
5806 2000-08-22 Doug Kwan <dkwan@transmeta.com>
5808 * coff-w65.c (CREATE_LITTLE_COFF_TARGET): Fix typo.
5809 * coffcode.h (coff_set_flags): Add detection of w65 architecture.
5811 2000-08-22 H.J. Lu <hjl@gnu.org>
5813 * elf-bfd.h (elf_link_hash_table): Add runpath.
5815 * bfd-in.h (bfd_elf_get_runpath_list): New prototype.
5816 * bfd-in2.h: Rebuilt.
5818 * elf.c (_bfd_elf_link_hash_table_init): Initialize the
5819 "runpath" field to NULL.
5820 (bfd_elf_get_runpath_list): New function.
5822 * elflink.h (elf_link_add_object_symbols): Record DT_RPATH and
5825 2000-08-22 Alexandre Oliva <aoliva@redhat.com>
5827 * elf32-sh.c (sh_elf_relocate_section) [R_SH_IND12W,
5828 R_SH_DIR8WPN, R_SH_DIR8WPZ, R_SH_DIR8WPL]: Handle them
5829 explicitly. Improve validation of r_type.
5831 2000-08-21 H.J. Lu <hjl@gnu.org>
5833 * elf32-i386.c (elf_i386_size_dynamic_sections): Zero out the
5834 dynamic allocated content space. Add a comment to remind us that
5835 one day this ought to be fixed.
5836 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
5837 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
5838 * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
5840 2000-08-21 Jason Eckhardt <jle@cygnus.com>
5842 * elf32-i860.c (elf32_i860_relocate_pc16): Just write the immediate
5843 field with the newly relocated value instead of adding it to the
5844 existing immediate field.
5845 (elf32_i860_relocate_splitn): Likewise.
5846 (elf32_i860_relocate_highadj): Likewise.
5848 2000-08-16 Jason Eckhardt <jle@cygnus.com>
5850 * elf32-i860.c (elf32_i860_relocate_pc16): Implemented function (it
5851 was previously just a stub).
5853 2000-08-16 Alexandre Oliva <aoliva@redhat.com>
5855 * elflink.c (_bfd_elf_create_got_section): Don't abort().
5857 (_bfd_elf_create_dynamic_sections): Likewise.
5859 2000-08-16 Andrew Macleod <amacleod@cygnus.com>
5861 * elf64-sparc.c (sparc64_elf_relocate_section): Set relocation address
5862 for undefined symbols to be the beginning of the section.
5864 * elf64-sparc.c (sparc64_elf_adjust_dynamic_symbol): Don't allocate
5865 four extra entries at the beginning of the .rela.plt section.
5866 (sparc64_elf_finish_dynamic_symbol): Adjust the offset in the .rela.plt
5867 section to account for the four reserved entries in the .plt section.
5869 2000-08-15 Geoffrey Keating <geoffk@cygnus.com>
5871 * xcofflink.c (_bfd_ppc_xcoff_relocate_section): Add ori r0,r0,0
5872 to the list of NOPs we recognize after a branch-and-link.
5873 Use the ori NOP when one is needed.
5875 * coff-rs6000.c (_bfd_xcoff_slurp_armap): Finish implementation
5878 2000-08-14 Jim Wilson <wilson@cygnus.com>
5880 * elf64-ia64.c (elf64_ia64_merge_private_bfd_data): Handle
5881 EF_IA_64_REDUCEDFP, EF_IA_64_CONS_GP, and EF_IA_64_NOFUNCDESC_CONS_GP.
5882 (elf64_ia64_print_private_bfd_data): Likewise. Also handle
5885 2000-08-11 Alexandre Oliva <aoliva@redhat.com>
5887 * elf32-sh.c (sh_elf_set_mach_from_flags): Make it static.
5889 2000-08-10 Jason Eckhardt <jle@cygnus.com>
5891 * elf32-i860.c (elf32_i860_relocate_section): New function.
5892 (i860_final_link_relocate): New function.
5893 (elf32_i860_relocate_splitn): New function.
5894 (elf32_i860_relocate_pc16): New function.
5895 (elf32_i860_relocate_highadj): New function.
5896 (elf32_i860_howto): Minor adjustments to some relocations.
5897 (elf_info_to_howto_rel): Define.
5898 (elf_backend_relocate_section): Define.
5900 2000-08-10 Nick Clifton <nickc@cygnus.com>
5902 * elf32-arm.h: Fix formatting.
5904 2000-08-10 Bernd Schmidt <bernds@cygnus.co.uk>
5906 * elf32-sh.c (sh_elf_reloc_loop): Make LAST_SYMBOL_SECTION static.
5908 2000-08-08 Jason Eckhardt <jle@cygnus.com>
5910 * elf32-i860.c (elf32_i860_howto_table): Updated some fields.
5912 2000-08-07 Kazu Hirata <kazu@hxi.com>
5914 * ieee.c (ieee_write_debug_part): Rewrite a comment.
5915 * elf64-ia64.c: Fix a typo.
5917 2000-08-05 Jason Eckhardt <jle@cygnus.com>
5919 * elf32-i860.c (elf32_i860_howto_table): New structure.
5920 (lookup_howto): New function.
5921 (elf32_i860_reloc_type_lookup): New function.
5922 (elf32_i860_info_to_howto_rela): New function.
5923 (elf_code_to_howto_index): New structure.
5924 (elf_info_to_howto): Re-define as elf32_i860_info_to_howto_rela.
5925 (bfd_elf32_bfd_reloc_type_lookup): Re-define as
5926 elf32_i860_reloc_type_lookup.
5928 2000-08-04 Rodney Brown <RodneyBrown@pmsc.com>
5930 * som.c (struct fixup_format): Constify `format'.
5931 (som_hppa_howto_table): Use SOM_HOWTO macro.
5932 (try_prev_fixup, hppa_som_reloc): Decorate unused parameter.
5933 (som_bfd_reloc_type_lookup): Likewise.
5934 (compare_subspaces): Remove unused `count1', `count2'.
5935 (som_begin_writing): Remove unused `total_reloc_size'.
5936 (som_bfd_derive_misc_symbol_info): Decorate unused parameter.
5937 (som_print_symbol, som_bfd_is_local_label_name): Likewise.
5938 (som_set_reloc_info): Constify `cp'. Remove unused `addend'.
5939 (som_find_nearest_line): Decorate unused parameter(s).
5940 (som_sizeof_headers, som_get_symbol_info, som_write_armap): Likewise.
5941 (som_bfd_link_split_section): Likewise.
5943 2000-08-03 Nick Clifton <nickc@cygnus.com>
5945 * section.c: Restore backed out code.
5946 * elf.c: Restore backed out code.
5947 (copy_private_bfd_data): Fix bug preventing stipped dynamic
5948 binaries from working.
5949 * bfd-in2.h: Regenerate.
5951 2000-08-03 H.J. Lu <hjl@gnu.org>
5953 * section.c: Back out the change made by Nick Clifton
5954 <nickc@cygnus.com> on 2000-07-31. It breaks stripping dynamic
5956 * bfd-in2.h: Likewise.
5959 2000-08-03 Alexandre Oliva <aoliva@redhat.com>
5961 * elf32-sh.c (sh_elf_reloc_loop): Warning removal.
5963 2000-07-31 Jason Eckhardt <jle@cygnus.com>
5965 * reloc.c (BFD_RELOC_860_*): New bfd relocs for i860.
5966 * bfd-in2.h, libbfd.h: Regenerate.
5968 2000-07-31 Nick Clifton <nickc@cygnus.com>
5970 * section.c (struct sec): Add new boolean field 'segment_mark'.
5971 (STD_SECTION): Initialise new field to zero.
5973 * bfd-in2.h: Regenerate.
5975 * elf.c (copy_private_bfd_data): Reorganise section to segment
5976 mapping to cope with moved sections requiring new segments,
5977 and overlapping segments.
5978 (SEGMENT_END): New macro: Return the end address of a segment.
5979 (IS_CONTAINED_BY_VMA): New macro: Determine if a segment
5980 contains a section by comparing their VMA addresses.
5981 (IS_CONTAINED_BY_LMA): New macro: Determine if a segment
5982 contains a section by comparing their LMA addresses.
5983 (INCLUDE_SECTION_IN_SEGMENT): New macro: Determine if a
5984 section should be included in a segment.
5985 (SEGMENT_AFTER_SEGMENT): New macro: Determine if one segment
5986 follows another in memory.
5987 (SEGMENT_OVERLAPS_SEGMENT): New macro: Determine if two
5990 2000-07-22 Jason Eckhardt <jle@cygnus.com>
5992 * cpu-i860.c: Added comments.
5994 * elf32-i860.c (TARGET_LITTLE_SYM): Defined to
5995 bfd_elf32_i860_little_vec.
5996 (TARGET_LITTLE_NAME): Defined to "elf32-i860-little".
5997 (ELF_MAXPAGESIZE): Changed to 4096.
5999 * targets.c (bfd_elf32_i860_little_vec): Declaration of
6001 (bfd_target_vector): Added bfd_elf32_i860_little_vec.
6003 * config.bfd (i860-stardent-sysv4*, i860-stardent-elf*): Added
6004 config for little endian elf32 i860.
6005 (targ_defvec): Define for the new config above
6006 as "bfd_elf32_i860_little_vec".
6007 (targ_selvecs): Define for the new config above
6008 as "bfd_elf32_i860_vec bfd_elf32_i860_little_vec"
6010 * configure.in (bfd_elf32_i860_little_vec): Added recognition
6013 * configure: Regenerated.
6015 2000-07-27 H.J. Lu <hjl@gnu.org>
6017 * elflink.h (elf_merge_symbol): Take one more argument,
6018 dt_needed, to indicate if the symbol comes from a DT_NEEDED
6019 entry. Don't overide the existing weak definition if dt_needed
6021 (elf_link_add_object_symbols): Pass dt_needed to
6022 elf_merge_symbol ().
6024 2000-07-27 Nick Clifton <nickc@cygnus.com>
6026 * elflink.h (elf_link_size_reloc_section): Zeroes the section's
6029 2000-07-25 Geoffrey Keating <geoffk@cygnus.com>
6031 * configure.host (*-*-aix*): AIX has 'long long' always.
6033 * coff-rs6000.c (xcoff_write_one_armap_big): New procedure.
6034 (xcoff_write_armap_big): Write both 32-bit and 64-bit armaps.
6035 (xcoff_write_archive_contents_big): Don't update the offset
6036 of the symbol table, xcoff_write_armap will do it.
6038 2000-07-23 Ulf Carlsson <ulfc@engr.sgi.com>
6040 * elf32-mips.c (_bfd_mips_elf_check_relocs): Use abfd instead
6041 of dynobj for SGI_COMPAT checks.
6043 2000-07-21 Michael Sokolov <msokolov@ivan.Harhan.ORG>
6045 * coff-m68k.c (bfd_m68k_coff_create_embedded_relocs): New function.
6046 * bfd-in.h (bfd_m68k_coff_create_embedded_relocs): Add declaration.
6047 * bfd-in2.h: Regenerate.
6049 2000-07-21 Nick Clifton <nickc@cygnus.com>
6051 * elf32-mips.c (_bfd_mips_elf_check_relocs): Detect out of
6052 range symbol indices in relocs and issue an error message.
6054 2000-07-20 H.J. Lu <hjl@gnu.org>
6056 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Don't check
6057 info->new_dtags when setting DT_FLAGS_1. It will only be set
6058 by the new linker options. It shouldn't break anything.
6060 2000-07-20 H.J. Lu <hjl@gnu.org>
6062 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set DT_FLAGS_1
6063 only if info->new_dtags is true.
6065 2000-07-20 H.J. Lu <hjl@gnu.org>
6067 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set
6068 DT_RUNPATH and DT_FLAGS only if info->new_dtags is true.
6070 2000-07-20 Hans-Peter Nilsson <hp@axis.com>
6072 * Makefile.am (ALL_MACHINES): Add cpu-cris.lo.
6073 (ALL_MACHINES_CFILES): Add cpu-cris.c.
6074 (BFD32_BACKENDS): Add aout-cris.lo and elf32-cris.lo.
6075 (BFD32_BACKENDS_CFILES): Add aout-cris.c and elf32-cris.c.
6076 (cpu-cris.lo, aout-cris.lo, elf32-cris.lo): New rules.
6077 * Makefile.in: Rebuild.
6078 * aclocal.m4: Rebuild.
6079 * aoutx.h (NAME(aout,machine_type)): Add case for bfd_arch_cris.
6080 * archures.c (enum bfd_architecture): Add bfd_arch_cris.
6081 (bfd_cris_arch): Declare.
6082 (bfd_archures_list): Add bfd_cris_arch.
6083 * bfd-in2.h: Rebuild.
6084 * config.bfd: (cris-*-*): New target.
6085 * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vectors.
6086 * configure: Rebuild.
6087 * elf.c (prep_headers): Add bfd_arch_cris.
6088 * libbfd.h: Rebuild.
6089 * libaout.h (enum machine_type): Add M_CRIS.
6090 * reloc.c: Add CRIS relocations.
6091 * targets.c (bfd_elf32_cris_vec, cris_aout_vec): Declare.
6092 (bfd_target_vect): Add bfd_elf32_cris_vec and cris_aout_vec.
6093 * cpu-cris.c, aout-cris.c, elf32-cris.c: New files.
6094 * po/POTFILES.in, po/bfd.pot: Regenerate.
6096 2000-07-19 H.J. Lu <hjl@gnu.org>
6098 * elf32-arm.h (elf32_arm_size_dynamic_sections): Also set
6099 DF_TEXTREL if DT_TEXTREL is set.
6100 * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise.
6101 * elf32-i386.c (elf_i386_size_dynamic_sections): Likewise.
6102 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
6103 * elf32-mips.c (_bfd_mips_elf_size_dynamic_sections): Likewise.
6104 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise.
6105 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
6106 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Likewise.
6107 * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
6108 * elf64-ia64.c (elf64_ia64_size_dynamic_sections): Likewise.
6109 * elf64-sparc.c (sparc64_elf_size_dynamic_sections): Likewise.
6111 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Also
6112 set DF_SYMBOLIC for symbolic link. Also set DT_RUNPATH if
6114 Set the DT_FLAGS and DT_FLAGS_1 entries if necessary.
6116 2000-07-19 H.J. Lu <hjl@gnu.org>
6118 * bfd-in.h (bfd_elf_set_dt_needed_soname): New.
6119 * bfd-in2.h: Rebuild.
6121 * elf-bfd.h (elf_obj_tdata): Add dt_soname.
6122 (elf_dt_soname): New.
6124 * elf.c (bfd_elf_set_dt_needed_soname): New.
6126 * elflink.h (elf_link_add_object_symbols): Add the DT_NEEDED
6127 entry if the shared object loaded by DT_NEEDED is used to
6128 resolve the reference in a regular object.
6130 2000-07-19 H.J. Lu <hjl@gnu.org>
6132 * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_CONFIG,
6133 DT_DEPAUDIT and DT_AUDIT as strings.
6135 2000-07-19 Nick Clifton <nickc@cygnus.com>
6137 * format.c: Fix formatting.
6139 2000-07-19 H.J. Lu <hjl@gnu.org>
6141 * elf.c (_bfd_elf_print_private_bfd_data): Fix DT_CHECKSUM.
6143 2000-07-19 H.J. Lu <hjl@gnu.org>
6145 * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_BIND_NOW,
6146 DT_INIT_ARRAY, DT_FINI_ARRAY, DT_INIT_ARRAYSZ, DT_FINI_ARRAYSZ,
6147 DT_RUNPATH, DT_FLAGS, DT_PREINIT_ARRAY, DT_PREINIT_ARRAYSZ,
6148 DT_PLTPADSZ, DT_MOVEENT, DT_MOVESZ, DT_FEATURE, DT_POSFLAG_1,
6149 DT_SYMINSZ, DT_SYMINENT, DT_CONFIG, DT_DEPAUDIT, DT_AUDIT,
6150 DT_PLTPAD, DT_MOVETAB, DT_SYMINFO, DT_RELACOUNT, DT_RELCOUNT,
6151 DT_FLAGS_1, DT_USED and DT_CHECKSUM.
6153 2000-07-18 Andrew Cagney <cagney@b1.cygnus.com>
6155 * elf.c (bfd_elf_get_sign_extend_vma, bfd_elf_get_arch_size): Move
6156 renamed functions from here...
6157 (assign_section_numbers): Use renamed functions.
6158 (prep_headers): Use renamed functions.
6160 * bfd.c (bfd_get_sign_extend_vma, bfd_get_arch_size): ...To here.
6161 * bfd-in.h (bfd_get_sign_extend_vma, bfd_get_arch_size): Update.
6162 * bfd-in2.h: Regenerate.
6164 2000-07-18 Ulf Carlsson <ulfc@engr.sgi.com>
6166 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Add
6167 parenthesis in if statement.
6169 2000-07-17 Koundinya K <kk@ddeorg.soft.net>
6171 Enable the support for Traditional MIPS.
6172 * elf32-mips.c (IRIX_COMPAT): Recognize bfd_elf32_tradbigmips_vecand
6173 return ict_none appropriately for traditional mips targets.
6174 (STUB_LW): Change 0x8f998000 to 0x8f998010 for traditional mips.
6175 (STUB_MOVE): Conditionalize for traditonal mips.
6176 (STUB_LI16): Likewise.
6177 (_bfd_mips_elf_modify_segment_map): Conditionalize to avoid making
6178 room for RTPROC header.
6179 (_bfd_mips_elf_modify_segment_map): For a normal mips executable set
6180 the permission for the PT_DYNAMIC as read, write and execute.
6181 (mips_elf_calculate_relocation): Check for the symbol _DYNAMIC_LINKING
6182 for traditonal mips.
6183 (_bfd_mips_elf_create_dynamic_sections): Add the symbol
6184 _DYNAMIC_LINKING for traditonal mips.
6185 (_bfd_mips_elf_create_dynamic_sections): Add the symbol __RLD_MAP
6186 in case of traditonal mips.
6187 (_bfd_mips_elf_adjust_dynamic_symbol): Create a stub only if a PLT
6188 entry is required. For a function if PLT is not required then set the
6189 corresponding hash table entry to 0.
6190 (_bfd_mips_elf_size_dynamic_sections): Add DT_DEBUG entry for
6192 (_bfd_mips_elf_finish_dynamic_symbol): for a undefined symbol in a
6193 shared object set the value to 0.
6194 (_bfd_mips_elf_finish_dynamic_symbol): Check for the symbol
6195 _DYNAMIC_LINKING for traditonal mips.
6196 (_bfd_mips_elf_finish_dynamic_symbol): Check for the symbol __RLD_MAP
6197 for traditonal mips.
6199 2000-07-15 H.J. Lu <hjl@gnu.org>
6201 * aoutx.h (translate_to_native_sym_flags): Handle BSF_LOCAL.
6203 2000-07-12 Charles Wilson <cwilson@ece.gatech.edu>
6205 * libbfd.c (bfd_seek): fix 'seek beyond EOF' error when writing
6206 out a structure that is BFD_IN_MEMORY.
6208 2000-07-11 Alan Modra <alan@linuxcare.com.au>
6210 * elf64-hppa.c (get_dyn_name): Pass in section pointer instead of
6211 bfd pointer. Print section id instead of bfd pointer for local
6212 syms. Prefix addend with `+' for global syms as well as local.
6213 Correct calculation of name component lengths.
6214 (elf64_hppa_check_relocs): Update call to get_dyn_name.
6216 From David Huggins-Daines <dhd@linuxcare.com>
6217 * elf-hppa.h (elf_hppa_relocate_section): Update calls here too.
6218 * elf64-hppa.c (elf64_hppa_check_relocs): Fix some warnings.
6219 (elf64_hppa_modify_segment_map): Likewise.
6221 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
6223 * elf.c (bfd_elf_get_sign_extend_vma): Return tendency of VMA
6224 addresses to be "naturally" sign extended. Return -1 if unknown.
6225 * bfd-in.h (bfd_elf_get_sign_extend_vma): Add declaration.
6226 * bfd-in2.h: Regenerate.
6228 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
6230 * ecoffswap.h (ecoff_get_off, ecoff_put_off): Add ECOFF_SIGNED_32
6231 and ECOF_SIGNED_64 to list ways to extract an offset.
6232 (ecoff_swap_fdr_in, ecoff_swap_fdr_out, ecoff_swap_pdr_in,
6233 ecoff_swap_pdr_out, ecoff_swap_ext_in, ecoff_swap_ext_out):
6235 * elf64-mips.c (ECOFF_SIGNED_64): Define instead of ECOFF_64.
6236 * elf32-mips.c (ECOFF_SIGNED_32): Define instead of ECOFF_32.
6238 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
6240 * elfcode.h (elf_object_p): Use bfd_set_start_address and not
6241 bfd_get_start_address.
6242 (elf_swap_ehdr_in): Sign extend e_entry when applicable.
6243 (elf_swap_ehdr_out): Ditto.
6245 2000-07-10 Alexander Aganichev <AAganichev@hypercom.com>
6247 * archures.c (bfd_default_scan): Add set of bfd_mach_ cases for
6248 compatibility with older binutils.
6250 2000-07-10 Alan Modra <alan@linuxcare.com.au>
6252 * section.c (bfd_make_section_anyway): Start section_id at 0x10.
6253 (STD_SECTION): Avoid negative ids, instead use 0 to 3.
6255 From Ryan Bradetich <rbradetich@uswest.net>
6256 * dwarf1.c (parse_die): Cure signed/unsigned char warnings.
6257 (parse_line_table): Ditto.
6258 (_bfd_dwarf1_find_nearest_line): Ditto.
6259 * syms.c (cmpindexentry): Remove extra `*' from params.
6261 2000-07-09 Koundinya K <kk@ddeorg.soft.net>
6263 * elf32-mips.c (sort_dynamic_relocs): New Function.
6264 (_bfd_mips_elf_finish_dynamic_sections): Call sort_dynamic_relocs
6265 via qsort to sort the dynamic relocations in increasing r_symndx
6268 2000-07-09 Alan Modra <alan@linuxcare.com.au>
6270 * elf64-hppa.c (elf64_hppa_dyn_hash_table_init): Add
6271 ATTRIBUTE_UNUSED to unused args.
6272 (get_opd): Likewise.
6273 (get_plt): Likewise.
6274 (get_dlt): Likewise.
6275 (get_stub): Likewise.
6276 (elf64_hppa_adjust_dynamic_symbol): Likewise.
6277 (elf64_hppa_link_output_symbol_hook): Likewise.
6278 (elf64_hppa_check_relocs): Delete unused var.
6279 (elf64_hppa_size_dynamic_sections): Likewise.
6280 (elf64_hppa_finalize_opd): Likewise.
6281 (elf64_hppa_finalize_dynreloc): Likewise.
6282 (elf64_hppa_modify_segment_map): Likewise.
6283 (elf64_hppa_finish_dynamic_sections): Likewise.
6285 * elf-hppa.h (elf_hppa_final_write_processing): Add
6286 ATTRIBUTE_UNUSED to unused args.
6287 (elf_hppa_final_link_relocate): Likewise.
6288 (elf_hppa_record_segment_addrs): Add paretheses.
6289 (elf_hppa_relocate_section): Constify dyn_name.
6291 From David Huggins-Daines <dhd@linuxcare.com>
6292 * config.bfd: Add hppa*64*-*-linux-gnu 64-bit target, and
6293 rearrange case statement so that it gets preferred to 32-bit ones.
6295 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Use
6296 asection->id instead of address of asection structure.
6297 (elf32_hppa_size_stubs): Likewise.
6299 * elf32-hppa.c (elf32_hppa_size_stubs): Use just one stub section
6300 for .init* and .fini*.
6302 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Mask pointers
6303 and addends used in stub names to 32 bits.
6304 (elf32_hppa_size_stubs): Likewise.
6306 * elf-hppa.h (elf_hppa_final_link_relocate): Don't sum addend
6307 twice for R_PARISC_GPREL64. Use bfd_put_32 for R_PARISC_PCREL32,
6308 not bfd_put_64. Fix minor comment typo and formatting.
6310 Changes to create multiple linker stubs, positioned immediately
6311 before the section where they are required.
6312 * elf32-hppa.c: Don't include hppa_stubs.h.
6313 (elf32_hppa_stub_hash_entry): Add a pointer to the stub section.
6314 (elf32_hppa_stub_hash_table): Delete.
6315 (elf32_hppa_link_hash_entry): Delete.
6316 (elf32_hppa_link_hash_table): Use plain bfd_hash_table for
6317 stub_hash_table, and store the struct here rather than a pointer.
6318 Delete output_symbol_count. Add offset array. Change
6319 global_value to a bfd_vma.
6320 (elf32_hppa_stub_hash_lookup): Use table instead of table->root.
6321 (elf32_hppa_stub_hash_traverse): Delete.
6322 (elf32_hppa_name_of_stub): Delete.
6323 (elf32_hppa_link_hash_lookup): Delete.
6324 (elf32_hppa_link_hash_traverse): Delete.
6325 (elf32_hppa_stub_hash_table_init): Delete.
6326 (elf32_hppa_size_of_stub): Pass input section and offset rather
6327 than location and calculate location here. Don't pass name as all
6328 stubs are now the same size.
6329 (elf32_hppa_stub_hash_newfunc): Init new fields.
6330 (elf32_hppa_link_hash_table_create): Likewise, and stub_hash_table
6332 (elf32_hppa_bfd_final_link_relocate): Cast enums to int before
6333 comparing against ints. Rewrite stub handling code.
6334 (elf32_hppa_relocate_section): Make r_type and r_symndx unsigned.
6335 Case enums to int before comparing against ints. Remove
6336 bfd_reloc_dangerous case.
6337 (elf32_hppa_build_one_stub): Rewrite.
6338 (elf32_hppa_size_one_stub): New function.
6339 (elf32_hppa_build_stubs): Rewrite.
6340 (elf32_hppa_size_stubs): Pass in linker call-back functions.
6341 Rewrite stub-handling specific code.
6343 * elf32-hppa.h (elf32_hppa_size_stubs): Update prototype.
6345 * elf64-hppa.c (elf64_hppa_dyn_hash_entry): Fix a comment typo.
6347 * hppa_stubs.h: Delete.
6348 * Makefile.am (SOURCE_HFILES): Remove hppa_stubs.h
6349 (elf32-hppa.lo): Remove hppa_stubs.h from dependencies.
6350 * Makefile.in: Regenerate.
6352 * elf-hppa.h (_bfd_elf_hppa_gen_reloc_type): Handle e_nlsel and
6355 * libhppa.h (hppa_field_adjust): Correct e_nsel case.
6357 * elf32-hppa.c (elf32_hppa_relocate_section): Mention the offset
6358 and section name for bfd_reloc_notsupported error message.
6359 (elf32_hppa_bfd_final_link_relocate): Print reasons for returning
6360 bfd_reloc_notsupported.
6361 (elf32_hppa_relocate_section): Add ATTRIBUTE_UNUSED to output_bfd.
6363 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Handle
6364 undefined weak symbols for all relocs.
6365 (elf32_hppa_size_of_stub): Adjust calculation by 8 since branch
6366 offsets are relative to one past the delay slot.
6367 (elf32_hppa_size_stubs): Account for reloc addend when calculating
6368 branch destination. Put addend into stub name too.
6369 (elf32_hppa_bfd_final_link_relocate): Account for reloc addend and
6370 adjust by 8 when deciding whether a linker stub is needed. Put
6371 addend into stub name as for above.
6373 * elf32-hppa.c (hppa_elf_relocate_insn): Change signed/unsigned on
6374 various args and vars.
6375 (elf32_hppa_bfd_final_link_relocate): Here too.
6376 (elf32_hppa_size_stubs): Rename index -> indx. Use e_indx for
6377 inner block var to avoid shadowing.
6379 * elf32-hppa.h (_bfd_elf32_hppa_gen_reloc_type): Make `field' arg
6381 * elf64-hppa.h (_bfd_elf64_hppa_gen_reloc_type): Ditto.
6382 * elf-hppa.h (_bfd_elf_hppa_gen_reloc_type): Ditto.
6383 (elf_hppa_fake_sections): Rename local var to avoid shadowing.
6385 * libhppa.h: Change practically all unsigned ints to plain ints.
6386 Remove tests on gcc version. Instead use ATTRIBUTE_UNUSED for
6389 From Ryan Bradetich <rbradetich@uswest.net>
6390 * libhppa.h (hppa_opcode_type): New enum to replace #define's.
6391 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Modify to
6393 From David Huggins-Daines <dhd@linuxcare.com>
6394 * elf-hppa.h (elf_hppa_relocate_insn): Update the opcode constants
6395 to the new OP_* ones.
6397 * elf32-hppa.c (elf32_hppa_size_stubs): Consolidate freeing on
6398 error exit. Bail out earlier on plabel relocs that we aren't
6399 interested in. Don't tell elf32_hppa_stub_hash_lookup to copy
6400 string, and then don't free our copy.
6401 (elf32_hppa_build_one_stub): Make insn unsigned int.
6403 * libhppa.h (bfd_hppa_insn2fmt): 22 bit branches are only
6404 available with BL, not BE and BLE.
6406 * elf32-hppa.c (hppa_elf_relocate_insn): Add some more example
6407 code for elf arg relocs.
6408 (elf32_hppa_bfd_final_link_relocate): Replace boolean is_local
6409 argument with elf_link_hash_entry h. Handle undefined weak
6410 symbols. Move $global$ lookup from here...
6411 (elf32_hppa_relocate_section): ...to here. Return correct error
6412 message for non-handled relocs.
6413 (elf32_hppa_size_of_stub): Correctly test branch range. Previous
6414 wrong test was -0x3ffff to +0x40000.
6416 * elf-hppa.h (elf_hppa_final_link_relocate): R_PARISC_DIR17R,
6417 R_PARISC_DIR17F, and R_PARISC_DIR21L are for absolute branches;
6418 Handle them as such.
6419 (elf_hppa_relocate_insn): Fix a typo.
6421 * libhppa.h (GET_FIELD, GET_BIT, MASK, CATENATE, ELEVEN): Delete.
6422 (assemble_3, assemble_6, assemble_12, assemble_16, assemble_16a,
6423 assemble_17, assemble_21): Delete.
6424 Supply defines for all 64 possible opcodes.
6425 (bfd_hppa_insn2fmt): Add bfd argument, and use to select wide mode
6426 formats. Handle COMICLR.
6427 (hppa_rebuild_insn): Delete bfd argument. Handle formats 10, -11,
6430 * elf32-hppa.c (hppa_elf_relocate_insn): Complete rewrite.
6431 (elf32_hppa_bfd_final_link_relocate): Major rewrite.
6432 (elf32_hppa_build_one_stub): Modify hppa_elf_relocate_insn calls
6434 (elf32_hppa_size_stubs): Don't free stub_name twice. Read in all
6435 the local syms - did this code get deleted accidentally? Ignore
6436 undefined and undefweak syms.
6438 * elf-hppa.h (elf_hppa_final_link): Move hppa_info to outermost
6439 block. Use it instead of elf64_hppa_hash_table (info).
6440 (elf_hppa_final_link_relocate): Use hppa_info instead of
6441 elf64_hppa_hash_table (info).
6443 * libhppa.h (re_assemble_3, re_assemble_12, re_assemble_16,
6444 re_assemble_17, re_assemble_21, re_assemble_22): Don't mask insn.
6445 (hppa_rebuild_insn): Mask immediate bits here instead.
6446 * elf-hppa.h (elf_hppa_relocate_insn): Mask here too.
6448 2000-07-08 Alan Modra <alan@linuxcare.com.au>
6450 * section.c (struct sec): Add id field. Tidy comment formatting.
6451 (bfd_make_section_anyway): Set id.
6452 (STD_SECTION): Init id too.
6453 Change CONST to const throughout.
6454 * archures.c (bfd_arch_info): Tidy comment.
6455 (bfd_arch_list): Change a CONST to const.
6456 * libbfd-in.h: Tidy comments and replace CONST with const.
6457 * elf-bfd.h: Likewise.
6458 * libbfd.h: Regenerate.
6459 * bfd-in2.h: Regenerate.
6460 * libcoff.h: Regenerate.
6462 2000-07-07 DJ Delorie <dj@redhat.com>
6464 * archive.c (_bfd_write_archive_contents): Add an informative
6467 2000-07-06 Kazu Hirata <kazu@hxi.com>
6469 * srec.c: Fix formatting.
6471 2000-06-05 DJ Delorie <dj@redhat.com>
6475 2000-07-04 Alexandre Oliva <aoliva@redhat.com>
6477 * coff-arm.c (coff_arm_relocate_section): Do not ignore the symbol
6478 value of PC-relative offsets.
6480 2000-07-03 Jim Wilson <wilson@cygnus.com>
6482 * elf64-alpha.c (alpha_elf_size_info): New.
6483 (elf_backend_size_info): Define to alpha_elf_size_info.
6484 * elfcode.h (elf_size_info): Change hash bucket size to 4.
6486 2000-07-03 Ulf Carlsson <ulfc@engr.sgi.com>
6488 * elf32-mips.c: Include elf32-target.h again for the traditional
6491 2000-07-03 Marek Michalkiewicz <marekm@linux.org.pl>
6493 * elf32-avr.c (bfd_elf32_bfd_reloc_type_lookup):
6494 Add ATTRIBUTE_UNUSED to unused arguments to avoid warnings.
6495 (avr_info_to_howto_rela): Likewise.
6496 (elf32_avr_gc_mark_hook): Likewise.
6497 (elf32_avr_gc_sweep_hook): Likewise.
6498 (elf32_avr_relocate_section): Likewise.
6500 2000-07-03 Mark Elbrecht <snowball3@bigfoot.com>
6502 * cofflink.c (_bfd_coff_write_global_sym): Turn a weak symbol into
6503 an external symbol for a non-shared, non-relocatable link.
6505 2000-07-03 Nick Clifton <nickc@redhat.com>
6507 * cofflink.c (IS_EXTERNAL): New macro: Return true if the symbol
6508 is an external symbol.
6509 (IS_WEAK_EXTERNAL): New macro: Return true if the symbol is a weak
6512 2000-07-03 Kazu Hirata <kazu@hxi.com>
6514 * reloc16.c: Fix formatting.
6516 2000-07-01 Koundinya K <kk@ddeorg.soft.net>
6518 * config.bfd: Change targ_defvec and targ_selvecs for mips*-*-sysv4*
6519 to add a new target for traditional mips i.e
6520 bfd_elf32_tradbigmips_vec and bfd_elf32_tradlittlemips_vec.
6521 * configure.in: Likewise.
6522 * configure: Rebuild.
6523 * targets.c (bfd_elf32_tradbigmips_vec): Declare and put in
6525 (bfd_elf32_tradlittlemips_vec): Likewise.
6526 * elfxx-target.h: Add macro INCLUDED_TARGET_FILE which is more a test
6527 to see that elfNN_bed does not get redefined even if the target file
6528 is included twice for a chip. See elf32-mips.c.
6530 2000-07-01 Alan Modra <alan@linuxcare.com.au>
6532 * Makefile.am (DEP): Fix 2000-06-22. grep after running dep.sed
6533 (CLEANFILES): Add DEPA.
6534 * Makefile.in: Regenerate.
6536 2000-06-30 DJ Delorie <dj@cygnus.com>
6538 * peicode.h (coff_swap_filehdr_in): can't use e_magic because we
6539 can't assume the PE header is at 0x80.
6541 2000-06-29 Mark Elbrecht <snowball3@bigfoot.com>
6543 * syms.c (_bfd_stab_section_find_nearest_line): Use IS_ABSOLUTE_PATH.
6545 2000-06-28 Mark Elbrecht <snowball3@bigfoot.com>
6547 * go32stub.h: Update stub.
6549 2000-06-26 Marek Michalkiewicz <marekm@linux.org.pl>
6551 * archures.c (bfd_mach_avr5): Define.
6552 * bfd-in2.h (bfd_mach_avr5): Define.
6553 * cpu-avr.c (arch_info_struct): Rename bfd_mach_avr4 to
6554 bfd_mach_avr5, add bfd_mach_avr4. Update comments.
6555 (compatible): Update comment. Add missing test.
6556 * elf32-avr.c (avr_final_link_relocate): Support 8K wrap
6557 for avr2 and avr4. Simplify 8K wrap code.
6558 (bfd_elf_avr_final_write_processing): Recognize bfd_mach_avr5.
6559 (elf32_avr_object_p): Recognize E_AVR_MACH_AVR5.
6561 2000-06-26 Kazu Hirata <kazu@hxi.com>
6563 * coff-h8300.c: Fix formatting.
6564 * cpu-h8300.c: Likewise.
6566 2000-06-24 Alexandre Oliva <aoliva@redhat.com>
6568 * elf32-arm.h (elf32_arm_final_link_relocate): Print `(local)'
6569 for local symbols whose names are unknown.
6571 2000-06-22 Alan Modra <alan@linuxcare.com.au>
6573 * Makefile.am (DEP): grep for leading `/' in DEP1, and fail if we
6575 * Makefile.in: Regenerate.
6576 * doc/Makefile.in: Regenerate.
6578 2000-06-20 H.J. Lu <hjl@gnu.org>
6580 * Makefile.am: Rebuild dependency.
6581 * Makefile.in: Rebuild.
6583 2000-06-20 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
6585 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): New function.
6586 (elf_backend_copy_indirect_symbol): Map to the new function.
6588 2000-06-20 Alan Modra <alan@linuxcare.com.au>
6590 * archive.c (normalize): Correct pointer comparison when checking
6592 (bfd_bsd_truncate_arname): Likewise.
6593 (bfd_gnu_truncate_arname): Likewise.
6595 2000-06-20 Ulf Carlsson <ulfc@engr.sgi.com>
6597 * elf-bfd.h (struct elf_obj_tdata): Define per BFD Irix 5 virtual
6598 sections elf_{text,data}_{section,symbol}.
6599 * elf32-mips.c: mips_elf_{text,data}_{section,symbol}{,_ptr}: Remove.
6600 (_bfd_mips_elf_hide_symbol): New function.
6601 (elf_backend_hide_symbol): Map to the new function.
6602 (_bfd_mips_elf_add_symbol_hook): Change to use new per BFD
6603 definitions of mips_elf_{text,data}_{section,symbol}.
6604 (mips_elf_local_relocation_p): Try to find the direct symbol
6605 based on new check_forced argument.
6606 (mips_elf_calculate_relocation): Use new version of
6607 mips_elf_local_relocation_p.
6608 (mips_elf_relocate_section): Likewise.
6609 (_bfd_mips_elf_relocate_section): Likewise.
6610 (mips_elf_sort_hash_table): Only assert that have enough GOT
6612 (mips_elf_got16_entry): Match all 32 bits to the existing GOT
6613 entry if the relocation based on the new external argument.
6614 (mips_elf_create_dynamic_relocation): Assert that we have a
6615 section contents allocated where we can swap out the dynamic
6617 (mips_elf_calculate_relocation): Find the real hash-table entry
6618 correctly by using h->root.root.type. Only create a dynamic
6619 relocation entry if the symbol is defined in a shared library.
6620 Create an external GOT entry for the GOT16 relocation if the
6621 symbol was forced local.
6622 (_bfd_mips_elf_finish_dynamic_symbol): Don't assert there is a
6623 dynamic index if the symbol was forced local.
6625 2000-06-20 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
6627 * elf32-mips.c: Fix typos in comments.
6629 2000-06-19 Mark Kettenis <kettenis@gnu.org>
6631 * rs6000-core.c: Wrap definition of `union VmInfo' within #ifdef
6634 2000-06-18 Stephane Carrez <stcarrez@worldnet.fr>
6636 * Makefile.in, bfd-in2.h, libbfd.h, configure: Rebuild.
6637 * Makefile.am (ALL_MACHINES, ALL_MACHINES_CFILES, BFD32_BACKENDS,
6638 BFD32_BACKENDS_CFILES): Add 68hc12, 68hc11 files.
6639 * configure.in (bfd_elf32_m68hc12_vec): Recognize.
6640 (bfd_elf32_m68hc11_vec): Likewise.
6641 * config.bfd (targ_cpu): Recognize 68hc12 and 68hc11.
6642 Supports 68hc11 & 68hc12 at the same time.
6643 * targets.c (bfd_elf32_m68hc12_vec): Declare and put in
6645 (bfd_elf32_m68hc11_vec): Likewise.
6646 * elf.c (prep_headers): Recognize bfd_arch_m68hc12 and 68hc11.
6647 * archures.c (bfd_m68hc12_arch): Define and register in global list
6648 (bfd_m68hc11_arch): Likewise.
6649 * reloc.c (BFD_RELOC_M68HC11_HI8, BFD_RELOC_M68HC11_LO8,
6650 BFD_RELOC_M68HC11_3B): Define.
6651 * cpu-m68hc12.c, elf32-m68hc12.c: New files for 68hc12 support.
6652 * cpu-m68hc11.c, elf32-m68hc11.c: New files for 68hc11 support.
6654 2000-06-18 Ulf Carlsson <ulfc@engr.sgi.com>
6656 * elf_bfd.h (struct elf_backend_data): Add info argument to
6657 elf_backend_hide_symbol.
6658 (_bfd_elf_link_hash_hide_symbol): Likewise.
6659 * elf.c (_bfd_elf_link_hash_hide_symbol): Likewise.
6660 * elf64-ia64.c (elf64_ia64_hash_hide_symbol): Likewise.
6661 * elflink.h (elf_link_add_object_symbols): Likewise.
6662 (elf_link_assign_sym_version): Likewise.
6664 2000-06-18 H.J. Lu <hjl@gnu.org>
6666 * coff-i386.c (coff_i386_reloc): Don't return in case of
6667 output_bfd == (bfd *) NULL if COFF_WITH_PE is defined.
6668 Compensate PE relocations when linking with non-PE object
6669 files to generate a non-PE executable.
6671 2000-06-17 Ulf Carlsson <ulfc@engr.sgi.com>
6673 * elf32-mips.c (mips_elf_calculate_relocation): Explicitly write
6674 GOT entries if we're doing a static link or -Bsymbolic link.
6676 2000-06-15 Ulf Carlsson <ulfc@engr.sgi.com>
6678 * elflink.h (elf_link_adjust_relocs): Check for and call backend
6679 specifific swap_reloc_{in,out} and swap_reloca_{in,out} if
6681 (elf_link_output_relocs): Likewise.
6682 (elf_reloc_link_order): Likewise.
6684 2000-06-16 Nicholas Duffek <nsd@redhat.com>
6686 * archures.c (enum bfd_architecture): #define constants for
6687 PowerPc and RS6000 machine numbers.
6688 * bfd-in2.h: Regenerate.
6689 * coffcode.h (coff_set_arch_mach_hook): #ifdef XCOFF64, set arch
6690 to bfd_arch_powerpc instead of bfd_arch_rs6000. Refer to PowerPc
6691 and RS6000 machine numbers using #defined constants from
6693 * cpu-powerpc.c (arch_info_struct): Refer to PowerPc and RS6000
6694 machine numbers using #defined constants from archures.c. Add
6695 entries for EC603e, 630, A35, RS64II, RS64III, 7400. Specify
6696 64-bit words in 620 entry.
6697 * cpu-rs6000.c (arch_info_struct): Create with entries for RS1,
6699 (bfd_rs6000_arch): Change default machine to 0 (bfd_mach_rs6k).
6701 2000-06-16 Nicholas Duffek <nsd@cygnus.com>
6703 * coffcode.h (coff_mkobject_hook): Set xcoff_tdata.xcoff64.
6704 * libcoff-in.h (struct xcoff_tdata): Define xcoff64 field.
6705 * libcoff.h (struct xcoff_tdata): Define xcoff64 field.
6707 2000-06-16 Nicholas Duffek <nsd@redhat.com>
6709 * bfd-in.h (bfd_family_coff): Define.
6710 * bfd-in2.h: Regenerate.
6711 * coffgen.c (coff_count_linenumbers, coff_symbol_from,
6712 coff_find_nearest_line): Check COFFness using bfd_family_coff()
6713 instead of bfd_target_coff_flavour.
6714 * cofflink.c (_bfd_coff_final_link): Likewise.
6715 * cpu-ns32k.c (do_ns32k_reloc): Don't strcmp() target name to
6716 exclude XCOFF files.
6717 * reloc.c (bfd_perform_relocation, bfd_install_relocation):
6719 * targets.c (enum bfd_flavour): Add bfd_target_xcoff_flavour.
6720 * xcoff-target.h (TARGET_SYM): Use bfd_target_xcoff_flavour.
6721 * xcofflink.c (XCOFF_XVECP): Delete.
6722 (bfd_xcoff_link_record_set, bfd_xcoff_import_symbol,
6723 bfd_xcoff_export_symbol, bfd_xcoff_link_count_reloc,
6724 bfd_xcoff_record_link_assignment,
6725 bfd_xcoff_size_dynamic_sections): Replace XCOFF_XVECP() with
6726 check for bfd_target_xcoff_flavour.
6728 2000-06-16 Nicholas Duffek <nsd@redhat.com>
6730 * rs6000-core.c: Support 64-bit core files, support pre-4.3 core
6732 (read_hdr): New function.
6733 (rs6000coff_core_p): Store mstsave or __context64 struct instead
6734 of trying to extract individual registers. Set abfd->arch_info
6735 to match the architecture that created the core file.
6736 (rs6000coff_get_section_contents): Delete.
6737 * xcoff-target.h (rs6000coff_get_section_contents): Delete.
6739 2000-06-14 H.J. Lu <hjl@gnu.org>
6741 * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_rec)
6744 2000-06-13 H.J. Lu <hjl@gnu.org>
6746 * configure: Regenerate.
6748 2000-06-13 J"orn Rennecke <amylaar@cygnus.co.uk>
6750 * peicode.h (pe_ILF_object_p): Use TARGET_LITTLE_SYM instead of
6753 2000-06-08 David O'Brien <obrien@FreeBSD.org>
6755 * configure.in (VERSION): Update to show this is the CVS mainline.
6757 2000-06-07 Alan Modra <alan@linuxcare.com.au>
6759 * elf32-d10v.c: Include elf/d10v.h
6760 (enum reloc_type): Delete.
6761 * elf32-d30v.c: Include elf/d30v.h
6762 (enum reloc_type): Delete.
6764 * Makefile.am: Run "make dep-am" to regenerate dependencies.
6765 * Makefile.in: Regenerate.
6767 * elf32-i386.c (elf_howto_table): Remove EMPTY_HOWTOs.
6768 (elf32_i386_vtinherit_howto, elf32_i386_vtentry_howto): Delete and
6769 move HOWTOs into elf_howto_table.
6770 (R_386_standard, R_386_ext_offset): Define.
6771 (R_386_ext, R_386_vt_offset, R_386_vt): Define.
6772 (elf_i386_reloc_type_lookup): Modify calculation of index into
6773 elf_howto_table since we've removed the padding.
6774 (elf_i386_info_to_howto_rel): Likewise.
6775 (elf_i386_relocate_section): Likewise.
6777 2000-06-06 Michael Snyder <msnyder@seadog.cygnus.com>
6779 * elf.c (elf_grok_pr_status): Eliminate reference to prgregset_t.
6781 2000-06-05 H.J. Lu <hjl@gnu.org>
6783 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Don't flag
6784 an error when seeing an undefined symbol with hidden/internal
6785 attribute. It is handled in *_relocate_section ().
6787 2000-06-05 H.J. Lu <hjl@gnu.org>
6789 * elflink.h (elf_fix_symbol_flags): Follow the link for the
6790 indirect symbol for the ELF_LINK_NON_ELF bit.
6791 (elf_link_output_extsym): Don't output the indirect symbol even
6792 if the ELF_LINK_NON_ELF bit is set.
6794 2000-06-01 J.T. Conklin <jtc@redback.com>
6796 * config.bfd (i[3456]86-*-netbsdelf*): New target.
6797 (i[3456]86-*-netbsdaout*): New target.
6798 (i[3456]86-*-netbsd*): Add bfd_elf32_i386_vec to targ_selvecs.
6799 (i[3456]86-*-openbsd*): Likewise.
6801 2000-05-30 Andrew Cagney <cagney@b1.cygnus.com>
6803 * trad-core.c: From hpux-core.c, include <dirent.h> or
6804 <sys/ndir.h> when possible.
6806 2000-05-31 Ulrich Drepper <drepper@redhat.com>
6808 * elf.c (_bfd_elf_slurp_version_tables): Correct reading of version
6809 definitions. We must not assume they are sorted in the file
6810 according to their index numbers.
6812 2000-05-31 Alan Modra <alan@linuxcare.com.au>
6814 * elf-hppa.h: (elf_hppa_final_link_relocate): Use e_rsel field
6815 selector for R_PARISC_PCREL17R. R_PARISC_DIR17R and
6816 R_PARISC_DIR17F are for absolute branches; Handle them as such.
6818 2000-05-30 Nick Clifton <nickc@cygnus.com>
6820 * cpu-i960.c (scan_960_mach): Accept 80960KA, 80960KB,
6821 80960CA, 80960MC as valid machine names.
6823 2000-05-30 H.J. Lu <hjl@gnu.org>
6825 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Clear the
6826 visibility bits if the symbol is undefined. Correctly handle
6827 weak undefined symbols with hidden and internal attributes.
6829 * elflink.h (elf_link_add_object_symbols): Always turn the
6830 symbol into local if it has the hidden or internal attribute.
6832 2000-05-29 Philip Blundell <philb@gnu.org>
6834 * ppcboot.c: Add packed attribute if compiling with GCC.
6836 2000-05-29 Anatoly Vorobey <mellon@pobox.com>
6838 * elf.c (_bfd_elf_link_hash_table_init): Initialize dynlocal.
6840 2000-05-26 Michael Snyder <msnyder@seadog.cygnus.com>
6842 * elf.c (elfcore_grok_prstatus, elfcore_grok_pstatus,
6843 elfcore_grok_psinfo): Add code to allow debugging a 32-bit
6844 corefile on a 64-bit (Sparc Solaris) host. Also clean up
6847 2000-05-26 Alan Modra <alan@linuxcare.com.au>
6849 * Makefile.am: Update dependencies with "make dep-am"
6850 * Makefile.in: Regenerate.
6852 * sysdep.h (gettext, dgettext, dcgettext, textdomain,
6853 bindtextdomain): Replace defines with those from intl/libgettext.h
6854 to quieten gcc warnings.
6856 2000-05-26 Eli Zaretskii <eliz@is.elta.co.il>
6858 * aoutx.h (find_nearest_line): Use IS_ABSOLUTE_PATH.
6860 * archive.c (normalize, bfd_bsd_truncate_arname,
6861 bfd_gnu_truncate_arname) [HAVE_DOS_BASED_FILE_SYSTEM]: Support
6862 file names with backslashes.
6864 * cache.c (bfd_open_file) [__MSDOS__]: Don't unlink the file
6867 * sysdep.h: Include filenames.h.
6869 2000-05-26 Alan Modra <alan@linuxcare.com.au>
6871 * opncls.c (bfd_close_all_done): Mask file perms with 0777 not 0x777.
6873 2000-05-26 Jakub Jelinek <jakub@redhat.com>
6875 * elf64-sparc.c (sparc64_elf_relax_section): New.
6876 (sparc64_elf_relocate_section): Optimize tail call into branch always
6878 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
6879 (elf32_sparc_relax_section): New.
6881 2000-05-26 Jakub Jelinek <jakub@redhat.com>
6883 * elf64-sparc.c: Add ATTRIBUTE_UNUSED to unused function parameters.
6884 Remove unusued variables.
6885 (sparc64_elf_relocate_section): Change r_symndx type to unsigned long.
6886 (sparc64_elf_merge_private_bfd_data): Fix shared library case from
6887 previous fix, so that shared libs really don't influence targets
6888 extension mask and memory model.
6890 2000-05-23 H.J. Lu <hjl@gnu.org>
6892 * elf64-alpha.c (elf64_alpha_relocate_section): Check
6893 h->root.other not h->other.
6894 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
6896 * elf32-ppc.c (ppc_elf_relocate_section): Fix a typo.
6898 2000-05-23 H.J. Lu <hjl@gnu.org>
6900 * elf32-i386.c (elf_i386_relocate_section): Don't allow the
6901 undefined symbol with the non-default visibility attributes.
6902 * elf-hppa.h (elf_hppa_relocate_section): Likewise.
6903 * elf32-arm.h (elf32_arm_relocate_section): Likewise.
6904 * elf32-i370.c (i370_elf_relocate_section): Likewise.
6905 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
6906 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
6907 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
6908 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
6909 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
6910 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
6911 * elf64-ia64.c (elf64_ia64_relocate_section): Likewise.
6912 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
6914 2000-05-22 Richard Henderson <rth@cygnus.com>
6916 * elf64-ia64.c (ia64_howto_table): Add PCREL60B, PCREL21BI,
6917 PCREL22, PCREL64I. Zero size of special relocs.
6918 (elf64_ia64_reloc_type_lookup): Likewise.
6919 (USE_BRL, oor_brl, oor_ip): New.
6920 (elf64_ia64_relax_section): New.
6921 (elf64_ia64_check_relocs): Handle PCREL60B, PCREL22, PCREL64I.
6922 (elf64_ia64_install_value): Likewise, plus PCREL21BI.
6923 (elf64_ia64_relocate_section): Likewise.
6924 (bfd_elf64_bfd_relax_section): New.
6925 * reloc.c (BFD_RELOC_IA64_PCREL21BI): New.
6926 (BFD_RELOC_IA64_{PCREL22,PCREL60B,PCREL64I}): New.
6927 * bfd-in2.h, libbfd.h: Regenerate.
6929 2000-05-22 Nick Clifton <nickc@cygnus.com>
6931 * configure.in : Add peigen.lo to MIPS PE targets.
6932 * configure: Regenerate.
6934 2000-05-22 Momchil Velikov <velco@fadata.bg>
6936 * libbfd.c (_bfd_generic_verify_endian_match): Compare endianess
6937 only if it is known for both input and output bfds. Separate
6938 error message strings as in some languages, it may be necessary
6939 to change more than one place in the string to change between
6942 * elf32-ppc.c (ppc_elf_merge_private_bfd_data): Remove inline
6943 endianess checks, call _bfd_generic_verify_endian_match() instead.
6945 * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Likewise.
6947 * elf32-mcore.c (mcore_elf_merge_private_bfd_data): Likewise.
6949 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Likewise. Verify
6950 endianess before checking bfd flavours.
6952 2000-05-22 H.J. Lu <hjl@gnu.org>
6954 * elflink.h (elf_link_output_extsym): Clear the visibility
6955 field for symbols not defined locally.
6957 2000-05-18 Alan Modra <alan@linuxcare.com.au>
6959 * libhppa.h (re_assemble_3, re_assemble_12, re_assemble_16,
6960 re_assemble_17, re_assemble_21, re_assemble_22): Don't mask insn.
6961 (hppa_rebuild_insn): Mask immediate bits here instead.
6962 * elf-hppa.h (elf_hppa_relocate_insn): Mask here too.
6964 2000-05-18 Momchil Velikov <velco@fadata.bg>
6966 * elflink.h (elf_bfd_final_link, elf_link_input_bfd): When emiting
6967 relocs for an executable, ensure that they are virtual addresses.
6969 2000-05-18 Jeffrey A Law (law@cygnus.com)
6971 * config.bfd (hppa*64*-*-hpux11*): New target triplet.
6973 2000-05-17 S. Bharadwaj Yadavalli <sby@scrugs.lkg.dec.com>
6974 Rick Gorton <gorton@scrugs.lkg.dec.com>
6976 * elflink.h: Add emitrelocations support: when enabled, relocation
6977 information and relocation sections are put into final output
6978 executables. If the emitrelocations flag is set, do the following:
6979 (elf_bfd_final_link): Emit relocation sections.
6980 (elf_link_input_bfd): Compute relocation section contents.
6981 (elf_gc_sections): Don't clean relocation sections.
6983 2000-05-16 Catherine Moore <clm@cygnus.com>
6985 * som.c (som_decode_symclass): Recognize weak symbols.
6987 2000-05-16 Szabolcs Szakacsits <szaka@F-Secure.com>
6989 * peigen.c (pe_print_idata): Undo part of 2000-05-12 change that
6990 read idata section only from dataoff.
6991 (pe_print_edata): Correctly check for valid eat_member.
6993 2000-05-16 J"orn Rennecke <amylaar@cygnus.co.uk>
6995 * elf32-sh.c (sh_elf_relax_delete_bytes): Handle R_SH_SWITCH8.
6997 2000-05-14 Philip Blundell <philb@gnu.org>
6999 * config.bfd (armeb-*-elf, arm*b-*-linux-gnu*): New targets.
7001 2000-05-12 Alan Modra <alan@linuxcare.com.au>
7003 * targets.c (bfd_target_vector): #ifdef BFD64 rs6000coff64_vec
7005 * peigen.c (pe_print_idata): Look for .idata section and print
7006 info even if data directory has zero entries. Read idata section
7007 starting from dataoff, and adjust all data offsets to suit. Cast
7008 all bfd_vma vars to unsigned long before passing to fprintf.
7009 * peigen.c (pe_print_edata): Similarly, look for .edata section
7010 and print info even if data directory has zero entries. Cast
7011 all bfd_vma vars to unsigned long before passing to fprintf.
7013 From Szabolcs Szakacsits <szaka@F-Secure.com>
7014 * peigen.c (pe_print_idata): Use bfd_section_size rather than data
7015 directory size which may be bogus.
7016 * peigen.c (pe_print_edata): Similarly.
7018 2000-05-09 Alan Modra <alan@linuxcare.com.au>
7020 * elf.c (bfd_section_from_shdr): Don't set use_rela_p if rela
7022 (copy_private_bfd_data): Allow for space possibly taken up by elf
7023 headers when calculating segment physical address from lma.
7025 2000-05-08 Alan Modra <alan@linuxcare.com.au>
7027 * versados.c (versados_scan): Init stringlen and pass_2_done.
7029 * trad-core.c (trad_unix_core_file_p): Return
7030 bfd_error_wrong_format rather than bfd_error_file_truncated.
7032 * peigen.c (_bfd_pei_swap_aouthdr_out): Pass ImageBase to
7033 add_data_entry. DataDirectory virtual address is relative.
7034 (pe_print_idata): Account for relative DataDirectory virtual
7035 addresses. Don't trash datasize inside POWERPC_LE_PE code.
7036 (pe_print_edata): Similarly.
7038 From Szabolcs Szakacsits <szaka@F-Secure.com>
7039 * peigen.c (dir_names): Add Delay Import Directory.
7040 (pe_print_idata): Always search for bfd section containing
7041 idata address rather than looking up section name. Print this
7042 section name rather than .idata.
7043 (pe_print_edata): Similarly. Also print some fields as %08lx.
7044 (_bfd_pe_print_private_bfd_data_common): Print Reserved1 field as
7047 2000-05-05 Clinton Popetz <cpopetz@cygnus.com>
7049 * xcoff.h: Rename to xcoff-target.h
7050 * Makefile.am: Change all instances of xcoff.h to xcoff-target.h
7051 * coff-rs6000.c: Ditto.
7052 * coff64-rs6000.c: Ditto.
7053 * coff-pmac.c: Ditto.
7054 * Makefile.in: Regenerate.
7056 2000-05-05 Clinton Popetz <cpopetz@cygnus.com>
7058 * coffcode.h (coff_set_arch_mach_hook, coff_set_flags):
7059 Change U802TOC64MAGIC to U803XTOCMAGIC.
7061 2000-05-04 Michael Snyder <msnyder@seadog.cygnus.com>
7063 * elf.c (bfd_elf_get_arch_size): New function, return 32 | 64 | -1.
7064 * bfd-in.h: Prototype bfd_elf_get_arch_size.
7065 * bfd-in2.h: Prototype bfd_elf_get_arch_size.
7067 2000-05-04 Alan Modra <alan@linuxcare.com.au>
7069 * libhppa.h (HPPA_R_CONSTANT): Cast argument to bfd_signed_vma.
7071 2000-05-03 Martin v. L
\81öwis <loewis@informatik.hu-berlin.de>
7073 * elflink.h (elf_link_add_object_symbols): Reset dynindx for
7074 hidden and internal symbols.
7075 (elf_fix_symbol_flags): Clear NEEDS_PLT for symbols with
7077 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Do not
7078 assign a PLT or GOT entry to symbols with hidden and
7079 internal visibility.
7081 2000-05-03 Mark Elbrecht <snowball3@bigfoot.com>
7083 * coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Add entry for
7085 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
7087 2000-05-02 H.J. Lu <hjl@gnu.org>
7089 * elf.c (prep_headers): Use ELFOSABI_NONE instead of
7092 2000-05-02 Alan Modra <alan@linuxcare.com.au>
7094 * targets.c (bfd_target_vector): Restore bfd_elf32_hppa_vec.
7095 * Makefile.am (BFD32_BACKENDS): Restore elf32-hppa.lo. Regenerate
7097 * Makefile.in: Regenerate.
7099 2000-05-01 Jim Wilson <wilson@cygnus.com>
7101 * Makefile.am (BFD32_BACKENDS): Add efi-app-ia32.lo.
7102 (BFD32_BACKENDS_CFILES): Add efi-app-ia32.c.
7103 (BFD64_BACKENDS): Delete coff-ia64.lo. Add efi-app-ia64.lo.
7104 (BFD64_BACKENDS_CFILES): Delete coff-ia64.c. Add efi-app-ia64.c.
7105 * Makefile.in: Rebuild.
7107 2000-05-02 Alan Modra <alan@linuxcare.com.au>
7109 * config.bfd: Re-enable elf32-hppa. It now compiles, even if it
7110 doesn't work very well.
7112 * elf-hppa.h (elf_hppa_internal_shdr): Define.
7113 (elf_hppa_fake_sections): hdr is elf_hppa_internal_shdr.
7114 Set hdr->s_type to 1 if ARCH_SIZE == 32.
7115 (_bfd_elf_hppa_gen_reloc_type): Add prototype.
7116 (elf_hppa_info_to_howto): Likewise.
7117 (elf_hppa_info_to_howto_rel): Likewise.
7118 (elf_hppa_reloc_type_lookup): Likewise.
7119 (elf_hppa_is_local_label_name): Likewise.
7120 (elf_hppa_fake_sections): Likewise.
7121 (elf_hppa_final_write_processing): Likewise.
7122 (elf_hppa_howto_table): Fully initialise all entries.
7123 (_bfd_elf_hppa_gen_reloc_type): Add ATTRIBUTE_UNUSED to args.
7124 (elf_hppa_info_to_howto): Likewise.
7125 (elf_hppa_info_to_howto_rel): Likewise.
7126 (elf_hppa_reloc_type_lookup): Likewise.
7127 (elf_hppa_final_write_processing, elf_hppa_add_symbol_hook,
7128 elf_hppa_unmark_useless_dynamic_symbols,
7129 elf_hppa_remark_useless_dynamic_symbols,
7130 elf_hppa_record_segment_addrs, elf_hppa_final_link,
7131 elf_hppa_relocate_section, elf_hppa_final_link_relocate,
7132 elf_hppa_relocate_insn): Compile only if ARCH_SIZE == 64 until
7133 elf32-hppa.c mess is cleaned up.
7134 (elf_hppa_final_link_relocate): Make insn and r_type unsigned
7135 int. Delete r_field. In case R_PARISC_PCREL21L, don't set
7136 r_field then call hppa_field_adjust inline func with variable
7137 r_field arg, instead call hppa_field_adjust with fixed arg.
7138 In case R_PARISC_PCREL22F, don't set r_field.
7139 (elf_hppa_relocate_insn): Change args and return type to unsigned
7140 int. Call re_assemble_* funcs to do the work.
7142 * elf32-hppa.c (hppa_elf_relocate_insn): Don't assume 32 bit when
7145 * libhppa.h (HPPA_R_CONSTANT): Don't assume 32 bit when sign
7147 (sign_extend): Mask first before sign extending.
7148 (low_sign_extend): Rewrite without condition expression.
7149 (ones, dis_assemble_3, dis_assemble_12, dis_assemble_16,
7150 dis_assemble_17, dis_assemble_21, dis_assemble_22): Delete.
7151 (assemble_3, assemble_6, assemble_12, assemble_16, assemble_16a,
7152 assemble_17, assemble_21, sign_unext, low_sign_unext): Return
7153 result as function return value rather than through pointer arg.
7154 Accept unsigned int args, and return unsigned int.
7155 (re_assemble_3): New. Combines function of dis_assemble_3 with
7156 re-assembly of opcode and immediate.
7157 (re_assemble_12): Likewise.
7158 (re_assemble_16): Likewise.
7159 (re_assemble_17): Likewise.
7160 (re_assemble_21): Likewise.
7161 (re_assemble_22): Likewise.
7162 (hppa_field_adjust): Rewrite and document, paying attention to
7163 size of types and signed/unsigned issues.
7164 (get_opcode): Shift before masking.
7165 (FDLW): Rename to FLDW.
7166 (bfd_hppa_insn2fmt): Change arg to unsigned int. Delete fmt.
7167 (hppa_rebuild_insn): Change args and return value to unsigned
7168 int. Make use of re_assemble_*. Correct case 11.
7170 * dep-in.sed: Handle ../opcodes/.
7171 * Makefile.am (SOURCE_HFILES): Add elf-hppa.h, elf32-hppa.h,
7172 elf64-hppa.h, hppa_stubs.h, xcoff.h.
7173 (BFD32_BACKENDS_CFILES): Restore elf32-hppa.c.
7174 Remove elf64-hppa.lo, cpu-ia64.lo, elf64-ia64.lo, elfarm-oabi.lo,
7175 elfarm-nabi.lo dependencies outside of auto-dependency area.
7176 Regenerate dependencies.
7177 * Makefile.in: Regenerate.
7179 * configure.in (TRAD_HEADER): Test non-null before
7181 * configure: Regenerate.
7183 * reloc.c: Fix mis-spelling in comment.
7185 2000-05-01 Alan Modra <alan@linuxcare.com.au>
7187 * coff-sh.c (bfd_coff_small_swap_table): Fix Fri Apr 28 change.
7188 * vms.c (vms_openr_next_archived_file): Return NULL.
7190 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7192 * coffcode.h Copy changes mistakenly done to libcoff.h in
7195 2000-04-29 Andreas Jaeger <aj@suse.de>
7197 * libbfd-in.h: Correctly check GCC version.
7198 * bfd-in.h: Likewise.
7199 * libhppa.h: Likewise.
7200 * libbfd.h: Regenerate.
7201 * bfd-in2.h: Regenerate.
7203 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7205 * Makefile.am (BFD64_BACKENDS, BFD64_BACKENDS_CFILES): Add
7206 coffdu-rs6000.{lo,c}.
7207 (coff-pmac.lo, coff-rs6000.lo, coff64-rs6000.lo): Add dependency
7209 * Makefile.in: Regenerate.
7210 * xcoff.h: New file.
7211 * coff-pmac.c: Use xcoff.h instead of coff-rs6000.c.
7212 * coff-rs6000.c: Move all declarations and defines that are
7213 common to the xcoff backends into xcoff.h
7214 * coff64-rs6000.c: Ditto,
7216 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7218 * coff-mips.c (mips_ecoff_backend_data): Add initialization of
7219 _bfd_coff_force_symnames in strings and
7220 _bfd_coff_debug_string_prefix_length to their default values.
7221 * coff-sh.c: (bfd_coff_small_swap_table): Ditto.
7223 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7225 * coff-alpha.c (alpha_ecoff_backend_data): Add initialization of
7226 _bfd_coff_force_symnames in strings and
7227 _bfd_coff_debug_string_prefix_length to their default values.
7229 2000-04-27 Alan Modra <alan@linuxcare.com.au>
7231 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Return if dynobj NULL.
7232 Check local_got_refcounts before dereferencing.
7234 * elf32-ppc.c (ppc_elf_relocate_section): Check splt != NULL
7235 before deciding we don't need R_PPC_PLT32 relocation.
7236 (ppc_elf_gc_sweep_hook): Check local_got_refcounts before
7239 * elflink.h (elf_gc_common_finalize_got_offsets): Fix comment.
7241 * elf32-i386.c (elf_i386_check_relocs): Reference count .got and
7243 (elf_i386_gc_sweep_hook): Garbage collect .got and .plt entries.
7244 (elf_i386_adjust_dynamic_symbol): Recognize unused .plt entries.
7245 (elf_i386_relocate_section): Allow for .plt to go missing.
7246 (elf_i386_finish_dynamic_symbol): Use same test to decide if we
7247 can use a relative reloc for got as elf_i386_relocate_section.
7248 (bfd_elf32_bfd_final_link): Define to use gc form of final link.
7250 2000-04-26 Clinton Popetz <cpopetz@cygnus.com>
7252 * config.bfd: Remove extraneous bfd_powerpc_64_arch.
7254 2000-04-24 Clinton Popetz <cpopetz@cygnus.com>
7256 * Makefile.am (coff64-rs6000.lo): New rule.
7257 * Makefile.in: Regenerate.
7258 * coff-rs6000.c (xcoff_mkobject, xcoff_copy_private_bfd_data,
7259 xcoff_is_local_label_name, xcoff_rtype2howto,
7260 xcoff_reloc_type_lookup, xcoff_slurp_armap, xcoff_archive_p,
7261 xcoff_read_ar_hdr, xcoff_openr_next_archived_file, xcoff_write_armap,
7262 xcoff_write_archive_contents): No longer static, and prefix with _bfd_.
7263 (NO_COFF_SYMBOLS): Define.
7264 (xcoff64_swap_sym_in, xcoff64_swap_sym_out, xcoff64_swap_aux_in,
7265 xcoff64_swap_aux_out): New functions; handle xcoff symbol tables
7267 (MINUS_ONE): New macro.
7268 (xcoff_howto_tabl, xcoff_reloc_type_lookup): Add 64 bit POS
7270 (coff_SWAP_sym_in, coff_SWAP_sym_out, coff_SWAP_aux_in,
7271 coff_SWAP_aux_out): Map to the new functions.
7272 * coff64-rs6000.c: New file.
7273 * libcoff.h (bfd_coff_backend_data): Add new fields
7274 _bfd_coff_force_symnames_in_strings and
7275 _bfd_coff_debug_string_prefix_length.
7276 (bfd_coff_force_symnames_in_strings,
7277 bfd_coff_debug_string_prefix_length): New macros for above fields.
7278 * coffcode.h (coff_set_arch_mach_hook): Handle XCOFF64 magic.
7279 Set machine to 620 for XCOFF64. Use bfd_coff_swap_sym_in instead
7280 of using coff_swap_sym_in directly.
7281 (FORCE_SYMNAMES_IN_STRINGS): New macro, defined for XCOFF64.
7282 (coff_set_flags) Set magic for XCOFF64.
7283 (coff_compute_section_file_positions): Add symbol name length to
7284 string section length if bfd_coff_debug_string_prefix_length is
7286 (coff_write_object_contents): Don't do reloc overflow for XCOFF64.
7287 (coff_slurp_line_table): Use bfd_coff_swap_lineno_in instead of
7288 using coff_swap_lineno_in directly.
7289 (bfd_coff_backend_data): Add _bfd_coff_force_symnames_in_strings
7290 and _bfd_coff_debug_string_prefix_length fields.
7291 * coffgen.c (coff_fix_symbol_name, coff_write_symbols): Force
7292 symbol names into strings table when
7293 bfd_coff_force_symnames_in_strings is true.
7294 * coffswap.h (MAX_SCNHDR_NRELOC, MAX_SCNHDR_NLNNO, GET_RELOC_VADDR,
7295 SET_RELOC_VADDR): New macros.
7296 (coff_swap_reloc_in, coff_swap_reloc_out): Use above macros.
7297 (coff_swap_aux_in, coff_swap_aux_out): Remove RS6000COFF_C
7299 (coff_swap_aouthdr_in, coff_swap_aouthdr_out): Handle XCOFF64
7300 changes within RS6000COFF_C specific code.
7301 (coff_swap_scnhdr_out): Use PUT_SCNHDR_NLNNO, PUT_SCNHDR_NRELOC,
7302 MAX_SCNHDR_NRELOC, and MAX_SCNHDR_NLNNO.
7303 * reloc.c (bfd_perform_relocation, bfd_install_relocation):
7304 Extend existing hack on target name.
7305 * xcofflink.c (XCOFF_XVECP): Extend existing hack on
7307 * coff-tic54x.c (ticof): Keep up to date with new fields
7308 in bfd_coff_backend_data.
7309 * config.bfd: Add bfd_powerpc_64_arch to targ_arch and define
7310 targ_selvecs to include rs6000coff64_vec for rs6000.
7311 * configure.in: Add rs6000coff64_vec case.
7312 * cpu-powerpc.c: New bfd_arch_info_type.
7314 2000-04-24 Jeffrey A Law (law@cygnus.com)
7316 * config.bfd: Only disable elf32-hppa vectors, not all of the
7317 BSD and OSF configuration support. Provide (disabled) clauses
7319 * configure.in: Add clause for PA64 support.
7320 * configure: Rebuilt.
7322 * targets.c (bfd_target_vector): Add bfd_elf64_hppa_vec.
7323 (bfd_elf64_hppa_vec): Declare.
7325 * Makefile.am (BFD64_BACKENDS): Add elf64-hppa.lo
7326 (BFD64_BACKENDS_CFILES): Add elf64-hppa.c
7327 (elf64-hppa.lo): Add dependencies.
7328 * Makefile.in: Rebuilt.
7330 * elf64-hppa.c, elf64-hppa.h: New files with PA64 support.
7332 2000-04-24 Jason Eckhardt <jle@cygnus.com>
7334 * libhppa.h (dis_assemble_16): New function.
7335 (pa_arch): Added pa20w element.
7337 2000-04-24 Ulrich Drepper <drepper@cygnus.com>
7339 * elf-bfd.h: Add prototypes for bfd_elf32_write_relocs,
7340 bfd_elf32_slurp_reloc_table, bfd_elf64_write_relocs, and
7341 bfd_elf64_slurp_reloc_table.
7343 * elfcode.h (elf_write_relocs, elf_slurp_reloc_table): New
7344 definitions to get external names.
7345 (elf_write_relocs): Renamed from write_relocs and make global.
7346 (elf_slurp_reloc_table): Make global.
7347 (_bfd_elf,size_info): Use elf_write_relocs instead of write_relocs.
7349 * archive.c (hpux_uid_gid_encode): New function.
7350 (bfd_ar_hdr_from_filesystem): Use it if HPUX_LARGE_AR_IDS is
7351 defined and the ID is greater than 99999.
7352 (bfd_generic_stat_arch_elt): If HPUX_LARGE_AR_IDS is defined decode
7353 special uid/gid fields into 32 bit values.
7355 2000-04-21 Matthew Green <mrg@cygnus.com>
7357 * config.bfd: Add NetBSD/sparc64 support.
7359 Fri Apr 21 13:20:53 2000 Richard Henderson <rth@cygnus.com>
7360 David Mosberger <davidm@hpl.hp.com>
7361 Timothy Wall <twall@cygnus.com>
7362 Jim Wilson <wilson@cygnus.com>
7364 * Makefile.am (ALL_MACHINES): Add cpu-ia64.lo.
7365 (ALL_MACHINES_CFILES): Add cpu-ia64.c.
7366 (BFD64_BACKENDS): Add elf64-ia64.lo.
7367 (BFD64_BACKENDS_CFILES): Add elf64-ia64.c.
7368 (cpu-ia64.lo, elf64-ia64.lo): New rules.
7369 * Makefile.in: Rebuild.
7370 * archures.c (enum bfd_architecture): Add bfd_arch_ia64.
7371 (bfd_ia64_arch): Declare.
7372 (bfd_archures_list): Add bfd_ia64_arch.
7373 * bfd-in2.h: Rebuild.
7374 * config.bfd: (ia64*-*-linux-gnu*, ia64*-*-elf*): New targets.
7375 * configure: Rebuild.
7376 * configure.host: (ia64-*-linux*): New host.
7377 * configure.in (bfd_elf64_ia64_little_vec, bfd_elf64_ia64_big_vec,
7378 bfd_efi_app_ia64_vec, bfd_efi_app_ia64_vec): New vectors.
7379 * elf.c (prep_headers): Add bfd_arch_ia64.
7380 * libbfd.h: Rebuild.
7381 * reloc.c: Add IA-64 relocations.
7382 * targets.c (bfd_elf64_ia64_little_vec, bfd_elf64_ia64_big_vec):
7384 (bfd_target_vect): Add bfd_elf64_ia64_little_vec.
7385 * cpu-ia64-opc.c, cpu-ia64.c, elf64-ia64.c: New files.
7387 2000-04-21 Richard Henderson <rth@cygnus.com>
7389 * elf32-d30v.c (bfd_elf_d30v_reloc): Don't modify section
7390 contents when performing a partial link.
7391 (bfd_elf_d30v_reloc_21): Likewise.
7393 2000-04-20 H.J. Lu <hjl@gnu.org>
7395 * elf32-i386.c (elf_i386_relocate_section): Restrict 1998-12-10
7396 patch to symbols defined by a shared object.
7397 * elf32-ppc.c (ppc_elf_relocate_section): Similarly.
7399 2000-04-19 Michael Sokolov <msokolov@ivan.Harhan.ORG>
7402 * dwarf2.c (concat_filename): Avoid string literal concatenation.
7403 * ieee.c (ieee_get_symtab): Don't initialise union in struct.
7405 Mon Apr 17 19:14:36 2000 David Mosberger <davidm@hpl.hp.com>
7407 * Makefile.am (BFD64_BACKENDS): Mention coff-ia64.lo.
7408 (BFD64_BACKENDS_CFILES): Mention coff-ia64.c
7409 (coff-ia64.lo): Add dependency.
7410 * Makefile.in: Regenerate.
7411 * coff-ia64.c: New file.
7412 * efi-app-ia32.c: Ditto.
7413 * efi-app-ia64.c: Ditto.
7414 * coffcode.h (coff_set_arch_mach_hook): Handle IA64MAGIC.
7415 (coff_set_flags): Ditto.
7416 (coff_write_object_contents) [IA64]: Set magic number to ZMAGIC.
7417 * config.bfd (i[3456]86-*-linux-gnu*): Mention bfd_efi_app_ia32_vec.
7418 * configure.in (elf): Handle bfd_efi_app_ia32 and bfd_efi_app_ia64_vec.
7419 * configure: Regenerate.
7420 * libpei.h (GET_OPTHDR_IMAGE_BASE): New macro.
7421 (PUT_OPTHDR_IMAGE_BASE): Ditto.
7422 (GET_OPTHDR_SIZE_OF_STACK_RESERVE): Ditto.
7423 (PUT_OPTHDR_SIZE_OF_STACK_RESERVE): Ditto.
7424 (GET_OPTHDR_SIZE_OF_STACK_COMMIT): Ditto.
7425 (PUT_OPTHDR_SIZE_OF_STACK_COMMIT): Ditto.
7426 (GET_OPTHDR_SIZE_OF_HEAP_RESERVE): Ditto.
7427 (PUT_OPTHDR_SIZE_OF_HEAP_RESERVE): Ditto.
7428 (GET_OPTHDR_SIZE_OF_HEAP_COMMIT): Ditto.
7429 (PUT_OPTHDR_SIZE_OF_HEAP_COMMIT): Ditto.
7430 (GET_PDATA_ENTRY): Ditto.
7431 * peigen.c (_bfd_pei_swap_aouthdr_in) [COFF_WITH_PEP64]: Don't read
7432 data_start. Use above macros to read fields that are 64 bit wide for
7433 COFF_WITH_PEP64. Don't truncate entry and text_start to 32 bits.
7434 (_bfd_pei_swap_aouthdr_out) [PEI_FORCE_MINIMUM_ALIGNMENT]: Force
7435 FileAlignment and SectionAlignment to minimum alignment if they
7437 (_bfd_pei_swap_aouthdr_out) [PEI_DEFAULT_TARGET_SUBSYSTEM]: Set
7438 Subsystem to default PEI_DEFAULT_TARGET_SUBSYSTEM.
7439 (_bfd_pei_swap_aouthdr_out) [COFF_WITH_PEP64]: Don't set data_start.
7440 Use above macros to write fields that are 64 bit wide for
7442 (pe_print_pdata): Set PDATA_ROW_SIZE to 3*8 for COFF_WITH_PEP64,
7443 5*4 otherwise. This should be right for IA-32 and IA-64, but may
7444 be wrong for platforms. Use PDATA_ROW_SIZE instead of hardcoded
7445 value of 20 bytes. Modify printing for COFF_WITH_PEP64 to print
7446 begin address, end address, and unwind info address only. Use
7447 GET_PDATA_ENTRY() to read .pdata entries. Use fprintf_vma() to
7449 (tbl): Add SECTION, REL32, RESERVED1, MIPS_JMPADDR16, DIR64, and
7450 HIGH3ADJ relocation names.
7451 (_bfd_pe_print_private_bfd_data): Print Subsystem name in legible form.
7452 * targets.c: Declare bfd_efi_app_ia32_vec and
7453 bfd_efi_app_ia64_vec.
7454 (bfd_target_vector): Mention bfd_efi_app_ia32_vec and
7455 bfd_efi_app_ia64_vec.
7457 2000-04-17 Timothy Wall <twall@cygnus.com>
7459 * bfd-in2.h: Add prototypes for tic54x load page access.
7460 * bfd-in.h: Regenerate.
7461 * coff-tic54x.c: Add load page functions; allow bfd_arch_unknown
7462 in customized _set_arch_mach function.
7463 * coffcode.h (coff_set_alignment_hook): Set section load page if
7464 the appropriate macro is defined.
7465 (write_object_contents): Read section load page.
7467 2000-04-13 Alan Modra <alan@linuxcare.com.au>
7469 * elf32-hppa.h: Update copyright date.
7471 * elf32-fr30.c (fr30_elf_i20_reloc): Don't use U suffix.
7472 * elf32-mips.c (_bfd_mips_elf_relocate_section): And here.
7474 * elf32-d30v.c (MAX32): Don't use LL suffix.
7475 (MIN32): Define in terms of MAX32.
7476 (bfd_elf_d30v_reloc): Make relocation a bfd_signed_vma.
7478 * coff-a29k.c (SIGN_EXTEND_HWORD): Replace with more concise
7481 * peicode.h (pe_ILF_build_a_bfd): Remove UL from hex constants.
7483 2000-04-12 Alan Modra <alan@linuxcare.com.au>
7485 * dep-in.sed: Match space before file name, not after.
7486 * Makefile.am: Regenerate dependencies.
7487 * Makefile.in: Regenerate.
7489 * reloc.c (_bfd_relocate_contents): In complain_overflow_bitfield
7490 case, allow address wrap-around stupidly removed 2000-03-17. Sign
7491 extend without an if statement.
7493 2000-04-11 Alan Modra <alan@linuxcare.com.au>
7495 * coff-mips.c (mips_gprel_reloc): Test for 16 bit range using
7497 * elf32-mips.c (gprel16_with_gp): Likewise.
7498 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Test range
7499 here using -0x40000, not (int)0xfffc0000.
7500 (elf32_hppa_size_of_stub): Likewise.
7502 2000-04-11 Timothy Wall <twall@cygnus.com>
7504 * coff-tic54x.c: Now builds with all targets.
7505 * Makefile.am: Add coff/tic54x.h to coff-tic54x.o dependencies.
7506 * Makefile.in: Regenerate.
7507 * coffcode.h (coff_set_arch_mach_hook): Eliminate warning on
7508 unitialized variable.
7510 Fri Apr 7 15:56:57 2000 Andrew Cagney <cagney@b1.cygnus.com>
7512 * configure.in (WARN_CFLAGS): Set to -W -Wall by default. Add
7513 --enable-build-warnings option.
7514 * Makefile.am (AM_CFLAGS, WARN_CFLAGS): Add definitions.
7515 * Makefile.in, configure: Re-generate.
7517 2000-04-07 Nick Clifton <nickc@cygnus.com>
7519 * reloc.c: Add BFD_RELOC_ARM_PCREL_BLX and
7520 BFD_RELOC_THUMB_PCREL_BLX.
7522 * elf32-arm.h (elf32_arm_final_link_relocate): Handle
7523 R_ARM_XPC25 and R_ARM_THM_PC22.
7525 * elfarm-nabi.c (elf32_arm_howto_): Fix definitions of
7526 R_ARM_XPC25 and R_ARM_THM_XPC22.
7527 (elf32_arm_reloc_map): Make BFD_RELOC_{ARM|THUMB}_PCREL_BLX to
7528 R_ARM_[XPC25|THM_XPC22].
7530 * elfarm-oabi.c: Define OLD_ARM_ABI and change include from
7531 elf/arm-oabi.h to elf/arm.h
7533 * Makefile.am: Fix dependency for elfarm-oabi.c
7534 * Makefile.in: Regenerate.
7536 * bfd-in2.h: Regenerate.
7537 * libbfd.h: Regenerate.
7539 2000-04-06 Michael Snyder <msnyder@seadog.cygnus.com>
7541 * elfcore.h (elf_core_file_p): preserve value of tdata at entry,
7542 and restore it on failure. Release newly allocated tdata on
7545 Fri Apr 7 11:33:47 2000 Jim Wilson <wilson@cygnus.com>
7547 * dwarf2.c (struct dwarf2_debug): New field dwarf_line_size.
7548 (decode_line_info): Set it. Report error if unit->line_offset is
7549 equal to or larger than it.
7551 2000-04-07 Timothy Wall <twall@cygnus.com>
7553 * targets.c: Added vecs for tic54x.
7554 * reloc.c: Added relocs for tic54x.
7555 * libbfd.h: Regenerated.
7556 * configure: Add TI COFF vecs for tic54x.
7557 * configure.in: Ditto.
7558 * config.bfd (targ_cpu): Recognize new tic54x target.
7559 * coffcode.h (coff_slurp_symbol_table): Additions for TI COFF handling.
7560 * bfd-in2.h: Add tic54x target and relocations.
7561 * Makefile.am, Makefile.in: Add tic54x target.
7562 * archures.c (bfd_archures_list): Add tic54x target.
7563 * coff-tic54x.c: New.
7564 * cpu-tic54x.c: New.
7566 2000-04-06 Michael Snyder <msnyder@seadog.cygnus.com>
7568 * elfcore.h (elf_core_file_p): call backend_object_p which
7569 thereby gets an opportunity to update the arch/machine type.
7571 2000-04-06 Timothy Wall <twall@cygnus.com>
7573 * coffcode.h (coff_slurp_symbol_table): Handle C_STATLAB storage
7574 class. Handle SEC_CLINK and SEC_BLOCK flags.
7575 * section.c: Add SEC_CLINK and SEC_BLOCK flags.
7576 * bfd-in2.h: Add SEC_CLINK and SEC_BLOCK flags.
7578 2000-04-06 Nick Clifton <nickc@cygnus.com>
7580 * elf32-arm.h (elf32_arm_set_private_flags): Only check for
7581 EF_INTERWORK if this is an unknown EABI.
7582 (elf32_arm_merge_private_bfd_data): Check EABI version
7583 numbers. Only check EF_xxx flags if the EABI version number
7585 (elf32_arm_check_private_bfd_data): Only check EF_xxx flags
7586 if the EABI version number is unknown.
7587 (elf32_arm_print_private_bfd_data): Only decode EF_xxx flags
7588 if the EABI version number is unknown.
7590 Wed Apr 5 22:04:20 2000 J"orn Rennecke <amylaar@cygnus.co.uk>
7592 * reloc.c (_bfd_relocate_contents): Add BFD_RELOC_SH_LOOP_START and
7593 BFD_RELOC_SH_LOOP_END.
7594 * elf32-sh.c (sh_elf_howto_tab): Change special_func to
7595 sh_elf_ignore_reloc for all entries that sh_elf_reloc used to ignore.
7596 Add entries for R_SH_LOOP_START and R_SH_LOOP_END.
7597 (sh_elf_reloc_loop): New function.
7598 (sh_elf_reloc): No need to test for always-to-be-ignored relocs
7600 (sh_rel): Add entries for BFD_RELOC_SH_LOOP_{START,END}.
7601 (sh_elf_relocate_section): Handle BFD_RELOC_SH_LOOP_{START,END}.
7602 * bfd-in2.h, libbfd.h: Regenerate.
7604 2000-04-04 Alan Modra <alan@linuxcare.com.au>
7606 * po/bfd.pot: Regenerate.
7608 * Makefile.am: Remove extraneous mkdep comment.
7609 (MKDEP): Use gcc -MM rather than mkdep.
7610 (DEP): Quote when passing vars to sub-make. Add warning
7612 (DEP1): Rewrite for "gcc -MM".
7613 (CLEANFILES): Add DEP2.
7614 Update dependencies.
7615 * Makefile.in: Regenerate.
7617 2000-04-03 Kevin Buettner <kevinb@redhat.com>
7619 * configure.in: Added corefile support for AIX 4.3. In particular,
7620 AIX_CORE_DUMPX_CORE will be defined in addition to AIX_CORE when
7621 compiling rs6000-core.c.
7622 * configure: Regenerated.
7624 2000-04-03 H.J. Lu <hjl@gnu.org>
7626 * cache.c (bfd_open_file): Unlink the output file only if
7627 it has non-zero size.
7629 2000-04-01 Ken Block USG <block@zk3.dec.com>
7631 * elf64-alpha.c (elf64_alpha_relocate_section): Don't emit
7632 relative relocations for non-loaded sections in shared objects.
7633 (elf64_alpha_check_relocs): Similarly.
7635 Mon Apr 3 13:37:15 2000 Hans-Peter Nilsson <hp@axis.com>
7637 * aoutx.h (NAME(aout,reloc_type_lookup)): Add BFD_RELOC_8 and
7638 BFD_RELOC_16 to switch for extended relocs.
7639 (MY_swap_ext_reloc_in): New.
7640 (MY_swap_ext_reloc_out): New.
7641 (NAME(aout,slurp_reloc_table)): Use MY_swap_ext_reloc_in rather
7642 than NAME(aout,swap_ext_reloc_in) for extended relocs.
7643 (NAME(aout,squirt_out_relocs)): Similarly use
7644 MY_swap_ext_reloc_out.
7645 (aout_link_reloc_link_order): Use MY_put_ext_reloc if defined.
7647 2000-04-03 Kazu Hirata <kazu@hxi.com>
7649 * coff-h8300.c (h8300_reloc16_extra_cases): Add bsr:16 -> bsr:8 to
7650 the R_PCRWORD_B case.
7652 2000-03-31 Thomas de Lellis <tdel@wrs.com>
7654 * srec.c : Set CHUNK size to 16 bytes to prevent download failures
7658 Wed Mar 30 15:28:00 2000 Donald Lindsay <dlindsay@cygnus.com>
7660 * elf32-m32r.c (m32r_elf_generic_reloc): new function. All
7661 HOWTO references to bfd_elf_generic_reloc, that have
7662 partial_inplace == true, now use the new function. The function
7663 is based on the recent rewrite of m32r_elf_lo16_reloc(), and
7664 extends its fixes to the R_M32R_{16,24,32} relocs.
7665 The new logic in m32r_elf_lo16_reloc() has been removed, and
7666 it instead calls the new routine to obtain that functionality.
7668 2000-03-27 Alan Modra <alan@linuxcare.com.au>
7670 * elf32-avr.c (elf32_avr_gc_mark_hook, elf32_avr_gc_sweep_hook,
7671 elf32_avr_check_relocs, avr_final_link_relocate,
7672 elf32_avr_relocate_section, bfd_elf_avr_final_write_processing,
7673 elf32_avr_object_p): Add prototypes.
7674 (elf32_avr_gc_mark_hook): Add default for h->root.type.
7675 (bfd_elf_avr_final_write_processing): Make static.
7677 2000-03-27 Denis Chertykov <denisc@overta.ru>
7679 * cpu-avr.c: New file. BFD support routines for AVR architecture.
7680 * archures.c (bfd_architecture): Add AVR architecture.
7681 (bfd_archures_list): Add reference to AVR architecture info.
7682 * elf.c (prep_headers): Handle bfd_arch_avr.
7683 * reloc.c: Add various AVR relocation enums.
7684 * targets.c (bfd_elf32_avr_vec): Declare and add to target vector
7686 * Makefile.am: Add support for AVR elf.
7687 * configure.in: Likewise.
7688 * config.bfd: Likewise.
7689 * Makefile.in: Regenerate.
7690 * configure: This too.
7691 * bfd-in2.h: And this.
7692 * libbfd.h: And this.
7694 2000-03-24 H.J. Lu <hjl@gnu.org>
7696 * elf64-alpha.c (elf64_alpha_merge_ind_symbols): Add prototype.
7697 (elf64_alpha_find_reloc_at_ofs): Likewise.
7699 2000-03-17 Alan Modra <alan@linuxcare.com.au>
7701 * reloc.c (bfd_check_overflow): In case complain_overflow_bitfield,
7702 flag an overflow if the bitfield is outside -2**n to 2**n-1. The
7703 allowable range used to be -2**(n-1) to 2**n-1.
7704 * reloc.c (_bfd_relocate_contents): Same here. Also replace
7705 "boolean overflow" with "bfd_reloc_status_type flag".
7707 2000-03-14 Doug Evans <dje@casey.transmeta.com>
7709 * elf32-m32r.c (m32r_elf_lo16_reloc): Rewrite.
7711 2000-03-14 Kazu Hirata <kazu@hxi.com>
7713 * reloc16.c (bfd_coff_reloc16_relax_section): Count the total number
7714 of shrinks properly, including the last reloc.
7716 2000-03-13 Kazu Hirata <kazu@hxi.com>
7718 * coff-h8300.c (h8300_reloc16_extra_cases): Fix the sanity
7721 2000-03-11 Alan Modra <alan@linuxcare.com.au>
7723 * ieee.c (ieee_archive_p): Return bfd_error_wrong_format on
7724 a format mismatch rather than an "error" from bfd_read such as
7725 bfd_error_file_truncated.
7727 2000-03-10 Geoff Keating <geoffk@cygnus.com>
7729 * elf32-mips.c (_bfd_mips_elf_relocate_section): Do proper
7730 sign-extension and big-endian compensation for
7731 R_MIPS_64 even in ld -r.
7733 2000-03-10 Geoffrey Keating <geoffk@cygnus.com>
7735 * elf32-mips.c (mips_elf_next_relocation): Rename from
7736 mips_elf_next_lo16_relocation, and generalize to look
7737 for any relocation type.
7738 (elf_mips_howto_table): Make R_MIPS_PC16 pcrel_offset.
7739 (elf_mips_gnu_rel_hi16): Howto for R_MIPS_GNU_REL_HI16.
7740 (elf_mips_gnu_rel_lo16): Howto for R_MIPS_GNU_REL_LO16.
7741 (elf_mips_gnu_rel16_s2): Howto for R_MIPS_GNU_REL16_S2.
7742 (elf_mips_gnu_pcrel64): Howto for R_MIPS_PC64.
7743 (elf_mips_gnu_pcrel32): Howto for R_MIPS_PC32.
7744 (bfd_elf32_bfd_reloc_type_lookup): Add new relocs.
7745 (mips_rtype_to_howto): Likewise.
7746 (mips_elf_calculate_relocation): Handle new relocs.
7747 (_bfd_mips_elf_relocate_section): REL_HI16/REL_LO16 relocs
7748 are paired. The addend for R_MIPS_GNU_REL16_S2
7749 is shifted right two bits.
7751 2000-03-10 Alan Modra <alan@linuxcare.com.au>
7753 * reloc.c (bfd_perform_relocation): Undo emacs formatting of
7754 comment, and ensure it doesn't happen again.
7755 (bfd_install_relocation): Same here.
7756 (_bfd_relocate_contents): Don't bother assigning unused signmask
7757 shift result. Fix typos in comments.
7758 Remove trailing whitespace throughout file.
7760 2000-03-07 Doug Evans <dje@casey.transmeta.com>
7762 * reloc.c (reloc_howto_struct): Fix partial_inplace comment.
7763 * bfd-in2.h: Rebuild.
7765 2000-03-06 Nick Clifton <nickc@cygnus.com>
7767 * peicode.h (struct pe_ILF_vars): Add sym_ptr_table and
7769 (SIZEOF_ILF_SYM_PTR_TABLE): Define.
7770 (SIZEOF_ILF_STRINGS): Redefine.
7771 (pe_ILF_make_a_symbol-reloc): New function. Creates a symbol
7772 relative reloc, as opposed to a section relative reloc.
7773 (pe_ILF_make_a_symbol): Set the class of local symbols to C_STAT
7775 Add length of symbol's prefix to string pointer.
7776 Store a pointer to the symbol in the symbol pointer table.
7777 (pe_ILF_build_a_bfd): Do not build .idata$2 or .idata$7.
7778 Initialise the symbol pointer table.
7779 Store the hint in the Hint/Name table.
7780 Make the jump reloc be symbol realtive, not section relative.
7781 Create an import symbol for imported code.
7783 2000-03-06 Catherine Moore <clm@cygnus.com>
7785 * elf.c (swap_out_syms): Check for null type_ptr.
7787 2000-03-01 Hans-Peter Nilsson <hp@axis.com>
7789 * aout-target.h (MY(write_object_contents)): Remove unused
7790 and unusable "#if CHOOSE_RELOC_SIZE".
7791 * pc532-mach.c (MY(write_object_contents)): Ditto.
7792 * netbsd.h (MY(write_object_contents)): Ditto.
7793 * hp300hpux.c (MY(write_object_contents)): Ditto.
7794 * freebsd.h (MY(write_object_contents)): Ditto.
7795 * aout-tic30.c (tic30_aout_write_object_contents): Ditto.
7797 2000-02-29 H.J. Lu <hjl@gnu.org>
7799 * peicode.h (jtab): Make it static.
7801 * coff-sh.c (sh_align_load_span): Declared if COFF_WITH_PE is
7802 defined and COFF_IMAGE_WITH_PE is not defined.
7803 (_bfd_sh_align_load_span): Defined as sh_align_load_span if
7804 COFF_WITH_PE is defined and COFF_IMAGE_WITH_PE is not defined.
7806 2000-03-01 Nick Clifton <nickc@cygnus.com>
7808 * coff-arm.c (bfd_arm_process_before_allocation): Make
7809 'symndx' signed to prevent compile time warning.
7811 * coff-mcore.c: Remove unused prototype for pe_object_p.
7813 * coff-sh.c: Add "#ifndef COFF_IMAGE_WITH_PE" around static
7814 functions that are not used when COFF_IMAGE_WITH_PE is
7816 (struct sh_opcode): Change type of 'flags' field to unsigned
7817 long so that it can hold the USESAS flag.
7819 * coffcode.h (styp_to_sec_flags): Initialise 'target_name'.
7821 * elf-m10300.c (mn10300_elf_relax_section): Initialise
7824 * elf32-i370.c: Add ATTRIBUTE_UNUSED to unused function
7826 Remove unusued variables and code.
7827 (elf_backend_add_symbol_hook): Fix prototype.
7829 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Initialise 'sgot' and
7832 * elf32-mcore.c (mcore_elf_relocate_section): Initialise
7835 * elf32-mips.c: Add ATTRIBUTE_UNUSED to unused function
7837 Remove unusued variables and code.
7838 (elf_backend_add_symbol_hook): Fix prototype.
7840 * elf32-sh.c (sh_elf_set_mach_from_flags): Use 'flags'.
7842 * elflink.h (elf_bfd_link_add_symbols): Add ATTRIBUTE_UNUSED
7843 to unused function parameter.
7845 * pe-mips.c: Add ATTRIBUTE_UNUSED to unused function
7847 Use EMPTY_HOWTO to initialise empty howto slots.
7848 Remove unused variables.
7850 * peicode.h (pe_ILF_build_a_bfd): Initialise id6.
7852 2000-03-01 H.J. Lu <hjl@gnu.org>
7854 * aoutx.h (aout_link_input_section_std): Pass "true" to
7855 the undefined_symbol callback.
7856 (aout_link_input_section_ext): Likewise.
7857 * bout.c (get_value): Likewise.
7858 * coff-a29k.c (coff_a29k_relocate_section): Likewise.
7859 * coff-alpha.c (alpha_ecoff_get_relocated_section_conten):
7861 (alpha_relocate_section): Likewise.
7862 * coff-arm.c (coff_arm_relocate_section): Likewise.
7863 * coff-i960.c (coff_i960_relocate_section): Likewise.
7864 * coff-mcore.c (coff_mcore_relocate_section): Likewise.
7865 * coff-mips.c (mips_relocate_section): Likewise.
7866 * coff-ppc.c (coff_ppc_relocate_section): Likewise.
7867 * coff-sh.c (sh_relocate_section): Likewise.
7868 * coff-tic80.c (coff_tic80_relocate_section): Likewise.
7869 * cofflink.c (_bfd_coff_generic_relocate_section): Likewise.
7870 * elf-m10200.c (mn10200_elf_relocate_section): Likewise.
7871 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
7872 * elf32-d10v.c (elf32_d10v_relocate_section): Likewise.
7873 * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
7874 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
7875 * elf32-i370.c (i370_elf_relocate_section): Likewise.
7876 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
7877 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
7878 * elf32-sh.c (sh_elf_relocate_section): Likewise.
7879 * elf32-v850.c (v850_elf_relocate_section): Likewise.
7880 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Likewise.
7881 * elflink.h (elf_link_output_extsym): Likewise.
7882 * pe-mips.c (coff_pe_mips_relocate_section): Likewise.
7883 * reloc.c (bfd_generic_get_relocated_section_conten): Likewise.
7884 * reloc16.c (_bfd_ppc_xcoff_relocate_section): Likewise.
7886 * elf-hppa.h (elf_hppa_relocate_section): Pass "false" to the
7887 undefined_symbol callback when building shared library with
7888 -Bsymbolic and undefined symbols are allowed. Otherwise, pass
7890 * elf32-arm.h (elf32_arm_relocate_section): Likewise.
7891 * elf32-i386.c (elf_i386_relocate_section): Likewise.
7892 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
7893 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
7894 (elf32_mips_get_relocated_section_content): Likewise.
7895 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
7896 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
7897 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
7898 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
7900 2000-02-28 Nick Clifton <nickc@cygnus.com>
7902 * Makefile.am: Add rules to build pe[i]-{sh|mips}.lo objects.
7903 * Makefile.in: Regenerate.
7905 * configure.in: Add support for mips and sh pe vectors.
7906 * configure: regenerate.
7908 * config.bfd: Add support for arm-wince, mips-pe and sh-pe
7911 * targets.c: Add mips and sh pe vectors.
7913 * libpei.h (coff_final_link_postscript): Only define if not
7916 * coffcode.h: Add support for WinCE magic numbers.
7918 * peigen.c (pe_print_reloc): Update comment and rearrange
7919 appending of newline character.
7921 * peicode.h: Add support for Image Library Format.
7922 (pe_ILF_vars): Structure containing data used by ILF code.
7923 (pe_ILF_make_a_section): New function. Create a section based
7925 (pe_ILF_make_a_reloc): New function. Create a reloc based on
7927 (pe_ILF_make_a_symbol): New function. Create a symbol based
7929 (pe_ILF_save_relocs): New function. Store the relocs created
7930 by pe_ILF_make_a_reloc in a section.
7931 (pe_ILF_build_a_bfd): New function. Create a BFD describing
7933 (pe_ILF_object_p): New function. Return a bfd_target pointer
7935 (pe_bfd_object_p): If an ILF object is detected call
7936 pe_ILF_object_p on it.
7938 * coff-arm.c: Add support for WinCE relocs which are different
7939 from normal ARM COFF relocs.
7940 * pe-arm.c: Unset TARGET_UNDERSCORE for a WinCE target.
7942 * coff-sh.c: Add support for sh-pe target.
7943 * pe-sh.c: New file. Support code for sh-pe target.
7944 * pei-sh.c: New file. Support code for sh-pe target.
7946 * pe-mips.c: New file. Support code for mips-pe target.
7947 * pei-mips.c: New file. Support code for mips-pe target.
7949 2000-02-27 Jakub Jelinek <jakub@redhat.com>
7951 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data): Don't bump
7952 architecture if the object causing the bump is dynamic.
7953 * elf64-sparc.c (sparc64_elf_merge_private_bfd_data): Likewise,
7954 and also don't it for memory ordering.
7955 (sparc64_elf_write_relocs): Take src_rela out of the loop.
7957 2000-02-27 Ian Lance Taylor <ian@zembu.com>
7959 * dwarf2.c (read_abbrevs): Use _raw_size directly rather than
7960 calling bfd_get_section_size_before_reloc.
7961 (decode_line_info): Likewise.
7962 (_bfd_dwarf2_find_nearest_line): Likewise.
7964 2000-02-27 Eli Zaretskii <eliz@is.elta.co.il>
7966 * Makefile.am (stamp-lib): Use $(LIBTOOL) --config to get the
7967 name of the libtool directory.
7968 * Makefile.in: Rebuild.
7970 Fri Feb 25 18:39:26 2000 Rodney Brown (RodneyBrown@pmsc.com)
7972 * som.c (SOM_HOWTO): Define.
7973 (som_hppa_howto_table): Use it.
7975 2000-02-25 Alexandre Oliva <oliva@lsd.ic.unicamp.br>
7977 * config.bfd: Enable 64 bit support for GNU/Linux/sparc.
7979 * config.bfd: Enable 64 bit support for Solaris7+/sparc.
7981 2000-02-24 Catherine Moore <clm@cygnus.com>
7983 * som.c (som_misc_symbol_info): Add field
7985 (som_bfd_derive_misc_symbol_info): Initialize
7987 (som_build_and_write_symbol_table): Keep track
7988 of secondary_def field.
7989 (som_slurp_symbol_table): Set BSF_WEAK symbol flag
7990 if secondary_def field is set.
7991 (som_bfd_ar_write_symbol_stuff): Initialize
7994 2000-02-23 Stephane Carrez <stcarrez@worldnet.fr>
7996 * dwarf2.c (read_address): Read 16-bits addresses.
7997 (parse_comp_unit): Accept addr_size == 2.
7999 2000-02-23 Alan Modra <alan@spri.levels.unisa.edu.au>
8001 * bfd-in.h: Update copyright date.
8003 2000-02-23 Linas Vepstas <linas@linas.org>
8005 * cpu-i370.c: New file.
8006 * elf32-i370.c: New file.
8007 * archures.c (enum bfd_architecture): Add bfd_arch_i370.
8008 (bfd_i370_arch): New.
8009 (bfd_archures_list): Add bfd_i370_arch.
8010 * elf.c (prep_headers): Add bfd_arch_i370.
8011 * Makefile.am: Add support for IBM 370 elf.
8012 * config.bfd: Likewise.
8013 * configure.in: Likewise.
8014 * libbfd.h (bfd_reloc_code_real_names): Likewise.
8015 * reloc.c (bfd_reloc_code_type): Likewise.
8016 * targets.c: Likewise.
8018 * Makefile.in: Regenerate.
8019 * configure: Regenerate.
8020 * bfd-in2.h: Regenerate.
8022 2000-02-22 Ian Lance Taylor <ian@zembu.com>
8024 * elf32-i386.c (elf_i386_info_to_howto_rel): Give a warning for
8025 invalid relocation types, and change them to R_386_NONE.
8027 2000-02-22 H.J. Lu <hjl@gnu.org>
8029 * elflink.h (elf_link_add_object_symbols): If a version symbol is
8030 not defined, don't add a second ELF_VER_CHR.
8032 * elflink.h (elf_bfd_final_link): Call output_extsym for global
8033 symbols converted to local symbols even when stripping all
8035 (elf_link_output_extsym): Process global symbols converted to
8036 local symbols even if they are being stripped.
8038 2000-02-21 Alan Modra <alan@spri.levels.unisa.edu.au>
8040 * archures.c (bfd_octets_per_byte): Return unsigned int.
8041 (bfd_arch_mach_octets_per_byte): Ditto.
8042 * libbfd.c (bfd_read, bfd_seek): Quell signed vs. unsigned
8044 * section.c (bfd_get_section_size_before_reloc): Quell signed
8045 vs. unsigned comparison warning.
8046 (bfd_get_section_size_after_reloc): Same here. Fix parentheses too.
8047 * trad-core.c (trad_unix_core_file_p): Correct 2000-01-27
8048 change. What was I thinking?
8049 * bfd-in2.h: Regenerate.
8051 * elflink.h (elf_gc_sweep): Skip non-elf input bfds.
8052 (elf_gc_sections): Same here.
8053 (elf_gc_common_finalize_got_offsets): And here.
8055 2000-02-21 Ian Lance Taylor <ian@zembu.com>
8057 ELF HPPA doesn't work at present; remove it until it does.
8058 * config.bfd: Comment out setting targ_defvec to
8060 * Makefile.am: Rebuild dependencies.
8061 (BFD32_BACKENDS): Remove elf32-hppa.lo.
8062 (BFD32_BACKENDS_CFILES): Remove elf32-hppa.c.
8063 (SOURCE_HFILES): Remove elf32-hppa.h and hppa_stubs.h.
8064 * Makefile.in: Rebuild.
8065 * targets.c (bfd_target_vector): Comment out bfd_elf32_hppa_vec.
8067 2000-02-18 Geoff Keating <geoffk@cygnus.com>
8069 * coffcode.h (coff_set_arch_mach_hook): Use free(), because there
8070 is no bfd_free(). Revert bfd_free part of previous change.
8072 2000-02-18 Geoff Keating <geoffk@cygnus.com>
8074 * coffcode.h (coff_set_arch_mach_hook): Don't use variable-size
8076 (coff_compute_section_file_positions): Use bfd_free to pair
8078 (coff_write_object_contents): Likewise.
8080 * coff-rs6000.c (xcoff_howto_table_16): New variable.
8081 (xcoff_rtype2howto): Handle 16-bit variants of 32-bit relocs.
8083 2000-02-18 Ulrich Drepper <drepper@cygnus.com>
8085 * coff-rs6000.c (XCOFFARMAGBIG): New macro.
8086 (xcoff_ar_file_hdr_big): New structure.
8087 (SIZEOF_AR_FILE_HDR_BIG): New macro.
8088 (xcoff_ar_hdr_big): New structure.
8089 (SIZEOF_AR_HDR_BIG): New macro.
8090 (xcoff_big_format_p): New macro.
8091 (xcoff_ardata_big): New macro.
8092 (arch_xhdr_big): New macro.
8093 (xcoff_slurp_armap): Handle large archives.
8094 (xcoff_archive_p): Detect large archives.
8095 (xcoff_read_ar_hdr): Handle large archives.
8096 (xcoff_openr_next_archived_file): Handle large archives.
8097 (xcoff_generic_stat_arch_elt): Handle large archives.
8098 (xcoff_write_armap_old): Rename from xcoff_write_armap.
8099 (xcoff_write_armap_big): New function.
8100 (xcoff_write_armap): New function, dispatch to _old or _big.
8101 (xcoff_write_archive_contents_old): Rename from
8102 xcoff_write_archive_contents.
8103 (xcoff_write_archive_contents_big): New function.
8104 (xcoff_write_archive_contents): New function, dispatch to _old or
8107 2000-02-18 Richard Henderson <rth@cygnus.com>
8109 * elf-bfd.h (struct elf_link_hash_table): Remove copy_indirect
8110 and hide_symbol members.
8111 (elf_link_hash_copy_indirect): Remove.
8112 (elf_link_hash_hide_symbol): Remove.
8113 (struct elf_backend_data): Add elf_backend_copy_indirect_symbol
8114 and elf_backend_hide_symbol.
8115 (_bfd_elf_link_hash_copy_indirect): Declare.
8116 (_bfd_elf_link_hash_hide_symbol): Declare.
8117 * elf.c (_bfd_elf_link_hash_copy_indirect): Remove table argument.
8118 (_bfd_elf_link_hash_hide_symbol): Likewise.
8119 (_bfd_elf_link_hash_table_init): Don't init killed members.
8120 * elflink.h (elf_link_add_object_symbols): Use the bed function
8121 pointers not elf_link_hash_{copy_indirect,hide_symbol}.
8122 (elf_link_assign_sym_version): Likewise.
8123 * elfxx-target.h (elf_backend_copy_indirect_symbol): Default.
8124 (elf_backend_hide_symbol): Likewise.
8125 (elfNN_bed): Update for new members.
8127 2000-02-17 Kevin Buettner <kevinb@redhat.com>
8129 * rs6000-core.c (CORE_DATA_SIZE_FIELD, CORE_COMM_FIELD, SAVE_FIELD,
8130 STACK_END_ADDR): Define for new core file format.
8131 (LOADER_OFFSET_FIELD, LOADER_REGION_SIZE, CORE_DUMP): New defines
8132 for handling the vagaries of the various core file structures used
8133 by AIX over the years.
8134 (rs6000coff_core_p, rs6000coff_core_file_matches_executable,
8135 Rs6kCorData): Use above defines to adapt code to use AIX 4.3's
8136 core_dumpx structure.
8138 Thu Feb 17 00:04:48 2000 J"orn Rennecke <amylaar@cygnus.co.uk>
8140 * archures.c (bfd_mach_sh2, bfd_mach_sh_dsp): New macros.
8141 (bfd_mach_sh3_dsp): Likewise.
8142 (bfd_mach_sh4): Reinstate.
8143 (bfd_default_scan): Recognize 7410, 7708, 7729 and 7750.
8144 * bfd-in2.h: Regenerate.
8145 * coff-sh.c (struct sh_opcode): flags is no longer short.
8146 (USESAS, USESAS_REG, USESR8, SETSAS, SETSAS_REG): New macros.
8147 (sh_opcode41, sh_opcode42): Integrate as sh_opcode41.
8148 (sh_opcode01, sh_opcode02, sh_opcode40): Add sh-dsp opcodes.
8149 (sh_opcode41, sh_opcode4, sh_opcode80): Likewise.
8150 (sh_opcodes): No longer const.
8151 (sh_dsp_opcodef0, sh_dsp_opcodef): New arrays.
8152 (sh_insn_uses_reg): Check for USESAS and USESR8.
8153 (sh_insn_sets_reg, sh_insns_conflict): Check for SETSAS.
8154 (_bfd_sh_align_load_span): Return early for SH4.
8155 Modify sh_opcodes lookup table for sh-dsp / sh3-dsp.
8156 Take into account that field b of a parallel processing insn
8157 could be mistaken for a separate insn.
8158 * cpu-sh.c (arch_info_struct): New array elements for
8159 sh2, sh-dsp and sh3-dsp.
8160 Reinstate element for sh4.
8161 (SH2_NEXT, SH_DSP_NEXT, SH3_DSP_NEXT): New macros.
8162 (SH4_NEXT): Reinstate.
8163 (SH3_NEXT, SH3E_NEXT): Adjust.
8164 * elf-bfd.h (_sh_elf_set_mach_from_flags): Declare.
8165 * elf32-sh.c (sh_elf_set_private_flags): New function.
8166 (sh_elf_copy_private_data, sh_elf_set_mach_from_flags): Likewise.
8167 (sh_elf_merge_private_data): New function.
8168 (elf_backend_object_p, bfd_elf32_bfd_set_private_bfd_flags): Define.
8169 (bfd_elf32_bfd_copy_private_bfd_data): Define.
8170 (bfd_elf32_bfd_merge_private_bfd_data): Change to
8171 sh_elf_merge_private_data.
8173 2000-02-13 Richard Henderson <rth@cygnus.com>
8175 * elf-bfd.h (struct elf_link_hash_table): Add copy_indirect and
8176 hide_symbol members.
8177 (elf_link_hash_copy_indirect): New.
8178 (elf_link_hash_hide_symbol): New.
8179 * elflink.h (elf_link_add_object_symbols): Break out copy from
8180 indirect new new symbol to elf.c.
8181 (elf_link_assign_sym_version): Break out privatization of
8182 non-exported symbol to elf.c.
8183 * elf.c (_bfd_elf_link_hash_copy_indirect): New.
8184 (_bfd_elf_link_hash_hide_symbol): New.
8185 (_bfd_elf_link_hash_table_init): Init copy_indirect and hide_symbol.
8187 2000-02-13 Ian Lance Taylor <ian@zembu.com>
8189 * section.c (_bfd_strip_section_from_output): Add info parameter.
8190 If it passed as non-NULL, use it to check whether any input BFD
8191 has an input section which uses this output section. Change all
8193 * bfd-in2.h: Rebuild.
8195 * bfd-in.h: Move declarations of bfd_get_elf_phdr_upper_bound and
8196 bfd_get_elf_phdrs in from bfd-in2.h, correcting patch of
8198 * bfd-in2.h: Rebuild.
8200 2000-02-10 Timothy Wall <twall@cygnus.com>
8202 * coffswap.h (coff_swap_sym_in): Add hook SWAP_SYM_IN_POST to
8203 allow final modifications of swapped-in symbol.
8204 (coff_swap_sym_out): Ditto with SWAP_SYM_OUT_POST.
8205 * coffcode.h (coff_write_relocs): Use macro
8206 SECTION_RELATIVE_ABSOLUTE_SYMBOL_P if defined to determine whether
8207 symbol index should be set to -1.
8209 Thu Feb 10 20:07:50 GMT 2000 Toshiyasu Morita (toshi.morita@sega.com)
8211 * coff-sh.c (USES1_REG, USES2_REG, SETS1_REG, SETS2_REG,
8212 USESF1_REG, USESF2_REG, SETSF1_REG, SETSF2_REG): New macros.
8213 * (sh_insn_sets_reg, sh_insn_sets_freg): New prototypes.
8214 * (sh_insn_sets_reg, sh_insn_uses_or_sets_reg, sh_insns_sets_freg,
8215 sh_insns_uses_or_sets_freg): New functions.
8216 * (sh_insn_uses_reg, sh_insn_uses_freg): Use new macros.
8217 * (sh_insns_conflict): Use new functions and new macros to
8218 detect conflicts when two instructions both set same integer registers,
8219 both set same fp register, and both set special register.
8221 2000-02-09 Timothy Wall <twall@cygnus.com>
8223 * coffgen.c (coff_real_object_p): Set arch/mach info prior to
8224 swapping in sections, so that the swapping routines have access to
8227 2000-02-08 Mark Elbrecht <snowball3@bigfoot.com>
8229 * coff-go32.c: Update comment. Update copyright.
8231 2000-01-27 Thomas de Lellis <tdel@windriver.com>
8233 * syms.c (bfd_decode_symclass)
8234 Two new class characters were added - 'V' and 'v'. The
8235 meaning of 'W' is now restricted to just weak non-object
8236 symbols. This allows differentiation between, for example,
8237 weak functions vs weak objects. nm for example now dumps:
8239 'w' = weak unresolved
8240 'V' = weak global object
8241 'v' = weak unresolved object
8243 (bfd_is_undefined_symclass): New function. Return true if the
8244 given symbol class represents and undefined/unresolved symbol.
8246 (bfd_symbol_info): Use bfd_is_undefined_symclass to check for
8249 * bfd-in2.h: Add prototype for bfd_is_undefined_symbol().
8251 * elf32-arm.h (elf32_arm_get_symbol_type): If a symbol has the
8252 STT_ARM_16BIT flag set, but it is not attached to a data object
8253 return STT_ARM_16BIT so that it will be treated as code by the
8256 2000-01-27 Alan Modra <alan@spri.levels.unisa.edu.au>
8258 * coff-i386.c (i3coff_object_p): Remove prototype.
8261 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Add const
8262 to name. Update copyright.
8264 * trad-core.c (trad_unix_core_file_p): Cast core_regsec
8265 assignment to avoid warning. Update copyright.
8267 2000-01-24 Robert Lipe (robertl@sco.com)
8269 * coffcode.h (coff_write_object_contents): Get buff via bfd_malloc
8270 instead of using GNU C extension.
8272 2000-01-21 Nick Clifton <nickc@cygnus.com>
8274 * libbfd.c (bfd_read): Do not attempt to get a negativly sized
8275 amount from a bfd_in_memory structure.
8276 (bfd_seek): Do not allow seeks past the end of a bfd_in_memory
8279 2000-01-14 Nick Clifton <nickc@cygnus.com>
8281 * linker.c (default_indirect_link_order): oops - fix incorrectly
8282 applied patch from Tim Wall.
8284 2000-01-13 Timothy Wall (twall@tiac.net>
8286 * coffcode.h: Use bfd_coff_xxx instead of the macro XXX (where xxx
8287 = scnhsz, filhsz, relsz, aoutsz, etc)
8289 * coffswap.h: Ditto.
8291 2000-01-13 Nick Clifton <nickc@cygnus.com>
8293 * elf32-arm.h (elf32_thumb_to_arm_stub): Fix offset in branch to
8294 interwork thumb to arm stub.
8296 2000-01-13 Timothy Wall (twall@tiac.net>
8298 * archures.c (bfd_octets_per_byte): New function: Return
8300 (bfd_arch_mach_octets_per_byte): New function: Return target
8303 * section.c: Distinguish between octets and bytes for usage of
8304 _cooked_size, _raw_size, and output_offset. Clarify
8305 description of bfd_set_section_contents.
8307 * bfd-in2.h: Regenerate.
8309 * coffgen.c: Indicate that the offset parameter is in bytes, not
8312 * cofflink.c (bfd_coff_link_input_bfd): Use bfd_octets_per_byte
8313 where appropriate to get the octet offset when calling
8314 bfd_set_section_contents.
8315 (bfd_coff_reloc_link_order): Ditto.
8317 * linker.c (bfd_generic_reloc_link_order): Ditto.
8318 (_bfd_default_link_order): Ditto.
8320 * reloc.c (bfd_perform_relocation): Distinguish between octets
8321 and bytes. Use octets when indexing into octet data; use bytes
8322 when calculating target addresses.
8323 (bfd_install_relocation): Ditto.
8325 * srec.c (srec_write_section): Ditto.
8327 2000-01-13 Nick Clifton <nickc@cygnus.com>
8329 * coff-mcore.c (COFF_DEFAULT_SECTION_ALIGNMENT_POWER): Change from
8330 3 to 2. This allows 4 byte sized sections, which is necessary for
8331 dlltool to build functioning DLLs.
8333 2000-01-10 Philip Blundell <pb@futuretv.com>
8335 * config.bfd (arm*-*-linux-gnu*): Match instead of arm*-*-linux-gnu.
8336 (arm*-*-conix*): New target.
8338 2000-01-10 Egor Duda <deo@logos-m.ru>
8340 * config.bfd: Include elf32_i386 vector to target list for cygwin
8343 * config.in: Undefine HAVE_WIN32_PSTATUS_T.
8344 * configure.in: Test for structure win32_pstatus_t in
8346 * configure: Regenerate.
8348 * elf.c (elfcore_grok_win32pstatus): New function: process
8349 win32_pstatus_t notes in elf core file.
8350 (elfcore_grok_note): Detect win32_pstatus notes.
8352 2000-01-03 Martin v. Loewis <loewis@informatik.hu-berlin.de>
8354 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Process symbol
8356 * elflink.h (elf_link_add_object_symbols): Combine visibilities.
8357 * elf.c (bfd_elf_print_symbol): Interpret st_other as visibility.
8359 For older changes see ChangeLog-9899
8365 version-control: never