arm 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. #------------------------------------------------------------------------------
  2. # $File: arm,v 1.2 2021/07/14 17:40:31 christos Exp $
  3. # arm: file(1) magic for ARM COFF
  4. #
  5. # https://docs.microsoft.com/en-us/windows/win32/debug/pe-format
  6. # Aarch64
  7. 0 leshort 0xaa64
  8. # test for unused flag bits in f_flags
  9. >18 uleshort&0x8E80 0
  10. # use little endian variant of subroutine to
  11. # display name+variables+flags for common object formatted files
  12. >>0 use display-coff
  13. !:strength -10
  14. # ARM
  15. 0 leshort 0x01c0
  16. # test for unused flag bits in f_flags
  17. >18 uleshort&0x8E80 0
  18. # use little endian variant of subroutine to
  19. # display name+variables+flags for common object formatted files
  20. >>0 use display-coff
  21. !:strength -10
  22. # ARM Thumb
  23. 0 leshort 0x01c2
  24. # test for unused flag bits in f_flags
  25. >18 uleshort&0x8E80 0
  26. # use little endian variant of subroutine to
  27. # display name+variables+flags for common object formatted files
  28. >>0 use display-coff
  29. !:strength -10
  30. # ARMv7 Thumb
  31. 0 leshort 0x01c4
  32. # test for unused flag bits in f_flags
  33. >18 uleshort&0x8E80 0
  34. # use little endian variant of subroutine to
  35. # display name+variables+flags for common object formatted files
  36. >>0 use display-coff
  37. !:strength -10