* configure.in (bfd_elf32_bigarm_symbian_vec): Add it.
(bfd_elf32_littlearm_symbian_vec): Likewise.
* configure: Regenerated.
* elf-bfd.h (elf_backend_data): Add dynamic_sec_flags.
* elf32-arm.h (PLT_HEADER_SIZE): Do not define.
(PLT_ENTRY_SIZE): Likewise.
(bfd_vma_elf32_arm_symbian_plt_entry): New
variable.
(elf32_arm_link_hash_table): Add plt_header_size, plt_entry_size,
and symbian_p.
(create_got_section): Don't create sections when generating BPABI
objects.
(elf32_arm_create_dynamic_sections): Tidy.
(elf32_arm_link_hash_table_create): Set plt_header_size,
plt_entry_size, and symbian_p.
(elf32_arm_check_relocs): Do not mark .rel.dyn as loadable when
generating BPABI objects.
(allocate_dynrelocs): Use htab->plt_header_size, not
PLT_HEADER_SIZE. Do not add to .got.plt when
generating BPABI objects.
(elf32_arm_finish_dynamic_symbol): Generate Symbian OS PLTs.
* elfarm-nabi.c: Add SymbianOS target vectors.
* elflink.c (_bfd_elf_create_got_section): Use dynamic_sec_flags.
(_bfd_elf_link_create_dynamic_sections): Likewise.
* elfxx-target.h (ELF_DYNAMIC_SEC_FLAGS): New macro.
(elfNN_bed): Use it.
* targets.c (bfd_elf32_bigarm_symbian_vec): New variable.
(bfd_elf32_littlearm_symbian_vec): Likewise.
(_bfd_target_vector): Add them.
* Makefile.am (TARG_ENV_HFILES): Add te-symbian.h.
* Makefile.in: Regenerated.
* configure.in: Set em for arm*-*-symbianelf*.
* configure: Regenerated.
* config/tc-arm.c (elf32_arm_target_format): Use Symbian target
vectors when appropriate.
* config/te-symbian.h: New file.
* Makefile.am (ALL_EMULATIONS): Add earmsymbian.o.
(earmsymbian.c): New target.
* configure.tgt: Use armsymbian emulation for arm*-*-symbianelf*.
* Makefile.in: Regenerated.
* aclocal.m4: Likewise.
* configure: Likewise.
* emulparams/armsymbian.sh: New file.
argument, don't do anything if current section is not
.gnu.linkonce.t.* and linkonce_empty is set.
(generate_unwind_image, dot_endp): Adjust callers, call
start_unwind_section (*, 1) if nothing will be put into the
section.
* config.bfd (hppa*-*-netbsd*): Set targ_defvec to
bfd_elf32_hppa_nbsd_vec. Add bfd_elf32_hppa_linux_vec
to targ_selvecs.
* configure.in (bfd_elf32_hppa_nbsd_vec): Add case.
* configure: Regenerate.
* elf32-hppa.c (elf32_hppa_object_p): Add "elf32-hppa-netbsd"
case that accepts OSABI=NetBSD and OSABI=SysV.
(elf32_hppa_set_gp): For "elf32-hppa-netbsd", set the GP to
the base of .got or .data (if .got does not exist).
(elf32_hppa_post_process_headers): For elf32-hppa-netbsd,
set OSABI=NetBSD.
(TARGET_BIG_SYM): Add bfd_elf32_hppa_nbsd_vec case.
(TARGET_BIG_NAME): Add "elf32-hppa-netbsd" case.
* targets.c (bfd_elf32_hppa_nbsd_vec): Add extern declaration.
(_bfd_target_vector): Add bfd_elf32_hppa_nbsd_vec.
gas:
* config/tc-hppa.h (TARGET_FORMAT): Set to "elf32-hppa-netbsd"
for TE_NetBSD.
ld:
* emulparams/hppanbsd.sh (OUTPUT_FORMAT): Set to "elf32-hppa-netbsd".
2004-07-26 H.J. Lu <hongjiu.lu@intel.com>
* elf-bfd.h (bfd_elf_section_data): Add a pointer for the
linked-to section.
(elf_linked_to_section): New.
* elf.c (assign_section_numbers): Set up sh_link for
SHF_LINK_ORDER.
* elfxx-ia64.c (elfNN_ia64_final_write_processing): Set sh_info
to sh_link for SHT_IA_64_UNWIND sections.
gas/
2004-07-26 H.J. Lu <hongjiu.lu@intel.com>
* config/tc-ia64.c (start_unwind_section): Set the linked-to
section.
(ia64_elf_section_change_hook): Set the linked-to section for
SHT_IA_64_UNWIND.
no associated relocation.
(mips_ip): Cancel the expression after use for the Q format
specifier.
(parse_relocation): Return no relocation for unsupported
operators.
(my_getSmallExpression): Return no relocation if no relocation
operators are used.
bfd:
* elf32-sh.c: Include ../opcodes/sh-opc.h .
* Makefile.am: Ran make dep-am .
* Makefile.in: Ran make dep-in .
gas:
* config/tc-sh.c (md_assemble): Change isspace to ISSPACE.
(md_parse_option): Remove redundant -isa testing.
Make bfd_arch variable const.
(md_show_usage): Make bfd_arch variable const.
* bfd/cofflink.c (_bfd_coff_generic_relocate_section): Resolve PE weak
externals properly.
* src/gas/config/obj-coff.c (obj_coff_weak): New .weak syntax for PE weak
externals.
* binutils/doc/binutils.texi (nm): Clarify weak symbol description.
* gas/config/tc-i386.c (tc_gen_reloc): Use addend for weak symbols in TE_PE.
* gas/doc/as.texinfo (Weak): Document PE weak symbols.
* ld/ld.texinfo (WIN32): Document PE weak symbols.
(reloc_needs_lo_p): Only return true if HAVE_IN_PLACE_ADDENDS.
(mips_frob_file): Rework so that only a single pass through the
relocs is needed. Allow %lo()s to have higher offsets than their
corresponding %hi()s or %got()s.
testsuite/
* gas/mips/elf{,el}-rel.d: Adjust so that the earliest %hi() matches
the earliest %lo().
* gas/mips/elf-rel11.d: Don't expect the relocs to be reordered.
* gas/mips/elf-rel20.[sd]: New test.
* gas/mips/mips.exp: Run it.
bfd:
* Makefile.am: Regenerate dependencies.
* Makefile.in: Regenerate.
* archures.c: Add bfd_mach_sh3_nommu .
* bfd-in2.h: Regenerate.
* cpu-sh.c: Add sh3-nommu architecture.
(bfd_to_arch_table): Create new table.
(sh_get_arch_from_bfd_mach): Create new function.
(sh_get_arch_up_from_bfd_mach): Create new function.
(sh_merge_bfd_arch): Create new function.
* elf32-sh.c (sh_ef_bfd_table): Add table.
(sh_elf_check_relocs): Replace switch statement with
use of sh_ef_bfd_table .
(sh_elf_get_flags_from_mach): Add new function.
(sh_find_elf_flags): Likewise.
(sh_elf_copy_private_data): Replace most of non-elf contents
with a call to sh_merge_bfd_arch() .
gas:
* Makefile.am: Regenerate dependecies.
* Makefile.in: Regenerate.
* config/tc-sh.c (valid_arch): Make unsigned.
(preset_target_arch): Likewise.
(md_begin): Use new architecture flags system.
(get_specific): Likewise.
(assemble_ppi): Likewise.
(md_assemble): Likewise. Also fix error check for bad opcodes.
(md_parse_option): Likewise. Also generate -isa values according
to the table in bfd/cpu-sh.c instead of just constants. Also
allow <arch>-up ISA variants.
(sh_elf_final_processing): Replace if-else chain with a call to
sh_find_elf_flags().
* testsuite/gas/sh/arch: New directory.
* testsuite/gas/sh/arch/arch.exp: New test script.
* testsuite/gas/sh/arch/arch_expected.txt: New file.
* testsuite/gas/sh/arch/sh.s: New file.
* testsuite/gas/sh/arch/sh2.s: New file.
* testsuite/gas/sh/arch/sh-dsp.s: New file.
* testsuite/gas/sh/arch/sh2e.s: New file.
* testsuite/gas/sh/arch/sh3-nommu.s: New file.
* testsuite/gas/sh/arch/sh3.s: New file.
* testsuite/gas/sh/arch/sh3-dsp.s: New file.
* testsuite/gas/sh/arch/sh3e.s: New file.
* testsuite/gas/sh/arch/sh4-nommu-nofpu.s: New file.
* testsuite/gas/sh/arch/sh4-nofpu.s: New file.
* testsuite/gas/sh/arch/sh4.s: New file.
* testsuite/gas/sh/arch/sh4a-nofpu.s: New file.
* testsuite/gas/sh/arch/sh4al-dsp.s: New file.
* testsuite/gas/sh/arch/sh4a.s: New file.
include/elf:
* sh.h (EF_SH_HAS_DSP): Remove.
(EF_SH_HAS_FP): Remove.
(EF_SH_MERGE_MACH): Remove.
(EF_SH4_NOFPU): Convert to decimal.
(EF_SH4A_NOFPU): Likewise.
(EF_SH4_NOMMU_NOFPU): Likewise.
(EF_SH3_NOMMU): Add new macro.
(EF_SH_BFD_TABLE): Likewise.
(sh_find_elf_flags): Add prototype.
(sh_elf_get_flags_from_mach): Likewise.
opcodes:
* sh-dis.c (target_arch): Make unsigned.
(print_insn_sh): Replace (most of) switch with a call to
sh_get_arch_from_bfd_mach(). Also use new architecture flags system.
* sh-opc.h: Redefine architecture flags values.
Add sh3-nommu architecture.
Reorganise <arch>_up macros so they make more visual sense.
(SH_MERGE_ARCH_SET): Define new macro.
(SH_VALID_BASE_ARCH_SET): Likewise.
(SH_VALID_MMU_ARCH_SET): Likewise.
(SH_VALID_CO_ARCH_SET): Likewise.
(SH_VALID_ARCH_SET): Likewise.
(SH_MERGE_ARCH_SET_VALID): Likewise.
(SH_ARCH_SET_HAS_FPU): Likewise.
(SH_ARCH_SET_HAS_DSP): Likewise.
(SH_ARCH_UNKNOWN_ARCH): Likewise.
(sh_get_arch_from_bfd_mach): Add prototype.
(sh_get_arch_up_from_bfd_mach): Likewise.
(sh_get_bfd_mach_from_arch_set): Likewise.
(sh_merge_bfd_arc): Likewise.
ld:
* testsuite/ld-sh/arch/arch.exp: New test script.
* testsuite/ld-sh/arch/arch_expected.txt: New file.
* testsuite/ld-sh/arch/sh.s: New file.
* testsuite/ld-sh/arch/sh2.s: New file.
* testsuite/ld-sh/arch/sh-dsp.s: New file.
* testsuite/ld-sh/arch/sh2e.s: New file.
* testsuite/ld-sh/arch/sh3-nommu.s: New file.
* testsuite/ld-sh/arch/sh3.s: New file.
* testsuite/ld-sh/arch/sh3-dsp.s: New file.
* testsuite/ld-sh/arch/sh3e.s: New file.
* testsuite/ld-sh/arch/sh4-nommu-nofpu.s: New file.
* testsuite/ld-sh/arch/sh4-nofpu.s: New file.
* testsuite/ld-sh/arch/sh4.s: New file.
* testsuite/ld-sh/arch/sh4a-nofpu.s: New file.
* testsuite/ld-sh/arch/sh4al-dsp.s: New file.
* testsuite/ld-sh/arch/sh4a.s: New file.