VirtualBox

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

Last change on this file since 5679 was 5667, checked in by vboxsync, 17 years ago

Debugger interface for searching memory. Fixed a const mixup.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 9.4 KB
Line 
1# $Id: Makefile.kmk 5667 2007-11-11 04:28:47Z vboxsync $
2## @file
3# Top-level makefile for the VMM.
4#
5
6#
7# Copyright (C) 2006-2007 innotek GmbH
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 as published by the Free Software Foundation,
13# in version 2 as it comes in the "COPYING" file of the VirtualBox OSE
14# distribution. VirtualBox OSE is distributed in the hope that it will
15# be useful, but WITHOUT ANY WARRANTY of any kind.
16
17DEPTH = ../../..
18include $(PATH_KBUILD)/subheader.kmk
19
20## @todo get rid of these.
21# Enable the PDM lock.
22#DEFS += VBOX_WITH_PDM_LOCK
23ifdef VBOX_WITH_INTERNAL_NETWORKING
24DEFS += VBOX_WITH_INTERNAL_NETWORKING
25endif
26
27# Include sub-makefiles.
28include $(PATH_SUB_CURRENT)/testcase/Makefile.kmk
29
30
31#
32# VMMR3.dll
33#
34LIBRARIES += VMMR3
35
36VMMR3_TEMPLATE = VBOXR3
37VMMR3_DEFS = IN_VMM_R3 IN_PDM_R3 IN_CFGM_R3 IN_IOM_R3 IN_VM_R3 IN_CPUM_R3 IN_SELM_R3 IN_PGM_R3 IN_TRPM_R3 IN_MM_R3 IN_DBG_R3 \
38 IN_DBGF_R3 IN_PATM_R3 IN_DIS_R3 IN_STAM_R3 IN_CSAM_R3 IN_EM_R3 IN_TM_R3 IN_SSM_R3 IN_HWACCM_R3
39ifdef VBOX_WITH_IDT_PATCHING
40VMMR3_DEFS += VBOX_WITH_IDT_PATCHING
41endif
42ifdef VBOX_WITH_PREALLOC_RAM_BY_DEFAULT
43VMMR3_DEFS += VBOX_WITH_PREALLOC_RAM_BY_DEFAULT
44endif
45VMMR3_INCS := \
46 PATM \
47 $(PATH_SUB_CURRENT)
48
49VMMR3_SOURCES = \
50 CFGM.cpp \
51 CPUM.cpp \
52 CPUMStack.cpp \
53 DBGF.cpp \
54 DBGFAddr.cpp \
55 DBGFBp.cpp \
56 DBGFDisas.cpp \
57 DBGFInfo.cpp \
58 DBGFLog.cpp \
59 DBGFMem.cpp \
60 DBGFStack.cpp \
61 DBGFSym.cpp \
62 EM.cpp \
63 IOM.cpp \
64 MM.cpp \
65 MMHeap.cpp \
66 MMHyper.cpp \
67 MMPagePool.cpp \
68 MMPhys.cpp \
69 PDM.cpp \
70 PDMDevice.cpp \
71 PDMDriver.cpp \
72 PDMLdr.cpp \
73 PDMCritSect.cpp \
74 PDMQueue.cpp \
75 PDMThread.cpp \
76 PGM.cpp \
77 PGMDbg.cpp \
78 PGMHandler.cpp \
79 PGMMap.cpp \
80 PGMPhys.cpp \
81 PGMPool.cpp \
82 SELM.cpp \
83 SSM.cpp \
84 STAM.cpp \
85 TM.cpp \
86 TRPM.cpp \
87 VM.cpp \
88 VMEmt.cpp \
89 VMReq.cpp \
90 VMM.cpp \
91 VMMTests.cpp \
92 HWACCM.cpp \
93 VMMAll/CPUMAllRegs.cpp \
94 VMMAll/CPUMAllA.asm \
95 VMMAll/DBGFAll.cpp \
96 VMMAll/IOMAll.cpp \
97 VMMAll/IOMAllMMIO.cpp \
98 VMMAll/MMAll.cpp \
99 VMMAll/MMAllHyper.cpp \
100 VMMAll/MMAllPagePool.cpp \
101 VMMAll/MMAllPhys.cpp \
102 VMMAll/PDMAll.cpp \
103 VMMAll/PDMAllCritSect.cpp \
104 VMMAll/PDMAllQueue.cpp \
105 VMMAll/PGMAll.cpp \
106 VMMAll/PGMAllHandler.cpp \
107 VMMAll/PGMAllMap.cpp \
108 VMMAll/PGMAllPhys.cpp \
109 VMMAll/PGMAllPool.cpp \
110 VMMAll/SELMAll.cpp \
111 VMMAll/EMAll.cpp \
112 VMMAll/EMAllA.asm \
113 VMMAll/TMAll.cpp \
114 VMMAll/TMAllCpu.cpp \
115 VMMAll/TMAllReal.cpp \
116 VMMAll/TMAllVirtual.cpp \
117 VMMAll/TRPMAll.cpp \
118 VMMAll/VMAll.cpp \
119 VMMAll/VMMAll.cpp \
120 PATM/CSAM.cpp \
121 PATM/VMMAll/CSAMAll.cpp \
122 PATM/PATM.cpp \
123 PATM/PATMPatch.cpp \
124 PATM/PATMGuest.cpp \
125 PATM/PATMA.asm \
126 PATM/PATMSSM.cpp \
127 PATM/VMMAll/PATMAll.cpp
128VMMR3_SOURCES.x86 += \
129 VMMSwitcher/32BitTo32Bit.asm \
130 VMMSwitcher/32BitToPAE.asm \
131 VMMSwitcher/PAETo32Bit.asm \
132 VMMSwitcher/PAEToPAE.asm
133VMMR3_SOURCES.amd64 = \
134 VMMSwitcher/AMD64ToPAE.asm
135VMMR3_SOURCES.darwin.x86 += \
136 VMMSwitcher/AMD64ToPAE.asm
137
138ifdef VBOX_WITH_USB
139VMMR3_DEFS += VBOX_WITH_USB
140VMMR3_SOURCES += PDMUsb.cpp
141endif
142
143
144#
145# The VMM DLL.
146#
147DLLS += VBoxVMM
148VBoxVMM_TEMPLATE = VBOXR3
149VBoxVMM_DEFS = $(VMMR3_DEFS)
150VBoxVMM_SOURCES = VBoxVMMDeps.cpp
151VBoxVMM_SONAME.linux = VBoxVMM.so
152
153VBoxVMM_LIBS = \
154 $(PATH_LIB)/VMMR3$(VBOX_SUFF_LIB) \
155 $(PATH_LIB)/Debugger$(VBOX_SUFF_LIB) \
156 $(PATH_LIB)/DisasmR3$(VBOX_SUFF_LIB) \
157 $(LIB_REM) \
158 $(LIB_RUNTIME)
159
160VBoxVMM_LIBS.win = $(PATH_TOOL_$(VBOX_VCC_TOOL)_LIB)/delayimp.lib
161VBoxVMM_LDFLAGS.win = /DELAYLOAD:dbghelp.dll
162VBoxVMM_LDFLAGS.linux = -Wl,--no-undefined
163VBoxVMM_LDFLAGS.darwin = -install_name @executable_path/VBoxVMM.dylib
164VBoxVMM_LDFLAGS.solaris = -mimpure-text
165
166
167ifneq ($(filter pe lx,$(VBOX_LDR_FMT32)),)
168
169#
170# VMMGCBuiltin.lib
171#
172LIBRARIES += VMMGCBuiltin
173VMMGCBuiltin_TEMPLATE = VBOXGC
174ifeq ($(VBOX_LDR_FMT32),pe)
175VMMGCBuiltin_SOURCES = VMMGC/VMMGCBuiltin.def
176endif
177ifeq ($(VBOX_LDR_FMT32),lx)
178VMMGCBuiltin_SOURCES = $(PATH_TARGET)/VMMGCBuiltin.def
179$(PATH_TARGET)/VMMGCBuiltin.def: VMMGC/VMMGCBuiltin.def | $(call DIRDEP,$(PATH_TARGET))
180 $(SED) -e '/not-os2/d' -e 's/^[ \t][ \t]*\([a-zA-Z]\)/ _\1/' -e 's/[ \t]DATA[ \t]*/ /' $< > [email protected]
181 $(MV) -f [email protected] $@
182endif
183
184
185#
186# VMMGCImp.lib
187#
188LIBRARIES += VMMGCImp
189VMMGCImp_TEMPLATE = VBOXGC
190ifeq ($(VBOX_LDR_FMT32),pe)
191VMMGCImp_SOURCES = VMMGC/VMMGC.def
192endif
193ifeq ($(VBOX_LDR_FMT32),lx)
194VMMGCImp_SOURCES = $(PATH_TARGET)/VMMGC.def
195$(PATH_TARGET)/VMMGC.def: VMMGC/VMMGC.def | $(call DIRDEP,$(PATH_TARGET))
196 $(SED) -e '/not-os2/d' -e 's/^[ \t][ \t]*\([a-zA-Z]\)/ _\1/' -e 's/[ \t]DATA[ \t]*/ /' $< > [email protected]
197 $(APPEND) "[email protected]" ""
198 $(APPEND) "[email protected]" " ___ehInit"
199 $(MV) -f [email protected] $@
200endif
201
202endif # GC: pe + lx
203
204
205ifneq ($(filter pe lx,$(VBOX_LDR_FMT)),)
206#
207# VMMR0Imp.lib
208#
209LIBRARIES += VMMR0Imp
210VMMR0Imp_TEMPLATE = VBOXR0
211 ifeq ($(VBOX_LDR_FMT),pe)
212VMMR0Imp_SOURCES = VMMR0/VMMR0.def
213 endif
214 ifeq ($(VBOX_LDR_FMT),lx)
215VMMR0Imp_SOURCES = $(PATH_TARGET)/VMMR0.def
216$(PATH_TARGET)/VMMR0.def: VMMR0/VMMR0.def | $(call DIRDEP,$(PATH_TARGET))
217 $(SED) -e '/not-os2/d' -e 's/^[ \t][ \t]*\([a-zA-Z]\)/ _\1/' -e 's/[ \t]DATA[ \t]*/ /' $< > [email protected]
218 $(APPEND) "[email protected]" ""
219 $(APPEND) "[email protected]" " ___ehInit"
220 $(MV) -f [email protected] $@
221 endif
222endif # R0: pe + lx
223
224
225#
226# VMMGC.gc
227#
228SYSMODS += VMMGC
229VMMGC_TEMPLATE = VBOXGC
230VMMGC_INCS := \
231 $(PATH_SUB_CURRENT) \
232 VMMGC \
233 PATM
234VMMGC_DEFS = IN_VMM_GC IN_PDM_GC IN_CFGM_GC IN_IOM_GC IN_MM_GC IN_RT_GC IN_TRPM_GC IN_SELM_GC IN_VM_GC IN_IOM_GC IN_DIS_GC DIS_CORE_ONLY IN_PGM_GC IN_CPUM_GC IN_EM_GC IN_TM_GC IN_PATM_GC IN_CSAM_GC IN_REM_GC IN_DBGF_GC
235ifdef VBOX_WITH_IDT_PATCHING
236VMMGC_DEFS += VBOX_WITH_IDT_PATCHING
237endif
238VMMGC_SYSSUFF = .gc
239VMMGC_LIBS = \
240 $(PATH_LIB)/DisasmGC$(VBOX_SUFF_LIB) \
241 $(PATH_LIB)/RuntimeGC$(VBOX_SUFF_LIB)
242ifneq ($(filter pe lx,$(VBOX_LDR_FMT32)),)
243VMMGC_LIBS += \
244 $(PATH_LIB)/VMMGCBuiltin$(VBOX_SUFF_LIB)
245endif
246ifeq ($(VBOX_LDR_FMT32),pe)
247VMMGC_LDFLAGS = -Entry:VMMGCEntry
248endif
249VMMGC_SOURCES = \
250 VMMGC/VMMGC0.asm \
251 VMMGC/VMMGCDeps.cpp \
252 VMMGC/CPUMGC.cpp \
253 VMMGC/CPUMGCA.asm \
254 VMMGC/EMGCA.asm \
255 VMMGC/DBGFGC.cpp \
256 VMMGC/IOMGC.cpp \
257 VMMGC/MMRamGC.cpp \
258 VMMGC/MMRamGCA.asm \
259 VMMGC/PDMGCDevice.cpp \
260 VMMGC/PGMGC.cpp \
261 VMMGC/SELMGC.cpp \
262 VMMGC/TRPMGC.cpp \
263 VMMGC/TRPMGCHandlers.cpp \
264 VMMGC/TRPMGCHandlersA.asm \
265 VMMGC/VMMGC.cpp \
266 VMMGC/VMMGCA.asm \
267 VMMAll/CPUMAllRegs.cpp \
268 VMMAll/CPUMAllA.asm \
269 VMMAll/DBGFAll.cpp \
270 VMMAll/IOMAll.cpp \
271 VMMAll/IOMAllMMIO.cpp \
272 VMMAll/EMAll.cpp \
273 VMMAll/EMAllA.asm \
274 VMMAll/MMAll.cpp \
275 VMMAll/MMAllHyper.cpp \
276 VMMAll/PDMAll.cpp \
277 VMMAll/PDMAllCritSect.cpp \
278 VMMAll/PDMAllQueue.cpp \
279 VMMAll/PGMAll.cpp \
280 VMMAll/PGMAllHandler.cpp \
281 VMMAll/PGMAllMap.cpp \
282 VMMAll/PGMAllPhys.cpp \
283 VMMAll/PGMAllPool.cpp \
284 VMMAll/REMAll.cpp \
285 VMMAll/SELMAll.cpp \
286 VMMAll/TMAll.cpp \
287 VMMAll/TMAllCpu.cpp \
288 VMMAll/TMAllReal.cpp \
289 VMMAll/TMAllVirtual.cpp \
290 VMMAll/TRPMAll.cpp \
291 VMMAll/VMAll.cpp \
292 VMMAll/VMMAll.cpp \
293 PATM/VMMGC/CSAMGC.cpp \
294 PATM/VMMAll/CSAMAll.cpp \
295 PATM/VMMGC/PATMGC.cpp \
296 PATM/VMMAll/PATMAll.cpp
297
298ifeq ($(VBOX_LDR_FMT32),pe)
299VMMGC_SOURCES += VMMGC/VMMGC.def
300endif
301ifeq ($(VBOX_LDR_FMT32),lx)
302VMMGC_SOURCES += $(PATH_TARGET)/VMMGC.def
303endif
304
305# the very last one.
306VMMGC_SOURCES += VMMGC/VMMGC99.asm
307
308VMMGC/VMMGCDeps.cpp_CXXFLAGS.win = -Oi- -TC ## @todo rename VMMGCDeps.cpp to .c
309
310
311#
312# VMMR0.r0
313#
314SYSMODS += VMMR0
315VMMR0_TEMPLATE = VBOXR0
316VMMR0_INCS := \
317 $(PATH_SUB_CURRENT) \
318 PATM
319VMMR0_DEFS = IN_VMM_R0 IN_RT_R0 IN_TRPM_R0 IN_CPUM_R0 IN_VM_R0 IN_TM_R0 IN_INTNET_R0 IN_HWACCM_R0 IN_EM_R0 IN_PDM_R0 IN_PGM_R0 IN_DIS_R0 IN_MM_R0 IN_SELM_R0 IN_CSAM_R0 IN_PATM_R0 IN_DBGF_R0 IN_REM_R0 IN_IOM_R0 IN_GVMM_R0 IN_GMM_R0 DIS_CORE_ONLY
320ifdef VBOX_WITH_IDT_PATCHING
321VMMR0_DEFS += VBOX_WITH_IDT_PATCHING
322endif
323ifeq ($(VBOX_LDR_FMT),pe)
324VMMR0_LDFLAGS = -Entry:VMMR0EntryEx
325endif
326ifeq ($(VBOX_LDR_FMT),elf)
327 VMMR0_LDFLAGS = -e VMMR0EntryEx
328endif
329VMMR0_SYSSUFF = .r0
330VMMR0_SOURCES = \
331 VMMR0/CPUMR0.cpp \
332 VMMR0/DBGFR0.cpp \
333 VMMR0/GMMR0.cpp \
334 VMMR0/GVMMR0.cpp \
335 VMMR0/HWACCMR0.cpp \
336 VMMR0/HWACCMR0A.asm \
337 VMMR0/HWSVMR0.cpp \
338 VMMR0/HWVMXR0.cpp \
339 VMMR0/PDMR0Device.cpp \
340 VMMR0/PGMR0.cpp \
341 VMMR0/TRPMR0.cpp \
342 VMMR0/TRPMR0A.asm \
343 VMMR0/VMMR0.cpp \
344 VMMR0/VMMR0A.asm \
345 VMMAll/CPUMAllA.asm \
346 VMMAll/CPUMAllRegs.cpp \
347 VMMAll/DBGFAll.cpp \
348 VMMAll/EMAll.cpp \
349 VMMAll/EMAllA.asm \
350 VMMAll/IOMAll.cpp \
351 VMMAll/IOMAllMMIO.cpp \
352 VMMAll/MMAll.cpp \
353 VMMAll/MMAllHyper.cpp \
354 VMMAll/MMAllPagePool.cpp \
355 VMMAll/MMAllPhys.cpp \
356 VMMAll/PDMAll.cpp \
357 VMMAll/PDMAllCritSect.cpp \
358 VMMAll/PDMAllQueue.cpp \
359 VMMAll/PGMAll.cpp \
360 VMMAll/PGMAllHandler.cpp \
361 VMMAll/PGMAllMap.cpp \
362 VMMAll/PGMAllPhys.cpp \
363 VMMAll/PGMAllPool.cpp \
364 VMMAll/REMAll.cpp \
365 VMMAll/SELMAll.cpp \
366 VMMAll/TMAll.cpp \
367 VMMAll/TMAllCpu.cpp \
368 VMMAll/TMAllReal.cpp \
369 VMMAll/TMAllVirtual.cpp \
370 VMMAll/TRPMAll.cpp \
371 VMMAll/VMAll.cpp \
372
373
374ifeq ($(VBOX_LDR_FMT),pe)
375VMMR0_SOURCES += VMMR0/VMMR0.def
376endif
377ifeq ($(VBOX_LDR_FMT),lx)
378VMMR0_SOURCES += $(PATH_TARGET)/VMMR0.def
379endif
380
381VMMR0_LIBS = \
382 $(PATH_LIB)/ServicesR0$(VBOX_SUFF_LIB) \
383 $(PATH_LIB)/RuntimeR0$(VBOX_SUFF_LIB) \
384 $(PATH_LIB)/DisasmR0$(VBOX_SUFF_LIB)
385ifneq ($(filter pe lx,$(VBOX_LDR_FMT)),)
386VMMR0_LIBS += \
387 $(PATH_LIB)/SUPR0$(VBOX_SUFF_LIB)
388endif
389
390
391include $(PATH_KBUILD)/subfooter.kmk
392
393
394# Alias the PGM templates to the object in which they are defined.
395PGMBth.o PGMGst.o PGMShw.o \
396PGMBth.obj PGMGst.obj PGMShw.obj: PGM.o
397PGMAllBth.o PGMAllGst.o PGMAllShw.o \
398PGMAllBth.obj PGMAllGst.obj PGMAllShw.obj: PGMAll.o
399PGMGCBth.o PGMGCGst.o PGMGCShw.o \
400PGMGCBth.obj PGMGCGst.obj PGMGCShw.obj: PGMGC.o
401
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