]> git.saurik.com Git - apple/xnu.git/blame - iokit/conf/Makefile.template
xnu-7195.50.7.100.1.tar.gz
[apple/xnu.git] / iokit / conf / Makefile.template
CommitLineData
1c79356b
A
1#
2# Mach Operating System
3# Copyright (c) 1986 Carnegie-Mellon University
4# All rights reserved. The CMU software License Agreement specifies
5# the terms and conditions for use and redistribution.
6#
7
1c79356b
A
8export MakeInc_cmd=${SRCROOT}/makedefs/MakeInc.cmd
9export MakeInc_def=${SRCROOT}/makedefs/MakeInc.def
10export MakeInc_rule=${SRCROOT}/makedefs/MakeInc.rule
11export MakeInc_dir=${SRCROOT}/makedefs/MakeInc.dir
12
13include $(MakeInc_cmd)
14include $(MakeInc_def)
15
16#
b0d623f7 17# XXX: CFLAGS
1c79356b 18#
6d2010ae 19CFLAGS+= -include meta_features.h -DDRIVER_PRIVATE \
cb323159 20 -DIOKIT_KERNEL_PRIVATE -DDRIVERKIT_PRIVATE=1 -DIOMATCHDEBUG=1 -DIOALLOCDEBUG=1
5ba3f43e 21SFLAGS+= -include meta_features.h
1c79356b
A
22#-DIOKITDEBUG=-1
23
55e303ae 24CFLAGS_RELEASE += -DIOASSERT=0
39236c6e 25CFLAGS_DEVELOPMENT += -DIOASSERT=1
55e303ae
A
26CFLAGS_DEBUG += -DIOASSERT=1
27
1c79356b 28#
cb323159 29# Directories for generated files
1c79356b 30#
cb323159
A
31COMP_SUBDIRS = \
32 DriverKit
1c79356b
A
33
34#
35# Make sure we don't remove this by accident if interrupted at the wrong
36# time.
37#
38.PRECIOUS: Makefile
39
1c79356b
A
40#
41# Theses macros are filled in by the config program depending on the
42# current configuration. The MACHDEP macro is replaced by the
43# contents of the machine dependent makefile template and the others
44# are replaced by the corresponding symbol definitions for the
45# configuration.
46#
47
48%OBJS
49
50%CFILES
51
fe8ab488
A
52%CXXFILES
53
1c79356b
A
54%SFILES
55
1c79356b
A
56%MACHDEP
57
f427ee49
A
58#
59# Diagnostic opt-outs. We need to make this list empty.
60#
61# DO NOT ADD MORE HERE.
62#
63# -Wno-cast-align
64IODataQueue.cpo_CXXWARNFLAGS_ADD += -Wno-cast-align
65IOHibernateIO.cpo_CXXWARNFLAGS_ADD += -Wno-cast-align
66IOHibernateRestoreKernel.o_CFLAGS_ADD += -Wno-cast-align
67IONVRAM.cpo_CXXWARNFLAGS_ADD += -Wno-cast-align
68IOSharedDataQueue.cpo_CXXWARNFLAGS_ADD += -Wno-cast-align
69IOUserClient.cpo_CXXWARNFLAGS_ADD += -Wno-cast-align
70# -Wno-cast-qual
71DINetBootHook.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
72IOCatalogue.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
73IODMAController.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
74IODataQueue.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
75IODeviceTreeSupport.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
76IOHibernateIO.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
77IOInterruptController.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
78IOKitBSDInit.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
79IOKitDebug.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
80IOLib.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
81IOLocks.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
82IOMapper.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
83IOMemoryDescriptor.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
84IONVRAM.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
85IOPMrootDomain.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
86IOPlatformExpert.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
87IOPolledInterface.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
88IORegistryEntry.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
89IOService.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
90IOServicePM.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
91IOSharedDataQueue.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
92IOSimpleReporter.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
93IOSkywalkSupport.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
94IOStateReporter.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
95IOUserClient.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
96IOUserServer.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
97RootDomainUserClient.cpo_CXXWARNFLAGS_ADD += -Wno-cast-qual
98# -Wno-missing-prototypes
99IOKitBSDInit.cpo_CXXWARNFLAGS_ADD += -Wno-missing-prototypes
100IOKitDebug.cpo_CXXWARNFLAGS_ADD += -Wno-missing-prototypes
101IOPMrootDomain.cpo_CXXWARNFLAGS_ADD += -Wno-missing-prototypes
102IOUserClient.cpo_CXXWARNFLAGS_ADD += -Wno-missing-prototypes
103# -Wno-shadow
104IOHibernateIO.cpo_CXXWARNFLAGS_ADD += -Wno-shadow
105IOKitDebug.cpo_CXXWARNFLAGS_ADD += -Wno-shadow
106IOMemoryDescriptor.cpo_CXXWARNFLAGS_ADD += -Wno-shadow
107IOMultiMemoryDescriptor.cpo_CXXWARNFLAGS_ADD += -Wno-shadow
108IOPMrootDomain.cpo_CXXWARNFLAGS_ADD += -Wno-shadow
109IOPolledInterface.cpo_CXXWARNFLAGS_ADD += -Wno-shadow
110IOService.cpo_CXXWARNFLAGS_ADD += -Wno-shadow
111IOServicePM.cpo_CXXWARNFLAGS_ADD += -Wno-shadow
112IOSharedDataQueue.cpo_CXXWARNFLAGS_ADD += -Wno-shadow
113IOTimerEventSource.cpo_CXXWARNFLAGS_ADD += -Wno-shadow
114IOUserServer.cpo_CXXWARNFLAGS_ADD += -Wno-shadow
115TestIOMemoryDescriptor.cpo_CXXWARNFLAGS_ADD += -Wno-shadow
116Tests.cpo_CXXWARNFLAGS_ADD += -Wno-shadow
117# -Wno-shadow-field-in-constructor
118IOUserServer.cpo_CXXWARNFLAGS_ADD += -Wno-shadow-field-in-constructor
119# -Wno-sign-conversion
120DINetBootHook.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
121IOBufferMemoryDescriptor.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
122IOCPU.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
123IOCatalogue.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
124IOCommandQueue.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
125IODMACommand.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
126IODMAEventSource.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
127IODeviceTreeSupport.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
128IOFilterInterruptEventSource.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
129IOHibernateIO.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
130IOHibernateRestoreKernel.o_CFLAGS_ADD += -Wno-sign-conversion
131IOHistogramReporter.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
132IOInterleavedMemoryDescriptor.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
133IOInterruptAccounting.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
134IOInterruptController.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
135IOInterruptEventSource.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
136IOKitBSDInit.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
137IOKitDebug.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
138IOLib.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
139IOMemoryDescriptor.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
140IOMultiMemoryDescriptor.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
141IONVRAM.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
142IOPMPowerSource.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
143IOPMrootDomain.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
144IOPlatformActions.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
145IOPlatformExpert.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
146IOPolledInterface.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
147IORTC.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
148IORegistryEntry.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
149IOService.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
150IOServicePM.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
151IOSkywalkSupport.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
152IOStartIOKit.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
153IOStatistics.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
154IOStringFuncs.o_CFLAGS_ADD += -Wno-sign-conversion
155IOTimerEventSource.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
156IOUserClient.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
157IOUserServer.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
158IOWorkLoop.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
159RootDomainUserClient.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
160TestIOMemoryDescriptor.cpo_CXXWARNFLAGS_ADD += -Wno-sign-conversion
161# -Wno-unused-parameter
162IOBufferMemoryDescriptor.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
163IOCatalogue.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
164IOCommandGate.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
165IODMACommand.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
166IODeviceTreeSupport.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
167IOFilterInterruptEventSource.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
168IOHibernateIO.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
169IOHibernateRestoreKernel.o_CFLAGS_ADD += -Wno-unused-parameter
170IOInterruptController.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
171IOInterruptEventSource.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
172IOKitBSDInit.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
173IOKitDebug.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
174IOLib.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
175IOLocks.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
176IOMemoryDescriptor.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
177IOMultiMemoryDescriptor.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
178IONVRAM.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
179IOPMrootDomain.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
180IOPerfControl.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
181IOPlatformExpert.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
182IOPolledInterface.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
183IORTC.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
184IORegistryEntry.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
185IOReporter.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
186IOService.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
187IOServicePM.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
188IOSkywalkSupport.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
189IOStateReporter.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
190IOUserClient.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
191IOUserServer.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
192IOWatchDogTimer.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
193IOWorkLoop.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
194PassthruInterruptController.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
195RootDomainUserClient.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
196TestIOMemoryDescriptor.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
197Tests.cpo_CXXWARNFLAGS_ADD += -Wno-unused-parameter
198IODMACommand.iig.cpo_CXXWARNFLAGS_ADD += -Wno-duplicate-decl-specifier
199
fe8ab488
A
200# Rebuild if per-file overrides change
201${OBJS}: $(firstword $(MAKEFILE_LIST))
202
203# Rebuild if global compile flags change
204$(COBJS): .CFLAGS
205.CFLAGS: ALWAYS
206 $(_v)$(REPLACECONTENTS) $@ $(KCC) $(CFLAGS) $(INCFLAGS)
207$(CXXOBJS): .CXXFLAGS
208.CXXFLAGS: ALWAYS
209 $(_v)$(REPLACECONTENTS) $@ $(KC++) $(CXXFLAGS) $(INCFLAGS)
210$(SOBJS): .SFLAGS
211.SFLAGS: ALWAYS
212 $(_v)$(REPLACECONTENTS) $@ $(S_KCC) $(SFLAGS) $(INCFLAGS)
213
214$(COMPONENT).filelist: $(OBJS)
39236c6e 215 $(_v)for hib_file in ${HIB_FILES}; \
d1ecb069 216 do \
3e170ce0
A
217 $(SEG_HACK) -n __HIB -o $${hib_file}__ $${hib_file} || exit 1; \
218 mv $${hib_file}__ $${hib_file} || exit 1; \
39236c6e 219 done
f427ee49 220 @$(LOG_LDFILELIST) "$(COMPONENT)"
3e170ce0 221 $(_v)for obj in ${OBJS}; do \
cb323159 222 $(ECHO) $(TARGET)/$(CURRENT_KERNEL_CONFIG)/$${obj}; \
3e170ce0 223 done > $(COMPONENT).filelist
1c79356b 224
6d2010ae 225do_all: $(COMPONENT).filelist
1c79356b 226
39236c6e 227do_build_all:: do_all
1c79356b
A
228
229%RULES
230
1c79356b 231include $(MakeInc_rule)
1c79356b 232include $(MakeInc_dir)