From: Andreas Schwab Date: Wed, 20 Oct 2004 21:29:45 +0000 (+0000) Subject: * elf32-m68k.c (elf_m68k_plt_sym_val): New function. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=1715e0e33ecf4042867c6170b01e2103dd9dfe4c;p=binutils-gdb.git * elf32-m68k.c (elf_m68k_plt_sym_val): New function. (elf_backend_plt_sym_val): Define. --- diff --git a/bfd/ChangeLog b/bfd/ChangeLog index 2b745ac6f91..b640031e1f5 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,8 @@ +2004-10-20 Andreas Schwab + + * elf32-m68k.c (elf_m68k_plt_sym_val): New function. + (elf_backend_plt_sym_val): Define. + 2004-10-19 Danny Smith * config.bfd: Set targ_underscore=yes for PE COFF targets diff --git a/bfd/elf32-m68k.c b/bfd/elf32-m68k.c index 4f119035811..f1c6ea79319 100644 --- a/bfd/elf32-m68k.c +++ b/bfd/elf32-m68k.c @@ -2207,6 +2207,18 @@ elf32_m68k_reloc_type_class (rela) } } +/* Return address for Ith PLT stub in section PLT, for relocation REL + or (bfd_vma) -1 if it should not be included. */ + +static bfd_vma +elf_m68k_plt_sym_val (bfd_vma i, const asection *plt, + const arelent *rel ATTRIBUTE_UNUSED) +{ + if (CPU32_FLAG (plt->owner)) + return plt->vma + (i + 1) * PLT_CPU32_ENTRY_SIZE; + return plt->vma + (i + 1) * PLT_ENTRY_SIZE; +} + #define TARGET_BIG_SYM bfd_elf32_m68k_vec #define TARGET_BIG_NAME "elf32-m68k" #define ELF_MACHINE_CODE EM_68K @@ -2236,6 +2248,7 @@ elf32_m68k_reloc_type_class (rela) #define bfd_elf32_bfd_print_private_bfd_data \ elf32_m68k_print_private_bfd_data #define elf_backend_reloc_type_class elf32_m68k_reloc_type_class +#define elf_backend_plt_sym_val elf_m68k_plt_sym_val #define elf_backend_can_gc_sections 1 #define elf_backend_can_refcount 1