VirtualBox

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

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

IPRT: Implemented reading lib/Security/cacerts from JRE.

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