2 #------------------------------------------------------------------------------
3 # olf: file(1) magic for OLF executables
5 # We have to check the byte order flag to see what byte order all the
6 # other stuff in the header is in.
8 # Byte order is probably big-endian for MIPS R3000 and Amdahl.
9 # MIPS R3000 may also be for MIPS R2000.
11 # Created by Erik Theisen <etheisen@openbsd.org>
12 # Based on elf from Daniel Quinlan <quinlan@yggdrasil.com>
14 >4 byte 0 invalid class
30 >8 byte 1 dynamically linked
32 >5 byte 0 invalid byte order
34 >>16 leshort 0 no file type,
35 >>16 leshort 1 relocatable,
36 >>16 leshort 2 executable,
37 >>16 leshort 3 shared object,
38 >>16 leshort 4 core file,
39 >>16 leshort &0xff00 processor-specific,
40 >>18 leshort 0 no machine,
41 >>18 leshort 1 AT&T WE32100 - invalid byte order,
42 >>18 leshort 2 SPARC - invalid byte order,
43 >>18 leshort 3 Intel 80386,
44 >>18 leshort 4 Motorola 68000 - invalid byte order,
45 >>18 leshort 5 Motorola 88000 - invalid byte order,
46 >>18 leshort 6 Intel 80486,
47 >>18 leshort 7 Intel 80860,
48 >>18 leshort 8 MIPS R3000,
49 >>18 leshort 9 Amdahl,
50 >>20 lelong 0 invalid version
51 >>20 lelong 1 version 1
52 >>36 lelong 1 MathCoPro/FPU/MAU Required
54 >>16 beshort 0 no file type,
55 >>16 beshort 1 relocatable,
56 >>16 beshort 2 executable,
57 >>16 beshort 3 shared object,
58 >>16 beshort 4 core file,
59 >>16 beshort &0xff00 processor-specific,
60 >>18 beshort 0 no machine,
61 >>18 beshort 1 AT&T WE32100,
63 >>18 beshort 3 Intel 80386 - invalid byte order,
64 >>18 beshort 4 Motorola 68000,
65 >>18 beshort 5 Motorola 88000,
66 >>18 beshort 6 Intel 80486 - invalid byte order,
67 >>18 beshort 7 Intel 80860,
68 >>18 beshort 8 MIPS R3000,
69 >>18 leshort 9 Amdahl,
70 >>20 belong 0 invalid version
71 >>20 belong 1 version 1
72 >>36 belong 1 MathCoPro/FPU/MAU Required