1 2001-10-29 Kazu Hirata <kazu@hxi.com>
5 2001-10-24 Richard Henderson <rth@redhat.com>
7 * peXXigen.c (_bfd_XX_print_private_bfd_data_common): Copy
8 timestamp to time_t for ctime.
10 2001-10-24 Hans-Peter Nilsson <hp@axis.com>
12 * elf32-cris.c (cris_reloc_type_lookup): Change loop to use
13 unsigned, increasing index.
15 2001-10-23 H.J. Lu <hjl@gnu.org>
17 * elf32-mips.c (_bfd_mips_elf_modify_segment_map): Check
18 m != NULL before accessing it.
20 2001-10-23 Alan Modra <amodra@bigpond.net.au>
22 * elflink.h (elf_link_input_bfd): Zero the reloc instead of doing
23 bfd_reloc_type_lookup (bfd, BFD_RELOC_NONE) as bfd_reloc_type_lookup
24 doesn't accept BFD_RELOC_* on some targets, eg. hppa.
26 * elf32-hppa.c (elf32_hppa_link_hash_entry): Remove plt_abs.
27 (hppa_link_hash_newfunc): Likewise.
28 (elf32_hppa_finish_dynamic_symbol): Likewise.
29 (allocate_dynrelocs): Always allocate .got relocs if shared.
30 (elf32_hppa_relocate_section): Output them too. Similarly
31 consolidate .plt reloc code, and no longer initialise .plt
32 when a reloc is output.
33 (elf32_hppa_finish_dynamic_symbol): Only initialise .plt entries
34 when no reloc is output.
36 From Herbert Xu <herbert@gondor.apana.org.au>
37 * elf32-hppa.c (final_link_relocate): Call bfd_set_error for
40 2001-10-22 H.J. Lu <hjl@gnu.org>
42 * configure.in (WIN32LIBADD): Use -L../libiberty for
46 2001-10-21 H.J. Lu <hjl@gnu.org>
48 * configure.in (WIN32LIBADD): Include -L../libiberty/pic -liberty
49 if shared library is enabled only for Linux hosts.
52 2001-10-21 H.J. Lu <hjl@gnu.org>
54 * configure.in (WIN32LIBADD): Check if PICFLAG is defined in
55 ../libiberty/Makefile instead of $enable_shared.
58 2001-10-21 H.J. Lu <hjl@gnu.org>
60 * elf32-cris.c (cris_reloc_type_lookup): Use int for index. Cover
63 2001-10-20 H.J. Lu <hjl@gnu.org>
65 * configure.in (WIN32LIBADD): Include -L../libiberty/pic -liberty
66 if shared library is enabled.
69 2001-10-20 H.J. Lu <hjl@gnu.org>
71 * elf32-cris.c (cris_reloc_type_lookup): Allow index 0.
73 2001-10-19 H.J. Lu <hjl@gnu.org>
75 * elfcode.h (elf_object_p): Don't clear D_PAGED if the section
78 2001-10-18 H.J. Lu <hjl@gnu.org>
80 * elf32-i370.c (i370_elf_relocate_section): Ignore R_XXX_NONE.
81 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
83 2001-10-18 Jakub Jelinek <jakub@redhat.com>
85 * section.c (_bfd_strip_section_from_output): Don't count
86 SEC_EXCLUDE sections as references. Set SEC_EXCLUDE.
88 2001-10-17 Alan Modra <amodra@bigpond.net.au>
90 * elf-m10200.c (mn10200_elf_relax_section): Cast assignment to
91 Elf_Internal_Shdr.contents now that it's no longer a PTR.
92 * elf-m10300.c (mn10300_elf_relax_section): Likewise.
93 * elf32-h8300.c (elf32_h8_relax_section): Likewise.
94 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Likewise.
95 * elf32-sh.c (sh_elf_relax_section): Likewise.
96 * elf64-alpha.c (elf64_alpha_relax_section): Likewise.
97 * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
98 * elf.c (setup_group): Warning fixes.
99 * elflink.h (elf_link_sort_relocs): Likewise.
100 * pdp11.c (slurp_reloc_table): Likewise.
102 2001-10-16 Jeff Holcomb <jeffh@redhat.com>
104 * elflink.h (elf_link_sort_relocs): Remove unnecessary pointer
107 2001-10-15 H.J. Lu <hjl@gnu.org>
109 * elflink.h (elf_link_input_bfd): Set type to BFD_RELOC_NONE
110 for relocations against discarded link-once section.
112 2001-10-15 Alan Modra <amodra@bigpond.net.au>
114 * elf32-i386.c (elf_i386_relocate_section): Report some detail on
115 bfd_reloc_outofrange and similar errors.
117 * elf.c (_bfd_elf_link_hash_copy_indirect): Test ind->root.type
118 rather than ind->weakdef.
119 * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Likewise.
120 * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
121 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Likewise.
122 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
123 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
125 2001-10-15 Alan Modra <amodra@bigpond.net.au>
126 H.J. Lu <hjl@gnu.org>
128 * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Merge dyn_reloc
129 counts for aliases instead of aborting.
130 * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
131 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
133 * elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Set plt.offset
134 to -1 for non-function symbols.
135 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Likewise.
136 * elf32-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
137 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
138 * elf64-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
139 * elf64-x86-64.c (elf64_x86_64_adjust_dynamic_symbol): Likewise.
140 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Refer to
141 plt.offset instead of plt.refcount when setting to -1.
143 2001-10-12 Nick Clifton <nickc@cambridge.redhat.com>
145 * elf32-arm.h (elf32_arm_relocate_section): Treat R_ARM_THM_PC22
146 like R_ARM_PC24. Include reloc number in error message about
149 2001-10-10 Jakub Jelinek <jakub@redhat.com>
151 * elflink.h (elf_link_sort_cmp2): Don't mix PLT and non-PLT
152 relocations against the same symbol in .rel{,a}.dyn section.
154 2001-10-10 Kazu Hirata <kazu@hxi.com>
156 * aout-encap.c: Fix comment typos.
158 * archive.c: Likewise.
160 * coff64-rs6000.c: Likewise.
161 * coffcode.h: Likewise.
162 * coffgen.c: Likewise.
163 * cofflink.c: Likewise.
164 * coff-mips.c: Likewise.
166 * elf32-m32r.c: Likewise.
167 * libcoff-in.h: Likewise.
168 * libecoff.h: Likewise.
169 * libxcoff.h: Likewise.
170 * nlm32-i386.c: Likewise.
172 * section.c: Likewise.
175 * bfd-in2.h: Regenerate.
176 * libcoff.h: Likewise.
178 2001-10-10 Alan Modra <amodra@bigpond.net.au>
180 * elf.c (elf_map_symbols): Don't create new section symbols; Use
181 existing section syms. Update comments.
182 (copy_private_bfd_data): Formatting fixes.
183 (elfcore_grok_win32pstatus): Likewise.
184 (swap_out_syms): Likewise. Remove unnecessary level of braces.
186 2001-10-09 Alan Modra <amodra@bigpond.net.au>
188 * elf-bfd.h (struct bfd_elf_section_data): Rename "group" to
190 (elf_group_name): Define.
191 (elf_next_in_group): Define.
192 * elf.c: Make use of elf_group_name and elf_next_in_group throughout.
193 (setup_group): Don't use sec->lineno for SHT_GROUP section to store
194 first member section; Instead use elf_next_in_group.
195 (bfd_section_from_shdr): Likewise.
196 (set_group_contents): Likewise. Use elf_section_syms, not sec->symbol.
198 2001-10-09 Alan Modra <amodra@bigpond.net.au>
200 * elf-bfd.h (struct bfd_elf_section_data): Add "group" and
201 "next_in_group". Fix gp and gp_size comments.
202 * elf.c (union elf_internal_group): New.
203 (setup_group): New function.
204 (_bfd_elf_make_section_from_shdr): Set BFD flags for SHT_GROUP.
205 Call setup_group for SHF_GROUP sections.
206 (bfd_section_from_shdr): Build a BFD section for SHT_GROUP.
207 (elf_fake_sections): Set header type for SEC_GROUP, and header
208 flags for sections in a group.
209 (set_group_contents): New function.
210 (_bfd_elf_compute_section_file_positions): Call it.
211 (assign_section_numbers): Set sh_link for SHT_GROUP.
213 * elflink.h (gc_mark_hook): Handle section groups.
214 * elfxx-target.h: Add SEC_GROUP to applicable_flags.
215 * section.c (SEC_GROUP): Define.
216 (struct sec): Comment fixes.
217 * bfd-in2.h: Regenerate.
219 * elf.c (bfd_elf_print_symbol): Formatting fix; migrate expression
220 out of function args.
221 (_bfd_elf_canonicalize_reloc): Similarly.
222 (_bfd_elf_get_symtab): Here too.
223 (_bfd_elf_canonicalize_dynamic_symtab): And here.
224 * elfcode.h (elf_slurp_symbol_table): Don't recalculate size for
225 bfd_bread, and remove unnecessary cast.
227 2001-10-08 Aldy Hernandez <aldyh@redhat.com>
229 * bfd/config.bfd (targ_cpu): Add arm9e-*-elf.
231 2001-10-06 Stephane Carrez <Stephane.Carrez@worldnet.fr>
233 * dwarf2.c (comp_unit_find_nearest_line): Check for end of
236 2001-10-06 Alan Modra <amodra@bigpond.net.au>
238 * bfd.c (bfd_assert): Report bfd version.
239 (_bfd_abort): Likewise.
241 * elflink.h (elf_link_input_bfd): Don't zero discarded link-once
242 section sym values. Instead replace any relocs against them with
243 relocs against STN_UNDEF, which has a zero value.
245 * elf32-arc.c (elf_arc_howto_table): Set partial_inplace for all
248 2001-10-05 Jeff Law <law@redhat.com>
250 * som.h (som_exec_data): New field "version_id".
251 * som.c (som_object_setup): Record the version_id if it
253 (som_prep_headers): Do not initialize version_id here.
254 (som_finish_writing): Initialize version_id here.
256 2000-10-05 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
258 * elf32-mips.c (elf_mips_howto_table): Fix some relocation howtos
259 according to the MIPS/SGI ELF64 ABI Draft.
260 (mips_elf_sort_hash_table): Typo.
262 2001-10-04 Alan Modra <amodra@bigpond.net.au>
264 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Comment typo.
266 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Bail out after
267 copying flags if this is a weakdef.
269 2001-10-04 Alan Modra <amodra@bigpond.net.au>
271 * elf-bfd.h (struct elf_link_hash_entry): Reorganise for better
274 * elf32-mips.c (mips_elf_record_global_got_symbol): Set got.offset
275 to 1 rather than 0 to avoid confusing copy_indirect_symbol.
276 (mips_elf_sort_hash_table_f): Compare got.offset against 1.
278 * Makefile.am (BFD_H_DEPS): Add symcat.h. Ensure everything
279 depends on $(BFD_H) $(BFD_H_DEPS) $(LOCAL_H_DEPS), not just those
280 backends we configure. Run "make dep-am".
281 (install-data-local): Install symcat.h.
282 * dep-in.sed: Remove symcat.h from dependencies.
283 * Makefile.in: Regenerate.
285 2001-10-03 Vassili Karpov <malc@pulsesoft.com>
287 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Handle nocopyreloc.
289 2001-10-03 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
291 * elf64-mips.c (elf_backend_may_use_rela_p): New define.
292 (elf_backend_default_use_rela_p): New define.
294 2001-10-03 Alan Modra <amodra@bigpond.net.au>
296 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Fix typos in last
299 * configure.in (AC_OUTPUT <bfd-in3.h>): Remove version.h.
300 * configure: Regenerate.
301 * Makefile.am (BFD_H_FILES): Add version.h.
302 * Makefile.in: Regenerate.
303 * po/SRC-POTFILES.in: Regenerate.
305 * elflink.h (elf_fix_symbol_flags): Copy flags to weakdef using
306 elf_backend_copy_indirect_symbol so that backend has a chance to
307 copy other necessary fields.
308 * elf-bfd.h (struct elf_backend_data): Update description of
309 elf_backend_copy_indirect_symbol.
310 * elf.c (_bfd_elf_link_hash_copy_indirect): Bail out after
311 copying flags if this is a weakdef.
312 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
313 (elfNN_ia64_aix_add_symbol_hook): Use elf_link_hash_lookup rather
314 than bfd_link_hash_lookup.
315 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Don't do copy
316 reloc processing for weakdefs.
317 * elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Likewise.
318 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
320 2001-10-02 Alan Modra <amodra@bigpond.net.au>
322 * elf64-ppc.c (ppc64_elf_check_relocs): Use a local var and cast
323 result of ELF64_R_TYPE to enum before using in a switch.
324 (ppc64_elf_gc_mark_hook): Likewise.
325 (ppc64_elf_gc_sweep_hook): Likewise.
326 (ppc64_elf_reloc_type_class): Likewise.
328 2001-10-02 Alan Modra <amodra@bigpond.net.au>
330 * version.h: New file.
331 * bfd-in.h: (BFD_VERSION): Substitute bfd_version.
332 (BFD_VERSION_DATE): Define.
333 (BFD_VERSION_STRING): Define.
334 * configure.in: AC_SUBST bfd_version, bfd_version_date and
336 (AC_OUTPUT <bfd-in3.h>): Depend on version.h.
337 * bfd-in2.h: Regenerate.
338 * configure: Regenerate.
339 * Makefile.am: Run "make dep-am".
340 * Makefile.in: Regenerate.
342 * bfd-in.h: Include "symcat.h".
343 (CONCAT4): Redefine as for old CAT4.
344 * aout-arm.c: Use equivalent CONCAT* macro in place of CAT* macros.
345 Add warning regarding whitespace.
346 * aout-cris.c: Likewise.
347 * aout-ns32k.c: Likewise.
348 * aout-sparcle.c: Likewise.
349 * aout-tic30.c: Likewise.
351 * armnetbsd.c: Likewise.
352 * demo64.c: Likewise.
353 * elf-bfd.h: Likewise.
354 * gen-aout.c: Likewise.
355 * host-aout.c: Likewise.
356 * hp300bsd.c: Likewise.
357 * hp300hpux.c: Likewise.
358 * i386aout.c: Likewise.
359 * i386bsd.c: Likewise.
360 * i386dynix.c: Likewise.
361 * i386freebsd.c: Likewise.
362 * i386linux.c: Likewise.
363 * i386lynx.c: Likewise.
364 * i386mach3.c: Likewise.
365 * i386netbsd.c: Likewise.
366 * libaout.h: Likewise.
367 * m68k4knetbsd.c: Likewise.
368 * m68klinux.c: Likewise.
369 * m68klynx.c: Likewise.
370 * m68knetbsd.c: Likewise.
371 * m88kmach3.c: Likewise.
372 * mipsbsd.c: Likewise.
373 * newsos3.c: Likewise.
374 * ns32knetbsd.c: Likewise.
375 * pc532-mach.c: Likewise.
377 * riscix.c: Likewise.
378 * sparclinux.c: Likewise.
379 * sparclynx.c: Likewise.
380 * sparcnetbsd.c: Likewise.
382 * targets.c: Likewise.
383 * vaxnetbsd.c: Likewise.
384 * vms-hdr.c: Likewise.
386 2001-10-01 Alan Modra <amodra@bigpond.net.au>
388 * bfd-in.h: Remove comments regarding generated files.
389 * libbfd-in.h: Likewise.
390 * libcoff-in.h: Likewise.
391 * bfd-in2.h: Regenerate.
392 * libbfd.h: Likewise.
393 * libcoff.h: Likewise.
395 2001-09-30 kaz Kojima <kkojima@rr.iij4u.or.jp>
396 Hans-Peter Nilsson <hp@bitrange.com>
398 * elf32-sh.c (sh_elf_howto_table, R_SH_REL32): Make
399 partial_inplace, matching assembler output. Set src_mask to
401 (sh_elf_relocate_section): Delete misplaced comment.
402 For relocatable linking against section symbol, call
403 _bfd_relocate_contents for partial_inplace relocs and adjust
404 rel->r_addend for others.
405 <case R_SH_DIR32, R_SH_REL32>: Fetch partial_inplace addend with
406 bfd_get_32, not at rel->r_addend.
408 2001-09-30 Alan Modra <amodra@bigpond.net.au>
410 * elf.c (_bfd_elf_link_hash_copy_indirect): Set ind refcounts to
411 the old dir refcount, so we indirectly set them to init_refcount.
412 Short-circuit asserts when we've just verified they are true.
414 2001-09-29 Alan Modra <amodra@bigpond.net.au>
416 * section.c (struct sec): Remove kept_section.
417 (STD_SECTION): Remove kept_section initialisation.
418 (bfd_make_section_anyway): Here too.
419 * ecoff.c (bfd_debug_section): Remove kept_section initialisation.
420 * cofflink.c (_bfd_coff_link_input_bfd): Don't test kept_section.
421 * elflink.h (elf_link_input_bfd): Set discarded link-once section
422 symbols to zero, and remove all code involved with kept_section
423 and tracking section symbol values.
424 * bfd-in2.h: Regenerate.
425 * configure.in: Bump version number.
426 * configure: Regenerate.
428 2001-09-29 Alan Modra <amodra@bigpond.net.au>
430 * elf64-ppc.c (struct ppc_dyn_relocs): New.
431 (IS_ABSOLUTE_RELOC): Define.
432 (struct ppc_link_hash_entry): New.
433 (struct ppc_link_hash_table): New.
434 (ppc_hash_table): Define.
435 (link_hash_newfunc): New function.
436 (ppc64_elf_link_hash_table_create): New function.
437 (create_got_section): New function.
438 (ppc64_elf_create_dynamic_sections): Call create_got_section. Stash
439 pointers to our dynamic sections in hash table.
440 (ppc64_elf_copy_indirect_symbol): New function.
441 (ppc64_elf_check_relocs): Remove DEBUG code. Use short-cuts to
442 dynamic sections. Localise vars. Modify code for refcounts
443 starting from zero. Don't allocate here, or force symbols dynamic.
444 Don't copy all relocs if shared, select ones we need. Add code
445 to track possible copy relocs for non-shared link.
446 (ppc64_elf_gc_mark_hook): Update comment.
447 (ppc64_elf_gc_sweep_hook): Sweep dynrelocs too.
448 (ppc64_elf_adjust_dynamic_symbol): Remove DEBUG code. Rewrite .plt
449 code for reference counting garbage collection. Don't create .plt
450 entries for functions that don't comply with ABI naming convention,
451 and don't allocate .plt space here. Use short-cuts to dynamic
452 sections. If possible, keep dynamic relocations instead of using
453 copy relocs. Remove confused comments.
454 (ppc_adjust_dynindx): Delete.
455 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
456 (allocate_dynrelocs): New function.
457 (readonly_dynrelocs): New function.
458 (ppc64_elf_size_dynamic_sections): Rewrite. Allocate local .got
459 space here, and call allocate_dynrelocs to allocate space for
460 global .plt, .got and reloc sections. Use short-cuts to dynamic
461 sections. Call readonly_dynrelocs to determine whether we need
462 DT_TEXTREL. Don't generate section symbols here, the generic
463 ELF linker code does it for us.
464 (ppc64_elf_final_link): Call regular ELF backend linker rather than
465 gc variety, since we do our own .got handling.
466 (ppc64_elf_relocate_section): Remove DEBUG code. Make use of
467 dynamic section short-cuts. Localise vars, and delay setting.
468 Handle unknown relocs in main switch statement. Replace ugly
469 complicated tests for unresolvable relocs with a simple direct
470 scheme using "unresolved_reloc" var. Test ELF_ST_VISIBILITY
471 before allowing an undefined sym in a shared lib. Do R_*_DS tests
472 after main switch, when we've set addend. Do non-addend insn
473 tweaks before main swithc. Ignore input_section->vma when
474 calculating reloc offsets as it's always zero. Rewrite dynamic
475 reloc handling. Consolidate R_*_HA handling. Handle more relocs.
476 (ppc64_elf_finish_dynamic_symbol): Remove DEBUG code. Make use
477 of dynamic section short-cuts. Reorganise .plt handling code.
478 Remove confused comments. Take note of ELF_LINK_FORCED_LOCAL.
479 Move expressions out of swap_reloca_out function calls.
480 (ppc64_elf_reloc_type_class): New function.
481 (ppc64_elf_info_to_howto): Move common expression to local var.
482 (ppc64_elf_finish_dynamic_sections): Remove DEBUG code. Make use
483 of dynamic section short-cuts. Don't fiddle with section syms
484 here as the ELF linker does it for us.
485 (elf_backend_can_refcount): Define.
486 (bfd_elf64_bfd_link_hash_table_create): Define.
487 (elf_backend_copy_indirect_symbol): Define.
488 (elf_backend_reloc_type_class): Define.
489 (elf_backend_*, bfd_elf64_bfd_* defines): Sort.
491 2001-09-29 Alan Modra <amodra@bigpond.net.au>
493 * elf-bfd.h (struct elf_link_local_dynamic_entry): Add init_refcount.
494 (struct elf_backend_data): Add can_refcount.
495 * elf.c (_bfd_elf_link_hash_newfunc): Get rid of a few casts. Set
496 got.refcount and plt.refcount from init_refcount.
497 (_bfd_elf_link_hash_table_init): Set up init_refcount.
498 (_bfd_elf_link_hash_copy_indirect): Reference got/plt.refcount
499 rather than got/plt.offset, and test for <= 0 rather than -1.
500 * elflink.h (size_dynamic_sections): Set init_refcount to -1.
501 * elfxx-target.h (elf_backend_can_refcount): Define.
502 (elfNN_bed): Init can_refcount.
503 * linker.c (_bfd_link_hash_newfunc): Get rid of a few casts.
504 (_bfd_generic_link_hash_newfunc): Likewise.
505 * elf32-cris.c (cris_elf_check_relocs): Modify for refcounts
507 (elf_backend_can_refcount): Define.
508 * elf32-hppa.c (elf32_hppa_check_relocs): Modify for refcounts
510 (elf32_hppa_copy_indirect_symbol): Make static to agree with
512 (elf_backend_can_refcount): Define.
513 * elf32-i386.c (elf_i386_check_relocs): Modify for refcounts
515 (allocate_dynrelocs): Set plt/got.offset rather than *.refcount.
516 (elf_i386_finish_dynamic_symbol): Expand SHN_UNDEF comment.
517 (elf_i386_finish_dynamic_sections): Use local var so line < 80 chars.
518 (elf_backend_can_refcount): Define.
519 (elf_i386_copy_indirect_symbol): Make static to agree with
520 prototype. Formatting fix.
521 * elf32-m68k.c (elf_m68k_check_relocs): Modify for refcounts
523 (elf_backend_can_refcount): Define.
524 * elf32-ppc.c (ppc_elf_check_relocs): Modify for refcounts
526 (elf_backend_can_refcount): Define.
527 * elf32-s390.c (elf_s390_check_relocs): Modify for refcounts
529 (elf_backend_can_refcount): Define.
530 * elf64-s390.c (elf_s390_check_relocs): Modify for refcounts
532 (elf_backend_can_refcount): Define.
533 * elf64-x86-64.c (elf64_x86_64_check_relocs): Modify for refcounts
535 (elf_backend_can_refcount): Define.
537 * som.c (som_write_symbol_strings): Cast current_offset in
538 bfd_seek call to match param type.
540 2001-09-28 J. Brobecker <brobecker@gnat.com>
542 * som.c (som_write_symbol_strings): Fix incorrect type of
543 current_offset to match the function definition. Fixes a build
544 failure on HPUX-11.00.
546 2001-09-28 Richard Henderson <rth@redhat.com>
548 * elfxx-target.h [section_flags]: Add SEC_ARCH_BIT_0, SEC_SMALL_DATA,
549 SEC_MERGE, SEC_STRINGS.
551 * section.c (SEC_ARCH_BIT_0): New; replace unused SEC_BALIGN.
552 * bfd-in2.h: Rebuild.
554 2001-09-28 Alan Modra <amodra@bigpond.net.au>
556 * elf64-x86-64.c (elf64_x86_64_reloc_type_lookup): Don't map bfd
557 reloc code using x86_64_reloc_map.
559 * elf32-hppa.c (elf32_hppa_check_relocs): Update comment since we
560 no longer allocate here. Localise some vars to blocks where they
562 (elf32_hppa_adjust_dynamic_symbol): Correct a comment. Delay
563 setting of vars until needed.
564 (allocate_dynrelocs): Don't create a .plt entry without a reloc
565 when symbol visibilty makes a function local.
566 (elf32_hppa_finish_dynamic_symbol): Move expressions out of
567 swap_reloca_out function calls.
568 (elf32_hppa_relocate_section): Likewies. Comment typo fix.
569 (elf32_hppa_finish_dynamic_sections): Migrate common code out of
572 * elf32-i386.c (elf_i386_check_relocs): Update comment since we
573 no longer allocate here. Localise some vars to blocks where they
574 are used. Remove separate switch stmt for creating .got sec.
575 (elf_i386_adjust_dynamic_symbol): Correct a comment. Remove
576 redundant casts and aborts. Delay setting of vars until needed.
577 (allocate_dynrelocs): Remove redundant casts and aborts.
578 (elf_i386_size_dynamic_sections): Move comment.
579 (elf_i386_finish_dynamic_symbol): Move expressions out of function
581 (elf_i386_relocate_section): Likewise. Comment typo fix.
582 (elf_i386_finish_dynamic_sections): Migrate common code out of
584 (elf_backend_* defines): Sort.
586 * elf32-i386.c (allocate_dynrelocs): Don't create a .plt entry
587 without a reloc when symbol visibilty makes a function local.
589 2001-09-27 Nick Clifton <nickc@cambridge.redhat.com>
591 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix detection of
592 conflicting float flags.
594 2001-09-26 Alan Modra <amodra@bigpond.net.au>
596 * elf32-i386 (elf_i386_copy_indirect_symbol): New function.
597 (elf_backend_copy_indirect_symbol): Define.
598 (struct elf_i386_link_hash_entry): Rename "root" to "elf".
599 (struct elf_i386_link_hash_table): Likewise.
600 (link_hash_newfunc): Get rid of unnecessary casts.
601 (elf_i386_link_hash_table_create): Likewise.
602 (elf_i386_check_relocs): Initialise local_got_refcounts to 0.
603 Don't test input section SEC_READONLY here to try to avoid copy
604 relocs, and keep dyn_relocs regardleas of ELF_LINK_NON_GOT_REF.
605 (elf_i386_adjust_dynamic_symbol): Check output section SEC_READONLY
606 here to properly test whether we need copy relocs. Do so for weak
609 * elf32-hppa (elf32_hppa_copy_indirect_symbol): New function.
610 (elf_backend_copy_indirect_symbol): Define.
611 (struct elf32_hppa_link_hash_table): Rename "root" to "elf".
612 (stub_hash_newfunc): Get rid of unnecessary casts.
613 (hppa_link_hash_newfunc): Likewise.
614 (elf32_hppa_check_relocs): Initialise local_got_refcounts to 0.
615 Don't test input section SEC_READONLY here to try to avoid copy
616 relocs, and keep dyn_relocs regardleas of ELF_LINK_NON_GOT_REF.
617 (elf32_hppa_adjust_dynamic_symbol): Check output section SEC_READONLY
618 here to properly test whether we need copy relocs. Do so for weak
621 2001-09-26 Alan Modra <amodra@bigpond.net.au>
623 * bfd.c (_bfd_default_error_handlerl): Define using VPARAMS,
624 VA_OPEN, VA_FIXEDARG, VA_CLOSE.
625 (bfd_archive_filename): Cast bfd_malloc arg to the correct size.
627 2001-09-25 Jakub Jelinek <jakub@redhat.com>
629 * elf64-sparc.c (sparc64_elf_build_plt): Fix .plt[32768+] slot
632 2001-09-25 H.J. Lu <hjl@gnu.org>
634 * bfd-in2.h: Regenerated.
636 2001-09-25 Alan Modra <amodra@bigpond.net.au>
638 * elf32-i386.c: Add comment re linker function names and ordering.
639 (elf_i386_link_hash_newfunc): Rename to link_hash_newfunc.
640 (elf_i386_grok_prstatus): Move before linker functions.
641 (elf_i386_grok_psinfo): Likewise.
642 (elf_i386_fake_sections): Move so that functions are ordered.
643 (elf_i386_reloc_type_class): Likewise. Comment function purpose.
645 2001-09-25 Alan Modra <amodra@bigpond.net.au>
647 * elf32-hppa.c: Rename occurrences of "hplink" to "htab"
650 * elf32-hppa.c: (LONG_BRANCH_PIC_IN_SHLIB): Delete. Remove all
651 code handling this option.
652 (LONG_BRANCH_VIA_PLT): Likewise.
653 (RELATIVE_DYNRELOCS): Define as zero.
654 (struct elf32_hppa_dyn_reloc_entry): Add "sec", and
655 "pc_count" fields. Remove "section" field.
656 (elf32_hppa_link_hash_entry): Rename reloc_entries to dyn_relocs.
657 (elf32_hppa_check_relocs): Don't allocate space for dynamic
658 relocs here. Instead, record all needed dynamic relocs via
659 dyn_relocs and local_dynrel. Cache pointer to "sreloc" section
661 (elf32_hppa_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
662 (allocate_plt_and_got_and_discard_relocs): Rename to
663 allocate_dynrelocs. Allocate rather than discarding dyn relocs.
664 (readonly_dynrelocs): New function.
665 (elf32_hppa_size_dynamic_sections): Mark output_bfd unused.
666 Call readonly_dynrelocs to determine need for DT_TEXTREL.
667 Rename "i" to "ibfd". Allocate space for local dyn relocs.
668 (elf32_hppa_relocate_section): Make use of cached sreloc.
669 (elf32_hppa_reloc_type_class): New function.
670 (elf_backend_reloc_type_class): Define.
672 2001-09-25 Alan Modra <amodra@bigpond.net.au>
674 * elf-bfd.h (struct bfd_elf_section_data): Add "local_dynrel"
676 * elf32-i386.c (struct elf_i386_dyn_relocs): Add "sec", and
677 "pc_count" fields. Remove "section" field.
678 (elf_i386_check_relocs): Don't set DF_TEXTREL here. Don't
679 allocate space for dynamic relocs here. Instead, record all
680 needed dynamic relocs via dyn_relocs and local_dynrel. Cache
681 pointer to "sreloc" section in elf_section_data.
682 (elf_i386_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
683 (allocate_plt_and_got_and_discard_relocs): Rename to
684 allocate_dynrelocs. Allocate rather than discarding dyn relocs.
685 (readonly_dynrelocs): New function.
686 (elf_i386_size_dynamic_sections): Call readonly_dynrelocs.
687 Rename "i" to "ibfd". Allocate space for local dyn relocs.
688 (elf_i386_relocate_section): Make use of cached sreloc.
690 2001-09-24 Alan Modra <amodra@bigpond.net.au>
692 * elf-bfd.h (elf_backend_reloc_type_class): Pass in the entire
693 reloc rather than just the type.
694 (_bfd_elf_reloc_type_class): Likewise.
695 * elf.c (_bfd_elf_reloc_type_class): Likewise.
696 * elf32-arm.h (elf32_arm_reloc_type_class): Likewise.
697 * elf32-cris.c (elf_cris_reloc_type_class): Likewise.
698 * elf32-i386.c (elf_i386_reloc_type_class): Likewise.
699 * elf32-m68k.c (elf32_m68k_reloc_type_class): Likewise.
700 * elf32-ppc.c (ppc_elf_reloc_type_class): Likewise.
701 * elf32-s390.c (elf_s390_reloc_type_class): Likewise.
702 * elf32-sh.c (sh_elf_reloc_type_class): Likewise.
703 * elf32-sparc.c (elf32_sparc_reloc_type_class): Likewise.
704 * elf64-alpha.c (elf64_alpha_reloc_type_class): Likewise.
705 * elf64-s390.c (elf_s390_reloc_type_class): Likewise.
706 * elf64-sparc.c (sparc64_elf_reloc_type_class): Likewise.
707 * elf64-x86-64.c (elf64_x86_64_reloc_type_class): Likewise.
708 * elfxx-ia64.c (elfNN_ia64_reloc_type_class): Likewise.
709 * elflink.h: Formatting fixes.
710 (elf_link_sort_relocs): Make "count" and "size" bfd_size_type.
711 Call bfd_zmalloc rather than calloc. Remove unnecessary cast of
712 o->contents to PTR. Update call to elf_backend_reloc_type_class.
714 2001-09-22 John Reiser <jreiser@BitWagon.com>
716 * elfcode.h (elf_object_p): Allow for no section header at all in
717 non-ET_REL files. Honor 0 for e_shnum, e_shstrndx, e_shoff.
719 2001-09-21 Nick Clifton <nickc@cambridge.redhat.com>
721 * elfxx-ia64.c: Fix compile time warning messages.
722 * coff-mcore.c: Fix compile time warning messages.
723 * coff-ppc.c: Fix compile time warning messages.
724 * coffcode.h: Fix compile time warning messages.
725 * elf32-mips.c: Fix compile time warning messages.
726 * elf64-alpha.c: Fix compile time warning messages.
727 * libbfd.c: Fix compile time warning messages.
728 * bfd-in2.h: Regenerate.
730 2001-09-21 Alan Modra <amodra@bigpond.net.au>
732 * Makefile.am: Run "make dep-am".
733 * Makefile.in: Regenerate.
735 * aoutx.h: Formatting fixes.
736 * merge.c (_bfd_merged_section_offset): Break line at 80 chars.
738 * linker.c: Replace bfd_get_filename with bfd_archive_filename
741 2001-09-21 Alan Modra <amodra@bigpond.net.au>
743 * bfd.c (bfd_archive_filename): New function.
744 * bfd-in2.h: Regenerate.
745 * aout-adobe.c: Replace bfd_get_filename with bfd_archive_filename
746 in error messages where the bfd is an input bfd.
747 * aout-cris.c: Likewise.
748 * coff-arm.c: Likewise.
749 * coff-mcore.c: Likewise.
750 * coff-ppc.c: Likewise.
751 * coff-rs6000.c: Likewise.
752 * coff-sh.c: Likewise.
753 * coff-tic54x.c: Likewise.
754 * coff-tic80.c: Likewise.
755 * coff64-rs6000.c: Likewise.
756 * coffcode.h: Likewise.
757 * coffgen.c: Likewise.
758 * cofflink.c: Likewise.
759 * ecofflink.c: Likewise.
760 * elf-hppa.h: Likewise.
762 * elf32-arm.h: Likewise.
763 * elf32-cris.c: Likewise.
764 * elf32-gen.c: Likewise.
765 * elf32-hppa.c: Likewise.
766 * elf32-i370.c: Likewise.
767 * elf32-i386.c: Likewise.
768 * elf32-m32r.c: Likewise.
769 * elf32-mcore.c: Likewise.
770 * elf32-mips.c: Likewise.
771 * elf32-ppc.c: Likewise.
772 * elf32-s390.c: Likewise.
773 * elf32-sh.c: Likewise.
774 * elf32-sparc.c: Likewise.
775 * elf32-v850.c: Likewise.
776 * elf64-alpha.c: Likewise.
777 * elf64-gen.c: Likewise.
778 * elf64-ppc.c: Likewise.
779 * elf64-s390.c: Likewise.
780 * elf64-sparc.c: Likewise.
781 * elf64-x86-64.c: Likewise.
782 * elflink.h: Likewise.
783 * elfxx-ia64.c: Likewise.
786 * libbfd.c: Likewise.
788 * pe-mips.c: Likewise.
789 * peicode.h: Likewise.
791 * xcofflink.c: Likewise.
793 * elf32-arm.h: Make _bfd_error_handler calls K&R compatible.
795 * elflink.c (_bfd_elf_create_linker_section): Better grammar for
798 * coff-mcore.c (coff_mcore_relocate_section): Internalionalise
801 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Constify stt_types.
802 Consolidate error messages, and split long messages to two lines.
804 2001-09-20 John Reiser <jreiser@BitWagon.com>
806 * elf32-i386.c (elf_i386_relocate_section): Coordinate info->symbolic
807 and info->allow_shlib_undefined.
808 * elf32-cris.c: Likewise.
809 * elf32-hppa.c: Likewise.
810 * elf32-m68k.c: Likewise.
811 * elf32-mips.c: Likewise.
812 * elf32-ppc.c: Likewise.
813 * elf32-s390.c: Likewise.
814 * elf32-sh.c: Likewise.
815 * elf32-sparc.c: Likewise.
816 * elf64-alpha.c: Likewise.
817 * elf64-hppa.c: Likewise.
818 * elf64-ppc.c: Likewise.
819 * elf64-s390.c: Likewise.
820 * elf64-sparc.c: Likewise.
821 * elf64-x86-64.c: Likewise.
822 * elfxx-ia64.c: Likewise.
824 2001-09-18 Bruno Haible <haible@clisp.cons.org>
826 * aoutx.h: Include "safe-ctype.h" instead of <ctype.h>.
827 (aout_link_write_symbols): Use ISDIGIT instead of isdigit.
828 * archive.c: Include "safe-ctype.h" instead of <ctype.h>.
829 (_bfd_generic_read_ar_hdr_mag): Use ISDIGIT instead of isdigit.
830 * archures.c: Include "safe-ctype.h" instead of <ctype.h>.
831 (bfd_default_scan): Use ISDIGIT instead of isdigit.
832 * bfd.c: Include "safe-ctype.h" instead of <ctype.h>.
833 (bfd_scan_vma): Use ISXDIGIT/ISDIGIT/ISLOWER instead of
834 isxdigit/isdigit/islower.
835 * binary.c: Include "safe-ctype.h" instead of <ctype.h>.
836 (mangle_name): Use ISALNUM instead of isalnum.
837 * cpu-v850.c: Include "safe-ctype.h" instead of <ctype.h>.
838 (scan): Use ISDIGIT instead of isdigit.
839 * hosts/alphavms.h: Don't include <ctype.h>.
840 * ieee.c: Include "safe-ctype.h" instead of <ctype.h>.
841 (ieee_object_p): Use TOUPPER instead of toupper.
842 * ihex.c: Include "safe-ctype.h" instead of <ctype.h>.
843 (ihex_bad_byte): Use ISPRINT instead of isprint.
844 * merge.c: Don't include <ctype.h>.
845 * oasys.c: Include "safe-ctype.h" instead of <ctype.h>.
846 (oasys_write_sections): Use ISDIGIT instead of isdigit.
847 * pdp11.c: Include "safe-ctype.h" instead of <ctype.h>.
848 (aout_link_write_symbols): Use ISDIGIT instead of isdigit.
849 * ppcboot.c: Include "safe-ctype.h" instead of <ctype.h>.
850 (mangle_name): Use ISALNUM instead of isalnum.
851 * som.c: Include "safe-ctype.h" instead of <ctype.h>.
852 (som_set_reloc_info): Use ISUPPER/ISLOWER/ISDIGIT instead of
853 isupper/islower/isdigit.
854 (som_decode_symclass): Use TOUPPER instead of toupper.
855 * srec.c: Include "safe-ctype.h" instead of <ctype.h>.
856 (srec_bad_byte): Use ISPRINT instead of isprint.
857 (srec_scan): Use ISSPACE instead of isspace.
858 * stabs.c: Include "safe-ctype.h" instead of <ctype.h>.
859 (_bfd_link_section_stabs): Use ISDIGIT instead of isdigit.
860 * syms.c: Include "safe-ctype.h"
861 (islower, toupper): Remove macro definitions.
862 (bfd_decode_symclass): Use TOUPPER instead of toupper.
863 * vms-gsd.c: Don't include <ctype.h>.
864 * vms-hdr.c: Include "safe-ctype.h" instead of <ctype.h>.
865 (_bfd_vms_write_hdr): Use ISLOWER/TOUPPER instead of
867 * vms-tir.c: Don't include <ctype.h>.
869 2001-09-18 Alan Modra <amodra@bigpond.net.au>
871 * libbfd.c (bfd_bread): New function replacing bfd_read without
872 redundant params. Allow reads up to (size_t) -2 in length.
873 (bfd_bwrite): Similarly for bfd_write.
874 (real_read): Return a size_t.
875 (bfd_read): Call bfd_bread.
876 (bfd_write): Call bfd_bwrite.
877 (warn_deprecated): New function to annoy everybody.
878 (bfd_get_file_window): Don't call bfd_set_error unnecessarily.
879 * bfd-in.h (bfd_bread, bfd_bwrite, warn_deprecated): Declare.
880 (bfd_read, bfd_write): Define as macro.
881 * aix386-core.c: Replace calls to bfd_read with bfd_bread, and
882 likewise for bfd_write. Ensure function args are correct size by
883 using casts or local vars. In some cases, remove unnecessary
884 casts. Formatting fixes, in some cases removing a large expression
885 from function args by using a local var. Replace CONST with const.
886 Modify variable types to avoid warings. Use casts to avoid
887 warnings when using negative numbers in unsigned expressions.
888 * aout-adobe.c: Likewise.
889 * aout-arm.c: Likewise.
890 * aout-cris.c: Likewise.
891 * aout-encap.c: Likewise.
892 * aout-ns32k.c: Likewise.
893 * aout-target.h: Likewise.
894 * aout-tic30.c: Likewise.
895 * aoutf1.h: Likewise.
897 * archive.c: Likewise.
898 * archures.c: Likewise.
899 * bfd-in.h: Likewise.
901 * binary.c: Likewise.
904 * cisco-core.c: Likewise.
905 * coff-a29k.c: Likewise.
906 * coff-alpha.c: Likewise.
907 * coff-arm.c: Likewise.
908 * coff-h8300.c: Likewise.
909 * coff-h8500.c: Likewise.
910 * coff-i386.c: Likewise.
911 * coff-i860.c: Likewise.
912 * coff-i960.c: Likewise.
913 * coff-ia64.c: Likewise.
914 * coff-m68k.c: Likewise.
915 * coff-m88k.c: Likewise.
916 * coff-mcore.c: Likewise.
917 * coff-mips.c: Likewise.
918 * coff-ppc.c: Likewise.
919 * coff-rs6000.c: Likewise.
920 * coff-sh.c: Likewise.
921 * coff-sparc.c: Likewise.
922 * coff-stgo32.c: Likewise.
923 * coff-tic30.c: Likewise.
924 * coff-tic54x.c: Likewise.
925 * coff-tic80.c: Likewise.
926 * coff-w65.c: Likewise.
927 * coff-z8k.c: Likewise.
928 * coff64-rs6000.c: Likewise.
929 * coffcode.h: Likewise.
930 * coffgen.c: Likewise.
931 * cofflink.c: Likewise.
932 * coffswap.h: Likewise.
933 * corefile.c: Likewise.
934 * cpu-arc.c: Likewise.
935 * cpu-h8300.c: Likewise.
936 * cpu-h8500.c: Likewise.
937 * cpu-i960.c: Likewise.
938 * cpu-ia64-opc.c: Likewise.
939 * cpu-ns32k.c: Likewise.
940 * cpu-pdp11.c: Likewise.
941 * cpu-pj.c: Likewise.
942 * cpu-sh.c: Likewise.
943 * cpu-w65.c: Likewise.
944 * cpu-z8k.c: Likewise.
945 * dwarf1.c: Likewise.
946 * dwarf2.c: Likewise.
948 * ecofflink.c: Likewise.
949 * ecoffswap.h: Likewise.
950 * elf-bfd.h: Likewise.
951 * elf-hppa.h: Likewise.
952 * elf-m10200.c: Likewise.
953 * elf-m10300.c: Likewise.
955 * elf32-arc.c: Likewise.
956 * elf32-arm.h: Likewise.
957 * elf32-avr.c: Likewise.
958 * elf32-cris.c: Likewise.
959 * elf32-fr30.c: Likewise.
960 * elf32-gen.c: Likewise.
961 * elf32-h8300.c: Likewise.
962 * elf32-hppa.c: Likewise.
963 * elf32-i370.c: Likewise.
964 * elf32-i386.c: Likewise.
965 * elf32-i860.c: Likewise.
966 * elf32-m32r.c: Likewise.
967 * elf32-m68k.c: Likewise.
968 * elf32-mcore.c: Likewise.
969 * elf32-mips.c: Likewise.
970 * elf32-openrisc.c: Likewise.
971 * elf32-pj.c: Likewise.
972 * elf32-ppc.c: Likewise.
973 * elf32-s390.c: Likewise.
974 * elf32-sh-lin.c: Likewise.
975 * elf32-sh.c: Likewise.
976 * elf32-sparc.c: Likewise.
977 * elf32-v850.c: Likewise.
978 * elf64-alpha.c: Likewise.
979 * elf64-hppa.c: Likewise.
980 * elf64-mips.c: Likewise.
981 * elf64-ppc.c: Likewise.
982 * elf64-s390.c: Likewise.
983 * elf64-sparc.c: Likewise.
984 * elf64-x86-64.c: Likewise.
985 * elfarm-nabi.c: Likewise.
986 * elfcode.h: Likewise.
987 * elfcore.h: Likewise.
988 * elflink.c: Likewise.
989 * elflink.h: Likewise.
990 * elfxx-ia64.c: Likewise.
991 * elfxx-target.h: Likewise.
992 * format.c: Likewise.
994 * hp300hpux.c: Likewise.
995 * hppabsd-core.c: Likewise.
996 * hpux-core.c: Likewise.
997 * i386aout.c: Likewise.
998 * i386dynix.c: Likewise.
999 * i386linux.c: Likewise.
1000 * i386lynx.c: Likewise.
1001 * i386mach3.c: Likewise.
1002 * i386msdos.c: Likewise.
1003 * i386os9k.c: Likewise.
1006 * irix-core.c: Likewise.
1007 * libaout.h: Likewise.
1008 * libbfd-in.h: Likewise.
1009 * libbfd.c: Likewise.
1010 * libcoff-in.h: Likewise.
1011 * libecoff.h: Likewise.
1012 * libieee.h: Likewise.
1013 * libnlm.h: Likewise.
1014 * libpei.h: Likewise.
1015 * libxcoff.h: Likewise.
1016 * linker.c: Likewise.
1017 * lynx-core.c: Likewise.
1018 * m68klinux.c: Likewise.
1019 * merge.c: Likewise.
1020 * mipsbsd.c: Likewise.
1021 * netbsd-core.c: Likewise.
1023 * nlm32-alpha.c: Likewise.
1024 * nlm32-i386.c: Likewise.
1025 * nlm32-ppc.c: Likewise.
1026 * nlm32-sparc.c: Likewise.
1027 * nlmcode.h: Likewise.
1028 * nlmswap.h: Likewise.
1029 * ns32k.h: Likewise.
1030 * oasys.c: Likewise.
1031 * opncls.c: Likewise.
1032 * osf-core.c: Likewise.
1033 * pc532-mach.c: Likewise.
1034 * pdp11.c: Likewise.
1035 * pe-mips.c: Likewise.
1036 * peXXigen.c: Likewise.
1037 * peicode.h: Likewise.
1038 * ppcboot.c: Likewise.
1039 * ptrace-core.c: Likewise.
1040 * reloc.c: Likewise.
1041 * reloc16.c: Likewise.
1042 * riscix.c: Likewise.
1043 * rs6000-core.c: Likewise.
1044 * sco5-core.c: Likewise.
1045 * section.c: Likewise.
1047 * sparclinux.c: Likewise.
1048 * sparclynx.c: Likewise.
1050 * stabs.c: Likewise.
1051 * sunos.c: Likewise.
1053 * targets.c: Likewise.
1054 * tekhex.c: Likewise.
1055 * trad-core.c: Likewise.
1056 * versados.c: Likewise.
1057 * vms-gsd.c: Likewise.
1058 * vms-hdr.c: Likewise.
1059 * vms-misc.c: Likewise.
1060 * vms-tir.c: Likewise.
1063 * xcofflink.c: Likewise.
1064 * bfd-in2.h: Regenerate.
1065 * libbfd.h: Regenerate.
1066 * libcoff.h: Regenerate.
1068 * bfd.c (struct _bfd): Make "where" and "origin" unsigned.
1069 * bfd-in.h (file_ptr): Change from a long int to a bfd_signed_vma.
1070 (ufile_ptr): Define.
1071 (bfd_tell): Return a ufile_ptr.
1072 * libbfd.c (bfd_tell): Likewise.
1073 (bfd_seek): Use bfd_size_type locals. Don't call bfd_set_error
1075 * aix386-core.c: Test != 0 for bfd_seek errors rather than < 0.
1076 * aoutf1.h: Likewise.
1078 * cache.c (bfd_cache_lookup_worker): Guard against abfd->where
1079 larger than unsigned long can represent.
1081 * libbfd.c (bfd_malloc): Take a bfd_size_type arg. Error if
1082 size overflows size_t.
1083 (bfd_realloc): Likewise.
1084 (bfd_zmalloc): Likewise.
1085 * opncls.c (bfd_alloc): Likewise.
1086 (bfd_zalloc): Likewise.
1087 * libbfd-in.h (bfd_malloc, bfd_realloc, bfd_zmalloc): Update.
1088 (bfd_alloc, bfd_zalloc): Update.
1090 * libbfd.c (bfd_get_8): Mask with 0xff in case char is more than
1092 (bfd_get_signed_8): Likewise.
1093 (H_PUT_64, H_PUT_32, H_PUT_16, H_PUT_8,
1094 H_PUT_S64, H_PUT_S32, H_PUT_S16, H_PUT_S8,
1095 H_GET_64, H_GET_32, H_GET_16, H_GET_8,
1096 H_GET_S64, H_GET_S32, H_GET_S16, H_GET_S8): Define and use.
1097 * libaout.h: Likewise define and use here.
1098 * aout-adobe.c: Use H_GET_* and H_PUT_* macros.
1099 * aout-arm.c: Likewise.
1100 * aout-encap.c: Likewise.
1101 * aout-ns32k.c: Likewise.
1102 * aout-tic30.c: Likewise.
1103 * aoutf1.h: Likewise.
1104 * aoutx.h: Likewise.
1106 * coff-alpha.c: Likewise.
1107 * coff-h8300.c: Likewise.
1108 * coff-h8500.c: Likewise.
1109 * coff-i960.c: Likewise.
1110 * coff-ia64.c: Likewise.
1111 * coff-m88k.c: Likewise.
1112 * coff-mips.c: Likewise.
1113 * coff-ppc.c: Likewise.
1114 * coff-rs6000.c: Likewise.
1115 * coff-sh.c: Likewise.
1116 * coff-sparc.c: Likewise.
1117 * coff-stgo32.c: Likewise.
1118 * coff-tic30.c: Likewise.
1119 * coff-tic80.c: Likewise.
1120 * coff-w65.c: Likewise.
1121 * coff-z8k.c: Likewise.
1122 * coff64-rs6000.c: Likewise.
1123 * coffgen.c: Likewise.
1124 * cofflink.c: Likewise.
1125 * coffswap.h: Likewise.
1126 * ecoff.c: Likewise.
1127 * ecoffswap.h: Likewise.
1129 * elf32-mips.c: Likewise.
1130 * elf64-mips.c: Likewise.
1131 * hp300hpux.c: Likewise.
1132 * i386dynix.c: Likewise.
1133 * i386lynx.c: Likewise.
1134 * i386msdos.c: Likewise.
1135 * i386os9k.c: Likewise.
1136 * libpei.h: Likewise.
1137 * nlm32-alpha.c: Likewise.
1138 * nlm32-i386.c: Likewise.
1139 * nlm32-ppc.c: Likewise.
1140 * nlmcode.h: Likewise.
1141 * nlmswap.h: Likewise.
1142 * oasys.c: Likewise.
1143 * pdp11.c: Likewise.
1144 * pe-mips.c: Likewise.
1145 * peXXigen.c: Likewise.
1146 * peicode.h: Likewise.
1147 * riscix.c: Likewise.
1148 * sunos.c: Likewise.
1149 * xcofflink.c: Likewise.
1150 * elfcode.h: (put_word, get_word, put_signed_word, get_signed_word):
1151 Rename to H_PUT_WORD, H_GET_WORD, H_PUT_SIGNED_WORD, H_GET_SIGNED_WORD.
1152 * coff-rs6000.c (PUTWORD, PUTHALF, PUTBYTE): Don't define. Use
1153 equivalent H_PUT_* macro instead.
1154 (GETWORD, GETHALF, GETBYTE): Similarly.
1155 * coff64-rs6000.c (PUTWORD, PUTHALF, PUTBYTE): Likewise.
1156 (GETWORD, GETHALF, GETBYTE): Likewise.
1157 * coffswap.h (PUTWORD, PUTHALF, PUTBYTE): Likewise.
1159 * bfd-in.h (struct orl): Change "pos" to a union.
1160 * archive.c (_bfd_compute_and_write_armap): Use it instead of casts.
1161 (bsd_write_armap): Here too.
1162 (coff_write_armap): And here.
1163 * coff-rs6000.c (xcoff_write_armap_old): And here.
1164 (xcoff_write_one_armap_big): And here.
1165 (xcoff_write_armap_big): And here.
1166 * ecoff.c (_bfd_ecoff_write_armap): And here.
1167 * elf64-mips.c (mips_elf64_write_armap): And here.
1169 * aoutf1.h (sunos_set_arch_mach): Make "mach" param an enum.
1170 * elf-m10300.c (elf_mn10300_mach): Return an unsigned long.
1171 * elf32-h8300.c (elf32_h8_mach): Likewise.
1172 * elf32-mips.c (elf_mips_mach): Likewise.
1173 * sparclynx.c (NAME(lynx,set_arch_mach)): Likewise.
1175 * aix386-core.c (aix386_core_file_p): Remove redundant bfd_release
1177 (aix386_core_vec): Typo fix.
1179 * aout-arm.c: Include libaout.h and aout/aout64.h after N_TXTADDR
1180 etc. to avoid redefined macro warning.
1181 (MY(put_reloc)): Use bfd_vma for "value" rather than long.
1182 (MY(fix_pcrel_26)): Likewise.
1183 * aout-ns32k.c (MY(put_reloc)): Likewise.
1184 * aout-cris.c (MY(swap_ext_reloc_out)): Likewise for r_addend.
1185 * aoutx.h (NAME(aout,swap_ext_reloc_out)): Likewise.
1186 * coff-arm.c (coff_arm_relocate_section): Likewise for my_offset.
1188 * aout-encap.c: Include "file", not <file> for binutils headers.
1189 (encap_object_p): Half baked attempt to fix compile errors in
1190 code dealing with "magic".
1192 * aout-ns32k.c: Include "file", not <file> for binutils headers.
1193 (_bfd_ns32k_relocate_contents): get_data and put_data manipulate
1194 bfd_vma's rather than longs.
1195 * cpu-ns32k.c (ns32k_sign_extend): Delete.
1196 (_bfd_ns32k_get_displacement): Return a bfd_vma, don't pass in offset.
1197 (_bfd_ns32k_get_immediate): Likewise. Add code for 8 byte values,
1199 (_bfd_ns32k_put_displacement): Accept a bfd_vma, don't pass in offset.
1200 Use unsigned comparisons.
1201 (bfd_ns32k_put_immediate): Likewise, and add code for 8 byte values.
1202 (do_ns32k_reloc): get_data and put_data operate on bfd_vma's.
1203 (_bfd_do_ns32k_reloc_contents): Likewise.
1204 * ns32k.h (_bfd_ns32k_get_displacement): Update prototype.
1205 (_bfd_ns32k_get_immediate): Likewise.
1206 (_bfd_ns32k_put_displacement): Likewise.
1207 (_bfd_ns32k_put_immediate): Likewise.
1208 (bfd_reloc_status_type): Likewise.
1210 * aoutx.h (NAME(aout,find_nearest_line)): Rename 'p' to 'colon'
1212 * pdp11.c (NAME(aout,find_nearest_line)): Likewise.
1213 * coff-h8300.c (h8300_reloc16_extra_cases): Remove shadowing "value".
1214 * coff-ppc.c (enum ref_category): Rename "data" to "tocdata" to
1216 (record_toc): Use a bfd_signed_vma for our_toc_offset.
1217 * coffcode.h (coff_write_relocs): Rename "i" to avoid shadowing.
1218 * elf.c (bfd_elf_get_bfd_needed_list): Rename "link" var to avoid
1220 (_bfd_elfcore_strndup): Likewise for "dup".
1221 * elf32-cris.c (cris_elf_relocate_section): "symname" instead of
1222 "name" to avoid shadowing.
1223 * elf32-hppa.c (elf32_hppa_relocate_section): Remove duplicate
1224 definition of "off".
1225 * elf32-i386.c (elf_i386_relocate_section): Likewise.
1226 * elf32-mips.c (_bfd_mips_elf_modify_segment_map): Remove duplicate
1228 (_bfd_mips_elf_final_link): Rename "i" to "j". Remove duplicate
1230 * elf64-x86-64.c (elf64_x86_64_relocate_section): Rename inner "indx"
1232 * elflink.h (elf_link_add_object_symbols): Rename "link" to "shlink"
1234 (elf_link_input_bfd): Likewise.
1235 (elf_bfd_final_link): Remove duplicate innermost "off" var.
1236 * oasys.c (oasys_write_data): Rename innermost "p" to "sym".
1237 * reloc16.c (bfd_coff_reloc16_relax_section): Rename "i" param to
1239 * som.c (som_prep_for_fixups): Rename inner "i" to "j".
1240 * sunos.c (sunos_add_dynamic_symbols): Localise "s" var.
1241 (sunos_write_dynamic_symbol): Remove unused vars.
1242 * syms.c (_bfd_stab_section_find_nearest_line): Remove duplicate
1243 innermost "directory_name" and "file_name" vars.
1244 * tekhex.c (first_phase): Rename local var "type" to "stype".
1245 (tekhex_write_object_contents): Rename innermost "s" to "sym".
1246 * vms-gsd.c (vms_secflag_by_name): Change "size" param to "hassize",
1247 doing comparison at caller.
1248 (vms_esecflag_by_name): Likewise.
1249 * vms-tir.c (etir_sto): Rename innermost "psect" to "psect1".
1250 * xcofflink.c (xcoff_link_input_bfd): Delete duplicate innermost "o".
1251 (xcoff_write_global_symbol): Rename "p" param to "inf".
1253 * cisco-core.c: Add missing prototypes.
1254 (cisco_core_file_failing_command): Add ATTRIBUTE_UNUSED.
1255 (cisco_core_file_failing_signal): Likewise.
1256 (cisco_core_file_matches_executable_p): Likewise.
1257 * hpux-core.c (hpux_core_core_file_failing_signal): Likewise.
1258 * netbsd-core.c (netbsd_core_file_matches_executable_p): Likewise.
1259 * osf-core.c (osf_core_core_file_matches_executable_p): Likewise.
1260 * sco5-core.c (sco5_core_file_matches_executable_p): Likewise.
1262 * coff-arm.c (coff_arm_link_hash_table): Use bfd_size_type for
1263 thumb_glue_size and arm_glue_size.
1264 * elf32-arm.h (elf32_arm_link_hash_table): Likewise here.
1266 * coff64-rs6000.c: Group prototypes together.
1268 * coffcode.h (coff_set_arch_mach): Add ATTRIBUTE_UNUSED.
1269 (buy_and_read): Remove "seek" param. Change "size" to bfd_size_type.
1271 * cpu-arc.c: Add missing prototypes.
1272 * cpu-h8500.c: Likewise.
1273 * cpu-i960.c: Likewise.
1274 * cpu-pj.c: Likewise.
1275 * cpu-sh.c: Likewise.
1276 * cpu-w65.c: Likewise.
1277 * cpu-z8k.c: Likewise.
1278 * elf32-fr30.c: Likewise.
1279 * elf32-h8300.c: Likewise.
1280 * elf32-i370.c: Likewise.
1281 * hpux-core.c: Likewise.
1282 * versados.c: Likewise.
1284 * cpu-h8300.c (bfd_default_scan_num_mach): Don't declare.
1285 * cpu-h8500.c: Likewise.
1286 * cpu-i960.c: Likewise.
1287 * cpu-z8k.c: Likewise.
1289 * cpu-ia64-opc.c: Correct comment.
1291 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Remove unused var.
1293 * elf-bfd.h (elf_size_info): Change count param of write_out_phdrs
1295 (bfd_elf32_write_out_phdrs): Likewise.
1296 (bfd_elf64_write_out_phdrs): Likewise.
1297 (elf_linker_section_pointers): Change addend to bfd_vma.
1298 (_bfd_elf_find_pointer_linker_section): Likewise.
1299 (_bfd_elfcore_make_pseudosection): Change size param to size_t and
1300 filepos to unsigned file_ptr.
1301 (_bfd_elfcore_strndup): Change max param to size_t.
1302 * elf.c (_bfd_elfcore_make_pseudosection): As above.
1303 (_bfd_elfcore_strndup): Likewise.
1304 (_bfd_elf_find_pointer_linker_section): Likewise.
1306 * elf-hppa.h (elf_hppa_relocate_insn): Return an int, and change
1307 insn and sym_value to ints.
1309 * elf.c (elf_read): Make "offset" param a file_ptr, "size" a
1311 (elfcore_read_notes): Likewise.
1313 * elf32-arm.h (elf32_arm_final_link_relocate): Change sym_flags
1314 param from unsigned char to int.
1315 (elf32_arm_relocate_section): If USE_REL, cast "rel" appropriately
1316 for info_to_howto call.
1317 (add_dynamic_entry): Define macro.
1318 (elf32_arm_size_dynamic_sections): Use add_dynamic_entry.
1320 * elf32-cris.c (add_dynamic_entry): Define macro.
1321 (elf_cris_size_dynamic_sections): Use add_dynamic_entry.
1323 * elf32-h8300.c (elf32_h8_final_write_processing): Make static.
1324 (elf32_h8_object_p): Likewise.
1325 (elf32_h8_merge_private_bfd_data): Likewise.
1326 (elf32_h8_relax_section): Cast gap to int so signed comparisons work.
1328 * elf32-hppa.c (add_dynamic_entry): Define macro.
1329 (elf32_hppa_size_dynamic_sections): Use it.
1330 * elf32-i370.c (add_dynamic_entry): Define macro.
1331 (i370_elf_size_dynamic_sections): Use it.
1332 (i370_noop): Make static.
1333 * elf32-i386.c (add_dynamic_entry): Define macro.
1334 (elf_i386_size_dynamic_sections): Use it.
1335 * elf32-m68k.c (add_dynamic_entry): Define macro.
1336 (elf_m68k_size_dynamic_sections): Use it.
1337 * elf32-ppc.c (add_dynamic_entry): Define macro.
1338 (ppc_elf_size_dynamic_sections): Use it.
1339 * elf32-s390.c (add_dynamic_entry): Define macro.
1340 (elf_s390_size_dynamic_sections): Use it.
1341 * elf64-alpha.c (add_dynamic_entry): Define macro.
1342 (elf64_alpha_size_dynamic_sections): Use it.
1343 * elf64-hppa.c (add_dynamic_entry): Define macro.
1344 (elf64_hppa_size_dynamic_sections): Use it.
1345 * elf64-ppc.c (add_dynamic_entry): Define macro.
1346 (ppc64_elf_size_dynamic_sections): Use it.
1347 * elf64-s390.c (add_dynamic_entry): Define macro.
1348 (elf_s390_size_dynamic_sections): Use it.
1349 * elf64-sparc.c (add_dynamic_entry): Define macro.
1350 (sparc64_elf_size_dynamic_sections): Use it.
1351 * elf64-x86-64.c (add_dynamic_entry): Define macro.
1352 (elf64_x86_64_size_dynamic_sections): Use it.
1353 * elfxx-ia64.c (add_dynamic_entry): Define macro.
1354 (elfNN_ia64_size_dynamic_sections): Use it.
1356 * elf32-v850.c (SEXT24): Modify to avoid signed/unsigned warning.
1357 (v850_elf_perform_relocation): Make "r_type" param unsigned.
1359 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Just return
1360 false if the first malloc fails rather than going via error_return.
1362 * elf64-sparc.c (sparc64_elf_plt_entry_offset): Use a bfd_vma for
1364 (sparc64_elf_plt_ptr_offset): Likewise, and for "max" param too.
1366 * elflink.h (elf_link_input_bfd): s/ingored/ignored/ in error message.
1368 * elfxx-ia64.c (global_sym_index): Return a long.
1370 * ieee.c (get_symbol): Use int rather than char param.
1371 (ieee_slurp_sections): Move "section" var to inner blocks.
1372 (copy_expression): Don't init "value" to zero or worry about
1373 clearing to zero after using.
1374 (ieee_write_debug_part): Rename "output_buffer" to "obuff" to avoid
1377 * ihex.c (ihex_write_record): Make "count" var a size_t, "addr" an
1380 * libbfd-in.h (BFD_ALIGN): Add cast to avoid signed/unsigned warning.
1381 (bfd_write_bigendian_4byte_int): Pass an unsigned int value param.
1383 * mipsbsd.c (mips_fix_jmp_addr): Add "error_message" param.
1385 * pc532-mach.c (MYNSX): Delete.
1386 (ns32kaout_bfd_reloc_type_lookup): Define prototype without MYNSX.
1387 (write_object_contents): Correct prototype.
1389 * peicode.h (pe_ILF_build_a_bfd): Use an unsigned int param rather
1390 than unsigned short.
1392 * section.c (bfd_set_section_contents): Remove redundant
1393 "offset < 0" test. Check that "count" doesn't overflow size_t.
1394 (bfd_get_section_contents): Likewise.
1396 * som.c (som_fixup_formats): Add missing braces.
1397 (som_reloc_addend): Pass a bfd_vma for "addend".
1399 * srec.c (srec_write_record): Pass "type" as an unsigned int.
1400 (srec_write_symbols): Remove an unnecessary var.
1402 * targets.c (_bfd_target_vector): Sort entries. Sort externs
1404 * configure.in: Sort to match. Bump version number.
1405 * configure: Regenerate.
1407 * tekhex.c (move_section_contents): Assert offset == 0.
1409 * versados.c (new_symbol_string): Constify arg.
1410 (process_esd): Use bfd_und_section_ptr rather than &bfd_und_section.
1411 (versados_get_symbol_info): Make static.
1412 (versados_print_symbol): Likewise.
1413 (versados_get_reloc_upper_bound): Likewise.
1414 (versados_canonicalize_reloc): Likewise.
1416 2001-09-18 Nick Clifton <nickc@cambridge.redhat.com>
1418 * elflink.h (elf_link_input_bfd): Fix typo in error message.
1420 2001-09-17 H.J. Lu <hjl@gnu.org>
1422 * dwarf1.c (parse_die): Take a new arg for the end of the
1423 section. Return false if die is beyond the section.
1424 (parse_functions_in_unit): Pass the end of the section to
1426 (_bfd_dwarf1_find_nearest_line): Likewise.
1428 2001-09-14 Michael Rauch <mrauch@netbsd.org>
1430 * elf32-sparc.c (elf32_sparc_relocate_section): Treat R_SPARC_UA32
1431 just like R_SPARC_32.
1433 2001-09-14 Kevin Lo <kevlo@openbsd.org>
1435 * configure.bfd: Add arm-openbsd target.
1437 2001-09-14 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1439 * config.bfd: Change machine triplets from mips*el*-* to mips*el-*.
1440 Add support for mips64.
1442 2001-09-13 Alexandre Oliva <aoliva@redhat.com>
1444 * elf32-openrisc.c (ELF_MACHINE_ALT1): Define as EM_OPENRISC_OLD.
1446 2001-09-12 Alexandre Oliva <aoliva@redhat.com>
1448 * elf.c (prep_headers): Get the machine code from the elf
1450 * elf-m10200.c (ELF_MACHINE_CODE): Redefine to EM_MN10200.
1451 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_MN10200.
1452 * elf-m10300.c (ELF_MACHINE_CODE): Redefine to EM_MN10300.
1453 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_MN10300.
1454 * elf-arc.c (arc_elf_final_write_processing): Don't override
1455 e_machine, it's now properly set in prep_headers.
1456 * elf32-avr.c (elf32_avr_object_p): Accept both EM_AVR and
1458 (ELF_MACHINE_ALT1): Define to EM_AVR_OLD.
1459 * elf-d10v.c (ELF_MACHINE_CODE): Redefine to EM_D10V.
1460 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_D10V.
1461 * elf-d30v.c (ELF_MACHINE_CODE): Redefine to EM_D30V.
1462 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_D30V.
1463 * elf-fr30.c (ELF_MACHINE_CODE): Redefine to EM_FR30.
1464 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_FR30.
1465 * elf-m32r.c (ELF_MACHINE_CODE): Redefine to EM_M32R.
1466 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_M32R.
1467 * elf32-pj.c (ELF_MACHINE_ALT1): DEfine to EM_PJ_OLD.
1468 * elf-v850.c (ELF_MACHINE_CODE): Redefine to EM_V850.
1469 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_V850.
1471 2001-09-11 Richard Henderson <rth@redhat.com>
1473 * elf64-alpha.c (elf64_alpha_section_flags): New.
1474 (elf64_alpha_fake_sections): Map SEC_SMALL_DATA to SHF_ALPHA_GPREL.
1476 2001-09-11 Richard Henderson <rth@redhat.com>
1478 * elf64-alpha.c (elf64_alpha_relocate_section): Do not
1479 apply HINT relocations against dynamic symbols.
1481 2001-09-11 H.J. Lu <hjl@gnu.org>
1483 * linker.c (link_action): Change COMMON_ROW\defw from CREF to COM.
1485 2001-09-09 Richard Henderson <rth@redhat.com>
1487 * elf64-alpha.c: Delete all unused ERIC_neverdef and rth_notdef code.
1489 * elf64-alpha.c (elf64_alpha_relax_with_lituse): Nop out gpdisp
1490 following a call to a near function.
1492 2001-09-08 Richard Henderson <rth@redhat.com>
1494 * elf64-alpha.c (elf64_alpha_relocate_section): Soft fail
1495 relocation errors. Fail gp-relative relocations against
1498 2001-09-08 Alan Modra <amodra@bigpond.net.au>
1500 * elf32-i386.c (elf_i386_relocate_section): Check !DEF_REGULAR
1501 as well as DEF_DYNAMIC in test for avoided copy relocs.
1502 (allocate_plt_and_got_and_discard_relocs): Likewise.
1503 * elf32-hppa.c (elf_i386_relocate_section): Likewise.
1504 (allocate_plt_and_got_and_discard_relocs): Likewise.
1506 2001-09-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1508 * elf32-mips.c (mips_elf_calculate_relocation): Fix overflow handling
1511 2001-09-06 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1513 * elf64-mips.c (mips_elf64_howto_table_rel): Fix relocation HOWTO
1515 (mips_elf64_howto_table_rel): Likewise.
1517 2001-09-05 Tom Rix <trix@redhat.com>
1519 * xcofflink.c (bfd_xcoff_import_symbol): Handle import file XMC_XO
1520 and syscall symbols.
1521 (write_global_symbol) : Same.
1522 (bfd_xcoff_export_symbol): Remove unused syscall param.
1523 * libxcoff.h: Change prototype of bfd_xcoff_export symbol and
1524 bfd_xcoff_import_symbol.
1526 * bfd-in2.h : Regenerate.
1528 2001-09-04 Richard Henderson <rth@redhat.com>
1530 * elf64-alpha.c (SKIP_HOWTO): New.
1531 (elf64_alpha_howto_table): Use it to remove dead ECOFF relocs.
1532 Fix sizes of 16-bit mem format relocs.
1533 (elf64_alpha_reloc_map): Update to match.
1534 (elf64_alpha_relax_with_lituse): Use GPREL16 as appropriate.
1535 (elf64_alpha_relax_without_lituse): Likewise.
1536 (elf64_alpha_check_relocs): Handle GPREL16.
1537 (elf64_alpha_relocate_section): Likewise.
1538 * reloc.c (BFD_RELOC_ALPHA_USER_*): Remove.
1539 (BFD_RELOC_ALPHA_GPREL_HI16, BFD_RELOC_ALPHA_GPREL_LO16): New.
1540 * bfd-in2.h, libbfd.h: Rebuild.
1542 2001-09-04 Jeff Law <law@redhat.com>
1544 * elf32-h8300.c (elf32_h8_relax_section): New function.
1545 (elf32_h8_relax_delete_bytes): Likewise.
1546 (elf32_h8_symbol_address_p): Likewise.
1547 (elf32_h8_get_relocated_section_contents): Likewise.
1548 (bfd_elf32_bfd_relax_section): Define.
1549 (bfd_elf32_bfd_get_relocated_section_contents): Likewise.
1551 * elf32-h8300.c (special): New function.
1552 (h8_elf_howto_table): Use it for SPECIAL_FUNCTION field in
1554 (elf32_h8_final_link_relocate): Treat R_H8_DIR24A8 like 32bit
1555 relocations. Fix problems with the true 24bit reloc R_H8_DIR24R8.
1556 Fix minor problems with 8bit and 16bit PC relative relocations.
1558 2001-09-01 Andreas Jaeger <aj@suse.de>
1560 * vms-tir.c: Add missing prototypes.
1561 * vms-hdr.c: Likewise.
1562 * vms-gsd.c: Likewise.
1563 * vms-misc.c: Likewise.
1565 2001-08-31 H.J. Lu <hjl@gnu.org>
1567 * elf32-mips.c (_bfd_mips_elf_check_relocs): Report filename
1568 with bad relocation.
1570 2001-08-31 Eric Christopher <echristo@redhat.com>
1571 Jason Eckhardt <jle@redhat.com>
1573 * bfd/archures.c: Add mipsisa32 and mipsisa64. Remove mips32,
1574 mips32_4k and mips64.
1575 * bfd/aoutx.h: Remove bfd_mach_mips32, bfd_mach_mips32_4k,
1576 bfd_mach_mips64. Add bfd_mach_mipsisa32, bfd_mach_mipsisa64.
1577 * bfd/cpu-mips.c: Ditto.
1578 * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing): Ditto.
1579 * bfd/bfd-in2.h: Regenerate.
1581 2001-08-31 Jakub Jelinek <jakub@redhat.com>
1583 * elf64-alpha.c (elf64_alpha_relocate_section): Duplicate memory
1584 value into R_ALPHA_RELATIVE's addend.
1585 (elf64_alpha_finish_dynamic_symbol): Likewise.
1587 2001-08-31 Nick Clifton <nickc@cambridge.redhat.com>
1589 * elf32-arm.h (elf32_arm_relocate_section): Do not rightshift
1590 recomputed addend during relocatable link if not USE_REL.
1592 * elflink.h (elf_gc_propagate_vtable_entries_used): Fix off-by-one
1595 2001-08-30 H.J. Lu <hjl@gnu.org>
1597 * elf32-mips.c (mips_elf_calculate_relocation): Revert the last
1599 (_bfd_mips_elf_adjust_dynamic_symbol): Allocate dynamic
1600 relocations for weak definitions.
1602 2001-08-30 H.J. Lu <hjl@gnu.org>
1604 * Makefile.am (BFD32_BACKENDS): Add elf32-h8300.lo.
1605 (BFD32_BACKENDS_CFILES): Add elf32-h8300.c.
1606 * Makefile.in: Rebuild.
1608 2001-08-30 H.J. Lu <hjl@gnu.org>
1610 * elf32-mips.c (mips_elf_calculate_relocation): Don't create
1611 dynamic relocation for undefined weak symbols when creating
1612 executables. Check h->root.root.type, instead of h->root.type.
1614 2001-08-29 Joel Sherrill <joel@OARcorp.com>
1616 * config.bfd (i[3456]86-*-rtems*, m68*-*-rtems*): Change
1617 default from coff to elf.
1619 2001-08-29 Jeff Law <law@redhat.com>
1621 * elf32-h8300.c (h8_elf_howto_table): Add new PC relative
1623 (h8_reloc_map): Similarly.
1624 (elf32_h8_final_link_relocate): Remove incorrect overflow tests.
1625 Add support for PC relative relocations.
1627 * elf32-h8300.c: Put all prototypes together.
1628 (elf32_h8_info_to_howto): Parameter elf_reloc is used.
1629 (elf32_h8_final_link_relocate): New function for linker.
1630 (elf32_h8_relocate_section): Similarly.
1631 (elf_backend_relocate_section): Define.
1633 * cpu-h8300.c (h8300_scan, compatible): Prototype.
1634 (h8300_scan): Handle architecture:machine encodings typically
1635 found in linker scripts.
1636 * elf.c (prep_headers): Do not try to do H8 machine recognition
1638 * elf32-h8300.c: Add some missing prototypes.
1639 (elf32_h8_mach, elf32_h8_final_write_processing): New functions.
1640 (elf32_h8_object_p): Similarly.
1642 2001-08-29 Tom Rix <trix@redhat.com>
1644 * xcofflink.c (xcoff_link_add_symbols): Fix XTY_LD symbol that
1645 does not follow a XTY_SD.
1647 2001-08-29 Alan Modra <amodra@bigpond.net.au>
1649 * targmatch.sed: Delete case statements.
1650 * config.bfd <powerpc-*-aix* entry>: Select 64 bit xcoff for
1653 Wed Aug 29 02:27:36 2001 J"orn Rennecke <amylaar@redhat.com>
1655 * Makefile.am (elf32-h8300.lo): New target.
1656 * config.bfd (h8300*-*-elf): New case.
1657 * configure.in (bfd_elf32_h8300_vec): New case.
1658 * elf.c (prep_headers): Add case for bfd_arch_h8300.
1659 * reloc.c (BFD_RELOC_H8_DIR16A8): New relocation.
1660 (BFD_RELOC_H8_DIR16R8, BFD_RELOC_H8_DIR24A8): Likewise.
1661 (BFD_RELOC_H8_DIR24R8, BFD_RELOC_H8_DIR32A16): Likewise.
1662 * targets.c (bfd_target bfd_elf32_h8300_vec): New extern declaration.
1663 * elf32-h8300.c: New file.
1664 * Makefile.in, bfd-in2.h, libbfd.h, configure: Regenerated.
1666 2001-08-28 Nick Clifton <nickc@cambridge.redhat.com>
1668 * sparclynx.c: Add missing prototypes.
1669 * coff-mcore.c: Add missing prototypes.
1670 * elf32-pj.c: Add missing prototypes.
1671 * nlm32-sparc.c: Add missing prototypes.
1672 * oasys.c: Add missing prototypes.
1673 * pdp11.c: Add missing prototypes.
1674 * pe-mips.c: Add missing prototypes.
1675 * riscix.c: Add missing prototypes.
1677 2001-08-27 Daniel Jacobowitz <drow@mvista.com>
1679 * elf32-i386.c: Add missing prototypes.
1680 * elf32-ppc.c: Likewise.
1681 * elf32-sh-lin.c: Likewise.
1682 * elfarm-nabi.c: Likewise.
1684 2001-08-27 Daniel Jacobowitz <drow@mvista.com>
1686 * elf32-i386.c (elf_i386_grok_prstatus): New function.
1687 (elf_i386_grok_psinfo): New function.
1688 (elf_backend_grok_prstatus): Define.
1689 (elf_backend_grok_psinfo): Likewise.
1690 * elf32-ppc.c (ppc_elf_grok_prstatus): New function.
1691 (ppc_elf_grok_psinfo): New function.
1692 (elf_backend_grok_prstatus): Define.
1693 (elf_backend_grok_psinfo): Likewise.
1694 * elf32-sh-lin.c (elf32_shlin_grok_prstatus): New function.
1695 (elf32_shlin_grok_psinfo): New function.
1696 (elf_backend_grok_prstatus): Define.
1697 (elf_backend_grok_psinfo): Likewise.
1698 * elfarm-nabi.c (elf32_arm_nabi_grok_prstatus): New function.
1699 (elf32_arm_nabi_grok_psinfo): New function.
1700 (elf_backend_grok_prstatus): Define.
1701 (elf_backend_grok_psinfo): Likewise.
1703 2001-08-27 H.J. Lu <hjl@gnu.org>
1705 * elf32-mips.c (mips_elf_create_dynamic_relocation): Add more
1707 (mips_elf_calculate_relocation): Create dynamic relocation for
1708 symbols with weak definition or the ELF_LINK_HASH_DEF_REGULAR
1711 2001-08-27 H.J. Lu <hjl@gnu.org>
1713 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Add prototype.
1714 (_bfd_mips_elf_copy_indirect_symbol): Likewise.
1715 (_bfd_elf32_mips_grok_prstatus): Likewise.
1716 (_bfd_elf32_mips_grok_psinfo): Likewise.
1717 (_bfd_mips_elf_hide_symbol): Make it static and cast to
1718 `struct mips_elf_link_hash_entry *'.
1719 (_bfd_mips_elf_copy_indirect_symbol): Make it static.
1721 2001-08-27 Nick Clifton <nickc@cambridge.redhat.com>
1723 * mipsbsd.c: Add missing prototypes.
1724 * hp300hpux.c: Add missing prototypes.
1725 * i386aout.c: Add missing prototypes.
1726 * i386lynx.c: Add missing prototypes.
1727 * i386mach3.c: Add missing prototypes.
1728 * i386msdos.c: Add missing prototypes.
1729 * i386os9k.c: Add missing prototypes.
1731 2001-08-27 Linus Nordberg <linus@swox.se>
1732 Torbjorn Granlund <tege@swox.com>
1733 Staffan Ulfberg <staffanu@swox.se>
1734 Alan Modra <amodra@bigpond.net.au>
1736 * config.bfd: Add powerpc64 target. Add powerpc64 vectors to
1737 targ64_selvecs for 32 bit powerpc targets.
1738 * Makefile.am (BFD64_BACKENDS): Add elf64-ppc.lo.
1739 (BFD64_BACKENDS_CFILES): Add elf64-ppc.c.
1741 * Makefile.in: Regenerate.
1742 * configure.in: Add elf64_powerpc vecs.
1743 * configure: Regenerate.
1744 * cpu-powerpc.c: Default to bfd_mach_ppc_620 entry for 64 bit.
1745 * elf.c (prep_headers): EM_PPC64 for 64 bit ppc elf target.
1746 * targets.c: Add bfd_elf64_powerpc_vec and bfd_elf64_powerpcle_vec.
1747 * elf64-ppc.c: New file.
1748 * reloc.c: Add powerpc64 relocs.
1749 * libbfd.h: Regenerate.
1750 * bfd-in2.h: Regenerate.
1752 2001-08-27 Andreas Schwab <schwab@suse.de>
1754 * elf32-m68k.c (elf32_m68k_check_relocs): Set DF_TEXTREL if the
1755 reloc is against read-only section.
1756 (elf32_m68k_size_dynamic_sections): Use DF_TEXTREL flag instead of
1757 looking up section names for DT_TEXTREL.
1758 (elf32_m68k_reloc_type_class): New function.
1759 (elf_backend_reloc_type_class): Define.
1761 2001-08-27 Andreas Jaeger <aj@suse.de>
1763 * elf64-s390.c (elf_s390_check_relocs): Set DF_TEXTREL if the
1764 reloc is against read-only section.
1765 (elf_s390_size_dynamic_sections): Use DF_TEXTREL flag instead of
1766 looking up section names for DT_TEXTREL.
1767 (elf_s390_reloc_type_class): New.
1768 (elf_backend_reloc_type_class): Define.
1770 * elf32-s390.c (elf_s390_check_relocs): Set DF_TEXTREL if the
1771 reloc is against read-only section.
1772 (elf_s390_size_dynamic_sections): Use DF_TEXTREL flag instead of
1773 looking up section names for DT_TEXTREL.
1774 (elf_s390_reloc_type_class): New.
1775 (elf_backend_reloc_type_class): Define.
1777 * elf32-ppc.c (ppc_elf_check_relocs): Set DF_TEXTREL if the reloc
1778 is against read-only section.
1779 (ppc_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
1780 looking up section names for DT_TEXTREL.
1781 (ppc_elf_reloc_type_class): New.
1782 (elf_backend_reloc_type_class): Define.
1784 2001-08-26 Andreas Jaeger <aj@suse.de>
1786 * elf32-cris.c (cris_elf_check_relocs): Set DF_TEXTREL if the
1787 reloc is against read-only section.
1788 (elf_cris_size_dynamic_sections): Use DF_TEXTREL flag instead of
1789 looking up section names for DT_TEXTREL.
1790 (elf_cris_reloc_type_class): New.
1791 (elf_backend_reloc_type_class): Define.
1793 * elf32-sh.c (sh_elf_check_relocs): Set DF_TEXTREL if the reloc is
1794 against read-only section.
1795 (elf_backend_reloc_type_class): Define.
1796 (sh_elf_reloc_type_class): New.
1797 (sh_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
1798 looking up section names for DT_TEXTREL.
1800 * elf32-arm.h (elf32_arm_check_relocs): Set DF_TEXTREL if the
1801 reloc is against read-only section.
1802 (elf32_arm_size_dynamic_sections): Use DF_TEXTREL flag instead of
1803 looking up section names for DT_TEXTREL.
1804 (elf32_arm_reloc_type_class): New.
1805 (elf_backend_reloc_type_class): Define.
1807 2001-08-25 Andreas Jaeger <aj@suse.de>
1809 * oasys.c: Add missing prototypes.
1811 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Add unused
1812 attribute for parameter.
1813 * elf.c (_bfd_elf_reloc_type_class): Likewise.
1815 * versados.c (get_4): Make static.
1816 (get_10): Make static.
1817 Add missing prototypes.
1818 (process_esd): Fix call to versados_new_symbol.
1820 2001-08-25 Nick Clifton <nickc@cambridge.redhat.com>
1822 * coff-a29k.c: Add missing prototypes.
1823 * coff-apollo.c: Add missing prototypes.
1824 * coff-arm.c: Add missing prototypes.
1825 * coff-i860.c: Add missing prototypes.
1826 * coff-rs6000.c: Add missing prototypes.
1827 * coff-tic80.c: Add missing prototypes.
1828 * elf-m10200.c: Add missing prototypes.
1829 * elf-m10300.c: Add missing prototypes.
1830 * elf32-arm.h: Add missing prototypes.
1831 * elf32-d10v.c: Add missing prototypes.
1832 * elf32-m32r.c: Add missing prototypes.
1833 * elf32-mcore.c: Add missing prototypes.
1834 * elf32-openrisc.c: Add missing prototypes.
1835 * elf32-sh.c: Add missing prototypes.
1836 * elf32-sparc.c: Add missing prototypes.
1837 * elf32-v850.c: Add missing prototypes.
1838 * elfarm-nabi.c: Add missing prototypes.
1839 * elfarm-oabi.c: Add missing prototypes.
1841 2001-08-25 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1843 * elf32-mips.c (elf_mips_abi_name): Return the right ABI string for
1844 E_MIPS_ABI_O64 and E_MIPS_ABI_EABI64
1846 2001-08-24 H.J. Lu <hjl@gnu.org>
1848 * elf.c (_bfd_elf_merge_sections): Fail if not using an ELF
1851 2001-08-24 Nick Clifton <nickc@cambridge.redhat.com>
1853 * elf-bfd.h (elf_hash_table): Revert definition.
1854 (is_elf_hash_table): New macro.
1855 * elflink.h (elf_link_add_object_symbols): Test
1856 is_elf_hash_table before accessing ELF only fields in hash
1858 (elf_link_create_dynamic_sections): Fail if not using an ELF
1860 (elf_add_dynamic_entry): Fail if not using an ELF hash
1862 (elf_link_record_local_dynamic_symbol): Fail if not using an
1864 (size_dynamic_sections): Fail if not using an ELF hash
1866 (elf_adjust_dynamic_symbol): Fail if not using an ELF
1868 (elf_bfd_final_link): Fail if not using an ELF hash
1871 2001-08-24 H.J. Lu <hjl@gnu.org>
1873 * elf-bfd.h (elf_hash_table): Return NULL if the linker hash
1874 table is not an ELF linker hash table.
1876 * elf.c (_bfd_elf_link_hash_table_init): Set the linker hash
1877 table type to bfd_link_elf_hash_table.
1879 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_create): Revert
1882 * linker.c (_bfd_link_hash_table_init): Set the linker hash
1883 table type to bfd_link_generic_hash_table.
1885 2001-08-24 Alexandre Oliva <aoliva@redhat.com>
1887 * bfd.c (bfd_alt_mach_code): New function.
1888 * bfd-in2.h: Rebuilt.
1890 2001-08-24 Alexandre Oliva <aoliva@redhat.com>
1892 * elf-m10300.c (mn10300_elf_relocate_section): Test the right
1893 `type' field in the hash entry when deciding whether to follow a
1896 2001-08-24 Jakub Jelinek <jakub@redhat.com>
1898 * elflink.h (elf_link_sort_cmp1): Sort RELATIVE relocs first, not
1900 (elf_link_sort_relocs): Adjust accordingly.
1902 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Add reltext flag.
1903 (elf64_alpha_check_relocs): Set it if section this reloc is against
1904 is read-only. Set DF_TEXTREL if a RELATIVE reloc is needed against
1906 (elf64_alpha_calc_dynrel_sizes): Set DF_TEXTREL flag if relocation
1907 is is against read-only section.
1908 (elf64_alpha_size_dynamic_sections): Use DF_TEXTREL flag, don't
1909 check section names.
1910 (elf64_alpha_reloc_type_class): New.
1911 (elf_backend_reloc_type_class): Define.
1913 2001-08-24 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1915 * linker.c (_bfd_generic_link_add_archive_symbols): Replace alloca()
1918 2001-08-23 Andreas Jaeger <aj@suse.de>
1920 * elf64-x86-64.c (elf64_x86_64_check_relocs): Set DF_TEXTREL if
1921 the reloc is against read-only section.
1922 (elf64_x86_64_size_dynamic_sections): Use DF_TEXTREL flag instead
1923 of looking up section names for DT_TEXTREL.
1924 (elf64_x86_64_reloc_type_class): New.
1925 (elf_backend_reloc_type_class): Define.
1927 2001-08-23 H.J. Lu <hjl@gnu.org>
1929 * syms.c (bfd_print_symbol_vandf): Add abfd to arg.
1930 * bfd-in2.h (bfd_print_symbol_vandf): Regenerated.
1932 * aoutx.h (NAME(aout,print_symbol)): Pass abfd to
1933 bfd_print_symbol_vandf.
1934 * coffgen.c (coff_print_symbol): Likewise.
1935 * elf.c (bfd_elf_print_symbol): Likewise.
1936 * ieee.c (ieee_print_symbol): Likewise.
1937 * nlmcode.h (nlm_print_symbol): Likewise.
1938 * oasys.c (oasys_print_symbol): Likewise.
1939 * pdp11.c (NAME(aout,print_symbol)): Likewise.
1940 * som.c (som_print_symbol): Likewise.
1941 * srec.c (srec_print_symbol): Likewise.
1942 * tekhex.c (tekhex_print_symbol): Likewise.
1943 * versados.c (versados_print_symbol): Likewise.
1944 * vms.c (vms_print_symbol): Likewise.
1946 * elf.c (_bfd_elf_print_private_bfd_data): Replace fprintf_vma
1947 with bfd_fprintf_vma.
1948 (bfd_elf_print_symbol): Likewise.
1949 * syms.c (bfd_print_symbol_vandf): Likewise.
1951 2001-08-23 Nick Clifton <nickc@cambridge.redhat.com>
1953 * aoutf1.h (sunos_write_object_contents): Silence compile time
1955 * libaout.h (N_SET_DYNAMIC): Silence compile time warning.
1957 * bout.c: Add missing function prototypes. Fix formatting.
1958 * coff-z8k.c: Add missing function prototypes. Fix formatting.
1959 * coff-w65.c: Add missing function prototypes. Fix formatting.
1960 * coff-h8500.c: Add missing function prototypes. Fix formatting.
1961 * coff-h8300.c: Add missing function prototypes. Fix formatting.
1962 * coff-tic54x.c: Add missing function prototypes. Fix formatting.
1963 * coff-tic30.c: Add missing function prototypes. Fix formatting.
1964 * coff-m68k.c: Add missing function prototypes. Fix formatting.
1965 * coff-rs6000.c: Add missing function prototypes. Fix formatting.
1966 * coff-sh.c: Add missing function prototypes. Fix formatting.
1968 2001-08-23 Jakub Jelinek <jakub@redhat.com>
1970 * elf-bfd.h (enum elf_reloc_type_class): New.
1971 (struct elf_backend_data): Add elf_backend_reloc_type_class.
1972 (_bfd_elf_reloc_type_class): New.
1973 * elfxx-target.h (elf_backend_reloc_type_class): Define.
1974 (elfNN_bed): Add elf_backend_reloc_type_class.
1975 * elf.c (_bfd_elf_reloc_type_class): New.
1976 * elf32-i386.c (elf_i386_check_relocs): Set DF_TEXTREL if the reloc
1977 is against read-only section.
1978 (elf_i386_size_dynamic_sections): Use DF_TEXTREL flag instead of
1979 looking up section names for DT_TEXTREL.
1980 (elf_i386_reloc_type_class): New.
1981 (elf_backend_reloc_type_class): Define.
1982 * elf32-sparc.c (elf32_sparc_check_relocs): Set DF_TEXTREL if the
1983 reloc is against read-only section.
1984 (elf32_sparc_size_dynamic_sections): Use DF_TEXTREL flag instead of
1985 looking up section names for DT_TEXTREL.
1986 (elf32_sparc_reloc_type_class): New.
1987 (elf_backend_reloc_type_class): Define.
1988 * elf64-sparc.c (sparc64_elf_check_relocs): Set DF_TEXTREL if the
1989 reloc is against read-only section.
1990 (sparc64_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
1991 looking up section names for DT_TEXTREL.
1992 (sparc64_elf_reloc_type_class): New.
1993 (elf_backend_reloc_type_class): Define.
1994 * elfxx-ia64.c (struct elfNN_ia64_link_hash_table): Add reltext field.
1995 (elfNN_ia64_hash_table_create): Clear ia64_info.
1996 (get_reloc_section): Set DF_TEXTREL if the reloc is against read-only
1998 (elfNN_ia64_size_dynamic_sections): Use ia64_info->reltext flag
1999 instead of looking up section names for DT_TEXTREL.
2000 (elfNN_ia64_reloc_type_class): New.
2001 (elf_backend_reloc_type_class): Define.
2002 * elflink.h (size_dynamic_sections): Add spare DT_NULL tags.
2003 (struct elf_link_sort_rela): New.
2004 (elf_link_sort_cmp1, elf_link_sort_cmp2, elf_link_sort_relocs): New.
2005 (elf_bfd_final_link): Call elf_link_sort_relocs.
2006 Convert one spare DT_NULL into DT_RELCOUNT resp. DT_RELACOUNT if
2009 2001-08-23 Nick Clifton <nickc@cambridge.redhat.com>
2011 * configure.in (x86-bsdi): No corefile support.
2012 * configure: Regenerate.
2014 2001-08-22 Nick Clifton <nickc@cambridge.redhat.com>
2016 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Add missing
2019 2001-08-21 Mark Elbrecht <snowball3@bigfoot.com>
2021 * coff-go32.c: Make DWARF2 sections use an alignment of 0. Set
2022 the alignment of dwarf2 linkonce sections to 0.
2023 * coff-sto32.c: Likewise.
2025 2001-08-20 Andreas Jaeger <aj@suse.de>
2027 * coff-sparc.c: Add missing prototypes.
2028 * elf32-s390.c: Likewise.
2029 * elf32-i960.c: Likewise.
2030 * aout-target.h: Likewise.
2032 2001-08-20 H.J. Lu <hjl@gnu.org>
2034 * elf-bfd.h (elf_obj_tdata): Add num_section_syms.
2035 (elf_num_section_syms): New for num_section_syms.
2037 * elf.c (elf_map_symbols): Set num_section_syms.
2038 (_bfd_elf_symbol_from_bfd_symbol): Check num_section_syms for
2039 the section symbol index.
2041 2001-08-20 Nick Clifton <nickc@cambridge.redhat.com>
2043 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_create): Never
2044 select the generic has table creator. All elf backends need elf
2045 specific fields in the hash table.
2047 2001-08-20 Alan Modra <amodra@bigpond.net.au>
2049 * archive.c (offsetof): Remove define.
2052 * sysdep.h (offsetof): Define.
2054 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2056 * bfd.c (bfd_get_gp_size): Return an unsigned int.
2057 (bfd_set_gp_size): Make param unsigned.
2058 * bfd-in2.h: Regenerate.
2059 * elf32-ppc.c (ppc_elf_add_symbol_hook): Use elf_gp_size rather
2060 than calling bfd_get_gp_size.
2061 * elf64-alpha.c (elf64_alpha_add_symbol_hook): Likewise.
2062 * elfxx-ia64.c (elfNN_ia64_add_symbol_hook): Likewise.
2064 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2066 * linker.c (default_fill_link_order): Handle four byte fill value.
2068 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2070 * elf64-sparc.c (sparc64_elf_output_arch_syms): Add missing
2072 * nlm32-alpha.c (nlm_alpha_write_external): Fix warning.
2074 * elf64-mips.c (UNUSED_RELOC): Define.
2075 (mips_elf64_howto_table_rel): Use it.
2076 (mips_elf64_howto_table_rela): Here too.
2077 (mips_elf64_write_relocs): Fix signed/unsigned warning.
2079 * coffcode.h (coff_write_object_contents): Add ATTRIBUTE_UNUSED to
2081 * coffgen.c (coff_print_symbol): Fix warnings.
2082 (coff_find_nearest_line): Likewise.
2083 * cofflink.c (_bfd_coff_link_input_bfd): Likewise.
2084 * coff-alpha.c (alpha_convert_external_reloc): Likewise.
2085 * format.c (bfd_check_format_matches): Likewise.
2086 (bfd_set_format): Likewise.
2087 * coff-ia64.c: Add missing prototypes.
2088 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Make addend
2089 signed to silence warnings.
2090 (elf64_alpha_relocate_section): Likewise.
2091 (elf64_alpha_find_reloc_at_ofs): Fix warnings.
2092 (elf64_alpha_add_symbol_hook): Likewise.
2093 (elf64_alpha_final_link): Likewise.
2094 (elf64_alpha_relax_section): Remove redundant assign to info.gotent.
2095 (elf64_alpha_merge_gots): Add ATTRIBUTE_UNUSED to unused args.
2096 (elf64_alpha_size_got_sections): Likewise.
2097 * elfxx-ia64.c: Add missing prototypes.
2098 (elfNN_ia64_relocate_section): Fix warning.
2099 (elfNN_ia64_unwind_entry_compare): Make params const.
2101 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2103 * config.bfd (targ64_selvecs): New.
2104 <powerpc-*-aix* entry>: Use it here instead of ineffectual #ifdef.
2106 * bfd-in.h (BFD_VERSION): Remove wrong comment.
2107 (BFD_DEFAULT_TARGET_SIZE): New.
2108 (BFD_ARCH_SIZE): Comment.
2109 * configure.in (target_size): New. Set instead of target64 in
2110 selvecs case statement. Set target64 from it.
2111 (bfd_default_target_size): New. Set from taget_size. AC_SUBST.
2112 * bfd-in2.h: Regenerate.
2113 * configure: Regenerate.
2115 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2117 * bfd.c (enum bfd_error): Add bfd_error_wrong_object_format.
2118 (bfd_errmsgs): Add corresponding message.
2119 * archive.c (bfd_generic_archive_p): Don't release bfd_ardata when
2120 finding an archive that contains different format object files.
2121 Return bfd_error_wrong_object_format for this case.
2122 * format.c: Formatting fixes. s/CONST/const/.
2123 (bfd_check_format_matches): Accept archives that give
2124 bfd_error_wrong_object_format if no full match is found. Tidy
2125 code handling matching_vector. Don't return a pointer to freed
2126 memory in `matching'. Handle ambiguous matches as for partial
2128 * bfd-in2.h: Regenerate.
2130 2001-08-15 Alan Modra <amodra@bigpond.net.au>
2132 * libieee.h (common_header_type): Add last_byte field.
2134 * ieee.c: Add missing prototypes. Some format fixes.
2135 (struct output_buffer_struct): Move for availability to prototypes.
2136 (ieee_part_after): New function.
2137 (ieee_slurp_debug): Use it here.
2138 (ieee_seek): Pass in ieee_data_struct rather than bfd. Use
2139 ieee_part_after to set last_byte to one past end of current part.
2141 (ieee_pos): Pass in ieee_data_struct rather than bfd.
2143 (parse_expression): Don't go beyond the end of the current part.
2144 (ieee_slurp_external_symbols): Correct type passed to read_2bytes.
2145 (ieee_get_symtab_upper_bound, ieee_get_symtab,
2146 ieee_get_symbol_info, ieee_print_symbol, ieee_new_section_hook,
2147 ieee_get_reloc_upper_bound, ieee_canonicalize_reloc, block,
2148 ieee_set_section_contents, ieee_write_object_contents,
2149 ieee_make_empty_symbol): Make static.
2150 (ieee_archive_p): Correct comments regarding bfd_read.
2151 (ieee_object_p): Similarly.
2152 (ieee_mkobject): Move it. Clear output_ptr_start, output_ptr,
2153 output_ptr_end, input_ptr_start, input_ptr, input_ptr_end,
2154 input_bfd, output_bfd, output_buffer.
2155 (do_as_repeat): Write out ieee_set_current_pc_enum value as for
2156 do_with_relocs, ie. as a symbol for relocatable files.
2157 (ieee_vec): Add comments showing functions referenced by macros.
2159 2001-08-14 Nick Clifton <nickc@cambridge.redhat.com>
2161 * aout-tic30.c: Add missing prototypes. Fix formatting.
2162 * aout-ns32k.c: Add missing prototypes. Fix formatting.
2163 * peXXigen.c: Add missining prototypes. Fix formatting.
2164 * aout-adobe.c: Add missining prototypes. Fix formatting.
2166 2001-08-13 Nick Clifton <nickc@cambridge.redhat.com>
2168 * elf32-v850.c: Add missing function prototypes.
2169 Fix some formatting.
2171 * cpu-v850.c: Add missing function prototype.
2172 Fix some formatting.
2174 2001-08-11 Nick Clifton <nickc@cambridge.redhat.com>
2176 * elf-bfd.h (struct elf_backend_data): Add new fields
2177 'elf_backend_sprintf_vma' and 'elf_backend_fprintf_vma'.
2178 (bfd_elf_sprintf_vma): Rename function prototype to
2179 '_bfd_elf_sprintf_vma'.
2180 (bfd_elf_fprintf_vma): Rename function prototype to
2181 '_bfd_elf_fprintf_vma'.
2182 * bfd.c (bfd_sprintf_vma): Do not invoke bfd_elf_sprintf_vma
2183 directly, instead indirect via the elf_backend_data structure.
2184 (bfd_fprintf_vma): Do not invoke bfd_elf_fprintf_vma directly,
2185 instead indirect via the elf_backend_data structure.
2186 * elf.c (bfd_elf_sprintf_vma): Rename to _bfd_elf_sprintf_vma.
2187 (bfd_elf_fprintf_vma): Rename to _bfd_elf_fprintf_vma.
2188 * elfxx-target.h (elf_backend_sprintf_vma): Initialise if not
2190 (elf_backend_fprintf_vma): Initialise if not already defined.
2191 (struct elf_backend_data): Initialise the
2192 elf_backend_sprintf_vma and elf_backend_fprintf_vma fields.
2194 2001-08-10 Andreas Jaeger <aj@suse.de>
2196 * elf64-sparc.c: Add missing prototypes.
2197 * elf32-cris.c: Likewise.
2198 * elf32-i370.c: Likewise.
2199 * elf64-hppa.c: Likewise.
2200 * elf64-s390.c: Likewise.
2202 2001-08-10 Andreas Jaeger <aj@suse.de>
2204 * elf64-x86-64.c (elf64_x86_64_elf_object_p): Make static.
2205 Add prototypes where needed.
2207 2001-08-10 H.J. Lu <hjl@gnu.org>
2209 * bfd.c (bfd_sprintf_vma): Fix a typo in the last change.
2210 (bfd_fprintf_vma): Likewise.
2212 2001-08-10 H.J. Lu <hjl@gnu.org>
2214 * bfd.c (bfd_sprintf_vma): Don't return void.
2215 (bfd_fprintf_vma): Likewise.
2217 2001-08-10 Andreas Jaeger <aj@suse.de>
2219 * configure.in: Add -Wstrict-prototypes and -Wmissing-prototypes
2221 * configure: Regenerate.
2223 2001-08-10 Alan Modra <amodra@bigpond.net.au>
2225 * elf.c (bfd_elf_sprintf_vma): Add ATTRIBUTE_UNUSED to quiet
2226 warning if not BFD64. Add braces so emacs auto format works.
2227 (bfd_elf_fprintf_vma): Likewise.
2229 * libxcoff.h (struct xcoff_backend_data_rec): Constify src param
2231 * coff-rs6000.c (xcoff_swap_ldhdr_in): Modify type of external
2232 param to agree with libxcoff.h.
2233 (xcoff_swap_ldhdr_out): Likewise.
2234 (xcoff_swap_ldsym_in): Likewise.
2235 (xcoff_swap_ldsym_out): Likewise.
2236 (xcoff_swap_ldrel_in): Likewise.
2237 (xcoff_swap_ldrel_out): Likewise.
2238 (xcoff_create_csect_from_smclas): Likewise.
2239 * coff64-rs6000.c: Add missing prototypes.
2240 (xcoff64_swap_ldhdr_in): Modify type of external param to agree
2242 (xcoff64_swap_ldhdr_out): Likewise.
2243 (xcoff64_swap_ldsym_in): Likewise.
2244 (xcoff64_swap_ldsym_out): Likewise.
2245 (xcoff64_swap_ldrel_in): Likewise.
2246 (xcoff64_swap_ldrel_out): Likewise.
2247 (xcoff64_ppc_relocate_section): Make static.
2248 (xcoff64_slurp_armap): Likewise.
2249 (xcoff64_archive_p): Likewise.
2250 (xcoff64_openr_next_archived_file): Likewise.
2251 (xcoff64_sizeof_headers): Likewise.
2252 (xcoff64_is_lineno_count_overflow): Likewise.
2253 (xcoff64_is_reloc_count_overflow): Likewise.
2254 (xcoff64_loader_symbol_offset): Likewise.
2255 (xcoff64_loader_reloc_offset): Likewise.
2256 * elf64-gen.c: Add missing prototypes.
2258 2001-08-09 H.J. Lu <hjl@gnu.org>
2260 * elf.c (bfd_elf_sprintf_vma): Check ELFCLASS64 only in BFD64.
2261 (bfd_elf_fprintf_vma): Likewise.
2263 2001-08-09 H.J. Lu <hjl@gnu.org>
2265 * bfd-in.h (bfd_elf_sprintf_vma, bfd_elf_fprintf_vma): Moved
2268 * bfd-in2.h: Regenerated.
2270 2001-08-09 H.J. Lu <hjl@gnu.org>
2272 * bfd-in.h (bfd_sprintf_vma): New prototype.
2273 (bfd_fprintf_vma): Likewise.
2274 (bfd_elf_sprintf_vma): Likewise.
2275 (bfd_elf_fprintf_vma): Likewise.
2276 (bfd_printf_vma): New. Defined with bfd_fprintf_vma.
2277 * bfd-in2.h: Regenerated.
2279 * bfd.c (bfd_sprintf_vma): New. Defined.
2280 (bfd_fprintf_vma): Likewise.
2282 * elf.c (bfd_elf_sprintf_vma): New. Defined.
2283 (bfd_elf_fprintf_vma): Likewise.
2285 2001-08-09 Alan Modra <amodra@bigpond.net.au>
2287 * coff-rs6000.c: Add missing prototypes.
2288 (xcoff_ppc_relocate_section, xcoff_is_lineno_count_overflow,
2289 xcoff_is_reloc_count_overflow, xcoff_loader_symbol_offset,
2290 xcoff_loader_reloc_offset): Make static.
2291 * dwarf1.c: Add missing prototypes.
2292 * dwarf2.c: Add missing prototypes.
2293 (struct abbrev_info): Move definition.
2294 (struct attr_abbrev, ABBREV_HASH_SIZE, ATTR_ALLOC_CHUNK): Likewise.
2295 * elf.c: Add missing prototypes.
2296 * elf32-gen.c: Likewise.
2297 * elf32-i386.c: Likewise.
2298 * elf32-ppc.c: Likewise.
2299 (ppc_elf_sort_rela): Use PTR instead of "void *".
2300 * elflink.h: Add missing prototypes. Formatting fixes.
2301 * merge.c: Add missing prototypes.
2302 (last4_eq): Use PTR instead of "void *".
2303 (last_eq): Likewise.
2304 * syms.c: Add missing prototypes.
2306 2001-08-09 Nick Clifton <nickc@cambridge.redhat.com>
2308 * bfd.c: Fix formatting.
2309 * bfd-in2.h: Regenerate.
2311 2001-08-09 Nick Clifton <nickc@cambridge.redhat.com>
2313 * elf32-arc.c (R_ARC_B22_PCREL): Change 'partial_inplace' to
2314 true (this target uses REL relocations) and 'pcrel_offset' to
2315 false (the PC is implied, not stored in the offset).
2317 2001-08-08 Alan Modra <amodra@bigpond.net.au>
2319 1999-10-19 Linus Nordberg <linus@swox.se>
2320 * elf-bfd.h (struct elf_backend_data): Add want_got_sym.
2321 * elfxx-target.h (elf_backend_want_got_sym): Define.
2322 (elfNN_bed): Add elf_backend_want_got_sym.
2323 * elflink.c (_bfd_elf_create_got_section): Define
2324 _GLOBAL_OFFSET_TABLE_ only if bed->want_got_sym.
2326 2001-08-08 Alexandre Oliva <aoliva@redhat.com>
2328 * dwarf2.c (struct dwarf2_debug): Add sec, sec_info_ptr and syms.
2329 (find_rela_addend): New function.
2330 (parse_comp_unit): Call it to find the abbrev offset addend.
2331 (_bfd_dwarf2_find_nearest_line): Initialize and maintain the new
2332 members of dwarf2_debug as debugging information is read.
2334 2001-08-07 Nick Clifton <nickc@cambridge.redhat.com>
2336 * coff-sh.c (sh_coff_reloc_type_lookup): Provide for sh-coff
2337 targets as well as sh-pe.
2339 2001-08-03 Ben Harris <bjh21@netbsd.org>
2341 * elf32-arm.h (elf32_arm_final_link_relocate): Include offset of
2342 reloc from start of section when computing value for R_ARM_REL32
2345 2001-08-03 Alan Modra <amodra@bigpond.net.au>
2347 From H.J. Lu <hjl@gnu.org>
2348 * elf32-i386.c (allocate_plt_and_got_and_discard_relocs): Don't
2349 keep relocs for undefined syms if there are no dynamic sections in
2351 * elf32-hppa.c (allocate_plt_and_got_and_discard_relocs): Likewise.
2353 2001-08-02 Paul Sokolovsky <paul.sokolovsky@technologist.com>
2355 * cofflink.c (coff_link_check_ar_symbols): also search for
2356 __imp__symbol as well as _symbol.
2357 * linker.c (_bfd_generic_link_add_archive_symbols): also
2358 search for __imp__symbol as well as _symbol.
2360 2001-08-01 Adam Nemet <anemet@lnxw.com>
2362 * elf.c (elf_sort_sections): Return zero only as the last step.
2364 2001-08-01 Nick Clifton <nickc@cambridge.redhat.com>
2366 * config.bfd (arm-vxworks): Change name of define from VXWORKS to
2368 (arm-epoc-pe): Define ARM_COFF_BUGFIX.
2369 coff-arm.c (coff_arm_relocate_section): Replace VXWORKS with
2372 2001-07-30 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
2374 * libecoff.h (_bfd_ecoff_styp_to_sec_flags): Changed return type
2375 to match corresponding bfd_coff_backend data member.
2377 2001-07-24 Alan Modra <amodra@bigpond.net.au>
2379 * Makefile.am: Update dependencies with "make dep-am".
2380 * Makefile.in: Regenerate
2382 2001-07-15 H.J. Lu <hjl@gnu.org>
2384 * Makefile.am (po/SRC-POTFILES.in): Use tmp.src instead of tmp.
2385 (po/BLD-POTFILES.in): Use tmp.bld instead of tmp.
2386 * Makefile.in: Regenerate.
2388 2001-07-11 H.J. Lu <hjl@gnu.org>
2390 * elf64-alpha.c (elf64_alpha_check_relocs): Set the ALLOC|LOAD
2391 flags when creating the reloc section if the ALLOC flag in the
2392 source section is set.
2394 2001-07-11 Steve Ellcey <sje@cup.hp.com>
2396 * reloc.c (bfd_reloc_code_type): Add IA64 relocs
2397 BFD_RELOC_IA64_LTOFF_FPTR32MSB and BFD_RELOC_IA64_LTOFF_FPTR32LSB
2398 * bfd-in2.h: Regenerate.
2399 * libbfd.h: Regenerate.
2400 * elfxx-ia64.c (ia64_howto_table): Define how to handle
2402 (elfNN_ia64_reloc_type_lookup): Handle new relocations.
2403 (elfNN_ia64_check_relocs): Likewise.
2404 (elfNN_ia64_install_value): Likewise.
2405 (elfNN_ia64_relocate_section): Likewise.
2407 2001-07-11 Jakub Jelinek <jakub@redhat.com>
2409 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Remove support for
2411 (elf32_sparc_check_relocs): Likewise.
2412 Only create .rela section for alloced sections in shared libraries.
2413 (elf32_sparc_relocate_section): Likewise.
2414 Remove redundant check.
2415 Optimize unaligned reloc usage.
2416 * elf64-sparc.c (sparc64_elf_relocate_section): Remove redundant
2419 2001-07-11 H.J. Lu <hjl@gnu.org>
2421 * elf64-alpha.c (elf64_alpha_check_relocs): Only use the same
2422 ALLOC|LOAD flags as the source section for debugging sections
2423 when creating the reloc section.
2425 2001-07-05 Jim Wilson <wilson@redhat.com>
2427 * linker.c (_bfd_generic_link_add_one_symbol, case BIG): Use
2428 the section of the bigger symbol.
2430 * syms.c (bfd_is_local_label): Return false if BSF_SECTION_SYM.
2432 2001-07-05 Nick Clifton <nickc@cambridge.redhat.com>
2434 * peicode.h (coff_swap_scnhdr_in): For sections containing
2435 uninitialised data, only set their size to s_paddr if this does
2436 not reset their size to zero. MS's latest compilers will set
2439 2001-07-04 H.J. Lu <hjl@gnu.org>
2441 * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing):
2442 Handle bfd_mach_mips4400, bfd_mach_mips4600 and
2445 2001-07-03 Mark Elbrecht <snowball3@softhome.net>
2447 * bfd.c (bfd_get_sign_extend_vma): Support DJGPP COFF targets.
2449 * cofflink.c (_bfd_coff_link_input_bfd): Skip section symbols from
2450 sections being discarded.
2452 2001-06-30 Alan Modra <amodra@bigpond.net.au>
2454 * elfcore.h (elf_core_file_p): Call bfd_section_from_phdr directly
2455 instead of _bfd_elfcore_section_from_phdr.
2456 * elf-bfd.h (_bfd_elfcore_section_from_phdr): Remove.
2457 * elf.c (_bfd_elfcore_section_from_phdr): Remove.
2458 (_bfd_elfcore_make_pseudosection): Expedite tail-call.
2459 (elfcore_grok_prstatus): Likewise.
2460 (elfcore_grok_lwpstatus): Likewise.
2461 (bfd_get_elf_phdr_upper_bound): Likewise.
2462 (elfcore_make_note_pseudosection): Formatting.
2463 (_bfd_elfcore_strndup): Formatting.
2464 * elf32-mips.c (mips_elf_sym_is_global): Formatting.
2465 (_bfd_elf32_mips_grok_prstatus): Expedite tail-call.
2467 2001-06-29 Daniel Jacobowitz <drow@mvista.com>
2469 * elf-bfd.h: Add prototypes for _bfd_elfcore_make_pseudosection
2470 and _bfd_elfcore_strndup.
2471 (struct elf_backend_data): Add elf_backend_grok_prstatus
2472 and elf_backend_grok_psinfo.
2473 * elf.c (_bfd_elfcore_make_pseudosection): New function.
2474 (elfcore_grok_prstatus): Use it.
2475 (elfcore_make_note_pseudosection): Likewise.
2476 (elfcore_strndup): Rename to...
2477 (_bfd_elfcore_strndup): Here, and make global.
2478 (elfcore_grok_psinfo): Use _bfd_elfcore_strndup.
2479 (elfcore_grok_note): Call elf_backend_grok_prstatus
2480 and elf_backend_grok_psinfo if available.
2481 * elf32-mips.c (_bfd_elf32_mips_grok_prstatus): New function.
2482 (_bfd_elf32_mips_grok_psinfo): New function.
2483 (elf_backend_grok_prstatus): Define.
2484 (elf_backend_grok_psinfo): Define.
2485 * elfxx-target.h (elf_backend_grok_prstatus): Default to NULL.
2486 (elf_backend_grok_psinfo): Likewise.
2487 (elfNN_bed): Include elf_backend_grok_prstatus and
2488 elf_backend_grok_psinfo.
2490 2001-06-29 H.J. Lu <hjl@gnu.org>
2492 * elf32-hppa.c (elf32_hppa_finish_dynamic_sections): Check if
2493 hplink->sgot is NULL before filling GOT. Check if hplink->splt
2494 is NULL before filling PLT.
2496 2001-06-29 Alan Modra <amodra@bigpond.net.au>
2498 * elflink.h (elf_link_output_extsym): Revert 1999-04-10.
2500 2001-06-27 Alan Modra <amodra@bigpond.net.au>
2502 * elf32-hppa.c (elf32_hppa_check_relocs): Don't make syms dynamic
2504 (elf32_hppa_adjust_dynamic_symbol): ..nor here..
2505 (allocate_plt_and_got_and_discard_relocs): .. instead do so here
2508 * elf32-hppa.c (RELATIVE_DYNAMIC_RELOCS): Delete.
2509 (IS_ABSOLUTE_RELOC): Define.
2510 (elf32_hppa_link_hash_entry): Always include reloc_entries field.
2511 (hppa_link_hash_newfunc): Always init it.
2512 (elf32_hppa_check_relocs): Mark symbols as ELF_LINK_NON_GOT_REF to
2513 create COPY relocs only when the reloc is in a read-only section.
2514 Instead, allocate space for a dynamic reloc to reference the
2515 library symbol directly. Keep track of space we allocate using
2517 (hppa_discard_copies): Delete, and move code to..
2518 (allocate_plt_and_got): ..here. Rename to
2519 allocate_plt_and_got_and_discard_relocs. Remove unneeded dynamic
2520 relocs for non-shared link.
2521 (elf32_hppa_size_dynamic_sections): Update calls to above.
2522 (elf32_hppa_relocate_section): Write out the dynamic relocs used
2523 in lieu of COPY relocs.
2525 * elf32-i386.c (elf_i386_check_relocs): Don't make syms dynamic
2527 (elf_i386_adjust_dynamic_symbol): ..nor here..
2528 (allocate_plt_and_got_and_discard_relocs): .. instead do so here
2530 (elf_i386_size_dynamic_sections): Fix a comment.
2531 (elf_i386_relocate_section <R_386_32, R_386_PC32>): Rearrange code
2532 involved in writing reloc out.
2534 2001-06-25 Alan Modra <amodra@bigpond.net.au>
2536 * elf32-i386.c (elf_i386_check_relocs <R_386_32, R_386_PC32>):
2537 Ensure syms are dynamic if we might be emitting a reloc.
2538 (allocate_plt_and_got_and_discard_relocs): Don't discard relocs
2539 for undefweak or undefined syms..
2540 (elf_i386_relocate_section <R_386_32, R_386_PC32>): .. and emit.
2542 * elf32-i386.c (allocate_plt_and_got_and_discard_relocs): Discard
2543 relocs without ELF_LINK_HASH_DEF_DYNAMIC set.
2544 (elf_i386_relocate_section <R_386_32, R_386_PC32>): Remove
2545 redundant bfd_link_hash_defined, bfd_link_hash_defweak test.
2547 2001-06-24 H.J. Lu <hjl@gnu.org>
2549 * cpu-i960.c (scan_960_mach): Don't modify const char *. Use
2550 strncasecmp/strcasecmp instead of strncmp/strcmp.
2552 2001-06-23 H.J. Lu <hjl@gnu.org>
2554 * elf32-i386.c (elf_i386_relocate_section <R_386_32, R_386_PC32>):
2555 Check ELF_LINK_HASH_DEF_DYNAMIC to see if a symbol is not defined
2556 in the regular object file and treat the weak definition as
2559 2001-06-23 Alan Modra <amodra@bigpond.net.au>
2561 * elf32-i386.c (elf_i386_relocate_section <R_386_GOT32>): Tighten
2562 unresolved_reloc test to exclude cases where we use "relocation"
2563 before setting it to point into the .got. Reinstate fudge for
2564 unresolved relocs in debugging sections.
2566 * elf32-i386.c (elf_i386_relocate_section): Replace ugly
2567 complicated tests for unresolvable relocs with a simple direct
2568 scheme using "unresolved_reloc" var.
2570 * elf32-i386.c (struct elf_i386_pcrel_relocs_copied): Rename to
2571 elf_i386_dyn_relocs. Update comment.
2572 (struct elf_i386_link_hash_entry): Rename pcrel_relocs_copied to
2574 (elf_i386_adjust_dynamic_symbol): Remove a BFD_ASSERT, change
2576 (allocate_plt_and_got_and_discard_relocs): Replace BFD_ASSERT with
2578 (elf_i386_size_dynamic_sections): Likewise.
2579 (elf_i386_finish_dynamic_symbol): Likewise.
2580 (elf_i386_finish_dynamic_sections): Likewise.
2581 (elf_i386_relocate_section): Likewise. Tidy R_386_GOT32 and error
2584 Avoid creating COPY relocs if possible.
2585 * elf32-i386.c (elf_i386_check_relocs): Tweak condition under
2586 which .got created. Mark symbols used by R_386_32 and R_386_PC32
2587 relocs as ELF_LINK_NON_GOT_REF to create COPY relocs only when the
2588 reloc is in a read-only section. Instead, allocate space for a
2589 dynamic reloc to reference the library symbol directly. Keep
2590 track of space we allocate using pcrel_relocs_copied.
2591 (discard_copies): Delete, and move code to ..
2592 (allocate_plt_and_got): ..here. Rename to
2593 allocate_plt_and_got_and_discard_relocs. Remove unneeded dynamic
2594 relocs for non-shared link.
2595 (elf_i386_size_dynamic_sections): Update calls to above functions.
2596 (elf_i386_relocate_section): Write out the dynamic relocs. Add
2597 more ugly logic to avoid "unresolvable relocation" error. Use
2598 htab shortcut in place of elf_hash_table macro.
2599 (elf_i386_finish_dynamic_sections): Allow that dynamic .got may
2600 not always be created now.
2602 2001-06-20 Bo Thorsen <bo@suse.co.uk>
2604 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix linking of
2607 2001-06-18 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2609 * configure.host (mips64-*-linux): Reformat.
2611 2001-06-21 Alan Modra <amodra@bigpond.net.au>
2613 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Always
2614 allocate local .got space. Use shortcuts from hash table for .got
2615 and .plt rather than comparing section names.
2616 (elf32_hppa_check_relocs): Use local_plt_refcounts var rather than
2617 adjusting index into local_got_refcounts to document what we are
2619 (elf32_hppa_relocate_section): Similarly for local_plt_offsets.
2620 Tidy .got and .plt error checking.
2622 2001-06-20 Catherine Moore <clm@redhat.com>
2624 * elf-bfd.h (struct elf_backend_data):
2625 elf_backend_emit_relocs: New field: Function for emitting
2627 elf_backend_count_relocs: New field: Function for determining
2628 the number of relocs to be emitted.
2629 * elfxx-target.h: Provide default (NULL) values for
2630 elf_backend_emit_relocs and elf_backend_count_relocs.
2631 * elflink.h (elf_link_size_reloc_section): Make the hash table
2632 big enough to hold the relocs counted by either reloc_count or
2634 (elf_bfd_final_link) emit_relocs: New boolean, set if relocs
2635 should be emitted, either because of a command line option
2636 stored in the info structure or because the target provides a
2637 special reloc emitting function.
2638 If the target provides a reloc counting function use it,
2639 unless performing a relocatable link or emitting all relocs.
2640 Also set the SEC_RELOC flag on any output section which will
2642 (elf_link_input_bfd): emit_relocs: New boolean, set if relocs
2643 should be emitted, either because of a command line option
2644 stored in the info structure or because the target provides a
2645 special reloc emitting function.
2646 If the target provides a reloc emitting function, use it,
2647 unless performing a relocatable link or emitting all relocs.
2649 2001-06-20 H.J. Lu <hjl@gnu.org>
2651 * elf32-i386.c (elf_i386_size_dynamic_sections): Always
2652 allocate local .got space.
2654 2001-06-19 Andreas Jaeger <aj@suse.de>
2656 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix creation of
2659 2001-06-18 Hans-Peter Nilsson <hp@axis.com>
2661 * elflink.h (struct elf_assign_sym_version_info): Remove member
2662 export_dynamic. All users changed to use info member.
2663 NAME(bfd_elf,size_dynamic_sections)): Remove parameter
2664 export_dynamic, instead use member in parameter info.
2665 * bfd-in.h (bfd_elf32_size_dynamic_sections,
2666 bfd_elf64_size_dynamic_sections): Update prototype.
2667 * bfd-in2.h: Regenerate.
2669 2001-06-18 H.J. Lu <hjl@gnu.org>
2671 * elflink.h (elf_info_failed): Add a new field, verdefs.
2672 (NAME(bfd_elf,size_dynamic_sections): Pass verdefs to
2674 (elf_export_symbol): Check eif->verdefs to decide if a symbol
2677 2001-06-17 H.J. Lu <hjl@gnu.org>
2679 * elf32-mips.c (mips_elf_link_hash_entry): Add a new field,
2680 readonly_reloc, to record if a relocation in the .rel.dyn
2681 section is against a read-only section.
2682 (mips_elf_link_hash_newfunc): Initialize the readonly_reloc
2684 (_bfd_mips_elf_check_relocs): Record if there is a relocation
2685 in the .rel.dyn section against a read-only section by setting
2686 DF_TEXTREL or readonly_reloc.
2687 (_bfd_mips_elf_copy_indirect_symbol): Copy readonly_reloc if
2689 (_bfd_mips_elf_adjust_dynamic_symbol): Record DF_TEXTREL if
2690 there is a relocation in the .rel.dyn section against a
2692 (_bfd_mips_elf_size_dynamic_sections): Set DT_TEXTREL if
2695 2001-06-12 Nick Clifton <nickc@cambridge.redhat.com>
2697 * coffcode.h (styp_flags_to_sec_flags): Change to a boolean
2698 function. Move flagword result into parameter list. Remove
2699 comment about setting bfd_error_handler to intercept failure
2701 * coffgen.c (make_a_section_from_file): Examine result of
2702 calling bfd_coff_styp_to_sec_flags and pass a failure back to
2704 * ecoff.h (styp_flags_to_sec_flags): Change to a boolean
2705 function. Move flagword result into parameter list.
2706 * libcoff.h: Regenerate.
2707 * libecoff.h: Regenerate.
2709 2001-06-13 Nick Clifton <nickc@cambridge.redhat.com>
2711 * aoutx.h (adjust_z_magic): Only pad the tesxt section if the data
2712 section is going to follow it.
2714 2001-06-12 Catherine Moore <clm@redhat.com>
2716 * elflink.h (elf_gc_propagate_vtable_entries): Replace FILE_ALIGN
2717 with the file_align entry from elf_backend_data.
2718 (elf_gc_smash_unused_vtentry_relocs): Likewise.
2719 (elf_gc_record_vtentry): Likewise.
2721 2001-06-10 Alan Modra <amodra@bigpond.net.au>
2723 * elflink.h: Whitespace changes.
2724 (elf_link_read_relocs_from_section): Use "unsigned int" iterator
2725 rather than "unsigned char".
2726 (elf_link_output_relocs): Likewise.
2727 (elf_link_input_bfd): Likewise.
2728 (elf_reloc_link_order): LIkewise.
2729 * elf.c: s/CONST/const/. Whitespace changes.
2730 * elf32-mips.c: Formatting fix.
2732 * Makefile.am (SOURCE_HFILES): Include xcoff-target.h, remove xcoff.h.
2733 * Makefile.in: Regenerate.
2734 * po/Make-in: Remove trailing tab.
2736 2001-06-09 Philip Blundell <philb@gnu.org>
2738 * elf32-arm.h (elf32_arm_plt0_entry): Correct error in last
2740 (elf32_arm_plt_entry): Likewise.
2742 2001-06-08 H.J. Lu <hjl@gnu.org>
2744 * elf.c (swap_out_syms): Keep names for global section symbols.
2746 2001-06-07 H.J. Lu <hjl@gnu.org>
2748 * config.bfd: Put back ecoff for Linux/mips. Firmwares on some
2749 MIPS-based machines need it.
2751 2001-06-07 H.J. Lu <hjl@gnu.org>
2753 * elf32-mips.c (_bfd_mips_elf_object_p): Set the bad symtab
2756 * config.bfd: Remove ecoff from Linux/mips.
2758 2001-06-07 Andreas Jaeger <aj@suse.de>
2760 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_symbol): Add an
2762 (elf64_x86_64_check_relocs): Fix VTENTRY relocation; set an
2763 alignment of 8 for .rela sections; handle further relocations.
2765 2001-06-06 Christian Groessler <cpg@aladdin.de>
2767 * coff-z8k.c: Fix formatting.
2768 Fix howtos: howto->size was always 1.
2770 2001-06-05 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2772 * configure.host (mips64*-*-linux*): Define.
2774 2001-06-05 Alan Modra <amodra@bigpond.net.au>
2776 * elf32-i386.c (elf_i386_discard_copies): Rename to
2777 discard_copies, and use elf_link_hash_entry arg rather than
2778 elf_i386_link_hash_entry.
2779 (elf_i386_link_hash_traverse): Delete.
2780 (elf_i386_size_dynamic_sections): Adjust call to discard_copies.
2781 Tidy sizing of dynamic sections.
2782 (elf_i386_check_relocs <R_386_32, R_386_PC32>): Reference count
2783 possible .plt entries.
2784 (elf_i386_gc_sweep_hook): Likewise.
2785 (elf_i386_adjust_dynamic_symbol): Discard .plt entries for
2786 everything with plt.refcount <= 0.
2788 * elf32-i386.c (elf_i386_check_relocs): Don't allocate .got and
2790 (elf_i386_gc_sweep_hook): ..and no need to deallocate here..
2791 (elf_i386_adjust_dynamic_symbol): ..and don't allocate .plt and
2793 (allocate_plt_and_got): ..instead do it all here. New function.
2794 (elf_i386_size_dynamic_sections): Allocate local .got space and
2795 call allocate_plt_and_got. No need to zap .relgot if not dynamic.
2796 (bfd_elf32_bfd_final_link): Delete. (ie. use regular final link
2797 rather than gc variety).
2798 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
2799 (elf_i386_relocate_section): Use it here and correct handling of
2800 R_386_GOT32. Provide section and offset for "unresolvable
2801 relocation" error message.
2802 (elf_i386_finish_dynamic_symbol): Correct handling of R_386_GOT32.
2804 * elf32-i386.c (struct elf_i386_link_hash_table): Add sgot,
2805 sgotplt, srelgot, splt, srelplt, sdynbss, srelbss fields.
2806 (elf_i386_link_hash_table_create): Init them.
2807 (create_got_section): New function.
2808 (elf_i386_create_dynamic_sections): New function.
2809 (elf_backend_create_dynamic_sections): Set to above.
2810 (elf_i386_check_relocs): Use shortcuts from hash table rather than
2811 calling bfd_get_section_by_name.
2812 (elf_i386_gc_sweep_hook): Likewise.
2813 (elf_i386_adjust_dynamic_symbol): Likewise.
2814 (elf_i386_size_dynamic_sections): Likewise.
2815 (elf_i386_relocate_section): Likewise.
2816 (elf_i386_finish_dynamic_sections): Likewise.
2818 * elf32-hppa.c (allocate_plt_and_got): Skip indirect and warning syms.
2820 2001-06-02 H.J. Lu <hjl@gnu.org>
2822 * elf32-hppa.c (elf32_hppa_object_p): Check ELFOSABI_LINUX
2824 * elf64-hppa.c (elf64_hppa_object_p): Likewise.
2826 2001-06-02 H.J. Lu <hjl@gnu.org>
2828 * aout-cris.c (MACHTYPE_OK): New. Defined.
2830 2001-06-02 Hans-Peter Nilsson <hp@axis.com>
2832 * section.c (_bfd_strip_section_from_output): Handle NULL
2835 2001-06-02 H.J. Lu <hjl@gnu.org>
2837 * config.bfd (powerpc-*-aix*, powerpc-*-beos*, rs6000-*-*): Add
2838 rs6000coff64_vec only if BFD64 is defined.
2839 (powerpc64-*-aix*): Enable only if BFD64 is defined.
2841 2001-06-02 H.J. Lu <hjl@gnu.org>
2843 * coff-ia64.c (ia64coff_object_p): Rewrite with
2844 external_PEI_DOS_hdr and external_PEI_IMAGE_hdr.
2846 2001-06-01 Andreas Jaeger <aj@suse.de>
2848 * elf64-x86-64.c (elf64_x86_64_relocate_section): Add PC8
2849 relocation, small reformatting.
2851 2001-05-29 Andreas Jaeger <aj@suse.de>
2853 * elf64-x86-64.c (elf64_x86_64_check_relocs): Handle R_X86_64_64.
2854 (elf64_x86_64_relocate_section): Likewise.
2856 2001-05-30 Alan Modra <amodra@one.net.au>
2858 * elf32-hppa.c (elf32_hppa_check_relocs): Don't NEED_PLT for
2859 millicode. Don't allocate .got and .rela.got space here..
2860 (elf32_hppa_gc_sweep_hook): ..and no need to deallocate here..
2861 (elf32_hppa_adjust_dynamic_symbol): ..and don't allocate .plt and
2863 (hppa_handle_PIC_calls): ..nor here..
2864 (allocate_plt_and_got): ..instead do it all here. New function.
2865 (elf32_hppa_size_dynamic_sections): Allocate local .got space and
2866 call allocate_plt_and_got. No need to zap .got if not dynamic.
2867 (elf32_hppa_final_link): Call regular bfd_final_link instead of
2868 gc_common_final_link.
2869 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
2870 (elf32_hppa_relocate_section): Use it here.
2871 (elf32_hppa_finish_dynamic_symbol): Remove superfluous test of
2872 dynamic_sections_created.
2873 (hppa_type_of_stub): Don't LONG_BRANCH_VIA_PLT if millicode sym.
2875 2001-05-28 Andreas Jaeger <aj@suse.de>
2877 * elf64-x86-64.c (elf64_86_64_size_info): Remove, we can use the
2878 generic version since we want a hashsize of 4.
2879 (elf_backend_size_info): Likewise.
2881 2001-05-28 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2883 * elflink.h (elf_link_size_reloc_section): Use bfd_zmalloc instead of
2885 (elf_link_output_relocs): Handle MIPS ELF64 relocations correctly.
2886 (elf_link_input_bfd): Likewise.
2887 (elf_reloc_link_order): Likewise.
2888 (elf_finish_pointer_linker_section): Typo. Handle MIPS ELF64
2889 relocations correctly.
2891 2001-05-28 Nicolas Pitre <nico@cam.org>
2893 * elf32-arm.h: fix PLT generation for big endian ARM
2895 2001-05-28 Alan Modra <amodra@one.net.au>
2897 * elf32-hppa.c (elf32_hppa_relocate_section): Set up .plt entries
2898 for symbols forced local that need plabels.
2899 (elf32_hppa_adjust_dynamic_symbol): Don't allocate space in
2900 .plt.rela for local syms if non-shared.
2901 (hppa_build_one_stub): Mask lsb of plt.offset.
2902 (elf32_hppa_finish_dynamic_symbol): Abort if lsb of plt.offset set.
2903 (clobber_millicode_symbols): Correct comment.
2904 (elf32_hppa_relocate_section): Likewise.
2905 (elf32_hppa_finish_dynamic_symbol): Likewise.
2907 2001-05-28 Jeff Sturm <jsturm@one-point.com>
2909 * reloc.c: Add BFD_RELOC_SPARC_UA16 and BFD_RELOC_SPARC_UA64.
2910 * bfd-in2.h: Regenerate.
2911 * libbfd.h: Regenerate.
2912 * elf32-sparc.c: Enable BFD_RELOC_SPARC_UA16, BFD_RELOC_SPARC_UA32
2913 and BFD_RELOC_SPARC_UA64 mapping
2914 * elf64-sparc.c: Likewise.
2916 2001-05-25 H.J. Lu <hjl@gnu.org>
2918 * Makefile.am (BFD32_BACKENDS): Remove coff-pmac.lo.
2919 (BFD32_BACKENDS_CFILES): Remove coff-pmac.c.
2920 (coff-rs6000.lo): Remove the old dependency.
2921 * Makefile.in: Rebuild.
2923 * configure.in (pmac_xcoff_vec): Replace coff-pmac.lo with
2926 2001-05-25 H.J. Lu <hjl@gnu.org>
2928 * coff-rs6000.c (rs6000coff_vec): Use rs6000coff_core_p,
2929 rs6000coff_core_file_matches_executable_p,
2930 rs6000coff_core_file_failing_command and
2931 rs6000coff_core_file_failing_signal only if AIX_CORE is
2933 (pmac_xcoff_vec): Likewise.
2934 * coff64-rs6000.c (rs6000coff64_vec): Likewise.
2936 2001-05-25 Timothy Wall <twall@redhat.com>
2938 * elfxx-ia64.c (allocate_dynrel_entries): Don't allocate an entry
2939 for __GLOB_DATA_PTR on AIX5. Clean up some relocation bugs.
2941 2001-05-25 H.J. Lu <hjl@gnu.org>
2943 * bfd-in2.h: Regenerated.
2944 * libcoff.h: Likewise.
2946 2001-05-25 Alan Modra <amodra@one.net.au>
2948 * elf32-hppa.c (elf32_hppa_relocate_section): Don't allow
2949 undefined millicode syms in shared libs.
2950 (hppa_build_one_stub): Turn BFD_ASSERTs into aborts.
2951 (elf32_hppa_check_relocs): Likewise.
2952 (elf32_hppa_adjust_dynamic_symbol): Likewise.
2953 (elf32_hppa_size_dynamic_sections): Likewise.
2954 (elf32_hppa_relocate_section): Likewise.
2955 (elf32_hppa_finish_dynamic_symbol): Likewise.
2956 (elf32_hppa_finish_dynamic_sections): Likewise.
2958 2001-05-24 Tom Rix <trix@redhat.com>
2960 * Makefile.am coff-pmac bfd now defined in coff-rs6000.c
2961 xcoff-target.h not used to define rs6000 or ppc bfd.
2964 * bfd-in.h : (struct lineno_cache_entry) promote element "offset"
2967 * coff-rs6000.c : Many changes for 64 bit support. Move common
2968 32/64 code to xcofflink.c. Explictly define the rs6000coff_vec
2971 * coff64-rs6000.c : Many changes for 64 bit support. 64 bit
2972 linker now supported. Explictly define the rs6000coff64_vec.
2974 * coffcode.h : (coff_set_arch_mach_hook) xcoff 64 bit support
2975 (coff_print_aux) same
2976 (coff_write_object_contents) same
2977 (coff_slurp_line_table) same
2979 * coffgen.c : (coff_fix_symbol_name) formatting
2980 (coff_mangle_symbols) xcoff 64 bit support
2981 (coff_write_symbol) same
2982 (coff_write_alien_symbol) same
2983 (coff_write_native_symbol) same
2984 (coff_write_symbols) same
2985 (coff_get_symbol_info) same
2986 (bfd_coff_get_syment) same
2987 (coff_print_symbol) same
2989 * config.bfd : add powerpc64-*-aix* target
2991 * libcoff-in.h : formatting
2993 * libcoff.h : move xcoff extern declarations to libxcoff.h
2995 * libxcoff.h : New file
2997 * xcofflink.c : Many changes for xcoff64 support. Move common
2998 structures to include/coff/xcoff.h. Move specific structure to
2999 backends coff-rs6000.c and coff64-rs6000.c. Use new backend
3000 functions, defined in libxcoff.h, to isolate 32/64 dependencies.
3002 (bfd_xcoff_size_dynamic_sections) : special __rtinit symbol for
3005 (xcoff_build_ldsyms) : handle special __rtinit symbol.
3007 2001-05-23 Alexandre Oliva <aoliva@redhat.com>
3009 * elf64-sparc.c (sparc64_elf_slurp_reloc_table): Fix typo
3012 2001-05-23 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3014 * reloc.c (bfd_reloc_code_real): Add MIPS ELF64 relocations.
3015 * libbfd.h: Regenerate.
3016 * bfd-in2.h: Regenerate.
3018 * aoutx.h (aout_@var{size}_machine_type): Add MIPS r12k support.
3019 * archures.c (bfd_mach_mips12000): Define.
3020 * cpu-mips.c (arch_info_struct): Add MIPS r12k support.
3021 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Add MIPS r12k
3023 (_bfd_mips_elf_size_dynamic_sections): Use official bfd typedef.
3024 * bfd-in2.h: Regenerate.
3025 * elfxx-target.h: Do not redefine bfd_elfNN_bfd_make_debug_symbol.
3027 2001-05-23 kaz Kojima <kkojima@rr.iij4u.or.jp>
3029 * elf32-sh.c (elf_sh_plt0_entry_be, elf_sh_plt0_entry,
3030 elf_sh_plt_entry_be, elf_sh_plt_entry, elf_sh_pic_plt_entry_be,
3031 elf_sh_pic_plt_entry): New PLT code, that does not use r2, since
3032 that is used by GCC.
3034 2001-05-23 Nick Clifton <nickc@cambridge.redhat.com>
3036 * elf-bfd.h (NUM_SHDR_ENTRIES): New macro: compute the number
3037 of entries in a structured section.
3038 * elf.c: Use new macro.
3039 * elf32-i386.c: Use new macro.
3040 * elf32-mips.c: Use new macro.
3041 * elf64-alpha.c: Use new macro.
3042 * elf64-sparc.c: Use new macro.
3043 * elfcode.h: Use new macro.
3044 * elflink.h: Use new macro.
3046 2001-05-23 Nick Clifton <nickc@cambridge.redhat.com>
3048 * bfdint.texi: Replace -oformat with --oformat.
3050 2001-05-21 Andreas Jaeger <aj@suse.de>
3052 * dwarf2.c (decode_line_info): Fix error message.
3053 (read_abbrevs): Fix test for offset as suggested by Alan Modra and
3054 adjust error message.
3056 2001-05-18 H.J. Lu <hjl@gnu.org>
3058 * elflink.h (elf_link_add_object_symbols): Revert the last
3061 2001-05-17 Alan Modra <amodra@one.net.au>
3063 * elf32-hppa.c (clobber_millicode_symbols): Temporarily set
3064 ELF_LINK_FORCED_LOCAL to suit 2001-04-30 change.
3065 (hppa_build_one_stub): Add an assert to check plt.offset.
3067 2001-05-17 H.J. Lu <hjl@gnu.org>
3069 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set the
3070 version definition to basename of the output filename.
3072 2001-05-17 H.J. Lu <hjl@gnu.org>
3074 * elflink.h (elf_link_add_object_symbols): Set DT_NEEDED to
3075 basename of the bfd filename.
3077 2001-05-16 Alan Modra <amodra@one.net.au>
3079 * section.c (asection): Add linker_has_input field.
3080 (STD_SECTION): Adjust initialization to suit.
3081 * ecoff.c (bfd_debug_section): Likewise.
3082 * bfd-in2.h: Regenerate.
3084 2001-05-15 Alexandre Oliva <aoliva@redhat.com>
3086 * elf-m10300.c (mn10300_elf_relax_section): Don't relax
3087 negative 32-bit operands to 16 operands when the operand is
3088 going to be zero-extended by the modified opcode.
3090 2001-05-12 Peter Targett <peter.targett@arccores.com>
3092 * cpu-arc.c (arch_info_struct): Add entry 'base' representing old
3093 name for 'arc5' core versions.
3094 (bfd_arc_arch): Make bfd_mach_arc_6 default.
3096 * elf32-arc.c (arc_elf_object_p): Make E_ARC_MACH_ARC6 default
3098 (arc_elf_final_write_processing): Make bfd_mach_arc_6 default.
3100 2001-05-11 Jakub Jelinek <jakub@redhat.com>
3102 * elfxx-ia64.c (is_unwind_section_name): Consider linkonce unwind
3104 (elfNN_ia64_final_write_processing): Map .gnu.linkonce.ia64unw.FOO
3105 to .gnu.linkonce.t.FOO text section.
3107 2001-05-11 Jakub Jelinek <jakub@redhat.com>
3109 * merge.c (struct sec_merge_hash_entry): Add u.entsize and u.suffix
3110 fields, change sec into secinfo.
3111 (struct sec_merge_info): Add chain, remove last fields.
3112 (struct sec_merge_sec_info): Add next, sec, psecinfo fields.
3113 (sec_merge_hash_lookup): If lookup could not use a string only
3114 because it has bad alignment, mark the old string for deletion.
3115 (sec_merge_add): Add secinfo argument. Don't compute entry's
3116 position, instead record the section.
3117 (sec_merge_emit): Update for the sec into secinfo change in
3118 struct sec_merge_hash_entry.
3119 (_bfd_merge_section): Only record the section for merging, defer
3120 putting strings into the hash table.
3121 (cmplengthentry, last4_eq, last_eq, record_section, merge_strings,
3122 _bfd_merge_sections): New functions.
3123 (_bfd_merged_section_offset): Update for the sec_merge_hash_entry
3125 * libbfd-in.h (_bfd_merge_sections): Add prototype.
3126 (_bfd_nolink_bfd_merge_sections): Define.
3127 * libbfd.h: Likewise.
3128 (bfd_generic_merge_sections): Add prototype.
3129 * targets.c (BFD_JUMP_TABLE_LINK): Add _bfd_merge_sections.
3130 (struct bfd_target): Likewise.
3131 * bfd.c (bfd_merge_sections): Define.
3132 * bfd-in2.h: Rebuilt.
3133 * elf.c (_bfd_elf_merge_sections): New function.
3134 * elf-bfd.h (_bfd_elf_merge_sections): Add prototype.
3135 * elfxx-target.h (bfd_elfNN_bfd_merge_sections): Define.
3136 * reloc.c (bfd_generic_merge_sections): New function.
3137 * vms.c (vms_bfd_merge_sections): New function.
3138 * aout-adobe.c (aout_32_bfd_merge_sections): Define.
3139 * aout-target.h (MY_bfd_merge_sections): Define.
3140 * aout-tic30.c (MY_bfd_merge_sections): Define.
3141 * binary.c (binary_bfd_merge_sections): Define.
3142 * bout.c (b_out_bfd_merge_sections): Define.
3143 * coff-alpha.c (_bfd_ecoff_bfd_merge_sections): Define.
3144 * coffcode.c (coff_bfd_merge_sections): Define.
3145 * coff-mips.c (_bfd_ecoff_bfd_merge_sections): Define.
3146 * i386msdos.c (msdos_bfd_merge_sections): Define.
3147 * i386os9k.c (os9k_bfd_merge_sections): Define.
3148 * ieee.c (ieee_bfd_merge_sections): Define.
3149 * ihex.c (ihex_bfd_merge_sections): Define.
3150 * nlm-target.h (nlm_bfd_merge_sections): Define.
3151 * oasys.c (oasys_bfd_merge_sections): Define.
3152 * ppcboot.c (ppcboot_bfd_merge_sections): Define.
3153 * som.c (som_bfd_merge_sections): Define.
3154 * srec.c (srec_bfd_merge_sections): Define.
3155 * tekhex.c (tekhex_bfd_merge_sections): Define.
3156 * versados.c (versados_bfd_merge_sections): Define.
3157 * xcoff-target.h (_bfd_xcoff_bfd_merge_sections): Define.
3159 2001-05-11 Nick Clifton <nickc@cambridge.redhat.com>
3161 * dwarf1.c (_bfd_dwarf1_find_nearest_line): Change type of 'addr'
3162 to be unsigned long, in order to match its use.
3164 2001-05-10 H.J. Lu <hjl@gnu.org>
3166 * linker.c (_bfd_generic_link_add_one_symbol): Check loop on
3169 2001-05-09 H.J. Lu <hjl@gnu.org>
3171 * elflink.h (elf_link_add_object_symbols): Fix a typo. Allocate
3172 versymhdr->sh_size bytes for extversym instead of hdr->sh_size.
3173 Remove the unused veriable `dynver'.
3175 2001-05-08 Ian Lance Taylor <ian@zembu.com>
3177 * coff-i386.c (coff_i386_reloc): Don't dump core if output_bfd is
3178 NULL or is not COFF.
3179 (coff_i386_rtype_to_howto): Don't dump core if output section
3182 2001-05-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3184 * ecoff.c (bfd_debug_section): Fix initialization.
3185 * elf.c (_bfd_elf_slurp_version_tables): Change maxidx to unsigned, it
3186 is always a positive integer. Cast away sign mismatch.
3187 * elf32-mips.c: Fix misleading comment and typo.
3188 (_bfd_mips_elf_section_from_bfd_section): Remove unused attribute, use
3190 * elflink.c: Fix typo.
3191 (_bfd_elf_create_dynamic_sections): Remove superfluous initialization.
3192 * ecoffswap.h (ecoff_swap_fdr_in): Cast away sign mismatch.
3194 2001-05-04 Richard Henderson <rth@redhat.com>
3196 * elf64-alpha.c (SREL16, SREL32, SREL64): Set pcrel_offset true.
3198 2001-05-04 Nick Clifton <nickc@cambridge.redhat.com>
3200 * elf32-arm.h (elf32_arm_final_link_relocate): Set
3201 EF_ARM_HASENTRY if the start address is set.
3203 2001-05-03 Nick Clifton <nickc@cambridge.redhat.com>
3205 * targets.c (_bfd_target_vector_entries): Compute value based on
3206 the size of the _bfd_target_vector and not bfd_target_vector.
3208 2001-05-03 H.J. Lu <hjl@gnu.org>
3210 * elfcode.h: Include "libiberty.h".
3212 * elflink.h (elf_link_add_object_symbols): Set
3213 elf_dt_name (abfd) to basename of the bfd filename.
3214 (NAME(bfd_elf,size_dynamic_sections)): Set vn_file to basename
3215 of the bfd filename.
3217 2001-05-03 Andreas Jaeger <aj@suse.de>
3219 * elf64-gen.c (elf_generic_info_to_howto): Add unused attribute.
3220 (elf_generic_info_to_howto_rel): Likewise.
3221 * coff-alpha.c (reloc_nil): Likewise.
3222 (alpha_ecoff_bad_format_hook): Likewise.
3223 (alpha_adjust_reloc_out): Likewise.
3224 (alpha_bfd_reloc_type_lookup): Likewise.
3225 (alpha_convert_external_reloc): Likewise.
3226 * elf64-alpha.c (elf64_alpha_reloc_nil): Likewise.
3227 (elf64_alpha_reloc_bad): Likewise.
3228 (elf64_alpha_reloc_gpdisp): Likewise.
3229 (elf64_alpha_bfd_reloc_type_lookup): Likewise.
3230 (elf64_alpha_info_to_howto): Likewise.
3231 (elf64_alpha_add_symbol_hook): Likewise.
3232 (elf64_alpha_create_got_section): Likewise.
3233 (elf64_alpha_is_local_label_name): Likewise.
3234 (elf64_alpha_merge_ind_symbols): Likewise.
3235 * elf64-mips.c (mips_elf64_reloc_type_lookup): Likewise.
3236 (mips_elf64_get_reloc_upper_bound): Likewise.
3237 * nlm32-alpha.c (nlm_alpha_mangle_relocs): Likewise.
3238 (nlm_alpha_get_public_offset): Likewise.
3240 2001-05-02 Johan Rydberg <jrydberg@opencores.org>
3242 * elf32-openrisc.c (openrisc_elf_howto_table): Do not complain
3243 about overflow in R_OPENRISC_LO_16_IN_INSN and
3244 R_OPENRISC_HI_16_IN_INSN.Index: bfd/elf32-openrisc.c
3246 2001-04-30 H.J. Lu <hjl@gnu.org>
3248 * elf.c (_bfd_elf_link_hash_hide_symbol): Set dynindx to -1
3249 only for ELF_LINK_FORCED_LOCAL.
3250 * elf32-hppa.c (elf32_hppa_hide_symbol): Likewise.
3251 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Likewise.
3252 * elfxx-ia64.c (elfNN_ia64_hash_hide_symbol): Likewise.
3254 * elflink.h (elf_fix_symbol_flags): Set ELF_LINK_FORCED_LOCAL
3255 if the symbol has hidden or internal visibility.
3257 2001-04-30 Alan Modra <amodra@one.net.au>
3259 * elf32-hppa.c (final_link_relocate): Branch to .+8 for
3260 calls to undefined weak symbols.
3262 2001-04-30 Andreas Jaeger <aj@suse.de>, Andreas Schwab <schwab@suse.de>
3264 * elf64-x86-64.c (elf64_x86_64_relocate_section): Correct test for
3265 R_X86_64_GOTPCREL, don't use assignments instead of comparisons.
3267 2001-04-27 Andreas Jaeger <aj@suse.de>
3269 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_sections): Only swap
3270 out handled entries.
3271 (elf64_x86_64_finish_dynamic_symbol): Set up GOT entries.
3272 (elf64_x86_64_relocate_section): Fix GOTPCREL calculation.
3273 (elf64_x86_64_relocate_section): Merge entries for GOTPCREL and
3276 2001-04-27 Sean McNeil <sean@mcneil.com>
3278 * config.bfd: Add arm-vxworks target.
3279 * coff-arm (coff_arm_relocate_section): Add in symbol value to
3280 addend (fro VXworks targets).
3282 2001-04-26 H.J. Lu <hjl@gnu.org>
3284 * elf32-i386.c (elf_i386_check_relocs): Verify if r_symndx is
3287 2001-04-25 Frank Ch. Eigler <fche@redhat.com>
3289 * bfd-in.h (bfd_cache_close): Declare newly exported function.
3290 * bfd-in2.h: Regenerated.
3292 2001-04-24 Jakub Jelinek <jakub@redhat.com>
3294 * merge.c (struct sec_merge_hash_entry): Add alignment field.
3295 (struct sec_merge_hash): Remove alignment_power.
3296 (sec_merge_hash_newfunc): Clear alignment.
3297 (sec_merge_hash_lookup): Pass alignment as argument.
3298 Use hashp->root.next, not hashp->next to walk the hash chain.
3299 If a string already in the hashtable does not have required
3300 alignment, create a new hashtable entry.
3301 (sec_merge_init): Remove alignment_power argument.
3302 (sec_merge_add): Add alignment argument.
3303 (sec_merge_emit): Alignment is now a per-entity thing, not per
3305 (_bfd_merge_section): Sanity check even non-SEC_STRINGS sections
3306 for proper alignment.
3307 Pass alignment information to sec_merge_add.
3309 2001-04-24 Christian Groessler <cpg@aladdin.de>
3311 * coff-z8k.c (extra_case): added handler for R_DISP7, R_CALLR
3312 and R_REL16 reloc types; accept odd values for R_REL16 type
3314 2001-04-24 Johan Rydberg <jrydberg@opencores.org>
3316 * cpu-openrisc.c: New file.
3317 * elf32-openrisc.c: Likewise.
3319 * Makefile.am (ALL_MACHINES): Add cpu-openrisc.lo.
3320 (ALL_MACHINES_CFILES): Add cpu-openrisc.c.
3321 (BFD32_BACKENDS): Add elf32-openrisc.lo.
3322 (BFD32_BACKENDS_CFILES): Add elf32-openrisc.c.
3323 (cpu-openrisc.lo, elf32-openrisc.lo): New rules.
3324 * Makefile.in: Regenerated.
3325 * config.bfd: (openrisc-*-elf): New target.
3326 * configure.in (bfd_elf32_openrisc_vec): New vector.
3327 * configure: Regenerated.
3328 * libbfd.h: Regenerated.
3329 * bfd-in2.h: Regenerated.
3330 * reloc.c: Add OpenRISC relocations.
3331 * targets.c (bfd_elf32_openrisc_vec): Declare.
3332 (bfd_target_vect): Add bfd_elf32_openrisc_vec.
3333 * archures.c (enum bfd_architecture): Add bfd_arch_openrisc.
3334 (bfd_openrisc_arch): Declare.
3335 (bfd_archures_list): Add bfd_openrisc_arch.
3336 * elf.c (prep_headers): Add bfd_arch_openrisc.
3338 2001-04-23 Bo Thorsen <bo@suse.de>
3340 * elf64-x86-64.c: Add c++ vtable hack.
3341 Small whitespace and comment changes.
3343 2001-04-19 Andreas Jaeger <aj@suse.de>
3345 * elf64-x86-64.c (elf64_x86_64_plt0_entry): Fix instructions.
3346 (elf64_x86_64_plt_entry): Likewise.
3347 (elf64_x86_64_finish_dynamic_sections): Fix PLT0 generation.
3348 (elf64_x86_64_finish_dynamic_symbol): Fix PLT generation.
3350 2001-04-17 Hans-Peter Nilsson <hp@axis.com>
3352 * elf32-cris.c: Tweak comments related to dynamic linking.
3353 (cris_elf_relocate_section): When not creating shared object, fill
3354 in the .got table for any symbol not in the dynamic symbol table.
3355 (elf_cris_finish_dynamic_symbol): When not creating shared object,
3356 only emit a .got.rela reloc if the symbol is in the dynamic symbol
3358 (cris_elf_check_relocs): Use variable r_type in all places rather
3359 than the original expression. Add default case in switch for
3361 (elf_cris_size_dynamic_sections): Iterate over
3362 elf_cris_discard_excess_program_dynamics when not creating shared
3364 (elf_cris_discard_excess_dso_dynamics): Renamed from
3365 elf_cris_discard_copies. Correct typo, s/Rel/Rela/.
3366 (elf_cris_discard_excess_program_dynamics): New.
3368 2001-04-14 Mark Elbrecht <snowball3@bigfoot.com>
3370 * coffcode.h (coff_write_object_contents): Use
3371 bfd_coff_swap_filehdr_out instead of coff_swap_filehdr_out.
3373 2001-04-14 H.J. Lu <hjl@gnu.org>
3375 * bfd-in2.h: Regenerate.
3377 2001-04-14 Jakub Jelinek <jakub@redhat.com>
3379 * section.c (STD_SECTION): Add entsize.
3381 2001-04-13 H.J. Lu <hjl@gnu.org>
3383 * section.c (SEC_MERGE): Define new flag for merging.
3384 (SEC_STRINGS): Likewise.
3385 (entsize): New field.
3387 2001-04-13 Roger Sayle <roger@metaphorics.com>
3389 * coff-i386.c (TARGET_SYM): SEC_READONLY is an applicable section
3390 flag on pe-i386 targets.
3392 2001-04-13 Jakub Jelinek <jakub@redhat.com>
3394 * libbfd-in.h (_bfd_merge_section): New.
3395 (_bfd_write_merged_section): New.
3396 (_bfd_merged_section_offset): New.
3397 * libbfd.h: Rebuilt.
3398 * linker.c (_bfd_generic_link_output_symbols): Handle
3400 * aoutx.h (aout_link_write_symbols): Likewise.
3401 * pdp11.c (aout_link_write_symbols): Likewise.
3402 * elflink.h (elf_link_add_object_symbols): Call _bfd_merge_section.
3403 (elf_bfd_final_link): Adjust global symbols pointing into SEC_MERGE
3405 (elf_link_sec_merge_syms): New.
3406 (elf_link_input_bfd): Call _bfd_merged_section_offset
3407 and _bfd_write_merged_section.
3408 Handle discard_sec_merge.
3409 * elf-bfd.h (struct elf_link_hash_table): Add merge_info
3411 (struct bfd_elf_section_data): Likewise.
3412 * elf.c (_bfd_elf_make_section_from_shdr): Set SEC_MERGE and
3413 SEC_STRINGS section flags and entsize from their ELF counterparts.
3414 (_bfd_elf_link_hash_table_init): Initialize merge_info.
3415 (elf_fake_sections): Set SHF_MERGE, SHF_STRINGS and sh_entsize
3416 from their BFD counterparts.
3417 * merge.c: New file.
3418 * Makefile.am: Add strtab.lo.
3419 * Makefile.in: Rebuilt.
3421 2001-04-09 Hans-Peter Nilsson <hp@axis.com>
3423 * elflink.h (elf_fix_symbol_flags): For non-default visibilities,
3424 only hide symbols marked STV_INTERNAL or STV_HIDDEN.
3426 2001-04-05 Steven J. Hill <sjhill@cotw.com>
3428 * config.bfd (mips*el*-*-linux-gnu*): Use traditional little
3429 endian MIPS ELF target.
3430 * config.bfd (mips*-*-linux-gnu*): Use traditional big endian
3433 * configure.in (bfd_elf64_tradbigmips_vec): New. Traditional
3434 64bit big endian MIPS ELF target.
3435 (bfd_elf64_tradlittlemips_vec): New. Traditional 64bit little
3436 endian MIPS ELF target.
3437 * configure: Regenerated.
3439 * elf32-mips.c (IRIX_COMPAT): Handle traditional 64bit and
3440 little endian targets.
3441 (mips_elf_sym_is_global): Handle traditional targets.
3443 * elf64-mips.c (bfd_elf64_tradbigmips_vec): New. Traditional
3444 64bit big endian MIPS ELF target.
3445 (bfd_elf64_tradlittlemips_vec): New. Traditional 64bit little
3446 endian MIPS ELF target.
3448 * targets.c: (_bfd_target_vector): Add bfd_elf64_tradbigmips_vec
3449 and bfd_elf64_tradlittlemips_vec.
3451 2001-04-05 David Mosberger <davidm@hpl.hp.com>
3453 * elf32-i386.c (elf_i386_fake_sections): Treat ".reloc" as an
3454 ordinary "progbits" section.
3456 2001-04-04 Alan Modra <alan@linuxcare.com.au>
3458 * elflink.h (elf_fix_symbol_flags): Call elf_backend_hide_symbol
3459 when -Bsymbolic causes a symbol to no longer need a .plt entry.
3461 2001-04-03 David Mosberger <davidm@hpl.hp.com>
3463 * efi-app-ia32.c (ALIGN_SECTIONS_IN_FILE): Deleted.
3465 2001-03-30 H.J. Lu <hjl@gnu.org>
3467 * efi-app-ia32.c (PEI_TARGET_SUBSYSTEM): Rename from ...
3468 (PEI_DEFAULT_TARGET_SUBSYSTEM): This.
3470 2001-03-26 H.J. Lu <hjl@gnu.org>
3472 * elf32-gen.c (elf32_generic_link_add_symbols): New. Check
3473 if there are any relocations for generic ELF.
3474 (bfd_elf32_bfd_link_add_symbols): Defined to
3475 elf32_generic_link_add_symbols.
3476 * elf64-gen.c (elf64_generic_link_add_symbols): New. Check
3477 if there are any relocations for generic ELF.
3478 (bfd_elf64_bfd_link_add_symbols): Defined to
3479 elf64_generic_link_add_symbols.
3481 2001-03-23 Nick Clifton <nickc@redhat.com>
3483 * Makefile.am (BUILD_CFILES): New variable: List of C source
3484 files created in build directory.
3485 (BUILD_HFILES): New variable: List of header files created in
3488 (po/POTFILES.in): Replace rule with empty entry.
3489 (po/SRC-POTFILES.in): New rule: Create a list of source files
3490 in the source directory.
3491 (po/BLD-POTFILES.in): New rule: Create a list of source files
3492 in the build directory.
3493 (MOSTLYCLEAN): Do not delete source files created in build
3495 * Makefile.in: Regenerate.
3496 * configure.in: Insert SRC-POTFILES.in and BLD-POTFILES.in
3498 * configure: Regenerate.
3500 * po/Make-in: Replace occurrences of POTFILES with SRC-POTFILES
3502 Add .. to the search path when building bfd.pot.
3503 Delete POTFILES when performing distclean.
3504 Add comment describing why distclean is broken in maintainer mode.
3505 * po/POTFILES.in: Delete.
3506 * po/SRC-POTFILES.in: New file.
3507 * po/BLD-POTFILES.in: New file.
3508 * po/bfd.pot: Regenerate.
3510 2001-03-22 Hans-Peter Nilsson <hp@axis.com>
3512 * elf32-cris.c: Shlib and PIC support. PCREL tweaks.
3513 (elf_cris_discard_copies, elf_cris_adjust_gotplt_to_got,
3514 elf_cris_try_fold_plt_to_got, elf_cris_link_hash_newfunc,
3515 elf_cris_link_hash_table_create, elf_cris_adjust_dynamic_symbol,
3516 elf_cris_size_dynamic_sections, elf_cris_finish_dynamic_symbol,
3517 elf_cris_finish_dynamic_sections,elf_cris_hide_symbol): New
3519 (cris_elf_howto_table) <R_CRIS_8_PCREL, R_CRIS_16_PCREL,
3520 R_CRIS_32_PCREL>: Correct comments. Set pcrel_offset to false.
3521 <R_CRIS_COPY, R_CRIS_GLOB_DAT, R_CRIS_JUMP_SLOT, R_CRIS_RELATIVE,
3522 R_CRIS_16_GOT, R_CRIS_32_GOT, R_CRIS_16_GOTPLT, R_CRIS_32_GOTPLT,
3523 R_CRIS_32_GOTREL, R_CRIS_32_PLT_GOTREL, R_CRIS_32_PLT_PCREL>:
3524 New HOWTO members for new relocs.
3525 (cris_reloc_map): Map new relocs.
3526 (ELF_DYNAMIC_INTERPRETER): Define.
3527 (PLT_ENTRY_SIZE): Define.
3528 (elf_cris_plt0_entry, elf_cris_plt_entry, elf_cris_pic_plt0_entry,
3529 elf_cris_pic_plt_entry): New, PLT templates.
3530 (struct elf_cris_pcrel_relocs_copied, struct
3531 elf_cris_link_hash_entry, struct elf_cris_link_hash_table): New.
3532 (elf_cris_link_hash_traverse, elf_cris_hash_table): Define.
3533 (cris_final_link_relocate): Check that 16-bit GOT relocs have
3534 positive values. Adjust PCREL relocs to be relative to location
3536 (cris_elf_relocate_section): Handle relocations to dynamic
3537 objects. Handle new relocations. Call error handler when seeing
3538 non-PIC relocation for read-only sections while generating shared
3540 (cris_elf_check_relocs): Set reference counts for GOT and PLT
3542 (bfd_elf32_bfd_link_hash_table_create,
3543 elf_backend_adjust_dynamic_symbol,
3544 elf_backend_size_dynamic_sections,
3545 elf_backend_finish_dynamic_symbol,
3546 elf_backend_finish_dynamic_sections,
3547 elf_backend_create_dynamic_sections, bfd_elf32_bfd_final_link,
3548 elf_backend_hide_symbol, elf_backend_want_got_plt,
3549 elf_backend_plt_readonly, elf_backend_want_plt_sym,
3550 elf_backend_got_header_size, elf_backend_plt_header_size):
3553 * reloc.c: (BFD_RELOC_CRIS_COPY, BFD_RELOC_CRIS_GLOB_DAT,
3554 BFD_RELOC_CRIS_JUMP_SLOT, BFD_RELOC_CRIS_RELATIVE,
3555 BFD_RELOC_CRIS_32_GOT, BFD_RELOC_CRIS_16_GOT,
3556 BFD_RELOC_CRIS_32_GOTPLT, BFD_RELOC_CRIS_16_GOTPLT,
3557 BFD_RELOC_CRIS_32_GOTREL, BFD_RELOC_CRIS_32_PLT_GOTREL,
3558 BFD_RELOC_CRIS_32_PLT_PCREL): New relocs.
3559 * bfd-in2.h, libbfd.h: Regenerate.
3561 2001-03-21 Diego Novillo <dnovillo@redhat.com>
3563 (_bfd_mips_elf_relocate_section): Give a better error message when
3564 a relocation is not recognized.
3566 2001-03-21 Alan Modra <alan@linuxcare.com.au>
3568 * elf32-hppa.c (elf32_hppa_set_gp): Check sec->output_section
3569 non-NULL before attempting to dereference.
3571 2001-03-20 H.J. Lu <hjl@gnu.org>
3573 * configure.in: Remove the redundent AC_ARG_PROGRAM.
3574 * configure: Rebuild.
3576 2001-03-20 Andreas Schwab <schwab@suse.de>
3578 * elf32-m68k.c (elf_m68k_relocate_section): Don't need the
3579 relocation value when resolving a reference from a debugging
3582 2001-03-16 Scott Thomason <SThomaso@hii.com>
3584 * coff64-rs6000.c (xcoff64_swap_sym_out): Fix syntax errors.
3585 (xcoff64_swap_sym_out): Fix syntax errors.
3587 2001-03-16 Richard Sandiford <rsandifo@redhat.com>
3589 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix warning.
3591 2001-03-15 Alan Modra <alan@linuxcare.com.au>
3593 * elf32-hppa.c (elf32_hppa_link_hash_entry): Add maybe_pic_call.
3594 (hppa_link_hash_newfunc): Init it.
3595 (hppa_type_of_stub): Only use non-PIC to PIC call stub if caller
3596 section appears to be non-PIC.
3597 (final_link_relocate): Likewise.
3598 (elf32_hppa_adjust_dynamic_symbol): Set maybe_pic_call for any
3599 possible candidate function, and set pic_call for those that will
3600 only have a .plt entry for the PIC call stub.
3601 (hppa_handle_PIC_calls): Set maybe_pic_call.
3603 2001-03-12 DJ Delorie <dj@redhat.com>
3605 * elf32-sh.c (sh_elf_relocate_section): Only relocation
3606 R_SH_DIR8WP* relocs if they're against external symbols, else
3607 they're just for relaxing. Validate the reloc values.
3609 2001-03-12 Stefan Geuken <mail@stefan-geuken.de>
3611 * binary.c (bfd_external_binary_architecture): Declare.
3612 (binary_object_p): If bfd_external_binary_architecture is defined,
3613 set the architecture to this string.
3615 2001-03-11 Philip Blundell <philb@gnu.org>
3617 * elf32-arm.h (elf32_arm_finish_dynamic_symbol): Don't make PLT
3618 entries that could serve as a definition for a weak symbol.
3620 2001-03-08 Nick Clifton <nickc@redhat.com>
3622 * Most files: Update copyright notices using Perl script created
3623 by Kevin Buettner <kevinb@redhat.com>.
3625 2001-03-07 Nick Clifton <nickc@redhat.com>
3627 * elf32-arm.h (elf32_arm_final_link_relocate): Conditionalise
3628 prior patch on ! defined OLD_ARM_ABI.
3630 2001-03-07 Andreas Jaeger <aj@suse.de>
3632 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix handling of
3633 some relocation values.
3635 2001-03-06 Nick Clifton <nickc@redhat.com>
3637 * elf32-arm.h (elf32_arm_final_link_relocate): Clear bit zero
3638 of offset in BLX(1) instruction.
3639 * coff-arm.c (coff_arm_relocate_section): Clear bit zero of
3640 offset in BLX(1) instruction.
3643 2001-03-06 Nick Clifton <nickc@redhat.com>
3645 * coff-arm.c (coff_arm_reloc_type_lookup): Add
3646 BFD_RELOC_THUMB_PCREL_BLX.
3648 2001-03-06 Igor Shevlyakov <igor@windriver.com>
3650 * archures.c (bfd_default_scan): Add Coldfire CPUs.
3651 * bfd-in2.h: Regenerate.
3652 * cpu-m68k.c: Add Coldfire CPUs for arch table.
3653 * ieee.c (ieee_write_processor): Set proper id for
3656 2001-03-01 D.J. Barrow <djbarrow@de.ibm.com,barrow_dj@yahoo.com>
3658 * configure.in: Add s390 target.
3659 * configure: Regenerate.
3661 2001-02-28 Andreas Jaeger <aj@suse.de>
3663 * elf64-x86-64.c (elf64_x86_64_relocate_section): Add relocation
3666 2001-02-28 Philip Blundell <pb@futuretv.com>
3668 * elf32-arm.h: Update mentions of renamed EF_xx constants.
3669 (elf32_arm_print_private_bfd_data): Handle ARM EABI version 2.
3671 2001-02-27 H.J. Lu <hjl@gnu.org>
3673 * aoutx.h (NAME(aout,bfd_free_cached_info)): Return true if
3674 abfd->tdata.aout_data == NULL.
3676 2001-02-27 Alan Modra <alan@linuxcare.com.au>
3678 * elf32-hppa.c: Correct field selector in stub comments.
3679 (clobber_millicode_symbols): Formatting fix.
3681 * configure.in: Bump version to 2.11.90.
3682 * configure: Regenerate.
3683 * Makefile.am (CFILES): Rename to SOURCE_CFILES.
3684 (CFILES): $SOURCE_CFILES + generated C files.
3685 (POTFILES): Include $HFILES not $SOURCE_HFILES.
3687 * Makefile.in: Regenerate.
3688 * doc/Makefile.in: This too.
3690 2001-02-26 Timothy Wall <twall@cygnus.com>
3692 * elfxx-ia64.c (elfNN_ia64_aix_add_symbol_hook): Remove obsolete
3695 2001-02-26 Nick Clifton <nickc@redhat.com>
3697 * coffcode.h (styp_to_sec_flags) [COFF_WITH_PE version]: Tidy
3698 up, replacing multiple if statements with a switch.
3699 (handle_COMDAT): New function.
3701 2001-02-26 H.J. Lu <hjl@gnu.org>
3703 * coffcode.h (styp_to_sec_flags) [COFF_WITH_PE version]: Issue
3704 a warning for section flags we do not handle instead of
3707 2001-02-26 Andreas Jaeger <aj@suse.de>
3709 * elf64-x86-64.c (x86_64_elf_howto_table): Fix order of entries.
3711 2001-02-22 Timothy Wall <twall@cygnus.com>
3713 * config.bfd (targ_cpu): Add vectors for ia64-*-aix* (aka Monterey).
3714 * configure.in: Add objects for elf64_ia64_aix vectors.
3715 * configure: Regenerated.
3716 * configure.host: Recognize ia64-*-aix*.
3717 * elfxx-ia64.c: Add hooks for ELF64 on AIX5. Define new vectors
3718 for AIX. AIX5 requires most relocations to be dynamic (*all*
3719 binaries are somewhat similar to shared libraries).
3720 * targets.c: Add elf64_ia64_aix vectors.
3722 2001-02-21 David Mosberger <davidm@hpl.hp.com>
3724 * cpu-ia64-opc.c (elf64_ia64_operands}: Fix typo: error string for
3725 C8 said "1" instead of "8". Clarify error string for IMM22:
3726 "signed integer" instead of just "integer".
3728 2001-02-20 Andreas Jaeger <aj@suse.de>
3730 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_symbol): Don't make
3731 PLT entries that could serve as a definition for a weak symbol.
3733 2001-02-19 Jakub Jelinek <jakub@redhat.com>
3735 * elf32-sparc.c (elf32_sparc_finish_dynamic_symbol): Don't make PLT
3736 entries that could serve as a definition for a weak symbol.
3737 * elf64-sparc.c (sparc64_elf_finish_dynamic_symbol): Likewise.
3739 2001-02-18 David O'Brien <obrien@FreeBSD>
3741 * configure.in: Recognize FreeBSD/arm, FreeBSD/PowerPC, and treat
3742 FreeBSD/i386-CURRENT differently until I can figure out the needed
3744 * configure: Regenerate.
3745 * config.bfd: Recognize FreeBSD/x86-64, FreeBSD/ia64, FreeBSD/arm,
3746 FreeBSD/PowerPC, and FreeBSD/sparc64.
3748 2001-02-18 lars brinkhoff <lars@nocrew.org>
3750 * Makefile.am: Add PDP-11 a.out target.
3751 * config.bfd: Likewise.
3752 * configure.in: Likewise.
3753 * targets.c: Likewise.
3754 * archures.c: Likewise.
3755 * bfd-in2.h: Likewise. Add PDP-11 relocations.
3756 * libbfd.h: Add PDP-11 relocations.
3757 * reloc.c: Likewise.
3758 * cpu-pdp11.c: New file.
3759 * pdp11.c: New file.
3761 * libaout.h (GET_WORD) [ARCH_SIZE==16]: Define.
3762 (GET_SWORD) [ARCH_SIZE==16]: Likewise.
3763 (GET_SWORD) [ARCH_SIZE==16]: Likewise.
3764 (PUT_WORD) [ARCH_SIZE==16]: Likewise.
3765 (GET_MAGIC): New macro.
3766 (PUT_MAGIC): Likewise.
3767 * aout-target.h (MY(object_p)): Use GET_MAGIC to read magic word.
3769 2001-02-18 Jim Kingdon <jkingdon@engr.sgi.com>
3771 * irix-core.c (irix_core_core_file_p): Set the architecture (GDB
3772 multiarch needs it).
3774 2001-02-18 H.J. Lu <hjl@gnu.org>
3776 * elflink.h (elf_link_input_bfd): Ignore invalid section symbol
3779 2001-02-18 Kazu Hirata <kazu@hxi.com>
3781 * vms-misc.c: Fix formatting.
3783 2001-02-16 Kazu Hirata <kazu@hxi.com>
3785 * vms.c: Fix formatting.
3787 2001-02-14 H.J. Lu <hjl@gnu.org>
3789 * elf.c (elf_find_function): New function.
3790 (_bfd_elf_find_nearest_line): Call elf_find_function () to find
3791 the file name and function name.
3793 2001-02-14 Nick Clifton <nickc@redhat.com>
3795 * ecoff.c (bfd_debug_section): Update to initialise new fields in
3798 * Makefile.am (BFD32_BACKENDS_CFILES): Remove peigen.c
3799 (BFD64_BACKENDS): Add pepigen.c
3800 Add rules to create peigen.c and pepigen.c from peXXigen.c.
3802 * Makefile.in: Regenerate.
3803 * configure: Regenerate.
3804 * po/POTFILES.in: Regenerate.
3805 * po/bfd.pot: Regenerate.
3807 2001-02-14 H.J. Lu <hjl@gnu.org>
3809 * libcoff-in.h (pe_tdata): Add members target_subsystem and
3810 force_minimum_alignment.
3812 2001-02-14 Bo Thorsen <bo@suse.de>
3814 * elf64-x86-64.c: Small formatting fixes and rearrangements of code.
3815 (elf64_86_64_size_info): Struct added to fix a problem
3816 with the hashtable string entries.
3817 (elf64_x86_64_adjust_dynamic_symbol): Add generation of .got.plt.
3818 (elf64_x86_64_size_dynamic_sections): A FIXME removed.
3819 (elf64_x86_64_size_dynamic_sections): Fix a dynamic entry and
3820 remove the FIXME for this.
3821 (elf64_x86_64_adjust_dynamic_symbol): Fix check for unneeded .plt
3822 section. Also removed the FIXME for it.
3823 (x86_64_elf_howto_table): Use bfd_elf_generic_reloc.
3824 (ELF_DYNAMIC_INTERPRETER): Fix the name of the dynamic linker.
3825 (elf64_x86_64_finish_dynamic_sections): Enable .got.plt writing.
3827 2001-02-13 Richard Henderson <rth@redhat.com>
3829 * elfxx-ia64.c (elfNN_ia64_final_link): Set __gp if required
3830 and not user provided.
3832 2001-02-13 Kazu Hirata <kazu@hxi.com>
3834 * vms.c (vms_print_symbol): Remove unreachable code.
3836 * rs6000-core.c: Fix formatting.
3838 2001-02-13 David Mosberger <davidm@hpl.hp.com>
3840 * peicode.h (coff_swap_filehdr_out) [COFF_IMAGE_WITH_PE]: Define
3841 as _bfd_XXi_only_swap_filehdr_out.
3842 (pe_mkobject) [PEI_FORCE_MINIMUM_ALIGNMENT]: Set
3843 pe->force_minimum_alignment to TRUE.
3844 (pe_mkobject) [PEI_TARGET_SUBSYSTEM]: Set pe->target_subsystem to
3845 PEI_TARGET_SUBSYSTEM.
3846 (pe_print_private_bfd_data): Call
3847 _bfd_XX_print_private_bfd_data_common() instead of
3848 _bfd_pe_print_private_bfd_data_common().
3849 (pe_bfd_copy_private_bfd_data): Call
3850 _bfd_XX_bfd_copy_private_bfd_data_common() instead of
3851 _bfd_pe_bfd_copy_private_bfd_data_common().
3852 (coff_bfd_copy_private_section_data): Define as
3853 _bfd_XX_bfd_copy_private_section_data instead of
3854 _bfd_pe_bfd_copy_private_section_data.
3855 (coff_get_symbol_info): Define as _bfd_XX_get_symbol_info instead
3856 of a _bfd_pe_get_symbol_info.
3860 * peXXigen.c: Renamed from peigen.c.
3861 (COFF_WITH_XX): Define this macro (will get expanded into
3862 COFF_WITH_pep or COFF_WITH_pe, depending on whether this is being
3863 compiled as peigen.c or pepigen.c.
3864 [COFF_WITH_pep]: Include "coff/ia64.h" instead of "coff/i386.h" to
3865 define the canonical PEP structures and definitions.
3866 (_bfd_XXi_swap_aouthdr_out): If pe->force_minimum_alignment is in
3867 effect, enforce minimum file and section alignments. If
3868 extra->Subsystem is IMAGE_SUBSYSTEM_UNKNOWN, set it to
3869 pe->target_subsystem (this defaults to IMAGE_SUBSYSTEM_UNKNOWN,
3870 so, by default, this is a no-op).
3872 * libpei.h: Rename COFF_WITH_PEP to COFF_WITH_pep.
3873 (_bfd_XX_bfd_copy_private_bfd_data_common): Add macros to map
3874 _bfd_XXfoo to _bfd_pepfoo if COFF_WIT_PEP is defined and to
3875 _bfd_pefoo if it's not defined. Use these macros to define
3878 * libcoff.h (pe_tdata): Add members target_subsystem and
3879 force_minimum_alignment.
3881 * efi-app-ia64.c (COFF_WITH_pep): Rename COFF_WITH_PEP to
3883 (PEI_TARGET_SUBSYSTEM): Rename from PEI_DEFAULT_TARGET_SUBSYSTEM.
3885 * configure.in (bfd_efi_app_ia64_vec): Use pepigen.lo instead of
3888 * coff-ia64.c: Rename COFF_WITH_PEP to COFF_WITH_pep.
3889 (AOUTSZ): Rename PEP64AOUTSZ and PEP64AOUTHDR to PEPAOUTSZ and
3892 * Makefile.in (BFD64_BACKENDS): Mention pepigen.lo.
3893 (BFD64_BACKENDS_CFILES): Mention pepigen.c
3894 (peigen.c): Add rule to generate from peXXigen.c.
3896 (pepigen.lo): List dependencies for pepigen.lo.
3898 2001-02-13 Alan Modra <alan@linuxcare.com.au>
3900 * elf32-hppa.c (elf32_hppa_set_gp): Handle weak $global$. If
3901 $global$ referenced but not defined, set its value here.
3903 2001-02-09 Bo Thorsen <bo@suse.de>
3905 * elf64-x86-64.c (elf64_x86_64_check_relocs): Set .rela.got section
3907 (elf64_x86_64_check_relocs): Write R_X86_64_GOTPCREL GOT entry
3909 (elf64_x86_64_relocate_section): Fix formatting.
3910 (elf64_x86_64_relocate_section): Fix addend for relocation of
3911 R_X86_64_(8|16|32|PC8|PC16|PC32).
3913 2001-02-12 Jan Hubicka <jh@suse.cz>
3915 * elf64-x86-64.c (x86_64_elf_howto): Fix name of R_X86_64_GOTPCREL.
3917 2001-02-11 H.J. Lu <hjl@gnu.org>
3919 * elflink.h (elf_bfd_final_link): Use file_align for SYMTAB
3922 2001-02-11 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
3924 * elf32-mips.c (mips_elf_create_dynamic_relocation): Undo patch
3925 from 2000-10-13. Do not add the symbol's value for R_MIPS_REL32
3926 relocations against dynsym symbols.
3928 * elf32-mips.c (elf_mips_howto_table): Fix the comment on
3929 the R_MIPS_26 relocation.
3930 (mips_elf_calculate_relocation): Use (p + 4) instead of p for
3931 the R_MIPS_26 relocation.
3932 (mips_elf_perform_relocation): Fix the comment on the R_MIPS16_26
3934 * elf64-mips.c (mips_elf64_howto_table_rel): Fix the comment on
3935 the R_MIPS_26 relocation.
3936 (mips_elf64_howto_table_rela): Likewise.
3938 * elf32-mips.c (struct mips_elf_link_hash_entry): Added no_fn_stub
3939 member to mark symbols that have non-CALL relocations against
3941 (mips_elf_link_hash_newfunc): Initialize no_fn_stub.
3942 (mips_elf_calculate_relocation): Handle R_MIPS_CALL16 like
3944 (_bfd_mips_elf_check_relocs): Set no_fn_stub for a symbol if a
3945 non-CALL relocation against it is encountered.
3946 (_bfd_mips_elf_copy_indirect_symbol): Merge no_fn_stub as well.
3947 (_bfd_mips_elf_adjust_dynamic_symbol): Only create a stub if
3948 no_fn_stub is not set.
3950 * elf32-mips.c (mips_elf_output_extsym): Get the output section
3951 information from the real symbol for indirect ones.
3952 Check no_fn_stub to find out if a symbol has a function stub
3955 2001-02-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
3957 * Makefile.am (stamp-lib): ranlib the libbfd.a in the build directory.
3958 * Makefile.in: Regenerate.
3960 2001-02-09 David Mosberger <davidm@hpl.hp.com>
3962 * elfxx-ia64.c (is_unwind_section_name): New function. Returns
3963 true if section name is an unwind table section name.
3964 (elfNN_ia64_additional_program_headers): Count each unwind section
3966 (elfNN_ia64_modify_segment_map): Install one unwind program header
3967 for each unwind separate section. Note: normally the linker
3968 script merges the unwind sections that go into a single segment,
3969 so this still generates at most one unwind program header per
3972 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Accept any section
3973 name for SHT_IA_64_UNWIND, not just .IA_64.unwind.
3974 (elfNN_ia64_fake_sections): Mark sections with names that start
3975 with .IA_64.unwind but not with .IA_64.unwind_info as an IA-64
3978 * elfxx-ia64.c (elfNN_ia64_final_write_processing): New function.
3979 Use it to make sh_info in unwind section point to the text section
3982 2001-02-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
3984 * Makefile.am: Add linux target for S/390.
3985 * archures.c: Likewise.
3986 * bfd-in2.h: Likewise.
3987 * config.bfd: Likewise.
3988 * configure.in: Likewise.
3990 * libbfd.h: Likewise.
3991 * targets.c: Likewise.
3992 * cpu-s390.c: New file.
3993 * elf32-s390.c: New file.
3994 * elf64-s390.c: New file.
3996 2001-02-09 Nick Clifton <nickc@redhat.com>
3998 * peigen.c (_bfd_pe_get_symbol_info): Suppress addition of
3999 ImageBase. This has already been done by coff_swap_hdr_in.
4001 2001-02-09 Jakub Jelinek <jakub@redhat.com>
4003 * elf64-sparc.c (sparc64_elf_copy_private_bfd_data): New function.
4005 2001-02-09 Jakub Jelinek <jakub@redhat.com>
4007 * elf64-sparc.c (sparc64_elf_check_relocs): Don't trust reloc_count.
4008 (sparc64_elf_relocate_section): Likewise.
4010 2001-02-09 Mark Kettenis <kettenis@gnu.org>
4012 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Treat R_SPARC_UA32
4013 similar to R_SPARC_32.
4014 * elf64-sparc.c (sparc64_elf_howto_table): Likewise.
4016 2001-02-08 H.J. Lu <hjl@gnu.org>
4018 * elf32-i386.c (elf_i386_check_relocs): Reserve R_386_PC32
4019 relocation entries for weak definitions when building DSO with
4022 2001-02-08 Richard Henderson <rth@redhat.com>
4024 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Respect weakness
4025 before visibility. Locally defined protected symbols are not
4028 2001-02-08 Geoffrey Keating <geoffk@redhat.com>
4030 * config.bfd: Enable coff64 for rs6000-*. Patch from
4031 <hzoli@austin.ibm.com>.
4033 2001-02-07 Mark Elbrecht <snowball3@bigfoot.com>
4035 * coffgen.c (coff_find_nearest_line): If stabs info is successfully
4036 found, do not attempt to find dwarf2 info before returning.
4038 2001-02-07 Jakub Jelinek <jakub@redhat.com>
4040 * elflink.h (is_global_symbol_definition): Rename to
4041 is_global_data_symbol_definition and have it reject function
4043 (elf_link_is_defined_archive_symbol): Use renamed function.
4045 2001-02-07 Todd Vierling <tv@wasabisystems.com>
4047 * libbfd-in.h (bfd_target_vector): Change extern array to pointer.
4048 * libbfd.h (bfd_target_vector): Likewise.
4049 * targets.c (bfd_target_vector): Rename to _bfd_target_vector and
4050 make static; create pointer reference named bfd_target_vector.
4051 (_bfd_target_vector_entries): Calculate this based on the array
4052 typed _bfd_target_vector.
4054 2001-02-06 H.J. Lu <hjl@gnu.org>
4056 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Only hidden and
4057 internal symbols are not dynamic.
4058 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise.
4060 2001-02-06 Nick Clifton <nickc@redhat.com>
4062 * Makefile.am (BFD64_BACKENDS_CFILES): Remove elf64-ia64.c, so
4063 that it will not be pulled into the list of files that make up
4065 * Makefile.in: Regenerate.
4066 * po/bfd.pot: Regenerate.
4068 2001-02-06 H.J. Lu <hjl@gnu.org>
4070 * peicode.h (coff_swap_filehdr_in): Remove the e_magic
4072 (pe_bfd_object_p): Rewrite with external_PEI_DOS_hdr and
4073 external_PEI_IMAGE_hdr.
4075 2001-02-06 Kazu Hirata <kazu@hxi.com>
4077 * elf-m10200.c: Fix formatting.
4079 2001-02-04 Nick Clifton <nickc@redhat.com>
4081 * elf32-v850.c (v850_elf_reloc): Do not convert reloc addend to PC
4082 rel, it will be handled later on.
4084 2001-02-02 Fred Fish <fnf@ninemoons.com>
4086 * Makefile.in: Fix typo.
4088 2001-02-01 Kazu Hirata <kazu@hxi.com>
4090 * elf-m10300.c: Fix formatting.
4092 2001-01-30 Alan Modra <alan@linuxcare.com.au>
4094 * elf64-hppa.c (elf64_hppa_elf_get_symbol_type): New function.
4095 (elf_backend_get_symbol_type): Define.
4096 (elf64_hppa_object_p): Set architecture and machine from elf
4099 2001-01-30 Curtis L. Janssen <cljanss@ca.sandia.gov>
4101 * elf64-alpha.c (elf64_alpha_find_nearest_line): Query dwarf2
4104 2001-01-26 Richard Henderson <rth@redhat.com>
4106 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Return false
4107 for non-default visibility.
4108 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise, but
4109 delete ugly macro and replace with pretty function.
4111 2001-01-25 Mark Elbrecht <snowball3@bigfoot.com>
4113 * coff-go32.c: Update copyright.
4114 * coff-stgo32.c: Likewise.
4115 * coff-go32.c (COFF_LONG_FILENAMES): Define.
4116 * coff-stgo32.c (COFF_LONG_FILENAMES): Likewise.
4117 * coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Remove .bss entry.
4118 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
4120 2001-01-25 Kazu Hirata <kazu@hxi.com>
4122 * bfd-in2.h: Rebuild.
4123 * libbfd.h: Likewise.
4125 2001-01-23 H.J. Lu <hjl@gnu.org>
4127 * bfd-in2.h: Rebuild.
4129 2001-01-23 H.J. Lu <hjl@gnu.org>
4131 * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_buf)
4132 is NULL or PRIV(vms_rec) is outside of the buffer.
4134 2001-01-23 Kazu Hirata <kazu@hxi.com>
4136 * coff64-rs6000.c: Fix formatting.
4137 * coff-arm.c: Likewise.
4138 * coffgen.c: Likewise.
4139 * cofflink.c: Likewise.
4140 * coff-mcore.c: Likewise.
4141 * coff-mips.c: Likewise.
4142 * coff-pmac.c: Likewise.
4143 * coff-ppc.c: Likewise.
4144 * coff-rs6000.c: Likewise.
4145 * elf32.c: Likewise.
4146 * elf32-fr30.c: Likewise.
4147 * elf32-i370.c: Likewise.
4148 * elf32-i860.c: Likewise.
4149 * elf32-m32r.c: Likewise.
4150 * elf32-m68k.c: Likewise.
4151 * elf32-mcore.c: Likewise.
4152 * elf32-ppc.c: Likewise.
4153 * elf32-sh.c: Likewise.
4154 * elf32-v850.c: Likewise.
4155 * elf64-alpha.c: Likewise.
4156 * elf64-sparc.c: Likewise.
4157 * elflink.c: Likewise.
4158 * elflink.h: Likewise.
4159 * elf-m10200.c: Likewise.
4160 * elf-m10300.c: Likewise.
4161 * elfxx-ia64.c: Likewise.
4163 * aoutx.h: Fix formatting.
4165 * bfd-in2.h: Likewise.
4166 * bfd-in.h: Likewise.
4167 * cpu-i386.c: Likewise.
4168 * cpu-m68hc11.c: Likewise.
4169 * dwarf2.c: Likewise.
4170 * elf64-x86-64.c: Likewise.
4171 * format.c: Likewise.
4172 * freebsd.h: Likewise.
4174 * hp300hpux.c: Likewise.
4175 * hppabsd-core.c: Likewise.
4176 * hpux-core.c: Likewise.
4178 2001-01-22 Bo Thorsen <bo@suse.de>
4180 * elf64-x86-64.c: Added PIC support for X86-64.
4181 (elf64_x86_64_link_hash_newfunc): Function added.
4182 (elf64_x86_64_link_hash_table_create): Likewise.
4183 (elf64_x86_64_check_relocs): Likewise.
4184 (elf64_x86_64_gc_mark_hook): Likewise.
4185 (elf64_x86_64_gc_sweep_hook): Likewise.
4186 (elf64_x86_64_adjust_dynamic_symbol): Likewise.
4187 (elf64_x86_64_size_dynamic_sections): Likewise.
4188 (elf64_x86_64_discard_copies): Likewise.
4189 (elf64_x86_64_finish_dynamic_symbol): Likewise.
4190 (elf64_x86_64_finish_dynamic_sections): Likewise.
4191 (elf64_x86_64_relocate_section): Add relocation of PIC sections.
4193 2001-01-21 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
4195 * Makefile.am (install-data-local): Make use of $(DESTDIR).
4196 * Makefile.in: Regenerate.
4198 2001-01-21 Kazu Hirata <kazu@hxi.com>
4200 * coff-a29k.c: Fix formatting.
4202 2001-01-19 H.J. Lu <hjl@gnu.org>
4204 * elf32-i386.c (elf_i386_check_relocs): Report files with bad
4205 relocation section names.
4206 (elf_i386_relocate_section): Report files with bad relocation
4207 section names and return false.
4209 2001-01-17 Bo Thorsen <bo@suse.de>
4211 * targets.c: Alphabetize list of xvecs.
4213 2001-01-14 Alan Modra <alan@linuxcare.com.au>
4215 * config.bfd: Add linux target variant for elfxx-hppa.
4216 * configure.in: Recognize bfd_elf32_hppa_linux_vec and
4217 bfd_elf64_hppa_linux_vec.
4218 * configure: Regenerate.
4219 * elf64-hppa.c: Include elf64-target.h again to support linux
4221 (elf64_hppa_post_process_headers): Set ELFOSABI_LINUX for linux.
4222 * elf32-hppa.c: Include elf32-target.h again to support linux
4224 (elf32_hppa_post_process_headers): New function.
4225 (elf_backend_post_process_headers): Define.
4226 * targets.c (bfd_target_vector): Add bfd_elf64_hppa_linux_vec and
4227 bfd_elf32_hppa_linux_vec.
4229 * elf32-hppa.c (elf32_hppa_link_hash_table): Add text_segment_base,
4230 and data_segment_base fields.
4231 (elf32_hppa_link_hash_table_create ): Init them.
4232 (elf32_hppa_check_relocs): Update comments.
4233 (hppa_record_segment_addr): New function.
4234 (elf32_hppa_relocate_section): Call it.
4235 (final_link_relocate): Handle R_PARISC_SEGREL32.
4236 (elf32_hppa_final_link): New function.
4237 (bfd_elf32_bfd_final_link): Define to call it.
4238 (hppa_unwind_entry_compare): New function.
4239 * cache.c (bfd_open_file): Create files in write+read mode.
4241 * elf-hppa.h (elf_hppa_howto_table): Set bitsize value for
4242 SEGREL32 and numerous other relocs. Change duplicate
4243 R_PARISC_NONE relocs to R_PARISC_UNIMPLEMENTED.
4245 * opncls.c (bfd_fdopenr): Add parens like the comment says around
4248 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Don't create
4249 .plt entries for DT_INIT and DT_FINI.
4250 (elf32_hppa_finish_dynamic_sections): Remove special handling of
4251 DT_INIT and DT_FINI.
4253 * elf64-hppa.c (elf64_hppa_finish_dynamic_symbol): Use 16-bit
4254 offsets for stub .plt access if wide mode. Check offset in range.
4256 2001-01-13 Nick Clifton <nickc@redhat.com>
4258 * elf32-fr30.c (fr30_elf_howto_table): Remove spurious blank
4261 * coffcode.h (coff_canonicalize_reloc): Remove spurious blank
4264 2001-01-12 Alan Modra <alan@linuxcare.com.au>
4266 * configure.in ([bfd_elf64_x86_64_vec]): Set target64.
4267 * configure: Regenerate.
4269 2001-01-11 Peter Targett <peter.targett@arccores.com>
4271 * bfd-in2.h (bfd_architecture): Add bfd_mach_arc_5,
4272 bfd_mach_arc_6, bfd_mach_arc_7, bfd_mach_arc_8 for ARC variants.
4273 * cpu-arc.c (arch_info_struct): Add entries for variants.
4274 (bfd_arc_arch) Set default to bfd_mach_arc_5.
4275 (arc_get_mach) Don't assume machine names prefixed arc- before
4277 * elf32-arc.c (arc_elf_object_p): Set machine number based on new
4279 (arc_elf_final_write_processing) Likewise.
4280 (ELF_MACHINE_CODE) Use EM_ARC.
4282 2001-01-10 Nick Clifton <nickc@redhat.com>
4284 * coff-arm.c (LOCAL_LABEL_PREFIX): Change definition to "".
4286 2001-01-07 Philip Blundell <philb@gnu.org>
4288 * README: Replace `bug-gnu-utils@gnu.org' with
4289 `bug-binutils@gnu.org'.
4291 2001-01-04 Kazu Hirata <kazu@hxi.com>
4293 * som.c: Fix formatting.
4295 2001-01-03 Kazu Hirata <kazu@hxi.com>
4297 * ecoffswap.h: Fix formatting.
4298 * elf-bfd.h: Likewise.
4299 * elfarm-nabi.c: Likewise.
4300 * elfarm-oabi.c: Likewise.
4301 * elfcode.h: Likewise.
4302 * elfcore.h: Likewise.
4303 * elflink.c: Likewise.
4304 * elflink.h: Likewise.
4305 * elfxx-ia64.c: Likewise.
4306 * elfxx-target.h: Likewise.
4307 * libbfd.c: Likewise
4308 * linker.c: Likewise.
4309 * lynx-core.c: Likewise.
4311 2001-01-02 Kazu Hirata <kazu@hxi.com>
4313 * pc532-mach.c: Fix formatting.
4314 * pe-arm.c: Likewise.
4315 * pe-i386.c: Likewise.
4316 * pe-mips.c: Likewise.
4317 * pe-ppc.c: Likewise.
4318 * pe-sh.c: Likewise.
4319 * pei-mips.c: Likewise.
4320 * pei-sh.c: Likewise.
4321 * peicode.h: Likewise.
4322 * ppcboot.c: Likewise.
4323 * ptrace-core.c: Likewise.
4325 2001-01-01 Kazu Hirata <kazu@hxi.com>
4327 * reloc.c: Fix formatting.
4328 * riscix.c: Likewise.
4329 * rs6000-core.c: Likewise.
4330 * xcoff-target.h: Likewise.
4332 2000-12-29 Hans-Peter Nilsson <hp@bitrange.com>
4334 * elfcode.h (elf_object_p): Also restore the bfd mach field on
4335 error, by calling bfd_default_set_arch_mach with incoming
4338 2000-12-26 Kazu Hirata <kazu@hxi.com>
4340 * vaxnetbsd.c: Fix formatting.
4341 * versados.c: Likewise.
4342 * vms-gsd.c: Likewise.
4343 * vms-hdr.c: Likewise.
4344 * vms-misc.c: Likewise.
4346 2000-12-25 Alexandre Oliva <aoliva@redhat.com>
4348 * archive.c (coff_write_armap): Don't write more than symbol_count
4349 `archive_member_file_ptr's.
4351 2000-12-25 Kazu Hirata <kazu@hxi.com>
4353 * vms-tir.c: Fix formatting.
4355 2000-12-23 Kazu Hirata <kazu@hxi.com>
4357 * vms.c: Fix formatting.
4360 2000-12-21 Santeri Paavolainen <santtu@ssh.com>
4362 * vms-hdr.c: Include alloca.h if HAVE_ALLOCA_H is defined.
4364 * peicode.h (pe_ILF_object_p): Add const to import of TARGET_LITTLE_SYM.
4366 * elf32-m32r.c (m32r_elf_generic_reloc): Add cast to avoid (void *)
4369 * elf32-fr30.c: Add casts to avoid (void *) arithmetic.
4371 * coffcode.h (styp_to_sec_flags): Add empty statement after label.
4373 2000-12-21 Richard Sandiford <rsandifo@redhat.com>
4375 * libbfd.c (bfd_get_bits): Added
4376 (bfd_put_bits): Likewise
4377 * bfd-in.h: Declared the above.
4378 * bfd-in2.h: Regenerated.
4380 2000-12-20 Kazu Hirata <kazu@hxi.com>
4382 * targets.c: Fix formatting.
4383 * tekhex.c: Likewise.
4384 * trad-core.c: Likewise.
4386 2000-12-19 Kazu Hirata <kazu@hxi.com>
4388 * sco5-core.c: Fix formatting.
4389 * section.c: Likewise.
4390 * sparclinux.c: Likewise.
4391 * sparclynx.c: Likewise.
4392 * sparcnetbsd.c: Likewise.
4394 * stabs.c: Likewise.
4395 * stab-syms.c: Likewise.
4396 * sunos.c: Likewise.
4398 * sysdep.h: Likewise.
4400 2000-12-18 Nick Clifton <nickc@redhat.com>
4402 * coff-arm.c (EXTRA_S_FLAGS): Only define if not already
4404 * epoc-pe-arm.c (EXTRA_S_FLAGS): Define.
4405 * epoc-pei-arm.c (EXTRA_S_FLAGS): Define.
4407 2000-12-18 Nick Clifton <nickc@redhat.com>
4409 * vms-misc.c (_bfd_vms_get_record): Add default case to
4412 2000-12-15 Miloslav Trmac <mitr@volny.cz>
4414 * elfcore.h (elf_core_file_p): Move to the start of the program
4415 headers before attempting to read them.
4417 2000-12-14 Kazu Hirata <kazu@hxi.com>
4419 * peigen.c: Fix formatting.
4423 2000-12-13 Kazu Hirata <kazu@hxi.com>
4425 * peigen.c: Fix formatting.
4427 2000-12-12 Jim Wilson <wilson@redhat.com>
4429 * elfxx-ia64.c (get_dyn_sym_info): Cast %p argument to void *.
4431 2000-12-08 Mark Salter <msalter@redhat.com>
4433 * binary.c (binary_set_section_contents): Ignore sections
4436 2000-12-12 Kazu Hirata <kazu@hxi.com>
4438 * m68klinux.c: Fix formatting.
4439 * m68knetbsd.c: Likewise.
4440 * mipsbsd.c: Likewise.
4441 * netbsd-core.c: Likewise.
4442 * netbsd.h: Likewise.
4443 * newsos3.c: Likewise.
4444 * nlm32-alpha.c: Likewise.
4445 * nlm32-i386.c: Likewise.
4446 * nlm32-ppc.c: Likewise.
4447 * nlm32-sparc.c: Likewise.
4448 * nlmcode.h: Likewise.
4449 * nlmswap.h: Likewise.
4450 * nlm-target.h: Likewise.
4451 * ns32knetbsd.c: Likewise.
4453 2000-12-10 Fred Fish <fnf@be.com>
4455 * elflink.h (elf_link_output_extsym): Don't complain about undefined
4456 symbols in shared objects if allow_shlib_undefined is true.
4458 2000-12-12 Nick Clifton <nickc@redhat.com>
4460 * cpu-sh.c: Fix formattng.
4461 * elf.c: Fix formattng.
4462 * elf32-mips.c: Fix formattng.
4463 * elf32-sh.c: Fix formattng.
4464 * elf64-alpha.c: Fix formattng.
4466 2000-12-09 Nick Clifton <nickc@redhat.com>
4468 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Pass
4469 dwarf2_find_line_info as last parameter to invocation of
4470 _bfd_dwarf2_find_nearest_line.
4471 * elf32-arm.h (elf32_arm_find_nearest_line): Pass
4472 dwarf2_find_line_info as last parameter to invocation of
4473 _bfd_dwarf2_find_nearest_line.
4475 2000-12-08 Mark Elbrecht <snowball3@bigfoot.com>
4477 * Makefile.am (BFD32_BACKENDS): Move dwarf2.lo from here...
4478 (BFD_LIBS): ...to here.
4479 (BFD32_BACKENDS_CFILES): Move dwarf2.c from here...
4480 (BFD_LIBS_CFILES): ...to here.
4481 * Makefile.in: Regenerate.
4482 * configure.in: Remove dwarf.lo from the elf shell variable.
4483 * configure: Regenerate.
4484 * libcoff-in.h (coff_tdata): Add pointer dwarf2_find_line_info.
4485 * libcoff.h: Regenerate.
4486 * coffgen.c (coff_find_nearest_line): Call
4487 _bfd_dwarf2_find_nearest_line.
4488 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Add parameter. Update
4490 (read_abbrevs): Likewise
4491 (decode_line_info): Likewise.
4492 (parse_comp_unit): Likewise.
4493 (comp_unit_find_nearest_line): Likewise.
4494 * libbfd-in.h (_bfd_dwarf2_find_nearest_line): Update prototype.
4495 * libbfd.h: Regenerate.
4496 * elf.c (_bfd_elf_find_nearest_line): Update call.
4497 * elf-bfd.h (elf_obj_tdata): Change dwarf2_find_line_info to type PTR.
4498 * dwarf2.c (concat_filename): Use IS_ABSOLUTE_PATH.
4499 * coffcode.h (STYP_XCOFF_DEBUG, STYP_DEBUG_INFO): New macros.
4500 (sec_to_styp_flags): Use them. Handle DWARF2 sections.
4501 (styp_to_sec_flags): Handle DWARF2 sections.
4502 * elf32-arm.h (elf32_arm_find_nearest_line): Add parameter to call
4503 to _bfd_find_nearest_line.
4504 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Add parameter to
4505 call to _bfd_find_nearest_line.
4507 2000-12-08 Kazu Hirata <kazu@hxi.com>
4509 * coffgen.c: Fix formatting.
4510 * elf-m10300.c: Likewise.
4511 * elf32-i386.c: Likewise.
4512 * elf32-i960.c: Likewise.
4513 * elf32-m68k.c: Likewise.
4514 * elf32-mcore.c: Likewise.
4515 * elf32-ppc.c: Likewise.
4516 * elf32-sh.c: Likewise.
4517 * elf32-sparc.c: Likewise.
4518 * elf32-v850.c: Likewise.
4519 * elf64-alpha.c: Likewise.
4520 * elf64-hppa.c: Likewise.
4521 * elf64-mips.c: Likewise.
4522 * elf64-sparc.c: Likewise.
4524 2000-12-07 Kazu Hirata <kazu@hxi.com>
4526 * elf32-ppc.c: Fix formatting.
4527 * elf64-x86-64.c: Likewise.
4529 2000-12-06 Ulf Carlsson <ulfc@engr.sgi.com>
4531 From Ralf Baechle <ralf@gnu.org>
4533 * elf32-mips.c (elf32_mips_merge_private_bfd_data): Always permit
4534 BFDs containing no sections or empty .text, .data or .bss sections
4535 to be merged, regardless of their flags.
4537 2000-12-06 Kazu Hirata <kazu@hxi.com>
4539 * elf32-m32r.c: Fix formatting.
4540 * elf32-m68hc11.c: Likewise.
4541 * elf32-m68hc12.c: Likewise.
4542 * elf32-m68k.c: Likewise.
4543 * elf32-mcore.c: Likewise.
4544 * elf32-pj.c: Likewise.
4545 * elf32-ppc.c: Likewise.
4547 2000-12-05 Kazu Hirata <kazu@hxi.com>
4549 * elf32-fr30.c: Fix formatting.
4550 * elf32-hppa.c: Likewise.
4551 * elf32-i370.c: Likewise.
4552 * elf32-i386.c: Likewise.
4553 * elf32-i860.c: Likewise.
4554 * elf32-i960.c: Likewise.
4556 2000-12-03 Kazu Hirata <kazu@hxi.com>
4558 * elf32-arm.h: Fix formatting.
4559 * elf32-avr.c: Likewise.
4560 * elf32-cris.c: Likewise.
4561 * elf32-d10v.c: Likewise.
4562 * elf32-d30v.c: Likewise.
4563 * elf-hppa.h: Likewise.
4564 * elf-m10200.c: Likewise.
4565 * elf-m10300.c: Likewise.
4567 2000-12-01 Chris Demetriou <cgd@sibyte.com>
4569 * aoutx.h (NAME(aout,machine_type)): Add bfd_mach_mips32 and
4570 bfd_mach_mips32_4k. Update FIXME comment.
4571 * archures.c (bfd_mach_mips32): New constant.
4572 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
4573 the latter, renumber it.
4574 * bfd-in2.h (bfd_mach_mips32): New constant.
4575 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
4576 the latter, renumber it.
4577 * cpu-mips.c (I_mips32): New constant.
4578 (I_mips4K, I_mips32_4k): Rename the former to the latter.
4579 (arch_info_struct): Add bfd_mach_mips32 entry, replace
4580 bfd_mach_mips4K entry with bfd_mach_mips32_4k entry.
4581 * elf32-mips.c (elf_mips_isa): Add E_MIPS_ARCH_32 case.
4582 (elf_mips_mach): Likewise. Also, replace E_MIPS_MACH_MIPS32
4583 with E_MIPS_MACH_MIPS32_4K.
4584 (_bfd_mips_elf_final_write_processing): Replace
4585 bfd_mach_mips4K with bfd_mach_mips32_4k case, add
4586 bfd_mach_mips32 case.
4587 (_bfd_mips_elf_merge_private_bfd_data): Generalize ISA mixing
4588 comparison with support for MIPS32.
4589 (_bfd_mips_elf_print_private_bfd_data): Print ISA name for
4592 * aoutx.h (NAME(aout,machine_type)): Add cases for
4593 bfd_mach_mips5 and bfd_mach_mips64.
4594 * archures.c (bfd_mach_mips5, bfd_mach_mips64): New constants.
4595 * bfd-in2.h (bfd_mach_mips5, bfd_mach_mips64): Likewise.
4596 * cpu_mips.c (I_mips5, I_mips64): New definitions.
4597 (arch_info_struct): Add entries for bfd_mach_mips5 and
4599 * elf32-mips.c (elf_mips_isa, elf_mips_mach,
4600 _bfd_mips_elf_print_private_bfd_data): Add cases for
4601 E_MIPS_ARCH_5 and E_MIPS_ARCH_64.
4602 (_bfd_mips_elf_final_write_processing): Add cases for
4603 bfd_mach_mips5 and bfd_mach_mips64.
4605 * aoutx.h (NAME(aout,machine_type)): Add a
4606 bfd_mach_mips_sb1 case.
4607 * archures.c (bfd_mach_mips_sb1): New constant.
4608 * bfd-in2.h (bfd_mach_mips_sb1): New constant.
4609 * cpu-mips.c (I_sb1): New constant.
4610 (arch_info_struct): Add entry for bfd_mach_mips_sb1.
4611 * elf32-mips.c (elf_mips_mach): Add case for
4613 (_bfd_mips_elf_final_write_processing): Add case for
4616 2000-12-01 Joel Sherrill <joel@OARcorp.com>
4618 * config.bfd (arm-*-rtems*, a29k-*rtems*): New targets.
4619 (sparc*-*-rtemself*, sparc*-*-rtemsaout*): New targets.
4620 (sparc*-*-rtems*): Switched from a.out to ELF.
4622 2000-11-30 Jan Hubicka <jh@suse.cz>
4624 * Makefile.am (BFD64_BACKENDS): Add elf64-x86-64.lo
4625 BFD64_BACKENDS_CFILES): Add elf64-x86-64.c
4626 (elf64-x86-64.lo): Add dependencies.
4627 * archures.c (DESCRIPTION): Add bfd_mach_x86_64,
4628 bfd_mach_x86_64_intel_syntax.
4629 * elf.c (prep_headers): Use EM_x86_64 for 64bit output.
4630 * config.bfd (x86_64): Add.
4631 * configure.in: Add support for bfd_elf64_x86_64_vec.
4632 * cpu-i386.c (bfd_x86_64_arch_intel_syntax, bfd_x86_64_arch): Add.
4633 (bfd_i386_arch, i8086_ar): Link in.
4634 * elf64-x86-64.c: New file.
4635 * reloc.c (ENUMDOC): Add BFD_RELOC_X86_64*.
4636 * targets.c (bfd_elf64_x86_64_vec): Add.
4637 (bfd_target_vect): Add bfd_elf64_x86_64_vec.
4639 2000-11-30 Kazu Hirata <kazu@hxi.com>
4641 * xcofflink.c: Fix formatting.
4643 2000-11-28 Kazu Hirata <kazu@hxi.com>
4645 * aoutx.h: Fix formatting.
4646 * bfd-in.h: Likewise.
4647 * bfd-in2.h: Likewise.
4648 * cache.c: Likewise.
4649 * cisco-core.c: Likewise.
4650 * coff64-rs6000.c: Likewise.
4651 * coffcode.h: Likewise.
4652 * coffswap.h: Likewise.
4653 * corefile.c: Likewise.
4654 * elf32-mips.c: Likewise.
4656 2000-11-27 Kazu Hirata <kazu@hxi.com>
4658 * aout-adobe.c: Fix formatting.
4659 * coff64-rs6000.c: Likewise.
4660 * coffgen.c: Likewise.
4661 * cofflink.c: Likewise.
4663 2000-11-27 Philip Blundell <pb@futuretv.com>
4665 * libcoff-in.h (coff_tdata): Add `strings_written' flag.
4666 (obj_coff_strings_written): New accessor macro for above.
4667 * libcoff.h: Regenerate.
4668 * cofflink.c (_bfd_coff_final_link): Say that we wrote the
4670 * coffcode.h (coff_write_object_contents): No need to write out
4671 the string table if it's already been done.
4673 2000-11-22 Philip Blundell <pb@futuretv.com>
4675 * cofflink.c (_bfd_coff_generic_relocate_section): Don't object to
4676 weak undefined symbols.
4678 2000-11-24 Nick Clifton <nickc@redhat.com>
4680 * archures.c (bfd_mach_arm_5TE): Define.
4681 (bfd_mach_arm+XScale): Define.
4682 * bfd-in2.h: Regenerate.
4684 * coff-arm.c (coff_arm_reloc_type_lookup): Accept
4685 BFD_RELOC_ARM_PCREL_BLX.
4687 * coffcode.h (coff_set_flags): Set flags for 5t, 5te and
4688 XScale machine numbers.
4690 * config.bfd (xscale-elf): Add target.
4691 (xscale-coff): Add target.
4693 * cpu-arm.c: Add xscale machine name.
4694 Add v5t, v5te and XScale machine numbers.
4696 2000-11-23 Kazu Hirata <kazu@hxi.com>
4698 * aix386-core.c: Fix formatting.
4700 2000-11-22 Jim Wilson <wilson@redhat.com>
4702 * coff-ia64.c (howto_table): Use EMPTY_HOWTO.
4703 (in_reloc_p): Add ATTRIBUTE_UNUSED to unused parameters.
4704 * cpu-ia64-opc.c (ins_rsvd, ext_rsvd, ins_const, ext_const): Likewise.
4705 (ins_imms_scaled): Initialize sign_bit at function entry.
4706 (elf64_ia64_operands): Add missing initializers.
4707 * elfxx-ia64.c (elfNN_ia64_reloc, elfNN_ia64_reloc_type_lookup,
4708 elfNN_ia64_info_to_howto, elfNN_ia64_fake_sections,
4709 elfNN_ia64_add_symbol_hook, elfNN_ia64_is_local_label_name,
4710 elfNN_ia64_local_hash_table_init, get_fptr, get_pltoff,
4711 elfNN_ia64_adjust_dynamic_symbol): Add ATTRIBUTE_UNUSED for unused
4713 (elfNN_ia64_info_to_howto): Initialize free_relocs, free_contents,
4714 and free_extsyms at function entry.
4715 (elfNN_add_symbol_hook): Add unsigned cast to bfd_get_gp_size result.
4716 (elfNN_ia64_create_dynamic_sections): Delete unused local h.
4717 (get_got): Delete unused local srel.
4718 (elfNN_ia64_check_relocs): Initialize dynrel_type when declared.
4719 (elfNN_ia64_relocate_section): Delete unused local dynindx.
4721 2000-11-21 Kazu Hirata <kazu@hxi.com>
4723 * coff-a29k.c: Fix formatting.
4724 * coff-h8500.c: Likewise.
4725 * coff-i960.c: Likewise.
4726 * coff-ppc.c: Likewise.
4727 * coff-rs6000.c: Likewise.
4728 * coff-stgo32.c: Likewise.
4729 * coff-tic54x.c: Likewise.
4730 * coff-w65.c: Likewise.
4731 * cpu-h8500.c: Likewise.
4732 * cpu-hppa.c: Likewise.
4733 * cpu-ns32k.c: Likewise.
4734 * ecoff.c: Likewise.
4735 * ecofflink.c: Likewise.
4737 2000-11-21 Nick Clifton <nickc@redhat.com>
4739 * elf32-sh.c (sh_elf_reloc_loop): Fix compile time warning, and
4740 remove possibility of infinite loop.
4742 2000-11-20 Kazu Hirata <kazu@hxi.com>
4744 * aix386-core.c: Fix formatting.
4745 * aout-adobe.c: Likewise.
4746 * aout-arm.c: Likewise.
4747 * aout-encap.c: Likewise.
4748 * aout-ns32k.c: Likewise.
4749 * aout-target.h: Likewise.
4750 * aout-tic30.c: Likewise.
4751 * aoutf1.h: Likewise.
4752 * aoutx.h: Likewise.
4753 * archive.c: Likewise.
4754 * bfd-in.h: Likewise.
4755 * bfd-in2.h: Likewise.
4759 2000-11-17 H.J. Lu <hjl@gnu.org>
4761 * elfxx-ia64.c (elfNN_ia64_size_dynamic_sections): Don't create
4762 pltoff entries for DT_INIT and DT_FINI.
4763 (elfNN_ia64_final_link): Don't set DT_INIT/FINI entries.
4764 (elfNN_ia64_finish_dynamic_sections): Don't fill in DT_INIT/FINI
4767 2000-11-16 Richard Henderson <rth@redhat.com>
4769 * elfxx-ia64.c (elfNN_ia64_check_relocs): Handle IPLT relocs.
4770 (allocate_dynrel_entries): Likewise.
4771 (elfNN_ia64_relocate_section): Likewise. Set REL addends correctly.
4772 (set_pltoff_entry): Likewise.
4773 (ia64_howto_table): Remove R_IA64_SEGBASE, and R_IA64_EPLT[ML]SB
4774 (elfNN_ia64_reloc_type_lookup): Likewise.
4775 (elfNN_ia64_install_value): Likewise.
4776 (elfNN_ia64_relocate_section): Likewise.
4777 * reloc.c (BFD_RELOC_IA64_SEGBASE): Remove.
4778 (BFD_RELOC_IA64_EPLTMSB, BFD_RELOC_IA64_EPLTLSB): Remove.
4780 2000-11-16 Kazu Hirata <kazu@hxi.com>
4782 * cpu-a29k.c: Fix formatting.
4783 * cpu-alpha.c: Likewise.
4784 * cpu-arm.c: Likewise.
4785 * cpu-avr.c: Likewise.
4786 * cpu-d10v.c: Likewise.
4787 * cpu-h8500.c: Likewise.
4788 * cpu-hppa.c: Likewise.
4789 * cpu-i370.c: Likewise.
4790 * cpu-i386.c: Likewise.
4791 * cpu-i960.c: Likewise.
4792 * cpu-ia64-opc.c: Likewise.
4793 * cpu-ia64.c: Likewise.
4794 * cpu-m32r.c: Likewise.
4795 * cpu-m68hc11.c: Likewise.
4796 * cpu-m68hc12.c: Likewise.
4797 * cpu-m68k.c: Likewise.
4798 * cpu-m88k.c: Likewise.
4799 * cpu-mips.c: Likewise.
4800 * cpu-ns32k.c: Likewise.
4801 * cpu-pj.c: Likewise.
4802 * cpu-powerpc.c: Likewise.
4803 * cpu-sh.c: Likewise.
4804 * cpu-sparc.c: Likewise.
4805 * cpu-tic54x.c: Likewise.
4806 * cpu-v850.c: Likewise.
4807 * cpu-vax.c: Likewise.
4808 * cpu-w65.c: Likewise.
4809 * cpu-we32k.c: Likewise.
4810 * cpu-z8k.c: Likewise.
4811 * dwarf1.c: Likewise.
4812 * dwarf2.c: Likewise.
4814 2000-11-15 Kazu Hirata <kazu@hxi.com>
4816 * coff-arm.c: Fix formatting.
4817 * coff-ppc.c: Likewise.
4818 * coff-rs6000.c: Likewise.
4819 * coff-sh.c: Likewise.
4820 * coff-sparc.c: Likewise.
4821 * coff-tic30.c: Likewise.
4822 * coff-tic54x.c: Likewise.
4823 * coff-tic80.c: Likewise.
4824 * coff-w65.c: Likewise.
4825 * coff-we32k.c: Likewise.
4826 * coff-z8k.c: Likewise.
4828 2000-11-15 Richard Henderson <rth@redhat.com>
4830 * elf64-alpha.c (elf64_alpha_check_relocs): Create the reloc
4831 section with the same ALLOC|LOAD flags as the source section.
4833 2000-11-14 Jakub Jelinek <jakub@redhat.com>
4835 * elf64-alpha.c (elf64_alpha_relax_opt_call): Only check bits used
4836 by STO_ALPHA constants.
4838 2000-11-14 Kazu Hirata <kazu@hxi.com>
4840 * coff-pmac.c: Fix formatting.
4841 * coff-ppc.c: Likewise.
4843 2000-11-13 H.J. Lu <hjl@gnu.org>
4845 * elflink.h (elf_link_add_object_symbols): Also add indirect
4846 symbols for common symbols with the default version.
4848 2000-11-09 Philip Blundell <pb@futuretv.com>
4850 * section.c (STD_SECTION): Set gc_mark flag.
4852 2000-11-11 Kazu Hirata <kazu@hxi.com>
4854 * coff-i960.c: Likewise.
4855 * coff-m68k.c: Likewise.
4856 * coff-m88k.c: Likewise.
4857 * coff-mcore.c: Likewise.
4858 * coff-mips.c: Likewise.
4860 2000-11-11 Bernd Schmidt <bernds@cygnus.co.uk>
4862 * elf32-sh.c (sh_elf_relocate_section): Ignore R_SH_NONE relocs.
4864 2000-11-10 Kazu Hirata <kazu@hxi.com>
4866 * coff-h8300.c: Fix formatting.
4867 * coff-h8500.c: Likewise.
4868 * coff-i386.c: Likewise.
4869 * coff-i860.c: Likewise.
4870 * coff-i960.c: Likewise.
4871 * coff-ia64.c: Likewise.
4873 2000-11-09 Kazu Hirata <kazu@hxi.com>
4875 * archive.c: Fix formatting.
4876 * archures.c: Likewise.
4878 2000-11-07 Richard Henderson <rth@redhat.com>
4880 * elfxx-ia64.c (elf64_ia64_final_link): New local unwind_output_sec.
4881 Set it before bfd_elf64_bfd_final_link call. Use it after the call.
4882 * section.c (bfd_set_section_contents): Call memcpy if
4883 section->contents set and location not equal to contents plus offset.
4885 2000-11-08 Kazu Hirata <kazu@hxi.com>
4887 * bfd-in.h: Fix formatting.
4888 * bfd-in2.h: Likewise.
4890 * binary.c: Likewise.
4892 * coff-a29k.c: Likewise.
4893 * coff-alpha.c: Likewise.
4894 * coff-apollo.c: Likewise.
4895 * coff-aux.c: Likewise.
4897 2000-11-07 Kazu Hirata <kazu@hxi.com>
4899 * aix386-core.c: Fix formatting.
4900 * aoutf1.h: Likewise.
4901 * aoutx.h: Likewise.
4902 * archures.c: Likewise.
4903 * armnetbsd.c: Likewise.
4905 2000-11-07 Alan Modra <alan@linuxcare.com.au>
4907 * coff-h8300.c (special): Adjust reloc address.
4909 2000-11-06 Steve Ellcey <sje@cup.hp.com>
4911 * archures.c (bfd_mach_ia64_elf64, bfd_mach_ia64_elf32): Add defines
4912 to differentiate elf32 and elf64 on ia64.
4913 * bfd-in2.h: Regenerate.
4914 * config.bfd: Add target for "ia64*-*-hpux*".
4915 * configure.in: Add bfd_elf32_ia64_big_vec to selvecs switch.
4916 * configure: Regenerate.
4917 * cpu-ia64.c (bfd_ia64_elf32_arch): Add elf32 arch info structure.
4918 * targets.c: Add bfd_target bfd_elf32_ia64_big_vec.
4920 * Makefile.am: Make elf32-ia64.c and elf64-ia64.c derived objects
4921 from elfxx-ia64.c. Add depenency rules for making elf32-ia64.lo.
4922 * Makefile.in: Regnerate.
4923 * elf64-ia64.c: Deleted.
4924 * elfxx-ia64.c: New file, paramaterized version of elf64-ia64.c.
4926 2000-11-06 Kazu Hirata <kazu@hxi.com>
4928 * aout-adobe.c: Fix formatting.
4929 * aout-arm.c: Likewise.
4930 * aout-cris.c: Likewise.
4931 * aout-encap.c: Likewise.
4932 * aout-ns32k.c: Likewise.
4933 * aout-target.h: Likewise.
4934 * aout-tic30.c: Likewise.
4936 2000-11-05 Philip Blundell <philb@gnu.org>
4938 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Always permit
4939 BFDs containing no sections to be merged, regardless of their flags.
4941 2000-11-04 Philip Blundell <philb@gnu.org>
4943 * elf32-arm.h (elf32_arm_relocate_section): Suppress error message
4944 if a relocation for an undefined symbol also results in an
4947 2000-11-06 Christopher Faylor <cgf@cygnus.com>
4949 * config.bfd: Add support for Sun Chorus.
4951 2000-11-05 David O'Brien <obrien@FreeBSD.org>
4953 * configure.in: Recognize alpha-*-freebsd*.
4954 * configure: Regenerate.
4956 2000-11-02 Luciano Gemme <ishitawa@yahoo.com>
4958 * srec.c (CHUNK): Rename to DEFAULT_CHUNK.
4959 (Chunk): New global variable set by a parameter in objcopy.c.
4960 (S3Forced): New global variable set by a parameter in
4962 (srec_set_section_contents): If S3Forced is true, always generate
4964 (srec_write_section): Use 'Chunk' to limit maximum length of S
4967 2000-11-02 Per Lundberg <plundis@chaosdev.org>
4969 * config.bfd: Add support for i[3456]86-chaosdev-storm-chaos.
4970 * Makefile.in: Regenerate.
4971 * bfd-in2.h: Regenerate.
4972 * po/bfd.pot: Regenerate.
4974 2000-10-31 Philip Blundell <philb@gnu.org>
4976 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Only handle
4977 EF_SOFT_FLOAT if it is defined.
4979 2000-10-27 Philip Blundell <philb@gnu.org>
4981 * elf32-arm.h (elf32_arm_copy_private_bfd_data): Don't refuse
4982 attempts to mix PIC code with non-PIC, just mark the output as
4983 being position dependent.
4984 (elf32_arm_merge_private_bfd_data): Likewise. Print an error
4985 message for EF_SOFT_FLOAT mismatches. Display diagnostics for
4986 all mismatches, not just the first one.
4988 2000-10-25 Chris Demetriou <cgd@sibyte.com>
4990 * ieee.c (ieee_archive_p): Plug one of many possible
4991 memory leaks in error handling.
4993 2000-10-20 Jakub Jelinek <jakub@redhat.com>
4995 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data,
4996 elf32_sparc_object_p, elf32_sparc_final_write_processing):
4998 * elf64-sparc.c (sparc64_elf_merge_private_bfd_data,
4999 sparc64_elf_object_p): Support v9b.
5000 * archures.c: Declare v8plusb and v9b machines.
5002 * cpu-sparc.c: Ditto.
5004 2000-10-16 Geoffrey Keating <geoffk@shoggoth.cygnus.com>
5006 * elf64-sparc.c (sparc64_elf_relocate_section): Clear the location
5009 * elf32-ppc.c (SYMBOL_REFERENCES_LOCAL): New macro.
5010 (SYMBOL_CALLS_LOCAL): New macro.
5011 (ppc_elf_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL.
5012 (ppc_elf_check_relocs): Use SYMBOL_REFERENCES_LOCAL.
5013 (ppc_elf_finish_dynamic_symbol): Use SYMBOL_REFERENCES_LOCAL.
5014 (ppc_elf_relocate_section): Use flag variable to determine
5015 whether the relocation refers to a local symbol.
5016 Test whether a PLTREL24 reloc will produce a reloc by looking
5017 to see whether a PLT entry was made.
5019 2000-10-14 Geoffrey Keating <geoffk@shoggoth.cygnus.com>
5021 * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Don't make PLT
5022 entries that could serve as a definition for a weak symbol.
5024 2000-10-13 Ulf Carlsson <ulfc@engr.sgi.com>
5026 From Ralf Baechle <ralf@gnu.org>
5028 * elf32-mips.c (mips_elf_create_dynamic_relocation): New argument
5029 local_p. Add symbol value only for non-R_MIPS_REL32 relocations
5030 against local symbols.
5031 (_bfd_mips_elf_finish_dynamic_sections): Undo patch from 2000-10-01.
5033 2000-10-12 Alan Modra <alan@linuxcare.com.au>
5035 * section.c (struct sec): Add kept_section.
5036 (struct bfd_comdat_info): Remove sec, we can use above.
5037 (STD_SECTION): Add initializer.
5038 (bfd_make_section_anyway): Init here too.
5040 * bfd-in2.h: Regenerate.
5042 * elflink.h (elf_link_add_object_symbols): Remove unnecessary
5044 (elf_link_input_bfd): Set all asection->symbol->value's here, and
5045 fudge values for discarded link-once section symbols.
5047 * elf64-hppa.c: Include alloca-conf.h
5049 2000-10-11 Alan Modra <alan@linuxcare.com.au>
5051 * elf.c (swap_out_syms): Revert 2000-10-07 changes.
5053 * ieee.c (ieee_make_empty_symbol): Oops, bfd_zalloc needs another arg.
5055 2000-10-10 Alan Modra <alan@linuxcare.com.au>
5057 * ieee.c (ieee_make_empty_symbol): Use bfd_zalloc, not bfd_zmalloc.
5059 2000-10-10 Tom Rix <trix@redhat.com>
5061 * section.c (bfd_make_section_anyway): Release newsect ptr when
5062 newsect->symbol fails to alloc. Use bfd_release instead of free.
5064 2000-10-09 Richard Henderson <rth@cygnus.com
5066 * elf64-ia64.c (elf64_ia64_unwind_entry_compare_bfd): New.
5067 (elf64_ia64_unwind_entry_compare): New.
5068 (elf64_ia64_final_link): Sort the .IA_64.unwind section.
5070 2000-10-07 Alan Modra <alan@linuxcare.com.au>
5072 * elflink.h (size_dynamic_sections): Don't create various tags if
5073 .dynstr is excluded from the link. Don't set first dynsym entry
5074 if dynsymcount is zero.
5075 (elf_bfd_final_link): Don't try to swap out dynamic syms if
5076 .dynsym excluded from the link. Don't try to write any dynamic
5077 sections excluded from the link.
5079 * elf.c (swap_out_syms): Handle global section symbols.
5081 2000-10-05 DJ Delorie <dj@redhat.com>
5083 * peigen.c (_bfd_pei_swap_scnhdr_out): note extended relocs
5084 * coffcode.h (coff_set_alignment_hook): read extended reloc count
5085 (coff_write_relocs): write extended reloc count
5086 (coff_write_object_contents): account for extended relocs
5088 2000-10-05 Jim Wilson <wilson@cygnus.com>
5090 * elf-bfd.h (struct elf_backend_data): Add elf_backend_section_flags
5092 * elf.c (_bfd_elf_make_section_from_shdr): Call the
5093 elf_backend_section_flags function.
5094 * elf64-ia64.c (elf64_ia64_section_from_shdr): Delete flag conversion
5096 (elf64_ia64_section_flags): New function containing flag conversion
5098 (elf_backend_section_flags): Define to elf64_ia64_section_flags.
5099 * elfxx-target.h (elf_backend_section_flags): Define.
5100 (elfNN_bed): Initialize elf_backend_section_flags field.
5102 2000-10-02 Alan Modra <alan@linuxcare.com.au>
5104 * elf32-hppa.c (elf32_hppa_check_relocs): Correct call to
5105 _bfd_elf32_gc_record_vtable. Correct a comment.
5107 2000-10-01 Ulf Carlsson <ulfc@engr.sgi.com>
5109 From Ralf Baechle <ralf@gnu.org>
5111 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_sections): Mark gld
5112 produces binaries with got[1] = 0x80000001 to differenciate them
5113 for the dynamic linker from the broken binaries produced by old
5116 2000-09-30 Petr Sorfa <petrs@sco.com>
5118 * elf.c (elfcore_grok_pstatus): Check for size of pxstatus_t.
5119 (elfcore_grok_lwpstatus): Check for size of lwpxstatus_t.
5120 * configure.in: Add check for pxstatus_t and lwpxstatus_t.
5121 * configure: Regenerate.
5123 2000-09-27 Hans-Peter Nilsson <hp@axis.com>
5125 Define two bfd_targets for absence and presence of leading
5126 underscore on symbols. Make sure to only link same kind.
5127 * elf32-cris.c (cris_elf_object_p,
5128 cris_elf_final_write_processing, cris_elf_print_private_bfd_data,
5129 cris_elf_merge_private_bfd_data): New.
5130 (elf_backend_object_p, elf_backend_final_write_processing,
5131 bfd_elf32_bfd_print_private_bfd_data,
5132 bfd_elf32_bfd_merge_private_bfd_data): Define.
5133 <Target vector definition>: Include elf32-target.h twice with
5134 different macro settings:
5135 (TARGET_LITTLE_SYM): First as bfd_elf32_cris_vec, then as
5136 bfd_elf32_us_cris_vec.
5137 (TARGET_LITTLE_NAME): First as "elf32-cris", then "elf32-us-cris".
5138 (elf_symbol_leading_char): First as 0, then '_'.
5139 (INCLUDED_TARGET_FILE): Define for second include of elf32-target.h.
5140 * config.bfd (cris-*-*): Add bfd_elf32_us_cris_vec to targ_selvecs.
5141 * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vector.
5142 * configure: Regenerate.
5143 * targets.c: Declare bfd_elf32_us_cris_vec.
5144 * po/bfd.pot: Regenerate.
5146 2000-09-29 Momchil Velikov <velco@fadata.bg>
5148 * elf32-arm.h (arm_add_to_rel): Correctly adjust the addend for
5149 R_ARM_THM_PC22 relocations.
5151 2000-09-29 NIIBE Yutaka <gniibe@chroot.org>
5153 * elflink.h (elf_link_add_object_symbols): Don't bfd_release runpath.
5155 2000-09-29 Momchil Velikov <velco@fadata.bg>
5157 * elf.c (elf_fake_sections): Do not mark the section SHT_NOBITS if
5158 is has the SEC_HAS_CONTENTS flag set.
5160 2000-09-28
\81Örjan Friberg <orjanf@axis.com>
5161 Hans-Peter Nilsson <hp@axis.com>
5163 * aout-cris.c (N_TXTADDR): Define.
5165 2000-09-28 John David Anglin <dave@hiauly1.hia.nrc.ca>
5167 * som.c: Include alloca-conf.h.
5168 * Makefile.am: "make dep-am"
5169 * Makefile.in: Regenerate.
5171 2000-09-27 Alan Modra <alan@linuxcare.com.au>
5173 * elf32-hppa.c (plt_stub): New.
5174 (PLT_STUB_ENTRY): Define.
5175 (elf32_hppa_link_hash_table): Change multi_subspace to packed
5176 boolean. Add need_plt_stub, has_12bit_branch and has_17bit_branch.
5177 (elf32_hppa_link_hash_table_create): Init to suit.
5178 (elf32_hppa_check_relocs): Set has_12bit_branch and
5179 has_17bit_branch as appropriate.
5180 (elf32_hppa_adjust_dynamic_symbol): Set need_plt_stub for
5181 non-local functions.
5182 (elf32_hppa_size_dynamic_sections): Correct setting of reltext.
5183 Add space for plt_stub as needed.
5184 (elf32_hppa_finish_dynamic_symbol): Point .plt entries for global
5185 functions at plt_stub.
5186 (elf32_hppa_finish_dynamic_sections): Write plt_stub.
5187 (elf32_hppa_create_dynamic_sections): Leave .plt executable.
5189 * elf32-hppa.h (elf32_hppa_size_stubs): Add group_size param.
5190 * elf32-hppa.c (elf32_hppa_size_stubs): Likewise. Use it instead
5191 of fixed size, and if negative, disable handling of input sections
5192 before stub section. Set up default stub group size depending
5193 on detected branch relocs.
5194 (hppa_build_one_stub): Use lrsel and rrsel for import stubs to
5195 ensure different offsets from sym_value aren't rounded to
5196 different 2k blocks. Use lrsel and rrsel for other stubs too for
5197 consistency rather than necessity.
5198 (elf32_hppa_check_relocs): Handle R_PARISC_DIR14F.
5199 (final_link_relocate): Likewise.
5200 (elf32_hppa_relocate_section): Likewise.
5202 * elf-hppa.h (elf_hppa_howto_table): Add R_PARISC_DIR14F reloc.
5203 (_bfd_elf_hppa_gen_reloc_type): Generate them.
5204 (elf_hppa_final_link_relocate): Handle them.
5205 (elf_hppa_relocate_insn): Likewise.
5206 (_bfd_elf_hppa_gen_reloc_type): Add missing e_ldsel and e_rdsel cases.
5208 2000-09-26 Hans-Peter Nilsson <hp@axis.com>
5210 * elfcode.h (elf_object_p): Preserve and clear abfd section
5211 information. Restore at error.
5213 2000-09-26 Paul Sokolovsky <Paul.Sokolovsky@technologist.com>
5215 * peigen.c (_bfd_pei_swap_aouthdr_in): If some DataDirectory
5216 is empty, make sure that its rva also 0. NT loader dislikes
5219 2000-09-26 Steve Ellcey <sje@cup.hp.com>
5221 * som.c (som_bfd_derive_misc_symbol_info): Make weak symbols
5224 2000-09-21 Alan Modra <alan@linuxcare.com.au>
5226 * elf32-hppa.c (elf32_hppa_check_relocs): Fix weak sym handling in
5227 currently unused RELATIVE_DYNAMIC_RELOCS code.
5228 (hppa_discard_copies): Likewise.
5229 (elf32_hppa_size_stubs): Size `input_list' array correctly. Correct
5230 comments. Don't check non-code output sections for stub grouping.
5232 2000-09-20 Alan Modra <alan@linuxcare.com.au>
5234 * section.c (bfd_get_unique_section_name): Return NULL if
5237 2000-09-19 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5239 * elf32-m68k.c (elf_cpu32_plt0_entry): Change the PLT entry 0
5240 instruction sequence to actually work.
5241 (elf_m68k_finish_dynamic_sections): Change the patch-in offset
5244 2000-09-18 Alexandre Oliva <aoliva@redhat.com>
5246 * elf32-sh.c (sh_elf_relocate_section): Use
5247 _bfd_final_link_relocate to apply the relocation against a section
5248 symbol, when doing relocatable links.
5250 2000-09-18 Alan Modra <alan@linuxcare.com.au>
5252 * elf32-hppa.c (elf32_hppa_stub_hash_entry): Rename input_section
5254 (stub_hash_newfunc): Here too.
5255 (hppa_add_stub): And here.
5256 (elf32_hppa_link_hash_table): Remove stub_section_created,
5257 reloc_section_created, first_init_sec and first_fini_sec. Add
5259 (elf32_hppa_link_hash_table_create): Init to suit.
5260 (hppa_get_stub_entry): Add support for grouping stub sections.
5261 (hppa_add_stub): Likewise. Remove sec_count param and init/fini
5262 section code. Index stub vars by section->id.
5263 (elf32_hppa_size_stubs): Likewise. Remove duplicated function
5264 exit paths. Zap allocation of above removed vars. Refine
5267 * elf32-hppa.h (elf32_hppa_size_stubs): Add output_bfd param.
5268 * elf32-hppa.c (elf32_hppa_size_stubs): Likewise.
5269 (hppa_get_stub_entry): Pass in pointer to elf32_hppa_link_hash_table
5270 rather than pointer to bfd_link_info.
5271 (hppa_add_stub): Likewise.
5272 (final_link_relocate): Likewise.
5274 2000-09-17 David Huggins-Daines <dhd@linuxcare.com>
5276 (elf32_hppa_size_stubs): Don't try to build stubs for discarded
5279 2000-09-16 Alexandre Oliva <aoliva@redhat.com>
5281 * elf32-sh.c (ELF_MAXPAGESIZE): Define to 128, to match
5282 ld/emulparams/shelf.sh.
5284 2000-09-10 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5286 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): New function.
5287 * bfd-in.h (bfd_m68k_elf32_create_embedded_relocs): Add declaration.
5288 * bfd-in2.h: Regenerate.
5290 2000-09-15 Kenneth Block <Kenneth.Block@compaq.com>
5292 * elf64-alpha.c (elf64_alpha_relax_with_lituse): ld performs
5293 LITUSE relocations incorrectly if -relax is specified on the ld
5294 command line and the displacement field of the load or store
5295 instruction is non-zero. (Patch by paul.winalski@compaq.com)
5297 2000-09-15 Alan Modra <alan@linuxcare.com.au>
5299 * elf32-hppa.c (hppa_add_stub): Dont set first_init_sec and
5300 first_fini_sec here.
5301 (elf32_hppa_size_stubs): Instead correctly find the first .init
5302 and .fini section here.
5304 2000-09-15 David Huggins-Daines <dhd@linuxcare.com>
5306 * elf32-hppa.c (clobber_millicode_symbols): New function.
5307 (elf32_hppa_size_dynamic_sections): Call it.
5309 2000-09-14 Alan Modra <alan@linuxcare.com.au>
5311 * elf32-hppa.c (elf32_hppa_link_hash_entry): Make pic_call
5312 packed. Add plabel, plt_abs packed booleans.
5313 (hppa_link_hash_newfunc): Init new fields.
5314 (PLABEL_PLT_ENTRY_SIZE): Define.
5315 (hppa_stub_name): Use size_t len vars.
5316 (hppa_add_stub): Likewise.
5317 (elf32_hppa_build_stubs): Likewise.
5318 (hppa_build_one_stub): Kill some compiler warnings.
5319 (elf32_hppa_check_relocs): Always generate a plt entry for PLABELs
5320 if dynamic linking. Munge the local plt offsets into
5321 local_got_refcounts. Set h->plabel for all global PLABELs. Use
5322 size_t len vars. Add assert for plabel addend.
5323 (elf32_hppa_gc_sweep_hook): Sweep local plt entries too.
5324 (elf32_hppa_hide_symbol): New function.
5325 (elf_backend_hide_symbol): Define.
5326 (elf32_hppa_adjust_dynamic_symbol): Don't throw away plt entries
5327 with h->plabel set. Don't make plt entries to have dynamic syms
5328 when they have been forced local. If plt entry is used by a
5329 plabel, make it PLABEL_PLT_ENTRY_SIZE.
5330 (elf32_hppa_size_dynamic_sections): Set plt_abs for init fns.
5331 Set up .plt offsets for local syms.
5332 (elf32_hppa_relocate_section): Initialise plt entries for local
5333 syms. Leave weak undefined plabels zero. Make global plabel
5334 relocs against function symbol, and leave the addend zero.
5335 Use *ABS* DIR32 relocs instead of SEGREL32 for dynamic got relocs.
5336 (elf32_hppa_finish_dynamic_symbol): Set up IPLT relocs for
5337 non-dynamic syms. Init extra plt for plabels. Use *ABS* DIR32
5338 relocs instead of SEGREL32 for dynamic got relocs.
5339 (elf32_hppa_finish_dynamic_sections): Reserve one more .got entry.
5340 (elf_backend_got_header_size): Adjust.
5341 (elf32_hppa_set_gp): Calculate an "ideal" LTP.
5343 * elf32-hppa.c (LONG_BRANCH_VIA_PLT): Define.
5344 (hppa_type_of_stub): Use it instead of #if 0
5345 (hppa_discard_copies): Use it here too.
5346 (elf32_hppa_size_dynamic_sections): And here.
5348 * elf32-hppa.c (elf32_hppa_link_hash_table): Remove `offset' field.
5349 (elf32_hppa_link_hash_table_create): And here.
5350 (hppa_build_one_stub): And here. Instead keep track of stub
5351 offset using _raw_size.
5352 (elf32_hppa_size_stubs): Likewise.
5353 (elf32_hppa_build_stubs): Likewise.
5354 (hppa_size_one_stub): Likewise. Resize reloc section too.
5356 * elf32-hppa.c (hppa_add_stub): Correct first_init_sec and
5357 first_fini_sec handling. Don't search for reloc section or set
5358 hplink->reloc_section_created here.
5359 (elf32_hppa_size_stubs): Instead search for reloc sections, and
5360 set reloc_section_created here.
5361 (hppa_handle_PIC_calls): Set ELF_LINK_HASH_NEEDS_PLT.
5362 (elf32_hppa_size_dynamic_sections): Make a .plt entry for DT_INIT
5364 (elf32_hppa_finish_dynamic_sections): Set DT_INIT and DT_FINI.
5366 * elf32-hppa.c (hppa_build_one_stub): Replace `elf_hash_table (info)'
5367 with `hplink->root.'.
5368 (elf32_hppa_check_relocs): Likewise.
5369 (elf32_hppa_gc_sweep_hook): Likewise.
5370 (elf32_hppa_adjust_dynamic_symbol): Likewise.
5371 (hppa_handle_PIC_calls): Likewise.
5372 (elf32_hppa_size_dynamic_sections): Likewise.
5373 (elf32_hppa_set_gp): Likewise.
5374 (elf32_hppa_relocate_section): Likewise.
5375 (elf32_hppa_finish_dynamic_symbol): Likewise.
5376 (elf32_hppa_finish_dynamic_sections): Likewise.
5378 From David Huggins-Daines <dhd@linuxcare.com>
5379 * elf32-hppa.c (hppa_type_of_stub): Generate import stubs for
5380 defined weak symbols in shared links.
5381 (final_link_relocate): Calls to defined weak symbols in shared
5382 objects must go via import stubs, as the target might not be known
5385 2000-09-14 Alexandre Oliva <aoliva@redhat.com>
5387 * elf32-sh.c (sh_elf_howto_table): Moved R_SH_GOT32, R_SH_PLT32,
5388 R_SH_COPY, R_SH_GLOB_DAT, R_SH_JMP_SLOT, R_SH_RELATIVE,
5389 R_SH_GOTOFF, R_SH_GOTPC) to the range from 160 to 167. Replaced
5390 the original entries with EMPTY_HOWTOs, and added new ones to fill
5392 (sh_elf_info_to_howto): Make sure the new gap isn't used.
5393 (sh_elf_relocate_section): Likewise.
5395 2000-09-13 Anders Norlander <anorland@acc.umu.se>
5397 * cpu-mips.c (arch_info_struct): Add mips:4K
5398 * bfd-in2.h (bfd_mach_mips4K): New define.
5399 * archures.c: Add bfd_mach_mips4K to comment.
5400 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Return
5401 E_MIPS_ARCH_2 for bfd_mach_mips4K.
5403 2000-09-13 Marco Franzen <marcof@thyron.com>
5405 * som.c (som_write_symbol_strings): Do not used fixed buffers,
5406 use size_t as a counter.
5407 (som_write_space_strings): Similarly.
5409 2000-09-12 Jason Eckhardt <jle@cygnus.com>
5411 * elf32-i860.c (elf32_i860_relocate_pc26): New function
5413 (elf32_i860_relocate_section): Invoke new function from here.
5415 2000-09-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5417 * elf.c (_bfd_elf_make_section_from_shdr): Make debug_sec_names
5420 2000-09-10 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5422 * coff-m68k.c (bfd_m68k_coff_create_embedded_relocs): Emit 8 NULs for
5423 target section name instead of dumping core when the target symbol is
5426 2000-09-09 Kazu Hirata <kazu@hxi.com>
5428 * riscix.c: Remove DEFUN.
5430 2000-09-08 Nick Clifton <nickc@redhat.com>
5432 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Do not
5433 initialise flags in output bfd if the input bfd is the default
5434 architecture with the default flags.
5436 2000-09-08 Kazu Hirata <kazu@hxi.com>
5438 * archive.c: Fix formatting.
5439 * coff-arm.c: Likewise.
5440 * doc/chew.c: Likewise.
5442 2000-09-08 Alan Modra <alan@linuxcare.com.au>
5444 * section.c (bfd_get_unique_section_name): Put a dot before the
5447 2000-09-07 Kazu Hirata <kazu@hxi.com>
5449 * doc/chew.c: Remove all uses of DEFUN and DEFUN_VOID.
5450 * elf.c: Fix formatting.
5452 2000-09-07 Alexandre Oliva <aoliva@redhat.com>
5454 * config.bfd (sh-*-linux*): Added.
5455 * configure.in (bfd_elf32_shlin_vec, bfd_elf32_shblin_vec): New.
5456 * targets.c: Declare them.
5457 * elf32-sh-lin.c: New file.
5458 * Makefile.am: Compile it.
5459 * elf32-sh.c: Don't override defines from elf32-sh-lin.c.
5460 * configure, Makefile.in: Rebuilt.
5462 2000-09-06 Geoffrey Keating <geoffk@cygnus.com>
5464 * xcofflink.c (xcoff_link_input_bfd): Include the .tocbss
5465 pseduo-section when determining where the TOC ends.
5467 * coff-rs6000.c (_bfd_xcoff_swap_aux_out): Use bfd_h_put_16 to
5468 output x_tvndx as it is only two bytes wide.
5470 * coff-rs6000.c (xcoff_howto_table): A modifiable branch-absolute
5471 reloc is 26 or 32 bits wide.
5473 * coff-rs6000.c (_bfd_xcoff_rtype2howto): The bitsize is irrelevant
5474 for relocs that don't change anything. Also look at the full
5477 2000-09-06 Philip Blundell <philb@gnu.org>
5479 * config.bfd (arm*-*-uclinux*): New target.
5481 2000-09-06 Alexandre Oliva <aoliva@redhat.com>
5483 * configure: Rebuilt with new libtool.m4.
5485 2000-09-06 Alan Modra <alan@linuxcare.com.au>
5487 * section.c (bfd_get_unique_section_name): Avoid c++ reserved
5488 word for variable name.
5489 * bfd-in2.h: Regenerate.
5491 2000-09-05 Nick Clifton <nickc@redhat.com>
5493 * config.in: Regenerate.
5494 * libbfd.h: Regenerate.
5495 * po/bfd.pot: Regenerate.
5496 * doc/bfdint.texi: Remove CVS date string - it foils compares with
5499 2000-09-05 Steven Johnson <sbjohnson@ozemail.com.au>
5501 * cpu-powerpc.c (arch_info_struct): Added MPC860 Family entry.
5503 2000-09-05 Alan Modra <alan@linuxcare.com.au>
5505 Shared library and PIC support.
5506 * elf32-hppa.c (PLT_ENTRY_SIZE): New.
5507 (GOT_ENTRY_SIZE): New.
5508 (ELF_DYNAMIC_INTERPRETER): New.
5509 (STUB_SUFFIX): Define.
5510 (LONG_BRANCH_PIC_IN_SHLIB): Define.
5511 (RELATIVE_DYNAMIC_RELOCS): Define.
5512 (enum elf32_hppa_stub_type): New.
5513 (struct elf32_hppa_stub_hash_entry): Rename offset to
5514 stub_offset. Add a number of new fields.
5515 (struct elf32_hppa_link_hash_entry): New.
5516 (struct elf32_hppa_link_hash_table): Add numerous fields. Remove
5518 (elf32_hppa_hash_table): Rename to hppa_link_hash_table.
5519 (elf32_hppa_stub_hash_lookup): Rename to hppa_stub_hash_lookup.
5520 (elf32_hppa_stub_hash_newfunc): Rename to stub_hash_newfunc. Init
5522 (hppa_link_hash_newfunc): New function.
5523 (elf32_hppa_link_hash_table_create): Use above function. Init new
5525 (elf32_hppa_stub_name): Rename to hppa_stub_name. Pass in reloc
5526 instead of addend, and remove sym_name from args. Don't use
5527 symbol name for local syms, instead use sym index.
5528 (elf32_hppa_size_of_stub): Rename to hppa_type_of_stub, and return
5529 stub type rather than size. Pass in hash and handle import stub
5530 case. Also pass in reloc instead of offset so we can calculate
5531 PCREL22F and PCREL12F branches properly.
5532 (elf32_hppa_build_one_stub): Rename to hppa_build_one_stub. Build
5533 import and export stubs too.
5534 (elf32_hppa_size_one_stub): Rename to hppa_size_one_stub. Handle
5535 import and export stub sizing.
5536 (elf32_hppa_check_relocs): New function.
5537 (elf32_hppa_adjust_dynamic_symbol): New function.
5538 (hppa_discard_copies): New function.
5539 (elf32_hppa_size_dynamic_sections): New function.
5540 (elf_backend_size_dynamic_sections): Define.
5541 (elf32_hppa_finish_dynamic_symbol): New function.
5542 (elf_backend_finish_dynamic_symbol): Define.
5543 (elf32_hppa_size_stubs): Stash params in link hash table, and move
5544 some local vars into the link hash table too. For shared links,
5545 trundle over function syms, generating export stubs. Handle
5546 PCREL22F branches. Break out stub creation code from here..
5547 (hppa_add_stub): .. to here. New function.
5548 (elf32_hppa_final_link): Rename to elf32_hppa_set_gp, and don't
5549 call the bfd linker. Use elf_gp to record global pointer.
5550 Calculate a value from sections if $global$ is missing.
5551 (bfd_elf32_bfd_final_link): Define as _bfd_elf32_gc_common_final_link.
5552 (elf32_hppa_gc_mark_hook): New function.
5553 (elf_backend_gc_mark_hook): Define.
5554 (elf32_hppa_gc_sweep_hook): New function.
5555 (elf_backend_gc_sweep_hook): Define.
5556 (elf32_hppa_bfd_final_link_relocate): Rename to final_link_relocate.
5557 Add rel to args, and remove howto, input_bfd, offset, addend,
5558 sym_name as we can recalculate these locally. Handle calls to
5559 dynamic objects, extra PIC relocs, PCREL22F branches. Change
5560 handling of undefined weak syms. Check that stubs are in range.
5561 Only look for import stubs on PCREL17F and PCREL22F relocs. Add
5562 message on hitting a DPREL21L reloc that needs fixing. Subtract
5563 off PC for PCREL14F. Break out code that does a stub lookup from
5565 (hppa_get_stub_entry): ..to here. New function.
5566 (elf32_hppa_relocate_insn): Merge into final_link_relocate.
5567 (elf32_hppa_relocate_section): Handle got and plt relocs, dynamic
5569 (elf32_hppa_finish_dynamic_sections): New function.
5570 (elf_backend_finish_dynamic_sections): Define.
5571 (elf_backend_final_write_processing) Define.
5572 (hppa_handle_PIC_calls): New function.
5573 (elf32_hppa_build_stubs): Call it. Pass link_info to
5574 hppa_build_one_stub.
5575 (elf32_hppa_create_dynamic_sections): New function
5576 to create .plt and .got then set .plt flags correctly.
5577 (elf_backend_create_dynamic_sections): Define.
5578 (elf32_hppa_object_p): New function.
5579 (elf_backend_object_p): Define.
5580 (elf32_hppa_elf_get_symbol_type): New function.
5581 (elf_backend_get_symbol_type): Define.
5582 (elf_backend_can_gc_sections): Define.
5583 (elf_backend_want_got_plt): Define.
5584 (elf_backend_plt_alignment): Set to 2.
5585 (elf_backend_plt_readonly): Define.
5586 (elf_backend_want_plt_sym): Define.
5587 (elf_backend_got_header_size): Reserve one entry.
5589 * elf32-hppa.h (elf32_hppa_build_stubs): Don't pass stub bfd.
5590 (elf32_hppa_size_stubs): Pass in multi_subspace.
5591 (elf32_hppa_set_gp): Declare.
5593 * section.c (SEC_HAS_GOT_REF): Define new flag for asection.
5594 (bfd_get_unique_section_name): New function.
5595 * bfd-in2.h: Regenerate.
5597 * elf64-hppa.c (elf64_hppa_check_relocs): Handle R_PARISC_PCREL12F.
5598 (elf64_hppa_size_dynamic_sections): Remove the FIXME at bfd_zalloc
5601 From David Huggins-Daines <dhd@linuxcare.com>
5602 * elf64-hppa.c (elf64_hppa_check_relocs): Fix a warning.
5603 (elf64_hppa_mark_exported_functions): Set dyn_h->st_shndx.
5604 (elf64_hppa_link_output_symbol_hook): Test dyn_h->st_shndx has
5605 been updated in finish_dynamic_symbol before modifying function
5608 * elf-hppa.h (elf_hppa_howto_table): Restructure into groups of
5609 eight entries. Replace NULL with bfd_elf_generic_reloc. Add
5610 R_PARISC_GNU_VTENTRY, R_PARISC_GNU_VTINHERIT and R_PARISC_PCREL12F.
5611 (_bfd_elf_hppa_gen_reloc_type): Handle R_PARISC_GNU_VT*. Add some
5612 comments. Handle format == 12 for R_HPPA_PCREL_CALL.
5613 (elf_hppa_final_link_relocate): Handle R_PARISC_PCREL12F.
5614 (elf_hppa_relocate_insn): Likewise. Reformat some comments.
5615 (elf_hppa_final_write_processing): Expose it for ARCH_SIZE == 32.
5617 From David Huggins-Daines <dhd@linuxcare.com>
5618 * elf-hppa.h (elf_hppa_is_local_label_name): Accept the SysV/ELF
5619 style of local labels as well.
5621 2000-09-03 Philip Blundell <philb@gnu.org>
5623 * elf32-arm.h (elf32_arm_relocate_section): Don't try to relocate
5624 references to undefined symbols in debugging sections.
5626 2000-09-02 H.J. Lu <hjl@gnu.org>
5628 * reloc.c (BFD_RELOC_SH_COPY, BFD_RELOC_SH_GLOB_DAT,
5629 BFD_RELOC_SH_JMP_SLOT, BFD_RELOC_SH_RELATIVE,
5630 BFD_RELOC_SH_GOTPC): Move them from the MIPS section to the SH
5633 2000-09-02 Jason Eckhardt <jle@cygnus.com>
5635 * elf32-i860.c (bfd_elf32_bfd_is_local_label_name): Define macro.
5636 (elf32_i860_is_local_label_name): New function and prototype.
5638 2000-09-02 Nick Clifton <nickc@redhat.com>
5640 * configure.in: Increase version number to 2.10.91.
5641 * configure: Regenerate.
5642 * aclocal.m4: Regenerate.
5643 * config.in: Regenerate.
5644 * po/bfd.pot: Regenerate.
5646 2000-09-02 Daniel Berlin <dberlin@redhat.com>
5648 * elf.c (_bfd_elf_make_section_from_shdr): Add
5649 .gnu.linkobce.wi. to the list of debug section names.
5651 2000-09-02 Nick Clifton <nickc@redhat.com>
5653 * dwarf2.c (find_debug_info): New function: Locate a section
5654 containing dwarf2 debug information.
5655 (bfd_dwarf2_find_nearest_line): Find all sections containing
5656 debug information and include them in the stash.
5658 2000-09-01 Niibe Yutaka <gniibe@m17n.org>, Kaz Kojima <kkojima@rr.iij4u.or.jp>, Alexandre Oliva <aoliva@redhat.com>
5660 * elf32-sh.c (R_SH_GOT32, R_SH_PLT32, R_SH_COPY, R_SH_GLOB_DAT,
5661 R_SH_JMP_SLOT, R_SH_RELATIVE, R_SH_GOTOFF, R_SH_GOTPC): New.
5662 (sh_reloc_map): Add new relocs.
5663 (sh_elf_check_relocs, sh_elf_link_hash_newfunc,
5664 sh_elf_link_hash_table_create, sh_elf_adjust_dynamic_symbol,
5665 sh_elf_size_dynamic_sections, sh_elf_finish_dynamic_symbol,
5666 sh_elf_finishe_dynamic_sections, sh_elf_discard_copies): New
5668 (ELF_DYNAMIC_INTERPRETER, PLT_ENTRY_SIZE): Define.
5669 (elf_sh_plt0_entry_be, elf_sh_plt0_entry_le,
5670 elf_sh_plt_entry_be, elf_sh_plt_entry_le,
5671 elf_sh_pic_plt_entry_be, elf_sh_pic_plt_entry_le):
5672 New array constants.
5673 (elf_sh_plt0_entry, elf_sh_plt_entry, elf_sh_pic_plt_entry):
5675 (elf_sh_sizeof_plt, elf_sh_plt_plt0_offset,
5676 elf_sh_plt0_linker_offset, elf_sh_plt0_gotid_offset,
5677 elf_sh_plt_temp_offset, elf_sh_plt_symbol_offset,
5678 elf_sh_plt_reloc_offset): Define.
5679 (elf_sh_pcrel_relocs_copied, elf_sh_link_hash_entry,
5680 elf_sh_link_hash_table): New structs.
5681 (sh_elf_link_hash_traverse, sh_elf_hash_table): New macros.
5682 (sh_elf_relocate_section, sh_elf_check_relocs): Handle new
5684 (elf_backend_create_dynamic_sections,
5685 bfd_elf32_bfd_link_hash_table_create,
5686 elf_backend_adjust_dynamic_symbol,
5687 elf_backend_size_dynamic_sections,
5688 elf_backend_finish_dynamic_symbol,
5689 elf_backend_finish_dynamic_sections, elf_backend_want_got_plt,
5690 elf_backend_plt_readonly, elf_backend_want_plt_sym,
5691 elf_backend_got_header_size, elf_backend_plt_header_size):
5693 * reloc.c (BFD_RELOC_SH_COPY, BFD_RELOC_SH_GLOB_DAT,
5694 BFD_RELOC_SH_JMP_SLOT, BFD_RELOC_SH_RELATIVE, BFD_RELOC_SH_GOTPC):
5696 * bfd-in2.h, libbfd.h: Rebuilt.
5698 2000-09-01 Alan Modra <alan@linuxcare.com.au>
5700 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Revert 2000-08-27
5703 2000-08-31 J"orn Rennecke <amylaar@cygnus.co.uk>
5705 * elf32-sh.c (sh_elf_merge_private_data): If ibfd's elf header flags
5706 not initialized, set them to indicate the SH1 instruction set.
5708 2000-08-31 Alexandre Oliva <aoliva@redhat.com>
5710 * acinclude.m4: Include libtool and gettext macros from the
5712 * aclocal.m4, configure: Rebuilt.
5714 2000-08-29 Michael Snyder <msnyder@seadog.cygnus.com>
5716 * elf.c: Eliminate references to __sparcv9 macro; replace with
5717 autoconf variables HAVE_PSINFO32_T etc.
5718 * configure.in: Auto-configure HAVE_PSINFO_32_T, HAVE_PRPSINFO32_T,
5719 HAVE_PSTATUS32_T, HAVE_PRSTATUS32_T, HAVE_PRSTATUS32_T_PR_WHO.
5721 * acinclude.m4 (BFD_HAVE_SYS_PROCFS_TYPE) define _SYSCALL32 so it can
5722 detect the above typedefs. (BFD_HAVE_SYS_PROCFS_TYPE_MEMBER): Ditto.
5723 * aclocal.m4: Ditto.
5724 * configure: Regenerate.
5726 2000-08-27 Alan Modra <alan@linuxcare.com.au>
5728 * elf32-i386.c (elf_i386_check_relocs): Keep info on relocs copied
5729 for any shared link, not just shared -Bsymbolic.
5730 (elf_i386_size_dynamic_sections): Call elf_i386_discard_copies on
5731 any shared link, and pass link info to it.
5732 (elf_i386_size_dynamic_sections): Update comment.
5733 (elf_i386_discard_copies): Modify to discard relocs for symbols
5734 that have been forced local.
5735 (elf_i386_finish_dynamic_symbol): Don't copy relocs for symbols
5736 that have been forced local.
5738 2000-08-24 Denis Chertykov <denisc@overta.ru> & Nick Clifton <nickc@redhat.com>
5740 * elflink.h (elf_link_add_object_symbols): Allow common
5741 symbols to have an alignment of 1 if explicitly requested, and
5742 not overridden by other definitions.
5744 2000-08-22 Doug Kwan <dkwan@transmeta.com>
5746 * coff-w65.c (CREATE_LITTLE_COFF_TARGET): Fix typo.
5747 * coffcode.h (coff_set_flags): Add detection of w65 architecture.
5749 2000-08-22 H.J. Lu <hjl@gnu.org>
5751 * elf-bfd.h (elf_link_hash_table): Add runpath.
5753 * bfd-in.h (bfd_elf_get_runpath_list): New prototype.
5754 * bfd-in2.h: Rebuilt.
5756 * elf.c (_bfd_elf_link_hash_table_init): Initialize the
5757 "runpath" field to NULL.
5758 (bfd_elf_get_runpath_list): New function.
5760 * elflink.h (elf_link_add_object_symbols): Record DT_RPATH and
5763 2000-08-22 Alexandre Oliva <aoliva@redhat.com>
5765 * elf32-sh.c (sh_elf_relocate_section) [R_SH_IND12W,
5766 R_SH_DIR8WPN, R_SH_DIR8WPZ, R_SH_DIR8WPL]: Handle them
5767 explicitly. Improve validation of r_type.
5769 2000-08-21 H.J. Lu <hjl@gnu.org>
5771 * elf32-i386.c (elf_i386_size_dynamic_sections): Zero out the
5772 dynamic allocated content space. Add a comment to remind us that
5773 one day this ought to be fixed.
5774 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
5775 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
5776 * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
5778 2000-08-21 Jason Eckhardt <jle@cygnus.com>
5780 * elf32-i860.c (elf32_i860_relocate_pc16): Just write the immediate
5781 field with the newly relocated value instead of adding it to the
5782 existing immediate field.
5783 (elf32_i860_relocate_splitn): Likewise.
5784 (elf32_i860_relocate_highadj): Likewise.
5786 2000-08-16 Jason Eckhardt <jle@cygnus.com>
5788 * elf32-i860.c (elf32_i860_relocate_pc16): Implemented function (it
5789 was previously just a stub).
5791 2000-08-16 Alexandre Oliva <aoliva@redhat.com>
5793 * elflink.c (_bfd_elf_create_got_section): Don't abort().
5795 (_bfd_elf_create_dynamic_sections): Likewise.
5797 2000-08-16 Andrew Macleod <amacleod@cygnus.com>
5799 * elf64-sparc.c (sparc64_elf_relocate_section): Set relocation address
5800 for undefined symbols to be the beginning of the section.
5802 * elf64-sparc.c (sparc64_elf_adjust_dynamic_symbol): Don't allocate
5803 four extra entries at the beginning of the .rela.plt section.
5804 (sparc64_elf_finish_dynamic_symbol): Adjust the offset in the .rela.plt
5805 section to account for the four reserved entries in the .plt section.
5807 2000-08-15 Geoffrey Keating <geoffk@cygnus.com>
5809 * xcofflink.c (_bfd_ppc_xcoff_relocate_section): Add ori r0,r0,0
5810 to the list of NOPs we recognize after a branch-and-link.
5811 Use the ori NOP when one is needed.
5813 * coff-rs6000.c (_bfd_xcoff_slurp_armap): Finish implementation
5816 2000-08-14 Jim Wilson <wilson@cygnus.com>
5818 * elf64-ia64.c (elf64_ia64_merge_private_bfd_data): Handle
5819 EF_IA_64_REDUCEDFP, EF_IA_64_CONS_GP, and EF_IA_64_NOFUNCDESC_CONS_GP.
5820 (elf64_ia64_print_private_bfd_data): Likewise. Also handle
5823 2000-08-11 Alexandre Oliva <aoliva@redhat.com>
5825 * elf32-sh.c (sh_elf_set_mach_from_flags): Make it static.
5827 2000-08-10 Jason Eckhardt <jle@cygnus.com>
5829 * elf32-i860.c (elf32_i860_relocate_section): New function.
5830 (i860_final_link_relocate): New function.
5831 (elf32_i860_relocate_splitn): New function.
5832 (elf32_i860_relocate_pc16): New function.
5833 (elf32_i860_relocate_highadj): New function.
5834 (elf32_i860_howto): Minor adjustments to some relocations.
5835 (elf_info_to_howto_rel): Define.
5836 (elf_backend_relocate_section): Define.
5838 2000-08-10 Nick Clifton <nickc@cygnus.com>
5840 * elf32-arm.h: Fix formatting.
5842 2000-08-10 Bernd Schmidt <bernds@cygnus.co.uk>
5844 * elf32-sh.c (sh_elf_reloc_loop): Make LAST_SYMBOL_SECTION static.
5846 2000-08-08 Jason Eckhardt <jle@cygnus.com>
5848 * elf32-i860.c (elf32_i860_howto_table): Updated some fields.
5850 2000-08-07 Kazu Hirata <kazu@hxi.com>
5852 * ieee.c (ieee_write_debug_part): Rewrite a comment.
5853 * elf64-ia64.c: Fix a typo.
5855 2000-08-05 Jason Eckhardt <jle@cygnus.com>
5857 * elf32-i860.c (elf32_i860_howto_table): New structure.
5858 (lookup_howto): New function.
5859 (elf32_i860_reloc_type_lookup): New function.
5860 (elf32_i860_info_to_howto_rela): New function.
5861 (elf_code_to_howto_index): New structure.
5862 (elf_info_to_howto): Re-define as elf32_i860_info_to_howto_rela.
5863 (bfd_elf32_bfd_reloc_type_lookup): Re-define as
5864 elf32_i860_reloc_type_lookup.
5866 2000-08-04 Rodney Brown <RodneyBrown@pmsc.com>
5868 * som.c (struct fixup_format): Constify `format'.
5869 (som_hppa_howto_table): Use SOM_HOWTO macro.
5870 (try_prev_fixup, hppa_som_reloc): Decorate unused parameter.
5871 (som_bfd_reloc_type_lookup): Likewise.
5872 (compare_subspaces): Remove unused `count1', `count2'.
5873 (som_begin_writing): Remove unused `total_reloc_size'.
5874 (som_bfd_derive_misc_symbol_info): Decorate unused parameter.
5875 (som_print_symbol, som_bfd_is_local_label_name): Likewise.
5876 (som_set_reloc_info): Constify `cp'. Remove unused `addend'.
5877 (som_find_nearest_line): Decorate unused parameter(s).
5878 (som_sizeof_headers, som_get_symbol_info, som_write_armap): Likewise.
5879 (som_bfd_link_split_section): Likewise.
5881 2000-08-03 Nick Clifton <nickc@cygnus.com>
5883 * section.c: Restore backed out code.
5884 * elf.c: Restore backed out code.
5885 (copy_private_bfd_data): Fix bug preventing stipped dynamic
5886 binaries from working.
5887 * bfd-in2.h: Regenerate.
5889 2000-08-03 H.J. Lu <hjl@gnu.org>
5891 * section.c: Back out the change made by Nick Clifton
5892 <nickc@cygnus.com> on 2000-07-31. It breaks stripping dynamic
5894 * bfd-in2.h: Likewise.
5897 2000-08-03 Alexandre Oliva <aoliva@redhat.com>
5899 * elf32-sh.c (sh_elf_reloc_loop): Warning removal.
5901 2000-07-31 Jason Eckhardt <jle@cygnus.com>
5903 * reloc.c (BFD_RELOC_860_*): New bfd relocs for i860.
5904 * bfd-in2.h, libbfd.h: Regenerate.
5906 2000-07-31 Nick Clifton <nickc@cygnus.com>
5908 * section.c (struct sec): Add new boolean field 'segment_mark'.
5909 (STD_SECTION): Initialise new field to zero.
5911 * bfd-in2.h: Regenerate.
5913 * elf.c (copy_private_bfd_data): Reorganise section to segment
5914 mapping to cope with moved sections requiring new segments,
5915 and overlapping segments.
5916 (SEGMENT_END): New macro: Return the end address of a segment.
5917 (IS_CONTAINED_BY_VMA): New macro: Determine if a segment
5918 contains a section by comparing their VMA addresses.
5919 (IS_CONTAINED_BY_LMA): New macro: Determine if a segment
5920 contains a section by comparing their LMA addresses.
5921 (INCLUDE_SECTION_IN_SEGMENT): New macro: Determine if a
5922 section should be included in a segment.
5923 (SEGMENT_AFTER_SEGMENT): New macro: Determine if one segment
5924 follows another in memory.
5925 (SEGMENT_OVERLAPS_SEGMENT): New macro: Determine if two
5928 2000-07-22 Jason Eckhardt <jle@cygnus.com>
5930 * cpu-i860.c: Added comments.
5932 * elf32-i860.c (TARGET_LITTLE_SYM): Defined to
5933 bfd_elf32_i860_little_vec.
5934 (TARGET_LITTLE_NAME): Defined to "elf32-i860-little".
5935 (ELF_MAXPAGESIZE): Changed to 4096.
5937 * targets.c (bfd_elf32_i860_little_vec): Declaration of
5939 (bfd_target_vector): Added bfd_elf32_i860_little_vec.
5941 * config.bfd (i860-stardent-sysv4*, i860-stardent-elf*): Added
5942 config for little endian elf32 i860.
5943 (targ_defvec): Define for the new config above
5944 as "bfd_elf32_i860_little_vec".
5945 (targ_selvecs): Define for the new config above
5946 as "bfd_elf32_i860_vec bfd_elf32_i860_little_vec"
5948 * configure.in (bfd_elf32_i860_little_vec): Added recognition
5951 * configure: Regenerated.
5953 2000-07-27 H.J. Lu <hjl@gnu.org>
5955 * elflink.h (elf_merge_symbol): Take one more argument,
5956 dt_needed, to indicate if the symbol comes from a DT_NEEDED
5957 entry. Don't overide the existing weak definition if dt_needed
5959 (elf_link_add_object_symbols): Pass dt_needed to
5960 elf_merge_symbol ().
5962 2000-07-27 Nick Clifton <nickc@cygnus.com>
5964 * elflink.h (elf_link_size_reloc_section): Zeroes the section's
5967 2000-07-25 Geoffrey Keating <geoffk@cygnus.com>
5969 * configure.host (*-*-aix*): AIX has 'long long' always.
5971 * coff-rs6000.c (xcoff_write_one_armap_big): New procedure.
5972 (xcoff_write_armap_big): Write both 32-bit and 64-bit armaps.
5973 (xcoff_write_archive_contents_big): Don't update the offset
5974 of the symbol table, xcoff_write_armap will do it.
5976 2000-07-23 Ulf Carlsson <ulfc@engr.sgi.com>
5978 * elf32-mips.c (_bfd_mips_elf_check_relocs): Use abfd instead
5979 of dynobj for SGI_COMPAT checks.
5981 2000-07-21 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5983 * coff-m68k.c (bfd_m68k_coff_create_embedded_relocs): New function.
5984 * bfd-in.h (bfd_m68k_coff_create_embedded_relocs): Add declaration.
5985 * bfd-in2.h: Regenerate.
5987 2000-07-21 Nick Clifton <nickc@cygnus.com>
5989 * elf32-mips.c (_bfd_mips_elf_check_relocs): Detect out of
5990 range symbol indices in relocs and issue an error message.
5992 2000-07-20 H.J. Lu <hjl@gnu.org>
5994 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Don't check
5995 info->new_dtags when setting DT_FLAGS_1. It will only be set
5996 by the new linker options. It shouldn't break anything.
5998 2000-07-20 H.J. Lu <hjl@gnu.org>
6000 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set DT_FLAGS_1
6001 only if info->new_dtags is true.
6003 2000-07-20 H.J. Lu <hjl@gnu.org>
6005 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set
6006 DT_RUNPATH and DT_FLAGS only if info->new_dtags is true.
6008 2000-07-20 Hans-Peter Nilsson <hp@axis.com>
6010 * Makefile.am (ALL_MACHINES): Add cpu-cris.lo.
6011 (ALL_MACHINES_CFILES): Add cpu-cris.c.
6012 (BFD32_BACKENDS): Add aout-cris.lo and elf32-cris.lo.
6013 (BFD32_BACKENDS_CFILES): Add aout-cris.c and elf32-cris.c.
6014 (cpu-cris.lo, aout-cris.lo, elf32-cris.lo): New rules.
6015 * Makefile.in: Rebuild.
6016 * aclocal.m4: Rebuild.
6017 * aoutx.h (NAME(aout,machine_type)): Add case for bfd_arch_cris.
6018 * archures.c (enum bfd_architecture): Add bfd_arch_cris.
6019 (bfd_cris_arch): Declare.
6020 (bfd_archures_list): Add bfd_cris_arch.
6021 * bfd-in2.h: Rebuild.
6022 * config.bfd: (cris-*-*): New target.
6023 * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vectors.
6024 * configure: Rebuild.
6025 * elf.c (prep_headers): Add bfd_arch_cris.
6026 * libbfd.h: Rebuild.
6027 * libaout.h (enum machine_type): Add M_CRIS.
6028 * reloc.c: Add CRIS relocations.
6029 * targets.c (bfd_elf32_cris_vec, cris_aout_vec): Declare.
6030 (bfd_target_vect): Add bfd_elf32_cris_vec and cris_aout_vec.
6031 * cpu-cris.c, aout-cris.c, elf32-cris.c: New files.
6032 * po/POTFILES.in, po/bfd.pot: Regenerate.
6034 2000-07-19 H.J. Lu <hjl@gnu.org>
6036 * elf32-arm.h (elf32_arm_size_dynamic_sections): Also set
6037 DF_TEXTREL if DT_TEXTREL is set.
6038 * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise.
6039 * elf32-i386.c (elf_i386_size_dynamic_sections): Likewise.
6040 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
6041 * elf32-mips.c (_bfd_mips_elf_size_dynamic_sections): Likewise.
6042 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise.
6043 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
6044 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Likewise.
6045 * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
6046 * elf64-ia64.c (elf64_ia64_size_dynamic_sections): Likewise.
6047 * elf64-sparc.c (sparc64_elf_size_dynamic_sections): Likewise.
6049 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Also
6050 set DF_SYMBOLIC for symbolic link. Also set DT_RUNPATH if
6052 Set the DT_FLAGS and DT_FLAGS_1 entries if necessary.
6054 2000-07-19 H.J. Lu <hjl@gnu.org>
6056 * bfd-in.h (bfd_elf_set_dt_needed_soname): New.
6057 * bfd-in2.h: Rebuild.
6059 * elf-bfd.h (elf_obj_tdata): Add dt_soname.
6060 (elf_dt_soname): New.
6062 * elf.c (bfd_elf_set_dt_needed_soname): New.
6064 * elflink.h (elf_link_add_object_symbols): Add the DT_NEEDED
6065 entry if the shared object loaded by DT_NEEDED is used to
6066 resolve the reference in a regular object.
6068 2000-07-19 H.J. Lu <hjl@gnu.org>
6070 * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_CONFIG,
6071 DT_DEPAUDIT and DT_AUDIT as strings.
6073 2000-07-19 Nick Clifton <nickc@cygnus.com>
6075 * format.c: Fix formatting.
6077 2000-07-19 H.J. Lu <hjl@gnu.org>
6079 * elf.c (_bfd_elf_print_private_bfd_data): Fix DT_CHECKSUM.
6081 2000-07-19 H.J. Lu <hjl@gnu.org>
6083 * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_BIND_NOW,
6084 DT_INIT_ARRAY, DT_FINI_ARRAY, DT_INIT_ARRAYSZ, DT_FINI_ARRAYSZ,
6085 DT_RUNPATH, DT_FLAGS, DT_PREINIT_ARRAY, DT_PREINIT_ARRAYSZ,
6086 DT_PLTPADSZ, DT_MOVEENT, DT_MOVESZ, DT_FEATURE, DT_POSFLAG_1,
6087 DT_SYMINSZ, DT_SYMINENT, DT_CONFIG, DT_DEPAUDIT, DT_AUDIT,
6088 DT_PLTPAD, DT_MOVETAB, DT_SYMINFO, DT_RELACOUNT, DT_RELCOUNT,
6089 DT_FLAGS_1, DT_USED and DT_CHECKSUM.
6091 2000-07-18 Andrew Cagney <cagney@b1.cygnus.com>
6093 * elf.c (bfd_elf_get_sign_extend_vma, bfd_elf_get_arch_size): Move
6094 renamed functions from here...
6095 (assign_section_numbers): Use renamed functions.
6096 (prep_headers): Use renamed functions.
6098 * bfd.c (bfd_get_sign_extend_vma, bfd_get_arch_size): ...To here.
6099 * bfd-in.h (bfd_get_sign_extend_vma, bfd_get_arch_size): Update.
6100 * bfd-in2.h: Regenerate.
6102 2000-07-18 Ulf Carlsson <ulfc@engr.sgi.com>
6104 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Add
6105 parenthesis in if statement.
6107 2000-07-17 Koundinya K <kk@ddeorg.soft.net>
6109 Enable the support for Traditional MIPS.
6110 * elf32-mips.c (IRIX_COMPAT): Recognize bfd_elf32_tradbigmips_vecand
6111 return ict_none appropriately for traditional mips targets.
6112 (STUB_LW): Change 0x8f998000 to 0x8f998010 for traditional mips.
6113 (STUB_MOVE): Conditionalize for traditonal mips.
6114 (STUB_LI16): Likewise.
6115 (_bfd_mips_elf_modify_segment_map): Conditionalize to avoid making
6116 room for RTPROC header.
6117 (_bfd_mips_elf_modify_segment_map): For a normal mips executable set
6118 the permission for the PT_DYNAMIC as read, write and execute.
6119 (mips_elf_calculate_relocation): Check for the symbol _DYNAMIC_LINKING
6120 for traditonal mips.
6121 (_bfd_mips_elf_create_dynamic_sections): Add the symbol
6122 _DYNAMIC_LINKING for traditonal mips.
6123 (_bfd_mips_elf_create_dynamic_sections): Add the symbol __RLD_MAP
6124 in case of traditonal mips.
6125 (_bfd_mips_elf_adjust_dynamic_symbol): Create a stub only if a PLT
6126 entry is required. For a function if PLT is not required then set the
6127 corresponding hash table entry to 0.
6128 (_bfd_mips_elf_size_dynamic_sections): Add DT_DEBUG entry for
6130 (_bfd_mips_elf_finish_dynamic_symbol): for a undefined symbol in a
6131 shared object set the value to 0.
6132 (_bfd_mips_elf_finish_dynamic_symbol): Check for the symbol
6133 _DYNAMIC_LINKING for traditonal mips.
6134 (_bfd_mips_elf_finish_dynamic_symbol): Check for the symbol __RLD_MAP
6135 for traditonal mips.
6137 2000-07-15 H.J. Lu <hjl@gnu.org>
6139 * aoutx.h (translate_to_native_sym_flags): Handle BSF_LOCAL.
6141 2000-07-12 Charles Wilson <cwilson@ece.gatech.edu>
6143 * libbfd.c (bfd_seek): fix 'seek beyond EOF' error when writing
6144 out a structure that is BFD_IN_MEMORY.
6146 2000-07-11 Alan Modra <alan@linuxcare.com.au>
6148 * elf64-hppa.c (get_dyn_name): Pass in section pointer instead of
6149 bfd pointer. Print section id instead of bfd pointer for local
6150 syms. Prefix addend with `+' for global syms as well as local.
6151 Correct calculation of name component lengths.
6152 (elf64_hppa_check_relocs): Update call to get_dyn_name.
6154 From David Huggins-Daines <dhd@linuxcare.com>
6155 * elf-hppa.h (elf_hppa_relocate_section): Update calls here too.
6156 * elf64-hppa.c (elf64_hppa_check_relocs): Fix some warnings.
6157 (elf64_hppa_modify_segment_map): Likewise.
6159 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
6161 * elf.c (bfd_elf_get_sign_extend_vma): Return tendency of VMA
6162 addresses to be "naturally" sign extended. Return -1 if unknown.
6163 * bfd-in.h (bfd_elf_get_sign_extend_vma): Add declaration.
6164 * bfd-in2.h: Regenerate.
6166 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
6168 * ecoffswap.h (ecoff_get_off, ecoff_put_off): Add ECOFF_SIGNED_32
6169 and ECOF_SIGNED_64 to list ways to extract an offset.
6170 (ecoff_swap_fdr_in, ecoff_swap_fdr_out, ecoff_swap_pdr_in,
6171 ecoff_swap_pdr_out, ecoff_swap_ext_in, ecoff_swap_ext_out):
6173 * elf64-mips.c (ECOFF_SIGNED_64): Define instead of ECOFF_64.
6174 * elf32-mips.c (ECOFF_SIGNED_32): Define instead of ECOFF_32.
6176 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
6178 * elfcode.h (elf_object_p): Use bfd_set_start_address and not
6179 bfd_get_start_address.
6180 (elf_swap_ehdr_in): Sign extend e_entry when applicable.
6181 (elf_swap_ehdr_out): Ditto.
6183 2000-07-10 Alexander Aganichev <AAganichev@hypercom.com>
6185 * archures.c (bfd_default_scan): Add set of bfd_mach_ cases for
6186 compatibility with older binutils.
6188 2000-07-10 Alan Modra <alan@linuxcare.com.au>
6190 * section.c (bfd_make_section_anyway): Start section_id at 0x10.
6191 (STD_SECTION): Avoid negative ids, instead use 0 to 3.
6193 From Ryan Bradetich <rbradetich@uswest.net>
6194 * dwarf1.c (parse_die): Cure signed/unsigned char warnings.
6195 (parse_line_table): Ditto.
6196 (_bfd_dwarf1_find_nearest_line): Ditto.
6197 * syms.c (cmpindexentry): Remove extra `*' from params.
6199 2000-07-09 Koundinya K <kk@ddeorg.soft.net>
6201 * elf32-mips.c (sort_dynamic_relocs): New Function.
6202 (_bfd_mips_elf_finish_dynamic_sections): Call sort_dynamic_relocs
6203 via qsort to sort the dynamic relocations in increasing r_symndx
6206 2000-07-09 Alan Modra <alan@linuxcare.com.au>
6208 * elf64-hppa.c (elf64_hppa_dyn_hash_table_init): Add
6209 ATTRIBUTE_UNUSED to unused args.
6210 (get_opd): Likewise.
6211 (get_plt): Likewise.
6212 (get_dlt): Likewise.
6213 (get_stub): Likewise.
6214 (elf64_hppa_adjust_dynamic_symbol): Likewise.
6215 (elf64_hppa_link_output_symbol_hook): Likewise.
6216 (elf64_hppa_check_relocs): Delete unused var.
6217 (elf64_hppa_size_dynamic_sections): Likewise.
6218 (elf64_hppa_finalize_opd): Likewise.
6219 (elf64_hppa_finalize_dynreloc): Likewise.
6220 (elf64_hppa_modify_segment_map): Likewise.
6221 (elf64_hppa_finish_dynamic_sections): Likewise.
6223 * elf-hppa.h (elf_hppa_final_write_processing): Add
6224 ATTRIBUTE_UNUSED to unused args.
6225 (elf_hppa_final_link_relocate): Likewise.
6226 (elf_hppa_record_segment_addrs): Add paretheses.
6227 (elf_hppa_relocate_section): Constify dyn_name.
6229 From David Huggins-Daines <dhd@linuxcare.com>
6230 * config.bfd: Add hppa*64*-*-linux-gnu 64-bit target, and
6231 rearrange case statement so that it gets preferred to 32-bit ones.
6233 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Use
6234 asection->id instead of address of asection structure.
6235 (elf32_hppa_size_stubs): Likewise.
6237 * elf32-hppa.c (elf32_hppa_size_stubs): Use just one stub section
6238 for .init* and .fini*.
6240 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Mask pointers
6241 and addends used in stub names to 32 bits.
6242 (elf32_hppa_size_stubs): Likewise.
6244 * elf-hppa.h (elf_hppa_final_link_relocate): Don't sum addend
6245 twice for R_PARISC_GPREL64. Use bfd_put_32 for R_PARISC_PCREL32,
6246 not bfd_put_64. Fix minor comment typo and formatting.
6248 Changes to create multiple linker stubs, positioned immediately
6249 before the section where they are required.
6250 * elf32-hppa.c: Don't include hppa_stubs.h.
6251 (elf32_hppa_stub_hash_entry): Add a pointer to the stub section.
6252 (elf32_hppa_stub_hash_table): Delete.
6253 (elf32_hppa_link_hash_entry): Delete.
6254 (elf32_hppa_link_hash_table): Use plain bfd_hash_table for
6255 stub_hash_table, and store the struct here rather than a pointer.
6256 Delete output_symbol_count. Add offset array. Change
6257 global_value to a bfd_vma.
6258 (elf32_hppa_stub_hash_lookup): Use table instead of table->root.
6259 (elf32_hppa_stub_hash_traverse): Delete.
6260 (elf32_hppa_name_of_stub): Delete.
6261 (elf32_hppa_link_hash_lookup): Delete.
6262 (elf32_hppa_link_hash_traverse): Delete.
6263 (elf32_hppa_stub_hash_table_init): Delete.
6264 (elf32_hppa_size_of_stub): Pass input section and offset rather
6265 than location and calculate location here. Don't pass name as all
6266 stubs are now the same size.
6267 (elf32_hppa_stub_hash_newfunc): Init new fields.
6268 (elf32_hppa_link_hash_table_create): Likewise, and stub_hash_table
6270 (elf32_hppa_bfd_final_link_relocate): Cast enums to int before
6271 comparing against ints. Rewrite stub handling code.
6272 (elf32_hppa_relocate_section): Make r_type and r_symndx unsigned.
6273 Case enums to int before comparing against ints. Remove
6274 bfd_reloc_dangerous case.
6275 (elf32_hppa_build_one_stub): Rewrite.
6276 (elf32_hppa_size_one_stub): New function.
6277 (elf32_hppa_build_stubs): Rewrite.
6278 (elf32_hppa_size_stubs): Pass in linker call-back functions.
6279 Rewrite stub-handling specific code.
6281 * elf32-hppa.h (elf32_hppa_size_stubs): Update prototype.
6283 * elf64-hppa.c (elf64_hppa_dyn_hash_entry): Fix a comment typo.
6285 * hppa_stubs.h: Delete.
6286 * Makefile.am (SOURCE_HFILES): Remove hppa_stubs.h
6287 (elf32-hppa.lo): Remove hppa_stubs.h from dependencies.
6288 * Makefile.in: Regenerate.
6290 * elf-hppa.h (_bfd_elf_hppa_gen_reloc_type): Handle e_nlsel and
6293 * libhppa.h (hppa_field_adjust): Correct e_nsel case.
6295 * elf32-hppa.c (elf32_hppa_relocate_section): Mention the offset
6296 and section name for bfd_reloc_notsupported error message.
6297 (elf32_hppa_bfd_final_link_relocate): Print reasons for returning
6298 bfd_reloc_notsupported.
6299 (elf32_hppa_relocate_section): Add ATTRIBUTE_UNUSED to output_bfd.
6301 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Handle
6302 undefined weak symbols for all relocs.
6303 (elf32_hppa_size_of_stub): Adjust calculation by 8 since branch
6304 offsets are relative to one past the delay slot.
6305 (elf32_hppa_size_stubs): Account for reloc addend when calculating
6306 branch destination. Put addend into stub name too.
6307 (elf32_hppa_bfd_final_link_relocate): Account for reloc addend and
6308 adjust by 8 when deciding whether a linker stub is needed. Put
6309 addend into stub name as for above.
6311 * elf32-hppa.c (hppa_elf_relocate_insn): Change signed/unsigned on
6312 various args and vars.
6313 (elf32_hppa_bfd_final_link_relocate): Here too.
6314 (elf32_hppa_size_stubs): Rename index -> indx. Use e_indx for
6315 inner block var to avoid shadowing.
6317 * elf32-hppa.h (_bfd_elf32_hppa_gen_reloc_type): Make `field' arg
6319 * elf64-hppa.h (_bfd_elf64_hppa_gen_reloc_type): Ditto.
6320 * elf-hppa.h (_bfd_elf_hppa_gen_reloc_type): Ditto.
6321 (elf_hppa_fake_sections): Rename local var to avoid shadowing.
6323 * libhppa.h: Change practically all unsigned ints to plain ints.
6324 Remove tests on gcc version. Instead use ATTRIBUTE_UNUSED for
6327 From Ryan Bradetich <rbradetich@uswest.net>
6328 * libhppa.h (hppa_opcode_type): New enum to replace #define's.
6329 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Modify to
6331 From David Huggins-Daines <dhd@linuxcare.com>
6332 * elf-hppa.h (elf_hppa_relocate_insn): Update the opcode constants
6333 to the new OP_* ones.
6335 * elf32-hppa.c (elf32_hppa_size_stubs): Consolidate freeing on
6336 error exit. Bail out earlier on plabel relocs that we aren't
6337 interested in. Don't tell elf32_hppa_stub_hash_lookup to copy
6338 string, and then don't free our copy.
6339 (elf32_hppa_build_one_stub): Make insn unsigned int.
6341 * libhppa.h (bfd_hppa_insn2fmt): 22 bit branches are only
6342 available with BL, not BE and BLE.
6344 * elf32-hppa.c (hppa_elf_relocate_insn): Add some more example
6345 code for elf arg relocs.
6346 (elf32_hppa_bfd_final_link_relocate): Replace boolean is_local
6347 argument with elf_link_hash_entry h. Handle undefined weak
6348 symbols. Move $global$ lookup from here...
6349 (elf32_hppa_relocate_section): ...to here. Return correct error
6350 message for non-handled relocs.
6351 (elf32_hppa_size_of_stub): Correctly test branch range. Previous
6352 wrong test was -0x3ffff to +0x40000.
6354 * elf-hppa.h (elf_hppa_final_link_relocate): R_PARISC_DIR17R,
6355 R_PARISC_DIR17F, and R_PARISC_DIR21L are for absolute branches;
6356 Handle them as such.
6357 (elf_hppa_relocate_insn): Fix a typo.
6359 * libhppa.h (GET_FIELD, GET_BIT, MASK, CATENATE, ELEVEN): Delete.
6360 (assemble_3, assemble_6, assemble_12, assemble_16, assemble_16a,
6361 assemble_17, assemble_21): Delete.
6362 Supply defines for all 64 possible opcodes.
6363 (bfd_hppa_insn2fmt): Add bfd argument, and use to select wide mode
6364 formats. Handle COMICLR.
6365 (hppa_rebuild_insn): Delete bfd argument. Handle formats 10, -11,
6368 * elf32-hppa.c (hppa_elf_relocate_insn): Complete rewrite.
6369 (elf32_hppa_bfd_final_link_relocate): Major rewrite.
6370 (elf32_hppa_build_one_stub): Modify hppa_elf_relocate_insn calls
6372 (elf32_hppa_size_stubs): Don't free stub_name twice. Read in all
6373 the local syms - did this code get deleted accidentally? Ignore
6374 undefined and undefweak syms.
6376 * elf-hppa.h (elf_hppa_final_link): Move hppa_info to outermost
6377 block. Use it instead of elf64_hppa_hash_table (info).
6378 (elf_hppa_final_link_relocate): Use hppa_info instead of
6379 elf64_hppa_hash_table (info).
6381 * libhppa.h (re_assemble_3, re_assemble_12, re_assemble_16,
6382 re_assemble_17, re_assemble_21, re_assemble_22): Don't mask insn.
6383 (hppa_rebuild_insn): Mask immediate bits here instead.
6384 * elf-hppa.h (elf_hppa_relocate_insn): Mask here too.
6386 2000-07-08 Alan Modra <alan@linuxcare.com.au>
6388 * section.c (struct sec): Add id field. Tidy comment formatting.
6389 (bfd_make_section_anyway): Set id.
6390 (STD_SECTION): Init id too.
6391 Change CONST to const throughout.
6392 * archures.c (bfd_arch_info): Tidy comment.
6393 (bfd_arch_list): Change a CONST to const.
6394 * libbfd-in.h: Tidy comments and replace CONST with const.
6395 * elf-bfd.h: Likewise.
6396 * libbfd.h: Regenerate.
6397 * bfd-in2.h: Regenerate.
6398 * libcoff.h: Regenerate.
6400 2000-07-07 DJ Delorie <dj@redhat.com>
6402 * archive.c (_bfd_write_archive_contents): Add an informative
6405 2000-07-06 Kazu Hirata <kazu@hxi.com>
6407 * srec.c: Fix formatting.
6409 2000-06-05 DJ Delorie <dj@redhat.com>
6413 2000-07-04 Alexandre Oliva <aoliva@redhat.com>
6415 * coff-arm.c (coff_arm_relocate_section): Do not ignore the symbol
6416 value of PC-relative offsets.
6418 2000-07-03 Jim Wilson <wilson@cygnus.com>
6420 * elf64-alpha.c (alpha_elf_size_info): New.
6421 (elf_backend_size_info): Define to alpha_elf_size_info.
6422 * elfcode.h (elf_size_info): Change hash bucket size to 4.
6424 2000-07-03 Ulf Carlsson <ulfc@engr.sgi.com>
6426 * elf32-mips.c: Include elf32-target.h again for the traditional
6429 2000-07-03 Marek Michalkiewicz <marekm@linux.org.pl>
6431 * elf32-avr.c (bfd_elf32_bfd_reloc_type_lookup):
6432 Add ATTRIBUTE_UNUSED to unused arguments to avoid warnings.
6433 (avr_info_to_howto_rela): Likewise.
6434 (elf32_avr_gc_mark_hook): Likewise.
6435 (elf32_avr_gc_sweep_hook): Likewise.
6436 (elf32_avr_relocate_section): Likewise.
6438 2000-07-03 Mark Elbrecht <snowball3@bigfoot.com>
6440 * cofflink.c (_bfd_coff_write_global_sym): Turn a weak symbol into
6441 an external symbol for a non-shared, non-relocatable link.
6443 2000-07-03 Nick Clifton <nickc@redhat.com>
6445 * cofflink.c (IS_EXTERNAL): New macro: Return true if the symbol
6446 is an external symbol.
6447 (IS_WEAK_EXTERNAL): New macro: Return true if the symbol is a weak
6450 2000-07-03 Kazu Hirata <kazu@hxi.com>
6452 * reloc16.c: Fix formatting.
6454 2000-07-01 Koundinya K <kk@ddeorg.soft.net>
6456 * config.bfd: Change targ_defvec and targ_selvecs for mips*-*-sysv4*
6457 to add a new target for traditional mips i.e
6458 bfd_elf32_tradbigmips_vec and bfd_elf32_tradlittlemips_vec.
6459 * configure.in: Likewise.
6460 * configure: Rebuild.
6461 * targets.c (bfd_elf32_tradbigmips_vec): Declare and put in
6463 (bfd_elf32_tradlittlemips_vec): Likewise.
6464 * elfxx-target.h: Add macro INCLUDED_TARGET_FILE which is more a test
6465 to see that elfNN_bed does not get redefined even if the target file
6466 is included twice for a chip. See elf32-mips.c.
6468 2000-07-01 Alan Modra <alan@linuxcare.com.au>
6470 * Makefile.am (DEP): Fix 2000-06-22. grep after running dep.sed
6471 (CLEANFILES): Add DEPA.
6472 * Makefile.in: Regenerate.
6474 2000-06-30 DJ Delorie <dj@cygnus.com>
6476 * peicode.h (coff_swap_filehdr_in): can't use e_magic because we
6477 can't assume the PE header is at 0x80.
6479 2000-06-29 Mark Elbrecht <snowball3@bigfoot.com>
6481 * syms.c (_bfd_stab_section_find_nearest_line): Use IS_ABSOLUTE_PATH.
6483 2000-06-28 Mark Elbrecht <snowball3@bigfoot.com>
6485 * go32stub.h: Update stub.
6487 2000-06-26 Marek Michalkiewicz <marekm@linux.org.pl>
6489 * archures.c (bfd_mach_avr5): Define.
6490 * bfd-in2.h (bfd_mach_avr5): Define.
6491 * cpu-avr.c (arch_info_struct): Rename bfd_mach_avr4 to
6492 bfd_mach_avr5, add bfd_mach_avr4. Update comments.
6493 (compatible): Update comment. Add missing test.
6494 * elf32-avr.c (avr_final_link_relocate): Support 8K wrap
6495 for avr2 and avr4. Simplify 8K wrap code.
6496 (bfd_elf_avr_final_write_processing): Recognize bfd_mach_avr5.
6497 (elf32_avr_object_p): Recognize E_AVR_MACH_AVR5.
6499 2000-06-26 Kazu Hirata <kazu@hxi.com>
6501 * coff-h8300.c: Fix formatting.
6502 * cpu-h8300.c: Likewise.
6504 2000-06-24 Alexandre Oliva <aoliva@redhat.com>
6506 * elf32-arm.h (elf32_arm_final_link_relocate): Print `(local)'
6507 for local symbols whose names are unknown.
6509 2000-06-22 Alan Modra <alan@linuxcare.com.au>
6511 * Makefile.am (DEP): grep for leading `/' in DEP1, and fail if we
6513 * Makefile.in: Regenerate.
6514 * doc/Makefile.in: Regenerate.
6516 2000-06-20 H.J. Lu <hjl@gnu.org>
6518 * Makefile.am: Rebuild dependency.
6519 * Makefile.in: Rebuild.
6521 2000-06-20 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
6523 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): New function.
6524 (elf_backend_copy_indirect_symbol): Map to the new function.
6526 2000-06-20 Alan Modra <alan@linuxcare.com.au>
6528 * archive.c (normalize): Correct pointer comparison when checking
6530 (bfd_bsd_truncate_arname): Likewise.
6531 (bfd_gnu_truncate_arname): Likewise.
6533 2000-06-20 Ulf Carlsson <ulfc@engr.sgi.com>
6535 * elf-bfd.h (struct elf_obj_tdata): Define per BFD Irix 5 virtual
6536 sections elf_{text,data}_{section,symbol}.
6537 * elf32-mips.c: mips_elf_{text,data}_{section,symbol}{,_ptr}: Remove.
6538 (_bfd_mips_elf_hide_symbol): New function.
6539 (elf_backend_hide_symbol): Map to the new function.
6540 (_bfd_mips_elf_add_symbol_hook): Change to use new per BFD
6541 definitions of mips_elf_{text,data}_{section,symbol}.
6542 (mips_elf_local_relocation_p): Try to find the direct symbol
6543 based on new check_forced argument.
6544 (mips_elf_calculate_relocation): Use new version of
6545 mips_elf_local_relocation_p.
6546 (mips_elf_relocate_section): Likewise.
6547 (_bfd_mips_elf_relocate_section): Likewise.
6548 (mips_elf_sort_hash_table): Only assert that have enough GOT
6550 (mips_elf_got16_entry): Match all 32 bits to the existing GOT
6551 entry if the relocation based on the new external argument.
6552 (mips_elf_create_dynamic_relocation): Assert that we have a
6553 section contents allocated where we can swap out the dynamic
6555 (mips_elf_calculate_relocation): Find the real hash-table entry
6556 correctly by using h->root.root.type. Only create a dynamic
6557 relocation entry if the symbol is defined in a shared library.
6558 Create an external GOT entry for the GOT16 relocation if the
6559 symbol was forced local.
6560 (_bfd_mips_elf_finish_dynamic_symbol): Don't assert there is a
6561 dynamic index if the symbol was forced local.
6563 2000-06-20 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
6565 * elf32-mips.c: Fix typos in comments.
6567 2000-06-19 Mark Kettenis <kettenis@gnu.org>
6569 * rs6000-core.c: Wrap definition of `union VmInfo' within #ifdef
6572 2000-06-18 Stephane Carrez <stcarrez@worldnet.fr>
6574 * Makefile.in, bfd-in2.h, libbfd.h, configure: Rebuild.
6575 * Makefile.am (ALL_MACHINES, ALL_MACHINES_CFILES, BFD32_BACKENDS,
6576 BFD32_BACKENDS_CFILES): Add 68hc12, 68hc11 files.
6577 * configure.in (bfd_elf32_m68hc12_vec): Recognize.
6578 (bfd_elf32_m68hc11_vec): Likewise.
6579 * config.bfd (targ_cpu): Recognize 68hc12 and 68hc11.
6580 Supports 68hc11 & 68hc12 at the same time.
6581 * targets.c (bfd_elf32_m68hc12_vec): Declare and put in
6583 (bfd_elf32_m68hc11_vec): Likewise.
6584 * elf.c (prep_headers): Recognize bfd_arch_m68hc12 and 68hc11.
6585 * archures.c (bfd_m68hc12_arch): Define and register in global list
6586 (bfd_m68hc11_arch): Likewise.
6587 * reloc.c (BFD_RELOC_M68HC11_HI8, BFD_RELOC_M68HC11_LO8,
6588 BFD_RELOC_M68HC11_3B): Define.
6589 * cpu-m68hc12.c, elf32-m68hc12.c: New files for 68hc12 support.
6590 * cpu-m68hc11.c, elf32-m68hc11.c: New files for 68hc11 support.
6592 2000-06-18 Ulf Carlsson <ulfc@engr.sgi.com>
6594 * elf_bfd.h (struct elf_backend_data): Add info argument to
6595 elf_backend_hide_symbol.
6596 (_bfd_elf_link_hash_hide_symbol): Likewise.
6597 * elf.c (_bfd_elf_link_hash_hide_symbol): Likewise.
6598 * elf64-ia64.c (elf64_ia64_hash_hide_symbol): Likewise.
6599 * elflink.h (elf_link_add_object_symbols): Likewise.
6600 (elf_link_assign_sym_version): Likewise.
6602 2000-06-18 H.J. Lu <hjl@gnu.org>
6604 * coff-i386.c (coff_i386_reloc): Don't return in case of
6605 output_bfd == (bfd *) NULL if COFF_WITH_PE is defined.
6606 Compensate PE relocations when linking with non-PE object
6607 files to generate a non-PE executable.
6609 2000-06-17 Ulf Carlsson <ulfc@engr.sgi.com>
6611 * elf32-mips.c (mips_elf_calculate_relocation): Explicitly write
6612 GOT entries if we're doing a static link or -Bsymbolic link.
6614 2000-06-15 Ulf Carlsson <ulfc@engr.sgi.com>
6616 * elflink.h (elf_link_adjust_relocs): Check for and call backend
6617 specifific swap_reloc_{in,out} and swap_reloca_{in,out} if
6619 (elf_link_output_relocs): Likewise.
6620 (elf_reloc_link_order): Likewise.
6622 2000-06-16 Nicholas Duffek <nsd@redhat.com>
6624 * archures.c (enum bfd_architecture): #define constants for
6625 PowerPc and RS6000 machine numbers.
6626 * bfd-in2.h: Regenerate.
6627 * coffcode.h (coff_set_arch_mach_hook): #ifdef XCOFF64, set arch
6628 to bfd_arch_powerpc instead of bfd_arch_rs6000. Refer to PowerPc
6629 and RS6000 machine numbers using #defined constants from
6631 * cpu-powerpc.c (arch_info_struct): Refer to PowerPc and RS6000
6632 machine numbers using #defined constants from archures.c. Add
6633 entries for EC603e, 630, A35, RS64II, RS64III, 7400. Specify
6634 64-bit words in 620 entry.
6635 * cpu-rs6000.c (arch_info_struct): Create with entries for RS1,
6637 (bfd_rs6000_arch): Change default machine to 0 (bfd_mach_rs6k).
6639 2000-06-16 Nicholas Duffek <nsd@cygnus.com>
6641 * coffcode.h (coff_mkobject_hook): Set xcoff_tdata.xcoff64.
6642 * libcoff-in.h (struct xcoff_tdata): Define xcoff64 field.
6643 * libcoff.h (struct xcoff_tdata): Define xcoff64 field.
6645 2000-06-16 Nicholas Duffek <nsd@redhat.com>
6647 * bfd-in.h (bfd_family_coff): Define.
6648 * bfd-in2.h: Regenerate.
6649 * coffgen.c (coff_count_linenumbers, coff_symbol_from,
6650 coff_find_nearest_line): Check COFFness using bfd_family_coff()
6651 instead of bfd_target_coff_flavour.
6652 * cofflink.c (_bfd_coff_final_link): Likewise.
6653 * cpu-ns32k.c (do_ns32k_reloc): Don't strcmp() target name to
6654 exclude XCOFF files.
6655 * reloc.c (bfd_perform_relocation, bfd_install_relocation):
6657 * targets.c (enum bfd_flavour): Add bfd_target_xcoff_flavour.
6658 * xcoff-target.h (TARGET_SYM): Use bfd_target_xcoff_flavour.
6659 * xcofflink.c (XCOFF_XVECP): Delete.
6660 (bfd_xcoff_link_record_set, bfd_xcoff_import_symbol,
6661 bfd_xcoff_export_symbol, bfd_xcoff_link_count_reloc,
6662 bfd_xcoff_record_link_assignment,
6663 bfd_xcoff_size_dynamic_sections): Replace XCOFF_XVECP() with
6664 check for bfd_target_xcoff_flavour.
6666 2000-06-16 Nicholas Duffek <nsd@redhat.com>
6668 * rs6000-core.c: Support 64-bit core files, support pre-4.3 core
6670 (read_hdr): New function.
6671 (rs6000coff_core_p): Store mstsave or __context64 struct instead
6672 of trying to extract individual registers. Set abfd->arch_info
6673 to match the architecture that created the core file.
6674 (rs6000coff_get_section_contents): Delete.
6675 * xcoff-target.h (rs6000coff_get_section_contents): Delete.
6677 2000-06-14 H.J. Lu <hjl@gnu.org>
6679 * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_rec)
6682 2000-06-13 H.J. Lu <hjl@gnu.org>
6684 * configure: Regenerate.
6686 2000-06-13 J"orn Rennecke <amylaar@cygnus.co.uk>
6688 * peicode.h (pe_ILF_object_p): Use TARGET_LITTLE_SYM instead of
6691 2000-06-08 David O'Brien <obrien@FreeBSD.org>
6693 * configure.in (VERSION): Update to show this is the CVS mainline.
6695 2000-06-07 Alan Modra <alan@linuxcare.com.au>
6697 * elf32-d10v.c: Include elf/d10v.h
6698 (enum reloc_type): Delete.
6699 * elf32-d30v.c: Include elf/d30v.h
6700 (enum reloc_type): Delete.
6702 * Makefile.am: Run "make dep-am" to regenerate dependencies.
6703 * Makefile.in: Regenerate.
6705 * elf32-i386.c (elf_howto_table): Remove EMPTY_HOWTOs.
6706 (elf32_i386_vtinherit_howto, elf32_i386_vtentry_howto): Delete and
6707 move HOWTOs into elf_howto_table.
6708 (R_386_standard, R_386_ext_offset): Define.
6709 (R_386_ext, R_386_vt_offset, R_386_vt): Define.
6710 (elf_i386_reloc_type_lookup): Modify calculation of index into
6711 elf_howto_table since we've removed the padding.
6712 (elf_i386_info_to_howto_rel): Likewise.
6713 (elf_i386_relocate_section): Likewise.
6715 2000-06-06 Michael Snyder <msnyder@seadog.cygnus.com>
6717 * elf.c (elf_grok_pr_status): Eliminate reference to prgregset_t.
6719 2000-06-05 H.J. Lu <hjl@gnu.org>
6721 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Don't flag
6722 an error when seeing an undefined symbol with hidden/internal
6723 attribute. It is handled in *_relocate_section ().
6725 2000-06-05 H.J. Lu <hjl@gnu.org>
6727 * elflink.h (elf_fix_symbol_flags): Follow the link for the
6728 indirect symbol for the ELF_LINK_NON_ELF bit.
6729 (elf_link_output_extsym): Don't output the indirect symbol even
6730 if the ELF_LINK_NON_ELF bit is set.
6732 2000-06-01 J.T. Conklin <jtc@redback.com>
6734 * config.bfd (i[3456]86-*-netbsdelf*): New target.
6735 (i[3456]86-*-netbsdaout*): New target.
6736 (i[3456]86-*-netbsd*): Add bfd_elf32_i386_vec to targ_selvecs.
6737 (i[3456]86-*-openbsd*): Likewise.
6739 2000-05-30 Andrew Cagney <cagney@b1.cygnus.com>
6741 * trad-core.c: From hpux-core.c, include <dirent.h> or
6742 <sys/ndir.h> when possible.
6744 2000-05-31 Ulrich Drepper <drepper@redhat.com>
6746 * elf.c (_bfd_elf_slurp_version_tables): Correct reading of version
6747 definitions. We must not assume they are sorted in the file
6748 according to their index numbers.
6750 2000-05-31 Alan Modra <alan@linuxcare.com.au>
6752 * elf-hppa.h: (elf_hppa_final_link_relocate): Use e_rsel field
6753 selector for R_PARISC_PCREL17R. R_PARISC_DIR17R and
6754 R_PARISC_DIR17F are for absolute branches; Handle them as such.
6756 2000-05-30 Nick Clifton <nickc@cygnus.com>
6758 * cpu-i960.c (scan_960_mach): Accept 80960KA, 80960KB,
6759 80960CA, 80960MC as valid machine names.
6761 2000-05-30 H.J. Lu <hjl@gnu.org>
6763 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Clear the
6764 visibility bits if the symbol is undefined. Correctly handle
6765 weak undefined symbols with hidden and internal attributes.
6767 * elflink.h (elf_link_add_object_symbols): Always turn the
6768 symbol into local if it has the hidden or internal attribute.
6770 2000-05-29 Philip Blundell <philb@gnu.org>
6772 * ppcboot.c: Add packed attribute if compiling with GCC.
6774 2000-05-29 Anatoly Vorobey <mellon@pobox.com>
6776 * elf.c (_bfd_elf_link_hash_table_init): Initialize dynlocal.
6778 2000-05-26 Michael Snyder <msnyder@seadog.cygnus.com>
6780 * elf.c (elfcore_grok_prstatus, elfcore_grok_pstatus,
6781 elfcore_grok_psinfo): Add code to allow debugging a 32-bit
6782 corefile on a 64-bit (Sparc Solaris) host. Also clean up
6785 2000-05-26 Alan Modra <alan@linuxcare.com.au>
6787 * Makefile.am: Update dependencies with "make dep-am"
6788 * Makefile.in: Regenerate.
6790 * sysdep.h (gettext, dgettext, dcgettext, textdomain,
6791 bindtextdomain): Replace defines with those from intl/libgettext.h
6792 to quieten gcc warnings.
6794 2000-05-26 Eli Zaretskii <eliz@is.elta.co.il>
6796 * aoutx.h (find_nearest_line): Use IS_ABSOLUTE_PATH.
6798 * archive.c (normalize, bfd_bsd_truncate_arname,
6799 bfd_gnu_truncate_arname) [HAVE_DOS_BASED_FILE_SYSTEM]: Support
6800 file names with backslashes.
6802 * cache.c (bfd_open_file) [__MSDOS__]: Don't unlink the file
6805 * sysdep.h: Include filenames.h.
6807 2000-05-26 Alan Modra <alan@linuxcare.com.au>
6809 * opncls.c (bfd_close_all_done): Mask file perms with 0777 not 0x777.
6811 2000-05-26 Jakub Jelinek <jakub@redhat.com>
6813 * elf64-sparc.c (sparc64_elf_relax_section): New.
6814 (sparc64_elf_relocate_section): Optimize tail call into branch always
6816 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
6817 (elf32_sparc_relax_section): New.
6819 2000-05-26 Jakub Jelinek <jakub@redhat.com>
6821 * elf64-sparc.c: Add ATTRIBUTE_UNUSED to unused function parameters.
6822 Remove unusued variables.
6823 (sparc64_elf_relocate_section): Change r_symndx type to unsigned long.
6824 (sparc64_elf_merge_private_bfd_data): Fix shared library case from
6825 previous fix, so that shared libs really don't influence targets
6826 extension mask and memory model.
6828 2000-05-23 H.J. Lu <hjl@gnu.org>
6830 * elf64-alpha.c (elf64_alpha_relocate_section): Check
6831 h->root.other not h->other.
6832 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
6834 * elf32-ppc.c (ppc_elf_relocate_section): Fix a typo.
6836 2000-05-23 H.J. Lu <hjl@gnu.org>
6838 * elf32-i386.c (elf_i386_relocate_section): Don't allow the
6839 undefined symbol with the non-default visibility attributes.
6840 * elf-hppa.h (elf_hppa_relocate_section): Likewise.
6841 * elf32-arm.h (elf32_arm_relocate_section): Likewise.
6842 * elf32-i370.c (i370_elf_relocate_section): Likewise.
6843 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
6844 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
6845 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
6846 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
6847 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
6848 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
6849 * elf64-ia64.c (elf64_ia64_relocate_section): Likewise.
6850 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
6852 2000-05-22 Richard Henderson <rth@cygnus.com>
6854 * elf64-ia64.c (ia64_howto_table): Add PCREL60B, PCREL21BI,
6855 PCREL22, PCREL64I. Zero size of special relocs.
6856 (elf64_ia64_reloc_type_lookup): Likewise.
6857 (USE_BRL, oor_brl, oor_ip): New.
6858 (elf64_ia64_relax_section): New.
6859 (elf64_ia64_check_relocs): Handle PCREL60B, PCREL22, PCREL64I.
6860 (elf64_ia64_install_value): Likewise, plus PCREL21BI.
6861 (elf64_ia64_relocate_section): Likewise.
6862 (bfd_elf64_bfd_relax_section): New.
6863 * reloc.c (BFD_RELOC_IA64_PCREL21BI): New.
6864 (BFD_RELOC_IA64_{PCREL22,PCREL60B,PCREL64I}): New.
6865 * bfd-in2.h, libbfd.h: Regenerate.
6867 2000-05-22 Nick Clifton <nickc@cygnus.com>
6869 * configure.in : Add peigen.lo to MIPS PE targets.
6870 * configure: Regenerate.
6872 2000-05-22 Momchil Velikov <velco@fadata.bg>
6874 * libbfd.c (_bfd_generic_verify_endian_match): Compare endianess
6875 only if it is known for both input and output bfds. Separate
6876 error message strings as in some languages, it may be necessary
6877 to change more than one place in the string to change between
6880 * elf32-ppc.c (ppc_elf_merge_private_bfd_data): Remove inline
6881 endianess checks, call _bfd_generic_verify_endian_match() instead.
6883 * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Likewise.
6885 * elf32-mcore.c (mcore_elf_merge_private_bfd_data): Likewise.
6887 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Likewise. Verify
6888 endianess before checking bfd flavours.
6890 2000-05-22 H.J. Lu <hjl@gnu.org>
6892 * elflink.h (elf_link_output_extsym): Clear the visibility
6893 field for symbols not defined locally.
6895 2000-05-18 Alan Modra <alan@linuxcare.com.au>
6897 * libhppa.h (re_assemble_3, re_assemble_12, re_assemble_16,
6898 re_assemble_17, re_assemble_21, re_assemble_22): Don't mask insn.
6899 (hppa_rebuild_insn): Mask immediate bits here instead.
6900 * elf-hppa.h (elf_hppa_relocate_insn): Mask here too.
6902 2000-05-18 Momchil Velikov <velco@fadata.bg>
6904 * elflink.h (elf_bfd_final_link, elf_link_input_bfd): When emiting
6905 relocs for an executable, ensure that they are virtual addresses.
6907 2000-05-18 Jeffrey A Law (law@cygnus.com)
6909 * config.bfd (hppa*64*-*-hpux11*): New target triplet.
6911 2000-05-17 S. Bharadwaj Yadavalli <sby@scrugs.lkg.dec.com>
6912 Rick Gorton <gorton@scrugs.lkg.dec.com>
6914 * elflink.h: Add emitrelocations support: when enabled, relocation
6915 information and relocation sections are put into final output
6916 executables. If the emitrelocations flag is set, do the following:
6917 (elf_bfd_final_link): Emit relocation sections.
6918 (elf_link_input_bfd): Compute relocation section contents.
6919 (elf_gc_sections): Don't clean relocation sections.
6921 2000-05-16 Catherine Moore <clm@cygnus.com>
6923 * som.c (som_decode_symclass): Recognize weak symbols.
6925 2000-05-16 Szabolcs Szakacsits <szaka@F-Secure.com>
6927 * peigen.c (pe_print_idata): Undo part of 2000-05-12 change that
6928 read idata section only from dataoff.
6929 (pe_print_edata): Correctly check for valid eat_member.
6931 2000-05-16 J"orn Rennecke <amylaar@cygnus.co.uk>
6933 * elf32-sh.c (sh_elf_relax_delete_bytes): Handle R_SH_SWITCH8.
6935 2000-05-14 Philip Blundell <philb@gnu.org>
6937 * config.bfd (armeb-*-elf, arm*b-*-linux-gnu*): New targets.
6939 2000-05-12 Alan Modra <alan@linuxcare.com.au>
6941 * targets.c (bfd_target_vector): #ifdef BFD64 rs6000coff64_vec
6943 * peigen.c (pe_print_idata): Look for .idata section and print
6944 info even if data directory has zero entries. Read idata section
6945 starting from dataoff, and adjust all data offsets to suit. Cast
6946 all bfd_vma vars to unsigned long before passing to fprintf.
6947 * peigen.c (pe_print_edata): Similarly, look for .edata section
6948 and print info even if data directory has zero entries. Cast
6949 all bfd_vma vars to unsigned long before passing to fprintf.
6951 From Szabolcs Szakacsits <szaka@F-Secure.com>
6952 * peigen.c (pe_print_idata): Use bfd_section_size rather than data
6953 directory size which may be bogus.
6954 * peigen.c (pe_print_edata): Similarly.
6956 2000-05-09 Alan Modra <alan@linuxcare.com.au>
6958 * elf.c (bfd_section_from_shdr): Don't set use_rela_p if rela
6960 (copy_private_bfd_data): Allow for space possibly taken up by elf
6961 headers when calculating segment physical address from lma.
6963 2000-05-08 Alan Modra <alan@linuxcare.com.au>
6965 * versados.c (versados_scan): Init stringlen and pass_2_done.
6967 * trad-core.c (trad_unix_core_file_p): Return
6968 bfd_error_wrong_format rather than bfd_error_file_truncated.
6970 * peigen.c (_bfd_pei_swap_aouthdr_out): Pass ImageBase to
6971 add_data_entry. DataDirectory virtual address is relative.
6972 (pe_print_idata): Account for relative DataDirectory virtual
6973 addresses. Don't trash datasize inside POWERPC_LE_PE code.
6974 (pe_print_edata): Similarly.
6976 From Szabolcs Szakacsits <szaka@F-Secure.com>
6977 * peigen.c (dir_names): Add Delay Import Directory.
6978 (pe_print_idata): Always search for bfd section containing
6979 idata address rather than looking up section name. Print this
6980 section name rather than .idata.
6981 (pe_print_edata): Similarly. Also print some fields as %08lx.
6982 (_bfd_pe_print_private_bfd_data_common): Print Reserved1 field as
6985 2000-05-05 Clinton Popetz <cpopetz@cygnus.com>
6987 * xcoff.h: Rename to xcoff-target.h
6988 * Makefile.am: Change all instances of xcoff.h to xcoff-target.h
6989 * coff-rs6000.c: Ditto.
6990 * coff64-rs6000.c: Ditto.
6991 * coff-pmac.c: Ditto.
6992 * Makefile.in: Regenerate.
6994 2000-05-05 Clinton Popetz <cpopetz@cygnus.com>
6996 * coffcode.h (coff_set_arch_mach_hook, coff_set_flags):
6997 Change U802TOC64MAGIC to U803XTOCMAGIC.
6999 2000-05-04 Michael Snyder <msnyder@seadog.cygnus.com>
7001 * elf.c (bfd_elf_get_arch_size): New function, return 32 | 64 | -1.
7002 * bfd-in.h: Prototype bfd_elf_get_arch_size.
7003 * bfd-in2.h: Prototype bfd_elf_get_arch_size.
7005 2000-05-04 Alan Modra <alan@linuxcare.com.au>
7007 * libhppa.h (HPPA_R_CONSTANT): Cast argument to bfd_signed_vma.
7009 2000-05-03 Martin v. L
\81öwis <loewis@informatik.hu-berlin.de>
7011 * elflink.h (elf_link_add_object_symbols): Reset dynindx for
7012 hidden and internal symbols.
7013 (elf_fix_symbol_flags): Clear NEEDS_PLT for symbols with
7015 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Do not
7016 assign a PLT or GOT entry to symbols with hidden and
7017 internal visibility.
7019 2000-05-03 Mark Elbrecht <snowball3@bigfoot.com>
7021 * coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Add entry for
7023 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
7025 2000-05-02 H.J. Lu <hjl@gnu.org>
7027 * elf.c (prep_headers): Use ELFOSABI_NONE instead of
7030 2000-05-02 Alan Modra <alan@linuxcare.com.au>
7032 * targets.c (bfd_target_vector): Restore bfd_elf32_hppa_vec.
7033 * Makefile.am (BFD32_BACKENDS): Restore elf32-hppa.lo. Regenerate
7035 * Makefile.in: Regenerate.
7037 2000-05-01 Jim Wilson <wilson@cygnus.com>
7039 * Makefile.am (BFD32_BACKENDS): Add efi-app-ia32.lo.
7040 (BFD32_BACKENDS_CFILES): Add efi-app-ia32.c.
7041 (BFD64_BACKENDS): Delete coff-ia64.lo. Add efi-app-ia64.lo.
7042 (BFD64_BACKENDS_CFILES): Delete coff-ia64.c. Add efi-app-ia64.c.
7043 * Makefile.in: Rebuild.
7045 2000-05-02 Alan Modra <alan@linuxcare.com.au>
7047 * config.bfd: Re-enable elf32-hppa. It now compiles, even if it
7048 doesn't work very well.
7050 * elf-hppa.h (elf_hppa_internal_shdr): Define.
7051 (elf_hppa_fake_sections): hdr is elf_hppa_internal_shdr.
7052 Set hdr->s_type to 1 if ARCH_SIZE == 32.
7053 (_bfd_elf_hppa_gen_reloc_type): Add prototype.
7054 (elf_hppa_info_to_howto): Likewise.
7055 (elf_hppa_info_to_howto_rel): Likewise.
7056 (elf_hppa_reloc_type_lookup): Likewise.
7057 (elf_hppa_is_local_label_name): Likewise.
7058 (elf_hppa_fake_sections): Likewise.
7059 (elf_hppa_final_write_processing): Likewise.
7060 (elf_hppa_howto_table): Fully initialise all entries.
7061 (_bfd_elf_hppa_gen_reloc_type): Add ATTRIBUTE_UNUSED to args.
7062 (elf_hppa_info_to_howto): Likewise.
7063 (elf_hppa_info_to_howto_rel): Likewise.
7064 (elf_hppa_reloc_type_lookup): Likewise.
7065 (elf_hppa_final_write_processing, elf_hppa_add_symbol_hook,
7066 elf_hppa_unmark_useless_dynamic_symbols,
7067 elf_hppa_remark_useless_dynamic_symbols,
7068 elf_hppa_record_segment_addrs, elf_hppa_final_link,
7069 elf_hppa_relocate_section, elf_hppa_final_link_relocate,
7070 elf_hppa_relocate_insn): Compile only if ARCH_SIZE == 64 until
7071 elf32-hppa.c mess is cleaned up.
7072 (elf_hppa_final_link_relocate): Make insn and r_type unsigned
7073 int. Delete r_field. In case R_PARISC_PCREL21L, don't set
7074 r_field then call hppa_field_adjust inline func with variable
7075 r_field arg, instead call hppa_field_adjust with fixed arg.
7076 In case R_PARISC_PCREL22F, don't set r_field.
7077 (elf_hppa_relocate_insn): Change args and return type to unsigned
7078 int. Call re_assemble_* funcs to do the work.
7080 * elf32-hppa.c (hppa_elf_relocate_insn): Don't assume 32 bit when
7083 * libhppa.h (HPPA_R_CONSTANT): Don't assume 32 bit when sign
7085 (sign_extend): Mask first before sign extending.
7086 (low_sign_extend): Rewrite without condition expression.
7087 (ones, dis_assemble_3, dis_assemble_12, dis_assemble_16,
7088 dis_assemble_17, dis_assemble_21, dis_assemble_22): Delete.
7089 (assemble_3, assemble_6, assemble_12, assemble_16, assemble_16a,
7090 assemble_17, assemble_21, sign_unext, low_sign_unext): Return
7091 result as function return value rather than through pointer arg.
7092 Accept unsigned int args, and return unsigned int.
7093 (re_assemble_3): New. Combines function of dis_assemble_3 with
7094 re-assembly of opcode and immediate.
7095 (re_assemble_12): Likewise.
7096 (re_assemble_16): Likewise.
7097 (re_assemble_17): Likewise.
7098 (re_assemble_21): Likewise.
7099 (re_assemble_22): Likewise.
7100 (hppa_field_adjust): Rewrite and document, paying attention to
7101 size of types and signed/unsigned issues.
7102 (get_opcode): Shift before masking.
7103 (FDLW): Rename to FLDW.
7104 (bfd_hppa_insn2fmt): Change arg to unsigned int. Delete fmt.
7105 (hppa_rebuild_insn): Change args and return value to unsigned
7106 int. Make use of re_assemble_*. Correct case 11.
7108 * dep-in.sed: Handle ../opcodes/.
7109 * Makefile.am (SOURCE_HFILES): Add elf-hppa.h, elf32-hppa.h,
7110 elf64-hppa.h, hppa_stubs.h, xcoff.h.
7111 (BFD32_BACKENDS_CFILES): Restore elf32-hppa.c.
7112 Remove elf64-hppa.lo, cpu-ia64.lo, elf64-ia64.lo, elfarm-oabi.lo,
7113 elfarm-nabi.lo dependencies outside of auto-dependency area.
7114 Regenerate dependencies.
7115 * Makefile.in: Regenerate.
7117 * configure.in (TRAD_HEADER): Test non-null before
7119 * configure: Regenerate.
7121 * reloc.c: Fix mis-spelling in comment.
7123 2000-05-01 Alan Modra <alan@linuxcare.com.au>
7125 * coff-sh.c (bfd_coff_small_swap_table): Fix Fri Apr 28 change.
7126 * vms.c (vms_openr_next_archived_file): Return NULL.
7128 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7130 * coffcode.h Copy changes mistakenly done to libcoff.h in
7133 2000-04-29 Andreas Jaeger <aj@suse.de>
7135 * libbfd-in.h: Correctly check GCC version.
7136 * bfd-in.h: Likewise.
7137 * libhppa.h: Likewise.
7138 * libbfd.h: Regenerate.
7139 * bfd-in2.h: Regenerate.
7141 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7143 * Makefile.am (BFD64_BACKENDS, BFD64_BACKENDS_CFILES): Add
7144 coffdu-rs6000.{lo,c}.
7145 (coff-pmac.lo, coff-rs6000.lo, coff64-rs6000.lo): Add dependency
7147 * Makefile.in: Regenerate.
7148 * xcoff.h: New file.
7149 * coff-pmac.c: Use xcoff.h instead of coff-rs6000.c.
7150 * coff-rs6000.c: Move all declarations and defines that are
7151 common to the xcoff backends into xcoff.h
7152 * coff64-rs6000.c: Ditto,
7154 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7156 * coff-mips.c (mips_ecoff_backend_data): Add initialization of
7157 _bfd_coff_force_symnames in strings and
7158 _bfd_coff_debug_string_prefix_length to their default values.
7159 * coff-sh.c: (bfd_coff_small_swap_table): Ditto.
7161 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7163 * coff-alpha.c (alpha_ecoff_backend_data): Add initialization of
7164 _bfd_coff_force_symnames in strings and
7165 _bfd_coff_debug_string_prefix_length to their default values.
7167 2000-04-27 Alan Modra <alan@linuxcare.com.au>
7169 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Return if dynobj NULL.
7170 Check local_got_refcounts before dereferencing.
7172 * elf32-ppc.c (ppc_elf_relocate_section): Check splt != NULL
7173 before deciding we don't need R_PPC_PLT32 relocation.
7174 (ppc_elf_gc_sweep_hook): Check local_got_refcounts before
7177 * elflink.h (elf_gc_common_finalize_got_offsets): Fix comment.
7179 * elf32-i386.c (elf_i386_check_relocs): Reference count .got and
7181 (elf_i386_gc_sweep_hook): Garbage collect .got and .plt entries.
7182 (elf_i386_adjust_dynamic_symbol): Recognize unused .plt entries.
7183 (elf_i386_relocate_section): Allow for .plt to go missing.
7184 (elf_i386_finish_dynamic_symbol): Use same test to decide if we
7185 can use a relative reloc for got as elf_i386_relocate_section.
7186 (bfd_elf32_bfd_final_link): Define to use gc form of final link.
7188 2000-04-26 Clinton Popetz <cpopetz@cygnus.com>
7190 * config.bfd: Remove extraneous bfd_powerpc_64_arch.
7192 2000-04-24 Clinton Popetz <cpopetz@cygnus.com>
7194 * Makefile.am (coff64-rs6000.lo): New rule.
7195 * Makefile.in: Regenerate.
7196 * coff-rs6000.c (xcoff_mkobject, xcoff_copy_private_bfd_data,
7197 xcoff_is_local_label_name, xcoff_rtype2howto,
7198 xcoff_reloc_type_lookup, xcoff_slurp_armap, xcoff_archive_p,
7199 xcoff_read_ar_hdr, xcoff_openr_next_archived_file, xcoff_write_armap,
7200 xcoff_write_archive_contents): No longer static, and prefix with _bfd_.
7201 (NO_COFF_SYMBOLS): Define.
7202 (xcoff64_swap_sym_in, xcoff64_swap_sym_out, xcoff64_swap_aux_in,
7203 xcoff64_swap_aux_out): New functions; handle xcoff symbol tables
7205 (MINUS_ONE): New macro.
7206 (xcoff_howto_tabl, xcoff_reloc_type_lookup): Add 64 bit POS
7208 (coff_SWAP_sym_in, coff_SWAP_sym_out, coff_SWAP_aux_in,
7209 coff_SWAP_aux_out): Map to the new functions.
7210 * coff64-rs6000.c: New file.
7211 * libcoff.h (bfd_coff_backend_data): Add new fields
7212 _bfd_coff_force_symnames_in_strings and
7213 _bfd_coff_debug_string_prefix_length.
7214 (bfd_coff_force_symnames_in_strings,
7215 bfd_coff_debug_string_prefix_length): New macros for above fields.
7216 * coffcode.h (coff_set_arch_mach_hook): Handle XCOFF64 magic.
7217 Set machine to 620 for XCOFF64. Use bfd_coff_swap_sym_in instead
7218 of using coff_swap_sym_in directly.
7219 (FORCE_SYMNAMES_IN_STRINGS): New macro, defined for XCOFF64.
7220 (coff_set_flags) Set magic for XCOFF64.
7221 (coff_compute_section_file_positions): Add symbol name length to
7222 string section length if bfd_coff_debug_string_prefix_length is
7224 (coff_write_object_contents): Don't do reloc overflow for XCOFF64.
7225 (coff_slurp_line_table): Use bfd_coff_swap_lineno_in instead of
7226 using coff_swap_lineno_in directly.
7227 (bfd_coff_backend_data): Add _bfd_coff_force_symnames_in_strings
7228 and _bfd_coff_debug_string_prefix_length fields.
7229 * coffgen.c (coff_fix_symbol_name, coff_write_symbols): Force
7230 symbol names into strings table when
7231 bfd_coff_force_symnames_in_strings is true.
7232 * coffswap.h (MAX_SCNHDR_NRELOC, MAX_SCNHDR_NLNNO, GET_RELOC_VADDR,
7233 SET_RELOC_VADDR): New macros.
7234 (coff_swap_reloc_in, coff_swap_reloc_out): Use above macros.
7235 (coff_swap_aux_in, coff_swap_aux_out): Remove RS6000COFF_C
7237 (coff_swap_aouthdr_in, coff_swap_aouthdr_out): Handle XCOFF64
7238 changes within RS6000COFF_C specific code.
7239 (coff_swap_scnhdr_out): Use PUT_SCNHDR_NLNNO, PUT_SCNHDR_NRELOC,
7240 MAX_SCNHDR_NRELOC, and MAX_SCNHDR_NLNNO.
7241 * reloc.c (bfd_perform_relocation, bfd_install_relocation):
7242 Extend existing hack on target name.
7243 * xcofflink.c (XCOFF_XVECP): Extend existing hack on
7245 * coff-tic54x.c (ticof): Keep up to date with new fields
7246 in bfd_coff_backend_data.
7247 * config.bfd: Add bfd_powerpc_64_arch to targ_arch and define
7248 targ_selvecs to include rs6000coff64_vec for rs6000.
7249 * configure.in: Add rs6000coff64_vec case.
7250 * cpu-powerpc.c: New bfd_arch_info_type.
7252 2000-04-24 Jeffrey A Law (law@cygnus.com)
7254 * config.bfd: Only disable elf32-hppa vectors, not all of the
7255 BSD and OSF configuration support. Provide (disabled) clauses
7257 * configure.in: Add clause for PA64 support.
7258 * configure: Rebuilt.
7260 * targets.c (bfd_target_vector): Add bfd_elf64_hppa_vec.
7261 (bfd_elf64_hppa_vec): Declare.
7263 * Makefile.am (BFD64_BACKENDS): Add elf64-hppa.lo
7264 (BFD64_BACKENDS_CFILES): Add elf64-hppa.c
7265 (elf64-hppa.lo): Add dependencies.
7266 * Makefile.in: Rebuilt.
7268 * elf64-hppa.c, elf64-hppa.h: New files with PA64 support.
7270 2000-04-24 Jason Eckhardt <jle@cygnus.com>
7272 * libhppa.h (dis_assemble_16): New function.
7273 (pa_arch): Added pa20w element.
7275 2000-04-24 Ulrich Drepper <drepper@cygnus.com>
7277 * elf-bfd.h: Add prototypes for bfd_elf32_write_relocs,
7278 bfd_elf32_slurp_reloc_table, bfd_elf64_write_relocs, and
7279 bfd_elf64_slurp_reloc_table.
7281 * elfcode.h (elf_write_relocs, elf_slurp_reloc_table): New
7282 definitions to get external names.
7283 (elf_write_relocs): Renamed from write_relocs and make global.
7284 (elf_slurp_reloc_table): Make global.
7285 (_bfd_elf,size_info): Use elf_write_relocs instead of write_relocs.
7287 * archive.c (hpux_uid_gid_encode): New function.
7288 (bfd_ar_hdr_from_filesystem): Use it if HPUX_LARGE_AR_IDS is
7289 defined and the ID is greater than 99999.
7290 (bfd_generic_stat_arch_elt): If HPUX_LARGE_AR_IDS is defined decode
7291 special uid/gid fields into 32 bit values.
7293 2000-04-21 Matthew Green <mrg@cygnus.com>
7295 * config.bfd: Add NetBSD/sparc64 support.
7297 Fri Apr 21 13:20:53 2000 Richard Henderson <rth@cygnus.com>
7298 David Mosberger <davidm@hpl.hp.com>
7299 Timothy Wall <twall@cygnus.com>
7300 Jim Wilson <wilson@cygnus.com>
7302 * Makefile.am (ALL_MACHINES): Add cpu-ia64.lo.
7303 (ALL_MACHINES_CFILES): Add cpu-ia64.c.
7304 (BFD64_BACKENDS): Add elf64-ia64.lo.
7305 (BFD64_BACKENDS_CFILES): Add elf64-ia64.c.
7306 (cpu-ia64.lo, elf64-ia64.lo): New rules.
7307 * Makefile.in: Rebuild.
7308 * archures.c (enum bfd_architecture): Add bfd_arch_ia64.
7309 (bfd_ia64_arch): Declare.
7310 (bfd_archures_list): Add bfd_ia64_arch.
7311 * bfd-in2.h: Rebuild.
7312 * config.bfd: (ia64*-*-linux-gnu*, ia64*-*-elf*): New targets.
7313 * configure: Rebuild.
7314 * configure.host: (ia64-*-linux*): New host.
7315 * configure.in (bfd_elf64_ia64_little_vec, bfd_elf64_ia64_big_vec,
7316 bfd_efi_app_ia64_vec, bfd_efi_app_ia64_vec): New vectors.
7317 * elf.c (prep_headers): Add bfd_arch_ia64.
7318 * libbfd.h: Rebuild.
7319 * reloc.c: Add IA-64 relocations.
7320 * targets.c (bfd_elf64_ia64_little_vec, bfd_elf64_ia64_big_vec):
7322 (bfd_target_vect): Add bfd_elf64_ia64_little_vec.
7323 * cpu-ia64-opc.c, cpu-ia64.c, elf64-ia64.c: New files.
7325 2000-04-21 Richard Henderson <rth@cygnus.com>
7327 * elf32-d30v.c (bfd_elf_d30v_reloc): Don't modify section
7328 contents when performing a partial link.
7329 (bfd_elf_d30v_reloc_21): Likewise.
7331 2000-04-20 H.J. Lu <hjl@gnu.org>
7333 * elf32-i386.c (elf_i386_relocate_section): Restrict 1998-12-10
7334 patch to symbols defined by a shared object.
7335 * elf32-ppc.c (ppc_elf_relocate_section): Similarly.
7337 2000-04-19 Michael Sokolov <msokolov@ivan.Harhan.ORG>
7340 * dwarf2.c (concat_filename): Avoid string literal concatenation.
7341 * ieee.c (ieee_get_symtab): Don't initialise union in struct.
7343 Mon Apr 17 19:14:36 2000 David Mosberger <davidm@hpl.hp.com>
7345 * Makefile.am (BFD64_BACKENDS): Mention coff-ia64.lo.
7346 (BFD64_BACKENDS_CFILES): Mention coff-ia64.c
7347 (coff-ia64.lo): Add dependency.
7348 * Makefile.in: Regenerate.
7349 * coff-ia64.c: New file.
7350 * efi-app-ia32.c: Ditto.
7351 * efi-app-ia64.c: Ditto.
7352 * coffcode.h (coff_set_arch_mach_hook): Handle IA64MAGIC.
7353 (coff_set_flags): Ditto.
7354 (coff_write_object_contents) [IA64]: Set magic number to ZMAGIC.
7355 * config.bfd (i[3456]86-*-linux-gnu*): Mention bfd_efi_app_ia32_vec.
7356 * configure.in (elf): Handle bfd_efi_app_ia32 and bfd_efi_app_ia64_vec.
7357 * configure: Regenerate.
7358 * libpei.h (GET_OPTHDR_IMAGE_BASE): New macro.
7359 (PUT_OPTHDR_IMAGE_BASE): Ditto.
7360 (GET_OPTHDR_SIZE_OF_STACK_RESERVE): Ditto.
7361 (PUT_OPTHDR_SIZE_OF_STACK_RESERVE): Ditto.
7362 (GET_OPTHDR_SIZE_OF_STACK_COMMIT): Ditto.
7363 (PUT_OPTHDR_SIZE_OF_STACK_COMMIT): Ditto.
7364 (GET_OPTHDR_SIZE_OF_HEAP_RESERVE): Ditto.
7365 (PUT_OPTHDR_SIZE_OF_HEAP_RESERVE): Ditto.
7366 (GET_OPTHDR_SIZE_OF_HEAP_COMMIT): Ditto.
7367 (PUT_OPTHDR_SIZE_OF_HEAP_COMMIT): Ditto.
7368 (GET_PDATA_ENTRY): Ditto.
7369 * peigen.c (_bfd_pei_swap_aouthdr_in) [COFF_WITH_PEP64]: Don't read
7370 data_start. Use above macros to read fields that are 64 bit wide for
7371 COFF_WITH_PEP64. Don't truncate entry and text_start to 32 bits.
7372 (_bfd_pei_swap_aouthdr_out) [PEI_FORCE_MINIMUM_ALIGNMENT]: Force
7373 FileAlignment and SectionAlignment to minimum alignment if they
7375 (_bfd_pei_swap_aouthdr_out) [PEI_DEFAULT_TARGET_SUBSYSTEM]: Set
7376 Subsystem to default PEI_DEFAULT_TARGET_SUBSYSTEM.
7377 (_bfd_pei_swap_aouthdr_out) [COFF_WITH_PEP64]: Don't set data_start.
7378 Use above macros to write fields that are 64 bit wide for
7380 (pe_print_pdata): Set PDATA_ROW_SIZE to 3*8 for COFF_WITH_PEP64,
7381 5*4 otherwise. This should be right for IA-32 and IA-64, but may
7382 be wrong for platforms. Use PDATA_ROW_SIZE instead of hardcoded
7383 value of 20 bytes. Modify printing for COFF_WITH_PEP64 to print
7384 begin address, end address, and unwind info address only. Use
7385 GET_PDATA_ENTRY() to read .pdata entries. Use fprintf_vma() to
7387 (tbl): Add SECTION, REL32, RESERVED1, MIPS_JMPADDR16, DIR64, and
7388 HIGH3ADJ relocation names.
7389 (_bfd_pe_print_private_bfd_data): Print Subsystem name in legible form.
7390 * targets.c: Declare bfd_efi_app_ia32_vec and
7391 bfd_efi_app_ia64_vec.
7392 (bfd_target_vector): Mention bfd_efi_app_ia32_vec and
7393 bfd_efi_app_ia64_vec.
7395 2000-04-17 Timothy Wall <twall@cygnus.com>
7397 * bfd-in2.h: Add prototypes for tic54x load page access.
7398 * bfd-in.h: Regenerate.
7399 * coff-tic54x.c: Add load page functions; allow bfd_arch_unknown
7400 in customized _set_arch_mach function.
7401 * coffcode.h (coff_set_alignment_hook): Set section load page if
7402 the appropriate macro is defined.
7403 (write_object_contents): Read section load page.
7405 2000-04-13 Alan Modra <alan@linuxcare.com.au>
7407 * elf32-hppa.h: Update copyright date.
7409 * elf32-fr30.c (fr30_elf_i20_reloc): Don't use U suffix.
7410 * elf32-mips.c (_bfd_mips_elf_relocate_section): And here.
7412 * elf32-d30v.c (MAX32): Don't use LL suffix.
7413 (MIN32): Define in terms of MAX32.
7414 (bfd_elf_d30v_reloc): Make relocation a bfd_signed_vma.
7416 * coff-a29k.c (SIGN_EXTEND_HWORD): Replace with more concise
7419 * peicode.h (pe_ILF_build_a_bfd): Remove UL from hex constants.
7421 2000-04-12 Alan Modra <alan@linuxcare.com.au>
7423 * dep-in.sed: Match space before file name, not after.
7424 * Makefile.am: Regenerate dependencies.
7425 * Makefile.in: Regenerate.
7427 * reloc.c (_bfd_relocate_contents): In complain_overflow_bitfield
7428 case, allow address wrap-around stupidly removed 2000-03-17. Sign
7429 extend without an if statement.
7431 2000-04-11 Alan Modra <alan@linuxcare.com.au>
7433 * coff-mips.c (mips_gprel_reloc): Test for 16 bit range using
7435 * elf32-mips.c (gprel16_with_gp): Likewise.
7436 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Test range
7437 here using -0x40000, not (int)0xfffc0000.
7438 (elf32_hppa_size_of_stub): Likewise.
7440 2000-04-11 Timothy Wall <twall@cygnus.com>
7442 * coff-tic54x.c: Now builds with all targets.
7443 * Makefile.am: Add coff/tic54x.h to coff-tic54x.o dependencies.
7444 * Makefile.in: Regenerate.
7445 * coffcode.h (coff_set_arch_mach_hook): Eliminate warning on
7446 unitialized variable.
7448 Fri Apr 7 15:56:57 2000 Andrew Cagney <cagney@b1.cygnus.com>
7450 * configure.in (WARN_CFLAGS): Set to -W -Wall by default. Add
7451 --enable-build-warnings option.
7452 * Makefile.am (AM_CFLAGS, WARN_CFLAGS): Add definitions.
7453 * Makefile.in, configure: Re-generate.
7455 2000-04-07 Nick Clifton <nickc@cygnus.com>
7457 * reloc.c: Add BFD_RELOC_ARM_PCREL_BLX and
7458 BFD_RELOC_THUMB_PCREL_BLX.
7460 * elf32-arm.h (elf32_arm_final_link_relocate): Handle
7461 R_ARM_XPC25 and R_ARM_THM_PC22.
7463 * elfarm-nabi.c (elf32_arm_howto_): Fix definitions of
7464 R_ARM_XPC25 and R_ARM_THM_XPC22.
7465 (elf32_arm_reloc_map): Make BFD_RELOC_{ARM|THUMB}_PCREL_BLX to
7466 R_ARM_[XPC25|THM_XPC22].
7468 * elfarm-oabi.c: Define OLD_ARM_ABI and change include from
7469 elf/arm-oabi.h to elf/arm.h
7471 * Makefile.am: Fix dependency for elfarm-oabi.c
7472 * Makefile.in: Regenerate.
7474 * bfd-in2.h: Regenerate.
7475 * libbfd.h: Regenerate.
7477 2000-04-06 Michael Snyder <msnyder@seadog.cygnus.com>
7479 * elfcore.h (elf_core_file_p): preserve value of tdata at entry,
7480 and restore it on failure. Release newly allocated tdata on
7483 Fri Apr 7 11:33:47 2000 Jim Wilson <wilson@cygnus.com>
7485 * dwarf2.c (struct dwarf2_debug): New field dwarf_line_size.
7486 (decode_line_info): Set it. Report error if unit->line_offset is
7487 equal to or larger than it.
7489 2000-04-07 Timothy Wall <twall@cygnus.com>
7491 * targets.c: Added vecs for tic54x.
7492 * reloc.c: Added relocs for tic54x.
7493 * libbfd.h: Regenerated.
7494 * configure: Add TI COFF vecs for tic54x.
7495 * configure.in: Ditto.
7496 * config.bfd (targ_cpu): Recognize new tic54x target.
7497 * coffcode.h (coff_slurp_symbol_table): Additions for TI COFF handling.
7498 * bfd-in2.h: Add tic54x target and relocations.
7499 * Makefile.am, Makefile.in: Add tic54x target.
7500 * archures.c (bfd_archures_list): Add tic54x target.
7501 * coff-tic54x.c: New.
7502 * cpu-tic54x.c: New.
7504 2000-04-06 Michael Snyder <msnyder@seadog.cygnus.com>
7506 * elfcore.h (elf_core_file_p): call backend_object_p which
7507 thereby gets an opportunity to update the arch/machine type.
7509 2000-04-06 Timothy Wall <twall@cygnus.com>
7511 * coffcode.h (coff_slurp_symbol_table): Handle C_STATLAB storage
7512 class. Handle SEC_CLINK and SEC_BLOCK flags.
7513 * section.c: Add SEC_CLINK and SEC_BLOCK flags.
7514 * bfd-in2.h: Add SEC_CLINK and SEC_BLOCK flags.
7516 2000-04-06 Nick Clifton <nickc@cygnus.com>
7518 * elf32-arm.h (elf32_arm_set_private_flags): Only check for
7519 EF_INTERWORK if this is an unknown EABI.
7520 (elf32_arm_merge_private_bfd_data): Check EABI version
7521 numbers. Only check EF_xxx flags if the EABI version number
7523 (elf32_arm_check_private_bfd_data): Only check EF_xxx flags
7524 if the EABI version number is unknown.
7525 (elf32_arm_print_private_bfd_data): Only decode EF_xxx flags
7526 if the EABI version number is unknown.
7528 Wed Apr 5 22:04:20 2000 J"orn Rennecke <amylaar@cygnus.co.uk>
7530 * reloc.c (_bfd_relocate_contents): Add BFD_RELOC_SH_LOOP_START and
7531 BFD_RELOC_SH_LOOP_END.
7532 * elf32-sh.c (sh_elf_howto_tab): Change special_func to
7533 sh_elf_ignore_reloc for all entries that sh_elf_reloc used to ignore.
7534 Add entries for R_SH_LOOP_START and R_SH_LOOP_END.
7535 (sh_elf_reloc_loop): New function.
7536 (sh_elf_reloc): No need to test for always-to-be-ignored relocs
7538 (sh_rel): Add entries for BFD_RELOC_SH_LOOP_{START,END}.
7539 (sh_elf_relocate_section): Handle BFD_RELOC_SH_LOOP_{START,END}.
7540 * bfd-in2.h, libbfd.h: Regenerate.
7542 2000-04-04 Alan Modra <alan@linuxcare.com.au>
7544 * po/bfd.pot: Regenerate.
7546 * Makefile.am: Remove extraneous mkdep comment.
7547 (MKDEP): Use gcc -MM rather than mkdep.
7548 (DEP): Quote when passing vars to sub-make. Add warning
7550 (DEP1): Rewrite for "gcc -MM".
7551 (CLEANFILES): Add DEP2.
7552 Update dependencies.
7553 * Makefile.in: Regenerate.
7555 2000-04-03 Kevin Buettner <kevinb@redhat.com>
7557 * configure.in: Added corefile support for AIX 4.3. In particular,
7558 AIX_CORE_DUMPX_CORE will be defined in addition to AIX_CORE when
7559 compiling rs6000-core.c.
7560 * configure: Regenerated.
7562 2000-04-03 H.J. Lu <hjl@gnu.org>
7564 * cache.c (bfd_open_file): Unlink the output file only if
7565 it has non-zero size.
7567 2000-04-01 Ken Block USG <block@zk3.dec.com>
7569 * elf64-alpha.c (elf64_alpha_relocate_section): Don't emit
7570 relative relocations for non-loaded sections in shared objects.
7571 (elf64_alpha_check_relocs): Similarly.
7573 Mon Apr 3 13:37:15 2000 Hans-Peter Nilsson <hp@axis.com>
7575 * aoutx.h (NAME(aout,reloc_type_lookup)): Add BFD_RELOC_8 and
7576 BFD_RELOC_16 to switch for extended relocs.
7577 (MY_swap_ext_reloc_in): New.
7578 (MY_swap_ext_reloc_out): New.
7579 (NAME(aout,slurp_reloc_table)): Use MY_swap_ext_reloc_in rather
7580 than NAME(aout,swap_ext_reloc_in) for extended relocs.
7581 (NAME(aout,squirt_out_relocs)): Similarly use
7582 MY_swap_ext_reloc_out.
7583 (aout_link_reloc_link_order): Use MY_put_ext_reloc if defined.
7585 2000-04-03 Kazu Hirata <kazu@hxi.com>
7587 * coff-h8300.c (h8300_reloc16_extra_cases): Add bsr:16 -> bsr:8 to
7588 the R_PCRWORD_B case.
7590 2000-03-31 Thomas de Lellis <tdel@wrs.com>
7592 * srec.c : Set CHUNK size to 16 bytes to prevent download failures
7596 Wed Mar 30 15:28:00 2000 Donald Lindsay <dlindsay@cygnus.com>
7598 * elf32-m32r.c (m32r_elf_generic_reloc): new function. All
7599 HOWTO references to bfd_elf_generic_reloc, that have
7600 partial_inplace == true, now use the new function. The function
7601 is based on the recent rewrite of m32r_elf_lo16_reloc(), and
7602 extends its fixes to the R_M32R_{16,24,32} relocs.
7603 The new logic in m32r_elf_lo16_reloc() has been removed, and
7604 it instead calls the new routine to obtain that functionality.
7606 2000-03-27 Alan Modra <alan@linuxcare.com.au>
7608 * elf32-avr.c (elf32_avr_gc_mark_hook, elf32_avr_gc_sweep_hook,
7609 elf32_avr_check_relocs, avr_final_link_relocate,
7610 elf32_avr_relocate_section, bfd_elf_avr_final_write_processing,
7611 elf32_avr_object_p): Add prototypes.
7612 (elf32_avr_gc_mark_hook): Add default for h->root.type.
7613 (bfd_elf_avr_final_write_processing): Make static.
7615 2000-03-27 Denis Chertykov <denisc@overta.ru>
7617 * cpu-avr.c: New file. BFD support routines for AVR architecture.
7618 * archures.c (bfd_architecture): Add AVR architecture.
7619 (bfd_archures_list): Add reference to AVR architecture info.
7620 * elf.c (prep_headers): Handle bfd_arch_avr.
7621 * reloc.c: Add various AVR relocation enums.
7622 * targets.c (bfd_elf32_avr_vec): Declare and add to target vector
7624 * Makefile.am: Add support for AVR elf.
7625 * configure.in: Likewise.
7626 * config.bfd: Likewise.
7627 * Makefile.in: Regenerate.
7628 * configure: This too.
7629 * bfd-in2.h: And this.
7630 * libbfd.h: And this.
7632 2000-03-24 H.J. Lu <hjl@gnu.org>
7634 * elf64-alpha.c (elf64_alpha_merge_ind_symbols): Add prototype.
7635 (elf64_alpha_find_reloc_at_ofs): Likewise.
7637 2000-03-17 Alan Modra <alan@linuxcare.com.au>
7639 * reloc.c (bfd_check_overflow): In case complain_overflow_bitfield,
7640 flag an overflow if the bitfield is outside -2**n to 2**n-1. The
7641 allowable range used to be -2**(n-1) to 2**n-1.
7642 * reloc.c (_bfd_relocate_contents): Same here. Also replace
7643 "boolean overflow" with "bfd_reloc_status_type flag".
7645 2000-03-14 Doug Evans <dje@casey.transmeta.com>
7647 * elf32-m32r.c (m32r_elf_lo16_reloc): Rewrite.
7649 2000-03-14 Kazu Hirata <kazu@hxi.com>
7651 * reloc16.c (bfd_coff_reloc16_relax_section): Count the total number
7652 of shrinks properly, including the last reloc.
7654 2000-03-13 Kazu Hirata <kazu@hxi.com>
7656 * coff-h8300.c (h8300_reloc16_extra_cases): Fix the sanity
7659 2000-03-11 Alan Modra <alan@linuxcare.com.au>
7661 * ieee.c (ieee_archive_p): Return bfd_error_wrong_format on
7662 a format mismatch rather than an "error" from bfd_read such as
7663 bfd_error_file_truncated.
7665 2000-03-10 Geoff Keating <geoffk@cygnus.com>
7667 * elf32-mips.c (_bfd_mips_elf_relocate_section): Do proper
7668 sign-extension and big-endian compensation for
7669 R_MIPS_64 even in ld -r.
7671 2000-03-10 Geoffrey Keating <geoffk@cygnus.com>
7673 * elf32-mips.c (mips_elf_next_relocation): Rename from
7674 mips_elf_next_lo16_relocation, and generalize to look
7675 for any relocation type.
7676 (elf_mips_howto_table): Make R_MIPS_PC16 pcrel_offset.
7677 (elf_mips_gnu_rel_hi16): Howto for R_MIPS_GNU_REL_HI16.
7678 (elf_mips_gnu_rel_lo16): Howto for R_MIPS_GNU_REL_LO16.
7679 (elf_mips_gnu_rel16_s2): Howto for R_MIPS_GNU_REL16_S2.
7680 (elf_mips_gnu_pcrel64): Howto for R_MIPS_PC64.
7681 (elf_mips_gnu_pcrel32): Howto for R_MIPS_PC32.
7682 (bfd_elf32_bfd_reloc_type_lookup): Add new relocs.
7683 (mips_rtype_to_howto): Likewise.
7684 (mips_elf_calculate_relocation): Handle new relocs.
7685 (_bfd_mips_elf_relocate_section): REL_HI16/REL_LO16 relocs
7686 are paired. The addend for R_MIPS_GNU_REL16_S2
7687 is shifted right two bits.
7689 2000-03-10 Alan Modra <alan@linuxcare.com.au>
7691 * reloc.c (bfd_perform_relocation): Undo emacs formatting of
7692 comment, and ensure it doesn't happen again.
7693 (bfd_install_relocation): Same here.
7694 (_bfd_relocate_contents): Don't bother assigning unused signmask
7695 shift result. Fix typos in comments.
7696 Remove trailing whitespace throughout file.
7698 2000-03-07 Doug Evans <dje@casey.transmeta.com>
7700 * reloc.c (reloc_howto_struct): Fix partial_inplace comment.
7701 * bfd-in2.h: Rebuild.
7703 2000-03-06 Nick Clifton <nickc@cygnus.com>
7705 * peicode.h (struct pe_ILF_vars): Add sym_ptr_table and
7707 (SIZEOF_ILF_SYM_PTR_TABLE): Define.
7708 (SIZEOF_ILF_STRINGS): Redefine.
7709 (pe_ILF_make_a_symbol-reloc): New function. Creates a symbol
7710 relative reloc, as opposed to a section relative reloc.
7711 (pe_ILF_make_a_symbol): Set the class of local symbols to C_STAT
7713 Add length of symbol's prefix to string pointer.
7714 Store a pointer to the symbol in the symbol pointer table.
7715 (pe_ILF_build_a_bfd): Do not build .idata$2 or .idata$7.
7716 Initialise the symbol pointer table.
7717 Store the hint in the Hint/Name table.
7718 Make the jump reloc be symbol realtive, not section relative.
7719 Create an import symbol for imported code.
7721 2000-03-06 Catherine Moore <clm@cygnus.com>
7723 * elf.c (swap_out_syms): Check for null type_ptr.
7725 2000-03-01 Hans-Peter Nilsson <hp@axis.com>
7727 * aout-target.h (MY(write_object_contents)): Remove unused
7728 and unusable "#if CHOOSE_RELOC_SIZE".
7729 * pc532-mach.c (MY(write_object_contents)): Ditto.
7730 * netbsd.h (MY(write_object_contents)): Ditto.
7731 * hp300hpux.c (MY(write_object_contents)): Ditto.
7732 * freebsd.h (MY(write_object_contents)): Ditto.
7733 * aout-tic30.c (tic30_aout_write_object_contents): Ditto.
7735 2000-02-29 H.J. Lu <hjl@gnu.org>
7737 * peicode.h (jtab): Make it static.
7739 * coff-sh.c (sh_align_load_span): Declared if COFF_WITH_PE is
7740 defined and COFF_IMAGE_WITH_PE is not defined.
7741 (_bfd_sh_align_load_span): Defined as sh_align_load_span if
7742 COFF_WITH_PE is defined and COFF_IMAGE_WITH_PE is not defined.
7744 2000-03-01 Nick Clifton <nickc@cygnus.com>
7746 * coff-arm.c (bfd_arm_process_before_allocation): Make
7747 'symndx' signed to prevent compile time warning.
7749 * coff-mcore.c: Remove unused prototype for pe_object_p.
7751 * coff-sh.c: Add "#ifndef COFF_IMAGE_WITH_PE" around static
7752 functions that are not used when COFF_IMAGE_WITH_PE is
7754 (struct sh_opcode): Change type of 'flags' field to unsigned
7755 long so that it can hold the USESAS flag.
7757 * coffcode.h (styp_to_sec_flags): Initialise 'target_name'.
7759 * elf-m10300.c (mn10300_elf_relax_section): Initialise
7762 * elf32-i370.c: Add ATTRIBUTE_UNUSED to unused function
7764 Remove unusued variables and code.
7765 (elf_backend_add_symbol_hook): Fix prototype.
7767 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Initialise 'sgot' and
7770 * elf32-mcore.c (mcore_elf_relocate_section): Initialise
7773 * elf32-mips.c: Add ATTRIBUTE_UNUSED to unused function
7775 Remove unusued variables and code.
7776 (elf_backend_add_symbol_hook): Fix prototype.
7778 * elf32-sh.c (sh_elf_set_mach_from_flags): Use 'flags'.
7780 * elflink.h (elf_bfd_link_add_symbols): Add ATTRIBUTE_UNUSED
7781 to unused function parameter.
7783 * pe-mips.c: Add ATTRIBUTE_UNUSED to unused function
7785 Use EMPTY_HOWTO to initialise empty howto slots.
7786 Remove unused variables.
7788 * peicode.h (pe_ILF_build_a_bfd): Initialise id6.
7790 2000-03-01 H.J. Lu <hjl@gnu.org>
7792 * aoutx.h (aout_link_input_section_std): Pass "true" to
7793 the undefined_symbol callback.
7794 (aout_link_input_section_ext): Likewise.
7795 * bout.c (get_value): Likewise.
7796 * coff-a29k.c (coff_a29k_relocate_section): Likewise.
7797 * coff-alpha.c (alpha_ecoff_get_relocated_section_conten):
7799 (alpha_relocate_section): Likewise.
7800 * coff-arm.c (coff_arm_relocate_section): Likewise.
7801 * coff-i960.c (coff_i960_relocate_section): Likewise.
7802 * coff-mcore.c (coff_mcore_relocate_section): Likewise.
7803 * coff-mips.c (mips_relocate_section): Likewise.
7804 * coff-ppc.c (coff_ppc_relocate_section): Likewise.
7805 * coff-sh.c (sh_relocate_section): Likewise.
7806 * coff-tic80.c (coff_tic80_relocate_section): Likewise.
7807 * cofflink.c (_bfd_coff_generic_relocate_section): Likewise.
7808 * elf-m10200.c (mn10200_elf_relocate_section): Likewise.
7809 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
7810 * elf32-d10v.c (elf32_d10v_relocate_section): Likewise.
7811 * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
7812 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
7813 * elf32-i370.c (i370_elf_relocate_section): Likewise.
7814 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
7815 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
7816 * elf32-sh.c (sh_elf_relocate_section): Likewise.
7817 * elf32-v850.c (v850_elf_relocate_section): Likewise.
7818 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Likewise.
7819 * elflink.h (elf_link_output_extsym): Likewise.
7820 * pe-mips.c (coff_pe_mips_relocate_section): Likewise.
7821 * reloc.c (bfd_generic_get_relocated_section_conten): Likewise.
7822 * reloc16.c (_bfd_ppc_xcoff_relocate_section): Likewise.
7824 * elf-hppa.h (elf_hppa_relocate_section): Pass "false" to the
7825 undefined_symbol callback when building shared library with
7826 -Bsymbolic and undefined symbols are allowed. Otherwise, pass
7828 * elf32-arm.h (elf32_arm_relocate_section): Likewise.
7829 * elf32-i386.c (elf_i386_relocate_section): Likewise.
7830 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
7831 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
7832 (elf32_mips_get_relocated_section_content): Likewise.
7833 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
7834 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
7835 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
7836 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
7838 2000-02-28 Nick Clifton <nickc@cygnus.com>
7840 * Makefile.am: Add rules to build pe[i]-{sh|mips}.lo objects.
7841 * Makefile.in: Regenerate.
7843 * configure.in: Add support for mips and sh pe vectors.
7844 * configure: regenerate.
7846 * config.bfd: Add support for arm-wince, mips-pe and sh-pe
7849 * targets.c: Add mips and sh pe vectors.
7851 * libpei.h (coff_final_link_postscript): Only define if not
7854 * coffcode.h: Add support for WinCE magic numbers.
7856 * peigen.c (pe_print_reloc): Update comment and rearrange
7857 appending of newline character.
7859 * peicode.h: Add support for Image Library Format.
7860 (pe_ILF_vars): Structure containing data used by ILF code.
7861 (pe_ILF_make_a_section): New function. Create a section based
7863 (pe_ILF_make_a_reloc): New function. Create a reloc based on
7865 (pe_ILF_make_a_symbol): New function. Create a symbol based
7867 (pe_ILF_save_relocs): New function. Store the relocs created
7868 by pe_ILF_make_a_reloc in a section.
7869 (pe_ILF_build_a_bfd): New function. Create a BFD describing
7871 (pe_ILF_object_p): New function. Return a bfd_target pointer
7873 (pe_bfd_object_p): If an ILF object is detected call
7874 pe_ILF_object_p on it.
7876 * coff-arm.c: Add support for WinCE relocs which are different
7877 from normal ARM COFF relocs.
7878 * pe-arm.c: Unset TARGET_UNDERSCORE for a WinCE target.
7880 * coff-sh.c: Add support for sh-pe target.
7881 * pe-sh.c: New file. Support code for sh-pe target.
7882 * pei-sh.c: New file. Support code for sh-pe target.
7884 * pe-mips.c: New file. Support code for mips-pe target.
7885 * pei-mips.c: New file. Support code for mips-pe target.
7887 2000-02-27 Jakub Jelinek <jakub@redhat.com>
7889 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data): Don't bump
7890 architecture if the object causing the bump is dynamic.
7891 * elf64-sparc.c (sparc64_elf_merge_private_bfd_data): Likewise,
7892 and also don't it for memory ordering.
7893 (sparc64_elf_write_relocs): Take src_rela out of the loop.
7895 2000-02-27 Ian Lance Taylor <ian@zembu.com>
7897 * dwarf2.c (read_abbrevs): Use _raw_size directly rather than
7898 calling bfd_get_section_size_before_reloc.
7899 (decode_line_info): Likewise.
7900 (_bfd_dwarf2_find_nearest_line): Likewise.
7902 2000-02-27 Eli Zaretskii <eliz@is.elta.co.il>
7904 * Makefile.am (stamp-lib): Use $(LIBTOOL) --config to get the
7905 name of the libtool directory.
7906 * Makefile.in: Rebuild.
7908 Fri Feb 25 18:39:26 2000 Rodney Brown (RodneyBrown@pmsc.com)
7910 * som.c (SOM_HOWTO): Define.
7911 (som_hppa_howto_table): Use it.
7913 2000-02-25 Alexandre Oliva <oliva@lsd.ic.unicamp.br>
7915 * config.bfd: Enable 64 bit support for GNU/Linux/sparc.
7917 * config.bfd: Enable 64 bit support for Solaris7+/sparc.
7919 2000-02-24 Catherine Moore <clm@cygnus.com>
7921 * som.c (som_misc_symbol_info): Add field
7923 (som_bfd_derive_misc_symbol_info): Initialize
7925 (som_build_and_write_symbol_table): Keep track
7926 of secondary_def field.
7927 (som_slurp_symbol_table): Set BSF_WEAK symbol flag
7928 if secondary_def field is set.
7929 (som_bfd_ar_write_symbol_stuff): Initialize
7932 2000-02-23 Stephane Carrez <stcarrez@worldnet.fr>
7934 * dwarf2.c (read_address): Read 16-bits addresses.
7935 (parse_comp_unit): Accept addr_size == 2.
7937 2000-02-23 Alan Modra <alan@spri.levels.unisa.edu.au>
7939 * bfd-in.h: Update copyright date.
7941 2000-02-23 Linas Vepstas <linas@linas.org>
7943 * cpu-i370.c: New file.
7944 * elf32-i370.c: New file.
7945 * archures.c (enum bfd_architecture): Add bfd_arch_i370.
7946 (bfd_i370_arch): New.
7947 (bfd_archures_list): Add bfd_i370_arch.
7948 * elf.c (prep_headers): Add bfd_arch_i370.
7949 * Makefile.am: Add support for IBM 370 elf.
7950 * config.bfd: Likewise.
7951 * configure.in: Likewise.
7952 * libbfd.h (bfd_reloc_code_real_names): Likewise.
7953 * reloc.c (bfd_reloc_code_type): Likewise.
7954 * targets.c: Likewise.
7956 * Makefile.in: Regenerate.
7957 * configure: Regenerate.
7958 * bfd-in2.h: Regenerate.
7960 2000-02-22 Ian Lance Taylor <ian@zembu.com>
7962 * elf32-i386.c (elf_i386_info_to_howto_rel): Give a warning for
7963 invalid relocation types, and change them to R_386_NONE.
7965 2000-02-22 H.J. Lu <hjl@gnu.org>
7967 * elflink.h (elf_link_add_object_symbols): If a version symbol is
7968 not defined, don't add a second ELF_VER_CHR.
7970 * elflink.h (elf_bfd_final_link): Call output_extsym for global
7971 symbols converted to local symbols even when stripping all
7973 (elf_link_output_extsym): Process global symbols converted to
7974 local symbols even if they are being stripped.
7976 2000-02-21 Alan Modra <alan@spri.levels.unisa.edu.au>
7978 * archures.c (bfd_octets_per_byte): Return unsigned int.
7979 (bfd_arch_mach_octets_per_byte): Ditto.
7980 * libbfd.c (bfd_read, bfd_seek): Quell signed vs. unsigned
7982 * section.c (bfd_get_section_size_before_reloc): Quell signed
7983 vs. unsigned comparison warning.
7984 (bfd_get_section_size_after_reloc): Same here. Fix parentheses too.
7985 * trad-core.c (trad_unix_core_file_p): Correct 2000-01-27
7986 change. What was I thinking?
7987 * bfd-in2.h: Regenerate.
7989 * elflink.h (elf_gc_sweep): Skip non-elf input bfds.
7990 (elf_gc_sections): Same here.
7991 (elf_gc_common_finalize_got_offsets): And here.
7993 2000-02-21 Ian Lance Taylor <ian@zembu.com>
7995 ELF HPPA doesn't work at present; remove it until it does.
7996 * config.bfd: Comment out setting targ_defvec to
7998 * Makefile.am: Rebuild dependencies.
7999 (BFD32_BACKENDS): Remove elf32-hppa.lo.
8000 (BFD32_BACKENDS_CFILES): Remove elf32-hppa.c.
8001 (SOURCE_HFILES): Remove elf32-hppa.h and hppa_stubs.h.
8002 * Makefile.in: Rebuild.
8003 * targets.c (bfd_target_vector): Comment out bfd_elf32_hppa_vec.
8005 2000-02-18 Geoff Keating <geoffk@cygnus.com>
8007 * coffcode.h (coff_set_arch_mach_hook): Use free(), because there
8008 is no bfd_free(). Revert bfd_free part of previous change.
8010 2000-02-18 Geoff Keating <geoffk@cygnus.com>
8012 * coffcode.h (coff_set_arch_mach_hook): Don't use variable-size
8014 (coff_compute_section_file_positions): Use bfd_free to pair
8016 (coff_write_object_contents): Likewise.
8018 * coff-rs6000.c (xcoff_howto_table_16): New variable.
8019 (xcoff_rtype2howto): Handle 16-bit variants of 32-bit relocs.
8021 2000-02-18 Ulrich Drepper <drepper@cygnus.com>
8023 * coff-rs6000.c (XCOFFARMAGBIG): New macro.
8024 (xcoff_ar_file_hdr_big): New structure.
8025 (SIZEOF_AR_FILE_HDR_BIG): New macro.
8026 (xcoff_ar_hdr_big): New structure.
8027 (SIZEOF_AR_HDR_BIG): New macro.
8028 (xcoff_big_format_p): New macro.
8029 (xcoff_ardata_big): New macro.
8030 (arch_xhdr_big): New macro.
8031 (xcoff_slurp_armap): Handle large archives.
8032 (xcoff_archive_p): Detect large archives.
8033 (xcoff_read_ar_hdr): Handle large archives.
8034 (xcoff_openr_next_archived_file): Handle large archives.
8035 (xcoff_generic_stat_arch_elt): Handle large archives.
8036 (xcoff_write_armap_old): Rename from xcoff_write_armap.
8037 (xcoff_write_armap_big): New function.
8038 (xcoff_write_armap): New function, dispatch to _old or _big.
8039 (xcoff_write_archive_contents_old): Rename from
8040 xcoff_write_archive_contents.
8041 (xcoff_write_archive_contents_big): New function.
8042 (xcoff_write_archive_contents): New function, dispatch to _old or
8045 2000-02-18 Richard Henderson <rth@cygnus.com>
8047 * elf-bfd.h (struct elf_link_hash_table): Remove copy_indirect
8048 and hide_symbol members.
8049 (elf_link_hash_copy_indirect): Remove.
8050 (elf_link_hash_hide_symbol): Remove.
8051 (struct elf_backend_data): Add elf_backend_copy_indirect_symbol
8052 and elf_backend_hide_symbol.
8053 (_bfd_elf_link_hash_copy_indirect): Declare.
8054 (_bfd_elf_link_hash_hide_symbol): Declare.
8055 * elf.c (_bfd_elf_link_hash_copy_indirect): Remove table argument.
8056 (_bfd_elf_link_hash_hide_symbol): Likewise.
8057 (_bfd_elf_link_hash_table_init): Don't init killed members.
8058 * elflink.h (elf_link_add_object_symbols): Use the bed function
8059 pointers not elf_link_hash_{copy_indirect,hide_symbol}.
8060 (elf_link_assign_sym_version): Likewise.
8061 * elfxx-target.h (elf_backend_copy_indirect_symbol): Default.
8062 (elf_backend_hide_symbol): Likewise.
8063 (elfNN_bed): Update for new members.
8065 2000-02-17 Kevin Buettner <kevinb@redhat.com>
8067 * rs6000-core.c (CORE_DATA_SIZE_FIELD, CORE_COMM_FIELD, SAVE_FIELD,
8068 STACK_END_ADDR): Define for new core file format.
8069 (LOADER_OFFSET_FIELD, LOADER_REGION_SIZE, CORE_DUMP): New defines
8070 for handling the vagaries of the various core file structures used
8071 by AIX over the years.
8072 (rs6000coff_core_p, rs6000coff_core_file_matches_executable,
8073 Rs6kCorData): Use above defines to adapt code to use AIX 4.3's
8074 core_dumpx structure.
8076 Thu Feb 17 00:04:48 2000 J"orn Rennecke <amylaar@cygnus.co.uk>
8078 * archures.c (bfd_mach_sh2, bfd_mach_sh_dsp): New macros.
8079 (bfd_mach_sh3_dsp): Likewise.
8080 (bfd_mach_sh4): Reinstate.
8081 (bfd_default_scan): Recognize 7410, 7708, 7729 and 7750.
8082 * bfd-in2.h: Regenerate.
8083 * coff-sh.c (struct sh_opcode): flags is no longer short.
8084 (USESAS, USESAS_REG, USESR8, SETSAS, SETSAS_REG): New macros.
8085 (sh_opcode41, sh_opcode42): Integrate as sh_opcode41.
8086 (sh_opcode01, sh_opcode02, sh_opcode40): Add sh-dsp opcodes.
8087 (sh_opcode41, sh_opcode4, sh_opcode80): Likewise.
8088 (sh_opcodes): No longer const.
8089 (sh_dsp_opcodef0, sh_dsp_opcodef): New arrays.
8090 (sh_insn_uses_reg): Check for USESAS and USESR8.
8091 (sh_insn_sets_reg, sh_insns_conflict): Check for SETSAS.
8092 (_bfd_sh_align_load_span): Return early for SH4.
8093 Modify sh_opcodes lookup table for sh-dsp / sh3-dsp.
8094 Take into account that field b of a parallel processing insn
8095 could be mistaken for a separate insn.
8096 * cpu-sh.c (arch_info_struct): New array elements for
8097 sh2, sh-dsp and sh3-dsp.
8098 Reinstate element for sh4.
8099 (SH2_NEXT, SH_DSP_NEXT, SH3_DSP_NEXT): New macros.
8100 (SH4_NEXT): Reinstate.
8101 (SH3_NEXT, SH3E_NEXT): Adjust.
8102 * elf-bfd.h (_sh_elf_set_mach_from_flags): Declare.
8103 * elf32-sh.c (sh_elf_set_private_flags): New function.
8104 (sh_elf_copy_private_data, sh_elf_set_mach_from_flags): Likewise.
8105 (sh_elf_merge_private_data): New function.
8106 (elf_backend_object_p, bfd_elf32_bfd_set_private_bfd_flags): Define.
8107 (bfd_elf32_bfd_copy_private_bfd_data): Define.
8108 (bfd_elf32_bfd_merge_private_bfd_data): Change to
8109 sh_elf_merge_private_data.
8111 2000-02-13 Richard Henderson <rth@cygnus.com>
8113 * elf-bfd.h (struct elf_link_hash_table): Add copy_indirect and
8114 hide_symbol members.
8115 (elf_link_hash_copy_indirect): New.
8116 (elf_link_hash_hide_symbol): New.
8117 * elflink.h (elf_link_add_object_symbols): Break out copy from
8118 indirect new new symbol to elf.c.
8119 (elf_link_assign_sym_version): Break out privatization of
8120 non-exported symbol to elf.c.
8121 * elf.c (_bfd_elf_link_hash_copy_indirect): New.
8122 (_bfd_elf_link_hash_hide_symbol): New.
8123 (_bfd_elf_link_hash_table_init): Init copy_indirect and hide_symbol.
8125 2000-02-13 Ian Lance Taylor <ian@zembu.com>
8127 * section.c (_bfd_strip_section_from_output): Add info parameter.
8128 If it passed as non-NULL, use it to check whether any input BFD
8129 has an input section which uses this output section. Change all
8131 * bfd-in2.h: Rebuild.
8133 * bfd-in.h: Move declarations of bfd_get_elf_phdr_upper_bound and
8134 bfd_get_elf_phdrs in from bfd-in2.h, correcting patch of
8136 * bfd-in2.h: Rebuild.
8138 2000-02-10 Timothy Wall <twall@cygnus.com>
8140 * coffswap.h (coff_swap_sym_in): Add hook SWAP_SYM_IN_POST to
8141 allow final modifications of swapped-in symbol.
8142 (coff_swap_sym_out): Ditto with SWAP_SYM_OUT_POST.
8143 * coffcode.h (coff_write_relocs): Use macro
8144 SECTION_RELATIVE_ABSOLUTE_SYMBOL_P if defined to determine whether
8145 symbol index should be set to -1.
8147 Thu Feb 10 20:07:50 GMT 2000 Toshiyasu Morita (toshi.morita@sega.com)
8149 * coff-sh.c (USES1_REG, USES2_REG, SETS1_REG, SETS2_REG,
8150 USESF1_REG, USESF2_REG, SETSF1_REG, SETSF2_REG): New macros.
8151 * (sh_insn_sets_reg, sh_insn_sets_freg): New prototypes.
8152 * (sh_insn_sets_reg, sh_insn_uses_or_sets_reg, sh_insns_sets_freg,
8153 sh_insns_uses_or_sets_freg): New functions.
8154 * (sh_insn_uses_reg, sh_insn_uses_freg): Use new macros.
8155 * (sh_insns_conflict): Use new functions and new macros to
8156 detect conflicts when two instructions both set same integer registers,
8157 both set same fp register, and both set special register.
8159 2000-02-09 Timothy Wall <twall@cygnus.com>
8161 * coffgen.c (coff_real_object_p): Set arch/mach info prior to
8162 swapping in sections, so that the swapping routines have access to
8165 2000-02-08 Mark Elbrecht <snowball3@bigfoot.com>
8167 * coff-go32.c: Update comment. Update copyright.
8169 2000-01-27 Thomas de Lellis <tdel@windriver.com>
8171 * syms.c (bfd_decode_symclass)
8172 Two new class characters were added - 'V' and 'v'. The
8173 meaning of 'W' is now restricted to just weak non-object
8174 symbols. This allows differentiation between, for example,
8175 weak functions vs weak objects. nm for example now dumps:
8177 'w' = weak unresolved
8178 'V' = weak global object
8179 'v' = weak unresolved object
8181 (bfd_is_undefined_symclass): New function. Return true if the
8182 given symbol class represents and undefined/unresolved symbol.
8184 (bfd_symbol_info): Use bfd_is_undefined_symclass to check for
8187 * bfd-in2.h: Add prototype for bfd_is_undefined_symbol().
8189 * elf32-arm.h (elf32_arm_get_symbol_type): If a symbol has the
8190 STT_ARM_16BIT flag set, but it is not attached to a data object
8191 return STT_ARM_16BIT so that it will be treated as code by the
8194 2000-01-27 Alan Modra <alan@spri.levels.unisa.edu.au>
8196 * coff-i386.c (i3coff_object_p): Remove prototype.
8199 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Add const
8200 to name. Update copyright.
8202 * trad-core.c (trad_unix_core_file_p): Cast core_regsec
8203 assignment to avoid warning. Update copyright.
8205 2000-01-24 Robert Lipe (robertl@sco.com)
8207 * coffcode.h (coff_write_object_contents): Get buff via bfd_malloc
8208 instead of using GNU C extension.
8210 2000-01-21 Nick Clifton <nickc@cygnus.com>
8212 * libbfd.c (bfd_read): Do not attempt to get a negativly sized
8213 amount from a bfd_in_memory structure.
8214 (bfd_seek): Do not allow seeks past the end of a bfd_in_memory
8217 2000-01-14 Nick Clifton <nickc@cygnus.com>
8219 * linker.c (default_indirect_link_order): oops - fix incorrectly
8220 applied patch from Tim Wall.
8222 2000-01-13 Timothy Wall (twall@tiac.net>
8224 * coffcode.h: Use bfd_coff_xxx instead of the macro XXX (where xxx
8225 = scnhsz, filhsz, relsz, aoutsz, etc)
8227 * coffswap.h: Ditto.
8229 2000-01-13 Nick Clifton <nickc@cygnus.com>
8231 * elf32-arm.h (elf32_thumb_to_arm_stub): Fix offset in branch to
8232 interwork thumb to arm stub.
8234 2000-01-13 Timothy Wall (twall@tiac.net>
8236 * archures.c (bfd_octets_per_byte): New function: Return
8238 (bfd_arch_mach_octets_per_byte): New function: Return target
8241 * section.c: Distinguish between octets and bytes for usage of
8242 _cooked_size, _raw_size, and output_offset. Clarify
8243 description of bfd_set_section_contents.
8245 * bfd-in2.h: Regenerate.
8247 * coffgen.c: Indicate that the offset parameter is in bytes, not
8250 * cofflink.c (bfd_coff_link_input_bfd): Use bfd_octets_per_byte
8251 where appropriate to get the octet offset when calling
8252 bfd_set_section_contents.
8253 (bfd_coff_reloc_link_order): Ditto.
8255 * linker.c (bfd_generic_reloc_link_order): Ditto.
8256 (_bfd_default_link_order): Ditto.
8258 * reloc.c (bfd_perform_relocation): Distinguish between octets
8259 and bytes. Use octets when indexing into octet data; use bytes
8260 when calculating target addresses.
8261 (bfd_install_relocation): Ditto.
8263 * srec.c (srec_write_section): Ditto.
8265 2000-01-13 Nick Clifton <nickc@cygnus.com>
8267 * coff-mcore.c (COFF_DEFAULT_SECTION_ALIGNMENT_POWER): Change from
8268 3 to 2. This allows 4 byte sized sections, which is necessary for
8269 dlltool to build functioning DLLs.
8271 2000-01-10 Philip Blundell <pb@futuretv.com>
8273 * config.bfd (arm*-*-linux-gnu*): Match instead of arm*-*-linux-gnu.
8274 (arm*-*-conix*): New target.
8276 2000-01-10 Egor Duda <deo@logos-m.ru>
8278 * config.bfd: Include elf32_i386 vector to target list for cygwin
8281 * config.in: Undefine HAVE_WIN32_PSTATUS_T.
8282 * configure.in: Test for structure win32_pstatus_t in
8284 * configure: Regenerate.
8286 * elf.c (elfcore_grok_win32pstatus): New function: process
8287 win32_pstatus_t notes in elf core file.
8288 (elfcore_grok_note): Detect win32_pstatus notes.
8290 2000-01-03 Martin v. Loewis <loewis@informatik.hu-berlin.de>
8292 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Process symbol
8294 * elflink.h (elf_link_add_object_symbols): Combine visibilities.
8295 * elf.c (bfd_elf_print_symbol): Interpret st_other as visibility.
8297 For older changes see ChangeLog-9899
8303 version-control: never