1 | # $Id: Makefile.kmk 84540 2020-05-26 15:06:13Z vboxsync $
|
---|
2 | ## @file
|
---|
3 | # Sub-Makefile for the VMM testcases.
|
---|
4 | #
|
---|
5 |
|
---|
6 | #
|
---|
7 | # Copyright (C) 2006-2020 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 |
|
---|
18 | SUB_DEPTH = ../../../..
|
---|
19 | include $(KBUILD_PATH)/subheader.kmk
|
---|
20 |
|
---|
21 | #
|
---|
22 | # Include sub-makefiles.
|
---|
23 | #
|
---|
24 | if 0 # Not ready for general consumption yet.
|
---|
25 | include $(PATH_SUB_CURRENT)/Instructions/Makefile.kmk
|
---|
26 | endif
|
---|
27 |
|
---|
28 | #
|
---|
29 | # Target lists.
|
---|
30 | #
|
---|
31 | PROGRAMS += tstVMStructSize tstAsmStructs
|
---|
32 | ifdef VBOX_WITH_RAW_MODE
|
---|
33 | PROGRAMS += tstVMStructRC tstAsmStructsRC
|
---|
34 | endif
|
---|
35 | if !defined(VBOX_ONLY_EXTPACKS) \
|
---|
36 | && ( defined(VBOX_WITH_DTRACE_R3) \
|
---|
37 | || defined(VBOX_WITH_DTRACE_R0) \
|
---|
38 | || defined(VBOX_WITH_DTRACE_RC))
|
---|
39 | PROGRAMS += tstVMStructDTrace
|
---|
40 | INSTALLS += VMMLibDTraceStructTest
|
---|
41 | endif
|
---|
42 | ifndef VBOX_ONLY_EXTPACKS_USE_IMPLIBS
|
---|
43 | if defined(VBOX_WITH_HARDENING) && "$(KBUILD_TARGET)" == "win"
|
---|
44 | PROGRAMS += tstGlobalConfigHardened
|
---|
45 | DLL += tstGlobalConfig
|
---|
46 | else
|
---|
47 | PROGRAMS += tstGlobalConfig
|
---|
48 | endif
|
---|
49 |
|
---|
50 | ifdef VBOX_WITH_RAW_MODE
|
---|
51 | if defined(VBOX_WITH_HARDENING) && "$(KBUILD_TARGET)" == "win"
|
---|
52 | PROGRAMS += tstVMMHardened
|
---|
53 | DLLS += tstVMM
|
---|
54 | else
|
---|
55 | PROGRAMS += tstVMM tstVMM-HM
|
---|
56 | endif
|
---|
57 | ifneq ($(KBUILD_TARGET),win)
|
---|
58 | PROGRAMS += tstVMMFork
|
---|
59 | endif
|
---|
60 | endif
|
---|
61 | ifdef VBOX_WITH_TESTCASES
|
---|
62 | if defined(VBOX_WITH_HARDENING) && "$(KBUILD_TARGET)" == "win"
|
---|
63 | PROGRAMS += tstCFGMHardened tstVMREQHardened tstMMHyperHeapHardened tstAnimateHardened
|
---|
64 | DLLS += tstCFGM tstVMREQ tstMMHyperHeap tstAnimate
|
---|
65 | else
|
---|
66 | PROGRAMS += tstCFGM tstVMREQ tstMMHyperHeap tstAnimate
|
---|
67 | endif
|
---|
68 | PROGRAMS += \
|
---|
69 | tstCompressionBenchmark \
|
---|
70 | tstIEMCheckMc \
|
---|
71 | tstSSM \
|
---|
72 | tstVMMR0CallHost-1 \
|
---|
73 | tstVMMR0CallHost-2 \
|
---|
74 | tstX86-FpuSaveRestore
|
---|
75 | ifn1of ($(KBUILD_TARGET).$(KBUILD_TARGET_ARCH), solaris.x86 solaris.amd64 win.amd64 ) ## TODO: Fix the code.
|
---|
76 | PROGRAMS += tstX86-1
|
---|
77 | endif
|
---|
78 | ifdef VBOX_WITH_RAW_MODE
|
---|
79 | if defined(VBOX_WITH_HARDENING) && "$(KBUILD_TARGET)" == "win"
|
---|
80 | PROGRAMS += tstMicroHardened
|
---|
81 | DLLS += tstMicro
|
---|
82 | else
|
---|
83 | PROGRAMS += tstMicro
|
---|
84 | endif
|
---|
85 | SYSMODS += tstMicroRC
|
---|
86 | endif
|
---|
87 | ifdef VBOX_WITH_PDM_ASYNC_COMPLETION
|
---|
88 | if defined(VBOX_WITH_HARDENING) && "$(KBUILD_TARGET)" == "win"
|
---|
89 | PROGRAMS += tstPDMAsyncCompletionHardened tstPDMAsyncCompletionStressHardened
|
---|
90 | DLLS += tstPDMAsyncCompletion tstPDMAsyncCompletionStress
|
---|
91 | else
|
---|
92 | PROGRAMS += tstPDMAsyncCompletion tstPDMAsyncCompletionStress
|
---|
93 | endif
|
---|
94 | endif
|
---|
95 | endif # VBOX_WITH_TESTCASES
|
---|
96 | endif # !VBOX_ONLY_EXTPACKS_USE_IMPLIBS
|
---|
97 |
|
---|
98 | # Where we put our temporary files (just for simplicity)
|
---|
99 | VBOX_VMM_TESTCASE_OUT_DIR := $(PATH_TARGET)/VMM
|
---|
100 | BLDDIRS += $(VBOX_VMM_TESTCASE_OUT_DIR)
|
---|
101 |
|
---|
102 | #
|
---|
103 | # We setup two 'other' targets for executing the two structure & alignment
|
---|
104 | # validation testcases. Perhaps a bit hackish, but extremely useful.
|
---|
105 | #
|
---|
106 | ifeq ($(KBUILD_TARGET),$(KBUILD_HOST))
|
---|
107 | ifeq ($(filter-out x86.x86 amd64.amd64 x86.amd64, $(KBUILD_TARGET_ARCH).$(KBUILD_HOST_ARCH)),)
|
---|
108 | OTHERS += \
|
---|
109 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructs.run \
|
---|
110 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstVMStructSize.run
|
---|
111 | endif
|
---|
112 | endif
|
---|
113 |
|
---|
114 | # The normal testing pass.
|
---|
115 | TESTING += \
|
---|
116 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructs.run \
|
---|
117 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstVMStructSize.run
|
---|
118 |
|
---|
119 | OTHER_CLEAN += \
|
---|
120 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructs.run \
|
---|
121 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstVMStructSize.run \
|
---|
122 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructsAsm.o \
|
---|
123 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructsAsm.o.dep \
|
---|
124 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructsAsm.mac \
|
---|
125 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructsAsm.mac.o \
|
---|
126 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructsAsm.mac.lst \
|
---|
127 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructsRC.h \
|
---|
128 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructsHC.h \
|
---|
129 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstVMStructRC.h
|
---|
130 |
|
---|
131 | #
|
---|
132 | # Globals
|
---|
133 | #
|
---|
134 | VBOX_PATH_VMM_SRC = $(PATH_ROOT)/src/VBox/VMM
|
---|
135 |
|
---|
136 | #
|
---|
137 | # Targets
|
---|
138 | #
|
---|
139 | ifdef VBOX_WITH_RAW_MODE
|
---|
140 | tstVMStructRC_TEMPLATE = VBoxRcExe
|
---|
141 | tstVMStructRC_DEFS = VBOX_IN_VMM IN_VMM_RC IN_DIS IN_RT_RC VBOX_WITH_RAW_MODE $(VMM_COMMON_DEFS)
|
---|
142 | ifdef VBOX_WITH_R0_LOGGING
|
---|
143 | tstVMStructRC_DEFS += VBOX_WITH_R0_LOGGING
|
---|
144 | endif
|
---|
145 | ifdef VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI
|
---|
146 | tstVMStructRC_DEFS += VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI
|
---|
147 | endif
|
---|
148 | tstVMStructRC_SOURCES = tstVMStructRC.cpp
|
---|
149 | tstVMStructRC_INCS = \
|
---|
150 | $(VBOX_PATH_VMM_SRC)/include \
|
---|
151 | $(VBOX_PATH_VMM_SRC)/PATM
|
---|
152 | endif
|
---|
153 |
|
---|
154 | tstVMStructSize_TEMPLATE= VBOXR3AUTOTST
|
---|
155 | ifneq ($(KBUILD_TARGET),win)
|
---|
156 | tstVMStructSize_CXXFLAGS += $(VBOX_GCC_Wno-invalid-offsetof)
|
---|
157 | endif
|
---|
158 | tstVMStructSize_DEFS = VBOX_IN_VMM IN_VMM_R3 IN_DIS $(VMM_COMMON_DEFS)
|
---|
159 | ifdef VBOX_WITH_RAW_MODE
|
---|
160 | tstVMStructSize_DEFS += VBOX_WITH_RAW_MODE
|
---|
161 | endif
|
---|
162 | tstVMStructSize_INCS = \
|
---|
163 | $(VBOX_PATH_VMM_SRC)/include \
|
---|
164 | $(VBOX_PATH_VMM_SRC)/PATM \
|
---|
165 | $(VBOX_VMM_TESTCASE_OUT_DIR)
|
---|
166 | tstVMStructSize_SOURCES = tstVMStructSize.cpp
|
---|
167 | ifdef VBOX_WITH_RAW_MODE
|
---|
168 | tstVMStructSize.cpp_DEPS= $(VBOX_VMM_TESTCASE_OUT_DIR)/tstVMStructRC.h
|
---|
169 | endif
|
---|
170 | ifdef VBOX_WITH_R0_LOGGING
|
---|
171 | tstVMStructSize_DEFS += VBOX_WITH_R0_LOGGING
|
---|
172 | endif
|
---|
173 | ifdef VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI
|
---|
174 | tstVMStructSize_DEFS += VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI
|
---|
175 | endif
|
---|
176 |
|
---|
177 | tstAsmStructs_TEMPLATE = VBOXR3AUTOTST
|
---|
178 | ifneq ($(KBUILD_TARGET),win)
|
---|
179 | tstAsmStructSize_CXXFLAGS += $(VBOX_GCC_Wno-invalid-offsetof)
|
---|
180 | endif
|
---|
181 | tstAsmStructs_DEFS = VBOX_IN_VMM IN_VMM_R3 IN_DIS $(VMM_COMMON_DEFS)
|
---|
182 | ifdef VBOX_WITH_RAW_MODE
|
---|
183 | tstAsmStructs_DEFS += VBOX_WITH_RAW_MODE
|
---|
184 | endif
|
---|
185 | ifdef VBOX_WITH_R0_LOGGING
|
---|
186 | tstAsmStructs_DEFS += VBOX_WITH_R0_LOGGING
|
---|
187 | endif
|
---|
188 | ifdef VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI
|
---|
189 | tstAsmStructs_DEFS += VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI
|
---|
190 | endif
|
---|
191 | tstAsmStructs_INCS = \
|
---|
192 | $(VBOX_PATH_VMM_SRC)/include \
|
---|
193 | $(VBOX_VMM_TESTCASE_OUT_DIR)
|
---|
194 | tstAsmStructs_SOURCES = tstAsmStructs.cpp
|
---|
195 | tstAsmStructs.cpp_DEPS = $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructsHC.h
|
---|
196 |
|
---|
197 | ifdef VBOX_WITH_RAW_MODE
|
---|
198 | tstAsmStructsRC_TEMPLATE= VBoxRcExe
|
---|
199 | tstAsmStructsRC_DEFS = VBOX_IN_VMM IN_VMM_RC IN_DIS IN_RT_RC VBOX_WITH_RAW_MODE $(VMM_COMMON_DEFS)
|
---|
200 | ifdef VBOX_WITH_R0_LOGGING
|
---|
201 | tstAsmStructsRC_DEFS += VBOX_WITH_R0_LOGGING
|
---|
202 | endif
|
---|
203 | ifdef VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI
|
---|
204 | tstAsmStructsRC_DEFS += VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI
|
---|
205 | endif
|
---|
206 | tstAsmStructsRC_INCS = \
|
---|
207 | $(VBOX_PATH_VMM_SRC)/include \
|
---|
208 | $(VBOX_VMM_TESTCASE_OUT_DIR)
|
---|
209 | tstAsmStructsRC_SOURCES = tstAsmStructs.cpp
|
---|
210 | tstAsmStructs.cpp_DEPS += $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructsRC.h
|
---|
211 | endif # VBOX_WITH_RAW_MODE
|
---|
212 |
|
---|
213 |
|
---|
214 | #
|
---|
215 | # Glboal config tool.
|
---|
216 | #
|
---|
217 | if defined(VBOX_WITH_HARDENING) && "$(KBUILD_TARGET)" == "win"
|
---|
218 | tstGlobalConfigHardened_TEMPLATE = VBoxR3HardenedTstExe
|
---|
219 | tstGlobalConfigHardened_NAME = tstGlobalConfig
|
---|
220 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
221 | tstGlobalConfigHardened_DEFS = PROGRAM_NAME_STR="tstGlobalConfig"
|
---|
222 | else
|
---|
223 | tstGlobalConfigHardened_DEFS = PROGRAM_NAME_STR=\"tstGlobalConfig\"
|
---|
224 | endif
|
---|
225 | tstGlobalConfigHardened_SOURCES = ../../HostDrivers/Support/SUPR3HardenedMainTemplateTestcase.cpp
|
---|
226 | tstGlobalConfig_TEMPLATE = VBoxR3HardenedTstDll
|
---|
227 | else
|
---|
228 | tstGlobalConfig_TEMPLATE = VBOXR3TSTEXE
|
---|
229 | endif
|
---|
230 | tstGlobalConfig_SOURCES = tstGlobalConfig.cpp
|
---|
231 | tstGlobalConfig_LIBS = $(LIB_RUNTIME)
|
---|
232 |
|
---|
233 | #
|
---|
234 | # Testcase for checking the repurposing of the IEM instruction code.
|
---|
235 | #
|
---|
236 | tstIEMCheckMc_TEMPLATE = VBOXR3TSTEXE
|
---|
237 | tstIEMCheckMc_SOURCES = tstIEMCheckMc.cpp
|
---|
238 | tstIEMCheckMc_DEFS = $(VMM_COMMON_DEFS)
|
---|
239 | tstIEMCheckMc_LIBS = $(LIB_RUNTIME)
|
---|
240 | ifeq ($(KBUILD_TARGET),win)
|
---|
241 | tstIEMCheckMc_CXXFLAGS = $(VBOX_C_CXX_FLAGS_NO_UNUSED_PARAMETERS) -wd4189 # local variable is initialized but not used.
|
---|
242 | else
|
---|
243 | tstIEMCheckMc_CXXFLAGS = $(VBOX_C_CXX_FLAGS_NO_UNUSED_PARAMETERS) -Wno-unused-value -Wno-unused-variable
|
---|
244 | endif
|
---|
245 |
|
---|
246 | #
|
---|
247 | # VMM heap testcase.
|
---|
248 | #
|
---|
249 | if defined(VBOX_WITH_HARDENING) && "$(KBUILD_TARGET)" == "win"
|
---|
250 | tstMMHyperHeapHardened_TEMPLATE = VBoxR3HardenedTstExe
|
---|
251 | tstMMHyperHeapHardened_NAME = tstMMHyperHeap
|
---|
252 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
253 | tstMMHyperHeapHardened_DEFS = PROGRAM_NAME_STR="tstMMHyperHeap"
|
---|
254 | else
|
---|
255 | tstMMHyperHeapHardened_DEFS = PROGRAM_NAME_STR=\"tstMMHyperHeap\"
|
---|
256 | endif
|
---|
257 | tstMMHyperHeapHardened_SOURCES = ../../HostDrivers/Support/SUPR3HardenedMainTemplateTestcase.cpp
|
---|
258 | tstMMHyperHeap_TEMPLATE = VBoxR3HardenedTstDll
|
---|
259 | else
|
---|
260 | tstMMHyperHeap_TEMPLATE = VBOXR3TSTEXE
|
---|
261 | endif
|
---|
262 | tstMMHyperHeap_DEFS = $(VMM_COMMON_DEFS)
|
---|
263 | tstMMHyperHeap_SOURCES = tstMMHyperHeap.cpp
|
---|
264 | tstMMHyperHeap_LIBS = $(LIB_VMM) $(LIB_REM) $(LIB_RUNTIME)
|
---|
265 |
|
---|
266 | #
|
---|
267 | # Saved state manager testcase.
|
---|
268 | #
|
---|
269 | tstSSM_TEMPLATE = VBOXR3TSTEXE
|
---|
270 | tstSSM_INCS = $(VBOX_PATH_VMM_SRC)/include
|
---|
271 | tstSSM_DEFS = $(VMM_COMMON_DEFS)
|
---|
272 | tstSSM_SOURCES = tstSSM.cpp
|
---|
273 | tstSSM_LIBS = $(LIB_VMM) $(LIB_REM) $(LIB_RUNTIME)
|
---|
274 |
|
---|
275 | #
|
---|
276 | # VMM configuration manager tests.
|
---|
277 | #
|
---|
278 | if defined(VBOX_WITH_HARDENING) && "$(KBUILD_TARGET)" == "win"
|
---|
279 | tstCFGMHardened_TEMPLATE = VBoxR3HardenedTstExe
|
---|
280 | tstCFGMHardened_NAME = tstCFGM
|
---|
281 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
282 | tstCFGMHardened_DEFS = PROGRAM_NAME_STR="tstCFGM"
|
---|
283 | else
|
---|
284 | tstCFGMHardened_DEFS = PROGRAM_NAME_STR=\"tstCFGM\"
|
---|
285 | endif
|
---|
286 | tstCFGMHardened_SOURCES = ../../HostDrivers/Support/SUPR3HardenedMainTemplateTestcase.cpp
|
---|
287 | tstCFGM_TEMPLATE = VBoxR3HardenedTstDll
|
---|
288 | else
|
---|
289 | tstCFGM_TEMPLATE = VBOXR3TSTEXE
|
---|
290 | endif
|
---|
291 | tstCFGM_DEFS = $(VMM_COMMON_DEFS)
|
---|
292 | tstCFGM_SOURCES = tstCFGM.cpp
|
---|
293 | tstCFGM_LIBS = $(LIB_VMM) $(LIB_REM) $(LIB_RUNTIME)
|
---|
294 |
|
---|
295 | #
|
---|
296 | # Comparing some compression algorithms considered for SSM usage.
|
---|
297 | #
|
---|
298 | tstCompressionBenchmark_TEMPLATE = VBOXR3TSTEXE
|
---|
299 | tstCompressionBenchmark_SOURCES = tstCompressionBenchmark.cpp
|
---|
300 |
|
---|
301 | #
|
---|
302 | # Two testcases for checking the ring-3 "long jump" code.
|
---|
303 | #
|
---|
304 | tstVMMR0CallHost-1_TEMPLATE = VBOXR3TSTEXE
|
---|
305 | tstVMMR0CallHost-1_DEFS = VMM_R0_NO_SWITCH_STACK
|
---|
306 | tstVMMR0CallHost-1_INCS = $(VBOX_PATH_VMM_SRC)/include
|
---|
307 | tstVMMR0CallHost-1_SOURCES = \
|
---|
308 | tstVMMR0CallHost-1.cpp
|
---|
309 | tstVMMR0CallHost-1_SOURCES.amd64 = \
|
---|
310 | $(VBOX_PATH_VMM_SRC)/VMMR0/VMMR0JmpA-amd64.asm
|
---|
311 | tstVMMR0CallHost-1_SOURCES.x86 = \
|
---|
312 | $(VBOX_PATH_VMM_SRC)/VMMR0/VMMR0JmpA-x86.asm
|
---|
313 |
|
---|
314 | tstVMMR0CallHost-2_EXTENDS = tstVMMR0CallHost-1
|
---|
315 | tstVMMR0CallHost-2_DEFS = VMM_R0_SWITCH_STACK
|
---|
316 |
|
---|
317 | #
|
---|
318 | # For testing the VM request queue code.
|
---|
319 | #
|
---|
320 | if defined(VBOX_WITH_HARDENING) && "$(KBUILD_TARGET)" == "win"
|
---|
321 | tstVMREQHardened_TEMPLATE = VBOXR3HARDENEDEXE
|
---|
322 | tstVMREQHardened_NAME = tstVMREQ
|
---|
323 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
324 | tstVMREQHardened_DEFS = PROGRAM_NAME_STR="tstVMREQ"
|
---|
325 | else
|
---|
326 | tstVMREQHardened_DEFS = PROGRAM_NAME_STR=\"tstVMREQ\"
|
---|
327 | endif
|
---|
328 | tstVMREQHardened_SOURCES = ../../HostDrivers/Support/SUPR3HardenedMainTemplate.cpp
|
---|
329 | tstVMREQ_TEMPLATE = VBOXR3
|
---|
330 | else
|
---|
331 | tstVMREQ_TEMPLATE = VBOXR3EXE
|
---|
332 | endif
|
---|
333 | tstVMREQ_DEFS = $(VMM_COMMON_DEFS)
|
---|
334 | tstVMREQ_SOURCES = tstVMREQ.cpp
|
---|
335 | tstVMREQ_LIBS = $(LIB_VMM) $(LIB_REM) $(LIB_RUNTIME)
|
---|
336 |
|
---|
337 | #
|
---|
338 | # Tool for reanimate things like OS/2 dumps.
|
---|
339 | #
|
---|
340 | if defined(VBOX_WITH_HARDENING) && "$(KBUILD_TARGET)" == "win"
|
---|
341 | tstAnimateHardened_TEMPLATE = VBOXR3HARDENEDEXE
|
---|
342 | tstAnimateHardened_NAME = tstAnimate
|
---|
343 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
344 | tstAnimateHardened_DEFS = PROGRAM_NAME_STR="tstAnimate"
|
---|
345 | else
|
---|
346 | tstAnimateHardened_DEFS = PROGRAM_NAME_STR=\"tstAnimate\"
|
---|
347 | endif
|
---|
348 | tstAnimateHardened_SOURCES = ../../HostDrivers/Support/SUPR3HardenedMainTemplate.cpp
|
---|
349 | tstAnimate_TEMPLATE = VBOXR3
|
---|
350 | else
|
---|
351 | tstAnimate_TEMPLATE = VBOXR3EXE
|
---|
352 | endif
|
---|
353 | tstAnimate_DEFS = $(VMM_COMMON_DEFS)
|
---|
354 | tstAnimate_SOURCES = tstAnimate.cpp
|
---|
355 | tstAnimate_LIBS = $(LIB_VMM) $(LIB_REM) $(LIB_RUNTIME)
|
---|
356 |
|
---|
357 | tstX86-1_TEMPLATE = VBOXR3TSTEXE
|
---|
358 | tstX86-1_SOURCES = tstX86-1.cpp tstX86-1A.asm
|
---|
359 | tstX86-1_LIBS = $(LIB_RUNTIME)
|
---|
360 | tstX86-1_LDFLAGS.linux = $(VBOX_GCC_no-pie)
|
---|
361 |
|
---|
362 | tstX86-FpuSaveRestore_TEMPLATE = VBOXR3TSTEXE
|
---|
363 | tstX86-FpuSaveRestore_SOURCES = tstX86-FpuSaveRestore.cpp tstX86-FpuSaveRestoreA.asm
|
---|
364 | tstX86-FpuSaveRestore_LIBS = $(LIB_RUNTIME)
|
---|
365 |
|
---|
366 | ifdef VBOX_WITH_RAW_MODE
|
---|
367 |
|
---|
368 | #
|
---|
369 | # Raw-mode VMM testcase.
|
---|
370 | #
|
---|
371 | if defined(VBOX_WITH_HARDENING) && "$(KBUILD_TARGET)" == "win"
|
---|
372 | tstVMMHardened_TEMPLATE = VBOXR3HARDENEDEXE
|
---|
373 | tstVMMHardened_NAME = tstVMM
|
---|
374 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
375 | tstVMMHardened_DEFS = PROGRAM_NAME_STR="tstVMM"
|
---|
376 | else
|
---|
377 | tstVMMHardened_DEFS = PROGRAM_NAME_STR=\"tstVMM\"
|
---|
378 | endif
|
---|
379 | tstVMMHardened_SOURCES = ../../HostDrivers/Support/SUPR3HardenedMainTemplate.cpp
|
---|
380 | tstVMM_TEMPLATE = VBOXR3
|
---|
381 | else
|
---|
382 | tstVMM_TEMPLATE = VBOXR3EXE
|
---|
383 | endif
|
---|
384 | tstVMM_SOURCES = tstVMM.cpp
|
---|
385 | tstVMM_LIBS = $(LIB_VMM) $(LIB_REM) $(LIB_RUNTIME)
|
---|
386 |
|
---|
387 | #
|
---|
388 | # HM VMM testcase.
|
---|
389 | #
|
---|
390 | tstVMM-HM_TEMPLATE = VBOXR3EXE
|
---|
391 | tstVMM-HM_SOURCES = tstVMM-HM.cpp
|
---|
392 | tstVMM-HM_LIBS = $(LIB_VMM) $(LIB_REM) $(LIB_RUNTIME)
|
---|
393 |
|
---|
394 | #
|
---|
395 | # VMM host process fork test case (memory ++).
|
---|
396 | #
|
---|
397 | tstVMMFork_TEMPLATE = VBOXR3EXE
|
---|
398 | tstVMMFork_SOURCES = tstVMMFork.cpp
|
---|
399 | tstVMMFork_LIBS = $(LIB_VMM) $(LIB_REM) $(LIB_RUNTIME)
|
---|
400 |
|
---|
401 | #
|
---|
402 | # Raw-mode micro benchmark.
|
---|
403 | #
|
---|
404 | if defined(VBOX_WITH_HARDENING) && "$(KBUILD_TARGET)" == "win"
|
---|
405 | tstMicroHardened_TEMPLATE = VBOXR3HARDENEDEXE
|
---|
406 | tstMicroHardened_NAME = tstMicro
|
---|
407 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
408 | tstMicroHardened_DEFS = PROGRAM_NAME_STR="tstMicro"
|
---|
409 | else
|
---|
410 | tstMicroHardened_DEFS = PROGRAM_NAME_STR=\"tstMicro\"
|
---|
411 | endif
|
---|
412 | tstMicroHardened_SOURCES = ../../HostDrivers/Support/SUPR3HardenedMainTemplate.cpp
|
---|
413 | tstMicro_TEMPLATE = VBOXR3
|
---|
414 | else
|
---|
415 | tstMicro_TEMPLATE = VBOXR3EXE
|
---|
416 | endif
|
---|
417 | tstMicro_SOURCES = tstMicro.cpp
|
---|
418 | tstMicro_LIBS = $(LIB_VMM) $(LIB_REM) $(LIB_RUNTIME)
|
---|
419 | tstMicro_DEFS = $(if $(VBOX_WITH_RAW_MODE),VBOX_WITH_RAW_MODE,)
|
---|
420 |
|
---|
421 | tstMicroRC_TEMPLATE = VBoxRc
|
---|
422 | tstMicroRC_SOURCES = tstMicroRC.cpp tstMicroRCA.asm
|
---|
423 | tstMicroRC_DEFS = $(if $(VBOX_WITH_RAW_MODE),VBOX_WITH_RAW_MODE,)
|
---|
424 | tstMicroRC_INCS = $(VBOX_PATH_VMM_SRC)/testcase
|
---|
425 | ifeq ($(VBOX_LDR_FMT32),pe)
|
---|
426 | tstMicroRC_LDFLAGS = -Entry:tstMicroRC
|
---|
427 | endif
|
---|
428 | tstMicroRC_SYSSUFF = .gc
|
---|
429 | tstMicroRC_LIBS = \
|
---|
430 | $(PATH_STAGE_LIB)/DisasmRC$(VBOX_SUFF_LIB) \
|
---|
431 | $(PATH_STAGE_LIB)/RuntimeRC$(VBOX_SUFF_LIB)
|
---|
432 | ifeq ($(filter-out pe lx,$(VBOX_LDR_FMT32)),)
|
---|
433 | tstMicroRC_LIBS += \
|
---|
434 | $(PATH_STAGE_LIB)/VMMRCBuiltin$(VBOX_SUFF_LIB) \
|
---|
435 | $(LIB_VMMRC)
|
---|
436 | endif
|
---|
437 | tstMicroRC_SOURCES.win = tstMicroRC.def
|
---|
438 |
|
---|
439 | endif # VBOX_WITH_RAW_MODE
|
---|
440 |
|
---|
441 |
|
---|
442 | if !defined(VBOX_ONLY_EXTPACKS_USE_IMPLIBS)
|
---|
443 | #
|
---|
444 | # Special NEM host testcase.
|
---|
445 | #
|
---|
446 | if ("$(KBUILD_TARGET_ARCH).$(KBUILD_TARGET_ARCH)" == "darwin.amd64" && (defined(VBOX_WITH_NATIVE_NEM) || "$(USERNAME)" == "bird")) \
|
---|
447 | || ("$(KBUILD_TARGET_ARCH).$(KBUILD_TARGET_ARCH)" == "linux.amd64" && (defined(VBOX_WITH_NATIVE_NEM) || "$(USERNAME)" == "bird")) \
|
---|
448 | || ("$(KBUILD_TARGET_ARCH).$(KBUILD_TARGET_ARCH)" == "win.amd64" && defined(VBOX_WITH_NATIVE_NEM))
|
---|
449 | PROGRAMS += NemRawBench-1
|
---|
450 | NemRawBench-1_TEMPLATE = VBoxR3Static
|
---|
451 | NemRawBench-1_SOURCES = NemRawBench-1.cpp
|
---|
452 | NemRawBench-1_BLD_TYPE = release
|
---|
453 | NemRawBench-1_INCS.win = \
|
---|
454 | $(KBUILD_DEVTOOLS)/win.x86/sdk/v10.0.17134.0/include/10.0.17134.0/um \
|
---|
455 | $(KBUILD_DEVTOOLS)/win.x86/sdk/v10.0.17134.0/include/10.0.17134.0/shared
|
---|
456 | NemRawBench-1_CXXFLAGS.darwin = \
|
---|
457 | -F/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform//Developer/SDKs/MacOSX10.13.sdk/System/Library/Frameworks
|
---|
458 | #NemRawBench-1_LDFLAGS.darwin = \
|
---|
459 | # -F/System/Library/Frameworks \
|
---|
460 | # -framework Hypervisor
|
---|
461 | NemRawBench-1_LDFLAGS.darwin = \
|
---|
462 | /System/Library/Frameworks/Hypervisor.framework/Hypervisor
|
---|
463 | endif
|
---|
464 | endif
|
---|
465 |
|
---|
466 |
|
---|
467 | ifdef VBOX_WITH_PDM_ASYNC_COMPLETION
|
---|
468 | #
|
---|
469 | # PDM asynchronous completation test.
|
---|
470 | #
|
---|
471 | if defined(VBOX_WITH_HARDENING) && "$(KBUILD_TARGET)" == "win"
|
---|
472 | tstPDMAsyncCompletionHardened_TEMPLATE = VBOXR3HARDENEDEXE
|
---|
473 | tstPDMAsyncCompletionHardened_NAME = tstPDMAsyncCompletion
|
---|
474 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
475 | tstPDMAsyncCompletionHardened_DEFS = PROGRAM_NAME_STR="tstPDMAsyncCompletion"
|
---|
476 | else
|
---|
477 | tstPDMAsyncCompletionHardened_DEFS = PROGRAM_NAME_STR=\"tstPDMAsyncCompletion\"
|
---|
478 | endif
|
---|
479 | tstPDMAsyncCompletionHardened_SOURCES = ../../HostDrivers/Support/SUPR3HardenedMainTemplate.cpp
|
---|
480 | tstPDMAsyncCompletion_TEMPLATE = VBOXR3
|
---|
481 | else
|
---|
482 | tstPDMAsyncCompletion_TEMPLATE = VBOXR3EXE
|
---|
483 | endif
|
---|
484 | tstPDMAsyncCompletion_DEFS = $(VMM_COMMON_DEFS)
|
---|
485 | tstPDMAsyncCompletion_INCS = $(VBOX_PATH_VMM_SRC)/include
|
---|
486 | tstPDMAsyncCompletion_SOURCES = tstPDMAsyncCompletion.cpp
|
---|
487 | tstPDMAsyncCompletion_LIBS = $(LIB_VMM) $(LIB_REM) $(LIB_RUNTIME)
|
---|
488 |
|
---|
489 | #
|
---|
490 | # PDM asynchronous completation stress test.
|
---|
491 | #
|
---|
492 | if defined(VBOX_WITH_HARDENING) && "$(KBUILD_TARGET)" == "win"
|
---|
493 | tstPDMAsyncCompletionStressHardened_TEMPLATE = VBOXR3HARDENEDEXE
|
---|
494 | tstPDMAsyncCompletionStressHardened_NAME = tstPDMAsyncCompletionStress
|
---|
495 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
496 | tstPDMAsyncCompletionStressHardened_DEFS = PROGRAM_NAME_STR="tstPDMAsyncCompletionStress"
|
---|
497 | else
|
---|
498 | tstPDMAsyncCompletionStressHardened_DEFS = PROGRAM_NAME_STR=\"tstPDMAsyncCompletionStress\"
|
---|
499 | endif
|
---|
500 | tstPDMAsyncCompletionStressHardened_SOURCES = ../../HostDrivers/Support/SUPR3HardenedMainTemplate.cpp
|
---|
501 | tstPDMAsyncCompletionStress_TEMPLATE = VBOXR3
|
---|
502 | else
|
---|
503 | tstPDMAsyncCompletionStress_TEMPLATE = VBOXR3EXE
|
---|
504 | endif
|
---|
505 | tstPDMAsyncCompletionStress_DEFS = $(VMM_COMMON_DEFS)
|
---|
506 | tstPDMAsyncCompletionStress_INCS = $(VBOX_PATH_VMM_SRC)/include
|
---|
507 | tstPDMAsyncCompletionStress_SOURCES = tstPDMAsyncCompletionStress.cpp
|
---|
508 | tstPDMAsyncCompletionStress_LIBS = $(LIB_VMM) $(LIB_REM) $(LIB_RUNTIME)
|
---|
509 | endif
|
---|
510 |
|
---|
511 | ifndef VBOX_ONLY_EXTPACKS
|
---|
512 | PROGRAMS += tstSSM-2
|
---|
513 | tstSSM-2_TEMPLATE = VBOXR3TSTEXE
|
---|
514 | tstSSM-2_DEFS = IN_VMM_STATIC
|
---|
515 | tstSSM-2_SOURCES = tstSSM-2.cpp
|
---|
516 | tstSSM-2_LIBS = $(PATH_STAGE_LIB)/SSMStandalone$(VBOX_SUFF_LIB)
|
---|
517 | endif
|
---|
518 |
|
---|
519 | #
|
---|
520 | # Generate VM structure tests.
|
---|
521 | #
|
---|
522 | if !defined(VBOX_ONLY_EXTPACKS) \
|
---|
523 | && ( defined(VBOX_WITH_DTRACE_R3) \
|
---|
524 | || defined(VBOX_WITH_DTRACE_R0) \
|
---|
525 | || defined(VBOX_WITH_DTRACE_RC))
|
---|
526 | tstVMStructDTrace_TEMPLATE = VBOXR3AUTOTST
|
---|
527 | tstVMStructDTrace_DEFS = VBOX_IN_VMM IN_VMM_R3 IN_DIS $(VMM_COMMON_DEFS)
|
---|
528 | ifdef VBOX_WITH_RAW_MODE
|
---|
529 | tstVMStructDTrace_DEFS += VBOX_WITH_RAW_MODE
|
---|
530 | endif
|
---|
531 | tstVMStructDTrace_INCS = \
|
---|
532 | $(VBOX_PATH_VMM_SRC)/include \
|
---|
533 | $(VBOX_PATH_VMM_SRC)/PATM \
|
---|
534 | $(VBOX_VMM_TESTCASE_OUT_DIR)
|
---|
535 | tstVMStructDTrace_SOURCES = tstVMStructDTrace.cpp
|
---|
536 | ifdef VBOX_WITH_R0_LOGGING
|
---|
537 | tstVMStructDTrace_DEFS += VBOX_WITH_R0_LOGGING
|
---|
538 | endif
|
---|
539 | ifdef VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI
|
---|
540 | tstVMStructDTrace_DEFS += VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI
|
---|
541 | endif
|
---|
542 |
|
---|
543 |
|
---|
544 | VMMLibDTraceStructTest_INST = $(VBOX_INST_DTRACE_TST)$(KBUILD_TARGET_ARCH)/
|
---|
545 | VMMLibDTraceStructTest_SOURCES = \
|
---|
546 | $(tstVMStructDTrace_0_OUTDIR)/vbox-vm-struct-test.d
|
---|
547 | VMMLibDTraceStructTest_CLEAN = \
|
---|
548 | $(tstVMStructDTrace_0_OUTDIR)/vbox-vm-struct-test.d
|
---|
549 |
|
---|
550 | $$(tstVMStructDTrace_0_OUTDIR)/vbox-vm-struct-test.d: \
|
---|
551 | $$(tstVMStructDTrace_1_STAGE_TARGET) | $$(dir $$@)
|
---|
552 | $(QUIET)$(RM) -f $@
|
---|
553 | $< > $@
|
---|
554 |
|
---|
555 | endif
|
---|
556 |
|
---|
557 |
|
---|
558 | include $(FILE_KBUILD_SUB_FOOTER)
|
---|
559 |
|
---|
560 |
|
---|
561 | #
|
---|
562 | # Some handcrafted support targets for tstAsmStructs.
|
---|
563 | #
|
---|
564 | MY_ASA_ASM_STUFF = \
|
---|
565 | $(addprefix -D, \
|
---|
566 | $(DEFS) \
|
---|
567 | $(DEFS.$(KBUILD_TYPE)) \
|
---|
568 | $(DEFS.$(KBUILD_TARGET)) \
|
---|
569 | IN_RING3 $(ARCH_BITS_DEFS) \
|
---|
570 | $(DEFS.$(KBUILD_TARGET_ARCH)) \
|
---|
571 | $(DEFS.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH)) \
|
---|
572 | $(if $(VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI),VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI,) \
|
---|
573 | $(VMM_COMMON_DEFS) \
|
---|
574 | ) \
|
---|
575 | -f $(if $(eq $(KBUILD_TARGET),darwin),macho,elf) \
|
---|
576 | $(foreach inc,$(INCS) $(VBOX_PATH_VMM_SRC)/testcase $(VBOX_PATH_VMM_SRC)/include $(VBOX_VMM_TESTCASE_OUT_DIR)\
|
---|
577 | ,-I$(inc)/)
|
---|
578 |
|
---|
579 | # 1a. make a header file which makes all the structures+members globals.
|
---|
580 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructsAsm.mac: \
|
---|
581 | $(VBOX_PATH_VMM_SRC)/testcase/tstAsmStructsAsm.asm \
|
---|
582 | $(VBOX_PATH_VMM_SRC)/testcase/tstAsmStructsAsm-lst.sed \
|
---|
583 | $(DEPTH)/include/iprt/asmdefs.mac \
|
---|
584 | $(DEPTH)/include/VBox/vmm/cpum.mac \
|
---|
585 | $(DEPTH)/include/VBox/vmm/vm.mac \
|
---|
586 | $(DEPTH)/include/VBox/sup.mac \
|
---|
587 | $(DEPTH)/include/iprt/x86.mac \
|
---|
588 | $(VBOX_PATH_VMM_SRC)/include/CPUMInternal.mac \
|
---|
589 | $(VBOX_PATH_VMM_SRC)/include/HMInternal.mac \
|
---|
590 | $(VBOX_PATH_VMM_SRC)/include/VMMInternal.mac \
|
---|
591 | $(VBOX_PATH_VMM_SRC)/testcase/Makefile.kmk \
|
---|
592 | $(PATH_ROOT)/Config.kmk $(LOCALCFG) $(AUTOCFG) \
|
---|
593 | | $$(dir $$@)
|
---|
594 | $(call MSG_GENERATE,tstVMStructSize,$@,$<)
|
---|
595 | ifndef DONT_USE_YASM
|
---|
596 | $(QUIET)$(TOOL_YASM_AS) $(MY_ASA_ASM_STUFF) -o $@.o -l $@.lst $<
|
---|
597 | $(SED) -f $(VBOX_PATH_VMM_SRC)/testcase/tstAsmStructsAsm-lst.sed --output $@ $@.lst
|
---|
598 | else
|
---|
599 | $(QUIET)$(TOOL_NASM_AS) -g $(MY_ASA_ASM_STUFF) -o $@.o -l $@.lst $<
|
---|
600 | $(VBOX_NM) $@.o | $(SED) \
|
---|
601 | -e '/[0-9a-fA-F][0-9a-fA-F]* [^a] /d' \
|
---|
602 | -e 's/[0-9a-fA-F][0-9a-fA-F]* a \([^ ]*\)/global \1/' \
|
---|
603 | > $@
|
---|
604 | endif
|
---|
605 |
|
---|
606 | # 1b. make an elf/macho object containing the offsets.
|
---|
607 | includedep $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructsAsm.o.dep
|
---|
608 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructsAsm.o: \
|
---|
609 | $(VBOX_PATH_VMM_SRC)/testcase/tstAsmStructsAsm.asm \
|
---|
610 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructsAsm.mac \
|
---|
611 | $(DEPTH)/include/iprt/asmdefs.mac \
|
---|
612 | $(DEPTH)/include/VBox/vmm/cpum.mac \
|
---|
613 | $(DEPTH)/include/VBox/vmm/hm_vmx.mac \
|
---|
614 | $(DEPTH)/include/VBox/vmm/stam.mac \
|
---|
615 | $(DEPTH)/include/VBox/vmm/vm.mac \
|
---|
616 | $(DEPTH)/include/VBox/sup.mac \
|
---|
617 | $(DEPTH)/include/iprt/x86.mac \
|
---|
618 | $(VBOX_PATH_VMM_SRC)/include/CPUMInternal.mac \
|
---|
619 | $(VBOX_PATH_VMM_SRC)/include/HMInternal.mac \
|
---|
620 | $(VBOX_PATH_VMM_SRC)/include/VMMInternal.mac \
|
---|
621 | $(VBOX_PATH_VMM_SRC)/testcase/Makefile.kmk \
|
---|
622 | $$(if $$(eq $$(tstAsmStructsAsmDep_STUFF),$$(MY_ASA_ASM_STUFF)),,FORCE) \
|
---|
623 | | $$(dir $$@)
|
---|
624 | $(call MSG_COMPILE,tstAsmStructsasm,$<,$@,AS)
|
---|
625 | ifndef DONT_USE_YASM
|
---|
626 | $(QUIET)$(TOOL_YASM_AS) $(MY_ASA_ASM_STUFF) -DDO_GLOBALS -o $@ $<
|
---|
627 | else
|
---|
628 | $(QUIET)$(TOOL_NASM_AS) $(MY_ASA_ASM_STUFF) -DDO_GLOBALS -o $@ $<
|
---|
629 | endif
|
---|
630 | %$(QUIET2)$(RM) -f -- $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructsAsm.o.dep
|
---|
631 | %$(QUIET2)$(APPEND) '$(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructsAsm.o.dep' 'tstAsmStructsAsmDep_STUFF=$(MY_ASA_ASM_STUFF)'
|
---|
632 |
|
---|
633 | # 2. use nm and sed to transform this into the header we want.
|
---|
634 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructsHC.h: $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructsAsm.o
|
---|
635 | $(call MSG_GENERATE,tstVMStructSize,$@,$<)
|
---|
636 | $(QUIET)$(RM) -f $@ $@.dump $@.tmp
|
---|
637 | $(QUIET)$(REDIRECT) -wo $@.dump -- $(VBOX_NM) $<
|
---|
638 | $(QUIET)$(SED) \
|
---|
639 | -e '/STAMPROFILEADV/d' \
|
---|
640 | \
|
---|
641 | -e '/^\(0x\)\{0,1\}00[0-9a-fA-F]* [aAnN] [^_.]*\./!d' \
|
---|
642 | -e 's/^\(0x\)\{0,1\}\(00[0-9a-fA-F]*\) [aAnN] \([^.]*\)\.\(.*$$\)/ CHECK_OFF(\3, 0x0\2, \4);/' \
|
---|
643 | --output $@.tmp $@.dump
|
---|
644 | $(QUIET)$(SED) \
|
---|
645 | -e '/VM_size$$/d' \
|
---|
646 | -e '/VMCPU_size$$/d' \
|
---|
647 | -e '/VMMCPU_size$$/d' \
|
---|
648 | -e '/SUPDRVTRACERUSRCTX32_size$$/d' \
|
---|
649 | -e '/HMCPU_size$$/d' \
|
---|
650 | \
|
---|
651 | -e '/^\(0x\)\{0,1\}00[0-9a-fA-F]* [aAnN] [^_.]*_size$$/!d' \
|
---|
652 | -e 's/^\(0x\)\{0,1\}\(00[0-9a-fA-F]*\) [aAnN] \([^_.]*\)_size/ CHECK_SIZE(\3, 0x0\2);/' \
|
---|
653 | --append $@.tmp $@.dump
|
---|
654 | $(QUIET)$(MV) -f $@.tmp $@
|
---|
655 | $(QUIET)$(RM) -f $@.dump
|
---|
656 |
|
---|
657 | # 3. run it.
|
---|
658 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructs.run: \
|
---|
659 | $$(tstAsmStructs_1_STAGE_TARGET) \
|
---|
660 | $(if-expr defined(VBOX_WITH_RAW_MODE),$$(tstAsmStructsRC_1_STAGE_TARGET),)
|
---|
661 | $(QUIET)$(RM) -f $@
|
---|
662 | $(tstAsmStructs_1_STAGE_TARGET)
|
---|
663 | ifdef VBOX_WITH_RAW_MODE
|
---|
664 | $(tstAsmStructsRC_1_STAGE_TARGET)
|
---|
665 | endif
|
---|
666 | $(QUIET)$(APPEND) "$@" "done"
|
---|
667 |
|
---|
668 |
|
---|
669 |
|
---|
670 | #
|
---|
671 | # Run rule for tstVMStructSize.
|
---|
672 | #
|
---|
673 |
|
---|
674 | ifdef VBOX_WITH_RAW_MODE
|
---|
675 | # 1. Manually dump selected structures and members.
|
---|
676 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstVMStructRC.h: $$(tstVMStructRC_1_STAGE_TARGET) | $$(dir $$@)
|
---|
677 | $(call MSG_GENERATE,tstVMStructSize,$@)
|
---|
678 | $(QUIET)$(REDIRECT) -wo $@ -- $<
|
---|
679 | endif # VBOX_WITH_RAW_MODE
|
---|
680 |
|
---|
681 | # 2. run it.
|
---|
682 | $(VBOX_VMM_TESTCASE_OUT_DIR)/tstVMStructSize.run: $$(tstVMStructSize_1_STAGE_TARGET) | $$(dir $$@)
|
---|
683 | $(QUIET)$(RM) -f $@
|
---|
684 | $<
|
---|
685 | $(QUIET)$(APPEND) "$@" "done"
|
---|
686 |
|
---|
687 | # alias for the two struct tests.
|
---|
688 | run-struct-tests: $(VBOX_VMM_TESTCASE_OUT_DIR)/tstAsmStructs.run $(VBOX_VMM_TESTCASE_OUT_DIR)/tstVMStructSize.run
|
---|
689 |
|
---|