]>
Commit | Line | Data |
---|---|---|
91447636 | 1 | # |
5d5c5d0d | 2 | # Copyright (c) 2000-2004 Apple Computer, Inc. All rights reserved. |
91447636 | 3 | # |
6601e61a | 4 | # @APPLE_LICENSE_HEADER_START@ |
91447636 | 5 | # |
8f6c56a5 A |
6 | # The contents of this file constitute Original Code as defined in and |
7 | # are subject to the Apple Public Source License Version 1.1 (the | |
8 | # "License"). You may not use this file except in compliance with the | |
9 | # License. Please obtain a copy of the License at | |
10 | # http://www.apple.com/publicsource and read it before using this file. | |
11 | # | |
12 | # This Original Code and all software distributed under the License are | |
13 | # distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER | |
14 | # EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, | |
15 | # INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, | |
16 | # FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the | |
17 | # License for the specific language governing rights and limitations | |
18 | # under the License. | |
19 | # | |
6601e61a | 20 | # @APPLE_LICENSE_HEADER_END@ |
91447636 A |
21 | # |
22 | ||
1c79356b A |
23 | # |
24 | # Mach Operating System | |
25 | # Copyright (c) 1986 Carnegie-Mellon University | |
26 | # All rights reserved. The CMU software License Agreement specifies | |
27 | # the terms and conditions for use and redistribution. | |
28 | # | |
29 | ||
30 | # | |
31 | # Export IDENT for sub-makefiles | |
32 | # | |
33 | export IDENT | |
34 | ||
1c79356b A |
35 | export MakeInc_cmd=${SRCROOT}/makedefs/MakeInc.cmd |
36 | export MakeInc_def=${SRCROOT}/makedefs/MakeInc.def | |
37 | export MakeInc_rule=${SRCROOT}/makedefs/MakeInc.rule | |
38 | export MakeInc_dir=${SRCROOT}/makedefs/MakeInc.dir | |
39 | ||
40 | include $(MakeInc_cmd) | |
41 | include $(MakeInc_def) | |
42 | ||
43 | # | |
44 | # XXX: CFLAGS | |
45 | # | |
9bccf70c A |
46 | CFLAGS+= -imacros meta_features.h -DARCH_PRIVATE -DKERNEL -DDRIVER_PRIVATE \ |
47 | -D_KERNEL_BUILD -DKERNEL_BUILD -DMACH_KERNEL -DBSD_BUILD \ | |
b0d623f7 | 48 | -DBSD_KERNEL_PRIVATE -DLP64KERN=1 -DLP64_DEBUG=0 -I. $(CFLAGS_INLINE_CONFIG) |
0b4e3aa0 | 49 | |
1c79356b A |
50 | # |
51 | # Directories for mig generated files | |
52 | # | |
53 | COMP_SUBDIRS = | |
54 | ||
55 | # | |
56 | # Make sure we don't remove this by accident if interrupted at the wrong | |
57 | # time. | |
58 | # | |
59 | .PRECIOUS: Makefile | |
60 | ||
1c79356b A |
61 | # |
62 | # Theses macros are filled in by the config program depending on the | |
63 | # current configuration. The MACHDEP macro is replaced by the | |
64 | # contents of the machine dependent makefile template and the others | |
65 | # are replaced by the corresponding symbol definitions for the | |
66 | # configuration. | |
67 | # | |
68 | ||
69 | %OBJS | |
70 | ||
71 | %CFILES | |
72 | ||
73 | %MFILES | |
74 | ||
75 | %SFILES | |
76 | ||
77 | %BFILES | |
78 | ||
79 | %ORDERED | |
80 | %MACHDEP | |
81 | ||
55e303ae A |
82 | # |
83 | # This rule insures that the subr_prof.c does NOT get compiled with | |
84 | # profiling. It implements mcount() and profiling it leads to recursion. | |
85 | # | |
86 | ||
87 | subr_prof.o_CFLAGS_RM = -pg | |
88 | ||
1c79356b A |
89 | # |
90 | # OBJSDEPS is the set of files (defined in the machine dependent | |
91 | # template if necessary) which all objects depend on (such as an | |
92 | # in-line assembler expansion filter) | |
93 | # | |
94 | ${OBJS}: ${OBJSDEPS} | |
95 | ||
96 | ||
97 | %LOAD | |
98 | ||
99 | LDOBJS = $(OBJS) | |
100 | ||
101 | $(COMPONENT).o: $(LDOBJS) | |
b0d623f7 A |
102 | @echo LDFILELIST $(COMPONENT) |
103 | $(_v)( for obj in ${LDOBJS}; do \ | |
104 | echo $(TARGET)$(COMP_OBJ_DIR)/$(KERNEL_CONFIG)/$${obj}; \ | |
105 | done; ) > $(COMPONENT).o | |
106 | ||
107 | MAKESYSCALLS = $(SRCROOT)/bsd/kern/makesyscalls.sh | |
108 | ||
109 | init_sysent.c: $(SRCROOT)/bsd/kern/syscalls.master $(MAKESYSCALLS) | |
110 | @echo "Generating $@ from $<"; | |
111 | $(_v)$(MAKESYSCALLS) $< table > /dev/null | |
112 | ||
113 | syscalls.c: $(SRCROOT)/bsd/kern/syscalls.master $(MAKESYSCALLS) | |
114 | @echo "Generating $@ from $<"; | |
115 | $(_v)$(MAKESYSCALLS) $< names > /dev/null | |
116 | ||
117 | audit_kevents.c: $(SRCROOT)/bsd/kern/syscalls.master $(MAKESYSCALLS) | |
118 | @echo "Generating $@ from $<"; | |
119 | $(_v)$(MAKESYSCALLS) $< audit > /dev/null | |
1c79356b A |
120 | |
121 | do_depend: do_all | |
2d21ac55 | 122 | $(_v)${MD} -u Makedep -f -d `ls *.d`; |
b0d623f7 | 123 | |
1c79356b A |
124 | do_all: $(COMPONENT).o |
125 | ||
126 | do_build_all: do_depend | |
127 | ||
128 | %RULES | |
129 | ||
1c79356b A |
130 | include $(MakeInc_rule) |
131 | include $(MakeInc_dir) |