1. 01 Feb, 2017 1 commit
  2. 21 Aug, 2013 1 commit
  3. 18 Jul, 2013 1 commit
    • Nick Clifton's avatar
      * elf32-arm.c (elf32_arm_stub_long_branch_arm_nacl): New variable. · 7a89b94e
      Nick Clifton authored
      	(elf32_arm_stub_long_branch_arm_nacl_pic): New variable.
      	(arm_build_one_stub): Increase MAXRELOCS to 3.
      	(arm_type_of_stub): Use them if GLOBALS->nacl_p.
      	(struct elf32_arm_link_hash_table): Give add_stub_section member's
      	pointee type a third argument.
      	(elf32_arm_create_or_find_stub_sec): Update caller.
      	(elf32_arm_size_stubs): Update argument type.
      	* bfd-in.h (elf32_arm_size_stubs): Update decl.
      	* bfd-in2.h: Regenerate.
      	* libbfd.h: Regenerate.
      
      	* emultempl/armelf.em (elf32_arm_add_stub_section): Take third
      	argument ALIGNMENT_POWER, use it instead of constant 3.
      
      	* ld-arm/farcall-arm-nacl.d: New file.
      	* ld-arm/farcall-arm-nacl-pic.d: New file.
      	* ld-arm/farcall-data-nacl.d: New file.
      	* ld-arm/arm-elf.exp (armeabitests_common): Add extra element to
      	"action" lists for those cases to use a different dump file for NaCl
      	targets.
      	Massage $armeabitests_common to drop the extra element or the one
      	before it, depending on [istarget "arm*-*-nacl*"].
      
      	* ld-arm/arm-elf.exp (armelftests_common): Move all "Cortex-A8
      	erratum fix", Thumb-only and interworking cases to ...
      	(armelftests_nonacl): ... here.
      	(armeabitests_common): Move all "erratum 760522 fix", Thumb-only
      	and interworking cases to ...
      	(armeabitests_nonacl): ... here.
      7a89b94e
  4. 26 Jun, 2013 1 commit
    • Yufeng Zhang's avatar
      [AArch64, ILP32] 2/6 Parametrize elfnn-aarch64.c and add basic support in ld · cec5225b
      Yufeng Zhang authored
      and gas.
      
      bfd/
      
      	* Makefile.am (BFD64_BACKENDS): Add elf32-aarch64.lo.
      	(BUILD_CFILES): Add elf32-aarch64.c.
      	(elf32-aarch64.c): New rule for generating from elfnn-aarch64.c.
      	* Makefile.in: Re-generated.
      	* archures.c (bfd_mach_aarch64_ilp32): New define.
      	* bfd-in.h (bfd_elf32_aarch64_init_maps): New declaration.
      	(bfd_elf32_aarch64_set_options): Ditto.
      	(elf32_aarch64_setup_section_lists): Ditto.
      	(elf32_aarch64_next_input_section): Ditto.
      	(elf32_aarch64_size_stubs): Ditto.
      	(elf32_aarch64_build_stubs): Ditto.
      	* bfd-in2.h: Re-generated.
      	* config.bfd (aarch64-*-elf): Add bfd_elf32_littleaarch64_vec
      	and bfd_elf32_bigaarch64_vec.
      	(aarch64-*-linux*): Likewise.
      	(aarch64_be-*-elf): Likewise.
      	(aarch64_be-*-linux*): Likewise.
      	* configure.in (bfd_elf32_bigaarch64_vec)
      	(bfd_elf32_littleaarch64_vec): New.
      	* configure: Re-generated.
      	* cpu-aarch64.c (compatible): Don't allow mixing ilp32 objects with
      	lp64 ones.
      	(bfd_aarch64_arch_ilp32): New.
      	(bfd_aarch64_arch): Link to bfd_aarch64_arch_ilp32.
      	* elfnn-aarch64.c (ARCH_SIZE): New define.
      	(AARCH64_R, AARCH64_R_STR, LOG_FILE_ALIGN): New defines.
      	(GOT_ENTRY_SIZE): Re-define as (ARCH_SIZE / 8).
      	(elf64_aarch64_*): Rename to elfNN_aarch64_*.
      	(ELF64_R_*): Rename to ELFNN_R_*.
      	Plus other paramaterization.
      	* targets.c (bfd_elf32_bigaarch64_vec, bfd_elf32_littleaarch64_vec):
      	New declarations.
      	(_bfd_target_vector): Add bfd_elf32_bigaarch64_vec and
      	bfd_elf32_littleaarch64_vec.
      
      gas/
      
      	* config/tc-aarch64.c (ilp32_p): New static variable.
      	(elf64_aarch64_target_format): Return the target according to the
      	value of 'ilp32_p'.
      	(md_begin): Determine 'mach' according to the value of 'ilp32_p'.
      	(aarch64_opts): Add support for options '-milp32' and '-mlp64'.
      	(aarch64_dwarf2_addr_size): New function.
      	* config/tc-aarch64.h (aarch64_dwarf2_addr_size): New declaration.
      	(DWARF2_ADDR_SIZE): New define.
      
      ld/
      
      	* Makefile.am (ALL_64_EMULATION_SOURCES): Add eaarch64elf32.c.
      	(eaarch64elf32.c): New dependency and rule.
      	* Makefile.in: Re-generated.
      	* configure.tgt (aarch64-*-elf): Add aarch64elf32.
      	(aarch64_be-*-elf, aarch64_be-*-linux*, aarch64-*-linux*): Likewise.
      	* emulparams/aarch64elf32.sh: New file.
      cec5225b
  5. 20 Jun, 2013 1 commit
    • Yufeng Zhang's avatar
      bfd/ · b9eead84
      Yufeng Zhang authored
      	* bfd-in.h (bfd_elf64_aarch64_set_options): Add 'extern'.
      	* bfd-in2.h: Re-generated.
      	* elf64-aarch64.c (RELOC_SECTION): Removed.
      	(SWAP_RELOC_IN, SWAP_RELOC_OUT): Ditto.
      	(AARCH64_ELF_OS_ABI_VERSION): Ditto.
      	(elf64_aarch64_link_hash_traverse): Ditto.
      	(elf64_aarch64_size_stubs): Change 'Aarch64' to 'AArch64' in the
      	comment.
      
      opcodes/
      
      	* aarch64-dis.c (EMBEDDED_ENV): Remove the check on it.
      	(SYMTAB_AVAILABLE): Removed.
      	(#include "elf/aarch64.h): Ditto.
      b9eead84
  6. 10 Jan, 2013 1 commit
    • H.J. Lu's avatar
      Remove trailing white spaces in bfd · 68ffbac6
      H.J. Lu authored
      	* aout0.c: Remove trailing white spaces.
      	* archive.c: Likewise.
      	* archures.c: Likewise.
      	* bfd-in.h: Likewise.
      	* bfd-in2.h: Likewise.
      	* coff-alpha.c: Likewise.
      	* coff-i860.c: Likewise.
      	* coff-mips.c: Likewise.
      	* coff-ppc.c: Likewise.
      	* coff-tic80.c: Likewise.
      	* coff-x86_64.c: Likewise.
      	* coff-z80.c: Likewise.
      	* coffcode.h: Likewise.
      	* coffgen.c: Likewise.
      	* cofflink.c: Likewise.
      	* compress.c: Likewise.
      	* corefile.c: Likewise.
      	* cpu-arm.c: Likewise.
      	* cpu-avr.c: Likewise.
      	* cpu-bfin.c: Likewise.
      	* cpu-cr16.c: Likewise.
      	* cpu-cr16c.c: Likewise.
      	* cpu-crx.c: Likewise.
      	* cpu-h8300.c: Likewise.
      	* cpu-i386.c: Likewise.
      	* cpu-lm32.c: Likewise.
      	* cpu-m68k.c: Likewise.
      	* cpu-moxie.c: Likewise.
      	* cpu-msp430.c: Likewise.
      	* cpu-sh.c: Likewise.
      	* cpu-xc16x.c: Likewise.
      	* dwarf2.c: Likewise.
      	* ecofflink.c: Likewise.
      	* ecoffswap.h: Likewise.
      	* elf-ifunc.c: Likewise.
      	* elf-m10300.c: Likewise.
      	* elf-vxworks.c: Likewise.
      	* elf32-avr.c: Likewise.
      	* elf32-avr.h: Likewise.
      	* elf32-cr16.c: Likewise.
      	* elf32-cr16c.c: Likewise.
      	* elf32-cris.c: Likewise.
      	* elf32-crx.c: Likewise.
      	* elf32-frv.c: Likewise.
      	* elf32-hppa.c: Likewise.
      	* elf32-i860.c: Likewise.
      	* elf32-ip2k.c: Likewise.
      	* elf32-iq2000.c: Likewise.
      	* elf32-m32c.c: Likewise.
      	* elf32-m68hc1x.c: Likewise.
      	* elf32-msp430.c: Likewise.
      	* elf32-mt.c: Likewise.
      	* elf32-ppc.c: Likewise.
      	* elf32-rl78.c: Likewise.
      	* elf32-s390.c: Likewise.
      	* elf32-score.h: Likewise.
      	* elf32-sh-symbian.c: Likewise.
      	* elf32-sh.c: Likewise.
      	* elf32-spu.c: Likewise.
      	* elf32-tic6x.c: Likewise.
      	* elf32-v850.c: Likewise.
      	* elf32-xc16x.c: Likewise.
      	* elf32-xtensa.c: Likewise.
      	* elf64-alpha.c: Likewise.
      	* elf64-hppa.c: Likewise.
      	* elf64-ppc.c: Likewise.
      	* elf64-s390.c: Likewise.
      	* elfcore.h: Likewise.
      	* elflink.c: Likewise.
      	* elfxx-mips.c: Likewise.
      	* elfxx-sparc.c: Likewise.
      	* elfxx-tilegx.c: Likewise.
      	* ieee.c: Likewise.
      	* libcoff.h: Likewise.
      	* libpei.h: Likewise.
      	* libxcoff.h: Likewise.
      	* linker.c: Likewise.
      	* mach-o-i386.c: Likewise.
      	* mach-o-target.c: Likewise.
      	* mach-o.c: Likewise.
      	* mach-o.h: Likewise.
      	* mmo.c: Likewise.
      	* opncls.c: Likewise.
      	* pdp11.c: Likewise.
      	* pe-x86_64.c: Likewise.
      	* peXXigen.c: Likewise.
      	* pef-traceback.h: Likewise.
      	* pei-x86_64.c: Likewise.
      	* peicode.h: Likewise.
      	* plugin.c: Likewise.
      	* reloc.c: Likewise.
      	* riscix.c: Likewise.
      	* section.c: Likewise.
      	* som.c: Likewise.
      	* syms.c: Likewise.
      	* tekhex.c: Likewise.
      	* ticoff.h: Likewise.
      	* vaxbsd.c: Likewise.
      	* xcofflink.c: Likewise.
      	* xtensa-isa.c: Likewise.
      68ffbac6
  7. 23 Oct, 2012 1 commit
    • Nathan Sidwell's avatar
      bfd/ · 04c3a755
      Nathan Sidwell authored
      	* bfd-in.h (bfd_elf_stack_segment_size): Declare.
      	* bfd-in2.h: Rebuilt.
      	* elfxx-target.h (elf_backend_stack_align): New.
      	(elfNN_bed): Add it.
      	* elf-bfd.h (struct elf_backend_data): Add stack_align field.
      	* elf.c (bfd_elf_map_sections_to_segments): Pay attention to
      	stack_align and stacksize for PT_GNU_STACK segment.
      	(assign_file_positions_for_non_load_sections): Set p_memsz for
      	PT_GNU_STACK segment.
      	(copy_elf_program_header): Copy PT_GNU_STACK size.
      	* elflink.c (bfd_elf_stack_segment_size): New function, taken from
      	uclinux backends.
      	(bfd_elf_size_dynamic_sections): Determine
      	PT_GNU_STACK requirements after calling backend.  Pay attention to
      	stacksize.
      	* elf32-bfin.c (elf32_bfinfdpic_always_size_sections): Call
      	bfd_elf_stack_segment_size.
      	(elf32_bfinfdpic_modify_program_headers): Delete.
      	(elf32_bfingfdpic_copy_private_bfd_data): Don't copy PT_GNU_STACK
      	here.
      	(elf_backend_stack_align): Override.
      	(elf_backend_modify_program_headers): Don't override.
      	* elf32-frv.c (frvfdpic_always_size_sections): Call
      	bfd_elf_stack_segment_size.
      	(elf32_frvfdpic_modify_program_headers): Delete.
      	(elf32_frvfdpic_copy_private_bfd_data): Don't copy PT_GNU_STACK
      	here.
      	(elf_backend_stack_align): Override.
      	(elf_backend_modify_program_headers): Don't override.
      	* elf32-lm32.c (lm32_elf_always_size_sections): Leave
      	PT_GNU_STACK creation to underlying elf support.  Check
      	__stacksize here for backwards compatibility, and set it if
      	needed.
      	(lm32_elf_modify_segment_map): Delete.
      	(lm32_elf_modify_program_headers): Delete.
      	(elf_backend_stack_align): Override.
      	(elf_backend_modify_segment_map): Don't override.
      	(elf_backend_modify_program_headers): Don't override.
      	* elf32-sh.c (sh_elf_always_size_sections): Call
      	bfd_elf_stack_segment_size.
      	(sh_elf_modify_program_headers): Delete.
      	(sh_elf_copy_private_data): Don't copy PT_GNU_STACK
      	here.
      	(elf_backend_stack_align): Override.
      	(elf_backend_modify_program_headers): Don't override.
      	* elf32-tic6x.c (elf32_tic6x_always_size_sections): Call
      	bfd_elf_stack_segment_size.
      	(elf32_tic6x_modify_program_headers): Delete.
      	(elf32_tic6x_copy_private_data): Delete.
      	(elf_backend_stack_align): Override.
      	(bfd_elf32_bfd_copy_private_bfd_data): Don't override.
      	(elf_backend_modify_program_headers): Don't override.
      
      	include/
      	* bfdlink.h (struct bfd_link_info): Add stacksize option.
      
      	ld/
      	* ld.texinfo (stack-size): New option.
      	* emultempl/elf32.em: Add stack-size option.
      
      	ld/testsuite/
      	* ld-elf/binutils.exp: Add -z stack-size=0.
      	* ld-elf/elf.exp: Add stack-exec and stack-size tests.
      	* ld-elf/orphan-region.d: Add stack-size option. Remove xfail.
      	* ld-elf/stack-exec.rd: New.
      	* ld-elf/stack-size.rd: New.
      	* ld-elf/stack.s: New.
      	* ld-scripts/empty-aligned.d: Add stack-size option.
      	* ld-sh/fdpic-stack-set.d: New.
      	* ld-tic6x/shlib-1.rd: Remove __stacksize symbol.
      	* ld-tic6x/shlib-1b.rd: Likewise.
      	* ld-tic6x/shlib-1r.rd: Likewise.
      	* ld-tic6x/shlib-1rb.rd: Likewise.
      	* ld-tic6x/shlib-app-1.rd: Likewise.
      	* ld-tic6x/shlib-app-1b.rd: Likewise.
      	* ld-tic6x/shlib-app-1r.rd: Likewise.
      	* ld-tic6x/shlib-app-1rb.rd: Likewise.
      	* ld-tic6x/shlib-noindex.rd: Likewise.
      	* ld-tic6x/static-app-1.rd: Likewise.
      	* ld-tic6x/static-app-1b.rd: Likewise.
      	* ld-tic6x/static-app-1r.rd: Likewise.
      	* ld-tic6x/static-app-1rb.rd: Likewise.
      04c3a755
  8. 13 Aug, 2012 1 commit
  9. 04 Jun, 2012 1 commit
    • Jan Kratochvil's avatar
      bfd/ · fe78531d
      Jan Kratochvil authored
      	* bfd-in.h (bfd_elf_bfd_from_remote_memory): Make LEN argument
      	of target_read_memory as bfd_size_type.
      	* bfd-in2.h: Regenerate.
      	* elf-bfd.h (elf_backend_bfd_from_remote_memory): Make LEN
      	argument of target_read_memory as bfd_size_type.
      	(_bfd_elf32_bfd_from_remote_memory): Likewise.
      	(_bfd_elf64_bfd_from_remote_memory): Likewise.
      	* elf.c (bfd_elf_bfd_from_remote_memory): Likewise.
      	* elfcode.h (NAME(_bfd_elf,bfd_from_remote_memory)): Likewise.
      
      gdb/
      	* symfile-mem.c: 3 new gdb_static_assert for target_read_memory_bfd
      	parameters.
      	(target_read_memory_bfd): New function.
      	(symbol_file_add_from_memory): Use it.
      fe78531d
  10. 01 Jun, 2012 1 commit
    • Jan Kratochvil's avatar
      bfd/ · 5299c1c4
      Jan Kratochvil authored
      	* bfd-in.h (bfd_elf_bfd_from_remote_memory): Make LEN argument
      	of target_read_memory as size_t.
      	* bfd-in2.h: Regenerate.
      	* elf-bfd.h (elf_backend_bfd_from_remote_memory): Make LEN
      	argument of target_read_memory as size_t.
      	(_bfd_elf32_bfd_from_remote_memory): Likewise.
      	(_bfd_elf64_bfd_from_remote_memory): Likewise.
      	* elf.c (bfd_elf_bfd_from_remote_memory): Likewise.
      	* elfcode.h (NAME(_bfd_elf,bfd_from_remote_memory)): Likewise.
      
      gdb/
      	* target.c (target_read_memory): Make LEN argument as size_t.
      	* target.h (target_read_memory): Likewise.
      5299c1c4
  11. 18 May, 2012 1 commit
    • Nick Clifton's avatar
      PR 14072 · 0bee45d9
      Nick Clifton authored
      	* bfd-in.h: Check for PACKAGE or PACKAGE_VERSION before
      	complaining about config.h not having been included.
      	* bfd-in2.h: Regenerate.
      0bee45d9
  12. 17 May, 2012 1 commit
    • Nick Clifton's avatar
      PR 14072 · df7b86aa
      Nick Clifton authored
      	* configure.in: Add check that sysdep.h has been included before
      	any system header files.
      	* configure: Regenerate.
      	* config.in: Regenerate.
      	* sysdep.h: Generate an error if included before config.h.
      	* alpha-opc.c: Include sysdep.h before any other header file.
      	* alpha-dis.c: Likewise.
      	* avr-dis.c: Likewise.
      	* cgen-opc.c: Likewise.
      	* cr16-dis.c: Likewise.
      	* cris-dis.c: Likewise.
      	* crx-dis.c: Likewise.
      	* d10v-dis.c: Likewise.
      	* d10v-opc.c: Likewise.
      	* d30v-dis.c: Likewise.
      	* d30v-opc.c: Likewise.
      	* h8500-dis.c: Likewise.
      	* i370-dis.c: Likewise.
      	* i370-opc.c: Likewise.
      	* m10200-dis.c: Likewise.
      	* m10300-dis.c: Likewise.
      	* micromips-opc.c: Likewise.
      	* mips-opc.c: Likewise.
      	* mips61-opc.c: Likewise.
      	* moxie-dis.c: Likewise.
      	* or32-opc.c: Likewise.
      	* pj-dis.c: Likewise.
      	* ppc-dis.c: Likewise.
      	* ppc-opc.c: Likewise.
      	* s390-dis.c: Likewise.
      	* sh-dis.c: Likewise.
      	* sh64-dis.c: Likewise.
      	* sparc-dis.c: Likewise.
      	* sparc-opc.c: Likewise.
      	* spu-dis.c: Likewise.
      	* tic30-dis.c: Likewise.
      	* tic54x-dis.c: Likewise.
      	* tic80-dis.c: Likewise.
      	* tic80-opc.c: Likewise.
      	* tilegx-dis.c: Likewise.
      	* tilepro-dis.c: Likewise.
      	* v850-dis.c: Likewise.
      	* v850-opc.c: Likewise.
      	* vax-dis.c: Likewise.
      	* w65-dis.c: Likewise.
      	* xgate-dis.c: Likewise.
      	* xtensa-dis.c: Likewise.
      	* rl78-decode.opc: Likewise.
      	* rl78-decode.c: Regenerate.
      	* rx-decode.opc: Likewise.
      	* rx-decode.c: Regenerate.
      
      	* configure.in: Add check that sysdep.h has been included before
      	any system header files.
      	* configure: Regenerate.
      	* config.in: Regenerate.
      	* sysdep.h: Generate an error if included before config.h.
      
      	* configure.in: Add check that sysdep.h has been included before
      	any system header files.
      	* configure: Regenerate.
      	* config.in: Regenerate.
      	* aclocal.m4: Regenerate.
      	* bfd-in.h: Generate an error if included before config.h.
      	* sysdep.h: Likewise.
      	* bfd-in2.h: Regenerate.
      	* compress.c: Remove #include "config.h".
      	* plugin.c: Likewise.
      	* elf32-m68hc1x.c: Include sysdep.h before alloca-conf.h.
      	* elf64-hppa.c: Likewise.
      	* som.c: Likewise.
      	* xsymc.c: Likewise.
      
      	* configure.in: Add check that sysdep.h has been included before
      	any system header files.
      	* configure: Regenerate.
      	* config.in: Regenerate.
      
      	* configure.in: Add check that sysdep.h has been included before
      	any system header files.
      	* configure: Regenerate.
      	* config.in: Regenerate.
      	* aclocal.m4: Regenerate.
      	* Makefile.am: Use wrappers around C files generated by flex.
      	* Makefile.in: Regenerate.
      	* doc/Makefile.in: Regenerate.
      	* itbl-lex-wrapper.c: New file.
      	* config/bfin-lex-wrapper.c: New file.
      	* cgen.c: Include as.h before setjmp.h.
      	* config/tc-dlx.c: Include as.h before any other header.
      	* config/tc-h8300.c: Likewise.
      	* config/tc-lm32.c: Likewise.
      	* config/tc-mep.c: Likewise.
      	* config/tc-microblaze.c: Likewise.
      	* config/tc-mmix.c: Likewise.
      	* config/tc-msp430.c: Likewise.
      	* config/tc-or32.c: Likewise.
      	* config/tc-tic4x.c: Likewise.
      	* config/tc-tic54x.c: Likewise.
      	* config/tc-xtensa.c: Likewise.
      
      	* configure.in: Add check that sysdep.h has been included before
      	any system header files.
      	* configure: Regenerate.
      	* config.in: Regenerate.
      	* unwind-ia64.h: Include config.h.
      df7b86aa
  13. 16 May, 2012 1 commit
    • Nick Clifton's avatar
      * bfd-in.h (bfd_get_section_name, bfd_get_section_vma, · a0f49396
      Nick Clifton authored
      	bfd_get_section_lma, bfd_get_section_alignment,
      	bfd_get_section_flags, bfd_get_section_userdata): Rewrite macros
      	in order to use the `bfd' argument.
      	* bfd-in2.h: Regenerate.
      	* elf-vxworks.c (elf_vxworks_finish_dynamic_entry): Pass proper `bfd'
      	as the first argument for `bfd_get_section_alignment'.
      	* elf32-arm.c (create_ifunc_sections): Likewise, for
      	`bfd_set_section_alignment'.
      	* elf32-m32r.c (m32r_elf_relocate_section): Likewise, for
      	`bfd_get_section_name'.
      	* elf32-microblaze.c (microblaze_elf_relocate_section): Likewise.
      	* elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise.
      	(ppc_elf_relocate_section): Likewise.
      	* elf64-mmix.c (mmix_final_link_relocate): Likewise, for
      	`bfd_get_section_vma'.
      	* elf64-ppc.c (create_linkage_sections): Likewise, for
      	`bfd_set_section_alignment'.
      
      	* emultempl/m68hc1xelf.em (hook_in_stub): Pass proper `bfd'
      	as the first argument for `bfd_get_section_name'.
      
      	* config/tc-alpha.c (maybe_set_gp): Pass proper `bfd'
      	as the first argument for `bfd_get_section_vma'.
      a0f49396
  14. 24 Apr, 2012 1 commit
    • Alan Modra's avatar
      PR ld/13991 · dbaa2011
      Alan Modra authored
      bfd/
      	* bfd/elf-bfd.h (_bfd_elf_link_just_syms): Define as
      	_bfd_generic_link_just_syms.
      	* bfd/elflink.c (_bfd_elf_link_just_syms): Delete.
      	* bfd/linker.c (_bfd_generic_link_just_syms): Set sec_info_type.
      
      	* bfd/bfd-in.h (discarded_section): Renamed from elf_discarded_section.
      	* bfd/section.c (SEC_INFO_TYPE_NONE, SEC_INFO_TYPE_STABS,
      	SEC_INFO_TYPE_MERGE, SEC_INFO_TYPE_EH_FRAME,
      	SEC_INFO_TYPE_JUST_SYMS): Renamed from corresponding ELF_INFO_TYPE.
      	* bfd/elf-eh-frame.c, * bfd/elf-m10200.c, * bfd/elf-m10300.c,
      	* bfd/elf.c, * bfd/elf32-arm.c, * bfd/elf32-avr.c, * bfd/elf32-bfin.c,
      	* bfd/elf32-cr16.c, * bfd/elf32-cr16c.c, * bfd/elf32-cris.c,
      	* bfd/elf32-crx.c, * bfd/elf32-d10v.c, * bfd/elf32-epiphany.c,
      	* bfd/elf32-fr30.c, * bfd/elf32-frv.c, * bfd/elf32-h8300.c,
      	* bfd/elf32-hppa.c, * bfd/elf32-i370.c, * bfd/elf32-i386.c,
      	* bfd/elf32-i860.c, * bfd/elf32-ip2k.c, * bfd/elf32-iq2000.c,
      	* bfd/elf32-lm32.c, * bfd/elf32-m32c.c, * bfd/elf32-m32r.c,
      	* bfd/elf32-m68hc1x.c, * bfd/elf32-m68k.c, * bfd/elf32-mcore.c,
      	* bfd/elf32-mep.c, * bfd/elf32-moxie.c, * bfd/elf32-msp430.c,
      	* bfd/elf32-mt.c, * bfd/elf32-openrisc.c, * bfd/elf32-ppc.c,
      	* bfd/elf32-rl78.c, * bfd/elf32-rx.c, * bfd/elf32-s390.c,
      	* bfd/elf32-score.c, * bfd/elf32-score7.c, * bfd/elf32-sh.c,
      	* bfd/elf32-spu.c, * bfd/elf32-tic6x.c, * bfd/elf32-tilepro.c,
      	* bfd/elf32-v850.c, * bfd/elf32-vax.c, * bfd/elf32-xc16x.c,
      	* bfd/elf32-xstormy16.c, * bfd/elf32-xtensa.c, * bfd/elf64-alpha.c,
      	* bfd/elf64-hppa.c, * bfd/elf64-ia64-vms.c, * bfd/elf64-mmix.c,
      	* bfd/elf64-ppc.c, * bfd/elf64-s390.c, * bfd/elf64-sh64.c,
      	* bfd/elf64-x86-64.c, * bfd/elflink.c, * bfd/elfnn-ia64.c,
      	* bfd/elfxx-mips.c, * bfd/elfxx-sparc.c, * bfd/elfxx-tilegx.c,
      	* bfd/reloc.c: Update all references.
      	* bfd/bfd-in2.h: Regenerate.
      ld/
      	* ld/ldlang.c (size_input_section): Use sec_info_type rather than
      	usrdata->flags.just_syms.
      	* ld/ldwrite.c (build_link_order): Likewise.
      	* ld/emultempl/hppaelf.em (build_section_lists): Likewise.
      	* ld/emultempl/ppc64elf.em (build_toc_list): Likewise.
      	* ld/emultempl/armelf.em (build_section_lists): Likewise.
      	(after_allocation): Update for renamed sec_info_type value.
      	* ld/emultempl/tic6xdsbt.em: Likewise.
      dbaa2011
  15. 29 Mar, 2012 1 commit
  16. 23 Mar, 2012 1 commit
    • Alan Modra's avatar
      * linker.c (_bfd_nearby_section): New function, split out from.. · 051d833a
      Alan Modra authored
      	(fix_syms): ..here.
      	* bfd-in.h (_bfd_nearby_section): Declare.
      	* bfd-in2.h: Regenerate.
      	* elflink.c (elf_link_input_bfd): Don't use text_index_section or
      	data_index_section with ld -q or ld -r output relocs against
      	stripped output sections.  Instead use _bfd_nearby_section.
      051d833a
  17. 24 Oct, 2011 1 commit
    • Nick Clifton's avatar
      PR binutils/13292 · f1163205
      Nick Clifton authored
      	* bfd-in.h: Include <sys/stat.h> rather than forward defining
      	struct stat.
      	* bfd-in2.h: Regenerate.
      f1163205
  18. 16 Sep, 2011 1 commit
    • H.J. Lu's avatar
      Check if a symbol is hidden by linker script. · fd91d419
      H.J. Lu authored
      bfd/
      
      2011-09-15  H.J. Lu  <hongjiu.lu@intel.com>
      
      	PR ld/12975
      	* bfd-in.h (bfd_elf_size_dynamic_sections): Remove pointer
      	to struct bfd_elf_version_tree.
      
      	* elflink.c (elf_info_failed): Remove verdefs.
      	(_bfd_elf_export_symbol): Updated.
      	_bfd_elf_link_assign_sym_version): Likewise.
      	(bfd_elf_size_dynamic_sections): Remove pointer to struct
      	bfd_elf_version_tree.  Updated.
      	(bfd_elf_gc_mark_dynamic_ref_symbol): Check if a symbol is hidden
      	by linker script.
      
      	* linker.c (bfd_hide_sym_by_version): New.
      
      	* bfd-in2.h: Regenerated.
      
      include/
      
      2011-09-15  H.J. Lu  <hongjiu.lu@intel.com>
      
      	PR ld/12975
      	* bfdlink.h (bfd_link_info): Add version_info.
      
      ld/
      
      2011-09-15  H.J. Lu  <hongjiu.lu@intel.com>
      
      	PR ld/12975
      	* ldlang.c (lang_elf_version_info): Removed.
      	(lang_register_vers_node): Replace lang_elf_version_info with
      	link_info.version_info.
      	(lang_add_vers_depend): Likewise.
      	* pe-dll.c (process_def_file_and_drectve): Likewise.
      	* emultempl/solaris2.em (elf_solaris2_before_allocation): Likewise.
      
      	* ldlang.h (lang_elf_version_info): Removed.
      
      	* plugin.c  (is_visible_from_outside): Check if symbol is hidden
      	by version script.
      
      	* emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation):
      	Remove lang_elf_version_info.
      
      ld/testsuite/
      
      2011-09-15  H.J. Lu  <hongjiu.lu@intel.com>
      
      	PR ld/12975
      	* ld-elf/pr12975.d: New.
      	* ld-elf/pr12975.s: Likewise.
      	* ld-elf/pr12975.t: Likewise.
      fd91d419
  19. 17 Aug, 2011 1 commit
    • Alan Modra's avatar
      PR ld/12762 · c77ec726
      Alan Modra authored
      bfd/
      	* bfd-in.h (struct bfd_section_already_linked): Forward declare.
      	(_bfd_handle_already_linked): Declare.
      	* coff-alpha.c (_bfd_ecoff_section_already_linked): Define as
      	_bfd_coff_section_already_linked.
      	* coff-mips.c (_bfd_ecoff_section_already_linked): Likewise.
      	* coffcode.h (coff_section_already_linked): Likewise.
      	* cofflink.c (coff_link_add_symbols): Revert 2011-07-09 changes.
      	* elf-bfd.h: Likewise.
      	* libbfd-in.h: Likewise.
      	* targets.c: Likewise.
      	* linker.c (bfd_section_already_linked): Likewise.
      	(bfd_section_already_linked_table_lookup): Likewise.
      	(bfd_section_already_linked_table_insert): Likewise.
      	(_bfd_generic_section_already_linked): Likewise.  Call
      	_bfd_handle_already_linked.
      	(_bfd_handle_already_linked): New function, split out from..
      	* elflink.c (_bfd_elf_section_already_linked): ..here.  Revert
      	2011-07-09 changes.  Avoid unnecessary strcmp when matching
      	already_linked_list entries.  Match plugin linkonce section.
      	(section_signature): Delete.
      	* coffgen.c (_bfd_coff_section_already_linked): New function.
      	* libcoff-in.h (_bfd_coff_section_already_linked): Declare.
      	* libbfd.h: Regenerate.
      	* libcoff.h: Regenerate.
      	* bfd-in2.h: Regenerate.
      ld/
      	* ldlang.c (section_already_linked): Revert 2011-07-09 changes.
      	* plugin.c: Likewise.
      	(asymbol_from_plugin_symbol): Create linkonce section for syms
      	with comdat_key.
      c77ec726
  20. 09 Aug, 2011 1 commit
    • Matthew Gretton-Dann's avatar
      * bfd/bfd-in.h (bfd_elf32_arm_set_target_relocs): Update prototype. · 2de70689
      Matthew Gretton-Dann authored
      	* bfd/bfd-in2.h (bfd_elf32_arm_set_target_relocs): Likewise.
      	* bfd/elf32-arm.c (elf32_arm_link_hash_table): New field.
      	(elf232_arm_link_hash_table_create): Initialise new field.
      	(check_use_blx): Change test depending on fix_arm1176.
      	(bfd_elf32_arm_set_target_relocs): Set fix_arm1176 from
      	command line options.
      	* ld/emultempl/armelf.em (fix_arm1176): New variable.
      	(arm_elf_create_output_section_statements): Pass
      	fix_arm1176 option to bfd backend.
      	(OPTION_FIX_ARM1176): New define.
      	(OPTION_NO_FIX_ARM1176): Likewise.
      	(PARSE_AND_LIST_LONGOPTS): Add new command line options.
      	(PARSE_AND_LIST_OPTIONS): Likewise.
      	(PARSE_AND_LIST_ARGS_CASES): Likewise.
      	* ld/ld.texinfo: Document new command line options.
      	* ld/testsuite/ld-arm/arm-elf.exp (armelftests): Update for new command-line
      	options.
      	(armeabitests): Update for new command-line options, and add
      	new test cases.
      	* ld/testsuite/ld-arm/fix-arm1176.s: Add test case.
      	* ld/testsuite/ld-arm/fix-arm1176-off.d: Likewise.
      	* ld/testsuite/ld-arm/fix-arm1176-on.d: Likewise.
      2de70689
  21. 09 May, 2011 1 commit
    • Paul Brook's avatar
      2011-05-09 Paul Brook <paul@codesourcery.com> · fbd9ad90
      Paul Brook authored
      	bfd/
      	* bfd-in.h (elf32_tic6x_fix_exidx_coverage): Add prototype.
      	* bfd-in2.h: Regenerate.
      	* elf32-tic6x.c: Include limits.h.
      	(tic6x_unwind_edit_type, tic6x_unwind_table_edit,
      	_tic6x_elf_section_data): New.
      	(elf32_tic6x_section_data): Define.
      	(elf32_tic6x_new_section_hook): Allocate target specific data.
      	(elf32_tic6x_add_unwind_table_edit): New function.
      	(get_tic6x_elf_section_data, elf32_tic6x_adjust_exidx_size,
      	elf32_tic6x_insert_cantunwind_after, elf32_tic6x_add_low31,
      	elf32_tic6x_copy_exidx_entry): New functions.
      	(elf_backend_write_section): Define.
      
      	ld/
      	* emultempl/tic6xdsbt.em (merge_exidx_entries): New.
      	(compare_output_sec_vma): New function.
      	(gld${EMULATION_NAME}_after_allocation): New function.
      	(OPTION_NO_MERGE_EXIDX_ENTRIES): Define.
      	(PARSE_AND_LIST_OPTIONS): Add --no-merge-exidx-entries.
      	(PARSE_AND_LIST_ARGS_CASES): Add OPTION_NO_MERGE_EXIDX_ENTRIES.
      	(LDEMUL_AFTER_ALLOCATION): Set.
      	* ld.texinfo: Document c6x --no-merge-exidx-entries.
      
      	ld/testsuite/
      	* ld-tic6x/discard-unwind.ld: New.
      	* ld-tic6x/unwind.ld: New.
      	* ld-tic6x/unwind-1.d: New test.
      	* ld-tic6x/unwind-1.s: New test.
      	* ld-tic6x/unwind-2.d: New test.
      	* ld-tic6x/unwind-2.s: New test.
      	* ld-tic6x/unwind-3.d: New test.
      	* ld-tic6x/unwind-3.s: New test.
      	* ld-tic6x/unwind-4.d: New test.
      	* ld-tic6x/unwind-4.s: New test.
      	* ld-tic6x/unwind-5.d: New test.
      	* ld-tic6x/unwind-5.s: New test.
      	* ld-tic6x/unwind-6.d: New test.
      fbd9ad90
  22. 20 Apr, 2011 1 commit
    • Alan Modra's avatar
      bfd/ · 8ad17b3a
      Alan Modra authored
      	* hash.c (bfd_default_hash_table_size): Make it an unsigned long.
      	(bfd_hash_table_init_n): Overflow checking.
      	(bfd_hash_set_default_size): Return current size.  Take unsigned long
      	arg.  Add 65537 to hash_size primes.
      	* bfd-in.h (bfd_hash_set_default_size): Update prototype.
      	* bfd-in2.h: Regenerate.
      gas/
      	* hash.c (set_gas_hash_table_size): Use bfd_hash_set_default_size.
      	(hash_new_sized): New function, split out from..
      	(hash_new): ..here.
      ld/
      	* ld.h (ld_config_type <hash_table_size>): Make it an unsigned long.
      8ad17b3a
  23. 11 Apr, 2011 1 commit
    • Alan Modra's avatar
      * bfd-in.h (bfd_get_section_limit): Don't use rawsize with output · e57278ef
      Alan Modra authored
      	sections.
      	* libbfd.c (_bfd_generic_get_section_contents): Likewise.
      	(_bfd_generic_get_section_contents_in_window): Likewise.
      	* section.c (bfd_get_section_contents): Likewise.
      	* compress.c (bfd_get_full_section_contents): Likewise.
      	* elf32-rx.c (rx_final_link): Ignore rawsize.
      	* elf32-microblaze.c (microblaze_elf_relocate_section): Use correct
      	bfd with bfd_get_section_limit.
      	* elfxx-ia64.c (elfNN_ia64_choose_gp): Add "final" parameter.  Use
      	os->size during final link.  Update callers.
      	* bfd-in2.h: Regenerate.
      e57278ef
  24. 08 Nov, 2010 1 commit
    • Alan Modra's avatar
      bfd/ · 4e011fb5
      Alan Modra authored
      	* hash.c (bfd_hash_hash): Extract from..
      	(bfd_hash_lookup): ..here.
      	(bfd_hash_rename): New function.
      	* section.c (bfd_rename_section): New function.
      	* bfd-in.h (bfd_hash_rename): Declare.
      	* bfd-in2.h: Regenerate.
      	* elf.c (_bfd_elf_make_section_from_shdr): Rename input sections
      	when compressing or decompressing.  Don't assert name match.
      	* elf64-hppa.c (get_reloc_section): Don't assert name match.
      	* elfxx-ia64.c (get_reloc_section): Likewise.
      binutils/
      	* objcopy.c (copy_main): No need to rename sections when compressing
      	or decompressing.
      binutils/testsuite/
      	* binutils-all/objdump.W: Adjust expected result for debug section
      	rename.
      4e011fb5
  25. 21 Apr, 2010 1 commit
    • Andrew Haley's avatar
      2010-04-15 Andrew Haley <aph@redhat.com> · 85fdf906
      Andrew Haley authored
      	* emultempl/armelf.em (merge_exidx_entries): New variable.
      	(OPTION_NO_MERGE_EXIDX_ENTRIES): New definition.
      	("no-merge-exidx-entries"): New option.
      	* ld.texinfo (merge-exidx-entries): Document this option.
      
      2010-04-15  Andrew Haley  <aph@redhat.com>
      
      	* bfd-in.h (elf32_arm_fix_exidx_coverage): Add new flag:
      	merge_exidx_entries.
      	* bfd-in2.h: Likewise.
      	* elf32-arm.c (elf32_arm_fix_exidx_coverage): Likewise.  Use it to
      	control merging of exidx entries.
      
      2010-04-15  Andrew Haley  <aph@redhat.com>
      
      	* options.h (merge_exidx_entries): New option.
      	* arm.cc (class Arm_exidx_fixup): Add new arg, merge_exidx_entries.
      	(class Arm_exidx_fixup::merge_exidx_entries_): New member.
      	(Output_section::fix_exidx_coverage): Add new arg, merge_exidx_entries.
      	(Target_arm::merge_exidx_entries): New function.
      	(process_exidx_entry): Don't merge if merge_exidx_entries_ is false.
      	(Arm_output_section::fix_exidx_coverage): Pass merge_exidx_entries
      	to Arm_exidx_fixup constructor.
      	Add new arg, merge_exidx_entries.
      	(Target_arm::fix_exidx_coverage): pass merge_exidx_entries to
      	Arm_output_section::fix_exidx_coverage.
      85fdf906
  26. 26 Mar, 2010 1 commit
  27. 25 Jan, 2010 1 commit
    • Alan Modra's avatar
      PR ld/11217 · 766bc656
      Alan Modra authored
      	* elf64-ppc.c (ppc64_elf_tls_optimize): Optimize tls sequences
      	with relocations against undefined weak symbols.
      	(ppc64_elf_relocate_section): Don't optimize calls to undefined
      	weak functions if the symbol is dynamic.
      	(ppc64_elf_relocate_section): Edit tprel tls sequences.
      	* elf32-ppc.c (ppc_elf_relocate_section): Likewise.
      	(_bfd_elf_ppc_at_tprel_transform): New function.
      	* bfd-in.h (_bfd_elf_ppc_at_tprel_transform): Declare.
      	* bfd-in2.h: Regenerate.
      766bc656
  28. 18 Nov, 2009 1 commit
    • Alan Modra's avatar
      bfd/ · 2d0f3896
      Alan Modra authored
      	* bfd-in.h (_bfd_elf_ppc_at_tls_transform): Declare.
      	* bfd-in2.h: Regenerate.
      	* elf64-ppc.c (ppc64_elf_relocate_section): Move code for R_PPC64_TLS
      	insn optimisation to..
      	* elf32-ppc.c (_bfd_elf_ppc_at_tls_transform): ..here.  New function.
      	(ppc_elf_relocate_section): Use it.
      gas/
      	* config/tc-ppc.c (md_assemble): Report error on invalid @tls operands
      	and opcode.
      2d0f3896
  29. 23 Sep, 2009 1 commit
    • Alan Modra's avatar
      bfd/ · 7ee314fa
      Alan Modra authored
      	* bfd-in.h (bfd_elf_size_dynamic_sections): Add audit and depaudit
      	arguments.
      	* elflink.c (bfd_elf_size_dynamic_sections): Generate DT_AUDIT,
      	DT_DEPAUDIT from audit/depaudit arguments.
      	(elf_finalize_dynstr): Finalize DT_AUDIT and DT_DEPAUDIT strtab entries.
      	(elf_link_add_object_symbols): Set dt_audit target data when finding a
      	DT_AUDIT.
      	* bfd-in2.h: Regenerate.
      	* bfd-elf.h: Add dt_audit to elf_obj_tdata, and elf_dt_audit macro.
      ld/
      	* emultempl/elf32.em (gld${EMULATION_NAME}_add_options): Add --audit,
      	--depaudit, and -P options.
      	(gld${EULATION_NAME}_handle_options): Ditto.
      	(gld${EULATION_NAME}_list_options): Ditto.
      	(gld${EMULATION_NAME}_append_to_separated_string): New function for
      	handling rpath-like colon separated strings.
      	(gld${EMULATION_NAME}_before_allocation): Pass the audit and depaudit
      	libs to bfd.  Propagate DT_AUDIT from needed libs to depaudit.
      	* ld.texinfo: Document new options.
      ld/testsuite/
      	* ld-elf/audit.exp: New.
      	* ld-elf/audit.rd: New.
      	* ld-elf/depaudit.rd: New.
      	* ld-elf/depaudit2.rd: New.
      7ee314fa
  30. 02 Sep, 2009 1 commit
  31. 26 May, 2009 1 commit
    • Nick Clifton's avatar
      * Makefile.am: Run "make dep-am". · ce3c775b
      Nick Clifton authored
              (AM_CPPFLAGS): New.
              (LIBDL): New.
              (ALL_MACHINES): Add cpu-plugin.lo.
              (ALL_MACHINES_CFILES): Add cpu-plugin.c.
              (BFD32_BACKENDS): Add plugin.lo.
              (BFD32_BACKENDS_CFILES): Add plugin.c.
              (libbfd_la_LIBADD): Add LIBDL
              * archures.c (bfd_architecture): Add bfd_arch_plugin.
              (bfd_plugin_arch): Declare.
              * bfd-in.h (BFD_SUPPORTS_PLUGINS): New.
              * bfd.c (bfd): Add plugin_data.
              * config.bfd: Handle the plugin target.
              * configure.in: Check for --enable-plugins.
              (LT_INIT): Use the dlopen option.
              * cpu-plugin.c: New.
              * plugin.c: New.
              * plugin.h: New.
              * targets.c (plugin_vec): Declare.
              (_bfd_target_vector): Add plugin_vec.
              * Makefile.in: Regenerate.
              * bfd-in2.h: Regenerate.
              * configure: Regenerate.
              * ar.c: Include plugin.h.
              (main): Handle the --plugin option.
              * nm.c: Include plugin.h.
              (OPTION_PLUGIN): New.
              (long_options): Add plugin.
              (main): Handle OPTION_PLUGIN.
              * NEWS: Mention  the new feature.
              * doc/binutils: Documement the new command line options.
              * configure.in: Check for --enable-plugins.
              * configure: Regenerate.
      ce3c775b
  32. 22 May, 2009 1 commit
    • Julian Brown's avatar
      ld/ · 48229727
      Julian Brown authored
          * emultempl/armelf.em (fix_cortex_a8): New.
          (arm_elf_before_allocation): Call bfd_elf32_arm_set_cortex_a8_fix.
          (arm_elf_create_output_section_statements): Add fix_cortex_a8 to
          bfd_elf32_arm_set_target_relocs.
          (OPTION_FIX_CORTEX_A8, OPTION_NO_FIX_CORTEX_A8): New.
          (PARSE_AND_LIST_LONGOPTS): Add [no-]fix-cortex-a8 options.
          (PARSE_AND_LIST_OPTIONS): Add [no-]fix-cortex-a8 options.
          (PARSE_AND_LIST_ARGS_CASES): Handle OPTION_[NO_]FIX_CORTEX_A8.
          * ld.texinfo (--[no-]fix-cortex-a8): Briefly document new options.
      
          bfd/
          * elf32-arm.c (THUMB16_BCOND_INSN, THUMB32_INSN, THUMB32_B_INSN):
          New macros.
          (elf32_arm_stub_a8_veneer_b_cond, elf32_arm_stub_a8_veneer_b)
          (elf32_arm_stub_a8_veneer_blx): New stub sequences.
          (elf32_arm_stub_type): Add arm_stub_a8_veneer_b_cond,
          arm_stub_a8_veneer_b and arm_stub_a8_veneer_blx.
          (elf32_arm_stub_hash_entry): Add target_addend, orig_insn fields.
          (a8_erratum_fix, a8_erratum_reloc): New structs.
          (elf32_arm_link_hash_table): Add a8_erratum_fixes,
          num_a8_erratum_fixes, fix_cortex_a8 fields.
          (elf32_arm_link_hash_table_create): Zero fix_cortex_a8.
          (elf32_arm_add_stub): Split into two parts, creating...
          (elf32_arm_create_or_find_stub_sec): New function.
          (elf32_arm_final_link_relocate): Add forward declaration.
          (arm_build_one_stub): Add support for THUMB32_TYPE, Thumb-2
          relocations, multiple relocations per stub.
          (find_stub_size_and_template): New (using parts of
          arm_size_one_stub).
          (arm_size_one_stub): Use find_stub_size_and_template.
          (a8_reloc_compare): New.
          (find_thumb_glue): Add forward declaration.
          (cortex_a8_erratum_scan): New.
          (elf32_arm_size_stubs): Add Cortex-A8 erratum workaround support.
          (bfd_elf32_arm_set_cortex_a8_fix): New.
          (bfd_elf32_arm_set_target_relocs): Add fix_cortex_a8 argument.
          (arm_map_one_stub): Add THUMB32_TYPE support.
          (a8_branch_to_stub_data): New.
          (make_branch_to_a8_stub): New.
          (elf32_arm_write_section): Add Cortex-A8 erratum workaround support.
          * bfd-in.h (bfd_elf32_arm_set_cortex_a8_fix): New.
          (bfd_elf32_arm_set_target_relocs): Add argument for controlling
          Cortex-A8 erratum workaround.
          * bfd-in2.h: Regenerate.
      
          ld/testsuite/
          * ld-arm/cortex-a8-arm-target.s: New.
          * ld-arm/cortex-a8-thumb-target.s: New.
          * ld-arm/cortex-a8-fix-b-rel.s: New.
          * ld-arm/cortex-a8-fix-b-rel-arm.d: New.
          * ld-arm/cortex-a8-fix-b-rel-thumb.d: New.
          * ld-arm/cortex-a8-fix-b.s: New.
          * ld-arm/cortex-a8-fix-b.d: New.
          * ld-arm/cortex-a8-fix-bl-rel.s: New.
          * ld-arm/cortex-a8-fix-bl-rel-arm.d: New.
          * ld-arm/cortex-a8-fix-bl-rel-thumb.d: New.
          * ld-arm/cortex-a8-fix-bl.s: New.
          * ld-arm/cortex-a8-fix-bl.d: New.
          * ld-arm/cortex-a8-fix-bcc-rel.s: New.
          * ld-arm/cortex-a8-fix-bcc-rel-thumb.d: New.
          * ld-arm/cortex-a8-fix-bcc.s: New.
          * ld-arm/cortex-a8-fix-bcc.d: New.
          * ld-arm/cortex-a8-fix-blx-rel.s: New.
          * ld-arm/cortex-a8-fix-blx-rel-arm.d: New.
          * ld-arm/cortex-a8-fix-blx-rel-thumb.d: New.
          * ld-arm/cortex-a8-fix-blx.s: New.
          * ld-arm/cortex-a8-fix-blx.d: New.
          * ld-arm/arm-elf.exp: Add new tests.
      48229727
  33. 05 May, 2009 1 commit
    • Paul Brook's avatar
      2009-05-05 Paul Brook <paul@codesourcery.com> · 2468f9c9
      Paul Brook authored
      	bfd/
      	* bfd-in.h (elf32_arm_fix_exidx_coverage): Add prototype.
      	* bfd-in2.h: Regenerate.
      	* elf32-arm.c (arm_unwind_edit_type, arm_unwind_table_edit): Define.
      	(_arm_elf_section_data): Add text and exidx fields.
      	(add_unwind_table_edit, get_arm_elf_section_data, adjust_exidx_size,
      	insert_cantunwind_after, elf32_arm_fix_exidx_coverage, offset_prel31,
      	copy_exidx_entry): New functions.
      	(elf32_arm_write_section): Fixup .ARM.exidx contents.
      
      	ld/
      	* emultempl/armelf.em (compare_output_sec_vma): New function.
      	(gld${EMULATION_NAME}_finish): Add exidx munging code.
      
      	ld/testsuite/
      	* ld-arm/arm.ld: Add .ARM.exidx and .ARM.extab.
      	* ld-arm/arm-elf.exp: Add unwind-[1-4].
      	* ld-arm/unwind-1.d: New test.
      	* ld-arm/unwind-1.s: New test.
      	* ld-arm/unwind-2.d: New test.
      	* ld-arm/unwind-2.s: New test.
      	* ld-arm/unwind-3.d: New test.
      	* ld-arm/unwind-3.s: New test.
      	* ld-arm/unwind-4.d: New test.
      	* ld-arm/unwind-4.s: New test.
      2468f9c9
  34. 01 Apr, 2009 1 commit
    • Richard Sandiford's avatar
      bfd/ · 24c611d1
      Richard Sandiford authored
      	* bfd-in.h (bfd_xcoff_split_import_path): Declare.
      	(bfd_xcoff_set_archive_import_path): Likewise.
      	* bfd-in2.h: Regenerate.
      	* xcofflink.c: Include libiberty.h.
      	(xcoff_archive_info): New structure.
      	(xcoff_archive_info_hash): New function.
      	(xcoff_archive_info_eq): Likewise.
      	(xcoff_get_archive_info): Likewise.
      	(_bfd_xcoff_bfd_link_hash_table_create): Initialize archive_info.
      	(bfd_xcoff_split_import_path): New function.
      	(bfd_xcoff_set_archive_import_path): Likewise.
      	(xcoff_set_import_path): Move earlier in file.
      	(xcoff_link_add_dynamic_symbols): Set the import path of a non-archive
      	object to the the directory part of the bfd's filename.  Get the
      	import path and filename of an archive object from the archive's
      	xcoff_tdata, initializing it if necessary.  Update use of
      	import_file_id.
      	(bfd_link_input_bfd): Update use of import_file_id.
      	(xcoff_write_global_symbol): Likewise.
      
      ld/
      	* emultempl/aix.em (gld${EMULATION_NAME}_open_dynamic_archive): New
      	function.
      	(ld_${EMULATION_NAME}_emulation): Use it.
      24c611d1
  35. 14 Mar, 2009 1 commit
    • Richard Sandiford's avatar
      include/coff/ · b64232cc
      Richard Sandiford authored
      	* xcoff.h (XCOFF_EXPALL, XCOFF_EXPFULL): New flags.
      	(xcoff_loader_info): Add auto_export_flags.
      
      bfd/
      	* bfd-in.h (bfd_xcoff_size_dynamic_sections): Replace the
      	bfd_boolean export_defineds parameter with an unsigned int
      	auto_export_flags parameter.
      	* bfd-in2.h: Regenerate.
      	* xcofflink.c (xcoff_archive_contains_shared_object_p): New function,
      	split out from xcoff_build_ldsyms.
      	(xcoff_covered_by_expall_p): New function.
      	(xcoff_auto_export_p): New function, split out from xcoff_build_ldsyms
      	but with extra code to handle -bexpfull and -bexpall.
      	(xcoff_mark_auto_exports): New function.
      	(xcoff_build_ldsyms): Use xcoff_auto_export_p to decide whether
      	a function should be automatically exported.
      	(bfd_xcoff_size_dynamic_sections): Replace the export_defineds
      	parameter with an auto_export_flags parameter.  Update ldinfo
      	accordingly.  Use xcoff_mark_auto_exports to mark all automatically-
      	exported symbols.
      
      ld/
      	* emultempl/aix.em (auto_export_flags): New variable.
      	(explicit_auto_export_flags): Likewise.
      	(OPTION_EXPALL, OPTION_EXPFULL): New enum values.
      	(OPTION_NOEXPALL, OPTION_NOEXPFULL): Likewise.
      	(gld${EMULATION_NAME}_add_options): Add -bexpall, -bexpfull,
      	-bnoexpall and -bnoexpfull.
      	(gld${EMULATION_NAME}_handle_option): Handle them.
      	(gld${EMULATION_NAME}_before_allocation): Update the call to
      	bfd_size_dynamic_sections.
      
      ld/testsuite/
      	* ld-powerpc/aix-export-1-all.dd, ld-powerpc/aix-export-1-full.dd,
      	ld-powerpc/aix-export-1a.s, ld-powerpc/aix-export-1b.s: New tests.
      	* ld-powerpc/aix52.exp: Run them.
      b64232cc
  36. 27 Nov, 2008 1 commit
    • M R Swami Reddy's avatar
      · 99706f30
      M R Swami Reddy authored
              * Add PIC support for CR16 target.
              * elf32-cr16.c (R_CR16_GOT_REGREL20, R_CR16_GOTC_REGREL20 and
              R_CR16_GLOB_DAT): New macros
              (cr16_elf_howto_table): Add entries for for R_CR16_GOT_REGREL20,
              R_CR16_GOTC_REGREL20 and R_CR16_GLOB_DAT.
              (cr16_reloc_map): Ditto
              (_bfd_cr16_elf_create_got_section): New function to create GOT section.
              (_bfd_cr16_elf_create_dynamic_sections): New function to create dynamic
              section.
              (_bfd_cr16_elf_adjust_dynamic_symbol): New function to adjust symbol
              defined by dynamic object.
              (_bfd_cr16_elf_size_dynamic_sections): New function to find the size
              of dynamic section.
              (_bfd_cr16_elf_finish_dynamic_symbol): New function to handle dynamic
              symbols.
              (_bfd_cr16_elf_finish_dynamic_symbol): New function to handle dynamic
              sections.
              (bfd_cr16_elf32_create_embedded_relocs): New function to create
              embedded relocs in .emreloc section in memory for .data.rel section.
              (_bfd_cr16_elf_reloc_type_class): New function for classify reloc types.
              (cr16_elf_check_relocs): New function for checking reloc types in
              first phase.
              (cr16_elf_final_link_relocate): Update for handling the new reloc
              types R_CR16_GOT_REGREL20 and R_CR16_GOTC_REGREL20.
              (elf32_cr16_relax_section): Update relax implementation.
              * reloc.c (bfd_reloc_code_type): Add entries for R_CR16_GOT_REGREL20,
              R_CR16_GOTC_REGREL20 and R_CR16_GLOB_DAT.
              * bfd-in.h (bfd_boolean bfd_cr16_elf32_create_embedded_relocs): Declared
              * libbfd.h, bfd-in2.h: Regenerate.
      99706f30
  37. 28 Jul, 2008 1 commit
    • Alan Modra's avatar
      bfd/ · 14a91970
      Alan Modra authored
      	PR 6769
      	* bfd-in.h (BFD_VMA_FMT): Define.
      	(printf_vma, sprintf_vma): Use the above.
      	(_bfd_int64_low, _bfd_int64_high): Delete.
      	* bfd-in2.h: Regenerate.
      binutils/
      	PR 6769
      	* readelf.c (print_dec_vma, print_hex_vma): Delete.
      	(print_vma): Use BFD_VMA_FMT.
      	* size.c (size_number, rprint_number): Likewise.
      14a91970
  38. 18 Jul, 2008 1 commit
    • Joseph Myers's avatar
      bfd: · a9dc9481
      Joseph Myers authored
      	* bfd-in.h (bfd_elf32_arm_set_target_relocs): Add new parameter.
      	* bfd-in2.h: Regenerate.
      	* elf32-arm.c (struct elf_arm_obj_tdata): Add field
      	no_wchar_size_warning.
      	(bfd_elf32_arm_set_target_relocs): Add new parameter
      	no_wchar_warn.
      	(elf32_arm_merge_eabi_attributes): Give a warning, not an error,
      	for conflicting wchar_t attributes.  Do not warn if
      	--no-wchar-size-warning.  Make diagnostic text more specific.
      
      ld:
      	* ld.texinfo (--no-wchar-size-warning): Document new ARM option.
      	* emultempl/armelf.em (no_wchar_size_warning): New.
      	(arm_elf_create_output_section_statements): Pass
      	no_wchar_size_warning to arm_elf_create_output_section_statements.
      	(OPTION_NO_WCHAR_SIZE_WARNING): New.
      	(PARSE_AND_LIST_LONGOPTS): Add no-wchar-size-warning.
      	(PARSE_AND_LIST_OPTIONS): List --no-wchar-size-warning.
      	(PARSE_AND_LIST_ARGS_CASES): Handle --no-wchar-size-warning.
      
      ld/testsuite:
      	* ld-arm/attr-merge-wchar-0.s,ld-arm/attr-merge-wchar-2.s,
      	ld-arm/attr-merge-wchar-4.s, ld-arm/attr-merge-wchar-00-nowarn.d,
      	ld-arm/attr-merge-wchar-00.d, ld-arm/attr-merge-wchar-02-nowarn.d,
      	ld-arm/attr-merge-wchar-02.d, ld-arm/attr-merge-wchar-04-nowarn.d,
      	ld-arm/attr-merge-wchar-04.d, ld-arm/attr-merge-wchar-20-nowarn.d,
      	ld-arm/attr-merge-wchar-20.d, ld-arm/attr-merge-wchar-22-nowarn.d,
      	ld-arm/attr-merge-wchar-22.d, ld-arm/attr-merge-wchar-24-nowarn.d,
      	ld-arm/attr-merge-wchar-24.d, ld-arm/attr-merge-wchar-40-nowarn.d,
      	ld-arm/attr-merge-wchar-40.d, ld-arm/attr-merge-wchar-42-nowarn.d,
      	ld-arm/attr-merge-wchar-42.d, ld-arm/attr-merge-wchar-44-nowarn.d,
      	ld-arm/attr-merge-wchar-44.d: New.
      	* ld-arm/arm-elf.exp: Run new tests.
      a9dc9481
  39. 30 Jun, 2008 1 commit
    • Richard Sandiford's avatar
      bfd/ · 6ba2a415
      Richard Sandiford authored
      	* syms.c (BSF_SYNTHETIC): New flag.
      	* elf.c (_bfd_elf_get_synthetic_symtab): Set it.
      	* elf32-ppc.c (ppc_elf_get_synthetic_symtab): Likewise.
      	* elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Likewise.
      	* bfd-in.h (bfd_asymbol_flavour): Return bfd_target_unknown_flavour
      	for synthetic symbols.
      	* bfd-in2.h: Regenerate.
      
      opcodes/
      	* mips-dis.c (_print_insn_mips): Use bfd_asymbol_flavour to check
      	for ELF symbols.
      6ba2a415
  40. 21 May, 2008 1 commit
    • Nick Clifton's avatar
      Multi-GOT support for m68k. · 7fb9f789
      Nick Clifton authored
              bfd/
      
              * elf32-m68k.c (struct elf_m68k_link_hash_entry: got_entry_key,
              glist): New fields.
              (struct elf_m68k_got_entry_key, struct elf_m68k_got_entry,
              struct elf_m68k_got, struct elf_m68k_bfd2got_entry,
              struct elf_m68k_multi_got): New data structures.
              (struct elf_m68k_link_hash_table: local_gp_p, use_neg_got_offsets_p,
              allow_multigot_p, multi_got_): New fields.
              (elf_m68k_multi_got): New macro.
              (elf_m68k_link_hash_newfunc): Initialize new fields of
              struct elf_m68k_link_hash_entry.
              (elf_m68k_link_hash_table_create): Initialize new fields of
              struct elf_m68k_link_hash_table.
              (elf_m68k_link_hash_table_free): New static function implementing hook.
              (elf_m68k_init_got, elf_m68k_clear_got, elf_m68k_create_empty_got): New
              static functions for struct elf_m68k_got.
              (elf_m68k_init_got_entry_key, elf_m68k_got_entry_hash,
              elf_m68k_got_entry_eq): New static functions for
              struct elf_m68k_got_entry.
              (ELF_M68K_REL_8O_MAX_N_ENTRIES_IN_GOT,
              ELF_M68K_REL_8O_16O_MAX_N_ENTRIES_IN_GOT): New macros.
              (enum elf_m68k_get_entry_howto): New enum.
              (elf_m68k_get_got_entry, elf_m68k_update_got_entry_type,
              elf_m68k_remove_got_entry_type): New static functions for
              struct elf_m68k_got_entry.
              (elf_m68k_add_entry_to_got): New static function.
              (elf_m68k_bfd2got_entry_hash, elf_m68k_bfd2got_entry_eq,
              elf_m68k_bfd2got_entry_del, elf_m68k_get_bfd2got_entry): New static
              functions for struct elf_m68k_bfd2got_entry.
              (struct elf_m68k_can_merge_gots_arg, elf_m68k_can_merge_gots_1,
              elf_m68k_can_merge_gots): New traversal.
              (struct elf_m68k_merge_gots_arg, elf_m68k_merge_gots_1,
              elf_m68k_merge_gots): Ditto.
              (struct elf_m68k_finalize_got_offsets_arg,
              elf_m68k_finalize_got_offsets_1, elf_m68k_finalize_got_offsets): Ditto.
              (struct elf_m68k_partition_multi_got_arg,
              elf_m68k_partition_multi_got_1, elf_m68k_init_symndx2h_1,
              elf_m68k_partition_multi_got): Ditto.
              (elf_m68k_find_got_entry_ptr, elf_m68k_remove_got_entry): New static
              functions.
              (elf_m68k_copy_indirect_symbol): New static function implementing
              a hook.
              (elf_m68k_check_relocs): Update to add entries to multi-GOT.
              (elf_m68k_gc_sweep_hook): Update to remove entries from multi-GOT.
              (elf_m68k_always_size_sections): Assign BFDs to GOTs.
              (elf_m68k_relocate_section): Update to properly handle GOT relocations.
              (elf_m68k_finish_dynamic_symbol): Update to traverse all GOT entries
              of a global symbol.
              (bfd_elf_m68k_set_target_options): New function.
              (bfd_elf32_bfd_link_hash_table_free): Define hook.
              (bfd_elf32_bfd_final_link): Change expansion to bfd_elf_final_link
              to skip generic calculation of GOT offsets.
              (elf_backend_copy_indirect_symbol): Define hook.
      
              * bfd-in.h (bfd_elf_m68k_set_target_options): Declare function.
              * bfd-in2.h: Regenerate.
      
              ld/
      
              * configure.in (--enable-got): New option.  Handle it.
              * configure: Regenerate.
              * config.in: Regenerate.
      
              * emultempl/m68kelf.em: (got_handling_target_default): New shell
              variable.
              (GOT_HANDLING_TARGET_DEFAULT): New macro.
              (GOT_HANDLING_DEFAULT): New macro.  Initialize it from configure
              option if one was given.
              (got_handling): New static variable.
              (elf_m68k_create_output_section_statements): New static function
              implementing hook.
              (PARSE_AND_LIST_PROLOGUE): Define shell variable.
              (OPTION_GOT): New macro.
              (PARSE_AND_LIST_LONGOPTS): Define shell variable.  Specify
              --got option.
              (got): New linker option.
              (PARSE_AND_LIST_OPTIONS): Define shell variable.  Print help string
              for --got option.
              (PARSE_AND_LIST_ARGS_CASES): Define shell variable.  Handle --got
              option.
      
              * ld.texinfo: Document --got=<type> option.
              * gen-doc.texi: Add M68K.
              * NEWS: Mention the new feature.
      
              ld/testsuite/
      
              * ld-m68k/got-12.s: New file.
              * ld-m68k/got-13.s: New file.
              * ld-m68k/got-14.s: New file.
              * ld-m68k/got-15.s: New file.
              * ld-m68k/got-34.s: New file.
              * ld-m68k/got-35.s: New file.
              * ld-m68k/got-single-12-ok.d: New dump test.
              * ld-m68k/got-single-13-er.d: New dump test.
              * ld-m68k/got-negative-14-ok.d: New dump test.
              * ld-m68k/got-negative-15-er.d: New dump test.
              * ld-m68k/got-negative-12-13-14-34-ok.d: New dump test.
              * ld-m68k/got-negative-12-13-14-35-er.d: New dump test.
              * ld-m68k/got-multigot-14-ok.d: New dump test.
              * ld-m68k/got-multigot-15-er.d: New dump test.
              * ld-m68k/got-multigot-12-13-14-34-35-ok.d: New dump test.
              * ld-m68k/xgot-15.s: New source.
              * ld-m68k/got-xgot-15-ok.d: New test.
              * ld-m68k/got-xgot-12-13-14-15-34-35-ok.d: New test.
              * ld-m68k/m68k.exp: Run new tests.
      7fb9f789