"Fossies" - the Fresh Open Source Software Archive

Member "dmd2/src/druntime/import/core/sys/netbsd/sys/elf_common.d" (20 Nov 2020, 26846 Bytes) of package /linux/misc/dmd.2.094.2.linux.tar.xz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) D source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file.

    1 /**
    2  * D header file for NetBSD.
    3  *
    4  * http://cvsweb.netbsd.org/bsdweb.cgi/~checkout~/src/sys/sys/exec_elf.h
    5  */
    6 module core.sys.netbsd.sys.elf_common;
    7 
    8 version (NetBSD):
    9 extern (C):
   10 pure:
   11 nothrow:
   12 
   13 import core.stdc.stdint;
   14 
   15 struct Elf_Note
   16 {
   17     uint32_t      n_namesz;
   18     uint32_t      n_descsz;
   19     uint32_t      n_type;
   20 }
   21 
   22 struct Elf_GNU_Hash_Header
   23 {
   24     uint32_t      gh_nbuckets;
   25     uint32_t      gh_symndx;
   26     uint32_t      gh_maskwords;
   27     uint32_t      gh_shift2;
   28 }
   29 
   30 enum EI_MAG0 =         0;
   31 enum EI_MAG1 =         1;
   32 enum EI_MAG2 =         2;
   33 enum EI_MAG3 =         3;
   34 enum EI_CLASS =        4;
   35 enum EI_DATA =         5;
   36 enum EI_VERSION =      6;
   37 enum EI_OSABI =        7;
   38 enum EI_ABIVERSION =   8;
   39 enum OLD_EI_BRAND =    8;
   40 enum EI_PAD =          9;
   41 enum EI_NIDENT =       16;
   42 
   43 enum ELFMAG0 =         0x7f;
   44 enum ELFMAG1 =         'E';
   45 enum ELFMAG2 =         'L';
   46 enum ELFMAG3 =         'F';
   47 enum ELFMAG =          "\177ELF";
   48 enum SELFMAG =         4;
   49 
   50 enum EV_NONE =         0;
   51 enum EV_CURRENT =      1;
   52 
   53 enum ELFCLASSNONE =    0;
   54 enum ELFCLASS32 =      1;
   55 enum ELFCLASS64 =      2;
   56 
   57 enum ELFDATANONE =     0;
   58 enum ELFDATA2LSB =     1;
   59 enum ELFDATA2MSB =     2;
   60 
   61 enum ELFOSABI_NONE =           0;
   62 enum ELFOSABI_SYSV =           0;
   63 enum ELFOSABI_HPUX =           1;
   64 enum ELFOSABI_NETBSD =         2;
   65 enum ELFOSABI_LINUX =          3;
   66 enum ELFOSABI_HURD  =          4;
   67 enum ELFOSABI_86OPEN =         5;
   68 enum ELFOSABI_SOLARIS =        6;
   69 enum ELFOSABI_AIX =            7;
   70 enum ELFOSABI_MONTEREY =       7;
   71 enum ELFOSABI_IRIX =           8;
   72 enum ELFOSABI_FREEBSD =        9;
   73 enum ELFOSABI_TRU64 =          10;
   74 enum ELFOSABI_MODESTO =        11;
   75 enum ELFOSABI_OPENBSD =        12;
   76 enum ELFOSABI_OPENVMS =        13;
   77 enum ELFOSABI_NSK =            14;
   78 enum ELFOSABI_AROS =           15;
   79 enum ELFOSABI_ARM =            97;
   80 enum ELFOSABI_STANDALONE =     255;
   81 enum ELFOSABI_DRAGONFLYBSD =   ELFOSABI_NONE;
   82 
   83 extern (D)
   84 {
   85     auto IS_ELF(T)(T ehdr) { return ehdr.e_ident[EI_MAG0] == ELFMAG0 &&
   86                                     ehdr.e_ident[EI_MAG1] == ELFMAG1 &&
   87                                     ehdr.e_ident[EI_MAG2] == ELFMAG2 &&
   88                                     ehdr.e_ident[EI_MAG3] == ELFMAG3; }
   89 }
   90 
   91 enum ET_NONE =         0;
   92 enum ET_REL =          1;
   93 enum ET_EXEC =         2;
   94 enum ET_DYN =          3;
   95 enum ET_CORE =         4;
   96 enum ET_LOOS =         0xfe00;
   97 enum ET_HIOS =         0xfeff;
   98 enum ET_LOPROC =       0xff00;
   99 enum ET_HIPROC =       0xffff;
  100 
  101 enum EM_NONE =          0;
  102 enum EM_M32 =           1;
  103 enum EM_SPARC =         2;
  104 enum EM_386 =           3;
  105 enum EM_68K =           4;
  106 enum EM_88K =           5;
  107 enum EM_860 =           7;
  108 enum EM_MIPS =          8;
  109 enum EM_S370 =          9;
  110 enum EM_MIPS_RS3_LE =  10;
  111 enum EM_PARISC =       15;
  112 enum EM_VPP500 =       17;
  113 enum EM_SPARC32PLUS =  18;
  114 enum EM_960 =          19;
  115 enum EM_PPC =          20;
  116 enum EM_PPC64 =        21;
  117 enum EM_S390 =         22;
  118 enum EM_V800 =         36;
  119 enum EM_FR20 =         37;
  120 enum EM_RH32 =         38;
  121 enum EM_RCE =          39;
  122 enum EM_ARM =          40;
  123 enum EM_SH =           42;
  124 enum EM_SPARCV9 =      43;
  125 enum EM_TRICORE =      44;
  126 enum EM_ARC =          45;
  127 enum EM_H8_300 =       46;
  128 enum EM_H8_300H =      47;
  129 enum EM_H8S =          48;
  130 enum EM_H8_500 =       49;
  131 enum EM_IA_64 =        50;
  132 enum EM_MIPS_X =       51;
  133 enum EM_COLDFIRE =     52;
  134 enum EM_68HC12 =       53;
  135 enum EM_MMA =          54;
  136 enum EM_PCP =          55;
  137 enum EM_NCPU =         56;
  138 enum EM_NDR1 =         57;
  139 enum EM_STARCORE =     58;
  140 enum EM_ME16 =         59;
  141 enum EM_ST100 =        60;
  142 enum EM_TINYJ =        61;
  143 enum EM_X86_64 =       62;
  144 enum EM_AMD64 =        62;
  145 enum EM_PDSP =         63;
  146 enum EM_FX66 =         66;
  147 enum EM_ST9PLUS =      67;
  148 enum EM_ST7 =          68;
  149 enum EM_68HC16 =       69;
  150 enum EM_68HC11 =       70;
  151 enum EM_68HC08 =       71;
  152 enum EM_68HC05 =       72;
  153 enum EM_SVX =          73;
  154 enum EM_ST19 =         74;
  155 enum EM_VAX =          75;
  156 enum EM_CRIS =         76;
  157 enum EM_JAVELIN =      77;
  158 enum EM_FIREPATH =     78;
  159 enum EM_ZSP =          79;
  160 enum EM_MMIX =         80;
  161 enum EM_HUANY =        81;
  162 enum EM_PRISM =        82;
  163 enum EM_AVR =          83;
  164 enum EM_FR30 =         84;
  165 enum EM_D10V =         85;
  166 enum EM_D30V =         86;
  167 enum EM_V850 =         87;
  168 enum EM_M32R =         88;
  169 enum EM_MN10300 =      89;
  170 enum EM_MN10200 =      90;
  171 enum EM_PJ =           91;
  172 enum EM_OPENRISC =     92;
  173 enum EM_ARC_A5 =       93;
  174 enum EM_XTENSA =       94;
  175 enum EM_VIDEOCORE =    95;
  176 enum EM_TMM_GPP =      96;
  177 enum EM_NS32K =        97;
  178 enum EM_TPC =          98;
  179 enum EM_SNP1K =        99;
  180 enum EM_ST200 =       100;
  181 enum EM_IP2K =        101;
  182 enum EM_MAX =         102;
  183 enum EM_CR =          103;
  184 enum EM_F2MC16 =      104;
  185 enum EM_MSP430 =      105;
  186 enum EM_BLACKFIN =    106;
  187 enum EM_SE_C33 =      107;
  188 enum EM_SEP =         108;
  189 enum EM_ARCA =        109;
  190 enum EM_UNICORE =     110;
  191 enum EM_AARCH64 =     183;     /* AArch64 64-bit ARM microprocessor */
  192 
  193 /* Unofficial machine types follow */
  194 enum EM_AVR32  =       6317;    /* used by NetBSD/avr32 */
  195 enum EM_ALPHA_EXP  =  36902;   /* used by NetBSD/alpha; obsolete */
  196 
  197 enum EM_486 =           6;
  198 enum EM_MIPS_RS4_BE =  10;
  199 enum EM_ALPHA_STD =    41;
  200 enum EM_ALPHA =    0x9026;
  201 
  202 enum SHN_UNDEF =       0;
  203 enum SHN_LORESERVE =   0xff00;
  204 enum SHN_LOPROC =      0xff00;
  205 enum SHN_HIPROC =      0xff1f;
  206 enum SHN_LOOS =        0xff20;
  207 enum SHN_HIOS =        0xff3f;
  208 enum SHN_ABS =         0xfff1;
  209 enum SHN_COMMON =      0xfff2;
  210 enum SHN_XINDEX =      0xffff;
  211 enum SHN_HIRESERVE =   0xffff;
  212 
  213 enum SHT_NULL =          0;
  214 enum SHT_PROGBITS =      1;
  215 enum SHT_SYMTAB =        2;
  216 enum SHT_STRTAB =        3;
  217 enum SHT_RELA =          4;
  218 enum SHT_HASH =          5;
  219 enum SHT_DYNAMIC =       6;
  220 enum SHT_NOTE =          7;
  221 enum SHT_NOBITS =        8;
  222 enum SHT_REL =           9;
  223 enum SHT_SHLIB =         10;
  224 enum SHT_DYNSYM =        11;
  225 enum SHT_INIT_ARRAY =    14;
  226 enum SHT_FINI_ARRAY =    15;
  227 enum SHT_PREINIT_ARRAY = 16;
  228 enum SHT_GROUP =         17;
  229 enum SHT_SYMTAB_SHNDX =  18;
  230 enum SHT_LOOS =          0x60000000;
  231 enum SHT_LOSUNW =        0x6ffffff4;
  232 enum SHT_SUNW_dof =      0x6ffffff4;
  233 enum SHT_SUNW_cap =      0x6ffffff5;
  234 enum SHT_SUNW_SIGNATURE = 0x6ffffff6;
  235 enum SHT_GNU_HASH =      0x6ffffff6;
  236 enum SHT_SUNW_ANNOTATE = 0x6ffffff7;
  237 enum SHT_SUNW_DEBUGSTR = 0x6ffffff8;
  238 enum SHT_SUNW_DEBUG =    0x6ffffff9;
  239 enum SHT_SUNW_move =     0x6ffffffa;
  240 enum SHT_SUNW_COMDAT =   0x6ffffffb;
  241 enum SHT_SUNW_syminfo =  0x6ffffffc;
  242 enum SHT_SUNW_verdef =   0x6ffffffd;
  243 enum SHT_GNU_verdef =    0x6ffffffd;
  244 enum SHT_SUNW_verneed =  0x6ffffffe;
  245 enum SHT_GNU_verneed =   0x6ffffffe;
  246 enum SHT_SUNW_versym =   0x6fffffff;
  247 enum SHT_GNU_versym =    0x6fffffff;
  248 enum SHT_HISUNW =        0x6fffffff;
  249 enum SHT_HIOS =          0x6fffffff;
  250 enum SHT_LOPROC =        0x70000000;
  251 enum SHT_AMD64_UNWIND =  0x70000001;
  252 enum SHT_ARM_EXIDX =     0x70000001;
  253 enum SHT_ARM_PREEMPTMAP = 0x70000002;
  254 enum SHT_ARM_ATTRIBUTES = 0x70000003;
  255 enum SHT_ARM_DEBUGOVERLAY = 0x70000004;
  256 enum SHT_ARM_OVERLAYSECTION = 0x70000005;
  257 enum SHT_MIPS_REGINFO =  0x70000006;
  258 enum SHT_MIPS_OPTIONS =  0x7000000d;
  259 enum SHT_MIPS_DWARF =    0x7000001e;
  260 enum SHT_HIPROC =        0x7fffffff;
  261 enum SHT_LOUSER =        0x80000000;
  262 enum SHT_HIUSER =        0x8fffffff;
  263 
  264 enum SHF_WRITE =            (1 << 0);
  265 enum SHF_ALLOC =            (1 << 1);
  266 enum SHF_EXECINSTR =        (1 << 2);
  267 enum SHF_MERGE =            (1 << 4);
  268 enum SHF_STRINGS =          (1 << 5);
  269 enum SHF_INFO_LINK =        (1 << 6);
  270 enum SHF_LINK_ORDER =       (1 << 7);
  271 enum SHF_OS_NONCONFORMING = (1 << 8);
  272 enum SHF_GROUP =            (1 << 9);
  273 enum SHF_TLS =              (1 << 10);
  274 enum SHF_MASKOS =           0x0ff00000;
  275 enum SHF_MASKPROC =         0xf0000000;
  276 
  277 enum PT_NULL =         0;
  278 enum PT_LOAD =         1;
  279 enum PT_DYNAMIC =      2;
  280 enum PT_INTERP =       3;
  281 enum PT_NOTE =         4;
  282 enum PT_SHLIB =        5;
  283 enum PT_PHDR =         6;
  284 enum PT_TLS =          7;
  285 enum PT_LOOS =         0x60000000;
  286 enum PT_SUNW_UNWIND =  0x6464e550;
  287 enum PT_GNU_EH_FRAME = 0x6474e550;
  288 enum PT_GNU_STACK =    0x6474e551;
  289 enum PT_GNU_RELRO =    0x6474e552;
  290 enum PT_LOSUNW =       0x6ffffffa;
  291 enum PT_SUNWBSS =      0x6ffffffa;
  292 enum PT_SUNWSTACK =    0x6ffffffb;
  293 enum PT_SUNWDTRACE =   0x6ffffffc;
  294 enum PT_SUNWCAP =      0x6ffffffd;
  295 enum PT_HISUNW =       0x6fffffff;
  296 enum PT_HIOS =         0x6fffffff;
  297 enum PT_LOPROC =       0x70000000;
  298 enum PT_HIPROC =       0x7fffffff;
  299 
  300 enum PF_X =            (1 << 0);
  301 enum PF_W =            (1 << 1);
  302 enum PF_R =            (1 << 2);
  303 enum PF_MASKOS =       0x0ff00000;
  304 enum PF_MASKPROC =     0xf0000000;
  305 
  306 enum PN_XNUM =         0xffff;
  307 
  308 enum DT_NULL =         0;
  309 enum DT_NEEDED =       1;
  310 enum DT_PLTRELSZ =     2;
  311 enum DT_PLTGOT =       3;
  312 enum DT_HASH =         4;
  313 enum DT_STRTAB =       5;
  314 enum DT_SYMTAB =       6;
  315 enum DT_RELA =         7;
  316 enum DT_RELASZ =       8;
  317 enum DT_RELAENT =      9;
  318 enum DT_STRSZ =        10;
  319 enum DT_SYMENT =       11;
  320 enum DT_INIT =         12;
  321 enum DT_FINI =         13;
  322 enum DT_SONAME =       14;
  323 enum DT_RPATH =        15;
  324 enum DT_SYMBOLIC =     16;
  325 enum DT_REL =          17;
  326 enum DT_RELSZ =        18;
  327 enum DT_RELENT =       19;
  328 enum DT_PLTREL =       20;
  329 enum DT_DEBUG =        21;
  330 enum DT_TEXTREL =      22;
  331 enum DT_JMPREL =       23;
  332 enum DT_BIND_NOW =     24;
  333 enum DT_INIT_ARRAY =   25;
  334 enum DT_FINI_ARRAY =   26;
  335 enum DT_INIT_ARRAYSZ = 27;
  336 enum DT_FINI_ARRAYSZ = 28;
  337 enum DT_RUNPATH =      29;
  338 enum DT_FLAGS =        30;
  339 enum DT_ENCODING =     32;
  340 enum DT_PREINIT_ARRAY = 32;
  341 enum DT_PREINIT_ARRAYSZ = 33;
  342 enum DT_MAXPOSTAGS =   34;
  343 enum DT_LOOS =         0x6000000d;
  344 enum DT_SUNW_AUXILIARY = 0x6000000d;
  345 enum DT_SUNW_RTLDINF = 0x6000000e;
  346 enum DT_SUNW_FILTER =  0x6000000f;
  347 enum DT_SUNW_CAP =     0x60000010;
  348 enum DT_HIOS =         0x6ffff000;
  349 enum DT_VALRNGLO =     0x6ffffd00;
  350 enum DT_CHECKSUM =     0x6ffffdf8;
  351 enum DT_PLTPADSZ =     0x6ffffdf9;
  352 enum DT_MOVEENT =      0x6ffffdfa;
  353 enum DT_MOVESZ =       0x6ffffdfb;
  354 enum DT_FEATURE_1 =    0x6ffffdfc;
  355 enum DT_POSFLAG_1 =    0x6ffffdfd;
  356 enum DT_SYMINSZ =      0x6ffffdfe;
  357 enum DT_SYMINENT =     0x6ffffdff;
  358 enum DT_VALRNGHI =     0x6ffffdff;
  359 enum DT_ADDRRNGLO =    0x6ffffe00;
  360 enum DT_GNU_HASH =     0x6ffffef5;
  361 enum DT_CONFIG =       0x6ffffefa;
  362 enum DT_DEPAUDIT =     0x6ffffefb;
  363 enum DT_AUDIT =        0x6ffffefc;
  364 enum DT_PLTPAD =       0x6ffffefd;
  365 enum DT_MOVETAB =      0x6ffffefe;
  366 enum DT_SYMINFO =      0x6ffffeff;
  367 enum DT_ADDRRNGHI =    0x6ffffeff;
  368 enum DT_VERSYM =       0x6ffffff0;
  369 enum DT_RELACOUNT =    0x6ffffff9;
  370 enum DT_RELCOUNT =     0x6ffffffa;
  371 enum DT_FLAGS_1 =      0x6ffffffb;
  372 enum DT_VERDEF =       0x6ffffffc;
  373 enum DT_VERDEFNUM =    0x6ffffffd;
  374 enum DT_VERNEED =      0x6ffffffe;
  375 enum DT_VERNEEDNUM =   0x6fffffff;
  376 enum DT_LOPROC =       0x70000000;
  377 enum DT_DEPRECATED_SPARC_REGISTER = 0x7000001;
  378 enum DT_AUXILIARY =    0x7ffffffd;
  379 enum DT_USED =         0x7ffffffe;
  380 enum DT_FILTER =       0x7fffffff;
  381 enum DT_HIPROC =       0x7fffffff;
  382 
  383 enum DF_ORIGIN =       0x00000001;
  384 enum DF_SYMBOLIC =     0x00000002;
  385 enum DF_TEXTREL =      0x00000004;
  386 enum DF_BIND_NOW =     0x00000008;
  387 enum DF_STATIC_TLS =   0x00000010;
  388 
  389 enum DF_1_BIND_NOW =   0x00000001;
  390 enum DF_1_GLOBAL =     0x00000002;
  391 enum DF_1_NODELETE =   0x00000008;
  392 enum DF_1_LOADFLTR =   0x00000010;
  393 enum DF_1_NOOPEN =     0x00000040;
  394 enum DF_1_NODEFLIB =   0x00000800;
  395 
  396 enum NT_PRSTATUS =     1;
  397 enum NT_FPREGSET =     2;
  398 enum NT_PRPSINFO =     3;
  399 enum NT_THRMISC =      7;
  400 enum NT_PROCSTAT_PROC = 8;
  401 enum NT_PROCSTAT_FILES = 9;
  402 enum NT_PROCSTAT_VMMAP = 10;
  403 enum NT_PROCSTAT_GROUPS = 11;
  404 enum NT_PROCSTAT_UMASK = 12;
  405 enum NT_PROCSTAT_RLIMIT = 13;
  406 enum NT_PROCSTAT_OSREL = 14;
  407 enum NT_PROCSTAT_PSSTRINGS = 15;
  408 enum NT_PROCSTAT_AUXV = 16;
  409 
  410 enum STB_LOCAL =       0;
  411 enum STB_GLOBAL =      1;
  412 enum STB_WEAK =        2;
  413 enum STB_NUM =         3;
  414 enum STB_LOOS =        10;
  415 enum STB_HIOS =        12;
  416 enum STB_LOPROC =      13;
  417 enum STB_HIPROC =      15;
  418 
  419 enum STT_NOTYPE =      0;
  420 enum STT_OBJECT =      1;
  421 enum STT_FUNC =        2;
  422 enum STT_SECTION =     3;
  423 enum STT_FILE =        4;
  424 enum STT_COMMON =      5;
  425 enum STT_TLS =         6;
  426 enum STT_NUM =         7;
  427 enum STT_LOOS =        10;
  428 enum STT_GNU_IFUNC =   10;
  429 enum STT_HIOS =        12;
  430 enum STT_LOPROC =      13;
  431 enum STT_HIPROC =      15;
  432 
  433 enum STV_DEFAULT =     0;
  434 enum STV_INTERNAL =    1;
  435 enum STV_HIDDEN =      2;
  436 enum STV_PROTECTED =   3;
  437 enum STV_EXPORTED =    4;
  438 enum STV_SINGLETON =   5;
  439 enum STV_ELIMINATE =   6;
  440 
  441 enum STN_UNDEF =       0;
  442 
  443 enum VER_DEF_CURRENT = 1;
  444 alias VER_NDX VER_DEF_IDX;
  445 
  446 enum VER_FLG_BASE =    0x1;
  447 enum VER_FLG_WEAK =    0x2;
  448 
  449 enum VER_NEED_CURRENT = 1;
  450 enum VER_NEED_WEAK =    32768;
  451 enum VER_NEED_HIDDEN = VER_NDX_HIDDEN;
  452 alias VER_NDX VER_NEED_IDX;
  453 
  454 enum VER_NDX_LOCAL =           0;
  455 enum VER_NDX_GLOBAL =          1;
  456 enum VER_NDX_GIVEN =           2;
  457 
  458 enum VER_NDX_HIDDEN =      32768;
  459 extern (D)
  460 {
  461     auto VER_NDX(V)(V v) { return v & ~(1u << 15); }
  462 }
  463 
  464 enum CA_SUNW_NULL =    0;
  465 enum CA_SUNW_HW_1 =    1;
  466 enum CA_SUNW_SF_1 =    2;
  467 
  468 enum SYMINFO_FLG_DIRECT =      0x0001;
  469 enum SYMINFO_FLG_PASSTHRU =    0x0002;
  470 enum SYMINFO_FLG_COPY =        0x0004;
  471 enum SYMINFO_FLG_LAZYLOAD =    0x0008;
  472 enum SYMINFO_FLG_DIRECTBIND =  0x0010;
  473 enum SYMINFO_FLG_NOEXTDIRECT = 0x0020;
  474 enum SYMINFO_FLG_FILTER =      0x0002;
  475 enum SYMINFO_FLG_AUXILIARY =   0x0040;
  476 
  477 enum SYMINFO_BT_SELF =         0xffff;
  478 enum SYMINFO_BT_PARENT =       0xfffe;
  479 enum SYMINFO_BT_NONE =         0xfffd;
  480 enum SYMINFO_BT_EXTERN =       0xfffc;
  481 enum SYMINFO_BT_LOWRESERVE =   0xff00;
  482 
  483 enum SYMINFO_NONE =            0;
  484 enum SYMINFO_CURRENT =         1;
  485 enum SYMINFO_NUM =             2;
  486 
  487 enum R_386_NONE =               0;
  488 enum R_386_32 =                 1;
  489 enum R_386_PC32 =               2;
  490 enum R_386_GOT32 =              3;
  491 enum R_386_PLT32 =              4;
  492 enum R_386_COPY =               5;
  493 enum R_386_GLOB_DAT =           6;
  494 enum R_386_JMP_SLOT =           7;
  495 enum R_386_RELATIVE =           8;
  496 enum R_386_GOTOFF =             9;
  497 enum R_386_GOTPC =              10;
  498 enum R_386_TLS_TPOFF =          14;
  499 enum R_386_TLS_IE =             15;
  500 enum R_386_TLS_GOTIE =          16;
  501 enum R_386_TLS_LE =             17;
  502 enum R_386_TLS_GD =             18;
  503 enum R_386_TLS_LDM =            19;
  504 enum R_386_TLS_GD_32 =          24;
  505 enum R_386_TLS_GD_PUSH =        25;
  506 enum R_386_TLS_GD_CALL =        26;
  507 enum R_386_TLS_GD_POP =         27;
  508 enum R_386_TLS_LDM_32 =         28;
  509 enum R_386_TLS_LDM_PUSH =       29;
  510 enum R_386_TLS_LDM_CALL =       30;
  511 enum R_386_TLS_LDM_POP =        31;
  512 enum R_386_TLS_LDO_32 =         32;
  513 enum R_386_TLS_IE_32 =          33;
  514 enum R_386_TLS_LE_32 =          34;
  515 enum R_386_TLS_DTPMOD32 =       35;
  516 enum R_386_TLS_DTPOFF32 =       36;
  517 enum R_386_TLS_TPOFF32 =        37;
  518 enum R_386_IRELATIVE =          42;
  519 
  520 enum R_ARM_NONE =               0;
  521 enum R_ARM_PC24 =               1;
  522 enum R_ARM_ABS32 =              2;
  523 enum R_ARM_REL32 =              3;
  524 enum R_ARM_PC13 =               4;
  525 enum R_ARM_ABS16 =              5;
  526 enum R_ARM_ABS12 =              6;
  527 enum R_ARM_THM_ABS5 =           7;
  528 enum R_ARM_ABS8 =               8;
  529 enum R_ARM_SBREL32 =            9;
  530 enum R_ARM_THM_PC22 =           10;
  531 enum R_ARM_THM_PC8 =            11;
  532 enum R_ARM_AMP_VCALL9 =         12;
  533 enum R_ARM_SWI24 =              13;
  534 enum R_ARM_THM_SWI8 =           14;
  535 enum R_ARM_XPC25 =              15;
  536 enum R_ARM_THM_XPC22 =          16;
  537 enum R_ARM_TLS_DTPMOD32 =       17;
  538 enum R_ARM_TLS_DTPOFF32 =       18;
  539 enum R_ARM_TLS_TPOFF32 =        19;
  540 enum R_ARM_COPY =               20;
  541 enum R_ARM_GLOB_DAT =           21;
  542 enum R_ARM_JUMP_SLOT =          22;
  543 enum R_ARM_RELATIVE =           23;
  544 enum R_ARM_GOTOFF =             24;
  545 enum R_ARM_GOTPC =              25;
  546 enum R_ARM_GOT32 =              26;
  547 enum R_ARM_PLT32 =              27;
  548 enum R_ARM_GNU_VTENTRY =        100;
  549 enum R_ARM_GNU_VTINHERIT =      101;
  550 enum R_ARM_RSBREL32 =           250;
  551 enum R_ARM_THM_RPC22 =          251;
  552 enum R_ARM_RREL32 =             252;
  553 enum R_ARM_RABS32 =             253;
  554 enum R_ARM_RPC24 =              254;
  555 enum R_ARM_RBASE =              255;
  556 
  557 enum R_IA_64_NONE =             0;
  558 enum R_IA_64_IMM14 =            0x21;
  559 enum R_IA_64_IMM22 =            0x22;
  560 enum R_IA_64_IMM64 =            0x23;
  561 enum R_IA_64_DIR32MSB =         0x24;
  562 enum R_IA_64_DIR32LSB =         0x25;
  563 enum R_IA_64_DIR64MSB =         0x26;
  564 enum R_IA_64_DIR64LSB =         0x27;
  565 enum R_IA_64_GPREL22 =          0x2a;
  566 enum R_IA_64_GPREL64I =         0x2b;
  567 enum R_IA_64_GPREL32MSB =       0x2c;
  568 enum R_IA_64_GPREL32LSB =       0x2d;
  569 enum R_IA_64_GPREL64MSB =       0x2e;
  570 enum R_IA_64_GPREL64LSB =       0x2f;
  571 enum R_IA_64_LTOFF22 =          0x32;
  572 enum R_IA_64_LTOFF64I =         0x33;
  573 enum R_IA_64_PLTOFF22 =         0x3a;
  574 enum R_IA_64_PLTOFF64I =        0x3b;
  575 enum R_IA_64_PLTOFF64MSB =      0x3e;
  576 enum R_IA_64_PLTOFF64LSB =      0x3f;
  577 enum R_IA_64_FPTR64I =          0x43;
  578 enum R_IA_64_FPTR32MSB =        0x44;
  579 enum R_IA_64_FPTR32LSB =        0x45;
  580 enum R_IA_64_FPTR64MSB =        0x46;
  581 enum R_IA_64_FPTR64LSB =        0x47;
  582 enum R_IA_64_PCREL60B =         0x48;
  583 enum R_IA_64_PCREL21B =         0x49;
  584 enum R_IA_64_PCREL21M =         0x4a;
  585 enum R_IA_64_PCREL21F =         0x4b;
  586 enum R_IA_64_PCREL32MSB =       0x4c;
  587 enum R_IA_64_PCREL32LSB =       0x4d;
  588 enum R_IA_64_PCREL64MSB =       0x4e;
  589 enum R_IA_64_PCREL64LSB =       0x4f;
  590 enum R_IA_64_LTOFF_FPTR22 =     0x52;
  591 enum R_IA_64_LTOFF_FPTR64I =    0x53;
  592 enum R_IA_64_LTOFF_FPTR32MSB =  0x54;
  593 enum R_IA_64_LTOFF_FPTR32LSB =  0x55;
  594 enum R_IA_64_LTOFF_FPTR64MSB =  0x56;
  595 enum R_IA_64_LTOFF_FPTR64LSB =  0x57;
  596 enum R_IA_64_SEGREL32MSB =      0x5c;
  597 enum R_IA_64_SEGREL32LSB =      0x5d;
  598 enum R_IA_64_SEGREL64MSB =      0x5e;
  599 enum R_IA_64_SEGREL64LSB =      0x5f;
  600 enum R_IA_64_SECREL32MSB =      0x64;
  601 enum R_IA_64_SECREL32LSB =      0x65;
  602 enum R_IA_64_SECREL64MSB =      0x66;
  603 enum R_IA_64_SECREL64LSB =      0x67;
  604 enum R_IA_64_REL32MSB =         0x6c;
  605 enum R_IA_64_REL32LSB =         0x6d;
  606 enum R_IA_64_REL64MSB =         0x6e;
  607 enum R_IA_64_REL64LSB =         0x6f;
  608 enum R_IA_64_LTV32MSB =         0x74;
  609 enum R_IA_64_LTV32LSB =         0x75;
  610 enum R_IA_64_LTV64MSB =         0x76;
  611 enum R_IA_64_LTV64LSB =         0x77;
  612 enum R_IA_64_PCREL21BI =        0x79;
  613 enum R_IA_64_PCREL22 =          0x7a;
  614 enum R_IA_64_PCREL64I =         0x7b;
  615 enum R_IA_64_IPLTMSB =          0x80;
  616 enum R_IA_64_IPLTLSB =          0x81;
  617 enum R_IA_64_SUB =              0x85;
  618 enum R_IA_64_LTOFF22X =         0x86;
  619 enum R_IA_64_LDXMOV =           0x87;
  620 enum R_IA_64_TPREL14 =          0x91;
  621 enum R_IA_64_TPREL22 =          0x92;
  622 enum R_IA_64_TPREL64I =         0x93;
  623 enum R_IA_64_TPREL64MSB =       0x96;
  624 enum R_IA_64_TPREL64LSB =       0x97;
  625 enum R_IA_64_LTOFF_TPREL22 =    0x9a;
  626 enum R_IA_64_DTPMOD64MSB =      0xa6;
  627 enum R_IA_64_DTPMOD64LSB =      0xa7;
  628 enum R_IA_64_LTOFF_DTPMOD22 =   0xaa;
  629 enum R_IA_64_DTPREL14 =         0xb1;
  630 enum R_IA_64_DTPREL22 =         0xb2;
  631 enum R_IA_64_DTPREL64I =        0xb3;
  632 enum R_IA_64_DTPREL32MSB =      0xb4;
  633 enum R_IA_64_DTPREL32LSB =      0xb5;
  634 enum R_IA_64_DTPREL64MSB =      0xb6;
  635 enum R_IA_64_DTPREL64LSB =      0xb7;
  636 enum R_IA_64_LTOFF_DTPREL22 =   0xba;
  637 
  638 enum R_MIPS_NONE =              0;
  639 enum R_MIPS_16 =                1;
  640 enum R_MIPS_32 =                2;
  641 enum R_MIPS_REL32 =             3;
  642 enum R_MIPS_26 =                4;
  643 enum R_MIPS_HI16 =              5;
  644 enum R_MIPS_LO16 =              6;
  645 enum R_MIPS_GPREL16 =           7;
  646 enum R_MIPS_LITERAL =           8;
  647 enum R_MIPS_GOT16 =             9;
  648 enum R_MIPS_PC16 =              10;
  649 enum R_MIPS_CALL16 =            11;
  650 enum R_MIPS_GPREL32 =           12;
  651 enum R_MIPS_GOTHI16 =           21;
  652 enum R_MIPS_GOTLO16 =           22;
  653 enum R_MIPS_CALLHI16 =          30;
  654 enum R_MIPS_CALLLO16 =          31;
  655 
  656 enum R_PPC_NONE =               0;
  657 enum R_PPC_ADDR32 =             1;
  658 enum R_PPC_ADDR24 =             2;
  659 enum R_PPC_ADDR16 =             3;
  660 enum R_PPC_ADDR16_LO =          4;
  661 enum R_PPC_ADDR16_HI =          5;
  662 enum R_PPC_ADDR16_HA =          6;
  663 enum R_PPC_ADDR14 =             7;
  664 enum R_PPC_ADDR14_BRTAKEN =     8;
  665 enum R_PPC_ADDR14_BRNTAKEN =    9;
  666 enum R_PPC_REL24 =              10;
  667 enum R_PPC_REL14 =              11;
  668 enum R_PPC_REL14_BRTAKEN =      12;
  669 enum R_PPC_REL14_BRNTAKEN =     13;
  670 enum R_PPC_GOT16 =              14;
  671 enum R_PPC_GOT16_LO =           15;
  672 enum R_PPC_GOT16_HI =           16;
  673 enum R_PPC_GOT16_HA =           17;
  674 enum R_PPC_PLTREL24 =           18;
  675 enum R_PPC_COPY =               19;
  676 enum R_PPC_GLOB_DAT =           20;
  677 enum R_PPC_JMP_SLOT =           21;
  678 enum R_PPC_RELATIVE =           22;
  679 enum R_PPC_LOCAL24PC =          23;
  680 enum R_PPC_UADDR32 =            24;
  681 enum R_PPC_UADDR16 =            25;
  682 enum R_PPC_REL32 =              26;
  683 enum R_PPC_PLT32 =              27;
  684 enum R_PPC_PLTREL32 =           28;
  685 enum R_PPC_PLT16_LO =           29;
  686 enum R_PPC_PLT16_HI =           30;
  687 enum R_PPC_PLT16_HA =           31;
  688 enum R_PPC_SDAREL16 =           32;
  689 enum R_PPC_SECTOFF =            33;
  690 enum R_PPC_SECTOFF_LO =         34;
  691 enum R_PPC_SECTOFF_HI =         35;
  692 enum R_PPC_SECTOFF_HA =         36;
  693 
  694 enum R_PPC64_ADDR64 =           38;
  695 enum R_PPC64_ADDR16_HIGHER =    39;
  696 enum R_PPC64_ADDR16_HIGHERA =   40;
  697 enum R_PPC64_ADDR16_HIGHEST =   41;
  698 enum R_PPC64_ADDR16_HIGHESTA =  42;
  699 enum R_PPC64_UADDR64 =          43;
  700 enum R_PPC64_REL64 =            44;
  701 enum R_PPC64_PLT64 =            45;
  702 enum R_PPC64_PLTREL64 =         46;
  703 enum R_PPC64_TOC16 =            47;
  704 enum R_PPC64_TOC16_LO =         48;
  705 enum R_PPC64_TOC16_HI =         49;
  706 enum R_PPC64_TOC16_HA =         50;
  707 enum R_PPC64_TOC =              51;
  708 enum R_PPC64_DTPMOD64 =         68;
  709 enum R_PPC64_TPREL64 =          73;
  710 enum R_PPC64_DTPREL64 =         78;
  711 
  712 enum R_PPC_TLS =                67;
  713 enum R_PPC_DTPMOD32 =           68;
  714 enum R_PPC_TPREL16 =            69;
  715 enum R_PPC_TPREL16_LO =         70;
  716 enum R_PPC_TPREL16_HI =         71;
  717 enum R_PPC_TPREL16_HA =         72;
  718 enum R_PPC_TPREL32 =            73;
  719 enum R_PPC_DTPREL16 =           74;
  720 enum R_PPC_DTPREL16_LO =        75;
  721 enum R_PPC_DTPREL16_HI =        76;
  722 enum R_PPC_DTPREL16_HA =        77;
  723 enum R_PPC_DTPREL32 =           78;
  724 enum R_PPC_GOT_TLSGD16 =        79;
  725 enum R_PPC_GOT_TLSGD16_LO =     80;
  726 enum R_PPC_GOT_TLSGD16_HI =     81;
  727 enum R_PPC_GOT_TLSGD16_HA =     82;
  728 enum R_PPC_GOT_TLSLD16 =        83;
  729 enum R_PPC_GOT_TLSLD16_LO =     84;
  730 enum R_PPC_GOT_TLSLD16_HI =     85;
  731 enum R_PPC_GOT_TLSLD16_HA =     86;
  732 enum R_PPC_GOT_TPREL16 =        87;
  733 enum R_PPC_GOT_TPREL16_LO =     88;
  734 enum R_PPC_GOT_TPREL16_HI =     89;
  735 enum R_PPC_GOT_TPREL16_HA =     90;
  736 
  737 enum R_PPC_EMB_NADDR32 =        101;
  738 enum R_PPC_EMB_NADDR16 =        102;
  739 enum R_PPC_EMB_NADDR16_LO =     103;
  740 enum R_PPC_EMB_NADDR16_HI =     104;
  741 enum R_PPC_EMB_NADDR16_HA =     105;
  742 enum R_PPC_EMB_SDAI16 =         106;
  743 enum R_PPC_EMB_SDA2I16 =        107;
  744 enum R_PPC_EMB_SDA2REL =        108;
  745 enum R_PPC_EMB_SDA21 =          109;
  746 enum R_PPC_EMB_MRKREF =         110;
  747 enum R_PPC_EMB_RELSEC16 =       111;
  748 enum R_PPC_EMB_RELST_LO =       112;
  749 enum R_PPC_EMB_RELST_HI =       113;
  750 enum R_PPC_EMB_RELST_HA =       114;
  751 enum R_PPC_EMB_BIT_FLD =        115;
  752 enum R_PPC_EMB_RELSDA =         116;
  753 
  754 enum R_SPARC_NONE =             0;
  755 enum R_SPARC_8 =                1;
  756 enum R_SPARC_16 =               2;
  757 enum R_SPARC_32 =               3;
  758 enum R_SPARC_DISP8 =            4;
  759 enum R_SPARC_DISP16 =           5;
  760 enum R_SPARC_DISP32 =           6;
  761 enum R_SPARC_WDISP30 =          7;
  762 enum R_SPARC_WDISP22 =          8;
  763 enum R_SPARC_HI22 =             9;
  764 enum R_SPARC_22 =               10;
  765 enum R_SPARC_13 =               11;
  766 enum R_SPARC_LO10 =             12;
  767 enum R_SPARC_GOT10 =            13;
  768 enum R_SPARC_GOT13 =            14;
  769 enum R_SPARC_GOT22 =            15;
  770 enum R_SPARC_PC10 =             16;
  771 enum R_SPARC_PC22 =             17;
  772 enum R_SPARC_WPLT30 =           18;
  773 enum R_SPARC_COPY =             19;
  774 enum R_SPARC_GLOB_DAT =         20;
  775 enum R_SPARC_JMP_SLOT =         21;
  776 enum R_SPARC_RELATIVE =         22;
  777 enum R_SPARC_UA32 =             23;
  778 enum R_SPARC_PLT32 =            24;
  779 enum R_SPARC_HIPLT22 =          25;
  780 enum R_SPARC_LOPLT10 =          26;
  781 enum R_SPARC_PCPLT32 =          27;
  782 enum R_SPARC_PCPLT22 =          28;
  783 enum R_SPARC_PCPLT10 =          29;
  784 enum R_SPARC_10 =               30;
  785 enum R_SPARC_11 =               31;
  786 enum R_SPARC_64 =               32;
  787 enum R_SPARC_OLO10 =            33;
  788 enum R_SPARC_HH22 =             34;
  789 enum R_SPARC_HM10 =             35;
  790 enum R_SPARC_LM22 =             36;
  791 enum R_SPARC_PC_HH22 =          37;
  792 enum R_SPARC_PC_HM10 =          38;
  793 enum R_SPARC_PC_LM22 =          39;
  794 enum R_SPARC_WDISP16 =          40;
  795 enum R_SPARC_WDISP19 =          41;
  796 enum R_SPARC_GLOB_JMP =         42;
  797 enum R_SPARC_7 =                43;
  798 enum R_SPARC_5 =                44;
  799 enum R_SPARC_6 =                45;
  800 enum R_SPARC_DISP64 =           46;
  801 enum R_SPARC_PLT64 =            47;
  802 enum R_SPARC_HIX22 =            48;
  803 enum R_SPARC_LOX10 =            49;
  804 enum R_SPARC_H44 =              50;
  805 enum R_SPARC_M44 =              51;
  806 enum R_SPARC_L44 =              52;
  807 enum R_SPARC_REGISTER =         53;
  808 enum R_SPARC_UA64 =             54;
  809 enum R_SPARC_UA16 =             55;
  810 enum R_SPARC_TLS_GD_HI22 =      56;
  811 enum R_SPARC_TLS_GD_LO10 =      57;
  812 enum R_SPARC_TLS_GD_ADD =       58;
  813 enum R_SPARC_TLS_GD_CALL =      59;
  814 enum R_SPARC_TLS_LDM_HI22 =     60;
  815 enum R_SPARC_TLS_LDM_LO10 =     61;
  816 enum R_SPARC_TLS_LDM_ADD =      62;
  817 enum R_SPARC_TLS_LDM_CALL =     63;
  818 enum R_SPARC_TLS_LDO_HIX22 =    64;
  819 enum R_SPARC_TLS_LDO_LOX10 =    65;
  820 enum R_SPARC_TLS_LDO_ADD =      66;
  821 enum R_SPARC_TLS_IE_HI22 =      67;
  822 enum R_SPARC_TLS_IE_LO10 =      68;
  823 enum R_SPARC_TLS_IE_LD =        69;
  824 enum R_SPARC_TLS_IE_LDX =       70;
  825 enum R_SPARC_TLS_IE_ADD =       71;
  826 enum R_SPARC_TLS_LE_HIX22 =     72;
  827 enum R_SPARC_TLS_LE_LOX10 =     73;
  828 enum R_SPARC_TLS_DTPMOD32 =     74;
  829 enum R_SPARC_TLS_DTPMOD64 =     75;
  830 enum R_SPARC_TLS_DTPOFF32 =     76;
  831 enum R_SPARC_TLS_DTPOFF64 =     77;
  832 enum R_SPARC_TLS_TPOFF32 =      78;
  833 enum R_SPARC_TLS_TPOFF64 =      79;
  834 
  835 enum R_X86_64_NONE =            0;
  836 enum R_X86_64_64 =              1;
  837 enum R_X86_64_PC32 =            2;
  838 enum R_X86_64_GOT32 =           3;
  839 enum R_X86_64_PLT32 =           4;
  840 enum R_X86_64_COPY =            5;
  841 enum R_X86_64_GLOB_DAT =        6;
  842 enum R_X86_64_JMP_SLOT =        7;
  843 enum R_X86_64_RELATIVE =        8;
  844 enum R_X86_64_GOTPCREL =        9;
  845 enum R_X86_64_32 =              10;
  846 enum R_X86_64_32S =             11;
  847 enum R_X86_64_16 =              12;
  848 enum R_X86_64_PC16 =            13;
  849 enum R_X86_64_8 =               14;
  850 enum R_X86_64_PC8 =             15;
  851 enum R_X86_64_DTPMOD64 =        16;
  852 enum R_X86_64_DTPOFF64 =        17;
  853 enum R_X86_64_TPOFF64 =         18;
  854 enum R_X86_64_TLSGD =           19;
  855 enum R_X86_64_TLSLD =           20;
  856 enum R_X86_64_DTPOFF32 =        21;
  857 enum R_X86_64_GOTTPOFF =        22;
  858 enum R_X86_64_TPOFF32 =         23;
  859 enum R_X86_64_IRELATIVE =       37;