xref: /minix3/external/bsd/file/dist/magic/magdir/mach (revision 0a6a1f1d05b60e214de2f05a7310ddd1f0e590e7)
1835f6802SDirk Vogt
2ef01931fSBen Gras#------------------------------------------------------------
3*0a6a1f1dSLionel Sambuc# $File: mach,v 1.19 2014/04/30 21:41:02 christos Exp $
4ef01931fSBen Gras# Mach has two magic numbers, 0xcafebabe and 0xfeedface.
5ef01931fSBen Gras# Unfortunately the first, cafebabe, is shared with
6ef01931fSBen Gras# Java ByteCode, so they are both handled in the file "cafebabe".
7ef01931fSBen Gras# The "feedface" ones are handled herein.
8ef01931fSBen Gras#------------------------------------------------------------
984d9c625SLionel Sambuc# if set, it's for the 64-bit version of the architecture
1084d9c625SLionel Sambuc# yes, this is separate from the low-order magic number bit
1184d9c625SLionel Sambuc# it's also separate from the "64-bit libraries" bit in the
1284d9c625SLionel Sambuc# upper 8 bits of the CPU subtype
1384d9c625SLionel Sambuc
1484d9c625SLionel Sambuc0	name	mach-o-cpu
1584d9c625SLionel Sambuc>0	belong&0x01000000	0
16ef01931fSBen Gras#
1784d9c625SLionel Sambuc# 32-bit ABIs.
1884d9c625SLionel Sambuc#
1984d9c625SLionel Sambuc#				1	vax
2084d9c625SLionel Sambuc>>0	belong&0x00ffffff	1
2184d9c625SLionel Sambuc>>>4		belong&0x00ffffff	0	vax
2284d9c625SLionel Sambuc>>>4		belong&0x00ffffff	1	vax11/780
2384d9c625SLionel Sambuc>>>4		belong&0x00ffffff	2	vax11/785
2484d9c625SLionel Sambuc>>>4		belong&0x00ffffff	3	vax11/750
2584d9c625SLionel Sambuc>>>4		belong&0x00ffffff	4	vax11/730
2684d9c625SLionel Sambuc>>>4		belong&0x00ffffff	5	uvaxI
2784d9c625SLionel Sambuc>>>4		belong&0x00ffffff	6	uvaxII
2884d9c625SLionel Sambuc>>>4		belong&0x00ffffff	7	vax8200
2984d9c625SLionel Sambuc>>>4		belong&0x00ffffff	8	vax8500
3084d9c625SLionel Sambuc>>>4		belong&0x00ffffff	9	vax8600
3184d9c625SLionel Sambuc>>>4		belong&0x00ffffff	10	vax8650
3284d9c625SLionel Sambuc>>>4		belong&0x00ffffff	11	vax8800
3384d9c625SLionel Sambuc>>>4		belong&0x00ffffff	12	uvaxIII
34*0a6a1f1dSLionel Sambuc>>>4		belong&0x00ffffff	>12	vax subarchitecture=%d
3584d9c625SLionel Sambuc>>0	belong&0x00ffffff	2	romp
3684d9c625SLionel Sambuc>>0	belong&0x00ffffff	3	architecture=3
3784d9c625SLionel Sambuc>>0	belong&0x00ffffff	4	ns32032
3884d9c625SLionel Sambuc>>0	belong&0x00ffffff	5	ns32332
3984d9c625SLionel Sambuc>>0	belong&0x00ffffff	6	m68k
4084d9c625SLionel Sambuc#				7	x86
4184d9c625SLionel Sambuc>>0	belong&0x00ffffff	7
4284d9c625SLionel Sambuc>>>4	belong&0x0000000f	3		i386
4384d9c625SLionel Sambuc>>>4	belong&0x0000000f	4		i486
4484d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0
4584d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0x80		\bsx
4684d9c625SLionel Sambuc>>>4	belong&0x0000000f	5		i586
4784d9c625SLionel Sambuc>>>4	belong&0x0000000f	6
4884d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0		p6
4984d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0x10		pentium_pro
5084d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0x20		pentium_2_m0x20
5184d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0x30		pentium_2_m3
5284d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0x40		pentium_2_m0x40
5384d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0x50		pentium_2_m5
54*0a6a1f1dSLionel Sambuc>>>>4	belong&0x00fffff0	>0x50		pentium_2_m0x%x
5584d9c625SLionel Sambuc>>>4	belong&0x0000000f	7		celeron
56*0a6a1f1dSLionel Sambuc>>>>4	belong&0x00fffff0	0x00		\b_m0x%x
57*0a6a1f1dSLionel Sambuc>>>>4	belong&0x00fffff0	0x10		\b_m0x%x
58*0a6a1f1dSLionel Sambuc>>>>4	belong&0x00fffff0	0x20		\b_m0x%x
59*0a6a1f1dSLionel Sambuc>>>>4	belong&0x00fffff0	0x30		\b_m0x%x
60*0a6a1f1dSLionel Sambuc>>>>4	belong&0x00fffff0	0x40		\b_m0x%x
61*0a6a1f1dSLionel Sambuc>>>>4	belong&0x00fffff0	0x50		\b_m0x%x
6284d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0x60
6384d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0x70		\b_mobile
64*0a6a1f1dSLionel Sambuc>>>>4	belong&0x00fffff0	>0x70		\b_m0x%x
6584d9c625SLionel Sambuc>>>4	belong&0x0000000f	8		pentium_3
6684d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0x00
6784d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0x10		\b_m
6884d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0x20		\b_xeon
69*0a6a1f1dSLionel Sambuc>>>>4	belong&0x00fffff0	>0x20		\b_m0x%x
7084d9c625SLionel Sambuc>>>4	belong&0x0000000f	9		pentiumM
7184d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0x00
72*0a6a1f1dSLionel Sambuc>>>>4	belong&0x00fffff0	>0x00		\b_m0x%x
7384d9c625SLionel Sambuc>>>4	belong&0x0000000f	10		pentium_4
7484d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0x00
7584d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0x10		\b_m
76*0a6a1f1dSLionel Sambuc>>>>4	belong&0x00fffff0	>0x10		\b_m0x%x
7784d9c625SLionel Sambuc>>>4	belong&0x0000000f	11		itanium
7884d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0x00
7984d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0x10		\b_2
80*0a6a1f1dSLionel Sambuc>>>>4	belong&0x00fffff0	>0x10		\b_m0x%x
8184d9c625SLionel Sambuc>>>4	belong&0x0000000f	12		xeon
8284d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0x00
8384d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0x10		\b_mp
84*0a6a1f1dSLionel Sambuc>>>>4	belong&0x00fffff0	>0x10		\b_m0x%x
85*0a6a1f1dSLionel Sambuc>>>4	belong&0x0000000f	>12		ia32 family=%d
8684d9c625SLionel Sambuc>>>>4	belong&0x00fffff0	0x00
87*0a6a1f1dSLionel Sambuc>>>>4	belong&0x00fffff0	>0x00		model=%x
8884d9c625SLionel Sambuc>>0	belong&0x00ffffff	8	mips
8984d9c625SLionel Sambuc>>>4		belong&0x00ffffff	1	R2300
9084d9c625SLionel Sambuc>>>4		belong&0x00ffffff	2	R2600
9184d9c625SLionel Sambuc>>>4		belong&0x00ffffff	3	R2800
9284d9c625SLionel Sambuc>>>4		belong&0x00ffffff	4	R2000a
9384d9c625SLionel Sambuc>>>4		belong&0x00ffffff	5	R2000
9484d9c625SLionel Sambuc>>>4		belong&0x00ffffff	6	R3000a
9584d9c625SLionel Sambuc>>>4		belong&0x00ffffff	7	R3000
96*0a6a1f1dSLionel Sambuc>>>4		belong&0x00ffffff	>7	subarchitecture=%d
9784d9c625SLionel Sambuc>>0	belong&0x00ffffff	9	ns32532
9884d9c625SLionel Sambuc>>0	belong&0x00ffffff	10	mc98000
9984d9c625SLionel Sambuc>>0	belong&0x00ffffff	11	hppa
10084d9c625SLionel Sambuc>>>4		belong&0x00ffffff	0	7100
10184d9c625SLionel Sambuc>>>4		belong&0x00ffffff	1	7100LC
102*0a6a1f1dSLionel Sambuc>>>4		belong&0x00ffffff	>1	subarchitecture=%d
10384d9c625SLionel Sambuc>>0	belong&0x00ffffff	12	arm
10484d9c625SLionel Sambuc>>>4		belong&0x00ffffff	0
105*0a6a1f1dSLionel Sambuc>>>4		belong&0x00ffffff	1	subarchitecture=%d
106*0a6a1f1dSLionel Sambuc>>>4		belong&0x00ffffff	2	subarchitecture=%d
107*0a6a1f1dSLionel Sambuc>>>4		belong&0x00ffffff	3	subarchitecture=%d
108*0a6a1f1dSLionel Sambuc>>>4		belong&0x00ffffff	4	subarchitecture=%d
10984d9c625SLionel Sambuc>>>4		belong&0x00ffffff	5	\b_v4t
11084d9c625SLionel Sambuc>>>4		belong&0x00ffffff	6	\b_v6
11184d9c625SLionel Sambuc>>>4		belong&0x00ffffff	7	\b_v5tej
11284d9c625SLionel Sambuc>>>4		belong&0x00ffffff	8	\b_xscale
11384d9c625SLionel Sambuc>>>4		belong&0x00ffffff	9	\b_v7
11484d9c625SLionel Sambuc>>>4		belong&0x00ffffff	10	\b_v7f
115*0a6a1f1dSLionel Sambuc>>>4		belong&0x00ffffff	11	subarchitecture=%d
11684d9c625SLionel Sambuc>>>4		belong&0x00ffffff	12	\b_v7k
117*0a6a1f1dSLionel Sambuc>>>4		belong&0x00ffffff	>12	subarchitecture=%d
11884d9c625SLionel Sambuc#				13	m88k
11984d9c625SLionel Sambuc>>0	belong&0x00ffffff	13
12084d9c625SLionel Sambuc>>>4		belong&0x00ffffff	0	mc88000
12184d9c625SLionel Sambuc>>>4		belong&0x00ffffff	1	mc88100
12284d9c625SLionel Sambuc>>>4		belong&0x00ffffff	2	mc88110
123*0a6a1f1dSLionel Sambuc>>>4		belong&0x00ffffff	>2	mc88000 subarchitecture=%d
124*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	14	SPARC
12584d9c625SLionel Sambuc>>0	belong&0x00ffffff	15	i860g
12684d9c625SLionel Sambuc>>0	belong&0x00ffffff	16	alpha
12784d9c625SLionel Sambuc>>0	belong&0x00ffffff	17	rs6000
12884d9c625SLionel Sambuc>>0	belong&0x00ffffff	18	ppc
12984d9c625SLionel Sambuc>>>4		belong&0x00ffffff	0
13084d9c625SLionel Sambuc>>>4		belong&0x00ffffff	1	\b_601
13184d9c625SLionel Sambuc>>>4		belong&0x00ffffff	2	\b_602
13284d9c625SLionel Sambuc>>>4		belong&0x00ffffff	3	\b_603
13384d9c625SLionel Sambuc>>>4		belong&0x00ffffff	4	\b_603e
13484d9c625SLionel Sambuc>>>4		belong&0x00ffffff	5	\b_603ev
13584d9c625SLionel Sambuc>>>4		belong&0x00ffffff	6	\b_604
13684d9c625SLionel Sambuc>>>4		belong&0x00ffffff	7	\b_604e
13784d9c625SLionel Sambuc>>>4		belong&0x00ffffff	8	\b_620
13884d9c625SLionel Sambuc>>>4		belong&0x00ffffff	9	\b_650
13984d9c625SLionel Sambuc>>>4		belong&0x00ffffff	10	\b_7400
14084d9c625SLionel Sambuc>>>4		belong&0x00ffffff	11	\b_7450
14184d9c625SLionel Sambuc>>>4		belong&0x00ffffff	100	\b_970
142*0a6a1f1dSLionel Sambuc>>>4		belong&0x00ffffff	>100	subarchitecture=%d
143*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	>18	architecture=%d
14484d9c625SLionel Sambuc>0	belong&0x01000000	0x01000000
14584d9c625SLionel Sambuc#
14684d9c625SLionel Sambuc# 64-bit ABIs.
14784d9c625SLionel Sambuc#
148*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	0	64-bit architecture=%d
149*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	1	64-bit architecture=%d
150*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	2	64-bit architecture=%d
151*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	3	64-bit architecture=%d
152*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	4	64-bit architecture=%d
153*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	5	64-bit architecture=%d
154*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	6	64-bit architecture=%d
15584d9c625SLionel Sambuc>>0	belong&0x00ffffff	7	x86_64
156*0a6a1f1dSLionel Sambuc>>>4		belong&0x00ffffff	0	subarchitecture=%d
157*0a6a1f1dSLionel Sambuc>>>4		belong&0x00ffffff	1	subarchitecture=%d
158*0a6a1f1dSLionel Sambuc>>>4		belong&0x00ffffff	2	subarchitecture=%d
15984d9c625SLionel Sambuc>>>4		belong&0x00ffffff	3
16084d9c625SLionel Sambuc>>>4		belong&0x00ffffff	4	\b_arch1
161*0a6a1f1dSLionel Sambuc>>>4		belong&0x00ffffff	>4	subarchitecture=%d
162*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	8	64-bit architecture=%d
163*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	9	64-bit architecture=%d
164*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	10	64-bit architecture=%d
165*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	11	64-bit architecture=%d
166*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	12	64-bit architecture=%d
167*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	13	64-bit architecture=%d
168*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	14	64-bit architecture=%d
169*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	15	64-bit architecture=%d
170*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	16	64-bit architecture=%d
171*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	17	64-bit architecture=%d
17284d9c625SLionel Sambuc>>0	belong&0x00ffffff	18	ppc64
17384d9c625SLionel Sambuc>>>4		belong&0x00ffffff	0
17484d9c625SLionel Sambuc>>>4		belong&0x00ffffff	1		\b_601
17584d9c625SLionel Sambuc>>>4		belong&0x00ffffff	2		\b_602
17684d9c625SLionel Sambuc>>>4		belong&0x00ffffff	3		\b_603
17784d9c625SLionel Sambuc>>>4		belong&0x00ffffff	4		\b_603e
17884d9c625SLionel Sambuc>>>4		belong&0x00ffffff	5		\b_603ev
17984d9c625SLionel Sambuc>>>4		belong&0x00ffffff	6		\b_604
18084d9c625SLionel Sambuc>>>4		belong&0x00ffffff	7		\b_604e
18184d9c625SLionel Sambuc>>>4		belong&0x00ffffff	8		\b_620
18284d9c625SLionel Sambuc>>>4		belong&0x00ffffff	9		\b_650
18384d9c625SLionel Sambuc>>>4		belong&0x00ffffff	10		\b_7400
18484d9c625SLionel Sambuc>>>4		belong&0x00ffffff	11		\b_7450
18584d9c625SLionel Sambuc>>>4		belong&0x00ffffff	100		\b_970
186*0a6a1f1dSLionel Sambuc>>>4		belong&0x00ffffff	>100		subarchitecture=%d
187*0a6a1f1dSLionel Sambuc>>0	belong&0x00ffffff	>18	64-bit architecture=%d
18884d9c625SLionel Sambuc
18984d9c625SLionel Sambuc
19084d9c625SLionel Sambuc0	name		mach-o-be
19184d9c625SLionel Sambuc>0	byte		0xcf		64-bit
19284d9c625SLionel Sambuc>4	use		mach-o-cpu
193ef01931fSBen Gras>12	belong		1		object
194ef01931fSBen Gras>12	belong		2		executable
195ef01931fSBen Gras>12	belong		3		fixed virtual memory shared library
196ef01931fSBen Gras>12	belong		4		core
197ef01931fSBen Gras>12	belong		5		preload executable
198ef01931fSBen Gras>12	belong		6		dynamically linked shared library
199ef01931fSBen Gras>12	belong		7		dynamic linker
200ef01931fSBen Gras>12	belong		8		bundle
201ef01931fSBen Gras>12	belong		9		dynamically linked shared library stub
20284d9c625SLionel Sambuc>12	belong		10		dSYM companion file
20384d9c625SLionel Sambuc>12	belong		11		kext bundle
20484d9c625SLionel Sambuc>12	belong		>11
205*0a6a1f1dSLionel Sambuc>>12	belong		x		filetype=%d
20684d9c625SLionel Sambuc
20784d9c625SLionel Sambuc#
20884d9c625SLionel Sambuc0	lelong&0xfffffffe	0xfeedface	Mach-O
20984d9c625SLionel Sambuc!:strength +1
21084d9c625SLionel Sambuc>0	use	\^mach-o-be
21184d9c625SLionel Sambuc
21284d9c625SLionel Sambuc0	belong&0xfffffffe	0xfeedface	Mach-O
21384d9c625SLionel Sambuc!:strength +1
21484d9c625SLionel Sambuc>0	use	mach-o-be
215