aboutsummaryrefslogtreecommitdiff
path: root/bfd/elf.c
AgeCommit message (Collapse)AuthorFilesLines
2007-10-25 * elf.c (elfcore_grok_ppc_vmx): New function.Alan Modra1-0/+26
(elfcore_grok_note): Handle NT_PPC_VMX. (elfcore_write_ppc_vmx): New function. * elf-bfd.h (elfcore_write_ppc_vmx): Declare.
2007-10-16Support the use of the STT_COMMON type. (In source and object files only at ↵Nick Clifton1-1/+5
the moment)
2007-10-12 * elf.c (elfcore_grok_prxfpreg): Fix comment typo.Alan Modra1-1/+1
2007-10-112007-10-10 H.J. Lu <hongjiu.lu@intel.com>H.J. Lu1-19/+35
* elf.c (get_program_header_size): Always add a PT_GNU_RELRO segment for -z relro. (_bfd_elf_map_sections_to_segments): Make a PT_GNU_RELRO segment only when needed.
2007-09-24 * elf.c (assign_file_positions_for_load_sections): TrustDaniel Jacobowitz1-6/+2
p_align_valid. (copy_elf_program_header): Copy PT_NULL segments.
2007-09-18 * elf.c (bfd_section_from_shdr): Check bfd_alloc return.Alan Modra1-0/+4
(elfcore_write_note): Check realloc return. * elflink.c (_bfd_elf_link_find_version_dependencies): Check bfd_zalloc return. (_bfd_elf_link_assign_sym_version): Check bfd_malloc return. (elf_link_add_object_symbols): Likewise. (struct hash_codes_info): New. (elf_collect_hash_codes): Return bfd_malloc error. (struct collect_gnu_hash_codes): Add "error". (elf_collect_gnu_hash_codes): Return bfd_malloc error. (bfd_elf_size_dynamic_sections): Check return status of _bfd_elf_link_find_version_dependencies. (bfd_elf_size_dynsym_hash_dynstr): Adjust for elf_collect_hash_codes and elf_collect_gnu_hash_codes changes. (elf_sym_name_compare): Formatting. (elf_fixup_link_order): Use bfd_malloc, not xmalloc.
2007-09-18bfd/H.J. Lu1-14/+63
2007-09-17 H.J. Lu <hongjiu.lu@intel.com> PR binutils/3281 PR binutils/5037 * elf-bfd.h (elf_obj_tdata): Remove relro. * elf.c (get_program_header_size): Check info->relro instead of elf_tdata (abfd)->relro. (_bfd_elf_map_sections_to_segments): Likewise. (assign_file_positions_for_load_sections): Don't set PT_GNU_RELRO segment alignment here. (assign_file_positions_for_non_load_sections): Properly set up PT_GNU_RELRO segment for copying executable/shared library. (rewrite_elf_program_header): Remove PT_GNU_RELRO segment. (copy_elf_program_header): Set p_size and p_size_valid fields for PT_GNU_RELRO segment. include/elf/ 2007-09-17 H.J. Lu <hongjiu.lu@intel.com> PR binutils/3281 PR binutils/5037 * internal.h (elf_segment_map): Add p_size and p_size_valid. (ELF_IS_SECTION_IN_SEGMENT): Allow SHF_TLS sections in PT_GNU_RELRO segments. ld/ 2007-09-17 H.J. Lu <hongjiu.lu@intel.com> PR binutils/3281 PR binutils/5037 * ldexp.h (ldexp_control): Add relro, relro_start_stat and relro_end_stat. * ldexp.c (fold_binary): Set expld.dataseg.relro to exp_dataseg_relro_start or exp_dataseg_relro_end when seeing DATA_SEGMENT_ALIGN or DATA_SEGMENT_RELRO_END, respectively. * ldlang.c (lang_size_sections_1): Properly set expld.dataseg.relro_start_stat and expld.dataseg.relro_end_stat. (find_relro_section_callback): New function. (lang_find_relro_sections_1): Likewise. (lang_find_relro_sections): Likewise. (lang_process): Call lang_find_relro_sections for non-relocatable link. ld/testsuite/ 2007-09-17 H.J. Lu <hongjiu.lu@intel.com> PR binutils/3281 PR binutils/5037 * ld-elf/binutils.exp: Update "-z relro" tests to use relro1.s. Add "-z relro" tests with relro2.s. Add "-z relro" tests with TLS for objcopy. * ld-elf/relro1.s: New file. * ld-elf/relro2.s: Likewise.
2007-09-12 * elf-bfd.h (struct elf_backend_data): Delete elf_backend_sprintf_vmaAlan Modra1-57/+0
and elf_backend_fprintf_vma. (_bfd_elf_sprintf_vma, _bfd_elf_fprintf_vma): Delete. * elf.c (_bfd_elf_sprintf_vma, _bfd_elf_fprintf_vma): Delete. * elfxx-target.h (elf_backend_sprintf_vma): Don't define. (elf_backend_fprintf_vma): Likewise. (elfNN_bed): Don't init removed fields. * bfd.c (is32bit): New function. (bfd_sprintf_vma, bfd_fprintf_vma): Use the above.
2007-09-08 PR ld/2864, ld/5006Alan Modra1-10/+22
* elf.c (special_sections): Comment typo. (elf_fake_sections): Force SHT_PROGBITS for sections that are SHT_NOBITS if BFD section flags say they have contents.
2007-08-25include/elf/Alan Modra1-0/+31
* common.h (NT_SPU): Define. bfd/ * elf.c (elfcore_grok_spu_note): New function. (elf_parse_notes): Call it. binutils/ * readelf.c (process_note): Recognize SPU core file notes.
2007-08-24 * elf.c (elfcore_grok_win32pstatus): Remove HAVE_WIN32_PSTATUS_TPedro Alves1-21/+29
guard. Make it host independent. (elfcore_grok_note): Remove HAVE_WIN32_PSTATUS_T guard around NT_WIN32PSTATUS.
2007-08-242007-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>Jan Kratochvil1-35/+108
* elf-bfd.h (struct elf_obj_tdata): New BUILD_ID_SIZE, BUILD_ID. * elf.c (elfcore_read_notes): Split to ... (elf_read_notes) ... here ... (elf_parse_notes): ... and here. Check `bfd_get_format (abfd)' with the former subfunctions called only for BFD_CORE. Call ELFOBJ_GROK_GNU_NOTE for BFD_OBJECT files with the owner "GNU". (_bfd_elf_make_section_from_shdr): Call ELF_PARSE_NOTES for SHT_NOTEs. (bfd_section_from_phdr): Update the call for renamed ELFCORE_READ_NOTES. (elfobj_grok_gnu_build_id, elfobj_grok_gnu_note): New functions. Code advisory: Roland McGrath
2007-08-16bfd/H.J. Lu1-66/+32
2007-08-16 H.J. Lu <hongjiu.lu@intel.com> * elf.c: Revert last change. binutils/ 2007-08-16 H.J. Lu <hongjiu.lu@intel.com> * readelf.c: Revert last change. include/elf/ 2007-08-16 H.J. Lu <hongjiu.lu@intel.com> * common.h: Revert last change.
2007-08-16bfd/H.J. Lu1-32/+66
2007-08-16 H.J. Lu <hongjiu.lu@intel.com> * elf.c (get_segment_type): Change PT_GNU_STACK to PT_GNU_ATTR. (bfd_section_from_phdr): Likewise. (get_program_header_size): Likewise. Add a PT_GNU_ATTR segment if there is an attribute section. (_bfd_elf_map_sections_to_segments): Likewise. (IS_SECTION_IN_INPUT_SEGMENT): Likewise. binutils/ 2007-08-16 H.J. Lu <hongjiu.lu@intel.com> * readelf.c (get_segment_type): Change PT_GNU_STACK to PT_GNU_ATTR. include/elf/ 2007-08-16 H.J. Lu <hongjiu.lu@intel.com> * common.h (PT_GNU_STACK): Renamed to ... (PT_GNU_ATTR): This. (PT_GNU_STACK): New. Make an alias of PT_GNU_ATTR.
2007-08-13 * elf.c (elf_modify_segment_map): Add remove_empty_load param.Alan Modra1-6/+9
Don't remove empty PT_LOAD header if false. (_bfd_elf_map_sections_to_segments): If user phdrs, pass false to elf_modify_segment_map. (assign_file_positions_for_load_sections): Pass false to elf_modify_segment_map.
2007-08-092007-08-09 H.J. Lu <hongjiu.lu@intel.com>H.J. Lu1-0/+27
PR ld/4909 * elf.c (print_segment_map): New function. (assign_file_positions_for_load_sections): Call print_segment_map when a section can't be allocated in segment.
2007-08-06 * elf.c: (_bfd_elf_make_section_from_phdr): Properly handleAlan Modra1-30/+49
bss segments.
2007-08-06 * elf.c (rewrite_elf_program_header): Handle sections not sortedDaniel Jacobowitz1-3/+6
by address. (copy_elf_program_header): Likewise.
2007-08-012007-08-01 Michael Snyder <msnyder@access-company.com>Michael Snyder1-1/+1
* elf.c (bfd_elf_print_symbol): Macro dereferences pointer, so pointer must be non-null.
2007-08-01 * elf.c (_bfd_elf_map_sections_to_segments): Work around buggyJakub Jelinek1-7/+10
GCC 3.4.x warning.
2007-07-31 * elf.c (get_program_header_size): Adjacent loadable .note*Jakub Jelinek1-8/+40
sections need just one PT_NOTE segment. (_bfd_elf_map_sections_to_segments): Likewise.
2007-07-262007-07-26 Michael Snyder <msnyder@access-company.com>Michael Snyder1-1/+1
* elf.c (_bfd_elf_get_synthetic_symtab): Remove meaningless pointer increment.
2007-07-24 * elflink.c (_bfd_elf_link_just_syms, merge_sections_remove_hook,Alan Modra1-721/+0
_bfd_elf_merge_sections, _bfd_elf_link_hash_newfunc, _bfd_elf_link_hash_copy_indirect, _bfd_elf_link_hash_hide_symbol, _bfd_elf_link_hash_table_init, _bfd_elf_link_hash_table_create, bfd_elf_set_dt_needed_name, bfd_elf_get_dyn_lib_class, bfd_elf_set_dyn_lib_class, bfd_elf_get_needed_list, bfd_elf_get_runpath_list, bfd_elf_get_dt_soname, bfd_elf_get_bfd_needed_list, struct elf_symbuf_symbol, struct elf_symbuf_head, struct elf_symbol, elf_sort_elf_symbol, elf_sym_name_compare, elf_create_symbuf, bfd_elf_match_symbols_in_sections, _bfd_elf_match_sections_by_type): Move to here.. * elf.c: ..from here.
2007-07-18 * elf-bfd.h (struct sym_sec_cache): Delete "sec". Add "shndx".Alan Modra1-25/+24
* elf.c (bfd_section_from_r_symndx): Don't cache bfd section of symbol. Instead cache ELF section index. Remove redundant checks of st_shndx.
2007-07-132007-07-13 Roland McGrath <roland@redhat.com>Roland McGrath1-148/+2
* elf-bfd.h (struct elf_obj_tdata): Revert last change. Add after_write_object_contents, after_write_object_contents_info. * elf.c (_bfd_elf_write_object_contents): Revert last change. Instead, call after_write_object_contents if set.
2007-07-092007-07-09 Roland McGrath <roland@redhat.com>Roland McGrath1-1/+155
* elf-bfd.h (struct elf_obj_tdata): Add members emit_note_gnu_build_id and note_gnu_build_id_sec. * elf.c (_bfd_id_note_section_size): New global function. (read_hex, _bfd_elf_write_build_id_section): New static functions. (_bfd_elf_write_object_contents): Call _bfd_elf_write_build_id_section if emit_note_gnu_build_id is set. * Makefile.am (elf.lo): Update dependencies.
2007-07-03Switch sources over to use the GPL version 3Nick Clifton1-2/+4
2007-07-02 PR 4712Alan Modra1-84/+81
* elf.c (assign_file_positions_for_load_sections): Adjust lma by p_vaddr_offset.
2007-06-29bfd:Joseph Myers1-0/+14
* elf-attrs.c: New. * Makefile.am (BFD32_BACKENDS): Add elf-attrs.lo. (BFD32_BACKENDS_CFILES): Add elf-attrs.c. (elf-attrs.lo): Generate dependencies. * Makefile.in: Regenerate. * configure.in (elf): Add elf-attrs.lo. * configure: Regenerate. * elf-bfd.h (struct elf_backend_data): Add entries for object attributes. (NUM_KNOWN_OBJ_ATTRIBUTES, obj_attribute, obj_attribute_list, OBJ_ATTR_PROC, OBJ_ATTR_GNU, OBJ_ATTR_FIRST, OBJ_ATTR_LAST, Tag_NULL, Tag_File, Tag_Section, Tag_Symbol, Tag_compatibility): New. (struct elf_obj_tdata): Add entries for object attributes. (elf_known_obj_attributes, elf_other_obj_attributes, elf_known_obj_attributes_proc, elf_other_obj_attributes_proc): New. (bfd_elf_obj_attr_size, bfd_elf_set_obj_attr_contents, bfd_elf_get_obj_attr_int, bfd_elf_add_obj_attr_int, bfd_elf_add_proc_attr_int, bfd_elf_add_obj_attr_string, bfd_elf_add_proc_attr_string, bfd_elf_add_obj_attr_compat, bfd_elf_add_proc_attr_compat, _bfd_elf_attr_strdup, _bfd_elf_copy_obj_attributes, _bfd_elf_obj_attrs_arg_type, _bfd_elf_parse_attributes, _bfd_elf_merge_object_attributes): New. * elf.c (_bfd_elf_copy_private_bfd_data): Copy object attributes. (bfd_section_from_shdr): Handle attributes sections. * elflink.c (bfd_elf_final_link): Handle attributes sections. * elfxx-target.h (elf_backend_obj_attrs_vendor, elf_backend_obj_attrs_section, elf_backend_obj_attrs_arg_type, elf_backend_obj_attrs_section_type): New. (elfNN_bed): Update. * elf32-arm.c (NUM_KNOWN_ATTRIBUTES, aeabi_attribute, aeabi_attribute_list): Remove. (struct elf32_arm_obj_tdata): Remove object attributes fields. (check_use_blx, bfd_elf32_arm_set_vfp11_fix, using_thumb2, elf32_arm_copy_private_bfd_data, elf32_arm_merge_eabi_attributes): Update for new object attributes interfaces. (uleb128_size, is_default_attr, eabi_attr_size, elf32_arm_eabi_attr_size, write_uleb128, write_eabi_attribute, elf32_arm_set_eabi_attr_contents, elf32_arm_bfd_final_link, elf32_arm_new_eabi_attr, elf32_arm_get_eabi_attr_int, elf32_arm_add_eabi_attr_int, attr_strdup, elf32_arm_add_eabi_attr_string, elf32_arm_add_eabi_attr_compat, copy_eabi_attributes, elf32_arm_parse_attributes): Remove. Moved to generic code in elf-attrs.c. (elf32_arm_obj_attrs_arg_type): New. (elf32_arm_fake_sections): Do not handle .ARM.attributes. (elf32_arm_section_from_shdr): Do not handle SHT_ARM_ATTRIBUTES. (bfd_elf32_bfd_final_link): Remove. (elf_backend_obj_attrs_vendor, elf_backend_obj_attrs_section, elf_backend_obj_attrs_arg_type, elf_backend_obj_attrs_section_type): New. * elf32-bfin.c (bfin_elf_copy_private_bfd_data): Copy object attributes. * elf32-frv.c (frv_elf_copy_private_bfd_data): Likewise. * elf32-iq2000.c (iq2000_elf_copy_private_bfd_data): Likewise. * elf32-mep.c (mep_elf_copy_private_bfd_data): Likewise. * elf32-mt.c (mt_elf_copy_private_bfd_data): Likewise. * elf32-sh.c (sh_elf_copy_private_data): Likewise. * elf64-sh64.c (sh_elf64_copy_private_data_internal): Likewise. binutils: * readelf.c (display_gnu_attribute): New. (process_arm_specific): Rearrange as process_attributes. (process_arm_specific): Replace by wrapper of process_attributes. gas: * as.c (create_obj_attrs_section): New. (main): Call create_obj_attrs_section for ELF. * read.c (s_gnu_attribute, skip_whitespace, skip_past_char, skip_past_comma, s_vendor_attribute): New. (potable): Add gnu_attribute for ELF. * read.h (s_vendor_attribute): Declare. * config/tc-arm.c (s_arm_eabi_attribute): Replace by wrapper round s_vendor_attribute. (aeabi_set_public_attributes): Update for new attributes interfaces. (arm_md_end): Remove attributes contents setting now done generically. include/elf: * arm.h (elf32_arm_add_eabi_attr_int, elf32_arm_add_eabi_attr_string, elf32_arm_add_eabi_attr_compat, elf32_arm_get_eabi_attr_int, elf32_arm_set_eabi_attr_contents, elf32_arm_eabi_attr_size, Tag_NULL, Tag_File, Tag_Section, Tag_Symbol, Tag_compatibility): Remove. * common.h (SHT_GNU_ATTRIBUTES): Define. ld: * emulparams/armelf.sh (OTHER_SECTIONS): Remove .ARM.attributes. (ATTRS_SECTIONS): Define. * scripttempl/elf.sc, scripttempl/elf32sh-symbian.sc, scripttempl/elf_chaos.sc, scripttempl/elfi370.sc, scripttempl/elfxtensa.sc: Handle ATTRS_SECTIONS.
2007-06-29 * elf.c (assign_file_positions_for_load_sections): Use elfAlan Modra1-19/+13
section header sh_size rather than bfd section size, simplifying .tbss handling.
2007-06-29 * elf.c (assign_file_positions_for_load_sections): Ensure bssAlan Modra1-26/+41
segments meet gABI alignment requirements. Don't allocate file space for bss sections in a segment also containing file or program headers.
2007-05-30bfd/Alan Modra1-10/+5
* elf.c (elf_fake_sections): Adjust test for SHT_NOBITS sections created by objcopy --only-keep-debug. (_bfd_elf_init_private_section_data): Only change elf_section_type if it is SHT_NULL. binutils/ * objcopy.c (copy_object): Revert 2007-05-11 change. Don't avoid calling bfd_copy_private_bfd_data for ELF STRIP_NONDEBUG. (setup_section): Don't modify flags, and don't avoid calling bfd_copy_private_section_data for ELF STRIP_NONDEBUG. * readelf.c (process_program_headers): Ignore .dynamic of type SHT_NOBITS.
2007-05-30 * elf.c (assign_file_positions_for_load_sections): Correct sh_typeAlan Modra1-61/+38
to SHT_NOBITS earlier. Base actions in rest of function on sh_type and sh_flags instead of bfd section flags. Delete voff and code keeping nobits segments aligned.
2007-05-15 PR 4479Alan Modra1-0/+10
* elf.c (elf_fake_sections): Don't allow backend to change SHT_NOBITS if called for strip/objcopy --only-keep-debug. * elfxx-mips.c (_bfd_mips_elf_fake_sections): Remove similar fix from here.
2007-05-14 * elf.c (bfd_elf_string_from_elf_section): Return NULL onAlan Modra1-1/+6
invalid shstrndx. (bfd_elf_get_str_section): Likewise.
2007-05-10bfd/Richard Sandiford1-1/+1
* elf.c (assign_file_positions_for_load_sections): Use p_memsz rather than p_filesz to calculate the LMA of the end of a segment. ld/testsuite/ * ld-elf/multibss1.d, ld-elf/multibss1.s: New test.
2007-05-07 * elf.c (assign_file_positions_for_load_sections): Don't checkAlan Modra1-3/+3
core segment.
2007-05-02include/elf/Alan Modra1-9/+19
* internal.h (ELF_IS_SECTION_IN_SEGMENT): Check both file offset and vma for appropriate sections. bfd/ * elf.c (assign_file_positions_for_load_sections): Set sh_offset here. Set sh_type to SHT_NOBITS if we won't be allocating file space. Don't bump p_memsz for non-alloc sections. Adjust section-in-segment check. (assign_file_positions_for_non_load_sections): Don't set sh_offset here for sections that have already been handled above.
2007-04-26bfd/Alan Modra1-1/+1
Many files: Include sysdep.h before bfd.h. * Makefile.am: Run "make dep-am". * Makefile.in: Regenerate. binutils/ * bucumm.h: Split off host dependencies to.. * sysdep.h: ..here. Many files: Include sysdep.h. Remove duplicate headers and reorder. * Makefile.am: Run "make dep-am". * Makefile.in: Regenerate. ld/ Many files: Include sysdep.h first. Remove duplicate headers. * Makefile.am: Run "make dep-am". * Makefile.in: Regenerate. opcodes/ * Makefile.am: Run "make dep-am". * Makefile.in: Regenerate. * ns32k-dis.c: Include sysdep.h first.
2007-04-172007-04-17 Paul Brook <paul@codesourcery.com>Paul Brook1-0/+11
bfd/ * elf.c (_bfd_elf_is_function_type): New function. * elflink.c (_bfd_elf_merge_symbol): Use bed->is_function_type. (_bfd_elf_dynamic_symbol_p, _bfd_elf_symbol_refs_local_p, is_global_data_symbol_definition, elf_link_add_object_symbols): Ditto. * elf-bfd.h (elf_backend_data): Add is_function_type. (_bfd_elf_is_function_type): Add prototype. * elfxx-target.h (elf_backend_is_function_type): Add default definition. (elfNN_bed): Add elf_backend_is_function_type. * elf32-arm.c (elf32_arm_is_function_type): New function. (elf_backend_is_function_type): Define. ld/testsuite/ * ld-arm/preempt-app.s: New test. * ld-arm/preempt-app.sym: New. * ld-arm/arm-elf.exp: Add preempt-app.
2007-03-29PR binutils/4110Nick Clifton1-13/+37
* elf.c (IS_VALID_GROUP_SECTION_HEADER): New macro. (setup_group): Use it. Report corrupt group section headers. (bfd_section_from_shdr): Use new macro. Replace constant 4 with GRP_ENTRY_SIZE. Cope with NULLs in the group section table. (elf_fake_section): Replace constant 4 with GRP_ENTRY_SIZE.
2007-03-22bfd/H.J. Lu1-3/+26
2007-03-22 H.J. Lu <hongjiu.lu@intel.com> PR ld/4007 * elf.c (assign_file_positions_for_load_sections): Check if all sections are in the segment. ld/testsuite/ 2007-03-22 H.J. Lu <hongjiu.lu@intel.com> PR ld/4007 * ld-elf/note-1.d: New file. * ld-elf/note-1.s: Likewise. * ld-elf/note-1.t: Likewise. * ld-i386/alloc.d: Likewise. * ld-i386/alloc.s: Likewise. * ld-i386/alloc.t: Likewise. * ld-i386/i386.exp: Run "alloc".
2007-03-20PR binutils/3535Nick Clifton1-14/+8
* elf.c (copy_private_bfd_data): Widen the scope of Solaris specific conditions that need the program headers to be rewritten.
2007-03-142007-03-13 H.J. Lu <hongjiu.lu@intel.com>H.J. Lu1-0/+11
PR binutils/3826 * elf-bfd.h (elf_backend_data): Add elf_osabi. (_bfd_elf_set_osabi): New. * elf.c (_bfd_elf_set_osabi): New. * elf32-hppa.c (elf32_hppa_post_process_headers): Removed. (elf_backend_post_process_headers): Defined with _bfd_elf_set_osabi. (ELF_OSABI): Properly defined for each target. * elf32-i370.c (i370_elf_post_process_headers): Removed. (ELF_OSABI): Defined. (elf_backend_post_process_headers): Defined with _bfd_elf_set_osabi. * elf32-i386.c (ELF_OSABI): Defined to ELFOSABI_FREEBSD for freebsd. (elf_i386_post_process_headers): Set EI_OSABI with elf_osabi. * elf32-msp430.c (elf32_msp430_post_process_headers): Removed. (ELF_OSABI): Defined. (elf_backend_post_process_headers): Defined with _bfd_elf_set_osabi. * elf64-alpha.c (ELF_OSABI): Defined to ELFOSABI_FREEBSD for freebsd. (elf64_alpha_fbsd_post_process_headers): Set EI_OSABI with elf_osabi. * elf64-hppa.c (elf64_hppa_post_process_headers): Set EI_OSABI with elf_osabi. (ELF_OSABI): Properly defined for each target. (elf_backend_post_process_headers): Defined with _bfd_elf_set_osabi for Linux. * elf64-sparc.c (elf64_sparc_fbsd_post_process_headers): Removed. (ELF_OSABI): Defined to ELFOSABI_FREEBSD for freebsd. (elf_backend_post_process_headers): Defined with _bfd_elf_set_osabi. * elf64-x86-64.c (elf64_x86_64_fbsd_post_process_headers): Removed. (ELF_OSABI): Defined to ELFOSABI_FREEBSD for freebsd. (elf_backend_post_process_headers): Defined with _bfd_elf_set_osabi. * elfcode.h (elf_object_p): Match the ELFOSABI_NONE ELF target with any ELF target of the compatible machine for which we do not have a specific backend. * elfxx-ia64.c (elfNN_hpux_post_process_headers): Set EI_OSABI with elf_osabi. * elfxx-target.h (ELF_OSABI): Default to ELFOSABI_NONE. (elfNN_bed): Initialize elf_osabi with ELF_OSABI.
2007-03-07 PR 4144Alan Modra1-22/+12
* elf.c (assign_file_positions_for_load_sections): Don't adjust p_memsz for !SEC_LOAD section vma modulo page size. Instead, use the same lma based adjustment for SEC_LOAD sections.
2007-02-23PR binutils/3535Nick Clifton1-6/+20
* elf.c (copy_private_bfd_data): Always rewrite the program headers when a Solaris interpreter segment is involved.
2007-02-21Take into account MEMORY regions when creating a segment map.Nick Clifton1-0/+4
2007-02-05Support for Toshiba MeP and for complex relocations.Dave Brolley1-0/+4
2007-02-02 * elf-bfd.h (struct elf_obj_tdata): Change symbuf type to void *.Jakub Jelinek1-99/+211
* elf.c (struct elf_symbuf_symbol, struct elf_symbuf_head): New types. (struct elf_symbol): Change first member into union. (elf_sort_elf_symbol): Compare pointers to internal syms rather than internal syms. Only compare st_shndx fields. (elf_create_symbuf): New function. (bfd_elf_match_symbols_in_sections): Use it. If symbufs are available for bfds, use a binary search, otherwise don't qsort symbols unnecessarily only to select which symbols are for the particular shndx.
2007-02-01PR ld/3852Nick Clifton1-16/+1
* elf.c (_bfd_elf_link_hash_table_init): Initialize all the fields in the elf_link_hash_table structure.