]> git.saurik.com Git - apple/xnu.git/blob - osfmk/mach/Makefile
xnu-517.12.7.tar.gz
[apple/xnu.git] / osfmk / mach / Makefile
1 export MakeInc_cmd=${SRCROOT}/makedefs/MakeInc.cmd
2 export MakeInc_def=${SRCROOT}/makedefs/MakeInc.def
3 export MakeInc_rule=${SRCROOT}/makedefs/MakeInc.rule
4 export MakeInc_dir=${SRCROOT}/makedefs/MakeInc.dir
5
6
7 include $(MakeInc_cmd)
8 include $(MakeInc_def)
9
10 INSTINC_SUBDIRS = \
11 machine
12
13 INSTINC_SUBDIRS_PPC = \
14 ppc
15
16 INSTINC_SUBDIRS_I386 = \
17 i386
18
19 EXPINC_SUBDIRS = \
20 machine
21
22 EXPINC_SUBDIRS_PPC = \
23 ppc
24
25 EXPINC_SUBDIRS_I386 = \
26 i386
27
28 MIG_TYPES = \
29 clock_types.defs \
30 mach_types.defs \
31 std_types.defs
32
33 MIG_DEFS = \
34 audit_triggers.defs \
35 clock.defs \
36 clock_priv.defs \
37 clock_reply.defs \
38 exc.defs \
39 host_notify_reply.defs \
40 host_priv.defs \
41 host_security.defs \
42 ledger.defs \
43 lock_set.defs \
44 mach_host.defs \
45 mach_port.defs \
46 notify.defs \
47 processor.defs \
48 processor_set.defs \
49 task.defs \
50 thread_act.defs \
51 vm_map.defs \
52 upl.defs
53
54 MACH_PRIVATE_DEFS = \
55 mach_notify.defs \
56 memory_object.defs \
57 memory_object_control.defs \
58 memory_object_default.defs \
59 memory_object_name.defs
60
61 #
62 # MIG-generated headers that are traditionally used by user
63 # level code.
64 #
65 MIG_USHDRS = \
66 clock_reply_server.h \
67 exc_server.h \
68 memory_object_server.h \
69 memory_object_default_server.h \
70 notify_server.h
71
72 MIG_UUHDRS = \
73 audit_triggers.h \
74 clock.h \
75 clock_priv.h \
76 host_priv.h \
77 host_security.h \
78 ledger.h \
79 lock_set.h \
80 mach_host.h \
81 mach_port.h \
82 memory_object_control.h \
83 memory_object_name.h \
84 processor.h \
85 processor_set.h \
86 task.h \
87 thread_act.h \
88 upl.h \
89 vm_map.h
90
91 MIGINCLUDES = ${MIG_UUHDRS} ${MIG_USHDRS}
92
93 DATAFILES = \
94 boolean.h \
95 boot_info.h \
96 bootstrap.h \
97 clock_types.h \
98 error.h \
99 exception.h \
100 exception_types.h \
101 host_notify.h \
102 host_info.h \
103 host_reboot.h \
104 host_special_ports.h \
105 kern_return.h \
106 kmod.h \
107 mach_param.h \
108 mach_time.h \
109 mach_traps.h \
110 mach_types.h \
111 machine.h \
112 mach_syscalls.h \
113 memory_object_types.h \
114 message.h \
115 mig.h \
116 mig_errors.h \
117 ndr.h \
118 notify.h \
119 policy.h \
120 port.h \
121 processor_info.h \
122 rpc.h \
123 semaphore.h \
124 shared_memory_server.h \
125 std_types.h \
126 sync_policy.h \
127 syscall_sw.h \
128 task_info.h \
129 task_ledger.h \
130 task_policy.h \
131 task_special_ports.h \
132 thread_info.h \
133 thread_policy.h \
134 thread_special_ports.h \
135 thread_status.h \
136 thread_switch.h \
137 time_value.h \
138 vm_attributes.h \
139 vm_behavior.h \
140 vm_inherit.h \
141 vm_param.h \
142 vm_prot.h \
143 vm_region.h \
144 vm_statistics.h \
145 vm_sync.h \
146 vm_types.h \
147 ${MIG_TYPES} \
148 ${MIG_DEFS}
149
150 INSTALL_MI_LIST = \
151 ${DATAFILES}
152
153 INSTALL_MI_GEN_LIST =
154
155 INSTALL_MI_DIR = mach
156
157 EXPORT_MI_LIST = \
158 mach_interface.h \
159 etap.h etap_events.h \
160 ${DATAFILES}
161
162 EXPORT_MI_GEN_LIST = \
163 ${MIGINCLUDES}
164
165 EXPORT_MI_DIR = mach
166
167 .ORDER: ${MIGINCLUDES}
168
169 ${MIGINCLUDES} : ${MIG_TYPES}
170
171 .ORDER: ${MIG_UUHDRS}
172
173 ${MIG_UUHDRS} : \
174 %.h : %.defs
175 $(MIG) $(MIGFLAGS) \
176 -server /dev/null \
177 -user /dev/null \
178 -header $@ \
179 $<
180
181 .ORDER: ${MIG_USHDRS}
182
183 ${MIG_USHDRS} : \
184 %_server.h : %.defs
185 $(MIG) $(MIGFLAGS) \
186 -server /dev/null \
187 -user /dev/null \
188 -header /dev/null \
189 -sheader $@ \
190 $<
191
192 #
193 # Build path
194 #
195 COMP_SUBDIRS_I386 = \
196 i386
197
198 INCFLAGS_MAKEFILE= -I..
199
200 MIGKSFLAGS = -DMACH_KERNEL_PRIVATE -DKERNEL_SERVER=1
201 MIGKUFLAGS = -DMACH_KERNEL_PRIVATE -DKERNEL_USER=1 -maxonstack 1024
202 #
203 # MIG-generated headers that are traditionally used by kernel
204 # level code.
205 #
206 MIG_KUHDRS = \
207 clock_reply.h \
208 exc.h \
209 host_notify_reply.h \
210 mach_notify.h \
211 memory_object.h \
212 memory_object_control.h \
213 memory_object_default.h \
214 upl.h \
215 vm_map.h
216
217 MIG_KUSRC = \
218 audit_triggers_user.c \
219 clock_reply_user.c \
220 exc_user.c \
221 host_notify_reply_user.c \
222 mach_notify_user.c \
223 memory_object_user.c \
224 memory_object_control_user.c \
225 memory_object_default_user.c \
226 upl_user.c \
227 vm_map_user.c
228
229 MIG_KSHDRS = \
230 clock_server.h \
231 clock_priv_server.h \
232 exc_server.h \
233 host_priv_server.h \
234 host_security_server.h \
235 ledger_server.h \
236 lock_set_server.h \
237 mach_host_server.h \
238 mach_notify_server.h \
239 mach_port_server.h \
240 memory_object_server.h \
241 memory_object_control_server.h \
242 memory_object_default_server.h \
243 memory_object_name_server.h \
244 processor_server.h \
245 processor_set_server.h \
246 semaphore_server.h \
247 task_server.h \
248 thread_act_server.h \
249 upl_server.h \
250 vm_map_server.h
251
252 MIG_KSSRC = \
253 clock_server.c \
254 clock_priv_server.c \
255 exc_server.c \
256 host_priv_server.c \
257 host_security_server.c \
258 ledger_server.c \
259 lock_set_server.c \
260 mach_host_server.c \
261 mach_notify_server.c \
262 mach_port_server.c \
263 memory_object_server.c \
264 memory_object_control_server.c \
265 memory_object_default_server.c \
266 memory_object_name_server.c \
267 processor_server.c \
268 processor_set_server.c \
269 semaphore_server.c \
270 task_server.c \
271 thread_act_server.c \
272 upl_server.c \
273 vm_map_server.c
274
275 #
276 # JMM -
277 # Since there are two generated header files with the same name, one for
278 # install and export, the other for internal use (and they are different)
279 # we can't explicitly list two rules for the same target. So rules for
280 # generating internal headers will be handled implicitly by creating rules
281 # to generate the internal C sources, and the headers get created as a
282 # side-effect.
283 #
284 #
285 # This is all temporary scaffolding, as we are moving to a model where
286 # the MIG-generated code is identical in all environments. At first, it
287 # will contain some environment-specific ifdefs, but over time should not
288 # even require that as we move towards making all the environments look
289 # the same.
290 #
291 COMP_FILES = ${MIG_KUSRC} ${MIG_KSSRC}
292
293 ${COMP_FILES} : ${MIG_TYPES}
294
295 .ORDER: ${MIG_KUSRC}
296
297 ${MIG_KUSRC} : \
298 %_user.c : %.defs
299 ${MIG} ${MIGFLAGS} ${MIGKUFLAGS} \
300 -user $*_user.c \
301 -header $*.h \
302 -server /dev/null \
303 -sheader /dev/null \
304 $<
305
306 .ORDER: ${MIG_KSSRC}
307
308 ${MIG_KSSRC}: \
309 %_server.c : %.defs
310 ${MIG} ${MIGFLAGS} ${MIGKSFLAGS} \
311 -user /dev/null \
312 -header /dev/null \
313 -server $*_server.c \
314 -sheader $*_server.h \
315 $<
316
317 include $(MakeInc_rule)
318 include $(MakeInc_dir)