From 4107ae2218c9a74fce40d50cb68a7a5ab0bf06e5 Mon Sep 17 00:00:00 2001 From: DJ Delorie Date: Wed, 27 Feb 2013 21:39:20 +0000 Subject: * reloc.c (BFD_RELOC_RL78_CODE): Add. * libbfd.h: Regenerate. * bfd-in2.h: Regenerate. * elf32-rl78.c (rl78_elf_relocate_section): Handle weak code references in compuated relocs. * config/tc-rl78.c (reloc_function): Add %code -> BFD_RELOC_RL78_CODE. (rl78_op): Handle %code(). (rl78_cons_fix_new): Likewise, but ignore for 20-bit operands. (tc_gen_reloc): Likwise; convert to a computed reloc. (md_apply_fix): Likewise. --- bfd/elf32-rl78.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'bfd/elf32-rl78.c') diff --git a/bfd/elf32-rl78.c b/bfd/elf32-rl78.c index 3a46c6b..ea9a076 100644 --- a/bfd/elf32-rl78.c +++ b/bfd/elf32-rl78.c @@ -778,6 +778,8 @@ rl78_elf_relocate_section + sec->output_section->vma + sec->output_offset + rel->r_addend); + else if (h->root.type == bfd_link_hash_undefweak) + RL78_STACK_PUSH (0); else _bfd_error_handler (_("Warning: RL78_SYM reloc with an unknown symbol")); } -- cgit v1.1