3 * Makefile.am (stamp-lib): ranlib the libbfd.a in the build directory.
4 * Makefile.in: Regenerate.
8 * elfxx-ia64.c (is_unwind_section_name): New function. Returns
9 true if section name is an unwind table section name.
10 (elfNN_ia64_additional_program_headers): Count each unwind section
12 (elfNN_ia64_modify_segment_map): Install one unwind program header
13 for each unwind separate section. Note: normally the linker
14 script merges the unwind sections that go into a single segment,
15 so this still generates at most one unwind program header per
18 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Accept any section
19 name for SHT_IA_64_UNWIND, not just .IA_64.unwind.
20 (elfNN_ia64_fake_sections): Mark sections with names that start
21 with .IA_64.unwind but not with .IA_64.unwind_info as an IA-64
24 * elfxx-ia64.c (elfNN_ia64_final_write_processing): New function.
25 Use it to make sh_info in unwind section point to the text section
30 * Makefile.am: Add linux target for S/390.
31 * archures.c: Likewise.
32 * bfd-in2.h: Likewise.
33 * config.bfd: Likewise.
34 * configure.in: Likewise.
37 * targets.c: Likewise.
38 * cpu-s390.c: New file.
39 * elf32-s390.c: New file.
40 * elf64-s390.c: New file.
44 * peigen.c (_bfd_pe_get_symbol_info): Suppress addition of
45 ImageBase. This has already been done by coff_swap_hdr_in.
49 * elf64-sparc.c (sparc64_elf_copy_private_bfd_data): New function.
53 * elf64-sparc.c (sparc64_elf_check_relocs): Don't trust reloc_count.
54 (sparc64_elf_relocate_section): Likewise.
58 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Treat R_SPARC_UA32
59 similar to R_SPARC_32.
60 * elf64-sparc.c (sparc64_elf_howto_table): Likewise.
64 * elf32-i386.c (elf_i386_check_relocs): Reserve R_386_PC32
65 relocation entries for weak definitions when building DSO with
70 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Respect weakness
71 before visibility. Locally defined protected symbols are not
76 * config.bfd: Enable coff64 for rs6000-*. Patch from
81 * coffgen.c (coff_find_nearest_line): If stabs info is successfully
82 found, do not attempt to find dwarf2 info before returning.
86 * elflink.h (is_global_symbol_definition): Rename to
87 is_global_data_symbol_definition and have it reject function
89 (elf_link_is_defined_archive_symbol): Use renamed function.
93 * libbfd-in.h (bfd_target_vector): Change extern array to pointer.
94 * libbfd.h (bfd_target_vector): Likewise.
95 * targets.c (bfd_target_vector): Rename to _bfd_target_vector and
96 make static; create pointer reference named bfd_target_vector.
97 (_bfd_target_vector_entries): Calculate this based on the array
98 typed _bfd_target_vector.
102 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Only hidden and
103 internal symbols are not dynamic.
104 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise.
108 * Makefile.am (BFD64_BACKENDS_CFILES): Remove elf64-ia64.c, so
109 that it will not be pulled into the list of files that make up
111 * Makefile.in: Regenerate.
112 * po/bfd.pot: Regenerate.
116 * bfd/peicode.h (coff_swap_filehdr_in): Remove the e_magic
118 (pe_bfd_object_p): Rewrite with external_PEI_DOS_hdr and
119 external_PEI_IMAGE_hdr.
123 * elf-m10200.c: Fix formatting.
127 * elf32-v850.c (v850_elf_reloc): Do not convert reloc addend to PC
128 rel, it will be handled later on.
132 * Makefile.in: Fix typo.
136 * elf-m10300.c: Fix formatting.
140 * elf64-hppa.c (elf64_hppa_elf_get_symbol_type): New function.
141 (elf_backend_get_symbol_type): Define.
142 (elf64_hppa_object_p): Set architecture and machine from elf
147 * elf64-alpha.c (elf64_alpha_find_nearest_line): Query dwarf2
152 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Return false
153 for non-default visibility.
154 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise, but
155 delete ugly macro and replace with pretty function.
159 * coff-go32.c: Update copyright.
160 * coff-stgo32.c: Likewise.
161 * coff-go32.c (COFF_LONG_FILENAMES): Define.
162 * coff-stgo32.c (COFF_LONG_FILENAMES): Likewise.
163 * coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Remove .bss entry.
164 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
168 * bfd-in2.h: Rebuild.
169 * libbfd.h: Likewise.
173 * bfd-in2.h: Rebuild.
177 * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_buf)
178 is NULL or PRIV(vms_rec) is outside of the buffer.
182 * coff64-rs6000.c: Fix formatting.
183 * coff-arm.c: Likewise.
184 * coffgen.c: Likewise.
185 * cofflink.c: Likewise.
186 * coff-mcore.c: Likewise.
187 * coff-mips.c: Likewise.
188 * coff-pmac.c: Likewise.
189 * coff-ppc.c: Likewise.
190 * coff-rs6000.c: Likewise.
192 * elf32-fr30.c: Likewise.
193 * elf32-i370.c: Likewise.
194 * elf32-i860.c: Likewise.
195 * elf32-m32r.c: Likewise.
196 * elf32-m68k.c: Likewise.
197 * elf32-mcore.c: Likewise.
198 * elf32-ppc.c: Likewise.
199 * elf32-sh.c: Likewise.
200 * elf32-v850.c: Likewise.
201 * elf64-alpha.c: Likewise.
202 * elf64-sparc.c: Likewise.
203 * elflink.c: Likewise.
204 * elflink.h: Likewise.
205 * elf-m10200.c: Likewise.
206 * elf-m10300.c: Likewise.
207 * elfxx-ia64.c: Likewise.
209 * aoutx.h: Fix formatting.
211 * bfd-in2.h: Likewise.
212 * bfd-in.h: Likewise.
213 * cpu-i386.c: Likewise.
214 * cpu-m68hc11.c: Likewise.
215 * dwarf2.c: Likewise.
216 * elf64-x86-64.c: Likewise.
217 * format.c: Likewise.
218 * freebsd.h: Likewise.
220 * hp300hpux.c: Likewise.
221 * hppabsd-core.c: Likewise.
222 * hpux-core.c: Likewise.
226 * elf64-x86-64.c: Added PIC support for X86-64.
227 (elf64_x86_64_link_hash_newfunc): Function added.
228 (elf64_x86_64_link_hash_table_create): Likewise.
229 (elf64_x86_64_check_relocs): Likewise.
230 (elf64_x86_64_gc_mark_hook): Likewise.
231 (elf64_x86_64_gc_sweep_hook): Likewise.
232 (elf64_x86_64_adjust_dynamic_symbol): Likewise.
233 (elf64_x86_64_size_dynamic_sections): Likewise.
234 (elf64_x86_64_discard_copies): Likewise.
235 (elf64_x86_64_finish_dynamic_symbol): Likewise.
236 (elf64_x86_64_finish_dynamic_sections): Likewise.
237 (elf64_x86_64_relocate_section): Add relocation of PIC sections.
241 * Makefile.am (install-data-local): Make use of $(DESTDIR).
242 * Makefile.in: Regenerate.
246 * coff-a29k.c: Fix formatting.
250 * elf32-i386.c (elf_i386_check_relocs): Report files with bad
251 relocation section names.
252 (elf_i386_relocate_section): Report files with bad relocation
253 section names and return false.
257 * targets.c: Alphabetize list of xvecs.
261 * config.bfd: Add linux target variant for elfxx-hppa.
262 * configure.in: Recognize bfd_elf32_hppa_linux_vec and
263 bfd_elf64_hppa_linux_vec.
264 * configure: Regenerate.
265 * elf64-hppa.c: Include elf64-target.h again to support linux
267 (elf64_hppa_post_process_headers): Set ELFOSABI_LINUX for linux.
268 * elf32-hppa.c: Include elf32-target.h again to support linux
270 (elf32_hppa_post_process_headers): New function.
271 (elf_backend_post_process_headers): Define.
272 * targets.c (bfd_target_vector): Add bfd_elf64_hppa_linux_vec and
273 bfd_elf32_hppa_linux_vec.
275 * elf32-hppa.c (elf32_hppa_link_hash_table): Add text_segment_base,
276 and data_segment_base fields.
277 (elf32_hppa_link_hash_table_create ): Init them.
278 (elf32_hppa_check_relocs): Update comments.
279 (hppa_record_segment_addr): New function.
280 (elf32_hppa_relocate_section): Call it.
281 (final_link_relocate): Handle R_PARISC_SEGREL32.
282 (elf32_hppa_final_link): New function.
283 (bfd_elf32_bfd_final_link): Define to call it.
284 (hppa_unwind_entry_compare): New function.
285 * cache.c (bfd_open_file): Create files in write+read mode.
287 * elf-hppa.h (elf_hppa_howto_table): Set bitsize value for
288 SEGREL32 and numerous other relocs. Change duplicate
289 R_PARISC_NONE relocs to R_PARISC_UNIMPLEMENTED.
291 * opncls.c (bfd_fdopenr): Add parens like the comment says around
294 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Don't create
295 .plt entries for DT_INIT and DT_FINI.
296 (elf32_hppa_finish_dynamic_sections): Remove special handling of
299 * elf64-hppa.c (elf64_hppa_finish_dynamic_symbol): Use 16-bit
300 offsets for stub .plt access if wide mode. Check offset in range.
304 * elf32-fr30.c (fr30_elf_howto_table): Remove spurious blank
307 * coffcode.h (coff_canonicalize_reloc): Remove spurious blank
312 * configure.in ([bfd_elf64_x86_64_vec]): Set target64.
313 * configure: Regenerate.
317 * bfd-in2.h (bfd_architecture): Add bfd_mach_arc_5,
318 bfd_mach_arc_6, bfd_mach_arc_7, bfd_mach_arc_8 for ARC variants.
319 * cpu-arc.c (arch_info_struct): Add entries for variants.
320 (bfd_arc_arch) Set default to bfd_mach_arc_5.
321 (arc_get_mach) Don't assume machine names prefixed arc- before
323 * elf32-arc.c (arc_elf_object_p): Set machine number based on new
325 (arc_elf_final_write_processing) Likewise.
326 (ELF_MACHINE_CODE) Use EM_ARC.
330 * coff-arm.c (LOCAL_LABEL_PREFIX): Change definition to "".
339 * som.c: Fix formatting.
343 * ecoffswap.h: Fix formatting.
344 * elf-bfd.h: Likewise.
345 * elfarm-nabi.c: Likewise.
346 * elfarm-oabi.c: Likewise.
347 * elfcode.h: Likewise.
348 * elfcore.h: Likewise.
349 * elflink.c: Likewise.
350 * elflink.h: Likewise.
351 * elfxx-ia64.c: Likewise.
352 * elfxx-target.h: Likewise.
354 * linker.c: Likewise.
355 * lynx-core.c: Likewise.
359 * pc532-mach.c: Fix formatting.
360 * pe-arm.c: Likewise.
361 * pe-i386.c: Likewise.
362 * pe-mips.c: Likewise.
363 * pe-ppc.c: Likewise.
365 * pei-mips.c: Likewise.
366 * pei-sh.c: Likewise.
367 * peicode.h: Likewise.
368 * ppcboot.c: Likewise.
369 * ptrace-core.c: Likewise.
373 * reloc.c: Fix formatting.
374 * riscix.c: Likewise.
375 * rs6000-core.c: Likewise.
376 * xcoff-target.h: Likewise.
380 * elfcode.h (elf_object_p): Also restore the bfd mach field on
381 error, by calling bfd_default_set_arch_mach with incoming
386 * vaxnetbsd.c: Fix formatting.
387 * versados.c: Likewise.
388 * vms-gsd.c: Likewise.
389 * vms-hdr.c: Likewise.
390 * vms-misc.c: Likewise.
394 * archive.c (coff_write_armap): Don't write more than symbol_count
395 `archive_member_file_ptr's.
399 * vms-tir.c: Fix formatting.
403 * vms.c: Fix formatting.
408 * vms-hdr.c: Include alloca.h if HAVE_ALLOCA_H is defined.
410 * peicode.h (pe_ILF_object_p): Add const to import of TARGET_LITTLE_SYM.
412 * elf32-m32r.c (m32r_elf_generic_reloc): Add cast to avoid (void *)
415 * elf32-fr30.c: Add casts to avoid (void *) arithmetic.
417 * coffcode.h (styp_to_sec_flags): Add empty statement after label.
421 * libbfd.c (bfd_get_bits): Added
422 (bfd_put_bits): Likewise
423 * bfd-in.h: Declared the above.
424 * bfd-in2.h: Regenerated.
428 * targets.c: Fix formatting.
429 * tekhex.c: Likewise.
430 * trad-core.c: Likewise.
434 * sco5-core.c: Fix formatting.
435 * section.c: Likewise.
436 * sparclinux.c: Likewise.
437 * sparclynx.c: Likewise.
438 * sparcnetbsd.c: Likewise.
441 * stab-syms.c: Likewise.
444 * sysdep.h: Likewise.
448 * coff-arm.c (EXTRA_S_FLAGS): Only define if not already
450 * epoc-pe-arm.c (EXTRA_S_FLAGS): Define.
451 * epoc-pei-arm.c (EXTRA_S_FLAGS): Define.
455 * vms-misc.c (_bfd_vms_get_record): Add default case to
460 * elfcore.h (elf_core_file_p): Move to the start of the program
461 headers before attempting to read them.
465 * peigen.c: Fix formatting.
471 * peigen.c: Fix formatting.
475 * elfxx-ia64.c (get_dyn_sym_info): Cast %p argument to void *.
479 * binary.c (binary_set_section_contents): Ignore sections
484 * m68klinux.c: Fix formatting.
485 * m68knetbsd.c: Likewise.
486 * mipsbsd.c: Likewise.
487 * netbsd-core.c: Likewise.
488 * netbsd.h: Likewise.
489 * newsos3.c: Likewise.
490 * nlm32-alpha.c: Likewise.
491 * nlm32-i386.c: Likewise.
492 * nlm32-ppc.c: Likewise.
493 * nlm32-sparc.c: Likewise.
494 * nlmcode.h: Likewise.
495 * nlmswap.h: Likewise.
496 * nlm-target.h: Likewise.
497 * ns32knetbsd.c: Likewise.
501 * elflink.h (elf_link_output_extsym): Don't complain about undefined
502 symbols in shared objects if allow_shlib_undefined is true.
506 * cpu-sh.c: Fix formattng.
507 * elf.c: Fix formattng.
508 * elf32-mips.c: Fix formattng.
509 * elf32-sh.c: Fix formattng.
510 * elf64-alpha.c: Fix formattng.
514 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Pass
515 dwarf2_find_line_info as last parameter to invocation of
516 _bfd_dwarf2_find_nearest_line.
517 * elf32-arm.h (elf32_arm_find_nearest_line): Pass
518 dwarf2_find_line_info as last parameter to invocation of
519 _bfd_dwarf2_find_nearest_line.
523 * Makefile.am (BFD32_BACKENDS): Move dwarf2.lo from here...
524 (BFD_LIBS): ...to here.
525 (BFD32_BACKENDS_CFILES): Move dwarf2.c from here...
526 (BFD_LIBS_CFILES): ...to here.
527 * Makefile.in: Regenerate.
528 * configure.in: Remove dwarf.lo from the elf shell variable.
529 * configure: Regenerate.
530 * libcoff-in.h (coff_tdata): Add pointer dwarf2_find_line_info.
531 * libcoff.h: Regenerate.
532 * coffgen.c (coff_find_nearest_line): Call
533 _bfd_dwarf2_find_nearest_line.
534 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Add parameter. Update
536 (read_abbrevs): Likewise
537 (decode_line_info): Likewise.
538 (parse_comp_unit): Likewise.
539 (comp_unit_find_nearest_line): Likewise.
540 * libbfd-in.h (_bfd_dwarf2_find_nearest_line): Update prototype.
541 * libbfd.h: Regenerate.
542 * elf.c (_bfd_elf_find_nearest_line): Update call.
543 * elf-bfd.h (elf_obj_tdata): Change dwarf2_find_line_info to type PTR.
544 * dwarf2.c (concat_filename): Use IS_ABSOLUTE_PATH.
545 * coffcode.h (STYP_XCOFF_DEBUG, STYP_DEBUG_INFO): New macros.
546 (sec_to_styp_flags): Use them. Handle DWARF2 sections.
547 (styp_to_sec_flags): Handle DWARF2 sections.
548 * elf32-arm.h (elf32_arm_find_nearest_line): Add parameter to call
549 to _bfd_find_nearest_line.
550 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Add parameter to
551 call to _bfd_find_nearest_line.
555 * coffgen.c: Fix formatting.
556 * elf-m10300.c: Likewise.
557 * elf32-i386.c: Likewise.
558 * elf32-i960.c: Likewise.
559 * elf32-m68k.c: Likewise.
560 * elf32-mcore.c: Likewise.
561 * elf32-ppc.c: Likewise.
562 * elf32-sh.c: Likewise.
563 * elf32-sparc.c: Likewise.
564 * elf32-v850.c: Likewise.
565 * elf64-alpha.c: Likewise.
566 * elf64-hppa.c: Likewise.
567 * elf64-mips.c: Likewise.
568 * elf64-sparc.c: Likewise.
572 * elf32-ppc.c: Fix formatting.
573 * elf64-x86-64.c: Likewise.
579 * elf32-mips.c (elf32_mips_merge_private_bfd_data): Always permit
580 BFDs containing no sections or empty .text, .data or .bss sections
581 to be merged, regardless of their flags.
585 * elf32-m32r.c: Fix formatting.
586 * elf32-m68hc11.c: Likewise.
587 * elf32-m68hc12.c: Likewise.
588 * elf32-m68k.c: Likewise.
589 * elf32-mcore.c: Likewise.
590 * elf32-pj.c: Likewise.
591 * elf32-ppc.c: Likewise.
595 * elf32-fr30.c: Fix formatting.
596 * elf32-hppa.c: Likewise.
597 * elf32-i370.c: Likewise.
598 * elf32-i386.c: Likewise.
599 * elf32-i860.c: Likewise.
600 * elf32-i960.c: Likewise.
604 * elf32-arm.h: Fix formatting.
605 * elf32-avr.c: Likewise.
606 * elf32-cris.c: Likewise.
607 * elf32-d10v.c: Likewise.
608 * elf32-d30v.c: Likewise.
609 * elf-hppa.h: Likewise.
610 * elf-m10200.c: Likewise.
611 * elf-m10300.c: Likewise.
615 * aoutx.h (NAME(aout,machine_type)): Add bfd_mach_mips32 and
616 bfd_mach_mips32_4k. Update FIXME comment.
617 * archures.c (bfd_mach_mips32): New constant.
618 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
619 the latter, renumber it.
620 * bfd-in2.h (bfd_mach_mips32): New constant.
621 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
622 the latter, renumber it.
623 * cpu-mips.c (I_mips32): New constant.
624 (I_mips4K, I_mips32_4k): Rename the former to the latter.
625 (arch_info_struct): Add bfd_mach_mips32 entry, replace
626 bfd_mach_mips4K entry with bfd_mach_mips32_4k entry.
627 * elf32-mips.c (elf_mips_isa): Add E_MIPS_ARCH_32 case.
628 (elf_mips_mach): Likewise. Also, replace E_MIPS_MACH_MIPS32
629 with E_MIPS_MACH_MIPS32_4K.
630 (_bfd_mips_elf_final_write_processing): Replace
631 bfd_mach_mips4K with bfd_mach_mips32_4k case, add
632 bfd_mach_mips32 case.
633 (_bfd_mips_elf_merge_private_bfd_data): Generalize ISA mixing
634 comparison with support for MIPS32.
635 (_bfd_mips_elf_print_private_bfd_data): Print ISA name for
638 * aoutx.h (NAME(aout,machine_type)): Add cases for
639 bfd_mach_mips5 and bfd_mach_mips64.
640 * archures.c (bfd_mach_mips5, bfd_mach_mips64): New constants.
641 * bfd-in2.h (bfd_mach_mips5, bfd_mach_mips64): Likewise.
642 * cpu_mips.c (I_mips5, I_mips64): New definitions.
643 (arch_info_struct): Add entries for bfd_mach_mips5 and
645 * elf32-mips.c (elf_mips_isa, elf_mips_mach,
646 _bfd_mips_elf_print_private_bfd_data): Add cases for
647 E_MIPS_ARCH_5 and E_MIPS_ARCH_64.
648 (_bfd_mips_elf_final_write_processing): Add cases for
649 bfd_mach_mips5 and bfd_mach_mips64.
651 * bfd/aoutx.h (NAME(aout,machine_type)): Add a
652 bfd_mach_mips_sb1 case.
653 * bfd/archures.c (bfd_mach_mips_sb1): New constant.
654 * bfd/bfd-in2.h (bfd_mach_mips_sb1): New constant.
655 * bfd/cpu-mips.c (I_sb1): New constant.
656 (arch_info_struct): Add entry for bfd_mach_mips_sb1.
657 * bfd/elf32-mips.c (elf_mips_mach): Add case for
659 (_bfd_mips_elf_final_write_processing): Add case for
664 * config.bfd (arm-*-rtems*, a29k-*rtems*): New targets.
665 (sparc*-*-rtemself*, sparc*-*-rtemsaout*): New targets.
666 (sparc*-*-rtems*): Switched from a.out to ELF.
670 * Makefile.am (BFD64_BACKENDS): Add elf64-x86-64.lo
671 BFD64_BACKENDS_CFILES): Add elf64-x86-64.c
672 (elf64-x86-64.lo): Add dependencies.
673 * archures.c (DESCRIPTION): Add bfd_mach_x86_64,
674 bfd_mach_x86_64_intel_syntax.
675 * elf.c (prep_headers): Use EM_x86_64 for 64bit output.
676 * config.bfd (x86_64): Add.
677 * configure.in: Add support for bfd_elf64_x86_64_vec.
678 * cpu-i386.c (bfd_x86_64_arch_intel_syntax, bfd_x86_64_arch): Add.
679 (bfd_i386_arch, i8086_ar): Link in.
680 * elf64-x86-64.c: New file.
681 * reloc.c (ENUMDOC): Add BFD_RELOC_X86_64*.
682 * targets.c (bfd_elf64_x86_64_vec): Add.
683 (bfd_target_vect): Add bfd_elf64_x86_64_vec.
687 * xcofflink.c: Fix formatting.
691 * aoutx.h: Fix formatting.
692 * bfd-in.h: Likewise.
693 * bfd-in2.h: Likewise.
695 * cisco-core.c: Likewise.
696 * coff64-rs6000.c: Likewise.
697 * coffcode.h: Likewise.
698 * coffswap.h: Likewise.
699 * corefile.c: Likewise.
700 * elf32-mips.c: Likewise.
704 * aout-adobe.c: Fix formatting.
705 * coff64-rs6000.c: Likewise.
706 * coffgen.c: Likewise.
707 * cofflink.c: Likewise.
711 * libcoff-in.h (coff_tdata): Add `strings_written' flag.
712 (obj_coff_strings_written): New accessor macro for above.
713 * libcoff.h: Regenerate.
714 * cofflink.c (_bfd_coff_final_link): Say that we wrote the
716 * coffcode.h (coff_write_object_contents): No need to write out
717 the string table if it's already been done.
721 * cofflink.c (_bfd_coff_generic_relocate_section): Don't object to
722 weak undefined symbols.
726 * archures.c (bfd_mach_arm_5TE): Define.
727 (bfd_mach_arm+XScale): Define.
728 * bfd-in2.h: Regenerate.
730 * coff-arm.c (coff_arm_reloc_type_lookup): Accept
731 BFD_RELOC_ARM_PCREL_BLX.
733 * coffcode.h (coff_set_flags): Set flags for 5t, 5te and
734 XScale machine numbers.
736 * config.bfd (xscale-elf): Add target.
737 (xscale-coff): Add target.
739 * cpu-arm.c: Add xscale machine name.
740 Add v5t, v5te and XScale machine numbers.
744 * aix386-core.c: Fix formatting.
748 * coff-ia64.c (howto_table): Use EMPTY_HOWTO.
749 (in_reloc_p): Add ATTRIBUTE_UNUSED to unused parameters.
750 * cpu-ia64-opc.c (ins_rsvd, ext_rsvd, ins_const, ext_const): Likewise.
751 (ins_imms_scaled): Initialize sign_bit at function entry.
752 (elf64_ia64_operands): Add missing initializers.
753 * elfxx-ia64.c (elfNN_ia64_reloc, elfNN_ia64_reloc_type_lookup,
754 elfNN_ia64_info_to_howto, elfNN_ia64_fake_sections,
755 elfNN_ia64_add_symbol_hook, elfNN_ia64_is_local_label_name,
756 elfNN_ia64_local_hash_table_init, get_fptr, get_pltoff,
757 elfNN_ia64_adjust_dynamic_symbol): Add ATTRIBUTE_UNUSED for unused
759 (elfNN_ia64_info_to_howto): Initialize free_relocs, free_contents,
760 and free_extsyms at function entry.
761 (elfNN_add_symbol_hook): Add unsigned cast to bfd_get_gp_size result.
762 (elfNN_ia64_create_dynamic_sections): Delete unused local h.
763 (get_got): Delete unused local srel.
764 (elfNN_ia64_check_relocs): Initialize dynrel_type when declared.
765 (elfNN_ia64_relocate_section): Delete unused local dynindx.
769 * coff-a29k.c: Fix formatting.
770 * coff-h8500.c: Likewise.
771 * coff-i960.c: Likewise.
772 * coff-ppc.c: Likewise.
773 * coff-rs6000.c: Likewise.
774 * coff-stgo32.c: Likewise.
775 * coff-tic54x.c: Likewise.
776 * coff-w65.c: Likewise.
777 * cpu-h8500.c: Likewise.
778 * cpu-hppa.c: Likewise.
779 * cpu-ns32k.c: Likewise.
781 * ecofflink.c: Likewise.
785 * elf32-sh.c (sh_elf_reloc_loop): Fix compile time warning, and
786 remove possibility of infinite loop.
790 * aix386-core.c: Fix formatting.
791 * aout-adobe.c: Likewise.
792 * aout-arm.c: Likewise.
793 * aout-encap.c: Likewise.
794 * aout-ns32k.c: Likewise.
795 * aout-target.h: Likewise.
796 * aout-tic30.c: Likewise.
797 * aoutf1.h: Likewise.
799 * archive.c: Likewise.
800 * bfd-in.h: Likewise.
801 * bfd-in2.h: Likewise.
807 * elfxx-ia64.c (elfNN_ia64_size_dynamic_sections): Don't create
808 pltoff entries for DT_INIT and DT_FINI.
809 (elfNN_ia64_final_link): Don't set DT_INIT/FINI entries.
810 (elfNN_ia64_finish_dynamic_sections): Don't fill in DT_INIT/FINI
815 * elfxx-ia64.c (elfNN_ia64_check_relocs): Handle IPLT relocs.
816 (allocate_dynrel_entries): Likewise.
817 (elfNN_ia64_relocate_section): Likewise. Set REL addends correctly.
818 (set_pltoff_entry): Likewise.
819 (ia64_howto_table): Remove R_IA64_SEGBASE, and R_IA64_EPLT[ML]SB
820 (elfNN_ia64_reloc_type_lookup): Likewise.
821 (elfNN_ia64_install_value): Likewise.
822 (elfNN_ia64_relocate_section): Likewise.
823 * reloc.c (BFD_RELOC_IA64_SEGBASE): Remove.
824 (BFD_RELOC_IA64_EPLTMSB, BFD_RELOC_IA64_EPLTLSB): Remove.
828 * cpu-a29k.c: Fix formatting.
829 * cpu-alpha.c: Likewise.
830 * cpu-arm.c: Likewise.
831 * cpu-avr.c: Likewise.
832 * cpu-d10v.c: Likewise.
833 * cpu-h8500.c: Likewise.
834 * cpu-hppa.c: Likewise.
835 * cpu-i370.c: Likewise.
836 * cpu-i386.c: Likewise.
837 * cpu-i960.c: Likewise.
838 * cpu-ia64-opc.c: Likewise.
839 * cpu-ia64.c: Likewise.
840 * cpu-m32r.c: Likewise.
841 * cpu-m68hc11.c: Likewise.
842 * cpu-m68hc12.c: Likewise.
843 * cpu-m68k.c: Likewise.
844 * cpu-m88k.c: Likewise.
845 * cpu-mips.c: Likewise.
846 * cpu-ns32k.c: Likewise.
847 * cpu-pj.c: Likewise.
848 * cpu-powerpc.c: Likewise.
849 * cpu-sh.c: Likewise.
850 * cpu-sparc.c: Likewise.
851 * cpu-tic54x.c: Likewise.
852 * cpu-v850.c: Likewise.
853 * cpu-vax.c: Likewise.
854 * cpu-w65.c: Likewise.
855 * cpu-we32k.c: Likewise.
856 * cpu-z8k.c: Likewise.
857 * dwarf1.c: Likewise.
858 * dwarf2.c: Likewise.
862 * coff-arm.c: Fix formatting.
863 * coff-ppc.c: Likewise.
864 * coff-rs6000.c: Likewise.
865 * coff-sh.c: Likewise.
866 * coff-sparc.c: Likewise.
867 * coff-tic30.c: Likewise.
868 * coff-tic54x.c: Likewise.
869 * coff-tic80.c: Likewise.
870 * coff-w65.c: Likewise.
871 * coff-we32k.c: Likewise.
872 * coff-z8k.c: Likewise.
876 * elf64-alpha.c (elf64_alpha_check_relocs): Create the reloc
877 section with the same ALLOC|LOAD flags as the source section.
881 * elf64-alpha.c (elf64_alpha_relax_opt_call): Only check bits used
882 by STO_ALPHA constants.
886 * coff-pmac.c: Fix formatting.
887 * coff-ppc.c: Likewise.
891 * elflink.h (elf_link_add_object_symbols): Also add indirect
892 symbols for common symbols with the default version.
896 * section.c (STD_SECTION): Set gc_mark flag.
900 * coff-i960.c: Likewise.
901 * coff-m68k.c: Likewise.
902 * coff-m88k.c: Likewise.
903 * coff-mcore.c: Likewise.
904 * coff-mips.c: Likewise.
908 * elf32-sh.c (sh_elf_relocate_section): Ignore R_SH_NONE relocs.
912 * coff-h8300.c: Fix formatting.
913 * coff-h8500.c: Likewise.
914 * coff-i386.c: Likewise.
915 * coff-i860.c: Likewise.
916 * coff-i960.c: Likewise.
917 * coff-ia64.c: Likewise.
921 * archive.c: Fix formatting.
922 * archures.c: Likewise.
926 * elfxx-ia64.c (elf64_ia64_final_link): New local unwind_output_sec.
927 Set it before bfd_elf64_bfd_final_link call. Use it after the call.
928 * section.c (bfd_set_section_contents): Call memcpy if
929 section->contents set and location not equal to contents plus offset.
933 * bfd-in.h: Fix formatting.
934 * bfd-in2.h: Likewise.
936 * binary.c: Likewise.
938 * coff-a29k.c: Likewise.
939 * coff-alpha.c: Likewise.
940 * coff-apollo.c: Likewise.
941 * coff-aux.c: Likewise.
945 * aix386-core.c: Fix formatting.
946 * aoutf1.h: Likewise.
948 * archures.c: Likewise.
949 * armnetbsd.c: Likewise.
953 * coff-h8300.c (special): Adjust reloc address.
957 * archures.c (bfd_mach_ia64_elf64, bfd_mach_ia64_elf32): Add defines
958 to differentiate elf32 and elf64 on ia64.
959 * bfd-in2.h: Regenerate.
960 * config.bfd: Add target for "ia64*-*-hpux*".
961 * configure.in: Add bfd_elf32_ia64_big_vec to selvecs switch.
962 * configure: Regenerate.
963 * cpu-ia64.c (bfd_ia64_elf32_arch): Add elf32 arch info structure.
964 * targets.c: Add bfd_target bfd_elf32_ia64_big_vec.
966 * Makefile.am: Make elf32-ia64.c and elf64-ia64.c derived objects
967 from elfxx-ia64.c. Add depenency rules for making elf32-ia64.lo.
968 * Makefile.in: Regnerate.
969 * elf64-ia64.c: Deleted.
970 * elfxx-ia64.c: New file, paramaterized version of elf64-ia64.c.
974 * aout-adobe.c: Fix formatting.
975 * aout-arm.c: Likewise.
976 * aout-cris.c: Likewise.
977 * aout-encap.c: Likewise.
978 * aout-ns32k.c: Likewise.
979 * aout-target.h: Likewise.
980 * aout-tic30.c: Likewise.
984 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Always permit
985 BFDs containing no sections to be merged, regardless of their flags.
989 * elf32-arm.h (elf32_arm_relocate_section): Suppress error message
990 if a relocation for an undefined symbol also results in an
995 * config.bfd: Add support for Sun Chorus.
999 * configure.in: Recognize alpha-*-freebsd*.
1000 * configure: Regenerate.
1004 * srec.c (CHUNK): Rename to DEFAULT_CHUNK.
1005 (Chunk): New global variable set by a parameter in objcopy.c.
1006 (S3Forced): New global variable set by a parameter in
1008 (srec_set_section_contents): If S3Forced is true, always generate
1010 (srec_write_section): Use 'Chunk' to limit maximum length of S
1015 * config.bfd: Add support for i[3456]86-chaosdev-storm-chaos.
1016 * Makefile.in: Regenerate.
1017 * bfd-in2.h: Regenerate.
1018 * po/bfd.pot: Regenerate.
1022 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Only handle
1023 EF_SOFT_FLOAT if it is defined.
1027 * elf32-arm.h (elf32_arm_copy_private_bfd_data): Don't refuse
1028 attempts to mix PIC code with non-PIC, just mark the output as
1029 being position dependent.
1030 (elf32_arm_merge_private_bfd_data): Likewise. Print an error
1031 message for EF_SOFT_FLOAT mismatches. Display diagnostics for
1032 all mismatches, not just the first one.
1036 * ieee.c (ieee_archive_p): Plug one of many possible
1037 memory leaks in error handling.
1041 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data,
1042 elf32_sparc_object_p, elf32_sparc_final_write_processing):
1044 * elf64-sparc.c (sparc64_elf_merge_private_bfd_data,
1045 sparc64_elf_object_p): Support v9b.
1046 * archures.c: Declare v8plusb and v9b machines.
1048 * cpu-sparc.c: Ditto.
1052 * elf64-sparc.c (sparc64_elf_relocate_section): Clear the location
1055 * elf32-ppc.c (SYMBOL_REFERENCES_LOCAL): New macro.
1056 (SYMBOL_CALLS_LOCAL): New macro.
1057 (ppc_elf_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL.
1058 (ppc_elf_check_relocs): Use SYMBOL_REFERENCES_LOCAL.
1059 (ppc_elf_finish_dynamic_symbol): Use SYMBOL_REFERENCES_LOCAL.
1060 (ppc_elf_relocate_section): Use flag variable to determine
1061 whether the relocation refers to a local symbol.
1062 Test whether a PLTREL24 reloc will produce a reloc by looking
1063 to see whether a PLT entry was made.
1067 * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Don't make PLT
1068 entries that could serve as a definition for a weak symbol.
1074 * elf32-mips.c (mips_elf_create_dynamic_relocation): New argument
1075 local_p. Add symbol value only for non-R_MIPS_REL32 relocations
1076 against local symbols.
1077 (_bfd_mips_elf_finish_dynamic_sections): Undo patch from 2000-10-01.
1081 * section.c (struct sec): Add kept_section.
1082 (struct bfd_comdat_info): Remove sec, we can use above.
1083 (STD_SECTION): Add initializer.
1084 (bfd_make_section_anyway): Init here too.
1086 * bfd-in2.h: Regenerate.
1088 * elflink.h (elf_link_add_object_symbols): Remove unnecessary
1090 (elf_link_input_bfd): Set all asection->symbol->value's here, and
1091 fudge values for discarded link-once section symbols.
1093 * elf64-hppa.c: Include alloca-conf.h
1097 * elf.c (swap_out_syms): Revert 2000-10-07 changes.
1099 * ieee.c (ieee_make_empty_symbol): Oops, bfd_zalloc needs another arg.
1103 * ieee.c (ieee_make_empty_symbol): Use bfd_zalloc, not bfd_zmalloc.
1107 * section.c (bfd_make_section_anyway): Release newsect ptr when
1108 newsect->symbol fails to alloc. Use bfd_release instead of free.
1112 * elf64-ia64.c (elf64_ia64_unwind_entry_compare_bfd): New.
1113 (elf64_ia64_unwind_entry_compare): New.
1114 (elf64_ia64_final_link): Sort the .IA_64.unwind section.
1118 * elflink.h (size_dynamic_sections): Don't create various tags if
1119 .dynstr is excluded from the link. Don't set first dynsym entry
1120 if dynsymcount is zero.
1121 (elf_bfd_final_link): Don't try to swap out dynamic syms if
1122 .dynsym excluded from the link. Don't try to write any dynamic
1123 sections excluded from the link.
1125 * elf.c (swap_out_syms): Handle global section symbols.
1129 * peigen.c (_bfd_pei_swap_scnhdr_out): note extended relocs
1130 * coffcode.h (coff_set_alignment_hook): read extended reloc count
1131 (coff_write_relocs): write extended reloc count
1132 (coff_write_object_contents): account for extended relocs
1136 * elf-bfd.h (struct elf_backend_data): Add elf_backend_section_flags
1138 * elf.c (_bfd_elf_make_section_from_shdr): Call the
1139 elf_backend_section_flags function.
1140 * elf64-ia64.c (elf64_ia64_section_from_shdr): Delete flag conversion
1142 (elf64_ia64_section_flags): New function containing flag conversion
1144 (elf_backend_section_flags): Define to elf64_ia64_section_flags.
1145 * elfxx-target.h (elf_backend_section_flags): Define.
1146 (elfNN_bed): Initialize elf_backend_section_flags field.
1150 * elf32-hppa.c (elf32_hppa_check_relocs): Correct call to
1151 _bfd_elf32_gc_record_vtable. Correct a comment.
1157 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_sections): Mark gld
1158 produces binaries with got[1] = 0x80000001 to differenciate them
1159 for the dynamic linker from the broken binaries produced by old
1164 * elf.c (elfcore_grok_pstatus): Check for size of pxstatus_t.
1165 (elfcore_grok_lwpstatus): Check for size of lwpxstatus_t.
1166 * configure.in: Add check for pxstatus_t and lwpxstatus_t.
1167 * configure: Regenerate.
1171 Define two bfd_targets for absence and presence of leading
1172 underscore on symbols. Make sure to only link same kind.
1173 * elf32-cris.c (cris_elf_object_p,
1174 cris_elf_final_write_processing, cris_elf_print_private_bfd_data,
1175 cris_elf_merge_private_bfd_data): New.
1176 (elf_backend_object_p, elf_backend_final_write_processing,
1177 bfd_elf32_bfd_print_private_bfd_data,
1178 bfd_elf32_bfd_merge_private_bfd_data): Define.
1179 <Target vector definition>: Include elf32-target.h twice with
1180 different macro settings:
1181 (TARGET_LITTLE_SYM): First as bfd_elf32_cris_vec, then as
1182 bfd_elf32_us_cris_vec.
1183 (TARGET_LITTLE_NAME): First as "elf32-cris", then "elf32-us-cris".
1184 (elf_symbol_leading_char): First as 0, then '_'.
1185 (INCLUDED_TARGET_FILE): Define for second include of elf32-target.h.
1186 * config.bfd (cris-*-*): Add bfd_elf32_us_cris_vec to targ_selvecs.
1187 * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vector.
1188 * configure: Regenerate.
1189 * targets.c: Declare bfd_elf32_us_cris_vec.
1190 * po/bfd.pot: Regenerate.
1194 * elf32-arm.h (arm_add_to_rel): Correctly adjust the addend for
1195 R_ARM_THM_PC22 relocations.
1199 * elflink.h (elf_link_add_object_symbols): Don't bfd_release runpath.
1203 * elf.c (elf_fake_sections): Do not mark the section SHT_NOBITS if
1204 is has the SEC_HAS_CONTENTS flag set.
1209 * aout-cris.c (N_TXTADDR): Define.
1213 * som.c: Include alloca-conf.h.
1214 * Makefile.am: "make dep-am"
1215 * Makefile.in: Regenerate.
1219 * elf32-hppa.c (plt_stub): New.
1220 (PLT_STUB_ENTRY): Define.
1221 (elf32_hppa_link_hash_table): Change multi_subspace to packed
1222 boolean. Add need_plt_stub, has_12bit_branch and has_17bit_branch.
1223 (elf32_hppa_link_hash_table_create): Init to suit.
1224 (elf32_hppa_check_relocs): Set has_12bit_branch and
1225 has_17bit_branch as appropriate.
1226 (elf32_hppa_adjust_dynamic_symbol): Set need_plt_stub for
1227 non-local functions.
1228 (elf32_hppa_size_dynamic_sections): Correct setting of reltext.
1229 Add space for plt_stub as needed.
1230 (elf32_hppa_finish_dynamic_symbol): Point .plt entries for global
1231 functions at plt_stub.
1232 (elf32_hppa_finish_dynamic_sections): Write plt_stub.
1233 (elf32_hppa_create_dynamic_sections): Leave .plt executable.
1235 * elf32-hppa.h (elf32_hppa_size_stubs): Add group_size param.
1236 * elf32-hppa.c (elf32_hppa_size_stubs): Likewise. Use it instead
1237 of fixed size, and if negative, disable handling of input sections
1238 before stub section. Set up default stub group size depending
1239 on detected branch relocs.
1240 (hppa_build_one_stub): Use lrsel and rrsel for import stubs to
1241 ensure different offsets from sym_value aren't rounded to
1242 different 2k blocks. Use lrsel and rrsel for other stubs too for
1243 consistency rather than necessity.
1244 (elf32_hppa_check_relocs): Handle R_PARISC_DIR14F.
1245 (final_link_relocate): Likewise.
1246 (elf32_hppa_relocate_section): Likewise.
1248 * elf-hppa.h (elf_hppa_howto_table): Add R_PARISC_DIR14F reloc.
1249 (_bfd_elf_hppa_gen_reloc_type): Generate them.
1250 (elf_hppa_final_link_relocate): Handle them.
1251 (elf_hppa_relocate_insn): Likewise.
1252 (_bfd_elf_hppa_gen_reloc_type): Add missing e_ldsel and e_rdsel cases.
1256 * elfcode.h (elf_object_p): Preserve and clear abfd section
1257 information. Restore at error.
1261 * peigen.c (_bfd_pei_swap_aouthdr_in): If some DataDirectory
1262 is empty, make sure that its rva also 0. NT loader dislikes
1267 * som.c (som_bfd_derive_misc_symbol_info): Make weak symbols
1272 * elf32-hppa.c (elf32_hppa_check_relocs): Fix weak sym handling in
1273 currently unused RELATIVE_DYNAMIC_RELOCS code.
1274 (hppa_discard_copies): Likewise.
1275 (elf32_hppa_size_stubs): Size `input_list' array correctly. Correct
1276 comments. Don't check non-code output sections for stub grouping.
1280 * section.c (bfd_get_unique_section_name): Return NULL if
1285 * elf32-m68k.c (elf_cpu32_plt0_entry): Change the PLT entry 0
1286 instruction sequence to actually work.
1287 (elf_m68k_finish_dynamic_sections): Change the patch-in offset
1292 * elf32-sh.c (sh_elf_relocate_section): Use
1293 _bfd_final_link_relocate to apply the relocation against a section
1294 symbol, when doing relocatable links.
1298 * elf32-hppa.c (elf32_hppa_stub_hash_entry): Rename input_section
1300 (stub_hash_newfunc): Here too.
1301 (hppa_add_stub): And here.
1302 (elf32_hppa_link_hash_table): Remove stub_section_created,
1303 reloc_section_created, first_init_sec and first_fini_sec. Add
1305 (elf32_hppa_link_hash_table_create): Init to suit.
1306 (hppa_get_stub_entry): Add support for grouping stub sections.
1307 (hppa_add_stub): Likewise. Remove sec_count param and init/fini
1308 section code. Index stub vars by section->id.
1309 (elf32_hppa_size_stubs): Likewise. Remove duplicated function
1310 exit paths. Zap allocation of above removed vars. Refine
1313 * elf32-hppa.h (elf32_hppa_size_stubs): Add output_bfd param.
1314 * elf32-hppa.c (elf32_hppa_size_stubs): Likewise.
1315 (hppa_get_stub_entry): Pass in pointer to elf32_hppa_link_hash_table
1316 rather than pointer to bfd_link_info.
1317 (hppa_add_stub): Likewise.
1318 (final_link_relocate): Likewise.
1322 (elf32_hppa_size_stubs): Don't try to build stubs for discarded
1327 * elf32-sh.c (ELF_MAXPAGESIZE): Define to 128, to match
1328 ld/emulparams/shelf.sh.
1332 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): New function.
1333 * bfd-in.h (bfd_m68k_elf32_create_embedded_relocs): Add declaration.
1334 * bfd-in2.h: Regenerate.
1338 * bfd/elf64-alpha.c (elf64_alpha_relax_with_lituse): ld performs
1339 LITUSE relocations incorrectly if -relax is specified on the ld
1340 command line and the displacement field of the load or store
1345 * elf32-hppa.c (hppa_add_stub): Dont set first_init_sec and
1346 first_fini_sec here.
1347 (elf32_hppa_size_stubs): Instead correctly find the first .init
1348 and .fini section here.
1352 * elf32-hppa.c (clobber_millicode_symbols): New function.
1353 (elf32_hppa_size_dynamic_sections): Call it.
1357 * elf32-hppa.c (elf32_hppa_link_hash_entry): Make pic_call
1358 packed. Add plabel, plt_abs packed booleans.
1359 (hppa_link_hash_newfunc): Init new fields.
1360 (PLABEL_PLT_ENTRY_SIZE): Define.
1361 (hppa_stub_name): Use size_t len vars.
1362 (hppa_add_stub): Likewise.
1363 (elf32_hppa_build_stubs): Likewise.
1364 (hppa_build_one_stub): Kill some compiler warnings.
1365 (elf32_hppa_check_relocs): Always generate a plt entry for PLABELs
1366 if dynamic linking. Munge the local plt offsets into
1367 local_got_refcounts. Set h->plabel for all global PLABELs. Use
1368 size_t len vars. Add assert for plabel addend.
1369 (elf32_hppa_gc_sweep_hook): Sweep local plt entries too.
1370 (elf32_hppa_hide_symbol): New function.
1371 (elf_backend_hide_symbol): Define.
1372 (elf32_hppa_adjust_dynamic_symbol): Don't throw away plt entries
1373 with h->plabel set. Don't make plt entries to have dynamic syms
1374 when they have been forced local. If plt entry is used by a
1375 plabel, make it PLABEL_PLT_ENTRY_SIZE.
1376 (elf32_hppa_size_dynamic_sections): Set plt_abs for init fns.
1377 Set up .plt offsets for local syms.
1378 (elf32_hppa_relocate_section): Initialise plt entries for local
1379 syms. Leave weak undefined plabels zero. Make global plabel
1380 relocs against function symbol, and leave the addend zero.
1381 Use *ABS* DIR32 relocs instead of SEGREL32 for dynamic got relocs.
1382 (elf32_hppa_finish_dynamic_symbol): Set up IPLT relocs for
1383 non-dynamic syms. Init extra plt for plabels. Use *ABS* DIR32
1384 relocs instead of SEGREL32 for dynamic got relocs.
1385 (elf32_hppa_finish_dynamic_sections): Reserve one more .got entry.
1386 (elf_backend_got_header_size): Adjust.
1387 (elf32_hppa_set_gp): Calculate an "ideal" LTP.
1389 * elf32-hppa.c (LONG_BRANCH_VIA_PLT): Define.
1390 (hppa_type_of_stub): Use it instead of #if 0
1391 (hppa_discard_copies): Use it here too.
1392 (elf32_hppa_size_dynamic_sections): And here.
1394 * elf32-hppa.c (elf32_hppa_link_hash_table): Remove `offset' field.
1395 (elf32_hppa_link_hash_table_create): And here.
1396 (hppa_build_one_stub): And here. Instead keep track of stub
1397 offset using _raw_size.
1398 (elf32_hppa_size_stubs): Likewise.
1399 (elf32_hppa_build_stubs): Likewise.
1400 (hppa_size_one_stub): Likewise. Resize reloc section too.
1402 * elf32-hppa.c (hppa_add_stub): Correct first_init_sec and
1403 first_fini_sec handling. Don't search for reloc section or set
1404 hplink->reloc_section_created here.
1405 (elf32_hppa_size_stubs): Instead search for reloc sections, and
1406 set reloc_section_created here.
1407 (hppa_handle_PIC_calls): Set ELF_LINK_HASH_NEEDS_PLT.
1408 (elf32_hppa_size_dynamic_sections): Make a .plt entry for DT_INIT
1410 (elf32_hppa_finish_dynamic_sections): Set DT_INIT and DT_FINI.
1412 * elf32-hppa.c (hppa_build_one_stub): Replace `elf_hash_table (info)'
1413 with `hplink->root.'.
1414 (elf32_hppa_check_relocs): Likewise.
1415 (elf32_hppa_gc_sweep_hook): Likewise.
1416 (elf32_hppa_adjust_dynamic_symbol): Likewise.
1417 (hppa_handle_PIC_calls): Likewise.
1418 (elf32_hppa_size_dynamic_sections): Likewise.
1419 (elf32_hppa_set_gp): Likewise.
1420 (elf32_hppa_relocate_section): Likewise.
1421 (elf32_hppa_finish_dynamic_symbol): Likewise.
1422 (elf32_hppa_finish_dynamic_sections): Likewise.
1425 * elf32-hppa.c (hppa_type_of_stub): Generate import stubs for
1426 defined weak symbols in shared links.
1427 (final_link_relocate): Calls to defined weak symbols in shared
1428 objects must go via import stubs, as the target might not be known
1433 * elf32-sh.c (sh_elf_howto_table): Moved R_SH_GOT32, R_SH_PLT32,
1434 R_SH_COPY, R_SH_GLOB_DAT, R_SH_JMP_SLOT, R_SH_RELATIVE,
1435 R_SH_GOTOFF, R_SH_GOTPC) to the range from 160 to 167. Replaced
1436 the original entries with EMPTY_HOWTOs, and added new ones to fill
1438 (sh_elf_info_to_howto): Make sure the new gap isn't used.
1439 (sh_elf_relocate_section): Likewise.
1443 * cpu-mips.c (arch_info_struct): Add mips:4K
1444 * bfd-in2.h (bfd_mach_mips4K): New define.
1445 * archures.c: Add bfd_mach_mips4K to comment.
1446 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Return
1447 E_MIPS_ARCH_2 for bfd_mach_mips4K.
1451 * som.c (som_write_symbol_strings): Do not used fixed buffers,
1452 use size_t as a counter.
1453 (som_write_space_strings): Similarly.
1457 * elf32-i860.c (elf32_i860_relocate_pc26): New function
1459 (elf32_i860_relocate_section): Invoke new function from here.
1463 * elf.c (_bfd_elf_make_section_from_shdr): Make debug_sec_names
1468 * coff-m68k.c (bfd_m68k_coff_create_embedded_relocs): Emit 8 NULs for
1469 target section name instead of dumping core when the target symbol is
1474 * riscix.c: Remove DEFUN.
1478 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Do not
1479 initialise flags in output bfd if the input bfd is the default
1480 architecture with the default flags.
1484 * archive.c: Fix formatting.
1485 * coff-arm.c: Likewise.
1486 * doc/chew.c: Likewise.
1490 * section.c (bfd_get_unique_section_name): Put a dot before the
1495 * doc/chew.c: Remove all uses of DEFUN and DEFUN_VOID.
1496 * elf.c: Fix formatting.
1500 * config.bfd (sh-*-linux*): Added.
1501 * configure.in (bfd_elf32_shlin_vec, bfd_elf32_shblin_vec): New.
1502 * targets.c: Declare them.
1503 * elf32-sh-lin.c: New file.
1504 * Makefile.am: Compile it.
1505 * elf32-sh.c: Don't override defines from elf32-sh-lin.c.
1506 * configure, Makefile.in: Rebuilt.
1510 * xcofflink.c (xcoff_link_input_bfd): Include the .tocbss
1511 pseduo-section when determining where the TOC ends.
1513 * coff-rs6000.c (_bfd_xcoff_swap_aux_out): Use bfd_h_put_16 to
1514 output x_tvndx as it is only two bytes wide.
1516 * coff-rs6000.c (xcoff_howto_table): A modifiable branch-absolute
1517 reloc is 26 or 32 bits wide.
1519 * coff-rs6000.c (_bfd_xcoff_rtype2howto): The bitsize is irrelevant
1520 for relocs that don't change anything. Also look at the full
1525 * config.bfd (arm*-*-uclinux*): New target.
1529 * configure: Rebuilt with new libtool.m4.
1533 * section.c (bfd_get_unique_section_name): Avoid c++ reserved
1534 word for variable name.
1535 * bfd-in2.h: Regenerate.
1539 * config.in: Regenerate.
1540 * libbfd.h: Regenerate.
1541 * po/bfd.pot: Regenerate.
1542 * doc/bfdint.texi: Remove CVS date string - it foils compares with
1547 * cpu-powerpc.c (arch_info_struct): Added MPC860 Family entry.
1551 Shared library and PIC support.
1552 * elf32-hppa.c (PLT_ENTRY_SIZE): New.
1553 (GOT_ENTRY_SIZE): New.
1554 (ELF_DYNAMIC_INTERPRETER): New.
1555 (STUB_SUFFIX): Define.
1556 (LONG_BRANCH_PIC_IN_SHLIB): Define.
1557 (RELATIVE_DYNAMIC_RELOCS): Define.
1558 (enum elf32_hppa_stub_type): New.
1559 (struct elf32_hppa_stub_hash_entry): Rename offset to
1560 stub_offset. Add a number of new fields.
1561 (struct elf32_hppa_link_hash_entry): New.
1562 (struct elf32_hppa_link_hash_table): Add numerous fields. Remove
1564 (elf32_hppa_hash_table): Rename to hppa_link_hash_table.
1565 (elf32_hppa_stub_hash_lookup): Rename to hppa_stub_hash_lookup.
1566 (elf32_hppa_stub_hash_newfunc): Rename to stub_hash_newfunc. Init
1568 (hppa_link_hash_newfunc): New function.
1569 (elf32_hppa_link_hash_table_create): Use above function. Init new
1571 (elf32_hppa_stub_name): Rename to hppa_stub_name. Pass in reloc
1572 instead of addend, and remove sym_name from args. Don't use
1573 symbol name for local syms, instead use sym index.
1574 (elf32_hppa_size_of_stub): Rename to hppa_type_of_stub, and return
1575 stub type rather than size. Pass in hash and handle import stub
1576 case. Also pass in reloc instead of offset so we can calculate
1577 PCREL22F and PCREL12F branches properly.
1578 (elf32_hppa_build_one_stub): Rename to hppa_build_one_stub. Build
1579 import and export stubs too.
1580 (elf32_hppa_size_one_stub): Rename to hppa_size_one_stub. Handle
1581 import and export stub sizing.
1582 (elf32_hppa_check_relocs): New function.
1583 (elf32_hppa_adjust_dynamic_symbol): New function.
1584 (hppa_discard_copies): New function.
1585 (elf32_hppa_size_dynamic_sections): New function.
1586 (elf_backend_size_dynamic_sections): Define.
1587 (elf32_hppa_finish_dynamic_symbol): New function.
1588 (elf_backend_finish_dynamic_symbol): Define.
1589 (elf32_hppa_size_stubs): Stash params in link hash table, and move
1590 some local vars into the link hash table too. For shared links,
1591 trundle over function syms, generating export stubs. Handle
1592 PCREL22F branches. Break out stub creation code from here..
1593 (hppa_add_stub): .. to here. New function.
1594 (elf32_hppa_final_link): Rename to elf32_hppa_set_gp, and don't
1595 call the bfd linker. Use elf_gp to record global pointer.
1596 Calculate a value from sections if $global$ is missing.
1597 (bfd_elf32_bfd_final_link): Define as _bfd_elf32_gc_common_final_link.
1598 (elf32_hppa_gc_mark_hook): New function.
1599 (elf_backend_gc_mark_hook): Define.
1600 (elf32_hppa_gc_sweep_hook): New function.
1601 (elf_backend_gc_sweep_hook): Define.
1602 (elf32_hppa_bfd_final_link_relocate): Rename to final_link_relocate.
1603 Add rel to args, and remove howto, input_bfd, offset, addend,
1604 sym_name as we can recalculate these locally. Handle calls to
1605 dynamic objects, extra PIC relocs, PCREL22F branches. Change
1606 handling of undefined weak syms. Check that stubs are in range.
1607 Only look for import stubs on PCREL17F and PCREL22F relocs. Add
1608 message on hitting a DPREL21L reloc that needs fixing. Subtract
1609 off PC for PCREL14F. Break out code that does a stub lookup from
1611 (hppa_get_stub_entry): ..to here. New function.
1612 (elf32_hppa_relocate_insn): Merge into final_link_relocate.
1613 (elf32_hppa_relocate_section): Handle got and plt relocs, dynamic
1615 (elf32_hppa_finish_dynamic_sections): New function.
1616 (elf_backend_finish_dynamic_sections): Define.
1617 (elf_backend_final_write_processing) Define.
1618 (hppa_handle_PIC_calls): New function.
1619 (elf32_hppa_build_stubs): Call it. Pass link_info to
1620 hppa_build_one_stub.
1621 (elf32_hppa_create_dynamic_sections): New function
1622 to create .plt and .got then set .plt flags correctly.
1623 (elf_backend_create_dynamic_sections): Define.
1624 (elf32_hppa_object_p): New function.
1625 (elf_backend_object_p): Define.
1626 (elf32_hppa_elf_get_symbol_type): New function.
1627 (elf_backend_get_symbol_type): Define.
1628 (elf_backend_can_gc_sections): Define.
1629 (elf_backend_want_got_plt): Define.
1630 (elf_backend_plt_alignment): Set to 2.
1631 (elf_backend_plt_readonly): Define.
1632 (elf_backend_want_plt_sym): Define.
1633 (elf_backend_got_header_size): Reserve one entry.
1635 * elf32-hppa.h (elf32_hppa_build_stubs): Don't pass stub bfd.
1636 (elf32_hppa_size_stubs): Pass in multi_subspace.
1637 (elf32_hppa_set_gp): Declare.
1639 * section.c (SEC_HAS_GOT_REF): Define new flag for asection.
1640 (bfd_get_unique_section_name): New function.
1641 * bfd_in2.h: Regenerate.
1643 * elf64-hppa.c (elf64_hppa_check_relocs): Handle R_PARISC_PCREL12F.
1644 (elf64_hppa_size_dynamic_sections): Remove the FIXME at bfd_zalloc
1648 * elf64-hppa.c (elf64_hppa_check_relocs): Fix a warning.
1649 (elf64_hppa_mark_exported_functions): Set dyn_h->st_shndx.
1650 (elf64_hppa_link_output_symbol_hook): Test dyn_h->st_shndx has
1651 been updated in finish_dynamic_symbol before modifying function
1654 * elf-hppa.h (elf_hppa_howto_table): Restructure into groups of
1655 eight entries. Replace NULL with bfd_elf_generic_reloc. Add
1656 R_PARISC_GNU_VTENTRY, R_PARISC_GNU_VTINHERIT and R_PARISC_PCREL12F.
1657 (_bfd_elf_hppa_gen_reloc_type): Handle R_PARISC_GNU_VT*. Add some
1658 comments. Handle format == 12 for R_HPPA_PCREL_CALL.
1659 (elf_hppa_final_link_relocate): Handle R_PARISC_PCREL12F.
1660 (elf_hppa_relocate_insn): Likewise. Reformat some comments.
1661 (elf_hppa_final_write_processing): Expose it for ARCH_SIZE == 32.
1664 * elf-hppa.h (elf_hppa_is_local_label_name): Accept the SysV/ELF
1665 style of local labels as well.
1669 * elf32-arm.h (elf32_arm_relocate_section): Don't try to relocate
1670 references to undefined symbols in debugging sections.
1674 * reloc.c (BFD_RELOC_SH_COPY, BFD_RELOC_SH_GLOB_DAT,
1675 BFD_RELOC_SH_JMP_SLOT, BFD_RELOC_SH_RELATIVE,
1676 BFD_RELOC_SH_GOTPC): Move them from the MIPS section to the SH
1681 * elf32-i860.c (bfd_elf32_bfd_is_local_label_name): Define macro.
1682 (elf32_i860_is_local_label_name): New function and prototype.
1686 * configure.in: Increase version number to 2.10.91.
1687 * configure: Regenerate.
1688 * aclocal.m4: Regenerate.
1689 * config.in: Regenerate.
1690 * po/bfd.pot: Regenerate.
1694 * elf.c (_bfd_elf_make_section_from_shdr): Add
1695 .gnu.linkobce.wi. to the list of debug section names.
1699 * dwarf2.c (find_debug_info): New function: Locate a section
1700 containing dwarf2 debug information.
1701 (bfd_dwarf2_find_nearest_line): Find all sections containing
1702 debug information and include them in the stash.
1706 * elf32-sh.c (R_SH_GOT32, R_SH_PLT32, R_SH_COPY, R_SH_GLOB_DAT,
1707 R_SH_JMP_SLOT, R_SH_RELATIVE, R_SH_GOTOFF, R_SH_GOTPC): New.
1708 (sh_reloc_map): Add new relocs.
1709 (sh_elf_check_relocs, sh_elf_link_hash_newfunc,
1710 sh_elf_link_hash_table_create, sh_elf_adjust_dynamic_symbol,
1711 sh_elf_size_dynamic_sections, sh_elf_finish_dynamic_symbol,
1712 sh_elf_finishe_dynamic_sections, sh_elf_discard_copies): New
1714 (ELF_DYNAMIC_INTERPRETER, PLT_ENTRY_SIZE): Define.
1715 (elf_sh_plt0_entry_be, elf_sh_plt0_entry_le,
1716 elf_sh_plt_entry_be, elf_sh_plt_entry_le,
1717 elf_sh_pic_plt_entry_be, elf_sh_pic_plt_entry_le):
1718 New array constants.
1719 (elf_sh_plt0_entry, elf_sh_plt_entry, elf_sh_pic_plt_entry):
1721 (elf_sh_sizeof_plt, elf_sh_plt_plt0_offset,
1722 elf_sh_plt0_linker_offset, elf_sh_plt0_gotid_offset,
1723 elf_sh_plt_temp_offset, elf_sh_plt_symbol_offset,
1724 elf_sh_plt_reloc_offset): Define.
1725 (elf_sh_pcrel_relocs_copied, elf_sh_link_hash_entry,
1726 elf_sh_link_hash_table): New structs.
1727 (sh_elf_link_hash_traverse, sh_elf_hash_table): New macros.
1728 (sh_elf_relocate_section, sh_elf_check_relocs): Handle new
1730 (elf_backend_create_dynamic_sections,
1731 bfd_elf32_bfd_link_hash_table_create,
1732 elf_backend_adjust_dynamic_symbol,
1733 elf_backend_size_dynamic_sections,
1734 elf_backend_finish_dynamic_symbol,
1735 elf_backend_finish_dynamic_sections, elf_backend_want_got_plt,
1736 elf_backend_plt_readonly, elf_backend_want_plt_sym,
1737 elf_backend_got_header_size, elf_backend_plt_header_size):
1739 * reloc.c (BFD_RELOC_SH_COPY, BFD_RELOC_SH_GLOB_DAT,
1740 BFD_RELOC_SH_JMP_SLOT, BFD_RELOC_SH_RELATIVE, BFD_RELOC_SH_GOTPC):
1742 * bfd-in2.h, libbfd.h: Rebuilt.
1746 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Revert 2000-08-27
1751 * elf32-sh.c (sh_elf_merge_private_data): If ibfd's elf header flags
1752 not initialized, set them to indicate the SH1 instruction set.
1756 * acinclude.m4: Include libtool and gettext macros from the
1758 * aclocal.m4, configure: Rebuilt.
1762 * elf.c: Eliminate references to __sparcv9 macro; replace with
1763 autoconf variables HAVE_PSINFO32_T etc.
1764 * configure.in: Auto-configure HAVE_PSINFO_32_T, HAVE_PRPSINFO32_T,
1765 HAVE_PSTATUS32_T, HAVE_PRSTATUS32_T, HAVE_PRSTATUS32_T_PR_WHO.
1767 * acinclude.m4 (BFD_HAVE_SYS_PROCFS_TYPE) define _SYSCALL32 so it can
1768 detect the above typedefs. (BFD_HAVE_SYS_PROCFS_TYPE_MEMBER): Ditto.
1769 * aclocal.m4: Ditto.
1770 * configure: Regenerate.
1774 * elf32-i386.c (elf_i386_check_relocs): Keep info on relocs copied
1775 for any shared link, not just shared -Bsymbolic.
1776 (elf_i386_size_dynamic_sections): Call elf_i386_discard_copies on
1777 any shared link, and pass link info to it.
1778 (elf_i386_size_dynamic_sections): Update comment.
1779 (elf_i386_discard_copies): Modify to discard relocs for symbols
1780 that have been forced local.
1781 (elf_i386_finish_dynamic_symbol): Don't copy relocs for symbols
1782 that have been forced local.
1786 * elflink.h (elf_link_add_object_symbols): Allow common
1787 symbols to have an alignment of 1 if explicitly requested, and
1788 not overridden by other definitions.
1792 * coff-w65.c (CREATE_LITTLE_COFF_TARGET): Fix typo.
1793 * coffcode.h (coff_set_flags): Add detection of w65 architecture.
1797 * elf-bfd.h (elf_link_hash_table): Add runpath.
1799 * bfd-in.h (bfd_elf_get_runpath_list): New prototype.
1800 * bfd-in2.h: Rebuilt.
1802 * elf.c (_bfd_elf_link_hash_table_init): Initialize the
1803 "runpath" field to NULL.
1804 (bfd_elf_get_runpath_list): New function.
1806 * elflink.h (elf_link_add_object_symbols): Record DT_RPATH and
1811 * elf32-sh.c (sh_elf_relocate_section) [R_SH_IND12W,
1812 R_SH_DIR8WPN, R_SH_DIR8WPZ, R_SH_DIR8WPL]: Handle them
1813 explicitly. Improve validation of r_type.
1817 * elf32-i386.c (elf_i386_size_dynamic_sections): Zero out the
1818 dynamic allocated content space. Add a comment to remind us that
1819 one day this ought to be fixed.
1820 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
1821 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
1822 * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
1826 * elf32-i860.c (elf32_i860_relocate_pc16): Just write the immediate
1827 field with the newly relocated value instead of adding it to the
1828 existing immediate field.
1829 (elf32_i860_relocate_splitn): Likewise.
1830 (elf32_i860_relocate_highadj): Likewise.
1834 * elf32-i860.c (elf32_i860_relocate_pc16): Implemented function (it
1835 was previously just a stub).
1839 * elflink.c (_bfd_elf_create_got_section): Don't abort().
1841 (_bfd_elf_create_dynamic_sections): Likewise.
1845 * elf64-sparc.c (sparc64_elf_relocate_section): Set relocation address
1846 for undefined symbols to be the beginning of the section.
1848 * elf64-sparc.c (sparc64_elf_adjust_dynamic_symbol): Don't allocate
1849 four extra entries at the beginning of the .rela.plt section.
1850 (sparc64_elf_finish_dynamic_symbol): Adjust the offset in the .rela.plt
1851 section to account for the four reserved entries in the .plt section.
1855 * xcofflink.c (_bfd_ppc_xcoff_relocate_section): Add ori r0,r0,0
1856 to the list of NOPs we recognize after a branch-and-link.
1857 Use the ori NOP when one is needed.
1859 * coff-rs6000.c (_bfd_xcoff_slurp_armap): Finish implementation
1864 * elf64-ia64.c (elf64_ia64_merge_private_bfd_data): Handle
1865 EF_IA_64_REDUCEDFP, EF_IA_64_CONS_GP, and EF_IA_64_NOFUNCDESC_CONS_GP.
1866 (elf64_ia64_print_private_bfd_data): Likewise. Also handle
1871 * elf32-sh.c (sh_elf_set_mach_from_flags): Make it static.
1875 * elf32-i860.c (elf32_i860_relocate_section): New function.
1876 (i860_final_link_relocate): New function.
1877 (elf32_i860_relocate_splitn): New function.
1878 (elf32_i860_relocate_pc16): New function.
1879 (elf32_i860_relocate_highadj): New function.
1880 (elf32_i860_howto): Minor adjustments to some relocations.
1881 (elf_info_to_howto_rel): Define.
1882 (elf_backend_relocate_section): Define.
1886 * elf32-arm.h: Fix formatting.
1890 * elf32-sh.c (sh_elf_reloc_loop): Make LAST_SYMBOL_SECTION static.
1894 * elf32-i860.c (elf32_i860_howto_table): Updated some fields.
1898 * ieee.c (ieee_write_debug_part): Rewrite a comment.
1899 * elf64-ia64.c: Fix a typo.
1903 * elf32-i860 (elf32_i860_howto_table): New structure.
1904 (lookup_howto): New function.
1905 (elf32_i860_reloc_type_lookup): New function.
1906 (elf32_i860_info_to_howto_rela): New function.
1907 (elf_code_to_howto_index): New structure.
1908 (elf_info_to_howto): Re-define as elf32_i860_info_to_howto_rela.
1909 (bfd_elf32_bfd_reloc_type_lookup): Re-define as
1910 elf32_i860_reloc_type_lookup.
1914 * som.c (struct fixup_format): Constify `format'.
1915 (som_hppa_howto_table): Use SOM_HOWTO macro.
1916 (try_prev_fixup, hppa_som_reloc): Decorate unused parameter.
1917 (som_bfd_reloc_type_lookup): Likewise.
1918 (compare_subspaces): Remove unused `count1', `count2'.
1919 (som_begin_writing): Remove unused `total_reloc_size'.
1920 (som_bfd_derive_misc_symbol_info): Decorate unused parameter.
1921 (som_print_symbol, som_bfd_is_local_label_name): Likewise.
1922 (som_set_reloc_info): Constify `cp'. Remove unused `addend'.
1923 (som_find_nearest_line): Decorate unused parameter(s).
1924 (som_sizeof_headers, som_get_symbol_info, som_write_armap): Likewise.
1925 (som_bfd_link_split_section): Likewise.
1929 * section.c: Restore backed out code.
1930 * elf.c: Restore backed out code.
1931 (copy_private_bfd_data): Fix bug preventing stipped dynamic
1932 binaries from working.
1933 * bfd-in2.h: Regenerate.
1937 * section.c: Back out the change made by Nick Clifton
1940 * bfd-in2.h: Likewise.
1945 * elf32-sh.c (sh_elf_reloc_loop): Warning removal.
1949 * reloc.c (BFD_RELOC_860_*): New bfd relocs for i860.
1950 * bfd-in2.h, libbfd.h: Regenerate.
1954 * section.c (struct sec): Add new boolean field 'segment_mark'.
1955 (STD_SECTION): Initialise new field to zero.
1957 * bfd-in2.h: Regenerate.
1959 * elf.c (copy_private_bfd_data): Reorganise section to segment
1960 mapping to cope with moved sections requiring new segments,
1961 and overlapping segments.
1962 (SEGMENT_END): New macro: Return the end address of a segment.
1963 (IS_CONTAINED_BY_VMA): New macro: Determine if a segment
1964 contains a section by comparing their VMA addresses.
1965 (IS_CONTAINED_BY_LMA): New macro: Determine if a segment
1966 contains a section by comparing their LMA addresses.
1967 (INCLUDE_SECTION_IN_SEGMENT): New macro: Determine if a
1968 section should be included in a segment.
1969 (SEGMENT_AFTER_SEGMENT): New macro: Determine if one segment
1970 follows another in memory.
1971 (SEGMENT_OVERLAPS_SEGMENT): New macro: Determine if two
1976 * cpu-i860.c: Added comments.
1978 * elf32-i860.c (TARGET_LITTLE_SYM): Defined to
1979 bfd_elf32_i860_little_vec.
1980 (TARGET_LITTLE_NAME): Defined to "elf32-i860-little".
1981 (ELF_MAXPAGESIZE): Changed to 4096.
1983 * targets.c (bfd_elf32_i860_little_vec): Declaration of
1985 (bfd_target_vector): Added bfd_elf32_i860_little_vec.
1987 * config.bfd (i860-stardent-sysv4*, i860-stardent-elf*): Added
1988 config for little endian elf32 i860.
1989 (targ_defvec): Define for the new config above
1990 as "bfd_elf32_i860_little_vec".
1991 (targ_selvecs): Define for the new config above
1992 as "bfd_elf32_i860_vec bfd_elf32_i860_little_vec"
1994 * configure.in (bfd_elf32_i860_little_vec): Added recognition
1997 * configure: Regenerated.
2001 * elflink.h (elf_merge_symbol): Take one more argument,
2002 dt_needed, to indicate if the symbol comes from a DT_NEEDED
2003 entry. Don't overide the existing weak definition if dt_needed
2005 (elf_link_add_object_symbols): Pass dt_needed to
2006 elf_merge_symbol ().
2010 * elflink.h (elf_link_size_reloc_section): Zeroes the section's
2015 * configure.host (*-*-aix*): AIX has 'long long' always.
2017 * coff-rs6000.c (xcoff_write_one_armap_big): New procedure.
2018 (xcoff_write_armap_big): Write both 32-bit and 64-bit armaps.
2019 (xcoff_write_archive_contents_big): Don't update the offset
2020 of the symbol table, xcoff_write_armap will do it.
2024 * elf32-mips.c (_bfd_mips_elf_check_relocs): Use abfd instead
2025 of dynobj for SGI_COMPAT checks.
2029 * coff-m68k.c (bfd_m68k_coff_create_embedded_relocs): New function.
2030 * bfd-in.h (bfd_m68k_coff_create_embedded_relocs): Add declaration.
2031 * bfd-in2.h: Regenerate.
2035 * elf32-mips.c (_bfd_mips_elf_check_relocs): Detect out of
2036 range symbol indices in relocs and issue an error message.
2040 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Don't check
2041 info->new_dtags when setting DT_FLAGS_1. It will only be set
2042 by the new linker options. It shouldn't break anything.
2046 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set DT_FLAGS_1
2047 only if info->new_dtags is true.
2051 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set
2052 DT_RUNPATH and DT_FLAGS only if info->new_dtags is true.
2056 * Makefile.am (ALL_MACHINES): Add cpu-cris.lo.
2057 (ALL_MACHINES_CFILES): Add cpu-cris.c.
2058 (BFD32_BACKENDS): Add aout-cris.lo and elf32-cris.lo.
2059 (BFD32_BACKENDS_CFILES): Add aout-cris.c and elf32-cris.c.
2060 (cpu-cris.lo, aout-cris.lo, elf32-cris.lo): New rules.
2061 * Makefile.in: Rebuild.
2062 * aclocal.m4: Rebuild.
2063 * aoutx.h (NAME(aout,machine_type)): Add case for bfd_arch_cris.
2064 * archures.c (enum bfd_architecture): Add bfd_arch_cris.
2065 (bfd_cris_arch): Declare.
2066 (bfd_archures_list): Add bfd_cris_arch.
2067 * bfd-in2.h: Rebuild.
2068 * config.bfd: (cris-*-*): New target.
2069 * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vectors.
2070 * configure: Rebuild.
2071 * elf.c (prep_headers): Add bfd_arch_cris.
2072 * libbfd.h: Rebuild.
2073 * libaout.h (enum machine_type): Add M_CRIS.
2074 * reloc.c: Add CRIS relocations.
2075 * targets.c (bfd_elf32_cris_vec, cris_aout_vec): Declare.
2076 (bfd_target_vect): Add bfd_elf32_cris_vec and cris_aout_vec.
2077 * cpu-cris.c, aout-cris.c, elf32-cris.c: New files.
2078 * po/POTFILES.in, po/bfd.pot: Regenerate.
2082 * elf32-arm.h (elf32_arm_size_dynamic_sections): Also set
2083 DF_TEXTREL if DT_TEXTREL is set.
2084 * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise.
2085 * elf32-i386.c (elf_i386_size_dynamic_sections): Likewise.
2086 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
2087 * elf32-mips.c (_bfd_mips_elf_size_dynamic_sections): Likewise.
2088 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise.
2089 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
2090 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Likewise.
2091 * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
2092 * elf64-ia64.c (elf64_ia64_size_dynamic_sections): Likewise.
2093 * elf64-sparc.c (sparc64_elf_size_dynamic_sections): Likewise.
2095 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Also
2096 set DF_SYMBOLIC for symbolic link. Also set DT_RUNPATH if
2098 Set the DT_FLAGS and DT_FLAGS_1 entries if necessary.
2102 * bfd-in.h (bfd_elf_set_dt_needed_soname): New.
2103 * bfd-in2.h: Rebuild.
2105 * elf-bfd.h (elf_obj_tdata): Add dt_soname.
2106 (elf_dt_soname): New.
2108 * elf.c (bfd_elf_set_dt_needed_soname): New.
2110 * elflink.h (elf_link_add_object_symbols): Add the DT_NEEDED
2111 entry if the shared object loaded by DT_NEEDED is used to
2112 resolve the reference in a regular object.
2116 * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_CONFIG,
2117 DT_DEPAUDIT and DT_AUDIT as strings.
2121 * format.c: Fix formatting.
2125 * elf.c (_bfd_elf_print_private_bfd_data): Fix DT_CHECKSUM.
2129 * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_BIND_NOW,
2130 DT_INIT_ARRAY, DT_FINI_ARRAY, DT_INIT_ARRAYSZ, DT_FINI_ARRAYSZ,
2131 DT_RUNPATH, DT_FLAGS, DT_PREINIT_ARRAY, DT_PREINIT_ARRAYSZ,
2132 DT_PLTPADSZ, DT_MOVEENT, DT_MOVESZ, DT_FEATURE, DT_POSFLAG_1,
2133 DT_SYMINSZ, DT_SYMINENT, DT_CONFIG, DT_DEPAUDIT, DT_AUDIT,
2134 DT_PLTPAD, DT_MOVETAB, DT_SYMINFO, DT_RELACOUNT, DT_RELCOUNT,
2135 DT_FLAGS_1, DT_USED and DT_CHECKSUM.
2139 * elf.c (bfd_elf_get_sign_extend_vma, bfd_elf_get_arch_size): Move
2140 renamed functions from here...
2141 (assign_section_numbers): Use renamed functions.
2142 (prep_headers): Use renamed functions.
2144 * bfd.c (bfd_get_sign_extend_vma, bfd_get_arch_size): ...To here.
2145 * bfd-in.h (bfd_get_sign_extend_vma, bfd_get_arch_size): Update.
2146 * bfd-in2.h: Regenerate.
2150 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Add
2151 parenthesis in if statement.
2155 Enable the support for Traditional MIPS.
2156 * elf32-mips.c (IRIX_COMPAT): Recognize bfd_elf32_tradbigmips_vecand
2157 return ict_none appropriately for traditional mips targets.
2158 (STUB_LW): Change 0x8f998000 to 0x8f998010 for traditional mips.
2159 (STUB_MOVE): Conditionalize for traditonal mips.
2160 (STUB_LI16): Likewise.
2161 (_bfd_mips_elf_modify_segment_map): Conditionalize to avoid making
2162 room for RTPROC header.
2163 (_bfd_mips_elf_modify_segment_map): For a normal mips executable set
2164 the permission for the PT_DYNAMIC as read, write and execute.
2165 (mips_elf_calculate_relocation): Check for the symbol _DYNAMIC_LINKING
2166 for traditonal mips.
2167 (_bfd_mips_elf_create_dynamic_sections): Add the symbol
2168 _DYNAMIC_LINKING for traditonal mips.
2169 (_bfd_mips_elf_create_dynamic_sections): Add the symbol __RLD_MAP
2170 in case of traditonal mips.
2171 (_bfd_mips_elf_adjust_dynamic_symbol): Create a stub only if a PLT
2172 entry is required. For a function if PLT is not required then set the
2173 corresponding hash table entry to 0.
2174 (_bfd_mips_elf_size_dynamic_sections): Add DT_DEBUG entry for
2176 (_bfd_mips_elf_finish_dynamic_symbol): for a undefined symbol in a
2177 shared object set the value to 0.
2178 (_bfd_mips_elf_finish_dynamic_symbol): Check for the symbol
2179 _DYNAMIC_LINKING for traditonal mips.
2180 (_bfd_mips_elf_finish_dynamic_symbol): Check for the symbol __RLD_MAP
2181 for traditonal mips.
2185 * aoutx.h (translate_to_native_sym_flags): Handle BSF_LOCAL.
2189 * libbfd.c (bfd_seek): fix 'seek beyond EOF' error when writing
2190 out a structure that is BFD_IN_MEMORY.
2194 * elf64-hppa.c (get_dyn_name): Pass in section pointer instead of
2195 bfd pointer. Print section id instead of bfd pointer for local
2196 syms. Prefix addend with `+' for global syms as well as local.
2197 Correct calculation of name component lengths.
2198 (elf64_hppa_check_relocs): Update call to get_dyn_name.
2201 * elf-hppa.h (elf_hppa_relocate_section): Update calls here too.
2202 * elf64-hppa.c (elf64_hppa_check_relocs): Fix some warnings.
2203 (elf64_hppa_modify_segment_map): Likewise.
2207 * elf.c (bfd_elf_get_sign_extend_vma): Return tendency of VMA
2208 addresses to be "naturally" sign extended. Return -1 if unknown.
2209 * bfd-in.h (bfd_elf_get_sign_extend_vma): Add declaration.
2210 * bfd-in2.h: Regenerate.
2214 * ecoffswap.h (ecoff_get_off, ecoff_put_off): Add ECOFF_SIGNED_32
2215 and ECOF_SIGNED_64 to list ways to extract an offset.
2216 (ecoff_swap_fdr_in, ecoff_swap_fdr_out, ecoff_swap_pdr_in,
2217 ecoff_swap_pdr_out, ecoff_swap_ext_in, ecoff_swap_ext_out):
2219 * elf64-mips.c (ECOFF_SIGNED_64): Define instead of ECOFF_64.
2220 * elf32-mips.c (ECOFF_SIGNED_32): Define instead of ECOFF_32.
2224 * elfcode.h (elf_object_p): Use bfd_set_start_address and not
2225 bfd_get_start_address.
2226 (elf_swap_ehdr_in): Sign extend e_entry when applicable.
2227 (elf_swap_ehdr_out): Ditto.
2231 * archures.c (bfd_default_scan): Add set of bfd_mach_ cases for
2232 compatibility with older binutils.
2236 * section.c (bfd_make_section_anyway): Start section_id at 0x10.
2237 (STD_SECTION): Avoid negative ids, instead use 0 to 3.
2240 * dwarf1.c (parse_die): Cure signed/unsigned char warnings.
2241 (parse_line_table): Ditto.
2242 (_bfd_dwarf1_find_nearest_line): Ditto.
2243 * syms.c (cmpindexentry): Remove extra `*' from params.
2247 * elf32-mips.c (sort_dynamic_relocs): New Function.
2248 (_bfd_mips_elf_finish_dynamic_sections): Call sort_dynamic_relocs
2249 via qsort to sort the dynamic relocations in increasing r_symndx
2254 * elf64-hppa.c (elf64_hppa_dyn_hash_table_init): Add
2255 ATTRIBUTE_UNUSED to unused args.
2256 (get_opd): Likewise.
2257 (get_plt): Likewise.
2258 (get_dlt): Likewise.
2259 (get_stub): Likewise.
2260 (elf64_hppa_adjust_dynamic_symbol): Likewise.
2261 (elf64_hppa_link_output_symbol_hook): Likewise.
2262 (elf64_hppa_check_relocs): Delete unused var.
2263 (elf64_hppa_size_dynamic_sections): Likewise.
2264 (elf64_hppa_finalize_opd): Likewise.
2265 (elf64_hppa_finalize_dynreloc): Likewise.
2266 (elf64_hppa_modify_segment_map): Likewise.
2267 (elf64_hppa_finish_dynamic_sections): Likewise.
2269 * elf-hppa.h (elf_hppa_final_write_processing): Add
2270 ATTRIBUTE_UNUSED to unused args.
2271 (elf_hppa_final_link_relocate): Likewise.
2272 (elf_hppa_record_segment_addrs): Add paretheses.
2273 (elf_hppa_relocate_section): Constify dyn_name.
2276 * config.bfd: Add hppa*64*-*-linux-gnu 64-bit target, and
2277 rearrange case statement so that it gets preferred to 32-bit ones.
2279 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Use
2280 asection->id instead of address of asection structure.
2281 (elf32_hppa_size_stubs): Likewise.
2283 * elf32-hppa.c (elf32_hppa_size_stubs): Use just one stub section
2284 for .init* and .fini*.
2286 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Mask pointers
2287 and addends used in stub names to 32 bits.
2288 (elf32_hppa_size_stubs): Likewise.
2290 * elf-hppa.h (elf_hppa_final_link_relocate): Don't sum addend
2291 twice for R_PARISC_GPREL64. Use bfd_put_32 for R_PARISC_PCREL32,
2292 not bfd_put_64. Fix minor comment typo and formatting.
2294 Changes to create multiple linker stubs, positioned immediately
2295 before the section where they are required.
2296 * elf32-hppa.c: Don't include hppa_stubs.h.
2297 (elf32_hppa_stub_hash_entry): Add a pointer to the stub section.
2298 (elf32_hppa_stub_hash_table): Delete.
2299 (elf32_hppa_link_hash_entry): Delete.
2300 (elf32_hppa_link_hash_table): Use plain bfd_hash_table for
2301 stub_hash_table, and store the struct here rather than a pointer.
2302 Delete output_symbol_count. Add offset array. Change
2303 global_value to a bfd_vma.
2304 (elf32_hppa_stub_hash_lookup): Use table instead of table->root.
2305 (elf32_hppa_stub_hash_traverse): Delete.
2306 (elf32_hppa_name_of_stub): Delete.
2307 (elf32_hppa_link_hash_lookup): Delete.
2308 (elf32_hppa_link_hash_traverse): Delete.
2309 (elf32_hppa_stub_hash_table_init): Delete.
2310 (elf32_hppa_size_of_stub): Pass input section and offset rather
2311 than location and calculate location here. Don't pass name as all
2312 stubs are now the same size.
2313 (elf32_hppa_stub_hash_newfunc): Init new fields.
2314 (elf32_hppa_link_hash_table_create): Likewise, and stub_hash_table
2316 (elf32_hppa_bfd_final_link_relocate): Cast enums to int before
2317 comparing against ints. Rewrite stub handling code.
2318 (elf32_hppa_relocate_section): Make r_type and r_symndx unsigned.
2319 Case enums to int before comparing against ints. Remove
2320 bfd_reloc_dangerous case.
2321 (elf32_hppa_build_one_stub): Rewrite.
2322 (elf32_hppa_size_one_stub): New function.
2323 (elf32_hppa_build_stubs): Rewrite.
2324 (elf32_hppa_size_stubs): Pass in linker call-back functions.
2325 Rewrite stub-handling specific code.
2327 * elf32-hppa.h (elf32_hppa_size_stubs): Update prototype.
2329 * elf64-hppa.c (elf64_hppa_dyn_hash_entry): Fix a comment typo.
2331 * hppa_stubs.h: Delete.
2332 * Makefile.am (SOURCE_HFILES): Remove hppa_stubs.h
2333 (elf32-hppa.lo): Remove hppa_stubs.h from dependencies.
2334 * Makefile.in: Regenerate.
2336 * elf-hppa.h (_bfd_elf_hppa_gen_reloc_type): Handle e_nlsel and
2339 * libhppa.h (hppa_field_adjust): Correct e_nsel case.
2341 * elf32-hppa.c (elf32_hppa_relocate_section): Mention the offset
2342 and section name for bfd_reloc_notsupported error message.
2343 (elf32_hppa_bfd_final_link_relocate): Print reasons for returning
2344 bfd_reloc_notsupported.
2345 (elf32_hppa_relocate_section): Add ATTRIBUTE_UNUSED to output_bfd.
2347 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Handle
2348 undefined weak symbols for all relocs.
2349 (elf32_hppa_size_of_stub): Adjust calculation by 8 since branch
2350 offsets are relative to one past the delay slot.
2351 (elf32_hppa_size_stubs): Account for reloc addend when calculating
2352 branch destination. Put addend into stub name too.
2353 (elf32_hppa_bfd_final_link_relocate): Account for reloc addend and
2354 adjust by 8 when deciding whether a linker stub is needed. Put
2355 addend into stub name as for above.
2357 * elf32-hppa.c (hppa_elf_relocate_insn): Change signed/unsigned on
2358 various args and vars.
2359 (elf32_hppa_bfd_final_link_relocate): Here too.
2360 (elf32_hppa_size_stubs): Rename index -> indx. Use e_indx for
2361 inner block var to avoid shadowing.
2363 * elf32-hppa.h (_bfd_elf32_hppa_gen_reloc_type): Make `field' arg
2365 * elf64-hppa.h (_bfd_elf64_hppa_gen_reloc_type): Ditto.
2366 * elf-hppa.h (_bfd_elf_hppa_gen_reloc_type): Ditto.
2367 (elf_hppa_fake_sections): Rename local var to avoid shadowing.
2369 * libhppa.h: Change practically all unsigned ints to plain ints.
2370 Remove tests on gcc version. Instead use ATTRIBUTE_UNUSED for
2374 * libhppa.h (hppa_opcode_type): New enum to replace #define's.
2375 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Modify to
2378 * elf-hppa.h (elf_hppa_relocate_insn): Update the opcode constants
2379 to the new OP_* ones.
2381 * elf32-hppa.c (elf32_hppa_size_stubs): Consolidate freeing on
2382 error exit. Bail out earlier on plabel relocs that we aren't
2383 interested in. Don't tell elf32_hppa_stub_hash_lookup to copy
2384 string, and then don't free our copy.
2385 (elf32_hppa_build_one_stub): Make insn unsigned int.
2387 * libhppa.h (bfd_hppa_insn2fmt): 22 bit branches are only
2388 available with BL, not BE and BLE.
2390 * elf32-hppa.c (hppa_elf_relocate_insn): Add some more example
2391 code for elf arg relocs.
2392 (elf32_hppa_bfd_final_link_relocate): Replace boolean is_local
2393 argument with elf_link_hash_entry h. Handle undefined weak
2394 symbols. Move $global$ lookup from here...
2395 (elf32_hppa_relocate_section): ...to here. Return correct error
2396 message for non-handled relocs.
2397 (elf32_hppa_size_of_stub): Correctly test branch range. Previous
2398 wrong test was -0x3ffff to +0x40000.
2400 * elf-hppa.h (elf_hppa_final_link_relocate): R_PARISC_DIR17R,
2401 R_PARISC_DIR17F, and R_PARISC_DIR21L are for absolute branches;
2402 Handle them as such.
2403 (elf_hppa_relocate_insn): Fix a typo.
2405 * libhppa.h (GET_FIELD, GET_BIT, MASK, CATENATE, ELEVEN): Delete.
2406 (assemble_3, assemble_6, assemble_12, assemble_16, assemble_16a,
2407 assemble_17, assemble_21): Delete.
2408 Supply defines for all 64 possible opcodes.
2409 (bfd_hppa_insn2fmt): Add bfd argument, and use to select wide mode
2410 formats. Handle COMICLR.
2411 (hppa_rebuild_insn): Delete bfd argument. Handle formats 10, -11,
2414 * elf32-hppa.c (hppa_elf_relocate_insn): Complete rewrite.
2415 (elf32_hppa_bfd_final_link_relocate): Major rewrite.
2416 (elf32_hppa_build_one_stub): Modify hppa_elf_relocate_insn calls
2418 (elf32_hppa_size_stubs): Don't free stub_name twice. Read in all
2419 the local syms - did this code get deleted accidentally? Ignore
2420 undefined and undefweak syms.
2422 * elf-hppa.h (elf_hppa_final_link): Move hppa_info to outermost
2423 block. Use it instead of elf64_hppa_hash_table (info).
2424 (elf_hppa_final_link_relocate): Use hppa_info instead of
2425 elf64_hppa_hash_table (info).
2427 * libhppa.h (re_assemble_3, re_assemble_12, re_assemble_16,
2428 re_assemble_17, re_assemble_21, re_assemble_22): Don't mask insn.
2429 (hppa_rebuild_insn): Mask immediate bits here instead.
2430 * elf-hppa.h (elf_hppa_relocate_insn): Mask here too.
2434 * section.c (struct sec): Add id field. Tidy comment formatting.
2435 (bfd_make_section_anyway): Set id.
2436 (STD_SECTION): Init id too.
2437 Change CONST to const throughout.
2438 * archures.c (bfd_arch_info): Tidy comment.
2439 (bfd_arch_list): Change a CONST to const.
2440 * libbfd-in.h: Tidy comments and replace CONST with const.
2441 * elf-bfd.h: Likewise.
2442 * libbfd.h: Regenerate.
2443 * bfd-in2.h: Regenerate.
2444 * libcoff.h: Regenerate.
2448 * archive.c (_bfd_write_archive_contents): Add an informative
2453 * srec.c: Fix formatting.
2461 * coff-arm.c (coff_arm_relocate_section): Do not ignore the symbol
2462 value of PC-relative offsets.
2466 * elf64-alpha.c (alpha_elf_size_info): New.
2467 (elf_backend_size_info): Define to alpha_elf_size_info.
2468 * elfcode.h (elf_size_info): Change hash bucket size to 4.
2472 * elf32-mips.c: Include elf32-target.h again for the traditional
2477 * elf32-avr.c (bfd_elf32_bfd_reloc_type_lookup):
2478 Add ATTRIBUTE_UNUSED to unused arguments to avoid warnings.
2479 (avr_info_to_howto_rela): Likewise.
2480 (elf32_avr_gc_mark_hook): Likewise.
2481 (elf32_avr_gc_sweep_hook): Likewise.
2482 (elf32_avr_relocate_section): Likewise.
2486 * cofflink.c (_bfd_coff_write_global_sym): Turn a weak symbol into
2487 an external symbol for a non-shared, non-relocatable link.
2491 * cofflink.c (IS_EXTERNAL): New macro: Return true if the symbol
2492 is an external symbol.
2493 (IS_WEAK_EXTERNAL): New macro: Return true if the symbol is a weak
2498 * reloc16.c: Fix formatting.
2502 * config.bfd: Change targ_defvec and targ_selvecs for mips*-*-sysv4*
2503 to add a new target for traditional mips i.e
2504 bfd_elf32_tradbigmips_vec and bfd_elf32_tradlittlemips_vec.
2505 * configure.in: Likewise.
2506 * configure: Rebuild.
2507 * targets.c (bfd_elf32_tradbigmips_vec): Declare and put in
2509 (bfd_elf32_tradlittlemips_vec): Likewise.
2510 * elfxx-target.h: Add macro INCLUDED_TARGET_FILE which is more a test
2511 to see that elfNN_bed does not get redefined even if the target file
2512 is included twice for a chip. See elf32-mips.c.
2516 * Makefile.am (DEP): Fix 2000-06-22. grep after running dep.sed
2517 (CLEANFILES): Add DEPA.
2518 * Makefile.in: Regenerate.
2522 * peicode.h (coff_swap_filehdr_in): can't use e_magic because we
2523 can't assume the PE header is at 0x80.
2527 * syms.c (_bfd_stab_section_find_nearest_line): Use IS_ABSOLUTE_PATH.
2531 * go32stub.h: Update stub.
2535 * archures.c (bfd_mach_avr5): Define.
2536 * bfd-in2.h (bfd_mach_avr5): Define.
2537 * cpu-avr.c (arch_info_struct): Rename bfd_mach_avr4 to
2538 bfd_mach_avr5, add bfd_mach_avr4. Update comments.
2539 (compatible): Update comment. Add missing test.
2540 * elf32-avr.c (avr_final_link_relocate): Support 8K wrap
2541 for avr2 and avr4. Simplify 8K wrap code.
2542 (bfd_elf_avr_final_write_processing): Recognize bfd_mach_avr5.
2543 (elf32_avr_object_p): Recognize E_AVR_MACH_AVR5.
2547 * coff-h8300.c: Fix formatting.
2548 * cpu-h8300.c: Likewise.
2552 * elf32-arm.h (elf32_arm_final_link_relocate): Print `(local)'
2553 for local symbols whose names are unknown.
2557 * Makefile.am (DEP): grep for leading `/' in DEP1, and fail if we
2559 * Makefile.in: Regenerate.
2560 * doc/Makefile.in: Regenerate.
2564 * Makefile.am: Rebuild dependency.
2565 * Makefile.in: Rebuild.
2569 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): New function.
2570 (elf_backend_copy_indirect_symbol): Map to the new function.
2574 * archive.c (normalize): Correct pointer comparison when checking
2576 (bfd_bsd_truncate_arname): Likewise.
2577 (bfd_gnu_truncate_arname): Likewise.
2581 * elf-bfd.h (struct elf_obj_tdata): Define per BFD Irix 5 virtual
2582 sections elf_{text,data}_{section,symbol}.
2583 * elf32-mips.c: mips_elf_{text,data}_{section,symbol}{,_ptr}: Remove.
2584 (_bfd_mips_elf_hide_symbol): New function.
2585 (elf_backend_hide_symbol): Map to the new function.
2586 (_bfd_mips_elf_add_symbol_hook): Change to use new per BFD
2587 definitions of mips_elf_{text,data}_{section,symbol}.
2588 (mips_elf_local_relocation_p): Try to find the direct symbol
2589 based on new check_forced argument.
2590 (mips_elf_calculate_relocation): Use new version of
2591 mips_elf_local_relocation_p.
2592 (mips_elf_relocate_section): Likewise.
2593 (_bfd_mips_elf_relocate_section): Likewise.
2594 (mips_elf_sort_hash_table): Only assert that have enough GOT
2596 (mips_elf_got16_entry): Match all 32 bits to the existing GOT
2597 entry if the relocation based on the new external argument.
2598 (mips_elf_create_dynamic_relocation): Assert that we have a
2599 section contents allocated where we can swap out the dynamic
2601 (mips_elf_calculate_relocation): Find the real hash-table entry
2602 correctly by using h->root.root.type. Only create a dynamic
2603 relocation entry if the symbol is defined in a shared library.
2604 Create an external GOT entry for the GOT16 relocation if the
2605 symbol was forced local.
2606 (_bfd_mips_elf_finish_dynamic_symbol): Don't assert there is a
2607 dynamic index if the symbol was forced local.
2611 * elf32-mips.c: Fix typos in comments.
2615 * rs6000-core.c: Wrap definition of `union VmInfo' within #ifdef
2620 * Makefile.in, bfd-in2.h, libbfd.h, configure: Rebuild.
2621 * Makefile.am (ALL_MACHINES, ALL_MACHINES_CFILES, BFD32_BACKENDS,
2622 BFD32_BACKENDS_CFILES): Add 68hc12, 68hc11 files.
2623 * configure.in (bfd_elf32_m68hc12_vec): Recognize.
2624 (bfd_elf32_m68hc11_vec): Likewise.
2625 * config.bfd (targ_cpu): Recognize 68hc12 and 68hc11.
2626 Supports 68hc11 & 68hc12 at the same time.
2627 * targets.c (bfd_elf32_m68hc12_vec): Declare and put in
2629 (bfd_elf32_m68hc11_vec): Likewise.
2630 * elf.c (prep_headers): Recognize bfd_arch_m68hc12 and 68hc11.
2631 * archures.c (bfd_m68hc12_arch): Define and register in global list
2632 (bfd_m68hc11_arch): Likewise.
2633 * reloc.c (BFD_RELOC_M68HC11_HI8, BFD_RELOC_M68HC11_LO8,
2634 BFD_RELOC_M68HC11_3B): Define.
2635 * cpu-m68hc12.c, elf32-m68hc12.c: New files for 68hc12 support.
2636 * cpu-m68hc11.c, elf32-m68hc11.c: New files for 68hc11 support.
2640 * elf_bfd.h (struct elf_backend_data): Add info argument to
2641 elf_backend_hide_symbol.
2642 (_bfd_elf_link_hash_hide_symbol): Likewise.
2643 * elf.c (_bfd_elf_link_hash_hide_symbol): Likewise.
2644 * elf64-ia64.c (elf64_ia64_hash_hide_symbol): Likewise.
2645 * elflink.h (elf_link_add_object_symbols): Likewise.
2646 (elf_link_assign_sym_version): Likewise.
2650 * coff-i386.c (coff_i386_reloc): Don't return in case of
2651 output_bfd == (bfd *) NULL if COFF_WITH_PE is defined.
2652 Compensate PE relocations when linking with non-PE object
2653 files to generate a non-PE executable.
2657 * elf32-mips.c (mips_elf_calculate_relocation): Explicitly write
2658 GOT entries if we're doing a static link or -Bsymbolic link.
2662 * elflink.h (elf_link_adjust_relocs): Check for and call backend
2663 specifific swap_reloc_{in,out} and swap_reloca_{in,out} if
2665 (elf_link_output_relocs): Likewise.
2666 (elf_reloc_link_order): Likewise.
2670 * archures.c (enum bfd_architecture): #define constants for
2671 PowerPc and RS6000 machine numbers.
2672 * bfd-in2.h: Regenerate.
2673 * coffcode.h (coff_set_arch_mach_hook): #ifdef XCOFF64, set arch
2674 to bfd_arch_powerpc instead of bfd_arch_rs6000. Refer to PowerPc
2675 and RS6000 machine numbers using #defined constants from
2677 * cpu-powerpc.c (arch_info_struct): Refer to PowerPc and RS6000
2678 machine numbers using #defined constants from archures.c. Add
2679 entries for EC603e, 630, A35, RS64II, RS64III, 7400. Specify
2680 64-bit words in 620 entry.
2681 * cpu-rs6000.c (arch_info_struct): Create with entries for RS1,
2683 (bfd_rs6000_arch): Change default machine to 0 (bfd_mach_rs6k).
2687 * coffcode.h (coff_mkobject_hook): Set xcoff_tdata.xcoff64.
2688 * libcoff-in.h (struct xcoff_tdata): Define xcoff64 field.
2689 * libcoff.h (struct xcoff_tdata): Define xcoff64 field.
2693 * bfd-in.h (bfd_family_coff): Define.
2694 * bfd-in2.h: Regenerate.
2695 * coffgen.c (coff_count_linenumbers, coff_symbol_from,
2696 coff_find_nearest_line): Check COFFness using bfd_family_coff()
2697 instead of bfd_target_coff_flavour.
2698 * cofflink.c (_bfd_coff_final_link): Likewise.
2699 * cpu-ns32k.c (do_ns32k_reloc): Don't strcmp() target name to
2700 exclude XCOFF files.
2701 * reloc.c (bfd_perform_relocation, bfd_install_relocation):
2703 * targets.c (enum bfd_flavour): Add bfd_target_xcoff_flavour.
2704 * xcoff-target.h (TARGET_SYM): Use bfd_target_xcoff_flavour.
2705 * xcofflink.c (XCOFF_XVECP): Delete.
2706 (bfd_xcoff_link_record_set, bfd_xcoff_import_symbol,
2707 bfd_xcoff_export_symbol, bfd_xcoff_link_count_reloc,
2708 bfd_xcoff_record_link_assignment,
2709 bfd_xcoff_size_dynamic_sections): Replace XCOFF_XVECP() with
2710 check for bfd_target_xcoff_flavour.
2714 * rs6000-core.c: Support 64-bit core files, support pre-4.3 core
2716 (read_hdr): New function.
2717 (rs6000coff_core_p): Store mstsave or __context64 struct instead
2718 of trying to extract individual registers. Set abfd->arch_info
2719 to match the architecture that created the core file.
2720 (rs6000coff_get_section_contents): Delete.
2721 * xcoff-target.h (rs6000coff_get_section_contents): Delete.
2725 * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_rec)
2730 * configure: Regenerate.
2734 * peicode.h (pe_ILF_object_p): Use TARGET_LITTLE_SYM instead of
2739 * configure.in (VERSION): Update to show this is the CVS mainline.
2743 * elf32-d10v.c: Include elf/d10v.h
2744 (enum reloc_type): Delete.
2745 * elf32-d30v.c: Include elf/d30v.h
2746 (enum reloc_type): Delete.
2748 * Makefile.am: Run "make dep-am" to regenerate dependencies.
2749 * Makefile.in: Regenerate.
2751 * elf32-i386.c (elf_howto_table): Remove EMPTY_HOWTOs.
2752 (elf32_i386_vtinherit_howto, elf32_i386_vtentry_howto): Delete and
2753 move HOWTOs into elf_howto_table.
2754 (R_386_standard, R_386_ext_offset): Define.
2755 (R_386_ext, R_386_vt_offset, R_386_vt): Define.
2756 (elf_i386_reloc_type_lookup): Modify calculation of index into
2757 elf_howto_table since we've removed the padding.
2758 (elf_i386_info_to_howto_rel): Likewise.
2759 (elf_i386_relocate_section): Likewise.
2763 * elf.c (elf_grok_pr_status): Eliminate reference to prgregset_t.
2767 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Don't flag
2768 an error when seeing an undefined symbol with hidden/internal
2769 attribute. It is handled in *_relocate_section ().
2773 * elflink.h (elf_fix_symbol_flags): Follow the link for the
2774 indirect symbol for the ELF_LINK_NON_ELF bit.
2775 (elf_link_output_extsym): Don't output the indirect symbol even
2776 if the ELF_LINK_NON_ELF bit is set.
2780 * config.bfd (i[3456]86-*-netbsdelf*): New target.
2781 (i[3456]86-*-netbsdaout*): New target.
2782 (i[3456]86-*-netbsd*): Add bfd_elf32_i386_vec to targ_selvecs.
2783 (i[3456]86-*-openbsd*): Likewise.
2787 * trad-core.c: From hpux-core.c, include <dirent.h> or
2788 <sys/ndir.h> when possible.
2792 * opintl.h (_(String)): Explain why dgettext is used instead
2797 * elf.c (_bfd_elf_slurp_version_tables): Correct reading of version
2798 definitions. We must not assume they are sorted in the file
2799 according to their index numbers.
2803 * elf-hppa.h: (elf_hppa_final_link_relocate): Use e_rsel field
2804 selector for R_PARISC_PCREL17R. R_PARISC_DIR17R and
2805 R_PARISC_DIR17F are for absolute branches; Handle them as such.
2809 * cpu-i960.c (scan_960_mach): Accept 80960KA, 80960KB,
2810 80960CA, 80960MC as valid machine names.
2814 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Clear the
2815 visibility bits if the symbol is undefined. Correctly handle
2816 weak undefined symbols with hidden and internal attributes.
2818 * elflink.h (elf_link_add_object_symbols): Always turn the
2819 symbol into local if it has the hidden or internal attribute.
2823 * ppcboot.c: Add packed attribute if compiling with GCC.
2827 * elf.c (_bfd_elf_link_hash_table_init): Initialize dynlocal.
2831 * elf.c (elfcore_grok_prstatus, elfcore_grok_pstatus,
2832 elfcore_grok_psinfo): Add code to allow debugging a 32-bit
2833 corefile on a 64-bit (Sparc Solaris) host. Also clean up
2838 * Makefile.am: Update dependencies with "make dep-am"
2839 * Makefile.in: Regenerate.
2841 * sysdep.h (gettext, dgettext, dcgettext, textdomain,
2842 bindtextdomain): Replace defines with those from intl/libgettext.h
2843 to quieten gcc warnings.
2847 * aoutx.h (find_nearest_line): Use IS_ABSOLUTE_PATH.
2849 * archive.c (normalize, bfd_bsd_truncate_arname,
2850 bfd_gnu_truncate_arname) [HAVE_DOS_BASED_FILE_SYSTEM]: Support
2851 file names with backslashes.
2853 * cache.c (bfd_open_file) [__MSDOS__]: Don't unlink the file
2856 * sysdep.h: Include filenames.h.
2860 * opncls.c (bfd_close_all_done): Mask file perms with 0777 not 0x777.
2864 * elf64-sparc.c (sparc64_elf_relax_section): New.
2865 (sparc64_elf_relocate_section): Optimize tail call into branch always
2867 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
2868 (elf32_sparc_relax_section): New.
2872 * elf64-sparc.c: Add ATTRIBUTE_UNUSED to unused function parameters.
2873 Remove unusued variables.
2874 (sparc64_elf_relocate_section): Change r_symndx type to unsigned long.
2875 (sparc64_elf_merge_private_bfd_data): Fix shared library case from
2876 previous fix, so that shared libs really don't influence targets
2877 extension mask and memory model.
2881 * elf64-alpha.c (elf64_alpha_relocate_section): Check
2882 h->root.other not h->other.
2883 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
2885 * elf32-ppc.c (ppc_elf_relocate_section): Fix a typo.
2889 * elf32-i386.c (elf_i386_relocate_section): Don't allow the
2890 undefined symbol with the non-default visibility attributes.
2891 * elf-hppa.h (elf_hppa_relocate_section): Likewise.
2892 * elf32-arm.h (elf32_arm_relocate_section): Likewise.
2893 * elf32-i370.c (i370_elf_relocate_section): Likewise.
2894 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
2895 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
2896 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
2897 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
2898 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
2899 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
2900 * elf64-ia64.c (elf64_ia64_relocate_section): Likewise.
2901 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
2905 * elf64-ia64.c (ia64_howto_table): Add PCREL60B, PCREL21BI,
2906 PCREL22, PCREL64I. Zero size of special relocs.
2907 (elf64_ia64_reloc_type_lookup): Likewise.
2908 (USE_BRL, oor_brl, oor_ip): New.
2909 (elf64_ia64_relax_section): New.
2910 (elf64_ia64_check_relocs): Handle PCREL60B, PCREL22, PCREL64I.
2911 (elf64_ia64_install_value): Likewise, plus PCREL21BI.
2912 (elf64_ia64_relocate_section): Likewise.
2913 (bfd_elf64_bfd_relax_section): New.
2914 * reloc.c (BFD_RELOC_IA64_PCREL21BI): New.
2915 (BFD_RELOC_IA64_{PCREL22,PCREL60B,PCREL64I}): New.
2916 * bfd-in2.h, libbfd.h: Regenerate.
2920 * configure.in : Add peigen.lo to MIPS PE targets.
2921 * configure: Regenerate.
2925 * libbfd.c (_bfd_generic_verify_endian_match): Compare endianess
2926 only if it is known for both input and output bfds. Separate
2927 error message strings as in some languages, it may be necessary
2928 to change more than one place in the string to change between
2931 * elf32-ppc.c (ppc_elf_merge_private_bfd_data): Remove inline
2932 endianess checks, call _bfd_generic_verify_endian_match() instead.
2934 * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Likewise.
2936 * elf32-mcore.c (mcore_elf_merge_private_bfd_data): Likewise.
2938 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Likewise. Verify
2939 endianess before checking bfd flavours.
2943 * elflink.h (elf_link_output_extsym): Clear the visibility
2944 field for symbols not defined locally.
2948 * libhppa.h (re_assemble_3, re_assemble_12, re_assemble_16,
2949 re_assemble_17, re_assemble_21, re_assemble_22): Don't mask insn.
2950 (hppa_rebuild_insn): Mask immediate bits here instead.
2951 * elf-hppa.h (elf_hppa_relocate_insn): Mask here too.
2955 * elflink.h (elf_bfd_final_link, elf_link_input_bfd): When emiting
2956 relocs for an executable, ensure that they are virtual addresses.
2960 * config.bfd (hppa*64*-*-hpux11*): New target triplet.
2965 * elflink.h: Add emitrelocations support: when enabled, relocation
2966 information and relocation sections are put into final output
2967 executables. If the emitrelocations flag is set, do the following:
2968 (elf_bfd_final_link): Emit relocation sections.
2969 (elf_link_input_bfd): Compute relocation section contents.
2970 (elf_gc_sections): Don't clean relocation sections.
2974 * som.c (som_decode_symclass): Recognize weak symbols.
2978 * peigen.c (pe_print_idata): Undo part of 2000-05-12 change that
2979 read idata section only from dataoff.
2980 (pe_print_edata): Correctly check for valid eat_member.
2984 * elf32-sh.c (sh_elf_relax_delete_bytes): Handle R_SH_SWITCH8.
2988 * config.bfd (armeb-*-elf, arm*b-*-linux-gnu*): New targets.
2992 * targets.c (bfd_target_vector): #ifdef BFD64 rs6000coff64_vec
2994 * peigen.c (pe_print_idata): Look for .idata section and print
2995 info even if data directory has zero entries. Read idata section
2996 starting from dataoff, and adjust all data offsets to suit. Cast
2997 all bfd_vma vars to unsigned long before passing to fprintf.
2998 * peigen.c (pe_print_edata): Similarly, look for .edata section
2999 and print info even if data directory has zero entries. Cast
3000 all bfd_vma vars to unsigned long before passing to fprintf.
3003 * peigen.c (pe_print_idata): Use bfd_section_size rather than data
3004 directory size which may be bogus.
3005 * peigen.c (pe_print_edata): Similarly.
3009 * elf.c (bfd_section_from_shdr): Don't set use_rela_p if rela
3011 (copy_private_bfd_data): Allow for space possibly taken up by elf
3012 headers when calculating segment physical address from lma.
3016 * versados.c (versados_scan): Init stringlen and pass_2_done.
3018 * trad-core.c (trad_unix_core_file_p): Return
3019 bfd_error_wrong_format rather than bfd_error_file_truncated.
3021 * peigen.c (_bfd_pei_swap_aouthdr_out): Pass ImageBase to
3022 add_data_entry. DataDirectory virtual address is relative.
3023 (pe_print_idata): Account for relative DataDirectory virtual
3024 addresses. Don't trash datasize inside POWERPC_LE_PE code.
3025 (pe_print_edata): Similarly.
3028 * peigen.c (dir_names): Add Delay Import Directory.
3029 (pe_print_idata): Always search for bfd section containing
3030 idata address rather than looking up section name. Print this
3031 section name rather than .idata.
3032 (pe_print_edata): Similarly. Also print some fields as %08lx.
3033 (_bfd_pe_print_private_bfd_data_common): Print Reserved1 field as
3038 * xcoff.h: Rename to xcoff-target.h
3039 * Makefile.am: Change all instances of xcoff.h to xcoff-target.h
3040 * coff-rs6000.c: Ditto.
3041 * coff64-rs6000.c: Ditto.
3042 * coff-pmac.c: Ditto.
3043 * Makefile.in: Regenerate.
3047 * coffcode.h (coff_set_arch_mach_hook, coff_set_flags):
3048 Change U802TOC64MAGIC to U803XTOCMAGIC.
3052 * elf.c (bfd_elf_get_arch_size): New function, return 32 | 64 | -1.
3053 * bfd-in.h: Prototype bfd_elf_get_arch_size.
3054 * bfd-in2.h: Prototype bfd_elf_get_arch_size.
3058 * libhppa.h (HPPA_R_CONSTANT): Cast argument to bfd_signed_vma.
3062 * elflink.h (elf_link_add_object_symbols): Reset dynindx for
3063 hidden and internal symbols.
3064 (elf_fix_symbol_flags): Clear NEEDS_PLT for symbols with
3066 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Do not
3067 assign a PLT or GOT entry to symbols with hidden and
3068 internal visibility.
3072 * bfd/coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Add entry for
3074 * bfd/coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
3078 * elf.c (prep_headers): Use ELFOSABI_NONE instead of
3083 * targets.c (bfd_target_vector): Restore bfd_elf32_hppa_vec.
3084 * Makefile.am (BFD32_BACKENDS): Restore elf32-hppa.lo. Regenerate
3086 * Makefile.in: Regenerate.
3090 * Makefile.am (BFD32_BACKENDS): Add efi-app-ia32.lo.
3091 (BFD32_BACKENDS_CFILES): Add efi-app-ia32.c.
3092 (BFD64_BACKENDS): Delete coff-ia64.lo. Add efi-app-ia64.lo.
3093 (BFD64_BACKENDS_CFILES): Delete coff-ia64.c. Add efi-app-ia64.c.
3094 * Makefile.in: Rebuild.
3098 * config.bfd: Re-enable elf32-hppa. It now compiles, even if it
3099 doesn't work very well.
3101 * elf-hppa.h (elf_hppa_internal_shdr): Define.
3102 (elf_hppa_fake_sections): hdr is elf_hppa_internal_shdr.
3103 Set hdr->s_type to 1 if ARCH_SIZE == 32.
3104 (_bfd_elf_hppa_gen_reloc_type): Add prototype.
3105 (elf_hppa_info_to_howto): Likewise.
3106 (elf_hppa_info_to_howto_rel): Likewise.
3107 (elf_hppa_reloc_type_lookup): Likewise.
3108 (elf_hppa_is_local_label_name): Likewise.
3109 (elf_hppa_fake_sections): Likewise.
3110 (elf_hppa_final_write_processing): Likewise.
3111 (elf_hppa_howto_table): Fully initialise all entries.
3112 (_bfd_elf_hppa_gen_reloc_type): Add ATTRIBUTE_UNUSED to args.
3113 (elf_hppa_info_to_howto): Likewise.
3114 (elf_hppa_info_to_howto_rel): Likewise.
3115 (elf_hppa_reloc_type_lookup): Likewise.
3116 (elf_hppa_final_write_processing, elf_hppa_add_symbol_hook,
3117 elf_hppa_unmark_useless_dynamic_symbols,
3118 elf_hppa_remark_useless_dynamic_symbols,
3119 elf_hppa_record_segment_addrs, elf_hppa_final_link,
3120 elf_hppa_relocate_section, elf_hppa_final_link_relocate,
3121 elf_hppa_relocate_insn): Compile only if ARCH_SIZE == 64 until
3122 elf32-hppa.c mess is cleaned up.
3123 (elf_hppa_final_link_relocate): Make insn and r_type unsigned
3124 int. Delete r_field. In case R_PARISC_PCREL21L, don't set
3125 r_field then call hppa_field_adjust inline func with variable
3126 r_field arg, instead call hppa_field_adjust with fixed arg.
3127 In case R_PARISC_PCREL22F, don't set r_field.
3128 (elf_hppa_relocate_insn): Change args and return type to unsigned
3129 int. Call re_assemble_* funcs to do the work.
3131 * elf32-hppa.c (hppa_elf_relocate_insn): Don't assume 32 bit when
3134 * libhppa.h (HPPA_R_CONSTANT): Don't assume 32 bit when sign
3136 (sign_extend): Mask first before sign extending.
3137 (low_sign_extend): Rewrite without condition expression.
3138 (ones, dis_assemble_3, dis_assemble_12, dis_assemble_16,
3139 dis_assemble_17, dis_assemble_21, dis_assemble_22): Delete.
3140 (assemble_3, assemble_6, assemble_12, assemble_16, assemble_16a,
3141 assemble_17, assemble_21, sign_unext, low_sign_unext): Return
3142 result as function return value rather than through pointer arg.
3143 Accept unsigned int args, and return unsigned int.
3144 (re_assemble_3): New. Combines function of dis_assemble_3 with
3145 re-assembly of opcode and immediate.
3146 (re_assemble_12): Likewise.
3147 (re_assemble_16): Likewise.
3148 (re_assemble_17): Likewise.
3149 (re_assemble_21): Likewise.
3150 (re_assemble_22): Likewise.
3151 (hppa_field_adjust): Rewrite and document, paying attention to
3152 size of types and signed/unsigned issues.
3153 (get_opcode): Shift before masking.
3154 (FDLW): Rename to FLDW.
3155 (bfd_hppa_insn2fmt): Change arg to unsigned int. Delete fmt.
3156 (hppa_rebuild_insn): Change args and return value to unsigned
3157 int. Make use of re_assemble_*. Correct case 11.
3159 * dep-in.sed: Handle ../opcodes/.
3160 * Makefile.am (SOURCE_HFILES): Add elf-hppa.h, elf32-hppa.h,
3161 elf64-hppa.h, hppa_stubs.h, xcoff.h.
3162 (BFD32_BACKENDS_CFILES): Restore elf32-hppa.c.
3163 Remove elf64-hppa.lo, cpu-ia64.lo, elf64-ia64.lo, elfarm-oabi.lo,
3164 elfarm-nabi.lo dependencies outside of auto-dependency area.
3165 Regenerate dependencies.
3166 * Makefile.in: Regenerate.
3168 * configure.in (TRAD_HEADER): Test non-null before
3170 * configure: Regenerate.
3172 * reloc.c: Fix mis-spelling in comment.
3176 * coff-sh.c (bfd_coff_small_swap_table): Fix Fri Apr 28 change.
3177 * vms.c (vms_openr_next_archived_file): Return NULL.
3181 * coffcode.h Copy changes mistakenly done to libcoff.h in
3186 * libbfd-in.h: Correctly check GCC version.
3187 * bfd-in.h: Likewise.
3188 * libhppa.h: Likewise.
3189 * libbfd.h: Regenerate.
3190 * bfd-in2.h: Regenerate.
3194 * Makefile.am (BFD64_BACKENDS, BFD64_BACKENDS_CFILES): Add
3195 coffdu-rs6000.{lo,c}.
3196 (coff-pmac.lo, coff-rs6000.lo, coff64-rs6000.lo): Add dependency
3198 * Makefile.in: Regenerate.
3199 * xcoff.h: New file.
3200 * coff-pmac.c: Use xcoff.h instead of coff-rs6000.c.
3201 * coff-rs6000.c: Move all declarations and defines that are
3202 common to the xcoff backends into xcoff.h
3203 * coff64-rs6000.c: Ditto,
3207 * coff-mips.c (mips_ecoff_backend_data): Add initialization of
3208 _bfd_coff_force_symnames in strings and
3209 _bfd_coff_debug_string_prefix_length to their default values.
3210 * coff-sh.c: (bfd_coff_small_swap_table): Ditto.
3214 * coff-alpha.c (alpha_ecoff_backend_data): Add initialization of
3215 _bfd_coff_force_symnames in strings and
3216 _bfd_coff_debug_string_prefix_length to their default values.
3220 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Return if dynobj NULL.
3221 Check local_got_refcounts before dereferencing.
3223 * elf32-ppc.c (ppc_elf_relocate_section): Check splt != NULL
3224 before deciding we don't need R_PPC_PLT32 relocation.
3225 (ppc_elf_gc_sweep_hook): Check local_got_refcounts before
3228 * elflink.h (elf_gc_common_finalize_got_offsets): Fix comment.
3230 * elf32-i386.c (elf_i386_check_relocs): Reference count .got and
3232 (elf_i386_gc_sweep_hook): Garbage collect .got and .plt entries.
3233 (elf_i386_adjust_dynamic_symbol): Recognize unused .plt entries.
3234 (elf_i386_relocate_section): Allow for .plt to go missing.
3235 (elf_i386_finish_dynamic_symbol): Use same test to decide if we
3236 can use a relative reloc for got as elf_i386_relocate_section.
3237 (bfd_elf32_bfd_final_link): Define to use gc form of final link.
3241 * config.bfd: Remove extraneous bfd_powerpc_64_arch.
3245 * Makefile.am (coff64-rs6000.lo): New rule.
3246 * Makefile.in: Regenerate.
3247 * coff-rs6000.c (xcoff_mkobject, xcoff_copy_private_bfd_data,
3248 xcoff_is_local_label_name, xcoff_rtype2howto,
3249 xcoff_reloc_type_lookup, xcoff_slurp_armap, xcoff_archive_p,
3250 xcoff_read_ar_hdr, xcoff_openr_next_archived_file, xcoff_write_armap,
3251 xcoff_write_archive_contents): No longer static, and prefix with _bfd_.
3252 (NO_COFF_SYMBOLS): Define.
3253 (xcoff64_swap_sym_in, xcoff64_swap_sym_out, xcoff64_swap_aux_in,
3254 xcoff64_swap_aux_out): New functions; handle xcoff symbol tables
3256 (MINUS_ONE): New macro.
3257 (xcoff_howto_tabl, xcoff_reloc_type_lookup): Add 64 bit POS
3259 (coff_SWAP_sym_in, coff_SWAP_sym_out, coff_SWAP_aux_in,
3260 coff_SWAP_aux_out): Map to the new functions.
3261 * coff64-rs6000.c: New file.
3262 * libcoff.h (bfd_coff_backend_data): Add new fields
3263 _bfd_coff_force_symnames_in_strings and
3264 _bfd_coff_debug_string_prefix_length.
3265 (bfd_coff_force_symnames_in_strings,
3266 bfd_coff_debug_string_prefix_length): New macros for above fields.
3267 * coffcode.h (coff_set_arch_mach_hook): Handle XCOFF64 magic.
3268 Set machine to 620 for XCOFF64. Use bfd_coff_swap_sym_in instead
3269 of using coff_swap_sym_in directly.
3270 (FORCE_SYMNAMES_IN_STRINGS): New macro, defined for XCOFF64.
3271 (coff_set_flags) Set magic for XCOFF64.
3272 (coff_compute_section_file_positions): Add symbol name length to
3273 string section length if bfd_coff_debug_string_prefix_length is
3275 (coff_write_object_contents): Don't do reloc overflow for XCOFF64.
3276 (coff_slurp_line_table): Use bfd_coff_swap_lineno_in instead of
3277 using coff_swap_lineno_in directly.
3278 (bfd_coff_backend_data): Add _bfd_coff_force_symnames_in_strings
3279 and _bfd_coff_debug_string_prefix_length fields.
3280 * coffgen.c (coff_fix_symbol_name, coff_write_symbols): Force
3281 symbol names into strings table when
3282 bfd_coff_force_symnames_in_strings is true.
3283 * coffswap.h (MAX_SCNHDR_NRELOC, MAX_SCNHDR_NLNNO, GET_RELOC_VADDR,
3284 SET_RELOC_VADDR): New macros.
3285 (coff_swap_reloc_in, coff_swap_reloc_out): Use above macros.
3286 (coff_swap_aux_in, coff_swap_aux_out): Remove RS6000COFF_C
3288 (coff_swap_aouthdr_in, coff_swap_aouthdr_out): Handle XCOFF64
3289 changes within RS6000COFF_C specific code.
3290 (coff_swap_scnhdr_out): Use PUT_SCNHDR_NLNNO, PUT_SCNHDR_NRELOC,
3291 MAX_SCNHDR_NRELOC, and MAX_SCNHDR_NLNNO.
3292 * reloc.c (bfd_perform_relocation, bfd_install_relocation):
3293 Extend existing hack on target name.
3294 * xcofflink.c (XCOFF_XVECP): Extend existing hack on
3296 * coff-tic54x.c (ticof): Keep up to date with new fields
3297 in bfd_coff_backend_data.
3298 * config.bfd: Add bfd_powerpc_64_arch to targ_arch and define
3299 targ_selvecs to include rs6000coff64_vec for rs6000.
3300 * configure.in: Add rs6000coff64_vec case.
3301 * cpu-powerpc.c: New bfd_arch_info_type.
3305 * config.bfd: Only disable elf32-hppa vectors, not all of the
3306 BSD and OSF configuration support. Provide (disabled) clauses
3308 * configure.in: Add clause for PA64 support.
3309 * configure: Rebuilt.
3311 * targets.c (bfd_target_vector): Add bfd_elf64_hppa_vec.
3312 (bfd_elf64_hppa_vec): Declare.
3314 * Makefile.am (BFD64_BACKENDS): Add elf64-hppa.lo
3315 (BFD64_BACKENDS_CFILES): Add elf64-hppa.c
3316 (elf64-hppa.lo): Add dependencies.
3317 * Makefile.in: Rebuilt.
3319 * elf64-hppa.c, elf64-hppa.h: New files with PA64 support.
3323 * libhppa.h (dis_assemble_16): New function.
3324 (pa_arch): Added pa20w element.
3328 * elf-bfd.h: Add prototypes for bfd_elf32_write_relocs,
3329 bfd_elf32_slurp_reloc_table, bfd_elf64_write_relocs, and
3330 bfd_elf64_slurp_reloc_table.
3332 * elfcode.h (elf_write_relocs, elf_slurp_reloc_table): New
3333 definitions to get external names.
3334 (elf_write_relocs): Renamed from write_relocs and make global.
3335 (elf_slurp_reloc_table): Make global.
3336 (_bfd_elf,size_info): Use elf_write_relocs instead of write_relocs.
3338 * archive.c (hpux_uid_gid_encode): New function.
3339 (bfd_ar_hdr_from_filesystem): Use it if HPUX_LARGE_AR_IDS is
3340 defined and the ID is greater than 99999.
3341 (bfd_generic_stat_arch_elt): If HPUX_LARGE_AR_IDS is defined decode
3342 special uid/gid fields into 32 bit values.
3346 * config.bfd: Add NetBSD/sparc64 support.
3353 * Makefile.am (ALL_MACHINES): Add cpu-ia64.lo.
3354 (ALL_MACHINES_CFILES): Add cpu-ia64.c.
3355 (BFD64_BACKENDS): Add elf64-ia64.lo.
3356 (BFD64_BACKENDS_CFILES): Add elf64-ia64.c.
3357 (cpu-ia64.lo, elf64-ia64.lo): New rules.
3358 * Makefile.in: Rebuild.
3359 * archures.c (enum bfd_architecture): Add bfd_arch_ia64.
3360 (bfd_ia64_arch): Declare.
3361 (bfd_archures_list): Add bfd_ia64_arch.
3362 * bfd-in2.h: Rebuild.
3363 * config.bfd: (ia64*-*-linux-gnu*, ia64*-*-elf*): New targets.
3364 * configure: Rebuild.
3365 * configure.host: (ia64-*-linux*): New host.
3366 * configure.in (bfd_elf64_ia64_little_vec, bfd_elf64_ia64_big_vec,
3367 bfd_efi_app_ia64_vec, bfd_efi_app_ia64_vec): New vectors.
3368 * elf.c (prep_headers): Add bfd_arch_ia64.
3369 * libbfd.h: Rebuild.
3370 * reloc.c: Add IA-64 relocations.
3371 * targets.c (bfd_elf64_ia64_little_vec, bfd_elf64_ia64_big_vec):
3373 (bfd_target_vect): Add bfd_elf64_ia64_little_vec.
3374 * cpu-ia64-opc.c, cpu-ia64.c, elf64-ia64.c: New files.
3378 * elf32-d30v.c (bfd_elf_d30v_reloc): Don't modify section
3379 contents when performing a partial link.
3380 (bfd_elf_d30v_reloc_21): Likewise.
3384 * elf32-i386.c (elf_i386_relocate_section): Restrict 1998-12-10
3385 patch to symbols defined by a shared object.
3386 * elf32-ppc.c (ppc_elf_relocate_section): Similarly.
3391 * dwarf2.c (concat_filename): Avoid string literal concatenation.
3392 * ieee.c (ieee_get_symtab): Don't initialise union in struct.
3396 * Makefile.am (BFD64_BACKENDS): Mention coff-ia64.lo.
3397 (BFD64_BACKENDS_CFILES): Mention coff-ia64.c
3398 (coff-ia64.lo): Add dependency.
3399 * Makefile.in: Regenerate.
3400 * coff-ia64.c: New file.
3401 * efi-app-ia32.c: Ditto.
3402 * efi-app-ia64.c: Ditto.
3403 * coffcode.h (coff_set_arch_mach_hook): Handle IA64MAGIC.
3404 (coff_set_flags): Ditto.
3405 (coff_write_object_contents) [IA64]: Set magic number to ZMAGIC.
3406 * config.bfd (i[3456]86-*-linux-gnu*): Mention bfd_efi_app_ia32_vec.
3407 * configure.in (elf): Handle bfd_efi_app_ia32 and bfd_efi_app_ia64_vec.
3408 * configure: Regenerate.
3409 * libpei.h (GET_OPTHDR_IMAGE_BASE): New macro.
3410 (PUT_OPTHDR_IMAGE_BASE): Ditto.
3411 (GET_OPTHDR_SIZE_OF_STACK_RESERVE): Ditto.
3412 (PUT_OPTHDR_SIZE_OF_STACK_RESERVE): Ditto.
3413 (GET_OPTHDR_SIZE_OF_STACK_COMMIT): Ditto.
3414 (PUT_OPTHDR_SIZE_OF_STACK_COMMIT): Ditto.
3415 (GET_OPTHDR_SIZE_OF_HEAP_RESERVE): Ditto.
3416 (PUT_OPTHDR_SIZE_OF_HEAP_RESERVE): Ditto.
3417 (GET_OPTHDR_SIZE_OF_HEAP_COMMIT): Ditto.
3418 (PUT_OPTHDR_SIZE_OF_HEAP_COMMIT): Ditto.
3419 (GET_PDATA_ENTRY): Ditto.
3420 * peigen.c (_bfd_pei_swap_aouthdr_in) [COFF_WITH_PEP64]: Don't read
3421 data_start. Use above macros to read fields that are 64 bit wide for
3422 COFF_WITH_PEP64. Don't truncate entry and text_start to 32 bits.
3423 (_bfd_pei_swap_aouthdr_out) [PEI_FORCE_MINIMUM_ALIGNMENT]: Force
3424 FileAlignment and SectionAlignment to minimum alignment if they
3426 (_bfd_pei_swap_aouthdr_out) [PEI_DEFAULT_TARGET_SUBSYSTEM]: Set
3427 Subsystem to default PEI_DEFAULT_TARGET_SUBSYSTEM.
3428 (_bfd_pei_swap_aouthdr_out) [COFF_WITH_PEP64]: Don't set data_start.
3429 Use above macros to write fields that are 64 bit wide for
3431 (pe_print_pdata): Set PDATA_ROW_SIZE to 3*8 for COFF_WITH_PEP64,
3432 5*4 otherwise. This should be right for IA-32 and IA-64, but may
3433 be wrong for platforms. Use PDATA_ROW_SIZE instead of hardcoded
3434 value of 20 bytes. Modify printing for COFF_WITH_PEP64 to print
3435 begin address, end address, and unwind info address only. Use
3436 GET_PDATA_ENTRY() to read .pdata entries. Use fprintf_vma() to
3438 (tbl): Add SECTION, REL32, RESERVED1, MIPS_JMPADDR16, DIR64, and
3439 HIGH3ADJ relocation names.
3440 (_bfd_pe_print_private_bfd_data): Print Subsystem name in legible form.
3441 * targets.c: Declare bfd_efi_app_ia32_vec and
3442 bfd_efi_app_ia64_vec.
3443 (bfd_target_vector): Mention bfd_efi_app_ia32_vec and
3444 bfd_efi_app_ia64_vec.
3448 * bfd-in2.h: Add prototypes for tic54x load page access.
3449 * bfd-in.h: Regenerate.
3450 * coff-tic54x.c: Add load page functions; allow bfd_arch_unknown
3451 in customized _set_arch_mach function.
3452 * coffcode.h (coff_set_alignment_hook): Set section load page if
3453 the appropriate macro is defined.
3454 (write_object_contents): Read section load page.
3458 * elf32-hppa.h: Update copyright date.
3460 * elf32-fr30.c (fr30_elf_i20_reloc): Don't use U suffix.
3461 * elf32-mips.c (_bfd_mips_elf_relocate_section): And here.
3463 * elf32-d30v.c (MAX32): Don't use LL suffix.
3464 (MIN32): Define in terms of MAX32.
3465 (bfd_elf_d30v_reloc): Make relocation a bfd_signed_vma.
3467 * coff-a29k.c (SIGN_EXTEND_HWORD): Replace with more concise
3470 * peicode.h (pe_ILF_build_a_bfd): Remove UL from hex constants.
3474 * dep-in.sed: Match space before file name, not after.
3475 * Makefile.am: Regenerate dependencies.
3476 * Makefile.in: Regenerate.
3478 * reloc.c (_bfd_relocate_contents): In complain_overflow_bitfield
3479 case, allow address wrap-around stupidly removed 2000-03-17. Sign
3480 extend without an if statement.
3484 * coff-mips.c (mips_gprel_reloc): Test for 16 bit range using
3486 * elf32-mips.c (gprel16_with_gp): Likewise.
3487 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Test range
3488 here using -0x40000, not (int)0xfffc0000.
3489 (elf32_hppa_size_of_stub): Likewise.
3493 * coff-tic54x.c: Now builds with all targets.
3494 * Makefile.am: Add coff/tic54x.h to coff-tic54x.o dependencies.
3495 * Makefile.in: Regenerate.
3496 * coffcode.h (coff_set_arch_mach_hook): Eliminate warning on
3497 unitialized variable.
3501 * configure.in (WARN_CFLAGS): Set to -W -Wall by default. Add
3502 --enable-build-warnings option.
3503 * Makefile.am (AM_CFLAGS, WARN_CFLAGS): Add definitions.
3504 * Makefile.in, configure: Re-generate.
3508 * reloc.c: Add BFD_RELOC_ARM_PCREL_BLX and
3509 BFD_RELOC_THUMB_PCREL_BLX.
3511 * elf32-arm.h (elf32_arm_final_link_relocate): Handle
3512 R_ARM_XPC25 and R_ARM_THM_PC22.
3514 * elfarm-nabi.c (elf32_arm_howto_): Fix definitions of
3515 R_ARM_XPC25 and R_ARM_THM_XPC22.
3516 (elf32_arm_reloc_map): Make BFD_RELOC_{ARM|THUMB}_PCREL_BLX to
3517 R_ARM_[XPC25|THM_XPC22].
3519 * elfarm-oabi.c: Define OLD_ARM_ABI and change include from
3520 elf/arm-oabi.h to elf/arm.h
3522 * Makefile.am: Fix dependency for elfarm-oabi.c
3523 * Makefile.in: Regenerate.
3525 * bfd-in2.h: Regenerate.
3526 * libbfd.h: Regenerate.
3530 * elfcore.h (elf_core_file_p): preserve value of tdata at entry,
3531 and restore it on failure. Release newly allocated tdata on
3536 * dwarf2.c (struct dwarf2_debug): New field dwarf_line_size.
3537 (decode_line_info): Set it. Report error if unit->line_offset is
3538 equal to or larger than it.
3542 * targets.c: Added vecs for tic54x.
3543 * reloc.c: Added relocs for tic54x.
3544 * libbfd.h: Regenerated.
3545 * configure: Add TI COFF vecs for tic54x.
3546 * configure.in: Ditto.
3547 * config.bfd (targ_cpu): Recognize new tic54x target.
3548 * coffcode.h (coff_slurp_symbol_table): Additions for TI COFF handling.
3549 * bfd-in2.h: Add tic54x target and relocations.
3550 * Makefile.am, Makefile.in: Add tic54x target.
3551 * archures.c (bfd_archures_list): Add tic54x target.
3552 * coff-tic54x.c: New.
3553 * cpu-tic54x.c: New.
3557 * elfcore.h (elf_core_file_p): call backend_object_p which
3558 thereby gets an opportunity to update the arch/machine type.
3562 * coffcode.h (coff_slurp_symbol_table): Handle C_STATLAB storage
3563 class. Handle SEC_CLINK and SEC_BLOCK flags.
3564 * section.c: Add SEC_CLINK and SEC_BLOCK flags.
3565 * bfd-in2.h: Add SEC_CLINK and SEC_BLOCK flags.
3569 * elf32-arm.h (elf32_arm_set_private_flags): Only check for
3570 EF_INTERWORK if this is an unknown EABI.
3571 (elf32_arm_merge_private_bfd_data): Check EABI version
3572 numbers. Only check EF_xxx flags if the EABI version number
3574 (elf32_arm_check_private_bfd_data): Only check EF_xxx flags
3575 if the EABI version number is unknown.
3576 (elf32_arm_print_private_bfd_data): Only decode EF_xxx flags
3577 if the EABI version number is unknown.
3581 * reloc.c (_bfd_relocate_contents): Add BFD_RELOC_SH_LOOP_START and
3582 BFD_RELOC_SH_LOOP_END.
3583 * elf32-sh.c (sh_elf_howto_tab): Change special_func to
3584 sh_elf_ignore_reloc for all entries that sh_elf_reloc used to ignore.
3585 Add entries for R_SH_LOOP_START and R_SH_LOOP_END.
3586 (sh_elf_reloc_loop): New function.
3587 (sh_elf_reloc): No need to test for always-to-be-ignored relocs
3589 (sh_rel): Add entries for BFD_RELOC_SH_LOOP_{START,END}.
3590 (sh_elf_relocate_section): Handle BFD_RELOC_SH_LOOP_{START,END}.
3591 * bfd-in2.h, libbfd.h: Regenerate.
3595 * po/bfd.pot: Regenerate.
3597 * Makefile.am: Remove extraneous mkdep comment.
3598 (MKDEP): Use gcc -MM rather than mkdep.
3599 (DEP): Quote when passing vars to sub-make. Add warning
3601 (DEP1): Rewrite for "gcc -MM".
3602 (CLEANFILES): Add DEP2.
3603 Update dependencies.
3604 * Makefile.in: Regenerate.
3608 * configure.in: Added corefile support for AIX 4.3. In particular,
3609 AIX_CORE_DUMPX_CORE will be defined in addition to AIX_CORE when
3610 compiling rs6000-core.c.
3611 * configure: Regenerated.
3615 * cache.c (bfd_open_file): Unlink the output file only if
3616 it has non-zero size.
3620 * elf64-alpha.c (elf64_alpha_relocate_section): Don't emit
3621 relative relocations for non-loaded sections in shared objects.
3622 (elf64_alpha_check_relocs): Similarly.
3626 * aoutx.h (NAME(aout,reloc_type_lookup)): Add BFD_RELOC_8 and
3627 BFD_RELOC_16 to switch for extended relocs.
3628 (MY_swap_ext_reloc_in): New.
3629 (MY_swap_ext_reloc_out): New.
3630 (NAME(aout,slurp_reloc_table)): Use MY_swap_ext_reloc_in rather
3631 than NAME(aout,swap_ext_reloc_in) for extended relocs.
3632 (NAME(aout,squirt_out_relocs)): Similarly use
3633 MY_swap_ext_reloc_out.
3634 (aout_link_reloc_link_order): Use MY_put_ext_reloc if defined.
3638 * coff-h8300.c (h8300_reloc16_extra_cases): Add bsr:16 -> bsr:8 to
3639 the R_PCRWORD_B case.
3643 * srec.c : Set CHUNK size to 16 bytes to prevent download failures
3649 * elf32-m32r.c (m32r_elf_generic_reloc): new function. All
3650 HOWTO references to bfd_elf_generic_reloc, that have
3651 partial_inplace == true, now use the new function. The function
3652 is based on the recent rewrite of m32r_elf_lo16_reloc(), and
3653 extends its fixes to the R_M32R_{16,24,32} relocs.
3654 The new logic in m32r_elf_lo16_reloc() has been removed, and
3655 it instead calls the new routine to obtain that functionality.
3659 * elf32-avr.c (elf32_avr_gc_mark_hook, elf32_avr_gc_sweep_hook,
3660 elf32_avr_check_relocs, avr_final_link_relocate,
3661 elf32_avr_relocate_section, bfd_elf_avr_final_write_processing,
3662 elf32_avr_object_p): Add prototypes.
3663 (elf32_avr_gc_mark_hook): Add default for h->root.type.
3664 (bfd_elf_avr_final_write_processing): Make static.
3668 * cpu-avr.c: New file. BFD support routines for AVR architecture.
3669 * archures.c (bfd_architecture): Add AVR architecture.
3670 (bfd_archures_list): Add reference to AVR architecture info.
3671 * elf.c (prep_headers): Handle bfd_arch_avr.
3672 * reloc.c: Add various AVR relocation enums.
3673 * targets.c (bfd_elf32_avr_vec): Declare and add to target vector
3675 * Makefile.am: Add support for AVR elf.
3676 * configure.in: Likewise.
3677 * config.bfd: Likewise.
3678 * Makefile.in: Regenerate.
3679 * configure: This too.
3680 * bfd-in2.h: And this.
3681 * libbfd.h: And this.
3685 * elf64-alpha.c (elf64_alpha_merge_ind_symbols): Add prototype.
3686 (elf64_alpha_find_reloc_at_ofs): Likewise.
3690 * reloc.c (bfd_check_overflow): In case complain_overflow_bitfield,
3691 flag an overflow if the bitfield is outside -2**n to 2**n-1. The
3692 allowable range used to be -2**(n-1) to 2**n-1.
3693 * reloc.c (_bfd_relocate_contents): Same here. Also replace
3694 "boolean overflow" with "bfd_reloc_status_type flag".
3698 * elf32-m32r.c (m32r_elf_lo16_reloc): Rewrite.
3702 * reloc16.c (bfd_coff_reloc16_relax_section): Count the total number
3703 of shrinks properly, including the last reloc.
3707 * coff-h8300.c (h8300_reloc16_extra_cases): Fix the sanity
3712 * ieee.c (ieee_archive_p): Return bfd_error_wrong_format on
3713 a format mismatch rather than an "error" from bfd_read such as
3714 bfd_error_file_truncated.
3718 * elf32-mips.c (_bfd_mips_elf_relocate_section): Do proper
3719 sign-extension and big-endian compensation for
3720 R_MIPS_64 even in ld -r.
3724 * elf32-mips.c (mips_elf_next_relocation): Rename from
3725 mips_elf_next_lo16_relocation, and generalize to look
3726 for any relocation type.
3727 (elf_mips_howto_table): Make R_MIPS_PC16 pcrel_offset.
3728 (elf_mips_gnu_rel_hi16): Howto for R_MIPS_GNU_REL_HI16.
3729 (elf_mips_gnu_rel_lo16): Howto for R_MIPS_GNU_REL_LO16.
3730 (elf_mips_gnu_rel16_s2): Howto for R_MIPS_GNU_REL16_S2.
3731 (elf_mips_gnu_pcrel64): Howto for R_MIPS_PC64.
3732 (elf_mips_gnu_pcrel32): Howto for R_MIPS_PC32.
3733 (bfd_elf32_bfd_reloc_type_lookup): Add new relocs.
3734 (mips_rtype_to_howto): Likewise.
3735 (mips_elf_calculate_relocation): Handle new relocs.
3736 (_bfd_mips_elf_relocate_section): REL_HI16/REL_LO16 relocs
3737 are paired. The addend for R_MIPS_GNU_REL16_S2
3738 is shifted right two bits.
3742 * reloc.c (bfd_perform_relocation): Undo emacs formatting of
3743 comment, and ensure it doesn't happen again.
3744 (bfd_install_relocation): Same here.
3745 (_bfd_relocate_contents): Don't bother assigning unused signmask
3746 shift result. Fix typos in comments.
3747 Remove trailing whitespace throughout file.
3751 * reloc.c (reloc_howto_struct): Fix partial_inplace comment.
3752 * bfd-in2.h: Rebuild.
3756 * peicode.h (struct pe_ILF_vars): Add sym_ptr_table and
3758 (SIZEOF_ILF_SYM_PTR_TABLE): Define.
3759 (SIZEOF_ILF_STRINGS): Redefine.
3760 (pe_ILF_make_a_symbol-reloc): New function. Creates a symbol
3761 relative reloc, as opposed to a section relative reloc.
3762 (pe_ILF_make_a_symbol): Set the class of local symbols to C_STAT
3764 Add length of symbol's prefix to string pointer.
3765 Store a pointer to the symbol in the symbol pointer table.
3766 (pe_ILF_build_a_bfd): Do not build .idata$2 or .idata$7.
3767 Initialise the symbol pointer table.
3768 Store the hint in the Hint/Name table.
3769 Make the jump reloc be symbol realtive, not section relative.
3770 Create an import symbol for imported code.
3774 * elf.c (swap_out_syms): Check for null type_ptr.
3778 * aout-target.h (MY(write_object_contents)): Remove unused
3779 and unusable "#if CHOOSE_RELOC_SIZE".
3780 * pc532-mach.c (MY(write_object_contents)): Ditto.
3781 * netbsd.h (MY(write_object_contents)): Ditto.
3782 * hp300hpux.c (MY(write_object_contents)): Ditto.
3783 * freebsd.h (MY(write_object_contents)): Ditto.
3784 * aout-tic30.c (tic30_aout_write_object_contents): Ditto.
3788 * peicode.h (jtab): Make it static.
3790 * coff-sh.c (sh_align_load_span): Declared if COFF_WITH_PE is
3791 defined and COFF_IMAGE_WITH_PE is not defined.
3792 (_bfd_sh_align_load_span): Defined as sh_align_load_span if
3793 COFF_WITH_PE is defined and COFF_IMAGE_WITH_PE is not defined.
3797 * coff-arm.c (bfd_arm_process_before_allocation): Make
3798 'symndx' signed to prevent compile time warning.
3800 * coff-mcore.c: Remove unused prototype for pe_object_p.
3802 * coff-sh.c: Add "#ifndef COFF_IMAGE_WITH_PE" around static
3803 functions that are not used when COFF_IMAGE_WITH_PE is
3805 (struct sh_opcode): Change type of 'flags' field to unsigned
3806 long so that it can hold the USESAS flag.
3808 * coffcode.h (styp_to_sec_flags): Initialise 'target_name'.
3810 * elf-m10300.c (mn10300_elf_relax_section): Initialise
3813 * elf32-i370.c: Add ATTRIBUTE_UNUSED to unused function
3815 Remove unusued variables and code.
3816 (elf_backend_add_symbol_hook): Fix prototype.
3818 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Initialise 'sgot' and
3821 * elf32-mcore.c (mcore_elf_relocate_section): Initialise
3824 * elf32-mips.c: Add ATTRIBUTE_UNUSED to unused function
3826 Remove unusued variables and code.
3827 (elf_backend_add_symbol_hook): Fix prototype.
3829 * elf32-sh.c (sh_elf_set_mach_from_flags): Use 'flags'.
3831 * elflink.h (elf_bfd_link_add_symbols): Add ATTRIBUTE_UNUSED
3832 to unused function parameter.
3834 * pe-mips.c: Add ATTRIBUTE_UNUSED to unused function
3836 Use EMPTY_HOWTO to initialise empty howto slots.
3837 Remove unused variables.
3839 * peicode.h (pe_ILF_build_a_bfd): Initialise id6.
3843 * aoutx.h (aout_link_input_section_std): Pass "true" to
3844 the undefined_symbol callback.
3845 (aout_link_input_section_ext): Likewise.
3846 * bout.c (get_value): Likewise.
3847 * coff-a29k.c (coff_a29k_relocate_section): Likewise.
3848 * coff-alpha.c (alpha_ecoff_get_relocated_section_conten):
3850 (alpha_relocate_section): Likewise.
3851 * coff-arm.c (coff_arm_relocate_section): Likewise.
3852 * coff-i960.c (coff_i960_relocate_section): Likewise.
3853 * coff-mcore.c (coff_mcore_relocate_section): Likewise.
3854 * coff-mips.c (mips_relocate_section): Likewise.
3855 * coff-ppc.c (coff_ppc_relocate_section): Likewise.
3856 * coff-sh.c (sh_relocate_section): Likewise.
3857 * coff-tic80.c (coff_tic80_relocate_section): Likewise.
3858 * cofflink.c (_bfd_coff_generic_relocate_section): Likewise.
3859 * elf-m10200.c (mn10200_elf_relocate_section): Likewise.
3860 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
3861 * elf32-d10v.c (elf32_d10v_relocate_section): Likewise.
3862 * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
3863 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
3864 * elf32-i370.c (i370_elf_relocate_section): Likewise.
3865 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
3866 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
3867 * elf32-sh.c (sh_elf_relocate_section): Likewise.
3868 * elf32-v850.c (v850_elf_relocate_section): Likewise.
3869 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Likewise.
3870 * elflink.h (elf_link_output_extsym): Likewise.
3871 * pe-mips.c (coff_pe_mips_relocate_section): Likewise.
3872 * reloc.c (bfd_generic_get_relocated_section_conten): Likewise.
3873 * reloc16.c (_bfd_ppc_xcoff_relocate_section): Likewise.
3875 * elf-hppa.h (elf_hppa_relocate_section): Pass "false" to the
3876 undefined_symbol callback when building shared library with
3877 -Bsymbolic and undefined symbols are allowed. Otherwise, pass
3879 * elf32-arm.h (elf32_arm_relocate_section): Likewise.
3880 * elf32-i386.c (elf_i386_relocate_section): Likewise.
3881 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
3882 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
3883 (elf32_mips_get_relocated_section_content): Likewise.
3884 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
3885 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
3886 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
3887 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
3891 * Makefile.am: Add rules to build pe[i]-{sh|mips}.lo objects.
3892 * Makefile.in: Regenerate.
3894 * configure.in: Add support for mips and sh pe vectors.
3895 * configure: regenerate.
3897 * config.bfd: Add support for arm-wince, mips-pe and sh-pe
3900 * targets.c: Add mips and sh pe vectors.
3902 * libpei.h (coff_final_link_postscript): Only define if not
3905 * coffcode.h: Add support for WinCE magic numbers.
3907 * peigen.c (pe_print_reloc): Update comment and rearrange
3908 appending of newline character.
3910 * peicode.h: Add support for Image Library Format.
3911 (pe_ILF_vars): Structure containing data used by ILF code.
3912 (pe_ILF_make_a_section): New function. Create a section based
3914 (pe_ILF_make_a_reloc): New function. Create a reloc based on
3916 (pe_ILF_make_a_symbol): New function. Create a symbol based
3918 (pe_ILF_save_relocs): New function. Store the relocs created
3919 by pe_ILF_make_a_reloc in a section.
3920 (pe_ILF_build_a_bfd): New function. Create a BFD describing
3922 (pe_ILF_object_p): New function. Return a bfd_target pointer
3924 (pe_bfd_object_p): If an ILF object is detected call
3925 pe_ILF_object_p on it.
3927 * coff-arm.c: Add support for WinCE relocs which are different
3928 from normal ARM COFF relocs.
3929 * pe-arm.c: Unset TARGET_UNDERSCORE for a WinCE target.
3931 * coff-sh.c: Add support for sh-pe target.
3932 * pe-sh.c: New file. Support code for sh-pe target.
3933 * pei-sh.c: New file. Support code for sh-pe target.
3935 * pe-mips.c: New file. Support code for mips-pe target.
3936 * pei-mips.c: New file. Support code for mips-pe target.
3940 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data): Don't bump
3941 architecture if the object causing the bump is dynamic.
3942 * elf64-sparc.c (sparc64_elf_merge_private_bfd_data): Likewise,
3943 and also don't it for memory ordering.
3944 (sparc64_elf_write_relocs): Take src_rela out of the loop.
3948 * dwarf2.c (read_abbrevs): Use _raw_size directly rather than
3949 calling bfd_get_section_size_before_reloc.
3950 (decode_line_info): Likewise.
3951 (_bfd_dwarf2_find_nearest_line): Likewise.
3955 * Makefile.am (stamp-lib): Use $(LIBTOOL) --config to get the
3956 name of the libtool directory.
3957 * Makefile.in: Rebuild.
3961 * som.c (SOM_HOWTO): Define.
3962 (som_hppa_howto_table): Use it.
3966 * config.bfd: Enable 64 bit support for GNU/Linux/sparc.
3968 * config.bfd: Enable 64 bit support for Solaris7+/sparc.
3972 * som.c (som_misc_symbol_info): Add field
3974 (som_bfd_derive_misc_symbol_info): Initialize
3976 (som_build_and_write_symbol_table): Keep track
3977 of secondary_def field.
3978 (som_slurp_symbol_table): Set BSF_WEAK symbol flag
3979 if secondary_def field is set.
3980 (som_bfd_ar_write_symbol_stuff): Initialize
3985 * dwarf2.c (read_address): Read 16-bits addresses.
3986 (parse_comp_unit): Accept addr_size == 2.
3990 * bfd-in.h: Update copyright date.
3994 * cpu-i370.c: New file.
3995 * elf32-i370.c: New file.
3996 * archures.c (enum bfd_architecture): Add bfd_arch_i370.
3997 (bfd_i370_arch): New.
3998 (bfd_archures_list): Add bfd_i370_arch.
3999 * elf.c (prep_headers): Add bfd_arch_i370.
4000 * Makefile.am: Add support for IBM 370 elf.
4001 * config.bfd: Likewise.
4002 * configure.in: Likewise.
4003 * libbfd.h (bfd_reloc_code_real_names): Likewise.
4004 * reloc.c (bfd_reloc_code_type): Likewise.
4005 * targets.c: Likewise.
4007 * Makefile.in: Regenerate.
4008 * configure: Regenerate.
4009 * bfd-in2.h: Regenerate.
4013 * elf32-i386.c (elf_i386_info_to_howto_rel): Give a warning for
4014 invalid relocation types, and change them to R_386_NONE.
4018 * elflink.h (elf_link_add_object_symbols): If a version symbol is
4019 not defined, don't add a second ELF_VER_CHR.
4021 * elflink.h (elf_bfd_final_link): Call output_extsym for global
4022 symbols converted to local symbols even when stripping all
4024 (elf_link_output_extsym): Process global symbols converted to
4025 local symbols even if they are being stripped.
4029 * archures.c (bfd_octets_per_byte): Return unsigned int.
4030 (bfd_arch_mach_octets_per_byte): Ditto.
4031 * libbfd.c (bfd_read, bfd_seek): Quell signed vs. unsigned
4033 * section.c (bfd_get_section_size_before_reloc): Quell signed
4034 vs. unsigned comparison warning.
4035 (bfd_get_section_size_after_reloc): Same here. Fix parentheses too.
4036 * trad-core.c (trad_unix_core_file_p): Correct 2000-01-27
4037 change. What was I thinking?
4038 * bfd-in2.h: Regenerate.
4040 * elflink.h (elf_gc_sweep): Skip non-elf input bfds.
4041 (elf_gc_sections): Same here.
4042 (elf_gc_common_finalize_got_offsets): And here.
4046 ELF HPPA doesn't work at present; remove it until it does.
4047 * config.bfd: Comment out setting targ_defvec to
4049 * Makefile.am: Rebuild dependencies.
4050 (BFD32_BACKENDS): Remove elf32-hppa.lo.
4051 (BFD32_BACKENDS_CFILES): Remove elf32-hppa.c.
4052 (SOURCE_HFILES): Remove elf32-hppa.h and hppa_stubs.h.
4053 * Makefile.in: Rebuild.
4054 * targets.c (bfd_target_vector): Comment out bfd_elf32_hppa_vec.
4058 * coffcode.h (coff_set_arch_mach_hook): Use free(), because there
4059 is no bfd_free(). Revert bfd_free part of previous change.
4063 * coffcode.h (coff_set_arch_mach_hook): Don't use variable-size
4065 (coff_compute_section_file_positions): Use bfd_free to pair
4067 (coff_write_object_contents): Likewise.
4069 * coff-rs6000.c (xcoff_howto_table_16): New variable.
4070 (xcoff_rtype2howto): Handle 16-bit variants of 32-bit relocs.
4074 * coff-rs6000.c (XCOFFARMAGBIG): New macro.
4075 (xcoff_ar_file_hdr_big): New structure.
4076 (SIZEOF_AR_FILE_HDR_BIG): New macro.
4077 (xcoff_ar_hdr_big): New structure.
4078 (SIZEOF_AR_HDR_BIG): New macro.
4079 (xcoff_big_format_p): New macro.
4080 (xcoff_ardata_big): New macro.
4081 (arch_xhdr_big): New macro.
4082 (xcoff_slurp_armap): Handle large archives.
4083 (xcoff_archive_p): Detect large archives.
4084 (xcoff_read_ar_hdr): Handle large archives.
4085 (xcoff_openr_next_archived_file): Handle large archives.
4086 (xcoff_generic_stat_arch_elt): Handle large archives.
4087 (xcoff_write_armap_old): Rename from xcoff_write_armap.
4088 (xcoff_write_armap_big): New function.
4089 (xcoff_write_armap): New function, dispatch to _old or _big.
4090 (xcoff_write_archive_contents_old): Rename from
4091 xcoff_write_archive_contents.
4092 (xcoff_write_archive_contents_big): New function.
4093 (xcoff_write_archive_contents): New function, dispatch to _old or
4098 * elf-bfd.h (struct elf_link_hash_table): Remove copy_indirect
4099 and hide_symbol members.
4100 (elf_link_hash_copy_indirect): Remove.
4101 (elf_link_hash_hide_symbol): Remove.
4102 (struct elf_backend_data): Add elf_backend_copy_indirect_symbol
4103 and elf_backend_hide_symbol.
4104 (_bfd_elf_link_hash_copy_indirect): Declare.
4105 (_bfd_elf_link_hash_hide_symbol): Declare.
4106 * elf.c (_bfd_elf_link_hash_copy_indirect): Remove table argument.
4107 (_bfd_elf_link_hash_hide_symbol): Likewise.
4108 (_bfd_elf_link_hash_table_init): Don't init killed members.
4109 * elflink.h (elf_link_add_object_symbols): Use the bed function
4110 pointers not elf_link_hash_{copy_indirect,hide_symbol}.
4111 (elf_link_assign_sym_version): Likewise.
4112 * elfxx-target.h (elf_backend_copy_indirect_symbol): Default.
4113 (elf_backend_hide_symbol): Likewise.
4114 (elfNN_bed): Update for new members.
4118 * rs6000-core.c (CORE_DATA_SIZE_FIELD, CORE_COMM_FIELD, SAVE_FIELD,
4119 STACK_END_ADDR): Define for new core file format.
4120 (LOADER_OFFSET_FIELD, LOADER_REGION_SIZE, CORE_DUMP): New defines
4121 for handling the vagaries of the various core file structures used
4122 by AIX over the years.
4123 (rs6000coff_core_p, rs6000coff_core_file_matches_executable,
4124 Rs6kCorData): Use above defines to adapt code to use AIX 4.3's
4125 core_dumpx structure.
4129 * archures.c (bfd_mach_sh2, bfd_mach_sh_dsp): New macros.
4130 (bfd_mach_sh3_dsp): Likewise.
4131 (bfd_mach_sh4): Reinstate.
4132 (bfd_default_scan): Recognize 7410, 7708, 7729 and 7750.
4133 * bfd-in2.h: Regenerate.
4134 * coff-sh.c (struct sh_opcode): flags is no longer short.
4135 (USESAS, USESAS_REG, USESR8, SETSAS, SETSAS_REG): New macros.
4136 (sh_opcode41, sh_opcode42): Integrate as sh_opcode41.
4137 (sh_opcode01, sh_opcode02, sh_opcode40): Add sh-dsp opcodes.
4138 (sh_opcode41, sh_opcode4, sh_opcode80): Likewise.
4139 (sh_opcodes): No longer const.
4140 (sh_dsp_opcodef0, sh_dsp_opcodef): New arrays.
4141 (sh_insn_uses_reg): Check for USESAS and USESR8.
4142 (sh_insn_sets_reg, sh_insns_conflict): Check for SETSAS.
4143 (_bfd_sh_align_load_span): Return early for SH4.
4144 Modify sh_opcodes lookup table for sh-dsp / sh3-dsp.
4145 Take into account that field b of a parallel processing insn
4146 could be mistaken for a separate insn.
4147 * cpu-sh.c (arch_info_struct): New array elements for
4148 sh2, sh-dsp and sh3-dsp.
4149 Reinstate element for sh4.
4150 (SH2_NEXT, SH_DSP_NEXT, SH3_DSP_NEXT): New macros.
4151 (SH4_NEXT): Reinstate.
4152 (SH3_NEXT, SH3E_NEXT): Adjust.
4153 * elf-bfd.h (_sh_elf_set_mach_from_flags): Declare.
4154 * elf32-sh.c (sh_elf_set_private_flags): New function.
4155 (sh_elf_copy_private_data, sh_elf_set_mach_from_flags): Likewise.
4156 (sh_elf_merge_private_data): New function.
4157 (elf_backend_object_p, bfd_elf32_bfd_set_private_bfd_flags): Define.
4158 (bfd_elf32_bfd_copy_private_bfd_data): Define.
4159 (bfd_elf32_bfd_merge_private_bfd_data): Change to
4160 sh_elf_merge_private_data.
4164 * elf-bfd.h (struct elf_link_hash_table): Add copy_indirect and
4165 hide_symbol members.
4166 (elf_link_hash_copy_indirect): New.
4167 (elf_link_hash_hide_symbol): New.
4168 * elflink.h (elf_link_add_object_symbols): Break out copy from
4169 indirect new new symbol to elf.c.
4170 (elf_link_assign_sym_version): Break out privatization of
4171 non-exported symbol to elf.c.
4172 * elf.c (_bfd_elf_link_hash_copy_indirect): New.
4173 (_bfd_elf_link_hash_hide_symbol): New.
4174 (_bfd_elf_link_hash_table_init): Init copy_indirect and hide_symbol.
4178 * section.c (_bfd_strip_section_from_output): Add info parameter.
4179 If it passed as non-NULL, use it to check whether any input BFD
4180 has an input section which uses this output section. Change all
4182 * bfd-in2.h: Rebuild.
4184 * bfd-in.h: Move declarations of bfd_get_elf_phdr_upper_bound and
4185 bfd_get_elf_phdrs in from bfd-in2.h, correcting patch of
4187 * bfd-in2.h: Rebuild.
4191 * coffswap.h (coff_swap_sym_in): Add hook SWAP_SYM_IN_POST to
4192 allow final modifications of swapped-in symbol.
4193 (coff_swap_sym_out): Ditto with SWAP_SYM_OUT_POST.
4194 * coffcode.h (coff_write_relocs): Use macro
4195 SECTION_RELATIVE_ABSOLUTE_SYMBOL_P if defined to determine whether
4196 symbol index should be set to -1.
4200 * coff-sh.c (USES1_REG, USES2_REG, SETS1_REG, SETS2_REG,
4201 USESF1_REG, USESF2_REG, SETSF1_REG, SETSF2_REG): New macros.
4202 * (sh_insn_sets_reg, sh_insn_sets_freg): New prototypes.
4203 * (sh_insn_sets_reg, sh_insn_uses_or_sets_reg, sh_insns_sets_freg,
4204 sh_insns_uses_or_sets_freg): New functions.
4205 * (sh_insn_uses_reg, sh_insn_uses_freg): Use new macros.
4206 * (sh_insns_conflict): Use new functions and new macros to
4207 detect conflicts when two instructions both set same integer registers,
4208 both set same fp register, and both set special register.
4212 * coffgen.c (coff_real_object_p): Set arch/mach info prior to
4213 swapping in sections, so that the swapping routines have access to
4218 * coff-go32.c: Update comment. Update copyright.
4222 * syms.c (bfd_decode_symclass)
4223 Two new class characters were added - 'V' and 'v'. The
4224 meaning of 'W' is now restricted to just weak non-object
4225 symbols. This allows differentiation between, for example,
4226 weak functions vs weak objects. nm for example now dumps:
4228 'w' = weak unresolved
4229 'V' = weak global object
4230 'v' = weak unresolved object
4232 (bfd_is_undefined_symclass): New function. Return true if the
4233 given symbol class represents and undefined/unresolved symbol.
4235 (bfd_symbol_info): Use bfd_is_undefined_symclass to check for
4238 * bfd-in2.h: Add prototype for bfd_is_undefined_symbol().
4240 * elf32-arm.h (elf32_arm_get_symbol_type): If a symbol has the
4241 STT_ARM_16BIT flag set, but it is not attached to a data object
4242 return STT_ARM_16BIT so that it will be treated as code by the
4247 * coff-i386.c (i3coff_object_p): Remove prototype.
4250 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Add const
4251 to name. Update copyright.
4253 * trad-core.c (trad_unix_core_file_p): Cast core_regsec
4254 assignment to avoid warning. Update copyright.
4258 * coffcode.h (coff_write_object_contents): Get buff via bfd_malloc
4259 instead of using GNU C extension.
4263 * libbfd.c (bfd_read): Do not attempt to get a negativly sized
4264 amount from a bfd_in_memory structure.
4265 (bfd_seek): Do not allow seeks past the end of a bfd_in_memory
4270 * linker.c (default_indirect_link_order): oops - fix incorrectly
4271 applied patch from Tim Wall.
4275 * coffcode.h: Use bfd_coff_xxx instead of the macro XXX (where xxx
4276 = scnhsz, filhsz, relsz, aoutsz, etc)
4278 * coffswap.h: Ditto.
4282 * elf32-arm.h (elf32_thumb_to_arm_stub): Fix offset in branch to
4283 interwork thumb to arm stub.
4287 * archures.c (bfd_octets_per_byte): New function: Return
4289 (bfd_arch_mach_octets_per_byte): New function: Return target
4292 * section.c: Distinguish between octets and bytes for usage of
4293 _cooked_size, _raw_size, and output_offset. Clarify
4294 description of bfd_set_section_contents.
4296 * bfd-in2.h: Regenerate.
4298 * coffgen.c: Indicate that the offset parameter is in bytes, not
4301 * cofflink.c (bfd_coff_link_input_bfd): Use bfd_octets_per_byte
4302 where appropriate to get the octet offset when calling
4303 bfd_set_section_contents.
4304 (bfd_coff_reloc_link_order): Ditto.
4306 * linker.c (bfd_generic_reloc_link_order): Ditto.
4307 (_bfd_default_link_order): Ditto.
4309 * reloc.c (bfd_perform_relocation): Distinguish between octets
4310 and bytes. Use octets when indexing into octet data; use bytes
4311 when calculating target addresses.
4312 (bfd_install_relocation): Ditto.
4314 * srec.c (srec_write_section): Ditto.
4318 * coff-mcore.c (COFF_DEFAULT_SECTION_ALIGNMENT_POWER): Change from
4319 3 to 2. This allows 4 byte sized sections, which is necessary for
4320 dlltool to build functioning DLLs.
4324 * config.bfd (arm*-*-linux-gnu*): Match instead of arm*-*-linux-gnu.
4325 (arm*-*-conix*): New target.
4329 * config.bfd: Include elf32_i386 vector to target list for cygwin
4332 * config.in: Undefine HAVE_WIN32_PSTATUS_T.
4333 * configure.in: Test for structure win32_pstatus_t in
4335 * configure: Regenerate.
4337 * elf.c (elfcore_grok_win32pstatus): New function: process
4338 win32_pstatus_t notes in elf core file.
4339 (elfcore_grok_note): Detect win32_pstatus notes.
4343 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Process symbol
4345 * elflink.h (elf_link_add_object_symbols): Combine visibilities.
4346 * elf.c (bfd_elf_print_symbol): Interpret st_other as visibility.
4348 For older changes see ChangeLog-9899
4354 version-control: never