]> git.saurik.com Git - apple/xnu.git/blame - osfmk/default_pager/Makefile
xnu-344.tar.gz
[apple/xnu.git] / osfmk / default_pager / 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
10MIG_TYPES = \
11 default_pager_types.defs
12
13MIG_DEFS = \
14 default_pager_alerts.defs
15
16MIG_USHDRS = \
17
18MIG_UUHDRS = \
19
20
21MIGINCLUDES = ${MIG_UUHDRS} ${MIG_USHDRS}
22
23DATAFILES = \
24 default_pager_types.h \
25 ${MIG_DEFS}
26
27INSTALL_MI_LIST = ${DATAFILES}
28
29INSTALL_MI_GEN_LIST = ${MIGINCLUDES}
30
31INSTALL_MI_DIR = default_pager
32
33EXPORT_MI_LIST = \
34 ${DATAFILES}
35
36EXPORT_MI_GEN_LIST = \
37 ${MIGINCLUDES}
38
39EXPORT_MI_DIR = default_pager
40
41.ORDER: ${MIG_HDRS} ${MIGINCLUDES}
42
43${MIGINCLUDES} : ${MIG_TYPES}
44
45.ORDER: ${MIG_UUHDRS}
46
47${MIG_UUHDRS} : \
48 %.h : %.defs
49 $(MIG) $(MIGFLAGS) \
50 -server /dev/null \
51 -user /dev/null \
52 -header $@ \
53 $<
54
55.ORDER: ${MIG_USHDRS}
56
57${MIG_USHDRS} : \
58 %_server.h : %.defs
59 $(MIG) $(MIGFLAGS) \
60 -server /dev/null \
61 -user /dev/null \
62 -header /dev/null \
63 -sheader $@ \
64 $<
65
66#
67# Build path
68#
69INCFLAGS_MAKEFILE= -I..
70
71MIGKSFLAGS = -DMACH_KERNEL_PRIVATE -DKERNEL_SERVER=1
72MIGKUFLAGS = -DMACH_KERNEL_PRIVATE -DKERNEL_USER=1 -maxonstack 1024
73
74#
75# MIG-generated headers that are traditionally used by kernel
76# level code.
77#
78MIG_KUHDRS = \
79 default_pager_alerts.h
80
81MIG_KUSRC = \
82 default_pager_alerts_user.c
83
84MIG_KSHDRS = \
85 default_pager_object.h
86
87MIG_KSSRC = \
88 default_pager_object_server.c
89
90#
91# JMM -
92# Since there are two generated header files with the same name, one for
93# install and export, the other for internal use (and they are different)
94# we can't explicitly list two rules for the same target. So rules for
95# generating internal headers will be handled implicitly by creating rules
96# to generate the internal C sources, and the headers get created as a
97# side-effect.
98#
99# This is all temporary scaffolding, as we are moving to a model where
100# the MIG-generated code is identical in all environments. At first, it
101# will contain some environment-specific ifdefs, but over time should not
102# even require that as we move towards making all the environments look
103# the same.
104#
105COMP_FILES = ${MIG_KUSRC} ${MIG_KSSRC}
106
107${COMP_FILES} : ${MIG_TYPES}
108
109.ORDER: ${MIG_KUSRC}
110
111${MIG_KUSRC} : \
112 %_user.c : %.defs
113 ${MIG} ${MIGFLAGS} ${MIGKUFLAGS} \
114 -user $*_user.c \
115 -header $*.h \
116 -server /dev/null \
117 -sheader /dev/null \
118 $<
119
120.ORDER: ${MIG_KSSRC}
121
122${MIG_KSSRC}: \
123 %_server.c : %.defs
124 ${MIG} ${MIGFLAGS} ${MIGKSFLAGS} \
125 -user /dev/null \
126 -header /dev/null \
127 -server $*_server.c \
128 -sheader $*_server.h \
129 $<
130
131
132include $(MakeInc_rule)
133include $(MakeInc_dir)