VirtualBox

source: vbox/trunk/src/VBox/Runtime/testcase/Makefile.kmk@ 20033

Last change on this file since 20033 was 20033, checked in by vboxsync, 16 years ago

another OSE fix

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 8.7 KB
Line 
1# $Id: Makefile.kmk 20033 2009-05-26 12:40:07Z 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
31SUB_DEPTH = ../../../..
32include $(KBUILD_PATH)/subheader.kmk
33
34ifdef VBOX_WITH_TESTCASES
35
36#
37# Globals
38#
39# WARNING: Careful with this wrt to the other sub-makefiles this joins.
40#
41TEMPLATE = VBOXR3TSTEXE
42
43# Defined by the parent makefile as well (for errmsgdata.h).
44IPRT_OUT_DIR ?= $(PATH_TARGET)/Runtime
45
46
47#
48# Target lists
49#
50PROGRAMS += \
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 tstTermCallbacks \
92 tstThread-1 \
93 tstTime \
94 tstTime-2 \
95 tstTime-3 \
96 tstTime-4 \
97 tstTimer \
98 tstTimerLR \
99 tstTimeSpec \
100 tstTSC \
101 tstUtf8 \
102 tstUuid
103# tstSems
104PROGRAMS.win += \
105 tstRTProcWait \
106 tstRTCritSectW32 \
107 tstFileAppendWin-1 \
108 ntGetTimerResolution
109PROGRAMS.linux += \
110 tstRTProcWait \
111 tstRTProcIsRunningByName \
112 tstRTBitOperationsPIC3 \
113 tstInlineAsmPIC \
114 tstInlineAsmPIC3 \
115 tstSemMutex
116PROGRAMS.l4 += \
117 tstIoCtl
118PROGRAMS.darwin += \
119 tstDarwinSched
120SYSMODS += \
121 tstLdrObj \
122 tstLdrObjR0 \
123 tstR0ThreadPreemption
124if1of ($(VBOX_LDR_FMT)), lx pe)
125LIBRARIES += \
126 tstLdr-4Imp
127endif
128ifdef RT_ASYNC_IO_CODE
129PROGRAMS += \
130 tstFileAio
131endif
132
133if defined(VBOX_WITH_LIBXML2_IN_VBOXRT) && !defined(VBOX_OSE)
134PROGRAMS += \
135 tstRTS3
136endif
137
138
139#
140# Target configs in almost alphabetical order.
141#
142
143tstRTAvl_TEMPLATE = VBOXR3TSTEXE
144tstRTAvl_SOURCES = tstRTAvl.cpp
145
146tstRTBase64_TEMPLATE = VBOXR3TSTEXE
147tstRTBase64_SOURCES = tstRTBase64.cpp
148
149tstRTBitOperations_TEMPLATE = VBOXR3TSTEXE
150tstRTBitOperations_SOURCES = tstRTBitOperations.cpp
151
152tstRTBitOperationsPIC3_TEMPLATE = VBOXR3TSTEXE
153tstRTBitOperationsPIC3_SOURCES = tstRTBitOperations.cpp
154tstRTBitOperationsPIC3_CXXFLAGS = -fPIC -fomit-frame-pointer -O3
155tstRTBitOperationsPIC3_DEFS = PIC
156
157tstRTCidr_TEMPLATE = VBOXR3TSTEXE
158tstRTCidr_SOURCES = tstRTCidr.cpp
159
160tstRTCritSect_TEMPLATE = VBOXR3TSTEXE
161tstRTCritSect_SOURCES = tstRTCritSect.cpp
162
163tstRTCritSectW32_TEMPLATE = VBOXR3TSTEXE
164tstRTCritSectW32_SOURCES = tstRTCritSect.cpp
165tstRTCritSectW32_DEFS = TRY_WIN32_CRIT
166
167tstDarwinSched_SOURCES = tstDarwinSched.cpp
168
169tstDeadlock_SOURCES = tstDeadlock.cpp
170
171tstDir_SOURCES = tstDir.cpp
172
173tstDir-2_SOURCES = tstDir-2.cpp
174
175tstDir-3_SOURCES = tstDir-3.cpp
176
177tstEnv_SOURCES = tstEnv.cpp
178
179# Note: tstErrUnique.cpp depends on a header generated by the makefile above us.
180tstErrUnique_SOURCES = tstErrUnique.cpp
181tstErrUnique_INCS = $(IPRT_OUT_DIR)/
182tstErrUnique.cpp_DEPS = $(IPRT_OUT_DIR)/errmsgdata.h
183
184tstFile_SOURCES = tstFile.cpp
185
186tstFileAppendWin-1_SOURCES = tstFileAppendWin-1.cpp
187
188tstFileLock_SOURCES = tstFileLock.cpp
189
190tstFork_SOURCES = tstFork.cpp
191
192tstGetOpt_SOURCES = tstGetOpt.cpp
193
194tstHandleTable_SOURCES = tstHandleTable.cpp
195
196tstHeapSimple_SOURCES = tstHeapSimple.cpp
197
198tstIoCtl_SOURCES = tstIoCtl.cpp
199
200tstInlineAsm_SOURCES = tstInlineAsm.cpp
201
202tstInlineAsmPIC_SOURCES = tstInlineAsm.cpp
203tstInlineAsmPIC_CXXFLAGS = -fPIC
204tstInlineAsmPIC_DEFS = PIC
205
206tstInlineAsmPIC3_SOURCES = tstInlineAsm.cpp
207tstInlineAsmPIC3_CXXFLAGS = -fPIC -fomit-frame-pointer -O3
208tstInlineAsmPIC3_DEFS = PIC
209
210tstLdr_SOURCES = tstLdr.cpp
211
212tstLdr-2_SOURCES = tstLdr-2.cpp
213tstLdr-2_DEFS = IN_DIS
214tstLdr-2_LIBS = \
215 $(PATH_LIB)/DisasmR3$(VBOX_SUFF_LIB)
216
217tstLdrObj_TEMPLATE = VBOXGC
218tstLdrObj_INST = $(INST_TESTCASE)
219tstLdrObj_SYSSUFF = .gc
220tstLdrObj_SOURCES = tstLdrObj.cpp
221tstLdrObj_DEFS = IN_DIS IN_RT_GC IN_RT_RC DIS_CORE_ONLY
222ifeq ($(VBOX_LDR_FMT32),elf)
223tstLdrObj_DEFS += VBOX_SOME_IMPORT_FUNCTION
224endif
225tstLdrObj_LIBS = \
226 $(PATH_LIB)/DisasmGC$(VBOX_SUFF_LIB) \
227 $(PATH_LIB)/RuntimeGC$(VBOX_SUFF_LIB)
228ifeq ($(VBOX_LDR_FMT32),pe)
229tstLdrObj_LDFLAGS = -Entry:Entrypoint
230tstLdrObj_LIBS += \
231 $(PATH_LIB)/VMMGCBuiltin$(VBOX_SUFF_LIB)
232endif # PE
233ifeq ($(VBOX_LDR_FMT32),elf)
234tstLdrObj_LDFLAGS = -e Entrypoint
235endif
236ifeq ($(VBOX_LDR_FMT32),lx)
237tstLdrObj_LIBS += \
238 $(PATH_LIB)/VMMGCBuiltin$(VBOX_SUFF_LIB)
239endif
240
241tstLdr-3_SOURCES = tstLdr-3.cpp
242tstLdr-3_DEFS = IN_DIS
243tstLdr-3_LIBS = \
244 $(PATH_LIB)/DisasmR3$(VBOX_SUFF_LIB)
245
246tstLdr-4Imp_TEMPLATE = VBOXR0
247ifeq ($(VBOX_LDR_FMT),lx)
248 tstLdr-4Imp_SOURCES = tstLdr-4Imp-os2.def
249else ifeq ($(VBOX_LDR_FMT),pe)
250 tstLdr-4Imp_SOURCES.win = tstLdr-4Imp-win.def
251endif
252
253tstLdrObjR0_TEMPLATE = VBOXR0
254tstLdrObjR0_INST = $(INST_TESTCASE)
255tstLdrObjR0_SYSSUFF = .r0
256tstLdrObjR0_SOURCES = tstLdrObjR0.cpp tstLdrDisasmTest.cpp
257tstLdrObjR0_DEFS = IN_DIS IN_RT_R0 DIS_CORE_ONLY
258ifeq ($(VBOX_LDR_FMT32),elf)
259 tstLdrObjR0_DEFS += VBOX_SOME_IMPORT_FUNCTION
260endif
261tstLdrObjR0_LIBS = \
262 $(PATH_LIB)/DisasmR0$(VBOX_SUFF_LIB) \
263 $(PATH_LIB)/RuntimeR0$(VBOX_SUFF_LIB)
264ifeq ($(VBOX_LDR_FMT),pe)
265 tstLdrObjR0_LDFLAGS = -Entry:Entrypoint
266 tstLdrObjR0_LIBS += \
267 $(PATH_LIB)/SUPR0$(VBOX_SUFF_LIB) \
268 $(TARGET_tstLdr-4Imp)
269endif
270ifeq ($(VBOX_LDR_FMT),elf)
271 tstLdrObjR0_LDFLAGS = -e Entrypoint
272endif
273ifeq ($(VBOX_LDR_FMT),lx)
274 tstLdrObjR0_LIBS += \
275 $(PATH_LIB)/SUPR0$(VBOX_SUFF_LIB) \
276 $(TARGET_tstLdr-4Imp)
277endif
278
279tstLdr-4_SOURCES = tstLdr-4.cpp tstLdrDisasmTest.cpp
280tstLdr-4_DEFS = IN_DIS
281tstLdr-4_LIBS = \
282 $(PATH_LIB)/DisasmR3$(VBOX_SUFF_LIB)
283
284tstLdrLoad_SOURCES = tstLdrLoad.cpp
285
286tstLog_SOURCES = tstLog.cpp
287
288tstMemAutoPtr_SOURCES = tstMemAutoPtr.cpp
289
290tstMove_SOURCES = tstMove.cpp
291
292tstMp-1_SOURCES = tstMp-1.cpp
293
294tstNoCrt-1_DEFS = RT_WITHOUT_NOCRT_WRAPPER_ALIASES
295tstNoCrt-1_SOURCES = \
296 tstNoCrt-1.cpp \
297 ../common/string/memcpy.asm \
298 ../common/string/mempcpy.asm \
299 ../common/string/memmove.asm \
300 ../common/string/memset.asm \
301 ../common/string/memchr.asm \
302 ../common/string/memcmp.asm \
303 ../common/string/strchr.asm \
304 ../common/string/strcmp.asm \
305 ../common/string/strcpy.asm \
306 ../common/string/strlen.asm
307
308tstOnce_SOURCES = tstOnce.cpp
309
310tstPath_SOURCES = tstPath.cpp
311
312tstPrfRT_SOURCES = tstPrfRT.cpp
313
314tstRand_SOURCES = tstRand.cpp
315
316tstR0ThreadPreemption_TEMPLATE = VBOXR0
317tstR0ThreadPreemption_INST = $(INST_TESTCASE)
318tstR0ThreadPreemption_DEFS = IN_RT_R0
319tstR0ThreadPreemption_SYSSUFF = .r0
320tstR0ThreadPreemption_SOURCES = tstR0ThreadPreemption.cpp
321tstR0ThreadPreemption_LIBS = $(PATH_LIB)/RuntimeR0$(VBOX_SUFF_LIB)
322if1of ($(VBOX_LDR_FMT), pe lx)
323 tstR0ThreadPreemption_LIBS += $(PATH_LIB)/SUPR0$(VBOX_SUFF_LIB)
324endif
325
326tstR0ThreadPreemptionDriver_SOURCES = tstR0ThreadPreemptionDriver.cpp
327
328tstRTFsQueries_SOURCES = tstRTFsQueries.cpp
329
330tstRTProcWait_SOURCES = tstRTProcWait.cpp
331
332tstRTProcIsRunningByName_SOURCES = tstRTProcIsRunningByName.cpp
333
334tstSemMutex_SOURCES = tstSemMutex.cpp
335
336tstSemPingPong_SOURCES = tstSemPingPong.cpp
337
338tstSems_SOURCES = tstSems.cpp
339
340tstStrFormat_SOURCES = tstStrFormat.cpp
341
342tstStrSimplePattern_SOURCES = tstStrSimplePattern.cpp
343
344tstStrToNum_SOURCES = tstStrToNum.cpp
345
346tstSystemQueryOsInfo_SOURCES = tstSystemQueryOsInfo.cpp
347
348tstTermCallbacks_SOURCES = tstTermCallbacks.cpp
349
350tstThread-1_SOURCES = tstThread-1.cpp
351
352tstTime_SOURCES = tstTime.cpp
353
354tstTime-2_SOURCES = tstTime-2.cpp
355
356tstTime-3_SOURCES = tstTime-3.cpp
357
358tstTime-4_SOURCES = tstTime-4.cpp
359
360tstTimer_SOURCES = tstTimer.cpp
361
362tstTimerLR_SOURCES = tstTimerLR.cpp
363
364tstTimeSpec_SOURCES = tstTimeSpec.cpp
365
366tstTSC_SOURCES = tstTSC.cpp
367tstTSC_CXXFLAGS.linux += -O3
368
369tstUuid_SOURCES = tstUuid.cpp
370
371tstRTS3_SOURCES = tstRTS3.cpp
372
373tstUtf8_SOURCES = tstUtf8.cpp
374
375tstFileAio_SOURCES = tstFileAio.cpp
376
377ntGetTimerResolution_SOURCES = ntGetTimerResolution.cpp
378ntGetTimerResolution_SDKS.win = WINPSDK W2K3DDK VBOX_NTDLL
379
380endif # VBOX_WITH_TESTCASES
381
382include $(KBUILD_PATH)/subfooter.kmk
383
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