1 2001-10-24 Richard Henderson <rth@redhat.com>
3 * peXXigen.c (_bfd_XX_print_private_bfd_data_common): Copy
4 timestamp to time_t for ctime.
6 2001-10-24 Hans-Peter Nilsson <hp@axis.com>
8 * elf32-cris.c (cris_reloc_type_lookup): Change loop to use
9 unsigned, increasing index.
11 2001-10-23 H.J. Lu <hjl@gnu.org>
13 * elf32-mips.c (_bfd_mips_elf_modify_segment_map): Check
14 m != NULL before accessing it.
16 2001-10-23 Alan Modra <amodra@bigpond.net.au>
18 * elflink.h (elf_link_input_bfd): Zero the reloc instead of doing
19 bfd_reloc_type_lookup (bfd, BFD_RELOC_NONE) as bfd_reloc_type_lookup
20 doesn't accept BFD_RELOC_* on some targets, eg. hppa.
22 * elf32-hppa.c (elf32_hppa_link_hash_entry): Remove plt_abs.
23 (hppa_link_hash_newfunc): Likewise.
24 (elf32_hppa_finish_dynamic_symbol): Likewise.
25 (allocate_dynrelocs): Always allocate .got relocs if shared.
26 (elf32_hppa_relocate_section): Output them too. Similarly
27 consolidate .plt reloc code, and no longer initialise .plt
28 when a reloc is output.
29 (elf32_hppa_finish_dynamic_symbol): Only initialise .plt entries
30 when no reloc is output.
32 From Herbert Xu <herbert@gondor.apana.org.au>
33 * elf32-hppa.c (final_link_relocate): Call bfd_set_error for
36 2001-10-22 H.J. Lu <hjl@gnu.org>
38 * configure.in (WIN32LIBADD): Use -L../libiberty for
42 2001-10-21 H.J. Lu <hjl@gnu.org>
44 * configure.in (WIN32LIBADD): Include -L../libiberty/pic -liberty
45 if shared library is enabled only for Linux hosts.
48 2001-10-21 H.J. Lu <hjl@gnu.org>
50 * configure.in (WIN32LIBADD): Check if PICFLAG is defined in
51 ../libiberty/Makefile instead of $enable_shared.
54 2001-10-21 H.J. Lu <hjl@gnu.org>
56 * elf32-cris.c (cris_reloc_type_lookup): Use int for index. Cover
59 2001-10-20 H.J. Lu <hjl@gnu.org>
61 * configure.in (WIN32LIBADD): Include -L../libiberty/pic -liberty
62 if shared library is enabled.
65 2001-10-20 H.J. Lu <hjl@gnu.org>
67 * elf32-cris.c (cris_reloc_type_lookup): Allow index 0.
69 2001-10-19 H.J. Lu <hjl@gnu.org>
71 * elfcode.h (elf_object_p): Don't clear D_PAGED if the section
74 2001-10-18 H.J. Lu <hjl@gnu.org>
76 * elf32-i370.c (i370_elf_relocate_section): Ignore R_XXX_NONE.
77 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
79 2001-10-18 Jakub Jelinek <jakub@redhat.com>
81 * section.c (_bfd_strip_section_from_output): Don't count
82 SEC_EXCLUDE sections as references. Set SEC_EXCLUDE.
84 2001-10-17 Alan Modra <amodra@bigpond.net.au>
86 * elf-m10200.c (mn10200_elf_relax_section): Cast assignment to
87 Elf_Internal_Shdr.contents now that it's no longer a PTR.
88 * elf-m10300.c (mn10300_elf_relax_section): Likewise.
89 * elf32-h8300.c (elf32_h8_relax_section): Likewise.
90 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Likewise.
91 * elf32-sh.c (sh_elf_relax_section): Likewise.
92 * elf64-alpha.c (elf64_alpha_relax_section): Likewise.
93 * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
94 * elf.c (setup_group): Warning fixes.
95 * elflink.h (elf_link_sort_relocs): Likewise.
96 * pdp11.c (slurp_reloc_table): Likewise.
98 2001-10-16 Jeff Holcomb <jeffh@redhat.com>
100 * elflink.h (elf_link_sort_relocs): Remove unnecessary pointer
103 2001-10-15 H.J. Lu <hjl@gnu.org>
105 * elflink.h (elf_link_input_bfd): Set type to BFD_RELOC_NONE
106 for relocations against discarded link-once section.
108 2001-10-15 Alan Modra <amodra@bigpond.net.au>
110 * elf32-i386.c (elf_i386_relocate_section): Report some detail on
111 bfd_reloc_outofrange and similar errors.
113 * elf.c (_bfd_elf_link_hash_copy_indirect): Test ind->root.type
114 rather than ind->weakdef.
115 * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Likewise.
116 * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
117 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Likewise.
118 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
119 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
121 2001-10-15 Alan Modra <amodra@bigpond.net.au>
122 H.J. Lu <hjl@gnu.org>
124 * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Merge dyn_reloc
125 counts for aliases instead of aborting.
126 * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
127 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
129 * elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Set plt.offset
130 to -1 for non-function symbols.
131 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Likewise.
132 * elf32-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
133 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
134 * elf64-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
135 * elf64-x86-64.c (elf64_x86_64_adjust_dynamic_symbol): Likewise.
136 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Refer to
137 plt.offset instead of plt.refcount when setting to -1.
139 2001-10-12 Nick Clifton <nickc@cambridge.redhat.com>
141 * elf32-arm.h (elf32_arm_relocate_section): Treat R_ARM_THM_PC22
142 like R_ARM_PC24. Include reloc number in error message about
145 2001-10-10 Jakub Jelinek <jakub@redhat.com>
147 * elflink.h (elf_link_sort_cmp2): Don't mix PLT and non-PLT
148 relocations against the same symbol in .rel{,a}.dyn section.
150 2001-10-10 Kazu Hirata <kazu@hxi.com>
152 * aout-encap.c: Fix comment typos.
154 * archive.c: Likewise.
156 * coff64-rs6000.c: Likewise.
157 * coffcode.h: Likewise.
158 * coffgen.c: Likewise.
159 * cofflink.c: Likewise.
160 * coff-mips.c: Likewise.
162 * elf32-m32r.c: Likewise.
163 * libcoff-in.h: Likewise.
164 * libecoff.h: Likewise.
165 * libxcoff.h: Likewise.
166 * nlm32-i386.c: Likewise.
168 * section.c: Likewise.
171 * bfd-in2.h: Regenerate.
172 * libcoff.h: Likewise.
174 2001-10-10 Alan Modra <amodra@bigpond.net.au>
176 * elf.c (elf_map_symbols): Don't create new section symbols; Use
177 existing section syms. Update comments.
178 (copy_private_bfd_data): Formatting fixes.
179 (elfcore_grok_win32pstatus): Likewise.
180 (swap_out_syms): Likewise. Remove unnecessary level of braces.
182 2001-10-09 Alan Modra <amodra@bigpond.net.au>
184 * elf-bfd.h (struct bfd_elf_section_data): Rename "group" to
186 (elf_group_name): Define.
187 (elf_next_in_group): Define.
188 * elf.c: Make use of elf_group_name and elf_next_in_group throughout.
189 (setup_group): Don't use sec->lineno for SHT_GROUP section to store
190 first member section; Instead use elf_next_in_group.
191 (bfd_section_from_shdr): Likewise.
192 (set_group_contents): Likewise. Use elf_section_syms, not sec->symbol.
194 2001-10-09 Alan Modra <amodra@bigpond.net.au>
196 * elf-bfd.h (struct bfd_elf_section_data): Add "group" and
197 "next_in_group". Fix gp and gp_size comments.
198 * elf.c (union elf_internal_group): New.
199 (setup_group): New function.
200 (_bfd_elf_make_section_from_shdr): Set BFD flags for SHT_GROUP.
201 Call setup_group for SHF_GROUP sections.
202 (bfd_section_from_shdr): Build a BFD section for SHT_GROUP.
203 (elf_fake_sections): Set header type for SEC_GROUP, and header
204 flags for sections in a group.
205 (set_group_contents): New function.
206 (_bfd_elf_compute_section_file_positions): Call it.
207 (assign_section_numbers): Set sh_link for SHT_GROUP.
209 * elflink.h (gc_mark_hook): Handle section groups.
210 * elfxx-target.h: Add SEC_GROUP to applicable_flags.
211 * section.c (SEC_GROUP): Define.
212 (struct sec): Comment fixes.
213 * bfd-in2.h: Regenerate.
215 * elf.c (bfd_elf_print_symbol): Formatting fix; migrate expression
216 out of function args.
217 (_bfd_elf_canonicalize_reloc): Similarly.
218 (_bfd_elf_get_symtab): Here too.
219 (_bfd_elf_canonicalize_dynamic_symtab): And here.
220 * elfcode.h (elf_slurp_symbol_table): Don't recalculate size for
221 bfd_bread, and remove unnecessary cast.
223 2001-10-08 Aldy Hernandez <aldyh@redhat.com>
225 * bfd/config.bfd (targ_cpu): Add arm9e-*-elf.
227 2001-10-06 Stephane Carrez <Stephane.Carrez@worldnet.fr>
229 * dwarf2.c (comp_unit_find_nearest_line): Check for end of
232 2001-10-06 Alan Modra <amodra@bigpond.net.au>
234 * bfd.c (bfd_assert): Report bfd version.
235 (_bfd_abort): Likewise.
237 * elflink.h (elf_link_input_bfd): Don't zero discarded link-once
238 section sym values. Instead replace any relocs against them with
239 relocs against STN_UNDEF, which has a zero value.
241 * elf32-arc.c (elf_arc_howto_table): Set partial_inplace for all
244 2001-10-05 Jeff Law <law@redhat.com>
246 * som.h (som_exec_data): New field "version_id".
247 * som.c (som_object_setup): Record the version_id if it
249 (som_prep_headers): Do not initialize version_id here.
250 (som_finish_writing): Initialize version_id here.
252 2000-10-05 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
254 * elf32-mips.c (elf_mips_howto_table): Fix some relocation howtos
255 according to the MIPS/SGI ELF64 ABI Draft.
256 (mips_elf_sort_hash_table): Typo.
258 2001-10-04 Alan Modra <amodra@bigpond.net.au>
260 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Comment typo.
262 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Bail out after
263 copying flags if this is a weakdef.
265 2001-10-04 Alan Modra <amodra@bigpond.net.au>
267 * elf-bfd.h (struct elf_link_hash_entry): Reorganise for better
270 * elf32-mips.c (mips_elf_record_global_got_symbol): Set got.offset
271 to 1 rather than 0 to avoid confusing copy_indirect_symbol.
272 (mips_elf_sort_hash_table_f): Compare got.offset against 1.
274 * Makefile.am (BFD_H_DEPS): Add symcat.h. Ensure everything
275 depends on $(BFD_H) $(BFD_H_DEPS) $(LOCAL_H_DEPS), not just those
276 backends we configure. Run "make dep-am".
277 (install-data-local): Install symcat.h.
278 * dep-in.sed: Remove symcat.h from dependencies.
279 * Makefile.in: Regenerate.
281 2001-10-03 Vassili Karpov <malc@pulsesoft.com>
283 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Handle nocopyreloc.
285 2001-10-03 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
287 * elf64-mips.c (elf_backend_may_use_rela_p): New define.
288 (elf_backend_default_use_rela_p): New define.
290 2001-10-03 Alan Modra <amodra@bigpond.net.au>
292 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Fix typos in last
295 * configure.in (AC_OUTPUT <bfd-in3.h>): Remove version.h.
296 * configure: Regenerate.
297 * Makefile.am (BFD_H_FILES): Add version.h.
298 * Makefile.in: Regenerate.
299 * po/SRC-POTFILES.in: Regenerate.
301 * elflink.h (elf_fix_symbol_flags): Copy flags to weakdef using
302 elf_backend_copy_indirect_symbol so that backend has a chance to
303 copy other necessary fields.
304 * elf-bfd.h (struct elf_backend_data): Update description of
305 elf_backend_copy_indirect_symbol.
306 * elf.c (_bfd_elf_link_hash_copy_indirect): Bail out after
307 copying flags if this is a weakdef.
308 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
309 (elfNN_ia64_aix_add_symbol_hook): Use elf_link_hash_lookup rather
310 than bfd_link_hash_lookup.
311 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Don't do copy
312 reloc processing for weakdefs.
313 * elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Likewise.
314 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
316 2001-10-02 Alan Modra <amodra@bigpond.net.au>
318 * elf64-ppc.c (ppc64_elf_check_relocs): Use a local var and cast
319 result of ELF64_R_TYPE to enum before using in a switch.
320 (ppc64_elf_gc_mark_hook): Likewise.
321 (ppc64_elf_gc_sweep_hook): Likewise.
322 (ppc64_elf_reloc_type_class): Likewise.
324 2001-10-02 Alan Modra <amodra@bigpond.net.au>
326 * version.h: New file.
327 * bfd-in.h: (BFD_VERSION): Substitute bfd_version.
328 (BFD_VERSION_DATE): Define.
329 (BFD_VERSION_STRING): Define.
330 * configure.in: AC_SUBST bfd_version, bfd_version_date and
332 (AC_OUTPUT <bfd-in3.h>): Depend on version.h.
333 * bfd-in2.h: Regenerate.
334 * configure: Regenerate.
335 * Makefile.am: Run "make dep-am".
336 * Makefile.in: Regenerate.
338 * bfd-in.h: Include "symcat.h".
339 (CONCAT4): Redefine as for old CAT4.
340 * aout-arm.c: Use equivalent CONCAT* macro in place of CAT* macros.
341 Add warning regarding whitespace.
342 * aout-cris.c: Likewise.
343 * aout-ns32k.c: Likewise.
344 * aout-sparcle.c: Likewise.
345 * aout-tic30.c: Likewise.
347 * armnetbsd.c: Likewise.
348 * demo64.c: Likewise.
349 * elf-bfd.h: Likewise.
350 * gen-aout.c: Likewise.
351 * host-aout.c: Likewise.
352 * hp300bsd.c: Likewise.
353 * hp300hpux.c: Likewise.
354 * i386aout.c: Likewise.
355 * i386bsd.c: Likewise.
356 * i386dynix.c: Likewise.
357 * i386freebsd.c: Likewise.
358 * i386linux.c: Likewise.
359 * i386lynx.c: Likewise.
360 * i386mach3.c: Likewise.
361 * i386netbsd.c: Likewise.
362 * libaout.h: Likewise.
363 * m68k4knetbsd.c: Likewise.
364 * m68klinux.c: Likewise.
365 * m68klynx.c: Likewise.
366 * m68knetbsd.c: Likewise.
367 * m88kmach3.c: Likewise.
368 * mipsbsd.c: Likewise.
369 * newsos3.c: Likewise.
370 * ns32knetbsd.c: Likewise.
371 * pc532-mach.c: Likewise.
373 * riscix.c: Likewise.
374 * sparclinux.c: Likewise.
375 * sparclynx.c: Likewise.
376 * sparcnetbsd.c: Likewise.
378 * targets.c: Likewise.
379 * vaxnetbsd.c: Likewise.
380 * vms-hdr.c: Likewise.
382 2001-10-01 Alan Modra <amodra@bigpond.net.au>
384 * bfd-in.h: Remove comments regarding generated files.
385 * libbfd-in.h: Likewise.
386 * libcoff-in.h: Likewise.
387 * bfd-in2.h: Regenerate.
388 * libbfd.h: Likewise.
389 * libcoff.h: Likewise.
391 2001-09-30 kaz Kojima <kkojima@rr.iij4u.or.jp>
392 Hans-Peter Nilsson <hp@bitrange.com>
394 * elf32-sh.c (sh_elf_howto_table, R_SH_REL32): Make
395 partial_inplace, matching assembler output. Set src_mask to
397 (sh_elf_relocate_section): Delete misplaced comment.
398 For relocatable linking against section symbol, call
399 _bfd_relocate_contents for partial_inplace relocs and adjust
400 rel->r_addend for others.
401 <case R_SH_DIR32, R_SH_REL32>: Fetch partial_inplace addend with
402 bfd_get_32, not at rel->r_addend.
404 2001-09-30 Alan Modra <amodra@bigpond.net.au>
406 * elf.c (_bfd_elf_link_hash_copy_indirect): Set ind refcounts to
407 the old dir refcount, so we indirectly set them to init_refcount.
408 Short-circuit asserts when we've just verified they are true.
410 2001-09-29 Alan Modra <amodra@bigpond.net.au>
412 * section.c (struct sec): Remove kept_section.
413 (STD_SECTION): Remove kept_section initialisation.
414 (bfd_make_section_anyway): Here too.
415 * ecoff.c (bfd_debug_section): Remove kept_section initialisation.
416 * cofflink.c (_bfd_coff_link_input_bfd): Don't test kept_section.
417 * elflink.h (elf_link_input_bfd): Set discarded link-once section
418 symbols to zero, and remove all code involved with kept_section
419 and tracking section symbol values.
420 * bfd-in2.h: Regenerate.
421 * configure.in: Bump version number.
422 * configure: Regenerate.
424 2001-09-29 Alan Modra <amodra@bigpond.net.au>
426 * elf64-ppc.c (struct ppc_dyn_relocs): New.
427 (IS_ABSOLUTE_RELOC): Define.
428 (struct ppc_link_hash_entry): New.
429 (struct ppc_link_hash_table): New.
430 (ppc_hash_table): Define.
431 (link_hash_newfunc): New function.
432 (ppc64_elf_link_hash_table_create): New function.
433 (create_got_section): New function.
434 (ppc64_elf_create_dynamic_sections): Call create_got_section. Stash
435 pointers to our dynamic sections in hash table.
436 (ppc64_elf_copy_indirect_symbol): New function.
437 (ppc64_elf_check_relocs): Remove DEBUG code. Use short-cuts to
438 dynamic sections. Localise vars. Modify code for refcounts
439 starting from zero. Don't allocate here, or force symbols dynamic.
440 Don't copy all relocs if shared, select ones we need. Add code
441 to track possible copy relocs for non-shared link.
442 (ppc64_elf_gc_mark_hook): Update comment.
443 (ppc64_elf_gc_sweep_hook): Sweep dynrelocs too.
444 (ppc64_elf_adjust_dynamic_symbol): Remove DEBUG code. Rewrite .plt
445 code for reference counting garbage collection. Don't create .plt
446 entries for functions that don't comply with ABI naming convention,
447 and don't allocate .plt space here. Use short-cuts to dynamic
448 sections. If possible, keep dynamic relocations instead of using
449 copy relocs. Remove confused comments.
450 (ppc_adjust_dynindx): Delete.
451 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
452 (allocate_dynrelocs): New function.
453 (readonly_dynrelocs): New function.
454 (ppc64_elf_size_dynamic_sections): Rewrite. Allocate local .got
455 space here, and call allocate_dynrelocs to allocate space for
456 global .plt, .got and reloc sections. Use short-cuts to dynamic
457 sections. Call readonly_dynrelocs to determine whether we need
458 DT_TEXTREL. Don't generate section symbols here, the generic
459 ELF linker code does it for us.
460 (ppc64_elf_final_link): Call regular ELF backend linker rather than
461 gc variety, since we do our own .got handling.
462 (ppc64_elf_relocate_section): Remove DEBUG code. Make use of
463 dynamic section short-cuts. Localise vars, and delay setting.
464 Handle unknown relocs in main switch statement. Replace ugly
465 complicated tests for unresolvable relocs with a simple direct
466 scheme using "unresolved_reloc" var. Test ELF_ST_VISIBILITY
467 before allowing an undefined sym in a shared lib. Do R_*_DS tests
468 after main switch, when we've set addend. Do non-addend insn
469 tweaks before main swithc. Ignore input_section->vma when
470 calculating reloc offsets as it's always zero. Rewrite dynamic
471 reloc handling. Consolidate R_*_HA handling. Handle more relocs.
472 (ppc64_elf_finish_dynamic_symbol): Remove DEBUG code. Make use
473 of dynamic section short-cuts. Reorganise .plt handling code.
474 Remove confused comments. Take note of ELF_LINK_FORCED_LOCAL.
475 Move expressions out of swap_reloca_out function calls.
476 (ppc64_elf_reloc_type_class): New function.
477 (ppc64_elf_info_to_howto): Move common expression to local var.
478 (ppc64_elf_finish_dynamic_sections): Remove DEBUG code. Make use
479 of dynamic section short-cuts. Don't fiddle with section syms
480 here as the ELF linker does it for us.
481 (elf_backend_can_refcount): Define.
482 (bfd_elf64_bfd_link_hash_table_create): Define.
483 (elf_backend_copy_indirect_symbol): Define.
484 (elf_backend_reloc_type_class): Define.
485 (elf_backend_*, bfd_elf64_bfd_* defines): Sort.
487 2001-09-29 Alan Modra <amodra@bigpond.net.au>
489 * elf-bfd.h (struct elf_link_local_dynamic_entry): Add init_refcount.
490 (struct elf_backend_data): Add can_refcount.
491 * elf.c (_bfd_elf_link_hash_newfunc): Get rid of a few casts. Set
492 got.refcount and plt.refcount from init_refcount.
493 (_bfd_elf_link_hash_table_init): Set up init_refcount.
494 (_bfd_elf_link_hash_copy_indirect): Reference got/plt.refcount
495 rather than got/plt.offset, and test for <= 0 rather than -1.
496 * elflink.h (size_dynamic_sections): Set init_refcount to -1.
497 * elfxx-target.h (elf_backend_can_refcount): Define.
498 (elfNN_bed): Init can_refcount.
499 * linker.c (_bfd_link_hash_newfunc): Get rid of a few casts.
500 (_bfd_generic_link_hash_newfunc): Likewise.
501 * elf32-cris.c (cris_elf_check_relocs): Modify for refcounts
503 (elf_backend_can_refcount): Define.
504 * elf32-hppa.c (elf32_hppa_check_relocs): Modify for refcounts
506 (elf32_hppa_copy_indirect_symbol): Make static to agree with
508 (elf_backend_can_refcount): Define.
509 * elf32-i386.c (elf_i386_check_relocs): Modify for refcounts
511 (allocate_dynrelocs): Set plt/got.offset rather than *.refcount.
512 (elf_i386_finish_dynamic_symbol): Expand SHN_UNDEF comment.
513 (elf_i386_finish_dynamic_sections): Use local var so line < 80 chars.
514 (elf_backend_can_refcount): Define.
515 (elf_i386_copy_indirect_symbol): Make static to agree with
516 prototype. Formatting fix.
517 * elf32-m68k.c (elf_m68k_check_relocs): Modify for refcounts
519 (elf_backend_can_refcount): Define.
520 * elf32-ppc.c (ppc_elf_check_relocs): Modify for refcounts
522 (elf_backend_can_refcount): Define.
523 * elf32-s390.c (elf_s390_check_relocs): Modify for refcounts
525 (elf_backend_can_refcount): Define.
526 * elf64-s390.c (elf_s390_check_relocs): Modify for refcounts
528 (elf_backend_can_refcount): Define.
529 * elf64-x86-64.c (elf64_x86_64_check_relocs): Modify for refcounts
531 (elf_backend_can_refcount): Define.
533 * som.c (som_write_symbol_strings): Cast current_offset in
534 bfd_seek call to match param type.
536 2001-09-28 J. Brobecker <brobecker@gnat.com>
538 * som.c (som_write_symbol_strings): Fix incorrect type of
539 current_offset to match the function definition. Fixes a build
540 failure on HPUX-11.00.
542 2001-09-28 Richard Henderson <rth@redhat.com>
544 * elfxx-target.h [section_flags]: Add SEC_ARCH_BIT_0, SEC_SMALL_DATA,
545 SEC_MERGE, SEC_STRINGS.
547 * section.c (SEC_ARCH_BIT_0): New; replace unused SEC_BALIGN.
548 * bfd-in2.h: Rebuild.
550 2001-09-28 Alan Modra <amodra@bigpond.net.au>
552 * elf64-x86-64.c (elf64_x86_64_reloc_type_lookup): Don't map bfd
553 reloc code using x86_64_reloc_map.
555 * elf32-hppa.c (elf32_hppa_check_relocs): Update comment since we
556 no longer allocate here. Localise some vars to blocks where they
558 (elf32_hppa_adjust_dynamic_symbol): Correct a comment. Delay
559 setting of vars until needed.
560 (allocate_dynrelocs): Don't create a .plt entry without a reloc
561 when symbol visibilty makes a function local.
562 (elf32_hppa_finish_dynamic_symbol): Move expressions out of
563 swap_reloca_out function calls.
564 (elf32_hppa_relocate_section): Likewies. Comment typo fix.
565 (elf32_hppa_finish_dynamic_sections): Migrate common code out of
568 * elf32-i386.c (elf_i386_check_relocs): Update comment since we
569 no longer allocate here. Localise some vars to blocks where they
570 are used. Remove separate switch stmt for creating .got sec.
571 (elf_i386_adjust_dynamic_symbol): Correct a comment. Remove
572 redundant casts and aborts. Delay setting of vars until needed.
573 (allocate_dynrelocs): Remove redundant casts and aborts.
574 (elf_i386_size_dynamic_sections): Move comment.
575 (elf_i386_finish_dynamic_symbol): Move expressions out of function
577 (elf_i386_relocate_section): Likewise. Comment typo fix.
578 (elf_i386_finish_dynamic_sections): Migrate common code out of
580 (elf_backend_* defines): Sort.
582 * elf32-i386.c (allocate_dynrelocs): Don't create a .plt entry
583 without a reloc when symbol visibilty makes a function local.
585 2001-09-27 Nick Clifton <nickc@cambridge.redhat.com>
587 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix detection of
588 conflicting float flags.
590 2001-09-26 Alan Modra <amodra@bigpond.net.au>
592 * elf32-i386 (elf_i386_copy_indirect_symbol): New function.
593 (elf_backend_copy_indirect_symbol): Define.
594 (struct elf_i386_link_hash_entry): Rename "root" to "elf".
595 (struct elf_i386_link_hash_table): Likewise.
596 (link_hash_newfunc): Get rid of unnecessary casts.
597 (elf_i386_link_hash_table_create): Likewise.
598 (elf_i386_check_relocs): Initialise local_got_refcounts to 0.
599 Don't test input section SEC_READONLY here to try to avoid copy
600 relocs, and keep dyn_relocs regardleas of ELF_LINK_NON_GOT_REF.
601 (elf_i386_adjust_dynamic_symbol): Check output section SEC_READONLY
602 here to properly test whether we need copy relocs. Do so for weak
605 * elf32-hppa (elf32_hppa_copy_indirect_symbol): New function.
606 (elf_backend_copy_indirect_symbol): Define.
607 (struct elf32_hppa_link_hash_table): Rename "root" to "elf".
608 (stub_hash_newfunc): Get rid of unnecessary casts.
609 (hppa_link_hash_newfunc): Likewise.
610 (elf32_hppa_check_relocs): Initialise local_got_refcounts to 0.
611 Don't test input section SEC_READONLY here to try to avoid copy
612 relocs, and keep dyn_relocs regardleas of ELF_LINK_NON_GOT_REF.
613 (elf32_hppa_adjust_dynamic_symbol): Check output section SEC_READONLY
614 here to properly test whether we need copy relocs. Do so for weak
617 2001-09-26 Alan Modra <amodra@bigpond.net.au>
619 * bfd.c (_bfd_default_error_handlerl): Define using VPARAMS,
620 VA_OPEN, VA_FIXEDARG, VA_CLOSE.
621 (bfd_archive_filename): Cast bfd_malloc arg to the correct size.
623 2001-09-25 Jakub Jelinek <jakub@redhat.com>
625 * elf64-sparc.c (sparc64_elf_build_plt): Fix .plt[32768+] slot
628 2001-09-25 H.J. Lu <hjl@gnu.org>
630 * bfd-in2.h: Regenerated.
632 2001-09-25 Alan Modra <amodra@bigpond.net.au>
634 * elf32-i386.c: Add comment re linker function names and ordering.
635 (elf_i386_link_hash_newfunc): Rename to link_hash_newfunc.
636 (elf_i386_grok_prstatus): Move before linker functions.
637 (elf_i386_grok_psinfo): Likewise.
638 (elf_i386_fake_sections): Move so that functions are ordered.
639 (elf_i386_reloc_type_class): Likewise. Comment function purpose.
641 2001-09-25 Alan Modra <amodra@bigpond.net.au>
643 * elf32-hppa.c: Rename occurrences of "hplink" to "htab"
646 * elf32-hppa.c: (LONG_BRANCH_PIC_IN_SHLIB): Delete. Remove all
647 code handling this option.
648 (LONG_BRANCH_VIA_PLT): Likewise.
649 (RELATIVE_DYNRELOCS): Define as zero.
650 (struct elf32_hppa_dyn_reloc_entry): Add "sec", and
651 "pc_count" fields. Remove "section" field.
652 (elf32_hppa_link_hash_entry): Rename reloc_entries to dyn_relocs.
653 (elf32_hppa_check_relocs): Don't allocate space for dynamic
654 relocs here. Instead, record all needed dynamic relocs via
655 dyn_relocs and local_dynrel. Cache pointer to "sreloc" section
657 (elf32_hppa_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
658 (allocate_plt_and_got_and_discard_relocs): Rename to
659 allocate_dynrelocs. Allocate rather than discarding dyn relocs.
660 (readonly_dynrelocs): New function.
661 (elf32_hppa_size_dynamic_sections): Mark output_bfd unused.
662 Call readonly_dynrelocs to determine need for DT_TEXTREL.
663 Rename "i" to "ibfd". Allocate space for local dyn relocs.
664 (elf32_hppa_relocate_section): Make use of cached sreloc.
665 (elf32_hppa_reloc_type_class): New function.
666 (elf_backend_reloc_type_class): Define.
668 2001-09-25 Alan Modra <amodra@bigpond.net.au>
670 * elf-bfd.h (struct bfd_elf_section_data): Add "local_dynrel"
672 * elf32-i386.c (struct elf_i386_dyn_relocs): Add "sec", and
673 "pc_count" fields. Remove "section" field.
674 (elf_i386_check_relocs): Don't set DF_TEXTREL here. Don't
675 allocate space for dynamic relocs here. Instead, record all
676 needed dynamic relocs via dyn_relocs and local_dynrel. Cache
677 pointer to "sreloc" section in elf_section_data.
678 (elf_i386_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
679 (allocate_plt_and_got_and_discard_relocs): Rename to
680 allocate_dynrelocs. Allocate rather than discarding dyn relocs.
681 (readonly_dynrelocs): New function.
682 (elf_i386_size_dynamic_sections): Call readonly_dynrelocs.
683 Rename "i" to "ibfd". Allocate space for local dyn relocs.
684 (elf_i386_relocate_section): Make use of cached sreloc.
686 2001-09-24 Alan Modra <amodra@bigpond.net.au>
688 * elf-bfd.h (elf_backend_reloc_type_class): Pass in the entire
689 reloc rather than just the type.
690 (_bfd_elf_reloc_type_class): Likewise.
691 * elf.c (_bfd_elf_reloc_type_class): Likewise.
692 * elf32-arm.h (elf32_arm_reloc_type_class): Likewise.
693 * elf32-cris.c (elf_cris_reloc_type_class): Likewise.
694 * elf32-i386.c (elf_i386_reloc_type_class): Likewise.
695 * elf32-m68k.c (elf32_m68k_reloc_type_class): Likewise.
696 * elf32-ppc.c (ppc_elf_reloc_type_class): Likewise.
697 * elf32-s390.c (elf_s390_reloc_type_class): Likewise.
698 * elf32-sh.c (sh_elf_reloc_type_class): Likewise.
699 * elf32-sparc.c (elf32_sparc_reloc_type_class): Likewise.
700 * elf64-alpha.c (elf64_alpha_reloc_type_class): Likewise.
701 * elf64-s390.c (elf_s390_reloc_type_class): Likewise.
702 * elf64-sparc.c (sparc64_elf_reloc_type_class): Likewise.
703 * elf64-x86-64.c (elf64_x86_64_reloc_type_class): Likewise.
704 * elfxx-ia64.c (elfNN_ia64_reloc_type_class): Likewise.
705 * elflink.h: Formatting fixes.
706 (elf_link_sort_relocs): Make "count" and "size" bfd_size_type.
707 Call bfd_zmalloc rather than calloc. Remove unnecessary cast of
708 o->contents to PTR. Update call to elf_backend_reloc_type_class.
710 2001-09-22 John Reiser <jreiser@BitWagon.com>
712 * elfcode.h (elf_object_p): Allow for no section header at all in
713 non-ET_REL files. Honor 0 for e_shnum, e_shstrndx, e_shoff.
715 2001-09-21 Nick Clifton <nickc@cambridge.redhat.com>
717 * elfxx-ia64.c: Fix compile time warning messages.
718 * coff-mcore.c: Fix compile time warning messages.
719 * coff-ppc.c: Fix compile time warning messages.
720 * coffcode.h: Fix compile time warning messages.
721 * elf32-mips.c: Fix compile time warning messages.
722 * elf64-alpha.c: Fix compile time warning messages.
723 * libbfd.c: Fix compile time warning messages.
724 * bfd-in2.h: Regenerate.
726 2001-09-21 Alan Modra <amodra@bigpond.net.au>
728 * Makefile.am: Run "make dep-am".
729 * Makefile.in: Regenerate.
731 * aoutx.h: Formatting fixes.
732 * merge.c (_bfd_merged_section_offset): Break line at 80 chars.
734 * linker.c: Replace bfd_get_filename with bfd_archive_filename
737 2001-09-21 Alan Modra <amodra@bigpond.net.au>
739 * bfd.c (bfd_archive_filename): New function.
740 * bfd-in2.h: Regenerate.
741 * aout-adobe.c: Replace bfd_get_filename with bfd_archive_filename
742 in error messages where the bfd is an input bfd.
743 * aout-cris.c: Likewise.
744 * coff-arm.c: Likewise.
745 * coff-mcore.c: Likewise.
746 * coff-ppc.c: Likewise.
747 * coff-rs6000.c: Likewise.
748 * coff-sh.c: Likewise.
749 * coff-tic54x.c: Likewise.
750 * coff-tic80.c: Likewise.
751 * coff64-rs6000.c: Likewise.
752 * coffcode.h: Likewise.
753 * coffgen.c: Likewise.
754 * cofflink.c: Likewise.
755 * ecofflink.c: Likewise.
756 * elf-hppa.h: Likewise.
758 * elf32-arm.h: Likewise.
759 * elf32-cris.c: Likewise.
760 * elf32-gen.c: Likewise.
761 * elf32-hppa.c: Likewise.
762 * elf32-i370.c: Likewise.
763 * elf32-i386.c: Likewise.
764 * elf32-m32r.c: Likewise.
765 * elf32-mcore.c: Likewise.
766 * elf32-mips.c: Likewise.
767 * elf32-ppc.c: Likewise.
768 * elf32-s390.c: Likewise.
769 * elf32-sh.c: Likewise.
770 * elf32-sparc.c: Likewise.
771 * elf32-v850.c: Likewise.
772 * elf64-alpha.c: Likewise.
773 * elf64-gen.c: Likewise.
774 * elf64-ppc.c: Likewise.
775 * elf64-s390.c: Likewise.
776 * elf64-sparc.c: Likewise.
777 * elf64-x86-64.c: Likewise.
778 * elflink.h: Likewise.
779 * elfxx-ia64.c: Likewise.
782 * libbfd.c: Likewise.
784 * pe-mips.c: Likewise.
785 * peicode.h: Likewise.
787 * xcofflink.c: Likewise.
789 * elf32-arm.h: Make _bfd_error_handler calls K&R compatible.
791 * elflink.c (_bfd_elf_create_linker_section): Better grammar for
794 * coff-mcore.c (coff_mcore_relocate_section): Internalionalise
797 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Constify stt_types.
798 Consolidate error messages, and split long messages to two lines.
800 2001-09-20 John Reiser <jreiser@BitWagon.com>
802 * elf32-i386.c (elf_i386_relocate_section): Coordinate info->symbolic
803 and info->allow_shlib_undefined.
804 * elf32-cris.c: Likewise.
805 * elf32-hppa.c: Likewise.
806 * elf32-m68k.c: Likewise.
807 * elf32-mips.c: Likewise.
808 * elf32-ppc.c: Likewise.
809 * elf32-s390.c: Likewise.
810 * elf32-sh.c: Likewise.
811 * elf32-sparc.c: Likewise.
812 * elf64-alpha.c: Likewise.
813 * elf64-hppa.c: Likewise.
814 * elf64-ppc.c: Likewise.
815 * elf64-s390.c: Likewise.
816 * elf64-sparc.c: Likewise.
817 * elf64-x86-64.c: Likewise.
818 * elfxx-ia64.c: Likewise.
820 2001-09-18 Bruno Haible <haible@clisp.cons.org>
822 * aoutx.h: Include "safe-ctype.h" instead of <ctype.h>.
823 (aout_link_write_symbols): Use ISDIGIT instead of isdigit.
824 * archive.c: Include "safe-ctype.h" instead of <ctype.h>.
825 (_bfd_generic_read_ar_hdr_mag): Use ISDIGIT instead of isdigit.
826 * archures.c: Include "safe-ctype.h" instead of <ctype.h>.
827 (bfd_default_scan): Use ISDIGIT instead of isdigit.
828 * bfd.c: Include "safe-ctype.h" instead of <ctype.h>.
829 (bfd_scan_vma): Use ISXDIGIT/ISDIGIT/ISLOWER instead of
830 isxdigit/isdigit/islower.
831 * binary.c: Include "safe-ctype.h" instead of <ctype.h>.
832 (mangle_name): Use ISALNUM instead of isalnum.
833 * cpu-v850.c: Include "safe-ctype.h" instead of <ctype.h>.
834 (scan): Use ISDIGIT instead of isdigit.
835 * hosts/alphavms.h: Don't include <ctype.h>.
836 * ieee.c: Include "safe-ctype.h" instead of <ctype.h>.
837 (ieee_object_p): Use TOUPPER instead of toupper.
838 * ihex.c: Include "safe-ctype.h" instead of <ctype.h>.
839 (ihex_bad_byte): Use ISPRINT instead of isprint.
840 * merge.c: Don't include <ctype.h>.
841 * oasys.c: Include "safe-ctype.h" instead of <ctype.h>.
842 (oasys_write_sections): Use ISDIGIT instead of isdigit.
843 * pdp11.c: Include "safe-ctype.h" instead of <ctype.h>.
844 (aout_link_write_symbols): Use ISDIGIT instead of isdigit.
845 * ppcboot.c: Include "safe-ctype.h" instead of <ctype.h>.
846 (mangle_name): Use ISALNUM instead of isalnum.
847 * som.c: Include "safe-ctype.h" instead of <ctype.h>.
848 (som_set_reloc_info): Use ISUPPER/ISLOWER/ISDIGIT instead of
849 isupper/islower/isdigit.
850 (som_decode_symclass): Use TOUPPER instead of toupper.
851 * srec.c: Include "safe-ctype.h" instead of <ctype.h>.
852 (srec_bad_byte): Use ISPRINT instead of isprint.
853 (srec_scan): Use ISSPACE instead of isspace.
854 * stabs.c: Include "safe-ctype.h" instead of <ctype.h>.
855 (_bfd_link_section_stabs): Use ISDIGIT instead of isdigit.
856 * syms.c: Include "safe-ctype.h"
857 (islower, toupper): Remove macro definitions.
858 (bfd_decode_symclass): Use TOUPPER instead of toupper.
859 * vms-gsd.c: Don't include <ctype.h>.
860 * vms-hdr.c: Include "safe-ctype.h" instead of <ctype.h>.
861 (_bfd_vms_write_hdr): Use ISLOWER/TOUPPER instead of
863 * vms-tir.c: Don't include <ctype.h>.
865 2001-09-18 Alan Modra <amodra@bigpond.net.au>
867 * libbfd.c (bfd_bread): New function replacing bfd_read without
868 redundant params. Allow reads up to (size_t) -2 in length.
869 (bfd_bwrite): Similarly for bfd_write.
870 (real_read): Return a size_t.
871 (bfd_read): Call bfd_bread.
872 (bfd_write): Call bfd_bwrite.
873 (warn_deprecated): New function to annoy everybody.
874 (bfd_get_file_window): Don't call bfd_set_error unnecessarily.
875 * bfd-in.h (bfd_bread, bfd_bwrite, warn_deprecated): Declare.
876 (bfd_read, bfd_write): Define as macro.
877 * aix386-core.c: Replace calls to bfd_read with bfd_bread, and
878 likewise for bfd_write. Ensure function args are correct size by
879 using casts or local vars. In some cases, remove unnecessary
880 casts. Formatting fixes, in some cases removing a large expression
881 from function args by using a local var. Replace CONST with const.
882 Modify variable types to avoid warings. Use casts to avoid
883 warnings when using negative numbers in unsigned expressions.
884 * aout-adobe.c: Likewise.
885 * aout-arm.c: Likewise.
886 * aout-cris.c: Likewise.
887 * aout-encap.c: Likewise.
888 * aout-ns32k.c: Likewise.
889 * aout-target.h: Likewise.
890 * aout-tic30.c: Likewise.
891 * aoutf1.h: Likewise.
893 * archive.c: Likewise.
894 * archures.c: Likewise.
895 * bfd-in.h: Likewise.
897 * binary.c: Likewise.
900 * cisco-core.c: Likewise.
901 * coff-a29k.c: Likewise.
902 * coff-alpha.c: Likewise.
903 * coff-arm.c: Likewise.
904 * coff-h8300.c: Likewise.
905 * coff-h8500.c: Likewise.
906 * coff-i386.c: Likewise.
907 * coff-i860.c: Likewise.
908 * coff-i960.c: Likewise.
909 * coff-ia64.c: Likewise.
910 * coff-m68k.c: Likewise.
911 * coff-m88k.c: Likewise.
912 * coff-mcore.c: Likewise.
913 * coff-mips.c: Likewise.
914 * coff-ppc.c: Likewise.
915 * coff-rs6000.c: Likewise.
916 * coff-sh.c: Likewise.
917 * coff-sparc.c: Likewise.
918 * coff-stgo32.c: Likewise.
919 * coff-tic30.c: Likewise.
920 * coff-tic54x.c: Likewise.
921 * coff-tic80.c: Likewise.
922 * coff-w65.c: Likewise.
923 * coff-z8k.c: Likewise.
924 * coff64-rs6000.c: Likewise.
925 * coffcode.h: Likewise.
926 * coffgen.c: Likewise.
927 * cofflink.c: Likewise.
928 * coffswap.h: Likewise.
929 * corefile.c: Likewise.
930 * cpu-arc.c: Likewise.
931 * cpu-h8300.c: Likewise.
932 * cpu-h8500.c: Likewise.
933 * cpu-i960.c: Likewise.
934 * cpu-ia64-opc.c: Likewise.
935 * cpu-ns32k.c: Likewise.
936 * cpu-pdp11.c: Likewise.
937 * cpu-pj.c: Likewise.
938 * cpu-sh.c: Likewise.
939 * cpu-w65.c: Likewise.
940 * cpu-z8k.c: Likewise.
941 * dwarf1.c: Likewise.
942 * dwarf2.c: Likewise.
944 * ecofflink.c: Likewise.
945 * ecoffswap.h: Likewise.
946 * elf-bfd.h: Likewise.
947 * elf-hppa.h: Likewise.
948 * elf-m10200.c: Likewise.
949 * elf-m10300.c: Likewise.
951 * elf32-arc.c: Likewise.
952 * elf32-arm.h: Likewise.
953 * elf32-avr.c: Likewise.
954 * elf32-cris.c: Likewise.
955 * elf32-fr30.c: Likewise.
956 * elf32-gen.c: Likewise.
957 * elf32-h8300.c: Likewise.
958 * elf32-hppa.c: Likewise.
959 * elf32-i370.c: Likewise.
960 * elf32-i386.c: Likewise.
961 * elf32-i860.c: Likewise.
962 * elf32-m32r.c: Likewise.
963 * elf32-m68k.c: Likewise.
964 * elf32-mcore.c: Likewise.
965 * elf32-mips.c: Likewise.
966 * elf32-openrisc.c: Likewise.
967 * elf32-pj.c: Likewise.
968 * elf32-ppc.c: Likewise.
969 * elf32-s390.c: Likewise.
970 * elf32-sh-lin.c: Likewise.
971 * elf32-sh.c: Likewise.
972 * elf32-sparc.c: Likewise.
973 * elf32-v850.c: Likewise.
974 * elf64-alpha.c: Likewise.
975 * elf64-hppa.c: Likewise.
976 * elf64-mips.c: Likewise.
977 * elf64-ppc.c: Likewise.
978 * elf64-s390.c: Likewise.
979 * elf64-sparc.c: Likewise.
980 * elf64-x86-64.c: Likewise.
981 * elfarm-nabi.c: Likewise.
982 * elfcode.h: Likewise.
983 * elfcore.h: Likewise.
984 * elflink.c: Likewise.
985 * elflink.h: Likewise.
986 * elfxx-ia64.c: Likewise.
987 * elfxx-target.h: Likewise.
988 * format.c: Likewise.
990 * hp300hpux.c: Likewise.
991 * hppabsd-core.c: Likewise.
992 * hpux-core.c: Likewise.
993 * i386aout.c: Likewise.
994 * i386dynix.c: Likewise.
995 * i386linux.c: Likewise.
996 * i386lynx.c: Likewise.
997 * i386mach3.c: Likewise.
998 * i386msdos.c: Likewise.
999 * i386os9k.c: Likewise.
1002 * irix-core.c: Likewise.
1003 * libaout.h: Likewise.
1004 * libbfd-in.h: Likewise.
1005 * libbfd.c: Likewise.
1006 * libcoff-in.h: Likewise.
1007 * libecoff.h: Likewise.
1008 * libieee.h: Likewise.
1009 * libnlm.h: Likewise.
1010 * libpei.h: Likewise.
1011 * libxcoff.h: Likewise.
1012 * linker.c: Likewise.
1013 * lynx-core.c: Likewise.
1014 * m68klinux.c: Likewise.
1015 * merge.c: Likewise.
1016 * mipsbsd.c: Likewise.
1017 * netbsd-core.c: Likewise.
1019 * nlm32-alpha.c: Likewise.
1020 * nlm32-i386.c: Likewise.
1021 * nlm32-ppc.c: Likewise.
1022 * nlm32-sparc.c: Likewise.
1023 * nlmcode.h: Likewise.
1024 * nlmswap.h: Likewise.
1025 * ns32k.h: Likewise.
1026 * oasys.c: Likewise.
1027 * opncls.c: Likewise.
1028 * osf-core.c: Likewise.
1029 * pc532-mach.c: Likewise.
1030 * pdp11.c: Likewise.
1031 * pe-mips.c: Likewise.
1032 * peXXigen.c: Likewise.
1033 * peicode.h: Likewise.
1034 * ppcboot.c: Likewise.
1035 * ptrace-core.c: Likewise.
1036 * reloc.c: Likewise.
1037 * reloc16.c: Likewise.
1038 * riscix.c: Likewise.
1039 * rs6000-core.c: Likewise.
1040 * sco5-core.c: Likewise.
1041 * section.c: Likewise.
1043 * sparclinux.c: Likewise.
1044 * sparclynx.c: Likewise.
1046 * stabs.c: Likewise.
1047 * sunos.c: Likewise.
1049 * targets.c: Likewise.
1050 * tekhex.c: Likewise.
1051 * trad-core.c: Likewise.
1052 * versados.c: Likewise.
1053 * vms-gsd.c: Likewise.
1054 * vms-hdr.c: Likewise.
1055 * vms-misc.c: Likewise.
1056 * vms-tir.c: Likewise.
1059 * xcofflink.c: Likewise.
1060 * bfd-in2.h: Regenerate.
1061 * libbfd.h: Regenerate.
1062 * libcoff.h: Regenerate.
1064 * bfd.c (struct _bfd): Make "where" and "origin" unsigned.
1065 * bfd-in.h (file_ptr): Change from a long int to a bfd_signed_vma.
1066 (ufile_ptr): Define.
1067 (bfd_tell): Return a ufile_ptr.
1068 * libbfd.c (bfd_tell): Likewise.
1069 (bfd_seek): Use bfd_size_type locals. Don't call bfd_set_error
1071 * aix386-core.c: Test != 0 for bfd_seek errors rather than < 0.
1072 * aoutf1.h: Likewise.
1074 * cache.c (bfd_cache_lookup_worker): Guard against abfd->where
1075 larger than unsigned long can represent.
1077 * libbfd.c (bfd_malloc): Take a bfd_size_type arg. Error if
1078 size overflows size_t.
1079 (bfd_realloc): Likewise.
1080 (bfd_zmalloc): Likewise.
1081 * opncls.c (bfd_alloc): Likewise.
1082 (bfd_zalloc): Likewise.
1083 * libbfd-in.h (bfd_malloc, bfd_realloc, bfd_zmalloc): Update.
1084 (bfd_alloc, bfd_zalloc): Update.
1086 * libbfd.c (bfd_get_8): Mask with 0xff in case char is more than
1088 (bfd_get_signed_8): Likewise.
1089 (H_PUT_64, H_PUT_32, H_PUT_16, H_PUT_8,
1090 H_PUT_S64, H_PUT_S32, H_PUT_S16, H_PUT_S8,
1091 H_GET_64, H_GET_32, H_GET_16, H_GET_8,
1092 H_GET_S64, H_GET_S32, H_GET_S16, H_GET_S8): Define and use.
1093 * libaout.h: Likewise define and use here.
1094 * aout-adobe.c: Use H_GET_* and H_PUT_* macros.
1095 * aout-arm.c: Likewise.
1096 * aout-encap.c: Likewise.
1097 * aout-ns32k.c: Likewise.
1098 * aout-tic30.c: Likewise.
1099 * aoutf1.h: Likewise.
1100 * aoutx.h: Likewise.
1102 * coff-alpha.c: Likewise.
1103 * coff-h8300.c: Likewise.
1104 * coff-h8500.c: Likewise.
1105 * coff-i960.c: Likewise.
1106 * coff-ia64.c: Likewise.
1107 * coff-m88k.c: Likewise.
1108 * coff-mips.c: Likewise.
1109 * coff-ppc.c: Likewise.
1110 * coff-rs6000.c: Likewise.
1111 * coff-sh.c: Likewise.
1112 * coff-sparc.c: Likewise.
1113 * coff-stgo32.c: Likewise.
1114 * coff-tic30.c: Likewise.
1115 * coff-tic80.c: Likewise.
1116 * coff-w65.c: Likewise.
1117 * coff-z8k.c: Likewise.
1118 * coff64-rs6000.c: Likewise.
1119 * coffgen.c: Likewise.
1120 * cofflink.c: Likewise.
1121 * coffswap.h: Likewise.
1122 * ecoff.c: Likewise.
1123 * ecoffswap.h: Likewise.
1125 * elf32-mips.c: Likewise.
1126 * elf64-mips.c: Likewise.
1127 * hp300hpux.c: Likewise.
1128 * i386dynix.c: Likewise.
1129 * i386lynx.c: Likewise.
1130 * i386msdos.c: Likewise.
1131 * i386os9k.c: Likewise.
1132 * libpei.h: Likewise.
1133 * nlm32-alpha.c: Likewise.
1134 * nlm32-i386.c: Likewise.
1135 * nlm32-ppc.c: Likewise.
1136 * nlmcode.h: Likewise.
1137 * nlmswap.h: Likewise.
1138 * oasys.c: Likewise.
1139 * pdp11.c: Likewise.
1140 * pe-mips.c: Likewise.
1141 * peXXigen.c: Likewise.
1142 * peicode.h: Likewise.
1143 * riscix.c: Likewise.
1144 * sunos.c: Likewise.
1145 * xcofflink.c: Likewise.
1146 * elfcode.h: (put_word, get_word, put_signed_word, get_signed_word):
1147 Rename to H_PUT_WORD, H_GET_WORD, H_PUT_SIGNED_WORD, H_GET_SIGNED_WORD.
1148 * coff-rs6000.c (PUTWORD, PUTHALF, PUTBYTE): Don't define. Use
1149 equivalent H_PUT_* macro instead.
1150 (GETWORD, GETHALF, GETBYTE): Similarly.
1151 * coff64-rs6000.c (PUTWORD, PUTHALF, PUTBYTE): Likewise.
1152 (GETWORD, GETHALF, GETBYTE): Likewise.
1153 * coffswap.h (PUTWORD, PUTHALF, PUTBYTE): Likewise.
1155 * bfd-in.h (struct orl): Change "pos" to a union.
1156 * archive.c (_bfd_compute_and_write_armap): Use it instead of casts.
1157 (bsd_write_armap): Here too.
1158 (coff_write_armap): And here.
1159 * coff-rs6000.c (xcoff_write_armap_old): And here.
1160 (xcoff_write_one_armap_big): And here.
1161 (xcoff_write_armap_big): And here.
1162 * ecoff.c (_bfd_ecoff_write_armap): And here.
1163 * elf64-mips.c (mips_elf64_write_armap): And here.
1165 * aoutf1.h (sunos_set_arch_mach): Make "mach" param an enum.
1166 * elf-m10300.c (elf_mn10300_mach): Return an unsigned long.
1167 * elf32-h8300.c (elf32_h8_mach): Likewise.
1168 * elf32-mips.c (elf_mips_mach): Likewise.
1169 * sparclynx.c (NAME(lynx,set_arch_mach)): Likewise.
1171 * aix386-core.c (aix386_core_file_p): Remove redundant bfd_release
1173 (aix386_core_vec): Typo fix.
1175 * aout-arm.c: Include libaout.h and aout/aout64.h after N_TXTADDR
1176 etc. to avoid redefined macro warning.
1177 (MY(put_reloc)): Use bfd_vma for "value" rather than long.
1178 (MY(fix_pcrel_26)): Likewise.
1179 * aout-ns32k.c (MY(put_reloc)): Likewise.
1180 * aout-cris.c (MY(swap_ext_reloc_out)): Likewise for r_addend.
1181 * aoutx.h (NAME(aout,swap_ext_reloc_out)): Likewise.
1182 * coff-arm.c (coff_arm_relocate_section): Likewise for my_offset.
1184 * aout-encap.c: Include "file", not <file> for binutils headers.
1185 (encap_object_p): Half baked attempt to fix compile errors in
1186 code dealing with "magic".
1188 * aout-ns32k.c: Include "file", not <file> for binutils headers.
1189 (_bfd_ns32k_relocate_contents): get_data and put_data manipulate
1190 bfd_vma's rather than longs.
1191 * cpu-ns32k.c (ns32k_sign_extend): Delete.
1192 (_bfd_ns32k_get_displacement): Return a bfd_vma, don't pass in offset.
1193 (_bfd_ns32k_get_immediate): Likewise. Add code for 8 byte values,
1195 (_bfd_ns32k_put_displacement): Accept a bfd_vma, don't pass in offset.
1196 Use unsigned comparisons.
1197 (bfd_ns32k_put_immediate): Likewise, and add code for 8 byte values.
1198 (do_ns32k_reloc): get_data and put_data operate on bfd_vma's.
1199 (_bfd_do_ns32k_reloc_contents): Likewise.
1200 * ns32k.h (_bfd_ns32k_get_displacement): Update prototype.
1201 (_bfd_ns32k_get_immediate): Likewise.
1202 (_bfd_ns32k_put_displacement): Likewise.
1203 (_bfd_ns32k_put_immediate): Likewise.
1204 (bfd_reloc_status_type): Likewise.
1206 * aoutx.h (NAME(aout,find_nearest_line)): Rename 'p' to 'colon'
1208 * pdp11.c (NAME(aout,find_nearest_line)): Likewise.
1209 * coff-h8300.c (h8300_reloc16_extra_cases): Remove shadowing "value".
1210 * coff-ppc.c (enum ref_category): Rename "data" to "tocdata" to
1212 (record_toc): Use a bfd_signed_vma for our_toc_offset.
1213 * coffcode.h (coff_write_relocs): Rename "i" to avoid shadowing.
1214 * elf.c (bfd_elf_get_bfd_needed_list): Rename "link" var to avoid
1216 (_bfd_elfcore_strndup): Likewise for "dup".
1217 * elf32-cris.c (cris_elf_relocate_section): "symname" instead of
1218 "name" to avoid shadowing.
1219 * elf32-hppa.c (elf32_hppa_relocate_section): Remove duplicate
1220 definition of "off".
1221 * elf32-i386.c (elf_i386_relocate_section): Likewise.
1222 * elf32-mips.c (_bfd_mips_elf_modify_segment_map): Remove duplicate
1224 (_bfd_mips_elf_final_link): Rename "i" to "j". Remove duplicate
1226 * elf64-x86-64.c (elf64_x86_64_relocate_section): Rename inner "indx"
1228 * elflink.h (elf_link_add_object_symbols): Rename "link" to "shlink"
1230 (elf_link_input_bfd): Likewise.
1231 (elf_bfd_final_link): Remove duplicate innermost "off" var.
1232 * oasys.c (oasys_write_data): Rename innermost "p" to "sym".
1233 * reloc16.c (bfd_coff_reloc16_relax_section): Rename "i" param to
1235 * som.c (som_prep_for_fixups): Rename inner "i" to "j".
1236 * sunos.c (sunos_add_dynamic_symbols): Localise "s" var.
1237 (sunos_write_dynamic_symbol): Remove unused vars.
1238 * syms.c (_bfd_stab_section_find_nearest_line): Remove duplicate
1239 innermost "directory_name" and "file_name" vars.
1240 * tekhex.c (first_phase): Rename local var "type" to "stype".
1241 (tekhex_write_object_contents): Rename innermost "s" to "sym".
1242 * vms-gsd.c (vms_secflag_by_name): Change "size" param to "hassize",
1243 doing comparison at caller.
1244 (vms_esecflag_by_name): Likewise.
1245 * vms-tir.c (etir_sto): Rename innermost "psect" to "psect1".
1246 * xcofflink.c (xcoff_link_input_bfd): Delete duplicate innermost "o".
1247 (xcoff_write_global_symbol): Rename "p" param to "inf".
1249 * cisco-core.c: Add missing prototypes.
1250 (cisco_core_file_failing_command): Add ATTRIBUTE_UNUSED.
1251 (cisco_core_file_failing_signal): Likewise.
1252 (cisco_core_file_matches_executable_p): Likewise.
1253 * hpux-core.c (hpux_core_core_file_failing_signal): Likewise.
1254 * netbsd-core.c (netbsd_core_file_matches_executable_p): Likewise.
1255 * osf-core.c (osf_core_core_file_matches_executable_p): Likewise.
1256 * sco5-core.c (sco5_core_file_matches_executable_p): Likewise.
1258 * coff-arm.c (coff_arm_link_hash_table): Use bfd_size_type for
1259 thumb_glue_size and arm_glue_size.
1260 * elf32-arm.h (elf32_arm_link_hash_table): Likewise here.
1262 * coff64-rs6000.c: Group prototypes together.
1264 * coffcode.h (coff_set_arch_mach): Add ATTRIBUTE_UNUSED.
1265 (buy_and_read): Remove "seek" param. Change "size" to bfd_size_type.
1267 * cpu-arc.c: Add missing prototypes.
1268 * cpu-h8500.c: Likewise.
1269 * cpu-i960.c: Likewise.
1270 * cpu-pj.c: Likewise.
1271 * cpu-sh.c: Likewise.
1272 * cpu-w65.c: Likewise.
1273 * cpu-z8k.c: Likewise.
1274 * elf32-fr30.c: Likewise.
1275 * elf32-h8300.c: Likewise.
1276 * elf32-i370.c: Likewise.
1277 * hpux-core.c: Likewise.
1278 * versados.c: Likewise.
1280 * cpu-h8300.c (bfd_default_scan_num_mach): Don't declare.
1281 * cpu-h8500.c: Likewise.
1282 * cpu-i960.c: Likewise.
1283 * cpu-z8k.c: Likewise.
1285 * cpu-ia64-opc.c: Correct comment.
1287 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Remove unused var.
1289 * elf-bfd.h (elf_size_info): Change count param of write_out_phdrs
1291 (bfd_elf32_write_out_phdrs): Likewise.
1292 (bfd_elf64_write_out_phdrs): Likewise.
1293 (elf_linker_section_pointers): Change addend to bfd_vma.
1294 (_bfd_elf_find_pointer_linker_section): Likewise.
1295 (_bfd_elfcore_make_pseudosection): Change size param to size_t and
1296 filepos to unsigned file_ptr.
1297 (_bfd_elfcore_strndup): Change max param to size_t.
1298 * elf.c (_bfd_elfcore_make_pseudosection): As above.
1299 (_bfd_elfcore_strndup): Likewise.
1300 (_bfd_elf_find_pointer_linker_section): Likewise.
1302 * elf-hppa.h (elf_hppa_relocate_insn): Return an int, and change
1303 insn and sym_value to ints.
1305 * elf.c (elf_read): Make "offset" param a file_ptr, "size" a
1307 (elfcore_read_notes): Likewise.
1309 * elf32-arm.h (elf32_arm_final_link_relocate): Change sym_flags
1310 param from unsigned char to int.
1311 (elf32_arm_relocate_section): If USE_REL, cast "rel" appropriately
1312 for info_to_howto call.
1313 (add_dynamic_entry): Define macro.
1314 (elf32_arm_size_dynamic_sections): Use add_dynamic_entry.
1316 * elf32-cris.c (add_dynamic_entry): Define macro.
1317 (elf_cris_size_dynamic_sections): Use add_dynamic_entry.
1319 * elf32-h8300.c (elf32_h8_final_write_processing): Make static.
1320 (elf32_h8_object_p): Likewise.
1321 (elf32_h8_merge_private_bfd_data): Likewise.
1322 (elf32_h8_relax_section): Cast gap to int so signed comparisons work.
1324 * elf32-hppa.c (add_dynamic_entry): Define macro.
1325 (elf32_hppa_size_dynamic_sections): Use it.
1326 * elf32-i370.c (add_dynamic_entry): Define macro.
1327 (i370_elf_size_dynamic_sections): Use it.
1328 (i370_noop): Make static.
1329 * elf32-i386.c (add_dynamic_entry): Define macro.
1330 (elf_i386_size_dynamic_sections): Use it.
1331 * elf32-m68k.c (add_dynamic_entry): Define macro.
1332 (elf_m68k_size_dynamic_sections): Use it.
1333 * elf32-ppc.c (add_dynamic_entry): Define macro.
1334 (ppc_elf_size_dynamic_sections): Use it.
1335 * elf32-s390.c (add_dynamic_entry): Define macro.
1336 (elf_s390_size_dynamic_sections): Use it.
1337 * elf64-alpha.c (add_dynamic_entry): Define macro.
1338 (elf64_alpha_size_dynamic_sections): Use it.
1339 * elf64-hppa.c (add_dynamic_entry): Define macro.
1340 (elf64_hppa_size_dynamic_sections): Use it.
1341 * elf64-ppc.c (add_dynamic_entry): Define macro.
1342 (ppc64_elf_size_dynamic_sections): Use it.
1343 * elf64-s390.c (add_dynamic_entry): Define macro.
1344 (elf_s390_size_dynamic_sections): Use it.
1345 * elf64-sparc.c (add_dynamic_entry): Define macro.
1346 (sparc64_elf_size_dynamic_sections): Use it.
1347 * elf64-x86-64.c (add_dynamic_entry): Define macro.
1348 (elf64_x86_64_size_dynamic_sections): Use it.
1349 * elfxx-ia64.c (add_dynamic_entry): Define macro.
1350 (elfNN_ia64_size_dynamic_sections): Use it.
1352 * elf32-v850.c (SEXT24): Modify to avoid signed/unsigned warning.
1353 (v850_elf_perform_relocation): Make "r_type" param unsigned.
1355 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Just return
1356 false if the first malloc fails rather than going via error_return.
1358 * elf64-sparc.c (sparc64_elf_plt_entry_offset): Use a bfd_vma for
1360 (sparc64_elf_plt_ptr_offset): Likewise, and for "max" param too.
1362 * elflink.h (elf_link_input_bfd): s/ingored/ignored/ in error message.
1364 * elfxx-ia64.c (global_sym_index): Return a long.
1366 * ieee.c (get_symbol): Use int rather than char param.
1367 (ieee_slurp_sections): Move "section" var to inner blocks.
1368 (copy_expression): Don't init "value" to zero or worry about
1369 clearing to zero after using.
1370 (ieee_write_debug_part): Rename "output_buffer" to "obuff" to avoid
1373 * ihex.c (ihex_write_record): Make "count" var a size_t, "addr" an
1376 * libbfd-in.h (BFD_ALIGN): Add cast to avoid signed/unsigned warning.
1377 (bfd_write_bigendian_4byte_int): Pass an unsigned int value param.
1379 * mipsbsd.c (mips_fix_jmp_addr): Add "error_message" param.
1381 * pc532-mach.c (MYNSX): Delete.
1382 (ns32kaout_bfd_reloc_type_lookup): Define prototype without MYNSX.
1383 (write_object_contents): Correct prototype.
1385 * peicode.h (pe_ILF_build_a_bfd): Use an unsigned int param rather
1386 than unsigned short.
1388 * section.c (bfd_set_section_contents): Remove redundant
1389 "offset < 0" test. Check that "count" doesn't overflow size_t.
1390 (bfd_get_section_contents): Likewise.
1392 * som.c (som_fixup_formats): Add missing braces.
1393 (som_reloc_addend): Pass a bfd_vma for "addend".
1395 * srec.c (srec_write_record): Pass "type" as an unsigned int.
1396 (srec_write_symbols): Remove an unnecessary var.
1398 * targets.c (_bfd_target_vector): Sort entries. Sort externs
1400 * configure.in: Sort to match. Bump version number.
1401 * configure: Regenerate.
1403 * tekhex.c (move_section_contents): Assert offset == 0.
1405 * versados.c (new_symbol_string): Constify arg.
1406 (process_esd): Use bfd_und_section_ptr rather than &bfd_und_section.
1407 (versados_get_symbol_info): Make static.
1408 (versados_print_symbol): Likewise.
1409 (versados_get_reloc_upper_bound): Likewise.
1410 (versados_canonicalize_reloc): Likewise.
1412 2001-09-18 Nick Clifton <nickc@cambridge.redhat.com>
1414 * elflink.h (elf_link_input_bfd): Fix typo in error message.
1416 2001-09-17 H.J. Lu <hjl@gnu.org>
1418 * dwarf1.c (parse_die): Take a new arg for the end of the
1419 section. Return false if die is beyond the section.
1420 (parse_functions_in_unit): Pass the end of the section to
1422 (_bfd_dwarf1_find_nearest_line): Likewise.
1424 2001-09-14 Michael Rauch <mrauch@netbsd.org>
1426 * elf32-sparc.c (elf32_sparc_relocate_section): Treat R_SPARC_UA32
1427 just like R_SPARC_32.
1429 2001-09-14 Kevin Lo <kevlo@openbsd.org>
1431 * configure.bfd: Add arm-openbsd target.
1433 2001-09-14 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1435 * config.bfd: Change machine triplets from mips*el*-* to mips*el-*.
1436 Add support for mips64.
1438 2001-09-13 Alexandre Oliva <aoliva@redhat.com>
1440 * elf32-openrisc.c (ELF_MACHINE_ALT1): Define as EM_OPENRISC_OLD.
1442 2001-09-12 Alexandre Oliva <aoliva@redhat.com>
1444 * elf.c (prep_headers): Get the machine code from the elf
1446 * elf-m10200.c (ELF_MACHINE_CODE): Redefine to EM_MN10200.
1447 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_MN10200.
1448 * elf-m10300.c (ELF_MACHINE_CODE): Redefine to EM_MN10300.
1449 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_MN10300.
1450 * elf-arc.c (arc_elf_final_write_processing): Don't override
1451 e_machine, it's now properly set in prep_headers.
1452 * elf32-avr.c (elf32_avr_object_p): Accept both EM_AVR and
1454 (ELF_MACHINE_ALT1): Define to EM_AVR_OLD.
1455 * elf-d10v.c (ELF_MACHINE_CODE): Redefine to EM_D10V.
1456 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_D10V.
1457 * elf-d30v.c (ELF_MACHINE_CODE): Redefine to EM_D30V.
1458 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_D30V.
1459 * elf-fr30.c (ELF_MACHINE_CODE): Redefine to EM_FR30.
1460 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_FR30.
1461 * elf-m32r.c (ELF_MACHINE_CODE): Redefine to EM_M32R.
1462 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_M32R.
1463 * elf32-pj.c (ELF_MACHINE_ALT1): DEfine to EM_PJ_OLD.
1464 * elf-v850.c (ELF_MACHINE_CODE): Redefine to EM_V850.
1465 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_V850.
1467 2001-09-11 Richard Henderson <rth@redhat.com>
1469 * elf64-alpha.c (elf64_alpha_section_flags): New.
1470 (elf64_alpha_fake_sections): Map SEC_SMALL_DATA to SHF_ALPHA_GPREL.
1472 2001-09-11 Richard Henderson <rth@redhat.com>
1474 * elf64-alpha.c (elf64_alpha_relocate_section): Do not
1475 apply HINT relocations against dynamic symbols.
1477 2001-09-11 H.J. Lu <hjl@gnu.org>
1479 * linker.c (link_action): Change COMMON_ROW\defw from CREF to COM.
1481 2001-09-09 Richard Henderson <rth@redhat.com>
1483 * elf64-alpha.c: Delete all unused ERIC_neverdef and rth_notdef code.
1485 * elf64-alpha.c (elf64_alpha_relax_with_lituse): Nop out gpdisp
1486 following a call to a near function.
1488 2001-09-08 Richard Henderson <rth@redhat.com>
1490 * elf64-alpha.c (elf64_alpha_relocate_section): Soft fail
1491 relocation errors. Fail gp-relative relocations against
1494 2001-09-08 Alan Modra <amodra@bigpond.net.au>
1496 * elf32-i386.c (elf_i386_relocate_section): Check !DEF_REGULAR
1497 as well as DEF_DYNAMIC in test for avoided copy relocs.
1498 (allocate_plt_and_got_and_discard_relocs): Likewise.
1499 * elf32-hppa.c (elf_i386_relocate_section): Likewise.
1500 (allocate_plt_and_got_and_discard_relocs): Likewise.
1502 2001-09-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1504 * elf32-mips.c (mips_elf_calculate_relocation): Fix overflow handling
1507 2001-09-06 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1509 * elf64-mips.c (mips_elf64_howto_table_rel): Fix relocation HOWTO
1511 (mips_elf64_howto_table_rel): Likewise.
1513 2001-09-05 Tom Rix <trix@redhat.com>
1515 * xcofflink.c (bfd_xcoff_import_symbol): Handle import file XMC_XO
1516 and syscall symbols.
1517 (write_global_symbol) : Same.
1518 (bfd_xcoff_export_symbol): Remove unused syscall param.
1519 * libxcoff.h: Change prototype of bfd_xcoff_export symbol and
1520 bfd_xcoff_import_symbol.
1522 * bfd-in2.h : Regenerate.
1524 2001-09-04 Richard Henderson <rth@redhat.com>
1526 * elf64-alpha.c (SKIP_HOWTO): New.
1527 (elf64_alpha_howto_table): Use it to remove dead ECOFF relocs.
1528 Fix sizes of 16-bit mem format relocs.
1529 (elf64_alpha_reloc_map): Update to match.
1530 (elf64_alpha_relax_with_lituse): Use GPREL16 as appropriate.
1531 (elf64_alpha_relax_without_lituse): Likewise.
1532 (elf64_alpha_check_relocs): Handle GPREL16.
1533 (elf64_alpha_relocate_section): Likewise.
1534 * reloc.c (BFD_RELOC_ALPHA_USER_*): Remove.
1535 (BFD_RELOC_ALPHA_GPREL_HI16, BFD_RELOC_ALPHA_GPREL_LO16): New.
1536 * bfd-in2.h, libbfd.h: Rebuild.
1538 2001-09-04 Jeff Law <law@redhat.com>
1540 * elf32-h8300.c (elf32_h8_relax_section): New function.
1541 (elf32_h8_relax_delete_bytes): Likewise.
1542 (elf32_h8_symbol_address_p): Likewise.
1543 (elf32_h8_get_relocated_section_contents): Likewise.
1544 (bfd_elf32_bfd_relax_section): Define.
1545 (bfd_elf32_bfd_get_relocated_section_contents): Likewise.
1547 * elf32-h8300.c (special): New function.
1548 (h8_elf_howto_table): Use it for SPECIAL_FUNCTION field in
1550 (elf32_h8_final_link_relocate): Treat R_H8_DIR24A8 like 32bit
1551 relocations. Fix problems with the true 24bit reloc R_H8_DIR24R8.
1552 Fix minor problems with 8bit and 16bit PC relative relocations.
1554 2001-09-01 Andreas Jaeger <aj@suse.de>
1556 * vms-tir.c: Add missing prototypes.
1557 * vms-hdr.c: Likewise.
1558 * vms-gsd.c: Likewise.
1559 * vms-misc.c: Likewise.
1561 2001-08-31 H.J. Lu <hjl@gnu.org>
1563 * elf32-mips.c (_bfd_mips_elf_check_relocs): Report filename
1564 with bad relocation.
1566 2001-08-31 Eric Christopher <echristo@redhat.com>
1567 Jason Eckhardt <jle@redhat.com>
1569 * bfd/archures.c: Add mipsisa32 and mipsisa64. Remove mips32,
1570 mips32_4k and mips64.
1571 * bfd/aoutx.h: Remove bfd_mach_mips32, bfd_mach_mips32_4k,
1572 bfd_mach_mips64. Add bfd_mach_mipsisa32, bfd_mach_mipsisa64.
1573 * bfd/cpu-mips.c: Ditto.
1574 * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing): Ditto.
1575 * bfd/bfd-in2.h: Regenerate.
1577 2001-08-31 Jakub Jelinek <jakub@redhat.com>
1579 * elf64-alpha.c (elf64_alpha_relocate_section): Duplicate memory
1580 value into R_ALPHA_RELATIVE's addend.
1581 (elf64_alpha_finish_dynamic_symbol): Likewise.
1583 2001-08-31 Nick Clifton <nickc@cambridge.redhat.com>
1585 * elf32-arm.h (elf32_arm_relocate_section): Do not rightshift
1586 recomputed addend during relocatable link if not USE_REL.
1588 * elflink.h (elf_gc_propagate_vtable_entries_used): Fix off-by-one
1591 2001-08-30 H.J. Lu <hjl@gnu.org>
1593 * elf32-mips.c (mips_elf_calculate_relocation): Revert the last
1595 (_bfd_mips_elf_adjust_dynamic_symbol): Allocate dynamic
1596 relocations for weak definitions.
1598 2001-08-30 H.J. Lu <hjl@gnu.org>
1600 * Makefile.am (BFD32_BACKENDS): Add elf32-h8300.lo.
1601 (BFD32_BACKENDS_CFILES): Add elf32-h8300.c.
1602 * Makefile.in: Rebuild.
1604 2001-08-30 H.J. Lu <hjl@gnu.org>
1606 * elf32-mips.c (mips_elf_calculate_relocation): Don't create
1607 dynamic relocation for undefined weak symbols when creating
1608 executables. Check h->root.root.type, instead of h->root.type.
1610 2001-08-29 Joel Sherrill <joel@OARcorp.com>
1612 * config.bfd (i[3456]86-*-rtems*, m68*-*-rtems*): Change
1613 default from coff to elf.
1615 2001-08-29 Jeff Law <law@redhat.com>
1617 * elf32-h8300.c (h8_elf_howto_table): Add new PC relative
1619 (h8_reloc_map): Similarly.
1620 (elf32_h8_final_link_relocate): Remove incorrect overflow tests.
1621 Add support for PC relative relocations.
1623 * elf32-h8300.c: Put all prototypes together.
1624 (elf32_h8_info_to_howto): Parameter elf_reloc is used.
1625 (elf32_h8_final_link_relocate): New function for linker.
1626 (elf32_h8_relocate_section): Similarly.
1627 (elf_backend_relocate_section): Define.
1629 * cpu-h8300.c (h8300_scan, compatible): Prototype.
1630 (h8300_scan): Handle architecture:machine encodings typically
1631 found in linker scripts.
1632 * elf.c (prep_headers): Do not try to do H8 machine recognition
1634 * elf32-h8300.c: Add some missing prototypes.
1635 (elf32_h8_mach, elf32_h8_final_write_processing): New functions.
1636 (elf32_h8_object_p): Similarly.
1638 2001-08-29 Tom Rix <trix@redhat.com>
1640 * xcofflink.c (xcoff_link_add_symbols): Fix XTY_LD symbol that
1641 does not follow a XTY_SD.
1643 2001-08-29 Alan Modra <amodra@bigpond.net.au>
1645 * targmatch.sed: Delete case statements.
1646 * config.bfd <powerpc-*-aix* entry>: Select 64 bit xcoff for
1649 Wed Aug 29 02:27:36 2001 J"orn Rennecke <amylaar@redhat.com>
1651 * Makefile.am (elf32-h8300.lo): New target.
1652 * config.bfd (h8300*-*-elf): New case.
1653 * configure.in (bfd_elf32_h8300_vec): New case.
1654 * elf.c (prep_headers): Add case for bfd_arch_h8300.
1655 * reloc.c (BFD_RELOC_H8_DIR16A8): New relocation.
1656 (BFD_RELOC_H8_DIR16R8, BFD_RELOC_H8_DIR24A8): Likewise.
1657 (BFD_RELOC_H8_DIR24R8, BFD_RELOC_H8_DIR32A16): Likewise.
1658 * targets.c (bfd_target bfd_elf32_h8300_vec): New extern declaration.
1659 * elf32-h8300.c: New file.
1660 * Makefile.in, bfd-in2.h, libbfd.h, configure: Regenerated.
1662 2001-08-28 Nick Clifton <nickc@cambridge.redhat.com>
1664 * sparclynx.c: Add missing prototypes.
1665 * coff-mcore.c: Add missing prototypes.
1666 * elf32-pj.c: Add missing prototypes.
1667 * nlm32-sparc.c: Add missing prototypes.
1668 * oasys.c: Add missing prototypes.
1669 * pdp11.c: Add missing prototypes.
1670 * pe-mips.c: Add missing prototypes.
1671 * riscix.c: Add missing prototypes.
1673 2001-08-27 Daniel Jacobowitz <drow@mvista.com>
1675 * elf32-i386.c: Add missing prototypes.
1676 * elf32-ppc.c: Likewise.
1677 * elf32-sh-lin.c: Likewise.
1678 * elfarm-nabi.c: Likewise.
1680 2001-08-27 Daniel Jacobowitz <drow@mvista.com>
1682 * elf32-i386.c (elf_i386_grok_prstatus): New function.
1683 (elf_i386_grok_psinfo): New function.
1684 (elf_backend_grok_prstatus): Define.
1685 (elf_backend_grok_psinfo): Likewise.
1686 * elf32-ppc.c (ppc_elf_grok_prstatus): New function.
1687 (ppc_elf_grok_psinfo): New function.
1688 (elf_backend_grok_prstatus): Define.
1689 (elf_backend_grok_psinfo): Likewise.
1690 * elf32-sh-lin.c (elf32_shlin_grok_prstatus): New function.
1691 (elf32_shlin_grok_psinfo): New function.
1692 (elf_backend_grok_prstatus): Define.
1693 (elf_backend_grok_psinfo): Likewise.
1694 * elfarm-nabi.c (elf32_arm_nabi_grok_prstatus): New function.
1695 (elf32_arm_nabi_grok_psinfo): New function.
1696 (elf_backend_grok_prstatus): Define.
1697 (elf_backend_grok_psinfo): Likewise.
1699 2001-08-27 H.J. Lu <hjl@gnu.org>
1701 * elf32-mips.c (mips_elf_create_dynamic_relocation): Add more
1703 (mips_elf_calculate_relocation): Create dynamic relocation for
1704 symbols with weak definition or the ELF_LINK_HASH_DEF_REGULAR
1707 2001-08-27 H.J. Lu <hjl@gnu.org>
1709 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Add prototype.
1710 (_bfd_mips_elf_copy_indirect_symbol): Likewise.
1711 (_bfd_elf32_mips_grok_prstatus): Likewise.
1712 (_bfd_elf32_mips_grok_psinfo): Likewise.
1713 (_bfd_mips_elf_hide_symbol): Make it static and cast to
1714 `struct mips_elf_link_hash_entry *'.
1715 (_bfd_mips_elf_copy_indirect_symbol): Make it static.
1717 2001-08-27 Nick Clifton <nickc@cambridge.redhat.com>
1719 * mipsbsd.c: Add missing prototypes.
1720 * hp300hpux.c: Add missing prototypes.
1721 * i386aout.c: Add missing prototypes.
1722 * i386lynx.c: Add missing prototypes.
1723 * i386mach3.c: Add missing prototypes.
1724 * i386msdos.c: Add missing prototypes.
1725 * i386os9k.c: Add missing prototypes.
1727 2001-08-27 Linus Nordberg <linus@swox.se>
1728 Torbjorn Granlund <tege@swox.com>
1729 Staffan Ulfberg <staffanu@swox.se>
1730 Alan Modra <amodra@bigpond.net.au>
1732 * config.bfd: Add powerpc64 target. Add powerpc64 vectors to
1733 targ64_selvecs for 32 bit powerpc targets.
1734 * Makefile.am (BFD64_BACKENDS): Add elf64-ppc.lo.
1735 (BFD64_BACKENDS_CFILES): Add elf64-ppc.c.
1737 * Makefile.in: Regenerate.
1738 * configure.in: Add elf64_powerpc vecs.
1739 * configure: Regenerate.
1740 * cpu-powerpc.c: Default to bfd_mach_ppc_620 entry for 64 bit.
1741 * elf.c (prep_headers): EM_PPC64 for 64 bit ppc elf target.
1742 * targets.c: Add bfd_elf64_powerpc_vec and bfd_elf64_powerpcle_vec.
1743 * elf64-ppc.c: New file.
1744 * reloc.c: Add powerpc64 relocs.
1745 * libbfd.h: Regenerate.
1746 * bfd-in2.h: Regenerate.
1748 2001-08-27 Andreas Schwab <schwab@suse.de>
1750 * elf32-m68k.c (elf32_m68k_check_relocs): Set DF_TEXTREL if the
1751 reloc is against read-only section.
1752 (elf32_m68k_size_dynamic_sections): Use DF_TEXTREL flag instead of
1753 looking up section names for DT_TEXTREL.
1754 (elf32_m68k_reloc_type_class): New function.
1755 (elf_backend_reloc_type_class): Define.
1757 2001-08-27 Andreas Jaeger <aj@suse.de>
1759 * elf64-s390.c (elf_s390_check_relocs): Set DF_TEXTREL if the
1760 reloc is against read-only section.
1761 (elf_s390_size_dynamic_sections): Use DF_TEXTREL flag instead of
1762 looking up section names for DT_TEXTREL.
1763 (elf_s390_reloc_type_class): New.
1764 (elf_backend_reloc_type_class): Define.
1766 * elf32-s390.c (elf_s390_check_relocs): Set DF_TEXTREL if the
1767 reloc is against read-only section.
1768 (elf_s390_size_dynamic_sections): Use DF_TEXTREL flag instead of
1769 looking up section names for DT_TEXTREL.
1770 (elf_s390_reloc_type_class): New.
1771 (elf_backend_reloc_type_class): Define.
1773 * elf32-ppc.c (ppc_elf_check_relocs): Set DF_TEXTREL if the reloc
1774 is against read-only section.
1775 (ppc_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
1776 looking up section names for DT_TEXTREL.
1777 (ppc_elf_reloc_type_class): New.
1778 (elf_backend_reloc_type_class): Define.
1780 2001-08-26 Andreas Jaeger <aj@suse.de>
1782 * elf32-cris.c (cris_elf_check_relocs): Set DF_TEXTREL if the
1783 reloc is against read-only section.
1784 (elf_cris_size_dynamic_sections): Use DF_TEXTREL flag instead of
1785 looking up section names for DT_TEXTREL.
1786 (elf_cris_reloc_type_class): New.
1787 (elf_backend_reloc_type_class): Define.
1789 * elf32-sh.c (sh_elf_check_relocs): Set DF_TEXTREL if the reloc is
1790 against read-only section.
1791 (elf_backend_reloc_type_class): Define.
1792 (sh_elf_reloc_type_class): New.
1793 (sh_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
1794 looking up section names for DT_TEXTREL.
1796 * elf32-arm.h (elf32_arm_check_relocs): Set DF_TEXTREL if the
1797 reloc is against read-only section.
1798 (elf32_arm_size_dynamic_sections): Use DF_TEXTREL flag instead of
1799 looking up section names for DT_TEXTREL.
1800 (elf32_arm_reloc_type_class): New.
1801 (elf_backend_reloc_type_class): Define.
1803 2001-08-25 Andreas Jaeger <aj@suse.de>
1805 * oasys.c: Add missing prototypes.
1807 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Add unused
1808 attribute for parameter.
1809 * elf.c (_bfd_elf_reloc_type_class): Likewise.
1811 * versados.c (get_4): Make static.
1812 (get_10): Make static.
1813 Add missing prototypes.
1814 (process_esd): Fix call to versados_new_symbol.
1816 2001-08-25 Nick Clifton <nickc@cambridge.redhat.com>
1818 * coff-a29k.c: Add missing prototypes.
1819 * coff-apollo.c: Add missing prototypes.
1820 * coff-arm.c: Add missing prototypes.
1821 * coff-i860.c: Add missing prototypes.
1822 * coff-rs6000.c: Add missing prototypes.
1823 * coff-tic80.c: Add missing prototypes.
1824 * elf-m10200.c: Add missing prototypes.
1825 * elf-m10300.c: Add missing prototypes.
1826 * elf32-arm.h: Add missing prototypes.
1827 * elf32-d10v.c: Add missing prototypes.
1828 * elf32-m32r.c: Add missing prototypes.
1829 * elf32-mcore.c: Add missing prototypes.
1830 * elf32-openrisc.c: Add missing prototypes.
1831 * elf32-sh.c: Add missing prototypes.
1832 * elf32-sparc.c: Add missing prototypes.
1833 * elf32-v850.c: Add missing prototypes.
1834 * elfarm-nabi.c: Add missing prototypes.
1835 * elfarm-oabi.c: Add missing prototypes.
1837 2001-08-25 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1839 * elf32-mips.c (elf_mips_abi_name): Return the right ABI string for
1840 E_MIPS_ABI_O64 and E_MIPS_ABI_EABI64
1842 2001-08-24 H.J. Lu <hjl@gnu.org>
1844 * elf.c (_bfd_elf_merge_sections): Fail if not using an ELF
1847 2001-08-24 Nick Clifton <nickc@cambridge.redhat.com>
1849 * elf-bfd.h (elf_hash_table): Revert definition.
1850 (is_elf_hash_table): New macro.
1851 * elflink.h (elf_link_add_object_symbols): Test
1852 is_elf_hash_table before accessing ELF only fields in hash
1854 (elf_link_create_dynamic_sections): Fail if not using an ELF
1856 (elf_add_dynamic_entry): Fail if not using an ELF hash
1858 (elf_link_record_local_dynamic_symbol): Fail if not using an
1860 (size_dynamic_sections): Fail if not using an ELF hash
1862 (elf_adjust_dynamic_symbol): Fail if not using an ELF
1864 (elf_bfd_final_link): Fail if not using an ELF hash
1867 2001-08-24 H.J. Lu <hjl@gnu.org>
1869 * elf-bfd.h (elf_hash_table): Return NULL if the linker hash
1870 table is not an ELF linker hash table.
1872 * elf.c (_bfd_elf_link_hash_table_init): Set the linker hash
1873 table type to bfd_link_elf_hash_table.
1875 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_create): Revert
1878 * linker.c (_bfd_link_hash_table_init): Set the linker hash
1879 table type to bfd_link_generic_hash_table.
1881 2001-08-24 Alexandre Oliva <aoliva@redhat.com>
1883 * bfd.c (bfd_alt_mach_code): New function.
1884 * bfd-in2.h: Rebuilt.
1886 2001-08-24 Alexandre Oliva <aoliva@redhat.com>
1888 * elf-m10300.c (mn10300_elf_relocate_section): Test the right
1889 `type' field in the hash entry when deciding whether to follow a
1892 2001-08-24 Jakub Jelinek <jakub@redhat.com>
1894 * elflink.h (elf_link_sort_cmp1): Sort RELATIVE relocs first, not
1896 (elf_link_sort_relocs): Adjust accordingly.
1898 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Add reltext flag.
1899 (elf64_alpha_check_relocs): Set it if section this reloc is against
1900 is read-only. Set DF_TEXTREL if a RELATIVE reloc is needed against
1902 (elf64_alpha_calc_dynrel_sizes): Set DF_TEXTREL flag if relocation
1903 is is against read-only section.
1904 (elf64_alpha_size_dynamic_sections): Use DF_TEXTREL flag, don't
1905 check section names.
1906 (elf64_alpha_reloc_type_class): New.
1907 (elf_backend_reloc_type_class): Define.
1909 2001-08-24 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1911 * linker.c (_bfd_generic_link_add_archive_symbols): Replace alloca()
1914 2001-08-23 Andreas Jaeger <aj@suse.de>
1916 * elf64-x86-64.c (elf64_x86_64_check_relocs): Set DF_TEXTREL if
1917 the reloc is against read-only section.
1918 (elf64_x86_64_size_dynamic_sections): Use DF_TEXTREL flag instead
1919 of looking up section names for DT_TEXTREL.
1920 (elf64_x86_64_reloc_type_class): New.
1921 (elf_backend_reloc_type_class): Define.
1923 2001-08-23 H.J. Lu <hjl@gnu.org>
1925 * syms.c (bfd_print_symbol_vandf): Add abfd to arg.
1926 * bfd-in2.h (bfd_print_symbol_vandf): Regenerated.
1928 * aoutx.h (NAME(aout,print_symbol)): Pass abfd to
1929 bfd_print_symbol_vandf.
1930 * coffgen.c (coff_print_symbol): Likewise.
1931 * elf.c (bfd_elf_print_symbol): Likewise.
1932 * ieee.c (ieee_print_symbol): Likewise.
1933 * nlmcode.h (nlm_print_symbol): Likewise.
1934 * oasys.c (oasys_print_symbol): Likewise.
1935 * pdp11.c (NAME(aout,print_symbol)): Likewise.
1936 * som.c (som_print_symbol): Likewise.
1937 * srec.c (srec_print_symbol): Likewise.
1938 * tekhex.c (tekhex_print_symbol): Likewise.
1939 * versados.c (versados_print_symbol): Likewise.
1940 * vms.c (vms_print_symbol): Likewise.
1942 * elf.c (_bfd_elf_print_private_bfd_data): Replace fprintf_vma
1943 with bfd_fprintf_vma.
1944 (bfd_elf_print_symbol): Likewise.
1945 * syms.c (bfd_print_symbol_vandf): Likewise.
1947 2001-08-23 Nick Clifton <nickc@cambridge.redhat.com>
1949 * aoutf1.h (sunos_write_object_contents): Silence compile time
1951 * libaout.h (N_SET_DYNAMIC): Silence compile time warning.
1953 * bout.c: Add missing function prototypes. Fix formatting.
1954 * coff-z8k.c: Add missing function prototypes. Fix formatting.
1955 * coff-w65.c: Add missing function prototypes. Fix formatting.
1956 * coff-h8500.c: Add missing function prototypes. Fix formatting.
1957 * coff-h8300.c: Add missing function prototypes. Fix formatting.
1958 * coff-tic54x.c: Add missing function prototypes. Fix formatting.
1959 * coff-tic30.c: Add missing function prototypes. Fix formatting.
1960 * coff-m68k.c: Add missing function prototypes. Fix formatting.
1961 * coff-rs6000.c: Add missing function prototypes. Fix formatting.
1962 * coff-sh.c: Add missing function prototypes. Fix formatting.
1964 2001-08-23 Jakub Jelinek <jakub@redhat.com>
1966 * elf-bfd.h (enum elf_reloc_type_class): New.
1967 (struct elf_backend_data): Add elf_backend_reloc_type_class.
1968 (_bfd_elf_reloc_type_class): New.
1969 * elfxx-target.h (elf_backend_reloc_type_class): Define.
1970 (elfNN_bed): Add elf_backend_reloc_type_class.
1971 * elf.c (_bfd_elf_reloc_type_class): New.
1972 * elf32-i386.c (elf_i386_check_relocs): Set DF_TEXTREL if the reloc
1973 is against read-only section.
1974 (elf_i386_size_dynamic_sections): Use DF_TEXTREL flag instead of
1975 looking up section names for DT_TEXTREL.
1976 (elf_i386_reloc_type_class): New.
1977 (elf_backend_reloc_type_class): Define.
1978 * elf32-sparc.c (elf32_sparc_check_relocs): Set DF_TEXTREL if the
1979 reloc is against read-only section.
1980 (elf32_sparc_size_dynamic_sections): Use DF_TEXTREL flag instead of
1981 looking up section names for DT_TEXTREL.
1982 (elf32_sparc_reloc_type_class): New.
1983 (elf_backend_reloc_type_class): Define.
1984 * elf64-sparc.c (sparc64_elf_check_relocs): Set DF_TEXTREL if the
1985 reloc is against read-only section.
1986 (sparc64_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
1987 looking up section names for DT_TEXTREL.
1988 (sparc64_elf_reloc_type_class): New.
1989 (elf_backend_reloc_type_class): Define.
1990 * elfxx-ia64.c (struct elfNN_ia64_link_hash_table): Add reltext field.
1991 (elfNN_ia64_hash_table_create): Clear ia64_info.
1992 (get_reloc_section): Set DF_TEXTREL if the reloc is against read-only
1994 (elfNN_ia64_size_dynamic_sections): Use ia64_info->reltext flag
1995 instead of looking up section names for DT_TEXTREL.
1996 (elfNN_ia64_reloc_type_class): New.
1997 (elf_backend_reloc_type_class): Define.
1998 * elflink.h (size_dynamic_sections): Add spare DT_NULL tags.
1999 (struct elf_link_sort_rela): New.
2000 (elf_link_sort_cmp1, elf_link_sort_cmp2, elf_link_sort_relocs): New.
2001 (elf_bfd_final_link): Call elf_link_sort_relocs.
2002 Convert one spare DT_NULL into DT_RELCOUNT resp. DT_RELACOUNT if
2005 2001-08-23 Nick Clifton <nickc@cambridge.redhat.com>
2007 * configure.in (x86-bsdi): No corefile support.
2008 * configure: Regenerate.
2010 2001-08-22 Nick Clifton <nickc@cambridge.redhat.com>
2012 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Add missing
2015 2001-08-21 Mark Elbrecht <snowball3@bigfoot.com>
2017 * coff-go32.c: Make DWARF2 sections use an alignment of 0. Set
2018 the alignment of dwarf2 linkonce sections to 0.
2019 * coff-sto32.c: Likewise.
2021 2001-08-20 Andreas Jaeger <aj@suse.de>
2023 * coff-sparc.c: Add missing prototypes.
2024 * elf32-s390.c: Likewise.
2025 * elf32-i960.c: Likewise.
2026 * aout-target.h: Likewise.
2028 2001-08-20 H.J. Lu <hjl@gnu.org>
2030 * elf-bfd.h (elf_obj_tdata): Add num_section_syms.
2031 (elf_num_section_syms): New for num_section_syms.
2033 * elf.c (elf_map_symbols): Set num_section_syms.
2034 (_bfd_elf_symbol_from_bfd_symbol): Check num_section_syms for
2035 the section symbol index.
2037 2001-08-20 Nick Clifton <nickc@cambridge.redhat.com>
2039 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_create): Never
2040 select the generic has table creator. All elf backends need elf
2041 specific fields in the hash table.
2043 2001-08-20 Alan Modra <amodra@bigpond.net.au>
2045 * archive.c (offsetof): Remove define.
2048 * sysdep.h (offsetof): Define.
2050 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2052 * bfd.c (bfd_get_gp_size): Return an unsigned int.
2053 (bfd_set_gp_size): Make param unsigned.
2054 * bfd-in2.h: Regenerate.
2055 * elf32-ppc.c (ppc_elf_add_symbol_hook): Use elf_gp_size rather
2056 than calling bfd_get_gp_size.
2057 * elf64-alpha.c (elf64_alpha_add_symbol_hook): Likewise.
2058 * elfxx-ia64.c (elfNN_ia64_add_symbol_hook): Likewise.
2060 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2062 * linker.c (default_fill_link_order): Handle four byte fill value.
2064 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2066 * elf64-sparc.c (sparc64_elf_output_arch_syms): Add missing
2068 * nlm32-alpha.c (nlm_alpha_write_external): Fix warning.
2070 * elf64-mips.c (UNUSED_RELOC): Define.
2071 (mips_elf64_howto_table_rel): Use it.
2072 (mips_elf64_howto_table_rela): Here too.
2073 (mips_elf64_write_relocs): Fix signed/unsigned warning.
2075 * coffcode.h (coff_write_object_contents): Add ATTRIBUTE_UNUSED to
2077 * coffgen.c (coff_print_symbol): Fix warnings.
2078 (coff_find_nearest_line): Likewise.
2079 * cofflink.c (_bfd_coff_link_input_bfd): Likewise.
2080 * coff-alpha.c (alpha_convert_external_reloc): Likewise.
2081 * format.c (bfd_check_format_matches): Likewise.
2082 (bfd_set_format): Likewise.
2083 * coff-ia64.c: Add missing prototypes.
2084 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Make addend
2085 signed to silence warnings.
2086 (elf64_alpha_relocate_section): Likewise.
2087 (elf64_alpha_find_reloc_at_ofs): Fix warnings.
2088 (elf64_alpha_add_symbol_hook): Likewise.
2089 (elf64_alpha_final_link): Likewise.
2090 (elf64_alpha_relax_section): Remove redundant assign to info.gotent.
2091 (elf64_alpha_merge_gots): Add ATTRIBUTE_UNUSED to unused args.
2092 (elf64_alpha_size_got_sections): Likewise.
2093 * elfxx-ia64.c: Add missing prototypes.
2094 (elfNN_ia64_relocate_section): Fix warning.
2095 (elfNN_ia64_unwind_entry_compare): Make params const.
2097 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2099 * config.bfd (targ64_selvecs): New.
2100 <powerpc-*-aix* entry>: Use it here instead of ineffectual #ifdef.
2102 * bfd-in.h (BFD_VERSION): Remove wrong comment.
2103 (BFD_DEFAULT_TARGET_SIZE): New.
2104 (BFD_ARCH_SIZE): Comment.
2105 * configure.in (target_size): New. Set instead of target64 in
2106 selvecs case statement. Set target64 from it.
2107 (bfd_default_target_size): New. Set from taget_size. AC_SUBST.
2108 * bfd-in2.h: Regenerate.
2109 * configure: Regenerate.
2111 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2113 * bfd.c (enum bfd_error): Add bfd_error_wrong_object_format.
2114 (bfd_errmsgs): Add corresponding message.
2115 * archive.c (bfd_generic_archive_p): Don't release bfd_ardata when
2116 finding an archive that contains different format object files.
2117 Return bfd_error_wrong_object_format for this case.
2118 * format.c: Formatting fixes. s/CONST/const/.
2119 (bfd_check_format_matches): Accept archives that give
2120 bfd_error_wrong_object_format if no full match is found. Tidy
2121 code handling matching_vector. Don't return a pointer to freed
2122 memory in `matching'. Handle ambiguous matches as for partial
2124 * bfd-in2.h: Regenerate.
2126 2001-08-15 Alan Modra <amodra@bigpond.net.au>
2128 * libieee.h (common_header_type): Add last_byte field.
2130 * ieee.c: Add missing prototypes. Some format fixes.
2131 (struct output_buffer_struct): Move for availability to prototypes.
2132 (ieee_part_after): New function.
2133 (ieee_slurp_debug): Use it here.
2134 (ieee_seek): Pass in ieee_data_struct rather than bfd. Use
2135 ieee_part_after to set last_byte to one past end of current part.
2137 (ieee_pos): Pass in ieee_data_struct rather than bfd.
2139 (parse_expression): Don't go beyond the end of the current part.
2140 (ieee_slurp_external_symbols): Correct type passed to read_2bytes.
2141 (ieee_get_symtab_upper_bound, ieee_get_symtab,
2142 ieee_get_symbol_info, ieee_print_symbol, ieee_new_section_hook,
2143 ieee_get_reloc_upper_bound, ieee_canonicalize_reloc, block,
2144 ieee_set_section_contents, ieee_write_object_contents,
2145 ieee_make_empty_symbol): Make static.
2146 (ieee_archive_p): Correct comments regarding bfd_read.
2147 (ieee_object_p): Similarly.
2148 (ieee_mkobject): Move it. Clear output_ptr_start, output_ptr,
2149 output_ptr_end, input_ptr_start, input_ptr, input_ptr_end,
2150 input_bfd, output_bfd, output_buffer.
2151 (do_as_repeat): Write out ieee_set_current_pc_enum value as for
2152 do_with_relocs, ie. as a symbol for relocatable files.
2153 (ieee_vec): Add comments showing functions referenced by macros.
2155 2001-08-14 Nick Clifton <nickc@cambridge.redhat.com>
2157 * aout-tic30.c: Add missing prototypes. Fix formatting.
2158 * aout-ns32k.c: Add missing prototypes. Fix formatting.
2159 * peXXigen.c: Add missining prototypes. Fix formatting.
2160 * aout-adobe.c: Add missining prototypes. Fix formatting.
2162 2001-08-13 Nick Clifton <nickc@cambridge.redhat.com>
2164 * elf32-v850.c: Add missing function prototypes.
2165 Fix some formatting.
2167 * cpu-v850.c: Add missing function prototype.
2168 Fix some formatting.
2170 2001-08-11 Nick Clifton <nickc@cambridge.redhat.com>
2172 * elf-bfd.h (struct elf_backend_data): Add new fields
2173 'elf_backend_sprintf_vma' and 'elf_backend_fprintf_vma'.
2174 (bfd_elf_sprintf_vma): Rename function prototype to
2175 '_bfd_elf_sprintf_vma'.
2176 (bfd_elf_fprintf_vma): Rename function prototype to
2177 '_bfd_elf_fprintf_vma'.
2178 * bfd.c (bfd_sprintf_vma): Do not invoke bfd_elf_sprintf_vma
2179 directly, instead indirect via the elf_backend_data structure.
2180 (bfd_fprintf_vma): Do not invoke bfd_elf_fprintf_vma directly,
2181 instead indirect via the elf_backend_data structure.
2182 * elf.c (bfd_elf_sprintf_vma): Rename to _bfd_elf_sprintf_vma.
2183 (bfd_elf_fprintf_vma): Rename to _bfd_elf_fprintf_vma.
2184 * elfxx-target.h (elf_backend_sprintf_vma): Initialise if not
2186 (elf_backend_fprintf_vma): Initialise if not already defined.
2187 (struct elf_backend_data): Initialise the
2188 elf_backend_sprintf_vma and elf_backend_fprintf_vma fields.
2190 2001-08-10 Andreas Jaeger <aj@suse.de>
2192 * elf64-sparc.c: Add missing prototypes.
2193 * elf32-cris.c: Likewise.
2194 * elf32-i370.c: Likewise.
2195 * elf64-hppa.c: Likewise.
2196 * elf64-s390.c: Likewise.
2198 2001-08-10 Andreas Jaeger <aj@suse.de>
2200 * elf64-x86-64.c (elf64_x86_64_elf_object_p): Make static.
2201 Add prototypes where needed.
2203 2001-08-10 H.J. Lu <hjl@gnu.org>
2205 * bfd.c (bfd_sprintf_vma): Fix a typo in the last change.
2206 (bfd_fprintf_vma): Likewise.
2208 2001-08-10 H.J. Lu <hjl@gnu.org>
2210 * bfd.c (bfd_sprintf_vma): Don't return void.
2211 (bfd_fprintf_vma): Likewise.
2213 2001-08-10 Andreas Jaeger <aj@suse.de>
2215 * configure.in: Add -Wstrict-prototypes and -Wmissing-prototypes
2217 * configure: Regenerate.
2219 2001-08-10 Alan Modra <amodra@bigpond.net.au>
2221 * elf.c (bfd_elf_sprintf_vma): Add ATTRIBUTE_UNUSED to quiet
2222 warning if not BFD64. Add braces so emacs auto format works.
2223 (bfd_elf_fprintf_vma): Likewise.
2225 * libxcoff.h (struct xcoff_backend_data_rec): Constify src param
2227 * coff-rs6000.c (xcoff_swap_ldhdr_in): Modify type of external
2228 param to agree with libxcoff.h.
2229 (xcoff_swap_ldhdr_out): Likewise.
2230 (xcoff_swap_ldsym_in): Likewise.
2231 (xcoff_swap_ldsym_out): Likewise.
2232 (xcoff_swap_ldrel_in): Likewise.
2233 (xcoff_swap_ldrel_out): Likewise.
2234 (xcoff_create_csect_from_smclas): Likewise.
2235 * coff64-rs6000.c: Add missing prototypes.
2236 (xcoff64_swap_ldhdr_in): Modify type of external param to agree
2238 (xcoff64_swap_ldhdr_out): Likewise.
2239 (xcoff64_swap_ldsym_in): Likewise.
2240 (xcoff64_swap_ldsym_out): Likewise.
2241 (xcoff64_swap_ldrel_in): Likewise.
2242 (xcoff64_swap_ldrel_out): Likewise.
2243 (xcoff64_ppc_relocate_section): Make static.
2244 (xcoff64_slurp_armap): Likewise.
2245 (xcoff64_archive_p): Likewise.
2246 (xcoff64_openr_next_archived_file): Likewise.
2247 (xcoff64_sizeof_headers): Likewise.
2248 (xcoff64_is_lineno_count_overflow): Likewise.
2249 (xcoff64_is_reloc_count_overflow): Likewise.
2250 (xcoff64_loader_symbol_offset): Likewise.
2251 (xcoff64_loader_reloc_offset): Likewise.
2252 * elf64-gen.c: Add missing prototypes.
2254 2001-08-09 H.J. Lu <hjl@gnu.org>
2256 * elf.c (bfd_elf_sprintf_vma): Check ELFCLASS64 only in BFD64.
2257 (bfd_elf_fprintf_vma): Likewise.
2259 2001-08-09 H.J. Lu <hjl@gnu.org>
2261 * bfd-in.h (bfd_elf_sprintf_vma, bfd_elf_fprintf_vma): Moved
2264 * bfd-in2.h: Regenerated.
2266 2001-08-09 H.J. Lu <hjl@gnu.org>
2268 * bfd-in.h (bfd_sprintf_vma): New prototype.
2269 (bfd_fprintf_vma): Likewise.
2270 (bfd_elf_sprintf_vma): Likewise.
2271 (bfd_elf_fprintf_vma): Likewise.
2272 (bfd_printf_vma): New. Defined with bfd_fprintf_vma.
2273 * bfd-in2.h: Regenerated.
2275 * bfd.c (bfd_sprintf_vma): New. Defined.
2276 (bfd_fprintf_vma): Likewise.
2278 * elf.c (bfd_elf_sprintf_vma): New. Defined.
2279 (bfd_elf_fprintf_vma): Likewise.
2281 2001-08-09 Alan Modra <amodra@bigpond.net.au>
2283 * coff-rs6000.c: Add missing prototypes.
2284 (xcoff_ppc_relocate_section, xcoff_is_lineno_count_overflow,
2285 xcoff_is_reloc_count_overflow, xcoff_loader_symbol_offset,
2286 xcoff_loader_reloc_offset): Make static.
2287 * dwarf1.c: Add missing prototypes.
2288 * dwarf2.c: Add missing prototypes.
2289 (struct abbrev_info): Move definition.
2290 (struct attr_abbrev, ABBREV_HASH_SIZE, ATTR_ALLOC_CHUNK): Likewise.
2291 * elf.c: Add missing prototypes.
2292 * elf32-gen.c: Likewise.
2293 * elf32-i386.c: Likewise.
2294 * elf32-ppc.c: Likewise.
2295 (ppc_elf_sort_rela): Use PTR instead of "void *".
2296 * elflink.h: Add missing prototypes. Formatting fixes.
2297 * merge.c: Add missing prototypes.
2298 (last4_eq): Use PTR instead of "void *".
2299 (last_eq): Likewise.
2300 * syms.c: Add missing prototypes.
2302 2001-08-09 Nick Clifton <nickc@cambridge.redhat.com>
2304 * bfd.c: Fix formatting.
2305 * bfd-in2.h: Regenerate.
2307 2001-08-09 Nick Clifton <nickc@cambridge.redhat.com>
2309 * elf32-arc.c (R_ARC_B22_PCREL): Change 'partial_inplace' to
2310 true (this target uses REL relocations) and 'pcrel_offset' to
2311 false (the PC is implied, not stored in the offset).
2313 2001-08-08 Alan Modra <amodra@bigpond.net.au>
2315 1999-10-19 Linus Nordberg <linus@swox.se>
2316 * elf-bfd.h (struct elf_backend_data): Add want_got_sym.
2317 * elfxx-target.h (elf_backend_want_got_sym): Define.
2318 (elfNN_bed): Add elf_backend_want_got_sym.
2319 * elflink.c (_bfd_elf_create_got_section): Define
2320 _GLOBAL_OFFSET_TABLE_ only if bed->want_got_sym.
2322 2001-08-08 Alexandre Oliva <aoliva@redhat.com>
2324 * dwarf2.c (struct dwarf2_debug): Add sec, sec_info_ptr and syms.
2325 (find_rela_addend): New function.
2326 (parse_comp_unit): Call it to find the abbrev offset addend.
2327 (_bfd_dwarf2_find_nearest_line): Initialize and maintain the new
2328 members of dwarf2_debug as debugging information is read.
2330 2001-08-07 Nick Clifton <nickc@cambridge.redhat.com>
2332 * coff-sh.c (sh_coff_reloc_type_lookup): Provide for sh-coff
2333 targets as well as sh-pe.
2335 2001-08-03 Ben Harris <bjh21@netbsd.org>
2337 * elf32-arm.h (elf32_arm_final_link_relocate): Include offset of
2338 reloc from start of section when computing value for R_ARM_REL32
2341 2001-08-03 Alan Modra <amodra@bigpond.net.au>
2343 From H.J. Lu <hjl@gnu.org>
2344 * elf32-i386.c (allocate_plt_and_got_and_discard_relocs): Don't
2345 keep relocs for undefined syms if there are no dynamic sections in
2347 * elf32-hppa.c (allocate_plt_and_got_and_discard_relocs): Likewise.
2349 2001-08-02 Paul Sokolovsky <paul.sokolovsky@technologist.com>
2351 * cofflink.c (coff_link_check_ar_symbols): also search for
2352 __imp__symbol as well as _symbol.
2353 * linker.c (_bfd_generic_link_add_archive_symbols): also
2354 search for __imp__symbol as well as _symbol.
2356 2001-08-01 Adam Nemet <anemet@lnxw.com>
2358 * elf.c (elf_sort_sections): Return zero only as the last step.
2360 2001-08-01 Nick Clifton <nickc@cambridge.redhat.com>
2362 * config.bfd (arm-vxworks): Change name of define from VXWORKS to
2364 (arm-epoc-pe): Define ARM_COFF_BUGFIX.
2365 coff-arm.c (coff_arm_relocate_section): Replace VXWORKS with
2368 2001-07-30 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
2370 * libecoff.h (_bfd_ecoff_styp_to_sec_flags): Changed return type
2371 to match corresponding bfd_coff_backend data member.
2373 2001-07-24 Alan Modra <amodra@bigpond.net.au>
2375 * Makefile.am: Update dependencies with "make dep-am".
2376 * Makefile.in: Regenerate
2378 2001-07-15 H.J. Lu <hjl@gnu.org>
2380 * Makefile.am (po/SRC-POTFILES.in): Use tmp.src instead of tmp.
2381 (po/BLD-POTFILES.in): Use tmp.bld instead of tmp.
2382 * Makefile.in: Regenerate.
2384 2001-07-11 H.J. Lu <hjl@gnu.org>
2386 * elf64-alpha.c (elf64_alpha_check_relocs): Set the ALLOC|LOAD
2387 flags when creating the reloc section if the ALLOC flag in the
2388 source section is set.
2390 2001-07-11 Steve Ellcey <sje@cup.hp.com>
2392 * reloc.c (bfd_reloc_code_type): Add IA64 relocs
2393 BFD_RELOC_IA64_LTOFF_FPTR32MSB and BFD_RELOC_IA64_LTOFF_FPTR32LSB
2394 * bfd-in2.h: Regenerate.
2395 * libbfd.h: Regenerate.
2396 * elfxx-ia64.c (ia64_howto_table): Define how to handle
2398 (elfNN_ia64_reloc_type_lookup): Handle new relocations.
2399 (elfNN_ia64_check_relocs): Likewise.
2400 (elfNN_ia64_install_value): Likewise.
2401 (elfNN_ia64_relocate_section): Likewise.
2403 2001-07-11 Jakub Jelinek <jakub@redhat.com>
2405 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Remove support for
2407 (elf32_sparc_check_relocs): Likewise.
2408 Only create .rela section for alloced sections in shared libraries.
2409 (elf32_sparc_relocate_section): Likewise.
2410 Remove redundant check.
2411 Optimize unaligned reloc usage.
2412 * elf64-sparc.c (sparc64_elf_relocate_section): Remove redundant
2415 2001-07-11 H.J. Lu <hjl@gnu.org>
2417 * elf64-alpha.c (elf64_alpha_check_relocs): Only use the same
2418 ALLOC|LOAD flags as the source section for debugging sections
2419 when creating the reloc section.
2421 2001-07-05 Jim Wilson <wilson@redhat.com>
2423 * linker.c (_bfd_generic_link_add_one_symbol, case BIG): Use
2424 the section of the bigger symbol.
2426 * syms.c (bfd_is_local_label): Return false if BSF_SECTION_SYM.
2428 2001-07-05 Nick Clifton <nickc@cambridge.redhat.com>
2430 * peicode.h (coff_swap_scnhdr_in): For sections containing
2431 uninitialised data, only set their size to s_paddr if this does
2432 not reset their size to zero. MS's latest compilers will set
2435 2001-07-04 H.J. Lu <hjl@gnu.org>
2437 * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing):
2438 Handle bfd_mach_mips4400, bfd_mach_mips4600 and
2441 2001-07-03 Mark Elbrecht <snowball3@softhome.net>
2443 * bfd.c (bfd_get_sign_extend_vma): Support DJGPP COFF targets.
2445 * cofflink.c (_bfd_coff_link_input_bfd): Skip section symbols from
2446 sections being discarded.
2448 2001-06-30 Alan Modra <amodra@bigpond.net.au>
2450 * elfcore.h (elf_core_file_p): Call bfd_section_from_phdr directly
2451 instead of _bfd_elfcore_section_from_phdr.
2452 * elf-bfd.h (_bfd_elfcore_section_from_phdr): Remove.
2453 * elf.c (_bfd_elfcore_section_from_phdr): Remove.
2454 (_bfd_elfcore_make_pseudosection): Expedite tail-call.
2455 (elfcore_grok_prstatus): Likewise.
2456 (elfcore_grok_lwpstatus): Likewise.
2457 (bfd_get_elf_phdr_upper_bound): Likewise.
2458 (elfcore_make_note_pseudosection): Formatting.
2459 (_bfd_elfcore_strndup): Formatting.
2460 * elf32-mips.c (mips_elf_sym_is_global): Formatting.
2461 (_bfd_elf32_mips_grok_prstatus): Expedite tail-call.
2463 2001-06-29 Daniel Jacobowitz <drow@mvista.com>
2465 * elf-bfd.h: Add prototypes for _bfd_elfcore_make_pseudosection
2466 and _bfd_elfcore_strndup.
2467 (struct elf_backend_data): Add elf_backend_grok_prstatus
2468 and elf_backend_grok_psinfo.
2469 * elf.c (_bfd_elfcore_make_pseudosection): New function.
2470 (elfcore_grok_prstatus): Use it.
2471 (elfcore_make_note_pseudosection): Likewise.
2472 (elfcore_strndup): Rename to...
2473 (_bfd_elfcore_strndup): Here, and make global.
2474 (elfcore_grok_psinfo): Use _bfd_elfcore_strndup.
2475 (elfcore_grok_note): Call elf_backend_grok_prstatus
2476 and elf_backend_grok_psinfo if available.
2477 * elf32-mips.c (_bfd_elf32_mips_grok_prstatus): New function.
2478 (_bfd_elf32_mips_grok_psinfo): New function.
2479 (elf_backend_grok_prstatus): Define.
2480 (elf_backend_grok_psinfo): Define.
2481 * elfxx-target.h (elf_backend_grok_prstatus): Default to NULL.
2482 (elf_backend_grok_psinfo): Likewise.
2483 (elfNN_bed): Include elf_backend_grok_prstatus and
2484 elf_backend_grok_psinfo.
2486 2001-06-29 H.J. Lu <hjl@gnu.org>
2488 * elf32-hppa.c (elf32_hppa_finish_dynamic_sections): Check if
2489 hplink->sgot is NULL before filling GOT. Check if hplink->splt
2490 is NULL before filling PLT.
2492 2001-06-29 Alan Modra <amodra@bigpond.net.au>
2494 * elflink.h (elf_link_output_extsym): Revert 1999-04-10.
2496 2001-06-27 Alan Modra <amodra@bigpond.net.au>
2498 * elf32-hppa.c (elf32_hppa_check_relocs): Don't make syms dynamic
2500 (elf32_hppa_adjust_dynamic_symbol): ..nor here..
2501 (allocate_plt_and_got_and_discard_relocs): .. instead do so here
2504 * elf32-hppa.c (RELATIVE_DYNAMIC_RELOCS): Delete.
2505 (IS_ABSOLUTE_RELOC): Define.
2506 (elf32_hppa_link_hash_entry): Always include reloc_entries field.
2507 (hppa_link_hash_newfunc): Always init it.
2508 (elf32_hppa_check_relocs): Mark symbols as ELF_LINK_NON_GOT_REF to
2509 create COPY relocs only when the reloc is in a read-only section.
2510 Instead, allocate space for a dynamic reloc to reference the
2511 library symbol directly. Keep track of space we allocate using
2513 (hppa_discard_copies): Delete, and move code to..
2514 (allocate_plt_and_got): ..here. Rename to
2515 allocate_plt_and_got_and_discard_relocs. Remove unneeded dynamic
2516 relocs for non-shared link.
2517 (elf32_hppa_size_dynamic_sections): Update calls to above.
2518 (elf32_hppa_relocate_section): Write out the dynamic relocs used
2519 in lieu of COPY relocs.
2521 * elf32-i386.c (elf_i386_check_relocs): Don't make syms dynamic
2523 (elf_i386_adjust_dynamic_symbol): ..nor here..
2524 (allocate_plt_and_got_and_discard_relocs): .. instead do so here
2526 (elf_i386_size_dynamic_sections): Fix a comment.
2527 (elf_i386_relocate_section <R_386_32, R_386_PC32>): Rearrange code
2528 involved in writing reloc out.
2530 2001-06-25 Alan Modra <amodra@bigpond.net.au>
2532 * elf32-i386.c (elf_i386_check_relocs <R_386_32, R_386_PC32>):
2533 Ensure syms are dynamic if we might be emitting a reloc.
2534 (allocate_plt_and_got_and_discard_relocs): Don't discard relocs
2535 for undefweak or undefined syms..
2536 (elf_i386_relocate_section <R_386_32, R_386_PC32>): .. and emit.
2538 * elf32-i386.c (allocate_plt_and_got_and_discard_relocs): Discard
2539 relocs without ELF_LINK_HASH_DEF_DYNAMIC set.
2540 (elf_i386_relocate_section <R_386_32, R_386_PC32>): Remove
2541 redundant bfd_link_hash_defined, bfd_link_hash_defweak test.
2543 2001-06-24 H.J. Lu <hjl@gnu.org>
2545 * cpu-i960.c (scan_960_mach): Don't modify const char *. Use
2546 strncasecmp/strcasecmp instead of strncmp/strcmp.
2548 2001-06-23 H.J. Lu <hjl@gnu.org>
2550 * elf32-i386.c (elf_i386_relocate_section <R_386_32, R_386_PC32>):
2551 Check ELF_LINK_HASH_DEF_DYNAMIC to see if a symbol is not defined
2552 in the regular object file and treat the weak definition as
2555 2001-06-23 Alan Modra <amodra@bigpond.net.au>
2557 * elf32-i386.c (elf_i386_relocate_section <R_386_GOT32>): Tighten
2558 unresolved_reloc test to exclude cases where we use "relocation"
2559 before setting it to point into the .got. Reinstate fudge for
2560 unresolved relocs in debugging sections.
2562 * elf32-i386.c (elf_i386_relocate_section): Replace ugly
2563 complicated tests for unresolvable relocs with a simple direct
2564 scheme using "unresolved_reloc" var.
2566 * elf32-i386.c (struct elf_i386_pcrel_relocs_copied): Rename to
2567 elf_i386_dyn_relocs. Update comment.
2568 (struct elf_i386_link_hash_entry): Rename pcrel_relocs_copied to
2570 (elf_i386_adjust_dynamic_symbol): Remove a BFD_ASSERT, change
2572 (allocate_plt_and_got_and_discard_relocs): Replace BFD_ASSERT with
2574 (elf_i386_size_dynamic_sections): Likewise.
2575 (elf_i386_finish_dynamic_symbol): Likewise.
2576 (elf_i386_finish_dynamic_sections): Likewise.
2577 (elf_i386_relocate_section): Likewise. Tidy R_386_GOT32 and error
2580 Avoid creating COPY relocs if possible.
2581 * elf32-i386.c (elf_i386_check_relocs): Tweak condition under
2582 which .got created. Mark symbols used by R_386_32 and R_386_PC32
2583 relocs as ELF_LINK_NON_GOT_REF to create COPY relocs only when the
2584 reloc is in a read-only section. Instead, allocate space for a
2585 dynamic reloc to reference the library symbol directly. Keep
2586 track of space we allocate using pcrel_relocs_copied.
2587 (discard_copies): Delete, and move code to ..
2588 (allocate_plt_and_got): ..here. Rename to
2589 allocate_plt_and_got_and_discard_relocs. Remove unneeded dynamic
2590 relocs for non-shared link.
2591 (elf_i386_size_dynamic_sections): Update calls to above functions.
2592 (elf_i386_relocate_section): Write out the dynamic relocs. Add
2593 more ugly logic to avoid "unresolvable relocation" error. Use
2594 htab shortcut in place of elf_hash_table macro.
2595 (elf_i386_finish_dynamic_sections): Allow that dynamic .got may
2596 not always be created now.
2598 2001-06-20 Bo Thorsen <bo@suse.co.uk>
2600 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix linking of
2603 2001-06-18 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2605 * configure.host (mips64-*-linux): Reformat.
2607 2001-06-21 Alan Modra <amodra@bigpond.net.au>
2609 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Always
2610 allocate local .got space. Use shortcuts from hash table for .got
2611 and .plt rather than comparing section names.
2612 (elf32_hppa_check_relocs): Use local_plt_refcounts var rather than
2613 adjusting index into local_got_refcounts to document what we are
2615 (elf32_hppa_relocate_section): Similarly for local_plt_offsets.
2616 Tidy .got and .plt error checking.
2618 2001-06-20 Catherine Moore <clm@redhat.com>
2620 * elf-bfd.h (struct elf_backend_data):
2621 elf_backend_emit_relocs: New field: Function for emitting
2623 elf_backend_count_relocs: New field: Function for determining
2624 the number of relocs to be emitted.
2625 * elfxx-target.h: Provide default (NULL) values for
2626 elf_backend_emit_relocs and elf_backend_count_relocs.
2627 * elflink.h (elf_link_size_reloc_section): Make the hash table
2628 big enough to hold the relocs counted by either reloc_count or
2630 (elf_bfd_final_link) emit_relocs: New boolean, set if relocs
2631 should be emitted, either because of a command line option
2632 stored in the info structure or because the target provides a
2633 special reloc emitting function.
2634 If the target provides a reloc counting function use it,
2635 unless performing a relocatable link or emitting all relocs.
2636 Also set the SEC_RELOC flag on any output section which will
2638 (elf_link_input_bfd): emit_relocs: New boolean, set if relocs
2639 should be emitted, either because of a command line option
2640 stored in the info structure or because the target provides a
2641 special reloc emitting function.
2642 If the target provides a reloc emitting function, use it,
2643 unless performing a relocatable link or emitting all relocs.
2645 2001-06-20 H.J. Lu <hjl@gnu.org>
2647 * elf32-i386.c (elf_i386_size_dynamic_sections): Always
2648 allocate local .got space.
2650 2001-06-19 Andreas Jaeger <aj@suse.de>
2652 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix creation of
2655 2001-06-18 Hans-Peter Nilsson <hp@axis.com>
2657 * elflink.h (struct elf_assign_sym_version_info): Remove member
2658 export_dynamic. All users changed to use info member.
2659 NAME(bfd_elf,size_dynamic_sections)): Remove parameter
2660 export_dynamic, instead use member in parameter info.
2661 * bfd-in.h (bfd_elf32_size_dynamic_sections,
2662 bfd_elf64_size_dynamic_sections): Update prototype.
2663 * bfd-in2.h: Regenerate.
2665 2001-06-18 H.J. Lu <hjl@gnu.org>
2667 * elflink.h (elf_info_failed): Add a new field, verdefs.
2668 (NAME(bfd_elf,size_dynamic_sections): Pass verdefs to
2670 (elf_export_symbol): Check eif->verdefs to decide if a symbol
2673 2001-06-17 H.J. Lu <hjl@gnu.org>
2675 * elf32-mips.c (mips_elf_link_hash_entry): Add a new field,
2676 readonly_reloc, to record if a relocation in the .rel.dyn
2677 section is against a read-only section.
2678 (mips_elf_link_hash_newfunc): Initialize the readonly_reloc
2680 (_bfd_mips_elf_check_relocs): Record if there is a relocation
2681 in the .rel.dyn section against a read-only section by setting
2682 DF_TEXTREL or readonly_reloc.
2683 (_bfd_mips_elf_copy_indirect_symbol): Copy readonly_reloc if
2685 (_bfd_mips_elf_adjust_dynamic_symbol): Record DF_TEXTREL if
2686 there is a relocation in the .rel.dyn section against a
2688 (_bfd_mips_elf_size_dynamic_sections): Set DT_TEXTREL if
2691 2001-06-12 Nick Clifton <nickc@cambridge.redhat.com>
2693 * coffcode.h (styp_flags_to_sec_flags): Change to a boolean
2694 function. Move flagword result into parameter list. Remove
2695 comment about setting bfd_error_handler to intercept failure
2697 * coffgen.c (make_a_section_from_file): Examine result of
2698 calling bfd_coff_styp_to_sec_flags and pass a failure back to
2700 * ecoff.h (styp_flags_to_sec_flags): Change to a boolean
2701 function. Move flagword result into parameter list.
2702 * libcoff.h: Regenerate.
2703 * libecoff.h: Regenerate.
2705 2001-06-13 Nick Clifton <nickc@cambridge.redhat.com>
2707 * aoutx.h (adjust_z_magic): Only pad the tesxt section if the data
2708 section is going to follow it.
2710 2001-06-12 Catherine Moore <clm@redhat.com>
2712 * elflink.h (elf_gc_propagate_vtable_entries): Replace FILE_ALIGN
2713 with the file_align entry from elf_backend_data.
2714 (elf_gc_smash_unused_vtentry_relocs): Likewise.
2715 (elf_gc_record_vtentry): Likewise.
2717 2001-06-10 Alan Modra <amodra@bigpond.net.au>
2719 * elflink.h: Whitespace changes.
2720 (elf_link_read_relocs_from_section): Use "unsigned int" iterator
2721 rather than "unsigned char".
2722 (elf_link_output_relocs): Likewise.
2723 (elf_link_input_bfd): Likewise.
2724 (elf_reloc_link_order): LIkewise.
2725 * elf.c: s/CONST/const/. Whitespace changes.
2726 * elf32-mips.c: Formatting fix.
2728 * Makefile.am (SOURCE_HFILES): Include xcoff-target.h, remove xcoff.h.
2729 * Makefile.in: Regenerate.
2730 * po/Make-in: Remove trailing tab.
2732 2001-06-09 Philip Blundell <philb@gnu.org>
2734 * elf32-arm.h (elf32_arm_plt0_entry): Correct error in last
2736 (elf32_arm_plt_entry): Likewise.
2738 2001-06-08 H.J. Lu <hjl@gnu.org>
2740 * elf.c (swap_out_syms): Keep names for global section symbols.
2742 2001-06-07 H.J. Lu <hjl@gnu.org>
2744 * config.bfd: Put back ecoff for Linux/mips. Firmwares on some
2745 MIPS-based machines need it.
2747 2001-06-07 H.J. Lu <hjl@gnu.org>
2749 * elf32-mips.c (_bfd_mips_elf_object_p): Set the bad symtab
2752 * config.bfd: Remove ecoff from Linux/mips.
2754 2001-06-07 Andreas Jaeger <aj@suse.de>
2756 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_symbol): Add an
2758 (elf64_x86_64_check_relocs): Fix VTENTRY relocation; set an
2759 alignment of 8 for .rela sections; handle further relocations.
2761 2001-06-06 Christian Groessler <cpg@aladdin.de>
2763 * coff-z8k.c: Fix formatting.
2764 Fix howtos: howto->size was always 1.
2766 2001-06-05 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2768 * configure.host (mips64*-*-linux*): Define.
2770 2001-06-05 Alan Modra <amodra@bigpond.net.au>
2772 * elf32-i386.c (elf_i386_discard_copies): Rename to
2773 discard_copies, and use elf_link_hash_entry arg rather than
2774 elf_i386_link_hash_entry.
2775 (elf_i386_link_hash_traverse): Delete.
2776 (elf_i386_size_dynamic_sections): Adjust call to discard_copies.
2777 Tidy sizing of dynamic sections.
2778 (elf_i386_check_relocs <R_386_32, R_386_PC32>): Reference count
2779 possible .plt entries.
2780 (elf_i386_gc_sweep_hook): Likewise.
2781 (elf_i386_adjust_dynamic_symbol): Discard .plt entries for
2782 everything with plt.refcount <= 0.
2784 * elf32-i386.c (elf_i386_check_relocs): Don't allocate .got and
2786 (elf_i386_gc_sweep_hook): ..and no need to deallocate here..
2787 (elf_i386_adjust_dynamic_symbol): ..and don't allocate .plt and
2789 (allocate_plt_and_got): ..instead do it all here. New function.
2790 (elf_i386_size_dynamic_sections): Allocate local .got space and
2791 call allocate_plt_and_got. No need to zap .relgot if not dynamic.
2792 (bfd_elf32_bfd_final_link): Delete. (ie. use regular final link
2793 rather than gc variety).
2794 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
2795 (elf_i386_relocate_section): Use it here and correct handling of
2796 R_386_GOT32. Provide section and offset for "unresolvable
2797 relocation" error message.
2798 (elf_i386_finish_dynamic_symbol): Correct handling of R_386_GOT32.
2800 * elf32-i386.c (struct elf_i386_link_hash_table): Add sgot,
2801 sgotplt, srelgot, splt, srelplt, sdynbss, srelbss fields.
2802 (elf_i386_link_hash_table_create): Init them.
2803 (create_got_section): New function.
2804 (elf_i386_create_dynamic_sections): New function.
2805 (elf_backend_create_dynamic_sections): Set to above.
2806 (elf_i386_check_relocs): Use shortcuts from hash table rather than
2807 calling bfd_get_section_by_name.
2808 (elf_i386_gc_sweep_hook): Likewise.
2809 (elf_i386_adjust_dynamic_symbol): Likewise.
2810 (elf_i386_size_dynamic_sections): Likewise.
2811 (elf_i386_relocate_section): Likewise.
2812 (elf_i386_finish_dynamic_sections): Likewise.
2814 * elf32-hppa.c (allocate_plt_and_got): Skip indirect and warning syms.
2816 2001-06-02 H.J. Lu <hjl@gnu.org>
2818 * elf32-hppa.c (elf32_hppa_object_p): Check ELFOSABI_LINUX
2820 * elf64-hppa.c (elf64_hppa_object_p): Likewise.
2822 2001-06-02 H.J. Lu <hjl@gnu.org>
2824 * aout-cris.c (MACHTYPE_OK): New. Defined.
2826 2001-06-02 Hans-Peter Nilsson <hp@axis.com>
2828 * section.c (_bfd_strip_section_from_output): Handle NULL
2831 2001-06-02 H.J. Lu <hjl@gnu.org>
2833 * config.bfd (powerpc-*-aix*, powerpc-*-beos*, rs6000-*-*): Add
2834 rs6000coff64_vec only if BFD64 is defined.
2835 (powerpc64-*-aix*): Enable only if BFD64 is defined.
2837 2001-06-02 H.J. Lu <hjl@gnu.org>
2839 * coff-ia64.c (ia64coff_object_p): Rewrite with
2840 external_PEI_DOS_hdr and external_PEI_IMAGE_hdr.
2842 2001-06-01 Andreas Jaeger <aj@suse.de>
2844 * elf64-x86-64.c (elf64_x86_64_relocate_section): Add PC8
2845 relocation, small reformatting.
2847 2001-05-29 Andreas Jaeger <aj@suse.de>
2849 * elf64-x86-64.c (elf64_x86_64_check_relocs): Handle R_X86_64_64.
2850 (elf64_x86_64_relocate_section): Likewise.
2852 2001-05-30 Alan Modra <amodra@one.net.au>
2854 * elf32-hppa.c (elf32_hppa_check_relocs): Don't NEED_PLT for
2855 millicode. Don't allocate .got and .rela.got space here..
2856 (elf32_hppa_gc_sweep_hook): ..and no need to deallocate here..
2857 (elf32_hppa_adjust_dynamic_symbol): ..and don't allocate .plt and
2859 (hppa_handle_PIC_calls): ..nor here..
2860 (allocate_plt_and_got): ..instead do it all here. New function.
2861 (elf32_hppa_size_dynamic_sections): Allocate local .got space and
2862 call allocate_plt_and_got. No need to zap .got if not dynamic.
2863 (elf32_hppa_final_link): Call regular bfd_final_link instead of
2864 gc_common_final_link.
2865 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
2866 (elf32_hppa_relocate_section): Use it here.
2867 (elf32_hppa_finish_dynamic_symbol): Remove superfluous test of
2868 dynamic_sections_created.
2869 (hppa_type_of_stub): Don't LONG_BRANCH_VIA_PLT if millicode sym.
2871 2001-05-28 Andreas Jaeger <aj@suse.de>
2873 * elf64-x86-64.c (elf64_86_64_size_info): Remove, we can use the
2874 generic version since we want a hashsize of 4.
2875 (elf_backend_size_info): Likewise.
2877 2001-05-28 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2879 * elflink.h (elf_link_size_reloc_section): Use bfd_zmalloc instead of
2881 (elf_link_output_relocs): Handle MIPS ELF64 relocations correctly.
2882 (elf_link_input_bfd): Likewise.
2883 (elf_reloc_link_order): Likewise.
2884 (elf_finish_pointer_linker_section): Typo. Handle MIPS ELF64
2885 relocations correctly.
2887 2001-05-28 Nicolas Pitre <nico@cam.org>
2889 * elf32-arm.h: fix PLT generation for big endian ARM
2891 2001-05-28 Alan Modra <amodra@one.net.au>
2893 * elf32-hppa.c (elf32_hppa_relocate_section): Set up .plt entries
2894 for symbols forced local that need plabels.
2895 (elf32_hppa_adjust_dynamic_symbol): Don't allocate space in
2896 .plt.rela for local syms if non-shared.
2897 (hppa_build_one_stub): Mask lsb of plt.offset.
2898 (elf32_hppa_finish_dynamic_symbol): Abort if lsb of plt.offset set.
2899 (clobber_millicode_symbols): Correct comment.
2900 (elf32_hppa_relocate_section): Likewise.
2901 (elf32_hppa_finish_dynamic_symbol): Likewise.
2903 2001-05-28 Jeff Sturm <jsturm@one-point.com>
2905 * reloc.c: Add BFD_RELOC_SPARC_UA16 and BFD_RELOC_SPARC_UA64.
2906 * bfd-in2.h: Regenerate.
2907 * libbfd.h: Regenerate.
2908 * elf32-sparc.c: Enable BFD_RELOC_SPARC_UA16, BFD_RELOC_SPARC_UA32
2909 and BFD_RELOC_SPARC_UA64 mapping
2910 * elf64-sparc.c: Likewise.
2912 2001-05-25 H.J. Lu <hjl@gnu.org>
2914 * Makefile.am (BFD32_BACKENDS): Remove coff-pmac.lo.
2915 (BFD32_BACKENDS_CFILES): Remove coff-pmac.c.
2916 (coff-rs6000.lo): Remove the old dependency.
2917 * Makefile.in: Rebuild.
2919 * configure.in (pmac_xcoff_vec): Replace coff-pmac.lo with
2922 2001-05-25 H.J. Lu <hjl@gnu.org>
2924 * coff-rs6000.c (rs6000coff_vec): Use rs6000coff_core_p,
2925 rs6000coff_core_file_matches_executable_p,
2926 rs6000coff_core_file_failing_command and
2927 rs6000coff_core_file_failing_signal only if AIX_CORE is
2929 (pmac_xcoff_vec): Likewise.
2930 * coff64-rs6000.c (rs6000coff64_vec): Likewise.
2932 2001-05-25 Timothy Wall <twall@redhat.com>
2934 * elfxx-ia64.c (allocate_dynrel_entries): Don't allocate an entry
2935 for __GLOB_DATA_PTR on AIX5. Clean up some relocation bugs.
2937 2001-05-25 H.J. Lu <hjl@gnu.org>
2939 * bfd-in2.h: Regenerated.
2940 * libcoff.h: Likewise.
2942 2001-05-25 Alan Modra <amodra@one.net.au>
2944 * elf32-hppa.c (elf32_hppa_relocate_section): Don't allow
2945 undefined millicode syms in shared libs.
2946 (hppa_build_one_stub): Turn BFD_ASSERTs into aborts.
2947 (elf32_hppa_check_relocs): Likewise.
2948 (elf32_hppa_adjust_dynamic_symbol): Likewise.
2949 (elf32_hppa_size_dynamic_sections): Likewise.
2950 (elf32_hppa_relocate_section): Likewise.
2951 (elf32_hppa_finish_dynamic_symbol): Likewise.
2952 (elf32_hppa_finish_dynamic_sections): Likewise.
2954 2001-05-24 Tom Rix <trix@redhat.com>
2956 * Makefile.am coff-pmac bfd now defined in coff-rs6000.c
2957 xcoff-target.h not used to define rs6000 or ppc bfd.
2960 * bfd-in.h : (struct lineno_cache_entry) promote element "offset"
2963 * coff-rs6000.c : Many changes for 64 bit support. Move common
2964 32/64 code to xcofflink.c. Explictly define the rs6000coff_vec
2967 * coff64-rs6000.c : Many changes for 64 bit support. 64 bit
2968 linker now supported. Explictly define the rs6000coff64_vec.
2970 * coffcode.h : (coff_set_arch_mach_hook) xcoff 64 bit support
2971 (coff_print_aux) same
2972 (coff_write_object_contents) same
2973 (coff_slurp_line_table) same
2975 * coffgen.c : (coff_fix_symbol_name) formatting
2976 (coff_mangle_symbols) xcoff 64 bit support
2977 (coff_write_symbol) same
2978 (coff_write_alien_symbol) same
2979 (coff_write_native_symbol) same
2980 (coff_write_symbols) same
2981 (coff_get_symbol_info) same
2982 (bfd_coff_get_syment) same
2983 (coff_print_symbol) same
2985 * config.bfd : add powerpc64-*-aix* target
2987 * libcoff-in.h : formatting
2989 * libcoff.h : move xcoff extern declarations to libxcoff.h
2991 * libxcoff.h : New file
2993 * xcofflink.c : Many changes for xcoff64 support. Move common
2994 structures to include/coff/xcoff.h. Move specific structure to
2995 backends coff-rs6000.c and coff64-rs6000.c. Use new backend
2996 functions, defined in libxcoff.h, to isolate 32/64 dependencies.
2998 (bfd_xcoff_size_dynamic_sections) : special __rtinit symbol for
3001 (xcoff_build_ldsyms) : handle special __rtinit symbol.
3003 2001-05-23 Alexandre Oliva <aoliva@redhat.com>
3005 * elf64-sparc.c (sparc64_elf_slurp_reloc_table): Fix typo
3008 2001-05-23 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3010 * reloc.c (bfd_reloc_code_real): Add MIPS ELF64 relocations.
3011 * libbfd.h: Regenerate.
3012 * bfd-in2.h: Regenerate.
3014 * aoutx.h (aout_@var{size}_machine_type): Add MIPS r12k support.
3015 * archures.c (bfd_mach_mips12000): Define.
3016 * cpu-mips.c (arch_info_struct): Add MIPS r12k support.
3017 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Add MIPS r12k
3019 (_bfd_mips_elf_size_dynamic_sections): Use official bfd typedef.
3020 * bfd-in2.h: Regenerate.
3021 * elfxx-target.h: Do not redefine bfd_elfNN_bfd_make_debug_symbol.
3023 2001-05-23 kaz Kojima <kkojima@rr.iij4u.or.jp>
3025 * elf32-sh.c (elf_sh_plt0_entry_be, elf_sh_plt0_entry,
3026 elf_sh_plt_entry_be, elf_sh_plt_entry, elf_sh_pic_plt_entry_be,
3027 elf_sh_pic_plt_entry): New PLT code, that does not use r2, since
3028 that is used by GCC.
3030 2001-05-23 Nick Clifton <nickc@cambridge.redhat.com>
3032 * elf-bfd.h (NUM_SHDR_ENTRIES): New macro: compute the number
3033 of entries in a structured section.
3034 * elf.c: Use new macro.
3035 * elf32-i386.c: Use new macro.
3036 * elf32-mips.c: Use new macro.
3037 * elf64-alpha.c: Use new macro.
3038 * elf64-sparc.c: Use new macro.
3039 * elfcode.h: Use new macro.
3040 * elflink.h: Use new macro.
3042 2001-05-23 Nick Clifton <nickc@cambridge.redhat.com>
3044 * bfdint.texi: Replace -oformat with --oformat.
3046 2001-05-21 Andreas Jaeger <aj@suse.de>
3048 * dwarf2.c (decode_line_info): Fix error message.
3049 (read_abbrevs): Fix test for offset as suggested by Alan Modra and
3050 adjust error message.
3052 2001-05-18 H.J. Lu <hjl@gnu.org>
3054 * elflink.h (elf_link_add_object_symbols): Revert the last
3057 2001-05-17 Alan Modra <amodra@one.net.au>
3059 * elf32-hppa.c (clobber_millicode_symbols): Temporarily set
3060 ELF_LINK_FORCED_LOCAL to suit 2001-04-30 change.
3061 (hppa_build_one_stub): Add an assert to check plt.offset.
3063 2001-05-17 H.J. Lu <hjl@gnu.org>
3065 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set the
3066 version definition to basename of the output filename.
3068 2001-05-17 H.J. Lu <hjl@gnu.org>
3070 * elflink.h (elf_link_add_object_symbols): Set DT_NEEDED to
3071 basename of the bfd filename.
3073 2001-05-16 Alan Modra <amodra@one.net.au>
3075 * section.c (asection): Add linker_has_input field.
3076 (STD_SECTION): Adjust initialization to suit.
3077 * ecoff.c (bfd_debug_section): Likewise.
3078 * bfd-in2.h: Regenerate.
3080 2001-05-15 Alexandre Oliva <aoliva@redhat.com>
3082 * elf-m10300.c (mn10300_elf_relax_section): Don't relax
3083 negative 32-bit operands to 16 operands when the operand is
3084 going to be zero-extended by the modified opcode.
3086 2001-05-12 Peter Targett <peter.targett@arccores.com>
3088 * cpu-arc.c (arch_info_struct): Add entry 'base' representing old
3089 name for 'arc5' core versions.
3090 (bfd_arc_arch): Make bfd_mach_arc_6 default.
3092 * elf32-arc.c (arc_elf_object_p): Make E_ARC_MACH_ARC6 default
3094 (arc_elf_final_write_processing): Make bfd_mach_arc_6 default.
3096 2001-05-11 Jakub Jelinek <jakub@redhat.com>
3098 * elfxx-ia64.c (is_unwind_section_name): Consider linkonce unwind
3100 (elfNN_ia64_final_write_processing): Map .gnu.linkonce.ia64unw.FOO
3101 to .gnu.linkonce.t.FOO text section.
3103 2001-05-11 Jakub Jelinek <jakub@redhat.com>
3105 * merge.c (struct sec_merge_hash_entry): Add u.entsize and u.suffix
3106 fields, change sec into secinfo.
3107 (struct sec_merge_info): Add chain, remove last fields.
3108 (struct sec_merge_sec_info): Add next, sec, psecinfo fields.
3109 (sec_merge_hash_lookup): If lookup could not use a string only
3110 because it has bad alignment, mark the old string for deletion.
3111 (sec_merge_add): Add secinfo argument. Don't compute entry's
3112 position, instead record the section.
3113 (sec_merge_emit): Update for the sec into secinfo change in
3114 struct sec_merge_hash_entry.
3115 (_bfd_merge_section): Only record the section for merging, defer
3116 putting strings into the hash table.
3117 (cmplengthentry, last4_eq, last_eq, record_section, merge_strings,
3118 _bfd_merge_sections): New functions.
3119 (_bfd_merged_section_offset): Update for the sec_merge_hash_entry
3121 * libbfd-in.h (_bfd_merge_sections): Add prototype.
3122 (_bfd_nolink_bfd_merge_sections): Define.
3123 * libbfd.h: Likewise.
3124 (bfd_generic_merge_sections): Add prototype.
3125 * targets.c (BFD_JUMP_TABLE_LINK): Add _bfd_merge_sections.
3126 (struct bfd_target): Likewise.
3127 * bfd.c (bfd_merge_sections): Define.
3128 * bfd-in2.h: Rebuilt.
3129 * elf.c (_bfd_elf_merge_sections): New function.
3130 * elf-bfd.h (_bfd_elf_merge_sections): Add prototype.
3131 * elfxx-target.h (bfd_elfNN_bfd_merge_sections): Define.
3132 * reloc.c (bfd_generic_merge_sections): New function.
3133 * vms.c (vms_bfd_merge_sections): New function.
3134 * aout-adobe.c (aout_32_bfd_merge_sections): Define.
3135 * aout-target.h (MY_bfd_merge_sections): Define.
3136 * aout-tic30.c (MY_bfd_merge_sections): Define.
3137 * binary.c (binary_bfd_merge_sections): Define.
3138 * bout.c (b_out_bfd_merge_sections): Define.
3139 * coff-alpha.c (_bfd_ecoff_bfd_merge_sections): Define.
3140 * coffcode.c (coff_bfd_merge_sections): Define.
3141 * coff-mips.c (_bfd_ecoff_bfd_merge_sections): Define.
3142 * i386msdos.c (msdos_bfd_merge_sections): Define.
3143 * i386os9k.c (os9k_bfd_merge_sections): Define.
3144 * ieee.c (ieee_bfd_merge_sections): Define.
3145 * ihex.c (ihex_bfd_merge_sections): Define.
3146 * nlm-target.h (nlm_bfd_merge_sections): Define.
3147 * oasys.c (oasys_bfd_merge_sections): Define.
3148 * ppcboot.c (ppcboot_bfd_merge_sections): Define.
3149 * som.c (som_bfd_merge_sections): Define.
3150 * srec.c (srec_bfd_merge_sections): Define.
3151 * tekhex.c (tekhex_bfd_merge_sections): Define.
3152 * versados.c (versados_bfd_merge_sections): Define.
3153 * xcoff-target.h (_bfd_xcoff_bfd_merge_sections): Define.
3155 2001-05-11 Nick Clifton <nickc@cambridge.redhat.com>
3157 * dwarf1.c (_bfd_dwarf1_find_nearest_line): Change type of 'addr'
3158 to be unsigned long, in order to match its use.
3160 2001-05-10 H.J. Lu <hjl@gnu.org>
3162 * linker.c (_bfd_generic_link_add_one_symbol): Check loop on
3165 2001-05-09 H.J. Lu <hjl@gnu.org>
3167 * elflink.h (elf_link_add_object_symbols): Fix a typo. Allocate
3168 versymhdr->sh_size bytes for extversym instead of hdr->sh_size.
3169 Remove the unused veriable `dynver'.
3171 2001-05-08 Ian Lance Taylor <ian@zembu.com>
3173 * coff-i386.c (coff_i386_reloc): Don't dump core if output_bfd is
3174 NULL or is not COFF.
3175 (coff_i386_rtype_to_howto): Don't dump core if output section
3178 2001-05-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3180 * ecoff.c (bfd_debug_section): Fix initialization.
3181 * elf.c (_bfd_elf_slurp_version_tables): Change maxidx to unsigned, it
3182 is always a positive integer. Cast away sign mismatch.
3183 * elf32-mips.c: Fix misleading comment and typo.
3184 (_bfd_mips_elf_section_from_bfd_section): Remove unused attribute, use
3186 * elflink.c: Fix typo.
3187 (_bfd_elf_create_dynamic_sections): Remove superfluous initialization.
3188 * ecoffswap.h (ecoff_swap_fdr_in): Cast away sign mismatch.
3190 2001-05-04 Richard Henderson <rth@redhat.com>
3192 * elf64-alpha.c (SREL16, SREL32, SREL64): Set pcrel_offset true.
3194 2001-05-04 Nick Clifton <nickc@cambridge.redhat.com>
3196 * elf32-arm.h (elf32_arm_final_link_relocate): Set
3197 EF_ARM_HASENTRY if the start address is set.
3199 2001-05-03 Nick Clifton <nickc@cambridge.redhat.com>
3201 * targets.c (_bfd_target_vector_entries): Compute value based on
3202 the size of the _bfd_target_vector and not bfd_target_vector.
3204 2001-05-03 H.J. Lu <hjl@gnu.org>
3206 * elfcode.h: Include "libiberty.h".
3208 * elflink.h (elf_link_add_object_symbols): Set
3209 elf_dt_name (abfd) to basename of the bfd filename.
3210 (NAME(bfd_elf,size_dynamic_sections)): Set vn_file to basename
3211 of the bfd filename.
3213 2001-05-03 Andreas Jaeger <aj@suse.de>
3215 * elf64-gen.c (elf_generic_info_to_howto): Add unused attribute.
3216 (elf_generic_info_to_howto_rel): Likewise.
3217 * coff-alpha.c (reloc_nil): Likewise.
3218 (alpha_ecoff_bad_format_hook): Likewise.
3219 (alpha_adjust_reloc_out): Likewise.
3220 (alpha_bfd_reloc_type_lookup): Likewise.
3221 (alpha_convert_external_reloc): Likewise.
3222 * elf64-alpha.c (elf64_alpha_reloc_nil): Likewise.
3223 (elf64_alpha_reloc_bad): Likewise.
3224 (elf64_alpha_reloc_gpdisp): Likewise.
3225 (elf64_alpha_bfd_reloc_type_lookup): Likewise.
3226 (elf64_alpha_info_to_howto): Likewise.
3227 (elf64_alpha_add_symbol_hook): Likewise.
3228 (elf64_alpha_create_got_section): Likewise.
3229 (elf64_alpha_is_local_label_name): Likewise.
3230 (elf64_alpha_merge_ind_symbols): Likewise.
3231 * elf64-mips.c (mips_elf64_reloc_type_lookup): Likewise.
3232 (mips_elf64_get_reloc_upper_bound): Likewise.
3233 * nlm32-alpha.c (nlm_alpha_mangle_relocs): Likewise.
3234 (nlm_alpha_get_public_offset): Likewise.
3236 2001-05-02 Johan Rydberg <jrydberg@opencores.org>
3238 * elf32-openrisc.c (openrisc_elf_howto_table): Do not complain
3239 about overflow in R_OPENRISC_LO_16_IN_INSN and
3240 R_OPENRISC_HI_16_IN_INSN.Index: bfd/elf32-openrisc.c
3242 2001-04-30 H.J. Lu <hjl@gnu.org>
3244 * elf.c (_bfd_elf_link_hash_hide_symbol): Set dynindx to -1
3245 only for ELF_LINK_FORCED_LOCAL.
3246 * elf32-hppa.c (elf32_hppa_hide_symbol): Likewise.
3247 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Likewise.
3248 * elfxx-ia64.c (elfNN_ia64_hash_hide_symbol): Likewise.
3250 * elflink.h (elf_fix_symbol_flags): Set ELF_LINK_FORCED_LOCAL
3251 if the symbol has hidden or internal visibility.
3253 2001-04-30 Alan Modra <amodra@one.net.au>
3255 * elf32-hppa.c (final_link_relocate): Branch to .+8 for
3256 calls to undefined weak symbols.
3258 2001-04-30 Andreas Jaeger <aj@suse.de>, Andreas Schwab <schwab@suse.de>
3260 * elf64-x86-64.c (elf64_x86_64_relocate_section): Correct test for
3261 R_X86_64_GOTPCREL, don't use assignments instead of comparisons.
3263 2001-04-27 Andreas Jaeger <aj@suse.de>
3265 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_sections): Only swap
3266 out handled entries.
3267 (elf64_x86_64_finish_dynamic_symbol): Set up GOT entries.
3268 (elf64_x86_64_relocate_section): Fix GOTPCREL calculation.
3269 (elf64_x86_64_relocate_section): Merge entries for GOTPCREL and
3272 2001-04-27 Sean McNeil <sean@mcneil.com>
3274 * config.bfd: Add arm-vxworks target.
3275 * coff-arm (coff_arm_relocate_section): Add in symbol value to
3276 addend (fro VXworks targets).
3278 2001-04-26 H.J. Lu <hjl@gnu.org>
3280 * elf32-i386.c (elf_i386_check_relocs): Verify if r_symndx is
3283 2001-04-25 Frank Ch. Eigler <fche@redhat.com>
3285 * bfd-in.h (bfd_cache_close): Declare newly exported function.
3286 * bfd-in2.h: Regenerated.
3288 2001-04-24 Jakub Jelinek <jakub@redhat.com>
3290 * merge.c (struct sec_merge_hash_entry): Add alignment field.
3291 (struct sec_merge_hash): Remove alignment_power.
3292 (sec_merge_hash_newfunc): Clear alignment.
3293 (sec_merge_hash_lookup): Pass alignment as argument.
3294 Use hashp->root.next, not hashp->next to walk the hash chain.
3295 If a string already in the hashtable does not have required
3296 alignment, create a new hashtable entry.
3297 (sec_merge_init): Remove alignment_power argument.
3298 (sec_merge_add): Add alignment argument.
3299 (sec_merge_emit): Alignment is now a per-entity thing, not per
3301 (_bfd_merge_section): Sanity check even non-SEC_STRINGS sections
3302 for proper alignment.
3303 Pass alignment information to sec_merge_add.
3305 2001-04-24 Christian Groessler <cpg@aladdin.de>
3307 * coff-z8k.c (extra_case): added handler for R_DISP7, R_CALLR
3308 and R_REL16 reloc types; accept odd values for R_REL16 type
3310 2001-04-24 Johan Rydberg <jrydberg@opencores.org>
3312 * cpu-openrisc.c: New file.
3313 * elf32-openrisc.c: Likewise.
3315 * Makefile.am (ALL_MACHINES): Add cpu-openrisc.lo.
3316 (ALL_MACHINES_CFILES): Add cpu-openrisc.c.
3317 (BFD32_BACKENDS): Add elf32-openrisc.lo.
3318 (BFD32_BACKENDS_CFILES): Add elf32-openrisc.c.
3319 (cpu-openrisc.lo, elf32-openrisc.lo): New rules.
3320 * Makefile.in: Regenerated.
3321 * config.bfd: (openrisc-*-elf): New target.
3322 * configure.in (bfd_elf32_openrisc_vec): New vector.
3323 * configure: Regenerated.
3324 * libbfd.h: Regenerated.
3325 * bfd-in2.h: Regenerated.
3326 * reloc.c: Add OpenRISC relocations.
3327 * targets.c (bfd_elf32_openrisc_vec): Declare.
3328 (bfd_target_vect): Add bfd_elf32_openrisc_vec.
3329 * archures.c (enum bfd_architecture): Add bfd_arch_openrisc.
3330 (bfd_openrisc_arch): Declare.
3331 (bfd_archures_list): Add bfd_openrisc_arch.
3332 * elf.c (prep_headers): Add bfd_arch_openrisc.
3334 2001-04-23 Bo Thorsen <bo@suse.de>
3336 * elf64-x86-64.c: Add c++ vtable hack.
3337 Small whitespace and comment changes.
3339 2001-04-19 Andreas Jaeger <aj@suse.de>
3341 * elf64-x86-64.c (elf64_x86_64_plt0_entry): Fix instructions.
3342 (elf64_x86_64_plt_entry): Likewise.
3343 (elf64_x86_64_finish_dynamic_sections): Fix PLT0 generation.
3344 (elf64_x86_64_finish_dynamic_symbol): Fix PLT generation.
3346 2001-04-17 Hans-Peter Nilsson <hp@axis.com>
3348 * elf32-cris.c: Tweak comments related to dynamic linking.
3349 (cris_elf_relocate_section): When not creating shared object, fill
3350 in the .got table for any symbol not in the dynamic symbol table.
3351 (elf_cris_finish_dynamic_symbol): When not creating shared object,
3352 only emit a .got.rela reloc if the symbol is in the dynamic symbol
3354 (cris_elf_check_relocs): Use variable r_type in all places rather
3355 than the original expression. Add default case in switch for
3357 (elf_cris_size_dynamic_sections): Iterate over
3358 elf_cris_discard_excess_program_dynamics when not creating shared
3360 (elf_cris_discard_excess_dso_dynamics): Renamed from
3361 elf_cris_discard_copies. Correct typo, s/Rel/Rela/.
3362 (elf_cris_discard_excess_program_dynamics): New.
3364 2001-04-14 Mark Elbrecht <snowball3@bigfoot.com>
3366 * coffcode.h (coff_write_object_contents): Use
3367 bfd_coff_swap_filehdr_out instead of coff_swap_filehdr_out.
3369 2001-04-14 H.J. Lu <hjl@gnu.org>
3371 * bfd-in2.h: Regenerate.
3373 2001-04-14 Jakub Jelinek <jakub@redhat.com>
3375 * section.c (STD_SECTION): Add entsize.
3377 2001-04-13 H.J. Lu <hjl@gnu.org>
3379 * section.c (SEC_MERGE): Define new flag for merging.
3380 (SEC_STRINGS): Likewise.
3381 (entsize): New field.
3383 2001-04-13 Roger Sayle <roger@metaphorics.com>
3385 * coff-i386.c (TARGET_SYM): SEC_READONLY is an applicable section
3386 flag on pe-i386 targets.
3388 2001-04-13 Jakub Jelinek <jakub@redhat.com>
3390 * libbfd-in.h (_bfd_merge_section): New.
3391 (_bfd_write_merged_section): New.
3392 (_bfd_merged_section_offset): New.
3393 * libbfd.h: Rebuilt.
3394 * linker.c (_bfd_generic_link_output_symbols): Handle
3396 * aoutx.h (aout_link_write_symbols): Likewise.
3397 * pdp11.c (aout_link_write_symbols): Likewise.
3398 * elflink.h (elf_link_add_object_symbols): Call _bfd_merge_section.
3399 (elf_bfd_final_link): Adjust global symbols pointing into SEC_MERGE
3401 (elf_link_sec_merge_syms): New.
3402 (elf_link_input_bfd): Call _bfd_merged_section_offset
3403 and _bfd_write_merged_section.
3404 Handle discard_sec_merge.
3405 * elf-bfd.h (struct elf_link_hash_table): Add merge_info
3407 (struct bfd_elf_section_data): Likewise.
3408 * elf.c (_bfd_elf_make_section_from_shdr): Set SEC_MERGE and
3409 SEC_STRINGS section flags and entsize from their ELF counterparts.
3410 (_bfd_elf_link_hash_table_init): Initialize merge_info.
3411 (elf_fake_sections): Set SHF_MERGE, SHF_STRINGS and sh_entsize
3412 from their BFD counterparts.
3413 * merge.c: New file.
3414 * Makefile.am: Add strtab.lo.
3415 * Makefile.in: Rebuilt.
3417 2001-04-09 Hans-Peter Nilsson <hp@axis.com>
3419 * elflink.h (elf_fix_symbol_flags): For non-default visibilities,
3420 only hide symbols marked STV_INTERNAL or STV_HIDDEN.
3422 2001-04-05 Steven J. Hill <sjhill@cotw.com>
3424 * config.bfd (mips*el*-*-linux-gnu*): Use traditional little
3425 endian MIPS ELF target.
3426 * config.bfd (mips*-*-linux-gnu*): Use traditional big endian
3429 * configure.in (bfd_elf64_tradbigmips_vec): New. Traditional
3430 64bit big endian MIPS ELF target.
3431 (bfd_elf64_tradlittlemips_vec): New. Traditional 64bit little
3432 endian MIPS ELF target.
3433 * configure: Regenerated.
3435 * elf32-mips.c (IRIX_COMPAT): Handle traditional 64bit and
3436 little endian targets.
3437 (mips_elf_sym_is_global): Handle traditional targets.
3439 * elf64-mips.c (bfd_elf64_tradbigmips_vec): New. Traditional
3440 64bit big endian MIPS ELF target.
3441 (bfd_elf64_tradlittlemips_vec): New. Traditional 64bit little
3442 endian MIPS ELF target.
3444 * targets.c: (_bfd_target_vector): Add bfd_elf64_tradbigmips_vec
3445 and bfd_elf64_tradlittlemips_vec.
3447 2001-04-05 David Mosberger <davidm@hpl.hp.com>
3449 * elf32-i386.c (elf_i386_fake_sections): Treat ".reloc" as an
3450 ordinary "progbits" section.
3452 2001-04-04 Alan Modra <alan@linuxcare.com.au>
3454 * elflink.h (elf_fix_symbol_flags): Call elf_backend_hide_symbol
3455 when -Bsymbolic causes a symbol to no longer need a .plt entry.
3457 2001-04-03 David Mosberger <davidm@hpl.hp.com>
3459 * efi-app-ia32.c (ALIGN_SECTIONS_IN_FILE): Deleted.
3461 2001-03-30 H.J. Lu <hjl@gnu.org>
3463 * efi-app-ia32.c (PEI_TARGET_SUBSYSTEM): Rename from ...
3464 (PEI_DEFAULT_TARGET_SUBSYSTEM): This.
3466 2001-03-26 H.J. Lu <hjl@gnu.org>
3468 * elf32-gen.c (elf32_generic_link_add_symbols): New. Check
3469 if there are any relocations for generic ELF.
3470 (bfd_elf32_bfd_link_add_symbols): Defined to
3471 elf32_generic_link_add_symbols.
3472 * elf64-gen.c (elf64_generic_link_add_symbols): New. Check
3473 if there are any relocations for generic ELF.
3474 (bfd_elf64_bfd_link_add_symbols): Defined to
3475 elf64_generic_link_add_symbols.
3477 2001-03-23 Nick Clifton <nickc@redhat.com>
3479 * Makefile.am (BUILD_CFILES): New variable: List of C source
3480 files created in build directory.
3481 (BUILD_HFILES): New variable: List of header files created in
3484 (po/POTFILES.in): Replace rule with empty entry.
3485 (po/SRC-POTFILES.in): New rule: Create a list of source files
3486 in the source directory.
3487 (po/BLD-POTFILES.in): New rule: Create a list of source files
3488 in the build directory.
3489 (MOSTLYCLEAN): Do not delete source files created in build
3491 * Makefile.in: Regenerate.
3492 * configure.in: Insert SRC-POTFILES.in and BLD-POTFILES.in
3494 * configure: Regenerate.
3496 * po/Make-in: Replace occurrences of POTFILES with SRC-POTFILES
3498 Add .. to the search path when building bfd.pot.
3499 Delete POTFILES when performing distclean.
3500 Add comment describing why distclean is broken in maintainer mode.
3501 * po/POTFILES.in: Delete.
3502 * po/SRC-POTFILES.in: New file.
3503 * po/BLD-POTFILES.in: New file.
3504 * po/bfd.pot: Regenerate.
3506 2001-03-22 Hans-Peter Nilsson <hp@axis.com>
3508 * elf32-cris.c: Shlib and PIC support. PCREL tweaks.
3509 (elf_cris_discard_copies, elf_cris_adjust_gotplt_to_got,
3510 elf_cris_try_fold_plt_to_got, elf_cris_link_hash_newfunc,
3511 elf_cris_link_hash_table_create, elf_cris_adjust_dynamic_symbol,
3512 elf_cris_size_dynamic_sections, elf_cris_finish_dynamic_symbol,
3513 elf_cris_finish_dynamic_sections,elf_cris_hide_symbol): New
3515 (cris_elf_howto_table) <R_CRIS_8_PCREL, R_CRIS_16_PCREL,
3516 R_CRIS_32_PCREL>: Correct comments. Set pcrel_offset to false.
3517 <R_CRIS_COPY, R_CRIS_GLOB_DAT, R_CRIS_JUMP_SLOT, R_CRIS_RELATIVE,
3518 R_CRIS_16_GOT, R_CRIS_32_GOT, R_CRIS_16_GOTPLT, R_CRIS_32_GOTPLT,
3519 R_CRIS_32_GOTREL, R_CRIS_32_PLT_GOTREL, R_CRIS_32_PLT_PCREL>:
3520 New HOWTO members for new relocs.
3521 (cris_reloc_map): Map new relocs.
3522 (ELF_DYNAMIC_INTERPRETER): Define.
3523 (PLT_ENTRY_SIZE): Define.
3524 (elf_cris_plt0_entry, elf_cris_plt_entry, elf_cris_pic_plt0_entry,
3525 elf_cris_pic_plt_entry): New, PLT templates.
3526 (struct elf_cris_pcrel_relocs_copied, struct
3527 elf_cris_link_hash_entry, struct elf_cris_link_hash_table): New.
3528 (elf_cris_link_hash_traverse, elf_cris_hash_table): Define.
3529 (cris_final_link_relocate): Check that 16-bit GOT relocs have
3530 positive values. Adjust PCREL relocs to be relative to location
3532 (cris_elf_relocate_section): Handle relocations to dynamic
3533 objects. Handle new relocations. Call error handler when seeing
3534 non-PIC relocation for read-only sections while generating shared
3536 (cris_elf_check_relocs): Set reference counts for GOT and PLT
3538 (bfd_elf32_bfd_link_hash_table_create,
3539 elf_backend_adjust_dynamic_symbol,
3540 elf_backend_size_dynamic_sections,
3541 elf_backend_finish_dynamic_symbol,
3542 elf_backend_finish_dynamic_sections,
3543 elf_backend_create_dynamic_sections, bfd_elf32_bfd_final_link,
3544 elf_backend_hide_symbol, elf_backend_want_got_plt,
3545 elf_backend_plt_readonly, elf_backend_want_plt_sym,
3546 elf_backend_got_header_size, elf_backend_plt_header_size):
3549 * reloc.c: (BFD_RELOC_CRIS_COPY, BFD_RELOC_CRIS_GLOB_DAT,
3550 BFD_RELOC_CRIS_JUMP_SLOT, BFD_RELOC_CRIS_RELATIVE,
3551 BFD_RELOC_CRIS_32_GOT, BFD_RELOC_CRIS_16_GOT,
3552 BFD_RELOC_CRIS_32_GOTPLT, BFD_RELOC_CRIS_16_GOTPLT,
3553 BFD_RELOC_CRIS_32_GOTREL, BFD_RELOC_CRIS_32_PLT_GOTREL,
3554 BFD_RELOC_CRIS_32_PLT_PCREL): New relocs.
3555 * bfd-in2.h, libbfd.h: Regenerate.
3557 2001-03-21 Diego Novillo <dnovillo@redhat.com>
3559 (_bfd_mips_elf_relocate_section): Give a better error message when
3560 a relocation is not recognized.
3562 2001-03-21 Alan Modra <alan@linuxcare.com.au>
3564 * elf32-hppa.c (elf32_hppa_set_gp): Check sec->output_section
3565 non-NULL before attempting to dereference.
3567 2001-03-20 H.J. Lu <hjl@gnu.org>
3569 * configure.in: Remove the redundent AC_ARG_PROGRAM.
3570 * configure: Rebuild.
3572 2001-03-20 Andreas Schwab <schwab@suse.de>
3574 * elf32-m68k.c (elf_m68k_relocate_section): Don't need the
3575 relocation value when resolving a reference from a debugging
3578 2001-03-16 Scott Thomason <SThomaso@hii.com>
3580 * coff64-rs6000.c (xcoff64_swap_sym_out): Fix syntax errors.
3581 (xcoff64_swap_sym_out): Fix syntax errors.
3583 2001-03-16 Richard Sandiford <rsandifo@redhat.com>
3585 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix warning.
3587 2001-03-15 Alan Modra <alan@linuxcare.com.au>
3589 * elf32-hppa.c (elf32_hppa_link_hash_entry): Add maybe_pic_call.
3590 (hppa_link_hash_newfunc): Init it.
3591 (hppa_type_of_stub): Only use non-PIC to PIC call stub if caller
3592 section appears to be non-PIC.
3593 (final_link_relocate): Likewise.
3594 (elf32_hppa_adjust_dynamic_symbol): Set maybe_pic_call for any
3595 possible candidate function, and set pic_call for those that will
3596 only have a .plt entry for the PIC call stub.
3597 (hppa_handle_PIC_calls): Set maybe_pic_call.
3599 2001-03-12 DJ Delorie <dj@redhat.com>
3601 * elf32-sh.c (sh_elf_relocate_section): Only relocation
3602 R_SH_DIR8WP* relocs if they're against external symbols, else
3603 they're just for relaxing. Validate the reloc values.
3605 2001-03-12 Stefan Geuken <mail@stefan-geuken.de>
3607 * binary.c (bfd_external_binary_architecture): Declare.
3608 (binary_object_p): If bfd_external_binary_architecture is defined,
3609 set the architecture to this string.
3611 2001-03-11 Philip Blundell <philb@gnu.org>
3613 * elf32-arm.h (elf32_arm_finish_dynamic_symbol): Don't make PLT
3614 entries that could serve as a definition for a weak symbol.
3616 2001-03-08 Nick Clifton <nickc@redhat.com>
3618 * Most files: Update copyright notices using Perl script created
3619 by Kevin Buettner <kevinb@redhat.com>.
3621 2001-03-07 Nick Clifton <nickc@redhat.com>
3623 * elf32-arm.h (elf32_arm_final_link_relocate): Conditionalise
3624 prior patch on ! defined OLD_ARM_ABI.
3626 2001-03-07 Andreas Jaeger <aj@suse.de>
3628 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix handling of
3629 some relocation values.
3631 2001-03-06 Nick Clifton <nickc@redhat.com>
3633 * elf32-arm.h (elf32_arm_final_link_relocate): Clear bit zero
3634 of offset in BLX(1) instruction.
3635 * coff-arm.c (coff_arm_relocate_section): Clear bit zero of
3636 offset in BLX(1) instruction.
3639 2001-03-06 Nick Clifton <nickc@redhat.com>
3641 * coff-arm.c (coff_arm_reloc_type_lookup): Add
3642 BFD_RELOC_THUMB_PCREL_BLX.
3644 2001-03-06 Igor Shevlyakov <igor@windriver.com>
3646 * archures.c (bfd_default_scan): Add Coldfire CPUs.
3647 * bfd-in2.h: Regenerate.
3648 * cpu-m68k.c: Add Coldfire CPUs for arch table.
3649 * ieee.c (ieee_write_processor): Set proper id for
3652 2001-03-01 D.J. Barrow <djbarrow@de.ibm.com,barrow_dj@yahoo.com>
3654 * configure.in: Add s390 target.
3655 * configure: Regenerate.
3657 2001-02-28 Andreas Jaeger <aj@suse.de>
3659 * elf64-x86-64.c (elf64_x86_64_relocate_section): Add relocation
3662 2001-02-28 Philip Blundell <pb@futuretv.com>
3664 * elf32-arm.h: Update mentions of renamed EF_xx constants.
3665 (elf32_arm_print_private_bfd_data): Handle ARM EABI version 2.
3667 2001-02-27 H.J. Lu <hjl@gnu.org>
3669 * aoutx.h (NAME(aout,bfd_free_cached_info)): Return true if
3670 abfd->tdata.aout_data == NULL.
3672 2001-02-27 Alan Modra <alan@linuxcare.com.au>
3674 * elf32-hppa.c: Correct field selector in stub comments.
3675 (clobber_millicode_symbols): Formatting fix.
3677 * configure.in: Bump version to 2.11.90.
3678 * configure: Regenerate.
3679 * Makefile.am (CFILES): Rename to SOURCE_CFILES.
3680 (CFILES): $SOURCE_CFILES + generated C files.
3681 (POTFILES): Include $HFILES not $SOURCE_HFILES.
3683 * Makefile.in: Regenerate.
3684 * doc/Makefile.in: This too.
3686 2001-02-26 Timothy Wall <twall@cygnus.com>
3688 * elfxx-ia64.c (elfNN_ia64_aix_add_symbol_hook): Remove obsolete
3691 2001-02-26 Nick Clifton <nickc@redhat.com>
3693 * coffcode.h (styp_to_sec_flags) [COFF_WITH_PE version]: Tidy
3694 up, replacing multiple if statements with a switch.
3695 (handle_COMDAT): New function.
3697 2001-02-26 H.J. Lu <hjl@gnu.org>
3699 * coffcode.h (styp_to_sec_flags) [COFF_WITH_PE version]: Issue
3700 a warning for section flags we do not handle instead of
3703 2001-02-26 Andreas Jaeger <aj@suse.de>
3705 * elf64-x86-64.c (x86_64_elf_howto_table): Fix order of entries.
3707 2001-02-22 Timothy Wall <twall@cygnus.com>
3709 * config.bfd (targ_cpu): Add vectors for ia64-*-aix* (aka Monterey).
3710 * configure.in: Add objects for elf64_ia64_aix vectors.
3711 * configure: Regenerated.
3712 * configure.host: Recognize ia64-*-aix*.
3713 * elfxx-ia64.c: Add hooks for ELF64 on AIX5. Define new vectors
3714 for AIX. AIX5 requires most relocations to be dynamic (*all*
3715 binaries are somewhat similar to shared libraries).
3716 * targets.c: Add elf64_ia64_aix vectors.
3718 2001-02-21 David Mosberger <davidm@hpl.hp.com>
3720 * cpu-ia64-opc.c (elf64_ia64_operands}: Fix typo: error string for
3721 C8 said "1" instead of "8". Clarify error string for IMM22:
3722 "signed integer" instead of just "integer".
3724 2001-02-20 Andreas Jaeger <aj@suse.de>
3726 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_symbol): Don't make
3727 PLT entries that could serve as a definition for a weak symbol.
3729 2001-02-19 Jakub Jelinek <jakub@redhat.com>
3731 * elf32-sparc.c (elf32_sparc_finish_dynamic_symbol): Don't make PLT
3732 entries that could serve as a definition for a weak symbol.
3733 * elf64-sparc.c (sparc64_elf_finish_dynamic_symbol): Likewise.
3735 2001-02-18 David O'Brien <obrien@FreeBSD>
3737 * configure.in: Recognize FreeBSD/arm, FreeBSD/PowerPC, and treat
3738 FreeBSD/i386-CURRENT differently until I can figure out the needed
3740 * configure: Regenerate.
3741 * config.bfd: Recognize FreeBSD/x86-64, FreeBSD/ia64, FreeBSD/arm,
3742 FreeBSD/PowerPC, and FreeBSD/sparc64.
3744 2001-02-18 lars brinkhoff <lars@nocrew.org>
3746 * Makefile.am: Add PDP-11 a.out target.
3747 * config.bfd: Likewise.
3748 * configure.in: Likewise.
3749 * targets.c: Likewise.
3750 * archures.c: Likewise.
3751 * bfd-in2.h: Likewise. Add PDP-11 relocations.
3752 * libbfd.h: Add PDP-11 relocations.
3753 * reloc.c: Likewise.
3754 * cpu-pdp11.c: New file.
3755 * pdp11.c: New file.
3757 * libaout.h (GET_WORD) [ARCH_SIZE==16]: Define.
3758 (GET_SWORD) [ARCH_SIZE==16]: Likewise.
3759 (GET_SWORD) [ARCH_SIZE==16]: Likewise.
3760 (PUT_WORD) [ARCH_SIZE==16]: Likewise.
3761 (GET_MAGIC): New macro.
3762 (PUT_MAGIC): Likewise.
3763 * aout-target.h (MY(object_p)): Use GET_MAGIC to read magic word.
3765 2001-02-18 Jim Kingdon <jkingdon@engr.sgi.com>
3767 * irix-core.c (irix_core_core_file_p): Set the architecture (GDB
3768 multiarch needs it).
3770 2001-02-18 H.J. Lu <hjl@gnu.org>
3772 * elflink.h (elf_link_input_bfd): Ignore invalid section symbol
3775 2001-02-18 Kazu Hirata <kazu@hxi.com>
3777 * vms-misc.c: Fix formatting.
3779 2001-02-16 Kazu Hirata <kazu@hxi.com>
3781 * vms.c: Fix formatting.
3783 2001-02-14 H.J. Lu <hjl@gnu.org>
3785 * elf.c (elf_find_function): New function.
3786 (_bfd_elf_find_nearest_line): Call elf_find_function () to find
3787 the file name and function name.
3789 2001-02-14 Nick Clifton <nickc@redhat.com>
3791 * ecoff.c (bfd_debug_section): Update to initialise new fields in
3794 * Makefile.am (BFD32_BACKENDS_CFILES): Remove peigen.c
3795 (BFD64_BACKENDS): Add pepigen.c
3796 Add rules to create peigen.c and pepigen.c from peXXigen.c.
3798 * Makefile.in: Regenerate.
3799 * configure: Regenerate.
3800 * po/POTFILES.in: Regenerate.
3801 * po/bfd.pot: Regenerate.
3803 2001-02-14 H.J. Lu <hjl@gnu.org>
3805 * libcoff-in.h (pe_tdata): Add members target_subsystem and
3806 force_minimum_alignment.
3808 2001-02-14 Bo Thorsen <bo@suse.de>
3810 * elf64-x86-64.c: Small formatting fixes and rearrangements of code.
3811 (elf64_86_64_size_info): Struct added to fix a problem
3812 with the hashtable string entries.
3813 (elf64_x86_64_adjust_dynamic_symbol): Add generation of .got.plt.
3814 (elf64_x86_64_size_dynamic_sections): A FIXME removed.
3815 (elf64_x86_64_size_dynamic_sections): Fix a dynamic entry and
3816 remove the FIXME for this.
3817 (elf64_x86_64_adjust_dynamic_symbol): Fix check for unneeded .plt
3818 section. Also removed the FIXME for it.
3819 (x86_64_elf_howto_table): Use bfd_elf_generic_reloc.
3820 (ELF_DYNAMIC_INTERPRETER): Fix the name of the dynamic linker.
3821 (elf64_x86_64_finish_dynamic_sections): Enable .got.plt writing.
3823 2001-02-13 Richard Henderson <rth@redhat.com>
3825 * elfxx-ia64.c (elfNN_ia64_final_link): Set __gp if required
3826 and not user provided.
3828 2001-02-13 Kazu Hirata <kazu@hxi.com>
3830 * vms.c (vms_print_symbol): Remove unreachable code.
3832 * rs6000-core.c: Fix formatting.
3834 2001-02-13 David Mosberger <davidm@hpl.hp.com>
3836 * peicode.h (coff_swap_filehdr_out) [COFF_IMAGE_WITH_PE]: Define
3837 as _bfd_XXi_only_swap_filehdr_out.
3838 (pe_mkobject) [PEI_FORCE_MINIMUM_ALIGNMENT]: Set
3839 pe->force_minimum_alignment to TRUE.
3840 (pe_mkobject) [PEI_TARGET_SUBSYSTEM]: Set pe->target_subsystem to
3841 PEI_TARGET_SUBSYSTEM.
3842 (pe_print_private_bfd_data): Call
3843 _bfd_XX_print_private_bfd_data_common() instead of
3844 _bfd_pe_print_private_bfd_data_common().
3845 (pe_bfd_copy_private_bfd_data): Call
3846 _bfd_XX_bfd_copy_private_bfd_data_common() instead of
3847 _bfd_pe_bfd_copy_private_bfd_data_common().
3848 (coff_bfd_copy_private_section_data): Define as
3849 _bfd_XX_bfd_copy_private_section_data instead of
3850 _bfd_pe_bfd_copy_private_section_data.
3851 (coff_get_symbol_info): Define as _bfd_XX_get_symbol_info instead
3852 of a _bfd_pe_get_symbol_info.
3856 * peXXigen.c: Renamed from peigen.c.
3857 (COFF_WITH_XX): Define this macro (will get expanded into
3858 COFF_WITH_pep or COFF_WITH_pe, depending on whether this is being
3859 compiled as peigen.c or pepigen.c.
3860 [COFF_WITH_pep]: Include "coff/ia64.h" instead of "coff/i386.h" to
3861 define the canonical PEP structures and definitions.
3862 (_bfd_XXi_swap_aouthdr_out): If pe->force_minimum_alignment is in
3863 effect, enforce minimum file and section alignments. If
3864 extra->Subsystem is IMAGE_SUBSYSTEM_UNKNOWN, set it to
3865 pe->target_subsystem (this defaults to IMAGE_SUBSYSTEM_UNKNOWN,
3866 so, by default, this is a no-op).
3868 * libpei.h: Rename COFF_WITH_PEP to COFF_WITH_pep.
3869 (_bfd_XX_bfd_copy_private_bfd_data_common): Add macros to map
3870 _bfd_XXfoo to _bfd_pepfoo if COFF_WIT_PEP is defined and to
3871 _bfd_pefoo if it's not defined. Use these macros to define
3874 * libcoff.h (pe_tdata): Add members target_subsystem and
3875 force_minimum_alignment.
3877 * efi-app-ia64.c (COFF_WITH_pep): Rename COFF_WITH_PEP to
3879 (PEI_TARGET_SUBSYSTEM): Rename from PEI_DEFAULT_TARGET_SUBSYSTEM.
3881 * configure.in (bfd_efi_app_ia64_vec): Use pepigen.lo instead of
3884 * coff-ia64.c: Rename COFF_WITH_PEP to COFF_WITH_pep.
3885 (AOUTSZ): Rename PEP64AOUTSZ and PEP64AOUTHDR to PEPAOUTSZ and
3888 * Makefile.in (BFD64_BACKENDS): Mention pepigen.lo.
3889 (BFD64_BACKENDS_CFILES): Mention pepigen.c
3890 (peigen.c): Add rule to generate from peXXigen.c.
3892 (pepigen.lo): List dependencies for pepigen.lo.
3894 2001-02-13 Alan Modra <alan@linuxcare.com.au>
3896 * elf32-hppa.c (elf32_hppa_set_gp): Handle weak $global$. If
3897 $global$ referenced but not defined, set its value here.
3899 2001-02-09 Bo Thorsen <bo@suse.de>
3901 * elf64-x86-64.c (elf64_x86_64_check_relocs): Set .rela.got section
3903 (elf64_x86_64_check_relocs): Write R_X86_64_GOTPCREL GOT entry
3905 (elf64_x86_64_relocate_section): Fix formatting.
3906 (elf64_x86_64_relocate_section): Fix addend for relocation of
3907 R_X86_64_(8|16|32|PC8|PC16|PC32).
3909 2001-02-12 Jan Hubicka <jh@suse.cz>
3911 * elf64-x86-64.c (x86_64_elf_howto): Fix name of R_X86_64_GOTPCREL.
3913 2001-02-11 H.J. Lu <hjl@gnu.org>
3915 * elflink.h (elf_bfd_final_link): Use file_align for SYMTAB
3918 2001-02-11 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
3920 * elf32-mips.c (mips_elf_create_dynamic_relocation): Undo patch
3921 from 2000-10-13. Do not add the symbol's value for R_MIPS_REL32
3922 relocations against dynsym symbols.
3924 * elf32-mips.c (elf_mips_howto_table): Fix the comment on
3925 the R_MIPS_26 relocation.
3926 (mips_elf_calculate_relocation): Use (p + 4) instead of p for
3927 the R_MIPS_26 relocation.
3928 (mips_elf_perform_relocation): Fix the comment on the R_MIPS16_26
3930 * elf64-mips.c (mips_elf64_howto_table_rel): Fix the comment on
3931 the R_MIPS_26 relocation.
3932 (mips_elf64_howto_table_rela): Likewise.
3934 * elf32-mips.c (struct mips_elf_link_hash_entry): Added no_fn_stub
3935 member to mark symbols that have non-CALL relocations against
3937 (mips_elf_link_hash_newfunc): Initialize no_fn_stub.
3938 (mips_elf_calculate_relocation): Handle R_MIPS_CALL16 like
3940 (_bfd_mips_elf_check_relocs): Set no_fn_stub for a symbol if a
3941 non-CALL relocation against it is encountered.
3942 (_bfd_mips_elf_copy_indirect_symbol): Merge no_fn_stub as well.
3943 (_bfd_mips_elf_adjust_dynamic_symbol): Only create a stub if
3944 no_fn_stub is not set.
3946 * elf32-mips.c (mips_elf_output_extsym): Get the output section
3947 information from the real symbol for indirect ones.
3948 Check no_fn_stub to find out if a symbol has a function stub
3951 2001-02-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
3953 * Makefile.am (stamp-lib): ranlib the libbfd.a in the build directory.
3954 * Makefile.in: Regenerate.
3956 2001-02-09 David Mosberger <davidm@hpl.hp.com>
3958 * elfxx-ia64.c (is_unwind_section_name): New function. Returns
3959 true if section name is an unwind table section name.
3960 (elfNN_ia64_additional_program_headers): Count each unwind section
3962 (elfNN_ia64_modify_segment_map): Install one unwind program header
3963 for each unwind separate section. Note: normally the linker
3964 script merges the unwind sections that go into a single segment,
3965 so this still generates at most one unwind program header per
3968 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Accept any section
3969 name for SHT_IA_64_UNWIND, not just .IA_64.unwind.
3970 (elfNN_ia64_fake_sections): Mark sections with names that start
3971 with .IA_64.unwind but not with .IA_64.unwind_info as an IA-64
3974 * elfxx-ia64.c (elfNN_ia64_final_write_processing): New function.
3975 Use it to make sh_info in unwind section point to the text section
3978 2001-02-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
3980 * Makefile.am: Add linux target for S/390.
3981 * archures.c: Likewise.
3982 * bfd-in2.h: Likewise.
3983 * config.bfd: Likewise.
3984 * configure.in: Likewise.
3986 * libbfd.h: Likewise.
3987 * targets.c: Likewise.
3988 * cpu-s390.c: New file.
3989 * elf32-s390.c: New file.
3990 * elf64-s390.c: New file.
3992 2001-02-09 Nick Clifton <nickc@redhat.com>
3994 * peigen.c (_bfd_pe_get_symbol_info): Suppress addition of
3995 ImageBase. This has already been done by coff_swap_hdr_in.
3997 2001-02-09 Jakub Jelinek <jakub@redhat.com>
3999 * elf64-sparc.c (sparc64_elf_copy_private_bfd_data): New function.
4001 2001-02-09 Jakub Jelinek <jakub@redhat.com>
4003 * elf64-sparc.c (sparc64_elf_check_relocs): Don't trust reloc_count.
4004 (sparc64_elf_relocate_section): Likewise.
4006 2001-02-09 Mark Kettenis <kettenis@gnu.org>
4008 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Treat R_SPARC_UA32
4009 similar to R_SPARC_32.
4010 * elf64-sparc.c (sparc64_elf_howto_table): Likewise.
4012 2001-02-08 H.J. Lu <hjl@gnu.org>
4014 * elf32-i386.c (elf_i386_check_relocs): Reserve R_386_PC32
4015 relocation entries for weak definitions when building DSO with
4018 2001-02-08 Richard Henderson <rth@redhat.com>
4020 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Respect weakness
4021 before visibility. Locally defined protected symbols are not
4024 2001-02-08 Geoffrey Keating <geoffk@redhat.com>
4026 * config.bfd: Enable coff64 for rs6000-*. Patch from
4027 <hzoli@austin.ibm.com>.
4029 2001-02-07 Mark Elbrecht <snowball3@bigfoot.com>
4031 * coffgen.c (coff_find_nearest_line): If stabs info is successfully
4032 found, do not attempt to find dwarf2 info before returning.
4034 2001-02-07 Jakub Jelinek <jakub@redhat.com>
4036 * elflink.h (is_global_symbol_definition): Rename to
4037 is_global_data_symbol_definition and have it reject function
4039 (elf_link_is_defined_archive_symbol): Use renamed function.
4041 2001-02-07 Todd Vierling <tv@wasabisystems.com>
4043 * libbfd-in.h (bfd_target_vector): Change extern array to pointer.
4044 * libbfd.h (bfd_target_vector): Likewise.
4045 * targets.c (bfd_target_vector): Rename to _bfd_target_vector and
4046 make static; create pointer reference named bfd_target_vector.
4047 (_bfd_target_vector_entries): Calculate this based on the array
4048 typed _bfd_target_vector.
4050 2001-02-06 H.J. Lu <hjl@gnu.org>
4052 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Only hidden and
4053 internal symbols are not dynamic.
4054 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise.
4056 2001-02-06 Nick Clifton <nickc@redhat.com>
4058 * Makefile.am (BFD64_BACKENDS_CFILES): Remove elf64-ia64.c, so
4059 that it will not be pulled into the list of files that make up
4061 * Makefile.in: Regenerate.
4062 * po/bfd.pot: Regenerate.
4064 2001-02-06 H.J. Lu <hjl@gnu.org>
4066 * peicode.h (coff_swap_filehdr_in): Remove the e_magic
4068 (pe_bfd_object_p): Rewrite with external_PEI_DOS_hdr and
4069 external_PEI_IMAGE_hdr.
4071 2001-02-06 Kazu Hirata <kazu@hxi.com>
4073 * elf-m10200.c: Fix formatting.
4075 2001-02-04 Nick Clifton <nickc@redhat.com>
4077 * elf32-v850.c (v850_elf_reloc): Do not convert reloc addend to PC
4078 rel, it will be handled later on.
4080 2001-02-02 Fred Fish <fnf@ninemoons.com>
4082 * Makefile.in: Fix typo.
4084 2001-02-01 Kazu Hirata <kazu@hxi.com>
4086 * elf-m10300.c: Fix formatting.
4088 2001-01-30 Alan Modra <alan@linuxcare.com.au>
4090 * elf64-hppa.c (elf64_hppa_elf_get_symbol_type): New function.
4091 (elf_backend_get_symbol_type): Define.
4092 (elf64_hppa_object_p): Set architecture and machine from elf
4095 2001-01-30 Curtis L. Janssen <cljanss@ca.sandia.gov>
4097 * elf64-alpha.c (elf64_alpha_find_nearest_line): Query dwarf2
4100 2001-01-26 Richard Henderson <rth@redhat.com>
4102 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Return false
4103 for non-default visibility.
4104 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise, but
4105 delete ugly macro and replace with pretty function.
4107 2001-01-25 Mark Elbrecht <snowball3@bigfoot.com>
4109 * coff-go32.c: Update copyright.
4110 * coff-stgo32.c: Likewise.
4111 * coff-go32.c (COFF_LONG_FILENAMES): Define.
4112 * coff-stgo32.c (COFF_LONG_FILENAMES): Likewise.
4113 * coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Remove .bss entry.
4114 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
4116 2001-01-25 Kazu Hirata <kazu@hxi.com>
4118 * bfd-in2.h: Rebuild.
4119 * libbfd.h: Likewise.
4121 2001-01-23 H.J. Lu <hjl@gnu.org>
4123 * bfd-in2.h: Rebuild.
4125 2001-01-23 H.J. Lu <hjl@gnu.org>
4127 * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_buf)
4128 is NULL or PRIV(vms_rec) is outside of the buffer.
4130 2001-01-23 Kazu Hirata <kazu@hxi.com>
4132 * coff64-rs6000.c: Fix formatting.
4133 * coff-arm.c: Likewise.
4134 * coffgen.c: Likewise.
4135 * cofflink.c: Likewise.
4136 * coff-mcore.c: Likewise.
4137 * coff-mips.c: Likewise.
4138 * coff-pmac.c: Likewise.
4139 * coff-ppc.c: Likewise.
4140 * coff-rs6000.c: Likewise.
4141 * elf32.c: Likewise.
4142 * elf32-fr30.c: Likewise.
4143 * elf32-i370.c: Likewise.
4144 * elf32-i860.c: Likewise.
4145 * elf32-m32r.c: Likewise.
4146 * elf32-m68k.c: Likewise.
4147 * elf32-mcore.c: Likewise.
4148 * elf32-ppc.c: Likewise.
4149 * elf32-sh.c: Likewise.
4150 * elf32-v850.c: Likewise.
4151 * elf64-alpha.c: Likewise.
4152 * elf64-sparc.c: Likewise.
4153 * elflink.c: Likewise.
4154 * elflink.h: Likewise.
4155 * elf-m10200.c: Likewise.
4156 * elf-m10300.c: Likewise.
4157 * elfxx-ia64.c: Likewise.
4159 * aoutx.h: Fix formatting.
4161 * bfd-in2.h: Likewise.
4162 * bfd-in.h: Likewise.
4163 * cpu-i386.c: Likewise.
4164 * cpu-m68hc11.c: Likewise.
4165 * dwarf2.c: Likewise.
4166 * elf64-x86-64.c: Likewise.
4167 * format.c: Likewise.
4168 * freebsd.h: Likewise.
4170 * hp300hpux.c: Likewise.
4171 * hppabsd-core.c: Likewise.
4172 * hpux-core.c: Likewise.
4174 2001-01-22 Bo Thorsen <bo@suse.de>
4176 * elf64-x86-64.c: Added PIC support for X86-64.
4177 (elf64_x86_64_link_hash_newfunc): Function added.
4178 (elf64_x86_64_link_hash_table_create): Likewise.
4179 (elf64_x86_64_check_relocs): Likewise.
4180 (elf64_x86_64_gc_mark_hook): Likewise.
4181 (elf64_x86_64_gc_sweep_hook): Likewise.
4182 (elf64_x86_64_adjust_dynamic_symbol): Likewise.
4183 (elf64_x86_64_size_dynamic_sections): Likewise.
4184 (elf64_x86_64_discard_copies): Likewise.
4185 (elf64_x86_64_finish_dynamic_symbol): Likewise.
4186 (elf64_x86_64_finish_dynamic_sections): Likewise.
4187 (elf64_x86_64_relocate_section): Add relocation of PIC sections.
4189 2001-01-21 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
4191 * Makefile.am (install-data-local): Make use of $(DESTDIR).
4192 * Makefile.in: Regenerate.
4194 2001-01-21 Kazu Hirata <kazu@hxi.com>
4196 * coff-a29k.c: Fix formatting.
4198 2001-01-19 H.J. Lu <hjl@gnu.org>
4200 * elf32-i386.c (elf_i386_check_relocs): Report files with bad
4201 relocation section names.
4202 (elf_i386_relocate_section): Report files with bad relocation
4203 section names and return false.
4205 2001-01-17 Bo Thorsen <bo@suse.de>
4207 * targets.c: Alphabetize list of xvecs.
4209 2001-01-14 Alan Modra <alan@linuxcare.com.au>
4211 * config.bfd: Add linux target variant for elfxx-hppa.
4212 * configure.in: Recognize bfd_elf32_hppa_linux_vec and
4213 bfd_elf64_hppa_linux_vec.
4214 * configure: Regenerate.
4215 * elf64-hppa.c: Include elf64-target.h again to support linux
4217 (elf64_hppa_post_process_headers): Set ELFOSABI_LINUX for linux.
4218 * elf32-hppa.c: Include elf32-target.h again to support linux
4220 (elf32_hppa_post_process_headers): New function.
4221 (elf_backend_post_process_headers): Define.
4222 * targets.c (bfd_target_vector): Add bfd_elf64_hppa_linux_vec and
4223 bfd_elf32_hppa_linux_vec.
4225 * elf32-hppa.c (elf32_hppa_link_hash_table): Add text_segment_base,
4226 and data_segment_base fields.
4227 (elf32_hppa_link_hash_table_create ): Init them.
4228 (elf32_hppa_check_relocs): Update comments.
4229 (hppa_record_segment_addr): New function.
4230 (elf32_hppa_relocate_section): Call it.
4231 (final_link_relocate): Handle R_PARISC_SEGREL32.
4232 (elf32_hppa_final_link): New function.
4233 (bfd_elf32_bfd_final_link): Define to call it.
4234 (hppa_unwind_entry_compare): New function.
4235 * cache.c (bfd_open_file): Create files in write+read mode.
4237 * elf-hppa.h (elf_hppa_howto_table): Set bitsize value for
4238 SEGREL32 and numerous other relocs. Change duplicate
4239 R_PARISC_NONE relocs to R_PARISC_UNIMPLEMENTED.
4241 * opncls.c (bfd_fdopenr): Add parens like the comment says around
4244 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Don't create
4245 .plt entries for DT_INIT and DT_FINI.
4246 (elf32_hppa_finish_dynamic_sections): Remove special handling of
4247 DT_INIT and DT_FINI.
4249 * elf64-hppa.c (elf64_hppa_finish_dynamic_symbol): Use 16-bit
4250 offsets for stub .plt access if wide mode. Check offset in range.
4252 2001-01-13 Nick Clifton <nickc@redhat.com>
4254 * elf32-fr30.c (fr30_elf_howto_table): Remove spurious blank
4257 * coffcode.h (coff_canonicalize_reloc): Remove spurious blank
4260 2001-01-12 Alan Modra <alan@linuxcare.com.au>
4262 * configure.in ([bfd_elf64_x86_64_vec]): Set target64.
4263 * configure: Regenerate.
4265 2001-01-11 Peter Targett <peter.targett@arccores.com>
4267 * bfd-in2.h (bfd_architecture): Add bfd_mach_arc_5,
4268 bfd_mach_arc_6, bfd_mach_arc_7, bfd_mach_arc_8 for ARC variants.
4269 * cpu-arc.c (arch_info_struct): Add entries for variants.
4270 (bfd_arc_arch) Set default to bfd_mach_arc_5.
4271 (arc_get_mach) Don't assume machine names prefixed arc- before
4273 * elf32-arc.c (arc_elf_object_p): Set machine number based on new
4275 (arc_elf_final_write_processing) Likewise.
4276 (ELF_MACHINE_CODE) Use EM_ARC.
4278 2001-01-10 Nick Clifton <nickc@redhat.com>
4280 * coff-arm.c (LOCAL_LABEL_PREFIX): Change definition to "".
4282 2001-01-07 Philip Blundell <philb@gnu.org>
4284 * README: Replace `bug-gnu-utils@gnu.org' with
4285 `bug-binutils@gnu.org'.
4287 2001-01-04 Kazu Hirata <kazu@hxi.com>
4289 * som.c: Fix formatting.
4291 2001-01-03 Kazu Hirata <kazu@hxi.com>
4293 * ecoffswap.h: Fix formatting.
4294 * elf-bfd.h: Likewise.
4295 * elfarm-nabi.c: Likewise.
4296 * elfarm-oabi.c: Likewise.
4297 * elfcode.h: Likewise.
4298 * elfcore.h: Likewise.
4299 * elflink.c: Likewise.
4300 * elflink.h: Likewise.
4301 * elfxx-ia64.c: Likewise.
4302 * elfxx-target.h: Likewise.
4303 * libbfd.c: Likewise
4304 * linker.c: Likewise.
4305 * lynx-core.c: Likewise.
4307 2001-01-02 Kazu Hirata <kazu@hxi.com>
4309 * pc532-mach.c: Fix formatting.
4310 * pe-arm.c: Likewise.
4311 * pe-i386.c: Likewise.
4312 * pe-mips.c: Likewise.
4313 * pe-ppc.c: Likewise.
4314 * pe-sh.c: Likewise.
4315 * pei-mips.c: Likewise.
4316 * pei-sh.c: Likewise.
4317 * peicode.h: Likewise.
4318 * ppcboot.c: Likewise.
4319 * ptrace-core.c: Likewise.
4321 2001-01-01 Kazu Hirata <kazu@hxi.com>
4323 * reloc.c: Fix formatting.
4324 * riscix.c: Likewise.
4325 * rs6000-core.c: Likewise.
4326 * xcoff-target.h: Likewise.
4328 2000-12-29 Hans-Peter Nilsson <hp@bitrange.com>
4330 * elfcode.h (elf_object_p): Also restore the bfd mach field on
4331 error, by calling bfd_default_set_arch_mach with incoming
4334 2000-12-26 Kazu Hirata <kazu@hxi.com>
4336 * vaxnetbsd.c: Fix formatting.
4337 * versados.c: Likewise.
4338 * vms-gsd.c: Likewise.
4339 * vms-hdr.c: Likewise.
4340 * vms-misc.c: Likewise.
4342 2000-12-25 Alexandre Oliva <aoliva@redhat.com>
4344 * archive.c (coff_write_armap): Don't write more than symbol_count
4345 `archive_member_file_ptr's.
4347 2000-12-25 Kazu Hirata <kazu@hxi.com>
4349 * vms-tir.c: Fix formatting.
4351 2000-12-23 Kazu Hirata <kazu@hxi.com>
4353 * vms.c: Fix formatting.
4356 2000-12-21 Santeri Paavolainen <santtu@ssh.com>
4358 * vms-hdr.c: Include alloca.h if HAVE_ALLOCA_H is defined.
4360 * peicode.h (pe_ILF_object_p): Add const to import of TARGET_LITTLE_SYM.
4362 * elf32-m32r.c (m32r_elf_generic_reloc): Add cast to avoid (void *)
4365 * elf32-fr30.c: Add casts to avoid (void *) arithmetic.
4367 * coffcode.h (styp_to_sec_flags): Add empty statement after label.
4369 2000-12-21 Richard Sandiford <rsandifo@redhat.com>
4371 * libbfd.c (bfd_get_bits): Added
4372 (bfd_put_bits): Likewise
4373 * bfd-in.h: Declared the above.
4374 * bfd-in2.h: Regenerated.
4376 2000-12-20 Kazu Hirata <kazu@hxi.com>
4378 * targets.c: Fix formatting.
4379 * tekhex.c: Likewise.
4380 * trad-core.c: Likewise.
4382 2000-12-19 Kazu Hirata <kazu@hxi.com>
4384 * sco5-core.c: Fix formatting.
4385 * section.c: Likewise.
4386 * sparclinux.c: Likewise.
4387 * sparclynx.c: Likewise.
4388 * sparcnetbsd.c: Likewise.
4390 * stabs.c: Likewise.
4391 * stab-syms.c: Likewise.
4392 * sunos.c: Likewise.
4394 * sysdep.h: Likewise.
4396 2000-12-18 Nick Clifton <nickc@redhat.com>
4398 * coff-arm.c (EXTRA_S_FLAGS): Only define if not already
4400 * epoc-pe-arm.c (EXTRA_S_FLAGS): Define.
4401 * epoc-pei-arm.c (EXTRA_S_FLAGS): Define.
4403 2000-12-18 Nick Clifton <nickc@redhat.com>
4405 * vms-misc.c (_bfd_vms_get_record): Add default case to
4408 2000-12-15 Miloslav Trmac <mitr@volny.cz>
4410 * elfcore.h (elf_core_file_p): Move to the start of the program
4411 headers before attempting to read them.
4413 2000-12-14 Kazu Hirata <kazu@hxi.com>
4415 * peigen.c: Fix formatting.
4419 2000-12-13 Kazu Hirata <kazu@hxi.com>
4421 * peigen.c: Fix formatting.
4423 2000-12-12 Jim Wilson <wilson@redhat.com>
4425 * elfxx-ia64.c (get_dyn_sym_info): Cast %p argument to void *.
4427 2000-12-08 Mark Salter <msalter@redhat.com>
4429 * binary.c (binary_set_section_contents): Ignore sections
4432 2000-12-12 Kazu Hirata <kazu@hxi.com>
4434 * m68klinux.c: Fix formatting.
4435 * m68knetbsd.c: Likewise.
4436 * mipsbsd.c: Likewise.
4437 * netbsd-core.c: Likewise.
4438 * netbsd.h: Likewise.
4439 * newsos3.c: Likewise.
4440 * nlm32-alpha.c: Likewise.
4441 * nlm32-i386.c: Likewise.
4442 * nlm32-ppc.c: Likewise.
4443 * nlm32-sparc.c: Likewise.
4444 * nlmcode.h: Likewise.
4445 * nlmswap.h: Likewise.
4446 * nlm-target.h: Likewise.
4447 * ns32knetbsd.c: Likewise.
4449 2000-12-10 Fred Fish <fnf@be.com>
4451 * elflink.h (elf_link_output_extsym): Don't complain about undefined
4452 symbols in shared objects if allow_shlib_undefined is true.
4454 2000-12-12 Nick Clifton <nickc@redhat.com>
4456 * cpu-sh.c: Fix formattng.
4457 * elf.c: Fix formattng.
4458 * elf32-mips.c: Fix formattng.
4459 * elf32-sh.c: Fix formattng.
4460 * elf64-alpha.c: Fix formattng.
4462 2000-12-09 Nick Clifton <nickc@redhat.com>
4464 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Pass
4465 dwarf2_find_line_info as last parameter to invocation of
4466 _bfd_dwarf2_find_nearest_line.
4467 * elf32-arm.h (elf32_arm_find_nearest_line): Pass
4468 dwarf2_find_line_info as last parameter to invocation of
4469 _bfd_dwarf2_find_nearest_line.
4471 2000-12-08 Mark Elbrecht <snowball3@bigfoot.com>
4473 * Makefile.am (BFD32_BACKENDS): Move dwarf2.lo from here...
4474 (BFD_LIBS): ...to here.
4475 (BFD32_BACKENDS_CFILES): Move dwarf2.c from here...
4476 (BFD_LIBS_CFILES): ...to here.
4477 * Makefile.in: Regenerate.
4478 * configure.in: Remove dwarf.lo from the elf shell variable.
4479 * configure: Regenerate.
4480 * libcoff-in.h (coff_tdata): Add pointer dwarf2_find_line_info.
4481 * libcoff.h: Regenerate.
4482 * coffgen.c (coff_find_nearest_line): Call
4483 _bfd_dwarf2_find_nearest_line.
4484 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Add parameter. Update
4486 (read_abbrevs): Likewise
4487 (decode_line_info): Likewise.
4488 (parse_comp_unit): Likewise.
4489 (comp_unit_find_nearest_line): Likewise.
4490 * libbfd-in.h (_bfd_dwarf2_find_nearest_line): Update prototype.
4491 * libbfd.h: Regenerate.
4492 * elf.c (_bfd_elf_find_nearest_line): Update call.
4493 * elf-bfd.h (elf_obj_tdata): Change dwarf2_find_line_info to type PTR.
4494 * dwarf2.c (concat_filename): Use IS_ABSOLUTE_PATH.
4495 * coffcode.h (STYP_XCOFF_DEBUG, STYP_DEBUG_INFO): New macros.
4496 (sec_to_styp_flags): Use them. Handle DWARF2 sections.
4497 (styp_to_sec_flags): Handle DWARF2 sections.
4498 * elf32-arm.h (elf32_arm_find_nearest_line): Add parameter to call
4499 to _bfd_find_nearest_line.
4500 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Add parameter to
4501 call to _bfd_find_nearest_line.
4503 2000-12-08 Kazu Hirata <kazu@hxi.com>
4505 * coffgen.c: Fix formatting.
4506 * elf-m10300.c: Likewise.
4507 * elf32-i386.c: Likewise.
4508 * elf32-i960.c: Likewise.
4509 * elf32-m68k.c: Likewise.
4510 * elf32-mcore.c: Likewise.
4511 * elf32-ppc.c: Likewise.
4512 * elf32-sh.c: Likewise.
4513 * elf32-sparc.c: Likewise.
4514 * elf32-v850.c: Likewise.
4515 * elf64-alpha.c: Likewise.
4516 * elf64-hppa.c: Likewise.
4517 * elf64-mips.c: Likewise.
4518 * elf64-sparc.c: Likewise.
4520 2000-12-07 Kazu Hirata <kazu@hxi.com>
4522 * elf32-ppc.c: Fix formatting.
4523 * elf64-x86-64.c: Likewise.
4525 2000-12-06 Ulf Carlsson <ulfc@engr.sgi.com>
4527 From Ralf Baechle <ralf@gnu.org>
4529 * elf32-mips.c (elf32_mips_merge_private_bfd_data): Always permit
4530 BFDs containing no sections or empty .text, .data or .bss sections
4531 to be merged, regardless of their flags.
4533 2000-12-06 Kazu Hirata <kazu@hxi.com>
4535 * elf32-m32r.c: Fix formatting.
4536 * elf32-m68hc11.c: Likewise.
4537 * elf32-m68hc12.c: Likewise.
4538 * elf32-m68k.c: Likewise.
4539 * elf32-mcore.c: Likewise.
4540 * elf32-pj.c: Likewise.
4541 * elf32-ppc.c: Likewise.
4543 2000-12-05 Kazu Hirata <kazu@hxi.com>
4545 * elf32-fr30.c: Fix formatting.
4546 * elf32-hppa.c: Likewise.
4547 * elf32-i370.c: Likewise.
4548 * elf32-i386.c: Likewise.
4549 * elf32-i860.c: Likewise.
4550 * elf32-i960.c: Likewise.
4552 2000-12-03 Kazu Hirata <kazu@hxi.com>
4554 * elf32-arm.h: Fix formatting.
4555 * elf32-avr.c: Likewise.
4556 * elf32-cris.c: Likewise.
4557 * elf32-d10v.c: Likewise.
4558 * elf32-d30v.c: Likewise.
4559 * elf-hppa.h: Likewise.
4560 * elf-m10200.c: Likewise.
4561 * elf-m10300.c: Likewise.
4563 2000-12-01 Chris Demetriou <cgd@sibyte.com>
4565 * aoutx.h (NAME(aout,machine_type)): Add bfd_mach_mips32 and
4566 bfd_mach_mips32_4k. Update FIXME comment.
4567 * archures.c (bfd_mach_mips32): New constant.
4568 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
4569 the latter, renumber it.
4570 * bfd-in2.h (bfd_mach_mips32): New constant.
4571 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
4572 the latter, renumber it.
4573 * cpu-mips.c (I_mips32): New constant.
4574 (I_mips4K, I_mips32_4k): Rename the former to the latter.
4575 (arch_info_struct): Add bfd_mach_mips32 entry, replace
4576 bfd_mach_mips4K entry with bfd_mach_mips32_4k entry.
4577 * elf32-mips.c (elf_mips_isa): Add E_MIPS_ARCH_32 case.
4578 (elf_mips_mach): Likewise. Also, replace E_MIPS_MACH_MIPS32
4579 with E_MIPS_MACH_MIPS32_4K.
4580 (_bfd_mips_elf_final_write_processing): Replace
4581 bfd_mach_mips4K with bfd_mach_mips32_4k case, add
4582 bfd_mach_mips32 case.
4583 (_bfd_mips_elf_merge_private_bfd_data): Generalize ISA mixing
4584 comparison with support for MIPS32.
4585 (_bfd_mips_elf_print_private_bfd_data): Print ISA name for
4588 * aoutx.h (NAME(aout,machine_type)): Add cases for
4589 bfd_mach_mips5 and bfd_mach_mips64.
4590 * archures.c (bfd_mach_mips5, bfd_mach_mips64): New constants.
4591 * bfd-in2.h (bfd_mach_mips5, bfd_mach_mips64): Likewise.
4592 * cpu_mips.c (I_mips5, I_mips64): New definitions.
4593 (arch_info_struct): Add entries for bfd_mach_mips5 and
4595 * elf32-mips.c (elf_mips_isa, elf_mips_mach,
4596 _bfd_mips_elf_print_private_bfd_data): Add cases for
4597 E_MIPS_ARCH_5 and E_MIPS_ARCH_64.
4598 (_bfd_mips_elf_final_write_processing): Add cases for
4599 bfd_mach_mips5 and bfd_mach_mips64.
4601 * aoutx.h (NAME(aout,machine_type)): Add a
4602 bfd_mach_mips_sb1 case.
4603 * archures.c (bfd_mach_mips_sb1): New constant.
4604 * bfd-in2.h (bfd_mach_mips_sb1): New constant.
4605 * cpu-mips.c (I_sb1): New constant.
4606 (arch_info_struct): Add entry for bfd_mach_mips_sb1.
4607 * elf32-mips.c (elf_mips_mach): Add case for
4609 (_bfd_mips_elf_final_write_processing): Add case for
4612 2000-12-01 Joel Sherrill <joel@OARcorp.com>
4614 * config.bfd (arm-*-rtems*, a29k-*rtems*): New targets.
4615 (sparc*-*-rtemself*, sparc*-*-rtemsaout*): New targets.
4616 (sparc*-*-rtems*): Switched from a.out to ELF.
4618 2000-11-30 Jan Hubicka <jh@suse.cz>
4620 * Makefile.am (BFD64_BACKENDS): Add elf64-x86-64.lo
4621 BFD64_BACKENDS_CFILES): Add elf64-x86-64.c
4622 (elf64-x86-64.lo): Add dependencies.
4623 * archures.c (DESCRIPTION): Add bfd_mach_x86_64,
4624 bfd_mach_x86_64_intel_syntax.
4625 * elf.c (prep_headers): Use EM_x86_64 for 64bit output.
4626 * config.bfd (x86_64): Add.
4627 * configure.in: Add support for bfd_elf64_x86_64_vec.
4628 * cpu-i386.c (bfd_x86_64_arch_intel_syntax, bfd_x86_64_arch): Add.
4629 (bfd_i386_arch, i8086_ar): Link in.
4630 * elf64-x86-64.c: New file.
4631 * reloc.c (ENUMDOC): Add BFD_RELOC_X86_64*.
4632 * targets.c (bfd_elf64_x86_64_vec): Add.
4633 (bfd_target_vect): Add bfd_elf64_x86_64_vec.
4635 2000-11-30 Kazu Hirata <kazu@hxi.com>
4637 * xcofflink.c: Fix formatting.
4639 2000-11-28 Kazu Hirata <kazu@hxi.com>
4641 * aoutx.h: Fix formatting.
4642 * bfd-in.h: Likewise.
4643 * bfd-in2.h: Likewise.
4644 * cache.c: Likewise.
4645 * cisco-core.c: Likewise.
4646 * coff64-rs6000.c: Likewise.
4647 * coffcode.h: Likewise.
4648 * coffswap.h: Likewise.
4649 * corefile.c: Likewise.
4650 * elf32-mips.c: Likewise.
4652 2000-11-27 Kazu Hirata <kazu@hxi.com>
4654 * aout-adobe.c: Fix formatting.
4655 * coff64-rs6000.c: Likewise.
4656 * coffgen.c: Likewise.
4657 * cofflink.c: Likewise.
4659 2000-11-27 Philip Blundell <pb@futuretv.com>
4661 * libcoff-in.h (coff_tdata): Add `strings_written' flag.
4662 (obj_coff_strings_written): New accessor macro for above.
4663 * libcoff.h: Regenerate.
4664 * cofflink.c (_bfd_coff_final_link): Say that we wrote the
4666 * coffcode.h (coff_write_object_contents): No need to write out
4667 the string table if it's already been done.
4669 2000-11-22 Philip Blundell <pb@futuretv.com>
4671 * cofflink.c (_bfd_coff_generic_relocate_section): Don't object to
4672 weak undefined symbols.
4674 2000-11-24 Nick Clifton <nickc@redhat.com>
4676 * archures.c (bfd_mach_arm_5TE): Define.
4677 (bfd_mach_arm+XScale): Define.
4678 * bfd-in2.h: Regenerate.
4680 * coff-arm.c (coff_arm_reloc_type_lookup): Accept
4681 BFD_RELOC_ARM_PCREL_BLX.
4683 * coffcode.h (coff_set_flags): Set flags for 5t, 5te and
4684 XScale machine numbers.
4686 * config.bfd (xscale-elf): Add target.
4687 (xscale-coff): Add target.
4689 * cpu-arm.c: Add xscale machine name.
4690 Add v5t, v5te and XScale machine numbers.
4692 2000-11-23 Kazu Hirata <kazu@hxi.com>
4694 * aix386-core.c: Fix formatting.
4696 2000-11-22 Jim Wilson <wilson@redhat.com>
4698 * coff-ia64.c (howto_table): Use EMPTY_HOWTO.
4699 (in_reloc_p): Add ATTRIBUTE_UNUSED to unused parameters.
4700 * cpu-ia64-opc.c (ins_rsvd, ext_rsvd, ins_const, ext_const): Likewise.
4701 (ins_imms_scaled): Initialize sign_bit at function entry.
4702 (elf64_ia64_operands): Add missing initializers.
4703 * elfxx-ia64.c (elfNN_ia64_reloc, elfNN_ia64_reloc_type_lookup,
4704 elfNN_ia64_info_to_howto, elfNN_ia64_fake_sections,
4705 elfNN_ia64_add_symbol_hook, elfNN_ia64_is_local_label_name,
4706 elfNN_ia64_local_hash_table_init, get_fptr, get_pltoff,
4707 elfNN_ia64_adjust_dynamic_symbol): Add ATTRIBUTE_UNUSED for unused
4709 (elfNN_ia64_info_to_howto): Initialize free_relocs, free_contents,
4710 and free_extsyms at function entry.
4711 (elfNN_add_symbol_hook): Add unsigned cast to bfd_get_gp_size result.
4712 (elfNN_ia64_create_dynamic_sections): Delete unused local h.
4713 (get_got): Delete unused local srel.
4714 (elfNN_ia64_check_relocs): Initialize dynrel_type when declared.
4715 (elfNN_ia64_relocate_section): Delete unused local dynindx.
4717 2000-11-21 Kazu Hirata <kazu@hxi.com>
4719 * coff-a29k.c: Fix formatting.
4720 * coff-h8500.c: Likewise.
4721 * coff-i960.c: Likewise.
4722 * coff-ppc.c: Likewise.
4723 * coff-rs6000.c: Likewise.
4724 * coff-stgo32.c: Likewise.
4725 * coff-tic54x.c: Likewise.
4726 * coff-w65.c: Likewise.
4727 * cpu-h8500.c: Likewise.
4728 * cpu-hppa.c: Likewise.
4729 * cpu-ns32k.c: Likewise.
4730 * ecoff.c: Likewise.
4731 * ecofflink.c: Likewise.
4733 2000-11-21 Nick Clifton <nickc@redhat.com>
4735 * elf32-sh.c (sh_elf_reloc_loop): Fix compile time warning, and
4736 remove possibility of infinite loop.
4738 2000-11-20 Kazu Hirata <kazu@hxi.com>
4740 * aix386-core.c: Fix formatting.
4741 * aout-adobe.c: Likewise.
4742 * aout-arm.c: Likewise.
4743 * aout-encap.c: Likewise.
4744 * aout-ns32k.c: Likewise.
4745 * aout-target.h: Likewise.
4746 * aout-tic30.c: Likewise.
4747 * aoutf1.h: Likewise.
4748 * aoutx.h: Likewise.
4749 * archive.c: Likewise.
4750 * bfd-in.h: Likewise.
4751 * bfd-in2.h: Likewise.
4755 2000-11-17 H.J. Lu <hjl@gnu.org>
4757 * elfxx-ia64.c (elfNN_ia64_size_dynamic_sections): Don't create
4758 pltoff entries for DT_INIT and DT_FINI.
4759 (elfNN_ia64_final_link): Don't set DT_INIT/FINI entries.
4760 (elfNN_ia64_finish_dynamic_sections): Don't fill in DT_INIT/FINI
4763 2000-11-16 Richard Henderson <rth@redhat.com>
4765 * elfxx-ia64.c (elfNN_ia64_check_relocs): Handle IPLT relocs.
4766 (allocate_dynrel_entries): Likewise.
4767 (elfNN_ia64_relocate_section): Likewise. Set REL addends correctly.
4768 (set_pltoff_entry): Likewise.
4769 (ia64_howto_table): Remove R_IA64_SEGBASE, and R_IA64_EPLT[ML]SB
4770 (elfNN_ia64_reloc_type_lookup): Likewise.
4771 (elfNN_ia64_install_value): Likewise.
4772 (elfNN_ia64_relocate_section): Likewise.
4773 * reloc.c (BFD_RELOC_IA64_SEGBASE): Remove.
4774 (BFD_RELOC_IA64_EPLTMSB, BFD_RELOC_IA64_EPLTLSB): Remove.
4776 2000-11-16 Kazu Hirata <kazu@hxi.com>
4778 * cpu-a29k.c: Fix formatting.
4779 * cpu-alpha.c: Likewise.
4780 * cpu-arm.c: Likewise.
4781 * cpu-avr.c: Likewise.
4782 * cpu-d10v.c: Likewise.
4783 * cpu-h8500.c: Likewise.
4784 * cpu-hppa.c: Likewise.
4785 * cpu-i370.c: Likewise.
4786 * cpu-i386.c: Likewise.
4787 * cpu-i960.c: Likewise.
4788 * cpu-ia64-opc.c: Likewise.
4789 * cpu-ia64.c: Likewise.
4790 * cpu-m32r.c: Likewise.
4791 * cpu-m68hc11.c: Likewise.
4792 * cpu-m68hc12.c: Likewise.
4793 * cpu-m68k.c: Likewise.
4794 * cpu-m88k.c: Likewise.
4795 * cpu-mips.c: Likewise.
4796 * cpu-ns32k.c: Likewise.
4797 * cpu-pj.c: Likewise.
4798 * cpu-powerpc.c: Likewise.
4799 * cpu-sh.c: Likewise.
4800 * cpu-sparc.c: Likewise.
4801 * cpu-tic54x.c: Likewise.
4802 * cpu-v850.c: Likewise.
4803 * cpu-vax.c: Likewise.
4804 * cpu-w65.c: Likewise.
4805 * cpu-we32k.c: Likewise.
4806 * cpu-z8k.c: Likewise.
4807 * dwarf1.c: Likewise.
4808 * dwarf2.c: Likewise.
4810 2000-11-15 Kazu Hirata <kazu@hxi.com>
4812 * coff-arm.c: Fix formatting.
4813 * coff-ppc.c: Likewise.
4814 * coff-rs6000.c: Likewise.
4815 * coff-sh.c: Likewise.
4816 * coff-sparc.c: Likewise.
4817 * coff-tic30.c: Likewise.
4818 * coff-tic54x.c: Likewise.
4819 * coff-tic80.c: Likewise.
4820 * coff-w65.c: Likewise.
4821 * coff-we32k.c: Likewise.
4822 * coff-z8k.c: Likewise.
4824 2000-11-15 Richard Henderson <rth@redhat.com>
4826 * elf64-alpha.c (elf64_alpha_check_relocs): Create the reloc
4827 section with the same ALLOC|LOAD flags as the source section.
4829 2000-11-14 Jakub Jelinek <jakub@redhat.com>
4831 * elf64-alpha.c (elf64_alpha_relax_opt_call): Only check bits used
4832 by STO_ALPHA constants.
4834 2000-11-14 Kazu Hirata <kazu@hxi.com>
4836 * coff-pmac.c: Fix formatting.
4837 * coff-ppc.c: Likewise.
4839 2000-11-13 H.J. Lu <hjl@gnu.org>
4841 * elflink.h (elf_link_add_object_symbols): Also add indirect
4842 symbols for common symbols with the default version.
4844 2000-11-09 Philip Blundell <pb@futuretv.com>
4846 * section.c (STD_SECTION): Set gc_mark flag.
4848 2000-11-11 Kazu Hirata <kazu@hxi.com>
4850 * coff-i960.c: Likewise.
4851 * coff-m68k.c: Likewise.
4852 * coff-m88k.c: Likewise.
4853 * coff-mcore.c: Likewise.
4854 * coff-mips.c: Likewise.
4856 2000-11-11 Bernd Schmidt <bernds@cygnus.co.uk>
4858 * elf32-sh.c (sh_elf_relocate_section): Ignore R_SH_NONE relocs.
4860 2000-11-10 Kazu Hirata <kazu@hxi.com>
4862 * coff-h8300.c: Fix formatting.
4863 * coff-h8500.c: Likewise.
4864 * coff-i386.c: Likewise.
4865 * coff-i860.c: Likewise.
4866 * coff-i960.c: Likewise.
4867 * coff-ia64.c: Likewise.
4869 2000-11-09 Kazu Hirata <kazu@hxi.com>
4871 * archive.c: Fix formatting.
4872 * archures.c: Likewise.
4874 2000-11-07 Richard Henderson <rth@redhat.com>
4876 * elfxx-ia64.c (elf64_ia64_final_link): New local unwind_output_sec.
4877 Set it before bfd_elf64_bfd_final_link call. Use it after the call.
4878 * section.c (bfd_set_section_contents): Call memcpy if
4879 section->contents set and location not equal to contents plus offset.
4881 2000-11-08 Kazu Hirata <kazu@hxi.com>
4883 * bfd-in.h: Fix formatting.
4884 * bfd-in2.h: Likewise.
4886 * binary.c: Likewise.
4888 * coff-a29k.c: Likewise.
4889 * coff-alpha.c: Likewise.
4890 * coff-apollo.c: Likewise.
4891 * coff-aux.c: Likewise.
4893 2000-11-07 Kazu Hirata <kazu@hxi.com>
4895 * aix386-core.c: Fix formatting.
4896 * aoutf1.h: Likewise.
4897 * aoutx.h: Likewise.
4898 * archures.c: Likewise.
4899 * armnetbsd.c: Likewise.
4901 2000-11-07 Alan Modra <alan@linuxcare.com.au>
4903 * coff-h8300.c (special): Adjust reloc address.
4905 2000-11-06 Steve Ellcey <sje@cup.hp.com>
4907 * archures.c (bfd_mach_ia64_elf64, bfd_mach_ia64_elf32): Add defines
4908 to differentiate elf32 and elf64 on ia64.
4909 * bfd-in2.h: Regenerate.
4910 * config.bfd: Add target for "ia64*-*-hpux*".
4911 * configure.in: Add bfd_elf32_ia64_big_vec to selvecs switch.
4912 * configure: Regenerate.
4913 * cpu-ia64.c (bfd_ia64_elf32_arch): Add elf32 arch info structure.
4914 * targets.c: Add bfd_target bfd_elf32_ia64_big_vec.
4916 * Makefile.am: Make elf32-ia64.c and elf64-ia64.c derived objects
4917 from elfxx-ia64.c. Add depenency rules for making elf32-ia64.lo.
4918 * Makefile.in: Regnerate.
4919 * elf64-ia64.c: Deleted.
4920 * elfxx-ia64.c: New file, paramaterized version of elf64-ia64.c.
4922 2000-11-06 Kazu Hirata <kazu@hxi.com>
4924 * aout-adobe.c: Fix formatting.
4925 * aout-arm.c: Likewise.
4926 * aout-cris.c: Likewise.
4927 * aout-encap.c: Likewise.
4928 * aout-ns32k.c: Likewise.
4929 * aout-target.h: Likewise.
4930 * aout-tic30.c: Likewise.
4932 2000-11-05 Philip Blundell <philb@gnu.org>
4934 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Always permit
4935 BFDs containing no sections to be merged, regardless of their flags.
4937 2000-11-04 Philip Blundell <philb@gnu.org>
4939 * elf32-arm.h (elf32_arm_relocate_section): Suppress error message
4940 if a relocation for an undefined symbol also results in an
4943 2000-11-06 Christopher Faylor <cgf@cygnus.com>
4945 * config.bfd: Add support for Sun Chorus.
4947 2000-11-05 David O'Brien <obrien@FreeBSD.org>
4949 * configure.in: Recognize alpha-*-freebsd*.
4950 * configure: Regenerate.
4952 2000-11-02 Luciano Gemme <ishitawa@yahoo.com>
4954 * srec.c (CHUNK): Rename to DEFAULT_CHUNK.
4955 (Chunk): New global variable set by a parameter in objcopy.c.
4956 (S3Forced): New global variable set by a parameter in
4958 (srec_set_section_contents): If S3Forced is true, always generate
4960 (srec_write_section): Use 'Chunk' to limit maximum length of S
4963 2000-11-02 Per Lundberg <plundis@chaosdev.org>
4965 * config.bfd: Add support for i[3456]86-chaosdev-storm-chaos.
4966 * Makefile.in: Regenerate.
4967 * bfd-in2.h: Regenerate.
4968 * po/bfd.pot: Regenerate.
4970 2000-10-31 Philip Blundell <philb@gnu.org>
4972 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Only handle
4973 EF_SOFT_FLOAT if it is defined.
4975 2000-10-27 Philip Blundell <philb@gnu.org>
4977 * elf32-arm.h (elf32_arm_copy_private_bfd_data): Don't refuse
4978 attempts to mix PIC code with non-PIC, just mark the output as
4979 being position dependent.
4980 (elf32_arm_merge_private_bfd_data): Likewise. Print an error
4981 message for EF_SOFT_FLOAT mismatches. Display diagnostics for
4982 all mismatches, not just the first one.
4984 2000-10-25 Chris Demetriou <cgd@sibyte.com>
4986 * ieee.c (ieee_archive_p): Plug one of many possible
4987 memory leaks in error handling.
4989 2000-10-20 Jakub Jelinek <jakub@redhat.com>
4991 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data,
4992 elf32_sparc_object_p, elf32_sparc_final_write_processing):
4994 * elf64-sparc.c (sparc64_elf_merge_private_bfd_data,
4995 sparc64_elf_object_p): Support v9b.
4996 * archures.c: Declare v8plusb and v9b machines.
4998 * cpu-sparc.c: Ditto.
5000 2000-10-16 Geoffrey Keating <geoffk@shoggoth.cygnus.com>
5002 * elf64-sparc.c (sparc64_elf_relocate_section): Clear the location
5005 * elf32-ppc.c (SYMBOL_REFERENCES_LOCAL): New macro.
5006 (SYMBOL_CALLS_LOCAL): New macro.
5007 (ppc_elf_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL.
5008 (ppc_elf_check_relocs): Use SYMBOL_REFERENCES_LOCAL.
5009 (ppc_elf_finish_dynamic_symbol): Use SYMBOL_REFERENCES_LOCAL.
5010 (ppc_elf_relocate_section): Use flag variable to determine
5011 whether the relocation refers to a local symbol.
5012 Test whether a PLTREL24 reloc will produce a reloc by looking
5013 to see whether a PLT entry was made.
5015 2000-10-14 Geoffrey Keating <geoffk@shoggoth.cygnus.com>
5017 * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Don't make PLT
5018 entries that could serve as a definition for a weak symbol.
5020 2000-10-13 Ulf Carlsson <ulfc@engr.sgi.com>
5022 From Ralf Baechle <ralf@gnu.org>
5024 * elf32-mips.c (mips_elf_create_dynamic_relocation): New argument
5025 local_p. Add symbol value only for non-R_MIPS_REL32 relocations
5026 against local symbols.
5027 (_bfd_mips_elf_finish_dynamic_sections): Undo patch from 2000-10-01.
5029 2000-10-12 Alan Modra <alan@linuxcare.com.au>
5031 * section.c (struct sec): Add kept_section.
5032 (struct bfd_comdat_info): Remove sec, we can use above.
5033 (STD_SECTION): Add initializer.
5034 (bfd_make_section_anyway): Init here too.
5036 * bfd-in2.h: Regenerate.
5038 * elflink.h (elf_link_add_object_symbols): Remove unnecessary
5040 (elf_link_input_bfd): Set all asection->symbol->value's here, and
5041 fudge values for discarded link-once section symbols.
5043 * elf64-hppa.c: Include alloca-conf.h
5045 2000-10-11 Alan Modra <alan@linuxcare.com.au>
5047 * elf.c (swap_out_syms): Revert 2000-10-07 changes.
5049 * ieee.c (ieee_make_empty_symbol): Oops, bfd_zalloc needs another arg.
5051 2000-10-10 Alan Modra <alan@linuxcare.com.au>
5053 * ieee.c (ieee_make_empty_symbol): Use bfd_zalloc, not bfd_zmalloc.
5055 2000-10-10 Tom Rix <trix@redhat.com>
5057 * section.c (bfd_make_section_anyway): Release newsect ptr when
5058 newsect->symbol fails to alloc. Use bfd_release instead of free.
5060 2000-10-09 Richard Henderson <rth@cygnus.com
5062 * elf64-ia64.c (elf64_ia64_unwind_entry_compare_bfd): New.
5063 (elf64_ia64_unwind_entry_compare): New.
5064 (elf64_ia64_final_link): Sort the .IA_64.unwind section.
5066 2000-10-07 Alan Modra <alan@linuxcare.com.au>
5068 * elflink.h (size_dynamic_sections): Don't create various tags if
5069 .dynstr is excluded from the link. Don't set first dynsym entry
5070 if dynsymcount is zero.
5071 (elf_bfd_final_link): Don't try to swap out dynamic syms if
5072 .dynsym excluded from the link. Don't try to write any dynamic
5073 sections excluded from the link.
5075 * elf.c (swap_out_syms): Handle global section symbols.
5077 2000-10-05 DJ Delorie <dj@redhat.com>
5079 * peigen.c (_bfd_pei_swap_scnhdr_out): note extended relocs
5080 * coffcode.h (coff_set_alignment_hook): read extended reloc count
5081 (coff_write_relocs): write extended reloc count
5082 (coff_write_object_contents): account for extended relocs
5084 2000-10-05 Jim Wilson <wilson@cygnus.com>
5086 * elf-bfd.h (struct elf_backend_data): Add elf_backend_section_flags
5088 * elf.c (_bfd_elf_make_section_from_shdr): Call the
5089 elf_backend_section_flags function.
5090 * elf64-ia64.c (elf64_ia64_section_from_shdr): Delete flag conversion
5092 (elf64_ia64_section_flags): New function containing flag conversion
5094 (elf_backend_section_flags): Define to elf64_ia64_section_flags.
5095 * elfxx-target.h (elf_backend_section_flags): Define.
5096 (elfNN_bed): Initialize elf_backend_section_flags field.
5098 2000-10-02 Alan Modra <alan@linuxcare.com.au>
5100 * elf32-hppa.c (elf32_hppa_check_relocs): Correct call to
5101 _bfd_elf32_gc_record_vtable. Correct a comment.
5103 2000-10-01 Ulf Carlsson <ulfc@engr.sgi.com>
5105 From Ralf Baechle <ralf@gnu.org>
5107 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_sections): Mark gld
5108 produces binaries with got[1] = 0x80000001 to differenciate them
5109 for the dynamic linker from the broken binaries produced by old
5112 2000-09-30 Petr Sorfa <petrs@sco.com>
5114 * elf.c (elfcore_grok_pstatus): Check for size of pxstatus_t.
5115 (elfcore_grok_lwpstatus): Check for size of lwpxstatus_t.
5116 * configure.in: Add check for pxstatus_t and lwpxstatus_t.
5117 * configure: Regenerate.
5119 2000-09-27 Hans-Peter Nilsson <hp@axis.com>
5121 Define two bfd_targets for absence and presence of leading
5122 underscore on symbols. Make sure to only link same kind.
5123 * elf32-cris.c (cris_elf_object_p,
5124 cris_elf_final_write_processing, cris_elf_print_private_bfd_data,
5125 cris_elf_merge_private_bfd_data): New.
5126 (elf_backend_object_p, elf_backend_final_write_processing,
5127 bfd_elf32_bfd_print_private_bfd_data,
5128 bfd_elf32_bfd_merge_private_bfd_data): Define.
5129 <Target vector definition>: Include elf32-target.h twice with
5130 different macro settings:
5131 (TARGET_LITTLE_SYM): First as bfd_elf32_cris_vec, then as
5132 bfd_elf32_us_cris_vec.
5133 (TARGET_LITTLE_NAME): First as "elf32-cris", then "elf32-us-cris".
5134 (elf_symbol_leading_char): First as 0, then '_'.
5135 (INCLUDED_TARGET_FILE): Define for second include of elf32-target.h.
5136 * config.bfd (cris-*-*): Add bfd_elf32_us_cris_vec to targ_selvecs.
5137 * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vector.
5138 * configure: Regenerate.
5139 * targets.c: Declare bfd_elf32_us_cris_vec.
5140 * po/bfd.pot: Regenerate.
5142 2000-09-29 Momchil Velikov <velco@fadata.bg>
5144 * elf32-arm.h (arm_add_to_rel): Correctly adjust the addend for
5145 R_ARM_THM_PC22 relocations.
5147 2000-09-29 NIIBE Yutaka <gniibe@chroot.org>
5149 * elflink.h (elf_link_add_object_symbols): Don't bfd_release runpath.
5151 2000-09-29 Momchil Velikov <velco@fadata.bg>
5153 * elf.c (elf_fake_sections): Do not mark the section SHT_NOBITS if
5154 is has the SEC_HAS_CONTENTS flag set.
5156 2000-09-28
\81Örjan Friberg <orjanf@axis.com>
5157 Hans-Peter Nilsson <hp@axis.com>
5159 * aout-cris.c (N_TXTADDR): Define.
5161 2000-09-28 John David Anglin <dave@hiauly1.hia.nrc.ca>
5163 * som.c: Include alloca-conf.h.
5164 * Makefile.am: "make dep-am"
5165 * Makefile.in: Regenerate.
5167 2000-09-27 Alan Modra <alan@linuxcare.com.au>
5169 * elf32-hppa.c (plt_stub): New.
5170 (PLT_STUB_ENTRY): Define.
5171 (elf32_hppa_link_hash_table): Change multi_subspace to packed
5172 boolean. Add need_plt_stub, has_12bit_branch and has_17bit_branch.
5173 (elf32_hppa_link_hash_table_create): Init to suit.
5174 (elf32_hppa_check_relocs): Set has_12bit_branch and
5175 has_17bit_branch as appropriate.
5176 (elf32_hppa_adjust_dynamic_symbol): Set need_plt_stub for
5177 non-local functions.
5178 (elf32_hppa_size_dynamic_sections): Correct setting of reltext.
5179 Add space for plt_stub as needed.
5180 (elf32_hppa_finish_dynamic_symbol): Point .plt entries for global
5181 functions at plt_stub.
5182 (elf32_hppa_finish_dynamic_sections): Write plt_stub.
5183 (elf32_hppa_create_dynamic_sections): Leave .plt executable.
5185 * elf32-hppa.h (elf32_hppa_size_stubs): Add group_size param.
5186 * elf32-hppa.c (elf32_hppa_size_stubs): Likewise. Use it instead
5187 of fixed size, and if negative, disable handling of input sections
5188 before stub section. Set up default stub group size depending
5189 on detected branch relocs.
5190 (hppa_build_one_stub): Use lrsel and rrsel for import stubs to
5191 ensure different offsets from sym_value aren't rounded to
5192 different 2k blocks. Use lrsel and rrsel for other stubs too for
5193 consistency rather than necessity.
5194 (elf32_hppa_check_relocs): Handle R_PARISC_DIR14F.
5195 (final_link_relocate): Likewise.
5196 (elf32_hppa_relocate_section): Likewise.
5198 * elf-hppa.h (elf_hppa_howto_table): Add R_PARISC_DIR14F reloc.
5199 (_bfd_elf_hppa_gen_reloc_type): Generate them.
5200 (elf_hppa_final_link_relocate): Handle them.
5201 (elf_hppa_relocate_insn): Likewise.
5202 (_bfd_elf_hppa_gen_reloc_type): Add missing e_ldsel and e_rdsel cases.
5204 2000-09-26 Hans-Peter Nilsson <hp@axis.com>
5206 * elfcode.h (elf_object_p): Preserve and clear abfd section
5207 information. Restore at error.
5209 2000-09-26 Paul Sokolovsky <Paul.Sokolovsky@technologist.com>
5211 * peigen.c (_bfd_pei_swap_aouthdr_in): If some DataDirectory
5212 is empty, make sure that its rva also 0. NT loader dislikes
5215 2000-09-26 Steve Ellcey <sje@cup.hp.com>
5217 * som.c (som_bfd_derive_misc_symbol_info): Make weak symbols
5220 2000-09-21 Alan Modra <alan@linuxcare.com.au>
5222 * elf32-hppa.c (elf32_hppa_check_relocs): Fix weak sym handling in
5223 currently unused RELATIVE_DYNAMIC_RELOCS code.
5224 (hppa_discard_copies): Likewise.
5225 (elf32_hppa_size_stubs): Size `input_list' array correctly. Correct
5226 comments. Don't check non-code output sections for stub grouping.
5228 2000-09-20 Alan Modra <alan@linuxcare.com.au>
5230 * section.c (bfd_get_unique_section_name): Return NULL if
5233 2000-09-19 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5235 * elf32-m68k.c (elf_cpu32_plt0_entry): Change the PLT entry 0
5236 instruction sequence to actually work.
5237 (elf_m68k_finish_dynamic_sections): Change the patch-in offset
5240 2000-09-18 Alexandre Oliva <aoliva@redhat.com>
5242 * elf32-sh.c (sh_elf_relocate_section): Use
5243 _bfd_final_link_relocate to apply the relocation against a section
5244 symbol, when doing relocatable links.
5246 2000-09-18 Alan Modra <alan@linuxcare.com.au>
5248 * elf32-hppa.c (elf32_hppa_stub_hash_entry): Rename input_section
5250 (stub_hash_newfunc): Here too.
5251 (hppa_add_stub): And here.
5252 (elf32_hppa_link_hash_table): Remove stub_section_created,
5253 reloc_section_created, first_init_sec and first_fini_sec. Add
5255 (elf32_hppa_link_hash_table_create): Init to suit.
5256 (hppa_get_stub_entry): Add support for grouping stub sections.
5257 (hppa_add_stub): Likewise. Remove sec_count param and init/fini
5258 section code. Index stub vars by section->id.
5259 (elf32_hppa_size_stubs): Likewise. Remove duplicated function
5260 exit paths. Zap allocation of above removed vars. Refine
5263 * elf32-hppa.h (elf32_hppa_size_stubs): Add output_bfd param.
5264 * elf32-hppa.c (elf32_hppa_size_stubs): Likewise.
5265 (hppa_get_stub_entry): Pass in pointer to elf32_hppa_link_hash_table
5266 rather than pointer to bfd_link_info.
5267 (hppa_add_stub): Likewise.
5268 (final_link_relocate): Likewise.
5270 2000-09-17 David Huggins-Daines <dhd@linuxcare.com>
5272 (elf32_hppa_size_stubs): Don't try to build stubs for discarded
5275 2000-09-16 Alexandre Oliva <aoliva@redhat.com>
5277 * elf32-sh.c (ELF_MAXPAGESIZE): Define to 128, to match
5278 ld/emulparams/shelf.sh.
5280 2000-09-10 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5282 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): New function.
5283 * bfd-in.h (bfd_m68k_elf32_create_embedded_relocs): Add declaration.
5284 * bfd-in2.h: Regenerate.
5286 2000-09-15 Kenneth Block <Kenneth.Block@compaq.com>
5288 * elf64-alpha.c (elf64_alpha_relax_with_lituse): ld performs
5289 LITUSE relocations incorrectly if -relax is specified on the ld
5290 command line and the displacement field of the load or store
5291 instruction is non-zero. (Patch by paul.winalski@compaq.com)
5293 2000-09-15 Alan Modra <alan@linuxcare.com.au>
5295 * elf32-hppa.c (hppa_add_stub): Dont set first_init_sec and
5296 first_fini_sec here.
5297 (elf32_hppa_size_stubs): Instead correctly find the first .init
5298 and .fini section here.
5300 2000-09-15 David Huggins-Daines <dhd@linuxcare.com>
5302 * elf32-hppa.c (clobber_millicode_symbols): New function.
5303 (elf32_hppa_size_dynamic_sections): Call it.
5305 2000-09-14 Alan Modra <alan@linuxcare.com.au>
5307 * elf32-hppa.c (elf32_hppa_link_hash_entry): Make pic_call
5308 packed. Add plabel, plt_abs packed booleans.
5309 (hppa_link_hash_newfunc): Init new fields.
5310 (PLABEL_PLT_ENTRY_SIZE): Define.
5311 (hppa_stub_name): Use size_t len vars.
5312 (hppa_add_stub): Likewise.
5313 (elf32_hppa_build_stubs): Likewise.
5314 (hppa_build_one_stub): Kill some compiler warnings.
5315 (elf32_hppa_check_relocs): Always generate a plt entry for PLABELs
5316 if dynamic linking. Munge the local plt offsets into
5317 local_got_refcounts. Set h->plabel for all global PLABELs. Use
5318 size_t len vars. Add assert for plabel addend.
5319 (elf32_hppa_gc_sweep_hook): Sweep local plt entries too.
5320 (elf32_hppa_hide_symbol): New function.
5321 (elf_backend_hide_symbol): Define.
5322 (elf32_hppa_adjust_dynamic_symbol): Don't throw away plt entries
5323 with h->plabel set. Don't make plt entries to have dynamic syms
5324 when they have been forced local. If plt entry is used by a
5325 plabel, make it PLABEL_PLT_ENTRY_SIZE.
5326 (elf32_hppa_size_dynamic_sections): Set plt_abs for init fns.
5327 Set up .plt offsets for local syms.
5328 (elf32_hppa_relocate_section): Initialise plt entries for local
5329 syms. Leave weak undefined plabels zero. Make global plabel
5330 relocs against function symbol, and leave the addend zero.
5331 Use *ABS* DIR32 relocs instead of SEGREL32 for dynamic got relocs.
5332 (elf32_hppa_finish_dynamic_symbol): Set up IPLT relocs for
5333 non-dynamic syms. Init extra plt for plabels. Use *ABS* DIR32
5334 relocs instead of SEGREL32 for dynamic got relocs.
5335 (elf32_hppa_finish_dynamic_sections): Reserve one more .got entry.
5336 (elf_backend_got_header_size): Adjust.
5337 (elf32_hppa_set_gp): Calculate an "ideal" LTP.
5339 * elf32-hppa.c (LONG_BRANCH_VIA_PLT): Define.
5340 (hppa_type_of_stub): Use it instead of #if 0
5341 (hppa_discard_copies): Use it here too.
5342 (elf32_hppa_size_dynamic_sections): And here.
5344 * elf32-hppa.c (elf32_hppa_link_hash_table): Remove `offset' field.
5345 (elf32_hppa_link_hash_table_create): And here.
5346 (hppa_build_one_stub): And here. Instead keep track of stub
5347 offset using _raw_size.
5348 (elf32_hppa_size_stubs): Likewise.
5349 (elf32_hppa_build_stubs): Likewise.
5350 (hppa_size_one_stub): Likewise. Resize reloc section too.
5352 * elf32-hppa.c (hppa_add_stub): Correct first_init_sec and
5353 first_fini_sec handling. Don't search for reloc section or set
5354 hplink->reloc_section_created here.
5355 (elf32_hppa_size_stubs): Instead search for reloc sections, and
5356 set reloc_section_created here.
5357 (hppa_handle_PIC_calls): Set ELF_LINK_HASH_NEEDS_PLT.
5358 (elf32_hppa_size_dynamic_sections): Make a .plt entry for DT_INIT
5360 (elf32_hppa_finish_dynamic_sections): Set DT_INIT and DT_FINI.
5362 * elf32-hppa.c (hppa_build_one_stub): Replace `elf_hash_table (info)'
5363 with `hplink->root.'.
5364 (elf32_hppa_check_relocs): Likewise.
5365 (elf32_hppa_gc_sweep_hook): Likewise.
5366 (elf32_hppa_adjust_dynamic_symbol): Likewise.
5367 (hppa_handle_PIC_calls): Likewise.
5368 (elf32_hppa_size_dynamic_sections): Likewise.
5369 (elf32_hppa_set_gp): Likewise.
5370 (elf32_hppa_relocate_section): Likewise.
5371 (elf32_hppa_finish_dynamic_symbol): Likewise.
5372 (elf32_hppa_finish_dynamic_sections): Likewise.
5374 From David Huggins-Daines <dhd@linuxcare.com>
5375 * elf32-hppa.c (hppa_type_of_stub): Generate import stubs for
5376 defined weak symbols in shared links.
5377 (final_link_relocate): Calls to defined weak symbols in shared
5378 objects must go via import stubs, as the target might not be known
5381 2000-09-14 Alexandre Oliva <aoliva@redhat.com>
5383 * elf32-sh.c (sh_elf_howto_table): Moved R_SH_GOT32, R_SH_PLT32,
5384 R_SH_COPY, R_SH_GLOB_DAT, R_SH_JMP_SLOT, R_SH_RELATIVE,
5385 R_SH_GOTOFF, R_SH_GOTPC) to the range from 160 to 167. Replaced
5386 the original entries with EMPTY_HOWTOs, and added new ones to fill
5388 (sh_elf_info_to_howto): Make sure the new gap isn't used.
5389 (sh_elf_relocate_section): Likewise.
5391 2000-09-13 Anders Norlander <anorland@acc.umu.se>
5393 * cpu-mips.c (arch_info_struct): Add mips:4K
5394 * bfd-in2.h (bfd_mach_mips4K): New define.
5395 * archures.c: Add bfd_mach_mips4K to comment.
5396 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Return
5397 E_MIPS_ARCH_2 for bfd_mach_mips4K.
5399 2000-09-13 Marco Franzen <marcof@thyron.com>
5401 * som.c (som_write_symbol_strings): Do not used fixed buffers,
5402 use size_t as a counter.
5403 (som_write_space_strings): Similarly.
5405 2000-09-12 Jason Eckhardt <jle@cygnus.com>
5407 * elf32-i860.c (elf32_i860_relocate_pc26): New function
5409 (elf32_i860_relocate_section): Invoke new function from here.
5411 2000-09-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5413 * elf.c (_bfd_elf_make_section_from_shdr): Make debug_sec_names
5416 2000-09-10 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5418 * coff-m68k.c (bfd_m68k_coff_create_embedded_relocs): Emit 8 NULs for
5419 target section name instead of dumping core when the target symbol is
5422 2000-09-09 Kazu Hirata <kazu@hxi.com>
5424 * riscix.c: Remove DEFUN.
5426 2000-09-08 Nick Clifton <nickc@redhat.com>
5428 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Do not
5429 initialise flags in output bfd if the input bfd is the default
5430 architecture with the default flags.
5432 2000-09-08 Kazu Hirata <kazu@hxi.com>
5434 * archive.c: Fix formatting.
5435 * coff-arm.c: Likewise.
5436 * doc/chew.c: Likewise.
5438 2000-09-08 Alan Modra <alan@linuxcare.com.au>
5440 * section.c (bfd_get_unique_section_name): Put a dot before the
5443 2000-09-07 Kazu Hirata <kazu@hxi.com>
5445 * doc/chew.c: Remove all uses of DEFUN and DEFUN_VOID.
5446 * elf.c: Fix formatting.
5448 2000-09-07 Alexandre Oliva <aoliva@redhat.com>
5450 * config.bfd (sh-*-linux*): Added.
5451 * configure.in (bfd_elf32_shlin_vec, bfd_elf32_shblin_vec): New.
5452 * targets.c: Declare them.
5453 * elf32-sh-lin.c: New file.
5454 * Makefile.am: Compile it.
5455 * elf32-sh.c: Don't override defines from elf32-sh-lin.c.
5456 * configure, Makefile.in: Rebuilt.
5458 2000-09-06 Geoffrey Keating <geoffk@cygnus.com>
5460 * xcofflink.c (xcoff_link_input_bfd): Include the .tocbss
5461 pseduo-section when determining where the TOC ends.
5463 * coff-rs6000.c (_bfd_xcoff_swap_aux_out): Use bfd_h_put_16 to
5464 output x_tvndx as it is only two bytes wide.
5466 * coff-rs6000.c (xcoff_howto_table): A modifiable branch-absolute
5467 reloc is 26 or 32 bits wide.
5469 * coff-rs6000.c (_bfd_xcoff_rtype2howto): The bitsize is irrelevant
5470 for relocs that don't change anything. Also look at the full
5473 2000-09-06 Philip Blundell <philb@gnu.org>
5475 * config.bfd (arm*-*-uclinux*): New target.
5477 2000-09-06 Alexandre Oliva <aoliva@redhat.com>
5479 * configure: Rebuilt with new libtool.m4.
5481 2000-09-06 Alan Modra <alan@linuxcare.com.au>
5483 * section.c (bfd_get_unique_section_name): Avoid c++ reserved
5484 word for variable name.
5485 * bfd-in2.h: Regenerate.
5487 2000-09-05 Nick Clifton <nickc@redhat.com>
5489 * config.in: Regenerate.
5490 * libbfd.h: Regenerate.
5491 * po/bfd.pot: Regenerate.
5492 * doc/bfdint.texi: Remove CVS date string - it foils compares with
5495 2000-09-05 Steven Johnson <sbjohnson@ozemail.com.au>
5497 * cpu-powerpc.c (arch_info_struct): Added MPC860 Family entry.
5499 2000-09-05 Alan Modra <alan@linuxcare.com.au>
5501 Shared library and PIC support.
5502 * elf32-hppa.c (PLT_ENTRY_SIZE): New.
5503 (GOT_ENTRY_SIZE): New.
5504 (ELF_DYNAMIC_INTERPRETER): New.
5505 (STUB_SUFFIX): Define.
5506 (LONG_BRANCH_PIC_IN_SHLIB): Define.
5507 (RELATIVE_DYNAMIC_RELOCS): Define.
5508 (enum elf32_hppa_stub_type): New.
5509 (struct elf32_hppa_stub_hash_entry): Rename offset to
5510 stub_offset. Add a number of new fields.
5511 (struct elf32_hppa_link_hash_entry): New.
5512 (struct elf32_hppa_link_hash_table): Add numerous fields. Remove
5514 (elf32_hppa_hash_table): Rename to hppa_link_hash_table.
5515 (elf32_hppa_stub_hash_lookup): Rename to hppa_stub_hash_lookup.
5516 (elf32_hppa_stub_hash_newfunc): Rename to stub_hash_newfunc. Init
5518 (hppa_link_hash_newfunc): New function.
5519 (elf32_hppa_link_hash_table_create): Use above function. Init new
5521 (elf32_hppa_stub_name): Rename to hppa_stub_name. Pass in reloc
5522 instead of addend, and remove sym_name from args. Don't use
5523 symbol name for local syms, instead use sym index.
5524 (elf32_hppa_size_of_stub): Rename to hppa_type_of_stub, and return
5525 stub type rather than size. Pass in hash and handle import stub
5526 case. Also pass in reloc instead of offset so we can calculate
5527 PCREL22F and PCREL12F branches properly.
5528 (elf32_hppa_build_one_stub): Rename to hppa_build_one_stub. Build
5529 import and export stubs too.
5530 (elf32_hppa_size_one_stub): Rename to hppa_size_one_stub. Handle
5531 import and export stub sizing.
5532 (elf32_hppa_check_relocs): New function.
5533 (elf32_hppa_adjust_dynamic_symbol): New function.
5534 (hppa_discard_copies): New function.
5535 (elf32_hppa_size_dynamic_sections): New function.
5536 (elf_backend_size_dynamic_sections): Define.
5537 (elf32_hppa_finish_dynamic_symbol): New function.
5538 (elf_backend_finish_dynamic_symbol): Define.
5539 (elf32_hppa_size_stubs): Stash params in link hash table, and move
5540 some local vars into the link hash table too. For shared links,
5541 trundle over function syms, generating export stubs. Handle
5542 PCREL22F branches. Break out stub creation code from here..
5543 (hppa_add_stub): .. to here. New function.
5544 (elf32_hppa_final_link): Rename to elf32_hppa_set_gp, and don't
5545 call the bfd linker. Use elf_gp to record global pointer.
5546 Calculate a value from sections if $global$ is missing.
5547 (bfd_elf32_bfd_final_link): Define as _bfd_elf32_gc_common_final_link.
5548 (elf32_hppa_gc_mark_hook): New function.
5549 (elf_backend_gc_mark_hook): Define.
5550 (elf32_hppa_gc_sweep_hook): New function.
5551 (elf_backend_gc_sweep_hook): Define.
5552 (elf32_hppa_bfd_final_link_relocate): Rename to final_link_relocate.
5553 Add rel to args, and remove howto, input_bfd, offset, addend,
5554 sym_name as we can recalculate these locally. Handle calls to
5555 dynamic objects, extra PIC relocs, PCREL22F branches. Change
5556 handling of undefined weak syms. Check that stubs are in range.
5557 Only look for import stubs on PCREL17F and PCREL22F relocs. Add
5558 message on hitting a DPREL21L reloc that needs fixing. Subtract
5559 off PC for PCREL14F. Break out code that does a stub lookup from
5561 (hppa_get_stub_entry): ..to here. New function.
5562 (elf32_hppa_relocate_insn): Merge into final_link_relocate.
5563 (elf32_hppa_relocate_section): Handle got and plt relocs, dynamic
5565 (elf32_hppa_finish_dynamic_sections): New function.
5566 (elf_backend_finish_dynamic_sections): Define.
5567 (elf_backend_final_write_processing) Define.
5568 (hppa_handle_PIC_calls): New function.
5569 (elf32_hppa_build_stubs): Call it. Pass link_info to
5570 hppa_build_one_stub.
5571 (elf32_hppa_create_dynamic_sections): New function
5572 to create .plt and .got then set .plt flags correctly.
5573 (elf_backend_create_dynamic_sections): Define.
5574 (elf32_hppa_object_p): New function.
5575 (elf_backend_object_p): Define.
5576 (elf32_hppa_elf_get_symbol_type): New function.
5577 (elf_backend_get_symbol_type): Define.
5578 (elf_backend_can_gc_sections): Define.
5579 (elf_backend_want_got_plt): Define.
5580 (elf_backend_plt_alignment): Set to 2.
5581 (elf_backend_plt_readonly): Define.
5582 (elf_backend_want_plt_sym): Define.
5583 (elf_backend_got_header_size): Reserve one entry.
5585 * elf32-hppa.h (elf32_hppa_build_stubs): Don't pass stub bfd.
5586 (elf32_hppa_size_stubs): Pass in multi_subspace.
5587 (elf32_hppa_set_gp): Declare.
5589 * section.c (SEC_HAS_GOT_REF): Define new flag for asection.
5590 (bfd_get_unique_section_name): New function.
5591 * bfd-in2.h: Regenerate.
5593 * elf64-hppa.c (elf64_hppa_check_relocs): Handle R_PARISC_PCREL12F.
5594 (elf64_hppa_size_dynamic_sections): Remove the FIXME at bfd_zalloc
5597 From David Huggins-Daines <dhd@linuxcare.com>
5598 * elf64-hppa.c (elf64_hppa_check_relocs): Fix a warning.
5599 (elf64_hppa_mark_exported_functions): Set dyn_h->st_shndx.
5600 (elf64_hppa_link_output_symbol_hook): Test dyn_h->st_shndx has
5601 been updated in finish_dynamic_symbol before modifying function
5604 * elf-hppa.h (elf_hppa_howto_table): Restructure into groups of
5605 eight entries. Replace NULL with bfd_elf_generic_reloc. Add
5606 R_PARISC_GNU_VTENTRY, R_PARISC_GNU_VTINHERIT and R_PARISC_PCREL12F.
5607 (_bfd_elf_hppa_gen_reloc_type): Handle R_PARISC_GNU_VT*. Add some
5608 comments. Handle format == 12 for R_HPPA_PCREL_CALL.
5609 (elf_hppa_final_link_relocate): Handle R_PARISC_PCREL12F.
5610 (elf_hppa_relocate_insn): Likewise. Reformat some comments.
5611 (elf_hppa_final_write_processing): Expose it for ARCH_SIZE == 32.
5613 From David Huggins-Daines <dhd@linuxcare.com>
5614 * elf-hppa.h (elf_hppa_is_local_label_name): Accept the SysV/ELF
5615 style of local labels as well.
5617 2000-09-03 Philip Blundell <philb@gnu.org>
5619 * elf32-arm.h (elf32_arm_relocate_section): Don't try to relocate
5620 references to undefined symbols in debugging sections.
5622 2000-09-02 H.J. Lu <hjl@gnu.org>
5624 * reloc.c (BFD_RELOC_SH_COPY, BFD_RELOC_SH_GLOB_DAT,
5625 BFD_RELOC_SH_JMP_SLOT, BFD_RELOC_SH_RELATIVE,
5626 BFD_RELOC_SH_GOTPC): Move them from the MIPS section to the SH
5629 2000-09-02 Jason Eckhardt <jle@cygnus.com>
5631 * elf32-i860.c (bfd_elf32_bfd_is_local_label_name): Define macro.
5632 (elf32_i860_is_local_label_name): New function and prototype.
5634 2000-09-02 Nick Clifton <nickc@redhat.com>
5636 * configure.in: Increase version number to 2.10.91.
5637 * configure: Regenerate.
5638 * aclocal.m4: Regenerate.
5639 * config.in: Regenerate.
5640 * po/bfd.pot: Regenerate.
5642 2000-09-02 Daniel Berlin <dberlin@redhat.com>
5644 * elf.c (_bfd_elf_make_section_from_shdr): Add
5645 .gnu.linkobce.wi. to the list of debug section names.
5647 2000-09-02 Nick Clifton <nickc@redhat.com>
5649 * dwarf2.c (find_debug_info): New function: Locate a section
5650 containing dwarf2 debug information.
5651 (bfd_dwarf2_find_nearest_line): Find all sections containing
5652 debug information and include them in the stash.
5654 2000-09-01 Niibe Yutaka <gniibe@m17n.org>, Kaz Kojima <kkojima@rr.iij4u.or.jp>, Alexandre Oliva <aoliva@redhat.com>
5656 * elf32-sh.c (R_SH_GOT32, R_SH_PLT32, R_SH_COPY, R_SH_GLOB_DAT,
5657 R_SH_JMP_SLOT, R_SH_RELATIVE, R_SH_GOTOFF, R_SH_GOTPC): New.
5658 (sh_reloc_map): Add new relocs.
5659 (sh_elf_check_relocs, sh_elf_link_hash_newfunc,
5660 sh_elf_link_hash_table_create, sh_elf_adjust_dynamic_symbol,
5661 sh_elf_size_dynamic_sections, sh_elf_finish_dynamic_symbol,
5662 sh_elf_finishe_dynamic_sections, sh_elf_discard_copies): New
5664 (ELF_DYNAMIC_INTERPRETER, PLT_ENTRY_SIZE): Define.
5665 (elf_sh_plt0_entry_be, elf_sh_plt0_entry_le,
5666 elf_sh_plt_entry_be, elf_sh_plt_entry_le,
5667 elf_sh_pic_plt_entry_be, elf_sh_pic_plt_entry_le):
5668 New array constants.
5669 (elf_sh_plt0_entry, elf_sh_plt_entry, elf_sh_pic_plt_entry):
5671 (elf_sh_sizeof_plt, elf_sh_plt_plt0_offset,
5672 elf_sh_plt0_linker_offset, elf_sh_plt0_gotid_offset,
5673 elf_sh_plt_temp_offset, elf_sh_plt_symbol_offset,
5674 elf_sh_plt_reloc_offset): Define.
5675 (elf_sh_pcrel_relocs_copied, elf_sh_link_hash_entry,
5676 elf_sh_link_hash_table): New structs.
5677 (sh_elf_link_hash_traverse, sh_elf_hash_table): New macros.
5678 (sh_elf_relocate_section, sh_elf_check_relocs): Handle new
5680 (elf_backend_create_dynamic_sections,
5681 bfd_elf32_bfd_link_hash_table_create,
5682 elf_backend_adjust_dynamic_symbol,
5683 elf_backend_size_dynamic_sections,
5684 elf_backend_finish_dynamic_symbol,
5685 elf_backend_finish_dynamic_sections, elf_backend_want_got_plt,
5686 elf_backend_plt_readonly, elf_backend_want_plt_sym,
5687 elf_backend_got_header_size, elf_backend_plt_header_size):
5689 * reloc.c (BFD_RELOC_SH_COPY, BFD_RELOC_SH_GLOB_DAT,
5690 BFD_RELOC_SH_JMP_SLOT, BFD_RELOC_SH_RELATIVE, BFD_RELOC_SH_GOTPC):
5692 * bfd-in2.h, libbfd.h: Rebuilt.
5694 2000-09-01 Alan Modra <alan@linuxcare.com.au>
5696 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Revert 2000-08-27
5699 2000-08-31 J"orn Rennecke <amylaar@cygnus.co.uk>
5701 * elf32-sh.c (sh_elf_merge_private_data): If ibfd's elf header flags
5702 not initialized, set them to indicate the SH1 instruction set.
5704 2000-08-31 Alexandre Oliva <aoliva@redhat.com>
5706 * acinclude.m4: Include libtool and gettext macros from the
5708 * aclocal.m4, configure: Rebuilt.
5710 2000-08-29 Michael Snyder <msnyder@seadog.cygnus.com>
5712 * elf.c: Eliminate references to __sparcv9 macro; replace with
5713 autoconf variables HAVE_PSINFO32_T etc.
5714 * configure.in: Auto-configure HAVE_PSINFO_32_T, HAVE_PRPSINFO32_T,
5715 HAVE_PSTATUS32_T, HAVE_PRSTATUS32_T, HAVE_PRSTATUS32_T_PR_WHO.
5717 * acinclude.m4 (BFD_HAVE_SYS_PROCFS_TYPE) define _SYSCALL32 so it can
5718 detect the above typedefs. (BFD_HAVE_SYS_PROCFS_TYPE_MEMBER): Ditto.
5719 * aclocal.m4: Ditto.
5720 * configure: Regenerate.
5722 2000-08-27 Alan Modra <alan@linuxcare.com.au>
5724 * elf32-i386.c (elf_i386_check_relocs): Keep info on relocs copied
5725 for any shared link, not just shared -Bsymbolic.
5726 (elf_i386_size_dynamic_sections): Call elf_i386_discard_copies on
5727 any shared link, and pass link info to it.
5728 (elf_i386_size_dynamic_sections): Update comment.
5729 (elf_i386_discard_copies): Modify to discard relocs for symbols
5730 that have been forced local.
5731 (elf_i386_finish_dynamic_symbol): Don't copy relocs for symbols
5732 that have been forced local.
5734 2000-08-24 Denis Chertykov <denisc@overta.ru> & Nick Clifton <nickc@redhat.com>
5736 * elflink.h (elf_link_add_object_symbols): Allow common
5737 symbols to have an alignment of 1 if explicitly requested, and
5738 not overridden by other definitions.
5740 2000-08-22 Doug Kwan <dkwan@transmeta.com>
5742 * coff-w65.c (CREATE_LITTLE_COFF_TARGET): Fix typo.
5743 * coffcode.h (coff_set_flags): Add detection of w65 architecture.
5745 2000-08-22 H.J. Lu <hjl@gnu.org>
5747 * elf-bfd.h (elf_link_hash_table): Add runpath.
5749 * bfd-in.h (bfd_elf_get_runpath_list): New prototype.
5750 * bfd-in2.h: Rebuilt.
5752 * elf.c (_bfd_elf_link_hash_table_init): Initialize the
5753 "runpath" field to NULL.
5754 (bfd_elf_get_runpath_list): New function.
5756 * elflink.h (elf_link_add_object_symbols): Record DT_RPATH and
5759 2000-08-22 Alexandre Oliva <aoliva@redhat.com>
5761 * elf32-sh.c (sh_elf_relocate_section) [R_SH_IND12W,
5762 R_SH_DIR8WPN, R_SH_DIR8WPZ, R_SH_DIR8WPL]: Handle them
5763 explicitly. Improve validation of r_type.
5765 2000-08-21 H.J. Lu <hjl@gnu.org>
5767 * elf32-i386.c (elf_i386_size_dynamic_sections): Zero out the
5768 dynamic allocated content space. Add a comment to remind us that
5769 one day this ought to be fixed.
5770 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
5771 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
5772 * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
5774 2000-08-21 Jason Eckhardt <jle@cygnus.com>
5776 * elf32-i860.c (elf32_i860_relocate_pc16): Just write the immediate
5777 field with the newly relocated value instead of adding it to the
5778 existing immediate field.
5779 (elf32_i860_relocate_splitn): Likewise.
5780 (elf32_i860_relocate_highadj): Likewise.
5782 2000-08-16 Jason Eckhardt <jle@cygnus.com>
5784 * elf32-i860.c (elf32_i860_relocate_pc16): Implemented function (it
5785 was previously just a stub).
5787 2000-08-16 Alexandre Oliva <aoliva@redhat.com>
5789 * elflink.c (_bfd_elf_create_got_section): Don't abort().
5791 (_bfd_elf_create_dynamic_sections): Likewise.
5793 2000-08-16 Andrew Macleod <amacleod@cygnus.com>
5795 * elf64-sparc.c (sparc64_elf_relocate_section): Set relocation address
5796 for undefined symbols to be the beginning of the section.
5798 * elf64-sparc.c (sparc64_elf_adjust_dynamic_symbol): Don't allocate
5799 four extra entries at the beginning of the .rela.plt section.
5800 (sparc64_elf_finish_dynamic_symbol): Adjust the offset in the .rela.plt
5801 section to account for the four reserved entries in the .plt section.
5803 2000-08-15 Geoffrey Keating <geoffk@cygnus.com>
5805 * xcofflink.c (_bfd_ppc_xcoff_relocate_section): Add ori r0,r0,0
5806 to the list of NOPs we recognize after a branch-and-link.
5807 Use the ori NOP when one is needed.
5809 * coff-rs6000.c (_bfd_xcoff_slurp_armap): Finish implementation
5812 2000-08-14 Jim Wilson <wilson@cygnus.com>
5814 * elf64-ia64.c (elf64_ia64_merge_private_bfd_data): Handle
5815 EF_IA_64_REDUCEDFP, EF_IA_64_CONS_GP, and EF_IA_64_NOFUNCDESC_CONS_GP.
5816 (elf64_ia64_print_private_bfd_data): Likewise. Also handle
5819 2000-08-11 Alexandre Oliva <aoliva@redhat.com>
5821 * elf32-sh.c (sh_elf_set_mach_from_flags): Make it static.
5823 2000-08-10 Jason Eckhardt <jle@cygnus.com>
5825 * elf32-i860.c (elf32_i860_relocate_section): New function.
5826 (i860_final_link_relocate): New function.
5827 (elf32_i860_relocate_splitn): New function.
5828 (elf32_i860_relocate_pc16): New function.
5829 (elf32_i860_relocate_highadj): New function.
5830 (elf32_i860_howto): Minor adjustments to some relocations.
5831 (elf_info_to_howto_rel): Define.
5832 (elf_backend_relocate_section): Define.
5834 2000-08-10 Nick Clifton <nickc@cygnus.com>
5836 * elf32-arm.h: Fix formatting.
5838 2000-08-10 Bernd Schmidt <bernds@cygnus.co.uk>
5840 * elf32-sh.c (sh_elf_reloc_loop): Make LAST_SYMBOL_SECTION static.
5842 2000-08-08 Jason Eckhardt <jle@cygnus.com>
5844 * elf32-i860.c (elf32_i860_howto_table): Updated some fields.
5846 2000-08-07 Kazu Hirata <kazu@hxi.com>
5848 * ieee.c (ieee_write_debug_part): Rewrite a comment.
5849 * elf64-ia64.c: Fix a typo.
5851 2000-08-05 Jason Eckhardt <jle@cygnus.com>
5853 * elf32-i860.c (elf32_i860_howto_table): New structure.
5854 (lookup_howto): New function.
5855 (elf32_i860_reloc_type_lookup): New function.
5856 (elf32_i860_info_to_howto_rela): New function.
5857 (elf_code_to_howto_index): New structure.
5858 (elf_info_to_howto): Re-define as elf32_i860_info_to_howto_rela.
5859 (bfd_elf32_bfd_reloc_type_lookup): Re-define as
5860 elf32_i860_reloc_type_lookup.
5862 2000-08-04 Rodney Brown <RodneyBrown@pmsc.com>
5864 * som.c (struct fixup_format): Constify `format'.
5865 (som_hppa_howto_table): Use SOM_HOWTO macro.
5866 (try_prev_fixup, hppa_som_reloc): Decorate unused parameter.
5867 (som_bfd_reloc_type_lookup): Likewise.
5868 (compare_subspaces): Remove unused `count1', `count2'.
5869 (som_begin_writing): Remove unused `total_reloc_size'.
5870 (som_bfd_derive_misc_symbol_info): Decorate unused parameter.
5871 (som_print_symbol, som_bfd_is_local_label_name): Likewise.
5872 (som_set_reloc_info): Constify `cp'. Remove unused `addend'.
5873 (som_find_nearest_line): Decorate unused parameter(s).
5874 (som_sizeof_headers, som_get_symbol_info, som_write_armap): Likewise.
5875 (som_bfd_link_split_section): Likewise.
5877 2000-08-03 Nick Clifton <nickc@cygnus.com>
5879 * section.c: Restore backed out code.
5880 * elf.c: Restore backed out code.
5881 (copy_private_bfd_data): Fix bug preventing stipped dynamic
5882 binaries from working.
5883 * bfd-in2.h: Regenerate.
5885 2000-08-03 H.J. Lu <hjl@gnu.org>
5887 * section.c: Back out the change made by Nick Clifton
5888 <nickc@cygnus.com> on 2000-07-31. It breaks stripping dynamic
5890 * bfd-in2.h: Likewise.
5893 2000-08-03 Alexandre Oliva <aoliva@redhat.com>
5895 * elf32-sh.c (sh_elf_reloc_loop): Warning removal.
5897 2000-07-31 Jason Eckhardt <jle@cygnus.com>
5899 * reloc.c (BFD_RELOC_860_*): New bfd relocs for i860.
5900 * bfd-in2.h, libbfd.h: Regenerate.
5902 2000-07-31 Nick Clifton <nickc@cygnus.com>
5904 * section.c (struct sec): Add new boolean field 'segment_mark'.
5905 (STD_SECTION): Initialise new field to zero.
5907 * bfd-in2.h: Regenerate.
5909 * elf.c (copy_private_bfd_data): Reorganise section to segment
5910 mapping to cope with moved sections requiring new segments,
5911 and overlapping segments.
5912 (SEGMENT_END): New macro: Return the end address of a segment.
5913 (IS_CONTAINED_BY_VMA): New macro: Determine if a segment
5914 contains a section by comparing their VMA addresses.
5915 (IS_CONTAINED_BY_LMA): New macro: Determine if a segment
5916 contains a section by comparing their LMA addresses.
5917 (INCLUDE_SECTION_IN_SEGMENT): New macro: Determine if a
5918 section should be included in a segment.
5919 (SEGMENT_AFTER_SEGMENT): New macro: Determine if one segment
5920 follows another in memory.
5921 (SEGMENT_OVERLAPS_SEGMENT): New macro: Determine if two
5924 2000-07-22 Jason Eckhardt <jle@cygnus.com>
5926 * cpu-i860.c: Added comments.
5928 * elf32-i860.c (TARGET_LITTLE_SYM): Defined to
5929 bfd_elf32_i860_little_vec.
5930 (TARGET_LITTLE_NAME): Defined to "elf32-i860-little".
5931 (ELF_MAXPAGESIZE): Changed to 4096.
5933 * targets.c (bfd_elf32_i860_little_vec): Declaration of
5935 (bfd_target_vector): Added bfd_elf32_i860_little_vec.
5937 * config.bfd (i860-stardent-sysv4*, i860-stardent-elf*): Added
5938 config for little endian elf32 i860.
5939 (targ_defvec): Define for the new config above
5940 as "bfd_elf32_i860_little_vec".
5941 (targ_selvecs): Define for the new config above
5942 as "bfd_elf32_i860_vec bfd_elf32_i860_little_vec"
5944 * configure.in (bfd_elf32_i860_little_vec): Added recognition
5947 * configure: Regenerated.
5949 2000-07-27 H.J. Lu <hjl@gnu.org>
5951 * elflink.h (elf_merge_symbol): Take one more argument,
5952 dt_needed, to indicate if the symbol comes from a DT_NEEDED
5953 entry. Don't overide the existing weak definition if dt_needed
5955 (elf_link_add_object_symbols): Pass dt_needed to
5956 elf_merge_symbol ().
5958 2000-07-27 Nick Clifton <nickc@cygnus.com>
5960 * elflink.h (elf_link_size_reloc_section): Zeroes the section's
5963 2000-07-25 Geoffrey Keating <geoffk@cygnus.com>
5965 * configure.host (*-*-aix*): AIX has 'long long' always.
5967 * coff-rs6000.c (xcoff_write_one_armap_big): New procedure.
5968 (xcoff_write_armap_big): Write both 32-bit and 64-bit armaps.
5969 (xcoff_write_archive_contents_big): Don't update the offset
5970 of the symbol table, xcoff_write_armap will do it.
5972 2000-07-23 Ulf Carlsson <ulfc@engr.sgi.com>
5974 * elf32-mips.c (_bfd_mips_elf_check_relocs): Use abfd instead
5975 of dynobj for SGI_COMPAT checks.
5977 2000-07-21 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5979 * coff-m68k.c (bfd_m68k_coff_create_embedded_relocs): New function.
5980 * bfd-in.h (bfd_m68k_coff_create_embedded_relocs): Add declaration.
5981 * bfd-in2.h: Regenerate.
5983 2000-07-21 Nick Clifton <nickc@cygnus.com>
5985 * elf32-mips.c (_bfd_mips_elf_check_relocs): Detect out of
5986 range symbol indices in relocs and issue an error message.
5988 2000-07-20 H.J. Lu <hjl@gnu.org>
5990 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Don't check
5991 info->new_dtags when setting DT_FLAGS_1. It will only be set
5992 by the new linker options. It shouldn't break anything.
5994 2000-07-20 H.J. Lu <hjl@gnu.org>
5996 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set DT_FLAGS_1
5997 only if info->new_dtags is true.
5999 2000-07-20 H.J. Lu <hjl@gnu.org>
6001 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set
6002 DT_RUNPATH and DT_FLAGS only if info->new_dtags is true.
6004 2000-07-20 Hans-Peter Nilsson <hp@axis.com>
6006 * Makefile.am (ALL_MACHINES): Add cpu-cris.lo.
6007 (ALL_MACHINES_CFILES): Add cpu-cris.c.
6008 (BFD32_BACKENDS): Add aout-cris.lo and elf32-cris.lo.
6009 (BFD32_BACKENDS_CFILES): Add aout-cris.c and elf32-cris.c.
6010 (cpu-cris.lo, aout-cris.lo, elf32-cris.lo): New rules.
6011 * Makefile.in: Rebuild.
6012 * aclocal.m4: Rebuild.
6013 * aoutx.h (NAME(aout,machine_type)): Add case for bfd_arch_cris.
6014 * archures.c (enum bfd_architecture): Add bfd_arch_cris.
6015 (bfd_cris_arch): Declare.
6016 (bfd_archures_list): Add bfd_cris_arch.
6017 * bfd-in2.h: Rebuild.
6018 * config.bfd: (cris-*-*): New target.
6019 * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vectors.
6020 * configure: Rebuild.
6021 * elf.c (prep_headers): Add bfd_arch_cris.
6022 * libbfd.h: Rebuild.
6023 * libaout.h (enum machine_type): Add M_CRIS.
6024 * reloc.c: Add CRIS relocations.
6025 * targets.c (bfd_elf32_cris_vec, cris_aout_vec): Declare.
6026 (bfd_target_vect): Add bfd_elf32_cris_vec and cris_aout_vec.
6027 * cpu-cris.c, aout-cris.c, elf32-cris.c: New files.
6028 * po/POTFILES.in, po/bfd.pot: Regenerate.
6030 2000-07-19 H.J. Lu <hjl@gnu.org>
6032 * elf32-arm.h (elf32_arm_size_dynamic_sections): Also set
6033 DF_TEXTREL if DT_TEXTREL is set.
6034 * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise.
6035 * elf32-i386.c (elf_i386_size_dynamic_sections): Likewise.
6036 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
6037 * elf32-mips.c (_bfd_mips_elf_size_dynamic_sections): Likewise.
6038 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise.
6039 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
6040 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Likewise.
6041 * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
6042 * elf64-ia64.c (elf64_ia64_size_dynamic_sections): Likewise.
6043 * elf64-sparc.c (sparc64_elf_size_dynamic_sections): Likewise.
6045 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Also
6046 set DF_SYMBOLIC for symbolic link. Also set DT_RUNPATH if
6048 Set the DT_FLAGS and DT_FLAGS_1 entries if necessary.
6050 2000-07-19 H.J. Lu <hjl@gnu.org>
6052 * bfd-in.h (bfd_elf_set_dt_needed_soname): New.
6053 * bfd-in2.h: Rebuild.
6055 * elf-bfd.h (elf_obj_tdata): Add dt_soname.
6056 (elf_dt_soname): New.
6058 * elf.c (bfd_elf_set_dt_needed_soname): New.
6060 * elflink.h (elf_link_add_object_symbols): Add the DT_NEEDED
6061 entry if the shared object loaded by DT_NEEDED is used to
6062 resolve the reference in a regular object.
6064 2000-07-19 H.J. Lu <hjl@gnu.org>
6066 * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_CONFIG,
6067 DT_DEPAUDIT and DT_AUDIT as strings.
6069 2000-07-19 Nick Clifton <nickc@cygnus.com>
6071 * format.c: Fix formatting.
6073 2000-07-19 H.J. Lu <hjl@gnu.org>
6075 * elf.c (_bfd_elf_print_private_bfd_data): Fix DT_CHECKSUM.
6077 2000-07-19 H.J. Lu <hjl@gnu.org>
6079 * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_BIND_NOW,
6080 DT_INIT_ARRAY, DT_FINI_ARRAY, DT_INIT_ARRAYSZ, DT_FINI_ARRAYSZ,
6081 DT_RUNPATH, DT_FLAGS, DT_PREINIT_ARRAY, DT_PREINIT_ARRAYSZ,
6082 DT_PLTPADSZ, DT_MOVEENT, DT_MOVESZ, DT_FEATURE, DT_POSFLAG_1,
6083 DT_SYMINSZ, DT_SYMINENT, DT_CONFIG, DT_DEPAUDIT, DT_AUDIT,
6084 DT_PLTPAD, DT_MOVETAB, DT_SYMINFO, DT_RELACOUNT, DT_RELCOUNT,
6085 DT_FLAGS_1, DT_USED and DT_CHECKSUM.
6087 2000-07-18 Andrew Cagney <cagney@b1.cygnus.com>
6089 * elf.c (bfd_elf_get_sign_extend_vma, bfd_elf_get_arch_size): Move
6090 renamed functions from here...
6091 (assign_section_numbers): Use renamed functions.
6092 (prep_headers): Use renamed functions.
6094 * bfd.c (bfd_get_sign_extend_vma, bfd_get_arch_size): ...To here.
6095 * bfd-in.h (bfd_get_sign_extend_vma, bfd_get_arch_size): Update.
6096 * bfd-in2.h: Regenerate.
6098 2000-07-18 Ulf Carlsson <ulfc@engr.sgi.com>
6100 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Add
6101 parenthesis in if statement.
6103 2000-07-17 Koundinya K <kk@ddeorg.soft.net>
6105 Enable the support for Traditional MIPS.
6106 * elf32-mips.c (IRIX_COMPAT): Recognize bfd_elf32_tradbigmips_vecand
6107 return ict_none appropriately for traditional mips targets.
6108 (STUB_LW): Change 0x8f998000 to 0x8f998010 for traditional mips.
6109 (STUB_MOVE): Conditionalize for traditonal mips.
6110 (STUB_LI16): Likewise.
6111 (_bfd_mips_elf_modify_segment_map): Conditionalize to avoid making
6112 room for RTPROC header.
6113 (_bfd_mips_elf_modify_segment_map): For a normal mips executable set
6114 the permission for the PT_DYNAMIC as read, write and execute.
6115 (mips_elf_calculate_relocation): Check for the symbol _DYNAMIC_LINKING
6116 for traditonal mips.
6117 (_bfd_mips_elf_create_dynamic_sections): Add the symbol
6118 _DYNAMIC_LINKING for traditonal mips.
6119 (_bfd_mips_elf_create_dynamic_sections): Add the symbol __RLD_MAP
6120 in case of traditonal mips.
6121 (_bfd_mips_elf_adjust_dynamic_symbol): Create a stub only if a PLT
6122 entry is required. For a function if PLT is not required then set the
6123 corresponding hash table entry to 0.
6124 (_bfd_mips_elf_size_dynamic_sections): Add DT_DEBUG entry for
6126 (_bfd_mips_elf_finish_dynamic_symbol): for a undefined symbol in a
6127 shared object set the value to 0.
6128 (_bfd_mips_elf_finish_dynamic_symbol): Check for the symbol
6129 _DYNAMIC_LINKING for traditonal mips.
6130 (_bfd_mips_elf_finish_dynamic_symbol): Check for the symbol __RLD_MAP
6131 for traditonal mips.
6133 2000-07-15 H.J. Lu <hjl@gnu.org>
6135 * aoutx.h (translate_to_native_sym_flags): Handle BSF_LOCAL.
6137 2000-07-12 Charles Wilson <cwilson@ece.gatech.edu>
6139 * libbfd.c (bfd_seek): fix 'seek beyond EOF' error when writing
6140 out a structure that is BFD_IN_MEMORY.
6142 2000-07-11 Alan Modra <alan@linuxcare.com.au>
6144 * elf64-hppa.c (get_dyn_name): Pass in section pointer instead of
6145 bfd pointer. Print section id instead of bfd pointer for local
6146 syms. Prefix addend with `+' for global syms as well as local.
6147 Correct calculation of name component lengths.
6148 (elf64_hppa_check_relocs): Update call to get_dyn_name.
6150 From David Huggins-Daines <dhd@linuxcare.com>
6151 * elf-hppa.h (elf_hppa_relocate_section): Update calls here too.
6152 * elf64-hppa.c (elf64_hppa_check_relocs): Fix some warnings.
6153 (elf64_hppa_modify_segment_map): Likewise.
6155 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
6157 * elf.c (bfd_elf_get_sign_extend_vma): Return tendency of VMA
6158 addresses to be "naturally" sign extended. Return -1 if unknown.
6159 * bfd-in.h (bfd_elf_get_sign_extend_vma): Add declaration.
6160 * bfd-in2.h: Regenerate.
6162 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
6164 * ecoffswap.h (ecoff_get_off, ecoff_put_off): Add ECOFF_SIGNED_32
6165 and ECOF_SIGNED_64 to list ways to extract an offset.
6166 (ecoff_swap_fdr_in, ecoff_swap_fdr_out, ecoff_swap_pdr_in,
6167 ecoff_swap_pdr_out, ecoff_swap_ext_in, ecoff_swap_ext_out):
6169 * elf64-mips.c (ECOFF_SIGNED_64): Define instead of ECOFF_64.
6170 * elf32-mips.c (ECOFF_SIGNED_32): Define instead of ECOFF_32.
6172 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
6174 * elfcode.h (elf_object_p): Use bfd_set_start_address and not
6175 bfd_get_start_address.
6176 (elf_swap_ehdr_in): Sign extend e_entry when applicable.
6177 (elf_swap_ehdr_out): Ditto.
6179 2000-07-10 Alexander Aganichev <AAganichev@hypercom.com>
6181 * archures.c (bfd_default_scan): Add set of bfd_mach_ cases for
6182 compatibility with older binutils.
6184 2000-07-10 Alan Modra <alan@linuxcare.com.au>
6186 * section.c (bfd_make_section_anyway): Start section_id at 0x10.
6187 (STD_SECTION): Avoid negative ids, instead use 0 to 3.
6189 From Ryan Bradetich <rbradetich@uswest.net>
6190 * dwarf1.c (parse_die): Cure signed/unsigned char warnings.
6191 (parse_line_table): Ditto.
6192 (_bfd_dwarf1_find_nearest_line): Ditto.
6193 * syms.c (cmpindexentry): Remove extra `*' from params.
6195 2000-07-09 Koundinya K <kk@ddeorg.soft.net>
6197 * elf32-mips.c (sort_dynamic_relocs): New Function.
6198 (_bfd_mips_elf_finish_dynamic_sections): Call sort_dynamic_relocs
6199 via qsort to sort the dynamic relocations in increasing r_symndx
6202 2000-07-09 Alan Modra <alan@linuxcare.com.au>
6204 * elf64-hppa.c (elf64_hppa_dyn_hash_table_init): Add
6205 ATTRIBUTE_UNUSED to unused args.
6206 (get_opd): Likewise.
6207 (get_plt): Likewise.
6208 (get_dlt): Likewise.
6209 (get_stub): Likewise.
6210 (elf64_hppa_adjust_dynamic_symbol): Likewise.
6211 (elf64_hppa_link_output_symbol_hook): Likewise.
6212 (elf64_hppa_check_relocs): Delete unused var.
6213 (elf64_hppa_size_dynamic_sections): Likewise.
6214 (elf64_hppa_finalize_opd): Likewise.
6215 (elf64_hppa_finalize_dynreloc): Likewise.
6216 (elf64_hppa_modify_segment_map): Likewise.
6217 (elf64_hppa_finish_dynamic_sections): Likewise.
6219 * elf-hppa.h (elf_hppa_final_write_processing): Add
6220 ATTRIBUTE_UNUSED to unused args.
6221 (elf_hppa_final_link_relocate): Likewise.
6222 (elf_hppa_record_segment_addrs): Add paretheses.
6223 (elf_hppa_relocate_section): Constify dyn_name.
6225 From David Huggins-Daines <dhd@linuxcare.com>
6226 * config.bfd: Add hppa*64*-*-linux-gnu 64-bit target, and
6227 rearrange case statement so that it gets preferred to 32-bit ones.
6229 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Use
6230 asection->id instead of address of asection structure.
6231 (elf32_hppa_size_stubs): Likewise.
6233 * elf32-hppa.c (elf32_hppa_size_stubs): Use just one stub section
6234 for .init* and .fini*.
6236 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Mask pointers
6237 and addends used in stub names to 32 bits.
6238 (elf32_hppa_size_stubs): Likewise.
6240 * elf-hppa.h (elf_hppa_final_link_relocate): Don't sum addend
6241 twice for R_PARISC_GPREL64. Use bfd_put_32 for R_PARISC_PCREL32,
6242 not bfd_put_64. Fix minor comment typo and formatting.
6244 Changes to create multiple linker stubs, positioned immediately
6245 before the section where they are required.
6246 * elf32-hppa.c: Don't include hppa_stubs.h.
6247 (elf32_hppa_stub_hash_entry): Add a pointer to the stub section.
6248 (elf32_hppa_stub_hash_table): Delete.
6249 (elf32_hppa_link_hash_entry): Delete.
6250 (elf32_hppa_link_hash_table): Use plain bfd_hash_table for
6251 stub_hash_table, and store the struct here rather than a pointer.
6252 Delete output_symbol_count. Add offset array. Change
6253 global_value to a bfd_vma.
6254 (elf32_hppa_stub_hash_lookup): Use table instead of table->root.
6255 (elf32_hppa_stub_hash_traverse): Delete.
6256 (elf32_hppa_name_of_stub): Delete.
6257 (elf32_hppa_link_hash_lookup): Delete.
6258 (elf32_hppa_link_hash_traverse): Delete.
6259 (elf32_hppa_stub_hash_table_init): Delete.
6260 (elf32_hppa_size_of_stub): Pass input section and offset rather
6261 than location and calculate location here. Don't pass name as all
6262 stubs are now the same size.
6263 (elf32_hppa_stub_hash_newfunc): Init new fields.
6264 (elf32_hppa_link_hash_table_create): Likewise, and stub_hash_table
6266 (elf32_hppa_bfd_final_link_relocate): Cast enums to int before
6267 comparing against ints. Rewrite stub handling code.
6268 (elf32_hppa_relocate_section): Make r_type and r_symndx unsigned.
6269 Case enums to int before comparing against ints. Remove
6270 bfd_reloc_dangerous case.
6271 (elf32_hppa_build_one_stub): Rewrite.
6272 (elf32_hppa_size_one_stub): New function.
6273 (elf32_hppa_build_stubs): Rewrite.
6274 (elf32_hppa_size_stubs): Pass in linker call-back functions.
6275 Rewrite stub-handling specific code.
6277 * elf32-hppa.h (elf32_hppa_size_stubs): Update prototype.
6279 * elf64-hppa.c (elf64_hppa_dyn_hash_entry): Fix a comment typo.
6281 * hppa_stubs.h: Delete.
6282 * Makefile.am (SOURCE_HFILES): Remove hppa_stubs.h
6283 (elf32-hppa.lo): Remove hppa_stubs.h from dependencies.
6284 * Makefile.in: Regenerate.
6286 * elf-hppa.h (_bfd_elf_hppa_gen_reloc_type): Handle e_nlsel and
6289 * libhppa.h (hppa_field_adjust): Correct e_nsel case.
6291 * elf32-hppa.c (elf32_hppa_relocate_section): Mention the offset
6292 and section name for bfd_reloc_notsupported error message.
6293 (elf32_hppa_bfd_final_link_relocate): Print reasons for returning
6294 bfd_reloc_notsupported.
6295 (elf32_hppa_relocate_section): Add ATTRIBUTE_UNUSED to output_bfd.
6297 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Handle
6298 undefined weak symbols for all relocs.
6299 (elf32_hppa_size_of_stub): Adjust calculation by 8 since branch
6300 offsets are relative to one past the delay slot.
6301 (elf32_hppa_size_stubs): Account for reloc addend when calculating
6302 branch destination. Put addend into stub name too.
6303 (elf32_hppa_bfd_final_link_relocate): Account for reloc addend and
6304 adjust by 8 when deciding whether a linker stub is needed. Put
6305 addend into stub name as for above.
6307 * elf32-hppa.c (hppa_elf_relocate_insn): Change signed/unsigned on
6308 various args and vars.
6309 (elf32_hppa_bfd_final_link_relocate): Here too.
6310 (elf32_hppa_size_stubs): Rename index -> indx. Use e_indx for
6311 inner block var to avoid shadowing.
6313 * elf32-hppa.h (_bfd_elf32_hppa_gen_reloc_type): Make `field' arg
6315 * elf64-hppa.h (_bfd_elf64_hppa_gen_reloc_type): Ditto.
6316 * elf-hppa.h (_bfd_elf_hppa_gen_reloc_type): Ditto.
6317 (elf_hppa_fake_sections): Rename local var to avoid shadowing.
6319 * libhppa.h: Change practically all unsigned ints to plain ints.
6320 Remove tests on gcc version. Instead use ATTRIBUTE_UNUSED for
6323 From Ryan Bradetich <rbradetich@uswest.net>
6324 * libhppa.h (hppa_opcode_type): New enum to replace #define's.
6325 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Modify to
6327 From David Huggins-Daines <dhd@linuxcare.com>
6328 * elf-hppa.h (elf_hppa_relocate_insn): Update the opcode constants
6329 to the new OP_* ones.
6331 * elf32-hppa.c (elf32_hppa_size_stubs): Consolidate freeing on
6332 error exit. Bail out earlier on plabel relocs that we aren't
6333 interested in. Don't tell elf32_hppa_stub_hash_lookup to copy
6334 string, and then don't free our copy.
6335 (elf32_hppa_build_one_stub): Make insn unsigned int.
6337 * libhppa.h (bfd_hppa_insn2fmt): 22 bit branches are only
6338 available with BL, not BE and BLE.
6340 * elf32-hppa.c (hppa_elf_relocate_insn): Add some more example
6341 code for elf arg relocs.
6342 (elf32_hppa_bfd_final_link_relocate): Replace boolean is_local
6343 argument with elf_link_hash_entry h. Handle undefined weak
6344 symbols. Move $global$ lookup from here...
6345 (elf32_hppa_relocate_section): ...to here. Return correct error
6346 message for non-handled relocs.
6347 (elf32_hppa_size_of_stub): Correctly test branch range. Previous
6348 wrong test was -0x3ffff to +0x40000.
6350 * elf-hppa.h (elf_hppa_final_link_relocate): R_PARISC_DIR17R,
6351 R_PARISC_DIR17F, and R_PARISC_DIR21L are for absolute branches;
6352 Handle them as such.
6353 (elf_hppa_relocate_insn): Fix a typo.
6355 * libhppa.h (GET_FIELD, GET_BIT, MASK, CATENATE, ELEVEN): Delete.
6356 (assemble_3, assemble_6, assemble_12, assemble_16, assemble_16a,
6357 assemble_17, assemble_21): Delete.
6358 Supply defines for all 64 possible opcodes.
6359 (bfd_hppa_insn2fmt): Add bfd argument, and use to select wide mode
6360 formats. Handle COMICLR.
6361 (hppa_rebuild_insn): Delete bfd argument. Handle formats 10, -11,
6364 * elf32-hppa.c (hppa_elf_relocate_insn): Complete rewrite.
6365 (elf32_hppa_bfd_final_link_relocate): Major rewrite.
6366 (elf32_hppa_build_one_stub): Modify hppa_elf_relocate_insn calls
6368 (elf32_hppa_size_stubs): Don't free stub_name twice. Read in all
6369 the local syms - did this code get deleted accidentally? Ignore
6370 undefined and undefweak syms.
6372 * elf-hppa.h (elf_hppa_final_link): Move hppa_info to outermost
6373 block. Use it instead of elf64_hppa_hash_table (info).
6374 (elf_hppa_final_link_relocate): Use hppa_info instead of
6375 elf64_hppa_hash_table (info).
6377 * libhppa.h (re_assemble_3, re_assemble_12, re_assemble_16,
6378 re_assemble_17, re_assemble_21, re_assemble_22): Don't mask insn.
6379 (hppa_rebuild_insn): Mask immediate bits here instead.
6380 * elf-hppa.h (elf_hppa_relocate_insn): Mask here too.
6382 2000-07-08 Alan Modra <alan@linuxcare.com.au>
6384 * section.c (struct sec): Add id field. Tidy comment formatting.
6385 (bfd_make_section_anyway): Set id.
6386 (STD_SECTION): Init id too.
6387 Change CONST to const throughout.
6388 * archures.c (bfd_arch_info): Tidy comment.
6389 (bfd_arch_list): Change a CONST to const.
6390 * libbfd-in.h: Tidy comments and replace CONST with const.
6391 * elf-bfd.h: Likewise.
6392 * libbfd.h: Regenerate.
6393 * bfd-in2.h: Regenerate.
6394 * libcoff.h: Regenerate.
6396 2000-07-07 DJ Delorie <dj@redhat.com>
6398 * archive.c (_bfd_write_archive_contents): Add an informative
6401 2000-07-06 Kazu Hirata <kazu@hxi.com>
6403 * srec.c: Fix formatting.
6405 2000-06-05 DJ Delorie <dj@redhat.com>
6409 2000-07-04 Alexandre Oliva <aoliva@redhat.com>
6411 * coff-arm.c (coff_arm_relocate_section): Do not ignore the symbol
6412 value of PC-relative offsets.
6414 2000-07-03 Jim Wilson <wilson@cygnus.com>
6416 * elf64-alpha.c (alpha_elf_size_info): New.
6417 (elf_backend_size_info): Define to alpha_elf_size_info.
6418 * elfcode.h (elf_size_info): Change hash bucket size to 4.
6420 2000-07-03 Ulf Carlsson <ulfc@engr.sgi.com>
6422 * elf32-mips.c: Include elf32-target.h again for the traditional
6425 2000-07-03 Marek Michalkiewicz <marekm@linux.org.pl>
6427 * elf32-avr.c (bfd_elf32_bfd_reloc_type_lookup):
6428 Add ATTRIBUTE_UNUSED to unused arguments to avoid warnings.
6429 (avr_info_to_howto_rela): Likewise.
6430 (elf32_avr_gc_mark_hook): Likewise.
6431 (elf32_avr_gc_sweep_hook): Likewise.
6432 (elf32_avr_relocate_section): Likewise.
6434 2000-07-03 Mark Elbrecht <snowball3@bigfoot.com>
6436 * cofflink.c (_bfd_coff_write_global_sym): Turn a weak symbol into
6437 an external symbol for a non-shared, non-relocatable link.
6439 2000-07-03 Nick Clifton <nickc@redhat.com>
6441 * cofflink.c (IS_EXTERNAL): New macro: Return true if the symbol
6442 is an external symbol.
6443 (IS_WEAK_EXTERNAL): New macro: Return true if the symbol is a weak
6446 2000-07-03 Kazu Hirata <kazu@hxi.com>
6448 * reloc16.c: Fix formatting.
6450 2000-07-01 Koundinya K <kk@ddeorg.soft.net>
6452 * config.bfd: Change targ_defvec and targ_selvecs for mips*-*-sysv4*
6453 to add a new target for traditional mips i.e
6454 bfd_elf32_tradbigmips_vec and bfd_elf32_tradlittlemips_vec.
6455 * configure.in: Likewise.
6456 * configure: Rebuild.
6457 * targets.c (bfd_elf32_tradbigmips_vec): Declare and put in
6459 (bfd_elf32_tradlittlemips_vec): Likewise.
6460 * elfxx-target.h: Add macro INCLUDED_TARGET_FILE which is more a test
6461 to see that elfNN_bed does not get redefined even if the target file
6462 is included twice for a chip. See elf32-mips.c.
6464 2000-07-01 Alan Modra <alan@linuxcare.com.au>
6466 * Makefile.am (DEP): Fix 2000-06-22. grep after running dep.sed
6467 (CLEANFILES): Add DEPA.
6468 * Makefile.in: Regenerate.
6470 2000-06-30 DJ Delorie <dj@cygnus.com>
6472 * peicode.h (coff_swap_filehdr_in): can't use e_magic because we
6473 can't assume the PE header is at 0x80.
6475 2000-06-29 Mark Elbrecht <snowball3@bigfoot.com>
6477 * syms.c (_bfd_stab_section_find_nearest_line): Use IS_ABSOLUTE_PATH.
6479 2000-06-28 Mark Elbrecht <snowball3@bigfoot.com>
6481 * go32stub.h: Update stub.
6483 2000-06-26 Marek Michalkiewicz <marekm@linux.org.pl>
6485 * archures.c (bfd_mach_avr5): Define.
6486 * bfd-in2.h (bfd_mach_avr5): Define.
6487 * cpu-avr.c (arch_info_struct): Rename bfd_mach_avr4 to
6488 bfd_mach_avr5, add bfd_mach_avr4. Update comments.
6489 (compatible): Update comment. Add missing test.
6490 * elf32-avr.c (avr_final_link_relocate): Support 8K wrap
6491 for avr2 and avr4. Simplify 8K wrap code.
6492 (bfd_elf_avr_final_write_processing): Recognize bfd_mach_avr5.
6493 (elf32_avr_object_p): Recognize E_AVR_MACH_AVR5.
6495 2000-06-26 Kazu Hirata <kazu@hxi.com>
6497 * coff-h8300.c: Fix formatting.
6498 * cpu-h8300.c: Likewise.
6500 2000-06-24 Alexandre Oliva <aoliva@redhat.com>
6502 * elf32-arm.h (elf32_arm_final_link_relocate): Print `(local)'
6503 for local symbols whose names are unknown.
6505 2000-06-22 Alan Modra <alan@linuxcare.com.au>
6507 * Makefile.am (DEP): grep for leading `/' in DEP1, and fail if we
6509 * Makefile.in: Regenerate.
6510 * doc/Makefile.in: Regenerate.
6512 2000-06-20 H.J. Lu <hjl@gnu.org>
6514 * Makefile.am: Rebuild dependency.
6515 * Makefile.in: Rebuild.
6517 2000-06-20 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
6519 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): New function.
6520 (elf_backend_copy_indirect_symbol): Map to the new function.
6522 2000-06-20 Alan Modra <alan@linuxcare.com.au>
6524 * archive.c (normalize): Correct pointer comparison when checking
6526 (bfd_bsd_truncate_arname): Likewise.
6527 (bfd_gnu_truncate_arname): Likewise.
6529 2000-06-20 Ulf Carlsson <ulfc@engr.sgi.com>
6531 * elf-bfd.h (struct elf_obj_tdata): Define per BFD Irix 5 virtual
6532 sections elf_{text,data}_{section,symbol}.
6533 * elf32-mips.c: mips_elf_{text,data}_{section,symbol}{,_ptr}: Remove.
6534 (_bfd_mips_elf_hide_symbol): New function.
6535 (elf_backend_hide_symbol): Map to the new function.
6536 (_bfd_mips_elf_add_symbol_hook): Change to use new per BFD
6537 definitions of mips_elf_{text,data}_{section,symbol}.
6538 (mips_elf_local_relocation_p): Try to find the direct symbol
6539 based on new check_forced argument.
6540 (mips_elf_calculate_relocation): Use new version of
6541 mips_elf_local_relocation_p.
6542 (mips_elf_relocate_section): Likewise.
6543 (_bfd_mips_elf_relocate_section): Likewise.
6544 (mips_elf_sort_hash_table): Only assert that have enough GOT
6546 (mips_elf_got16_entry): Match all 32 bits to the existing GOT
6547 entry if the relocation based on the new external argument.
6548 (mips_elf_create_dynamic_relocation): Assert that we have a
6549 section contents allocated where we can swap out the dynamic
6551 (mips_elf_calculate_relocation): Find the real hash-table entry
6552 correctly by using h->root.root.type. Only create a dynamic
6553 relocation entry if the symbol is defined in a shared library.
6554 Create an external GOT entry for the GOT16 relocation if the
6555 symbol was forced local.
6556 (_bfd_mips_elf_finish_dynamic_symbol): Don't assert there is a
6557 dynamic index if the symbol was forced local.
6559 2000-06-20 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
6561 * elf32-mips.c: Fix typos in comments.
6563 2000-06-19 Mark Kettenis <kettenis@gnu.org>
6565 * rs6000-core.c: Wrap definition of `union VmInfo' within #ifdef
6568 2000-06-18 Stephane Carrez <stcarrez@worldnet.fr>
6570 * Makefile.in, bfd-in2.h, libbfd.h, configure: Rebuild.
6571 * Makefile.am (ALL_MACHINES, ALL_MACHINES_CFILES, BFD32_BACKENDS,
6572 BFD32_BACKENDS_CFILES): Add 68hc12, 68hc11 files.
6573 * configure.in (bfd_elf32_m68hc12_vec): Recognize.
6574 (bfd_elf32_m68hc11_vec): Likewise.
6575 * config.bfd (targ_cpu): Recognize 68hc12 and 68hc11.
6576 Supports 68hc11 & 68hc12 at the same time.
6577 * targets.c (bfd_elf32_m68hc12_vec): Declare and put in
6579 (bfd_elf32_m68hc11_vec): Likewise.
6580 * elf.c (prep_headers): Recognize bfd_arch_m68hc12 and 68hc11.
6581 * archures.c (bfd_m68hc12_arch): Define and register in global list
6582 (bfd_m68hc11_arch): Likewise.
6583 * reloc.c (BFD_RELOC_M68HC11_HI8, BFD_RELOC_M68HC11_LO8,
6584 BFD_RELOC_M68HC11_3B): Define.
6585 * cpu-m68hc12.c, elf32-m68hc12.c: New files for 68hc12 support.
6586 * cpu-m68hc11.c, elf32-m68hc11.c: New files for 68hc11 support.
6588 2000-06-18 Ulf Carlsson <ulfc@engr.sgi.com>
6590 * elf_bfd.h (struct elf_backend_data): Add info argument to
6591 elf_backend_hide_symbol.
6592 (_bfd_elf_link_hash_hide_symbol): Likewise.
6593 * elf.c (_bfd_elf_link_hash_hide_symbol): Likewise.
6594 * elf64-ia64.c (elf64_ia64_hash_hide_symbol): Likewise.
6595 * elflink.h (elf_link_add_object_symbols): Likewise.
6596 (elf_link_assign_sym_version): Likewise.
6598 2000-06-18 H.J. Lu <hjl@gnu.org>
6600 * coff-i386.c (coff_i386_reloc): Don't return in case of
6601 output_bfd == (bfd *) NULL if COFF_WITH_PE is defined.
6602 Compensate PE relocations when linking with non-PE object
6603 files to generate a non-PE executable.
6605 2000-06-17 Ulf Carlsson <ulfc@engr.sgi.com>
6607 * elf32-mips.c (mips_elf_calculate_relocation): Explicitly write
6608 GOT entries if we're doing a static link or -Bsymbolic link.
6610 2000-06-15 Ulf Carlsson <ulfc@engr.sgi.com>
6612 * elflink.h (elf_link_adjust_relocs): Check for and call backend
6613 specifific swap_reloc_{in,out} and swap_reloca_{in,out} if
6615 (elf_link_output_relocs): Likewise.
6616 (elf_reloc_link_order): Likewise.
6618 2000-06-16 Nicholas Duffek <nsd@redhat.com>
6620 * archures.c (enum bfd_architecture): #define constants for
6621 PowerPc and RS6000 machine numbers.
6622 * bfd-in2.h: Regenerate.
6623 * coffcode.h (coff_set_arch_mach_hook): #ifdef XCOFF64, set arch
6624 to bfd_arch_powerpc instead of bfd_arch_rs6000. Refer to PowerPc
6625 and RS6000 machine numbers using #defined constants from
6627 * cpu-powerpc.c (arch_info_struct): Refer to PowerPc and RS6000
6628 machine numbers using #defined constants from archures.c. Add
6629 entries for EC603e, 630, A35, RS64II, RS64III, 7400. Specify
6630 64-bit words in 620 entry.
6631 * cpu-rs6000.c (arch_info_struct): Create with entries for RS1,
6633 (bfd_rs6000_arch): Change default machine to 0 (bfd_mach_rs6k).
6635 2000-06-16 Nicholas Duffek <nsd@cygnus.com>
6637 * coffcode.h (coff_mkobject_hook): Set xcoff_tdata.xcoff64.
6638 * libcoff-in.h (struct xcoff_tdata): Define xcoff64 field.
6639 * libcoff.h (struct xcoff_tdata): Define xcoff64 field.
6641 2000-06-16 Nicholas Duffek <nsd@redhat.com>
6643 * bfd-in.h (bfd_family_coff): Define.
6644 * bfd-in2.h: Regenerate.
6645 * coffgen.c (coff_count_linenumbers, coff_symbol_from,
6646 coff_find_nearest_line): Check COFFness using bfd_family_coff()
6647 instead of bfd_target_coff_flavour.
6648 * cofflink.c (_bfd_coff_final_link): Likewise.
6649 * cpu-ns32k.c (do_ns32k_reloc): Don't strcmp() target name to
6650 exclude XCOFF files.
6651 * reloc.c (bfd_perform_relocation, bfd_install_relocation):
6653 * targets.c (enum bfd_flavour): Add bfd_target_xcoff_flavour.
6654 * xcoff-target.h (TARGET_SYM): Use bfd_target_xcoff_flavour.
6655 * xcofflink.c (XCOFF_XVECP): Delete.
6656 (bfd_xcoff_link_record_set, bfd_xcoff_import_symbol,
6657 bfd_xcoff_export_symbol, bfd_xcoff_link_count_reloc,
6658 bfd_xcoff_record_link_assignment,
6659 bfd_xcoff_size_dynamic_sections): Replace XCOFF_XVECP() with
6660 check for bfd_target_xcoff_flavour.
6662 2000-06-16 Nicholas Duffek <nsd@redhat.com>
6664 * rs6000-core.c: Support 64-bit core files, support pre-4.3 core
6666 (read_hdr): New function.
6667 (rs6000coff_core_p): Store mstsave or __context64 struct instead
6668 of trying to extract individual registers. Set abfd->arch_info
6669 to match the architecture that created the core file.
6670 (rs6000coff_get_section_contents): Delete.
6671 * xcoff-target.h (rs6000coff_get_section_contents): Delete.
6673 2000-06-14 H.J. Lu <hjl@gnu.org>
6675 * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_rec)
6678 2000-06-13 H.J. Lu <hjl@gnu.org>
6680 * configure: Regenerate.
6682 2000-06-13 J"orn Rennecke <amylaar@cygnus.co.uk>
6684 * peicode.h (pe_ILF_object_p): Use TARGET_LITTLE_SYM instead of
6687 2000-06-08 David O'Brien <obrien@FreeBSD.org>
6689 * configure.in (VERSION): Update to show this is the CVS mainline.
6691 2000-06-07 Alan Modra <alan@linuxcare.com.au>
6693 * elf32-d10v.c: Include elf/d10v.h
6694 (enum reloc_type): Delete.
6695 * elf32-d30v.c: Include elf/d30v.h
6696 (enum reloc_type): Delete.
6698 * Makefile.am: Run "make dep-am" to regenerate dependencies.
6699 * Makefile.in: Regenerate.
6701 * elf32-i386.c (elf_howto_table): Remove EMPTY_HOWTOs.
6702 (elf32_i386_vtinherit_howto, elf32_i386_vtentry_howto): Delete and
6703 move HOWTOs into elf_howto_table.
6704 (R_386_standard, R_386_ext_offset): Define.
6705 (R_386_ext, R_386_vt_offset, R_386_vt): Define.
6706 (elf_i386_reloc_type_lookup): Modify calculation of index into
6707 elf_howto_table since we've removed the padding.
6708 (elf_i386_info_to_howto_rel): Likewise.
6709 (elf_i386_relocate_section): Likewise.
6711 2000-06-06 Michael Snyder <msnyder@seadog.cygnus.com>
6713 * elf.c (elf_grok_pr_status): Eliminate reference to prgregset_t.
6715 2000-06-05 H.J. Lu <hjl@gnu.org>
6717 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Don't flag
6718 an error when seeing an undefined symbol with hidden/internal
6719 attribute. It is handled in *_relocate_section ().
6721 2000-06-05 H.J. Lu <hjl@gnu.org>
6723 * elflink.h (elf_fix_symbol_flags): Follow the link for the
6724 indirect symbol for the ELF_LINK_NON_ELF bit.
6725 (elf_link_output_extsym): Don't output the indirect symbol even
6726 if the ELF_LINK_NON_ELF bit is set.
6728 2000-06-01 J.T. Conklin <jtc@redback.com>
6730 * config.bfd (i[3456]86-*-netbsdelf*): New target.
6731 (i[3456]86-*-netbsdaout*): New target.
6732 (i[3456]86-*-netbsd*): Add bfd_elf32_i386_vec to targ_selvecs.
6733 (i[3456]86-*-openbsd*): Likewise.
6735 2000-05-30 Andrew Cagney <cagney@b1.cygnus.com>
6737 * trad-core.c: From hpux-core.c, include <dirent.h> or
6738 <sys/ndir.h> when possible.
6740 2000-05-31 Ulrich Drepper <drepper@redhat.com>
6742 * elf.c (_bfd_elf_slurp_version_tables): Correct reading of version
6743 definitions. We must not assume they are sorted in the file
6744 according to their index numbers.
6746 2000-05-31 Alan Modra <alan@linuxcare.com.au>
6748 * elf-hppa.h: (elf_hppa_final_link_relocate): Use e_rsel field
6749 selector for R_PARISC_PCREL17R. R_PARISC_DIR17R and
6750 R_PARISC_DIR17F are for absolute branches; Handle them as such.
6752 2000-05-30 Nick Clifton <nickc@cygnus.com>
6754 * cpu-i960.c (scan_960_mach): Accept 80960KA, 80960KB,
6755 80960CA, 80960MC as valid machine names.
6757 2000-05-30 H.J. Lu <hjl@gnu.org>
6759 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Clear the
6760 visibility bits if the symbol is undefined. Correctly handle
6761 weak undefined symbols with hidden and internal attributes.
6763 * elflink.h (elf_link_add_object_symbols): Always turn the
6764 symbol into local if it has the hidden or internal attribute.
6766 2000-05-29 Philip Blundell <philb@gnu.org>
6768 * ppcboot.c: Add packed attribute if compiling with GCC.
6770 2000-05-29 Anatoly Vorobey <mellon@pobox.com>
6772 * elf.c (_bfd_elf_link_hash_table_init): Initialize dynlocal.
6774 2000-05-26 Michael Snyder <msnyder@seadog.cygnus.com>
6776 * elf.c (elfcore_grok_prstatus, elfcore_grok_pstatus,
6777 elfcore_grok_psinfo): Add code to allow debugging a 32-bit
6778 corefile on a 64-bit (Sparc Solaris) host. Also clean up
6781 2000-05-26 Alan Modra <alan@linuxcare.com.au>
6783 * Makefile.am: Update dependencies with "make dep-am"
6784 * Makefile.in: Regenerate.
6786 * sysdep.h (gettext, dgettext, dcgettext, textdomain,
6787 bindtextdomain): Replace defines with those from intl/libgettext.h
6788 to quieten gcc warnings.
6790 2000-05-26 Eli Zaretskii <eliz@is.elta.co.il>
6792 * aoutx.h (find_nearest_line): Use IS_ABSOLUTE_PATH.
6794 * archive.c (normalize, bfd_bsd_truncate_arname,
6795 bfd_gnu_truncate_arname) [HAVE_DOS_BASED_FILE_SYSTEM]: Support
6796 file names with backslashes.
6798 * cache.c (bfd_open_file) [__MSDOS__]: Don't unlink the file
6801 * sysdep.h: Include filenames.h.
6803 2000-05-26 Alan Modra <alan@linuxcare.com.au>
6805 * opncls.c (bfd_close_all_done): Mask file perms with 0777 not 0x777.
6807 2000-05-26 Jakub Jelinek <jakub@redhat.com>
6809 * elf64-sparc.c (sparc64_elf_relax_section): New.
6810 (sparc64_elf_relocate_section): Optimize tail call into branch always
6812 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
6813 (elf32_sparc_relax_section): New.
6815 2000-05-26 Jakub Jelinek <jakub@redhat.com>
6817 * elf64-sparc.c: Add ATTRIBUTE_UNUSED to unused function parameters.
6818 Remove unusued variables.
6819 (sparc64_elf_relocate_section): Change r_symndx type to unsigned long.
6820 (sparc64_elf_merge_private_bfd_data): Fix shared library case from
6821 previous fix, so that shared libs really don't influence targets
6822 extension mask and memory model.
6824 2000-05-23 H.J. Lu <hjl@gnu.org>
6826 * elf64-alpha.c (elf64_alpha_relocate_section): Check
6827 h->root.other not h->other.
6828 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
6830 * elf32-ppc.c (ppc_elf_relocate_section): Fix a typo.
6832 2000-05-23 H.J. Lu <hjl@gnu.org>
6834 * elf32-i386.c (elf_i386_relocate_section): Don't allow the
6835 undefined symbol with the non-default visibility attributes.
6836 * elf-hppa.h (elf_hppa_relocate_section): Likewise.
6837 * elf32-arm.h (elf32_arm_relocate_section): Likewise.
6838 * elf32-i370.c (i370_elf_relocate_section): Likewise.
6839 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
6840 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
6841 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
6842 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
6843 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
6844 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
6845 * elf64-ia64.c (elf64_ia64_relocate_section): Likewise.
6846 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
6848 2000-05-22 Richard Henderson <rth@cygnus.com>
6850 * elf64-ia64.c (ia64_howto_table): Add PCREL60B, PCREL21BI,
6851 PCREL22, PCREL64I. Zero size of special relocs.
6852 (elf64_ia64_reloc_type_lookup): Likewise.
6853 (USE_BRL, oor_brl, oor_ip): New.
6854 (elf64_ia64_relax_section): New.
6855 (elf64_ia64_check_relocs): Handle PCREL60B, PCREL22, PCREL64I.
6856 (elf64_ia64_install_value): Likewise, plus PCREL21BI.
6857 (elf64_ia64_relocate_section): Likewise.
6858 (bfd_elf64_bfd_relax_section): New.
6859 * reloc.c (BFD_RELOC_IA64_PCREL21BI): New.
6860 (BFD_RELOC_IA64_{PCREL22,PCREL60B,PCREL64I}): New.
6861 * bfd-in2.h, libbfd.h: Regenerate.
6863 2000-05-22 Nick Clifton <nickc@cygnus.com>
6865 * configure.in : Add peigen.lo to MIPS PE targets.
6866 * configure: Regenerate.
6868 2000-05-22 Momchil Velikov <velco@fadata.bg>
6870 * libbfd.c (_bfd_generic_verify_endian_match): Compare endianess
6871 only if it is known for both input and output bfds. Separate
6872 error message strings as in some languages, it may be necessary
6873 to change more than one place in the string to change between
6876 * elf32-ppc.c (ppc_elf_merge_private_bfd_data): Remove inline
6877 endianess checks, call _bfd_generic_verify_endian_match() instead.
6879 * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Likewise.
6881 * elf32-mcore.c (mcore_elf_merge_private_bfd_data): Likewise.
6883 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Likewise. Verify
6884 endianess before checking bfd flavours.
6886 2000-05-22 H.J. Lu <hjl@gnu.org>
6888 * elflink.h (elf_link_output_extsym): Clear the visibility
6889 field for symbols not defined locally.
6891 2000-05-18 Alan Modra <alan@linuxcare.com.au>
6893 * libhppa.h (re_assemble_3, re_assemble_12, re_assemble_16,
6894 re_assemble_17, re_assemble_21, re_assemble_22): Don't mask insn.
6895 (hppa_rebuild_insn): Mask immediate bits here instead.
6896 * elf-hppa.h (elf_hppa_relocate_insn): Mask here too.
6898 2000-05-18 Momchil Velikov <velco@fadata.bg>
6900 * elflink.h (elf_bfd_final_link, elf_link_input_bfd): When emiting
6901 relocs for an executable, ensure that they are virtual addresses.
6903 2000-05-18 Jeffrey A Law (law@cygnus.com)
6905 * config.bfd (hppa*64*-*-hpux11*): New target triplet.
6907 2000-05-17 S. Bharadwaj Yadavalli <sby@scrugs.lkg.dec.com>
6908 Rick Gorton <gorton@scrugs.lkg.dec.com>
6910 * elflink.h: Add emitrelocations support: when enabled, relocation
6911 information and relocation sections are put into final output
6912 executables. If the emitrelocations flag is set, do the following:
6913 (elf_bfd_final_link): Emit relocation sections.
6914 (elf_link_input_bfd): Compute relocation section contents.
6915 (elf_gc_sections): Don't clean relocation sections.
6917 2000-05-16 Catherine Moore <clm@cygnus.com>
6919 * som.c (som_decode_symclass): Recognize weak symbols.
6921 2000-05-16 Szabolcs Szakacsits <szaka@F-Secure.com>
6923 * peigen.c (pe_print_idata): Undo part of 2000-05-12 change that
6924 read idata section only from dataoff.
6925 (pe_print_edata): Correctly check for valid eat_member.
6927 2000-05-16 J"orn Rennecke <amylaar@cygnus.co.uk>
6929 * elf32-sh.c (sh_elf_relax_delete_bytes): Handle R_SH_SWITCH8.
6931 2000-05-14 Philip Blundell <philb@gnu.org>
6933 * config.bfd (armeb-*-elf, arm*b-*-linux-gnu*): New targets.
6935 2000-05-12 Alan Modra <alan@linuxcare.com.au>
6937 * targets.c (bfd_target_vector): #ifdef BFD64 rs6000coff64_vec
6939 * peigen.c (pe_print_idata): Look for .idata section and print
6940 info even if data directory has zero entries. Read idata section
6941 starting from dataoff, and adjust all data offsets to suit. Cast
6942 all bfd_vma vars to unsigned long before passing to fprintf.
6943 * peigen.c (pe_print_edata): Similarly, look for .edata section
6944 and print info even if data directory has zero entries. Cast
6945 all bfd_vma vars to unsigned long before passing to fprintf.
6947 From Szabolcs Szakacsits <szaka@F-Secure.com>
6948 * peigen.c (pe_print_idata): Use bfd_section_size rather than data
6949 directory size which may be bogus.
6950 * peigen.c (pe_print_edata): Similarly.
6952 2000-05-09 Alan Modra <alan@linuxcare.com.au>
6954 * elf.c (bfd_section_from_shdr): Don't set use_rela_p if rela
6956 (copy_private_bfd_data): Allow for space possibly taken up by elf
6957 headers when calculating segment physical address from lma.
6959 2000-05-08 Alan Modra <alan@linuxcare.com.au>
6961 * versados.c (versados_scan): Init stringlen and pass_2_done.
6963 * trad-core.c (trad_unix_core_file_p): Return
6964 bfd_error_wrong_format rather than bfd_error_file_truncated.
6966 * peigen.c (_bfd_pei_swap_aouthdr_out): Pass ImageBase to
6967 add_data_entry. DataDirectory virtual address is relative.
6968 (pe_print_idata): Account for relative DataDirectory virtual
6969 addresses. Don't trash datasize inside POWERPC_LE_PE code.
6970 (pe_print_edata): Similarly.
6972 From Szabolcs Szakacsits <szaka@F-Secure.com>
6973 * peigen.c (dir_names): Add Delay Import Directory.
6974 (pe_print_idata): Always search for bfd section containing
6975 idata address rather than looking up section name. Print this
6976 section name rather than .idata.
6977 (pe_print_edata): Similarly. Also print some fields as %08lx.
6978 (_bfd_pe_print_private_bfd_data_common): Print Reserved1 field as
6981 2000-05-05 Clinton Popetz <cpopetz@cygnus.com>
6983 * xcoff.h: Rename to xcoff-target.h
6984 * Makefile.am: Change all instances of xcoff.h to xcoff-target.h
6985 * coff-rs6000.c: Ditto.
6986 * coff64-rs6000.c: Ditto.
6987 * coff-pmac.c: Ditto.
6988 * Makefile.in: Regenerate.
6990 2000-05-05 Clinton Popetz <cpopetz@cygnus.com>
6992 * coffcode.h (coff_set_arch_mach_hook, coff_set_flags):
6993 Change U802TOC64MAGIC to U803XTOCMAGIC.
6995 2000-05-04 Michael Snyder <msnyder@seadog.cygnus.com>
6997 * elf.c (bfd_elf_get_arch_size): New function, return 32 | 64 | -1.
6998 * bfd-in.h: Prototype bfd_elf_get_arch_size.
6999 * bfd-in2.h: Prototype bfd_elf_get_arch_size.
7001 2000-05-04 Alan Modra <alan@linuxcare.com.au>
7003 * libhppa.h (HPPA_R_CONSTANT): Cast argument to bfd_signed_vma.
7005 2000-05-03 Martin v. L
\81öwis <loewis@informatik.hu-berlin.de>
7007 * elflink.h (elf_link_add_object_symbols): Reset dynindx for
7008 hidden and internal symbols.
7009 (elf_fix_symbol_flags): Clear NEEDS_PLT for symbols with
7011 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Do not
7012 assign a PLT or GOT entry to symbols with hidden and
7013 internal visibility.
7015 2000-05-03 Mark Elbrecht <snowball3@bigfoot.com>
7017 * coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Add entry for
7019 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
7021 2000-05-02 H.J. Lu <hjl@gnu.org>
7023 * elf.c (prep_headers): Use ELFOSABI_NONE instead of
7026 2000-05-02 Alan Modra <alan@linuxcare.com.au>
7028 * targets.c (bfd_target_vector): Restore bfd_elf32_hppa_vec.
7029 * Makefile.am (BFD32_BACKENDS): Restore elf32-hppa.lo. Regenerate
7031 * Makefile.in: Regenerate.
7033 2000-05-01 Jim Wilson <wilson@cygnus.com>
7035 * Makefile.am (BFD32_BACKENDS): Add efi-app-ia32.lo.
7036 (BFD32_BACKENDS_CFILES): Add efi-app-ia32.c.
7037 (BFD64_BACKENDS): Delete coff-ia64.lo. Add efi-app-ia64.lo.
7038 (BFD64_BACKENDS_CFILES): Delete coff-ia64.c. Add efi-app-ia64.c.
7039 * Makefile.in: Rebuild.
7041 2000-05-02 Alan Modra <alan@linuxcare.com.au>
7043 * config.bfd: Re-enable elf32-hppa. It now compiles, even if it
7044 doesn't work very well.
7046 * elf-hppa.h (elf_hppa_internal_shdr): Define.
7047 (elf_hppa_fake_sections): hdr is elf_hppa_internal_shdr.
7048 Set hdr->s_type to 1 if ARCH_SIZE == 32.
7049 (_bfd_elf_hppa_gen_reloc_type): Add prototype.
7050 (elf_hppa_info_to_howto): Likewise.
7051 (elf_hppa_info_to_howto_rel): Likewise.
7052 (elf_hppa_reloc_type_lookup): Likewise.
7053 (elf_hppa_is_local_label_name): Likewise.
7054 (elf_hppa_fake_sections): Likewise.
7055 (elf_hppa_final_write_processing): Likewise.
7056 (elf_hppa_howto_table): Fully initialise all entries.
7057 (_bfd_elf_hppa_gen_reloc_type): Add ATTRIBUTE_UNUSED to args.
7058 (elf_hppa_info_to_howto): Likewise.
7059 (elf_hppa_info_to_howto_rel): Likewise.
7060 (elf_hppa_reloc_type_lookup): Likewise.
7061 (elf_hppa_final_write_processing, elf_hppa_add_symbol_hook,
7062 elf_hppa_unmark_useless_dynamic_symbols,
7063 elf_hppa_remark_useless_dynamic_symbols,
7064 elf_hppa_record_segment_addrs, elf_hppa_final_link,
7065 elf_hppa_relocate_section, elf_hppa_final_link_relocate,
7066 elf_hppa_relocate_insn): Compile only if ARCH_SIZE == 64 until
7067 elf32-hppa.c mess is cleaned up.
7068 (elf_hppa_final_link_relocate): Make insn and r_type unsigned
7069 int. Delete r_field. In case R_PARISC_PCREL21L, don't set
7070 r_field then call hppa_field_adjust inline func with variable
7071 r_field arg, instead call hppa_field_adjust with fixed arg.
7072 In case R_PARISC_PCREL22F, don't set r_field.
7073 (elf_hppa_relocate_insn): Change args and return type to unsigned
7074 int. Call re_assemble_* funcs to do the work.
7076 * elf32-hppa.c (hppa_elf_relocate_insn): Don't assume 32 bit when
7079 * libhppa.h (HPPA_R_CONSTANT): Don't assume 32 bit when sign
7081 (sign_extend): Mask first before sign extending.
7082 (low_sign_extend): Rewrite without condition expression.
7083 (ones, dis_assemble_3, dis_assemble_12, dis_assemble_16,
7084 dis_assemble_17, dis_assemble_21, dis_assemble_22): Delete.
7085 (assemble_3, assemble_6, assemble_12, assemble_16, assemble_16a,
7086 assemble_17, assemble_21, sign_unext, low_sign_unext): Return
7087 result as function return value rather than through pointer arg.
7088 Accept unsigned int args, and return unsigned int.
7089 (re_assemble_3): New. Combines function of dis_assemble_3 with
7090 re-assembly of opcode and immediate.
7091 (re_assemble_12): Likewise.
7092 (re_assemble_16): Likewise.
7093 (re_assemble_17): Likewise.
7094 (re_assemble_21): Likewise.
7095 (re_assemble_22): Likewise.
7096 (hppa_field_adjust): Rewrite and document, paying attention to
7097 size of types and signed/unsigned issues.
7098 (get_opcode): Shift before masking.
7099 (FDLW): Rename to FLDW.
7100 (bfd_hppa_insn2fmt): Change arg to unsigned int. Delete fmt.
7101 (hppa_rebuild_insn): Change args and return value to unsigned
7102 int. Make use of re_assemble_*. Correct case 11.
7104 * dep-in.sed: Handle ../opcodes/.
7105 * Makefile.am (SOURCE_HFILES): Add elf-hppa.h, elf32-hppa.h,
7106 elf64-hppa.h, hppa_stubs.h, xcoff.h.
7107 (BFD32_BACKENDS_CFILES): Restore elf32-hppa.c.
7108 Remove elf64-hppa.lo, cpu-ia64.lo, elf64-ia64.lo, elfarm-oabi.lo,
7109 elfarm-nabi.lo dependencies outside of auto-dependency area.
7110 Regenerate dependencies.
7111 * Makefile.in: Regenerate.
7113 * configure.in (TRAD_HEADER): Test non-null before
7115 * configure: Regenerate.
7117 * reloc.c: Fix mis-spelling in comment.
7119 2000-05-01 Alan Modra <alan@linuxcare.com.au>
7121 * coff-sh.c (bfd_coff_small_swap_table): Fix Fri Apr 28 change.
7122 * vms.c (vms_openr_next_archived_file): Return NULL.
7124 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7126 * coffcode.h Copy changes mistakenly done to libcoff.h in
7129 2000-04-29 Andreas Jaeger <aj@suse.de>
7131 * libbfd-in.h: Correctly check GCC version.
7132 * bfd-in.h: Likewise.
7133 * libhppa.h: Likewise.
7134 * libbfd.h: Regenerate.
7135 * bfd-in2.h: Regenerate.
7137 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7139 * Makefile.am (BFD64_BACKENDS, BFD64_BACKENDS_CFILES): Add
7140 coffdu-rs6000.{lo,c}.
7141 (coff-pmac.lo, coff-rs6000.lo, coff64-rs6000.lo): Add dependency
7143 * Makefile.in: Regenerate.
7144 * xcoff.h: New file.
7145 * coff-pmac.c: Use xcoff.h instead of coff-rs6000.c.
7146 * coff-rs6000.c: Move all declarations and defines that are
7147 common to the xcoff backends into xcoff.h
7148 * coff64-rs6000.c: Ditto,
7150 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7152 * coff-mips.c (mips_ecoff_backend_data): Add initialization of
7153 _bfd_coff_force_symnames in strings and
7154 _bfd_coff_debug_string_prefix_length to their default values.
7155 * coff-sh.c: (bfd_coff_small_swap_table): Ditto.
7157 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7159 * coff-alpha.c (alpha_ecoff_backend_data): Add initialization of
7160 _bfd_coff_force_symnames in strings and
7161 _bfd_coff_debug_string_prefix_length to their default values.
7163 2000-04-27 Alan Modra <alan@linuxcare.com.au>
7165 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Return if dynobj NULL.
7166 Check local_got_refcounts before dereferencing.
7168 * elf32-ppc.c (ppc_elf_relocate_section): Check splt != NULL
7169 before deciding we don't need R_PPC_PLT32 relocation.
7170 (ppc_elf_gc_sweep_hook): Check local_got_refcounts before
7173 * elflink.h (elf_gc_common_finalize_got_offsets): Fix comment.
7175 * elf32-i386.c (elf_i386_check_relocs): Reference count .got and
7177 (elf_i386_gc_sweep_hook): Garbage collect .got and .plt entries.
7178 (elf_i386_adjust_dynamic_symbol): Recognize unused .plt entries.
7179 (elf_i386_relocate_section): Allow for .plt to go missing.
7180 (elf_i386_finish_dynamic_symbol): Use same test to decide if we
7181 can use a relative reloc for got as elf_i386_relocate_section.
7182 (bfd_elf32_bfd_final_link): Define to use gc form of final link.
7184 2000-04-26 Clinton Popetz <cpopetz@cygnus.com>
7186 * config.bfd: Remove extraneous bfd_powerpc_64_arch.
7188 2000-04-24 Clinton Popetz <cpopetz@cygnus.com>
7190 * Makefile.am (coff64-rs6000.lo): New rule.
7191 * Makefile.in: Regenerate.
7192 * coff-rs6000.c (xcoff_mkobject, xcoff_copy_private_bfd_data,
7193 xcoff_is_local_label_name, xcoff_rtype2howto,
7194 xcoff_reloc_type_lookup, xcoff_slurp_armap, xcoff_archive_p,
7195 xcoff_read_ar_hdr, xcoff_openr_next_archived_file, xcoff_write_armap,
7196 xcoff_write_archive_contents): No longer static, and prefix with _bfd_.
7197 (NO_COFF_SYMBOLS): Define.
7198 (xcoff64_swap_sym_in, xcoff64_swap_sym_out, xcoff64_swap_aux_in,
7199 xcoff64_swap_aux_out): New functions; handle xcoff symbol tables
7201 (MINUS_ONE): New macro.
7202 (xcoff_howto_tabl, xcoff_reloc_type_lookup): Add 64 bit POS
7204 (coff_SWAP_sym_in, coff_SWAP_sym_out, coff_SWAP_aux_in,
7205 coff_SWAP_aux_out): Map to the new functions.
7206 * coff64-rs6000.c: New file.
7207 * libcoff.h (bfd_coff_backend_data): Add new fields
7208 _bfd_coff_force_symnames_in_strings and
7209 _bfd_coff_debug_string_prefix_length.
7210 (bfd_coff_force_symnames_in_strings,
7211 bfd_coff_debug_string_prefix_length): New macros for above fields.
7212 * coffcode.h (coff_set_arch_mach_hook): Handle XCOFF64 magic.
7213 Set machine to 620 for XCOFF64. Use bfd_coff_swap_sym_in instead
7214 of using coff_swap_sym_in directly.
7215 (FORCE_SYMNAMES_IN_STRINGS): New macro, defined for XCOFF64.
7216 (coff_set_flags) Set magic for XCOFF64.
7217 (coff_compute_section_file_positions): Add symbol name length to
7218 string section length if bfd_coff_debug_string_prefix_length is
7220 (coff_write_object_contents): Don't do reloc overflow for XCOFF64.
7221 (coff_slurp_line_table): Use bfd_coff_swap_lineno_in instead of
7222 using coff_swap_lineno_in directly.
7223 (bfd_coff_backend_data): Add _bfd_coff_force_symnames_in_strings
7224 and _bfd_coff_debug_string_prefix_length fields.
7225 * coffgen.c (coff_fix_symbol_name, coff_write_symbols): Force
7226 symbol names into strings table when
7227 bfd_coff_force_symnames_in_strings is true.
7228 * coffswap.h (MAX_SCNHDR_NRELOC, MAX_SCNHDR_NLNNO, GET_RELOC_VADDR,
7229 SET_RELOC_VADDR): New macros.
7230 (coff_swap_reloc_in, coff_swap_reloc_out): Use above macros.
7231 (coff_swap_aux_in, coff_swap_aux_out): Remove RS6000COFF_C
7233 (coff_swap_aouthdr_in, coff_swap_aouthdr_out): Handle XCOFF64
7234 changes within RS6000COFF_C specific code.
7235 (coff_swap_scnhdr_out): Use PUT_SCNHDR_NLNNO, PUT_SCNHDR_NRELOC,
7236 MAX_SCNHDR_NRELOC, and MAX_SCNHDR_NLNNO.
7237 * reloc.c (bfd_perform_relocation, bfd_install_relocation):
7238 Extend existing hack on target name.
7239 * xcofflink.c (XCOFF_XVECP): Extend existing hack on
7241 * coff-tic54x.c (ticof): Keep up to date with new fields
7242 in bfd_coff_backend_data.
7243 * config.bfd: Add bfd_powerpc_64_arch to targ_arch and define
7244 targ_selvecs to include rs6000coff64_vec for rs6000.
7245 * configure.in: Add rs6000coff64_vec case.
7246 * cpu-powerpc.c: New bfd_arch_info_type.
7248 2000-04-24 Jeffrey A Law (law@cygnus.com)
7250 * config.bfd: Only disable elf32-hppa vectors, not all of the
7251 BSD and OSF configuration support. Provide (disabled) clauses
7253 * configure.in: Add clause for PA64 support.
7254 * configure: Rebuilt.
7256 * targets.c (bfd_target_vector): Add bfd_elf64_hppa_vec.
7257 (bfd_elf64_hppa_vec): Declare.
7259 * Makefile.am (BFD64_BACKENDS): Add elf64-hppa.lo
7260 (BFD64_BACKENDS_CFILES): Add elf64-hppa.c
7261 (elf64-hppa.lo): Add dependencies.
7262 * Makefile.in: Rebuilt.
7264 * elf64-hppa.c, elf64-hppa.h: New files with PA64 support.
7266 2000-04-24 Jason Eckhardt <jle@cygnus.com>
7268 * libhppa.h (dis_assemble_16): New function.
7269 (pa_arch): Added pa20w element.
7271 2000-04-24 Ulrich Drepper <drepper@cygnus.com>
7273 * elf-bfd.h: Add prototypes for bfd_elf32_write_relocs,
7274 bfd_elf32_slurp_reloc_table, bfd_elf64_write_relocs, and
7275 bfd_elf64_slurp_reloc_table.
7277 * elfcode.h (elf_write_relocs, elf_slurp_reloc_table): New
7278 definitions to get external names.
7279 (elf_write_relocs): Renamed from write_relocs and make global.
7280 (elf_slurp_reloc_table): Make global.
7281 (_bfd_elf,size_info): Use elf_write_relocs instead of write_relocs.
7283 * archive.c (hpux_uid_gid_encode): New function.
7284 (bfd_ar_hdr_from_filesystem): Use it if HPUX_LARGE_AR_IDS is
7285 defined and the ID is greater than 99999.
7286 (bfd_generic_stat_arch_elt): If HPUX_LARGE_AR_IDS is defined decode
7287 special uid/gid fields into 32 bit values.
7289 2000-04-21 Matthew Green <mrg@cygnus.com>
7291 * config.bfd: Add NetBSD/sparc64 support.
7293 Fri Apr 21 13:20:53 2000 Richard Henderson <rth@cygnus.com>
7294 David Mosberger <davidm@hpl.hp.com>
7295 Timothy Wall <twall@cygnus.com>
7296 Jim Wilson <wilson@cygnus.com>
7298 * Makefile.am (ALL_MACHINES): Add cpu-ia64.lo.
7299 (ALL_MACHINES_CFILES): Add cpu-ia64.c.
7300 (BFD64_BACKENDS): Add elf64-ia64.lo.
7301 (BFD64_BACKENDS_CFILES): Add elf64-ia64.c.
7302 (cpu-ia64.lo, elf64-ia64.lo): New rules.
7303 * Makefile.in: Rebuild.
7304 * archures.c (enum bfd_architecture): Add bfd_arch_ia64.
7305 (bfd_ia64_arch): Declare.
7306 (bfd_archures_list): Add bfd_ia64_arch.
7307 * bfd-in2.h: Rebuild.
7308 * config.bfd: (ia64*-*-linux-gnu*, ia64*-*-elf*): New targets.
7309 * configure: Rebuild.
7310 * configure.host: (ia64-*-linux*): New host.
7311 * configure.in (bfd_elf64_ia64_little_vec, bfd_elf64_ia64_big_vec,
7312 bfd_efi_app_ia64_vec, bfd_efi_app_ia64_vec): New vectors.
7313 * elf.c (prep_headers): Add bfd_arch_ia64.
7314 * libbfd.h: Rebuild.
7315 * reloc.c: Add IA-64 relocations.
7316 * targets.c (bfd_elf64_ia64_little_vec, bfd_elf64_ia64_big_vec):
7318 (bfd_target_vect): Add bfd_elf64_ia64_little_vec.
7319 * cpu-ia64-opc.c, cpu-ia64.c, elf64-ia64.c: New files.
7321 2000-04-21 Richard Henderson <rth@cygnus.com>
7323 * elf32-d30v.c (bfd_elf_d30v_reloc): Don't modify section
7324 contents when performing a partial link.
7325 (bfd_elf_d30v_reloc_21): Likewise.
7327 2000-04-20 H.J. Lu <hjl@gnu.org>
7329 * elf32-i386.c (elf_i386_relocate_section): Restrict 1998-12-10
7330 patch to symbols defined by a shared object.
7331 * elf32-ppc.c (ppc_elf_relocate_section): Similarly.
7333 2000-04-19 Michael Sokolov <msokolov@ivan.Harhan.ORG>
7336 * dwarf2.c (concat_filename): Avoid string literal concatenation.
7337 * ieee.c (ieee_get_symtab): Don't initialise union in struct.
7339 Mon Apr 17 19:14:36 2000 David Mosberger <davidm@hpl.hp.com>
7341 * Makefile.am (BFD64_BACKENDS): Mention coff-ia64.lo.
7342 (BFD64_BACKENDS_CFILES): Mention coff-ia64.c
7343 (coff-ia64.lo): Add dependency.
7344 * Makefile.in: Regenerate.
7345 * coff-ia64.c: New file.
7346 * efi-app-ia32.c: Ditto.
7347 * efi-app-ia64.c: Ditto.
7348 * coffcode.h (coff_set_arch_mach_hook): Handle IA64MAGIC.
7349 (coff_set_flags): Ditto.
7350 (coff_write_object_contents) [IA64]: Set magic number to ZMAGIC.
7351 * config.bfd (i[3456]86-*-linux-gnu*): Mention bfd_efi_app_ia32_vec.
7352 * configure.in (elf): Handle bfd_efi_app_ia32 and bfd_efi_app_ia64_vec.
7353 * configure: Regenerate.
7354 * libpei.h (GET_OPTHDR_IMAGE_BASE): New macro.
7355 (PUT_OPTHDR_IMAGE_BASE): Ditto.
7356 (GET_OPTHDR_SIZE_OF_STACK_RESERVE): Ditto.
7357 (PUT_OPTHDR_SIZE_OF_STACK_RESERVE): Ditto.
7358 (GET_OPTHDR_SIZE_OF_STACK_COMMIT): Ditto.
7359 (PUT_OPTHDR_SIZE_OF_STACK_COMMIT): Ditto.
7360 (GET_OPTHDR_SIZE_OF_HEAP_RESERVE): Ditto.
7361 (PUT_OPTHDR_SIZE_OF_HEAP_RESERVE): Ditto.
7362 (GET_OPTHDR_SIZE_OF_HEAP_COMMIT): Ditto.
7363 (PUT_OPTHDR_SIZE_OF_HEAP_COMMIT): Ditto.
7364 (GET_PDATA_ENTRY): Ditto.
7365 * peigen.c (_bfd_pei_swap_aouthdr_in) [COFF_WITH_PEP64]: Don't read
7366 data_start. Use above macros to read fields that are 64 bit wide for
7367 COFF_WITH_PEP64. Don't truncate entry and text_start to 32 bits.
7368 (_bfd_pei_swap_aouthdr_out) [PEI_FORCE_MINIMUM_ALIGNMENT]: Force
7369 FileAlignment and SectionAlignment to minimum alignment if they
7371 (_bfd_pei_swap_aouthdr_out) [PEI_DEFAULT_TARGET_SUBSYSTEM]: Set
7372 Subsystem to default PEI_DEFAULT_TARGET_SUBSYSTEM.
7373 (_bfd_pei_swap_aouthdr_out) [COFF_WITH_PEP64]: Don't set data_start.
7374 Use above macros to write fields that are 64 bit wide for
7376 (pe_print_pdata): Set PDATA_ROW_SIZE to 3*8 for COFF_WITH_PEP64,
7377 5*4 otherwise. This should be right for IA-32 and IA-64, but may
7378 be wrong for platforms. Use PDATA_ROW_SIZE instead of hardcoded
7379 value of 20 bytes. Modify printing for COFF_WITH_PEP64 to print
7380 begin address, end address, and unwind info address only. Use
7381 GET_PDATA_ENTRY() to read .pdata entries. Use fprintf_vma() to
7383 (tbl): Add SECTION, REL32, RESERVED1, MIPS_JMPADDR16, DIR64, and
7384 HIGH3ADJ relocation names.
7385 (_bfd_pe_print_private_bfd_data): Print Subsystem name in legible form.
7386 * targets.c: Declare bfd_efi_app_ia32_vec and
7387 bfd_efi_app_ia64_vec.
7388 (bfd_target_vector): Mention bfd_efi_app_ia32_vec and
7389 bfd_efi_app_ia64_vec.
7391 2000-04-17 Timothy Wall <twall@cygnus.com>
7393 * bfd-in2.h: Add prototypes for tic54x load page access.
7394 * bfd-in.h: Regenerate.
7395 * coff-tic54x.c: Add load page functions; allow bfd_arch_unknown
7396 in customized _set_arch_mach function.
7397 * coffcode.h (coff_set_alignment_hook): Set section load page if
7398 the appropriate macro is defined.
7399 (write_object_contents): Read section load page.
7401 2000-04-13 Alan Modra <alan@linuxcare.com.au>
7403 * elf32-hppa.h: Update copyright date.
7405 * elf32-fr30.c (fr30_elf_i20_reloc): Don't use U suffix.
7406 * elf32-mips.c (_bfd_mips_elf_relocate_section): And here.
7408 * elf32-d30v.c (MAX32): Don't use LL suffix.
7409 (MIN32): Define in terms of MAX32.
7410 (bfd_elf_d30v_reloc): Make relocation a bfd_signed_vma.
7412 * coff-a29k.c (SIGN_EXTEND_HWORD): Replace with more concise
7415 * peicode.h (pe_ILF_build_a_bfd): Remove UL from hex constants.
7417 2000-04-12 Alan Modra <alan@linuxcare.com.au>
7419 * dep-in.sed: Match space before file name, not after.
7420 * Makefile.am: Regenerate dependencies.
7421 * Makefile.in: Regenerate.
7423 * reloc.c (_bfd_relocate_contents): In complain_overflow_bitfield
7424 case, allow address wrap-around stupidly removed 2000-03-17. Sign
7425 extend without an if statement.
7427 2000-04-11 Alan Modra <alan@linuxcare.com.au>
7429 * coff-mips.c (mips_gprel_reloc): Test for 16 bit range using
7431 * elf32-mips.c (gprel16_with_gp): Likewise.
7432 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Test range
7433 here using -0x40000, not (int)0xfffc0000.
7434 (elf32_hppa_size_of_stub): Likewise.
7436 2000-04-11 Timothy Wall <twall@cygnus.com>
7438 * coff-tic54x.c: Now builds with all targets.
7439 * Makefile.am: Add coff/tic54x.h to coff-tic54x.o dependencies.
7440 * Makefile.in: Regenerate.
7441 * coffcode.h (coff_set_arch_mach_hook): Eliminate warning on
7442 unitialized variable.
7444 Fri Apr 7 15:56:57 2000 Andrew Cagney <cagney@b1.cygnus.com>
7446 * configure.in (WARN_CFLAGS): Set to -W -Wall by default. Add
7447 --enable-build-warnings option.
7448 * Makefile.am (AM_CFLAGS, WARN_CFLAGS): Add definitions.
7449 * Makefile.in, configure: Re-generate.
7451 2000-04-07 Nick Clifton <nickc@cygnus.com>
7453 * reloc.c: Add BFD_RELOC_ARM_PCREL_BLX and
7454 BFD_RELOC_THUMB_PCREL_BLX.
7456 * elf32-arm.h (elf32_arm_final_link_relocate): Handle
7457 R_ARM_XPC25 and R_ARM_THM_PC22.
7459 * elfarm-nabi.c (elf32_arm_howto_): Fix definitions of
7460 R_ARM_XPC25 and R_ARM_THM_XPC22.
7461 (elf32_arm_reloc_map): Make BFD_RELOC_{ARM|THUMB}_PCREL_BLX to
7462 R_ARM_[XPC25|THM_XPC22].
7464 * elfarm-oabi.c: Define OLD_ARM_ABI and change include from
7465 elf/arm-oabi.h to elf/arm.h
7467 * Makefile.am: Fix dependency for elfarm-oabi.c
7468 * Makefile.in: Regenerate.
7470 * bfd-in2.h: Regenerate.
7471 * libbfd.h: Regenerate.
7473 2000-04-06 Michael Snyder <msnyder@seadog.cygnus.com>
7475 * elfcore.h (elf_core_file_p): preserve value of tdata at entry,
7476 and restore it on failure. Release newly allocated tdata on
7479 Fri Apr 7 11:33:47 2000 Jim Wilson <wilson@cygnus.com>
7481 * dwarf2.c (struct dwarf2_debug): New field dwarf_line_size.
7482 (decode_line_info): Set it. Report error if unit->line_offset is
7483 equal to or larger than it.
7485 2000-04-07 Timothy Wall <twall@cygnus.com>
7487 * targets.c: Added vecs for tic54x.
7488 * reloc.c: Added relocs for tic54x.
7489 * libbfd.h: Regenerated.
7490 * configure: Add TI COFF vecs for tic54x.
7491 * configure.in: Ditto.
7492 * config.bfd (targ_cpu): Recognize new tic54x target.
7493 * coffcode.h (coff_slurp_symbol_table): Additions for TI COFF handling.
7494 * bfd-in2.h: Add tic54x target and relocations.
7495 * Makefile.am, Makefile.in: Add tic54x target.
7496 * archures.c (bfd_archures_list): Add tic54x target.
7497 * coff-tic54x.c: New.
7498 * cpu-tic54x.c: New.
7500 2000-04-06 Michael Snyder <msnyder@seadog.cygnus.com>
7502 * elfcore.h (elf_core_file_p): call backend_object_p which
7503 thereby gets an opportunity to update the arch/machine type.
7505 2000-04-06 Timothy Wall <twall@cygnus.com>
7507 * coffcode.h (coff_slurp_symbol_table): Handle C_STATLAB storage
7508 class. Handle SEC_CLINK and SEC_BLOCK flags.
7509 * section.c: Add SEC_CLINK and SEC_BLOCK flags.
7510 * bfd-in2.h: Add SEC_CLINK and SEC_BLOCK flags.
7512 2000-04-06 Nick Clifton <nickc@cygnus.com>
7514 * elf32-arm.h (elf32_arm_set_private_flags): Only check for
7515 EF_INTERWORK if this is an unknown EABI.
7516 (elf32_arm_merge_private_bfd_data): Check EABI version
7517 numbers. Only check EF_xxx flags if the EABI version number
7519 (elf32_arm_check_private_bfd_data): Only check EF_xxx flags
7520 if the EABI version number is unknown.
7521 (elf32_arm_print_private_bfd_data): Only decode EF_xxx flags
7522 if the EABI version number is unknown.
7524 Wed Apr 5 22:04:20 2000 J"orn Rennecke <amylaar@cygnus.co.uk>
7526 * reloc.c (_bfd_relocate_contents): Add BFD_RELOC_SH_LOOP_START and
7527 BFD_RELOC_SH_LOOP_END.
7528 * elf32-sh.c (sh_elf_howto_tab): Change special_func to
7529 sh_elf_ignore_reloc for all entries that sh_elf_reloc used to ignore.
7530 Add entries for R_SH_LOOP_START and R_SH_LOOP_END.
7531 (sh_elf_reloc_loop): New function.
7532 (sh_elf_reloc): No need to test for always-to-be-ignored relocs
7534 (sh_rel): Add entries for BFD_RELOC_SH_LOOP_{START,END}.
7535 (sh_elf_relocate_section): Handle BFD_RELOC_SH_LOOP_{START,END}.
7536 * bfd-in2.h, libbfd.h: Regenerate.
7538 2000-04-04 Alan Modra <alan@linuxcare.com.au>
7540 * po/bfd.pot: Regenerate.
7542 * Makefile.am: Remove extraneous mkdep comment.
7543 (MKDEP): Use gcc -MM rather than mkdep.
7544 (DEP): Quote when passing vars to sub-make. Add warning
7546 (DEP1): Rewrite for "gcc -MM".
7547 (CLEANFILES): Add DEP2.
7548 Update dependencies.
7549 * Makefile.in: Regenerate.
7551 2000-04-03 Kevin Buettner <kevinb@redhat.com>
7553 * configure.in: Added corefile support for AIX 4.3. In particular,
7554 AIX_CORE_DUMPX_CORE will be defined in addition to AIX_CORE when
7555 compiling rs6000-core.c.
7556 * configure: Regenerated.
7558 2000-04-03 H.J. Lu <hjl@gnu.org>
7560 * cache.c (bfd_open_file): Unlink the output file only if
7561 it has non-zero size.
7563 2000-04-01 Ken Block USG <block@zk3.dec.com>
7565 * elf64-alpha.c (elf64_alpha_relocate_section): Don't emit
7566 relative relocations for non-loaded sections in shared objects.
7567 (elf64_alpha_check_relocs): Similarly.
7569 Mon Apr 3 13:37:15 2000 Hans-Peter Nilsson <hp@axis.com>
7571 * aoutx.h (NAME(aout,reloc_type_lookup)): Add BFD_RELOC_8 and
7572 BFD_RELOC_16 to switch for extended relocs.
7573 (MY_swap_ext_reloc_in): New.
7574 (MY_swap_ext_reloc_out): New.
7575 (NAME(aout,slurp_reloc_table)): Use MY_swap_ext_reloc_in rather
7576 than NAME(aout,swap_ext_reloc_in) for extended relocs.
7577 (NAME(aout,squirt_out_relocs)): Similarly use
7578 MY_swap_ext_reloc_out.
7579 (aout_link_reloc_link_order): Use MY_put_ext_reloc if defined.
7581 2000-04-03 Kazu Hirata <kazu@hxi.com>
7583 * coff-h8300.c (h8300_reloc16_extra_cases): Add bsr:16 -> bsr:8 to
7584 the R_PCRWORD_B case.
7586 2000-03-31 Thomas de Lellis <tdel@wrs.com>
7588 * srec.c : Set CHUNK size to 16 bytes to prevent download failures
7592 Wed Mar 30 15:28:00 2000 Donald Lindsay <dlindsay@cygnus.com>
7594 * elf32-m32r.c (m32r_elf_generic_reloc): new function. All
7595 HOWTO references to bfd_elf_generic_reloc, that have
7596 partial_inplace == true, now use the new function. The function
7597 is based on the recent rewrite of m32r_elf_lo16_reloc(), and
7598 extends its fixes to the R_M32R_{16,24,32} relocs.
7599 The new logic in m32r_elf_lo16_reloc() has been removed, and
7600 it instead calls the new routine to obtain that functionality.
7602 2000-03-27 Alan Modra <alan@linuxcare.com.au>
7604 * elf32-avr.c (elf32_avr_gc_mark_hook, elf32_avr_gc_sweep_hook,
7605 elf32_avr_check_relocs, avr_final_link_relocate,
7606 elf32_avr_relocate_section, bfd_elf_avr_final_write_processing,
7607 elf32_avr_object_p): Add prototypes.
7608 (elf32_avr_gc_mark_hook): Add default for h->root.type.
7609 (bfd_elf_avr_final_write_processing): Make static.
7611 2000-03-27 Denis Chertykov <denisc@overta.ru>
7613 * cpu-avr.c: New file. BFD support routines for AVR architecture.
7614 * archures.c (bfd_architecture): Add AVR architecture.
7615 (bfd_archures_list): Add reference to AVR architecture info.
7616 * elf.c (prep_headers): Handle bfd_arch_avr.
7617 * reloc.c: Add various AVR relocation enums.
7618 * targets.c (bfd_elf32_avr_vec): Declare and add to target vector
7620 * Makefile.am: Add support for AVR elf.
7621 * configure.in: Likewise.
7622 * config.bfd: Likewise.
7623 * Makefile.in: Regenerate.
7624 * configure: This too.
7625 * bfd-in2.h: And this.
7626 * libbfd.h: And this.
7628 2000-03-24 H.J. Lu <hjl@gnu.org>
7630 * elf64-alpha.c (elf64_alpha_merge_ind_symbols): Add prototype.
7631 (elf64_alpha_find_reloc_at_ofs): Likewise.
7633 2000-03-17 Alan Modra <alan@linuxcare.com.au>
7635 * reloc.c (bfd_check_overflow): In case complain_overflow_bitfield,
7636 flag an overflow if the bitfield is outside -2**n to 2**n-1. The
7637 allowable range used to be -2**(n-1) to 2**n-1.
7638 * reloc.c (_bfd_relocate_contents): Same here. Also replace
7639 "boolean overflow" with "bfd_reloc_status_type flag".
7641 2000-03-14 Doug Evans <dje@casey.transmeta.com>
7643 * elf32-m32r.c (m32r_elf_lo16_reloc): Rewrite.
7645 2000-03-14 Kazu Hirata <kazu@hxi.com>
7647 * reloc16.c (bfd_coff_reloc16_relax_section): Count the total number
7648 of shrinks properly, including the last reloc.
7650 2000-03-13 Kazu Hirata <kazu@hxi.com>
7652 * coff-h8300.c (h8300_reloc16_extra_cases): Fix the sanity
7655 2000-03-11 Alan Modra <alan@linuxcare.com.au>
7657 * ieee.c (ieee_archive_p): Return bfd_error_wrong_format on
7658 a format mismatch rather than an "error" from bfd_read such as
7659 bfd_error_file_truncated.
7661 2000-03-10 Geoff Keating <geoffk@cygnus.com>
7663 * elf32-mips.c (_bfd_mips_elf_relocate_section): Do proper
7664 sign-extension and big-endian compensation for
7665 R_MIPS_64 even in ld -r.
7667 2000-03-10 Geoffrey Keating <geoffk@cygnus.com>
7669 * elf32-mips.c (mips_elf_next_relocation): Rename from
7670 mips_elf_next_lo16_relocation, and generalize to look
7671 for any relocation type.
7672 (elf_mips_howto_table): Make R_MIPS_PC16 pcrel_offset.
7673 (elf_mips_gnu_rel_hi16): Howto for R_MIPS_GNU_REL_HI16.
7674 (elf_mips_gnu_rel_lo16): Howto for R_MIPS_GNU_REL_LO16.
7675 (elf_mips_gnu_rel16_s2): Howto for R_MIPS_GNU_REL16_S2.
7676 (elf_mips_gnu_pcrel64): Howto for R_MIPS_PC64.
7677 (elf_mips_gnu_pcrel32): Howto for R_MIPS_PC32.
7678 (bfd_elf32_bfd_reloc_type_lookup): Add new relocs.
7679 (mips_rtype_to_howto): Likewise.
7680 (mips_elf_calculate_relocation): Handle new relocs.
7681 (_bfd_mips_elf_relocate_section): REL_HI16/REL_LO16 relocs
7682 are paired. The addend for R_MIPS_GNU_REL16_S2
7683 is shifted right two bits.
7685 2000-03-10 Alan Modra <alan@linuxcare.com.au>
7687 * reloc.c (bfd_perform_relocation): Undo emacs formatting of
7688 comment, and ensure it doesn't happen again.
7689 (bfd_install_relocation): Same here.
7690 (_bfd_relocate_contents): Don't bother assigning unused signmask
7691 shift result. Fix typos in comments.
7692 Remove trailing whitespace throughout file.
7694 2000-03-07 Doug Evans <dje@casey.transmeta.com>
7696 * reloc.c (reloc_howto_struct): Fix partial_inplace comment.
7697 * bfd-in2.h: Rebuild.
7699 2000-03-06 Nick Clifton <nickc@cygnus.com>
7701 * peicode.h (struct pe_ILF_vars): Add sym_ptr_table and
7703 (SIZEOF_ILF_SYM_PTR_TABLE): Define.
7704 (SIZEOF_ILF_STRINGS): Redefine.
7705 (pe_ILF_make_a_symbol-reloc): New function. Creates a symbol
7706 relative reloc, as opposed to a section relative reloc.
7707 (pe_ILF_make_a_symbol): Set the class of local symbols to C_STAT
7709 Add length of symbol's prefix to string pointer.
7710 Store a pointer to the symbol in the symbol pointer table.
7711 (pe_ILF_build_a_bfd): Do not build .idata$2 or .idata$7.
7712 Initialise the symbol pointer table.
7713 Store the hint in the Hint/Name table.
7714 Make the jump reloc be symbol realtive, not section relative.
7715 Create an import symbol for imported code.
7717 2000-03-06 Catherine Moore <clm@cygnus.com>
7719 * elf.c (swap_out_syms): Check for null type_ptr.
7721 2000-03-01 Hans-Peter Nilsson <hp@axis.com>
7723 * aout-target.h (MY(write_object_contents)): Remove unused
7724 and unusable "#if CHOOSE_RELOC_SIZE".
7725 * pc532-mach.c (MY(write_object_contents)): Ditto.
7726 * netbsd.h (MY(write_object_contents)): Ditto.
7727 * hp300hpux.c (MY(write_object_contents)): Ditto.
7728 * freebsd.h (MY(write_object_contents)): Ditto.
7729 * aout-tic30.c (tic30_aout_write_object_contents): Ditto.
7731 2000-02-29 H.J. Lu <hjl@gnu.org>
7733 * peicode.h (jtab): Make it static.
7735 * coff-sh.c (sh_align_load_span): Declared if COFF_WITH_PE is
7736 defined and COFF_IMAGE_WITH_PE is not defined.
7737 (_bfd_sh_align_load_span): Defined as sh_align_load_span if
7738 COFF_WITH_PE is defined and COFF_IMAGE_WITH_PE is not defined.
7740 2000-03-01 Nick Clifton <nickc@cygnus.com>
7742 * coff-arm.c (bfd_arm_process_before_allocation): Make
7743 'symndx' signed to prevent compile time warning.
7745 * coff-mcore.c: Remove unused prototype for pe_object_p.
7747 * coff-sh.c: Add "#ifndef COFF_IMAGE_WITH_PE" around static
7748 functions that are not used when COFF_IMAGE_WITH_PE is
7750 (struct sh_opcode): Change type of 'flags' field to unsigned
7751 long so that it can hold the USESAS flag.
7753 * coffcode.h (styp_to_sec_flags): Initialise 'target_name'.
7755 * elf-m10300.c (mn10300_elf_relax_section): Initialise
7758 * elf32-i370.c: Add ATTRIBUTE_UNUSED to unused function
7760 Remove unusued variables and code.
7761 (elf_backend_add_symbol_hook): Fix prototype.
7763 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Initialise 'sgot' and
7766 * elf32-mcore.c (mcore_elf_relocate_section): Initialise
7769 * elf32-mips.c: Add ATTRIBUTE_UNUSED to unused function
7771 Remove unusued variables and code.
7772 (elf_backend_add_symbol_hook): Fix prototype.
7774 * elf32-sh.c (sh_elf_set_mach_from_flags): Use 'flags'.
7776 * elflink.h (elf_bfd_link_add_symbols): Add ATTRIBUTE_UNUSED
7777 to unused function parameter.
7779 * pe-mips.c: Add ATTRIBUTE_UNUSED to unused function
7781 Use EMPTY_HOWTO to initialise empty howto slots.
7782 Remove unused variables.
7784 * peicode.h (pe_ILF_build_a_bfd): Initialise id6.
7786 2000-03-01 H.J. Lu <hjl@gnu.org>
7788 * aoutx.h (aout_link_input_section_std): Pass "true" to
7789 the undefined_symbol callback.
7790 (aout_link_input_section_ext): Likewise.
7791 * bout.c (get_value): Likewise.
7792 * coff-a29k.c (coff_a29k_relocate_section): Likewise.
7793 * coff-alpha.c (alpha_ecoff_get_relocated_section_conten):
7795 (alpha_relocate_section): Likewise.
7796 * coff-arm.c (coff_arm_relocate_section): Likewise.
7797 * coff-i960.c (coff_i960_relocate_section): Likewise.
7798 * coff-mcore.c (coff_mcore_relocate_section): Likewise.
7799 * coff-mips.c (mips_relocate_section): Likewise.
7800 * coff-ppc.c (coff_ppc_relocate_section): Likewise.
7801 * coff-sh.c (sh_relocate_section): Likewise.
7802 * coff-tic80.c (coff_tic80_relocate_section): Likewise.
7803 * cofflink.c (_bfd_coff_generic_relocate_section): Likewise.
7804 * elf-m10200.c (mn10200_elf_relocate_section): Likewise.
7805 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
7806 * elf32-d10v.c (elf32_d10v_relocate_section): Likewise.
7807 * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
7808 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
7809 * elf32-i370.c (i370_elf_relocate_section): Likewise.
7810 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
7811 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
7812 * elf32-sh.c (sh_elf_relocate_section): Likewise.
7813 * elf32-v850.c (v850_elf_relocate_section): Likewise.
7814 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Likewise.
7815 * elflink.h (elf_link_output_extsym): Likewise.
7816 * pe-mips.c (coff_pe_mips_relocate_section): Likewise.
7817 * reloc.c (bfd_generic_get_relocated_section_conten): Likewise.
7818 * reloc16.c (_bfd_ppc_xcoff_relocate_section): Likewise.
7820 * elf-hppa.h (elf_hppa_relocate_section): Pass "false" to the
7821 undefined_symbol callback when building shared library with
7822 -Bsymbolic and undefined symbols are allowed. Otherwise, pass
7824 * elf32-arm.h (elf32_arm_relocate_section): Likewise.
7825 * elf32-i386.c (elf_i386_relocate_section): Likewise.
7826 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
7827 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
7828 (elf32_mips_get_relocated_section_content): Likewise.
7829 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
7830 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
7831 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
7832 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
7834 2000-02-28 Nick Clifton <nickc@cygnus.com>
7836 * Makefile.am: Add rules to build pe[i]-{sh|mips}.lo objects.
7837 * Makefile.in: Regenerate.
7839 * configure.in: Add support for mips and sh pe vectors.
7840 * configure: regenerate.
7842 * config.bfd: Add support for arm-wince, mips-pe and sh-pe
7845 * targets.c: Add mips and sh pe vectors.
7847 * libpei.h (coff_final_link_postscript): Only define if not
7850 * coffcode.h: Add support for WinCE magic numbers.
7852 * peigen.c (pe_print_reloc): Update comment and rearrange
7853 appending of newline character.
7855 * peicode.h: Add support for Image Library Format.
7856 (pe_ILF_vars): Structure containing data used by ILF code.
7857 (pe_ILF_make_a_section): New function. Create a section based
7859 (pe_ILF_make_a_reloc): New function. Create a reloc based on
7861 (pe_ILF_make_a_symbol): New function. Create a symbol based
7863 (pe_ILF_save_relocs): New function. Store the relocs created
7864 by pe_ILF_make_a_reloc in a section.
7865 (pe_ILF_build_a_bfd): New function. Create a BFD describing
7867 (pe_ILF_object_p): New function. Return a bfd_target pointer
7869 (pe_bfd_object_p): If an ILF object is detected call
7870 pe_ILF_object_p on it.
7872 * coff-arm.c: Add support for WinCE relocs which are different
7873 from normal ARM COFF relocs.
7874 * pe-arm.c: Unset TARGET_UNDERSCORE for a WinCE target.
7876 * coff-sh.c: Add support for sh-pe target.
7877 * pe-sh.c: New file. Support code for sh-pe target.
7878 * pei-sh.c: New file. Support code for sh-pe target.
7880 * pe-mips.c: New file. Support code for mips-pe target.
7881 * pei-mips.c: New file. Support code for mips-pe target.
7883 2000-02-27 Jakub Jelinek <jakub@redhat.com>
7885 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data): Don't bump
7886 architecture if the object causing the bump is dynamic.
7887 * elf64-sparc.c (sparc64_elf_merge_private_bfd_data): Likewise,
7888 and also don't it for memory ordering.
7889 (sparc64_elf_write_relocs): Take src_rela out of the loop.
7891 2000-02-27 Ian Lance Taylor <ian@zembu.com>
7893 * dwarf2.c (read_abbrevs): Use _raw_size directly rather than
7894 calling bfd_get_section_size_before_reloc.
7895 (decode_line_info): Likewise.
7896 (_bfd_dwarf2_find_nearest_line): Likewise.
7898 2000-02-27 Eli Zaretskii <eliz@is.elta.co.il>
7900 * Makefile.am (stamp-lib): Use $(LIBTOOL) --config to get the
7901 name of the libtool directory.
7902 * Makefile.in: Rebuild.
7904 Fri Feb 25 18:39:26 2000 Rodney Brown (RodneyBrown@pmsc.com)
7906 * som.c (SOM_HOWTO): Define.
7907 (som_hppa_howto_table): Use it.
7909 2000-02-25 Alexandre Oliva <oliva@lsd.ic.unicamp.br>
7911 * config.bfd: Enable 64 bit support for GNU/Linux/sparc.
7913 * config.bfd: Enable 64 bit support for Solaris7+/sparc.
7915 2000-02-24 Catherine Moore <clm@cygnus.com>
7917 * som.c (som_misc_symbol_info): Add field
7919 (som_bfd_derive_misc_symbol_info): Initialize
7921 (som_build_and_write_symbol_table): Keep track
7922 of secondary_def field.
7923 (som_slurp_symbol_table): Set BSF_WEAK symbol flag
7924 if secondary_def field is set.
7925 (som_bfd_ar_write_symbol_stuff): Initialize
7928 2000-02-23 Stephane Carrez <stcarrez@worldnet.fr>
7930 * dwarf2.c (read_address): Read 16-bits addresses.
7931 (parse_comp_unit): Accept addr_size == 2.
7933 2000-02-23 Alan Modra <alan@spri.levels.unisa.edu.au>
7935 * bfd-in.h: Update copyright date.
7937 2000-02-23 Linas Vepstas <linas@linas.org>
7939 * cpu-i370.c: New file.
7940 * elf32-i370.c: New file.
7941 * archures.c (enum bfd_architecture): Add bfd_arch_i370.
7942 (bfd_i370_arch): New.
7943 (bfd_archures_list): Add bfd_i370_arch.
7944 * elf.c (prep_headers): Add bfd_arch_i370.
7945 * Makefile.am: Add support for IBM 370 elf.
7946 * config.bfd: Likewise.
7947 * configure.in: Likewise.
7948 * libbfd.h (bfd_reloc_code_real_names): Likewise.
7949 * reloc.c (bfd_reloc_code_type): Likewise.
7950 * targets.c: Likewise.
7952 * Makefile.in: Regenerate.
7953 * configure: Regenerate.
7954 * bfd-in2.h: Regenerate.
7956 2000-02-22 Ian Lance Taylor <ian@zembu.com>
7958 * elf32-i386.c (elf_i386_info_to_howto_rel): Give a warning for
7959 invalid relocation types, and change them to R_386_NONE.
7961 2000-02-22 H.J. Lu <hjl@gnu.org>
7963 * elflink.h (elf_link_add_object_symbols): If a version symbol is
7964 not defined, don't add a second ELF_VER_CHR.
7966 * elflink.h (elf_bfd_final_link): Call output_extsym for global
7967 symbols converted to local symbols even when stripping all
7969 (elf_link_output_extsym): Process global symbols converted to
7970 local symbols even if they are being stripped.
7972 2000-02-21 Alan Modra <alan@spri.levels.unisa.edu.au>
7974 * archures.c (bfd_octets_per_byte): Return unsigned int.
7975 (bfd_arch_mach_octets_per_byte): Ditto.
7976 * libbfd.c (bfd_read, bfd_seek): Quell signed vs. unsigned
7978 * section.c (bfd_get_section_size_before_reloc): Quell signed
7979 vs. unsigned comparison warning.
7980 (bfd_get_section_size_after_reloc): Same here. Fix parentheses too.
7981 * trad-core.c (trad_unix_core_file_p): Correct 2000-01-27
7982 change. What was I thinking?
7983 * bfd-in2.h: Regenerate.
7985 * elflink.h (elf_gc_sweep): Skip non-elf input bfds.
7986 (elf_gc_sections): Same here.
7987 (elf_gc_common_finalize_got_offsets): And here.
7989 2000-02-21 Ian Lance Taylor <ian@zembu.com>
7991 ELF HPPA doesn't work at present; remove it until it does.
7992 * config.bfd: Comment out setting targ_defvec to
7994 * Makefile.am: Rebuild dependencies.
7995 (BFD32_BACKENDS): Remove elf32-hppa.lo.
7996 (BFD32_BACKENDS_CFILES): Remove elf32-hppa.c.
7997 (SOURCE_HFILES): Remove elf32-hppa.h and hppa_stubs.h.
7998 * Makefile.in: Rebuild.
7999 * targets.c (bfd_target_vector): Comment out bfd_elf32_hppa_vec.
8001 2000-02-18 Geoff Keating <geoffk@cygnus.com>
8003 * coffcode.h (coff_set_arch_mach_hook): Use free(), because there
8004 is no bfd_free(). Revert bfd_free part of previous change.
8006 2000-02-18 Geoff Keating <geoffk@cygnus.com>
8008 * coffcode.h (coff_set_arch_mach_hook): Don't use variable-size
8010 (coff_compute_section_file_positions): Use bfd_free to pair
8012 (coff_write_object_contents): Likewise.
8014 * coff-rs6000.c (xcoff_howto_table_16): New variable.
8015 (xcoff_rtype2howto): Handle 16-bit variants of 32-bit relocs.
8017 2000-02-18 Ulrich Drepper <drepper@cygnus.com>
8019 * coff-rs6000.c (XCOFFARMAGBIG): New macro.
8020 (xcoff_ar_file_hdr_big): New structure.
8021 (SIZEOF_AR_FILE_HDR_BIG): New macro.
8022 (xcoff_ar_hdr_big): New structure.
8023 (SIZEOF_AR_HDR_BIG): New macro.
8024 (xcoff_big_format_p): New macro.
8025 (xcoff_ardata_big): New macro.
8026 (arch_xhdr_big): New macro.
8027 (xcoff_slurp_armap): Handle large archives.
8028 (xcoff_archive_p): Detect large archives.
8029 (xcoff_read_ar_hdr): Handle large archives.
8030 (xcoff_openr_next_archived_file): Handle large archives.
8031 (xcoff_generic_stat_arch_elt): Handle large archives.
8032 (xcoff_write_armap_old): Rename from xcoff_write_armap.
8033 (xcoff_write_armap_big): New function.
8034 (xcoff_write_armap): New function, dispatch to _old or _big.
8035 (xcoff_write_archive_contents_old): Rename from
8036 xcoff_write_archive_contents.
8037 (xcoff_write_archive_contents_big): New function.
8038 (xcoff_write_archive_contents): New function, dispatch to _old or
8041 2000-02-18 Richard Henderson <rth@cygnus.com>
8043 * elf-bfd.h (struct elf_link_hash_table): Remove copy_indirect
8044 and hide_symbol members.
8045 (elf_link_hash_copy_indirect): Remove.
8046 (elf_link_hash_hide_symbol): Remove.
8047 (struct elf_backend_data): Add elf_backend_copy_indirect_symbol
8048 and elf_backend_hide_symbol.
8049 (_bfd_elf_link_hash_copy_indirect): Declare.
8050 (_bfd_elf_link_hash_hide_symbol): Declare.
8051 * elf.c (_bfd_elf_link_hash_copy_indirect): Remove table argument.
8052 (_bfd_elf_link_hash_hide_symbol): Likewise.
8053 (_bfd_elf_link_hash_table_init): Don't init killed members.
8054 * elflink.h (elf_link_add_object_symbols): Use the bed function
8055 pointers not elf_link_hash_{copy_indirect,hide_symbol}.
8056 (elf_link_assign_sym_version): Likewise.
8057 * elfxx-target.h (elf_backend_copy_indirect_symbol): Default.
8058 (elf_backend_hide_symbol): Likewise.
8059 (elfNN_bed): Update for new members.
8061 2000-02-17 Kevin Buettner <kevinb@redhat.com>
8063 * rs6000-core.c (CORE_DATA_SIZE_FIELD, CORE_COMM_FIELD, SAVE_FIELD,
8064 STACK_END_ADDR): Define for new core file format.
8065 (LOADER_OFFSET_FIELD, LOADER_REGION_SIZE, CORE_DUMP): New defines
8066 for handling the vagaries of the various core file structures used
8067 by AIX over the years.
8068 (rs6000coff_core_p, rs6000coff_core_file_matches_executable,
8069 Rs6kCorData): Use above defines to adapt code to use AIX 4.3's
8070 core_dumpx structure.
8072 Thu Feb 17 00:04:48 2000 J"orn Rennecke <amylaar@cygnus.co.uk>
8074 * archures.c (bfd_mach_sh2, bfd_mach_sh_dsp): New macros.
8075 (bfd_mach_sh3_dsp): Likewise.
8076 (bfd_mach_sh4): Reinstate.
8077 (bfd_default_scan): Recognize 7410, 7708, 7729 and 7750.
8078 * bfd-in2.h: Regenerate.
8079 * coff-sh.c (struct sh_opcode): flags is no longer short.
8080 (USESAS, USESAS_REG, USESR8, SETSAS, SETSAS_REG): New macros.
8081 (sh_opcode41, sh_opcode42): Integrate as sh_opcode41.
8082 (sh_opcode01, sh_opcode02, sh_opcode40): Add sh-dsp opcodes.
8083 (sh_opcode41, sh_opcode4, sh_opcode80): Likewise.
8084 (sh_opcodes): No longer const.
8085 (sh_dsp_opcodef0, sh_dsp_opcodef): New arrays.
8086 (sh_insn_uses_reg): Check for USESAS and USESR8.
8087 (sh_insn_sets_reg, sh_insns_conflict): Check for SETSAS.
8088 (_bfd_sh_align_load_span): Return early for SH4.
8089 Modify sh_opcodes lookup table for sh-dsp / sh3-dsp.
8090 Take into account that field b of a parallel processing insn
8091 could be mistaken for a separate insn.
8092 * cpu-sh.c (arch_info_struct): New array elements for
8093 sh2, sh-dsp and sh3-dsp.
8094 Reinstate element for sh4.
8095 (SH2_NEXT, SH_DSP_NEXT, SH3_DSP_NEXT): New macros.
8096 (SH4_NEXT): Reinstate.
8097 (SH3_NEXT, SH3E_NEXT): Adjust.
8098 * elf-bfd.h (_sh_elf_set_mach_from_flags): Declare.
8099 * elf32-sh.c (sh_elf_set_private_flags): New function.
8100 (sh_elf_copy_private_data, sh_elf_set_mach_from_flags): Likewise.
8101 (sh_elf_merge_private_data): New function.
8102 (elf_backend_object_p, bfd_elf32_bfd_set_private_bfd_flags): Define.
8103 (bfd_elf32_bfd_copy_private_bfd_data): Define.
8104 (bfd_elf32_bfd_merge_private_bfd_data): Change to
8105 sh_elf_merge_private_data.
8107 2000-02-13 Richard Henderson <rth@cygnus.com>
8109 * elf-bfd.h (struct elf_link_hash_table): Add copy_indirect and
8110 hide_symbol members.
8111 (elf_link_hash_copy_indirect): New.
8112 (elf_link_hash_hide_symbol): New.
8113 * elflink.h (elf_link_add_object_symbols): Break out copy from
8114 indirect new new symbol to elf.c.
8115 (elf_link_assign_sym_version): Break out privatization of
8116 non-exported symbol to elf.c.
8117 * elf.c (_bfd_elf_link_hash_copy_indirect): New.
8118 (_bfd_elf_link_hash_hide_symbol): New.
8119 (_bfd_elf_link_hash_table_init): Init copy_indirect and hide_symbol.
8121 2000-02-13 Ian Lance Taylor <ian@zembu.com>
8123 * section.c (_bfd_strip_section_from_output): Add info parameter.
8124 If it passed as non-NULL, use it to check whether any input BFD
8125 has an input section which uses this output section. Change all
8127 * bfd-in2.h: Rebuild.
8129 * bfd-in.h: Move declarations of bfd_get_elf_phdr_upper_bound and
8130 bfd_get_elf_phdrs in from bfd-in2.h, correcting patch of
8132 * bfd-in2.h: Rebuild.
8134 2000-02-10 Timothy Wall <twall@cygnus.com>
8136 * coffswap.h (coff_swap_sym_in): Add hook SWAP_SYM_IN_POST to
8137 allow final modifications of swapped-in symbol.
8138 (coff_swap_sym_out): Ditto with SWAP_SYM_OUT_POST.
8139 * coffcode.h (coff_write_relocs): Use macro
8140 SECTION_RELATIVE_ABSOLUTE_SYMBOL_P if defined to determine whether
8141 symbol index should be set to -1.
8143 Thu Feb 10 20:07:50 GMT 2000 Toshiyasu Morita (toshi.morita@sega.com)
8145 * coff-sh.c (USES1_REG, USES2_REG, SETS1_REG, SETS2_REG,
8146 USESF1_REG, USESF2_REG, SETSF1_REG, SETSF2_REG): New macros.
8147 * (sh_insn_sets_reg, sh_insn_sets_freg): New prototypes.
8148 * (sh_insn_sets_reg, sh_insn_uses_or_sets_reg, sh_insns_sets_freg,
8149 sh_insns_uses_or_sets_freg): New functions.
8150 * (sh_insn_uses_reg, sh_insn_uses_freg): Use new macros.
8151 * (sh_insns_conflict): Use new functions and new macros to
8152 detect conflicts when two instructions both set same integer registers,
8153 both set same fp register, and both set special register.
8155 2000-02-09 Timothy Wall <twall@cygnus.com>
8157 * coffgen.c (coff_real_object_p): Set arch/mach info prior to
8158 swapping in sections, so that the swapping routines have access to
8161 2000-02-08 Mark Elbrecht <snowball3@bigfoot.com>
8163 * coff-go32.c: Update comment. Update copyright.
8165 2000-01-27 Thomas de Lellis <tdel@windriver.com>
8167 * syms.c (bfd_decode_symclass)
8168 Two new class characters were added - 'V' and 'v'. The
8169 meaning of 'W' is now restricted to just weak non-object
8170 symbols. This allows differentiation between, for example,
8171 weak functions vs weak objects. nm for example now dumps:
8173 'w' = weak unresolved
8174 'V' = weak global object
8175 'v' = weak unresolved object
8177 (bfd_is_undefined_symclass): New function. Return true if the
8178 given symbol class represents and undefined/unresolved symbol.
8180 (bfd_symbol_info): Use bfd_is_undefined_symclass to check for
8183 * bfd-in2.h: Add prototype for bfd_is_undefined_symbol().
8185 * elf32-arm.h (elf32_arm_get_symbol_type): If a symbol has the
8186 STT_ARM_16BIT flag set, but it is not attached to a data object
8187 return STT_ARM_16BIT so that it will be treated as code by the
8190 2000-01-27 Alan Modra <alan@spri.levels.unisa.edu.au>
8192 * coff-i386.c (i3coff_object_p): Remove prototype.
8195 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Add const
8196 to name. Update copyright.
8198 * trad-core.c (trad_unix_core_file_p): Cast core_regsec
8199 assignment to avoid warning. Update copyright.
8201 2000-01-24 Robert Lipe (robertl@sco.com)
8203 * coffcode.h (coff_write_object_contents): Get buff via bfd_malloc
8204 instead of using GNU C extension.
8206 2000-01-21 Nick Clifton <nickc@cygnus.com>
8208 * libbfd.c (bfd_read): Do not attempt to get a negativly sized
8209 amount from a bfd_in_memory structure.
8210 (bfd_seek): Do not allow seeks past the end of a bfd_in_memory
8213 2000-01-14 Nick Clifton <nickc@cygnus.com>
8215 * linker.c (default_indirect_link_order): oops - fix incorrectly
8216 applied patch from Tim Wall.
8218 2000-01-13 Timothy Wall (twall@tiac.net>
8220 * coffcode.h: Use bfd_coff_xxx instead of the macro XXX (where xxx
8221 = scnhsz, filhsz, relsz, aoutsz, etc)
8223 * coffswap.h: Ditto.
8225 2000-01-13 Nick Clifton <nickc@cygnus.com>
8227 * elf32-arm.h (elf32_thumb_to_arm_stub): Fix offset in branch to
8228 interwork thumb to arm stub.
8230 2000-01-13 Timothy Wall (twall@tiac.net>
8232 * archures.c (bfd_octets_per_byte): New function: Return
8234 (bfd_arch_mach_octets_per_byte): New function: Return target
8237 * section.c: Distinguish between octets and bytes for usage of
8238 _cooked_size, _raw_size, and output_offset. Clarify
8239 description of bfd_set_section_contents.
8241 * bfd-in2.h: Regenerate.
8243 * coffgen.c: Indicate that the offset parameter is in bytes, not
8246 * cofflink.c (bfd_coff_link_input_bfd): Use bfd_octets_per_byte
8247 where appropriate to get the octet offset when calling
8248 bfd_set_section_contents.
8249 (bfd_coff_reloc_link_order): Ditto.
8251 * linker.c (bfd_generic_reloc_link_order): Ditto.
8252 (_bfd_default_link_order): Ditto.
8254 * reloc.c (bfd_perform_relocation): Distinguish between octets
8255 and bytes. Use octets when indexing into octet data; use bytes
8256 when calculating target addresses.
8257 (bfd_install_relocation): Ditto.
8259 * srec.c (srec_write_section): Ditto.
8261 2000-01-13 Nick Clifton <nickc@cygnus.com>
8263 * coff-mcore.c (COFF_DEFAULT_SECTION_ALIGNMENT_POWER): Change from
8264 3 to 2. This allows 4 byte sized sections, which is necessary for
8265 dlltool to build functioning DLLs.
8267 2000-01-10 Philip Blundell <pb@futuretv.com>
8269 * config.bfd (arm*-*-linux-gnu*): Match instead of arm*-*-linux-gnu.
8270 (arm*-*-conix*): New target.
8272 2000-01-10 Egor Duda <deo@logos-m.ru>
8274 * config.bfd: Include elf32_i386 vector to target list for cygwin
8277 * config.in: Undefine HAVE_WIN32_PSTATUS_T.
8278 * configure.in: Test for structure win32_pstatus_t in
8280 * configure: Regenerate.
8282 * elf.c (elfcore_grok_win32pstatus): New function: process
8283 win32_pstatus_t notes in elf core file.
8284 (elfcore_grok_note): Detect win32_pstatus notes.
8286 2000-01-03 Martin v. Loewis <loewis@informatik.hu-berlin.de>
8288 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Process symbol
8290 * elflink.h (elf_link_add_object_symbols): Combine visibilities.
8291 * elf.c (bfd_elf_print_symbol): Interpret st_other as visibility.
8293 For older changes see ChangeLog-9899
8299 version-control: never