1 | # $Id: Makefile.kmk 15821 2009-01-06 16:49:21Z 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 | tstAvl \
|
---|
52 | tstBitOperations \
|
---|
53 | tstCidr \
|
---|
54 | tstCritSect \
|
---|
55 | tstDeadlock \
|
---|
56 | tstDir \
|
---|
57 | tstDir-2 \
|
---|
58 | tstDir-3 \
|
---|
59 | tstEnv \
|
---|
60 | tstErrUnique \
|
---|
61 | tstFile \
|
---|
62 | tstFileLock \
|
---|
63 | tstGetOpt \
|
---|
64 | tstHandleTable \
|
---|
65 | tstHeapSimple \
|
---|
66 | tstInlineAsm \
|
---|
67 | tstLdr \
|
---|
68 | tstLdr-2 \
|
---|
69 | tstLdr-3 \
|
---|
70 | tstLdr-4 \
|
---|
71 | tstLdrLoad \
|
---|
72 | tstLog \
|
---|
73 | tstMemAutoPtr \
|
---|
74 | tstMove \
|
---|
75 | tstMp-1 \
|
---|
76 | tstNoCrt-1 \
|
---|
77 | tstOnce \
|
---|
78 | tstPath \
|
---|
79 | tstPrfRT \
|
---|
80 | tstRand \
|
---|
81 | tstRTFsQueries \
|
---|
82 | tstSemPingPong \
|
---|
83 | tstStrFormat \
|
---|
84 | tstStrSimplePattern \
|
---|
85 | tstStrToNum \
|
---|
86 | tstSystemQueryOsInfo \
|
---|
87 | tstThread-1 \
|
---|
88 | tstTime \
|
---|
89 | tstTime-2 \
|
---|
90 | tstTime-3 \
|
---|
91 | tstTime-4 \
|
---|
92 | tstTimer \
|
---|
93 | tstTimerLR \
|
---|
94 | tstTimeSpec \
|
---|
95 | tstTSC \
|
---|
96 | tstUtf8 \
|
---|
97 | tstUuid
|
---|
98 | # tstSems
|
---|
99 | PROGRAMS.win += \
|
---|
100 | tstRTProcWait \
|
---|
101 | tstCritSectW32 \
|
---|
102 | tstFileAppendWin-1 \
|
---|
103 | ntGetTimerResolution
|
---|
104 | PROGRAMS.linux += \
|
---|
105 | tstRTProcWait \
|
---|
106 | tstBitOperationsPIC3 \
|
---|
107 | tstInlineAsmPIC \
|
---|
108 | tstInlineAsmPIC3 \
|
---|
109 | tstSemMutex
|
---|
110 | PROGRAMS.l4 += \
|
---|
111 | tstIoCtl
|
---|
112 | PROGRAMS.darwin += \
|
---|
113 | tstDarwinSched
|
---|
114 | SYSMODS += \
|
---|
115 | tstLdrObj \
|
---|
116 | tstLdrObjR0
|
---|
117 | if1of ($(VBOX_LDR_FMT)), lx pe)
|
---|
118 | LIBRARIES += \
|
---|
119 | tstLdr-4Imp
|
---|
120 | endif
|
---|
121 |
|
---|
122 |
|
---|
123 |
|
---|
124 | #
|
---|
125 | # Target configs in almost alphabetical order.
|
---|
126 | #
|
---|
127 |
|
---|
128 | tstAvl_SOURCES = tstAvl.cpp
|
---|
129 |
|
---|
130 | tstBitOperations_TEMPLATE = VBOXR3TSTEXE
|
---|
131 | tstBitOperations_SOURCES = tstBitOperations.cpp
|
---|
132 |
|
---|
133 | tstBitOperationsPIC3_SOURCES = tstBitOperations.cpp
|
---|
134 | tstBitOperationsPIC3_CXXFLAGS = -fPIC -fomit-frame-pointer -O3
|
---|
135 | tstBitOperationsPIC3_DEFS = PIC
|
---|
136 |
|
---|
137 | tstCidr_SOURCES = tstCidr.cpp
|
---|
138 |
|
---|
139 | tstCritSect_SOURCES = tstCritSect.cpp
|
---|
140 |
|
---|
141 | tstCritSectW32_SOURCES = tstCritSect.cpp
|
---|
142 | tstCritSectW32_DEFS = TRY_WIN32_CRIT
|
---|
143 |
|
---|
144 | tstDarwinSched_SOURCES = tstDarwinSched.cpp
|
---|
145 |
|
---|
146 | tstDeadlock_SOURCES = tstDeadlock.cpp
|
---|
147 |
|
---|
148 | tstDir_SOURCES = tstDir.cpp
|
---|
149 |
|
---|
150 | tstDir-2_SOURCES = tstDir-2.cpp
|
---|
151 |
|
---|
152 | tstDir-3_SOURCES = tstDir-3.cpp
|
---|
153 |
|
---|
154 | tstEnv_SOURCES = tstEnv.cpp
|
---|
155 |
|
---|
156 | # Note: tstErrUnique.cpp depends on a header generated by the makefile above us.
|
---|
157 | tstErrUnique_SOURCES = tstErrUnique.cpp
|
---|
158 | tstErrUnique_INCS = $(IPRT_OUT_DIR)/
|
---|
159 | tstErrUnique.cpp_DEPS = $(IPRT_OUT_DIR)/errmsgdata.h
|
---|
160 |
|
---|
161 | tstFile_SOURCES = tstFile.cpp
|
---|
162 |
|
---|
163 | tstFileAppendWin-1_SOURCES = tstFileAppendWin-1.cpp
|
---|
164 |
|
---|
165 | tstFileLock_SOURCES = tstFileLock.cpp
|
---|
166 |
|
---|
167 | tstGetOpt_SOURCES = tstGetOpt.cpp
|
---|
168 |
|
---|
169 | tstHandleTable_SOURCES = tstHandleTable.cpp
|
---|
170 |
|
---|
171 | tstHeapSimple_SOURCES = tstHeapSimple.cpp
|
---|
172 |
|
---|
173 | tstIoCtl_SOURCES = tstIoCtl.cpp
|
---|
174 |
|
---|
175 | tstInlineAsm_SOURCES = tstInlineAsm.cpp
|
---|
176 |
|
---|
177 | tstInlineAsmPIC_SOURCES = tstInlineAsm.cpp
|
---|
178 | tstInlineAsmPIC_CXXFLAGS = -fPIC
|
---|
179 | tstInlineAsmPIC_DEFS = PIC
|
---|
180 |
|
---|
181 | tstInlineAsmPIC3_SOURCES = tstInlineAsm.cpp
|
---|
182 | tstInlineAsmPIC3_CXXFLAGS = -fPIC -fomit-frame-pointer -O3
|
---|
183 | tstInlineAsmPIC3_DEFS = PIC
|
---|
184 |
|
---|
185 | tstLdr_SOURCES = tstLdr.cpp
|
---|
186 |
|
---|
187 | tstLdr-2_SOURCES = tstLdr-2.cpp
|
---|
188 | tstLdr-2_DEFS = IN_DIS
|
---|
189 | tstLdr-2_LIBS = \
|
---|
190 | $(PATH_LIB)/DisasmR3$(VBOX_SUFF_LIB)
|
---|
191 |
|
---|
192 | tstLdrObj_TEMPLATE = VBOXGC
|
---|
193 | tstLdrObj_INST = $(INST_TESTCASE)
|
---|
194 | tstLdrObj_SYSSUFF = .gc
|
---|
195 | tstLdrObj_SOURCES = tstLdrObj.cpp
|
---|
196 | tstLdrObj_DEFS = IN_DIS IN_RT_GC IN_RT_RC DIS_CORE_ONLY
|
---|
197 | ifeq ($(VBOX_LDR_FMT32),elf)
|
---|
198 | tstLdrObj_DEFS += VBOX_SOME_IMPORT_FUNCTION
|
---|
199 | endif
|
---|
200 | tstLdrObj_LIBS = \
|
---|
201 | $(PATH_LIB)/DisasmGC$(VBOX_SUFF_LIB) \
|
---|
202 | $(PATH_LIB)/RuntimeGC$(VBOX_SUFF_LIB)
|
---|
203 | ifeq ($(VBOX_LDR_FMT32),pe)
|
---|
204 | tstLdrObj_LDFLAGS = -Entry:Entrypoint
|
---|
205 | tstLdrObj_LIBS += \
|
---|
206 | $(PATH_LIB)/VMMGCBuiltin$(VBOX_SUFF_LIB)
|
---|
207 | endif # PE
|
---|
208 | ifeq ($(VBOX_LDR_FMT32),elf)
|
---|
209 | tstLdrObj_LDFLAGS = -e Entrypoint
|
---|
210 | endif
|
---|
211 | ifeq ($(VBOX_LDR_FMT32),lx)
|
---|
212 | tstLdrObj_LIBS += \
|
---|
213 | $(PATH_LIB)/VMMGCBuiltin$(VBOX_SUFF_LIB)
|
---|
214 | endif
|
---|
215 |
|
---|
216 | tstLdr-3_SOURCES = tstLdr-3.cpp
|
---|
217 | tstLdr-3_DEFS = IN_DIS
|
---|
218 | tstLdr-3_LIBS = \
|
---|
219 | $(PATH_LIB)/DisasmR3$(VBOX_SUFF_LIB)
|
---|
220 |
|
---|
221 | tstLdr-4Imp_TEMPLATE = VBOXR0
|
---|
222 | ifeq ($(VBOX_LDR_FMT),lx)
|
---|
223 | tstLdr-4Imp_SOURCES = tstLdr-4Imp-os2.def
|
---|
224 | else ifeq ($(VBOX_LDR_FMT),pe)
|
---|
225 | tstLdr-4Imp_SOURCES.win = tstLdr-4Imp-win.def
|
---|
226 | endif
|
---|
227 |
|
---|
228 | tstLdrObjR0_TEMPLATE = VBOXR0
|
---|
229 | tstLdrObjR0_INST = $(INST_TESTCASE)
|
---|
230 | tstLdrObjR0_SYSSUFF = .r0
|
---|
231 | tstLdrObjR0_SOURCES = tstLdrObjR0.cpp tstLdrDisasmTest.cpp
|
---|
232 | tstLdrObjR0_DEFS = IN_DIS IN_RT_R0 DIS_CORE_ONLY
|
---|
233 | ifeq ($(VBOX_LDR_FMT32),elf)
|
---|
234 | tstLdrObjR0_DEFS += VBOX_SOME_IMPORT_FUNCTION
|
---|
235 | endif
|
---|
236 | tstLdrObjR0_LIBS = \
|
---|
237 | $(PATH_LIB)/DisasmR0$(VBOX_SUFF_LIB) \
|
---|
238 | $(PATH_LIB)/RuntimeR0$(VBOX_SUFF_LIB)
|
---|
239 | ifeq ($(VBOX_LDR_FMT),pe)
|
---|
240 | tstLdrObjR0_LDFLAGS = -Entry:Entrypoint
|
---|
241 | tstLdrObjR0_LIBS += \
|
---|
242 | $(PATH_LIB)/SUPR0$(VBOX_SUFF_LIB) \
|
---|
243 | $(TARGET_tstLdr-4Imp)
|
---|
244 | endif
|
---|
245 | ifeq ($(VBOX_LDR_FMT),elf)
|
---|
246 | tstLdrObjR0_LDFLAGS = -e Entrypoint
|
---|
247 | endif
|
---|
248 | ifeq ($(VBOX_LDR_FMT),lx)
|
---|
249 | tstLdrObjR0_LIBS += \
|
---|
250 | $(PATH_LIB)/SUPR0$(VBOX_SUFF_LIB) \
|
---|
251 | $(TARGET_tstLdr-4Imp)
|
---|
252 | endif
|
---|
253 |
|
---|
254 | tstLdr-4_SOURCES = tstLdr-4.cpp tstLdrDisasmTest.cpp
|
---|
255 | tstLdr-4_DEFS = IN_DIS
|
---|
256 | tstLdr-4_LIBS = \
|
---|
257 | $(PATH_LIB)/DisasmR3$(VBOX_SUFF_LIB)
|
---|
258 |
|
---|
259 | tstLdrLoad_SOURCES = tstLdrLoad.cpp
|
---|
260 |
|
---|
261 | tstLog_SOURCES = tstLog.cpp
|
---|
262 |
|
---|
263 | tstMemAutoPtr_SOURCES = tstMemAutoPtr.cpp
|
---|
264 |
|
---|
265 | tstMove_SOURCES = tstMove.cpp
|
---|
266 |
|
---|
267 | tstMp-1_SOURCES = tstMp-1.cpp
|
---|
268 |
|
---|
269 | tstNoCrt-1_DEFS = RT_WITHOUT_NOCRT_WRAPPER_ALIASES
|
---|
270 | tstNoCrt-1_SOURCES = \
|
---|
271 | tstNoCrt-1.cpp \
|
---|
272 | ../common/string/memcpy.asm \
|
---|
273 | ../common/string/mempcpy.asm \
|
---|
274 | ../common/string/memmove.asm \
|
---|
275 | ../common/string/memset.asm \
|
---|
276 | ../common/string/memchr.asm \
|
---|
277 | ../common/string/memcmp.asm \
|
---|
278 | ../common/string/strchr.asm \
|
---|
279 | ../common/string/strcmp.asm \
|
---|
280 | ../common/string/strcpy.asm \
|
---|
281 | ../common/string/strlen.asm
|
---|
282 |
|
---|
283 | tstOnce_SOURCES = tstOnce.cpp
|
---|
284 |
|
---|
285 | tstPath_SOURCES = tstPath.cpp
|
---|
286 |
|
---|
287 | tstPrfRT_SOURCES = tstPrfRT.cpp
|
---|
288 |
|
---|
289 | tstRand_SOURCES = tstRand.cpp
|
---|
290 |
|
---|
291 | tstRTFsQueries_SOURCES = tstRTFsQueries.cpp
|
---|
292 |
|
---|
293 | tstRTProcWait_SOURCES = tstRTProcWait.cpp
|
---|
294 |
|
---|
295 | tstSemMutex_SOURCES = tstSemMutex.cpp
|
---|
296 |
|
---|
297 | tstSemPingPong_SOURCES = tstSemPingPong.cpp
|
---|
298 |
|
---|
299 | tstSems_SOURCES = tstSems.cpp
|
---|
300 |
|
---|
301 | tstStrFormat_SOURCES = tstStrFormat.cpp
|
---|
302 |
|
---|
303 | tstStrSimplePattern_SOURCES = tstStrSimplePattern.cpp
|
---|
304 |
|
---|
305 | tstStrToNum_SOURCES = tstStrToNum.cpp
|
---|
306 |
|
---|
307 | tstSystemQueryOsInfo_SOURCES = tstSystemQueryOsInfo.cpp
|
---|
308 |
|
---|
309 | tstThread-1_SOURCES = tstThread-1.cpp
|
---|
310 |
|
---|
311 | tstTime_SOURCES = tstTime.cpp
|
---|
312 |
|
---|
313 | tstTime-2_SOURCES = tstTime-2.cpp
|
---|
314 |
|
---|
315 | tstTime-3_SOURCES = tstTime-3.cpp
|
---|
316 |
|
---|
317 | tstTime-4_SOURCES = tstTime-4.cpp
|
---|
318 |
|
---|
319 | tstTimer_SOURCES = tstTimer.cpp
|
---|
320 |
|
---|
321 | tstTimerLR_SOURCES = tstTimerLR.cpp
|
---|
322 |
|
---|
323 | tstTimeSpec_SOURCES = tstTimeSpec.cpp
|
---|
324 |
|
---|
325 | tstTSC_SOURCES = tstTSC.cpp
|
---|
326 | tstTSC_CXXFLAGS.linux += -O3
|
---|
327 |
|
---|
328 | tstUuid_SOURCES = tstUuid.cpp
|
---|
329 |
|
---|
330 | tstUtf8_SOURCES = tstUtf8.cpp
|
---|
331 |
|
---|
332 | ntGetTimerResolution_SOURCES = ntGetTimerResolution.cpp
|
---|
333 | ntGetTimerResolution_SDKS.win = WINPSDK W2K3DDK VBOX_NTDLL
|
---|
334 |
|
---|
335 | endif # VBOX_WITH_TESTCASES
|
---|
336 |
|
---|
337 | include $(KBUILD_PATH)/subfooter.kmk
|
---|
338 |
|
---|