X-Git-Url: https://git.libre-soc.org/?a=blobdiff_plain;f=bfd%2FChangeLog;h=f169f3db3ecc5901bbaecd8da18e47d844a1e7a8;hb=aac6b32f3129e8a9b2856fd3fb80c4613bddd455;hp=571c59786a3366c5257cc953c24306a3ef735576;hpb=459ae909b9afdda03da2255929ba1ec14a233ce9;p=binutils-gdb.git diff --git a/bfd/ChangeLog b/bfd/ChangeLog index 571c59786a3..f169f3db3ec 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,642 @@ +Mon Jun 20 11:06:27 1994 Ian Lance Taylor (ian@sanguine.cygnus.com) + + * ecoff.c (ecoff_swap_tir_in): Change input argument to const. + (ecoff_swap_tir_out): Likewise. + (ecoff_swap_rndx_in, ecoff_swap_rndx_out): Likewise. + (ecoff_slurp_symbolic_info): Add new arguments to correspond to + read_debug_info entry point in ecoff_debug_swap structure. + Change all calls. + * libecoff.h (ecoff_slurp_symbolic_info): Change declaration. + * ecoffswap.h (ecoff_swap_tir_in, ecoff_swap_tir_out): Declare. + (ecoff_swap_rndx_in, ecoff_swap_rndx_out): Declare. + * coff-alpha.c (alpha_ecoff_backend_data): Initialize new + ecoff_debug_swap fields. + * coff-mips.c (mips_ecoff_backend_data): Likewise. + * elf32-mips.c (mips_elf_read_ecoff_info): Undefine READ. + (mips_elf_ecoff_debug_swap): Initialize new ecoff_debug_swap + fields. + * configure.in (bfd_elf32_bigmips_vec): Use ecoff.o and + ecofflink.o. + (bfd_elf32_littlemips_vec): Likewise. + (ecoff_big_vec, ecoff_little_vec): Likewise. + (ecoffalpha_little_vec): Likewise. + * Makefile.in (BFD_LIBS): Remove ecoff.o and ecofflink.o. + (BFD32_BACKENDS): Add ecoff.o and ecofflink.o. + + * aoutx.h (NAME(aout,final_link)): Check flavour of sub, not abfd, + when computing reloc sizes. From Eric Youngdale + . + * elfcode.h (elf_bfd_final_link): Don't try to compute maximum + reloc count or size for a non-ELF file. + + * mipsbsd.c (MY_final_link_callback): Define to avoid warning. + + * hp300hpux.c (MY_final_link_callback): Define to avoid warning. + (BMAGIC, QMAGIC): Define; used by aoutx.h. + (MY(slurp_symbol_table)): Change translate_from_native_sym_flags + calls to use new parameters. + +Fri Jun 17 14:45:32 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) + + * aout-target.h (MY(callback)): Set the alignments of the text, + data and bss sections after determining the architecture. + + * sunos.c (sunos_add_one_symbol): Treat a common symbol from a + dynamic object as being in the .bss section of the object, rather + than as being undefined. + +Fri Jun 17 11:16:50 1994 Jeff Law (law@snake.cs.utah.edu) + + * libhppa.h (bfd_hppa_insn2fmt, hppa_rebuild_insn): Make INLINE. + + * elf32-hppa.h (elf_hppa_final_processing): Delete decl. + +Thu Jun 16 23:36:23 1994 Jeff Law (law@snake.cs.utah.edu) + + * elfcode.h (elf_link_input_bfd): Don't try to read local symbols + if there aren't any in the input file. + +Thu Jun 16 14:25:22 1994 Eric Youngdale (ericy@cais.cais.com) + + * i386linux.c: Many new functions and definitions for linker + support for Linux shared libraries. + * bfd-in.h (bfd_linux_size_dynamic_sections): Declare. + * bfd-in2.h: Rebuild. + +Thu Jun 16 14:23:46 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) + + * config.bfd: If second argument is ``_'', then, instead of + echoing config file name, echo whether target uses leading + underscores on symbol names. Add appropriate settings to + different cases. Used by binutils/configure.in to set default for + c++filt. + + * elfcode.h (elf_bfd_final_link): If trying to generate a shared + object, warn and return false. + + * aoutx.h (NAME(aout,some_aout_object_p)): Accept BMAGIC objects + and treat them as OMAGIC. + +Wed Jun 15 18:02:21 1994 Ken Raeburn (raeburn@cujo.cygnus.com) + + Enable sparc v9 support for release. Note that this is still a + work in progress, pending release of an ABI specification. + * config.bfd, configure.in: Include sparc v9 elf config. + * elfcode.h (prep_headers): Handle sparc v9 (64 bit). + * reloc.c (bfd_reloc_code_real): New reloc types. + * elf64-sparc.c: Implement elf64-sparc target. + * Makefile.in, targets.c: Updated. + +Wed Jun 15 01:34:07 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) + + * libelf.h (struct elf_obj_tdata): New field dt_needed_name. + (elf_dt_needed_name): New accessor macro. + * elfcode.h (elf_link_add_object_symbols): If elf_dt_needed_name + is set, use that instead of the filename for the DT_NEEDED dynamic + entry. + * elf.c (bfd_elf_set_dt_needed_name): New function. + * bfd-in.h (bfd_elf_set_dt_needed_name): Declare. + * bfd-in2.h: Rebuilt. + + * elfcode.h (NAME(bfd_elf,size_dynamic_sections)): Add sinterpptr + argument, and set it to the .interp section. + * bfd-in.h (bfd_elf32_size_dynamic_sections): Update prototype. + (bfd_elf64_size_dynamic_sections): Likewise. + * bfd-in2.h: Rebuilt. + + * coff-sparc.c (SWAP_OUT_RELOC_EXTRA): Define to clear the r_spare + field of the reloc rather than letting it be garbage. + + * archive.c (bfd_slurp_armap): Recognize __.SYMDEF/ as well as + __.SYMDEF; the former was used in old Linux archives. From + jrs@world.std.com (Rick Sladkey). + + * i386linux.c (i386linux_write_object_contents): Define; like + MY(write_object_contents) in aout-target.h, but set MACHTYPE to + M_386. From jrs@world.std.com (Rick Sladkey). + (MY_write_object_contents): Define. + + * aoutx.h (translate_from_native_sym_flags): Treat N_SETV symbols + as N_DATA symbols. + (aout_link_add_symbols): Likewise. + + * aoutx.h: Rewrite symbol duplicate elimination to use BFD hash + tables. + (struct stringtab_entry, struct stringtab_data): Remove. + (HASHMAXLEN, HASH_CHAR, hash, compare, log2, emit_strtab): Remove. + (struct strtab_hash_entry, struct strtab_hash): Define. + (strtab_hash_newfunc, strtab_hash_lookup): Define. + (stringtab_free, emit_stringtab): Define. + (stringtab_init, add_to_stringtab): Rewrite. + (NAME(aout,write_syms)): Use new stringtab code. + (struct aout_final_link_info, NAME(aout,final_link)): Likewise. + (aout_link_write_symbols, aout_link_write_other_symbol): Likewise. + + * bfd-in.h (BFD_TRADITIONAL_FORMAT): Define new BFD flag to + request BFD to write object in the traditional format, whatever + that means for the particular backend. + * bfd-in2.h: Rebuilt. + + * hash.c (bfd_hash_allocate): If obstack_alloc fails, set + bfd_error_no_memory. + +Tue Jun 14 13:00:04 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) + + * libaout.h (struct aoutdata): Add q_magic_format to subformat + enum. + * aout-target.h (MY_bfd_copy_private_bfd_data): Define as function + if not already defined. Copy subformat information. + (MY_text_includes_header): Define as 0 if not already defined. + (MY(backend_data)): Use MY_text_includes_header rather than 0. + (MY_final_link_callback): Rename from final_link_callback, and + define only if MY_final_link_callback is not already defined. + (MY_bfd_final_link): Rename use of final_link_callback to + MY_final_link_callback. + * aoutx.h (NAME(aout,some_aout_object_p)): Handle QMAGIC like + ZMAGIC, but set the subformat to q_magic_format. Abort if the + magic number if not recognized. + (adjust_z_magic): Use QMAGIC if q_magic_format. + * i386linux.c (MY_text_includes_header): Define as 1. + (i386linux_bfd_final_link): New static function. + (MY_bfd_final_link): Define as i386linux_bfd_final_link. + + * aoutx.h (translate_to_native_sym_flags): Check both section and + output_section against sections of abfd. + + * libecoff.h (struct ecoff_link_hash_entry): Change type of + written from boolean to char. Add new field small. + * ecoff.c (ecoff_link_hash_newfunc): Initialize written to 0 + rather than false. Initialize small to 0. + (ecoff_link_add_externals): If ECOFF type is scSUndefined, set + small. If small is set, and hash table type is common, force the + symbol into a section named SCOMMON and change the ECOFF type from + scCommon to scSCommon. + (ecoff_link_write_external): Set written to 1 rather than true. + * coff-mips.c (mips_relocate_section): Correct JMPADDR reloc + overflow check to consider section VMA of input file. + +Mon Jun 13 14:20:07 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) + + * aoutf1.h (aout_32_sunos4_write_object_contents): Handle a + machine type of 68000. + * aoutx.h (NAME(aout,machine_type)): Add new argument unknown. + Set *unknown to true if machine type is really unknown, as opposed + to M_UNKNOWN for the 68000. + (NAME(aout,set_arch_mach)): Change NAME(aout,machine_type) call + accordingly. + * libaout.h (NAME(aout,machine_type)): Add new argument to + prototype. + +Sun Jun 12 20:21:03 1994 Jeff Law (law@snake.cs.utah.edu) + + * som.c (EXEC_AUX_ID): Define based on availablity of HPUX_AUX_ID + or HIUX_AUX_ID. + (som_begin_writing): Use EXEC_AUX_ID instead of HPUX_AUX_ID. + (som_write_armap): Use CPU_PA_RISC1_0 as the magic number. Note + som.c is careful to always define CPU_PA_RISC1_0. + +Sat Jun 11 16:32:30 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) + + Add weak symbols as an extension to a.out. + * aoutx.h (sym_in_text_section): Don't define. + (sym_in_data_section, sym_in_bss_section): Likewise. + (sym_is_undefined, sym_is_global_defn): Likewise. + (sym_is_debugger_info, sym_is_fortrancommon): Likewise. + (sym_is_absolute, sym_is_indirect): Likewise. + (translate_from_native_sym_flags): Rewrite for clarity. Rearrange + arguments and change caller. Handle weak symbols. + (translate_to_native_sym_flags): Likewise. + (aout_link_check_ar_symbols): Don't ignore weak symbols. Pull + object in from archive if a weak defintion is found for an + existing undefined symbol. + (aout_link_add_symbols): Put all cases in switch. Set flags of an + undefined symbol to 0. Handle weak symbols. + (aout_link_write_symbols): Handle weak symbols. + (aout_link_write_other_symbol): Likewise. + (aout_link_input_section_std): Likewise. + (aout_link_input_section_ext): Likewise. + * sunos.c (sunos_write_dynamic_symbol): Likewise. + +Fri Jun 10 13:25:13 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) + + * aoutx.h (NAME(aout,canonicalize_reloc)): Handle .bss section. + (NAME(aout,get_reloc_upper_bound)): Likewise. + + * coff-i960.c (coff_i960_reloc_type_lookup): Add BFD_RELOC_CTOR. + * linker.c (_bfd_generic_link_write_global_symbol): Don't assume + the section of a common symbol is not NULL. + +Wed Jun 8 23:15:53 1994 Stu Grossman (grossman@cygnus.com) + + * nlmcode.h (nlm_object_p): Set EXEC_P and start address for GDB. + +Wed Jun 8 23:57:34 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) + + * aoutx.h (aout_get_external_symbols): Don't try to read the + strings if there are no symbols. + (aout_link_write_other_symbol): Use the output section when + working out the type. + +Tue Jun 7 13:25:08 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) + + * elfcode.h (assign_section_numbers): Put shstrtab, symtab and + strtab sections at end of file. Avoids bug in some versions of + SVR4 strip. From Eric Youngdale . + + * coffcode.h (styp_to_sec_flags): If COFF_PAGE_SIZE is defined, + set SEC_DEBUGGING for STYP_INFO sections. + (coff_compute_section_file_positions): If COFF_PAGE_SIZE is + defined, and D_PAGED is set, set the file position equal to the + section VMA modulo COFF_PAGE_SIZE. + * coffgen.c (coff_real_object_p): If F_EXEC is set, set D_PAGED. + * coff-i386.c: Set D_PAGED in BFD target. + (COFF_PAGE_SIZE): Define. + * coff-m68k.c, coff-sparc.c: Likewise. + +Mon Jun 6 10:57:28 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) + + * elfcode.h (bfd_section_from_shdr): Don't turn a reloc section + into a BFD section just because SHF_ALLOC is set; require that it + not use the normal symbol table. + (elf_section_from_bfd_section): Corresponding change. + + Better indirect and warning symbol handling inspired by Stuart + Quick . + * linker.c (enum link_action): Add REF, MIND, CWARN, REFC. + (link_action): Change UNDEF_ROW/def and UNDEFW_ROW/def from NOACT + to REF. Change UNDEF_ROW/indr and UNDEFW_ROW/indr from CYCLE to + REFC. Change DEF_ROW/indr and COMMON_ROW/indr from CYCLE to MDEF. + Change DEFW_ROW/indr from CYCLE to NOACT. Change INDR_ROW/indr + from MDEF to MIND. Change INDR_ROW/warn from WARNC to CYCLE. + Change WARN_ROW/def and WARN_ROW/indr from MWARN to CWARN. Change + WARN_ROW/com from MWARN to WARN. Change WARN_ROW/warn from NOACT + to CYCLE. Change SET_ROW/warn from WARNC to CYCLE> + (_bfd_generic_link_add_one_symbol): Handle REF, MIND, CWARN and + REFC. If a new indirect symbol has been referenced, push the + reference down to the symbol it points to. FIx handling of WARN. + * aoutx.h (translate_from_native_sym_flags): If N_WARNING, don't + clobber e_type of next symbol. + (translate_to_native_sym_flags): Likewise. + (aout_link_write_symbols): Loop on bfd_link_hash_warning as well + as bfd_link_hash_indirect. + + * libaout.h (struct aout_link_hash_entry): New field written. + * aoutx.h (NAME(aout,link_hash_newfunc)): Initialize written. + (aout_link_write_symbols): Use written, not root.written. + (aout_link_write_other_symbol): Likewise. + * sunos.c (sunos_scan_dynamic_symbol): Likewise. + * libecoff.h (struct ecoff_link_hash_entry): New field written. + * ecoff.c (ecoff_link_hash_newfunc): Initialize written. + (ecoff_link_write_external): use written, not root.written. + * genlink.h (struct generic_link_hash_entry): New field written. + * linker.c (_bfd_link_hash_newfunc): Don't initialize written. + (generic_link_hash_newfunc): Initialize written. + (_bfd_generic_link_output_symbols): Use written, not root.written. + (_bfd_generic_link_write_global_symbol): Likewise. + (_bfd_generic_reloc_link_order): Likewise. + + * libecoff.h (ecoff_data_type): Add linker field. + * ecoff.c (ecoff_write_object_contents): Check new tdata linker + field, rather than outsymbols being non-NULL, to decide whether to + output the symbols and relocs. + (ecoff_bfd_final_link): Set new tdata linker field to true. + + * ecoff.c (ecoff_bfd_copy_private_bfd_data): Don't try to copy + data to a non-ECOFF file. + + * libbfd-in.h: Add warning that libbfd.h is a generated file. + * libbfd.h: Rebuilt. + +Sun Jun 5 15:02:30 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) + + Changes to support ELF strip and objcopy on dynamically linked + files. + * elfcode.h (elf_fake_sections): Add prototype. + (bfd_section_from_shdr): Make a BFD section from an SHT_HASH + section, and from an SHT_DYNSYM section, and from the dynamic + string table section. + (elf_object_p): Set D_PAGED if there is a program header. + (elf_make_sections): Remove. + (fix_up_strtabs): Remove. + (elf_fake_sections): Rewrite. Now sets sh_entsize. + (assign_section_numbers): Rewrite. Now sets sh_link and sh_info + for all sections. + (elf_compute_section_file_positions): Don't call obsolete + functions elf_make_sections or fix_up_strtabs. + (swap_out_syms): Set sh_addralign to FILE_ALIGN rather than 4. + (NAME(bfd_elf,write_object_contents)): Permit writing DYNAMIC + objects. + (elf_section_from_bfd_section): Treat SHT_DYNSYM like other normal + sections. If an SHT_REL or SHT_RELA section is allocated or uses + an unusual symbol table, permit a BFD section to map to it. + Permit most SHT_STRTAB sections to have a BFD section mapped to + them. + (elf_bfd_final_link): Don't set sh_link, sh_info or sh_entsize + fields of dynamic sections here; do it in assign_section_numbers. + * elf32-target.h, elf64-target.h: Add D_PAGED to permitted object + flags. + + * elf.c (_bfd_elf_make_section_from_shdr): Only set SEC_DATA if + SEC_LOAD is set, rather than checking SEC_ALLOC. + + * libbfd-in.h (bfd_realloc): Change last arg to "size_t size". + +Fri Jun 3 10:58:02 1994 Jeff Law (law@snake.cs.utah.edu) + + * som.c (som_write_object_contents): Don't compute the file header's + checksum here. + (som_write_headers): Instead do it here. + + * libbfd.h (bfd_realloc): Change last arg to "size_t size". + +Thu Jun 2 17:39:22 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) + + * hosts/sun3.h: Include . Don't declare free, exit or + getenv. + + Add linker support for SunOS shared libraries. + * sunos.c: Include bfdlink.h. Add many new functions and + definitions for SunOS shared library support. + * bfd-in.h (bfd_sunos_record_link_assignment): Declare. + (bfd_sunos_size_dynamic_sections): Declare. + * bfd-in2.h: Rebuilt. + * aoutx.h (struct aout_link_hash_entry): Move to libaout.h. + (struct aout_link_hash_table): Likewise. + (aout_link_hash_lookup, aout_link_hash_traverse): Likewise. + (aout_hash_table): Likewise. + (NAME(aout,link_hash_newfunc)): Rename from aout_link_hash_newfunc + and make externally visible. + (NAME(aout,link_hash_table_init)): New function. + (NAME(aout,link_hash_table_create)): Call + NAME(aout,link_hash_table_init), not _bfd_link_hash_table_init. + (aout_link_add_symbols): Don't fail if no symbols. If it exists, + call add_dynamic_symbols backend entry point for dynamic objects. + Use add_one_symbol backend entry point if it exists. + (NAME(aout,final_link)): Call finish_dynamic_link backend entry + point, if it exists. + (aout_link_input_bfd): For a dynamic object, call + link_dynamic_object backend entry point, if it exists. + (aout_link_write_other_symbol): Call write_dynamic_symbol backend + entry point, if it exists. + (aout_link_input_section): Don't read the relocs if they have + already been read. + (aout_link_input_section_std): When doing a final link, for a + reloc against an external symbol, call check_dynamic_reloc backend + entry point, if it exists. + (aout_link_input_section_ext): Likewise. + * libaout.h: Protect against multiple inclusion. Include + bfdlink.h. + (struct aout_link_hash_entry): Move in from aoutx.h. + (struct aout_link_hash_table): Likewise. + (aout_link_hash_lookup, aout_link_hash_traverse): Likewise. + (aout_hash_table): Likewise. + (struct aout_backend_data): Add fields add_dynamic_symbols, + add_one_symbol, link_dynamic_object, write_dynamic_symbol, + check_dynamic_reloc, and finish_dynamic_link. + (struct aout_section_data_struct): Define new structure. + (aout_section_data): Define new accessor macro. + (NAME(aout,link_hash_newfunc)): Declare. + (NAME(aout,link_hash_table_init)): Declare. + * aoutf1.h (sunos4_aout_backend): Initialize new aout_backend_data + fields. + * aout-target.h (MY(backend_data)): Likewise. + * i386aout.c (MY(backend_data)): Likewise. + * i386mach3.c (MY(backend_data)): Likewise. + * mipsbsd.c (MY(backend_data)): Likewise. + * sparclynx.c (sparclynx_aout_backend): Likewise. + + * aoutx.h (NAME(aout,slurp_symbol_table)): Don't zero out cached + until we know it is non-NULL. + (aout_link_write_symbols): Don't skip a warning symbol even if it + has already been written out. If skipping an indirect symbol, + skip the next symbol as well. + +Wed Jun 1 14:37:50 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) + + * hosts/sun3.h: Don't declare qsort, malloc or realloc. + +Thu May 26 13:56:03 1994 Ken Raeburn (raeburn@cujo.cygnus.com) + + * nlmcode.h (nlm_swap_auxiliary_headers_in): Cast bfd_byte pointer + to char pointer to avoid compiler warnings. + + * dep-in.sed: Remove spaces before colons. + + Merged changes back in from FSF gas release 2.3: + + * Makefile.in (stmp-bfd.h): Wrap `if' block around grep + invocation, to avoid a bug in BSD 4.4 make. + + From Ralph Campbell: + * mipsbsd.c (mips_fix_jmp_addr): If symbol is undefined, return an + error. + (mips_fix_hi16_s): Ditto. + + Fri May 13 21:21:00 1994 DJ Delorie (dj@ctron.com) + + * makefile.dos: define a default target, or archives won't work + due to multiple matches. + + Wed May 11 22:32:00 1994 DJ Delorie (dj@ctron.com) + + * configure.bat: update for latest files + * makefile.dos: update for correct targets and sources + * coff-go32.c: [new] go32's COFF format (i386coff with underscores) + * targets.c: add go32coff target + * makefile.in: add coff-go32.c support + +Thu May 26 10:10:21 1994 Jeff Law (law@snake.cs.utah.edu) + + * som.c (som_prep_headers): Do not set the system_id here, private + bfd data has not been copied yet. + (som_write_headers): Instead do it here. + +Tue May 24 16:17:18 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) + + Make MIPS ELF use new ELF backend linker. No shared library + support yet. + * elf32-mips.c (bfd_mips_elf32_swap_gptab_in): New function. + (bfd_mips_elf32_swap_gptab_out): New function. + (mips_elf_object_p): If last symbol is LOCAL, set elf_bad_symtab. + (mips_elf_final_write_processing): Set sh_info field for .gptab.* + sections. + (mips_elf_fake_sections): Set sh_entsize for .gptab.* sections. + (mips_elf_read_ecoff_info): Read and free external symbols last, + not first, for clarity. + (struct mips_elf_link_hash_entry): Define new structure. + (struct mips_elf_link_hash_table): Define new structure. + (mips_elf_link_hash_lookup): Define new macro. + (mips_elf_link_hash_traverse): Define new macro. + (mips_elf_hash_table): Define new macro. + (mips_elf_link_hash_newfunc): New static function. + (mips_elf_link_hash_table_create): New static function. + (mips_elf_add_symbol_hook): New static function. + (struct extsym_info): Define new structure. + (mips_elf_get_extr, mips_elf_set_index): Remove. + (mips_elf_output_extsym): New static function. + (gptab_compare): New static function. + (mips_elf_final_link): Rewrite to use ELF backend linker, and to + merge gptab information in input files. + (mips_elf_relocate_hi16): New static function. + (mips_elf_relocate_section): New static function. + (bfd_elf32_bfd_link_hash_table_create): Define as macro before + including elf32-target.h. + (elf_backend_relocate_section): Likewise. + (elf_backend_add_symbol_hook): Likewise. + * elf.c (_bfd_elf_link_hash_newfunc): Rename from + elf_link_hash_newfunc and make globally visible. Change caller. + (_bfd_elf_link_hash_table_init): New function, broken out of + _bfd_elf_link_hash_table_create. + (_bfd_elf_link_hash_table_create): Use + _bfd_elf_link_hash_table_init. + * libelf.h (struct elf_obj_tdata): Add new field bad_symtab. + (elf_bad_symtab): Define new accessor macro. + (_bfd_elf_link_hash_newfunc): Declare. + (_bew_elf_link_hash_table_init): Declare. + * elfcode.h (elf_object_p): Call backend object_p hook after + swapping in all the section headers. + (map_program_segments): Correct typo: Internal for External. + (elf_link_add_object_symbols): If elf_bad_symtab is set, read all + the symbols. Skip STB_LOCAL symbols rather than giving an error. + (elf_bfd_final_link): If elf_bad_symtab is set, allocate space for + all symbols, not just locals. + (elf_link_output_extsym): Only skip a symbol not mentioned by a + regular file if it is mentioned by a dynamic object. + (elf_link_input_bfd): If elf_bad_symtab is set, read all the + symbols. + +Fri May 20 13:38:23 1994 Jeff Law (law@snake.cs.utah.edu) + + * som.c (som_set_reloc_info): Do not set any relocation info + for SOM fixups which are never passed to BFD. + +Fri May 20 11:57:05 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) + + * coff-mips.c (mips_relocate_section): Add MIPS_R_JMPADDR overflow + checking. + + * elf32-i386.c (elf_i386_size_dynamic_sections): Add DT_DEBUG to + the dynamic linking information for the benefit of the debugger. + From Peter Schauer. + * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise. + + * elf.c (_bfd_elf_make_section_from_shdr): New function, based on + code repeated three times in bfd_section_from_shdr in elfcode.h. + * libelf.h (_bfd_elf_make_section_from_shdr): Declare. + * elfcode.h (bfd_section_from_shdr): Use new function + _bfd_elf_make_section_from_shdr to create BFD sections. If a + reloc section does not use the main symbol table, or it is part of + the process image, treat it as a normal section, not relocs. + * elf32-mips.c (mips_elf_section_from_shdr): Use new function + _bfd_elf_make_section_from_shdr. + +Thu May 19 11:37:11 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) + + * elf32-target.h, elf64-target.h: Change ar_max_namelen value from + 15 to 14 to match SVR4 ar. + + Add support for ELF shared libraries. Loosely based on work by + Eric Youngdale . + * libelf.h (struct elf_backend_data): Add new fields for dynamic + linking: elf_backend_create_dynamic_sections, + elf_backend_adjust_dynamic_symbol, + elf_backend_size_dynamic_sections, + elf_backend_finish_dynamic_symbol, + elf_backend_finish_dynamic_sections. + (struct elf_link_hash_entry): Change type of align field to + bfd_size_type. Add fields dynindx, dynstr_index, weakdef, + elf_link_hash_flags. + (struct elf_link_hash_table): Add fields dynobj, dynsymcount, + dynstr, bucketcount. + (bfd_elf32_swap_reloc_in, bfd_elf32_swap_reloc_out): Declare. + (bfd_elf32_swap_reloca_in, bfd_elf32_swap_reloca_out): Declare. + (bfd_elf32_swap_dyn_in, bfd_elf32_swap_dyn_out): Declare. + (bfd_elf32_add_dynamic_entry): Declare. + (bfd_elf64_swap_reloc_in, bfd_elf64_swap_reloc_out): Declare. + (bfd_elf64_swap_reloca_in, bfd_elf64_swap_reloca_out): Declare. + (bfd_elf64_swap_dyn_in, bfd_elf64_swap_dyn_out): Declare. + (bfd_elf64_add_dynamic_entry): Declare. + * elfcode.h (Elf_External_Dyn): Define. + (elf_swap_reloc_in): Define as macro using NAME. Make externally + visible. + (elf_swap_reloc_out): Likewise. + (elf_swap_reloca_in, elf_swap_reloca_out): Likewise. + (elf_swap_dyn_in, elf_swap_dyn_out): Define as macro using NAME + and as new externally visible function. + (elf_fake_sections): Set section type of dynamic sections based on + section names. + (elf_write_phdrs): Remove. + (assign_file_position_for_section): Add new align argument. + Change all callers. + (get_program_header_size): New static function. + (struct seg_info): Remove. + (map_program_segments): Completely rewrite. + (assign_file_positions_except_relocs): Completely rewrite. + (assign_file_positions_for_relocs): Don't set a file position for + sections which already have one. Don't bother to align the file + position here. + (section_from_elf_index): Handle SHT_HASH and SHT_DYNAMIC + section types. + (elf_section_from_bfd_section): Likewise. + (elf_slurp_symbol_table): If section_from_elf_index fails, just + use bfd_abs_section rather than returning an error. + (elf_sizeof_headers): Make useful. + (elf_link_record_dynamic_symbol): New static function. + (elf_link_add_object_symbols): Handle dynamic objects. + (elf_link_create_dynamic_sections): New static function. + (elf_add_dynamic_entry): Define as macro using NAME and as new + externally visible function. + (NAME(bfd_elf,record_link_assignment)): New function. + (elf_buckets): New static variable. + (NAME(bfd_elf,size_dynamic_sections)): New function. + (struct elf_final_link_info): Add dynsym_sec and hash_sec fields. + (elf_bfd_final_link): Handle dynamic linking. Create a section + symbol for all ELF sections, not all BFD sections. Store section + symbol index in target_index field, not index field. Traverse + over global symbols even if stripping. + (elf_link_output_extsym): Output dynamic symbols. Mark symbols + defined by dynamic objects as undefined. + (elf_link_input_bfd): Ignore dynamic objects. Use target_index + field for section relocs, and make sure it is set. + (elf_reloc_link_order): Use target_index field for section relocs, + and make sure it is set. + * elf.c (elf_link_hash_newfunc): Initialize dynindx, dynstr_index, + weakdef and elf_link_hash_flags fields. + (_bfd_elf_link_hash_table_create): Initialize dynobj, dynsymcount, + dynstr and bucketcount fields. + * elf32-target.h: Initialize new dynamic linking fields. + * elf64-target.h: Likewise. + * elf32-i386.c: New functions for dynamic linking support. + * elf32-sparc.c: Likewise. + * bfd-in.h (bfd_elf32_record_link_assignment): Declare. + (bfd_elf64_record_link_assignment): Declare. + (bfd_elf32_size_dynamic_sections): Declare. + (bfd_elf64_size_dynamic_sections): Declare. + * bfd-in2.h: Rebuilt. + +Wed May 18 08:29:04 1994 Ian Lance Taylor (ian@cygnus.com) + + * som.c: Don't include or . + (som_reloc_queue_find): Call memcmp instead of bcmp. + (som_bfd_reloc_type_lookup): Change first argument to bfd *. + (compare_syms): Change types of arguments to const void *. + (bfd_section_from_som_symbol): Removed unused local found. + (som_write_armap): Add elength, map, orl_count and int arguments. + (som_write_armap): Use %ld and cast to long for getuid result. + +Wed May 18 09:09:32 1994 Jeff Law (law@snake.cs.utah.edu) + + * elf32-hppa.h (R_HPPA_ABS_CALL): Define. + * elf32-hppa.c (hppa_elf_gen_reloc_type): Handle absolute calls. + + * som.h (R_HPPA_ABS_CALL): Define. + * som.c (hppa_som_gen_reloc_type): Delete complex relocation types. + +Tue May 17 19:33:12 1994 Ken Raeburn (raeburn@cujo.cygnus.com) + + * coff-i960.c (icoff_little_vec, icoff_big_vec): Indicate leading + underscore, for compatibility with Intel tool chain (gnu960v2). + Mon May 16 10:09:22 1994 Jeff Law (law@snake.cs.utah.edu) * bfd-in2.h: Rebuilt. @@ -161,20 +800,6 @@ Fri May 6 11:48:55 1994 Steve Chamberlain (sac@cygnus.com) * Makefile.in: Build sysdep.h without causing worrying but harmless error message. -Fri May 6 13:34:14 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) - - * nlmcode.h (nlm_swap_auxiliary_headers_in): Rework custom header - handling for latest suggested format. - (nlm_swap_auxiliary_headers_out): Likewise. - (nlm_compute_section_file_positions): Likewise. - -Thu May 5 15:40:47 1994 Ken Raeburn (raeburn@cujo.cygnus.com) - - Patches from Ralph Campbell: - * mipsbsd.c (mips_fix_jmp_addr): New function. - (mips_fix_hi16_s): Use bfd_is_com_section. - (mips_howto_table_ext): Call mips_fix_jmp_addr for MIPS_RELOC_JMP. - Wed May 4 11:09:53 1994 Ian Lance Taylor (ian@cygnus.com) Changed m68k-aout to set flags to 0; m68k-sunos still uses 1. @@ -407,11 +1032,9 @@ Wed Apr 20 16:45:51 1994 Ken Raeburn (raeburn@cujo.cygnus.com) ones defined in stdlib.h. (From Minh Tran-Le.) Wed Apr 20 14:15:21 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) -start-sanitize-powerpc-netware * nlm32-ppc.c: Complete rewrite for new version of PowerPC NetWare. Old code still present, but ifdeffed out. -end-sanitize-powerpc-netware * nlmcode.h (nlm_swap_auxiliary_headers_in): Don't assume a particular format for the customer header. Allocate a block of @@ -1540,9 +2163,7 @@ Mon Mar 14 11:41:23 1994 Jeffrey A. Law (law@snake.cs.utah.edu) Sat Mar 12 09:46:09 1994 Ian Lance Taylor (ian@cygnus.com) * elf32-ppc.c: Renamed from elf32-powerpc.c. - start-sanitize-powerpc-netware * nlm32-ppc.c: Renamed from nlm32-powerpc.c. - end-sanitize-powerpc-netware * Makefile.in, configure.in: Corresponding changes. Fri Mar 11 22:27:19 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) @@ -1831,7 +2452,6 @@ Sat Feb 19 03:17:32 1994 Peter Schauer (pes@regent.e-technik.tu-muenchen.de) Fri Feb 18 11:41:58 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) - start-sanitize-powerpc-netware Support for PowerPC NetWare. * nlm32-powerpc.c: New file. * config.bfd (powerpc-*-netware*): New target; use ppc-nlm. @@ -1840,9 +2460,7 @@ Fri Feb 18 11:41:58 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) nlm32-powerpc.o, nlm32.o, nlm.o. * targets.c (nlm32_powerpc_vec): Declare. * Makefile.in (BFD32_BACKENDS): Add nlm32-powerpc.o. - (CFILES): Should add nlm32-powerpc.c, but didn't, because the - dependencies can't be sanitized. - end-sanitize-powerpc-netware + (CFILES): Add nlm32-powerpc.c. Initial support for PowerPC ELF. Done without an ABI, and probably to be changed when I get an ABI.