VirtualBox

source: vbox/trunk/src/VBox/VMM/Makefile.kmk@ 40274

Last change on this file since 40274 was 40274, checked in by vboxsync, 13 years ago

Introduced VBOX_WITH_REM in Config.kmk and the VMM.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 15.1 KB
Line 
1# $Id: Makefile.kmk 40274 2012-02-28 13:17:35Z vboxsync $
2## @file
3# Top-level makefile for the VMM.
4#
5
6#
7# Copyright (C) 2006-2010 Oracle Corporation
8#
9# This file is part of VirtualBox Open Source Edition (OSE), as
10# available from http://www.virtualbox.org. This file is free software;
11# you can redistribute it and/or modify it under the terms of the GNU
12# General Public License (GPL) as published by the Free Software
13# Foundation, in version 2 as it comes in the "COPYING" file of the
14# VirtualBox OSE distribution. VirtualBox OSE is distributed in the
15# hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
16#
17
18SUB_DEPTH = ../../..
19include $(KBUILD_PATH)/subheader.kmk
20
21# Include sub-makefiles.
22include $(PATH_SUB_CURRENT)/testcase/Makefile.kmk
23
24
25#
26# Globals
27#
28
29## DEFS variable that is picked up by all three VMM targets.
30# Can be prepended to by setting it in LocalConfig.kmk
31VMM_COMMON_DEFS ?= VBOX_IN_VMM
32ifdef VBOX_WITH_RAW_MODE
33 VMM_COMMON_DEFS += VBOX_WITH_RAW_MODE
34endif
35ifdef VBOX_WITH_REM
36 VMM_COMMON_DEFS += VBOX_WITH_REM
37endif
38ifdef VBOX_WITH_MULTI_CORE
39 VMM_COMMON_DEFS += VBOX_WITH_MULTI_CORE
40endif
41ifdef VBOX_WITH_R0_LOGGING
42 VMM_COMMON_DEFS += VBOX_WITH_R0_LOGGING
43endif
44ifdef VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI
45 VMM_COMMON_DEFS += VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI
46endif
47ifdef VBOX_WITH_PCI_PASSTHROUGH
48 VMM_COMMON_DEFS += VBOX_WITH_PCI_PASSTHROUGH
49endif
50# VMM_COMMON_DEFS += VBOX_WITH_NS_ACCOUNTING_STATS
51
52# Special IEM debug mode which compares the result with REM.
53ifdef IEM_VERIFICATION_MODE
54 VMM_COMMON_DEFS += IEM_VERIFICATION_MODE
55endif
56
57
58#
59# VMMR3.dll
60#
61ifndef VBOX_ONLY_EXTPACKS_USE_IMPLIBS
62LIBRARIES += VMMR3
63endif
64
65VMMR3_TEMPLATE = VBoxR3DllNoPic
66
67VMMR3_DEFS = IN_VMM_R3 IN_DIS IN_GMM_R3 IN_DBG $(VMM_COMMON_DEFS)
68## @todo eliminate IN_GMM_R3
69ifdef VBOX_WITH_PREALLOC_RAM_BY_DEFAULT
70 VMMR3_DEFS += VBOX_WITH_PREALLOC_RAM_BY_DEFAULT
71endif
72ifdef VBOX_WITH_VUSB
73 VMMR3_DEFS += VBOX_WITH_USB
74endif
75ifdef VBOX_WITH_PDM_ASYNC_COMPLETION
76 VMMR3_DEFS += VBOX_WITH_PDM_ASYNC_COMPLETION
77endif
78VMMR3_DEFS.darwin = VMM_R0_SWITCH_STACK
79VMMR3_DEFS.darwin.x86 = \
80 VBOX_WITH_2X_4GB_ADDR_SPACE VBOX_WITH_2X_4GB_ADDR_SPACE_IN_R3 \
81 VBOX_WITH_HYBRID_32BIT_KERNEL VBOX_WITH_HYBRID_32BIT_KERNEL_IN_R3
82
83VMMR3_INCS = \
84 include \
85 PATM
86VMMR3_ASINCS = .
87
88VMMR3_SOURCES = \
89 VMMR3/CFGM.cpp \
90 VMMR3/CPUM.cpp \
91 VMMR3/CPUMDbg.cpp \
92 VMMR3/DBGF.cpp \
93 VMMR3/DBGFAddr.cpp \
94 VMMR3/DBGFAddrSpace.cpp \
95 VMMR3/DBGFBp.cpp \
96 VMMR3/DBGFCoreWrite.cpp \
97 VMMR3/DBGFCpu.cpp \
98 VMMR3/DBGFDisas.cpp \
99 VMMR3/DBGFInfo.cpp \
100 VMMR3/DBGFLog.cpp \
101 VMMR3/DBGFMem.cpp \
102 VMMR3/DBGFOS.cpp \
103 VMMR3/DBGFReg.cpp \
104 VMMR3/DBGFStack.cpp \
105 VMMR3/DBGFSym.cpp \
106 VMMR3/DBGFR3Trace.cpp \
107 VMMR3/EM.cpp \
108 VMMR3/EMRaw.cpp \
109 VMMR3/EMHwaccm.cpp \
110 VMMR3/FTM.cpp \
111 VMMR3/IEMR3.cpp \
112 VMMR3/IOM.cpp \
113 VMMR3/GMM.cpp \
114 VMMR3/MM.cpp \
115 VMMR3/MMHeap.cpp \
116 VMMR3/MMHyper.cpp \
117 VMMR3/MMPagePool.cpp \
118 VMMR3/MMUkHeap.cpp \
119 VMMR3/PDM.cpp \
120 VMMR3/PDMBlkCache.cpp \
121 VMMR3/PDMDevice.cpp \
122 VMMR3/PDMDevHlp.cpp \
123 VMMR3/PDMDevMiscHlp.cpp \
124 VMMR3/PDMDriver.cpp \
125 VMMR3/PDMLdr.cpp \
126 VMMR3/PDMCritSect.cpp \
127 VMMR3/PDMQueue.cpp \
128 VMMR3/PDMThread.cpp \
129 VMMR3/PGM.cpp \
130 VMMR3/PGMDbg.cpp \
131 VMMR3/PGMHandler.cpp \
132 VMMR3/PGMMap.cpp \
133 VMMR3/PGMPhys.cpp \
134 VMMR3/PGMPool.cpp \
135 VMMR3/PGMSavedState.cpp \
136 VMMR3/PGMSharedPage.cpp \
137 VMMR3/SELM.cpp \
138 VMMR3/SSM.cpp \
139 VMMR3/STAM.cpp \
140 VMMR3/TM.cpp \
141 VMMR3/TRPM.cpp \
142 VMMR3/VM.cpp \
143 VMMR3/VMEmt.cpp \
144 VMMR3/VMReq.cpp \
145 VMMR3/VMM.cpp \
146 VMMR3/VMMGuruMeditation.cpp \
147 VMMR3/VMMSwitcher.cpp \
148 VMMR3/VMMTests.cpp \
149 VMMR3/HWACCM.cpp \
150 VMMR3/CSAM.cpp \
151 VMMR3/PATM.cpp \
152 VMMR3/PATMPatch.cpp \
153 VMMR3/PATMGuest.cpp \
154 VMMR3/PATMA.asm \
155 VMMR3/PATMSSM.cpp \
156 VMMAll/CPUMAllRegs.cpp \
157 VMMAll/CPUMStack.cpp \
158 VMMAll/DBGFAll.cpp \
159 VMMAll/HWACCMAll.cpp \
160 VMMAll/IOMAll.cpp \
161 VMMAll/IOMAllMMIO.cpp \
162 VMMAll/MMAll.cpp \
163 VMMAll/MMAllHyper.cpp \
164 VMMAll/MMAllPagePool.cpp \
165 VMMAll/PDMAll.cpp \
166 VMMAll/PDMAllCritSect.cpp \
167 VMMAll/PDMAllQueue.cpp \
168 VMMAll/PGMAll.cpp \
169 VMMAll/PGMAllHandler.cpp \
170 VMMAll/PGMAllMap.cpp \
171 VMMAll/PGMAllPhys.cpp \
172 VMMAll/PGMAllPool.cpp \
173 VMMAll/REMAll.cpp \
174 VMMAll/SELMAll.cpp \
175 VMMAll/EMAll.cpp \
176 VMMAll/EMAllA.asm \
177 VMMAll/FTMAll.cpp \
178 VMMAll/IEMAll.cpp \
179 VMMAll/IEMAllAImpl.asm \
180 VMMAll/IEMAllAImplC.cpp \
181 VMMAll/TMAll.cpp \
182 VMMAll/TMAllCpu.cpp \
183 VMMAll/TMAllReal.cpp \
184 VMMAll/TMAllVirtual.cpp \
185 VMMAll/TRPMAll.cpp \
186 VMMAll/VMAll.cpp \
187 VMMAll/VMMAll.cpp \
188 VMMAll/VMMAllA.asm \
189 VMMAll/CSAMAll.cpp \
190 VMMAll/PATMAll.cpp
191ifdef VBOX_WITH_VUSB
192 VMMR3_SOURCES += VMMR3/PDMUsb.cpp
193endif
194ifdef VBOX_WITH_PDM_ASYNC_COMPLETION
195 VMMR3_SOURCES += \
196 VMMR3/PDMAsyncCompletion.cpp \
197 VMMR3/PDMAsyncCompletionFile.cpp \
198 VMMR3/PDMAsyncCompletionFileFailsafe.cpp \
199 VMMR3/PDMAsyncCompletionFileNormal.cpp
200endif
201
202ifdef VBOX_WITH_RAW_MODE
203 VMMR3_SOURCES.x86 += \
204 VMMSwitcher/32BitTo32Bit.asm \
205 VMMSwitcher/32BitToPAE.asm \
206 VMMSwitcher/32BitToAMD64.asm \
207 VMMSwitcher/PAETo32Bit.asm \
208 VMMSwitcher/PAEToAMD64.asm \
209 VMMSwitcher/PAEToPAE.asm
210 VMMR3_SOURCES.amd64 = \
211 VMMSwitcher/AMD64To32Bit.asm \
212 VMMSwitcher/AMD64ToPAE.asm
213 VMMR3_SOURCES.darwin.x86 += \
214 VMMSwitcher/AMD64ToPAE.asm
215endif
216
217
218# SSM wish to know the build type, host os and arch.
219VMMR3/SSM.cpp_DEFS += \
220 KBUILD_TYPE=\"$(KBUILD_TYPE)\" \
221 KBUILD_TARGET=\"$(KBUILD_TARGET)\" \
222 KBUILD_TARGET_ARCH=\"$(KBUILD_TARGET_ARCH)\"
223
224#
225# The VMM DLL.
226#
227ifndef VBOX_ONLY_EXTPACKS_USE_IMPLIBS
228DLLS += VBoxVMM
229endif
230VBoxVMM_TEMPLATE = VBoxR3DllNoPic
231VBoxVMM_DEFS = $(VMMR3_DEFS)
232VBoxVMM_DEFS.$(KBUILD_TARGET) = $(VMMR3_DEFS.$(KBUILD_TARGET))
233VBoxVMM_SOURCES = VMMR3/VBoxVMMDeps.cpp
234VBoxVMM_SONAME.linux = VBoxVMM.so
235
236VBoxVMM_LIBS = \
237 $(PATH_STAGE_LIB)/VMMR3$(VBOX_SUFF_LIB) \
238 $(PATH_STAGE_LIB)/DisasmR3$(VBOX_SUFF_LIB)
239ifdef VBOX_WITH_DEBUGGER
240 VBoxVMM_LIBS += \
241 $(PATH_STAGE_LIB)/Debugger$(VBOX_SUFF_LIB)
242endif
243VBoxVMM_LIBS += \
244 $(LIB_REM) \
245 $(LIB_RUNTIME)
246
247VBoxVMM_LIBS.win = $(PATH_TOOL_$(VBOX_VCC_TOOL)_LIB)/delayimp.lib
248VBoxVMM_LDFLAGS.win = /DELAYLOAD:dbghelp.dll
249VBoxVMM_LDFLAGS.linux = -Wl,--no-undefined
250VBoxVMM_LDFLAGS.darwin = -install_name $(VBOX_DYLD_EXECUTABLE_PATH)/VBoxVMM.dylib
251VBoxVMM_LDFLAGS.solaris = -mimpure-text
252#ifdef VBOX_WITH_PDM_ASYNC_COMPLETION
253# ifeq ($(KBUILD_HOST), linux)
254#VBoxVMM_LIBS += aio
255# endif
256#endif
257
258
259if defined(VBOX_WITH_RAW_MODE) && $(intersects $(VBOX_LDR_FMT32), pe lx)
260
261 #
262 # VMMRCBuiltin.lib
263 #
264 LIBRARIES += VMMRCBuiltin
265 VMMRCBuiltin_TEMPLATE = VBoxRc
266 ifeq ($(VBOX_LDR_FMT32),pe)
267 VMMRCBuiltin_SOURCES = VMMRC/VMMRCBuiltin.def
268 endif
269 ifeq ($(VBOX_LDR_FMT32),lx)
270 VMMRCBuiltin_SOURCES = $(VMMRCBuiltin_0_OUTDIR)/VMMRCBuiltin.def
271 $$(VMMRCBuiltin_0_OUTDIR)/VMMRCBuiltin.def: $(PATH_SUB_CURRENT)/VMMRC/VMMRCBuiltin.def | $$(dir $$@)
272 $(SED) -e '/not-os2/d' -e 's/^[ \t][ \t]*\([a-zA-Z]\)/ _\1/' -e 's/[ \t]DATA[ \t]*/ /' --output $@ $<
273 endif
274
275
276 #
277 # VMMRCImp.lib
278 #
279 LIBRARIES += VMMRCImp
280 VMMRCImp_TEMPLATE = VBoxRc
281 VMMRCImp_SOURCES = $(VMMRCImp_0_OUTDIR)/VMMRC.def
282 VMMRCImp_CLEAN = $(VMMRCImp_0_OUTDIR)/VMMRC.def
283
284 $$(VMMRCImp_0_OUTDIR)/VMMRC.def: $(PATH_SUB_CURRENT)/VMMRC/VMMRC.def | $$(dir $$@)
285 ifeq ($(VBOX_LDR_FMT32),lx)
286 $(SED) \
287 -e '/not-os2/d' \
288 -e 's/^[ \t][ \t]*\([a-zA-Z]\)/ _\1/' \
289 -e 's/[ \t]DATA[ \t]*/ /' \
290 --output $@ \
291 $<
292 $(APPEND) "$@" ""
293 $(APPEND) "$@" " ___ehInit"
294 else
295 $(SED) \
296 -e '/not-win/d' \
297 -e '/not-$(KBUILD_TARGET_ARCH)/d' \
298 --output $@ $<
299 endif
300
301endif # RC && (pe || lx)
302
303
304if1of ($(VBOX_LDR_FMT), pe lx)
305 #
306 # VMMR0Imp.lib
307 #
308 LIBRARIES += VMMR0Imp
309 VMMR0Imp_TEMPLATE = VBoxR0
310 VMMR0Imp_SOURCES = $(VMMR0Imp_0_OUTDIR)/VMMR0.def
311 VMMR0Imp_CLEAN = $(VMMR0Imp_0_OUTDIR)/VMMR0.def
312
313 $$(VMMR0Imp_0_OUTDIR)/VMMR0.def: $(PATH_SUB_CURRENT)/VMMR0/VMMR0.def | $$(dir $$@)
314 ifeq ($(VBOX_LDR_FMT),lx)
315 $(SED) \
316 -e '/not-os2/d' \
317 -e '/not-amd64/d' \
318 -e 's/^[ \t][ \t]*\([a-zA-Z]\)/ _\1/' \
319 -e 's/[ \t]DATA[ \t]*/ /' \
320 --output $@ $<
321 $(APPEND) "$@" ""
322 $(APPEND) "$@" " ___ehInit"
323 else
324 $(SED) \
325 -e '/not-win/d' \
326 -e '/not-$(KBUILD_TARGET_ARCH)/d' \
327 --output $@ $<
328 endif
329endif # R0: pe + lx
330
331
332#
333# VMMR3Imp.lib
334#
335IMPORT_LIBS += VMMR3Imp
336$(call VBOX_GENERATE_IMPORT_TARGET_FN,VMMR3Imp,VBoxVMM,VMMR3/VMMR3.def)
337
338
339if defined(VBOX_WITH_RAW_MODE) && !defined(VBOX_ONLY_EXTPACKS)
340 #
341 # VMMRC.gc
342 #
343 SYSMODS += VMMRC
344 VMMRC_TEMPLATE = VBoxRc
345 VMMRC_NAME = VMMGC
346 VMMRC_SYSSUFF = .gc
347
348 VMMRC_DEFS = IN_VMM_RC IN_RT_RC IN_DIS DIS_CORE_ONLY VBOX_WITH_RAW_MODE $(VMM_COMMON_DEFS)
349 ifeq ($(KBUILD_TARGET_ARCH),x86)
350 VMMRC_DEFS.darwin = VMM_R0_SWITCH_STACK
351 VMMRC_DEFS.darwin = \
352 VBOX_WITH_2X_4GB_ADDR_SPACE VBOX_WITH_2X_4GB_ADDR_SPACE_IN_RC \
353 VBOX_WITH_HYBRID_32BIT_KERNEL VBOX_WITH_HYBRID_32BIT_KERNEL_IN_RC
354 endif
355
356 VMMRC_INCS := \
357 include \
358 VMMRC \
359 PATM
360
361 VMMRC_LIBS = \
362 $(PATH_STAGE_LIB)/DisasmRC$(VBOX_SUFF_LIB) \
363 $(PATH_STAGE_LIB)/RuntimeRC$(VBOX_SUFF_LIB)
364 ifneq ($(filter pe lx,$(VBOX_LDR_FMT32)),)
365 VMMRC_LIBS += \
366 $(PATH_STAGE_LIB)/VMMRCBuiltin$(VBOX_SUFF_LIB)
367 endif
368
369 VMMRC_SOURCES = \
370 VMMRC/VMMRC0.asm \
371 VMMRC/VMMRCDeps.cpp \
372 VMMRC/CPUMRC.cpp \
373 VMMRC/CPUMRCA.asm \
374 VMMRC/EMRCA.asm \
375 VMMRC/IOMRC.cpp \
376 VMMRC/MMRamRC.cpp \
377 VMMRC/MMRamRCA.asm \
378 VMMRC/PDMRCDevice.cpp \
379 VMMRC/PGMRC.cpp \
380 VMMRC/SELMRC.cpp \
381 VMMRC/TRPMRC.cpp \
382 VMMRC/TRPMRCHandlers.cpp \
383 VMMRC/TRPMRCHandlersA.asm \
384 VMMRC/VMMRC.cpp \
385 VMMRC/VMMRCA.asm \
386 VMMRC/HWACCMRCA.asm \
387 VMMRC/CSAMRC.cpp \
388 VMMRC/PATMRC.cpp \
389 VMMRZ/DBGFRZ.cpp \
390 VMMRZ/PGMRZDynMap.cpp \
391 VMMRZ/VMMRZ.cpp \
392 VMMAll/CPUMAllRegs.cpp \
393 VMMAll/CPUMAllA.asm \
394 VMMAll/DBGFAll.cpp \
395 VMMAll/IOMAll.cpp \
396 VMMAll/IOMAllMMIO.cpp \
397 VMMAll/EMAll.cpp \
398 VMMAll/EMAllA.asm \
399 VMMAll/FTMAll.cpp \
400 VMMAll/MMAll.cpp \
401 VMMAll/MMAllHyper.cpp \
402 VMMAll/PDMAll.cpp \
403 VMMAll/PDMAllCritSect.cpp \
404 VMMAll/PDMAllQueue.cpp \
405 VMMAll/PGMAll.cpp \
406 VMMAll/PGMAllHandler.cpp \
407 VMMAll/PGMAllMap.cpp \
408 VMMAll/PGMAllPhys.cpp \
409 VMMAll/PGMAllPool.cpp \
410 VMMAll/REMAll.cpp \
411 VMMAll/SELMAll.cpp \
412 VMMAll/TMAll.cpp \
413 VMMAll/TMAllCpu.cpp \
414 VMMAll/TMAllReal.cpp \
415 VMMAll/TMAllVirtual.cpp \
416 VMMAll/TRPMAll.cpp \
417 VMMAll/VMAll.cpp \
418 VMMAll/VMMAll.cpp \
419 VMMAll/VMMAllA.asm \
420 VMMAll/CSAMAll.cpp \
421 VMMAll/PATMAll.cpp
422 ifeq ($(VBOX_LDR_FMT32),pe)
423 VMMRC_SOURCES += VMMRC/VMMRC.def
424 endif
425 ifeq ($(VBOX_LDR_FMT32),lx)
426 VMMRC_SOURCES += $(VMMRCImp_0_OUTDIR)/VMMRC.def
427 endif
428
429
430 # the very last one.
431 VMMRC_SOURCES += VMMRC/VMMRC99.asm
432
433 VMMRC/VMMRCDeps.cpp_CXXFLAGS.win = -Oi- -TC ## @todo rename VMMRCDeps.cpp to .c
434endif # VBOX_WITH_RAW_MODE && !VBOX_ONLY_EXTPACKS
435
436
437ifndef VBOX_ONLY_EXTPACKS
438 #
439 # VMMR0.r0
440 #
441 SYSMODS += VMMR0
442 VMMR0_TEMPLATE = VBoxR0
443 VMMR0_SYSSUFF = .r0
444
445 VMMR0_DEFS = IN_VMM_R0 IN_RT_R0 IN_DIS DIS_CORE_ONLY IN_GVMM_R0 IN_GMM_R0 IN_INTNET_R0 \
446 $(VMM_COMMON_DEFS) RTASSERT_HAVE_SHOULD_PANIC
447 ## @todo eliminate IN_GVMM_R0 IN_GMM_R0
448 ifdef VBOX_WITH_VMMR0_DISABLE_PREEMPTION
449 VMMR0_DEFS += VBOX_WITH_VMMR0_DISABLE_PREEMPTION
450 endif
451 ifdef VBOX_WITH_PCI_PASSTHROUGH
452 VMMR0_DEFS += IN_PCIRAW_R0
453 endif
454 ifdef VBOX_WITH_TRIPLE_FAULT_HACK
455 VMMR0_DEFS += VBOX_WITH_TRIPLE_FAULT_HACK
456 endif
457 VMMR0_DEFS.darwin = VMM_R0_SWITCH_STACK
458 VMMR0_DEFS.darwin.x86 = \
459 VBOX_WITH_2X_4GB_ADDR_SPACE VBOX_WITH_2X_4GB_ADDR_SPACE_IN_R0 \
460 VBOX_WITH_HYBRID_32BIT_KERNEL VBOX_WITH_HYBRID_32BIT_KERNEL_IN_R0
461 VMMR0_DEFS.win.amd64 = VBOX_WITH_KERNEL_USING_XMM
462
463 ifeq ($(VBOX_LDR_FMT),elf)
464 VMMR0_LDFLAGS = -e VMMR0EntryEx
465 endif
466 VMMR0_INCS = \
467 include \
468 PATM
469
470 VMMR0_SOURCES = \
471 VMMR0/CPUMR0.cpp \
472 VMMR0/CPUMR0A.asm \
473 VMMR0/GMMR0.cpp \
474 VMMR0/GVMMR0.cpp \
475 VMMR0/HWACCMR0.cpp \
476 VMMR0/HWACCMR0A.asm \
477 VMMR0/HWSVMR0.cpp \
478 VMMR0/HWVMXR0.cpp \
479 VMMR0/PDMR0Device.cpp \
480 VMMR0/PDMR0Driver.cpp \
481 VMMR0/PGMR0.cpp \
482 VMMR0/PGMR0SharedPage.cpp \
483 VMMR0/TRPMR0.cpp \
484 VMMR0/TRPMR0A.asm \
485 VMMR0/VMMR0.cpp \
486 VMMRZ/DBGFRZ.cpp \
487 VMMRZ/VMMRZ.cpp \
488 VMMAll/CPUMAllA.asm \
489 VMMAll/CPUMAllRegs.cpp \
490 VMMAll/CPUMStack.cpp \
491 VMMAll/DBGFAll.cpp \
492 VMMAll/EMAll.cpp \
493 VMMAll/EMAllA.asm \
494 VMMAll/FTMAll.cpp \
495 VMMAll/HWACCMAll.cpp \
496 VMMAll/IOMAll.cpp \
497 VMMAll/IOMAllMMIO.cpp \
498 VMMAll/MMAll.cpp \
499 VMMAll/MMAllHyper.cpp \
500 VMMAll/MMAllPagePool.cpp \
501 VMMAll/PDMAll.cpp \
502 VMMAll/PDMAllCritSect.cpp \
503 VMMAll/PDMAllQueue.cpp \
504 VMMAll/PGMAll.cpp \
505 VMMAll/PGMAllHandler.cpp \
506 VMMAll/PGMAllMap.cpp \
507 VMMAll/PGMAllPhys.cpp \
508 VMMAll/PGMAllPool.cpp \
509 VMMAll/REMAll.cpp \
510 VMMAll/SELMAll.cpp \
511 VMMAll/TMAll.cpp \
512 VMMAll/TMAllCpu.cpp \
513 VMMAll/TMAllReal.cpp \
514 VMMAll/TMAllVirtual.cpp \
515 VMMAll/TRPMAll.cpp \
516 VMMAll/VMAll.cpp \
517 VMMAll/VMMAll.cpp \
518 VMMAll/VMMAllA.asm
519 if1of ($(VBOX_LDR_FMT), pe lx)
520 VMMR0_SOURCES += $(VMMR0Imp_0_OUTDIR)/VMMR0.def
521 endif
522 ifdef VBOX_WITH_TRIPLE_FAULT_HACK
523 VMMR0_SOURCES += \
524 VMMR0/VMMR0TripleFaultHack.cpp \
525 VMMR0/VMMR0TripleFaultHackA.asm
526 endif
527 VMMR0_SOURCES.amd64 = \
528 VMMR0/VMMR0JmpA-amd64.asm
529 VMMR0_SOURCES.x86 = \
530 VMMR0/VMMR0JmpA-x86.asm
531 VMMR0_SOURCES.darwin.x86 = \
532 VMMRZ/PGMRZDynMap.cpp
533
534 VMMR0_LIBS = \
535 $(PATH_STAGE_LIB)/ServicesR0$(VBOX_SUFF_LIB) \
536 $(PATH_STAGE_LIB)/RuntimeR0$(VBOX_SUFF_LIB) \
537 $(PATH_STAGE_LIB)/DisasmR0$(VBOX_SUFF_LIB)
538 ifneq ($(filter pe lx,$(VBOX_LDR_FMT)),)
539 VMMR0_LIBS += \
540 $(PATH_STAGE_LIB)/SUPR0$(VBOX_SUFF_LIB)
541 endif
542endif # !VBOX_ONLY_EXTPACKS
543
544
545ifndef VBOX_ONLY_EXTPACKS
546 #
547 # SSMStandalone.lib/a for linking with VBoxSVC and other executables.
548 #
549 LIBRARIES += SSMStandalone
550 SSMStandalone_TEMPLATE = VBOXR3EXE
551 SSMStandalone_DEFS = IN_VMM_R3 IN_VMM_STATIC SSM_STANDALONE
552 SSMStandalone_INCS = include
553 SSMStandalone_SOURCES = VMMR3/SSM.cpp
554endif # !VBOX_ONLY_EXTPACKS
555
556
557#
558# For vmmGetSvnRev.
559#
560VMMAll/VMMAll.cpp_DEFS = VBOX_SVN_REV=$(VBOX_SVN_REV)
561
562#
563# Disable annoying warnings about array subscript above array bounds in aPages[]
564#
565ifneq ($(KBUILD_TARGET),win)
566 VMMR3/PGMPool.cpp_CXXFLAGS = $(VBOX_GCC_Wno-array_bounds)
567 VMMAll/PGMAllPool.cpp_CXXFLAGS = $(VBOX_GCC_Wno-array_bounds)
568 VMMAll/PGMAll.cpp_CXXFLAGS = -Wno-unused-function
569 VMMAll/IEMAll.cpp_CXXFLAGS = -Wno-unused-parameter
570endif
571
572#
573# Always optimize the interpreter.
574#
575if1of ($(KBUILD_TARGET), win)
576#VMMAll/IEMAll.cpp_CXXFLAGS += TODO
577#else if1of ($(KBUILD_TARGET_ARCH), amd64)
578# VMMAll/IEMAll.cpp_CXXFLAGS += -O2 -fomit-frame-pointer
579else
580 VMMAll/IEMAll.cpp_CXXFLAGS += -O2
581 #VMMAll/IEMAll.cpp_CXXFLAGS += -fno-align-functions -fno-align-jumps -fno-align-loops # Saves a few of percents, not worth it.
582 #VMMAll/IEMAll.cpp_CXXFLAGS += -fno-reorder-blocks # Saves one or two percent ... never mind.
583 VMMAll/IEMAll.cpp_CXXFLAGS += -fomit-frame-pointer # Omitting the frame pointer results in larger code, but it might be worth it. (esp addressing vs ebp?)
584endif
585
586
587include $(KBUILD_PATH)/subfooter.kmk
588
589
590# Alias the PGM templates to the object in which they are defined.
591PGMInternal.o \
592PGMBth.o PGMGst.o PGMShw.o \
593PGMBth.obj PGMGst.obj PGMShw.obj: PGM.o
594
595PGMAllBth.o PGMAllGst.o PGMAllShw.o \
596PGMAllBth.obj PGMAllGst.obj PGMAllShw.obj: PGMAll.o
597
598PGMRCBth.o PGMRCGst.o PGMRCShw.o \
599PGMRCBth.obj PGMRCGst.obj PGMRCShw.obj: PGMRC.o
600
601PGMPhysRWTmpl.o PGMPhysRWTmpl.obj: PGMPhys.o
602
603PGMInline.o PGMInline.obj: PGMDbg.o
604
605# Alias the IEM templates to the object in which they are instantiated.
606IEMInternal.o \
607IEMAllInstructions.cpp.o IEMAllInstructions.cpp.obj \
608IEMAllCImpl.cpp.o IEMAllCImpl.cpp.obj \
609IEMAllCImplStrInstr.cpp.o IEMAllCImplStrInstr.cpp.obj: IEMAll.o
610
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette