Back to index

cell-binutils  2.17cvs20070401
elf32-mt.c
Go to the documentation of this file.
00001 /* Morpho Technologies MT specific support for 32-bit ELF
00002    Copyright 2001, 2002, 2003, 2004, 2005, 2006, 2007
00003    Free Software Foundation, Inc.
00004 
00005    This file is part of BFD, the Binary File Descriptor library.
00006 
00007    This program is free software; you can redistribute it and/or modify
00008    it under the terms of the GNU General Public License as published by
00009    the Free Software Foundation; either version 2 of the License, or
00010    (at your option) any later version.
00011 
00012    This program is distributed in the hope that it will be useful,
00013    but WITHOUT ANY WARRANTY; without even the implied warranty of
00014    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00015    GNU General Public License for more details.
00016 
00017    You should have received a copy of the GNU General Public License
00018    along with this program; if not, write to the Free Software
00019    Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
00020 
00021 #include "bfd.h"
00022 #include "sysdep.h"
00023 #include "libbfd.h"
00024 #include "elf-bfd.h"
00025 #include "elf/mt.h"
00026 
00027 /* Prototypes.  */
00028 static reloc_howto_type * mt_reloc_type_lookup 
00029   (bfd *, bfd_reloc_code_real_type);
00030 
00031 static void mt_info_to_howto_rela
00032   (bfd *, arelent *, Elf_Internal_Rela *);
00033 
00034 static bfd_reloc_status_type mt_elf_relocate_hi16
00035   (bfd *, Elf_Internal_Rela *, bfd_byte *, bfd_vma);
00036 
00037 static bfd_reloc_status_type mt_final_link_relocate
00038   (reloc_howto_type *, bfd *, asection *, bfd_byte *, 
00039    Elf_Internal_Rela *, bfd_vma);
00040 
00041 static bfd_boolean mt_elf_relocate_section
00042   (bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *, 
00043    Elf_Internal_Rela *, Elf_Internal_Sym *, asection **);
00044 
00045 /* Relocation tables.  */
00046 static reloc_howto_type mt_elf_howto_table [] =
00047 {
00048   /* This reloc does nothing.  */
00049   HOWTO (R_MT_NONE,           /* type */
00050           0,                      /* rightshift */ 
00051           2,                      /* size (0 = byte, 1 = short, 2 = long) */ 
00052           32,                     /* bitsize */
00053           FALSE,                  /* pc_relative */ 
00054           0,                      /* bitpos */ 
00055           complain_overflow_dont, /* complain_on_overflow */ 
00056           bfd_elf_generic_reloc,  /* special_function */ 
00057           "R_MT_NONE",          /* name */ 
00058           FALSE,                  /* partial_inplace */ 
00059           0 ,                     /* src_mask */ 
00060           0,                      /* dst_mask */ 
00061           FALSE),                 /* pcrel_offset */
00062 
00063   /* A 16 bit absolute relocation.  */
00064   HOWTO (R_MT_16,             /* type */
00065           0,                      /* rightshift */ 
00066           2,                      /* size (0 = byte, 1 = short, 2 = long) */ 
00067           16,                     /* bitsize */
00068           FALSE,                  /* pc_relative */ 
00069           0,                      /* bitpos */ 
00070           complain_overflow_dont, /* complain_on_overflow */ 
00071           bfd_elf_generic_reloc,  /* special_function */ 
00072           "R_MT_16",            /* name */ 
00073           FALSE,                  /* partial_inplace */ 
00074           0 ,                     /* src_mask */ 
00075           0xffff,                 /* dst_mask */ 
00076           FALSE),                 /* pcrel_offset */
00077 
00078   /* A 32 bit absolute relocation.  */
00079   HOWTO (R_MT_32,             /* type */
00080           0,                      /* rightshift */ 
00081           2,                      /* size (0 = byte, 1 = short, 2 = long) */ 
00082           32,                     /* bitsize */
00083           FALSE,                  /* pc_relative */ 
00084           0,                      /* bitpos */ 
00085           complain_overflow_dont, /* complain_on_overflow */ 
00086           bfd_elf_generic_reloc,  /* special_function */ 
00087           "R_MT_32",            /* name */ 
00088           FALSE,                  /* partial_inplace */ 
00089           0 ,                     /* src_mask */ 
00090           0xffffffff,             /* dst_mask */ 
00091           FALSE),                 /* pcrel_offset */
00092 
00093   /* A 32 bit pc-relative relocation.  */
00094   HOWTO (R_MT_32_PCREL,       /* type */
00095           0,                      /* rightshift */ 
00096           2,                      /* size (0 = byte, 1 = short, 2 = long) */ 
00097           32,                     /* bitsize */
00098           TRUE,                   /* pc_relative */ 
00099           0,                      /* bitpos */ 
00100           complain_overflow_dont, /* complain_on_overflow */ 
00101           bfd_elf_generic_reloc,  /* special_function */ 
00102           "R_MT_32_PCREL",    /* name */ 
00103           FALSE,                  /* partial_inplace */ 
00104           0 ,                     /* src_mask */ 
00105           0xffffffff,             /* dst_mask */ 
00106           TRUE),                  /* pcrel_offset */
00107 
00108   /* A 16 bit pc-relative relocation.  */
00109   HOWTO (R_MT_PC16,           /* type */
00110           0,                      /* rightshift */ 
00111           2,                      /* size (0 = byte, 1 = short, 2 = long) */ 
00112           16,                     /* bitsize */
00113           TRUE,                   /* pc_relative */ 
00114           0,                      /* bitpos */ 
00115           complain_overflow_signed, /* complain_on_overflow */ 
00116           bfd_elf_generic_reloc,  /* special_function */ 
00117           "R_MT_PC16",          /* name */ 
00118           FALSE,                  /* partial_inplace */ 
00119           0,                      /* src_mask */ 
00120           0xffff,                 /* dst_mask */ 
00121           TRUE),                  /* pcrel_offset */
00122 
00123   /* high 16 bits of symbol value.  */
00124   HOWTO (R_MT_HI16,          /* type */
00125          0,                     /* rightshift */
00126          2,                     /* size (0 = byte, 1 = short, 2 = long) */
00127          16,                    /* bitsize */
00128          FALSE,                 /* pc_relative */
00129          0,                     /* bitpos */
00130          complain_overflow_dont, /* complain_on_overflow */
00131          bfd_elf_generic_reloc, /* special_function */
00132          "R_MT_HI16",        /* name */
00133          FALSE,                  /* partial_inplace */
00134          0xffff0000,            /* src_mask */
00135          0xffff0000,            /* dst_mask */
00136          FALSE),                /* pcrel_offset */
00137 
00138   /* Low 16 bits of symbol value.  */
00139   HOWTO (R_MT_LO16,          /* type */
00140          0,                     /* rightshift */
00141          2,                     /* size (0 = byte, 1 = short, 2 = long) */
00142          16,                    /* bitsize */
00143          FALSE,                 /* pc_relative */
00144          0,                     /* bitpos */
00145          complain_overflow_dont, /* complain_on_overflow */
00146          bfd_elf_generic_reloc, /* special_function */
00147          "R_MT_LO16",        /* name */
00148          FALSE,                  /* partial_inplace */
00149          0xffff,                /* src_mask */
00150          0xffff,                /* dst_mask */
00151          FALSE),                /* pcrel_offset */
00152 };
00153 
00154 /* Map BFD reloc types to MT ELF reloc types.  */
00155 
00156 static reloc_howto_type *
00157 mt_reloc_type_lookup
00158     (bfd *                    abfd ATTRIBUTE_UNUSED,
00159      bfd_reloc_code_real_type code)
00160 {
00161   /* Note that the mt_elf_howto_table is indxed by the R_
00162      constants.  Thus, the order that the howto records appear in the
00163      table *must* match the order of the relocation types defined in
00164      include/elf/mt.h.  */
00165 
00166   switch (code)
00167     {
00168     case BFD_RELOC_NONE:
00169       return &mt_elf_howto_table[ (int) R_MT_NONE];
00170     case BFD_RELOC_16:
00171       return &mt_elf_howto_table[ (int) R_MT_16];
00172     case BFD_RELOC_32:
00173       return &mt_elf_howto_table[ (int) R_MT_32];
00174     case BFD_RELOC_32_PCREL:
00175       return &mt_elf_howto_table[ (int) R_MT_32_PCREL];
00176     case BFD_RELOC_16_PCREL:
00177       return &mt_elf_howto_table[ (int) R_MT_PC16];
00178     case BFD_RELOC_HI16:
00179       return &mt_elf_howto_table[ (int) R_MT_HI16];
00180     case BFD_RELOC_LO16:
00181       return &mt_elf_howto_table[ (int) R_MT_LO16];
00182 
00183     default:
00184       /* Pacify gcc -Wall.  */
00185       return NULL;
00186     }
00187   return NULL;
00188 }
00189 
00190 static reloc_howto_type *
00191 mt_reloc_name_lookup (bfd *abfd ATTRIBUTE_UNUSED,
00192                     const char *r_name)
00193 {
00194   unsigned int i;
00195 
00196   for (i = 0;
00197        i < sizeof (mt_elf_howto_table) / sizeof (mt_elf_howto_table[0]);
00198        i++)
00199     if (mt_elf_howto_table[i].name != NULL
00200        && strcasecmp (mt_elf_howto_table[i].name, r_name) == 0)
00201       return &mt_elf_howto_table[i];
00202 
00203   return NULL;
00204 }
00205 
00206 bfd_reloc_status_type
00207 mt_elf_relocate_hi16
00208     (bfd *               input_bfd,
00209      Elf_Internal_Rela * relhi,
00210      bfd_byte *          contents,
00211      bfd_vma             value)
00212 {
00213   bfd_vma insn;
00214 
00215   insn = bfd_get_32 (input_bfd, contents + relhi->r_offset);
00216 
00217   value += relhi->r_addend;
00218   value >>= 16;
00219   insn = ((insn & ~0xFFFF) | value);
00220 
00221   bfd_put_32 (input_bfd, insn, contents + relhi->r_offset);
00222   return bfd_reloc_ok;
00223 }
00224 
00225 /* XXX: The following code is the result of a cut&paste.  This unfortunate
00226    practice is very widespread in the various target back-end files.  */
00227 
00228 /* Set the howto pointer for a MT ELF reloc.  */
00229 
00230 static void
00231 mt_info_to_howto_rela
00232     (bfd *               abfd ATTRIBUTE_UNUSED,
00233      arelent *           cache_ptr,
00234      Elf_Internal_Rela * dst)
00235 {
00236   unsigned int r_type;
00237 
00238   r_type = ELF32_R_TYPE (dst->r_info);
00239   cache_ptr->howto = & mt_elf_howto_table [r_type];
00240 }
00241 
00242 /* Perform a single relocation.  By default we use the standard BFD
00243    routines.  */
00244 
00245 static bfd_reloc_status_type
00246 mt_final_link_relocate
00247     (reloc_howto_type *  howto,
00248      bfd *               input_bfd,
00249      asection *          input_section,
00250      bfd_byte *          contents,
00251      Elf_Internal_Rela * rel,
00252      bfd_vma             relocation)
00253 {
00254   return _bfd_final_link_relocate (howto, input_bfd, input_section,
00255                                contents, rel->r_offset,
00256                                relocation, rel->r_addend);
00257 }
00258 
00259 /* Relocate a MT ELF section.
00260    There is some attempt to make this function usable for many architectures,
00261    both USE_REL and USE_RELA ['twould be nice if such a critter existed],
00262    if only to serve as a learning tool.
00263 
00264    The RELOCATE_SECTION function is called by the new ELF backend linker
00265    to handle the relocations for a section.
00266 
00267    The relocs are always passed as Rela structures; if the section
00268    actually uses Rel structures, the r_addend field will always be
00269    zero.
00270 
00271    This function is responsible for adjusting the section contents as
00272    necessary, and (if using Rela relocs and generating a relocatable
00273    output file) adjusting the reloc addend as necessary.
00274 
00275    This function does not have to worry about setting the reloc
00276    address or the reloc symbol index.
00277 
00278    LOCAL_SYMS is a pointer to the swapped in local symbols.
00279 
00280    LOCAL_SECTIONS is an array giving the section in the input file
00281    corresponding to the st_shndx field of each local symbol.
00282 
00283    The global hash table entry for the global symbols can be found
00284    via elf_sym_hashes (input_bfd).
00285 
00286    When generating relocatable output, this function must handle
00287    STB_LOCAL/STT_SECTION symbols specially.  The output symbol is
00288    going to be the section symbol corresponding to the output
00289    section, which means that the addend must be adjusted
00290    accordingly.  */
00291 
00292 static bfd_boolean
00293 mt_elf_relocate_section
00294     (bfd *                   output_bfd ATTRIBUTE_UNUSED,
00295      struct bfd_link_info *  info,
00296      bfd *                   input_bfd,
00297      asection *              input_section,
00298      bfd_byte *              contents,
00299      Elf_Internal_Rela *     relocs,
00300      Elf_Internal_Sym *      local_syms,
00301      asection **             local_sections)
00302 {
00303   Elf_Internal_Shdr *           symtab_hdr;
00304   struct elf_link_hash_entry ** sym_hashes;
00305   Elf_Internal_Rela *           rel;
00306   Elf_Internal_Rela *           relend;
00307 
00308   symtab_hdr = & elf_tdata (input_bfd)->symtab_hdr;
00309   sym_hashes = elf_sym_hashes (input_bfd);
00310   relend     = relocs + input_section->reloc_count;
00311 
00312   for (rel = relocs; rel < relend; rel ++)
00313     {
00314       reloc_howto_type *           howto;
00315       unsigned long                r_symndx;
00316       Elf_Internal_Sym *           sym;
00317       asection *                   sec;
00318       struct elf_link_hash_entry * h;
00319       bfd_vma                      relocation;
00320       bfd_reloc_status_type        r;
00321       const char *                 name = NULL;
00322       int                          r_type;
00323       
00324       r_type = ELF32_R_TYPE (rel->r_info);
00325 
00326       r_symndx = ELF32_R_SYM (rel->r_info);
00327 
00328       howto  = mt_elf_howto_table + ELF32_R_TYPE (rel->r_info);
00329       h      = NULL;
00330       sym    = NULL;
00331       sec    = NULL;
00332       
00333       if (r_symndx < symtab_hdr->sh_info)
00334        {
00335          sym = local_syms + r_symndx;
00336          sec = local_sections [r_symndx];
00337          relocation = _bfd_elf_rela_local_sym (output_bfd, sym, &sec, rel);
00338          
00339          name = bfd_elf_string_from_elf_section
00340            (input_bfd, symtab_hdr->sh_link, sym->st_name);
00341          name = (name == NULL) ? bfd_section_name (input_bfd, sec) : name;
00342        }
00343       else
00344        {
00345          bfd_boolean unresolved_reloc;
00346          bfd_boolean warned;
00347 
00348          RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
00349                                r_symndx, symtab_hdr, sym_hashes,
00350                                h, sec, relocation,
00351                                unresolved_reloc, warned);
00352 
00353          name = h->root.root.string;
00354        }
00355 
00356       if (sec != NULL && elf_discarded_section (sec))
00357        {
00358          /* For relocs against symbols from removed linkonce sections,
00359             or sections discarded by a linker script, we just want the
00360             section contents zeroed.  Avoid any special processing.  */
00361          _bfd_clear_contents (howto, input_bfd, contents + rel->r_offset);
00362          rel->r_info = 0;
00363          rel->r_addend = 0;
00364          continue;
00365        }
00366 
00367       if (info->relocatable)
00368        continue;
00369 
00370       /* Finally, the sole MT-specific part.  */
00371       switch (r_type)
00372         {
00373         case R_MT_HI16:
00374           r = mt_elf_relocate_hi16 (input_bfd, rel, contents, relocation);
00375           break;
00376        default:
00377           r = mt_final_link_relocate (howto, input_bfd, input_section,
00378                                      contents, rel, relocation);
00379           break;
00380         }
00381 
00382 
00383       if (r != bfd_reloc_ok)
00384        {
00385          const char * msg = (const char *) NULL;
00386 
00387          switch (r)
00388            {
00389            case bfd_reloc_overflow:
00390              r = info->callbacks->reloc_overflow
00391               (info, (h ? &h->root : NULL), name, howto->name, (bfd_vma) 0,
00392                input_bfd, input_section, rel->r_offset);
00393              break;
00394              
00395            case bfd_reloc_undefined:
00396              r = info->callbacks->undefined_symbol
00397               (info, name, input_bfd, input_section, rel->r_offset, TRUE);
00398              break;
00399              
00400            case bfd_reloc_outofrange:
00401              msg = _("internal error: out of range error");
00402              break;
00403 
00404            case bfd_reloc_dangerous:
00405              msg = _("internal error: dangerous relocation");
00406              break;
00407 
00408            default:
00409              msg = _("internal error: unknown error");
00410              break;
00411            }
00412 
00413          if (msg)
00414            r = info->callbacks->warning
00415              (info, msg, name, input_bfd, input_section, rel->r_offset);
00416 
00417          if (! r)
00418            return FALSE;
00419        }
00420     }
00421 
00422   return TRUE;
00423 }
00424 
00425 /* Look through the relocs for a section during the first phase.
00426    Since we don't do .gots or .plts, we just need to consider the
00427    virtual table relocs for gc.  */
00428  
00429 static bfd_boolean
00430 mt_elf_check_relocs
00431     (bfd *                     abfd,
00432      struct bfd_link_info *    info,
00433      asection *                sec,
00434      const Elf_Internal_Rela * relocs)
00435 {
00436   Elf_Internal_Shdr *           symtab_hdr;
00437   struct elf_link_hash_entry ** sym_hashes;
00438   struct elf_link_hash_entry ** sym_hashes_end;
00439   const Elf_Internal_Rela *     rel;
00440   const Elf_Internal_Rela *     rel_end;
00441   
00442   if (info->relocatable)
00443     return TRUE;
00444   
00445   symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
00446   sym_hashes = elf_sym_hashes (abfd);
00447   sym_hashes_end = sym_hashes + symtab_hdr->sh_size / sizeof (Elf32_External_Sym);
00448   if (!elf_bad_symtab (abfd))
00449     sym_hashes_end -= symtab_hdr->sh_info;
00450   
00451   rel_end = relocs + sec->reloc_count;
00452   for (rel = relocs; rel < rel_end; rel++)
00453     {
00454       struct elf_link_hash_entry *h;
00455       unsigned long r_symndx;
00456       
00457       r_symndx = ELF32_R_SYM (rel->r_info);
00458       if (r_symndx < symtab_hdr->sh_info)
00459         h = NULL;
00460       else
00461        {
00462          h = sym_hashes[r_symndx - symtab_hdr->sh_info];
00463          while (h->root.type == bfd_link_hash_indirect
00464                || h->root.type == bfd_link_hash_warning)
00465            h = (struct elf_link_hash_entry *) h->root.u.i.link;
00466        }
00467     }
00468 
00469   return TRUE;
00470 }
00471 
00472 /* Return the MACH for an e_flags value.  */
00473 
00474 static int
00475 elf32_mt_machine (bfd *abfd)
00476 {
00477   switch (elf_elfheader (abfd)->e_flags & EF_MT_CPU_MASK)
00478     {
00479     case EF_MT_CPU_MRISC:   return bfd_mach_ms1;
00480     case EF_MT_CPU_MRISC2:  return bfd_mach_mrisc2;
00481     case EF_MT_CPU_MS2:            return bfd_mach_ms2;
00482     }
00483 
00484   return bfd_mach_ms1;
00485 }
00486 
00487 static bfd_boolean
00488 mt_elf_object_p (bfd * abfd)
00489 {
00490   bfd_default_set_arch_mach (abfd, bfd_arch_mt, elf32_mt_machine (abfd));
00491 
00492   return TRUE;
00493 }
00494 
00495 /* Function to set the ELF flag bits.  */
00496 
00497 static bfd_boolean
00498 mt_elf_set_private_flags (bfd *    abfd,
00499                         flagword flags)
00500 {
00501   elf_elfheader (abfd)->e_flags = flags;
00502   elf_flags_init (abfd) = TRUE;
00503   return TRUE;
00504 }
00505 
00506 static bfd_boolean
00507 mt_elf_copy_private_bfd_data (bfd * ibfd, bfd * obfd)
00508 {
00509   if (bfd_get_flavour (ibfd) != bfd_target_elf_flavour
00510       || bfd_get_flavour (obfd) != bfd_target_elf_flavour)
00511     return TRUE;
00512   
00513   BFD_ASSERT (!elf_flags_init (obfd)
00514              || elf_elfheader (obfd)->e_flags == elf_elfheader (ibfd)->e_flags);
00515 
00516   elf_elfheader (obfd)->e_flags = elf_elfheader (ibfd)->e_flags;
00517   elf_flags_init (obfd) = TRUE;
00518   return TRUE;
00519 }
00520 
00521 /* Merge backend specific data from an object file to the output
00522    object file when linking.  */
00523 
00524 static bfd_boolean
00525 mt_elf_merge_private_bfd_data (bfd * ibfd, bfd * obfd)
00526 {
00527   flagword     old_flags, new_flags;
00528   bfd_boolean  ok = TRUE;
00529 
00530   /* Check if we have the same endianess.  */
00531   if (_bfd_generic_verify_endian_match (ibfd, obfd) == FALSE)
00532     return FALSE;
00533 
00534   /* If they're not both mt, then merging is meaningless, so just
00535      don't do it.  */
00536   if (strcmp (ibfd->arch_info->arch_name, "mt") != 0)
00537     return TRUE;
00538   if (strcmp (obfd->arch_info->arch_name, "mt") != 0)
00539     return TRUE;
00540 
00541   new_flags = elf_elfheader (ibfd)->e_flags;
00542   old_flags = elf_elfheader (obfd)->e_flags;
00543 
00544 #ifdef DEBUG
00545   _bfd_error_handler ("%B: old_flags = 0x%.8lx, new_flags = 0x%.8lx, init = %s",
00546                     ibfd, old_flags, new_flags, elf_flags_init (obfd) ? "yes" : "no");
00547 #endif
00548 
00549   if (!elf_flags_init (obfd))
00550     {
00551       old_flags = new_flags;
00552       elf_flags_init (obfd) = TRUE;
00553     }
00554   else if ((new_flags & EF_MT_CPU_MASK) != (old_flags & EF_MT_CPU_MASK))
00555     {
00556       /* CPU has changed.  This is invalid, because MRISC, MRISC2 and
00557         MS2 are not subsets of each other.   */
00558       ok = FALSE;
00559     }
00560   
00561   if (ok)
00562     {
00563       obfd->arch_info = ibfd->arch_info;
00564       elf_elfheader (obfd)->e_flags = old_flags;
00565     }
00566 
00567   return ok;
00568 }
00569 
00570 static bfd_boolean
00571 mt_elf_print_private_bfd_data (bfd * abfd, void * ptr)
00572 {
00573   FILE *   file = (FILE *) ptr;
00574   flagword flags;
00575 
00576   BFD_ASSERT (abfd != NULL && ptr != NULL);
00577   
00578   /* Print normal ELF private data.  */
00579   _bfd_elf_print_private_bfd_data (abfd, ptr);
00580 
00581   flags = elf_elfheader (abfd)->e_flags;
00582   fprintf (file, _("private flags = 0x%lx:"), (long)flags);
00583 
00584   switch (flags & EF_MT_CPU_MASK)
00585     {
00586     default:
00587     case EF_MT_CPU_MRISC:   fprintf (file, " ms1-16-002");     break;
00588     case EF_MT_CPU_MRISC2:  fprintf (file, " ms1-16-003");     break;
00589     case EF_MT_CPU_MS2:     fprintf (file, " ms2");     break;
00590     }
00591 
00592   fputc ('\n', file);
00593 
00594   return TRUE;
00595 }
00596 
00597 
00598 #define TARGET_BIG_SYM       bfd_elf32_mt_vec
00599 #define TARGET_BIG_NAME  "elf32-mt"
00600 
00601 #define ELF_ARCH      bfd_arch_mt
00602 #define ELF_MACHINE_CODE EM_MT
00603 #define ELF_MAXPAGESIZE  1 /* No pages on the MT.  */
00604 
00605 #define elf_info_to_howto_rel                    NULL
00606 #define elf_info_to_howto                 mt_info_to_howto_rela
00607 
00608 #define elf_backend_relocate_section             mt_elf_relocate_section
00609 
00610 #define bfd_elf32_bfd_reloc_type_lookup           mt_reloc_type_lookup
00611 #define bfd_elf32_bfd_reloc_name_lookup   mt_reloc_name_lookup
00612 
00613 #define elf_backend_check_relocs                mt_elf_check_relocs
00614 #define elf_backend_object_p                      mt_elf_object_p
00615 #define elf_backend_rela_normal                  1
00616 
00617 #define elf_backend_can_gc_sections              1
00618 
00619 #define bfd_elf32_bfd_set_private_flags          mt_elf_set_private_flags
00620 #define bfd_elf32_bfd_copy_private_bfd_data      mt_elf_copy_private_bfd_data
00621 #define bfd_elf32_bfd_merge_private_bfd_data     mt_elf_merge_private_bfd_data
00622 #define bfd_elf32_bfd_print_private_bfd_data     mt_elf_print_private_bfd_data
00623 
00624 #include "elf32-target.h"