00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026 #ifndef _EXT_TYPES_H
00027 #define _EXT_TYPES_H
00028
00029 #ifdef __cplusplus
00030 extern "C" {
00031 #endif
00032
00033
00034
00035
00036 typedef unsigned char __ext_Elf32_Addr [ELF32_FSZ_ADDR];
00037 typedef unsigned char __ext_Elf32_Half [ELF32_FSZ_HALF];
00038 typedef unsigned char __ext_Elf32_Off [ELF32_FSZ_OFF];
00039 typedef unsigned char __ext_Elf32_Sword [ELF32_FSZ_SWORD];
00040 typedef unsigned char __ext_Elf32_Word [ELF32_FSZ_WORD];
00041
00042 #if __LIBELF64
00043
00044 typedef unsigned char __ext_Elf32_Lword [8];
00045
00046 typedef unsigned char __ext_Elf64_Addr [ELF64_FSZ_ADDR];
00047 typedef unsigned char __ext_Elf64_Half [ELF64_FSZ_HALF];
00048 typedef unsigned char __ext_Elf64_Off [ELF64_FSZ_OFF];
00049 typedef unsigned char __ext_Elf64_Sword [ELF64_FSZ_SWORD];
00050 typedef unsigned char __ext_Elf64_Word [ELF64_FSZ_WORD];
00051 typedef unsigned char __ext_Elf64_Sxword[ELF64_FSZ_SXWORD];
00052 typedef unsigned char __ext_Elf64_Xword [ELF64_FSZ_XWORD];
00053
00054 typedef unsigned char __ext_Elf64_Lword [8];
00055
00056 #endif
00057
00058
00059
00060
00061 typedef struct {
00062 unsigned char e_ident[EI_NIDENT];
00063 __ext_Elf32_Half e_type;
00064 __ext_Elf32_Half e_machine;
00065 __ext_Elf32_Word e_version;
00066 __ext_Elf32_Addr e_entry;
00067 __ext_Elf32_Off e_phoff;
00068 __ext_Elf32_Off e_shoff;
00069 __ext_Elf32_Word e_flags;
00070 __ext_Elf32_Half e_ehsize;
00071 __ext_Elf32_Half e_phentsize;
00072 __ext_Elf32_Half e_phnum;
00073 __ext_Elf32_Half e_shentsize;
00074 __ext_Elf32_Half e_shnum;
00075 __ext_Elf32_Half e_shstrndx;
00076 } __ext_Elf32_Ehdr;
00077
00078 #if __LIBELF64
00079 typedef struct {
00080 unsigned char e_ident[EI_NIDENT];
00081 __ext_Elf64_Half e_type;
00082 __ext_Elf64_Half e_machine;
00083 __ext_Elf64_Word e_version;
00084 __ext_Elf64_Addr e_entry;
00085 __ext_Elf64_Off e_phoff;
00086 __ext_Elf64_Off e_shoff;
00087 __ext_Elf64_Word e_flags;
00088 __ext_Elf64_Half e_ehsize;
00089 __ext_Elf64_Half e_phentsize;
00090 __ext_Elf64_Half e_phnum;
00091 __ext_Elf64_Half e_shentsize;
00092 __ext_Elf64_Half e_shnum;
00093 __ext_Elf64_Half e_shstrndx;
00094 } __ext_Elf64_Ehdr;
00095 #endif
00096
00097
00098
00099
00100 typedef struct {
00101 __ext_Elf32_Word sh_name;
00102 __ext_Elf32_Word sh_type;
00103 __ext_Elf32_Word sh_flags;
00104 __ext_Elf32_Addr sh_addr;
00105 __ext_Elf32_Off sh_offset;
00106 __ext_Elf32_Word sh_size;
00107 __ext_Elf32_Word sh_link;
00108 __ext_Elf32_Word sh_info;
00109 __ext_Elf32_Word sh_addralign;
00110 __ext_Elf32_Word sh_entsize;
00111 } __ext_Elf32_Shdr;
00112
00113 #if __LIBELF64
00114 typedef struct {
00115 __ext_Elf64_Word sh_name;
00116 __ext_Elf64_Word sh_type;
00117 __ext_Elf64_Xword sh_flags;
00118 __ext_Elf64_Addr sh_addr;
00119 __ext_Elf64_Off sh_offset;
00120 __ext_Elf64_Xword sh_size;
00121 __ext_Elf64_Word sh_link;
00122 __ext_Elf64_Word sh_info;
00123 __ext_Elf64_Xword sh_addralign;
00124 __ext_Elf64_Xword sh_entsize;
00125 } __ext_Elf64_Shdr;
00126 #endif
00127
00128
00129
00130
00131 typedef struct {
00132 __ext_Elf32_Word st_name;
00133 __ext_Elf32_Addr st_value;
00134 __ext_Elf32_Word st_size;
00135 unsigned char st_info;
00136 unsigned char st_other;
00137 __ext_Elf32_Half st_shndx;
00138 } __ext_Elf32_Sym;
00139
00140 #if __LIBELF64
00141 typedef struct {
00142 __ext_Elf64_Word st_name;
00143 unsigned char st_info;
00144 unsigned char st_other;
00145 __ext_Elf64_Half st_shndx;
00146 __ext_Elf64_Addr st_value;
00147 __ext_Elf64_Xword st_size;
00148 } __ext_Elf64_Sym;
00149 #endif
00150
00151
00152
00153
00154 typedef struct {
00155 __ext_Elf32_Addr r_offset;
00156 __ext_Elf32_Word r_info;
00157 } __ext_Elf32_Rel;
00158
00159 typedef struct {
00160 __ext_Elf32_Addr r_offset;
00161 __ext_Elf32_Word r_info;
00162 __ext_Elf32_Sword r_addend;
00163 } __ext_Elf32_Rela;
00164
00165 #if __LIBELF64
00166 typedef struct {
00167 __ext_Elf64_Addr r_offset;
00168 #if __LIBELF64_IRIX
00169 __ext_Elf64_Word r_sym;
00170 unsigned char r_ssym;
00171 unsigned char r_type3;
00172 unsigned char r_type2;
00173 unsigned char r_type;
00174 #else
00175 __ext_Elf64_Xword r_info;
00176 #endif
00177 } __ext_Elf64_Rel;
00178
00179 typedef struct {
00180 __ext_Elf64_Addr r_offset;
00181 #if __LIBELF64_IRIX
00182 __ext_Elf64_Word r_sym;
00183 unsigned char r_ssym;
00184 unsigned char r_type3;
00185 unsigned char r_type2;
00186 unsigned char r_type;
00187 #else
00188 __ext_Elf64_Xword r_info;
00189 #endif
00190 __ext_Elf64_Sxword r_addend;
00191 } __ext_Elf64_Rela;
00192 #endif
00193
00194
00195
00196
00197 typedef struct {
00198 __ext_Elf32_Word p_type;
00199 __ext_Elf32_Off p_offset;
00200 __ext_Elf32_Addr p_vaddr;
00201 __ext_Elf32_Addr p_paddr;
00202 __ext_Elf32_Word p_filesz;
00203 __ext_Elf32_Word p_memsz;
00204 __ext_Elf32_Word p_flags;
00205 __ext_Elf32_Word p_align;
00206 } __ext_Elf32_Phdr;
00207
00208 #if __LIBELF64
00209 typedef struct {
00210 __ext_Elf64_Word p_type;
00211 __ext_Elf64_Word p_flags;
00212 __ext_Elf64_Off p_offset;
00213 __ext_Elf64_Addr p_vaddr;
00214 __ext_Elf64_Addr p_paddr;
00215 __ext_Elf64_Xword p_filesz;
00216 __ext_Elf64_Xword p_memsz;
00217 __ext_Elf64_Xword p_align;
00218 } __ext_Elf64_Phdr;
00219 #endif
00220
00221
00222
00223
00224 typedef struct {
00225 __ext_Elf32_Sword d_tag;
00226 union {
00227 __ext_Elf32_Word d_val;
00228 __ext_Elf32_Addr d_ptr;
00229 } d_un;
00230 } __ext_Elf32_Dyn;
00231
00232 #if __LIBELF64
00233 typedef struct {
00234 __ext_Elf64_Sxword d_tag;
00235 union {
00236 __ext_Elf64_Xword d_val;
00237 __ext_Elf64_Addr d_ptr;
00238 } d_un;
00239 } __ext_Elf64_Dyn;
00240 #endif
00241
00242
00243
00244
00245 typedef struct {
00246 __ext_Elf32_Half vd_version;
00247 __ext_Elf32_Half vd_flags;
00248 __ext_Elf32_Half vd_ndx;
00249 __ext_Elf32_Half vd_cnt;
00250 __ext_Elf32_Word vd_hash;
00251 __ext_Elf32_Word vd_aux;
00252 __ext_Elf32_Word vd_next;
00253 } __ext_Elf32_Verdef;
00254
00255 typedef struct {
00256 __ext_Elf32_Word vda_name;
00257 __ext_Elf32_Word vda_next;
00258 } __ext_Elf32_Verdaux;
00259
00260 typedef struct {
00261 __ext_Elf32_Half vn_version;
00262 __ext_Elf32_Half vn_cnt;
00263 __ext_Elf32_Word vn_file;
00264 __ext_Elf32_Word vn_aux;
00265 __ext_Elf32_Word vn_next;
00266 } __ext_Elf32_Verneed;
00267
00268 typedef struct {
00269 __ext_Elf32_Word vna_hash;
00270 __ext_Elf32_Half vna_flags;
00271 __ext_Elf32_Half vna_other;
00272 __ext_Elf32_Word vna_name;
00273 __ext_Elf32_Word vna_next;
00274 } __ext_Elf32_Vernaux;
00275
00276 #if __LIBELF64
00277
00278 typedef struct {
00279 __ext_Elf64_Half vd_version;
00280 __ext_Elf64_Half vd_flags;
00281 __ext_Elf64_Half vd_ndx;
00282 __ext_Elf64_Half vd_cnt;
00283 __ext_Elf64_Word vd_hash;
00284 __ext_Elf64_Word vd_aux;
00285 __ext_Elf64_Word vd_next;
00286 } __ext_Elf64_Verdef;
00287
00288 typedef struct {
00289 __ext_Elf64_Word vda_name;
00290 __ext_Elf64_Word vda_next;
00291 } __ext_Elf64_Verdaux;
00292
00293 typedef struct {
00294 __ext_Elf64_Half vn_version;
00295 __ext_Elf64_Half vn_cnt;
00296 __ext_Elf64_Word vn_file;
00297 __ext_Elf64_Word vn_aux;
00298 __ext_Elf64_Word vn_next;
00299 } __ext_Elf64_Verneed;
00300
00301 typedef struct {
00302 __ext_Elf64_Word vna_hash;
00303 __ext_Elf64_Half vna_flags;
00304 __ext_Elf64_Half vna_other;
00305 __ext_Elf64_Word vna_name;
00306 __ext_Elf64_Word vna_next;
00307 } __ext_Elf64_Vernaux;
00308
00309 #endif
00310
00311
00312
00313
00314 #if __LIBELF64
00315
00316 typedef struct {
00317 __ext_Elf32_Lword m_value;
00318 __ext_Elf32_Word m_info;
00319 __ext_Elf32_Word m_poffset;
00320 __ext_Elf32_Half m_repeat;
00321 __ext_Elf32_Half m_stride;
00322 } __ext_Elf32_Move;
00323
00324 typedef struct {
00325 __ext_Elf64_Lword m_value;
00326 __ext_Elf64_Xword m_info;
00327 __ext_Elf64_Xword m_poffset;
00328 __ext_Elf64_Half m_repeat;
00329 __ext_Elf64_Half m_stride;
00330 } __ext_Elf64_Move;
00331
00332 #endif
00333
00334 #ifdef __cplusplus
00335 }
00336 #endif
00337
00338 #endif