relocs.patch 64 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709
  1. diff -Nur linux-3.13.6.orig/arch/x86/tools/relocs.c linux-3.13.6/arch/x86/tools/relocs.c
  2. --- linux-3.13.6.orig/arch/x86/tools/relocs.c 2014-03-07 07:07:02.000000000 +0100
  3. +++ linux-3.13.6/arch/x86/tools/relocs.c 2014-03-15 19:39:45.000000000 +0100
  4. @@ -126,6 +126,7 @@
  5. if (err) {
  6. regerror(err, &sym_regex_c[i], errbuf, sizeof errbuf);
  7. + printf("foo: %s\n", sym_regex[i]);
  8. die("%s", errbuf);
  9. }
  10. }
  11. diff -Nur linux-3.13.6.orig/arch/x86/tools/relocs.h linux-3.13.6/arch/x86/tools/relocs.h
  12. --- linux-3.13.6.orig/arch/x86/tools/relocs.h 2014-03-07 07:07:02.000000000 +0100
  13. +++ linux-3.13.6/arch/x86/tools/relocs.h 2014-03-15 18:48:40.000000000 +0100
  14. @@ -9,11 +9,19 @@
  15. #include <string.h>
  16. #include <errno.h>
  17. #include <unistd.h>
  18. +#ifdef __linux__
  19. #include <elf.h>
  20. #include <byteswap.h>
  21. #define USE_BSD
  22. #include <endian.h>
  23. +#else
  24. +#include "elf.h"
  25. +#endif
  26. +#ifdef __APPLE__
  27. +#include <pcreposix.h>
  28. +#else
  29. #include <regex.h>
  30. +#endif
  31. #include <tools/le_byteshift.h>
  32. void die(char *fmt, ...);
  33. diff -Nur linux-3.13.6.orig/tools/include/elf.h linux-3.13.6/tools/include/elf.h
  34. --- linux-3.13.6.orig/tools/include/elf.h 1970-01-01 01:00:00.000000000 +0100
  35. +++ linux-3.13.6/tools/include/elf.h 2014-03-15 18:47:36.000000000 +0100
  36. @@ -0,0 +1,2671 @@
  37. +#ifndef _ELF_H
  38. +#define _ELF_H
  39. +
  40. +#ifdef __cplusplus
  41. +extern "C" {
  42. +#endif
  43. +
  44. +#include <stdint.h>
  45. +
  46. +typedef uint16_t Elf32_Half;
  47. +typedef uint16_t Elf64_Half;
  48. +
  49. +typedef uint32_t Elf32_Word;
  50. +typedef int32_t Elf32_Sword;
  51. +typedef uint32_t Elf64_Word;
  52. +typedef int32_t Elf64_Sword;
  53. +
  54. +typedef uint64_t Elf32_Xword;
  55. +typedef int64_t Elf32_Sxword;
  56. +typedef uint64_t Elf64_Xword;
  57. +typedef int64_t Elf64_Sxword;
  58. +
  59. +typedef uint32_t Elf32_Addr;
  60. +typedef uint64_t Elf64_Addr;
  61. +
  62. +typedef uint32_t Elf32_Off;
  63. +typedef uint64_t Elf64_Off;
  64. +
  65. +typedef uint16_t Elf32_Section;
  66. +typedef uint16_t Elf64_Section;
  67. +
  68. +typedef Elf32_Half Elf32_Versym;
  69. +typedef Elf64_Half Elf64_Versym;
  70. +
  71. +#define EI_NIDENT (16)
  72. +
  73. +typedef struct {
  74. + unsigned char e_ident[EI_NIDENT];
  75. + Elf32_Half e_type;
  76. + Elf32_Half e_machine;
  77. + Elf32_Word e_version;
  78. + Elf32_Addr e_entry;
  79. + Elf32_Off e_phoff;
  80. + Elf32_Off e_shoff;
  81. + Elf32_Word e_flags;
  82. + Elf32_Half e_ehsize;
  83. + Elf32_Half e_phentsize;
  84. + Elf32_Half e_phnum;
  85. + Elf32_Half e_shentsize;
  86. + Elf32_Half e_shnum;
  87. + Elf32_Half e_shstrndx;
  88. +} Elf32_Ehdr;
  89. +
  90. +typedef struct {
  91. + unsigned char e_ident[EI_NIDENT];
  92. + Elf64_Half e_type;
  93. + Elf64_Half e_machine;
  94. + Elf64_Word e_version;
  95. + Elf64_Addr e_entry;
  96. + Elf64_Off e_phoff;
  97. + Elf64_Off e_shoff;
  98. + Elf64_Word e_flags;
  99. + Elf64_Half e_ehsize;
  100. + Elf64_Half e_phentsize;
  101. + Elf64_Half e_phnum;
  102. + Elf64_Half e_shentsize;
  103. + Elf64_Half e_shnum;
  104. + Elf64_Half e_shstrndx;
  105. +} Elf64_Ehdr;
  106. +
  107. +#define EI_MAG0 0
  108. +#define ELFMAG0 0x7f
  109. +
  110. +#define EI_MAG1 1
  111. +#define ELFMAG1 'E'
  112. +
  113. +#define EI_MAG2 2
  114. +#define ELFMAG2 'L'
  115. +
  116. +#define EI_MAG3 3
  117. +#define ELFMAG3 'F'
  118. +
  119. +
  120. +#define ELFMAG "\177ELF"
  121. +#define SELFMAG 4
  122. +
  123. +#define EI_CLASS 4
  124. +#define ELFCLASSNONE 0
  125. +#define ELFCLASS32 1
  126. +#define ELFCLASS64 2
  127. +#define ELFCLASSNUM 3
  128. +
  129. +#define EI_DATA 5
  130. +#define ELFDATANONE 0
  131. +#define ELFDATA2LSB 1
  132. +#define ELFDATA2MSB 2
  133. +#define ELFDATANUM 3
  134. +
  135. +#define EI_VERSION 6
  136. +
  137. +
  138. +#define EI_OSABI 7
  139. +#define ELFOSABI_NONE 0
  140. +#define ELFOSABI_SYSV 0
  141. +#define ELFOSABI_HPUX 1
  142. +#define ELFOSABI_NETBSD 2
  143. +#define ELFOSABI_LINUX 3
  144. +#define ELFOSABI_GNU 3
  145. +#define ELFOSABI_SOLARIS 6
  146. +#define ELFOSABI_AIX 7
  147. +#define ELFOSABI_IRIX 8
  148. +#define ELFOSABI_FREEBSD 9
  149. +#define ELFOSABI_TRU64 10
  150. +#define ELFOSABI_MODESTO 11
  151. +#define ELFOSABI_OPENBSD 12
  152. +#define ELFOSABI_ARM 97
  153. +#define ELFOSABI_STANDALONE 255
  154. +
  155. +#define EI_ABIVERSION 8
  156. +
  157. +#define EI_PAD 9
  158. +
  159. +
  160. +
  161. +#define ET_NONE 0
  162. +#define ET_REL 1
  163. +#define ET_EXEC 2
  164. +#define ET_DYN 3
  165. +#define ET_CORE 4
  166. +#define ET_NUM 5
  167. +#define ET_LOOS 0xfe00
  168. +#define ET_HIOS 0xfeff
  169. +#define ET_LOPROC 0xff00
  170. +#define ET_HIPROC 0xffff
  171. +
  172. +
  173. +
  174. +#define EM_NONE 0
  175. +#define EM_M32 1
  176. +#define EM_SPARC 2
  177. +#define EM_386 3
  178. +#define EM_68K 4
  179. +#define EM_88K 5
  180. +#define EM_860 7
  181. +#define EM_MIPS 8
  182. +#define EM_S370 9
  183. +#define EM_MIPS_RS3_LE 10
  184. +
  185. +#define EM_PARISC 15
  186. +#define EM_VPP500 17
  187. +#define EM_SPARC32PLUS 18
  188. +#define EM_960 19
  189. +#define EM_PPC 20
  190. +#define EM_PPC64 21
  191. +#define EM_S390 22
  192. +
  193. +#define EM_V800 36
  194. +#define EM_FR20 37
  195. +#define EM_RH32 38
  196. +#define EM_RCE 39
  197. +#define EM_ARM 40
  198. +#define EM_FAKE_ALPHA 41
  199. +#define EM_SH 42
  200. +#define EM_SPARCV9 43
  201. +#define EM_TRICORE 44
  202. +#define EM_ARC 45
  203. +#define EM_H8_300 46
  204. +#define EM_H8_300H 47
  205. +#define EM_H8S 48
  206. +#define EM_H8_500 49
  207. +#define EM_IA_64 50
  208. +#define EM_MIPS_X 51
  209. +#define EM_COLDFIRE 52
  210. +#define EM_68HC12 53
  211. +#define EM_MMA 54
  212. +#define EM_PCP 55
  213. +#define EM_NCPU 56
  214. +#define EM_NDR1 57
  215. +#define EM_STARCORE 58
  216. +#define EM_ME16 59
  217. +#define EM_ST100 60
  218. +#define EM_TINYJ 61
  219. +#define EM_X86_64 62
  220. +#define EM_PDSP 63
  221. +
  222. +#define EM_FX66 66
  223. +#define EM_ST9PLUS 67
  224. +#define EM_ST7 68
  225. +#define EM_68HC16 69
  226. +#define EM_68HC11 70
  227. +#define EM_68HC08 71
  228. +#define EM_68HC05 72
  229. +#define EM_SVX 73
  230. +#define EM_ST19 74
  231. +#define EM_VAX 75
  232. +#define EM_CRIS 76
  233. +#define EM_JAVELIN 77
  234. +#define EM_FIREPATH 78
  235. +#define EM_ZSP 79
  236. +#define EM_MMIX 80
  237. +#define EM_HUANY 81
  238. +#define EM_PRISM 82
  239. +#define EM_AVR 83
  240. +#define EM_FR30 84
  241. +#define EM_D10V 85
  242. +#define EM_D30V 86
  243. +#define EM_V850 87
  244. +#define EM_M32R 88
  245. +#define EM_MN10300 89
  246. +#define EM_MN10200 90
  247. +#define EM_PJ 91
  248. +#define EM_OPENRISC 92
  249. +#define EM_ARC_A5 93
  250. +#define EM_XTENSA 94
  251. +#define EM_AARCH64 183
  252. +#define EM_TILEPRO 188
  253. +#define EM_MICROBLAZE 189
  254. +#define EM_TILEGX 191
  255. +#define EM_NUM 192
  256. +#define EM_ALPHA 0x9026
  257. +
  258. +#define EV_NONE 0
  259. +#define EV_CURRENT 1
  260. +#define EV_NUM 2
  261. +
  262. +typedef struct {
  263. + Elf32_Word sh_name;
  264. + Elf32_Word sh_type;
  265. + Elf32_Word sh_flags;
  266. + Elf32_Addr sh_addr;
  267. + Elf32_Off sh_offset;
  268. + Elf32_Word sh_size;
  269. + Elf32_Word sh_link;
  270. + Elf32_Word sh_info;
  271. + Elf32_Word sh_addralign;
  272. + Elf32_Word sh_entsize;
  273. +} Elf32_Shdr;
  274. +
  275. +typedef struct {
  276. + Elf64_Word sh_name;
  277. + Elf64_Word sh_type;
  278. + Elf64_Xword sh_flags;
  279. + Elf64_Addr sh_addr;
  280. + Elf64_Off sh_offset;
  281. + Elf64_Xword sh_size;
  282. + Elf64_Word sh_link;
  283. + Elf64_Word sh_info;
  284. + Elf64_Xword sh_addralign;
  285. + Elf64_Xword sh_entsize;
  286. +} Elf64_Shdr;
  287. +
  288. +
  289. +
  290. +#define SHN_UNDEF 0
  291. +#define SHN_LORESERVE 0xff00
  292. +#define SHN_LOPROC 0xff00
  293. +#define SHN_BEFORE 0xff00
  294. +
  295. +#define SHN_AFTER 0xff01
  296. +
  297. +#define SHN_HIPROC 0xff1f
  298. +#define SHN_LOOS 0xff20
  299. +#define SHN_HIOS 0xff3f
  300. +#define SHN_ABS 0xfff1
  301. +#define SHN_COMMON 0xfff2
  302. +#define SHN_XINDEX 0xffff
  303. +#define SHN_HIRESERVE 0xffff
  304. +
  305. +
  306. +
  307. +#define SHT_NULL 0
  308. +#define SHT_PROGBITS 1
  309. +#define SHT_SYMTAB 2
  310. +#define SHT_STRTAB 3
  311. +#define SHT_RELA 4
  312. +#define SHT_HASH 5
  313. +#define SHT_DYNAMIC 6
  314. +#define SHT_NOTE 7
  315. +#define SHT_NOBITS 8
  316. +#define SHT_REL 9
  317. +#define SHT_SHLIB 10
  318. +#define SHT_DYNSYM 11
  319. +#define SHT_INIT_ARRAY 14
  320. +#define SHT_FINI_ARRAY 15
  321. +#define SHT_PREINIT_ARRAY 16
  322. +#define SHT_GROUP 17
  323. +#define SHT_SYMTAB_SHNDX 18
  324. +#define SHT_NUM 19
  325. +#define SHT_LOOS 0x60000000
  326. +#define SHT_GNU_ATTRIBUTES 0x6ffffff5
  327. +#define SHT_GNU_HASH 0x6ffffff6
  328. +#define SHT_GNU_LIBLIST 0x6ffffff7
  329. +#define SHT_CHECKSUM 0x6ffffff8
  330. +#define SHT_LOSUNW 0x6ffffffa
  331. +#define SHT_SUNW_move 0x6ffffffa
  332. +#define SHT_SUNW_COMDAT 0x6ffffffb
  333. +#define SHT_SUNW_syminfo 0x6ffffffc
  334. +#define SHT_GNU_verdef 0x6ffffffd
  335. +#define SHT_GNU_verneed 0x6ffffffe
  336. +#define SHT_GNU_versym 0x6fffffff
  337. +#define SHT_HISUNW 0x6fffffff
  338. +#define SHT_HIOS 0x6fffffff
  339. +#define SHT_LOPROC 0x70000000
  340. +#define SHT_HIPROC 0x7fffffff
  341. +#define SHT_LOUSER 0x80000000
  342. +#define SHT_HIUSER 0x8fffffff
  343. +
  344. +#define SHF_WRITE (1 << 0)
  345. +#define SHF_ALLOC (1 << 1)
  346. +#define SHF_EXECINSTR (1 << 2)
  347. +#define SHF_MERGE (1 << 4)
  348. +#define SHF_STRINGS (1 << 5)
  349. +#define SHF_INFO_LINK (1 << 6)
  350. +#define SHF_LINK_ORDER (1 << 7)
  351. +#define SHF_OS_NONCONFORMING (1 << 8)
  352. +
  353. +#define SHF_GROUP (1 << 9)
  354. +#define SHF_TLS (1 << 10)
  355. +#define SHF_MASKOS 0x0ff00000
  356. +#define SHF_MASKPROC 0xf0000000
  357. +#define SHF_ORDERED (1 << 30)
  358. +#define SHF_EXCLUDE (1 << 31)
  359. +
  360. +#define GRP_COMDAT 0x1
  361. +
  362. +typedef struct {
  363. + Elf32_Word st_name;
  364. + Elf32_Addr st_value;
  365. + Elf32_Word st_size;
  366. + unsigned char st_info;
  367. + unsigned char st_other;
  368. + Elf32_Section st_shndx;
  369. +} Elf32_Sym;
  370. +
  371. +typedef struct {
  372. + Elf64_Word st_name;
  373. + unsigned char st_info;
  374. + unsigned char st_other;
  375. + Elf64_Section st_shndx;
  376. + Elf64_Addr st_value;
  377. + Elf64_Xword st_size;
  378. +} Elf64_Sym;
  379. +
  380. +typedef struct {
  381. + Elf32_Half si_boundto;
  382. + Elf32_Half si_flags;
  383. +} Elf32_Syminfo;
  384. +
  385. +typedef struct {
  386. + Elf64_Half si_boundto;
  387. + Elf64_Half si_flags;
  388. +} Elf64_Syminfo;
  389. +
  390. +#define SYMINFO_BT_SELF 0xffff
  391. +#define SYMINFO_BT_PARENT 0xfffe
  392. +#define SYMINFO_BT_LOWRESERVE 0xff00
  393. +
  394. +#define SYMINFO_FLG_DIRECT 0x0001
  395. +#define SYMINFO_FLG_PASSTHRU 0x0002
  396. +#define SYMINFO_FLG_COPY 0x0004
  397. +#define SYMINFO_FLG_LAZYLOAD 0x0008
  398. +
  399. +#define SYMINFO_NONE 0
  400. +#define SYMINFO_CURRENT 1
  401. +#define SYMINFO_NUM 2
  402. +
  403. +#define ELF32_ST_BIND(val) (((unsigned char) (val)) >> 4)
  404. +#define ELF32_ST_TYPE(val) ((val) & 0xf)
  405. +#define ELF32_ST_INFO(bind, type) (((bind) << 4) + ((type) & 0xf))
  406. +
  407. +#define ELF64_ST_BIND(val) ELF32_ST_BIND (val)
  408. +#define ELF64_ST_TYPE(val) ELF32_ST_TYPE (val)
  409. +#define ELF64_ST_INFO(bind, type) ELF32_ST_INFO ((bind), (type))
  410. +
  411. +#define STB_LOCAL 0
  412. +#define STB_GLOBAL 1
  413. +#define STB_WEAK 2
  414. +#define STB_NUM 3
  415. +#define STB_LOOS 10
  416. +#define STB_GNU_UNIQUE 10
  417. +#define STB_HIOS 12
  418. +#define STB_LOPROC 13
  419. +#define STB_HIPROC 15
  420. +
  421. +#define STT_NOTYPE 0
  422. +#define STT_OBJECT 1
  423. +#define STT_FUNC 2
  424. +#define STT_SECTION 3
  425. +#define STT_FILE 4
  426. +#define STT_COMMON 5
  427. +#define STT_TLS 6
  428. +#define STT_NUM 7
  429. +#define STT_LOOS 10
  430. +#define STT_GNU_IFUNC 10
  431. +#define STT_HIOS 12
  432. +#define STT_LOPROC 13
  433. +#define STT_HIPROC 15
  434. +
  435. +#define STN_UNDEF 0
  436. +
  437. +#define ELF32_ST_VISIBILITY(o) ((o) & 0x03)
  438. +#define ELF64_ST_VISIBILITY(o) ELF32_ST_VISIBILITY (o)
  439. +
  440. +#define STV_DEFAULT 0
  441. +#define STV_INTERNAL 1
  442. +#define STV_HIDDEN 2
  443. +#define STV_PROTECTED 3
  444. +
  445. +
  446. +
  447. +
  448. +typedef struct
  449. +{
  450. + Elf32_Addr r_offset;
  451. + Elf32_Word r_info;
  452. +} Elf32_Rel;
  453. +
  454. +typedef struct {
  455. + Elf64_Addr r_offset;
  456. + Elf64_Xword r_info;
  457. +} Elf64_Rel;
  458. +
  459. +
  460. +
  461. +typedef struct {
  462. + Elf32_Addr r_offset;
  463. + Elf32_Word r_info;
  464. + Elf32_Sword r_addend;
  465. +} Elf32_Rela;
  466. +
  467. +typedef struct {
  468. + Elf64_Addr r_offset;
  469. + Elf64_Xword r_info;
  470. + Elf64_Sxword r_addend;
  471. +} Elf64_Rela;
  472. +
  473. +
  474. +
  475. +#define ELF32_R_SYM(val) ((val) >> 8)
  476. +#define ELF32_R_TYPE(val) ((val) & 0xff)
  477. +#define ELF32_R_INFO(sym, type) (((sym) << 8) + ((type) & 0xff))
  478. +
  479. +#define ELF64_R_SYM(i) ((i) >> 32)
  480. +#define ELF64_R_TYPE(i) ((i) & 0xffffffff)
  481. +#define ELF64_R_INFO(sym,type) ((((Elf64_Xword) (sym)) << 32) + (type))
  482. +
  483. +
  484. +
  485. +typedef struct {
  486. + Elf32_Word p_type;
  487. + Elf32_Off p_offset;
  488. + Elf32_Addr p_vaddr;
  489. + Elf32_Addr p_paddr;
  490. + Elf32_Word p_filesz;
  491. + Elf32_Word p_memsz;
  492. + Elf32_Word p_flags;
  493. + Elf32_Word p_align;
  494. +} Elf32_Phdr;
  495. +
  496. +typedef struct {
  497. + Elf64_Word p_type;
  498. + Elf64_Word p_flags;
  499. + Elf64_Off p_offset;
  500. + Elf64_Addr p_vaddr;
  501. + Elf64_Addr p_paddr;
  502. + Elf64_Xword p_filesz;
  503. + Elf64_Xword p_memsz;
  504. + Elf64_Xword p_align;
  505. +} Elf64_Phdr;
  506. +
  507. +
  508. +
  509. +#define PT_NULL 0
  510. +#define PT_LOAD 1
  511. +#define PT_DYNAMIC 2
  512. +#define PT_INTERP 3
  513. +#define PT_NOTE 4
  514. +#define PT_SHLIB 5
  515. +#define PT_PHDR 6
  516. +#define PT_TLS 7
  517. +#define PT_NUM 8
  518. +#define PT_LOOS 0x60000000
  519. +#define PT_GNU_EH_FRAME 0x6474e550
  520. +#define PT_GNU_STACK 0x6474e551
  521. +#define PT_GNU_RELRO 0x6474e552
  522. +#define PT_LOSUNW 0x6ffffffa
  523. +#define PT_SUNWBSS 0x6ffffffa
  524. +#define PT_SUNWSTACK 0x6ffffffb
  525. +#define PT_HISUNW 0x6fffffff
  526. +#define PT_HIOS 0x6fffffff
  527. +#define PT_LOPROC 0x70000000
  528. +#define PT_HIPROC 0x7fffffff
  529. +
  530. +
  531. +#define PN_XNUM 0xffff
  532. +
  533. +
  534. +#define PF_X (1 << 0)
  535. +#define PF_W (1 << 1)
  536. +#define PF_R (1 << 2)
  537. +#define PF_MASKOS 0x0ff00000
  538. +#define PF_MASKPROC 0xf0000000
  539. +
  540. +
  541. +
  542. +#define NT_PRSTATUS 1
  543. +#define NT_FPREGSET 2
  544. +#define NT_PRPSINFO 3
  545. +#define NT_PRXREG 4
  546. +#define NT_TASKSTRUCT 4
  547. +#define NT_PLATFORM 5
  548. +#define NT_AUXV 6
  549. +#define NT_GWINDOWS 7
  550. +#define NT_ASRS 8
  551. +#define NT_PSTATUS 10
  552. +#define NT_PSINFO 13
  553. +#define NT_PRCRED 14
  554. +#define NT_UTSNAME 15
  555. +#define NT_LWPSTATUS 16
  556. +#define NT_LWPSINFO 17
  557. +#define NT_PRFPXREG 20
  558. +#define NT_SIGINFO 0x53494749
  559. +#define NT_FILE 0x46494c45
  560. +#define NT_PRXFPREG 0x46e62b7f
  561. +#define NT_PPC_VMX 0x100
  562. +#define NT_PPC_SPE 0x101
  563. +#define NT_PPC_VSX 0x102
  564. +#define NT_386_TLS 0x200
  565. +#define NT_386_IOPERM 0x201
  566. +#define NT_X86_XSTATE 0x202
  567. +#define NT_S390_HIGH_GPRS 0x300
  568. +#define NT_S390_TIMER 0x301
  569. +#define NT_S390_TODCMP 0x302
  570. +#define NT_S390_TODPREG 0x303
  571. +#define NT_S390_CTRS 0x304
  572. +#define NT_S390_PREFIX 0x305
  573. +#define NT_S390_LAST_BREAK 0x306
  574. +#define NT_S390_SYSTEM_CALL 0x307
  575. +#define NT_S390_TDB 0x308
  576. +#define NT_ARM_VFP 0x400
  577. +#define NT_ARM_TLS 0x401
  578. +#define NT_ARM_HW_BREAK 0x402
  579. +#define NT_ARM_HW_WATCH 0x403
  580. +#define NT_METAG_CBUF 0x500
  581. +#define NT_METAG_RPIPE 0x501
  582. +#define NT_METAG_TLS 0x502
  583. +#define NT_VERSION 1
  584. +
  585. +
  586. +
  587. +
  588. +typedef struct {
  589. + Elf32_Sword d_tag;
  590. + union {
  591. + Elf32_Word d_val;
  592. + Elf32_Addr d_ptr;
  593. + } d_un;
  594. +} Elf32_Dyn;
  595. +
  596. +typedef struct {
  597. + Elf64_Sxword d_tag;
  598. + union {
  599. + Elf64_Xword d_val;
  600. + Elf64_Addr d_ptr;
  601. + } d_un;
  602. +} Elf64_Dyn;
  603. +
  604. +
  605. +
  606. +#define DT_NULL 0
  607. +#define DT_NEEDED 1
  608. +#define DT_PLTRELSZ 2
  609. +#define DT_PLTGOT 3
  610. +#define DT_HASH 4
  611. +#define DT_STRTAB 5
  612. +#define DT_SYMTAB 6
  613. +#define DT_RELA 7
  614. +#define DT_RELASZ 8
  615. +#define DT_RELAENT 9
  616. +#define DT_STRSZ 10
  617. +#define DT_SYMENT 11
  618. +#define DT_INIT 12
  619. +#define DT_FINI 13
  620. +#define DT_SONAME 14
  621. +#define DT_RPATH 15
  622. +#define DT_SYMBOLIC 16
  623. +#define DT_REL 17
  624. +#define DT_RELSZ 18
  625. +#define DT_RELENT 19
  626. +#define DT_PLTREL 20
  627. +#define DT_DEBUG 21
  628. +#define DT_TEXTREL 22
  629. +#define DT_JMPREL 23
  630. +#define DT_BIND_NOW 24
  631. +#define DT_INIT_ARRAY 25
  632. +#define DT_FINI_ARRAY 26
  633. +#define DT_INIT_ARRAYSZ 27
  634. +#define DT_FINI_ARRAYSZ 28
  635. +#define DT_RUNPATH 29
  636. +#define DT_FLAGS 30
  637. +#define DT_ENCODING 32
  638. +#define DT_PREINIT_ARRAY 32
  639. +#define DT_PREINIT_ARRAYSZ 33
  640. +#define DT_NUM 34
  641. +#define DT_LOOS 0x6000000d
  642. +#define DT_HIOS 0x6ffff000
  643. +#define DT_LOPROC 0x70000000
  644. +#define DT_HIPROC 0x7fffffff
  645. +#define DT_PROCNUM DT_MIPS_NUM
  646. +
  647. +#define DT_VALRNGLO 0x6ffffd00
  648. +#define DT_GNU_PRELINKED 0x6ffffdf5
  649. +#define DT_GNU_CONFLICTSZ 0x6ffffdf6
  650. +#define DT_GNU_LIBLISTSZ 0x6ffffdf7
  651. +#define DT_CHECKSUM 0x6ffffdf8
  652. +#define DT_PLTPADSZ 0x6ffffdf9
  653. +#define DT_MOVEENT 0x6ffffdfa
  654. +#define DT_MOVESZ 0x6ffffdfb
  655. +#define DT_FEATURE_1 0x6ffffdfc
  656. +#define DT_POSFLAG_1 0x6ffffdfd
  657. +
  658. +#define DT_SYMINSZ 0x6ffffdfe
  659. +#define DT_SYMINENT 0x6ffffdff
  660. +#define DT_VALRNGHI 0x6ffffdff
  661. +#define DT_VALTAGIDX(tag) (DT_VALRNGHI - (tag))
  662. +#define DT_VALNUM 12
  663. +
  664. +#define DT_ADDRRNGLO 0x6ffffe00
  665. +#define DT_GNU_HASH 0x6ffffef5
  666. +#define DT_TLSDESC_PLT 0x6ffffef6
  667. +#define DT_TLSDESC_GOT 0x6ffffef7
  668. +#define DT_GNU_CONFLICT 0x6ffffef8
  669. +#define DT_GNU_LIBLIST 0x6ffffef9
  670. +#define DT_CONFIG 0x6ffffefa
  671. +#define DT_DEPAUDIT 0x6ffffefb
  672. +#define DT_AUDIT 0x6ffffefc
  673. +#define DT_PLTPAD 0x6ffffefd
  674. +#define DT_MOVETAB 0x6ffffefe
  675. +#define DT_SYMINFO 0x6ffffeff
  676. +#define DT_ADDRRNGHI 0x6ffffeff
  677. +#define DT_ADDRTAGIDX(tag) (DT_ADDRRNGHI - (tag))
  678. +#define DT_ADDRNUM 11
  679. +
  680. +
  681. +
  682. +#define DT_VERSYM 0x6ffffff0
  683. +
  684. +#define DT_RELACOUNT 0x6ffffff9
  685. +#define DT_RELCOUNT 0x6ffffffa
  686. +
  687. +
  688. +#define DT_FLAGS_1 0x6ffffffb
  689. +#define DT_VERDEF 0x6ffffffc
  690. +
  691. +#define DT_VERDEFNUM 0x6ffffffd
  692. +#define DT_VERNEED 0x6ffffffe
  693. +
  694. +#define DT_VERNEEDNUM 0x6fffffff
  695. +#define DT_VERSIONTAGIDX(tag) (DT_VERNEEDNUM - (tag))
  696. +#define DT_VERSIONTAGNUM 16
  697. +
  698. +
  699. +
  700. +#define DT_AUXILIARY 0x7ffffffd
  701. +#define DT_FILTER 0x7fffffff
  702. +#define DT_EXTRATAGIDX(tag) ((Elf32_Word)-((Elf32_Sword) (tag) <<1>>1)-1)
  703. +#define DT_EXTRANUM 3
  704. +
  705. +
  706. +#define DF_ORIGIN 0x00000001
  707. +#define DF_SYMBOLIC 0x00000002
  708. +#define DF_TEXTREL 0x00000004
  709. +#define DF_BIND_NOW 0x00000008
  710. +#define DF_STATIC_TLS 0x00000010
  711. +
  712. +
  713. +
  714. +#define DF_1_NOW 0x00000001
  715. +#define DF_1_GLOBAL 0x00000002
  716. +#define DF_1_GROUP 0x00000004
  717. +#define DF_1_NODELETE 0x00000008
  718. +#define DF_1_LOADFLTR 0x00000010
  719. +#define DF_1_INITFIRST 0x00000020
  720. +#define DF_1_NOOPEN 0x00000040
  721. +#define DF_1_ORIGIN 0x00000080
  722. +#define DF_1_DIRECT 0x00000100
  723. +#define DF_1_TRANS 0x00000200
  724. +#define DF_1_INTERPOSE 0x00000400
  725. +#define DF_1_NODEFLIB 0x00000800
  726. +#define DF_1_NODUMP 0x00001000
  727. +#define DF_1_CONFALT 0x00002000
  728. +#define DF_1_ENDFILTEE 0x00004000
  729. +#define DF_1_DISPRELDNE 0x00008000
  730. +#define DF_1_DISPRELPND 0x00010000
  731. +#define DF_1_NODIRECT 0x00020000
  732. +#define DF_1_IGNMULDEF 0x00040000
  733. +#define DF_1_NOKSYMS 0x00080000
  734. +#define DF_1_NOHDR 0x00100000
  735. +#define DF_1_EDITED 0x00200000
  736. +#define DF_1_NORELOC 0x00400000
  737. +#define DF_1_SYMINTPOSE 0x00800000
  738. +#define DF_1_GLOBAUDIT 0x01000000
  739. +#define DF_1_SINGLETON 0x02000000
  740. +
  741. +#define DTF_1_PARINIT 0x00000001
  742. +#define DTF_1_CONFEXP 0x00000002
  743. +
  744. +
  745. +#define DF_P1_LAZYLOAD 0x00000001
  746. +#define DF_P1_GROUPPERM 0x00000002
  747. +
  748. +
  749. +
  750. +
  751. +typedef struct {
  752. + Elf32_Half vd_version;
  753. + Elf32_Half vd_flags;
  754. + Elf32_Half vd_ndx;
  755. + Elf32_Half vd_cnt;
  756. + Elf32_Word vd_hash;
  757. + Elf32_Word vd_aux;
  758. + Elf32_Word vd_next;
  759. +} Elf32_Verdef;
  760. +
  761. +typedef struct {
  762. + Elf64_Half vd_version;
  763. + Elf64_Half vd_flags;
  764. + Elf64_Half vd_ndx;
  765. + Elf64_Half vd_cnt;
  766. + Elf64_Word vd_hash;
  767. + Elf64_Word vd_aux;
  768. + Elf64_Word vd_next;
  769. +} Elf64_Verdef;
  770. +
  771. +
  772. +
  773. +#define VER_DEF_NONE 0
  774. +#define VER_DEF_CURRENT 1
  775. +#define VER_DEF_NUM 2
  776. +
  777. +
  778. +#define VER_FLG_BASE 0x1
  779. +#define VER_FLG_WEAK 0x2
  780. +
  781. +
  782. +#define VER_NDX_LOCAL 0
  783. +#define VER_NDX_GLOBAL 1
  784. +#define VER_NDX_LORESERVE 0xff00
  785. +#define VER_NDX_ELIMINATE 0xff01
  786. +
  787. +
  788. +
  789. +typedef struct {
  790. + Elf32_Word vda_name;
  791. + Elf32_Word vda_next;
  792. +} Elf32_Verdaux;
  793. +
  794. +typedef struct {
  795. + Elf64_Word vda_name;
  796. + Elf64_Word vda_next;
  797. +} Elf64_Verdaux;
  798. +
  799. +
  800. +
  801. +
  802. +typedef struct {
  803. + Elf32_Half vn_version;
  804. + Elf32_Half vn_cnt;
  805. + Elf32_Word vn_file;
  806. + Elf32_Word vn_aux;
  807. + Elf32_Word vn_next;
  808. +} Elf32_Verneed;
  809. +
  810. +typedef struct {
  811. + Elf64_Half vn_version;
  812. + Elf64_Half vn_cnt;
  813. + Elf64_Word vn_file;
  814. + Elf64_Word vn_aux;
  815. + Elf64_Word vn_next;
  816. +} Elf64_Verneed;
  817. +
  818. +
  819. +
  820. +#define VER_NEED_NONE 0
  821. +#define VER_NEED_CURRENT 1
  822. +#define VER_NEED_NUM 2
  823. +
  824. +
  825. +
  826. +typedef struct {
  827. + Elf32_Word vna_hash;
  828. + Elf32_Half vna_flags;
  829. + Elf32_Half vna_other;
  830. + Elf32_Word vna_name;
  831. + Elf32_Word vna_next;
  832. +} Elf32_Vernaux;
  833. +
  834. +typedef struct {
  835. + Elf64_Word vna_hash;
  836. + Elf64_Half vna_flags;
  837. + Elf64_Half vna_other;
  838. + Elf64_Word vna_name;
  839. + Elf64_Word vna_next;
  840. +} Elf64_Vernaux;
  841. +
  842. +
  843. +
  844. +#define VER_FLG_WEAK 0x2
  845. +
  846. +
  847. +
  848. +typedef struct {
  849. + uint32_t a_type;
  850. + union {
  851. + uint32_t a_val;
  852. + } a_un;
  853. +} Elf32_auxv_t;
  854. +
  855. +typedef struct {
  856. + uint64_t a_type;
  857. + union {
  858. + uint64_t a_val;
  859. + } a_un;
  860. +} Elf64_auxv_t;
  861. +
  862. +
  863. +
  864. +#define AT_NULL 0
  865. +#define AT_IGNORE 1
  866. +#define AT_EXECFD 2
  867. +#define AT_PHDR 3
  868. +#define AT_PHENT 4
  869. +#define AT_PHNUM 5
  870. +#define AT_PAGESZ 6
  871. +#define AT_BASE 7
  872. +#define AT_FLAGS 8
  873. +#define AT_ENTRY 9
  874. +#define AT_NOTELF 10
  875. +#define AT_UID 11
  876. +#define AT_EUID 12
  877. +#define AT_GID 13
  878. +#define AT_EGID 14
  879. +#define AT_CLKTCK 17
  880. +
  881. +
  882. +#define AT_PLATFORM 15
  883. +#define AT_HWCAP 16
  884. +
  885. +
  886. +
  887. +
  888. +#define AT_FPUCW 18
  889. +
  890. +
  891. +#define AT_DCACHEBSIZE 19
  892. +#define AT_ICACHEBSIZE 20
  893. +#define AT_UCACHEBSIZE 21
  894. +
  895. +
  896. +
  897. +#define AT_IGNOREPPC 22
  898. +
  899. +#define AT_SECURE 23
  900. +
  901. +#define AT_BASE_PLATFORM 24
  902. +
  903. +#define AT_RANDOM 25
  904. +
  905. +#define AT_HWCAP2 26
  906. +
  907. +#define AT_EXECFN 31
  908. +
  909. +
  910. +
  911. +#define AT_SYSINFO 32
  912. +#define AT_SYSINFO_EHDR 33
  913. +
  914. +
  915. +
  916. +#define AT_L1I_CACHESHAPE 34
  917. +#define AT_L1D_CACHESHAPE 35
  918. +#define AT_L2_CACHESHAPE 36
  919. +#define AT_L3_CACHESHAPE 37
  920. +
  921. +
  922. +
  923. +
  924. +typedef struct {
  925. + Elf32_Word n_namesz;
  926. + Elf32_Word n_descsz;
  927. + Elf32_Word n_type;
  928. +} Elf32_Nhdr;
  929. +
  930. +typedef struct {
  931. + Elf64_Word n_namesz;
  932. + Elf64_Word n_descsz;
  933. + Elf64_Word n_type;
  934. +} Elf64_Nhdr;
  935. +
  936. +
  937. +
  938. +
  939. +#define ELF_NOTE_SOLARIS "SUNW Solaris"
  940. +
  941. +
  942. +#define ELF_NOTE_GNU "GNU"
  943. +
  944. +
  945. +
  946. +
  947. +
  948. +#define ELF_NOTE_PAGESIZE_HINT 1
  949. +
  950. +
  951. +#define NT_GNU_ABI_TAG 1
  952. +#define ELF_NOTE_ABI NT_GNU_ABI_TAG
  953. +
  954. +
  955. +
  956. +#define ELF_NOTE_OS_LINUX 0
  957. +#define ELF_NOTE_OS_GNU 1
  958. +#define ELF_NOTE_OS_SOLARIS2 2
  959. +#define ELF_NOTE_OS_FREEBSD 3
  960. +
  961. +#define NT_GNU_BUILD_ID 3
  962. +#define NT_GNU_GOLD_VERSION 4
  963. +
  964. +
  965. +
  966. +typedef struct {
  967. + Elf32_Xword m_value;
  968. + Elf32_Word m_info;
  969. + Elf32_Word m_poffset;
  970. + Elf32_Half m_repeat;
  971. + Elf32_Half m_stride;
  972. +} Elf32_Move;
  973. +
  974. +typedef struct {
  975. + Elf64_Xword m_value;
  976. + Elf64_Xword m_info;
  977. + Elf64_Xword m_poffset;
  978. + Elf64_Half m_repeat;
  979. + Elf64_Half m_stride;
  980. +} Elf64_Move;
  981. +
  982. +
  983. +#define ELF32_M_SYM(info) ((info) >> 8)
  984. +#define ELF32_M_SIZE(info) ((unsigned char) (info))
  985. +#define ELF32_M_INFO(sym, size) (((sym) << 8) + (unsigned char) (size))
  986. +
  987. +#define ELF64_M_SYM(info) ELF32_M_SYM (info)
  988. +#define ELF64_M_SIZE(info) ELF32_M_SIZE (info)
  989. +#define ELF64_M_INFO(sym, size) ELF32_M_INFO (sym, size)
  990. +
  991. +#define EF_CPU32 0x00810000
  992. +
  993. +#define R_68K_NONE 0
  994. +#define R_68K_32 1
  995. +#define R_68K_16 2
  996. +#define R_68K_8 3
  997. +#define R_68K_PC32 4
  998. +#define R_68K_PC16 5
  999. +#define R_68K_PC8 6
  1000. +#define R_68K_GOT32 7
  1001. +#define R_68K_GOT16 8
  1002. +#define R_68K_GOT8 9
  1003. +#define R_68K_GOT32O 10
  1004. +#define R_68K_GOT16O 11
  1005. +#define R_68K_GOT8O 12
  1006. +#define R_68K_PLT32 13
  1007. +#define R_68K_PLT16 14
  1008. +#define R_68K_PLT8 15
  1009. +#define R_68K_PLT32O 16
  1010. +#define R_68K_PLT16O 17
  1011. +#define R_68K_PLT8O 18
  1012. +#define R_68K_COPY 19
  1013. +#define R_68K_GLOB_DAT 20
  1014. +#define R_68K_JMP_SLOT 21
  1015. +#define R_68K_RELATIVE 22
  1016. +#define R_68K_NUM 23
  1017. +
  1018. +#define R_386_NONE 0
  1019. +#define R_386_32 1
  1020. +#define R_386_PC32 2
  1021. +#define R_386_GOT32 3
  1022. +#define R_386_PLT32 4
  1023. +#define R_386_COPY 5
  1024. +#define R_386_GLOB_DAT 6
  1025. +#define R_386_JMP_SLOT 7
  1026. +#define R_386_RELATIVE 8
  1027. +#define R_386_GOTOFF 9
  1028. +#define R_386_GOTPC 10
  1029. +#define R_386_32PLT 11
  1030. +#define R_386_TLS_TPOFF 14
  1031. +#define R_386_TLS_IE 15
  1032. +#define R_386_TLS_GOTIE 16
  1033. +#define R_386_TLS_LE 17
  1034. +#define R_386_TLS_GD 18
  1035. +#define R_386_TLS_LDM 19
  1036. +#define R_386_16 20
  1037. +#define R_386_PC16 21
  1038. +#define R_386_8 22
  1039. +#define R_386_PC8 23
  1040. +#define R_386_TLS_GD_32 24
  1041. +#define R_386_TLS_GD_PUSH 25
  1042. +#define R_386_TLS_GD_CALL 26
  1043. +#define R_386_TLS_GD_POP 27
  1044. +#define R_386_TLS_LDM_32 28
  1045. +#define R_386_TLS_LDM_PUSH 29
  1046. +#define R_386_TLS_LDM_CALL 30
  1047. +#define R_386_TLS_LDM_POP 31
  1048. +#define R_386_TLS_LDO_32 32
  1049. +#define R_386_TLS_IE_32 33
  1050. +#define R_386_TLS_LE_32 34
  1051. +#define R_386_TLS_DTPMOD32 35
  1052. +#define R_386_TLS_DTPOFF32 36
  1053. +#define R_386_TLS_TPOFF32 37
  1054. +#define R_386_SIZE32 38
  1055. +#define R_386_TLS_GOTDESC 39
  1056. +#define R_386_TLS_DESC_CALL 40
  1057. +#define R_386_TLS_DESC 41
  1058. +#define R_386_IRELATIVE 42
  1059. +#define R_386_NUM 43
  1060. +
  1061. +
  1062. +
  1063. +
  1064. +
  1065. +#define STT_SPARC_REGISTER 13
  1066. +
  1067. +
  1068. +
  1069. +#define EF_SPARCV9_MM 3
  1070. +#define EF_SPARCV9_TSO 0
  1071. +#define EF_SPARCV9_PSO 1
  1072. +#define EF_SPARCV9_RMO 2
  1073. +#define EF_SPARC_LEDATA 0x800000
  1074. +#define EF_SPARC_EXT_MASK 0xFFFF00
  1075. +#define EF_SPARC_32PLUS 0x000100
  1076. +#define EF_SPARC_SUN_US1 0x000200
  1077. +#define EF_SPARC_HAL_R1 0x000400
  1078. +#define EF_SPARC_SUN_US3 0x000800
  1079. +
  1080. +
  1081. +
  1082. +#define R_SPARC_NONE 0
  1083. +#define R_SPARC_8 1
  1084. +#define R_SPARC_16 2
  1085. +#define R_SPARC_32 3
  1086. +#define R_SPARC_DISP8 4
  1087. +#define R_SPARC_DISP16 5
  1088. +#define R_SPARC_DISP32 6
  1089. +#define R_SPARC_WDISP30 7
  1090. +#define R_SPARC_WDISP22 8
  1091. +#define R_SPARC_HI22 9
  1092. +#define R_SPARC_22 10
  1093. +#define R_SPARC_13 11
  1094. +#define R_SPARC_LO10 12
  1095. +#define R_SPARC_GOT10 13
  1096. +#define R_SPARC_GOT13 14
  1097. +#define R_SPARC_GOT22 15
  1098. +#define R_SPARC_PC10 16
  1099. +#define R_SPARC_PC22 17
  1100. +#define R_SPARC_WPLT30 18
  1101. +#define R_SPARC_COPY 19
  1102. +#define R_SPARC_GLOB_DAT 20
  1103. +#define R_SPARC_JMP_SLOT 21
  1104. +#define R_SPARC_RELATIVE 22
  1105. +#define R_SPARC_UA32 23
  1106. +
  1107. +
  1108. +
  1109. +#define R_SPARC_PLT32 24
  1110. +#define R_SPARC_HIPLT22 25
  1111. +#define R_SPARC_LOPLT10 26
  1112. +#define R_SPARC_PCPLT32 27
  1113. +#define R_SPARC_PCPLT22 28
  1114. +#define R_SPARC_PCPLT10 29
  1115. +#define R_SPARC_10 30
  1116. +#define R_SPARC_11 31
  1117. +#define R_SPARC_64 32
  1118. +#define R_SPARC_OLO10 33
  1119. +#define R_SPARC_HH22 34
  1120. +#define R_SPARC_HM10 35
  1121. +#define R_SPARC_LM22 36
  1122. +#define R_SPARC_PC_HH22 37
  1123. +#define R_SPARC_PC_HM10 38
  1124. +#define R_SPARC_PC_LM22 39
  1125. +#define R_SPARC_WDISP16 40
  1126. +#define R_SPARC_WDISP19 41
  1127. +#define R_SPARC_GLOB_JMP 42
  1128. +#define R_SPARC_7 43
  1129. +#define R_SPARC_5 44
  1130. +#define R_SPARC_6 45
  1131. +#define R_SPARC_DISP64 46
  1132. +#define R_SPARC_PLT64 47
  1133. +#define R_SPARC_HIX22 48
  1134. +#define R_SPARC_LOX10 49
  1135. +#define R_SPARC_H44 50
  1136. +#define R_SPARC_M44 51
  1137. +#define R_SPARC_L44 52
  1138. +#define R_SPARC_REGISTER 53
  1139. +#define R_SPARC_UA64 54
  1140. +#define R_SPARC_UA16 55
  1141. +#define R_SPARC_TLS_GD_HI22 56
  1142. +#define R_SPARC_TLS_GD_LO10 57
  1143. +#define R_SPARC_TLS_GD_ADD 58
  1144. +#define R_SPARC_TLS_GD_CALL 59
  1145. +#define R_SPARC_TLS_LDM_HI22 60
  1146. +#define R_SPARC_TLS_LDM_LO10 61
  1147. +#define R_SPARC_TLS_LDM_ADD 62
  1148. +#define R_SPARC_TLS_LDM_CALL 63
  1149. +#define R_SPARC_TLS_LDO_HIX22 64
  1150. +#define R_SPARC_TLS_LDO_LOX10 65
  1151. +#define R_SPARC_TLS_LDO_ADD 66
  1152. +#define R_SPARC_TLS_IE_HI22 67
  1153. +#define R_SPARC_TLS_IE_LO10 68
  1154. +#define R_SPARC_TLS_IE_LD 69
  1155. +#define R_SPARC_TLS_IE_LDX 70
  1156. +#define R_SPARC_TLS_IE_ADD 71
  1157. +#define R_SPARC_TLS_LE_HIX22 72
  1158. +#define R_SPARC_TLS_LE_LOX10 73
  1159. +#define R_SPARC_TLS_DTPMOD32 74
  1160. +#define R_SPARC_TLS_DTPMOD64 75
  1161. +#define R_SPARC_TLS_DTPOFF32 76
  1162. +#define R_SPARC_TLS_DTPOFF64 77
  1163. +#define R_SPARC_TLS_TPOFF32 78
  1164. +#define R_SPARC_TLS_TPOFF64 79
  1165. +#define R_SPARC_GOTDATA_HIX22 80
  1166. +#define R_SPARC_GOTDATA_LOX10 81
  1167. +#define R_SPARC_GOTDATA_OP_HIX22 82
  1168. +#define R_SPARC_GOTDATA_OP_LOX10 83
  1169. +#define R_SPARC_GOTDATA_OP 84
  1170. +#define R_SPARC_H34 85
  1171. +#define R_SPARC_SIZE32 86
  1172. +#define R_SPARC_SIZE64 87
  1173. +#define R_SPARC_GNU_VTINHERIT 250
  1174. +#define R_SPARC_GNU_VTENTRY 251
  1175. +#define R_SPARC_REV32 252
  1176. +
  1177. +#define R_SPARC_NUM 253
  1178. +
  1179. +
  1180. +
  1181. +#define DT_SPARC_REGISTER 0x70000001
  1182. +#define DT_SPARC_NUM 2
  1183. +
  1184. +
  1185. +#define EF_MIPS_NOREORDER 1
  1186. +#define EF_MIPS_PIC 2
  1187. +#define EF_MIPS_CPIC 4
  1188. +#define EF_MIPS_XGOT 8
  1189. +#define EF_MIPS_64BIT_WHIRL 16
  1190. +#define EF_MIPS_ABI2 32
  1191. +#define EF_MIPS_ABI_ON32 64
  1192. +#define EF_MIPS_ARCH 0xf0000000
  1193. +
  1194. +
  1195. +
  1196. +#define EF_MIPS_ARCH_1 0x00000000
  1197. +#define EF_MIPS_ARCH_2 0x10000000
  1198. +#define EF_MIPS_ARCH_3 0x20000000
  1199. +#define EF_MIPS_ARCH_4 0x30000000
  1200. +#define EF_MIPS_ARCH_5 0x40000000
  1201. +#define EF_MIPS_ARCH_32 0x50000000
  1202. +#define EF_MIPS_ARCH_64 0x60000000
  1203. +#define EF_MIPS_ARCH_32R2 0x70000000
  1204. +#define EF_MIPS_ARCH_64R2 0x80000000
  1205. +
  1206. +
  1207. +#define E_MIPS_ARCH_1 0x00000000
  1208. +#define E_MIPS_ARCH_2 0x10000000
  1209. +#define E_MIPS_ARCH_3 0x20000000
  1210. +#define E_MIPS_ARCH_4 0x30000000
  1211. +#define E_MIPS_ARCH_5 0x40000000
  1212. +#define E_MIPS_ARCH_32 0x50000000
  1213. +#define E_MIPS_ARCH_64 0x60000000
  1214. +
  1215. +
  1216. +
  1217. +#define SHN_MIPS_ACOMMON 0xff00
  1218. +#define SHN_MIPS_TEXT 0xff01
  1219. +#define SHN_MIPS_DATA 0xff02
  1220. +#define SHN_MIPS_SCOMMON 0xff03
  1221. +#define SHN_MIPS_SUNDEFINED 0xff04
  1222. +
  1223. +
  1224. +
  1225. +#define SHT_MIPS_LIBLIST 0x70000000
  1226. +#define SHT_MIPS_MSYM 0x70000001
  1227. +#define SHT_MIPS_CONFLICT 0x70000002
  1228. +#define SHT_MIPS_GPTAB 0x70000003
  1229. +#define SHT_MIPS_UCODE 0x70000004
  1230. +#define SHT_MIPS_DEBUG 0x70000005
  1231. +#define SHT_MIPS_REGINFO 0x70000006
  1232. +#define SHT_MIPS_PACKAGE 0x70000007
  1233. +#define SHT_MIPS_PACKSYM 0x70000008
  1234. +#define SHT_MIPS_RELD 0x70000009
  1235. +#define SHT_MIPS_IFACE 0x7000000b
  1236. +#define SHT_MIPS_CONTENT 0x7000000c
  1237. +#define SHT_MIPS_OPTIONS 0x7000000d
  1238. +#define SHT_MIPS_SHDR 0x70000010
  1239. +#define SHT_MIPS_FDESC 0x70000011
  1240. +#define SHT_MIPS_EXTSYM 0x70000012
  1241. +#define SHT_MIPS_DENSE 0x70000013
  1242. +#define SHT_MIPS_PDESC 0x70000014
  1243. +#define SHT_MIPS_LOCSYM 0x70000015
  1244. +#define SHT_MIPS_AUXSYM 0x70000016
  1245. +#define SHT_MIPS_OPTSYM 0x70000017
  1246. +#define SHT_MIPS_LOCSTR 0x70000018
  1247. +#define SHT_MIPS_LINE 0x70000019
  1248. +#define SHT_MIPS_RFDESC 0x7000001a
  1249. +#define SHT_MIPS_DELTASYM 0x7000001b
  1250. +#define SHT_MIPS_DELTAINST 0x7000001c
  1251. +#define SHT_MIPS_DELTACLASS 0x7000001d
  1252. +#define SHT_MIPS_DWARF 0x7000001e
  1253. +#define SHT_MIPS_DELTADECL 0x7000001f
  1254. +#define SHT_MIPS_SYMBOL_LIB 0x70000020
  1255. +#define SHT_MIPS_EVENTS 0x70000021
  1256. +#define SHT_MIPS_TRANSLATE 0x70000022
  1257. +#define SHT_MIPS_PIXIE 0x70000023
  1258. +#define SHT_MIPS_XLATE 0x70000024
  1259. +#define SHT_MIPS_XLATE_DEBUG 0x70000025
  1260. +#define SHT_MIPS_WHIRL 0x70000026
  1261. +#define SHT_MIPS_EH_REGION 0x70000027
  1262. +#define SHT_MIPS_XLATE_OLD 0x70000028
  1263. +#define SHT_MIPS_PDR_EXCEPTION 0x70000029
  1264. +
  1265. +
  1266. +
  1267. +#define SHF_MIPS_GPREL 0x10000000
  1268. +#define SHF_MIPS_MERGE 0x20000000
  1269. +#define SHF_MIPS_ADDR 0x40000000
  1270. +#define SHF_MIPS_STRINGS 0x80000000
  1271. +#define SHF_MIPS_NOSTRIP 0x08000000
  1272. +#define SHF_MIPS_LOCAL 0x04000000
  1273. +#define SHF_MIPS_NAMES 0x02000000
  1274. +#define SHF_MIPS_NODUPE 0x01000000
  1275. +
  1276. +
  1277. +
  1278. +
  1279. +
  1280. +#define STO_MIPS_DEFAULT 0x0
  1281. +#define STO_MIPS_INTERNAL 0x1
  1282. +#define STO_MIPS_HIDDEN 0x2
  1283. +#define STO_MIPS_PROTECTED 0x3
  1284. +#define STO_MIPS_PLT 0x8
  1285. +#define STO_MIPS_SC_ALIGN_UNUSED 0xff
  1286. +
  1287. +
  1288. +#define STB_MIPS_SPLIT_COMMON 13
  1289. +
  1290. +
  1291. +
  1292. +typedef union {
  1293. + struct {
  1294. + Elf32_Word gt_current_g_value;
  1295. + Elf32_Word gt_unused;
  1296. + } gt_header;
  1297. + struct {
  1298. + Elf32_Word gt_g_value;
  1299. + Elf32_Word gt_bytes;
  1300. + } gt_entry;
  1301. +} Elf32_gptab;
  1302. +
  1303. +
  1304. +
  1305. +typedef struct {
  1306. + Elf32_Word ri_gprmask;
  1307. + Elf32_Word ri_cprmask[4];
  1308. + Elf32_Sword ri_gp_value;
  1309. +} Elf32_RegInfo;
  1310. +
  1311. +
  1312. +
  1313. +typedef struct {
  1314. + unsigned char kind;
  1315. +
  1316. + unsigned char size;
  1317. + Elf32_Section section;
  1318. +
  1319. + Elf32_Word info;
  1320. +} Elf_Options;
  1321. +
  1322. +
  1323. +
  1324. +#define ODK_NULL 0
  1325. +#define ODK_REGINFO 1
  1326. +#define ODK_EXCEPTIONS 2
  1327. +#define ODK_PAD 3
  1328. +#define ODK_HWPATCH 4
  1329. +#define ODK_FILL 5
  1330. +#define ODK_TAGS 6
  1331. +#define ODK_HWAND 7
  1332. +#define ODK_HWOR 8
  1333. +
  1334. +
  1335. +
  1336. +#define OEX_FPU_MIN 0x1f
  1337. +#define OEX_FPU_MAX 0x1f00
  1338. +#define OEX_PAGE0 0x10000
  1339. +#define OEX_SMM 0x20000
  1340. +#define OEX_FPDBUG 0x40000
  1341. +#define OEX_PRECISEFP OEX_FPDBUG
  1342. +#define OEX_DISMISS 0x80000
  1343. +
  1344. +#define OEX_FPU_INVAL 0x10
  1345. +#define OEX_FPU_DIV0 0x08
  1346. +#define OEX_FPU_OFLO 0x04
  1347. +#define OEX_FPU_UFLO 0x02
  1348. +#define OEX_FPU_INEX 0x01
  1349. +
  1350. +
  1351. +
  1352. +#define OHW_R4KEOP 0x1
  1353. +#define OHW_R8KPFETCH 0x2
  1354. +#define OHW_R5KEOP 0x4
  1355. +#define OHW_R5KCVTL 0x8
  1356. +
  1357. +#define OPAD_PREFIX 0x1
  1358. +#define OPAD_POSTFIX 0x2
  1359. +#define OPAD_SYMBOL 0x4
  1360. +
  1361. +
  1362. +
  1363. +typedef struct {
  1364. + Elf32_Word hwp_flags1;
  1365. + Elf32_Word hwp_flags2;
  1366. +} Elf_Options_Hw;
  1367. +
  1368. +
  1369. +
  1370. +#define OHWA0_R4KEOP_CHECKED 0x00000001
  1371. +#define OHWA1_R4KEOP_CLEAN 0x00000002
  1372. +
  1373. +
  1374. +
  1375. +#define R_MIPS_NONE 0
  1376. +#define R_MIPS_16 1
  1377. +#define R_MIPS_32 2
  1378. +#define R_MIPS_REL32 3
  1379. +#define R_MIPS_26 4
  1380. +#define R_MIPS_HI16 5
  1381. +#define R_MIPS_LO16 6
  1382. +#define R_MIPS_GPREL16 7
  1383. +#define R_MIPS_LITERAL 8
  1384. +#define R_MIPS_GOT16 9
  1385. +#define R_MIPS_PC16 10
  1386. +#define R_MIPS_CALL16 11
  1387. +#define R_MIPS_GPREL32 12
  1388. +
  1389. +#define R_MIPS_SHIFT5 16
  1390. +#define R_MIPS_SHIFT6 17
  1391. +#define R_MIPS_64 18
  1392. +#define R_MIPS_GOT_DISP 19
  1393. +#define R_MIPS_GOT_PAGE 20
  1394. +#define R_MIPS_GOT_OFST 21
  1395. +#define R_MIPS_GOT_HI16 22
  1396. +#define R_MIPS_GOT_LO16 23
  1397. +#define R_MIPS_SUB 24
  1398. +#define R_MIPS_INSERT_A 25
  1399. +#define R_MIPS_INSERT_B 26
  1400. +#define R_MIPS_DELETE 27
  1401. +#define R_MIPS_HIGHER 28
  1402. +#define R_MIPS_HIGHEST 29
  1403. +#define R_MIPS_CALL_HI16 30
  1404. +#define R_MIPS_CALL_LO16 31
  1405. +#define R_MIPS_SCN_DISP 32
  1406. +#define R_MIPS_REL16 33
  1407. +#define R_MIPS_ADD_IMMEDIATE 34
  1408. +#define R_MIPS_PJUMP 35
  1409. +#define R_MIPS_RELGOT 36
  1410. +#define R_MIPS_JALR 37
  1411. +#define R_MIPS_TLS_DTPMOD32 38
  1412. +#define R_MIPS_TLS_DTPREL32 39
  1413. +#define R_MIPS_TLS_DTPMOD64 40
  1414. +#define R_MIPS_TLS_DTPREL64 41
  1415. +#define R_MIPS_TLS_GD 42
  1416. +#define R_MIPS_TLS_LDM 43
  1417. +#define R_MIPS_TLS_DTPREL_HI16 44
  1418. +#define R_MIPS_TLS_DTPREL_LO16 45
  1419. +#define R_MIPS_TLS_GOTTPREL 46
  1420. +#define R_MIPS_TLS_TPREL32 47
  1421. +#define R_MIPS_TLS_TPREL64 48
  1422. +#define R_MIPS_TLS_TPREL_HI16 49
  1423. +#define R_MIPS_TLS_TPREL_LO16 50
  1424. +#define R_MIPS_GLOB_DAT 51
  1425. +#define R_MIPS_COPY 126
  1426. +#define R_MIPS_JUMP_SLOT 127
  1427. +
  1428. +#define R_MIPS_NUM 128
  1429. +
  1430. +
  1431. +
  1432. +#define PT_MIPS_REGINFO 0x70000000
  1433. +#define PT_MIPS_RTPROC 0x70000001
  1434. +#define PT_MIPS_OPTIONS 0x70000002
  1435. +
  1436. +
  1437. +
  1438. +#define PF_MIPS_LOCAL 0x10000000
  1439. +
  1440. +
  1441. +
  1442. +#define DT_MIPS_RLD_VERSION 0x70000001
  1443. +#define DT_MIPS_TIME_STAMP 0x70000002
  1444. +#define DT_MIPS_ICHECKSUM 0x70000003
  1445. +#define DT_MIPS_IVERSION 0x70000004
  1446. +#define DT_MIPS_FLAGS 0x70000005
  1447. +#define DT_MIPS_BASE_ADDRESS 0x70000006
  1448. +#define DT_MIPS_MSYM 0x70000007
  1449. +#define DT_MIPS_CONFLICT 0x70000008
  1450. +#define DT_MIPS_LIBLIST 0x70000009
  1451. +#define DT_MIPS_LOCAL_GOTNO 0x7000000a
  1452. +#define DT_MIPS_CONFLICTNO 0x7000000b
  1453. +#define DT_MIPS_LIBLISTNO 0x70000010
  1454. +#define DT_MIPS_SYMTABNO 0x70000011
  1455. +#define DT_MIPS_UNREFEXTNO 0x70000012
  1456. +#define DT_MIPS_GOTSYM 0x70000013
  1457. +#define DT_MIPS_HIPAGENO 0x70000014
  1458. +#define DT_MIPS_RLD_MAP 0x70000016
  1459. +#define DT_MIPS_DELTA_CLASS 0x70000017
  1460. +#define DT_MIPS_DELTA_CLASS_NO 0x70000018
  1461. +
  1462. +#define DT_MIPS_DELTA_INSTANCE 0x70000019
  1463. +#define DT_MIPS_DELTA_INSTANCE_NO 0x7000001a
  1464. +
  1465. +#define DT_MIPS_DELTA_RELOC 0x7000001b
  1466. +#define DT_MIPS_DELTA_RELOC_NO 0x7000001c
  1467. +
  1468. +#define DT_MIPS_DELTA_SYM 0x7000001d
  1469. +
  1470. +#define DT_MIPS_DELTA_SYM_NO 0x7000001e
  1471. +
  1472. +#define DT_MIPS_DELTA_CLASSSYM 0x70000020
  1473. +
  1474. +#define DT_MIPS_DELTA_CLASSSYM_NO 0x70000021
  1475. +
  1476. +#define DT_MIPS_CXX_FLAGS 0x70000022
  1477. +#define DT_MIPS_PIXIE_INIT 0x70000023
  1478. +#define DT_MIPS_SYMBOL_LIB 0x70000024
  1479. +#define DT_MIPS_LOCALPAGE_GOTIDX 0x70000025
  1480. +#define DT_MIPS_LOCAL_GOTIDX 0x70000026
  1481. +#define DT_MIPS_HIDDEN_GOTIDX 0x70000027
  1482. +#define DT_MIPS_PROTECTED_GOTIDX 0x70000028
  1483. +#define DT_MIPS_OPTIONS 0x70000029
  1484. +#define DT_MIPS_INTERFACE 0x7000002a
  1485. +#define DT_MIPS_DYNSTR_ALIGN 0x7000002b
  1486. +#define DT_MIPS_INTERFACE_SIZE 0x7000002c
  1487. +#define DT_MIPS_RLD_TEXT_RESOLVE_ADDR 0x7000002d
  1488. +
  1489. +#define DT_MIPS_PERF_SUFFIX 0x7000002e
  1490. +
  1491. +#define DT_MIPS_COMPACT_SIZE 0x7000002f
  1492. +#define DT_MIPS_GP_VALUE 0x70000030
  1493. +#define DT_MIPS_AUX_DYNAMIC 0x70000031
  1494. +
  1495. +#define DT_MIPS_PLTGOT 0x70000032
  1496. +
  1497. +#define DT_MIPS_RWPLT 0x70000034
  1498. +#define DT_MIPS_NUM 0x35
  1499. +
  1500. +
  1501. +
  1502. +#define RHF_NONE 0
  1503. +#define RHF_QUICKSTART (1 << 0)
  1504. +#define RHF_NOTPOT (1 << 1)
  1505. +#define RHF_NO_LIBRARY_REPLACEMENT (1 << 2)
  1506. +#define RHF_NO_MOVE (1 << 3)
  1507. +#define RHF_SGI_ONLY (1 << 4)
  1508. +#define RHF_GUARANTEE_INIT (1 << 5)
  1509. +#define RHF_DELTA_C_PLUS_PLUS (1 << 6)
  1510. +#define RHF_GUARANTEE_START_INIT (1 << 7)
  1511. +#define RHF_PIXIE (1 << 8)
  1512. +#define RHF_DEFAULT_DELAY_LOAD (1 << 9)
  1513. +#define RHF_REQUICKSTART (1 << 10)
  1514. +#define RHF_REQUICKSTARTED (1 << 11)
  1515. +#define RHF_CORD (1 << 12)
  1516. +#define RHF_NO_UNRES_UNDEF (1 << 13)
  1517. +#define RHF_RLD_ORDER_SAFE (1 << 14)
  1518. +
  1519. +
  1520. +
  1521. +typedef struct
  1522. +{
  1523. + Elf32_Word l_name;
  1524. + Elf32_Word l_time_stamp;
  1525. + Elf32_Word l_checksum;
  1526. + Elf32_Word l_version;
  1527. + Elf32_Word l_flags;
  1528. +} Elf32_Lib;
  1529. +
  1530. +typedef struct
  1531. +{
  1532. + Elf64_Word l_name;
  1533. + Elf64_Word l_time_stamp;
  1534. + Elf64_Word l_checksum;
  1535. + Elf64_Word l_version;
  1536. + Elf64_Word l_flags;
  1537. +} Elf64_Lib;
  1538. +
  1539. +
  1540. +
  1541. +
  1542. +#define LL_NONE 0
  1543. +#define LL_EXACT_MATCH (1 << 0)
  1544. +#define LL_IGNORE_INT_VER (1 << 1)
  1545. +#define LL_REQUIRE_MINOR (1 << 2)
  1546. +#define LL_EXPORTS (1 << 3)
  1547. +#define LL_DELAY_LOAD (1 << 4)
  1548. +#define LL_DELTA (1 << 5)
  1549. +
  1550. +
  1551. +
  1552. +typedef Elf32_Addr Elf32_Conflict;
  1553. +
  1554. +
  1555. +
  1556. +
  1557. +
  1558. +
  1559. +#define EF_PARISC_TRAPNIL 0x00010000
  1560. +#define EF_PARISC_EXT 0x00020000
  1561. +#define EF_PARISC_LSB 0x00040000
  1562. +#define EF_PARISC_WIDE 0x00080000
  1563. +#define EF_PARISC_NO_KABP 0x00100000
  1564. +
  1565. +#define EF_PARISC_LAZYSWAP 0x00400000
  1566. +#define EF_PARISC_ARCH 0x0000ffff
  1567. +
  1568. +
  1569. +
  1570. +#define EFA_PARISC_1_0 0x020b
  1571. +#define EFA_PARISC_1_1 0x0210
  1572. +#define EFA_PARISC_2_0 0x0214
  1573. +
  1574. +
  1575. +
  1576. +#define SHN_PARISC_ANSI_COMMON 0xff00
  1577. +
  1578. +#define SHN_PARISC_HUGE_COMMON 0xff01
  1579. +
  1580. +
  1581. +
  1582. +#define SHT_PARISC_EXT 0x70000000
  1583. +#define SHT_PARISC_UNWIND 0x70000001
  1584. +#define SHT_PARISC_DOC 0x70000002
  1585. +
  1586. +
  1587. +
  1588. +#define SHF_PARISC_SHORT 0x20000000
  1589. +#define SHF_PARISC_HUGE 0x40000000
  1590. +#define SHF_PARISC_SBP 0x80000000
  1591. +
  1592. +
  1593. +
  1594. +#define STT_PARISC_MILLICODE 13
  1595. +
  1596. +#define STT_HP_OPAQUE (STT_LOOS + 0x1)
  1597. +#define STT_HP_STUB (STT_LOOS + 0x2)
  1598. +
  1599. +
  1600. +
  1601. +#define R_PARISC_NONE 0
  1602. +#define R_PARISC_DIR32 1
  1603. +#define R_PARISC_DIR21L 2
  1604. +#define R_PARISC_DIR17R 3
  1605. +#define R_PARISC_DIR17F 4
  1606. +#define R_PARISC_DIR14R 6
  1607. +#define R_PARISC_PCREL32 9
  1608. +#define R_PARISC_PCREL21L 10
  1609. +#define R_PARISC_PCREL17R 11
  1610. +#define R_PARISC_PCREL17F 12
  1611. +#define R_PARISC_PCREL14R 14
  1612. +#define R_PARISC_DPREL21L 18
  1613. +#define R_PARISC_DPREL14R 22
  1614. +#define R_PARISC_GPREL21L 26
  1615. +#define R_PARISC_GPREL14R 30
  1616. +#define R_PARISC_LTOFF21L 34
  1617. +#define R_PARISC_LTOFF14R 38
  1618. +#define R_PARISC_SECREL32 41
  1619. +#define R_PARISC_SEGBASE 48
  1620. +#define R_PARISC_SEGREL32 49
  1621. +#define R_PARISC_PLTOFF21L 50
  1622. +#define R_PARISC_PLTOFF14R 54
  1623. +#define R_PARISC_LTOFF_FPTR32 57
  1624. +#define R_PARISC_LTOFF_FPTR21L 58
  1625. +#define R_PARISC_LTOFF_FPTR14R 62
  1626. +#define R_PARISC_FPTR64 64
  1627. +#define R_PARISC_PLABEL32 65
  1628. +#define R_PARISC_PLABEL21L 66
  1629. +#define R_PARISC_PLABEL14R 70
  1630. +#define R_PARISC_PCREL64 72
  1631. +#define R_PARISC_PCREL22F 74
  1632. +#define R_PARISC_PCREL14WR 75
  1633. +#define R_PARISC_PCREL14DR 76
  1634. +#define R_PARISC_PCREL16F 77
  1635. +#define R_PARISC_PCREL16WF 78
  1636. +#define R_PARISC_PCREL16DF 79
  1637. +#define R_PARISC_DIR64 80
  1638. +#define R_PARISC_DIR14WR 83
  1639. +#define R_PARISC_DIR14DR 84
  1640. +#define R_PARISC_DIR16F 85
  1641. +#define R_PARISC_DIR16WF 86
  1642. +#define R_PARISC_DIR16DF 87
  1643. +#define R_PARISC_GPREL64 88
  1644. +#define R_PARISC_GPREL14WR 91
  1645. +#define R_PARISC_GPREL14DR 92
  1646. +#define R_PARISC_GPREL16F 93
  1647. +#define R_PARISC_GPREL16WF 94
  1648. +#define R_PARISC_GPREL16DF 95
  1649. +#define R_PARISC_LTOFF64 96
  1650. +#define R_PARISC_LTOFF14WR 99
  1651. +#define R_PARISC_LTOFF14DR 100
  1652. +#define R_PARISC_LTOFF16F 101
  1653. +#define R_PARISC_LTOFF16WF 102
  1654. +#define R_PARISC_LTOFF16DF 103
  1655. +#define R_PARISC_SECREL64 104
  1656. +#define R_PARISC_SEGREL64 112
  1657. +#define R_PARISC_PLTOFF14WR 115
  1658. +#define R_PARISC_PLTOFF14DR 116
  1659. +#define R_PARISC_PLTOFF16F 117
  1660. +#define R_PARISC_PLTOFF16WF 118
  1661. +#define R_PARISC_PLTOFF16DF 119
  1662. +#define R_PARISC_LTOFF_FPTR64 120
  1663. +#define R_PARISC_LTOFF_FPTR14WR 123
  1664. +#define R_PARISC_LTOFF_FPTR14DR 124
  1665. +#define R_PARISC_LTOFF_FPTR16F 125
  1666. +#define R_PARISC_LTOFF_FPTR16WF 126
  1667. +#define R_PARISC_LTOFF_FPTR16DF 127
  1668. +#define R_PARISC_LORESERVE 128
  1669. +#define R_PARISC_COPY 128
  1670. +#define R_PARISC_IPLT 129
  1671. +#define R_PARISC_EPLT 130
  1672. +#define R_PARISC_TPREL32 153
  1673. +#define R_PARISC_TPREL21L 154
  1674. +#define R_PARISC_TPREL14R 158
  1675. +#define R_PARISC_LTOFF_TP21L 162
  1676. +#define R_PARISC_LTOFF_TP14R 166
  1677. +#define R_PARISC_LTOFF_TP14F 167
  1678. +#define R_PARISC_TPREL64 216
  1679. +#define R_PARISC_TPREL14WR 219
  1680. +#define R_PARISC_TPREL14DR 220
  1681. +#define R_PARISC_TPREL16F 221
  1682. +#define R_PARISC_TPREL16WF 222
  1683. +#define R_PARISC_TPREL16DF 223
  1684. +#define R_PARISC_LTOFF_TP64 224
  1685. +#define R_PARISC_LTOFF_TP14WR 227
  1686. +#define R_PARISC_LTOFF_TP14DR 228
  1687. +#define R_PARISC_LTOFF_TP16F 229
  1688. +#define R_PARISC_LTOFF_TP16WF 230
  1689. +#define R_PARISC_LTOFF_TP16DF 231
  1690. +#define R_PARISC_GNU_VTENTRY 232
  1691. +#define R_PARISC_GNU_VTINHERIT 233
  1692. +#define R_PARISC_TLS_GD21L 234
  1693. +#define R_PARISC_TLS_GD14R 235
  1694. +#define R_PARISC_TLS_GDCALL 236
  1695. +#define R_PARISC_TLS_LDM21L 237
  1696. +#define R_PARISC_TLS_LDM14R 238
  1697. +#define R_PARISC_TLS_LDMCALL 239
  1698. +#define R_PARISC_TLS_LDO21L 240
  1699. +#define R_PARISC_TLS_LDO14R 241
  1700. +#define R_PARISC_TLS_DTPMOD32 242
  1701. +#define R_PARISC_TLS_DTPMOD64 243
  1702. +#define R_PARISC_TLS_DTPOFF32 244
  1703. +#define R_PARISC_TLS_DTPOFF64 245
  1704. +#define R_PARISC_TLS_LE21L R_PARISC_TPREL21L
  1705. +#define R_PARISC_TLS_LE14R R_PARISC_TPREL14R
  1706. +#define R_PARISC_TLS_IE21L R_PARISC_LTOFF_TP21L
  1707. +#define R_PARISC_TLS_IE14R R_PARISC_LTOFF_TP14R
  1708. +#define R_PARISC_TLS_TPREL32 R_PARISC_TPREL32
  1709. +#define R_PARISC_TLS_TPREL64 R_PARISC_TPREL64
  1710. +#define R_PARISC_HIRESERVE 255
  1711. +
  1712. +
  1713. +
  1714. +#define PT_HP_TLS (PT_LOOS + 0x0)
  1715. +#define PT_HP_CORE_NONE (PT_LOOS + 0x1)
  1716. +#define PT_HP_CORE_VERSION (PT_LOOS + 0x2)
  1717. +#define PT_HP_CORE_KERNEL (PT_LOOS + 0x3)
  1718. +#define PT_HP_CORE_COMM (PT_LOOS + 0x4)
  1719. +#define PT_HP_CORE_PROC (PT_LOOS + 0x5)
  1720. +#define PT_HP_CORE_LOADABLE (PT_LOOS + 0x6)
  1721. +#define PT_HP_CORE_STACK (PT_LOOS + 0x7)
  1722. +#define PT_HP_CORE_SHM (PT_LOOS + 0x8)
  1723. +#define PT_HP_CORE_MMF (PT_LOOS + 0x9)
  1724. +#define PT_HP_PARALLEL (PT_LOOS + 0x10)
  1725. +#define PT_HP_FASTBIND (PT_LOOS + 0x11)
  1726. +#define PT_HP_OPT_ANNOT (PT_LOOS + 0x12)
  1727. +#define PT_HP_HSL_ANNOT (PT_LOOS + 0x13)
  1728. +#define PT_HP_STACK (PT_LOOS + 0x14)
  1729. +
  1730. +#define PT_PARISC_ARCHEXT 0x70000000
  1731. +#define PT_PARISC_UNWIND 0x70000001
  1732. +
  1733. +
  1734. +
  1735. +#define PF_PARISC_SBP 0x08000000
  1736. +
  1737. +#define PF_HP_PAGE_SIZE 0x00100000
  1738. +#define PF_HP_FAR_SHARED 0x00200000
  1739. +#define PF_HP_NEAR_SHARED 0x00400000
  1740. +#define PF_HP_CODE 0x01000000
  1741. +#define PF_HP_MODIFY 0x02000000
  1742. +#define PF_HP_LAZYSWAP 0x04000000
  1743. +#define PF_HP_SBP 0x08000000
  1744. +
  1745. +
  1746. +
  1747. +
  1748. +
  1749. +
  1750. +#define EF_ALPHA_32BIT 1
  1751. +#define EF_ALPHA_CANRELAX 2
  1752. +
  1753. +
  1754. +
  1755. +
  1756. +#define SHT_ALPHA_DEBUG 0x70000001
  1757. +#define SHT_ALPHA_REGINFO 0x70000002
  1758. +
  1759. +
  1760. +
  1761. +#define SHF_ALPHA_GPREL 0x10000000
  1762. +
  1763. +
  1764. +#define STO_ALPHA_NOPV 0x80
  1765. +#define STO_ALPHA_STD_GPLOAD 0x88
  1766. +
  1767. +
  1768. +
  1769. +#define R_ALPHA_NONE 0
  1770. +#define R_ALPHA_REFLONG 1
  1771. +#define R_ALPHA_REFQUAD 2
  1772. +#define R_ALPHA_GPREL32 3
  1773. +#define R_ALPHA_LITERAL 4
  1774. +#define R_ALPHA_LITUSE 5
  1775. +#define R_ALPHA_GPDISP 6
  1776. +#define R_ALPHA_BRADDR 7
  1777. +#define R_ALPHA_HINT 8
  1778. +#define R_ALPHA_SREL16 9
  1779. +#define R_ALPHA_SREL32 10
  1780. +#define R_ALPHA_SREL64 11
  1781. +#define R_ALPHA_GPRELHIGH 17
  1782. +#define R_ALPHA_GPRELLOW 18
  1783. +#define R_ALPHA_GPREL16 19
  1784. +#define R_ALPHA_COPY 24
  1785. +#define R_ALPHA_GLOB_DAT 25
  1786. +#define R_ALPHA_JMP_SLOT 26
  1787. +#define R_ALPHA_RELATIVE 27
  1788. +#define R_ALPHA_TLS_GD_HI 28
  1789. +#define R_ALPHA_TLSGD 29
  1790. +#define R_ALPHA_TLS_LDM 30
  1791. +#define R_ALPHA_DTPMOD64 31
  1792. +#define R_ALPHA_GOTDTPREL 32
  1793. +#define R_ALPHA_DTPREL64 33
  1794. +#define R_ALPHA_DTPRELHI 34
  1795. +#define R_ALPHA_DTPRELLO 35
  1796. +#define R_ALPHA_DTPREL16 36
  1797. +#define R_ALPHA_GOTTPREL 37
  1798. +#define R_ALPHA_TPREL64 38
  1799. +#define R_ALPHA_TPRELHI 39
  1800. +#define R_ALPHA_TPRELLO 40
  1801. +#define R_ALPHA_TPREL16 41
  1802. +
  1803. +#define R_ALPHA_NUM 46
  1804. +
  1805. +
  1806. +#define LITUSE_ALPHA_ADDR 0
  1807. +#define LITUSE_ALPHA_BASE 1
  1808. +#define LITUSE_ALPHA_BYTOFF 2
  1809. +#define LITUSE_ALPHA_JSR 3
  1810. +#define LITUSE_ALPHA_TLS_GD 4
  1811. +#define LITUSE_ALPHA_TLS_LDM 5
  1812. +
  1813. +
  1814. +#define DT_ALPHA_PLTRO (DT_LOPROC + 0)
  1815. +#define DT_ALPHA_NUM 1
  1816. +
  1817. +
  1818. +
  1819. +
  1820. +#define EF_PPC_EMB 0x80000000
  1821. +
  1822. +
  1823. +#define EF_PPC_RELOCATABLE 0x00010000
  1824. +#define EF_PPC_RELOCATABLE_LIB 0x00008000
  1825. +
  1826. +
  1827. +
  1828. +#define R_PPC_NONE 0
  1829. +#define R_PPC_ADDR32 1
  1830. +#define R_PPC_ADDR24 2
  1831. +#define R_PPC_ADDR16 3
  1832. +#define R_PPC_ADDR16_LO 4
  1833. +#define R_PPC_ADDR16_HI 5
  1834. +#define R_PPC_ADDR16_HA 6
  1835. +#define R_PPC_ADDR14 7
  1836. +#define R_PPC_ADDR14_BRTAKEN 8
  1837. +#define R_PPC_ADDR14_BRNTAKEN 9
  1838. +#define R_PPC_REL24 10
  1839. +#define R_PPC_REL14 11
  1840. +#define R_PPC_REL14_BRTAKEN 12
  1841. +#define R_PPC_REL14_BRNTAKEN 13
  1842. +#define R_PPC_GOT16 14
  1843. +#define R_PPC_GOT16_LO 15
  1844. +#define R_PPC_GOT16_HI 16
  1845. +#define R_PPC_GOT16_HA 17
  1846. +#define R_PPC_PLTREL24 18
  1847. +#define R_PPC_COPY 19
  1848. +#define R_PPC_GLOB_DAT 20
  1849. +#define R_PPC_JMP_SLOT 21
  1850. +#define R_PPC_RELATIVE 22
  1851. +#define R_PPC_LOCAL24PC 23
  1852. +#define R_PPC_UADDR32 24
  1853. +#define R_PPC_UADDR16 25
  1854. +#define R_PPC_REL32 26
  1855. +#define R_PPC_PLT32 27
  1856. +#define R_PPC_PLTREL32 28
  1857. +#define R_PPC_PLT16_LO 29
  1858. +#define R_PPC_PLT16_HI 30
  1859. +#define R_PPC_PLT16_HA 31
  1860. +#define R_PPC_SDAREL16 32
  1861. +#define R_PPC_SECTOFF 33
  1862. +#define R_PPC_SECTOFF_LO 34
  1863. +#define R_PPC_SECTOFF_HI 35
  1864. +#define R_PPC_SECTOFF_HA 36
  1865. +
  1866. +
  1867. +#define R_PPC_TLS 67
  1868. +#define R_PPC_DTPMOD32 68
  1869. +#define R_PPC_TPREL16 69
  1870. +#define R_PPC_TPREL16_LO 70
  1871. +#define R_PPC_TPREL16_HI 71
  1872. +#define R_PPC_TPREL16_HA 72
  1873. +#define R_PPC_TPREL32 73
  1874. +#define R_PPC_DTPREL16 74
  1875. +#define R_PPC_DTPREL16_LO 75
  1876. +#define R_PPC_DTPREL16_HI 76
  1877. +#define R_PPC_DTPREL16_HA 77
  1878. +#define R_PPC_DTPREL32 78
  1879. +#define R_PPC_GOT_TLSGD16 79
  1880. +#define R_PPC_GOT_TLSGD16_LO 80
  1881. +#define R_PPC_GOT_TLSGD16_HI 81
  1882. +#define R_PPC_GOT_TLSGD16_HA 82
  1883. +#define R_PPC_GOT_TLSLD16 83
  1884. +#define R_PPC_GOT_TLSLD16_LO 84
  1885. +#define R_PPC_GOT_TLSLD16_HI 85
  1886. +#define R_PPC_GOT_TLSLD16_HA 86
  1887. +#define R_PPC_GOT_TPREL16 87
  1888. +#define R_PPC_GOT_TPREL16_LO 88
  1889. +#define R_PPC_GOT_TPREL16_HI 89
  1890. +#define R_PPC_GOT_TPREL16_HA 90
  1891. +#define R_PPC_GOT_DTPREL16 91
  1892. +#define R_PPC_GOT_DTPREL16_LO 92
  1893. +#define R_PPC_GOT_DTPREL16_HI 93
  1894. +#define R_PPC_GOT_DTPREL16_HA 94
  1895. +
  1896. +
  1897. +
  1898. +#define R_PPC_EMB_NADDR32 101
  1899. +#define R_PPC_EMB_NADDR16 102
  1900. +#define R_PPC_EMB_NADDR16_LO 103
  1901. +#define R_PPC_EMB_NADDR16_HI 104
  1902. +#define R_PPC_EMB_NADDR16_HA 105
  1903. +#define R_PPC_EMB_SDAI16 106
  1904. +#define R_PPC_EMB_SDA2I16 107
  1905. +#define R_PPC_EMB_SDA2REL 108
  1906. +#define R_PPC_EMB_SDA21 109
  1907. +#define R_PPC_EMB_MRKREF 110
  1908. +#define R_PPC_EMB_RELSEC16 111
  1909. +#define R_PPC_EMB_RELST_LO 112
  1910. +#define R_PPC_EMB_RELST_HI 113
  1911. +#define R_PPC_EMB_RELST_HA 114
  1912. +#define R_PPC_EMB_BIT_FLD 115
  1913. +#define R_PPC_EMB_RELSDA 116
  1914. +
  1915. +
  1916. +#define R_PPC_DIAB_SDA21_LO 180
  1917. +#define R_PPC_DIAB_SDA21_HI 181
  1918. +#define R_PPC_DIAB_SDA21_HA 182
  1919. +#define R_PPC_DIAB_RELSDA_LO 183
  1920. +#define R_PPC_DIAB_RELSDA_HI 184
  1921. +#define R_PPC_DIAB_RELSDA_HA 185
  1922. +
  1923. +
  1924. +#define R_PPC_IRELATIVE 248
  1925. +
  1926. +
  1927. +#define R_PPC_REL16 249
  1928. +#define R_PPC_REL16_LO 250
  1929. +#define R_PPC_REL16_HI 251
  1930. +#define R_PPC_REL16_HA 252
  1931. +
  1932. +
  1933. +
  1934. +#define R_PPC_TOC16 255
  1935. +
  1936. +
  1937. +#define DT_PPC_GOT (DT_LOPROC + 0)
  1938. +#define DT_PPC_NUM 1
  1939. +
  1940. +
  1941. +#define R_PPC64_NONE R_PPC_NONE
  1942. +#define R_PPC64_ADDR32 R_PPC_ADDR32
  1943. +#define R_PPC64_ADDR24 R_PPC_ADDR24
  1944. +#define R_PPC64_ADDR16 R_PPC_ADDR16
  1945. +#define R_PPC64_ADDR16_LO R_PPC_ADDR16_LO
  1946. +#define R_PPC64_ADDR16_HI R_PPC_ADDR16_HI
  1947. +#define R_PPC64_ADDR16_HA R_PPC_ADDR16_HA
  1948. +#define R_PPC64_ADDR14 R_PPC_ADDR14
  1949. +#define R_PPC64_ADDR14_BRTAKEN R_PPC_ADDR14_BRTAKEN
  1950. +#define R_PPC64_ADDR14_BRNTAKEN R_PPC_ADDR14_BRNTAKEN
  1951. +#define R_PPC64_REL24 R_PPC_REL24
  1952. +#define R_PPC64_REL14 R_PPC_REL14
  1953. +#define R_PPC64_REL14_BRTAKEN R_PPC_REL14_BRTAKEN
  1954. +#define R_PPC64_REL14_BRNTAKEN R_PPC_REL14_BRNTAKEN
  1955. +#define R_PPC64_GOT16 R_PPC_GOT16
  1956. +#define R_PPC64_GOT16_LO R_PPC_GOT16_LO
  1957. +#define R_PPC64_GOT16_HI R_PPC_GOT16_HI
  1958. +#define R_PPC64_GOT16_HA R_PPC_GOT16_HA
  1959. +
  1960. +#define R_PPC64_COPY R_PPC_COPY
  1961. +#define R_PPC64_GLOB_DAT R_PPC_GLOB_DAT
  1962. +#define R_PPC64_JMP_SLOT R_PPC_JMP_SLOT
  1963. +#define R_PPC64_RELATIVE R_PPC_RELATIVE
  1964. +
  1965. +#define R_PPC64_UADDR32 R_PPC_UADDR32
  1966. +#define R_PPC64_UADDR16 R_PPC_UADDR16
  1967. +#define R_PPC64_REL32 R_PPC_REL32
  1968. +#define R_PPC64_PLT32 R_PPC_PLT32
  1969. +#define R_PPC64_PLTREL32 R_PPC_PLTREL32
  1970. +#define R_PPC64_PLT16_LO R_PPC_PLT16_LO
  1971. +#define R_PPC64_PLT16_HI R_PPC_PLT16_HI
  1972. +#define R_PPC64_PLT16_HA R_PPC_PLT16_HA
  1973. +
  1974. +#define R_PPC64_SECTOFF R_PPC_SECTOFF
  1975. +#define R_PPC64_SECTOFF_LO R_PPC_SECTOFF_LO
  1976. +#define R_PPC64_SECTOFF_HI R_PPC_SECTOFF_HI
  1977. +#define R_PPC64_SECTOFF_HA R_PPC_SECTOFF_HA
  1978. +#define R_PPC64_ADDR30 37
  1979. +#define R_PPC64_ADDR64 38
  1980. +#define R_PPC64_ADDR16_HIGHER 39
  1981. +#define R_PPC64_ADDR16_HIGHERA 40
  1982. +#define R_PPC64_ADDR16_HIGHEST 41
  1983. +#define R_PPC64_ADDR16_HIGHESTA 42
  1984. +#define R_PPC64_UADDR64 43
  1985. +#define R_PPC64_REL64 44
  1986. +#define R_PPC64_PLT64 45
  1987. +#define R_PPC64_PLTREL64 46
  1988. +#define R_PPC64_TOC16 47
  1989. +#define R_PPC64_TOC16_LO 48
  1990. +#define R_PPC64_TOC16_HI 49
  1991. +#define R_PPC64_TOC16_HA 50
  1992. +#define R_PPC64_TOC 51
  1993. +#define R_PPC64_PLTGOT16 52
  1994. +#define R_PPC64_PLTGOT16_LO 53
  1995. +#define R_PPC64_PLTGOT16_HI 54
  1996. +#define R_PPC64_PLTGOT16_HA 55
  1997. +
  1998. +#define R_PPC64_ADDR16_DS 56
  1999. +#define R_PPC64_ADDR16_LO_DS 57
  2000. +#define R_PPC64_GOT16_DS 58
  2001. +#define R_PPC64_GOT16_LO_DS 59
  2002. +#define R_PPC64_PLT16_LO_DS 60
  2003. +#define R_PPC64_SECTOFF_DS 61
  2004. +#define R_PPC64_SECTOFF_LO_DS 62
  2005. +#define R_PPC64_TOC16_DS 63
  2006. +#define R_PPC64_TOC16_LO_DS 64
  2007. +#define R_PPC64_PLTGOT16_DS 65
  2008. +#define R_PPC64_PLTGOT16_LO_DS 66
  2009. +
  2010. +
  2011. +#define R_PPC64_TLS 67
  2012. +#define R_PPC64_DTPMOD64 68
  2013. +#define R_PPC64_TPREL16 69
  2014. +#define R_PPC64_TPREL16_LO 70
  2015. +#define R_PPC64_TPREL16_HI 71
  2016. +#define R_PPC64_TPREL16_HA 72
  2017. +#define R_PPC64_TPREL64 73
  2018. +#define R_PPC64_DTPREL16 74
  2019. +#define R_PPC64_DTPREL16_LO 75
  2020. +#define R_PPC64_DTPREL16_HI 76
  2021. +#define R_PPC64_DTPREL16_HA 77
  2022. +#define R_PPC64_DTPREL64 78
  2023. +#define R_PPC64_GOT_TLSGD16 79
  2024. +#define R_PPC64_GOT_TLSGD16_LO 80
  2025. +#define R_PPC64_GOT_TLSGD16_HI 81
  2026. +#define R_PPC64_GOT_TLSGD16_HA 82
  2027. +#define R_PPC64_GOT_TLSLD16 83
  2028. +#define R_PPC64_GOT_TLSLD16_LO 84
  2029. +#define R_PPC64_GOT_TLSLD16_HI 85
  2030. +#define R_PPC64_GOT_TLSLD16_HA 86
  2031. +#define R_PPC64_GOT_TPREL16_DS 87
  2032. +#define R_PPC64_GOT_TPREL16_LO_DS 88
  2033. +#define R_PPC64_GOT_TPREL16_HI 89
  2034. +#define R_PPC64_GOT_TPREL16_HA 90
  2035. +#define R_PPC64_GOT_DTPREL16_DS 91
  2036. +#define R_PPC64_GOT_DTPREL16_LO_DS 92
  2037. +#define R_PPC64_GOT_DTPREL16_HI 93
  2038. +#define R_PPC64_GOT_DTPREL16_HA 94
  2039. +#define R_PPC64_TPREL16_DS 95
  2040. +#define R_PPC64_TPREL16_LO_DS 96
  2041. +#define R_PPC64_TPREL16_HIGHER 97
  2042. +#define R_PPC64_TPREL16_HIGHERA 98
  2043. +#define R_PPC64_TPREL16_HIGHEST 99
  2044. +#define R_PPC64_TPREL16_HIGHESTA 100
  2045. +#define R_PPC64_DTPREL16_DS 101
  2046. +#define R_PPC64_DTPREL16_LO_DS 102
  2047. +#define R_PPC64_DTPREL16_HIGHER 103
  2048. +#define R_PPC64_DTPREL16_HIGHERA 104
  2049. +#define R_PPC64_DTPREL16_HIGHEST 105
  2050. +#define R_PPC64_DTPREL16_HIGHESTA 106
  2051. +
  2052. +
  2053. +#define R_PPC64_JMP_IREL 247
  2054. +#define R_PPC64_IRELATIVE 248
  2055. +#define R_PPC64_REL16 249
  2056. +#define R_PPC64_REL16_LO 250
  2057. +#define R_PPC64_REL16_HI 251
  2058. +#define R_PPC64_REL16_HA 252
  2059. +
  2060. +
  2061. +#define DT_PPC64_GLINK (DT_LOPROC + 0)
  2062. +#define DT_PPC64_OPD (DT_LOPROC + 1)
  2063. +#define DT_PPC64_OPDSZ (DT_LOPROC + 2)
  2064. +#define DT_PPC64_NUM 3
  2065. +
  2066. +
  2067. +
  2068. +
  2069. +
  2070. +#define EF_ARM_RELEXEC 0x01
  2071. +#define EF_ARM_HASENTRY 0x02
  2072. +#define EF_ARM_INTERWORK 0x04
  2073. +#define EF_ARM_APCS_26 0x08
  2074. +#define EF_ARM_APCS_FLOAT 0x10
  2075. +#define EF_ARM_PIC 0x20
  2076. +#define EF_ARM_ALIGN8 0x40
  2077. +#define EF_ARM_NEW_ABI 0x80
  2078. +#define EF_ARM_OLD_ABI 0x100
  2079. +#define EF_ARM_SOFT_FLOAT 0x200
  2080. +#define EF_ARM_VFP_FLOAT 0x400
  2081. +#define EF_ARM_MAVERICK_FLOAT 0x800
  2082. +
  2083. +#define EF_ARM_ABI_FLOAT_SOFT 0x200
  2084. +#define EF_ARM_ABI_FLOAT_HARD 0x400
  2085. +
  2086. +
  2087. +#define EF_ARM_SYMSARESORTED 0x04
  2088. +#define EF_ARM_DYNSYMSUSESEGIDX 0x08
  2089. +#define EF_ARM_MAPSYMSFIRST 0x10
  2090. +#define EF_ARM_EABIMASK 0XFF000000
  2091. +
  2092. +
  2093. +#define EF_ARM_BE8 0x00800000
  2094. +#define EF_ARM_LE8 0x00400000
  2095. +
  2096. +#define EF_ARM_EABI_VERSION(flags) ((flags) & EF_ARM_EABIMASK)
  2097. +#define EF_ARM_EABI_UNKNOWN 0x00000000
  2098. +#define EF_ARM_EABI_VER1 0x01000000
  2099. +#define EF_ARM_EABI_VER2 0x02000000
  2100. +#define EF_ARM_EABI_VER3 0x03000000
  2101. +#define EF_ARM_EABI_VER4 0x04000000
  2102. +#define EF_ARM_EABI_VER5 0x05000000
  2103. +
  2104. +
  2105. +#define STT_ARM_TFUNC STT_LOPROC
  2106. +#define STT_ARM_16BIT STT_HIPROC
  2107. +
  2108. +
  2109. +#define SHF_ARM_ENTRYSECT 0x10000000
  2110. +#define SHF_ARM_COMDEF 0x80000000
  2111. +
  2112. +
  2113. +
  2114. +#define PF_ARM_SB 0x10000000
  2115. +
  2116. +#define PF_ARM_PI 0x20000000
  2117. +#define PF_ARM_ABS 0x40000000
  2118. +
  2119. +
  2120. +#define PT_ARM_EXIDX (PT_LOPROC + 1)
  2121. +
  2122. +
  2123. +#define SHT_ARM_EXIDX (SHT_LOPROC + 1)
  2124. +#define SHT_ARM_PREEMPTMAP (SHT_LOPROC + 2)
  2125. +#define SHT_ARM_ATTRIBUTES (SHT_LOPROC + 3)
  2126. +
  2127. +
  2128. +#define R_AARCH64_NONE 0
  2129. +#define R_AARCH64_ABS64 257
  2130. +#define R_AARCH64_ABS32 258
  2131. +#define R_AARCH64_COPY 1024
  2132. +#define R_AARCH64_GLOB_DAT 1025
  2133. +#define R_AARCH64_JUMP_SLOT 1026
  2134. +#define R_AARCH64_RELATIVE 1027
  2135. +#define R_AARCH64_TLS_DTPMOD64 1028
  2136. +#define R_AARCH64_TLS_DTPREL64 1029
  2137. +#define R_AARCH64_TLS_TPREL64 1030
  2138. +#define R_AARCH64_TLSDESC 1031
  2139. +
  2140. +
  2141. +#define R_ARM_NONE 0
  2142. +#define R_ARM_PC24 1
  2143. +#define R_ARM_ABS32 2
  2144. +#define R_ARM_REL32 3
  2145. +#define R_ARM_PC13 4
  2146. +#define R_ARM_ABS16 5
  2147. +#define R_ARM_ABS12 6
  2148. +#define R_ARM_THM_ABS5 7
  2149. +#define R_ARM_ABS8 8
  2150. +#define R_ARM_SBREL32 9
  2151. +#define R_ARM_THM_PC22 10
  2152. +#define R_ARM_THM_PC8 11
  2153. +#define R_ARM_AMP_VCALL9 12
  2154. +#define R_ARM_TLS_DESC 13
  2155. +#define R_ARM_THM_SWI8 14
  2156. +#define R_ARM_XPC25 15
  2157. +#define R_ARM_THM_XPC22 16
  2158. +#define R_ARM_TLS_DTPMOD32 17
  2159. +#define R_ARM_TLS_DTPOFF32 18
  2160. +#define R_ARM_TLS_TPOFF32 19
  2161. +#define R_ARM_COPY 20
  2162. +#define R_ARM_GLOB_DAT 21
  2163. +#define R_ARM_JUMP_SLOT 22
  2164. +#define R_ARM_RELATIVE 23
  2165. +#define R_ARM_GOTOFF 24
  2166. +#define R_ARM_GOTPC 25
  2167. +#define R_ARM_GOT32 26
  2168. +#define R_ARM_PLT32 27
  2169. +#define R_ARM_CALL 28
  2170. +#define R_ARM_JUMP24 29
  2171. +#define R_ARM_THM_JUMP24 30
  2172. +#define R_ARM_BASE_ABS 31
  2173. +#define R_ARM_ALU_PCREL_7_0 32
  2174. +#define R_ARM_ALU_PCREL_15_8 33
  2175. +#define R_ARM_ALU_PCREL_23_15 34
  2176. +#define R_ARM_LDR_SBREL_11_0 35
  2177. +#define R_ARM_ALU_SBREL_19_12 36
  2178. +#define R_ARM_ALU_SBREL_27_20 37
  2179. +#define R_ARM_TARGET1 38
  2180. +#define R_ARM_SBREL31 39
  2181. +#define R_ARM_V4BX 40
  2182. +#define R_ARM_TARGET2 41
  2183. +#define R_ARM_PREL31 42
  2184. +#define R_ARM_MOVW_ABS_NC 43
  2185. +#define R_ARM_MOVT_ABS 44
  2186. +#define R_ARM_MOVW_PREL_NC 45
  2187. +#define R_ARM_MOVT_PREL 46
  2188. +#define R_ARM_THM_MOVW_ABS_NC 47
  2189. +#define R_ARM_THM_MOVT_ABS 48
  2190. +#define R_ARM_THM_MOVW_PREL_NC 49
  2191. +#define R_ARM_THM_MOVT_PREL 50
  2192. +#define R_ARM_THM_JUMP19 51
  2193. +#define R_ARM_THM_JUMP6 52
  2194. +#define R_ARM_THM_ALU_PREL_11_0 53
  2195. +#define R_ARM_THM_PC12 54
  2196. +#define R_ARM_ABS32_NOI 55
  2197. +#define R_ARM_REL32_NOI 56
  2198. +#define R_ARM_ALU_PC_G0_NC 57
  2199. +#define R_ARM_ALU_PC_G0 58
  2200. +#define R_ARM_ALU_PC_G1_NC 59
  2201. +#define R_ARM_ALU_PC_G1 60
  2202. +#define R_ARM_ALU_PC_G2 61
  2203. +#define R_ARM_LDR_PC_G1 62
  2204. +#define R_ARM_LDR_PC_G2 63
  2205. +#define R_ARM_LDRS_PC_G0 64
  2206. +#define R_ARM_LDRS_PC_G1 65
  2207. +#define R_ARM_LDRS_PC_G2 66
  2208. +#define R_ARM_LDC_PC_G0 67
  2209. +#define R_ARM_LDC_PC_G1 68
  2210. +#define R_ARM_LDC_PC_G2 69
  2211. +#define R_ARM_ALU_SB_G0_NC 70
  2212. +#define R_ARM_ALU_SB_G0 71
  2213. +#define R_ARM_ALU_SB_G1_NC 72
  2214. +#define R_ARM_ALU_SB_G1 73
  2215. +#define R_ARM_ALU_SB_G2 74
  2216. +#define R_ARM_LDR_SB_G0 75
  2217. +#define R_ARM_LDR_SB_G1 76
  2218. +#define R_ARM_LDR_SB_G2 77
  2219. +#define R_ARM_LDRS_SB_G0 78
  2220. +#define R_ARM_LDRS_SB_G1 79
  2221. +#define R_ARM_LDRS_SB_G2 80
  2222. +#define R_ARM_LDC_SB_G0 81
  2223. +#define R_ARM_LDC_SB_G1 82
  2224. +#define R_ARM_LDC_SB_G2 83
  2225. +#define R_ARM_MOVW_BREL_NC 84
  2226. +#define R_ARM_MOVT_BREL 85
  2227. +#define R_ARM_MOVW_BREL 86
  2228. +#define R_ARM_THM_MOVW_BREL_NC 87
  2229. +#define R_ARM_THM_MOVT_BREL 88
  2230. +#define R_ARM_THM_MOVW_BREL 89
  2231. +#define R_ARM_TLS_GOTDESC 90
  2232. +#define R_ARM_TLS_CALL 91
  2233. +#define R_ARM_TLS_DESCSEQ 92
  2234. +#define R_ARM_THM_TLS_CALL 93
  2235. +#define R_ARM_PLT32_ABS 94
  2236. +#define R_ARM_GOT_ABS 95
  2237. +#define R_ARM_GOT_PREL 96
  2238. +#define R_ARM_GOT_BREL12 97
  2239. +#define R_ARM_GOTOFF12 98
  2240. +#define R_ARM_GOTRELAX 99
  2241. +#define R_ARM_GNU_VTENTRY 100
  2242. +#define R_ARM_GNU_VTINHERIT 101
  2243. +#define R_ARM_THM_PC11 102
  2244. +#define R_ARM_THM_PC9 103
  2245. +#define R_ARM_TLS_GD32 104
  2246. +
  2247. +#define R_ARM_TLS_LDM32 105
  2248. +
  2249. +#define R_ARM_TLS_LDO32 106
  2250. +
  2251. +#define R_ARM_TLS_IE32 107
  2252. +
  2253. +#define R_ARM_TLS_LE32 108
  2254. +#define R_ARM_TLS_LDO12 109
  2255. +#define R_ARM_TLS_LE12 110
  2256. +#define R_ARM_TLS_IE12GP 111
  2257. +#define R_ARM_ME_TOO 128
  2258. +#define R_ARM_THM_TLS_DESCSEQ 129
  2259. +#define R_ARM_THM_TLS_DESCSEQ16 129
  2260. +#define R_ARM_THM_TLS_DESCSEQ32 130
  2261. +#define R_ARM_THM_GOT_BREL12 131
  2262. +#define R_ARM_IRELATIVE 160
  2263. +#define R_ARM_RXPC25 249
  2264. +#define R_ARM_RSBREL32 250
  2265. +#define R_ARM_THM_RPC22 251
  2266. +#define R_ARM_RREL32 252
  2267. +#define R_ARM_RABS22 253
  2268. +#define R_ARM_RPC24 254
  2269. +#define R_ARM_RBASE 255
  2270. +
  2271. +#define R_ARM_NUM 256
  2272. +
  2273. +
  2274. +
  2275. +
  2276. +#define EF_IA_64_MASKOS 0x0000000f
  2277. +#define EF_IA_64_ABI64 0x00000010
  2278. +#define EF_IA_64_ARCH 0xff000000
  2279. +
  2280. +
  2281. +#define PT_IA_64_ARCHEXT (PT_LOPROC + 0)
  2282. +#define PT_IA_64_UNWIND (PT_LOPROC + 1)
  2283. +#define PT_IA_64_HP_OPT_ANOT (PT_LOOS + 0x12)
  2284. +#define PT_IA_64_HP_HSL_ANOT (PT_LOOS + 0x13)
  2285. +#define PT_IA_64_HP_STACK (PT_LOOS + 0x14)
  2286. +
  2287. +
  2288. +#define PF_IA_64_NORECOV 0x80000000
  2289. +
  2290. +
  2291. +#define SHT_IA_64_EXT (SHT_LOPROC + 0)
  2292. +#define SHT_IA_64_UNWIND (SHT_LOPROC + 1)
  2293. +
  2294. +
  2295. +#define SHF_IA_64_SHORT 0x10000000
  2296. +#define SHF_IA_64_NORECOV 0x20000000
  2297. +
  2298. +
  2299. +#define DT_IA_64_PLT_RESERVE (DT_LOPROC + 0)
  2300. +#define DT_IA_64_NUM 1
  2301. +
  2302. +
  2303. +#define R_IA64_NONE 0x00
  2304. +#define R_IA64_IMM14 0x21
  2305. +#define R_IA64_IMM22 0x22
  2306. +#define R_IA64_IMM64 0x23
  2307. +#define R_IA64_DIR32MSB 0x24
  2308. +#define R_IA64_DIR32LSB 0x25
  2309. +#define R_IA64_DIR64MSB 0x26
  2310. +#define R_IA64_DIR64LSB 0x27
  2311. +#define R_IA64_GPREL22 0x2a
  2312. +#define R_IA64_GPREL64I 0x2b
  2313. +#define R_IA64_GPREL32MSB 0x2c
  2314. +#define R_IA64_GPREL32LSB 0x2d
  2315. +#define R_IA64_GPREL64MSB 0x2e
  2316. +#define R_IA64_GPREL64LSB 0x2f
  2317. +#define R_IA64_LTOFF22 0x32
  2318. +#define R_IA64_LTOFF64I 0x33
  2319. +#define R_IA64_PLTOFF22 0x3a
  2320. +#define R_IA64_PLTOFF64I 0x3b
  2321. +#define R_IA64_PLTOFF64MSB 0x3e
  2322. +#define R_IA64_PLTOFF64LSB 0x3f
  2323. +#define R_IA64_FPTR64I 0x43
  2324. +#define R_IA64_FPTR32MSB 0x44
  2325. +#define R_IA64_FPTR32LSB 0x45
  2326. +#define R_IA64_FPTR64MSB 0x46
  2327. +#define R_IA64_FPTR64LSB 0x47
  2328. +#define R_IA64_PCREL60B 0x48
  2329. +#define R_IA64_PCREL21B 0x49
  2330. +#define R_IA64_PCREL21M 0x4a
  2331. +#define R_IA64_PCREL21F 0x4b
  2332. +#define R_IA64_PCREL32MSB 0x4c
  2333. +#define R_IA64_PCREL32LSB 0x4d
  2334. +#define R_IA64_PCREL64MSB 0x4e
  2335. +#define R_IA64_PCREL64LSB 0x4f
  2336. +#define R_IA64_LTOFF_FPTR22 0x52
  2337. +#define R_IA64_LTOFF_FPTR64I 0x53
  2338. +#define R_IA64_LTOFF_FPTR32MSB 0x54
  2339. +#define R_IA64_LTOFF_FPTR32LSB 0x55
  2340. +#define R_IA64_LTOFF_FPTR64MSB 0x56
  2341. +#define R_IA64_LTOFF_FPTR64LSB 0x57
  2342. +#define R_IA64_SEGREL32MSB 0x5c
  2343. +#define R_IA64_SEGREL32LSB 0x5d
  2344. +#define R_IA64_SEGREL64MSB 0x5e
  2345. +#define R_IA64_SEGREL64LSB 0x5f
  2346. +#define R_IA64_SECREL32MSB 0x64
  2347. +#define R_IA64_SECREL32LSB 0x65
  2348. +#define R_IA64_SECREL64MSB 0x66
  2349. +#define R_IA64_SECREL64LSB 0x67
  2350. +#define R_IA64_REL32MSB 0x6c
  2351. +#define R_IA64_REL32LSB 0x6d
  2352. +#define R_IA64_REL64MSB 0x6e
  2353. +#define R_IA64_REL64LSB 0x6f
  2354. +#define R_IA64_LTV32MSB 0x74
  2355. +#define R_IA64_LTV32LSB 0x75
  2356. +#define R_IA64_LTV64MSB 0x76
  2357. +#define R_IA64_LTV64LSB 0x77
  2358. +#define R_IA64_PCREL21BI 0x79
  2359. +#define R_IA64_PCREL22 0x7a
  2360. +#define R_IA64_PCREL64I 0x7b
  2361. +#define R_IA64_IPLTMSB 0x80
  2362. +#define R_IA64_IPLTLSB 0x81
  2363. +#define R_IA64_COPY 0x84
  2364. +#define R_IA64_SUB 0x85
  2365. +#define R_IA64_LTOFF22X 0x86
  2366. +#define R_IA64_LDXMOV 0x87
  2367. +#define R_IA64_TPREL14 0x91
  2368. +#define R_IA64_TPREL22 0x92
  2369. +#define R_IA64_TPREL64I 0x93
  2370. +#define R_IA64_TPREL64MSB 0x96
  2371. +#define R_IA64_TPREL64LSB 0x97
  2372. +#define R_IA64_LTOFF_TPREL22 0x9a
  2373. +#define R_IA64_DTPMOD64MSB 0xa6
  2374. +#define R_IA64_DTPMOD64LSB 0xa7
  2375. +#define R_IA64_LTOFF_DTPMOD22 0xaa
  2376. +#define R_IA64_DTPREL14 0xb1
  2377. +#define R_IA64_DTPREL22 0xb2
  2378. +#define R_IA64_DTPREL64I 0xb3
  2379. +#define R_IA64_DTPREL32MSB 0xb4
  2380. +#define R_IA64_DTPREL32LSB 0xb5
  2381. +#define R_IA64_DTPREL64MSB 0xb6
  2382. +#define R_IA64_DTPREL64LSB 0xb7
  2383. +#define R_IA64_LTOFF_DTPREL22 0xba
  2384. +
  2385. +
  2386. +
  2387. +
  2388. +#define R_SH_NONE 0
  2389. +#define R_SH_DIR32 1
  2390. +#define R_SH_REL32 2
  2391. +#define R_SH_DIR8WPN 3
  2392. +#define R_SH_IND12W 4
  2393. +#define R_SH_DIR8WPL 5
  2394. +#define R_SH_DIR8WPZ 6
  2395. +#define R_SH_DIR8BP 7
  2396. +#define R_SH_DIR8W 8
  2397. +#define R_SH_DIR8L 9
  2398. +#define R_SH_SWITCH16 25
  2399. +#define R_SH_SWITCH32 26
  2400. +#define R_SH_USES 27
  2401. +#define R_SH_COUNT 28
  2402. +#define R_SH_ALIGN 29
  2403. +#define R_SH_CODE 30
  2404. +#define R_SH_DATA 31
  2405. +#define R_SH_LABEL 32
  2406. +#define R_SH_SWITCH8 33
  2407. +#define R_SH_GNU_VTINHERIT 34
  2408. +#define R_SH_GNU_VTENTRY 35
  2409. +#define R_SH_TLS_GD_32 144
  2410. +#define R_SH_TLS_LD_32 145
  2411. +#define R_SH_TLS_LDO_32 146
  2412. +#define R_SH_TLS_IE_32 147
  2413. +#define R_SH_TLS_LE_32 148
  2414. +#define R_SH_TLS_DTPMOD32 149
  2415. +#define R_SH_TLS_DTPOFF32 150
  2416. +#define R_SH_TLS_TPOFF32 151
  2417. +#define R_SH_GOT32 160
  2418. +#define R_SH_PLT32 161
  2419. +#define R_SH_COPY 162
  2420. +#define R_SH_GLOB_DAT 163
  2421. +#define R_SH_JMP_SLOT 164
  2422. +#define R_SH_RELATIVE 165
  2423. +#define R_SH_GOTOFF 166
  2424. +#define R_SH_GOTPC 167
  2425. +
  2426. +#define R_SH_NUM 256
  2427. +
  2428. +
  2429. +
  2430. +#define R_390_NONE 0
  2431. +#define R_390_8 1
  2432. +#define R_390_12 2
  2433. +#define R_390_16 3
  2434. +#define R_390_32 4
  2435. +#define R_390_PC32 5
  2436. +#define R_390_GOT12 6
  2437. +#define R_390_GOT32 7
  2438. +#define R_390_PLT32 8
  2439. +#define R_390_COPY 9
  2440. +#define R_390_GLOB_DAT 10
  2441. +#define R_390_JMP_SLOT 11
  2442. +#define R_390_RELATIVE 12
  2443. +#define R_390_GOTOFF32 13
  2444. +#define R_390_GOTPC 14
  2445. +#define R_390_GOT16 15
  2446. +#define R_390_PC16 16
  2447. +#define R_390_PC16DBL 17
  2448. +#define R_390_PLT16DBL 18
  2449. +#define R_390_PC32DBL 19
  2450. +#define R_390_PLT32DBL 20
  2451. +#define R_390_GOTPCDBL 21
  2452. +#define R_390_64 22
  2453. +#define R_390_PC64 23
  2454. +#define R_390_GOT64 24
  2455. +#define R_390_PLT64 25
  2456. +#define R_390_GOTENT 26
  2457. +#define R_390_GOTOFF16 27
  2458. +#define R_390_GOTOFF64 28
  2459. +#define R_390_GOTPLT12 29
  2460. +#define R_390_GOTPLT16 30
  2461. +#define R_390_GOTPLT32 31
  2462. +#define R_390_GOTPLT64 32
  2463. +#define R_390_GOTPLTENT 33
  2464. +#define R_390_PLTOFF16 34
  2465. +#define R_390_PLTOFF32 35
  2466. +#define R_390_PLTOFF64 36
  2467. +#define R_390_TLS_LOAD 37
  2468. +#define R_390_TLS_GDCALL 38
  2469. +
  2470. +#define R_390_TLS_LDCALL 39
  2471. +
  2472. +#define R_390_TLS_GD32 40
  2473. +
  2474. +#define R_390_TLS_GD64 41
  2475. +
  2476. +#define R_390_TLS_GOTIE12 42
  2477. +
  2478. +#define R_390_TLS_GOTIE32 43
  2479. +
  2480. +#define R_390_TLS_GOTIE64 44
  2481. +
  2482. +#define R_390_TLS_LDM32 45
  2483. +
  2484. +#define R_390_TLS_LDM64 46
  2485. +
  2486. +#define R_390_TLS_IE32 47
  2487. +
  2488. +#define R_390_TLS_IE64 48
  2489. +
  2490. +#define R_390_TLS_IEENT 49
  2491. +
  2492. +#define R_390_TLS_LE32 50
  2493. +
  2494. +#define R_390_TLS_LE64 51
  2495. +
  2496. +#define R_390_TLS_LDO32 52
  2497. +
  2498. +#define R_390_TLS_LDO64 53
  2499. +
  2500. +#define R_390_TLS_DTPMOD 54
  2501. +#define R_390_TLS_DTPOFF 55
  2502. +#define R_390_TLS_TPOFF 56
  2503. +
  2504. +#define R_390_20 57
  2505. +#define R_390_GOT20 58
  2506. +#define R_390_GOTPLT20 59
  2507. +#define R_390_TLS_GOTIE20 60
  2508. +
  2509. +
  2510. +#define R_390_NUM 61
  2511. +
  2512. +
  2513. +
  2514. +#define R_CRIS_NONE 0
  2515. +#define R_CRIS_8 1
  2516. +#define R_CRIS_16 2
  2517. +#define R_CRIS_32 3
  2518. +#define R_CRIS_8_PCREL 4
  2519. +#define R_CRIS_16_PCREL 5
  2520. +#define R_CRIS_32_PCREL 6
  2521. +#define R_CRIS_GNU_VTINHERIT 7
  2522. +#define R_CRIS_GNU_VTENTRY 8
  2523. +#define R_CRIS_COPY 9
  2524. +#define R_CRIS_GLOB_DAT 10
  2525. +#define R_CRIS_JUMP_SLOT 11
  2526. +#define R_CRIS_RELATIVE 12
  2527. +#define R_CRIS_16_GOT 13
  2528. +#define R_CRIS_32_GOT 14
  2529. +#define R_CRIS_16_GOTPLT 15
  2530. +#define R_CRIS_32_GOTPLT 16
  2531. +#define R_CRIS_32_GOTREL 17
  2532. +#define R_CRIS_32_PLT_GOTREL 18
  2533. +#define R_CRIS_32_PLT_PCREL 19
  2534. +
  2535. +#define R_CRIS_NUM 20
  2536. +
  2537. +
  2538. +
  2539. +#define R_X86_64_NONE 0
  2540. +#define R_X86_64_64 1
  2541. +#define R_X86_64_PC32 2
  2542. +#define R_X86_64_GOT32 3
  2543. +#define R_X86_64_PLT32 4
  2544. +#define R_X86_64_COPY 5
  2545. +#define R_X86_64_GLOB_DAT 6
  2546. +#define R_X86_64_JUMP_SLOT 7
  2547. +#define R_X86_64_RELATIVE 8
  2548. +#define R_X86_64_GOTPCREL 9
  2549. +
  2550. +#define R_X86_64_32 10
  2551. +#define R_X86_64_32S 11
  2552. +#define R_X86_64_16 12
  2553. +#define R_X86_64_PC16 13
  2554. +#define R_X86_64_8 14
  2555. +#define R_X86_64_PC8 15
  2556. +#define R_X86_64_DTPMOD64 16
  2557. +#define R_X86_64_DTPOFF64 17
  2558. +#define R_X86_64_TPOFF64 18
  2559. +#define R_X86_64_TLSGD 19
  2560. +
  2561. +#define R_X86_64_TLSLD 20
  2562. +
  2563. +#define R_X86_64_DTPOFF32 21
  2564. +#define R_X86_64_GOTTPOFF 22
  2565. +
  2566. +#define R_X86_64_TPOFF32 23
  2567. +#define R_X86_64_PC64 24
  2568. +#define R_X86_64_GOTOFF64 25
  2569. +#define R_X86_64_GOTPC32 26
  2570. +#define R_X86_64_GOT64 27
  2571. +#define R_X86_64_GOTPCREL64 28
  2572. +#define R_X86_64_GOTPC64 29
  2573. +#define R_X86_64_GOTPLT64 30
  2574. +#define R_X86_64_PLTOFF64 31
  2575. +#define R_X86_64_SIZE32 32
  2576. +#define R_X86_64_SIZE64 33
  2577. +
  2578. +#define R_X86_64_GOTPC32_TLSDESC 34
  2579. +#define R_X86_64_TLSDESC_CALL 35
  2580. +
  2581. +#define R_X86_64_TLSDESC 36
  2582. +#define R_X86_64_IRELATIVE 37
  2583. +#define R_X86_64_RELATIVE64 38
  2584. +#define R_X86_64_NUM 39
  2585. +
  2586. +
  2587. +
  2588. +#define R_MN10300_NONE 0
  2589. +#define R_MN10300_32 1
  2590. +#define R_MN10300_16 2
  2591. +#define R_MN10300_8 3
  2592. +#define R_MN10300_PCREL32 4
  2593. +#define R_MN10300_PCREL16 5
  2594. +#define R_MN10300_PCREL8 6
  2595. +#define R_MN10300_GNU_VTINHERIT 7
  2596. +#define R_MN10300_GNU_VTENTRY 8
  2597. +#define R_MN10300_24 9
  2598. +#define R_MN10300_GOTPC32 10
  2599. +#define R_MN10300_GOTPC16 11
  2600. +#define R_MN10300_GOTOFF32 12
  2601. +#define R_MN10300_GOTOFF24 13
  2602. +#define R_MN10300_GOTOFF16 14
  2603. +#define R_MN10300_PLT32 15
  2604. +#define R_MN10300_PLT16 16
  2605. +#define R_MN10300_GOT32 17
  2606. +#define R_MN10300_GOT24 18
  2607. +#define R_MN10300_GOT16 19
  2608. +#define R_MN10300_COPY 20
  2609. +#define R_MN10300_GLOB_DAT 21
  2610. +#define R_MN10300_JMP_SLOT 22
  2611. +#define R_MN10300_RELATIVE 23
  2612. +
  2613. +#define R_MN10300_NUM 24
  2614. +
  2615. +
  2616. +
  2617. +#define R_M32R_NONE 0
  2618. +#define R_M32R_16 1
  2619. +#define R_M32R_32 2
  2620. +#define R_M32R_24 3
  2621. +#define R_M32R_10_PCREL 4
  2622. +#define R_M32R_18_PCREL 5
  2623. +#define R_M32R_26_PCREL 6
  2624. +#define R_M32R_HI16_ULO 7
  2625. +#define R_M32R_HI16_SLO 8
  2626. +#define R_M32R_LO16 9
  2627. +#define R_M32R_SDA16 10
  2628. +#define R_M32R_GNU_VTINHERIT 11
  2629. +#define R_M32R_GNU_VTENTRY 12
  2630. +
  2631. +#define R_M32R_16_RELA 33
  2632. +#define R_M32R_32_RELA 34
  2633. +#define R_M32R_24_RELA 35
  2634. +#define R_M32R_10_PCREL_RELA 36
  2635. +#define R_M32R_18_PCREL_RELA 37
  2636. +#define R_M32R_26_PCREL_RELA 38
  2637. +#define R_M32R_HI16_ULO_RELA 39
  2638. +#define R_M32R_HI16_SLO_RELA 40
  2639. +#define R_M32R_LO16_RELA 41
  2640. +#define R_M32R_SDA16_RELA 42
  2641. +#define R_M32R_RELA_GNU_VTINHERIT 43
  2642. +#define R_M32R_RELA_GNU_VTENTRY 44
  2643. +#define R_M32R_REL32 45
  2644. +
  2645. +#define R_M32R_GOT24 48
  2646. +#define R_M32R_26_PLTREL 49
  2647. +#define R_M32R_COPY 50
  2648. +#define R_M32R_GLOB_DAT 51
  2649. +#define R_M32R_JMP_SLOT 52
  2650. +#define R_M32R_RELATIVE 53
  2651. +#define R_M32R_GOTOFF 54
  2652. +#define R_M32R_GOTPC24 55
  2653. +#define R_M32R_GOT16_HI_ULO 56
  2654. +
  2655. +#define R_M32R_GOT16_HI_SLO 57
  2656. +
  2657. +#define R_M32R_GOT16_LO 58
  2658. +#define R_M32R_GOTPC_HI_ULO 59
  2659. +
  2660. +#define R_M32R_GOTPC_HI_SLO 60
  2661. +
  2662. +#define R_M32R_GOTPC_LO 61
  2663. +
  2664. +#define R_M32R_GOTOFF_HI_ULO 62
  2665. +
  2666. +#define R_M32R_GOTOFF_HI_SLO 63
  2667. +
  2668. +#define R_M32R_GOTOFF_LO 64
  2669. +#define R_M32R_NUM 256
  2670. +
  2671. +#define R_MICROBLAZE_NONE 0
  2672. +#define R_MICROBLAZE_32 1
  2673. +#define R_MICROBLAZE_32_PCREL 2
  2674. +#define R_MICROBLAZE_64_PCREL 3
  2675. +#define R_MICROBLAZE_32_PCREL_LO 4
  2676. +#define R_MICROBLAZE_64 5
  2677. +#define R_MICROBLAZE_32_LO 6
  2678. +#define R_MICROBLAZE_SRO32 7
  2679. +#define R_MICROBLAZE_SRW32 8
  2680. +#define R_MICROBLAZE_64_NONE 9
  2681. +#define R_MICROBLAZE_32_SYM_OP_SYM 10
  2682. +#define R_MICROBLAZE_GNU_VTINHERIT 11
  2683. +#define R_MICROBLAZE_GNU_VTENTRY 12
  2684. +#define R_MICROBLAZE_GOTPC_64 13
  2685. +#define R_MICROBLAZE_GOT_64 14
  2686. +#define R_MICROBLAZE_PLT_64 15
  2687. +#define R_MICROBLAZE_REL 16
  2688. +#define R_MICROBLAZE_JUMP_SLOT 17
  2689. +#define R_MICROBLAZE_GLOB_DAT 18
  2690. +#define R_MICROBLAZE_GOTOFF_64 19
  2691. +#define R_MICROBLAZE_GOTOFF_32 20
  2692. +#define R_MICROBLAZE_COPY 21
  2693. +#define R_MICROBLAZE_TLS 22
  2694. +#define R_MICROBLAZE_TLSGD 23
  2695. +#define R_MICROBLAZE_TLSLD 24
  2696. +#define R_MICROBLAZE_TLSDTPMOD32 25
  2697. +#define R_MICROBLAZE_TLSDTPREL32 26
  2698. +#define R_MICROBLAZE_TLSDTPREL64 27
  2699. +#define R_MICROBLAZE_TLSGOTTPREL32 28
  2700. +#define R_MICROBLAZE_TLSTPREL32 29
  2701. +
  2702. +#ifdef __cplusplus
  2703. +}
  2704. +#endif
  2705. +
  2706. +
  2707. +#endif