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