]> git.saurik.com Git - apple/xnu.git/blame - bsd/sys/Makefile
xnu-2782.10.72.tar.gz
[apple/xnu.git] / bsd / sys / Makefile
CommitLineData
1c79356b
A
1export MakeInc_cmd=${SRCROOT}/makedefs/MakeInc.cmd
2export MakeInc_def=${SRCROOT}/makedefs/MakeInc.def
3export MakeInc_rule=${SRCROOT}/makedefs/MakeInc.rule
4export MakeInc_dir=${SRCROOT}/makedefs/MakeInc.dir
5
6
7include $(MakeInc_cmd)
8include $(MakeInc_def)
9
39236c6e
A
10INSTINC_SUBDIRS = \
11 _types
593a1d5f 12
39236c6e
A
13EXPINC_SUBDIRS = \
14 _types
1c79356b 15
2d21ac55 16# Installs header file for user level -
2d21ac55
A
17# $(DSTROOT)/System/Library/Frameworks/System.framework/PrivateHeaders
18# $(DSTROOT)/usr/include/
1c79356b 19DATAFILES = \
55e303ae 20 appleapiopts.h acct.h aio.h attr.h \
91447636 21 buf.h cdefs.h conf.h \
2d21ac55
A
22 dir.h dirent.h disk.h dkstat.h dtrace.h dtrace_glue.h dtrace_impl.h \
23 errno.h ev.h event.h fasttrap.h fasttrap_isa.h fcntl.h file.h filedesc.h filio.h gmon.h \
91447636
A
24 ioccom.h ioctl.h \
25 ioctl_compat.h ipc.h kernel.h kernel_types.h kern_event.h loadable_fs.h lock.h lockf.h \
fe8ab488 26 kauth.h kdebug.h kern_control.h lctx.h lockstat.h malloc.h \
b0d623f7 27 mbuf.h mman.h mount.h msg.h msgbuf.h netport.h param.h paths.h pipe.h poll.h \
2d21ac55
A
28 proc.h proc_info.h ptrace.h queue.h quota.h random.h reboot.h resource.h resourcevar.h \
29 sbuf.h posix_sem.h posix_shm.h sdt.h \
fe8ab488 30 select.h sem.h semaphore.h shm.h signal.h signalvar.h socket.h socketvar.h sockio.h stat.h stdio.h \
b0d623f7 31 sysctl.h syslimits.h syslog.h sys_domain.h termios.h time.h \
1c79356b 32 timeb.h times.h tprintf.h trace.h tty.h ttychars.h ttycom.h \
9bccf70c 33 ttydefaults.h ttydev.h types.h ubc.h ucontext.h ucred.h uio.h un.h unistd.h unpcb.h \
2d21ac55 34 user.h utfconv.h utsname.h vadvise.h vcmd.h \
91447636 35 vm.h vmmeter.h vmparam.h vnioctl.h vnode.h vnode_if.h vstat.h wait.h xattr.h \
2d21ac55
A
36 _select.h _structs.h _types.h _endian.h domain.h protosw.h \
37 spawn.h
91447636 38
2d21ac55
A
39# Installs header file for Apple internal use in user level -
40# $(DSTROOT)/System/Library/Frameworks/System.framework/PrivateHeaders
91447636 41PRIVATE_DATAFILES = \
fe8ab488 42 coalition.h \
2d21ac55 43 codesign.h \
6d2010ae 44 content_protection.h \
fe8ab488 45 csr.h \
316670eb 46 decmpfs.h \
91447636 47 disklabel.h \
6d2010ae 48 fileport.h \
b0d623f7
A
49 fsctl.h \
50 fsgetpath.h \
2d21ac55 51 fslog.h \
39236c6e 52 guarded.h \
6d2010ae 53 imgsrc.h \
91447636 54 ipcs.h \
316670eb 55 kas_info.h \
fe8ab488 56 kern_memorystatus.h \
39236c6e 57 kern_overrides.h \
fe8ab488 58 sfi.h \
91447636 59 shm_internal.h \
2d21ac55 60 spawn_internal.h \
b0d623f7 61 tree.h \
91447636 62 ux_exception.h \
6d2010ae 63 process_policy.h \
39236c6e 64 proc_uuid_policy.h \
6d2010ae 65 priv.h
91447636 66
2d21ac55
A
67# Installs header file for kernel extensions -
68# $(DSTROOT)/System/Library/Frameworks/Kernel.framework/Headers
69# $(DSTROOT)/System/Library/Frameworks/Kernel.framework/PrivateHeaders
91447636
A
70KERNELFILES = \
71 appleapiopts.h attr.h \
72 buf.h cdefs.h conf.h \
2d21ac55 73 dir.h dirent.h disk.h disklabel.h dkstat.h \
b0d623f7 74 errno.h ev.h event.h fcntl.h file.h filio.h \
2d21ac55
A
75 ioccom.h ioctl.h ipc.h \
76 ioctl_compat.h kernel.h kernel_types.h kern_event.h lctx.h lock.h lockf.h \
fe8ab488 77 kauth.h kdebug.h md5.h kern_control.h imgact.h malloc.h namei.h \
b0d623f7
A
78 mman.h mbuf.h mount.h netport.h param.h paths.h \
79 proc.h queue.h random.h resource.h \
2d21ac55 80 sbuf.h posix_sem.h posix_shm.h sem.h shm.h \
fe8ab488 81 select.h signal.h socket.h socketvar.h sockio.h stat.h stdio.h \
91447636
A
82 sysctl.h syslimits.h syslog.h systm.h sys_domain.h time.h \
83 types.h ubc.h ucontext.h ucred.h uio.h un.h unistd.h unpcb.h \
2d21ac55
A
84 utfconv.h vm.h vmparam.h vnode.h vnode_if.h xattr.h \
85 _select.h _structs.h _types.h _endian.h protosw.h domain.h \
91447636 86 kpi_mbuf.h kpi_socket.h kpi_socketfilter.h \
2d21ac55 87 ttycom.h termios.h msg.h \
b0d623f7 88 wait.h \
2d21ac55
A
89 spawn.h
90# The last line was added to export needed headers for the MAC calls
91# whose source is outside of the xnu/bsd tree.
91447636
A
92
93
2d21ac55
A
94# Installs header file for Apple internal use for kernel extensions -
95# $(DSTROOT)/System/Library/Frameworks/Kernel.framework/PrivateHeaders
91447636 96PRIVATE_KERNELFILES = \
6d2010ae 97 codesign.h \
d1ecb069 98 cprotect.h \
6d2010ae 99 content_protection.h \
fe8ab488 100 csr.h \
b0d623f7 101 decmpfs.h \
91447636 102 disktab.h \
2d21ac55 103 fbt.h \
6d2010ae 104 fileport.h \
b0d623f7 105 fsctl.h \
2d21ac55 106 fslog.h \
fe8ab488
A
107 kasl.h \
108 kern_memorystatus.h \
91447636
A
109 mach_swapon.h \
110 msgbuf.h \
111 eventvar.h \
fe8ab488 112 proc_info.h \
39236c6e 113 pthread_shims.h \
b0d623f7 114 quota.h \
2d21ac55
A
115 sem_internal.h \
116 shm_internal.h \
91447636
A
117 signalvar.h \
118 tty.h ttychars.h \
119 ttydefaults.h ttydev.h \
120 user.h \
2d21ac55
A
121 vfs_context.h \
122 vmmeter.h \
6d2010ae
A
123 spawn_internal.h \
124 priv.h
b0d623f7 125
1c79356b 126
2d21ac55 127# /System/Library/Frameworks/System.framework/Headers and /usr/include
1c79356b
A
128INSTALL_MI_LIST = ${DATAFILES}
129
6d2010ae 130INSTALL_MI_GEN_LIST = syscall.h _posix_availability.h _symbol_aliasing.h
b0d623f7 131
1c79356b
A
132INSTALL_MI_DIR = sys
133
6d2010ae 134EXPORT_MI_LIST = ${KERNELFILES} ${PRIVATE_KERNELFILES} linker_set.h bsdtask_info.h pthread_internal.h filedesc.h pipe.h resourcevar.h semaphore.h \
b0d623f7 135 vnode_internal.h proc_internal.h file_internal.h mount_internal.h \
39236c6e 136 uio_internal.h tree.h munge.h kern_tests.h
b0d623f7
A
137
138EXPORT_MI_GEN_LIST = syscall.h sysproto.h
1c79356b
A
139
140EXPORT_MI_DIR = sys
141
91447636
A
142# /System/Library/Frameworks/System.framework/PrivateHeaders
143INSTALL_MI_LCL_LIST = ${DATAFILES} ${PRIVATE_DATAFILES}
144
145# /System/Library/Frameworks/Kernel.framework/PrivateHeaders
91447636
A
146INSTALL_KF_MI_LCL_LIST = ${KERNELFILES} ${PRIVATE_KERNELFILES}
147
b0d623f7
A
148INSTALL_KF_MI_LCL_GEN_LIST = sysproto.h
149
91447636 150# /System/Library/Frameworks/Kernel.framework/Headers
91447636 151INSTALL_KF_MI_LIST = ${KERNELFILES}
1c79356b 152
b0d623f7
A
153INSTALL_KF_MI_GEN_LIST =
154
155MAKESYSCALLS = $(SRCROOT)/bsd/kern/makesyscalls.sh
156
fe8ab488
A
157$(OBJROOT)/cscope.genhdrs:
158 $(_v)mkdir -p $(OBJROOT)/cscope.genhdrs
159
160syscall.h: $(SRCROOT)/bsd/kern/syscalls.master $(MAKESYSCALLS) $(OBJROOT)/cscope.genhdrs
b0d623f7 161 @echo "Generating bsd/sys/$@ from $<";
fe8ab488 162 @echo "$(OBJPATH)/bsd/sys/$@" > $(OBJROOT)/cscope.genhdrs/$@.path
b0d623f7
A
163 $(_v)$(MAKESYSCALLS) $< header > /dev/null
164
fe8ab488 165sysproto.h: $(SRCROOT)/bsd/kern/syscalls.master $(MAKESYSCALLS) $(OBJROOT)/cscope.genhdrs
b0d623f7 166 @echo "Generating bsd/sys/$@ from $<";
fe8ab488 167 @echo "$(OBJPATH)/bsd/sys/$@" > $(OBJROOT)/cscope.genhdrs/$@.path
b0d623f7
A
168 $(_v)$(MAKESYSCALLS) $< proto > /dev/null
169
6d2010ae
A
170MAKE_POSIX_AVAILABILITY = $(SRCROOT)/bsd/sys/make_posix_availability.sh
171_posix_availability.h: $(MAKE_POSIX_AVAILABILITY)
172 @echo "Generating bsd/sys/$@"
316670eb 173 $(_v)$(MAKE_POSIX_AVAILABILITY) "$@"
6d2010ae
A
174
175MAKE_SYMBOL_ALIASING = $(SRCROOT)/bsd/sys/make_symbol_aliasing.sh
176_symbol_aliasing.h: $(MAKE_SYMBOL_ALIASING)
177 @echo "Generating bsd/sys/$@"
316670eb 178 $(_v)$(MAKE_SYMBOL_ALIASING) "$(SDKROOT)" "$@"
6d2010ae 179
1c79356b
A
180include $(MakeInc_rule)
181include $(MakeInc_dir)
182
183