VirtualBox

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

Last change on this file since 57580 was 57580, checked in by vboxsync, 9 years ago

IPRT: Implemented RTCrStoreCreateSnapshotById for darwin.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 90.4 KB
Line 
1# $Id: Makefile.kmk 57580 2015-08-29 00:05:48Z vboxsync $
2## @file
3# Sub-Makefile for the IPRT.
4#
5
6#
7# Copyright (C) 2006-2015 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# 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
27SUB_DEPTH = ../../..
28include $(KBUILD_PATH)/subheader.kmk
29
30ifdef VBOX_ONLY_ADDITIONS
31 #
32 # Only build the additions, sort out the legacy names first.
33 #
34 LIBRARIES += RuntimeGuestR3 RuntimeGuestR3Shared
35 LIBRARIES.win.amd64 += RuntimeGuestR3-x86 RuntimeGuestR3Shared-x86
36 ifdef VBOX_WITH_ADDITION_DRIVERS
37 LIBRARIES += RuntimeGuestR0
38 #LIBRARIES.os2 += RuntimeGuestR0OS2Warp3
39 LIBRARIES.win.x86 += RuntimeGuestR0NT4
40 endif
41
42else ifdef VBOX_ONLY_VALIDATIONKIT
43 #
44 # Only build the Validation Kit.
45 #
46 LIBRARIES += RuntimeGuestR3 RuntimeGuestR3Shared RuntimeR3 RuntimeR0 RuntimeBldProg
47 LIBRARIES.solaris += RuntimeR0Stub
48 LIBRARIES.win += RuntimeR0Stub
49 LIBRARIES.win.x86 += RuntimeR3VccTricks
50 include $(PATH_SUB_CURRENT)/tools/Makefile.kmk
51
52else ifdef VBOX_ONLY_DOCS
53 #
54 # Build docs only - need just regular R3 runtime.
55 #
56 LIBRARIES += RuntimeR3 RuntimeBldProg
57
58else ifdef VBOX_ONLY_EXTPACKS_USE_IMPLIBS
59 #
60 # Build extension packs using import libraries as much as possible (VBoxDTrace
61 # needs Ring-0 IPRT, though).
62 #
63 LIBRARIES += RuntimeBldProg RuntimeR0
64 LIBRARIES.solaris += RuntimeR0Stub
65 LIBRARIES.win += RuntimeR0Stub RuntimeRCStub
66 include $(PATH_SUB_CURRENT)/tools/Makefile.kmk
67
68else # !VBOX_ONLY_ADDITIONS && !VBOX_ONLY_VALIDATIONKIT && !VBOX_ONLY_DOCS
69
70 #
71 # Normal build.
72 #
73 ifndef VBOX_ONLY_EXTPACKS
74 include $(PATH_SUB_CURRENT)/testcase/Makefile.kmk
75 endif
76 include $(PATH_SUB_CURRENT)/tools/Makefile.kmk
77
78 BLDPROGS += uniread
79 LIBRARIES += RuntimeR3 RuntimeBldProg RuntimeR0 RuntimeEFCPP RuntimeR3NoCRTGCC
80 LIBRARIES.solaris += RuntimeR0Stub
81 LIBRARIES.win += RuntimeR0Stub
82 ifdef VBOX_WITH_RAW_MODE
83 LIBRARIES += RuntimeRC
84 LIBRARIES.win += RuntimeRCStub
85 endif
86 ifdef VBOX_WITH_VBOXDRV
87 LIBRARIES += RuntimeR0Drv
88 endif
89 ifdef VBOX_WITH_ADDITIONS
90 LIBRARIES += RuntimeGuestR3 RuntimeGuestR3Shared
91 LIBRARIES.win.amd64 += RuntimeGuestR3-x86 RuntimeGuestR3Shared-x86
92 ifdef VBOX_WITH_ADDITION_DRIVERS
93 LIBRARIES += RuntimeGuestR0
94 endif
95 #LIBRARIES.os2 += RuntimeGuestR0OS2Warp3
96 LIBRARIES.win.x86 += RuntimeGuestR0NT4
97 endif # VBOX_WITH_ADDITIONS
98 LIBRARIES.win.x86 += RuntimeR3VccTricks
99 DLLS += VBoxRT
100 ifdef VBOX_WITH_32_ON_64_MAIN_API
101 DLLS += VBoxRT-x86
102 endif
103endif
104
105
106# Always build the ntdll import libraries on windows.
107LIBRARIES.win += RuntimeR3NtDll-x86
108if1of (amd64, $(KBUILD_TARGET_ARCH) $(KBUILD_HOST_ARCH))
109 LIBRARIES.win += RuntimeR3NtDll-amd64
110endif
111
112
113# Always build the import library.
114IMPORT_LIBS += VBoxRTImp
115
116
117# Where the generated stuff goes.
118IPRT_OUT_DIR := $(PATH_TARGET)/Runtime
119BLDDIRS += $(IPRT_OUT_DIR)
120OTHER_CLEAN += \
121 $(IPRT_OUT_DIR)/errmsgdata.h \
122 $(IPRT_OUT_DIR)/errmsgcomdata.h \
123 $(IPRT_OUT_DIR)/errmsgvboxcomdata.h \
124 $(IPRT_OUT_DIR)/errmsgvboxcomdata.h.ts \
125 $(IPRT_OUT_DIR)/Doxyfile.iprt \
126 $(IPRT_OUT_DIR)/Doxyfile.iprt.dep \
127 $(IPRT_OUT_DIR)/docs.iprt
128
129
130#
131# Globals
132#
133VBOX_PATH_RUNTIME_SRC := $(PATH_SUB_CURRENT)
134
135
136#
137# Set the defines that buildconfig.cpp needs. Its used by several targets.
138#
139common/misc/buildconfig.cpp_DEFS = \
140 IPRT_BLDCFG_SCM_REV=$(VBOX_SVN_REV) \
141 IPRT_BLDCFG_VERSION_STRING=\"$(VBOX_VERSION_STRING)\" \
142 IPRT_BLDCFG_VERSION_MAJOR=$(VBOX_VERSION_MAJOR) \
143 IPRT_BLDCFG_VERSION_MINOR=$(VBOX_VERSION_MINOR) \
144 IPRT_BLDCFG_VERSION_BUILD=$(VBOX_VERSION_BUILD) \
145 IPRT_BLDCFG_TARGET=\"$(KBUILD_TARGET)\" \
146 IPRT_BLDCFG_TARGET_ARCH=\"$(KBUILD_TARGET_ARCH)\" \
147 IPRT_BLDCFG_TYPE=\"$(KBUILD_TYPE)\"
148
149#
150# Unicode Specification reader used to regenerate unidata-*.cpp.
151#
152uniread_TEMPLATE = VBoxBldProg
153uniread_SOURCES = common/string/uniread.cpp
154uniread_INCS = include
155
156#
157# Win64 assembly sources.
158#
159RuntimeWin64ASM_SOURCES = \
160 win/amd64/ASMAtomicBitClear.asm \
161 win/amd64/ASMAtomicBitTestAndToggle.asm \
162 win/amd64/ASMAtomicBitToggle.asm \
163 win/amd64/ASMAtomicReadU64.asm \
164 win/amd64/ASMAtomicXchgU16.asm \
165 win/amd64/ASMAtomicXchgU8.asm \
166 win/amd64/ASMBitFirstClear.asm \
167 win/amd64/ASMBitFirstSet.asm \
168 win/amd64/ASMGetCS.asm \
169 win/amd64/ASMGetDS.asm \
170 win/amd64/ASMGetES.asm \
171 win/amd64/ASMGetFlags.asm \
172 win/amd64/ASMGetFS.asm \
173 win/amd64/ASMGetGS.asm \
174 win/amd64/ASMGetSS.asm \
175 win/amd64/ASMProbeReadByte.asm \
176 win/amd64/ASMSetFlags.asm \
177 win/amd64/ASMGetDR0.asm \
178 win/amd64/ASMGetDR1.asm \
179 win/amd64/ASMGetDR2.asm \
180 win/amd64/ASMGetDR3.asm \
181 win/amd64/ASMGetDR6.asm \
182 win/amd64/ASMGetDR7.asm \
183 common/asm/ASMAtomicCmpXchgU8.asm \
184 common/asm/ASMMultU32ByU32DivByU32.asm \
185 common/asm/ASMMultU64ByU32DivByU32.asm \
186 common/asm/ASMCpuId_Idx_ECX.asm \
187 common/asm/ASMNopPause.asm \
188 common/asm/ASMGetIDTR.asm \
189 common/asm/ASMGetIdtrLimit.asm \
190 common/asm/ASMSetIDTR.asm \
191 common/asm/ASMGetGDTR.asm \
192 common/asm/ASMSetGDTR.asm \
193 common/asm/ASMGetLDTR.asm \
194 common/asm/ASMGetSegAttr.asm \
195 common/asm/ASMGetTR.asm
196
197#
198# Win32 assembly sources.
199#
200RuntimeWin32ASM_SOURCES = \
201 common/asm/ASMAtomicCmpXchgU8.asm \
202 common/asm/ASMMultU32ByU32DivByU32.asm \
203 common/asm/ASMMultU64ByU32DivByU32.asm \
204 common/asm/ASMCpuId_Idx_ECX.asm \
205 common/asm/ASMGetSegAttr.asm
206
207#
208# NoCRT sources (minus math stuff).
209#
210if1of ($(KBUILD_TARGET_ARCH), amd64 x86)
211RuntimeNoCrt_SOURCES = \
212 common/misc/setjmp.asm \
213 common/string/memchr.asm \
214 common/string/memcmp.asm \
215 common/string/memcpy.asm \
216 common/string/mempcpy.asm \
217 common/string/memmove.asm \
218 common/string/memset.asm \
219 common/string/strchr.asm \
220 common/string/strcpy.asm \
221 common/string/strncpy.asm \
222 common/string/strcmp.asm \
223 common/string/strlen.asm
224endif
225
226
227#
228# RuntimeR3 - Static Runtime for Ring-3 executables.
229#
230RuntimeR3_TEMPLATE = VBoxR3Static
231RuntimeR3_SDKS = VBOX_OPENSSL VBOX_LIBXML2
232RuntimeR3_SDKS.win = $(VBOX_WINPSDK) $(VBOX_WINDDK)
233RuntimeR3_DEFS = \
234 IN_RT_R3 \
235 IN_SUP_R3 \
236 LDR_WITH_NATIVE \
237 LDR_WITH_ELF32 \
238 LDR_WITH_PE \
239 RT_WITH_VBOX \
240 RT_NO_GIP \
241 RT_WITHOUT_NOCRT_WRAPPERS \
242 IPRT_WITH_OPENSSL
243#RuntimeR3_DEFS += RTMEM_WRAP_TO_EF_APIS
244ifdef IPRT_WITH_KSTUFF
245 RuntimeR3_DEFS += LDR_WITH_KLDR
246endif
247ifdef IPRT_WITH_LZJB
248 RuntimeR3_DEFS += RTZIP_USE_LZJB
249endif
250ifdef IPRT_WITH_LZO
251 RuntimeR3_DEFS += RTZIP_USE_LZO
252endif
253ifn1of ($(KBUILD_TARGET), win)
254 RuntimeR3_DEFS += RT_WITH_ICONV_CACHE
255endif
256ifdef IPRT_WITH_FUTEX_BASED_SEMS
257 RuntimeR3_DEFS.linux += IPRT_WITH_FUTEX_BASED_SEMS
258endif
259RuntimeR3_INCS = \
260 include \
261 $(SDK_VBOX_ZLIB_INCS)
262RuntimeR3_INCS += \
263 $(PATH_ROOT)/src/libs/liblzf-3.4
264ifdef IPRT_WITH_KSTUFF
265 RuntimeR3_INCS += \
266 $(PATH_ROOT)/src/libs/kStuff/kStuff/include
267endif
268
269# RuntimeR3_INCS.solaris = \
270# /usr/include
271
272RuntimeR3_SOURCES = \
273 common/alloc/alloc.cpp \
274 common/alloc/heapsimple.cpp \
275 common/alloc/heapoffset.cpp \
276 common/alloc/memcache.cpp \
277 common/alloc/memtracker.cpp \
278 common/asn1/asn1-basics.cpp \
279 common/asn1/asn1-cursor.cpp \
280 common/asn1/asn1-default-allocator.cpp \
281 common/asn1/asn1-efence-allocator.cpp \
282 common/asn1/asn1-dump.cpp \
283 common/asn1/asn1-encode.cpp \
284 common/asn1/asn1-ut-bitstring.cpp \
285 common/asn1/asn1-ut-bitstring-decode.cpp \
286 common/asn1/asn1-ut-boolean.cpp \
287 common/asn1/asn1-ut-boolean-decode.cpp \
288 common/asn1/asn1-ut-core.cpp \
289 common/asn1/asn1-ut-core-decode.cpp \
290 common/asn1/asn1-ut-dyntype.cpp \
291 common/asn1/asn1-ut-dyntype-decode.cpp \
292 common/asn1/asn1-ut-integer.cpp \
293 common/asn1/asn1-ut-integer-decode.cpp \
294 common/asn1/asn1-ut-null.cpp \
295 common/asn1/asn1-ut-null-decode.cpp \
296 common/asn1/asn1-ut-objid.cpp \
297 common/asn1/asn1-ut-objid-decode.cpp \
298 common/asn1/asn1-ut-octetstring.cpp \
299 common/asn1/asn1-ut-octetstring-decode.cpp \
300 common/asn1/asn1-ut-string.cpp \
301 common/asn1/asn1-ut-string-decode.cpp \
302 common/asn1/asn1-ut-time.cpp \
303 common/asn1/asn1-ut-time-decode.cpp \
304 common/checksum/adler32.cpp \
305 common/checksum/crc32.cpp \
306 common/checksum/crc32c.cpp \
307 common/checksum/crc64.cpp \
308 common/checksum/alt-md2.cpp \
309 common/checksum/alt-md5.cpp \
310 common/checksum/alt-sha1.cpp \
311 common/checksum/alt-sha256.cpp \
312 common/checksum/alt-sha512.cpp \
313 common/checksum/md2str.cpp \
314 common/checksum/md5str.cpp \
315 common/checksum/ipv4.cpp \
316 common/checksum/ipv6.cpp \
317 common/checksum/manifest.cpp \
318 common/checksum/manifest2.cpp \
319 common/checksum/manifest3.cpp \
320 common/checksum/manifest-file.cpp \
321 common/checksum/RTSha1Digest.cpp \
322 common/checksum/RTSha256Digest.cpp \
323 common/checksum/sha1str.cpp \
324 common/checksum/sha224str.cpp \
325 common/checksum/sha256str.cpp \
326 common/checksum/sha384str.cpp \
327 common/checksum/sha512str.cpp \
328 common/checksum/sha512t224str.cpp \
329 common/checksum/sha512t256str.cpp \
330 common/checksum/x509.cpp \
331 common/crypto/digest-core.cpp \
332 common/crypto/digest-builtin.cpp \
333 common/crypto/iprt-openssl.cpp \
334 common/crypto/rsa-asn1-decoder.cpp \
335 common/crypto/rsa-core.cpp \
336 common/crypto/rsa-init.cpp \
337 common/crypto/rsa-sanity.cpp \
338 common/crypto/pemfile.cpp \
339 common/crypto/pkcs7-asn1-decoder.cpp \
340 common/crypto/pkcs7-core.cpp \
341 common/crypto/pkcs7-init.cpp \
342 common/crypto/pkcs7-sanity.cpp \
343 common/crypto/pkcs7-verify.cpp \
344 common/crypto/pkix-signature-builtin.cpp \
345 common/crypto/pkix-signature-core.cpp \
346 common/crypto/pkix-signature-rsa.cpp \
347 common/crypto/pkix-util.cpp \
348 common/crypto/pkix-verify.cpp \
349 common/crypto/spc-asn1-decoder.cpp \
350 common/crypto/spc-core.cpp \
351 common/crypto/spc-init.cpp \
352 common/crypto/spc-sanity.cpp \
353 common/crypto/x509-asn1-decoder.cpp \
354 common/crypto/x509-certpaths.cpp \
355 common/crypto/x509-core.cpp \
356 common/crypto/x509-file.cpp \
357 common/crypto/x509-init.cpp \
358 common/crypto/x509-sanity.cpp \
359 common/crypto/x509-verify.cpp \
360 common/crypto/taf-asn1-decoder.cpp \
361 common/crypto/taf-core.cpp \
362 common/crypto/taf-init.cpp \
363 common/crypto/taf-sanity.cpp \
364 common/crypto/tsp-asn1-decoder.cpp \
365 common/crypto/tsp-core.cpp \
366 common/crypto/tsp-init.cpp \
367 common/crypto/tsp-sanity.cpp \
368 common/crypto/store.cpp \
369 common/crypto/store-inmem.cpp \
370 common/crypto/RTCrStoreCertAddFromFile.cpp \
371 common/crypto/RTCrStoreCertAddFromDir.cpp \
372 common/crypto/RTCrStoreCertAddFromStore.cpp \
373 common/crypto/RTCrStoreCertExportAsPem.cpp \
374 common/dbg/dbg.cpp \
375 common/dbg/dbgas.cpp \
376 common/dbg/dbgcfg.cpp \
377 common/dbg/dbgmod.cpp \
378 common/dbg/dbgmodldr.cpp \
379 common/dbg/dbgmodcontainer.cpp \
380 common/dbg/dbgmoddeferred.cpp \
381 common/dbg/dbgmodexports.cpp \
382 common/dbg/dbgmodcodeview.cpp \
383 common/dbg/dbgmoddwarf.cpp \
384 common/dbg/dbgmodnm.cpp \
385 common/dvm/dvm.cpp \
386 common/dvm/dvmbsdlabel.cpp \
387 common/dvm/dvmgpt.cpp \
388 common/dvm/dvmmbr.cpp \
389 common/dvm/dvmvfs.cpp \
390 common/err/errinfo.cpp \
391 common/err/errinfo-alloc.cpp \
392 common/err/errmsg.cpp \
393 common/err/RTErrConvertFromErrno.cpp \
394 common/err/RTErrConvertToErrno.cpp \
395 common/filesystem/filesystem.cpp \
396 common/filesystem/filesystemext.cpp \
397 common/ldr/ldr.cpp \
398 common/ldr/ldrELF.cpp \
399 common/ldr/ldrEx.cpp \
400 common/ldr/ldrFile.cpp \
401 common/ldr/ldrMemory.cpp \
402 common/ldr/ldrNative.cpp \
403 common/ldr/ldrPE.cpp \
404 common/log/log.cpp \
405 common/log/logellipsis.cpp \
406 common/log/logrel.cpp \
407 common/log/logrelellipsis.cpp \
408 common/log/logcom.cpp \
409 common/log/logformat.cpp \
410 common/log/tracebuf.cpp \
411 common/log/tracedefault.cpp \
412 common/math/bignum.cpp \
413 common/misc/RTAssertMsg1Weak.cpp \
414 common/misc/RTAssertMsg2.cpp \
415 common/misc/RTAssertMsg2Add.cpp \
416 common/misc/RTAssertMsg2AddWeak.cpp \
417 common/misc/RTAssertMsg2AddWeakV.cpp \
418 common/misc/RTAssertMsg2Weak.cpp \
419 common/misc/RTAssertMsg2WeakV.cpp \
420 common/misc/RTFileModeToFlags.cpp \
421 common/misc/RTFileOpenF.cpp \
422 common/misc/RTFileOpenV.cpp \
423 common/misc/RTMemWipeThoroughly.cpp \
424 common/misc/RTSystemIsInsideVM-amd64-x86.cpp \
425 common/misc/assert.cpp \
426 common/misc/buildconfig.cpp \
427 common/misc/cidr.cpp \
428 common/misc/getopt.cpp \
429 common/misc/getoptargv.cpp \
430 common/misc/handle.cpp \
431 common/misc/handletable.cpp \
432 common/misc/handletablectx.cpp \
433 common/misc/handletablesimple.cpp \
434 common/misc/lockvalidator.cpp \
435 common/misc/message.cpp \
436 common/misc/once.cpp \
437 common/misc/req.cpp \
438 common/misc/reqpool.cpp \
439 common/misc/reqqueue.cpp \
440 common/misc/sanity-c.c \
441 common/misc/sanity-cpp.cpp \
442 common/misc/semspingpong.cpp \
443 common/misc/sg.cpp \
444 common/misc/circbuf.cpp \
445 common/misc/thread.cpp \
446 common/misc/term.cpp \
447 common/misc/uri.cpp \
448 common/misc/zero.asm \
449 common/net/netaddrstr2.cpp \
450 common/net/macstr.cpp \
451 common/path/rtPathRootSpecLen.cpp \
452 common/path/rtPathVolumeSpecLen.cpp \
453 common/path/RTPathAbsDup.cpp \
454 common/path/RTPathAbsEx.cpp \
455 common/path/RTPathAbsExDup.cpp \
456 common/path/RTPathAppend.cpp \
457 common/path/RTPathAppendEx.cpp \
458 common/path/RTPathCalcRelative.cpp \
459 common/path/RTPathChangeToDosSlashes.cpp \
460 common/path/RTPathChangeToUnixSlashes.cpp \
461 common/path/RTPathCopyComponents.cpp \
462 common/path/RTPathCountComponents.cpp \
463 common/path/RTPathEnsureTrailingSeparator.cpp \
464 common/path/RTPathExt.cpp \
465 common/path/RTPathFilename.cpp \
466 common/path/RTPathHasExt.cpp \
467 common/path/RTPathHasPath.cpp \
468 common/path/RTPathJoin.cpp \
469 common/path/RTPathJoinA.cpp \
470 common/path/RTPathJoinEx.cpp \
471 common/path/RTPathParse.cpp \
472 common/path/RTPathParsedReassemble.cpp \
473 common/path/RTPathParseSimple.cpp \
474 common/path/RTPathRealDup.cpp \
475 common/path/RTPathRmCmd.cpp \
476 common/path/RTPathSplit.cpp \
477 common/path/RTPathSplitA.cpp \
478 common/path/RTPathSplitReassemble.cpp \
479 common/path/RTPathStartsWithRoot.cpp \
480 common/path/RTPathStripExt.cpp \
481 common/path/RTPathStripFilename.cpp \
482 common/path/RTPathStripTrailingSlash.cpp \
483 common/path/RTPathTraverseList.cpp \
484 common/path/comparepaths.cpp \
485 common/rand/rand.cpp \
486 common/rand/randadv.cpp \
487 common/rand/randparkmiller.cpp \
488 common/sort/RTSortIsSorted.cpp \
489 common/sort/RTSortApvIsSorted.cpp \
490 common/sort/shellsort.cpp \
491 common/string/RTStrCat.cpp \
492 common/string/RTStrCatEx.cpp \
493 common/string/RTStrCatP.cpp \
494 common/string/RTStrCatPEx.cpp \
495 common/string/RTStrCmp.cpp \
496 common/string/RTStrCopy.cpp \
497 common/string/RTStrCopyEx.cpp \
498 common/string/RTStrCopyP.cpp \
499 common/string/RTStrCopyPEx.cpp \
500 common/string/RTStrNCmp.cpp \
501 common/string/RTStrNLen.cpp \
502 common/string/RTStrNLenEx.cpp \
503 common/string/RTStrPrintHexBytes.cpp \
504 common/string/RTStrStr.cpp \
505 common/string/RTUtf16Copy.cpp \
506 common/string/RTUtf16CopyAscii.cpp \
507 common/string/RTUtf16Cat.cpp \
508 common/string/RTUtf16CatAscii.cpp \
509 common/string/RTUtf16CmpAscii.cpp \
510 common/string/RTUtf16ICmpAscii.cpp \
511 common/string/RTUtf16End.cpp \
512 common/string/RTUtf16NLen.cpp \
513 common/string/RTUtf16NLenEx.cpp \
514 common/string/RTUtf16PrintHexBytes.cpp \
515 common/string/base64.cpp \
516 common/string/simplepattern.cpp \
517 common/string/straprintf.cpp \
518 common/string/strformat.cpp \
519 common/string/strformatnum.cpp \
520 common/string/strformatrt.cpp \
521 common/string/strformattype.cpp \
522 common/string/strhash1.cpp \
523 common/string/stringalloc.cpp \
524 common/string/strprintf.cpp \
525 common/string/strcache.cpp \
526 common/string/strspace.cpp \
527 common/string/strstrip.cpp \
528 common/string/strtonum.cpp \
529 common/string/strversion.cpp \
530 common/string/uni.cpp \
531 common/string/unidata-flags.cpp \
532 common/string/unidata-lower.cpp \
533 common/string/unidata-upper.cpp \
534 common/string/utf-16.cpp \
535 common/string/utf-16-case.cpp \
536 common/string/utf-16-latin-1.cpp \
537 common/string/utf-8.cpp \
538 common/string/utf-8-case.cpp \
539 common/string/utf-8-case2.cpp \
540 common/string/ministring.cpp \
541 common/table/avlgcptr.cpp \
542 common/table/avlhcphys.cpp \
543 common/table/avlgcphys.cpp \
544 common/table/avllu32.cpp \
545 common/table/avlou32.cpp \
546 common/table/avlogcphys.cpp \
547 common/table/avlogcptr.cpp \
548 common/table/avlohcphys.cpp \
549 common/table/avloioport.cpp \
550 common/table/avlpv.cpp \
551 common/table/avlrgcptr.cpp \
552 common/table/avlrogcphys.cpp \
553 common/table/avlrogcptr.cpp \
554 common/table/avlroioport.cpp \
555 common/table/avlroogcptr.cpp \
556 common/table/avlrpv.cpp \
557 common/table/avlruintptr.cpp \
558 common/table/avlrfoff.cpp \
559 common/table/avlru64.cpp \
560 common/table/avlu32.cpp \
561 common/table/avluintptr.cpp \
562 common/table/avlul.cpp \
563 common/table/table.cpp \
564 common/time/time.cpp \
565 common/time/timeprog.cpp \
566 common/time/timesup.cpp \
567 common/vfs/vfsbase.cpp \
568 common/vfs/vfschain.cpp \
569 common/vfs/vfsiosmisc.cpp \
570 common/vfs/vfsmemory.cpp \
571 common/vfs/vfsmisc.cpp \
572 common/vfs/vfsstdfile.cpp \
573 common/zip/tar.cpp \
574 common/zip/tarcmd.cpp \
575 common/zip/unzipcmd.cpp \
576 common/zip/tarvfs.cpp \
577 common/zip/gzipvfs.cpp \
578 common/zip/pkzip.cpp \
579 common/zip/pkzipvfs.cpp \
580 common/zip/zip.cpp \
581 generic/createtemp-generic.cpp \
582 generic/critsect-generic.cpp \
583 generic/critsectrw-generic.cpp \
584 generic/env-generic.cpp \
585 generic/RTDirCreateUniqueNumbered-generic.cpp \
586 generic/RTEnvDupEx-generic.cpp \
587 generic/RTFileCopy-generic.cpp \
588 generic/RTFileQuerySize-generic.cpp \
589 generic/RTFileReadAll-generic.cpp \
590 generic/RTFileReadAllEx-generic.cpp \
591 generic/RTFileReadAllByHandle-generic.cpp \
592 generic/RTFileReadAllByHandleEx-generic.cpp \
593 generic/RTFileReadAllFree-generic.cpp \
594 generic/RTLogWriteStdErr-generic.cpp \
595 generic/RTLogWriteStdOut-generic.cpp \
596 generic/RTLogWriteUser-generic.cpp \
597 generic/RTPathGetCurrentDrive-generic.cpp \
598 generic/RTPathIsSame-generic.cpp \
599 generic/RTProcessQueryUsernameA-generic.cpp \
600 generic/RTTimerLRCreate-generic.cpp \
601 generic/mempool-generic.cpp \
602 generic/semfastmutex-generic.cpp \
603 generic/semxroads-generic.cpp \
604 generic/spinlock-generic.cpp \
605 generic/timerlr-generic.cpp \
606 r3/alloc-ef.cpp \
607 r3/alloc.cpp \
608 r3/allocex.cpp \
609 r3/dir.cpp \
610 r3/dir2.cpp \
611 r3/fileio.cpp \
612 r3/fs.cpp \
613 r3/init.cpp \
614 r3/isofs.cpp \
615 r3/memsafer-r3.cpp \
616 r3/path.cpp \
617 r3/poll.cpp \
618 r3/process.cpp \
619 r3/socket.cpp \
620 r3/stream.cpp \
621 r3/test.cpp \
622 r3/testi.cpp \
623 r3/tcp.cpp \
624 r3/udp.cpp \
625 r3/generic/semspinmutex-r3-generic.cpp \
626 r3/xml.cpp \
627 common/zip/xarvfs.cpp
628
629
630#if1of ($(KBUILD_TARGET_ARCH),amd64 x86)
631# RuntimeR3_SOURCES += common/time/timesupA.asm
632#else
633 RuntimeR3_SOURCES += common/time/timesupref.cpp
634#endif
635
636RuntimeR3_SOURCES.x86 += \
637 generic/RTMpGetDescription-generic.cpp
638RuntimeR3_SOURCES.amd64 += \
639 generic/RTMpGetDescription-generic.cpp
640RuntimeR3_SOURCES.sparc32 += \
641 generic/RTMpGetDescription-generic-stub.cpp \
642 common/asm/asm-fake.cpp
643RuntimeR3_SOURCES.sparc64 += \
644 generic/RTMpGetDescription-generic-stub.cpp \
645 common/asm/asm-fake.cpp
646
647ifdef IPRT_WITH_LZJB
648 RuntimeR3_SOURCES += common/misc/lzjb.c
649endif
650
651# AMD64 / x86 assembly code.
652RuntimeR3_SOURCES.x86 += \
653 common/asm/ASMCpuIdExSlow.asm \
654 common/asm/ASMAtomicUoAndU64.asm \
655 common/asm/ASMAtomicUoAndU32.asm \
656 common/asm/ASMAtomicUoDecU32.asm \
657 common/asm/ASMAtomicUoIncU32.asm \
658 common/asm/ASMAtomicUoOrU64.asm \
659 common/asm/ASMAtomicUoOrU32.asm \
660 common/asm/ASMRdMsrEx.asm \
661 common/asm/ASMWrMsrEx.asm \
662 common/asm/ASMGetXcr0.asm \
663 common/asm/ASMSetXcr0.asm \
664 common/asm/ASMXSave.asm \
665 common/asm/ASMXRstor.asm \
666 common/math/bignum-amd64-x86.asm
667RuntimeR3_SOURCES.amd64 += \
668 common/asm/ASMCpuIdExSlow.asm \
669 common/asm/ASMAtomicUoAndU64.asm \
670 common/asm/ASMAtomicUoAndU32.asm \
671 common/asm/ASMAtomicUoDecU32.asm \
672 common/asm/ASMAtomicUoIncU32.asm \
673 common/asm/ASMAtomicUoOrU64.asm \
674 common/asm/ASMAtomicUoOrU32.asm \
675 common/asm/ASMRdMsrEx.asm \
676 common/asm/ASMWrMsrEx.asm \
677 common/asm/ASMGetXcr0.asm \
678 common/asm/ASMSetXcr0.asm \
679 common/asm/ASMXSave.asm \
680 common/asm/ASMXRstor.asm \
681 common/math/bignum-amd64-x86.asm \
682 common/math/RTUInt128MulByU64.asm
683
684# Some versions of GCC might require this.
685RuntimeR3_SOURCES.x86 += \
686 common/asm/ASMAtomicXchgU64.asm \
687 common/asm/ASMAtomicCmpXchgU64.asm \
688 common/asm/ASMAtomicCmpXchgExU64.asm \
689 common/asm/ASMAtomicReadU64.asm \
690 common/asm/ASMAtomicUoReadU64.asm
691
692
693ifdef IPRT_WITH_KSTUFF
694 RuntimeR3_SOURCES += \
695 common/ldr/ldrkStuff.cpp
696endif
697
698# VBox specific stuff.
699RuntimeR3_SOURCES += \
700 VBox/RTAssertShouldPanic-vbox.cpp \
701 VBox/log-vbox.cpp
702ifneq ($(KBUILD_TARGET),win)
703RuntimeR3_SOURCES += \
704 common/err/errmsgxpcom.cpp
705endif
706if1of ($(KBUILD_TARGET),freebsd linux netbsd openbsd solaris)
707RuntimeR3_SOURCES += \
708 $(if $(VBOX_WITH_DBUS),VBox/dbus.cpp,)
709endif
710
711VBOX_WITH_NT_DIRENUM = 1
712RuntimeR3_SOURCES.win = \
713 common/dbg/dbgmoddbghelp.cpp \
714 generic/cdrom-generic.cpp \
715 generic/RTDirExists-generic.cpp \
716 generic/RTDirQueryInfo-generic.cpp \
717 generic/RTDirSetTimes-generic.cpp \
718 generic/RTFileExists-generic.cpp \
719 generic/RTMpGetCurFrequency-generic.cpp \
720 generic/RTMpGetMaxFrequency-generic.cpp \
721 generic/RTPathAbs-generic.cpp \
722 generic/RTRandAdvCreateSystemFaster-generic.cpp \
723 generic/RTRandAdvCreateSystemTruer-generic.cpp \
724 generic/RTSemEventWait-generic.cpp \
725 generic/RTSemEventMultiWait-2-ex-generic.cpp \
726 generic/RTSemEventMultiWaitNoResume-2-ex-generic.cpp \
727 generic/RTSemMutexRequest-generic.cpp \
728 generic/RTSemMutexRequestDebug-generic.cpp \
729 generic/RTThreadSetAffinityToCpu-generic.cpp \
730 generic/mppresent-generic.cpp \
731 generic/semrw-$(if-expr defined(VBOX_WITH_LOCKLESS_SEMRW),lockless-,)generic.cpp \
732 generic/uuid-generic.cpp \
733 generic/RTProcDaemonize-generic.cpp \
734 generic/RTProcIsRunningByName-generic.cpp \
735 generic/RTThreadGetNativeState-generic.cpp \
736 nt/RTErrConvertFromNtStatus.cpp \
737 r3/nt/fs-nt.cpp \
738 r3/nt/pathint-nt.cpp \
739 r3/nt/RTProcQueryParent-r3-nt.cpp \
740 r3/win/env-win.cpp \
741 r3/win/RTCrStoreCreateSnapshotById-win.cpp \
742 r3/win/RTHandleGetStandard-win.cpp \
743 r3/win/RTSystemQueryOSInfo-win.cpp \
744 r3/win/RTSystemShutdown-win.cpp \
745 r3/win/RTSystemQueryDmiString-win.cpp \
746 r3/win/RTSystemQueryTotalRam-win.cpp \
747 r3/win/alloc-win.cpp \
748 r3/win/allocex-win.cpp \
749 r3/win/dir-win.cpp \
750 $(if-expr defined(VBOX_WITH_NT_DIRENUM),r3/nt/direnum-r3-nt.cpp,r3/win/direnum-win.cpp) \
751 r3/win/errvars-win.cpp \
752 r3/win/fileio-win.cpp \
753 r3/win/init-win.cpp \
754 r3/win/ldrNative-win.cpp \
755 r3/win/localipc-win.cpp \
756 r3/win/mp-win.cpp \
757 r3/win/path-win.cpp \
758 r3/win/pipe-win.cpp \
759 r3/win/process-win.cpp \
760 r3/win/RTLogWriteDebugger-win.cpp \
761 r3/win/rtProcInitExePath-win.cpp \
762 r3/win/sched-win.cpp \
763 r3/win/semevent-win.cpp \
764 r3/win/semeventmulti-win.cpp \
765 r3/win/semmutex-win.cpp \
766 r3/win/symlink-win.cpp \
767 r3/win/rtFileNativeSetAttributes-win.cpp \
768 r3/win/thread-win.cpp \
769 r3/win/thread2-win.cpp \
770 $(if-expr 1,r3/win/time-win.cpp,r3/nt/time-nt.cpp) \
771 r3/win/time2-win.cpp \
772 r3/win/timer-win.cpp \
773 r3/win/tls-win.cpp \
774 r3/win/utf16locale-win.cpp \
775 r3/win/utf8-win.cpp \
776 r3/win/RTUuidCreate-win.cpp \
777 win/errmsgwin.cpp \
778 win/RTErrConvertFromWin32.cpp \
779 common/string/mempcpy.asm
780
781RuntimeR3_SOURCES.win.amd64 := $(RuntimeWin64ASM_SOURCES)
782RuntimeR3_SOURCES.win.x86 := $(RuntimeWin32ASM_SOURCES)
783
784RuntimeR3_SOURCES.linux = \
785 generic/cdrom-generic.cpp \
786 generic/RTCrStoreCreateSnapshotById-generic.cpp \
787 generic/RTDirQueryInfo-generic.cpp \
788 generic/RTDirSetTimes-generic.cpp \
789 generic/RTFileMove-generic.cpp \
790 generic/RTLogWriteDebugger-generic.cpp \
791 generic/RTPathAbs-generic.cpp \
792 generic/RTPathGetCurrentOnDrive-generic.cpp \
793 generic/RTProcDaemonize-generic.cpp \
794 generic/RTSemEventMultiWait-2-ex-generic.cpp \
795 generic/RTSemEventMultiWaitNoResume-2-ex-generic.cpp \
796 generic/RTTimeLocalNow-generic.cpp \
797 generic/RTTimerCreate-generic.cpp \
798 generic/RTThreadSetAffinityToCpu-generic.cpp \
799 generic/RTUuidCreate-generic.cpp \
800 generic/mppresent-generic.cpp \
801 generic/utf16locale-generic.cpp \
802 generic/uuid-generic.cpp \
803 r3/posix/allocex-r3-posix.cpp \
804 r3/linux/RTThreadGetNativeState-linux.cpp \
805 r3/linux/mp-linux.cpp \
806 r3/linux/rtProcInitExePath-linux.cpp \
807 r3/linux/sched-linux.cpp \
808 r3/linux/sysfs.cpp \
809 r3/linux/time-linux.cpp \
810 r3/linux/thread-affinity-linux.cpp \
811 r3/linux/RTProcIsRunningByName-linux.cpp \
812 r3/linux/RTSystemQueryDmiString-linux.cpp \
813 r3/linux/RTSystemShutdown-linux.cpp \
814 r3/posix/RTFileQueryFsSizes-posix.cpp \
815 r3/posix/RTHandleGetStandard-posix.cpp \
816 r3/posix/RTMemProtect-posix.cpp \
817 r3/posix/RTPathUserHome-posix.cpp \
818 r3/posix/RTSystemQueryOSInfo-posix.cpp \
819 r3/linux/systemmem-linux.cpp \
820 r3/posix/RTTimeNow-posix.cpp \
821 r3/posix/RTTimeSet-posix.cpp \
822 r3/posix/rtmempage-exec-mmap-heap-posix.cpp \
823 r3/posix/dir-posix.cpp \
824 r3/posix/env-posix.cpp \
825 r3/posix/errvars-posix.cpp \
826 r3/posix/fileio-posix.cpp \
827 r3/posix/fileio2-posix.cpp \
828 r3/posix/filelock-posix.cpp \
829 r3/posix/fs-posix.cpp \
830 r3/posix/fs2-posix.cpp \
831 r3/posix/fs3-posix.cpp \
832 r3/posix/ldrNative-posix.cpp \
833 r3/posix/path-posix.cpp \
834 r3/posix/path2-posix.cpp \
835 r3/posix/pathhost-posix.cpp \
836 r3/posix/RTPathUserDocuments-posix.cpp \
837 r3/posix/pipe-posix.cpp \
838 r3/posix/process-posix.cpp \
839 r3/posix/process-creation-posix.cpp \
840 r3/posix/rand-posix.cpp \
841 r3/posix/semrw-posix.cpp \
842 r3/posix/symlink-posix.cpp \
843 r3/posix/thread-posix.cpp \
844 r3/posix/thread2-posix.cpp \
845 r3/posix/timelocal-posix.cpp \
846 r3/posix/timer-posix.cpp \
847 r3/posix/tls-posix.cpp \
848 r3/posix/utf8-posix.cpp
849ifdef IPRT_WITH_FUTEX_BASED_SEMS
850 RuntimeR3_SOURCES.linux += \
851 r3/linux/semevent-linux.cpp \
852 r3/linux/semeventmulti-linux.cpp \
853 r3/linux/semmutex-linux.cpp
854else
855 RuntimeR3_SOURCES.linux.x86 += \
856 r3/posix/semevent-posix.cpp \
857 r3/posix/semeventmulti-posix.cpp \
858 r3/posix/semmutex-posix.cpp
859 RuntimeR3_SOURCES.linux.amd64 += \
860 r3/linux/semevent-linux.cpp \
861 r3/linux/semeventmulti-linux.cpp
862 ifdef RT_NEW_LINUX_MUTEX_CODE
863 RuntimeR3_SOURCES.linux.amd64 += \
864 r3/linux/semmutex-linux.cpp
865 else
866 RuntimeR3_SOURCES.linux.amd64 += \
867 r3/posix/semmutex-posix.cpp
868 endif
869endif
870
871RuntimeR3_SOURCES.os2 = \
872 generic/cdrom-generic.cpp \
873 generic/RTCrStoreCreateSnapshotById-generic.cpp \
874 generic/RTDirQueryInfo-generic.cpp \
875 generic/RTDirSetTimes-generic.cpp \
876 generic/RTFileMove-generic.cpp \
877 generic/RTLogWriteDebugger-generic.cpp \
878 generic/RTPathAbs-generic.cpp \
879 generic/RTPathGetCurrentOnDrive-generic.cpp \
880 generic/RTProcDaemonize-generic.cpp \
881 generic/RTRandAdvCreateSystemFaster-generic.cpp \
882 generic/RTRandAdvCreateSystemTruer-generic.cpp \
883 generic/RTSystemQueryDmiString-generic.cpp \
884 generic/RTSystemShutdown-generic.cpp \
885 generic/RTTimeLocalNow-generic.cpp \
886 generic/RTTimerCreate-generic.cpp \
887 generic/RTThreadSetAffinityToCpu-generic.cpp \
888 generic/RTUuidCreate-generic.cpp \
889 generic/mppresent-generic.cpp \
890 generic/RTSemEventWait-generic.cpp \
891 generic/RTSemEventMultiWait-generic.cpp \
892 generic/RTSemMutexRequest-generic.cpp \
893 generic/RTSemMutexRequestDebug-generic.cpp \
894 generic/semrw-$(if-expr defined(VBOX_WITH_LOCKLESS_SEMRW),lockless-,)generic.cpp \
895 generic/timer-generic.cpp \
896 generic/utf16locale-generic.cpp \
897 generic/uuid-generic.cpp \
898 generic/RTMpGetCoreCount-generic.cpp \
899 generic/RTMpGetOnlineCoreCount-generic.cpp \
900 generic/RTMpGetCurFrequency-generic.cpp \
901 generic/RTMpGetMaxFrequency-generic.cpp \
902 generic/RTProcIsRunningByName-generic.cpp \
903 generic/RTThreadGetNativeState-generic.cpp \
904 os2/RTErrConvertFromOS2.cpp \
905 r3/generic/allocex-r3-generic.cpp \
906 r3/os2/filelock-os2.cpp \
907 r3/os2/mp-os2.cpp \
908 r3/os2/pipe-os2.cpp \
909 r3/os2/rtProcInitExePath-os2.cpp \
910 r3/os2/sched-os2.cpp \
911 r3/os2/sems-os2.cpp \
912 r3/os2/systemmem-os2.cpp \
913 r3/os2/thread-os2.cpp \
914 r3/os2/time-os2.cpp \
915 r3/posix/RTFileQueryFsSizes-posix.cpp \
916 r3/posix/RTHandleGetStandard-posix.cpp \
917 r3/posix/RTMemProtect-posix.cpp \
918 r3/posix/RTPathUserHome-posix.cpp \
919 r3/posix/RTSystemQueryOSInfo-posix.cpp \
920 r3/posix/RTTimeNow-posix.cpp \
921 r3/posix/RTTimeSet-posix.cpp \
922 r3/posix/dir-posix.cpp \
923 r3/posix/env-posix.cpp \
924 r3/posix/errvars-posix.cpp \
925 r3/posix/fileio-posix.cpp \
926 r3/posix/fileio2-posix.cpp \
927 r3/posix/fs-posix.cpp \
928 r3/posix/fs2-posix.cpp \
929 r3/posix/fs3-posix.cpp \
930 r3/posix/ldrNative-posix.cpp \
931 r3/posix/path-posix.cpp \
932 r3/posix/path2-posix.cpp \
933 r3/posix/pathhost-posix.cpp \
934 r3/posix/rtmempage-exec-mmap-heap-posix.cpp \
935 r3/posix/RTPathUserDocuments-posix.cpp \
936 r3/posix/process-posix.cpp \
937 r3/posix/process-creation-posix.cpp \
938 r3/posix/symlink-posix.cpp \
939 r3/posix/timelocal-posix.cpp \
940 r3/posix/utf8-posix.cpp
941
942RuntimeR3_SOURCES.darwin = \
943 darwin/RTErrConvertFromDarwin.cpp \
944 darwin/RTErrConvertFromDarwinCOM.cpp \
945 darwin/RTErrConvertFromDarwinIO.cpp \
946 darwin/RTErrConvertFromDarwinKern.cpp \
947 generic/cdrom-generic.cpp \
948 generic/RTDirQueryInfo-generic.cpp \
949 generic/RTDirSetTimes-generic.cpp \
950 generic/RTFileMove-generic.cpp \
951 generic/RTLogWriteDebugger-generic.cpp \
952 generic/RTPathAbs-generic.cpp \
953 generic/RTPathGetCurrentOnDrive-generic.cpp \
954 generic/RTProcDaemonize-generic.cpp \
955 generic/RTThreadGetAffinity-stub-generic.cpp \
956 generic/RTThreadSetAffinity-stub-generic.cpp \
957 generic/RTThreadSetAffinityToCpu-generic.cpp \
958 generic/RTTimeLocalNow-generic.cpp \
959 generic/RTTimerCreate-generic.cpp \
960 generic/RTUuidCreate-generic.cpp \
961 generic/mppresent-generic.cpp \
962 generic/RTMpGetOnlineCoreCount-generic.cpp \
963 generic/RTSemEventMultiWait-2-ex-generic.cpp \
964 generic/RTSemEventMultiWaitNoResume-2-ex-generic.cpp \
965 generic/semrw-$(if-expr defined(VBOX_WITH_LOCKLESS_SEMRW),lockless-,)generic.cpp \
966 generic/RTSystemShutdown-generic.cpp \
967 generic/timer-generic.cpp \
968 generic/utf16locale-generic.cpp \
969 generic/uuid-generic.cpp\
970 generic/RTProcIsRunningByName-generic.cpp \
971 generic/RTThreadGetNativeState-generic.cpp \
972 r3/darwin/RTCrStoreCreateSnapshotById-darwin.cpp \
973 r3/darwin/filelock-darwin.cpp \
974 r3/darwin/mp-darwin.cpp \
975 r3/darwin/pathhost-darwin.cpp \
976 r3/darwin/rtProcInitExePath-darwin.cpp \
977 r3/darwin/RTSystemQueryDmiString-darwin.cpp \
978 r3/darwin/sched-darwin.cpp \
979 r3/darwin/systemmem-darwin.cpp \
980 r3/darwin/time-darwin.cpp \
981 r3/darwin/RTPathUserDocuments-darwin.cpp \
982 r3/generic/allocex-r3-generic.cpp \
983 r3/posix/RTFileQueryFsSizes-posix.cpp \
984 r3/posix/RTHandleGetStandard-posix.cpp \
985 r3/posix/RTMemProtect-posix.cpp \
986 r3/posix/RTPathUserHome-posix.cpp \
987 r3/posix/RTSystemQueryOSInfo-posix.cpp \
988 r3/posix/RTTimeSet-posix.cpp \
989 r3/posix/dir-posix.cpp \
990 r3/posix/env-posix.cpp \
991 r3/posix/errvars-posix.cpp \
992 r3/posix/fileio-posix.cpp \
993 r3/posix/fileio2-posix.cpp \
994 r3/posix/fs-posix.cpp \
995 r3/posix/fs2-posix.cpp \
996 r3/posix/fs3-posix.cpp \
997 r3/posix/ldrNative-posix.cpp \
998 r3/posix/rtmempage-exec-mmap-heap-posix.cpp \
999 r3/posix/path-posix.cpp \
1000 r3/posix/path2-posix.cpp \
1001 r3/posix/pipe-posix.cpp \
1002 r3/posix/process-posix.cpp \
1003 r3/posix/process-creation-posix.cpp \
1004 r3/posix/rand-posix.cpp \
1005 r3/posix/semevent-posix.cpp \
1006 r3/posix/semeventmulti-posix.cpp \
1007 r3/posix/semmutex-posix.cpp \
1008 r3/posix/symlink-posix.cpp \
1009 r3/posix/thread-posix.cpp \
1010 r3/posix/thread2-posix.cpp \
1011 r3/posix/timelocal-posix.cpp \
1012 r3/posix/tls-posix.cpp \
1013 r3/posix/utf8-posix.cpp
1014
1015## @todo Make BSD sched, implement RTMP*.
1016RuntimeR3_SOURCES.freebsd = \
1017 generic/cdrom-generic.cpp \
1018 generic/RTCrStoreCreateSnapshotById-generic.cpp \
1019 generic/RTDirQueryInfo-generic.cpp \
1020 generic/RTDirSetTimes-generic.cpp \
1021 generic/RTFileMove-generic.cpp \
1022 generic/RTLogWriteDebugger-generic.cpp \
1023 generic/RTPathAbs-generic.cpp \
1024 generic/RTPathGetCurrentOnDrive-generic.cpp \
1025 generic/RTSemEventMultiWait-2-ex-generic.cpp \
1026 generic/RTSemEventMultiWaitNoResume-2-ex-generic.cpp \
1027 generic/RTSystemQueryDmiString-generic.cpp \
1028 generic/RTSystemShutdown-generic.cpp \
1029 generic/RTThreadGetAffinity-stub-generic.cpp \
1030 generic/RTThreadSetAffinity-stub-generic.cpp \
1031 generic/RTThreadSetAffinityToCpu-generic.cpp \
1032 generic/RTTimeLocalNow-generic.cpp \
1033 generic/RTTimerCreate-generic.cpp \
1034 generic/RTUuidCreate-generic.cpp \
1035 generic/mppresent-generic.cpp \
1036 generic/sched-generic.cpp \
1037 generic/utf16locale-generic.cpp \
1038 generic/uuid-generic.cpp \
1039 generic/RTMpCpuId-generic.cpp \
1040 generic/RTMpGetCoreCount-generic.cpp \
1041 generic/RTMpGetOnlineCoreCount-generic.cpp \
1042 generic/RTProcDaemonize-generic.cpp \
1043 generic/RTProcIsRunningByName-generic.cpp \
1044 generic/RTThreadGetNativeState-generic.cpp \
1045 r3/freebsd/mp-freebsd.cpp \
1046 r3/freebsd/systemmem-freebsd.cpp \
1047 r3/freebsd/rtProcInitExePath-freebsd.cpp \
1048 r3/generic/allocex-r3-generic.cpp \
1049 r3/posix/RTFileQueryFsSizes-posix.cpp \
1050 r3/posix/RTHandleGetStandard-posix.cpp \
1051 r3/posix/RTMemProtect-posix.cpp \
1052 r3/posix/RTPathUserHome-posix.cpp \
1053 r3/posix/RTSystemQueryOSInfo-posix.cpp \
1054 r3/posix/RTTimeNow-posix.cpp \
1055 r3/posix/RTTimeSet-posix.cpp \
1056 r3/posix/dir-posix.cpp \
1057 r3/posix/env-posix.cpp \
1058 r3/posix/errvars-posix.cpp \
1059 r3/posix/fileio-posix.cpp \
1060 r3/posix/fileio2-posix.cpp \
1061 r3/posix/filelock-posix.cpp \
1062 r3/posix/fs-posix.cpp \
1063 r3/posix/fs2-posix.cpp \
1064 r3/posix/fs3-posix.cpp \
1065 r3/posix/ldrNative-posix.cpp \
1066 r3/posix/rtmempage-exec-mmap-heap-posix.cpp \
1067 r3/posix/path-posix.cpp \
1068 r3/posix/path2-posix.cpp \
1069 r3/posix/pathhost-posix.cpp \
1070 r3/posix/RTPathUserDocuments-posix.cpp \
1071 r3/posix/pipe-posix.cpp \
1072 r3/posix/process-posix.cpp \
1073 r3/posix/process-creation-posix.cpp \
1074 r3/posix/rand-posix.cpp \
1075 r3/posix/semevent-posix.cpp \
1076 r3/posix/semeventmulti-posix.cpp \
1077 r3/posix/semmutex-posix.cpp \
1078 r3/posix/semrw-posix.cpp \
1079 r3/posix/symlink-posix.cpp \
1080 r3/posix/thread-posix.cpp \
1081 r3/posix/thread2-posix.cpp \
1082 r3/posix/time-posix.cpp \
1083 r3/posix/timelocal-posix.cpp \
1084 r3/posix/timer-posix.cpp \
1085 r3/posix/tls-posix.cpp \
1086 r3/posix/utf8-posix.cpp
1087
1088RuntimeR3_SOURCES.solaris = \
1089 generic/cdrom-generic.cpp \
1090 generic/RTCrStoreCreateSnapshotById-generic.cpp \
1091 generic/RTDirQueryInfo-generic.cpp \
1092 generic/RTDirSetTimes-generic.cpp \
1093 generic/RTFileMove-generic.cpp \
1094 generic/RTLogWriteDebugger-generic.cpp \
1095 generic/RTPathAbs-generic.cpp \
1096 generic/RTPathGetCurrentOnDrive-generic.cpp \
1097 generic/RTProcDaemonize-generic.cpp \
1098 generic/RTProcIsRunningByName-generic.cpp \
1099 generic/RTSemEventMultiWait-2-ex-generic.cpp \
1100 generic/RTSemEventMultiWaitNoResume-2-ex-generic.cpp \
1101 generic/RTThreadSetAffinityToCpu-generic.cpp \
1102 generic/RTTimeLocalNow-generic.cpp \
1103 generic/RTTimerCreate-generic.cpp \
1104 generic/RTUuidCreate-generic.cpp \
1105 generic/sched-generic.cpp \
1106 generic/utf16locale-generic.cpp \
1107 generic/uuid-generic.cpp \
1108 generic/RTThreadGetNativeState-generic.cpp \
1109 r3/generic/allocex-r3-generic.cpp \
1110 r3/posix/RTFileQueryFsSizes-posix.cpp \
1111 r3/posix/RTHandleGetStandard-posix.cpp \
1112 r3/posix/RTMemProtect-posix.cpp \
1113 r3/posix/RTPathUserHome-posix.cpp \
1114 r3/posix/RTSystemQueryOSInfo-posix.cpp \
1115 r3/posix/RTTimeNow-posix.cpp \
1116 r3/posix/RTTimeSet-posix.cpp \
1117 r3/posix/dir-posix.cpp \
1118 r3/posix/env-posix.cpp \
1119 r3/posix/errvars-posix.cpp \
1120 r3/posix/fileio-posix.cpp \
1121 r3/posix/fileio2-posix.cpp \
1122 r3/posix/filelock-posix.cpp \
1123 r3/posix/fs-posix.cpp \
1124 r3/posix/fs2-posix.cpp \
1125 r3/posix/fs3-posix.cpp \
1126 r3/posix/ldrNative-posix.cpp \
1127 r3/posix/rtmempage-exec-mmap-heap-posix.cpp \
1128 r3/posix/path-posix.cpp \
1129 r3/posix/path2-posix.cpp \
1130 r3/posix/pathhost-posix.cpp \
1131 r3/posix/RTPathUserDocuments-posix.cpp \
1132 r3/posix/pipe-posix.cpp \
1133 r3/posix/process-posix.cpp \
1134 r3/posix/process-creation-posix.cpp \
1135 r3/posix/rand-posix.cpp \
1136 r3/posix/semevent-posix.cpp \
1137 r3/posix/semeventmulti-posix.cpp \
1138 r3/posix/semmutex-posix.cpp \
1139 r3/posix/semrw-posix.cpp \
1140 r3/posix/symlink-posix.cpp \
1141 r3/posix/thread-posix.cpp \
1142 r3/posix/thread2-posix.cpp \
1143 r3/posix/time-posix.cpp \
1144 r3/posix/timelocal-posix.cpp \
1145 r3/posix/timer-posix.cpp \
1146 r3/posix/tls-posix.cpp \
1147 r3/posix/utf8-posix.cpp \
1148 r3/solaris/systemmem-solaris.cpp \
1149 r3/solaris/mp-solaris.cpp \
1150 r3/solaris/rtProcInitExePath-solaris.cpp \
1151 r3/solaris/RTSystemShutdown-solaris.cpp \
1152 r3/solaris/thread-affinity-solaris.cpp
1153RuntimeR3_SOURCES.solaris.amd64 = \
1154 r3/solaris/coredumper-solaris.cpp \
1155 r3/solaris/RTSystemQueryDmiString-solaris.cpp
1156RuntimeR3_SOURCES.solaris.x86 = \
1157 r3/solaris/coredumper-solaris.cpp \
1158 r3/solaris/RTSystemQueryDmiString-solaris.cpp
1159RuntimeR3_SOURCES.solaris.sparc32 = \
1160 generic/RTSystemQueryDmiString-generic.cpp
1161RuntimeR3_SOURCES.solaris.sparc64 = \
1162 generic/RTSystemQueryDmiString-generic.cpp
1163
1164RuntimeR3_SOURCES.haiku = \
1165 generic/RTCrStoreCreateSnapshotById-generic.cpp \
1166 generic/RTDirQueryInfo-generic.cpp \
1167 generic/RTDirSetTimes-generic.cpp \
1168 generic/RTFileMove-generic.cpp \
1169 generic/RTLogWriteDebugger-generic.cpp \
1170 generic/RTPathAbs-generic.cpp \
1171 generic/RTPathGetCurrentOnDrive-generic.cpp \
1172 generic/RTProcDaemonize-generic.cpp \
1173 generic/RTTimeLocalNow-generic.cpp \
1174 generic/RTTimerCreate-generic.cpp \
1175 generic/RTUuidCreate-generic.cpp \
1176 generic/mppresent-generic.cpp \
1177 generic/RTSemEventMultiWait-2-ex-generic.cpp \
1178 generic/RTSemEventMultiWaitNoResume-2-ex-generic.cpp \
1179 generic/sched-generic.cpp \
1180 generic/semrw-$(if-expr defined(VBOX_WITH_LOCKLESS_SEMRW),ockless-,)generic.cpp \
1181 generic/timer-generic.cpp \
1182 generic/utf16locale-generic.cpp \
1183 generic/uuid-generic.cpp\
1184 generic/RTProcIsRunningByName-generic.cpp \
1185 generic/RTThreadGetNativeState-generic.cpp \
1186 generic/RTMpGetCoreCount-generic.cpp \
1187 generic/RTMpGetOnlineCoreCount-generic.cpp \
1188 r3/haiku/rtProcInitExePath-haiku.cpp \
1189 r3/haiku/time-haiku.cpp \
1190 r3/generic/allocex-r3-generic.cpp \
1191 r3/posix/RTFileQueryFsSizes-posix.cpp \
1192 r3/posix/RTHandleGetStandard-posix.cpp \
1193 r3/posix/RTMemProtect-posix.cpp \
1194 r3/posix/RTPathUserHome-posix.cpp \
1195 r3/posix/RTSystemQueryOSInfo-posix.cpp \
1196 r3/posix/RTSystemQueryTotalRam-posix.cpp \
1197 r3/posix/RTTimeNow-posix.cpp \
1198 r3/posix/dir-posix.cpp \
1199 r3/posix/env-posix.cpp \
1200 r3/posix/errvars-posix.cpp \
1201 r3/posix/fileio-posix.cpp \
1202 r3/posix/fileio2-posix.cpp \
1203 r3/posix/filelock-posix.cpp \
1204 r3/posix/fs-posix.cpp \
1205 r3/posix/fs2-posix.cpp \
1206 r3/posix/fs3-posix.cpp \
1207 r3/posix/ldrNative-posix.cpp \
1208 r3/posix/rtmempage-exec-mmap-heap-posix.cpp \
1209 r3/posix/path-posix.cpp \
1210 r3/posix/path2-posix.cpp \
1211 r3/posix/pathhost-posix.cpp \
1212 r3/posix/pipe-posix.cpp \
1213 r3/posix/process-posix.cpp \
1214 r3/posix/process-creation-posix.cpp \
1215 r3/posix/rand-posix.cpp \
1216 r3/posix/semevent-posix.cpp \
1217 r3/posix/semeventmulti-posix.cpp \
1218 r3/posix/semmutex-posix.cpp \
1219 r3/posix/symlink-posix.cpp \
1220 r3/posix/thread-posix.cpp \
1221 r3/posix/thread2-posix.cpp \
1222 r3/posix/timelocal-posix.cpp \
1223 r3/posix/tls-posix.cpp \
1224 r3/posix/utf8-posix.cpp
1225
1226## PORTME: Porters add their selection of platform specific files for Ring-3 here.
1227
1228
1229#
1230# RuntimeBldProg - Static Runtime for build programs.
1231#
1232# Note! This is a bit of hacky since kBuild doesn't support building libraries
1233# for build programs.
1234#
1235RuntimeBldProg_TEMPLATE := VBoxAdvBldProg
1236RuntimeBldProg_EXTENDS := RuntimeR3
1237RuntimeBldProg_BLD_TRG := $(KBUILD_HOST)
1238RuntimeBldProg_BLD_TRG_ARCH := $(KBUILD_HOST_ARCH)
1239RuntimeBldProg_BLD_TRG_CPU := $(KBUILD_HOST_CPU)
1240RuntimeBldProg_DEFS := $(filter-out IN_SUP_R3 IN_SUP, $(RuntimeR3_DEFS)) IPRT_WITHOUT_LDR_VERIFY RT_NO_GIP
1241RuntimeBldProg_SOURCES = $(filter-out \
1242 r3/xml.cpp \
1243 common/zip/xarvfs.cpp \
1244 , $(RuntimeR3_SOURCES))
1245if "$(KBUILD_TARGET)" == "win" && "$(KBUILD_HOST)" != "win"
1246RuntimeBldProg_SOURCES += \
1247 common/err/errmsgxpcom.cpp
1248endif
1249
1250
1251
1252#
1253# RuntimeGuestR3 - Guest Additions Runtime (static/exe).
1254# (The KBUILD_HOST inheritance here is for cross building the linux
1255# additions, while .x86 is for cross building x86 while targeting amd64.)
1256#
1257RuntimeGuestR3_TEMPLATE := VBoxGuestR3Lib
1258## @todo change this to EXTEND the RuntimeR3 target.
1259RuntimeGuestR3_SDKS.win := $(RuntimeR3_SDKS.win)
1260RuntimeGuestR3_DEFS := $(filter-out RTCRITSECT_STRICT RT_NO_GIP IPRT_WITH_OPENSSL, $(RuntimeR3_DEFS))
1261RuntimeGuestR3_DEFS.$(KBUILD_TARGET) := $(RuntimeR3_DEFS.$(KBUILD_TARGET))
1262RuntimeGuestR3_DEFS.$(KBUILD_HOST) := $(RuntimeR3_DEFS.$(KBUILD_HOST))
1263RuntimeGuestR3_INCS := $(RuntimeR3_INCS)
1264RuntimeGuestR3_INCS.$(KBUILD_TARGET) := $(RuntimeR3_INCS.$(KBUILD_TARGET))
1265RuntimeGuestR3_INCS.$(KBUILD_HOST) := $(RuntimeR3_INCS.$(KBUILD_HOST))
1266RuntimeGuestR3_SOURCES := $(filter-out \
1267 common/time/timesupref.cpp \
1268 common/time/timesupA.asm \
1269 common/time/timesup.cpp \
1270 common/checksum/x509.cpp \
1271 generic/RTLogWriteUser-generic.cpp \
1272 r3/xml.cpp \
1273 common/zip/xarvfs.cpp \
1274 , $(RuntimeR3_SOURCES))
1275RuntimeGuestR3_SOURCES += \
1276 common/time/timesysalias.cpp \
1277 VBox/logbackdoor.cpp
1278RuntimeGuestR3_SOURCES.$(KBUILD_TARGET) := $(RuntimeR3_SOURCES.$(KBUILD_TARGET))
1279RuntimeGuestR3_SOURCES.$(KBUILD_HOST) := $(RuntimeR3_SOURCES.$(KBUILD_HOST))
1280RuntimeGuestR3_SOURCES.$(KBUILD_TARGET_ARCH) := $(RuntimeR3_SOURCES.$(KBUILD_TARGET_ARCH))
1281RuntimeGuestR3_SOURCES.x86 := $(RuntimeR3_SOURCES.x86)
1282RuntimeGuestR3_SOURCES.amd64 := $(RuntimeR3_SOURCES.amd64)
1283RuntimeGuestR3_SOURCES.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH) := $(RuntimeR3_SOURCES.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH))
1284RuntimeGuestR3_SOURCES.$(KBUILD_TARGET).x86 := $(RuntimeR3_SOURCES.$(KBUILD_TARGET).x86)
1285RuntimeGuestR3_SOURCES.$(KBUILD_TARGET).amd64:= $(RuntimeR3_SOURCES.$(KBUILD_TARGET).amd64)
1286RuntimeGuestR3_SOURCES.$(KBUILD_HOST).$(KBUILD_TARGET_ARCH) := $(RuntimeR3_SOURCES.$(KBUILD_HOST).$(KBUILD_TARGET_ARCH))
1287RuntimeGuestR3_SOURCES.win.x86 += \
1288 r3/win/vcc100-kernel32-fakes.cpp \
1289 r3/win/vcc100-kernel32-fakesA.asm
1290
1291#
1292# RuntimeGuestR3-x86 - Same as RuntimeGuestR3, except that it's targeting x86.
1293#
1294RuntimeGuestR3-x86_EXTENDS := RuntimeGuestR3
1295RuntimeGuestR3-x86_BLD_TRG_ARCH := x86
1296
1297
1298#
1299# RuntimeGuestR3Shared - Guest Additions Runtime (static/dll).
1300#
1301RuntimeGuestR3Shared_TEMPLATE := VBoxGuestR3Dll
1302RuntimeGuestR3Shared_EXTENDS := RuntimeGuestR3
1303RuntimeGuestR3Shared_INST = $(INST_ADDITIONS_LIB)
1304
1305
1306#
1307# RuntimeGuestR3Shared-x86 - Same as RuntimeGuestR3Shared, except that it's targeting x86.
1308#
1309RuntimeGuestR3Shared-x86_EXTENDS := RuntimeGuestR3Shared
1310RuntimeGuestR3Shared-x86_BLD_TRG_ARCH := x86
1311
1312
1313#
1314# VBoxRT - Shared Object / DLL version.
1315#
1316VBoxRT_TEMPLATE = VBoxR3DllNoPic
1317VBoxRT_SDKS = VBOX_LIBXML2
1318ifdef VBOX_WITH_LIBCURL
1319 VBoxRT_SDKS += VBOX_LIBCURL
1320endif
1321VBoxRT_SDKS += VBOX_OPENSSL
1322VBoxRT_SDKS.win = $(VBOX_WINPSDK) $(VBOX_WINDDK) VBOX_NTDLL
1323if1of ($(KBUILD_TARGET)$(VBOX_WITH_HARDENING), darwin win$(VBOX_WITH_HARDENING))
1324VBoxRT_INST = $(INST_DLL) $(INST_TESTCASE)
1325endif
1326VBoxRT_DEFS := $(filter-out RT_NO_GIP, $(RuntimeR3_DEFS)) \
1327 IN_SUP_R3 IN_SUP_R3 IPRT_WITH_XAR \
1328 $(if-expr !defined(VBOX_WITH_ALT_HASH_CODE),IPRT_WITHOUT_SHA512T224 IPRT_WITHOUT_SHA512T256,)
1329ifn1of ($(KBUILD_TARGET_ARCH), amd64 x86)
1330 VBoxRT_DEFS += RT_NO_GIP
1331endif
1332ifdef VBOX_WITH_LIBCURL
1333 VBoxRT_DEFS += IPRT_WITH_HTTP
1334endif
1335ifdef RTALLOC_REPLACE_MALLOC
1336 VBoxRT_DEFS += RTALLOC_REPLACE_MALLOC
1337endif
1338VBoxRT_DEFS.$(KBUILD_TYPE) := $(RuntimeR3_DEFS.$(KBUILD_TYPE))
1339VBoxRT_SOURCES := \
1340 VBox/VBoxRTDeps.cpp \
1341 $(filter-out common/checksum/crc32.cpp, \
1342 $(if-expr defined(VBOX_WITH_ALT_HASH_CODE), $(RuntimeR3_SOURCES), \
1343 $(patsubst common/checksum/alt-%,common/checksum/openssl-%,$(RuntimeR3_SOURCES)) ) ) \
1344 common/checksum/crc32-zlib.cpp \
1345 common/misc/aiomgr.cpp
1346ifdef VBOX_WITH_LIBCURL
1347 VBoxRT_SOURCES += common/misc/s3.cpp
1348 VBoxRT_SOURCES += common/misc/http.cpp
1349endif
1350VBoxRT_SOURCES.$(KBUILD_TARGET) = $(RuntimeR3_SOURCES.$(KBUILD_TARGET))
1351VBoxRT_SOURCES.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH) := $(RuntimeR3_SOURCES.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH))
1352VBoxRT_SOURCES.$(KBUILD_TARGET).x86 := $(RuntimeR3_SOURCES.$(KBUILD_TARGET).x86)
1353VBoxRT_SOURCES.$(KBUILD_TARGET).amd64 := $(RuntimeR3_SOURCES.$(KBUILD_TARGET).amd64)
1354VBoxRT_SOURCES.$(KBUILD_TARGET_ARCH) := $(RuntimeR3_SOURCES.$(KBUILD_TARGET_ARCH))
1355VBoxRT_SOURCES.x86 := $(RuntimeR3_SOURCES.x86)
1356VBoxRT_SOURCES.amd64 := $(RuntimeR3_SOURCES.amd64)
1357VBoxRT_SOURCES.win += \
1358 r3/win/dllmain-win.cpp \
1359 r3/win/fileaio-win.cpp \
1360 $(VBoxRT_0_OUTDIR)/VBoxRT.def
1361VBoxRT_SOURCES.linux += \
1362 r3/linux/fileaio-linux.cpp
1363VBoxRT_SOURCES.solaris += \
1364 r3/solaris/fileaio-solaris.cpp
1365VBoxRT_SOURCES.darwin += \
1366 r3/posix/fileaio-posix.cpp
1367VBoxRT_SOURCES.freebsd += \
1368 r3/freebsd/fileaio-freebsd.cpp
1369VBoxRT_INCS := $(RuntimeR3_INCS)
1370VBoxRT_INCS.$(KBUILD_TARGET) := $(RuntimeR3_INCS.$(KBUILD_TARGET))
1371VBoxRT_INCS.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH) := $(RuntimeR3_INCS.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH))
1372VBoxRT_LIBS = \
1373 $(PATH_STAGE_LIB)/VBox-liblzf$(VBOX_SUFF_LIB)
1374if1of ($(KBUILD_TARGET_ARCH), amd64 x86)
1375VBoxRT_LIBS += \
1376 $(PATH_STAGE_LIB)/SUPR3$(VBOX_SUFF_LIB)
1377endif
1378ifdef IPRT_WITH_KSTUFF
1379 VBoxRT_LIBS += \
1380 $(PATH_STAGE_LIB)/VBox-kStuff$(VBOX_SUFF_LIB)
1381endif
1382ifndef SDK_VBOX_LIBXML2_LIBS
1383 VBoxRT_LIBS += \
1384 $(PATH_STAGE_LIB)/VBox-libxml2$(VBOX_SUFF_LIB)
1385endif
1386VBoxRT_LIBS += \
1387 $(SDK_VBOX_ZLIB_LIBS)
1388ifndef SDK_VBOX_OPENSSL_LIBS
1389 VBoxRT_LIBS += \
1390 $(PATH_STAGE_LIB)/VBox-libcrypto$(VBOX_SUFF_LIB) \
1391 $(PATH_STAGE_LIB)/VBox-libssl$(VBOX_SUFF_LIB)
1392endif
1393ifdef IPRT_WITH_LZO
1394 VBoxRT_LIBS += lzo2
1395endif
1396ifdef RTALLOC_REPLACE_MALLOC
1397VBoxRT_LIBS += \
1398 $(PATH_STAGE_LIB)/DisasmR3$(VBOX_SUFF_LIB)
1399endif
1400VBoxRT_LIBS.linux = \
1401 crypt
1402VBoxRT_LIBS.darwin = \
1403 iconv
1404VBoxRT_LIBS.freebsd = \
1405 iconv \
1406 rt
1407VBoxRT_LIBS.haiku = \
1408 iconv
1409VBoxRT_LIBS.solaris = \
1410 kstat \
1411 contract
1412ifn1of ($(KBUILD_TARGET_ARCH), sparc32 sparc64)
1413 # SMBIOS not available on Solaris SPARC.
1414 VBoxRT_LIBS.solaris += smbios
1415endif
1416VBoxRT_LIBS.win = \
1417 $(PATH_SDK_$(VBOX_WINDDK)_LIB)/vccomsup.lib \
1418 $(PATH_SDK_$(VBOX_WINDDK)_LIB)/wbemuuid.lib \
1419 $(PATH_TOOL_$(VBOX_VCC_TOOL)_LIB)/delayimp.lib
1420VBoxRT_LDFLAGS.darwin = \
1421 -framework IOKit \
1422 -framework CoreFoundation \
1423 -framework CoreServices \
1424 -framework Security \
1425 -install_name $(VBOX_DYLD_EXECUTABLE_PATH)/VBoxRT.dylib
1426VBoxRT_LDFLAGS.win = /MANIFEST \
1427 /delayload:gdi32.dll \
1428 /delayload:user32.dll \
1429 /delayload:shell32.dll \
1430 /delayload:ole32.dll \
1431 /delayload:oleaut32.dll \
1432 /delayload:advapi32.dll
1433
1434if1of ($(DLLS), VBoxRT)
1435$$(VBoxRT_0_OUTDIR)/VBoxRT.def: \
1436 $(PATH_SUB_CURRENT)/r3/win/VBoxRT-$$(if-expr $$(KBUILD_TARGET_ARCH) == amd64,win64,win32).def \
1437 $(PATH_SUB_CURRENT)/r3/win/$(if $(VBOX_OSE),VBoxRT-openssl-ose.def,VBoxRT-openssl.def)
1438 $(RM) -f -- $@
1439 $(REDIRECT) -wto $@ -- $(CAT_EXT) $^
1440endif
1441
1442if1of (VBoxRT,$(DLLS))
1443 $(call VBOX_SET_VER_INFO_DLL,VBoxRT,VirtualBox Runtime)
1444endif
1445
1446
1447#
1448# HACK ALERT! Make testcase run during build on SELinux boxes.
1449# Create a dummy DLL that ensure that VBoxRT is installed
1450# during the DLL pass and cleaned up later.
1451#
1452ifeq ($(KBUILD_TARGET),linux)
1453 if1of (VBoxRT, $(DLLS))
1454 ifneq ($(wildcard /usr/bin/chcon),)
1455VBoxRT_INSTTYPE = none
1456VBoxRT_DEBUG_INSTTYPE = both
1457
1458DLLS += VBoxRTDummy
1459VBoxRTDummy_TEMPLATE = VBoxR3Dll
1460VBoxRTDummy_INSTTYPE = none
1461VBoxRTDummy_LIBS = $(PATH_STAGE_BIN)/VBoxRT.so
1462VBoxRTDummy_CLEAN = $(PATH_STAGE_BIN)/VBoxRT.so
1463BLDDIRS += $(PATH_STAGE_BIN)
1464
1465$(PATH_STAGE_BIN)/VBoxRT.so: $$(VBoxRT_1_TARGET) | $$(dir $$@)
1466 $(INSTALL) $< $@
1467 chcon -t texrel_shlib_t $@ || true
1468
1469VBoxRT:: VBoxRTDummy
1470 endif # chcon present.
1471 endif # building VBoxRT
1472endif # linux
1473
1474
1475#
1476# VBoxRT-x86 - 32-bit version of VBoxRT
1477#
1478VBoxRT-x86_EXTENDS = VBoxRT
1479VBoxRT-x86_TEMPLATE = VBoxR3Dll-x86
1480VBoxRT-x86_INST.win = $(INST_DLL)x86/
1481VBoxRT-x86_SDKS = VBOX_LIBXML2
1482ifdef VBOX_WITH_LIBCURL
1483 VBoxRT-x86_SDKS += VBOX_LIBCURL-x86
1484endif
1485VBoxRT-x86_SDKS += VBOX_OPENSSL-x86
1486
1487VBoxRT-x86_LIBS = \
1488 $(PATH_STAGE_LIB)/VBox-liblzf-x86$(VBOX_SUFF_LIB)
1489if1of ($(KBUILD_TARGET_ARCH), amd64 x86)
1490VBoxRT-x86_LIBS += \
1491 $(PATH_STAGE_LIB)/SUPR3-x86$(VBOX_SUFF_LIB)
1492endif
1493ifdef IPRT_WITH_KSTUFF
1494 VBoxRT-x86_LIBS += \
1495 $(PATH_STAGE_LIB)/VBox-kStuff-x86$(VBOX_SUFF_LIB)
1496endif
1497ifndef SDK_VBOX_LIBXML2_LIBS
1498 VBoxRT-x86_LIBS += \
1499 $(PATH_STAGE_LIB)/VBox-libxml2-x86$(VBOX_SUFF_LIB)
1500endif
1501VBoxRT-x86_LIBS += \
1502 $(SDK_VBOX_ZLIB_LIBS-x86)
1503ifndef SDK_VBOX_OPENSSL_LIBS
1504 VBoxRT-x86_LIBS += \
1505 $(PATH_STAGE_LIB)/VBox-libcrypto-x86$(VBOX_SUFF_LIB) \
1506 $(PATH_STAGE_LIB)/VBox-libssl-x86$(VBOX_SUFF_LIB)
1507endif
1508ifdef IPRT_WITH_LZO
1509 VBoxRT-x86_LIBS += lzo2
1510endif
1511VBoxRT-x86_LIBS.linux = \
1512 crypt
1513VBoxRT-x86_LIBS.darwin = \
1514 iconv
1515VBoxRT-x86_LIBS.freebsd = \
1516 iconv \
1517 rt
1518VBoxRT-x86_LIBS.haiku = \
1519 iconv
1520VBoxRT-x86_LIBS.solaris = \
1521 kstat \
1522 contract
1523ifn1of ($(KBUILD_TARGET_ARCH), sparc32 sparc64)
1524 # SMBIOS not available on Solaris SPARC.
1525 VBoxRT-x86_LIBS.solaris += smbios
1526endif
1527VBoxRT-x86_LIBS.win = \
1528 $(PATH_SDK_$(VBOX_WINDDK)_LIB.x86)/vccomsup.lib \
1529 $(PATH_SDK_$(VBOX_WINDDK)_LIB.x86)/wbemuuid.lib \
1530 $(PATH_TOOL_$(VBOX_VCC_TOOL_STEM)X86_LIB)/delayimp.lib
1531
1532VBoxRT-x86_SOURCES.win = $(filter-out %.def %.rc,$(VBoxRT_SOURCES.win)) \
1533 $(VBoxRT-x86_0_OUTDIR)/VBoxRT-x86.def
1534if1of ($(DLLS), VBoxRT-x86)
1535$$(VBoxRT-x86_0_OUTDIR)/VBoxRT-x86.def: \
1536 $(PATH_SUB_CURRENT)/r3/win/VBoxRT-win32.def \
1537 $(PATH_SUB_CURRENT)/r3/win/$(if $(VBOX_OSE),VBoxRT-openssl-ose.def,VBoxRT-openssl.def)
1538 $(RM) -f -- $@
1539 $(REDIRECT) -wto $@ -- $(CAT_EXT) $^
1540endif
1541
1542if1of (VBoxRT-x86,$(DLLS))
1543 $(call VBOX_SET_VER_INFO_DLL,VBoxRT-x86,VirtualBox 32-bit Runtime)
1544endif
1545
1546#
1547# VBoxRTImp - Import library/hack.
1548#
1549ifeq ($(KBUILD_TARGET).$(KBUILD_TARGET_ARCH),win.amd64)
1550$(call VBOX_GENERATE_IMPORT_TARGET_FN,VBoxRTImp,VBoxRT,VBox/VBoxRTImp.def r3/win/VBoxRT-win64.def)
1551else ifeq ($(KBUILD_TARGET).$(KBUILD_TARGET_ARCH),win.x86)
1552$(call VBOX_GENERATE_IMPORT_TARGET_FN,VBoxRTImp,VBoxRT,VBox/VBoxRTImp.def r3/win/VBoxRT-win32.def)
1553else
1554$(call VBOX_GENERATE_IMPORT_TARGET_FN,VBoxRTImp,VBoxRT,VBox/VBoxRTImp.def)
1555endif
1556
1557
1558#
1559# RuntimeR3NoCRTGCC - CRT replacement lib for VBoxREM.
1560# This is used together with VBoxRT.
1561#
1562## @todo the *_alias.c stuff is busted, remove and use RT_WITH_NOCRT_ALIASES instead.
1563RuntimeR3NoCRTGCC_TEMPLATE = VBoxNoCrtGccLib
1564RuntimeR3NoCRTGCC_LIBSUFF = $(VBOX_SUFF_LIB)
1565ifn1of ($(KBUILD_TARGET_ARCH), amd64 x86)
1566 RuntimeR3NoCRTGCC_DEFS += RT_NO_GIP
1567endif
1568RuntimeR3NoCRTGCC_INCS = include
1569RuntimeR3NoCRTGCC_SOURCES := \
1570 common/misc/sanity-cpp.cpp \
1571 common/misc/sanity-c.c \
1572 \
1573 $(RuntimeNoCrt_SOURCES)
1574
1575if1of ($(KBUILD_TARGET_ARCH), amd64 x86)
1576RuntimeR3NoCRTGCC_SOURCES += \
1577 common/math/ceill.asm \
1578 common/math/cosl.asm \
1579 common/math/fabs.asm \
1580 common/math/fabsf.asm \
1581 common/math/fabsl.asm \
1582 common/math/floor.asm \
1583 common/math/floorf.asm \
1584 common/math/floorl.asm \
1585 common/math/ldexpl.asm \
1586 common/math/llrint.asm \
1587 common/math/llrintf.asm \
1588 common/math/llrintl.asm \
1589 common/math/logl.asm \
1590 common/math/lrint.asm \
1591 common/math/lrintf.asm \
1592 common/math/lrintl.asm \
1593 common/math/remainder.asm \
1594 common/math/remainderf.asm \
1595 common/math/remainderl.asm \
1596 common/math/sinl.asm \
1597 common/math/tanl.asm \
1598 common/math/trunc.asm \
1599 common/math/truncf.asm \
1600 common/math/truncl.asm \
1601 \
1602 common/string/memchr_alias.c \
1603 common/string/memcmp_alias.c \
1604 common/string/memcpy_alias.c \
1605 common/string/memmove_alias.c \
1606 common/string/memset_alias.c \
1607 common/string/strchr_alias.c \
1608 common/string/strcmp_alias.c \
1609 common/string/strlen_alias.c
1610endif
1611
1612RuntimeR3NoCRTGCC_SOURCES.x86 = \
1613 common/math/x86/fenv-x86.c \
1614 common/math/gcc/adddi3.c \
1615 common/math/gcc/anddi3.c \
1616 common/math/gcc/ashldi3.c \
1617 common/math/gcc/ashrdi3.c \
1618 common/math/gcc/cmpdi2.c \
1619 common/math/gcc/divdi3.c \
1620 common/math/gcc/iordi3.c \
1621 common/math/gcc/lshldi3.c \
1622 common/math/gcc/lshrdi3.c \
1623 common/math/gcc/moddi3.c \
1624 common/math/gcc/muldi3.c \
1625 common/math/gcc/negdi2.c \
1626 common/math/gcc/notdi2.c \
1627 common/math/gcc/qdivrem.c \
1628 common/math/gcc/subdi3.c \
1629 common/math/gcc/ucmpdi2.c \
1630 common/math/gcc/udivdi3.c \
1631 common/math/gcc/umoddi3.c \
1632 common/math/gcc/xordi3.c
1633
1634
1635#
1636# RuntimeR0 - Ring-0 library for VMMR0.
1637#
1638RuntimeR0_TEMPLATE = VBoxR0
1639RuntimeR0_DEFS = IN_RT_R0 RT_WITH_VBOX
1640ifn1of ($(KBUILD_TARGET_ARCH), amd64 x86)
1641 RuntimeR0_DEFS += RT_NO_GIP
1642endif
1643RuntimeR0_INCS = include
1644RuntimeR0_SOURCES := \
1645 common/log/logellipsis.cpp \
1646 common/log/logrelellipsis.cpp \
1647 common/log/logcom.cpp \
1648 common/log/logformat.cpp \
1649 common/log/tracebuf.cpp \
1650 common/log/tracedefault.cpp \
1651 common/misc/RTAssertMsg1Weak.cpp \
1652 common/misc/RTAssertMsg2.cpp \
1653 common/misc/RTAssertMsg2Add.cpp \
1654 common/misc/RTAssertMsg2AddWeak.cpp \
1655 common/misc/RTAssertMsg2AddWeakV.cpp \
1656 common/misc/RTAssertMsg2Weak.cpp \
1657 common/misc/RTAssertMsg2WeakV.cpp \
1658 common/misc/buildconfig.cpp \
1659 common/misc/once.cpp \
1660 common/misc/sanity-c.c \
1661 common/misc/sanity-cpp.cpp \
1662 common/misc/term.cpp \
1663 common/path/RTPathFilename.cpp \
1664 common/string/strhash1.cpp \
1665 common/string/strncmp.cpp \
1666 common/string/strpbrk.cpp \
1667 common/string/RTStrCat.cpp \
1668 common/string/RTStrCatEx.cpp \
1669 common/string/RTStrCatP.cpp \
1670 common/string/RTStrCatPEx.cpp \
1671 common/string/RTStrCopy.cpp \
1672 common/string/RTStrCopyEx.cpp \
1673 common/string/RTStrCopyP.cpp \
1674 common/string/RTStrCopyPEx.cpp \
1675 common/string/RTStrNLen.cpp \
1676 common/string/RTStrNLenEx.cpp \
1677 common/table/avlgcptr.cpp \
1678 common/table/avlhcphys.cpp \
1679 common/table/avllu32.cpp \
1680 common/table/avlogcphys.cpp \
1681 common/table/avlogcptr.cpp \
1682 common/table/avlohcphys.cpp \
1683 common/table/avloioport.cpp \
1684 common/table/avlpv.cpp \
1685 common/table/avlrogcphys.cpp \
1686 common/table/avlrogcptr.cpp \
1687 common/table/avlroioport.cpp \
1688 common/table/avlroogcptr.cpp \
1689 common/table/avlu32.cpp \
1690 common/table/avlou32.cpp \
1691 common/time/timesup.cpp \
1692 generic/RTAssertShouldPanic-generic.cpp \
1693 generic/critsect-generic.cpp \
1694 \
1695 $(RuntimeNoCrt_SOURCES)
1696
1697if1of ($(KBUILD_TARGET), darwin solaris freebsd)
1698RuntimeR0_SOURCES += \
1699 common/math/gcc/adddi3.c \
1700 common/math/gcc/anddi3.c \
1701 common/math/gcc/ashldi3.c \
1702 common/math/gcc/ashrdi3.c \
1703 common/math/gcc/cmpdi2.c \
1704 common/math/gcc/divdi3.c \
1705 common/math/gcc/iordi3.c \
1706 common/math/gcc/lshldi3.c \
1707 common/math/gcc/lshrdi3.c \
1708 common/math/gcc/moddi3.c \
1709 common/math/gcc/muldi3.c \
1710 common/math/gcc/negdi2.c \
1711 common/math/gcc/notdi2.c \
1712 common/math/gcc/qdivrem.c \
1713 common/math/gcc/subdi3.c \
1714 common/math/gcc/ucmpdi2.c \
1715 common/math/gcc/udivdi3.c \
1716 common/math/gcc/umoddi3.c \
1717 common/math/gcc/xordi3.c
1718endif
1719
1720RuntimeR0_SOURCES.x86 += \
1721 common/asm/ASMCpuIdExSlow.asm \
1722 common/asm/ASMAtomicUoAndU64.asm \
1723 common/asm/ASMAtomicUoAndU32.asm \
1724 common/asm/ASMAtomicUoDecU32.asm \
1725 common/asm/ASMAtomicUoIncU32.asm \
1726 common/asm/ASMAtomicUoOrU64.asm \
1727 common/asm/ASMAtomicUoOrU32.asm \
1728 common/asm/ASMGetXcr0.asm \
1729 common/asm/ASMSetXcr0.asm \
1730 common/asm/ASMXSave.asm \
1731 common/asm/ASMXRstor.asm \
1732 common/asm/ASMRdMsrEx.asm \
1733 common/asm/ASMWrMsrEx.asm
1734RuntimeR0_SOURCES.amd64 += \
1735 common/asm/ASMCpuIdExSlow.asm \
1736 common/asm/ASMAtomicUoAndU64.asm \
1737 common/asm/ASMAtomicUoAndU32.asm \
1738 common/asm/ASMAtomicUoDecU32.asm \
1739 common/asm/ASMAtomicUoIncU32.asm \
1740 common/asm/ASMAtomicUoOrU64.asm \
1741 common/asm/ASMAtomicUoOrU32.asm \
1742 common/asm/ASMGetXcr0.asm \
1743 common/asm/ASMSetXcr0.asm \
1744 common/asm/ASMXSave.asm \
1745 common/asm/ASMXRstor.asm \
1746 common/asm/ASMRdMsrEx.asm \
1747 common/asm/ASMWrMsrEx.asm
1748
1749#if1of ($(KBUILD_TARGET_ARCH),amd64 x86)
1750# RuntimeR0_SOURCES += common/time/timesupA.asm
1751#else
1752 RuntimeR0_SOURCES += common/time/timesupref.cpp
1753#endif
1754
1755RuntimeR0_SOURCES.win.amd64 := $(RuntimeWin64ASM_SOURCES)
1756RuntimeR0_SOURCES.win.x86 := $(RuntimeWin32ASM_SOURCES)
1757RuntimeR0_SOURCES.win = \
1758 nt/NtProcessStartup-stub.cpp
1759
1760RuntimeR0_SOURCES.os2 = \
1761 os2/sys0.asm
1762
1763
1764#
1765# RuntimeR0Stub - Ring-0 context startup stub for Windows and Solaris.
1766#
1767RuntimeR0Stub_TEMPLATE = $(if-expr "$(KBUILD_TARGET)" == "solaris",VBoxR0DrvLib,VBoxR0)
1768RuntimeR0Stub_SOURCES.win = \
1769 nt/NtProcessStartup-stub.cpp
1770RuntimeR0Stub_SOURCES.solaris = \
1771 r0drv/solaris/modulestub-r0drv-solaris.c
1772
1773
1774#
1775# RuntimeR0Drv - Ring-0 library for host drivers.
1776#
1777RuntimeR0Drv_TEMPLATE = VBoxR0DrvLib
1778RuntimeR0Drv_SDKS.win = ReorderCompilerIncs $(VBOX_WINDDK) $(VBOX_WINPSDK)INCS VBOX_OPENSSL
1779RuntimeR0Drv_DEFS = IN_RT_R0 RT_WITH_VBOX RT_WITHOUT_NOCRT_WRAPPERS RT_NO_EXPORT_SYMBOL
1780RuntimeR0Drv_DEFS.win = IN_SUP_R0 LDR_ONLY_PE
1781RuntimeR0Drv_DEFS.linux = MODULE KBUILD_MODNAME=KBUILD_STR\(vboxdrv\) KBUILD_BASENAME=KBUILD_STR\(vboxdrv\) IN_SUP_R0
1782
1783RuntimeR0Drv_INCS := $(PATH_SUB_CURRENT) include
1784RuntimeR0Drv_INCS.freebsd = \
1785 $(PATH_STAGE)/gen-sys-hdrs
1786RuntimeR0Drv_INCS.linux = \
1787 r0drv/linux
1788RuntimeR0Drv_INCS.solaris = \
1789 r0drv/solaris/vbi/i86pc \
1790 r0drv/solaris/vbi/i86pc/sys
1791
1792RuntimeR0Drv_SOURCES = \
1793 common/alloc/alloc.cpp \
1794 common/alloc/heapsimple.cpp \
1795 common/alloc/heapoffset.cpp \
1796 common/checksum/alt-md5.cpp \
1797 common/checksum/crc32.cpp \
1798 common/checksum/crc64.cpp \
1799 common/checksum/ipv4.cpp \
1800 common/checksum/ipv6.cpp \
1801 common/err/RTErrConvertToErrno.cpp \
1802 common/err/RTErrConvertFromErrno.cpp \
1803 common/log/log.cpp \
1804 common/log/logellipsis.cpp \
1805 common/log/logrel.cpp \
1806 common/log/logrelellipsis.cpp \
1807 common/log/logcom.cpp \
1808 common/log/logformat.cpp \
1809 common/log/tracebuf.cpp \
1810 common/log/tracedefault.cpp \
1811 common/misc/RTAssertMsg1Weak.cpp \
1812 common/misc/RTAssertMsg2.cpp \
1813 common/misc/RTAssertMsg2Add.cpp \
1814 common/misc/RTAssertMsg2AddWeak.cpp \
1815 common/misc/RTAssertMsg2AddWeakV.cpp \
1816 common/misc/RTAssertMsg2Weak.cpp \
1817 common/misc/RTAssertMsg2WeakV.cpp \
1818 common/misc/assert.cpp \
1819 common/misc/buildconfig.cpp \
1820 common/misc/handletable.cpp \
1821 common/misc/handletablectx.cpp \
1822 common/misc/handletablesimple.cpp \
1823 common/misc/once.cpp \
1824 common/misc/sanity-c.c \
1825 common/misc/sanity-cpp.cpp \
1826 common/misc/term.cpp \
1827 common/misc/RTMemWipeThoroughly.cpp \
1828 common/path/rtPathVolumeSpecLen.cpp \
1829 common/path/RTPathAbsDup.cpp \
1830 common/path/RTPathAbsEx.cpp \
1831 common/path/RTPathAbsExDup.cpp \
1832 common/path/RTPathAppend.cpp \
1833 common/path/RTPathAppendEx.cpp \
1834 common/path/RTPathExt.cpp \
1835 common/path/RTPathFilename.cpp \
1836 common/path/RTPathHasExt.cpp \
1837 common/path/RTPathHasPath.cpp \
1838 common/path/RTPathParseSimple.cpp \
1839 common/path/RTPathRealDup.cpp \
1840 common/path/RTPathStripExt.cpp \
1841 common/path/RTPathStripFilename.cpp \
1842 common/path/RTPathStripTrailingSlash.cpp \
1843 common/rand/rand.cpp \
1844 common/rand/randadv.cpp \
1845 common/rand/randparkmiller.cpp \
1846 common/string/RTStrCat.cpp \
1847 common/string/RTStrCatEx.cpp \
1848 common/string/RTStrCatP.cpp \
1849 common/string/RTStrCatPEx.cpp \
1850 common/string/RTStrCmp.cpp \
1851 common/string/RTStrCopy.cpp \
1852 common/string/RTStrCopyEx.cpp \
1853 common/string/RTStrCopyP.cpp \
1854 common/string/RTStrCopyPEx.cpp \
1855 common/string/RTStrNCmp.cpp \
1856 common/string/RTStrNLen.cpp \
1857 common/string/RTStrNLenEx.cpp \
1858 common/string/straprintf.cpp \
1859 common/string/strformat.cpp \
1860 common/string/strformatnum.cpp \
1861 common/string/strformatrt.cpp \
1862 common/string/strformattype.cpp \
1863 common/string/strhash1.cpp \
1864 common/string/strprintf.cpp \
1865 common/string/strtonum.cpp \
1866 common/string/stringalloc.cpp \
1867 common/string/unidata-flags.cpp \
1868 common/string/unidata-lower.cpp \
1869 common/string/unidata-upper.cpp \
1870 common/string/utf-8.cpp \
1871 common/string/utf-8-case.cpp \
1872 common/string/utf-8-case2.cpp \
1873 common/string/utf-16.cpp \
1874 common/string/utf-16-case.cpp \
1875 common/string/utf-16-latin-1.cpp \
1876 common/table/avlpv.cpp \
1877 common/time/time.cpp \
1878 generic/RTLogWriteStdErr-stub-generic.cpp \
1879 generic/RTLogWriteUser-generic.cpp \
1880 generic/RTMpGetArraySize-generic.cpp \
1881 generic/RTRandAdvCreateSystemFaster-generic.cpp \
1882 generic/RTSemEventWait-2-ex-generic.cpp \
1883 generic/RTSemEventWaitNoResume-2-ex-generic.cpp \
1884 generic/RTSemEventMultiWait-2-ex-generic.cpp \
1885 generic/RTSemEventMultiWaitNoResume-2-ex-generic.cpp \
1886 generic/critsect-generic.cpp \
1887 generic/errvars-generic.cpp \
1888 generic/uuid-generic.cpp \
1889 r0drv/alloc-r0drv.cpp \
1890 r0drv/initterm-r0drv.cpp \
1891 r0drv/generic/semspinmutex-r0drv-generic.c \
1892 VBox/log-vbox.cpp \
1893
1894RuntimeR0Drv_SOURCES.amd64 = \
1895 common/asm/ASMRdMsrEx.asm \
1896 common/asm/ASMWrMsrEx.asm \
1897 common/math/bignum-amd64-x86.asm \
1898 common/math/RTUInt128MulByU64.asm
1899RuntimeR0Drv_SOURCES.x86 = \
1900 common/asm/ASMRdMsrEx.asm \
1901 common/asm/ASMWrMsrEx.asm \
1902 common/math/bignum-amd64-x86.asm
1903
1904
1905RuntimeR0Drv_SOURCES.linux = \
1906 common/misc/thread.cpp \
1907 common/string/strpbrk.cpp \
1908 generic/RTAssertShouldPanic-generic.cpp \
1909 generic/RTLogWriteStdOut-stub-generic.cpp \
1910 generic/RTMpGetCoreCount-generic.cpp \
1911 generic/mppresent-generic.cpp \
1912 r0drv/linux/alloc-r0drv-linux.c \
1913 r0drv/linux/assert-r0drv-linux.c \
1914 r0drv/linux/initterm-r0drv-linux.c \
1915 r0drv/linux/memobj-r0drv-linux.c \
1916 r0drv/linux/memuserkernel-r0drv-linux.c \
1917 r0drv/linux/mp-r0drv-linux.c \
1918 r0drv/linux/mpnotification-r0drv-linux.c \
1919 r0drv/linux/process-r0drv-linux.c \
1920 r0drv/linux/RTLogWriteDebugger-r0drv-linux.c \
1921 r0drv/linux/semevent-r0drv-linux.c \
1922 r0drv/linux/semeventmulti-r0drv-linux.c \
1923 r0drv/linux/semfastmutex-r0drv-linux.c \
1924 r0drv/linux/semmutex-r0drv-linux.c \
1925 r0drv/linux/spinlock-r0drv-linux.c \
1926 r0drv/linux/thread-r0drv-linux.c \
1927 r0drv/linux/thread2-r0drv-linux.c \
1928 r0drv/linux/threadctxhooks-r0drv-linux.c \
1929 r0drv/linux/time-r0drv-linux.c \
1930 r0drv/linux/timer-r0drv-linux.c \
1931 r0drv/memobj-r0drv.cpp \
1932 r0drv/mpnotification-r0drv.c \
1933 r0drv/powernotification-r0drv.c
1934
1935RuntimeR0Drv_SOURCES.win = \
1936 common/ldr/ldr.cpp \
1937 common/ldr/ldrEx.cpp \
1938 common/ldr/ldrPE.cpp \
1939 common/asn1/asn1-basics.cpp \
1940 common/asn1/asn1-dump.cpp \
1941 common/asn1/asn1-cursor.cpp \
1942 common/asn1/asn1-default-allocator.cpp \
1943 common/asn1/asn1-encode.cpp \
1944 common/asn1/asn1-ut-bitstring.cpp \
1945 common/asn1/asn1-ut-bitstring-decode.cpp \
1946 common/asn1/asn1-ut-boolean.cpp \
1947 common/asn1/asn1-ut-boolean-decode.cpp \
1948 common/asn1/asn1-ut-core.cpp \
1949 common/asn1/asn1-ut-core-decode.cpp \
1950 common/asn1/asn1-ut-dyntype.cpp \
1951 common/asn1/asn1-ut-dyntype-decode.cpp \
1952 common/asn1/asn1-ut-integer.cpp \
1953 common/asn1/asn1-ut-integer-decode.cpp \
1954 common/asn1/asn1-ut-null.cpp \
1955 common/asn1/asn1-ut-null-decode.cpp \
1956 common/asn1/asn1-ut-objid.cpp \
1957 common/asn1/asn1-ut-objid-decode.cpp \
1958 common/asn1/asn1-ut-octetstring.cpp \
1959 common/asn1/asn1-ut-octetstring-decode.cpp \
1960 common/asn1/asn1-ut-string.cpp \
1961 common/asn1/asn1-ut-string-decode.cpp \
1962 common/asn1/asn1-ut-time.cpp \
1963 common/asn1/asn1-ut-time-decode.cpp \
1964 common/crypto/digest-core.cpp \
1965 common/crypto/digest-builtin.cpp \
1966 common/crypto/rsa-asn1-decoder.cpp \
1967 common/crypto/rsa-core.cpp \
1968 common/crypto/rsa-init.cpp \
1969 common/crypto/rsa-sanity.cpp \
1970 common/crypto/pkcs7-asn1-decoder.cpp \
1971 common/crypto/pkcs7-core.cpp \
1972 common/crypto/pkcs7-init.cpp \
1973 common/crypto/pkcs7-sanity.cpp \
1974 common/crypto/pkcs7-verify.cpp \
1975 common/crypto/pkix-signature-builtin.cpp \
1976 common/crypto/pkix-signature-core.cpp \
1977 common/crypto/pkix-signature-rsa.cpp \
1978 common/crypto/pkix-util.cpp \
1979 common/crypto/pkix-verify.cpp \
1980 common/crypto/spc-asn1-decoder.cpp \
1981 common/crypto/spc-core.cpp \
1982 common/crypto/spc-init.cpp \
1983 common/crypto/spc-sanity.cpp \
1984 common/crypto/x509-asn1-decoder.cpp \
1985 common/crypto/x509-certpaths.cpp \
1986 common/crypto/x509-core.cpp \
1987 common/crypto/x509-init.cpp \
1988 common/crypto/x509-sanity.cpp \
1989 common/crypto/x509-verify.cpp \
1990 common/crypto/store.cpp \
1991 common/crypto/store-inmem.cpp \
1992 common/crypto/taf-asn1-decoder.cpp \
1993 common/crypto/taf-core.cpp \
1994 common/crypto/taf-init.cpp \
1995 common/crypto/taf-sanity.cpp \
1996 common/crypto/tsp-asn1-decoder.cpp \
1997 common/crypto/tsp-core.cpp \
1998 common/crypto/tsp-init.cpp \
1999 common/crypto/tsp-sanity.cpp \
2000 common/checksum/alt-md2.cpp \
2001 common/checksum/alt-sha1.cpp \
2002 common/checksum/alt-sha256.cpp \
2003 common/checksum/alt-sha512.cpp \
2004 common/checksum/md2str.cpp \
2005 common/checksum/md5str.cpp \
2006 common/checksum/sha1str.cpp \
2007 common/checksum/sha224str.cpp \
2008 common/checksum/sha256str.cpp \
2009 common/checksum/sha384str.cpp \
2010 common/checksum/sha512str.cpp \
2011 common/checksum/sha512t224str.cpp \
2012 common/checksum/sha512t256str.cpp \
2013 common/err/errinfo.cpp \
2014 common/path/RTPathChangeToUnixSlashes.cpp \
2015 common/math/bignum.cpp \
2016 common/misc/zero.asm \
2017 common/string/RTStrPrintHexBytes.cpp \
2018 common/string/RTUtf16Copy.cpp \
2019 common/string/RTUtf16CopyAscii.cpp \
2020 common/string/RTUtf16Cat.cpp \
2021 common/string/RTUtf16CatAscii.cpp \
2022 common/string/RTUtf16End.cpp \
2023 common/string/RTUtf16NLen.cpp \
2024 common/string/RTUtf16NLenEx.cpp \
2025 common/string/RTUtf16PrintHexBytes.cpp \
2026 common/string/strstrip.cpp \
2027 generic/memsafer-generic.cpp \
2028 \
2029 common/misc/thread.cpp \
2030 common/string/memcmp.asm \
2031 common/string/memchr.asm \
2032 common/string/memcpy.asm \
2033 common/string/memset.asm \
2034 common/string/memmove.asm \
2035 common/string/strlen.asm \
2036 common/string/strncmp.cpp \
2037 common/string/strpbrk.cpp \
2038 generic/RTAssertShouldPanic-generic.cpp \
2039 generic/RTLogWriteStdOut-stub-generic.cpp \
2040 generic/RTTimerCreate-generic.cpp \
2041 generic/mppresent-generic.cpp \
2042 generic/RTMpGetCoreCount-generic.cpp \
2043 nt/RTErrConvertFromNtStatus.cpp \
2044 r0drv/generic/threadctxhooks-r0drv-generic.cpp \
2045 r0drv/memobj-r0drv.cpp \
2046 r0drv/mpnotification-r0drv.c \
2047 r0drv/powernotification-r0drv.c \
2048 r0drv/nt/alloc-r0drv-nt.cpp \
2049 r0drv/nt/assert-r0drv-nt.cpp \
2050 r0drv/nt/initterm-r0drv-nt.cpp \
2051 r0drv/nt/memobj-r0drv-nt.cpp \
2052 r0drv/nt/memuserkernel-r0drv-nt.cpp \
2053 r0drv/nt/mp-r0drv-nt.cpp \
2054 r0drv/nt/mpnotification-r0drv-nt.cpp \
2055 r0drv/nt/process-r0drv-nt.cpp \
2056 r0drv/nt/RTLogWriteDebugger-r0drv-nt.cpp \
2057 r0drv/nt/semevent-r0drv-nt.cpp \
2058 r0drv/nt/semeventmulti-r0drv-nt.cpp \
2059 r0drv/nt/semfastmutex-r0drv-nt.cpp \
2060 r0drv/nt/semmutex-r0drv-nt.cpp \
2061 r0drv/nt/spinlock-r0drv-nt.cpp \
2062 r0drv/nt/thread-r0drv-nt.cpp \
2063 r0drv/nt/thread2-r0drv-nt.cpp \
2064 r0drv/nt/time-r0drv-nt.cpp \
2065 r0drv/nt/timer-r0drv-nt.cpp \
2066 r0drv/nt/toxic-chkstk-r0drv-nt.asm \
2067 r0drv/nt/RTTimerGetSystemGranularity-r0drv-nt.cpp
2068
2069RuntimeR0Drv_SOURCES.win.amd64 := $(RuntimeWin64ASM_SOURCES)
2070RuntimeR0Drv_SOURCES.win.x86 := $(RuntimeWin32ASM_SOURCES)
2071
2072RuntimeR0Drv_SOURCES.darwin = \
2073 common/misc/thread.cpp \
2074 common/string/memchr.asm \
2075 common/string/strpbrk.cpp \
2076 darwin/RTErrConvertFromDarwin.cpp \
2077 darwin/RTErrConvertFromDarwinIO.cpp \
2078 darwin/RTErrConvertFromDarwinKern.cpp \
2079 generic/RTAssertShouldPanic-generic.cpp \
2080 generic/RTTimerCreate-generic.cpp \
2081 generic/RTMpGetCoreCount-generic.cpp \
2082 generic/RTMpOnPair-generic.cpp \
2083 generic/mppresent-generic.cpp \
2084 generic/timer-generic.cpp \
2085 r0drv/generic/mpnotification-r0drv-generic.cpp \
2086 r0drv/generic/threadctxhooks-r0drv-generic.cpp \
2087 r0drv/darwin/alloc-r0drv-darwin.cpp \
2088 r0drv/darwin/assert-r0drv-darwin.cpp \
2089 r0drv/darwin/initterm-r0drv-darwin.cpp \
2090 r0drv/darwin/dbgkrnlinfo-r0drv-darwin.cpp \
2091 r0drv/darwin/memobj-r0drv-darwin.cpp \
2092 r0drv/darwin/mp-r0drv-darwin.cpp \
2093 r0drv/darwin/memuserkernel-r0drv-darwin.cpp \
2094 r0drv/darwin/process-r0drv-darwin.cpp \
2095 r0drv/darwin/RTLogWriteDebugger-r0drv-darwin.cpp \
2096 r0drv/darwin/RTLogWriteStdOut-r0drv-darwin.cpp \
2097 r0drv/darwin/semevent-r0drv-darwin.cpp \
2098 r0drv/darwin/semeventmulti-r0drv-darwin.cpp \
2099 r0drv/darwin/semfastmutex-r0drv-darwin.cpp \
2100 r0drv/darwin/semmutex-r0drv-darwin.cpp \
2101 r0drv/darwin/spinlock-r0drv-darwin.cpp \
2102 r0drv/darwin/thread-r0drv-darwin.cpp \
2103 r0drv/darwin/thread2-r0drv-darwin.cpp \
2104 r0drv/darwin/threadpreempt-r0drv-darwin.cpp \
2105 r0drv/darwin/time-r0drv-darwin.cpp \
2106 r0drv/memobj-r0drv.cpp \
2107 r0drv/powernotification-r0drv.c
2108
2109RuntimeR0Drv_SOURCES.os2 = \
2110 common/string/memchr.asm \
2111 common/string/memcmp.asm \
2112 common/string/memcpy.asm \
2113 common/string/mempcpy.asm \
2114 common/string/memmove.asm \
2115 common/string/memset.asm \
2116 common/string/strchr.asm \
2117 common/string/strcmp.asm \
2118 common/string/strcpy.asm \
2119 common/string/strlen.asm \
2120 \
2121 common/string/strncmp.cpp \
2122 common/string/strpbrk.cpp \
2123 \
2124 common/misc/thread.cpp \
2125 generic/RTAssertShouldPanic-generic.cpp \
2126 generic/RTLogWriteDebugger-generic.cpp \
2127 generic/RTLogWriteStdOut-stub-generic.cpp \
2128 generic/RTMpCpuId-generic.cpp \
2129 generic/RTMpCpuIdFromSetIndex-generic.cpp \
2130 generic/RTMpCpuIdToSetIndex-generic.cpp \
2131 generic/RTMpIsCpuPossible-generic.cpp \
2132 generic/RTMpGetCount-generic.cpp \
2133 generic/RTMpGetMaxCpuId-generic.cpp \
2134 generic/RTMpGetOnlineCount-generic.cpp \
2135 generic/RTMpGetOnlineSet-generic.cpp \
2136 generic/RTMpGetSet-generic.cpp \
2137 generic/RTMpIsCpuOnline-generic.cpp \
2138 generic/RTTimerCreate-generic.cpp \
2139 generic/mppresent-generic.cpp \
2140 os2/RTErrConvertFromOS2.cpp \
2141 os2/rtSemWaitOs2ConvertTimeout.cpp \
2142 os2/sys0.asm \
2143 r0drv/generic/RTMpIsCpuWorkPending-r0drv-generic.cpp \
2144 r0drv/generic/RTMpOn-r0drv-generic.cpp \
2145 r0drv/generic/mpnotification-r0drv-generic.cpp \
2146 r0drv/generic/threadctxhooks-r0drv-generic.cpp \
2147 r0drv/memobj-r0drv.cpp \
2148 r0drv/powernotification-r0drv.c \
2149 r0drv/os2/alloc-r0drv-os2.cpp \
2150 r0drv/os2/assert-r0drv-os2.cpp \
2151 r0drv/os2/assertA-r0drv-os2.asm \
2152 r0drv/os2/initterm-r0drv-os2.cpp \
2153 r0drv/os2/memobj-r0drv-os2.cpp \
2154 r0drv/os2/memuserkernel-r0drv-os2.cpp \
2155 r0drv/os2/os2imports.imp \
2156 r0drv/os2/process-r0drv-os2.cpp \
2157 r0drv/os2/RTR0AssertPanicSystem-r0drv-os2.asm \
2158 r0drv/os2/RTR0Os2DHQueryDOSVar.asm \
2159 r0drv/os2/RTR0Os2DHVMGlobalToProcess.asm \
2160 r0drv/os2/semevent-r0drv-os2.cpp \
2161 r0drv/os2/semeventmulti-r0drv-os2.cpp \
2162 r0drv/os2/semfastmutex-r0drv-os2.cpp \
2163 r0drv/os2/spinlock-r0drv-os2.cpp \
2164 r0drv/os2/thread-r0drv-os2.cpp \
2165 r0drv/os2/thread2-r0drv-os2.cpp \
2166 r0drv/os2/time-r0drv-os2.cpp \
2167 r0drv/os2/timer-r0drv-os2.cpp \
2168 r0drv/os2/timerA-r0drv-os2.asm
2169
2170RuntimeR0Drv_SOURCES.freebsd = \
2171 common/misc/thread.cpp \
2172 common/string/memchr.asm \
2173 common/string/memmove.asm \
2174 common/string/strpbrk.cpp \
2175 common/string/memcmp.asm \
2176 common/string/strchr.asm \
2177 generic/RTAssertShouldPanic-generic.cpp \
2178 generic/RTLogWriteDebugger-generic.cpp \
2179 generic/RTLogWriteStdOut-stub-generic.cpp \
2180 generic/RTMpOnPair-generic.cpp \
2181 generic/RTTimerCreate-generic.cpp \
2182 generic/mppresent-generic.cpp \
2183 r0drv/generic/RTMpIsCpuWorkPending-r0drv-generic.cpp \
2184 r0drv/generic/mpnotification-r0drv-generic.cpp \
2185 r0drv/generic/threadctxhooks-r0drv-generic.cpp \
2186 r0drv/freebsd/alloc-r0drv-freebsd.c \
2187 r0drv/freebsd/assert-r0drv-freebsd.c \
2188 r0drv/freebsd/initterm-r0drv-freebsd.c \
2189 r0drv/freebsd/memobj-r0drv-freebsd.c \
2190 r0drv/freebsd/memuserkernel-r0drv-freebsd.c \
2191 r0drv/freebsd/process-r0drv-freebsd.c \
2192 r0drv/freebsd/semevent-r0drv-freebsd.c \
2193 r0drv/freebsd/semeventmulti-r0drv-freebsd.c \
2194 r0drv/freebsd/semfastmutex-r0drv-freebsd.c \
2195 r0drv/freebsd/semmutex-r0drv-freebsd.c \
2196 r0drv/freebsd/spinlock-r0drv-freebsd.c \
2197 r0drv/freebsd/thread-r0drv-freebsd.c \
2198 r0drv/freebsd/thread2-r0drv-freebsd.c \
2199 r0drv/freebsd/time-r0drv-freebsd.c \
2200 r0drv/freebsd/mp-r0drv-freebsd.c \
2201 generic/timer-generic.cpp \
2202 r0drv/memobj-r0drv.cpp \
2203 r0drv/powernotification-r0drv.c
2204
2205RuntimeR0Drv_SOURCES.solaris = \
2206 common/misc/thread.cpp \
2207 common/string/memchr.asm \
2208 generic/RTAssertShouldPanic-generic.cpp \
2209 generic/RTLogWriteStdOut-stub-generic.cpp \
2210 generic/RTMpGetCoreCount-generic.cpp \
2211 generic/RTTimerCreate-generic.cpp \
2212 generic/mppresent-generic.cpp \
2213 r0drv/memobj-r0drv.cpp \
2214 r0drv/mpnotification-r0drv.c \
2215 r0drv/powernotification-r0drv.c \
2216 r0drv/solaris/RTLogWriteDebugger-r0drv-solaris.c \
2217 r0drv/solaris/RTMpPokeCpu-r0drv-solaris.c \
2218 r0drv/solaris/alloc-r0drv-solaris.c \
2219 r0drv/solaris/assert-r0drv-solaris.c \
2220 r0drv/solaris/dbgkrnlinfo-r0drv-solaris.c \
2221 r0drv/solaris/initterm-r0drv-solaris.c \
2222 r0drv/solaris/memuserkernel-r0drv-solaris.c \
2223 r0drv/solaris/mpnotification-r0drv-solaris.c \
2224 r0drv/solaris/memobj-r0drv-solaris.c \
2225 r0drv/solaris/mp-r0drv-solaris.c \
2226 r0drv/solaris/process-r0drv-solaris.c \
2227 r0drv/solaris/semevent-r0drv-solaris.c \
2228 r0drv/solaris/semeventmulti-r0drv-solaris.c \
2229 r0drv/solaris/semfastmutex-r0drv-solaris.c \
2230 r0drv/solaris/semmutex-r0drv-solaris.c \
2231 r0drv/solaris/spinlock-r0drv-solaris.c \
2232 r0drv/solaris/thread-r0drv-solaris.c \
2233 r0drv/solaris/thread2-r0drv-solaris.c \
2234 r0drv/solaris/threadctxhooks-r0drv-solaris.c \
2235 r0drv/solaris/time-r0drv-solaris.c \
2236 r0drv/solaris/timer-r0drv-solaris.c
2237
2238RuntimeR0Drv_SOURCES.haiku = \
2239 common/misc/thread.cpp \
2240 common/string/memchr.asm \
2241 common/string/memmove.asm \
2242 common/string/strpbrk.cpp \
2243 common/string/memcmp.asm \
2244 common/string/strchr.asm \
2245 generic/RTAssertShouldPanic-generic.cpp \
2246 generic/RTMpOnPair-generic.cpp \
2247 generic/RTTimerCreate-generic.cpp \
2248 generic/mppresent-generic.cpp \
2249 r0drv/generic/RTMpIsCpuWorkPending-r0drv-generic.cpp \
2250 r0drv/generic/mpnotification-r0drv-generic.cpp \
2251 r0drv/generic/threadctxhooks-r0drv-generic.cpp \
2252 r0drv/haiku/alloc-r0drv-haiku.c \
2253 r0drv/haiku/assert-r0drv-haiku.c \
2254 r0drv/haiku/initterm-r0drv-haiku.c \
2255 r0drv/haiku/memobj-r0drv-haiku.c \
2256 r0drv/haiku/mp-r0drv-haiku.c \
2257 r0drv/haiku/process-r0drv-haiku.c \
2258 r0drv/haiku/RTLogWriteDebugger-r0drv-haiku.c \
2259 r0drv/haiku/RTLogWriteStdOut-r0drv-haiku.c \
2260 r0drv/haiku/semevent-r0drv-haiku.c \
2261 r0drv/haiku/semeventmulti-r0drv-haiku.c \
2262 r0drv/haiku/semfastmutex-r0drv-haiku.c \
2263 r0drv/haiku/semmutex-r0drv-haiku.c \
2264 r0drv/haiku/spinlock-r0drv-haiku.c \
2265 r0drv/haiku/thread-r0drv-haiku.c \
2266 r0drv/haiku/thread2-r0drv-haiku.c \
2267 r0drv/haiku/time-r0drv-haiku.c \
2268 generic/timer-generic.cpp \
2269 r0drv/memobj-r0drv.cpp \
2270 r0drv/powernotification-r0drv.c
2271
2272## PORTME: Porters create and add their selection of platform specific Ring-0 Driver files here.
2273
2274RuntimeR0Drv_ORDERDEPS.freebsd = \
2275 $(PATH_STAGE)/gen-sys-hdrs/bus_if.h \
2276 $(PATH_STAGE)/gen-sys-hdrs/device_if.h
2277
2278
2279#
2280# RuntimeGuestR0 - Guest driver runtime.
2281# This is almost the same as the RuntimeR0Drv, the main difference
2282# is in the backdoor logging and the lack of sup.h (which should be
2283# made irrelevant even for RuntimeR0Drv).
2284#
2285RuntimeGuestR0_TEMPLATE := VBOXGUESTR0LIB
2286RuntimeGuestR0_EXTENDS = RuntimeR0Drv
2287RuntimeGuestR0_SOURCES := $(filter-out generic/RTLogWriteUser-generic.cpp, $(RuntimeR0Drv_SOURCES))
2288RuntimeGuestR0_SOURCES += \
2289 VBox/logbackdoor.cpp
2290RuntimeGuestR0_SOURCES.win := \
2291 $(filter-out common/checksum/md% common/checksum/sha%, $(RuntimeR0Drv_SOURCES.win))
2292
2293
2294#
2295# RuntimeGuestR0NT4 - Win32 NT4 guest driver runtime.
2296#
2297RuntimeGuestR0NT4_EXTENDS = RuntimeGuestR0
2298RuntimeGuestR0NT4_EXTENDS_BY = appending
2299RuntimeGuestR0NT4_DEFS = IPRT_TARGET_NT4
2300
2301
2302ifdef VBOX_WITH_RAW_MODE
2303 #
2304 # RuntimeRC - Raw-mode context library.
2305 #
2306 RuntimeRC_TEMPLATE = VBoxRc
2307 RuntimeRC_DEFS = IN_RT_RC RT_WITH_VBOX IN_SUP_RC IN_VMM_RC
2308 RuntimeRC_INCS = include
2309 RuntimeRC_SOURCES := \
2310 common/asm/ASMGetXcr0.asm \
2311 common/asm/ASMSetXcr0.asm \
2312 common/asm/ASMXSave.asm \
2313 common/asm/ASMXRstor.asm \
2314 common/checksum/alt-md5.cpp \
2315 common/checksum/crc32.cpp \
2316 common/checksum/crc64.cpp \
2317 common/log/log.cpp \
2318 common/log/logellipsis.cpp \
2319 common/log/logrel.cpp \
2320 common/log/logrelellipsis.cpp \
2321 common/log/logcom.cpp \
2322 common/log/logformat.cpp \
2323 common/log/tracebuf.cpp \
2324 common/log/tracedefault.cpp \
2325 common/misc/RTAssertMsg1Weak.cpp \
2326 common/misc/RTAssertMsg2.cpp \
2327 common/misc/RTAssertMsg2Add.cpp \
2328 common/misc/RTAssertMsg2AddWeak.cpp \
2329 common/misc/RTAssertMsg2AddWeakV.cpp \
2330 common/misc/RTAssertMsg2Weak.cpp \
2331 common/misc/RTAssertMsg2WeakV.cpp \
2332 common/misc/assert.cpp \
2333 common/misc/buildconfig.cpp \
2334 common/misc/sanity-c.c \
2335 common/misc/sanity-cpp.cpp \
2336 common/path/RTPathFilename.cpp \
2337 common/string/strformat.cpp \
2338 common/string/strformatnum.cpp \
2339 common/string/strformatrt.cpp \
2340 common/string/strformattype.cpp \
2341 common/string/strncmp.cpp \
2342 common/string/strpbrk.cpp \
2343 common/string/strprintf.cpp \
2344 common/string/RTStrCopy.cpp \
2345 common/string/RTStrCopyEx.cpp \
2346 common/table/avllu32.cpp \
2347 common/table/avlou32.cpp \
2348 common/table/avlogcphys.cpp \
2349 common/table/avlogcptr.cpp \
2350 common/table/avlohcphys.cpp \
2351 common/table/avloioport.cpp \
2352 common/table/avlrogcphys.cpp \
2353 common/table/avlrogcptr.cpp \
2354 common/table/avlroioport.cpp \
2355 common/table/avlroogcptr.cpp \
2356 common/table/avlu32.cpp \
2357 common/time/timeprog.cpp \
2358 common/time/timesup.cpp \
2359 gc/initterm-gc.cpp \
2360 generic/RTAssertShouldPanic-generic.cpp \
2361 generic/errvars-generic.cpp \
2362 \
2363 $(RuntimeNoCrt_SOURCES)
2364
2365 #if1of ($(KBUILD_TARGET_ARCH),amd64 x86)
2366 # RuntimeRC_SOURCES += common/time/timesupA.asm
2367 #else
2368 RuntimeRC_SOURCES += common/time/timesupref.cpp
2369 #endif
2370
2371 RuntimeRC_SOURCES.win.x86 = $(RuntimeWin32ASM_SOURCES)
2372
2373 ifeq ($(VBOX_LDR_FMT32),lx)
2374 RuntimeRC_SOURCES += os2/sys0.asm
2375 endif
2376
2377 if1of ($(KBUILD_TARGET), darwin solaris freebsd)
2378 RuntimeRC_SOURCES += \
2379 common/math/gcc/adddi3.c \
2380 common/math/gcc/anddi3.c \
2381 common/math/gcc/ashldi3.c \
2382 common/math/gcc/ashrdi3.c \
2383 common/math/gcc/cmpdi2.c \
2384 common/math/gcc/divdi3.c \
2385 common/math/gcc/iordi3.c \
2386 common/math/gcc/lshldi3.c \
2387 common/math/gcc/lshrdi3.c \
2388 common/math/gcc/moddi3.c \
2389 common/math/gcc/muldi3.c \
2390 common/math/gcc/negdi2.c \
2391 common/math/gcc/notdi2.c \
2392 common/math/gcc/qdivrem.c \
2393 common/math/gcc/subdi3.c \
2394 common/math/gcc/ucmpdi2.c \
2395 common/math/gcc/udivdi3.c \
2396 common/math/gcc/umoddi3.c \
2397 common/math/gcc/xordi3.c
2398 endif
2399
2400
2401 #
2402 # RuntimeRCStub - Raw-mode context startup stub for Windows.
2403 #
2404 RuntimeRCStub_TEMPLATE = VBoxRc
2405 RuntimeRCStub_SOURCES.win = \
2406 nt/NtProcessStartup-stub.cpp
2407
2408
2409endif # VBOX_WITH_RAW_MODE
2410
2411
2412#
2413# Static library for new & delete for the electric fence.
2414#
2415RuntimeEFCPP_TEMPLATE := $(VBoxRT_TEMPLATE)
2416RuntimeEFCPP_SDKS := $(RuntimeR3_SDKS)
2417RuntimeEFCPP_SDKS.$(KBUILD_TARGET) := $(RuntimeR3_SDKS.$(KBUILD_TARGET))
2418RuntimeEFCPP_DEFS := $(RuntimeR3_DEFS)
2419RuntimeEFCPP_DEFS.$(KBUILD_TARGET) := $(RuntimeR3_DEFS.$(KBUILD_TARGET))
2420RuntimeEFCPP_INCS := $(RuntimeR3_INCS)
2421RuntimeEFCPP_INCS.$(KBUILD_TARGET) := $(RuntimeR3_INCS.$(KBUILD_TARGET))
2422RuntimeEFCPP_SOURCES := r3/alloc-ef-cpp.cpp
2423
2424
2425
2426#
2427# The NTDLL mini import library.
2428#
2429# Note! The reason for doing this is to avoid importing CRT symbols from the
2430# NTDLL. We do not wish to do this because:
2431# - Our compiler is usually a different one and we should use the
2432# matching CRT,
2433# - Older versions of NTDLL may not sport all the exports our w2k3 or
2434# later WINDDK ntdll.lib have and thus we may easily end up with
2435# images that does not load on older windows versions.
2436#
2437if1of (win,$(KBUILD_TARGET) $(KBUILD_HOST))
2438RuntimeR3NtDll-amd64_TEMPLATE = VBoxR3Dll
2439RuntimeR3NtDll-amd64_BLD_TRG_ARCH = amd64
2440RuntimeR3NtDll-amd64_ARFLAGS = /NODEFAULTLIB /MACHINE:amd64
2441RuntimeR3NtDll-amd64_SOURCES = \
2442 r3/win/ntdll-mini-implib.def
2443
2444RuntimeR3NtDll-x86_TEMPLATE = VBoxR3Dll
2445RuntimeR3NtDll-x86_BLD_TRG_ARCH = x86
2446RuntimeR3NtDll-x86_ARFLAGS = /NODEFAULTLIB /MACHINE:x86
2447RuntimeR3NtDll-x86_SOURCES = \
2448 r3/win/ntdll-mini-implib.def \
2449 $(RuntimeR3NtDll-x86_0_OUTDIR)/ntdll-mini-implib.asm
2450RuntimeR3NtDll-x86_CLEAN = \
2451 $(RuntimeR3NtDll-x86_0_OUTDIR)/ntdll-mini-implib.asm
2452
2453$$(RuntimeR3NtDll-x86_0_OUTDIR)/ntdll-mini-implib.asm: $(PATH_SUB_CURRENT)/r3/win/ntdll-mini-implib.def | $$(dir $$@)
2454 $(call MSG_GENERATE,,$@,$<)
2455 $(QUIET)$(APPEND) -nt "$@" \
2456 ';Autogenerated, do not edit' \
2457 '%include "iprt/asmdefs.mac"' \
2458 'BEGINCODE' \
2459 '%macro IMPLIB_EXPORT 1' \
2460 'global %1:function' \
2461 '%1: nop' \
2462 '%endm' \
2463 ''
2464 $(QUIET)$(SED) -e '1,/EXPORTS/d' \
2465 -e 's/^.*;;=[[:space:]]*\([^[:space:]]*\)[[:space:]]*$$/IMPLIB_EXPORT \1/' \
2466 $< --append $@
2467endif
2468
2469#
2470# Bag of tricks required for making VCC100 output binaries work on NT4, W2K
2471# early XP and early W2K3.
2472#
2473RuntimeR3VccTricks_TEMPLATE = VBoxR3Dll
2474RuntimeR3VccTricks_SOURCES = \
2475 r3/win/vcc100-kernel32-fakes.cpp \
2476 r3/win/vcc100-kernel32-fakesA.asm
2477
2478
2479#
2480# errmsg.cpp depends on a generated header.
2481#
2482common/err/errmsg.cpp_DEPS = $(IPRT_OUT_DIR)/errmsgdata.h
2483common/err/errmsg.cpp_INCS = $(IPRT_OUT_DIR)
2484
2485win/errmsgwin.cpp_DEPS = $(IPRT_OUT_DIR)/errmsgcomdata.h
2486win/errmsgwin.cpp_INCS = $(IPRT_OUT_DIR)
2487
2488# Our COM errors only for R3 libraries on the host
2489define def_errmsgwin_deps
2490 $(lib)_win/errmsgwin.cpp_DEPS = $(IPRT_OUT_DIR)/errmsgvboxcomdata.h
2491 $(lib)_common/err/errmsgxpcom.cpp_INCS = $(IPRT_OUT_DIR)
2492 $(lib)_common/err/errmsgxpcom.cpp_DEPS = $(IPRT_OUT_DIR)/errmsgvboxcomdata.h
2493endef
2494$(foreach lib,RuntimeR3 RuntimeBldProg VBoxRT VBoxRT-x86,$(eval $(def_errmsgwin_deps)))
2495
2496
2497#
2498# Generate the status code data.
2499#
2500$(IPRT_OUT_DIR)/errmsgdata.h: \
2501 $(VBOX_PATH_RUNTIME_SRC)/common/err/errmsg.sed \
2502 $(PATH_ROOT)/include/iprt/err.h \
2503 $(PATH_ROOT)/include/VBox/err.h \
2504 | $$(dir $$@)
2505 $(call MSG_GENERATE,,$@,$(filter %.h,$^))
2506 $(QUIET)$(REDIRECT) -wo $@ -- $(SED) -f $< $(filter %.h,$^)
2507
2508## @todo r=bird: rename this to indicate that it's not only COM errors, but all win32/64 errors.
2509$(IPRT_OUT_DIR)/errmsgcomdata.h: \
2510 $(VBOX_PATH_RUNTIME_SRC)/common/err/errmsgcom.sed \
2511 $$(PATH_SDK_$(VBOX_WINPSDK)_INC)/WinError.h \
2512 | $$(dir $$@)
2513 $(call MSG_GENERATE,,$@,$(filter %.h,$^))
2514 $(QUIET)$(REDIRECT) -wo $@ -- $(SED) -f $< $(filter %.h,$^)
2515
2516$(IPRT_OUT_DIR)/errmsgvboxcomdata.h.ts +| $(IPRT_OUT_DIR)/errmsgvboxcomdata.h: \
2517 $(VBOX_PATH_RUNTIME_SRC)/VBox/errmsgvboxcom.xsl \
2518 $(VBOX_XIDL_FILE_SRC) \
2519 | $$(dir $$@)
2520 $(call MSG_GENERATE,,$@,$(filter %.xidl,$^))
2521 $(QUIET)$(VBOX_XSLTPROC) -o $(IPRT_OUT_DIR)/errmsgvboxcomdata.h.ts $< $(filter %.xidl,$^)
2522 $(QUIET)$(CP) --changed -fv $(IPRT_OUT_DIR)/errmsgvboxcomdata.h.ts $(IPRT_OUT_DIR)/errmsgvboxcomdata.h
2523
2524
2525if "$(KBUILD_TARGET)" == "freebsd"
2526#
2527# FreeBSDGeneratedKernelHeaders - Generate some kernel interface headers.
2528#
2529# These are used by:
2530# - The RTMp* API in IPRT.
2531# - VBoxGuest
2532#
2533# Note! We cannot give a output path to the awk program, it will always
2534# generate the header next to the source. So, we'll have to temporarily copy
2535# the source file to the destination directory to work.
2536#
2537VBOX_AWK := /usr/bin/awk
2538INSTALLS += FreeBSDGeneratedKernelHeaders
2539FreeBSDGeneratedKernelHeaders_INST = gen-sys-hdrs/
2540FreeBSDGeneratedKernelHeaders_SOURCES = \
2541 $(FreeBSDGeneratedKernelHeaders_0_OUTDIR)/bus_if.h \
2542 $(FreeBSDGeneratedKernelHeaders_0_OUTDIR)/device_if.h \
2543 $(FreeBSDGeneratedKernelHeaders_0_OUTDIR)/pci_if.h
2544FreeBSDGeneratedKernelHeaders_CLEAN = $(FreeBSDGeneratedKernelHeaders_SOURCES)
2545
2546$$(FreeBSDGeneratedKernelHeaders_0_OUTDIR)/bus_if.h: $(VBOX_FREEBSD_SRC)/kern/bus_if.m | $$(dir $$@)
2547 $(call MSG_TOOL,awk,FreeBSDGeneratedKernelHeaders,$<,$@)
2548 $(QUIET)$(CP) -f $< $(@D)/bus_if.m
2549 $(QUIET)$(VBOX_AWK) -f $(VBOX_FREEBSD_SRC)/tools/makeobjops.awk $(@D)/bus_if.m -h -p
2550 $(QUIET)$(RM) $(@D)/bus_if.m
2551
2552$$(FreeBSDGeneratedKernelHeaders_0_OUTDIR)/device_if.h: $(VBOX_FREEBSD_SRC)/kern/device_if.m | $$(dir $$@)
2553 $(call MSG_TOOL,awk,FreeBSDGeneratedKernelHeaders,$<,$@)
2554 $(QUIET)$(CP) -f $< $(@D)/device_if.m
2555 $(QUIET)$(VBOX_AWK) -f $(VBOX_FREEBSD_SRC)/tools/makeobjops.awk $(@D)/device_if.m -h -p
2556 $(QUIET)$(RM) $(@D)/device_if.m
2557
2558$$(FreeBSDGeneratedKernelHeaders_0_OUTDIR)/pci_if.h: $(VBOX_FREEBSD_SRC)/dev/pci/pci_if.m | $$(dir $$@)
2559 $(call MSG_TOOL,awk,FreeBSDGeneratedKernelHeaders,$<,$@)
2560 $(QUIET)$(CP) -f $< $(@D)/pci_if.m
2561 $(QUIET)$(VBOX_AWK) -f $(VBOX_FREEBSD_SRC)/tools/makeobjops.awk $(@D)/pci_if.m -h -p
2562 $(QUIET)$(RM) $(@D)/pci_if.m
2563endif # FreeBSD
2564
2565
2566#
2567# Aliases for .cpp.h files so we can more easily do syntax checking from the editor.
2568#
2569ldrELFRelocatable.cpp.o: ldrELF.o
2570ldrELFRelocatable.cpp.obj: ldrELF.obj
2571
2572
2573#
2574# Doxygen documentation.
2575#
2576IPRT_DOXYFILE_INPUT_DIRS = \
2577 $(PATH_ROOT)/include/iprt \
2578 $(PATH_ROOT)/include/iprt/cpp \
2579 $(PATH_ROOT)/include/iprt/linux \
2580 $(PATH_ROOT)/include/iprt/nocrt \
2581 $(PATH_ROOT)/include/iprt/nocrt/x86 \
2582 $(PATH_ROOT)/include/iprt/nocrt/amd64 \
2583 $(PATH_ROOT)/include/iprt/nocrt/compiler \
2584 $(VBOX_PATH_RUNTIME_SRC)/include/internal \
2585 $(VBOX_PATH_RUNTIME_SRC)/common/alloc \
2586 $(VBOX_PATH_RUNTIME_SRC)/common/asm \
2587 $(VBOX_PATH_RUNTIME_SRC)/common/checksum \
2588 $(VBOX_PATH_RUNTIME_SRC)/common/dbg \
2589 $(VBOX_PATH_RUNTIME_SRC)/common/err \
2590 $(VBOX_PATH_RUNTIME_SRC)/common/ldr \
2591 $(VBOX_PATH_RUNTIME_SRC)/common/log \
2592 $(VBOX_PATH_RUNTIME_SRC)/common/math \
2593 $(VBOX_PATH_RUNTIME_SRC)/common/math/amd64 \
2594 $(VBOX_PATH_RUNTIME_SRC)/common/math/gcc \
2595 $(VBOX_PATH_RUNTIME_SRC)/common/math/x86 \
2596 $(VBOX_PATH_RUNTIME_SRC)/common/misc \
2597 $(VBOX_PATH_RUNTIME_SRC)/common/path \
2598 $(VBOX_PATH_RUNTIME_SRC)/common/rand \
2599 $(VBOX_PATH_RUNTIME_SRC)/common/string \
2600 $(VBOX_PATH_RUNTIME_SRC)/common/table \
2601 $(VBOX_PATH_RUNTIME_SRC)/common/time \
2602 $(VBOX_PATH_RUNTIME_SRC)/VBox \
2603 $(foreach dir, $(VBOX_PATH_RUNTIME_SRC) $(VBOX_PATH_RUNTIME_SRC)/r3 $(VBOX_PATH_RUNTIME_SRC)/r0drv,\
2604 $(dir) \
2605 $(dir)/darwin \
2606 $(dir)/haiku \
2607 $(dir)/linux \
2608 $(dir)/nt \
2609 $(dir)/os2 \
2610 $(dir)/solaris \
2611 $(dir)/win \
2612 $(dir)/win32 \
2613 $(dir)/win64 \
2614 $(dir)/generic \
2615 )
2616
2617# These must come first in order to make things look nice.
2618IPRT_DOXYFILE_INPUT_FIRST =\
2619 $(PATH_ROOT)/include/iprt/cdefs.h \
2620 $(PATH_ROOT)/include/iprt/types.h \
2621 $(PATH_ROOT)/include/iprt/runtime.h \
2622 $(PATH_ROOT)/include/iprt/param.h \
2623 $(PATH_ROOT)/include/iprt/assert.h \
2624 $(PATH_ROOT)/include/iprt/asm.h \
2625
2626IPRT_DOXYFILE_INPUT := \
2627 $(filter-out %.cpp.h, $(sort $(wildcard $(addsuffix /*.h, $(IPRT_DOXYFILE_INPUT_DIRS)))) ) \
2628 $(foreach dir, $(IPRT_DOXYFILE_INPUT_DIRS), $(wildcard $(dir)/*.cpp $(dir)/.c $(dir)/.asm))
2629IPRT_DOXYFILE_INPUT := \
2630 $(IPRT_DOXYFILE_INPUT_FIRST) \
2631 $(filter-out $(IPRT_DOXYFILE_INPUT_FIRST), $(IPRT_DOXYFILE_INPUT))
2632
2633
2634IPRT_DOXYFILE_OUTPUT = $(PATH_OUT)/docs/iprt
2635BLDDIRS += $(IPRT_DOXYFILE_OUTPUT)
2636
2637includedep $(IPRT_OUT_DIR)/Doxyfile.iprt.dep
2638
2639# Generate the Doxyfile
2640$(IPRT_OUT_DIR)/Doxyfile.iprt: \
2641 $(VBOX_PATH_RUNTIME_SRC)/Doxyfile \
2642 $(VBOX_PATH_RUNTIME_SRC)/Makefile.kmk \
2643 $(comp-vars IPRT_DOXYFILE_INPUT,DOXYGEN_INPUT_PREV,FORCE) \
2644 $(comp-vars IPRT_DOXYFILE_OUTPUT,DOXYGEN_OUTPUT_PREV,FORCE) \
2645 | $$(dir $$@)
2646 $(RM) -f $@ [email protected] [email protected]
2647 $(CP) -f $(VBOX_PATH_RUNTIME_SRC)/Doxyfile [email protected]
2648 $(APPEND) [email protected]
2649 $(APPEND) [email protected] "OUTPUT_DIRECTORY = $(IPRT_DOXYFILE_OUTPUT)"
2650 $(APPEND) [email protected] "WARN_LOGFILE = $(IPRT_DOXYFILE_OUTPUT)/errors"
2651 $(APPEND) [email protected] "INCLUDE_PATH = $(PATH_ROOT)/include include . common/table"
2652 $(APPEND) [email protected] "INCLUDE_FILE_PATTERNS = *.cpp.h"
2653 $(APPEND) [email protected] "PREDEFINED += $(ARCH_BITS_DEFS)"
2654 $(APPEND) [email protected]
2655 $(APPEND) [email protected] "INPUT = $(IPRT_DOXYFILE_INPUT)"
2656 $(APPEND) [email protected]
2657 $(MV) -f [email protected] $@
2658 @$(APPEND) [email protected] "DOXYGEN_OUTPUT_PREV = $(IPRT_DOXYFILE_OUTPUT)"
2659 @$(APPEND) [email protected] "DOXYGEN_INPUT_PREV = $(IPRT_DOXYFILE_INPUT)"
2660
2661# Do the actual job.
2662$(IPRT_OUT_DIR)/docs.iprt: $(IPRT_OUT_DIR)/Doxyfile.iprt $$(IPRT_DOXYFILE_INPUT) | $(IPRT_DOXYFILE_OUTPUT)/
2663 $(RM) -f $(wildcard $(IPRT_DOXYFILE_OUTPUT)/html/*) $(IPRT_OUT_DIR)/docs.iprt
2664 doxygen $(IPRT_OUT_DIR)/Doxyfile.iprt
2665 $(APPEND) $(IPRT_OUT_DIR)/docs.iprt
2666
2667# aliases
2668docs.iprt: $(IPRT_OUT_DIR)/docs.iprt
2669if !defined(VBOX_ONLY_DOCS) && defined(VBOX_WITH_ALL_DOXYGEN_TARGETS)
2670docs: $(IPRT_OUT_DIR)/docs.iprt
2671endif
2672
2673test-doxygen::
2674 @echo test-$(comp-vars IPRT_DOXYFILE_OUTPUT,DOXYGEN_OUTPUT_PREV,FORCE)
2675 @echo $(IPRT_DOXYFILE_OUTPUT)
2676 @echo $(DOXYGEN_OUTPUT_PREV)
2677 @echo $(IPRT_DOXYFILE_INPUT)
2678
2679
2680#
2681# Test mangling.
2682#
2683if1of ($(LIBRARIES),RuntimeR3 RuntimeR0 RuntimeR0Drv RuntimeRC)
2684 test-mangling:: $(IPRT_OUT_DIR)/mangling.run
2685 OTHERS += $(IPRT_OUT_DIR)/mangling.run
2686 CLEANS += $(IPRT_OUT_DIR)/mangling.run
2687 $(IPRT_OUT_DIR)/mangling.run: \
2688 $$(RuntimeR3_1_TARGET) \
2689 $$(RuntimeR0_1_TARGET) \
2690 $$(RuntimeR0Drv_1_TARGET) \
2691 $$(RuntimeRC_1_TARGET)
2692 if1of ($(KBUILD_TARGET), win os2)
2693 $(call MSG_L1,IPRT: skipped mangling test.)
2694 else
2695# Generate a SED script from mangling.h that checks for known symbols.
2696 $(QUIET)$(SED) \
2697 -e '/# *define.*RT_MANGLER/!d' \
2698 -e 's/^.*RT_MANGLER(\([^)][^)]*\)).*$(DOLLAR)/\/^\1$(DOLLAR)\/b ok/' \
2699 $(PATH_ROOT)/include/iprt/mangling.h \
2700 --output "$@"
2701 $(QUIET)$(APPEND) -n '$@' \
2702 ':bad' \
2703 's/^\(.*\)$(DOLLAR)/error: Missing # define \1 /' \
2704 ':bad-pad' \
2705 '/^.\{0,70\}$(DOLLAR)/ { s/$(DOLLAR)/ /; bbad-pad; }' \
2706 's/define \([^ ]*\) \([ ]*\)$(DOLLAR)/define \1 \2RT_MANGLER(\1)/' \
2707 'p' \
2708 $(if-expr !defined(IPRT_IGNORE_TEST_MANGLING),'q 1') \
2709 '' \
2710 ':ok' \
2711 'd'
2712# Find the best way to generate a symbol list and subject it to mangling.h.
2713 if $(intersects $(KBUILD_TARGET), linux) && "$(VBOX_GCC_fvisibility-hidden)"
2714 $(call MSG_L1,IPRT: Testing mangling and visiblity for newer gcc...)
2715 $(QUIET)readelf -Ws $^ \
2716 | $(SED) \
2717 -e 's/[[:space:]]\+/ /g' \
2718 -e '/^ *[[:digit:]]\+:/!d' \
2719 -e 's/^ \+[[:digit:]]\+: \+[[:xdigit:]]\+ \+[[:digit:]]\+ \+//' \
2720 -e '/^SECTION/d' \
2721 -e '/^FILE/d' \
2722 -e 's/^[[:alpha:]]\+ \+//' \
2723 -e '/LOCAL/d' \
2724 -e 's/^[[:alpha:]]\+ \+//' \
2725 -e '/^HIDDEN [[:xdigit:]]\+ RT/bkeep-hidden' \
2726 -e '/^HIDDEN [[:xdigit:]]\+ g_[a-z0-9]*RT/bkeep-hidden' \
2727 -e '/^HIDDEN/d' \
2728 -e ':keep-hidden' \
2729 -e 's/^[[:alpha:]]\+ \+//' \
2730 -e '/^UND/d' \
2731 -e 's/^[[:digit:]]\+ \+//' \
2732 \
2733 -e '/^nocrt_/d' \
2734 -e '/^memchr/d' \
2735 -e '/^memcmp/d' \
2736 -e '/^memcpy/d' \
2737 -e '/^mempcpy/d' \
2738 -e '/^memmove/d' \
2739 -e '/^memset/d' \
2740 -e '/^strchr/d' \
2741 -e '/^strpbrk/d' \
2742 -e '/^_Z7strpbrk/d' \
2743 -e '/^strcmp/d' \
2744 -e '/^strcpy/d' \
2745 -e '/^strncpy/d' \
2746 -e '/^strlen/d' \
2747 -e '/^_Z[[:alpha:]]*[[:digit:]]\+RTC/d' \
2748 -e '/^_Z[[:alpha:]]*[[:digit:]]\+RTC/d' \
2749 \
2750 -e '/^_ZnwjPv/d' \
2751 -e '/^_ZnwmPv/d' \
2752 -e '/^_ZNSt9bad_allocC1Ev/d' \
2753 -e '/^_ZNSt9exceptionC2Ev/d' \
2754 -e '/^_ZNSt9exceptionC[12]ERKS_/d' \
2755 \
2756 -e '/^_ZN[a-zA-Z]*St[[:digit:]]*_*[lL]ist/d' \
2757 -e '/^_ZN[a-zA-Z]*[[:digit:]]*__gnu_cxx/d' \
2758 -e '/^_ZNSa.*ElementNode.*/d' \
2759 -e '/^_ZSt.*ElementNode.*/d' \
2760 \
2761 -e '/^_Z[[:digit:]]\+dbus/d' \
2762 -e '/^_Z13RTDBusLoadLibv/d' \
2763 \
2764 -e '/^VBoxHost_/d'\
2765 -e '/^VBoxGuest_/d'\
2766 | $(SED) -nf "$@"
2767 endif
2768 $(call MSG_L1,IPRT: Testing mangling using nm...)
2769 $(QUIET)$(VBOX_NM) $^ 2> /dev/null \
2770 | $(SED) -n \
2771 -e 's/^[0-9a-f][0-9a-f]* //' \
2772 -e '/^[TUDB] /!d' \
2773 -e 's/^. //' \
2774 $(if-expr "$(KBUILD_TARGET)" == "darwin" || "$(KBUILD_TARGET)" == "os2" || "$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH)" == "win.x86", \
2775 -e 's/^_//',) \
2776 \
2777 -e '/^g_cchrt/d'\
2778 -e '/^g_frt/d'\
2779 -e '/^g_offrt/d'\
2780 -e '/^g_pfnrt/d'\
2781 -e '/^g_rt/d'\
2782 -e '/^g_szrt/d'\
2783 -e '/^g_ProcessSelf/d'\
2784 -e '/^g_u64ProgramStart/d'\
2785 -e '/^g_enmProcessPriority/d'\
2786 -e '/^g_hDbgModStrCache/d'\
2787 -e '/^g_pfnR0Darwin/d'\
2788 -e '/^g_pDarwinLockGroup/d'\
2789 $(if-expr "$(KBUILD_TARGET)" == "solaris", \
2790 -e '/^g_kLdrRdrFileOps/d' \
2791 -e '/^g_pSUPGlobalInfoPage/d' \
2792 -e '/^g_Logger/d' \
2793 -e '/^g_RelLogger/d' \
2794 -e '/^g_VM/d',) \
2795 \
2796 -e '/^RTDBusLoadLib/d' \
2797 \
2798 -e '/^RT/p' \
2799 -e '/^g_/p' \
2800 | $(SED) -nf "$@"
2801 endif
2802endif
2803 $(QUIET)$(APPEND) -t $@
2804
2805if !defined(VBOX_ONLY_ADDITIONS) && !defined(VBOX_ONLY_VALIDATIONKIT) && !defined(VBOX_ONLY_DOCS)
2806#
2807# Windows build tool.
2808#
2809BLDPROGS.win += ntBldSymDb
2810ntBldSymDb_TEMPLATE = VBoxAdvBldProg
2811ntBldSymDb_INCS = .
2812ntBldSymDb_SOURCES = r0drv/nt/ntBldSymDb.cpp
2813endif
2814
2815#
2816# Generate the rules (we're the to sub-makefile).
2817#
2818include $(FILE_KBUILD_SUB_FOOTER)
2819
2820
2821#
2822# Aliases for code templates.
2823#
2824rsa-template.o rsa-template.obj: rsa-core.o rsa-asn1-decoder.o rsa-sanity.o rsa-init.o
2825spc-template.o spc-template.obj: spc-core.o spc-asn1-decoder.o spc-sanity.o spc-init.o
2826taf-template.o taf-template.obj: taf-core.o taf-asn1-decoder.o taf-sanity.o taf-init.o
2827tsp-template.o tsp-template.obj: tsp-core.o tsp-asn1-decoder.o tsp-sanity.o tsp-init.o
2828x509-template.o x509-template.obj: x509-core.o x509-asn1-decoder.o x509-sanity.o x509-init.o
2829pkcs7-template.o pkcs7-template.obj: pkcs7-core.o pkcs7-asn1-decoder.o pkcs7-sanity.o pkcs7-init.o
2830
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