aboutsummaryrefslogtreecommitdiff
path: root/ld
AgeCommit message (Collapse)AuthorFilesLines
2005-06-06bfd/Alan Modra2-2/+7
* elf64-pcc.c (ppc64_elf_gc_mark_hook): For the local sym in .opd case, include addend when indexing .opd section map. (ppc64_elf_edit_opd): Add no_opd_opt param. Do nothing besides clear opd_adjust array if no_opd_opt set. Tidy code. * elf64-ppc.h (ppc64_elf_edit_opd): Update prototype. ld/ * emultempl/ppc64elf.em (ppc_before_allocation): Always run ppc64_elf_edit_opd.
2005-06-05ld/H.J. Lu6-32/+48
2005-06-05 H.J. Lu <hongjiu.lu@intel.com> * ldexp.c (exp_mark_used_section): Set SEC_KEEP on current section only if the symbol will be defined. ld/testsuite/ 2005-06-05 H.J. Lu <hongjiu.lu@intel.com> * ld-cris/hiddef1.d: Undo the last change. * ld-cris/libdso-10.d: Likewise. * ld-cris/libdso-2.d: Likewise.
2005-06-042005-06-04 H.J. Lu <hongjiu.lu@intel.com>H.J. Lu4-19/+29
* ld-cris/hiddef1.d: Updated. * ld-cris/libdso-10.d: Likewise. * ld-cris/libdso-2.d: Likewise.
2005-06-042005-06-04 H.J. Lu <hongjiu.lu@intel.com>H.J. Lu3-2/+21
PR 992 * ldexp.c (exp_mark_used_section): Set SEC_KEEP on current section for etree_assign, etree_provide and etree_provided. Call fold_binary on etree_binary. * ldlang.c (lang_mark_used_section_1): Handle load base.
2005-06-03include/Alan Modra3-49/+64
* bfdlink.h (struct bfd_link_callbacks): Add einfo. bfd/ * configure.in: Bump version * configure: Regenerate. * elflink.c (elf_link_input_bfd): Use einfo linker callback to print discarded section sym refs and kill linker output. * simple.c (simple_dummy_einfo): New function. (bfd_simple_get_relocated_section_contents): Init callbacks.einfo. ld/ * ldmain.c (link_callbacks): Add einfo. (add_archive_element): Use passed info, not link_info. (constructor_callback): Likewise. (reloc_overflow): Don't handle null bfd specially. (reloc_dangerous, unattached_reloc): Likewise. * ldmisc.c (vfinfo <B>): Print "ld generated" for null bfd. (vfinfo <C, D, G>): Handle null bfd. Wrap comments.
2005-06-02 * ld-powerpc/powerpc.exp (ppcelftests): Assemble sda test with -a32.Alan Modra2-3/+7
2005-06-02 * ldexp.h (etree_value_type): Use "asection *" in place ofAlan Modra4-76/+77
"struct lang_output_section_statement_struct *" for "section". (exp_fold_tree): Likewise. (exp_mark_used_section): Likewise. * ldexp.c (new_rel, new_rel_from_section, fold_unary, fold_binary, fold_trinary, fold_name, exp_fold_tree_1, exp_fold_tree, exp_mark_used_section): Likewise for "current_section" param. (make_abs, new_abs, exp_binop, exp_unop, exp_get_vma, exp_get_fill, exp_get_abs_int): Adjust for above changes. * ldlang.c (lang_mark_used_section_1, print_assignment, lang_size_sections_1, lang_do_assignments_1): Likewise. * ldexp.c (fold_name): Init entire result struct.
2005-06-01* emulparams/elf32btsmip.sh: Unset DATA_ADDR.Maciej W. Rozycki2-0/+5
2005-06-01ld:Zack Weinberg10-40/+75
* ldlang.c (entry_symbol_default): New file-scope global. (lang_finish): Use it, not a hardwired "start". (lang_default_entry): Set it. * ldlang.h: Declare lang_default_entry. * emultempl/beos.em, emultempl/pe.em: Use lang_default_entry, not lang_add_entry, to override default entry point symbol. ld/testsuite: * ld-scripts/align.exp: Mark align1 XFAIL on PECOFF targets. * ld-scripts/data.exp: Mark data UNSUPPORTED on a.out targets. * ld-scripts/provide.exp, ld-scripts/size.exp: Mark all tests UNSUPPORTED on a.out targets. Tidy.
2005-05-29 * emulparams/elf64alpha.sh (PLT): New.Richard Henderson4-11/+108
(TEXT_PLT): New. * emultempl/alphaelf.em (disable_relaxation): New. (limit_32bit): Rename from elf64alpha_32bit; update all users. (elf64_alpha_use_secureplt): Declare. (bfd_elf64_alpha_vec, bfd_elf64_alpha_freebsd_vec): Declare. (alpha_after_open): New. (alpha_before_allocation): New. (OPTION_NO_RELAX, OPTION_SECUREPLT, OPTION_NO_SECUREPLT): New. (PARSE_AND_LIST_LONGOPTS): Include them. (PARSE_AND_LIST_OPTIONS): Likewise. (PARSE_AND_LIST_ARGS_CASES): Likewise. (LDEMUL_AFTER_OPEN, LDEMUL_BEFORE_ALLOCATION): New. * scripttempl/elf.sc (TEXT_PLT): New. (PLT): Use it.
2005-05-27 * config/default.exp (CC): Use find_gcc.Mark Mitchell2-5/+18
(CFLAGS): Define, if no definition is provided. (CXX): Likewise. (CXXFLAGS): Likewise.
2005-05-26* configure.host (HOSTING_LIBS): Add libunwind.a if it exists.Andreas Schwab2-1/+5
2005-05-252005-05-24 H.J. Lu <hongjiu.lu@intel.com>H.J. Lu3-2/+5
* ld-mmix/bpo-6.d: Updated. * ld-mmix/bpo-19.d: Likewise.
2005-05-24 * emultempl/ppc32elf.em (after_allocation): Don't callAlan Modra2-2/+8
ppc_elf_set_sdata_syms when relocatable.
2005-05-22 * ld-elfweak/dsow.dsym: Adjust for non-zero ST_OTHER.Richard Henderson4-5/+12
* ld-elfweak/weak.dsym: Likewise. * ld-selective/selective.exp: Don't test alpha.
2005-05-212005-05-21 H.J. Lu <hongjiu.lu@intel.com>H.J. Lu3-6/+18
* Makefile.am (ld.1): Revert the last 2 changes. (info-recursive): Depend on ld.1. * Makefile.in: Regenerated.
2005-05-212005-05-21 H.J. Lu <hongjiu.lu@intel.com>H.J. Lu3-6/+12
* Makefile.am (ld.1): Depend on "info" instead of "configdoc.texi ldver.texi". * Makefile.in: Regenerated.
2005-05-212005-05-21 H.J. Lu <hongjiu.lu@intel.com>H.J. Lu3-0/+9
* Makefile.am (ld.1): Depend on "info". * Makefile.in: Regenerated.
2005-05-20bfd/Daniel Jacobowitz5-0/+25
* bfd/elf32-ppc.c (struct ppc_elf_link_hash_entry): Add new field has_sda_refs. (ppc_elf_copy_indirect_symbol): Copy has_sda_refs. (ppc_elf_check_relocs): Set has_sda_refs. (ppc_elf_adjust_dynamic_symbol): Check has_sda_refs before eliminating copy relocations. Use has_sda_refs to place variables in .sbss. (ppc_elf_finish_dynamic_symbol): Use has_sda_refs to place variables in .sbss. ld/testsuite/ * ld-powerpc/sdalib.s, ld-powerpc/sdadyn.s, ld-powerpc/sdadyn.d: New files. * ld-powerpc/powerpc.exp: Run the new test.
2005-05-20 * ld-undefined/undefined.exp: Revert xfail for xtensa-*-*.Bob Wilson2-2/+4
2005-05-19 * bfd/Makefile.am, binutils/Makefile.am, etc/Makefile.inZack Weinberg3-0/+7
* gas/Makefile.am: Have 'all' depend on 'info'. * ld/Makefile.am: Have 'all' depend on 'info' and 'ld.1'. * bfd/Makefile.in, binutils/Makefile.in, gas/Makefile.in * ld/Makefile.in: Regenerate.
2005-05-18include/elf:Zack Weinberg2-3/+7
* arm.h: Import complete list of official relocation names and numbers from AAELF. Define FAKE_RELOCs for old names. Remove a few old names no longer used anywhere. bfd: * elf32-arm.c: Wherever possible, use official reloc names from AAELF. (elf32_arm_howto_table, elf32_arm_tls_gd32_howto) (elf32_arm_tls_ldo32_howto, elf32_arm_tls_ldm32_howto) (elf32_arm_tls_le32_howto, elf32_arm_tls_ie32_howto) (elf32_arm_vtinherit_howto, elf32_arm_vtentry_howto) (elf32_arm_pc11_howto, elf32_arm_thm_pc9_howto, elf32_arm_got_prel) (elf32_arm_r_howto): Replace with elf32_arm_howto_table_1, elf32_arm_howto_table_2, and elf32_arm_howto_table_3. Add many new relocations from AAELF. (elf32_arm_howto_from_type): Update to match. (elf32_arm_reloc_map): Add entries for R_ARM_THM_JUMP24, R_ARM_THM_JUMP11, R_ARM_THM_JUMP19, R_ARM_THM_JUMP8, R_ARM_THM_JUMP6, R_ARM_GNU_VTINHERIT, and R_ARM_GNU_VTENTRY. (elf32_arm_reloc_type_lookup): Use elf32_arm_howto_from_type. (elf32_arm_final_link_relocate): Add support for R_ARM_THM_JUMP24, R_ARM_THM_JUMP19, R_ARM_THM_JUMP6. Remove case entries redundant with default. * reloc.c: Reorganize ARM relocations. Add Thumb assembler-internal relocations BFD_RELOC_ARM_T32_OFFSET_U8, BFD_RELOC_ARM_T32_OFFSET_IMM, BFD_RELOC_ARM_T32_IMMEDIATE. Add visible relocations BFD_RELOC_THUMB_PCREL_BRANCH7, BFD_RELOC_THUMB_BRANCH20, BFD_RELOC_THUMB_BRANCH25. Delete unused relocations BFD_RELOC_ARM_GOT12, BFD_RELOC_ARM_COPY. * bfd-in2.h, libbfd.h: Regenerate. opcodes: * arm-dis.c (thumb_opcodes): Add disassembly for V6T2 16-bit instructions. Adjust disassembly of some opcodes to match unified syntax. (thumb32_opcodes): New table. (print_insn_thumb): Rename print_insn_thumb16; don't handle two-halfword branches here. (print_insn_thumb32): New function. (print_insn): Choose among print_insn_arm, print_insn_thumb16, and print_insn_thumb32. Be consistent about order of halfwords when printing 32-bit instructions. gas: * hash.c (hash_lookup): Add len parameter. All callers changed. (hash_find_n): New interface. * hash.h: Prototype hash_find_n. * sb.c: Include as.h. (scrub_from_sb, sb_to_scrub, scrub_position): New statics. (sb_scrub_and_add_sb): New interface. * sb.h: Prototype sb_scrub_and_add_sb. * input-scrub.c (input_scrub_include_sb): Use sb_scrub_and_add_sb. * config/tc-arm.h (TC_FORCE_RELOCATION_LOCAL): Remove reference to BFD_RELOC_ARM_GOT12 which is never generated. * config/tc-arm.c: Rewrite, adding Thumb-2 support. gas/testsuite: * gas/arm/arm.exp: Convert all existing "gas_test" tests to "run_dump_test" tests. Run more tests unconditionally. Run new tests. * gas/arm/arch4t.s, gas/arm/arch6zk.s, gas/arm/arm3.s, gas/arm/arm6.s * gas/arm/arm7dm.s, gas/arm/bignum1.s, gas/arm/float.s * gas/arm/immed.s, gas/arm/iwmmxt.s, gas/arm/offset.s, gas/arm/thumb.s: Adjust to work as a dump test. * gas/arm/arch4t.d, gas/arm/arch6zk.d, gas/arm/arm3.d, gas/arm/arm6.d * gas/arm/arm7dm.d, gas/arm/bignum1.d, gas/arm/float.d * gas/arm/immed.d, gas/arm/iwmmxt.d, gas/arm/offset.d, gas/arm/thumb.d: New files. * gas/arm/armv1-bad.l, gas/arm/armv1-bad.s: Remove tests for diagnostics that don't happen in the first pass anymore. * gas/arm/iwmmxt-bad.l, gas/arm/r15-bad.l, gas/arm/req.l * gas/arm/vfp-bad.l: Update expected diagnostics. * gas/arm/pic.d: Update expected reloc name. * gas/arm/thumbv6.d: CPY no longer appears in disassembly. * gas/arm/r15-bad.s: Avoid two-argument mul. * gas/arm/req.s: Adjust comments. * gas/arm/maverick.d, gas/arm/maverick.s: Avoid inappropriate use of PC. * gas/arm/macro-1.d, gas/arm/macro1.s * gas/arm/t16-bad.l, gas/arm/t16-bad.s * gas/arm/tcompat.d, gas/arm/tcompat.s * gas/arm/tcompat2.d, gas/arm/tcompat2.s * gas/arm/thumb32.d, gas/arm/thumb32.s New test pair. ld/testsuite: * ld-arm/mixed-app.d: Adjust expected disassembly a little.
2005-05-17binutils/Daniel Jacobowitz3-2/+9
* doc/Makefile.am (config.texi): Don't use $<. * doc/Makefile.in: Regenerated. ld/ * Makefile.am (ldver.texi): Don't use $<. * Makefile.in: Regenerated. gas/ * doc/Makefile.am (gasver.texi): Don't use $<. * doc/Makefile.in: Regenerated.
2005-05-17 * Makefile.am (AM_MAKEINFOFLAGS, TEXI2DVI): Explicitly includeDaniel Jacobowitz3-4/+10
$(srcdir) before $(BFDDIR)/doc. * Makefile.in: Regenerated.
2005-05-17bfd/H.J. Lu10-89/+431
2005-05-17 H.J. Lu <hongjiu.lu@intel.com> PR 797 * elf32-i386.c (elf_i386_size_dynamic_sections): Also remove empty sdynbss section. * elf64-x86-64.c (elf64_x86_64_size_dynamic_sections): Likewise. ld/ 2005-05-17 H.J. Lu <hongjiu.lu@intel.com> PR 797 * ldexp.c (exp_fold_tree_1): Renamed from exp_fold_tree and take take a bfd_boolean, mark_used. Ignore assert failure if mark_used is TRUE. (exp_fold_tree) Call exp_fold_tree_1 with mark_used == FALSE. (exp_fold_tree_no_dot): Updated to take a bfd_boolean, mark_used and pass down. (fold_unary): Likewise. (fold_binary): Likewise. (fold_trinary): Likewise. (exp_binop): Add FALSE to call to exp_fold_tree_no_dot. (exp_trinop): Likewise. (exp_unop): Likewise. (exp_nameop): Likewise. (exp_get_vma): Likewise. (exp_get_fill): Likewise. (exp_get_abs_int): Likewise. (fold_name): Likewise. Set SEC_KEEP in output section flags. (exp_mark_used_section): New. * ldexp.h (exp_mark_used_section): New. * ldlang.c (lang_output_section_statement_lookup_1): Set the ignored field to FALSE. (lang_mark_used_section_1): New. (lang_mark_used_section): Call lang_mark_used_section_1. (strip_excluded_output_sections): Call lang_mark_used_section and check for unused sections. (lang_size_sections_1): Skip an output section if it should be ignored. (lang_do_assignments_1): Likewise. (lang_process): Don't call lang_mark_used_section here. * ldlang.h (lang_output_section_statement_type): Change all_input_readonly to bitfield. Add ignored. ld/testsuite/ 2005-05-17 H.J. Lu <hongjiu.lu@intel.com> PR 797 * empty-aligned.d: New file. * empty-aligned.exp: Likewise. * empty-aligned.s: Likewise. * empty-aligned.t: Likewise.
2005-05-17(GENERATE_PIE_SCRIPT): Define as "yes".Nick Clifton3-0/+8
2005-05-17ldlang.c (print_assignment): Do not rely upon a valid result having a sectionNick Clifton2-2/+13
associated with it. elf32-arm.c (elf32_arm_final_link_relocate): Gracefully handle the situation where a symbols's section is not known but a section relative R_ARM_RELATIVE reloc has to be generated for the Symbian OS.
2005-05-17* ldlang.c (Scan_for_self_assignment): Check an assignment tree toNick Clifton3-9/+119
see if the same value is being used on the rhs as on the lhs. (print_assignment): Call scan_for_self_assignment and if it returns true, do no display the result of the computation but instead just the final value of the symbol on the lhs. * ld.texinfo: Document this behaviour and provide an example of when it will happen.
2005-05-15./Daniel Jacobowitz8-3977/+10179
* ylwrap: Import from Automake 1.9.5. binutils/ * acinclude.m4: Remove obsolete code. * configure.in: Update AC_PREREQ. * doc/Makefile.am (binutils_TEXINFOS): Define. (config.texi): Depend on distributed files instead of built files. (binutils.dvi, binutils.info): Remove unnecessary rules. (DISTCLEANFILES): Remove. (install-data-local): Renamed from install. (info-local): Renamed from info. * Makefile.in, aclocal.m4, config.in, configure, doc/Makefile.in: Regenerated. gas/ * Makefile.am (m68k-parse.c, itbl-parse.c): Update ylwrap invocation. * Makefile.in: Regenerated. ld/ * Makefile.am (AM_MAKEINFOFLAGS): Define. (TEXI2DVI): Define. (ldver.texi): Depend on distributed files instead of built files. (ld.info): Include $(srcdir) in the rule target. Remove actions. (ld.dvi): Remove actions. (MAINTAINERCLEANFILES): Add configdoc.texi. (CONFIG_STATUS_DEPENDENCIES): Add bfd/configure.in. (install-data-local): Renamed from install. (Makefile): Remove explicit dependency. * acinclude.m4: Remove obsolete code. * configure.in: Update AC_PREREQ. Remove extra $CONFIG_SHELL. * Makefile.in, aclocal.m4, config.in, configure: Regenerated. gdb/ * Makefile.in (.y.c): Update ylwrap invocation.
2005-05-12Update FSF addressesNick Clifton133-157/+157
2005-05-12 * scripttempl/elfxtensa.sc: Sync up with elf.sc.Bob Wilson3-31/+73
* emulparams/elf32xtensa.sh (PLT, GOT): Define.
2005-05-11 * ld-undefined/undefined.exp: xfail xtensa-*-*.Bob Wilson2-0/+6
2005-05-11 * ldgram.y: Add SPECIAL token.Alan Modra7-13/+135
(sect_constraint): Handle SPECIAL. * ldlang.c (lang_output_section_find_1): Don't match SPECIAL. (map_input_to_output_sections): Likewise. * ldlex.l (SPECIAL): Define. * emulparams/elf32ppc.sh (DATA_GOT, SDATA_GOT, SEPARATE_GOTPLT, GOT, PLT, GOTPLT): Define. * emultempl/ppc32elf.em (old_plt, old_got): New static vars. (ppc_after_open): New function. (PARSE_AND_LIST_PROLOGUE): Define OPTION_OLD_LPT and OPTION_OLD_GOT. (PARSE_AND_LIST_LONGOPTS): Add "bss-plt" and "sdata-got". (PARSE_AND_LIST_OPTIONS): Document them. (PARSE_AND_LIST_ARGS_CASES): Handle them. (LDEMUL_AFTER_OPEN): Define. * scripttempl/elf.sc (PLT): Don't override existing define. (DATA_GOT, SDATA_GOT): Define and use to enable alternate got placement rather than using NO_SMALL_DATA. Emit GOTPLT for RELRO_NOW.
2005-05-10 * scripttempl/elf.sc (DATA_SEGMENT_RELRO_GOTPLT_END): Delete.Alan Modra2-9/+10
(DATA_SEGMENT_RELRO_END): Use SEPARATE_GOTPLT value. (GOTPLT): Remove DATA_SEGMENT_RELRO_GOTPLT_END. Place after DATA_SEGMENT_RELRO_END in script.
2005-05-102005-05-09 H.J. Lu <hongjiu.lu@intel.com>H.J. Lu2-0/+7
* emultempl/elf32.em (gld${EMULATION_NAME}_provide_bound_symbols): Don't use a removed section.
2005-05-102005-05-09 H.J. Lu <hongjiu.lu@intel.com>H.J. Lu2-1/+8
* ldmain.c (reloc_overflow): Use output_bfd if the symbol is defined in the ABS section.
2005-05-07bfd/Alan Modra7-31/+42
* elf-bfd.h (struct elf_backend_data): Remove got_symbol_offset. * elfxx-target.h (elf_backend_got_symbol_offset): Delete. * elflink.c (_bfd_elf_create_got_section): Use zero in place of got_symbol_offset. * elf-m10300.c (_bfd_mn10300_elf_create_got_section): Likewise. * elf32-frv.c (_frv_create_got_section): Likewise. * elf32-i370.c (i370_elf_finish_dynamic_sections): Delete ppc code. (elf_backend_got_symbol_offset): Don't define. * elf64-ppc.c (elf_backend_got_symbol_offset): Don't define. * elf32-ppc.c (struct ppc_elf_link_hash_table): Add got_header_size and got_gap. (ppc_elf_create_got): Tidy. (ppc_elf_create_dynamic_sections): Don't set SEC_IN_MEMORY for .plt. (ppc_elf_check_relocs): Reduce string comparisons by using elf.hgot. (ppc_elf_gc_sweep_hook): Likewise. (ppc_elf_relocate_section): Likewise. (ppc_elf_finish_dynamic_symbol): Likewise. (allocate_got): New function. (allocate_dynrelocs): Use allocate_got. (ppc_elf_size_dynamic_sections): Likewise. Delay tlsld_got allocation so that local got can refcount it. Set got_header_size. (ppc_elf_relocate_section): Use value of elf.hgot rather than hard- coded 4. (ppc_elf_finish_dynamic_sections): Likewise. (elf_backend_got_symbol_offset): Don't define. (elf_backend_got_header_size): Ditto. ld/testsuite/ * ld-powerpc/tlsexe32.d: Update for changed got layout. * ld-powerpc/tlsexe32.g: Likewise. * ld-powerpc/tlsexe32.r: Likewise. * ld-powerpc/tlsso32.d: Likewise. * ld-powerpc/tlsso32.g: Likewise. * ld-powerpc/tlsso32.r: Likewise.
2005-05-072005-05-06 H.J. Lu <hongjiu.lu@intel.com>H.J. Lu2-1/+6
* emultempl/elf32.em (gld${EMULATION_NAME}_provide_init_fini_syms): Put back !link_info.relocatable.
2005-05-06Mention PR.H.J. Lu1-0/+1
2005-05-062005-05-06 H.J. Lu <hongjiu.lu@intel.com>H.J. Lu2-1/+6
* emultempl/elf32.em (gld${EMULATION_NAME}_provide_init_fini_syms): Just check link_info.executable.
2005-05-06Update the address and phone number of the FSF organization in the GPL noticesNick Clifton2-44/+98
2005-05-05bfd/H.J. Lu2-0/+6
2005-05-05 H.J. Lu <hongjiu.lu@intel.com> * elflink.c (_bfd_elf_provide_section_bound_symbols): Use "__bss_start" instead of "_edata" as fallback. ld/ 2005-05-05 H.J. Lu <hongjiu.lu@intel.com> * scripttempl/elf.sc: Document the usage of __bss_start.
2005-05-052005-05-05 Paul Brook <paul@codesourcery.com>Paul Brook7-8/+70
bfd/ * config.bfd: Use bfd_elf32_i386_vxworks_vec for i?86-*-vxworks. * configure.in: Add bfd_elf32_i386_vxworks_vec. i386 targets need elf-vxworks.lo. * configure: Regenerate. * Makefile.am (BFD32_BACKENDS): Add elf-vxworks.lo. (BFD32_BACKENDS_CFILES): Add elf-vxworks.c. (elf32-i386.lo): Depend on elf-vxworks.h. (elf-vxworks.lo): New rule. * Makefile.in: Regenerate. * elf-bfd.h (elf_backend_data): Update type of elf_backend_emit_relocs. (_bfd_elf_link_output_relocs): Update prototype. * elflink.c (_bfd_elf_link_output_relocs): Always use bed->elf_backend_emit_relocs when outputting relocations. * elfxx-target.h (elf_backend_emit_relocs): Default to _bfd_elf_link_output_relocs. * targets.c (bfd_elf32_i386_vxworks_vec): Declare. (_bfd_target_vector): Add bfd_elf32_i386_vxworks_vec. * elf32-i386.c: Add elf32-i386-vxworks target BFD. (elf_i386_plt0_entry): Remove padding. (elf_i386_pic_plt0_entry): Ditto. (PLTRESOLVE_RELOCS_SHLIB, PLTRESOLVE_RELOCS): Define. (PLT_NON_JUMP_SLOT_RELOCS): Define. (elf_i386_link_hash_table): Add srelplt2, hgot, hplt, is_vxworks and plt0_pad_byte fields. (elf_i386_link_hash_table_create): Zero them. (elf_i386_create_dynamic_sections): Create static relocation section. (allocate_dynrelocs): Allocate space for static PLT relocations. (elf_i386_size_dynamic_sections): Save shortcuts to PLT and GOT symbols. Give PLT symbols function type. Don't strip PLT sections if we have exported symbols from them. (elf_i386_finish_dynamic_symbol): Fill in VxWorks PLT static relocation section. Don't mark _GLOBAL_OFFSET_TABLE_ as absolute on VxWorks. (elf_i386_finish_dynamic_sections): Allow different pad bytes. Add relocation for GOT location. Fill in PLT static relocations. (elf_i386_vxworks_link_hash_table_create): New function. (elf_i386_vxworks_link_output_symbol_hook): New function. * elf-vxworks.h: New file. gas/ * config/tc-i386.h (ELF_TARGET_FORMAT): Define for TE_VXWORKS. gas/testsuite/ * gas/i386/i386.exp: Don't run divide test on vxworks. ld/ * Makefile.am: Add eelf_i386_vxworks. * Makefile.in: Regenerate. * configure.tgt: Make i?86-*-vxworks use targ_emul=elf_i386_vxworks. * emulparams/elf_i386_vxworks.sh: New file. * emulparams/vxworks.sh: New file. * scripttempl/elf.sc: Add DATA_END_SYMBOLS and ETEXT_NAME.
2005-05-05Replace linux-gnu with linux-* to allow for versions of Linux which do not useNick Clifton3-6/+12
glibc.
2005-05-052005-05-05 Paul Brook <paul@codesourcery.com>Paul Brook6-0/+33
gas/testsuite/ * lib/gas-defs.exp (regexp_diff): Pass test if last line is "#...". ld/testsuite/ * lib/ld-lib.exp (regexp_diff): Pass test if last line is "#...". * ld-elfweak/elfweak.exp: Run size2.d. * ld-elfwaek/size2.d: New file. * ld-elfwaek/size2a.s: New file. * ld-elfwaek/size2b.s: New file.
2005-05-04bfd/H.J. Lu2-29/+7
2005-05-04 H.J. Lu <hongjiu.lu@intel.com> * bfd-in.h (_bfd_elf_provide_section_bound_symbols): New. * bfd-in2.h: Regenerated. * elflink.c (bfd_elf_set_symbol): New. (_bfd_elf_provide_symbol): Call it. (_bfd_elf_provide_section_bound_symbols): New. ld/ 2005-05-04 H.J. Lu <hongjiu.lu@intel.com> * emultempl/elf32.em (gld${EMULATION_NAME}_provide_bound_symbols): Call _bfd_elf_provide_section_bound_symbols.
2005-05-04bfd/Alan Modra14-25/+99
* section.c (struct bfd_section): Replace link_order_head and link_order_tail with map_head and map_tail union. (STD_SECTION): Update. (_bfd_strip_section_from_output): Delete. * aoutx.h: Update throughout for above changes. * coff-ppc.c: Likewise. * cofflink.c: Likewise. * ecoff.c: Likewise. * elf-eh-frame.c: Likewise. * elf-m10300.c: Likewise. * elf.c: Likewise. * elf32-arm.c: Likewise. * elf32-cris.c: Likewise. * elf32-hppa.c: Likewise. * elf32-i386.c: Likewise. * elf32-m32r.c: Likewise. * elf32-m68hc1x.c: Likewise. * elf32-m68k.c: Likewise. * elf32-ppc.c: Likewise. * elf32-s390.c: Likewise. * elf32-sh.c: Likewise. * elf32-vax.c: Likewise. * elf32-xtensa.c: Likewise. * elf64-alpha.c: Likewise. * elf64-hppa.c: Likewise. * elf64-ppc.c: Likewise. * elf64-s390.c: Likewise. * elf64-sh64.c: Likewise. * elf64-x86-64.c: Likewise. * elflink.c: Likewise. * elfxx-ia64.c: Likewise. * elfxx-mips.c: Likewise. * elfxx-sparc.c: Likewise. * linker.c: Likewise. * merge.c: Likewise. * pdp11.c: Likewise. * xcofflink.c: Likewise. * elflink.c (bfd_boolean bfd_elf_size_dynsym_hash_dynstr): Split out from bfd_elf_size_dynamic_sections. * bfd-in.h (bfd_boolean bfd_elf_size_dynsym_hash_dynstr): Declare. * bfd-in2.h: Regenerate. ld/ * ldemul.c: Include bfdlink.h. (ldemul_before_allocation): Assume before_allocation is non-zero. (before_allocation_default): Call strip_excluded_output_sections. * ldlang.c (stripped_excluded_sections): New variable. (lang_add_section): Build input section list for each output section, attached via map_head and map_tail pointers. (strip_excluded_output_sections): Make global. Traverse the input section lists to find which output sections can go. Clear link_order pointers and set stripped_excluded_sections. (lang_process): Call strip_excluded_output_sections. * ldlang.h (strip_excluded_output_sections): Declare. * ldwrite.c: Update throuhout for link_order_head -> map_head change. * emultempl/aix.em (before_allocation): Call strip_excluded_output_sections. * emultempl/armcoff.em (before_allocation): Likewise. * emultempl/beos.em (before_allocation): Likewise. * emultempl/linux.em (before_allocation): Likewise. * emultempl/pe.em (before_allocation): Likewise. * emultempl/sunos.em (before_allocation): Likewise. * emultempl/elf32.em (before_allocation): Likewise. Call bfd_elf_size_dynsym_hash_dynstr too. * emultempl/lnk960.em (lnk960_before_allocation): Delete. (ld_lnk960): Use before_allocation_default.
2005-05-03bfd/H.J. Lu3-63/+91
2005-05-02 H.J. Lu <hongjiu.lu@intel.com> * bfd.c (bfd): Remove section_tail and add section_last. (bfd_preserve): Likewise. (bfd_preserve_save): Likewise. (bfd_preserve_restore): Likewise. * opncls.c (_bfd_new_bfd): Likewise. * coffcode.h (coff_compute_section_file_positions): Updated. (coff_compute_section_file_positions): Likewise. * elf.c (assign_section_numbers): Likewise. * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise. * elf64-mmix.c (mmix_elf_final_link): Likewise. * elfxx-ia64.c (elfNN_ia64_object_p): Likewise. * elfxx-mips.c (_bfd_mips_elf_link_hash_table_create): Likewise. * sunos.c (sunos_add_dynamic_symbols): Likewise. * xcofflink.c (_bfd_xcoff_bfd_final_link): Likewise. * ecoff.c (bfd_debug_section): Initialize prev. * section.c (bfd_section): Add prev. (bfd_section_list_remove): Updated. (bfd_section_list_append): New. (bfd_section_list_insert_after): New. (bfd_section_list_insert_before): New. (bfd_section_list_insert): Removed. (bfd_section_removed_from_list): Updated. (STD_SECTION): Initialize prev. (bfd_section_init): Updated. (bfd_section_list_clear): Updated. * bfd-in2.h: Regenerated. gas/ 2005-05-02 H.J. Lu <hongjiu.lu@intel.com> * write.c (write_object_file): Use bfd_section_double_list_remove to remove sections. ld/ 2005-05-02 H.J. Lu <hongjiu.lu@intel.com> * emultempl/elf32.em (gld${EMULATION_NAME}_strip_empty_section): Updated for bfd_section_list_remove change. * ldlang.c (lang_insert_orphan): Likewise. (strip_excluded_output_sections): Likewise. (sort_sections_by_lma): New. (lang_check_section_addresses): Sort the sections before checking addresses.
2005-04-29 * configure.tgt: Add h8300*-*-rtemscoff.Daniel Jacobowitz2-2/+7
Switch h8300*-*-rtems* to elf.
2005-04-28 * ldgram.y (lang_memory_region_type): Make static.Ben Elliston9-23/+30
(ldgram_want_filename): Likewise. * ldemul.c (ld_emulation): Make static. * ldfile.h (ldfile_find_command_file): Remove extern. * ldfile.c (ldfile_find_command_file): Make static. * ldlang.h (unique_section_list): Remove extern declaration. * ldlang.c (unique_section_list): Make static. * mri.h (symbol_truncate): Remove extern declaration. * mri.c (symbol_truncate): Make static. (order, only_load, address, alias): Likewise. (alignment, subalignment): Likewise.