1 | # $Id: Makefile.kmk 20111 2009-05-28 00:34:52Z vboxsync $
|
---|
2 | ## @file
|
---|
3 | # Sub-Makefile for the IPRT testcases.
|
---|
4 | #
|
---|
5 |
|
---|
6 | #
|
---|
7 | # Copyright (C) 2006-2007 Sun Microsystems, Inc.
|
---|
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 | # The contents of this file may alternatively be used under the terms
|
---|
18 | # of the Common Development and Distribution License Version 1.0
|
---|
19 | # (CDDL) only, as it comes in the "COPYING.CDDL" file of the
|
---|
20 | # VirtualBox OSE distribution, in which case the provisions of the
|
---|
21 | # CDDL are applicable instead of those of the GPL.
|
---|
22 | #
|
---|
23 | # You may elect to license modified versions of this file under the
|
---|
24 | # terms and conditions of either the GPL or the CDDL or both.
|
---|
25 | #
|
---|
26 | # Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa
|
---|
27 | # Clara, CA 95054 USA or visit http://www.sun.com if you need
|
---|
28 | # additional information or have any questions.
|
---|
29 | #
|
---|
30 |
|
---|
31 | SUB_DEPTH = ../../../..
|
---|
32 | include $(KBUILD_PATH)/subheader.kmk
|
---|
33 |
|
---|
34 | ifdef VBOX_WITH_TESTCASES
|
---|
35 |
|
---|
36 | #
|
---|
37 | # Globals
|
---|
38 | #
|
---|
39 | # WARNING: Careful with this wrt to the other sub-makefiles this joins.
|
---|
40 | #
|
---|
41 | TEMPLATE = VBOXR3TSTEXE
|
---|
42 |
|
---|
43 | # Defined by the parent makefile as well (for errmsgdata.h).
|
---|
44 | IPRT_OUT_DIR ?= $(PATH_TARGET)/Runtime
|
---|
45 |
|
---|
46 |
|
---|
47 | #
|
---|
48 | # Target lists
|
---|
49 | #
|
---|
50 | PROGRAMS += \
|
---|
51 | tstRTAvl \
|
---|
52 | tstRTBase64 \
|
---|
53 | tstRTBitOperations \
|
---|
54 | tstRTCidr \
|
---|
55 | tstRTCritSect \
|
---|
56 | tstDeadlock \
|
---|
57 | tstDir \
|
---|
58 | tstDir-2 \
|
---|
59 | tstDir-3 \
|
---|
60 | tstEnv \
|
---|
61 | tstErrUnique \
|
---|
62 | tstFile \
|
---|
63 | tstFileLock \
|
---|
64 | tstFork \
|
---|
65 | tstGetOpt \
|
---|
66 | tstHandleTable \
|
---|
67 | tstHeapSimple \
|
---|
68 | tstInlineAsm \
|
---|
69 | tstLdr \
|
---|
70 | tstLdr-2 \
|
---|
71 | tstLdr-3 \
|
---|
72 | tstLdr-4 \
|
---|
73 | tstLdrLoad \
|
---|
74 | tstLog \
|
---|
75 | tstMemAutoPtr \
|
---|
76 | tstMove \
|
---|
77 | tstMp-1 \
|
---|
78 | tstNoCrt-1 \
|
---|
79 | tstOnce \
|
---|
80 | tstPath \
|
---|
81 | tstPrfRT \
|
---|
82 | tstRand \
|
---|
83 | tstRTFsQueries \
|
---|
84 | tstR0ThreadPreemptionDriver \
|
---|
85 | tstSems \
|
---|
86 | tstSemPingPong \
|
---|
87 | tstStrFormat \
|
---|
88 | tstStrSimplePattern \
|
---|
89 | tstStrToNum \
|
---|
90 | tstSystemQueryOsInfo \
|
---|
91 | tstRTTemp \
|
---|
92 | tstTermCallbacks \
|
---|
93 | tstThread-1 \
|
---|
94 | tstTime \
|
---|
95 | tstTime-2 \
|
---|
96 | tstTime-3 \
|
---|
97 | tstTime-4 \
|
---|
98 | tstTimer \
|
---|
99 | tstTimerLR \
|
---|
100 | tstTimeSpec \
|
---|
101 | tstTSC \
|
---|
102 | tstUtf8 \
|
---|
103 | tstUuid
|
---|
104 | # tstSems
|
---|
105 | PROGRAMS.win += \
|
---|
106 | tstRTProcWait \
|
---|
107 | tstRTCritSectW32 \
|
---|
108 | tstFileAppendWin-1 \
|
---|
109 | ntGetTimerResolution
|
---|
110 | PROGRAMS.linux += \
|
---|
111 | tstRTProcWait \
|
---|
112 | tstRTProcIsRunningByName \
|
---|
113 | tstRTBitOperationsPIC3 \
|
---|
114 | tstInlineAsmPIC \
|
---|
115 | tstInlineAsmPIC3 \
|
---|
116 | tstSemMutex
|
---|
117 | PROGRAMS.l4 += \
|
---|
118 | tstIoCtl
|
---|
119 | PROGRAMS.darwin += \
|
---|
120 | tstDarwinSched
|
---|
121 | SYSMODS += \
|
---|
122 | tstLdrObj \
|
---|
123 | tstLdrObjR0 \
|
---|
124 | tstR0ThreadPreemption
|
---|
125 | if1of ($(VBOX_LDR_FMT)), lx pe)
|
---|
126 | LIBRARIES += \
|
---|
127 | tstLdr-4Imp
|
---|
128 | endif
|
---|
129 | ifdef RT_ASYNC_IO_CODE
|
---|
130 | PROGRAMS += \
|
---|
131 | tstFileAio
|
---|
132 | endif
|
---|
133 |
|
---|
134 | if defined(VBOX_WITH_LIBXML2_IN_VBOXRT)
|
---|
135 | PROGRAMS += \
|
---|
136 | tstRTS3
|
---|
137 | endif
|
---|
138 |
|
---|
139 |
|
---|
140 | #
|
---|
141 | # Target configs in almost alphabetical order.
|
---|
142 | #
|
---|
143 |
|
---|
144 | tstRTAvl_TEMPLATE = VBOXR3TSTEXE
|
---|
145 | tstRTAvl_SOURCES = tstRTAvl.cpp
|
---|
146 |
|
---|
147 | tstRTBase64_TEMPLATE = VBOXR3TSTEXE
|
---|
148 | tstRTBase64_SOURCES = tstRTBase64.cpp
|
---|
149 |
|
---|
150 | tstRTBitOperations_TEMPLATE = VBOXR3TSTEXE
|
---|
151 | tstRTBitOperations_SOURCES = tstRTBitOperations.cpp
|
---|
152 |
|
---|
153 | tstRTBitOperationsPIC3_TEMPLATE = VBOXR3TSTEXE
|
---|
154 | tstRTBitOperationsPIC3_SOURCES = tstRTBitOperations.cpp
|
---|
155 | tstRTBitOperationsPIC3_CXXFLAGS = -fPIC -fomit-frame-pointer -O3
|
---|
156 | tstRTBitOperationsPIC3_DEFS = PIC
|
---|
157 |
|
---|
158 | tstRTCidr_TEMPLATE = VBOXR3TSTEXE
|
---|
159 | tstRTCidr_SOURCES = tstRTCidr.cpp
|
---|
160 |
|
---|
161 | tstRTCritSect_TEMPLATE = VBOXR3TSTEXE
|
---|
162 | tstRTCritSect_SOURCES = tstRTCritSect.cpp
|
---|
163 |
|
---|
164 | tstRTCritSectW32_TEMPLATE = VBOXR3TSTEXE
|
---|
165 | tstRTCritSectW32_SOURCES = tstRTCritSect.cpp
|
---|
166 | tstRTCritSectW32_DEFS = TRY_WIN32_CRIT
|
---|
167 |
|
---|
168 | tstDeadlock_SOURCES = tstDeadlock.cpp
|
---|
169 |
|
---|
170 | tstDir_SOURCES = tstDir.cpp
|
---|
171 |
|
---|
172 | tstDir-2_SOURCES = tstDir-2.cpp
|
---|
173 |
|
---|
174 | tstDir-3_SOURCES = tstDir-3.cpp
|
---|
175 |
|
---|
176 | tstEnv_SOURCES = tstEnv.cpp
|
---|
177 |
|
---|
178 | # Note: tstErrUnique.cpp depends on a header generated by the makefile above us.
|
---|
179 | tstErrUnique_SOURCES = tstErrUnique.cpp
|
---|
180 | tstErrUnique_INCS = $(IPRT_OUT_DIR)/
|
---|
181 | tstErrUnique.cpp_DEPS = $(IPRT_OUT_DIR)/errmsgdata.h
|
---|
182 |
|
---|
183 | tstFile_SOURCES = tstFile.cpp
|
---|
184 |
|
---|
185 | tstFileAppendWin-1_SOURCES = tstFileAppendWin-1.cpp
|
---|
186 |
|
---|
187 | tstFileAio_SOURCES = tstFileAio.cpp
|
---|
188 |
|
---|
189 | tstFileLock_SOURCES = tstFileLock.cpp
|
---|
190 |
|
---|
191 | tstFork_SOURCES = tstFork.cpp
|
---|
192 |
|
---|
193 | tstGetOpt_SOURCES = tstGetOpt.cpp
|
---|
194 |
|
---|
195 | tstHandleTable_SOURCES = tstHandleTable.cpp
|
---|
196 |
|
---|
197 | tstHeapSimple_SOURCES = tstHeapSimple.cpp
|
---|
198 |
|
---|
199 | tstIoCtl_SOURCES = tstIoCtl.cpp
|
---|
200 |
|
---|
201 | tstInlineAsm_SOURCES = tstInlineAsm.cpp
|
---|
202 |
|
---|
203 | tstInlineAsmPIC_SOURCES = tstInlineAsm.cpp
|
---|
204 | tstInlineAsmPIC_CXXFLAGS = -fPIC
|
---|
205 | tstInlineAsmPIC_DEFS = PIC
|
---|
206 |
|
---|
207 | tstInlineAsmPIC3_SOURCES = tstInlineAsm.cpp
|
---|
208 | tstInlineAsmPIC3_CXXFLAGS = -fPIC -fomit-frame-pointer -O3
|
---|
209 | tstInlineAsmPIC3_DEFS = PIC
|
---|
210 |
|
---|
211 | tstLdr_SOURCES = tstLdr.cpp
|
---|
212 |
|
---|
213 | tstLdr-2_SOURCES = tstLdr-2.cpp
|
---|
214 | tstLdr-2_DEFS = IN_DIS
|
---|
215 | tstLdr-2_LIBS = \
|
---|
216 | $(PATH_LIB)/DisasmR3$(VBOX_SUFF_LIB)
|
---|
217 |
|
---|
218 | tstLdrObj_TEMPLATE = VBOXGC
|
---|
219 | tstLdrObj_INST = $(INST_TESTCASE)
|
---|
220 | tstLdrObj_SYSSUFF = .gc
|
---|
221 | tstLdrObj_SOURCES = tstLdrObj.cpp
|
---|
222 | tstLdrObj_DEFS = IN_DIS IN_RT_GC IN_RT_RC DIS_CORE_ONLY
|
---|
223 | ifeq ($(VBOX_LDR_FMT32),elf)
|
---|
224 | tstLdrObj_DEFS += VBOX_SOME_IMPORT_FUNCTION
|
---|
225 | endif
|
---|
226 | tstLdrObj_LIBS = \
|
---|
227 | $(PATH_LIB)/DisasmGC$(VBOX_SUFF_LIB) \
|
---|
228 | $(PATH_LIB)/RuntimeGC$(VBOX_SUFF_LIB)
|
---|
229 | ifeq ($(VBOX_LDR_FMT32),pe)
|
---|
230 | tstLdrObj_LDFLAGS = -Entry:Entrypoint
|
---|
231 | tstLdrObj_LIBS += \
|
---|
232 | $(PATH_LIB)/VMMGCBuiltin$(VBOX_SUFF_LIB)
|
---|
233 | endif # PE
|
---|
234 | ifeq ($(VBOX_LDR_FMT32),elf)
|
---|
235 | tstLdrObj_LDFLAGS = -e Entrypoint
|
---|
236 | endif
|
---|
237 | ifeq ($(VBOX_LDR_FMT32),lx)
|
---|
238 | tstLdrObj_LIBS += \
|
---|
239 | $(PATH_LIB)/VMMGCBuiltin$(VBOX_SUFF_LIB)
|
---|
240 | endif
|
---|
241 |
|
---|
242 | tstLdr-3_SOURCES = tstLdr-3.cpp
|
---|
243 | tstLdr-3_DEFS = IN_DIS
|
---|
244 | tstLdr-3_LIBS = \
|
---|
245 | $(PATH_LIB)/DisasmR3$(VBOX_SUFF_LIB)
|
---|
246 |
|
---|
247 | tstLdr-4Imp_TEMPLATE = VBOXR0
|
---|
248 | ifeq ($(VBOX_LDR_FMT),lx)
|
---|
249 | tstLdr-4Imp_SOURCES = tstLdr-4Imp-os2.def
|
---|
250 | else ifeq ($(VBOX_LDR_FMT),pe)
|
---|
251 | tstLdr-4Imp_SOURCES.win = tstLdr-4Imp-win.def
|
---|
252 | endif
|
---|
253 |
|
---|
254 | tstLdrObjR0_TEMPLATE = VBOXR0
|
---|
255 | tstLdrObjR0_INST = $(INST_TESTCASE)
|
---|
256 | tstLdrObjR0_SYSSUFF = .r0
|
---|
257 | tstLdrObjR0_SOURCES = tstLdrObjR0.cpp tstLdrDisasmTest.cpp
|
---|
258 | tstLdrObjR0_DEFS = IN_DIS IN_RT_R0 DIS_CORE_ONLY
|
---|
259 | ifeq ($(VBOX_LDR_FMT32),elf)
|
---|
260 | tstLdrObjR0_DEFS += VBOX_SOME_IMPORT_FUNCTION
|
---|
261 | endif
|
---|
262 | tstLdrObjR0_LIBS = \
|
---|
263 | $(PATH_LIB)/DisasmR0$(VBOX_SUFF_LIB) \
|
---|
264 | $(PATH_LIB)/RuntimeR0$(VBOX_SUFF_LIB)
|
---|
265 | ifeq ($(VBOX_LDR_FMT),pe)
|
---|
266 | tstLdrObjR0_LDFLAGS = -Entry:Entrypoint
|
---|
267 | tstLdrObjR0_LIBS += \
|
---|
268 | $(PATH_LIB)/SUPR0$(VBOX_SUFF_LIB) \
|
---|
269 | $(TARGET_tstLdr-4Imp)
|
---|
270 | endif
|
---|
271 | ifeq ($(VBOX_LDR_FMT),elf)
|
---|
272 | tstLdrObjR0_LDFLAGS = -e Entrypoint
|
---|
273 | endif
|
---|
274 | ifeq ($(VBOX_LDR_FMT),lx)
|
---|
275 | tstLdrObjR0_LIBS += \
|
---|
276 | $(PATH_LIB)/SUPR0$(VBOX_SUFF_LIB) \
|
---|
277 | $(TARGET_tstLdr-4Imp)
|
---|
278 | endif
|
---|
279 |
|
---|
280 | tstLdr-4_SOURCES = tstLdr-4.cpp tstLdrDisasmTest.cpp
|
---|
281 | tstLdr-4_DEFS = IN_DIS
|
---|
282 | tstLdr-4_LIBS = \
|
---|
283 | $(PATH_LIB)/DisasmR3$(VBOX_SUFF_LIB)
|
---|
284 |
|
---|
285 | tstLdrLoad_SOURCES = tstLdrLoad.cpp
|
---|
286 |
|
---|
287 | tstLog_SOURCES = tstLog.cpp
|
---|
288 |
|
---|
289 | tstMemAutoPtr_SOURCES = tstMemAutoPtr.cpp
|
---|
290 |
|
---|
291 | tstMove_SOURCES = tstMove.cpp
|
---|
292 |
|
---|
293 | tstMp-1_SOURCES = tstMp-1.cpp
|
---|
294 |
|
---|
295 | tstNoCrt-1_DEFS = RT_WITHOUT_NOCRT_WRAPPER_ALIASES
|
---|
296 | tstNoCrt-1_SOURCES = \
|
---|
297 | tstNoCrt-1.cpp \
|
---|
298 | ../common/string/memcpy.asm \
|
---|
299 | ../common/string/mempcpy.asm \
|
---|
300 | ../common/string/memmove.asm \
|
---|
301 | ../common/string/memset.asm \
|
---|
302 | ../common/string/memchr.asm \
|
---|
303 | ../common/string/memcmp.asm \
|
---|
304 | ../common/string/strchr.asm \
|
---|
305 | ../common/string/strcmp.asm \
|
---|
306 | ../common/string/strcpy.asm \
|
---|
307 | ../common/string/strlen.asm
|
---|
308 |
|
---|
309 | tstOnce_SOURCES = tstOnce.cpp
|
---|
310 |
|
---|
311 | tstPath_SOURCES = tstPath.cpp
|
---|
312 |
|
---|
313 | tstPrfRT_SOURCES = tstPrfRT.cpp
|
---|
314 |
|
---|
315 | tstRand_SOURCES = tstRand.cpp
|
---|
316 |
|
---|
317 | tstR0ThreadPreemption_TEMPLATE = VBOXR0
|
---|
318 | tstR0ThreadPreemption_INST = $(INST_TESTCASE)
|
---|
319 | tstR0ThreadPreemption_DEFS = IN_RT_R0
|
---|
320 | tstR0ThreadPreemption_SYSSUFF = .r0
|
---|
321 | tstR0ThreadPreemption_SOURCES = tstR0ThreadPreemption.cpp
|
---|
322 | tstR0ThreadPreemption_LIBS = $(PATH_LIB)/RuntimeR0$(VBOX_SUFF_LIB)
|
---|
323 | if1of ($(VBOX_LDR_FMT), pe lx)
|
---|
324 | tstR0ThreadPreemption_LIBS += $(PATH_LIB)/SUPR0$(VBOX_SUFF_LIB)
|
---|
325 | endif
|
---|
326 |
|
---|
327 | tstR0ThreadPreemptionDriver_SOURCES = tstR0ThreadPreemptionDriver.cpp
|
---|
328 |
|
---|
329 | tstRTFsQueries_SOURCES = tstRTFsQueries.cpp
|
---|
330 |
|
---|
331 | tstRTProcWait_SOURCES = tstRTProcWait.cpp
|
---|
332 |
|
---|
333 | tstRTProcIsRunningByName_SOURCES = tstRTProcIsRunningByName.cpp
|
---|
334 |
|
---|
335 | tstRTS3_SOURCES = tstRTS3.cpp
|
---|
336 |
|
---|
337 | tstSemMutex_SOURCES = tstSemMutex.cpp
|
---|
338 |
|
---|
339 | tstSemPingPong_SOURCES = tstSemPingPong.cpp
|
---|
340 |
|
---|
341 | tstSems_SOURCES = tstSems.cpp
|
---|
342 |
|
---|
343 | tstStrFormat_SOURCES = tstStrFormat.cpp
|
---|
344 |
|
---|
345 | tstStrSimplePattern_SOURCES = tstStrSimplePattern.cpp
|
---|
346 |
|
---|
347 | tstStrToNum_SOURCES = tstStrToNum.cpp
|
---|
348 |
|
---|
349 | tstSystemQueryOsInfo_SOURCES = tstSystemQueryOsInfo.cpp
|
---|
350 |
|
---|
351 | tstRTTemp_TEMPLATE = VBOXR3TSTEXE
|
---|
352 | tstRTTemp_SOURCES = tstRTTemp.cpp
|
---|
353 |
|
---|
354 | tstTermCallbacks_SOURCES = tstTermCallbacks.cpp
|
---|
355 |
|
---|
356 | tstThread-1_SOURCES = tstThread-1.cpp
|
---|
357 |
|
---|
358 | tstTime_SOURCES = tstTime.cpp
|
---|
359 |
|
---|
360 | tstTime-2_SOURCES = tstTime-2.cpp
|
---|
361 |
|
---|
362 | tstTime-3_SOURCES = tstTime-3.cpp
|
---|
363 |
|
---|
364 | tstTime-4_SOURCES = tstTime-4.cpp
|
---|
365 |
|
---|
366 | tstTimer_SOURCES = tstTimer.cpp
|
---|
367 |
|
---|
368 | tstTimerLR_SOURCES = tstTimerLR.cpp
|
---|
369 |
|
---|
370 | tstTimeSpec_SOURCES = tstTimeSpec.cpp
|
---|
371 |
|
---|
372 | tstTSC_SOURCES = tstTSC.cpp
|
---|
373 | tstTSC_CXXFLAGS.linux += -O3
|
---|
374 |
|
---|
375 | tstUuid_SOURCES = tstUuid.cpp
|
---|
376 |
|
---|
377 | tstUtf8_SOURCES = tstUtf8.cpp
|
---|
378 |
|
---|
379 |
|
---|
380 | #
|
---|
381 | # odds and ends
|
---|
382 | #
|
---|
383 |
|
---|
384 | tstDarwinSched_SOURCES = tstDarwinSched.cpp
|
---|
385 |
|
---|
386 | ntGetTimerResolution_SOURCES = ntGetTimerResolution.cpp
|
---|
387 | ntGetTimerResolution_SDKS.win = WINPSDK W2K3DDK VBOX_NTDLL
|
---|
388 |
|
---|
389 | endif # VBOX_WITH_TESTCASES
|
---|
390 |
|
---|
391 | include $(KBUILD_PATH)/subfooter.kmk
|
---|
392 |
|
---|