From 61ba1cf93601b0a0877a8ade94ba3c674a09f77e Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Fri, 29 Sep 2006 19:58:17 +0000 Subject: Snapshot. Now able to produce a minimal executable which actually runs. --- elfcpp/elfcpp_internal.h | 30 ++++++++++++++++++++++++++++-- 1 file changed, 28 insertions(+), 2 deletions(-) (limited to 'elfcpp/elfcpp_internal.h') diff --git a/elfcpp/elfcpp_internal.h b/elfcpp/elfcpp_internal.h index 696343a..0d69bae 100644 --- a/elfcpp/elfcpp_internal.h +++ b/elfcpp/elfcpp_internal.h @@ -158,8 +158,17 @@ convert_off(typename Elf_types::Elf_Off v) // Convert Elf_WXword. template -inline typename Elf_types::Elf_Off -convert_wxword(typename Elf_types::Elf_Off v) +inline typename Elf_types::Elf_WXword +convert_wxword(typename Elf_types::Elf_WXword v) +{ + return convert_addr_size(v); +} + +// Convert ELF_Swxword. + +template +inline typename Elf_types::Elf_Swxword +convert_swxword(typename Elf_types::Elf_Swxword v) { return convert_addr_size(v); } @@ -264,6 +273,23 @@ struct Sym_data<64> Elf_Xword st_size; }; +// Elf relocation table entries. + +template +struct Rel_data +{ + typename Elf_types::Elf_Addr r_offset; + typename Elf_types::Elf_WXword r_info; +}; + +template +struct Rela_data +{ + typename Elf_types::Elf_Addr r_offset; + typename Elf_types::Elf_WXword r_info; + typename Elf_types::Elf_Swxword r_addend; +}; + } // End namespace internal. } // End namespace elfcpp. -- cgit v1.1