aboutsummaryrefslogtreecommitdiff
path: root/ld
AgeCommit message (Collapse)AuthorFilesLines
2006-10-24 * ld-powerpc/plt1.s: New.Alan Modra5-1/+117
* ld-powerpc/plt1.d: New. * ld-powerpc/relbrlt.s: New. * ld-powerpc/relbrlt.d: New. * ld-powerpc/powerpc.exp: Run them.
2006-10-24 * lexsup.c (parse_args): Add a comment noting a fall-through.Ben Elliston2-0/+6
2006-10-232006-10-24 H.J. Lu <hongjiu.lu@intel.com>H.J. Lu4-2/+16
* configure.in (AC_CHECK_HEADERS): Add limits.h and sys/param.h. * configure: Regenerated. * config.in: Likewise.
2006-10-23 * emulparams/h8300elf.sh (TINY_DATA_SECTION, TINY_BSS_SECTION): Don'tAlan Modra2-12/+15
set section address on a relocatable link.
2006-10-23 * ld.texinfo (Output Section Discarding): Fix xref.Alan Modra2-3/+7
2006-10-23missed from 2006-10-19 commit.Alan Modra1-3/+3
2006-10-22 * gas/sh/sh64/syntax-1.d: Update.Kaz Kojima19-732/+679
* ld-sh/sh64/abi32.xd, ld-sh/sh64/abi64.xd, ld-sh/sh64/cmpct1.xd, * ld-sh/sh64/crange1.rd, ld-sh/sh64/crange2.rd, * ld-sh/sh64/crange3-cmpct.rd, ld-sh/sh64/crange3-media.rd, * ld-sh/sh64/crange3.rd, ld-sh/sh64/crangerel1.rd, * ld-sh/sh64/crangerel2.rd, ld-sh/sh64/mix1.xd, * ld-sh/sh64/mix2.xd, ld-sh/sh64/rel32.xd, ld-sh/sh64/rel64.xd, * ld-sh/sh64/reldl32.rd, ld-sh/sh64/reldl64.rd, * ld-sh/sh64/shdl32.xd, ld-sh/sh64/shdl64.xd: Update.
2006-10-22 * emulparams/shelf32.sh: Set default stack to 0x80000.Kaz Kojima3-2/+7
* emulparams/shelf64.sh: Likewise.
2006-10-20 * ld-sh/tlsbin-1.d: Update.Kaz Kojima4-51/+57
* ld-sh/tlspic-1.d: Likewise. * ld-sh/tlstpoff-1.d: Likewise.
2006-10-20bfd/Richard Sandiford4-35/+8
* elfxx-mips.c (_bfd_mips_elf_finish_dynamic_sections): Make the size of .rel.dyn reflect the value of DT_RELSZ. ld/testsuite/ * ld-mips-elf/multi-got-1.d: Remove trailing R_MIPS_NONE entries. * ld-mips-elf/tls-multi-got-1.got: Likewise. * ld-mips-elf/tls-multi-got-1.r: Likewise.
2006-10-20bfd/Richard Sandiford18-69/+95
* elfxx-mips.c (_bfd_mips_elf_additional_program_headers): Allocate a PT_NULL header for dynamic objects. (_bfd_mips_elf_modify_segment_map): Add it. ld/testsuite/ * ld-mips-elf/multi-got-1.d: Do not expect a particular address for DT_HASH. * ld-mips-elf/rel32-o32.d: Bump addresses by 0x20 to account for the extra program header. * ld-mips-elf/rel32-n32.d: Likewise. * ld-mips-elf/tlslib-o32.got: Likewise. * ld-mips-elf/tlslib-o32-hidden.got: Likewise. * ld-mips-elf/tlslib-o32-ver.got: Likewise. * ld-mips-elf/tls-multi-got-1.got: Likewise. * ld-mips-elf/tls-multi-got-1.r: Likewise. * ld-mips-elf/rel64.d: Bump addresses by 0x30 to account for the extra program header. * ld-mips-elf/tlsdyn-o32.d: Reduce the GOT offset by 32 to account for the extra program header, and thus the shorter gap between the text and data segments. * ld-mips-elf/tlsdyn-o32-1.d: Likewise. * ld-mips-elf/tlsdyn-o32-2.d: Likewise. * ld-mips-elf/tlsdyn-o32-3.d: Likewise. * ld-mips-elf/tlsdyn-o32.got: Bump GOT text addresses by 0x20 to account for the extra program header. * ld-mips-elf/tlsdyn-o32-1.got: Likewise. * ld-mips-elf/tlsdyn-o32-2.got: Likewise. * ld-mips-elf/tlsdyn-o32-3.got: Likewise.
2006-10-20ld/Richard Sandiford7-3/+30
* emulparams/elf32bmip.sh (OTHER_GOT_RELOC_SECTIONS): Define. * emulparams/elf32bmipn32-defs.sh (OTHER_GOT_RELOC_SECTIONS): Likewise. ld/testsuite/ * ld-mips-elf/rel32-o32.d: Bump the section number of .text by 1 to account for the fact that .rel.dyn is now before .text in the section table. * ld-mips-elf/rel32-n32.d: Likewise. * ld-mips-elf/rel64.d: Likewise.
2006-10-19Fix score bugsNick Clifton1-3/+3
2006-10-19bfd/Richard Sandiford5-13/+21
* elfxx-mips.c (sort_dynamic_relocs): Sort relocations against the same symbol by increasing r_offset. (sort_dynamic_relocs_64): Likewise. Fix comparisons between very large and very small symbol indexes. ld/testsuite/ * ld-mips-elf/tlslib-o32-hidden.got: Sort relocations against the same symbol in order of increasing r_offset. * ld-mips-elf/tls-multi-got-1.got: Likewise. * ld-mips-elf/tls-hidden3.r: Likewise. * ld-mips-elf/tls-hidden4.r: Likewise.
2006-10-19bfd/Richard Sandiford8-44/+55
* elfxx-mips.c (_bfd_mips_elf_size_dynamic_sections): Add DT_DEBUG and DT_MIPS_RLD_MAP tags for position-independent executables. Do not add DT_DEBUG to shared libraries for any MIPS target. ld/testsuite/ * ld-mips-elf/multi-got-1.d: Remove DT_DEBUG tag. Do not require a specific file offset for .dynamic. Reduce DT_HASH by 8 to account for removed tag. * ld-mips-elf/tls-multi-got-1.r: Likewise. Also reduce DT_REL by 8. Reduce PLTGOT and symbol values by 16 to account for the removed tag. * ld-mips-elf/textrel-1.d: Remove DT_DEBUG tag. * ld-mips-elf/rel32-n32.d: Reduce addresses by 16 to account for removed DT_DEBUG tag. * ld-mips-elf/rel64.d: Likewise. * ld-mips-elf/tls-multi-got-1.got: Likewise. * ld-mips-elf/tlslib-o32-hidden.got: Likewise.
2006-10-19bfd/H.J. Lu7-0/+149
2006-10-18 H.J. Lu <hongjiu.lu@intel.com> PR ld/3290 * elflink.c (elf_link_add_object_symbols): Hide definitions in debug sections. ld/testsuite/ 2006-10-18 H.J. Lu <hongjiu.lu@intel.com> PR ld/3290 * ld-elf/dummy.c: New file. * ld-elf/dwarf.exp: Likewise. * ld-elf/dwarf1.c: Likewise. * ld-elf/dwarf1.h: Likewise. * ld-elf/dwarf1.out: Likewise. * ld-elf/dwarf1main.c: Likewise.
2006-10-19bfd/Alan Modra2-13/+14
* elf32-arm.c (bfd_elf32_arm_allocate_interworking_sect): Check, don't set, glue section size. (record_arm_to_thumb_glue): Set glue section size here. (record_thumb_to_arm_glue): Likewise. (bfd_elf32_arm_add_glue_sections_to_bfd): Formatting. (bfd_elf32_arm_process_before_allocation): Ignore exluded sections. ld/ * emultempl/armelf.em (arm_elf_before_allocation): Run gld${EMULATION_NAME}_before_allocation later. * ldlang.c (lang_size_sections_1): Revert 2006-09-15 change.
2006-10-182006-10-18 Roy Marples <uberlord@gentoo.org>Mike Frysinger2-0/+6
* bfd/elf64-sparc.c: Add FreeBSD support. (elf64_sparc_fbsd_post_process_headers): New function. * bfd/targets.c (_bfd_target_vector): Add bfd_elf64_sparc_freebsd_vec. * bfd/config.bfd (sparc64-*-freebsd*): Set targ_defvec to bfd_elf64_sparc_freebsd_vec. * bfd/configure.in: Add entry for bfd_elf64_sparc_freebsd_vec. * bfd/configure: Regenerate. * gas/config/tc-sparc.c (md_parse_option): Treat any target starting with elf32-sparc as a viable target for the -32 switch and any target starting with elf64-sparc as a viable target for the -64 switch. (sparc_target_format): For 64-bit ELF flavoured output use ELF_TARGET_FORMAT64 while for 32-bit ELF flavoured output use ELF_TARGET_FORMAT. * gas/config/tc-sparc.h (ELF_TARGET_FORMAT, ELF_TARGET_FORMAT64): Define. * ld/emulparams/elf64_sparc_fbsd.sh (OUTPUT_FORMAT): Define as elf64-sparc-freebsd.
2006-10-18 * configure.tgt (i[3-7]86-*-linux-*): Also defineJoseph Myers3-1/+9
targ_extra_libpath in want64 case. * emulparams/elf_x86_64.sh: Handle i[3-7]86-*-linux-* the same as x86_64*-linux*.
2006-10-182006-10-18 H.J. Lu <hongjiu.lu@intel.com>H.J. Lu9-0/+117
* ld-elf/dl4.c: New file. * ld-elf/dl4.list: Likewise. * ld-elf/dl4a.out: Likewise. * ld-elf/dl4b.out: Likewise. * ld-elf/dl4main.c: Likewise. * ld-elf/dl4xxx.c: Likewise. * ld-elf/dl4xxx.list: Likewise. * ld-elf/shared.exp (build_tests): Add libdl4a.so and libdl4b.so. (run_tests): Likewise.
2006-10-18ld/testsuite/Richard Sandiford2-35/+39
* ld-mips-elf/reloc-1-n64.d: Match 16-character VMAs on LP64 hosts.
2006-10-18Fix typo in last changelog.Richard Sandiford1-1/+1
2006-10-18ld/testsuite/Richard Sandiford2-3/+9
* ld-mips-elf/rel32-n32.d: Bump addresses by 0x30 to account for the fact that .reginfo is now placed before .text. Change the section number of .text accordingly.
2006-10-18ld/testsuite/Richard Sandiford5-668/+681
* ld-mips-elf/elf-rel-got-n32.d: Adjust page gap from 0x100000 to 0x10000. Move .reginfo before .text and bump .text addresses by 0x10 to make room. Move data segment down by 0x10 bytes to account for new size of text segment. * ld-mips-elf/elf-rel-xgot-n32.d: Likewise. * ld-mips-elf/elf-rel-got-n64-linux.d: Adjust page gap from 0x100000 to 0x10000. * ld-mips-elf/elf-rel-xgot-n64-linux.d: Likewise.
2006-10-17 bfd/Mark Shinwell10-0/+140
* elf32-arm.c (elf32_arm_howto_table_1): Change offset for R_THM_CALL to 25 and remove FIXME comment. (using_thumb2): New function. (elf32_arm_final_link_relocate): Cope with Thumb-2 BL encoding. include/ * elf/arm.h: Define TAG_CPU_ARCH_* constants. ld/testsuite/ * ld-arm/arm-elf.exp: Add thumb1-bl, thumb2-bl, thumb2-bl-as-thumb1-bad and thumb2-bl-bad tests. * ld-arm/thumb1-bl.d: New. * ld-arm/thumb1-bl.s: New. * ld-arm/thumb2-bl-as-thumb1-bad.d: New. * ld-arm/thumb2-bl-as-thumb1-bad.s: New. * ld-arm/thumb2-bl-bad.d: New. * ld-arm/thumb2-bl-bad.s: New. * ld-arm/thumb2-bl.d: New. * ld-arm/thumb2-bl.s: New.
2006-10-17 * scripttempl/elf.sc (INTERP): Delete. Move definition to..Alan Modra5-5/+28
(INITIAL_READONLY_SECTIONS): ..here. * emulparams/criself.sh (INITIAL_READONLY_SECTIONS): Include .interp. * emulparams/elf32bmip.sh (INITIAL_READONLY_SECTIONS): Ditto. * emulparams/elf32bmipn32-defs.sh (INITIAL_READONLY_SECTIONS): Ditto.
2006-10-17bfd/Alan Modra62-393/+382
* elf-bfd.h (struct elf_link_hash_table): Reorder. Add text_index_section and data_index_section. (struct elf_backend_data): Add elf_backend_init_index_section. (_bfd_elf_init_1_index_section): Declare. (_bfd_elf_init_2_index_sections): Declare. * elfxx-target.h (elf_backend_init_index_section): Define. (elfNN_bed): Init new field. * elflink.c (_bfd_elf_link_omit_section_dynsym): Keep first tls section and text_index_section plus data_index_section. (_bfd_elf_link_renumber_dynsyms): Clear dynindx on omitted sections. (_bfd_elf_init_1_index_section): New function. (_bfd_elf_init_2_index_sections): New function. (bfd_elf_size_dynsym_hash_dynstr): Call elf_backend_init_index_section. (elf_link_input_bfd): When emitting relocs, use text_index_section and data_index_section for removed sections. * elf-m10300.c (elf_backend_omit_section_dynsym): Define. * elf32-i386.c: Likewise. * elf32-m32r.c: Likewise. * elf32-sh.c: Likewise. * elf32-xstormy16.c: Likewise. * elf32-xtensa.c: Likewise. * elf64-alpha.c: Likewise. * elf64-hppa.c: Likewise. * elf64-mmix.c: Likewise. * elf64-sh64.c: Likewise. * elfxx-ia64.c: Likewise. * elf32-arm.c (elf32_arm_final_link_relocate): Use text_index_section and data_index_section sym for relocs against sections with no dynamic section sym. (elf_backend_init_index_section): Define. * elf32-cris.c: Similarly. * elf32-hppa.c: Similarly. * elf32-i370.c: Similarly. * elf32-m68k.c: Similarly. * elf32-mips.c: Similarly. * elf32-ppc.c: Similarly. * elf32-s390.c: Similarly. * elf32-sparc.c: Similarly. * elf32-vax.c: Similarly. * elf64-mips.c: Similarly. * elf64-ppc.c: Similarly. * elf64-s390.c: Similarly. * elf64-sparc.c: Similarly. * elf64-x86-64.c: Similarly. * elfn32-mips.c: Similarly. * elfxx-mips.c: Similarly. * elfxx-sparc.c: Similarly. * linker.c (fix_syms): Base symbols in removed sections on previous section in preference to using absolute section. ld/ * ldlang.c (strip_excluded_output_sections): Do strip sections that define syms, but don't ignore them. * ld.texinfo (Output Section Discarding): Revise. * emultempl/armcoff.em (gld${EMULATION_NAME}_finish): Always call finish_default. ld/testsuite/ Update for section sym changes.
2006-10-16ld/Richard Sandiford14-40/+67
* Makefile.am (eelf64bmip.c): Depend on emulparams/elf64bmip-defs.sh. (eelf64btsmip.c, eelf64ltsmip.c): Likewise. * Makefile.in: Regenerate. * emulparams/elf32bmipn32-defs.sh (INITIAL_READONLY_SECTIONS): Include .reginfo rather than .MIPS.options. * emulparams/elf64bmip-defs.sh: New file. * emulparams/elf64bmip.sh: Include it. (COMMONPAGESIZE): Delete. * emulparams/elf64btsmip.sh: As for elf64bmip.sh. ld/testsuite/ * ld-mips-elf/branch-misc-1.d: Set the start address to 0x20000000. * ld-mips-elf/jalbal.d: Likewise 0x200000a0. * ld-mips-elf/jaloverflow-2.d: Likewise 0x20000000. * ld-mips-elf/reloc-3-n32.d: Likewise. * ld-mips-elf/reloc-3.d: Likewise. * ld-mips-elf/textrel-1.d: Don't require a specific file offset for .dynamic.
2006-10-12bfd/Bob Wilson2-7/+17
* elf32-xtensa.c (elf_xtensa_action_discarded): New. (elf_backend_action_discarded): Define. ld/ * emultempl/xtensaelf.em (is_inconsistent_linkonce_section): Check for linkonce XCC exception tables (".e" and ".h").
2006-10-11 * emulparams/elf32xtensa.sh (TEXT_PLT): Enable.Bob Wilson3-28/+98
(OTHER_READONLY_SECTIONS): Add linkonce .xt_except_table sections. (OTHER_READWRITE_SECTIONS): Add linkonce .xt_except_desc sections. (OTHER_SDATA_SECTIONS): New. * scripttempl/elfxtensa.sc: Import changes from elf.sc.
2006-10-11 * ldlang.c (lang_append_dynamic_list): When appending, add all elementsJakub Jelinek2-1/+9
of the dynamic list rather than just the first entry.
2006-10-10bfd/Bob Wilson2-0/+5
* elf32-xtensa.c (elf_xtensa_size_dynamic_sections): Add DT_DEBUG for PIE executables. ld/ * emulparams/elf32xtensa.sh (GENERATE_PIE_SCRIPT): Enable.
2006-10-06* genscripts.sh: Respect LIBPATH_SUFFIX when not using sysroot.Mike Frysinger2-0/+12
2006-10-05 * emulparams/xtensa-config.sh: Delete file.Bob Wilson5-11/+11
* emulparams/elf32xtensa.sh: Set MAXPAGESIZE here instead of including xtensa-config.sh. * Makefile.am (eelf32xtensa.c): Remove dependency on xtensa-config.sh. * Makefile.in: Regenerate.
2006-10-03 * elf-bfd.h (struct eh_cie_fde): Add set_loc pointer.Jakub Jelinek4-0/+133
* elf-eh-frame.c (skip_cfa_op): Fix handling of DW_CFA_advance_loc. Handle DW_CFA_{remember,restore}_state, DW_CFA_GNU_window_save, DW_CFA_val_{offset{,_sf},expression}. (skip_non_nops): Record number of DW_CFA_set_loc ops. (_bfd_elf_discard_section_eh_frame): Require skip_non_nops recognizes all ops. If there are any DW_CFA_set_loc ops and they are pcrel or going to be pcrel, compute set_loc array. (_bfd_elf_eh_frame_section_offset): If make_relative, kill relocations against DW_CFA_set_loc operands. (_bfd_elf_write_section_eh_frame): Handle DW_CFA_set_loc adjusting. * ld-elf/eh4.d: New test. * ld-elf/eh4.s: New file. * ld-elf/eh4a.s: New file.
2006-10-03* pe-dll.c : Fix typo.Nick Clifton3-22/+50
(autofilter_symbolprefixlist) : Remove __imp_. (is_import) : New. (auto-export) : Remove re-import check. Moved to callers. (process_def_file) : Check is symbol is an import. Always underscore __imp_. Only skip underscore on underscored targets. (make_one) : Always underscore __imp_. (pe_create_runtime_relocator_reference) : Only underscore _pei386_runtime_relocator on underscored targets. (pe_process_import_defs) : Always underscore __imp_. * pe.em (U) : New macro. (set_pe_subsystem) : Remove underscore from _WinMainCRTStartup on wince subsystem case. (pe_find_data_imports) : Use U on "_head_". (gld_${EMULATION_NAME}_unrecognized_file) : Use U.
2006-10-02* ld-arm/use-thumb-lib.sym: Robustify, by ignoring symbols we'reNick Clifton2-15/+8
not interested in and bucket number.
2006-10-02* ld-fastcall/fastcall.exp: Add x86_64-pc-mingw64 as valid target.Nick Clifton4-3/+13
* ld-pe/pe.exp: Likewise. * lib/ld-lib.exp ( is_pecoff_format): Accept x86_64-pc-mingw64.
2006-09-29 * ld-sh/tlspic-2.d: Update.Kaz Kojima2-0/+5
2006-09-27bfd/H.J. Lu21-2/+201
2006-09-26 H.J. Lu <hongjiu.lu@intel.com> PR ld/3223 PR ld/3267 * elf.c (assign_file_positions_for_non_load_sections): Don't warn zero size allocated sections. ld/ 2006-09-26 H.J. Lu <hongjiu.lu@intel.com> PR ld/3223 PR ld/3267 * ld.texinfo: Updated Output Section Discarding. * ldlang.h (lang_output_section_statement_type): Add section_relative_symbol. * ldlang.c (strip_excluded_output_sections): Don't strip a section with a symbol relative to it. (lang_size_sections_1): Mark if an output section has a symbol symbol relative to it. ld/testsuite/ 2006-09-26 H.J. Lu <hongjiu.lu@intel.com> PR ld/3223 PR ld/3267 * ld-scripts/empty-address-1.d: New file. * ld-scripts/empty-address-1.s: Likewise. * ld-scripts/empty-address-1.t: Likewise. * ld-scripts/empty-address-2.s: Likewise. * ld-scripts/empty-address-2a.d: Likewise. * ld-scripts/empty-address-2a.t: Likewise. * ld-scripts/empty-address-2b.d: Likewise. * ld-scripts/empty-address-2b.t: Likewise. * ld-scripts/empty-address-3.s: Likewise. * ld-scripts/empty-address-3a.d: Likewise. * ld-scripts/empty-address-3a.t: Likewise. * ld-scripts/empty-address-3b.d: Likewise. * ld-scripts/empty-address-3b.t: Likewise. * ld-scripts/empty-address-3c.d: Likewise. * ld-scripts/empty-address-3c.t: Likewise. * ld-scripts/empty-address.exp: Likewise.
2006-09-25 * ld.texinfo (Options): Update description of local symbols for -X.Bob Wilson2-3/+7
2006-09-242006-09-23 H.J. Lu <hongjiu.lu@intel.com>H.J. Lu2-2/+9
PR ld/3249 * scripttempl/elf.sc: Don't combine .gnu.linkonce.d.*personality* and .gnu.linkonce.wi.* sections with .data and .debug_info for relocatable link.
2006-09-21 * ld-m68k/plt1-68020.d: Fix patterns to match also for 64-bitAndreas Schwab2-4/+9
hosts.
2006-09-20Add x86_64-mingw64 targetNick Clifton21-68/+2291
2006-09-18 * ld-mips-elf/mips-elf.exp: Add test for R_MIPS16_GPREL relocations.Thiemo Seufer4-0/+44
* ld-mips-elf/reloc-3-n32.d, ld-mips-elf/reloc-3.d: New files.
2006-09-18 * ld-elfcomm/elfcomm.exp: Enable the alignment test forThiemo Seufer2-7/+17
mips*-*-*.
2006-09-18 * configure.tgt: Add mips*el-sde-elf* and mips*-sde-elf*Thiemo Seufer2-0/+9
configurations.
2006-09-16Add support for Score target.Nick Clifton11-3/+145
2006-09-16* bfd-in.h (STRING_AND_COMMA): New macro. Takes one constant string as itsNick Clifton12-102/+116
argument and emits the string followed by a comma and then the length of the string. (CONST_STRNEQ): New macro. Checks to see if a variable string has a constant string as its initial characters. (CONST_STRNCPY): New macro. Copies a constant string to the start of a variable string. * bfd-in2.h: Regenerate. * <remainign files>: Make use of the new macros.
2006-09-152006-09-15 H.J. Lu <hongjiu.lu@intel.com>H.J. Lu2-0/+5
* ld-scripts/overlay-size.t: Discard .reginfo sections.