]>
Commit | Line | Data |
---|---|---|
1c79356b A |
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 | ||
1c79356b A |
6 | include $(MakeInc_cmd) |
7 | include $(MakeInc_def) | |
8 | ||
6d2010ae | 9 | INSTINC_SUBDIRS = machine |
6d2010ae | 10 | INSTINC_SUBDIRS_X86_64 = i386 |
fe8ab488 | 11 | INSTINC_SUBDIRS_X86_64H = i386 |
3e170ce0 A |
12 | INSTINC_SUBDIRS_ARM = arm arm64 |
13 | INSTINC_SUBDIRS_ARM64 = arm arm64 | |
b0d623f7 | 14 | |
6d2010ae | 15 | EXPINC_SUBDIRS = machine |
6d2010ae | 16 | EXPINC_SUBDIRS_X86_64 = i386 |
fe8ab488 | 17 | EXPINC_SUBDIRS_X86_64H = i386 |
3e170ce0 A |
18 | EXPINC_SUBDIRS_ARM = arm arm64 |
19 | EXPINC_SUBDIRS_ARM64 = arm arm64 | |
2d21ac55 | 20 | |
1c79356b A |
21 | MIG_TYPES = \ |
22 | clock_types.defs \ | |
23 | mach_types.defs \ | |
24 | std_types.defs | |
25 | ||
26 | MIG_DEFS = \ | |
e5568f75 | 27 | audit_triggers.defs \ |
1c79356b A |
28 | clock.defs \ |
29 | clock_priv.defs \ | |
30 | clock_reply.defs \ | |
31 | exc.defs \ | |
55e303ae | 32 | host_notify_reply.defs \ |
1c79356b A |
33 | host_priv.defs \ |
34 | host_security.defs \ | |
1c79356b | 35 | lock_set.defs \ |
2d21ac55 | 36 | mach_exc.defs \ |
1c79356b A |
37 | mach_host.defs \ |
38 | mach_port.defs \ | |
91447636 | 39 | mach_vm.defs \ |
fe8ab488 A |
40 | mach_voucher.defs \ |
41 | mach_voucher_attr_control.defs \ | |
d9a64523 | 42 | memory_entry.defs \ |
1c79356b A |
43 | notify.defs \ |
44 | processor.defs \ | |
45 | processor_set.defs \ | |
46 | task.defs \ | |
2d21ac55 | 47 | task_access.defs \ |
39236c6e | 48 | telemetry_notification.defs \ |
1c79356b | 49 | thread_act.defs \ |
91447636 | 50 | vm_map.defs |
1c79356b | 51 | |
cb323159 A |
52 | MIG_PRIVATE_DEFS = \ |
53 | restartable.defs | |
54 | ||
1c79356b | 55 | MACH_PRIVATE_DEFS = \ |
fe8ab488 | 56 | coalition_notification.defs \ |
cb323159 A |
57 | fairplayd_notification.defs \ |
58 | arcade_upcall.defs \ | |
39037602 | 59 | ktrace_background.defs \ |
55e303ae | 60 | mach_notify.defs \ |
1c79356b A |
61 | memory_object_control.defs \ |
62 | memory_object_default.defs \ | |
3e170ce0 | 63 | sysdiagnose_notification.defs \ |
b0d623f7 | 64 | upl.defs \ |
cb323159 | 65 | vfs_nspace.defs \ |
b0d623f7 | 66 | vm32_map.defs |
1c79356b A |
67 | |
68 | # | |
69 | # MIG-generated headers that are traditionally used by user | |
70 | # level code. | |
71 | # | |
72 | MIG_USHDRS = \ | |
91447636 | 73 | audit_triggers_server.h \ |
1c79356b | 74 | clock_reply_server.h \ |
fe8ab488 | 75 | coalition_notification_server.h \ |
1c79356b | 76 | exc_server.h \ |
cb323159 A |
77 | fairplayd_notification_server.h \ |
78 | arcade_upcall_server.h \ | |
2d21ac55 | 79 | mach_exc_server.h \ |
1c79356b | 80 | memory_object_default_server.h \ |
2d21ac55 | 81 | notify_server.h \ |
39236c6e | 82 | task_access_server.h \ |
3e170ce0 | 83 | telemetry_notification_server.h \ |
cb323159 A |
84 | sysdiagnose_notification_server.h \ |
85 | vfs_nspace_server.h | |
1c79356b A |
86 | |
87 | MIG_UUHDRS = \ | |
1c79356b A |
88 | clock.h \ |
89 | clock_priv.h \ | |
90 | host_priv.h \ | |
91 | host_security.h \ | |
39037602 | 92 | ktrace_background.h \ |
1c79356b A |
93 | lock_set.h \ |
94 | mach_host.h \ | |
95 | mach_port.h \ | |
91447636 | 96 | mach_vm.h \ |
fe8ab488 A |
97 | mach_voucher.h \ |
98 | mach_voucher_attr_control.h \ | |
d9a64523 | 99 | memory_entry.h \ |
1c79356b | 100 | memory_object_control.h \ |
1c79356b A |
101 | processor.h \ |
102 | processor_set.h \ | |
103 | task.h \ | |
2d21ac55 | 104 | task_access.h \ |
1c79356b A |
105 | thread_act.h \ |
106 | upl.h \ | |
cb323159 A |
107 | vm_map.h \ |
108 | vfs_nspace.h | |
1c79356b A |
109 | |
110 | MIGINCLUDES = ${MIG_UUHDRS} ${MIG_USHDRS} | |
111 | ||
112 | DATAFILES = \ | |
113 | boolean.h \ | |
1c79356b | 114 | clock_types.h \ |
39037602 | 115 | dyld_kernel.h \ |
1c79356b A |
116 | error.h \ |
117 | exception.h \ | |
118 | exception_types.h \ | |
55e303ae | 119 | host_notify.h \ |
1c79356b A |
120 | host_info.h \ |
121 | host_reboot.h \ | |
55e303ae | 122 | host_special_ports.h \ |
1c79356b A |
123 | kern_return.h \ |
124 | kmod.h \ | |
1c79356b A |
125 | mach_param.h \ |
126 | mach_time.h \ | |
127 | mach_traps.h \ | |
128 | mach_types.h \ | |
fe8ab488 | 129 | mach_voucher_types.h \ |
1c79356b A |
130 | machine.h \ |
131 | mach_syscalls.h \ | |
132 | memory_object_types.h \ | |
133 | message.h \ | |
134 | mig.h \ | |
135 | mig_errors.h \ | |
fe8ab488 | 136 | mig_voucher_support.h \ |
39037602 | 137 | mig_strncpy_zerofill_support.h \ |
1c79356b A |
138 | ndr.h \ |
139 | notify.h \ | |
140 | policy.h \ | |
141 | port.h \ | |
142 | processor_info.h \ | |
143 | rpc.h \ | |
2d21ac55 | 144 | sdt.h \ |
1c79356b A |
145 | semaphore.h \ |
146 | shared_memory_server.h \ | |
2d21ac55 | 147 | shared_region.h \ |
1c79356b A |
148 | std_types.h \ |
149 | sync_policy.h \ | |
150 | syscall_sw.h \ | |
151 | task_info.h \ | |
5ba3f43e | 152 | task_inspect.h \ |
1c79356b A |
153 | task_policy.h \ |
154 | task_special_ports.h \ | |
155 | thread_info.h \ | |
156 | thread_policy.h \ | |
157 | thread_special_ports.h \ | |
158 | thread_status.h \ | |
159 | thread_switch.h \ | |
160 | time_value.h \ | |
161 | vm_attributes.h \ | |
162 | vm_behavior.h \ | |
163 | vm_inherit.h \ | |
164 | vm_param.h \ | |
165 | vm_prot.h \ | |
91447636 | 166 | vm_purgable.h \ |
1c79356b A |
167 | vm_region.h \ |
168 | vm_statistics.h \ | |
169 | vm_sync.h \ | |
170 | vm_types.h \ | |
171 | ${MIG_TYPES} \ | |
172 | ${MIG_DEFS} | |
173 | ||
174 | INSTALL_MI_LIST = \ | |
91447636 | 175 | bootstrap.h \ |
1c79356b A |
176 | ${DATAFILES} |
177 | ||
39037602 | 178 | # installed into System.framework's PrivateHeaders/mach subdirectory |
3e170ce0 | 179 | PRIVATE_DATAFILES = \ |
fe8ab488 | 180 | bootstrap.h \ |
3e170ce0 | 181 | coalition.h \ |
fe8ab488 | 182 | coalition_notification.defs \ |
cb323159 A |
183 | fairplayd_notification.defs \ |
184 | arcade_upcall.defs \ | |
3e170ce0 | 185 | host_info.h \ |
39037602 | 186 | ktrace_background.defs \ |
3e170ce0 A |
187 | mach_host.defs \ |
188 | mach_traps.h \ | |
189 | memory_object_types.h \ | |
190 | mig.h \ | |
813fb2f6 | 191 | mk_timer.h \ |
3e170ce0 | 192 | processor_info.h \ |
39037602 A |
193 | resource_notify.defs \ |
194 | resource_monitors.h \ | |
3e170ce0 A |
195 | semaphore.h \ |
196 | sfi_class.h \ | |
197 | syscall_sw.h \ | |
198 | sysdiagnose_notification.defs \ | |
199 | task_info.h \ | |
5ba3f43e | 200 | task_inspect.h \ |
3e170ce0 A |
201 | task_policy.h \ |
202 | thread_policy.h \ | |
203 | thread_switch.h \ | |
cb323159 A |
204 | vfs_nspace.defs \ |
205 | vm_prot.h \ | |
206 | ${MIG_PRIVATE_DEFS} | |
3e170ce0 A |
207 | |
208 | INSTALL_MI_LCL_LIST = ${PRIVATE_DATAFILES} | |
fe8ab488 | 209 | |
91447636 A |
210 | INSTALL_KF_MI_LIST = \ |
211 | mach_interface.h \ | |
212 | $(filter-out mach_traps.h mach_syscalls.h thread_switch.h, ${DATAFILES}) | |
213 | ||
214 | INSTALL_KF_MI_LCL_LIST = \ | |
3e170ce0 | 215 | coalition.h \ |
91447636 A |
216 | mach_interface.h \ |
217 | $(filter-out mach_traps.h mach_syscalls.h thread_switch.h, ${DATAFILES}) | |
218 | ||
1c79356b A |
219 | INSTALL_MI_GEN_LIST = |
220 | ||
221 | INSTALL_MI_DIR = mach | |
222 | ||
223 | EXPORT_MI_LIST = \ | |
3e170ce0 | 224 | coalition.h \ |
1c79356b | 225 | mach_interface.h \ |
39037602 | 226 | resource_monitors.h \ |
fe8ab488 | 227 | sfi_class.h \ |
1c79356b A |
228 | ${DATAFILES} |
229 | ||
230 | EXPORT_MI_GEN_LIST = \ | |
231 | ${MIGINCLUDES} | |
232 | ||
233 | EXPORT_MI_DIR = mach | |
234 | ||
1c79356b A |
235 | ${MIGINCLUDES} : ${MIG_TYPES} |
236 | ||
1c79356b A |
237 | ${MIG_UUHDRS} : \ |
238 | %.h : %.defs | |
cb323159 | 239 | $(call makelog,$(ColorM)MIG$(Color0) $(ColorF)$@$(Color0)) |
2d21ac55 | 240 | $(_v)$(MIG) $(MIGFLAGS) \ |
1c79356b A |
241 | -server /dev/null \ |
242 | -user /dev/null \ | |
39037602 | 243 | -header $@ \ |
1c79356b A |
244 | $< |
245 | ||
1c79356b A |
246 | ${MIG_USHDRS} : \ |
247 | %_server.h : %.defs | |
cb323159 | 248 | $(call makelog,$(ColorM)MIG$(Color0) $(ColorF)$@$(Color0)) |
2d21ac55 | 249 | $(_v)$(MIG) $(MIGFLAGS) \ |
1c79356b A |
250 | -server /dev/null \ |
251 | -user /dev/null \ | |
252 | -header /dev/null \ | |
39037602 | 253 | -sheader $@ \ |
1c79356b A |
254 | $< |
255 | ||
256 | # | |
257 | # Build path | |
258 | # | |
1c79356b A |
259 | |
260 | INCFLAGS_MAKEFILE= -I.. | |
261 | ||
262 | MIGKSFLAGS = -DMACH_KERNEL_PRIVATE -DKERNEL_SERVER=1 | |
263 | MIGKUFLAGS = -DMACH_KERNEL_PRIVATE -DKERNEL_USER=1 -maxonstack 1024 | |
264 | # | |
265 | # MIG-generated headers that are traditionally used by kernel | |
266 | # level code. | |
267 | # | |
39037602 A |
268 | |
269 | # sender-side ("user") headers generated by MIG from corresponding .defs | |
1c79356b | 270 | MIG_KUHDRS = \ |
91447636 | 271 | audit_triggers.h \ |
1c79356b A |
272 | clock_reply.h \ |
273 | exc.h \ | |
55e303ae | 274 | host_notify_reply.h \ |
39037602 | 275 | ktrace_background.h \ |
2d21ac55 | 276 | mach_exc.h \ |
55e303ae | 277 | mach_notify.h \ |
1c79356b | 278 | memory_object.h \ |
0b4e3aa0 | 279 | memory_object_control.h \ |
1c79356b | 280 | memory_object_default.h \ |
39037602 | 281 | resource_notify.h \ |
2d21ac55 | 282 | task_access.h \ |
1c79356b A |
283 | upl.h \ |
284 | vm_map.h | |
285 | ||
39037602 | 286 | # sender-side ("user") source files generated by MIG from corresponding .defs |
1c79356b | 287 | MIG_KUSRC = \ |
e5568f75 | 288 | audit_triggers_user.c \ |
1c79356b | 289 | clock_reply_user.c \ |
fe8ab488 | 290 | coalition_notification_user.c \ |
1c79356b | 291 | exc_user.c \ |
cb323159 A |
292 | fairplayd_notification_user.c \ |
293 | arcade_upcall_user.c \ | |
55e303ae | 294 | host_notify_reply_user.c \ |
39037602 | 295 | ktrace_background_user.c \ |
2d21ac55 | 296 | mach_exc_user.c \ |
55e303ae | 297 | mach_notify_user.c \ |
1c79356b | 298 | memory_object_user.c \ |
0b4e3aa0 | 299 | memory_object_control_user.c \ |
1c79356b | 300 | memory_object_default_user.c \ |
39037602 | 301 | resource_notify_user.c \ |
2d21ac55 | 302 | task_access_user.c \ |
39236c6e | 303 | telemetry_notification_user.c \ |
1c79356b | 304 | upl_user.c \ |
cb323159 | 305 | vfs_nspace_user.c \ |
3e170ce0 A |
306 | vm_map_user.c \ |
307 | sysdiagnose_notification_user.c | |
1c79356b A |
308 | |
309 | MIG_KSHDRS = \ | |
cb323159 | 310 | arcade_register_server.h \ |
1c79356b A |
311 | clock_server.h \ |
312 | clock_priv_server.h \ | |
313 | exc_server.h \ | |
314 | host_priv_server.h \ | |
315 | host_security_server.h \ | |
1c79356b | 316 | lock_set_server.h \ |
2d21ac55 | 317 | mach_exc_server.h \ |
1c79356b | 318 | mach_host_server.h \ |
55e303ae | 319 | mach_notify_server.h \ |
1c79356b | 320 | mach_port_server.h \ |
91447636 | 321 | mach_vm_server.h \ |
fe8ab488 A |
322 | mach_voucher_server.h \ |
323 | mach_voucher_attr_control_server.h \ | |
d9a64523 | 324 | memory_entry_server.h \ |
1c79356b A |
325 | memory_object_control_server.h \ |
326 | memory_object_default_server.h \ | |
1c79356b A |
327 | processor_server.h \ |
328 | processor_set_server.h \ | |
cb323159 | 329 | restartable_server.h \ |
1c79356b A |
330 | task_server.h \ |
331 | thread_act_server.h \ | |
332 | upl_server.h \ | |
b0d623f7 A |
333 | vm_map_server.h \ |
334 | vm32_map_server.h | |
1c79356b A |
335 | |
336 | MIG_KSSRC = \ | |
cb323159 | 337 | arcade_register_server.c \ |
1c79356b A |
338 | clock_server.c \ |
339 | clock_priv_server.c \ | |
340 | exc_server.c \ | |
341 | host_priv_server.c \ | |
342 | host_security_server.c \ | |
1c79356b | 343 | lock_set_server.c \ |
2d21ac55 | 344 | mach_exc_server.c \ |
1c79356b | 345 | mach_host_server.c \ |
55e303ae | 346 | mach_notify_server.c \ |
1c79356b | 347 | mach_port_server.c \ |
91447636 | 348 | mach_vm_server.c \ |
fe8ab488 A |
349 | mach_voucher_server.c \ |
350 | mach_voucher_attr_control_server.c \ | |
d9a64523 | 351 | memory_entry_server.c \ |
1c79356b A |
352 | memory_object_control_server.c \ |
353 | memory_object_default_server.c \ | |
1c79356b A |
354 | processor_server.c \ |
355 | processor_set_server.c \ | |
cb323159 | 356 | restartable_server.c \ |
1c79356b A |
357 | task_server.c \ |
358 | thread_act_server.c \ | |
359 | upl_server.c \ | |
b0d623f7 A |
360 | vm_map_server.c \ |
361 | vm32_map_server.c | |
1c79356b A |
362 | |
363 | # | |
364 | # JMM - | |
365 | # Since there are two generated header files with the same name, one for | |
366 | # install and export, the other for internal use (and they are different) | |
367 | # we can't explicitly list two rules for the same target. So rules for | |
368 | # generating internal headers will be handled implicitly by creating rules | |
369 | # to generate the internal C sources, and the headers get created as a | |
370 | # side-effect. | |
371 | # | |
372 | # | |
373 | # This is all temporary scaffolding, as we are moving to a model where | |
374 | # the MIG-generated code is identical in all environments. At first, it | |
375 | # will contain some environment-specific ifdefs, but over time should not | |
376 | # even require that as we move towards making all the environments look | |
377 | # the same. | |
378 | # | |
379 | COMP_FILES = ${MIG_KUSRC} ${MIG_KSSRC} | |
380 | ||
39236c6e A |
381 | do_build_all:: $(COMP_FILES) |
382 | ||
1c79356b | 383 | ${COMP_FILES} : ${MIG_TYPES} |
1c79356b A |
384 | |
385 | ${MIG_KUSRC} : \ | |
386 | %_user.c : %.defs | |
cb323159 | 387 | $(call makelog,$(ColorM)MIG$(Color0) $(ColorF)$@$(Color0)) |
2d21ac55 | 388 | $(_v)${MIG} ${MIGFLAGS} ${MIGKUFLAGS} \ |
1c79356b A |
389 | -user $*_user.c \ |
390 | -header $*.h \ | |
391 | -server /dev/null \ | |
392 | -sheader /dev/null \ | |
393 | $< | |
394 | ||
1c79356b A |
395 | ${MIG_KSSRC}: \ |
396 | %_server.c : %.defs | |
cb323159 | 397 | $(call makelog,$(ColorM)MIG$(Color0) $(ColorF)$@$(Color0)) |
2d21ac55 | 398 | $(_v)${MIG} ${MIGFLAGS} ${MIGKSFLAGS} \ |
1c79356b A |
399 | -user /dev/null \ |
400 | -header /dev/null \ | |
401 | -server $*_server.c \ | |
402 | -sheader $*_server.h \ | |
403 | $< | |
1c79356b A |
404 | |
405 | include $(MakeInc_rule) | |
406 | include $(MakeInc_dir) |