elf 2.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. #------------------------------------------------------------------------------
  2. # elf: file(1) magic for ELF executables
  3. #
  4. # We have to check the byte order flag to see what byte order all the
  5. # other stuff in the header is in.
  6. #
  7. # MIPS R3000 may also be for MIPS R2000.
  8. # What're the correct byte orders for the nCUBE and the Fujitsu VPP500?
  9. #
  10. # updated by Daniel Quinlan (quinlan@yggdrasil.com)
  11. 0 string \177ELF ELF
  12. >4 byte 0 invalid class
  13. >4 byte 1 32-bit
  14. >4 byte 2 64-bit
  15. >5 byte 0 invalid byte order
  16. >5 byte 1 LSB
  17. >>16 leshort 0 no file type,
  18. >>16 leshort 1 relocatable,
  19. >>16 leshort 2 executable,
  20. >>16 leshort 3 shared object,
  21. # Core handling from Peter Tobias <tobias@server.et-inf.fho-emden.de>
  22. # corrections by Christian 'Dr. Disk' Hechelmann <drdisk@ds9.au.s.shuttle.de>
  23. >>16 leshort 4 core file
  24. >>>(0x38+0xcc) string >\0 of '%s'
  25. >>>(0x38+0x10) lelong >0 (signal %d),
  26. >>16 leshort &0xff00 processor-specific,
  27. >>18 leshort 0 no machine,
  28. >>18 leshort 1 AT&T WE32100 - invalid byte order,
  29. >>18 leshort 2 SPARC - invalid byte order,
  30. >>18 leshort 3 Intel 80386,
  31. >>18 leshort 4 Motorola 68000 - invalid byte order,
  32. >>18 leshort 5 Motorola 88000 - invalid byte order,
  33. >>18 leshort 6 Intel 80486,
  34. >>18 leshort 7 Intel 80860,
  35. >>18 leshort 8 MIPS R3000_BE - invalid byte order,
  36. >>18 leshort 9 Amdahl - invalid byte order,
  37. >>18 leshort 10 MIPS R3000_LE,
  38. >>18 leshort 11 RS6000 - invalid byte order,
  39. >>18 leshort 15 PA-RISC - invalid byte order,
  40. >>18 leshort 16 nCUBE,
  41. >>18 leshort 17 VPP500,
  42. >>18 leshort 18 SPARC32PLUS,
  43. >>18 leshort 20 PowerPC,
  44. >>18 leshort 0x9026 Alpha,
  45. >>20 lelong 0 invalid version
  46. >>20 lelong 1 version 1
  47. >>36 lelong 1 MathCoPro/FPU/MAU Required
  48. >8 string >\0 (%s)
  49. >5 byte 2 MSB
  50. >>16 beshort 0 no file type,
  51. >>16 beshort 1 relocatable,
  52. >>16 beshort 2 executable,
  53. >>16 beshort 3 shared object,
  54. >>16 beshort 4 core file,
  55. >>>(0x38+0xcc) string >\0 of '%s'
  56. >>>(0x38+0x10) belong >0 (signal %d),
  57. >>16 beshort &0xff00 processor-specific,
  58. >>18 beshort 0 no machine,
  59. >>18 beshort 1 AT&T WE32100,
  60. >>18 beshort 2 SPARC,
  61. >>18 beshort 3 Intel 80386 - invalid byte order,
  62. >>18 beshort 4 Motorola 68000,
  63. >>18 beshort 5 Motorola 88000,
  64. >>18 beshort 6 Intel 80486 - invalid byte order,
  65. >>18 beshort 7 Intel 80860,
  66. >>18 beshort 8 MIPS R3000_BE,
  67. >>18 beshort 9 Amdahl,
  68. >>18 beshort 10 MIPS R3000_LE - invalid byte order,
  69. >>18 beshort 11 RS6000,
  70. >>18 beshort 15 PA-RISC,
  71. >>18 beshort 16 nCUBE,
  72. >>18 beshort 17 VPP500,
  73. >>18 beshort 18 SPARC32PLUS,
  74. >>18 beshort 20 PowerPC or cisco 4500,
  75. >>18 beshort 21 cisco 7500,
  76. >>18 beshort 24 cisco SVIP,
  77. >>18 beshort 25 cisco 7200,
  78. >>18 beshort 36 cisco 12000,
  79. >>18 beshort 0x9026 Alpha,
  80. >>20 belong 0 invalid version
  81. >>20 belong 1 version 1
  82. >>36 belong 1 MathCoPro/FPU/MAU Required