VirtualBox

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

Last change on this file since 96407 was 96407, checked in by vboxsync, 22 months ago

scm copyright and license note update

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 159.9 KB
Line 
1# $Id: Makefile.kmk 96407 2022-08-22 17:43:14Z vboxsync $
2## @file
3# Sub-Makefile for the IPRT.
4#
5
6#
7# Copyright (C) 2006-2022 Oracle and/or its affiliates.
8#
9# This file is part of VirtualBox base platform packages, as
10# available from https://www.virtualbox.org.
11#
12# This program is free software; you can redistribute it and/or
13# modify it under the terms of the GNU General Public License
14# as published by the Free Software Foundation, in version 3 of the
15# License.
16#
17# This program is distributed in the hope that it will be useful, but
18# WITHOUT ANY WARRANTY; without even the implied warranty of
19# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20# General Public License for more details.
21#
22# You should have received a copy of the GNU General Public License
23# along with this program; if not, see <https://www.gnu.org/licenses>.
24#
25# The contents of this file may alternatively be used under the terms
26# of the Common Development and Distribution License Version 1.0
27# (CDDL), a copy of it is provided in the "COPYING.CDDL" file included
28# in the VirtualBox distribution, in which case the provisions of the
29# CDDL are applicable instead of those of the GPL.
30#
31# You may elect to license modified versions of this file under the
32# terms and conditions of either the GPL or the CDDL or both.
33#
34# SPDX-License-Identifier: GPL-3.0-only OR CDDL-1.0
35#
36
37SUB_DEPTH = ../../..
38include $(KBUILD_PATH)/subheader.kmk
39
40ifdef VBOX_ONLY_ADDITIONS
41 #
42 # Only build the additions, sort out the legacy names first.
43 #
44 LIBRARIES += RuntimeGuestR3 RuntimeGuestR3Shared
45 LIBRARIES.win += RuntimeR3NoCrt
46 LIBRARIES.win.amd64 += RuntimeGuestR3-x86 RuntimeGuestR3Shared-x86
47 ifdef VBOX_WITH_ADDITION_DRIVERS
48 LIBRARIES += RuntimeGuestR0
49 #LIBRARIES.os2 += RuntimeGuestR0OS2Warp3
50 endif
51 ifndef VBOX_ONLY_ADDITIONS_WITHOUT_RTISOMAKER
52 LIBRARIES += RuntimeBldProg
53 include $(PATH_SUB_CURRENT)/tools/Makefile.kmk
54 endif
55
56else ifdef VBOX_ONLY_VALIDATIONKIT
57 #
58 # Only build the Validation Kit.
59 #
60 LIBRARIES += RuntimeGuestR3 RuntimeGuestR3Shared RuntimeR3 RuntimeBldProg
61 ifdef VBOX_WITH_R0_MODULES
62 LIBRARIES += RuntimeR0
63 endif
64 LIBRARIES.solaris += RuntimeR0Stub
65 LIBRARIES.win += RuntimeR0Stub #RuntimeR3NoCrt
66 LIBRARIES.win.x86 += RuntimeR3VccTricks
67 include $(PATH_SUB_CURRENT)/tools/Makefile.kmk
68 ifdef VBOX_WITH_VALIDATIONKIT_UNITTESTS_PACKING
69 include $(PATH_SUB_CURRENT)/testcase/Makefile.kmk
70 endif
71else ifdef VBOX_ONLY_DOCS
72 #
73 # Build docs only - need just regular R3 runtime.
74 #
75 LIBRARIES += RuntimeR3 RuntimeBldProg
76 include $(PATH_SUB_CURRENT)/tools/Makefile.kmk
77
78else ifdef VBOX_ONLY_EXTPACKS_USE_IMPLIBS
79 #
80 # Build extension packs using import libraries as much as possible (VBoxDTrace
81 # needs Ring-0 IPRT, though).
82 #
83 LIBRARIES += RuntimeBldProg
84 ifdef VBOX_WITH_R0_MODULES
85 LIBRARIES += RuntimeR0
86 endif
87 LIBRARIES.solaris += RuntimeR0Stub
88 LIBRARIES.win += RuntimeR0Stub
89 ifdef VBOX_WITH_RAW_MODE
90 LIBRARIES.win += RuntimeRCStub
91 endif
92 include $(PATH_SUB_CURRENT)/tools/Makefile.kmk
93
94else # !VBOX_ONLY_ADDITIONS && !VBOX_ONLY_VALIDATIONKIT && !VBOX_ONLY_DOCS
95
96 #
97 # Normal build.
98 #
99 ifndef VBOX_ONLY_EXTPACKS
100 include $(PATH_SUB_CURRENT)/testcase/Makefile.kmk
101 endif
102 include $(PATH_SUB_CURRENT)/tools/Makefile.kmk
103
104 BLDPROGS += uniread
105 LIBRARIES += RuntimeR3 RuntimeBldProg RuntimeEFCPP RuntimeR3NoCRTGCC
106 ifdef VBOX_WITH_R0_MODULES
107 LIBRARIES += RuntimeR0
108 endif
109 LIBRARIES.solaris += RuntimeR0Stub
110 LIBRARIES.win += RuntimeR0Stub RuntimeR3NoCrt
111 LIBRARIES.win.amd64 += RuntimeR3-x86
112 ifdef VBOX_WITH_RAW_MODE
113 LIBRARIES += RuntimeRC
114 LIBRARIES.win += RuntimeRCStub
115 endif
116 ifdef VBOX_WITH_VBOXDRV
117 LIBRARIES += RuntimeR0Drv
118 endif
119 ifdef VBOX_WITH_ADDITIONS
120 LIBRARIES += RuntimeGuestR3 RuntimeGuestR3Shared
121 LIBRARIES.win.amd64 += RuntimeGuestR3-x86 RuntimeGuestR3Shared-x86
122 ifdef VBOX_WITH_ADDITION_DRIVERS
123 LIBRARIES += RuntimeGuestR0
124 endif
125 #LIBRARIES.os2 += RuntimeGuestR0OS2Warp3
126 endif # VBOX_WITH_ADDITIONS
127 LIBRARIES.win.x86 += RuntimeR3VccTricks
128 DLLS += VBoxRT
129 ifdef VBOX_WITH_32_ON_64_MAIN_API
130 DLLS += VBoxRT-x86
131 endif
132endif
133
134
135# Always build the ntdll import libraries on windows.
136LIBRARIES.win += RuntimeR3NtDll-x86
137if1of (amd64, $(KBUILD_TARGET_ARCH) $(KBUILD_HOST_ARCH))
138 LIBRARIES.win += RuntimeR3NtDll-amd64
139endif
140
141
142# Always build the import library.
143IMPORT_LIBS += VBoxRTImp
144
145
146# Where the generated stuff goes.
147IPRT_OUT_DIR := $(PATH_TARGET)/Runtime
148BLDDIRS += $(IPRT_OUT_DIR)
149OTHER_CLEAN += \
150 $(IPRT_OUT_DIR)/errmsgdata.h \
151 $(IPRT_OUT_DIR)/errmsgwindata.h \
152 $(IPRT_OUT_DIR)/errmsgwindata-sorted.h \
153 $(IPRT_OUT_DIR)/errmsgwindata-sorted.h.ts \
154 $(IPRT_OUT_DIR)/errmsgvboxcomdata.h \
155 $(IPRT_OUT_DIR)/errmsgvboxcomdata.h.ts \
156 $(IPRT_OUT_DIR)/odi2name.h \
157 $(IPRT_OUT_DIR)/odi2name.h.ts \
158 $(IPRT_DOXYFILE_OUTPUT)/Doxyfile.iprt \
159 $(IPRT_DOXYFILE_OUTPUT)/Doxyfile.iprt.dep \
160 $(IPRT_DOXYFILE_OUTPUT)/docs.iprt
161
162
163#
164# Globals
165#
166VBOX_PATH_RUNTIME_SRC := $(PATH_SUB_CURRENT)
167
168
169#
170# Set the defines that buildconfig.cpp needs. Its used by several targets.
171#
172common/misc/buildconfig.cpp_DEFS = \
173 IPRT_BLDCFG_SCM_REV=$(VBOX_SVN_REV) \
174 IPRT_BLDCFG_VERSION_MAJOR=$(VBOX_VERSION_MAJOR) \
175 IPRT_BLDCFG_VERSION_MINOR=$(VBOX_VERSION_MINOR) \
176 IPRT_BLDCFG_VERSION_BUILD=$(VBOX_VERSION_BUILD)
177ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
178common/misc/buildconfig.cpp_DEFS += \
179 IPRT_BLDCFG_VERSION_STRING="$(VBOX_VERSION_STRING)" \
180 IPRT_BLDCFG_TARGET="$(KBUILD_TARGET)" \
181 IPRT_BLDCFG_TARGET_ARCH="$(KBUILD_TARGET_ARCH)" \
182 IPRT_BLDCFG_TYPE="$(KBUILD_TYPE)"
183else
184common/misc/buildconfig.cpp_DEFS += \
185 IPRT_BLDCFG_VERSION_STRING=\"$(VBOX_VERSION_STRING)\" \
186 IPRT_BLDCFG_TARGET=\"$(KBUILD_TARGET)\" \
187 IPRT_BLDCFG_TARGET_ARCH=\"$(KBUILD_TARGET_ARCH)\" \
188 IPRT_BLDCFG_TYPE=\"$(KBUILD_TYPE)\"
189endif
190
191#
192# OID to C table conversion program.
193#
194BLDPROGS += oiddb2c
195oiddb2c_TEMPLATE = VBoxBldProg
196oiddb2c_SOURCES = common/asn1/oiddb2c.cpp
197
198common/asn1/asn1-dump.cpp_DEPS = $(IPRT_OUT_DIR)/oiddb.h
199common/asn1/asn1-dump.cpp_INCS = $(IPRT_OUT_DIR)
200OTHER_CLEAN += $(IPRT_OUT_DIR)/oiddb.h $(IPRT_OUT_DIR)/oiddb.h.ts
201
202$(IPRT_OUT_DIR)/oiddb.h.ts +| $(IPRT_OUT_DIR)/oiddb.h: \
203 $(VBOX_PATH_RUNTIME_SRC)/common/asn1/oiddb.cfg \
204 $(VBOX_EXTRA_OID_CFG_FILES) \
205 $$(oiddb2c_1_TARGET) \
206 | $$(dir $$@)
207 $(call MSG_GENERATE,,$@,$(filter %.xidl,$^))
208 $(QUIET)$(oiddb2c_1_TARGET) "$@" $(filter %.cfg,$^)
209 $(QUIET)$(CP) --changed -fv "$@" "$(IPRT_OUT_DIR)/oiddb.h"
210
211
212#
213# Unicode Specification reader used to regenerate unidata-*.cpp.
214#
215uniread_TEMPLATE = VBoxBldProg
216uniread_SOURCES = common/string/uniread.cpp
217uniread_INCS = include
218
219#
220# Win64 assembly sources.
221#
222RuntimeWin64ASM_SOURCES = \
223 win/amd64/ASMAtomicBitClear.asm \
224 win/amd64/ASMAtomicBitTestAndToggle.asm \
225 win/amd64/ASMAtomicBitToggle.asm \
226 win/amd64/ASMAtomicReadU64.asm \
227 win/amd64/ASMAtomicXchgU8.asm \
228 win/amd64/ASMGetCS.asm \
229 win/amd64/ASMGetDS.asm \
230 win/amd64/ASMGetES.asm \
231 common/asm/ASMGetFlags.asm \
232 win/amd64/ASMGetFS.asm \
233 win/amd64/ASMGetGS.asm \
234 win/amd64/ASMGetSS.asm \
235 win/amd64/ASMProbeReadByte.asm \
236 common/asm/ASMSetFlags.asm \
237 common/asm/ASMAddFlags.asm \
238 win/amd64/ASMGetDR0.asm \
239 win/amd64/ASMGetDR1.asm \
240 win/amd64/ASMGetDR2.asm \
241 win/amd64/ASMGetDR3.asm \
242 win/amd64/ASMGetDR6.asm \
243 win/amd64/ASMGetDR7.asm \
244 common/asm/ASMAtomicCmpXchgU8.asm \
245 common/asm/ASMAtomicCmpXchgU16.asm \
246 common/asm/ASMAtomicXchgU16.asm \
247 common/asm/ASMBitFirstClear.asm \
248 common/asm/ASMBitFirstSet.asm \
249 common/asm/ASMBitNextClear.asm \
250 common/asm/ASMBitNextSet.asm \
251 common/asm/ASMMultU32ByU32DivByU32.asm \
252 common/asm/ASMMultU64ByU32DivByU32.asm \
253 common/asm/ASMCpuId_Idx_ECX.asm \
254 common/asm/ASMNopPause.asm \
255 common/asm/ASMGetIDTR.asm \
256 common/asm/ASMGetIdtrLimit.asm \
257 common/asm/ASMSetIDTR.asm \
258 common/asm/ASMGetGDTR.asm \
259 common/asm/ASMSetGDTR.asm \
260 common/asm/ASMGetLDTR.asm \
261 common/asm/ASMGetSegAttr.asm \
262 common/asm/ASMGetFSBase.asm \
263 common/asm/ASMSetFSBase.asm \
264 common/asm/ASMGetGSBase.asm \
265 common/asm/ASMSetGSBase.asm \
266 common/asm/ASMGetTR.asm \
267
268#
269# Win32 assembly sources.
270#
271RuntimeWin32ASM_SOURCES = \
272 common/asm/ASMAtomicCmpXchgU8.asm \
273 common/asm/ASMAtomicCmpXchgU16.asm \
274 common/asm/ASMAtomicXchgU16.asm \
275 common/asm/ASMMultU32ByU32DivByU32.asm \
276 common/asm/ASMMultU64ByU32DivByU32.asm \
277 common/asm/ASMCpuId_Idx_ECX.asm \
278 common/asm/ASMGetSegAttr.asm
279
280
281#
282# NoCRT sources (minus math stuff).
283#
284if1of ($(KBUILD_TARGET_ARCH), amd64 x86)
285RuntimeNoCrt_SOURCES = \
286 common/misc/setjmp.asm \
287 common/string/bzero.asm \
288 common/string/memchr.asm \
289 common/string/memcmp.asm \
290 common/string/memcpy.asm \
291 common/string/mempcpy.asm \
292 common/string/memmove.asm \
293 common/string/memset.asm \
294 common/string/strchr.asm \
295 common/string/strcpy.asm \
296 common/string/strncpy.asm \
297 common/string/strcmp.asm \
298 common/string/strlen.asm
299endif
300
301
302#
303# RuntimeBaseR3 - Commmon Base Runtime Target for Ring-3 executables.
304#
305# Note! This is not make itself, it's only used as a base target config to be
306# inherited from by RuntimeR3(.lib) and VBoxR3(.dll).
307#
308RuntimeBaseR3_TEMPLATE = VBoxR3Static
309RuntimeBaseR3_SDKS = VBOX_LIBXML2
310RuntimeBaseR3_SDKS.win = $(VBOX_WINPSDK) $(VBOX_WINDDK)
311RuntimeBaseR3_DEFS = \
312 IN_RT_R3 \
313 LDR_WITH_NATIVE \
314 LDR_WITH_ELF32 \
315 LDR_WITH_LX \
316 LDR_WITH_MACHO \
317 LDR_WITH_PE \
318 RT_WITH_VBOX \
319 RT_NO_GIP \
320 RT_WITHOUT_NOCRT_WRAPPERS \
321 NOFILEID
322if1of ($(KBUILD_TARGET_ARCH), amd64 x86)
323 RuntimeBaseR3_DEFS += \
324 IN_SUP_R3
325endif
326#RuntimeBaseR3_DEFS += RTMEM_WRAP_TO_EF_APIS
327ifdef IPRT_WITH_LZJB
328 RuntimeBaseR3_DEFS += RTZIP_USE_LZJB
329endif
330ifdef IPRT_WITH_LZO
331 RuntimeBaseR3_DEFS += RTZIP_USE_LZO
332endif
333ifn1of ($(KBUILD_TARGET), win)
334 RuntimeBaseR3_DEFS += RT_WITH_ICONV_CACHE
335endif
336ifdef IPRT_WITH_FUTEX_BASED_SEMS
337 RuntimeBaseR3_DEFS.linux += IPRT_WITH_FUTEX_BASED_SEMS
338endif
339ifdef IPRT_HTTP_WITH_WEBDAV
340 RuntimeBaseR3_DEFS += IPRT_HTTP_WITH_WEBDAV
341endif
342ifdef IPRT_WITHOUT_PAM
343 RuntimeBaseR3_DEFS += IPRT_WITHOUT_PAM
344endif
345RuntimeBaseR3_INCS = \
346 include \
347 $(SDK_VBOX_ZLIB_INCS) \
348 $(SDK_VBOX_LZF_INCS)
349
350# RuntimeBaseR3_INCS.solaris = \
351# /usr/include
352
353RuntimeBaseR3_SOURCES := \
354 common/alloc/alloc.cpp \
355 common/alloc/heapsimple.cpp \
356 common/alloc/heapoffset.cpp \
357 common/alloc/memcache.cpp \
358 common/alloc/memtracker.cpp \
359 common/asn1/asn1-basics.cpp \
360 common/asn1/asn1-cursor.cpp \
361 common/asn1/asn1-default-allocator.cpp \
362 common/asn1/asn1-efence-allocator.cpp \
363 common/asn1/asn1-safer-allocator.cpp \
364 common/asn1/asn1-dump.cpp \
365 common/asn1/asn1-encode.cpp \
366 common/asn1/asn1-ut-bitstring.cpp \
367 common/asn1/asn1-ut-bitstring-decode.cpp \
368 common/asn1/asn1-ut-boolean.cpp \
369 common/asn1/asn1-ut-boolean-decode.cpp \
370 common/asn1/asn1-ut-core.cpp \
371 common/asn1/asn1-ut-core-decode.cpp \
372 common/asn1/asn1-ut-dyntype.cpp \
373 common/asn1/asn1-ut-dyntype-decode.cpp \
374 common/asn1/asn1-ut-integer.cpp \
375 common/asn1/asn1-ut-integer-decode.cpp \
376 common/asn1/asn1-ut-null.cpp \
377 common/asn1/asn1-ut-null-decode.cpp \
378 common/asn1/asn1-ut-objid.cpp \
379 common/asn1/asn1-ut-objid-decode.cpp \
380 common/asn1/asn1-ut-octetstring.cpp \
381 common/asn1/asn1-ut-octetstring-decode.cpp \
382 common/asn1/asn1-ut-string.cpp \
383 common/asn1/asn1-ut-string-decode.cpp \
384 common/asn1/asn1-ut-time.cpp \
385 common/asn1/asn1-ut-time-decode.cpp \
386 common/checksum/adler32.cpp \
387 common/checksum/crc32.cpp \
388 common/checksum/crc32c.cpp \
389 common/checksum/crc64.cpp \
390 common/checksum/crc16ccitt.cpp \
391 common/checksum/alt-md2.cpp \
392 common/checksum/alt-md4.cpp \
393 common/checksum/alt-md5.cpp \
394 common/checksum/alt-sha1.cpp \
395 common/checksum/alt-sha256.cpp \
396 common/checksum/alt-sha512.cpp \
397 common/checksum/alt-sha3.cpp \
398 common/checksum/md2str.cpp \
399 common/checksum/md4str.cpp \
400 common/checksum/md5str.cpp \
401 common/checksum/ipv4.cpp \
402 common/checksum/ipv6.cpp \
403 common/checksum/manifest.cpp \
404 common/checksum/manifest2.cpp \
405 common/checksum/manifest3.cpp \
406 common/checksum/manifest-file.cpp \
407 common/checksum/RTSha1Digest.cpp \
408 common/checksum/RTSha256Digest.cpp \
409 common/checksum/sha1str.cpp \
410 common/checksum/sha224str.cpp \
411 common/checksum/sha256str.cpp \
412 common/checksum/sha384str.cpp \
413 common/checksum/sha512str.cpp \
414 common/checksum/sha512t224str.cpp \
415 common/checksum/sha512t256str.cpp \
416 common/crypto/cipher-openssl.cpp \
417 common/crypto/digest-core.cpp \
418 common/crypto/digest-builtin.cpp \
419 common/crypto/digest-vfs.cpp \
420 common/crypto/iprt-openssl.cpp \
421 common/crypto/key.cpp \
422 common/crypto/key-file.cpp \
423 common/crypto/key-openssl.cpp \
424 common/crypto/key-create-rsa-openssl.cpp \
425 common/crypto/rc4-openssl.cpp \
426 common/crypto/rsa-asn1-decoder.cpp \
427 common/crypto/rsa-core.cpp \
428 common/crypto/rsa-init.cpp \
429 common/crypto/rsa-sanity.cpp \
430 common/crypto/pemfile-read.cpp \
431 common/crypto/pemfile-write.cpp \
432 common/crypto/pkcs7-asn1-decoder.cpp \
433 common/crypto/pkcs7-core.cpp \
434 common/crypto/pkcs7-file.cpp \
435 common/crypto/pkcs7-init.cpp \
436 common/crypto/pkcs7-sanity.cpp \
437 common/crypto/pkcs7-sign.cpp \
438 common/crypto/pkcs7-verify.cpp \
439 common/crypto/pkix-sign.cpp \
440 common/crypto/pkix-signature-builtin.cpp \
441 common/crypto/pkix-signature-core.cpp \
442 common/crypto/pkix-signature-rsa.cpp \
443 common/crypto/pkix-util.cpp \
444 common/crypto/pkix-verify.cpp \
445 common/crypto/spc-asn1-decoder.cpp \
446 common/crypto/spc-core.cpp \
447 common/crypto/spc-init.cpp \
448 common/crypto/spc-sanity.cpp \
449 common/crypto/ssl-openssl.cpp \
450 common/crypto/x509-asn1-decoder.cpp \
451 common/crypto/x509-certpaths.cpp \
452 common/crypto/x509-core.cpp \
453 common/crypto/x509-file.cpp \
454 common/crypto/x509-init.cpp \
455 common/crypto/x509-sanity.cpp \
456 common/crypto/x509-verify.cpp \
457 common/crypto/taf-asn1-decoder.cpp \
458 common/crypto/taf-core.cpp \
459 common/crypto/taf-init.cpp \
460 common/crypto/taf-sanity.cpp \
461 common/crypto/tsp-asn1-decoder.cpp \
462 common/crypto/tsp-core.cpp \
463 common/crypto/tsp-init.cpp \
464 common/crypto/tsp-sanity.cpp \
465 common/crypto/store.cpp \
466 common/crypto/store-inmem.cpp \
467 common/crypto/store-cert-add-basic.cpp \
468 common/crypto/RTCrPkcs5Pbkdf2Hmac-openssl.cpp \
469 common/crypto/RTCrRandBytes-openssl.cpp \
470 common/crypto/RTCrStoreCertAddFromJavaKeyStore.cpp \
471 common/crypto/RTCrStoreCertAddWantedFromFishingExpedition.cpp \
472 common/crypto/RTCrStoreCertExportAsPem.cpp \
473 common/crypto/RTCrStoreCreateSnapshotOfUserAndSystemTrustedCAsAndCerts.cpp \
474 common/dbg/dbg.cpp \
475 common/dbg/dbgas.cpp \
476 common/dbg/dbgcfg.cpp \
477 common/dbg/dbgmod.cpp \
478 common/dbg/dbgmodldr.cpp \
479 common/dbg/dbgmodcontainer.cpp \
480 common/dbg/dbgmoddeferred.cpp \
481 common/dbg/dbgmodexports.cpp \
482 common/dbg/dbgmodcodeview.cpp \
483 common/dbg/dbgmoddwarf.cpp \
484 common/dbg/dbgmodmapsym.cpp \
485 common/dbg/dbgmodnm.cpp \
486 common/dvm/dvm.cpp \
487 common/dvm/dvmbsdlabel.cpp \
488 common/dvm/dvmgpt.cpp \
489 common/dvm/dvmmbr.cpp \
490 common/dvm/dvmvfs.cpp \
491 common/efi/efiguid.cpp \
492 common/efi/efitime.cpp \
493 common/efi/efisignaturedb.cpp \
494 common/efi/efivarstorevfs.cpp \
495 common/err/errinfo.cpp \
496 common/err/errinfolog.cpp \
497 common/err/errinfo-alloc.cpp \
498 common/err/errmsg.cpp \
499 common/err/RTErrConvertFromErrno.cpp \
500 common/err/RTErrConvertToErrno.cpp \
501 common/fs/extvfs.cpp \
502 common/fs/fatvfs.cpp \
503 common/fs/isovfs.cpp \
504 common/fs/isomaker.cpp \
505 common/fs/isomakercmd.cpp \
506 common/fs/isomakerimport.cpp \
507 common/fs/ntfsvfs.cpp \
508 common/fs/RTFsCmdLs.cpp \
509 common/ioqueue/ioqueuebase.cpp \
510 common/ioqueue/ioqueue-stdfile-provider.cpp \
511 common/ldr/ldr.cpp \
512 common/ldr/ldrELF.cpp \
513 common/ldr/ldrEx.cpp \
514 common/ldr/ldrFile.cpp \
515 common/ldr/ldrVfsFile.cpp \
516 common/ldr/ldrLX.cpp \
517 common/ldr/ldrMachO.cpp \
518 common/ldr/ldrMemory.cpp \
519 common/ldr/ldrNative.cpp \
520 common/ldr/ldrPE.cpp \
521 common/log/log.cpp \
522 common/log/logellipsis.cpp \
523 common/log/logrel.cpp \
524 common/log/logrelellipsis.cpp \
525 common/log/logcom.cpp \
526 common/log/logformat.cpp \
527 common/log/tracebuf.cpp \
528 common/log/tracedefault.cpp \
529 common/log/tracelogreader.cpp \
530 common/log/tracelogwriter.cpp \
531 common/log/RTLogCreateEx.cpp \
532 common/math/bignum.cpp \
533 common/misc/RTAssertMsg1Weak.cpp \
534 common/misc/RTAssertMsg2.cpp \
535 common/misc/RTAssertMsg2Add.cpp \
536 common/misc/RTAssertMsg2AddWeak.cpp \
537 common/misc/RTAssertMsg2AddWeakV.cpp \
538 common/misc/RTAssertMsg2Weak.cpp \
539 common/misc/RTAssertMsg2WeakV.cpp \
540 common/misc/RTFileModeToFlags.cpp \
541 common/misc/RTFileOpenF.cpp \
542 common/misc/RTFileOpenV.cpp \
543 common/misc/RTMemWipeThoroughly.cpp \
544 common/misc/RTSystemFirmwareTypeName.cpp \
545 common/misc/assert.cpp \
546 common/misc/buildconfig.cpp \
547 common/misc/cidr.cpp \
548 common/misc/expreval.cpp \
549 common/misc/getopt.cpp \
550 common/misc/getoptargv.cpp \
551 common/misc/handle.cpp \
552 common/misc/handletable.cpp \
553 common/misc/handletablectx.cpp \
554 common/misc/handletablesimple.cpp \
555 common/misc/inifile.cpp \
556 common/misc/json.cpp \
557 common/misc/lockvalidator.cpp \
558 common/misc/message.cpp \
559 common/misc/messagerefentry.cpp \
560 common/misc/once.cpp \
561 common/misc/req.cpp \
562 common/misc/reqpool.cpp \
563 common/misc/reqqueue.cpp \
564 common/misc/sanity-c.c \
565 common/misc/sanity-cpp.cpp \
566 common/misc/semspingpong.cpp \
567 common/misc/sg.cpp \
568 common/misc/circbuf.cpp \
569 common/misc/thread.cpp \
570 common/misc/term.cpp \
571 common/misc/uri.cpp \
572 common/net/netaddrstr2.cpp \
573 common/net/macstr.cpp \
574 common/path/rtPathRootSpecLen.cpp \
575 common/path/rtPathVolumeSpecLen.cpp \
576 common/path/RTPathAbsDup.cpp \
577 common/path/RTPathAbsEx.cpp \
578 common/path/RTPathAbsExDup.cpp \
579 common/path/RTPathAppend.cpp \
580 common/path/RTPathAppendEx.cpp \
581 common/path/RTPathCalcRelative.cpp \
582 common/path/RTPathChangeToDosSlashes.cpp \
583 common/path/RTPathChangeToUnixSlashes.cpp \
584 common/path/RTPathCopyComponents.cpp \
585 common/path/RTPathCountComponents.cpp \
586 common/path/RTPathEnsureTrailingSeparator.cpp \
587 common/path/RTPathExt.cpp \
588 common/path/RTPathFilename.cpp \
589 common/path/RTPathFilenameUtf16.cpp \
590 common/path/RTPathFindCommon.cpp \
591 common/path/RTPathGlob.cpp \
592 common/path/RTPathHasExt.cpp \
593 common/path/RTPathHasPath.cpp \
594 common/path/RTPathJoin.cpp \
595 common/path/RTPathJoinA.cpp \
596 common/path/RTPathJoinEx.cpp \
597 common/path/RTPathParentLength.cpp \
598 common/path/RTPathParse.cpp \
599 common/path/RTPathParsedReassemble.cpp \
600 common/path/RTPathParseSimple.cpp \
601 common/path/RTPathPurgeFilename.cpp \
602 common/path/RTPathRealDup.cpp \
603 common/path/RTPathRmCmd.cpp \
604 common/path/RTPathSkipRootSpec.cpp \
605 common/path/RTPathSplit.cpp \
606 common/path/RTPathSplitA.cpp \
607 common/path/RTPathSplitReassemble.cpp \
608 common/path/RTPathStartsWithRoot.cpp \
609 common/path/RTPathStripExt.cpp \
610 common/path/RTPathStripFilename.cpp \
611 common/path/RTPathStripTrailingSlash.cpp \
612 common/path/RTPathTraverseList.cpp \
613 common/path/comparepaths.cpp \
614 common/rand/rand.cpp \
615 common/rand/randadv.cpp \
616 common/rand/randparkmiller.cpp \
617 common/sort/RTSortIsSorted.cpp \
618 common/sort/RTSortApvIsSorted.cpp \
619 common/sort/shellsort.cpp \
620 common/string/RTStrCat.cpp \
621 common/string/RTStrCatEx.cpp \
622 common/string/RTStrCatP.cpp \
623 common/string/RTStrCatPEx.cpp \
624 common/string/RTStrCmp.cpp \
625 common/string/RTStrCopy.cpp \
626 common/string/RTStrCopyEx.cpp \
627 common/string/RTStrCopyP.cpp \
628 common/string/RTStrCopyPEx.cpp \
629 common/string/RTStrNCmp.cpp \
630 common/string/RTStrNLen.cpp \
631 common/string/RTStrNLenEx.cpp \
632 common/string/RTStrPrintHexBytes.cpp \
633 common/string/RTStrStartsWith.cpp \
634 common/string/RTStrIStartsWith.cpp \
635 common/string/RTStrICmpAscii.cpp \
636 common/string/RTStrNICmpAscii.cpp \
637 common/string/RTStrSplit.cpp \
638 common/string/RTStrStr.cpp \
639 common/string/RTUtf16Copy.cpp \
640 common/string/RTUtf16CopyAscii.cpp \
641 common/string/RTUtf16CopyEx.cpp \
642 common/string/RTUtf16Cat.cpp \
643 common/string/RTUtf16CatAscii.cpp \
644 common/string/RTUtf16Chr.cpp \
645 common/string/RTUtf16CmpAscii.cpp \
646 common/string/RTUtf16ICmpAscii.cpp \
647 common/string/RTUtf16End.cpp \
648 common/string/RTUtf16NCmp.cpp \
649 common/string/RTUtf16NCmpAscii.cpp \
650 common/string/RTUtf16NCmpUtf8.cpp \
651 common/string/RTUtf16NICmpAscii.cpp \
652 common/string/RTUtf16NLen.cpp \
653 common/string/RTUtf16NLenEx.cpp \
654 common/string/RTUtf16PrintHexBytes.cpp \
655 common/string/base64.cpp \
656 common/string/base64-utf16.cpp \
657 common/string/simplepattern.cpp \
658 common/string/straprintf.cpp \
659 common/string/strformat.cpp \
660 common/string/RTStrFormat.cpp \
661 common/string/strformatfloat.cpp \
662 common/string/strformatnum.cpp \
663 common/string/strformatrt.cpp \
664 common/string/strformattype.cpp \
665 common/string/strhash1.cpp \
666 common/string/stringalloc.cpp \
667 common/string/strprintf.cpp \
668 common/string/strprintf-ellipsis.cpp \
669 common/string/strprintf2.cpp \
670 common/string/strprintf2-ellipsis.cpp \
671 common/string/strcache.cpp \
672 common/string/strspace.cpp \
673 common/string/strstrip.cpp \
674 common/string/strtofloat.cpp \
675 common/string/strtonum.cpp \
676 common/string/strversion.cpp \
677 common/string/uni.cpp \
678 common/string/unidata-flags.cpp \
679 common/string/unidata-lower.cpp \
680 common/string/unidata-upper.cpp \
681 common/string/utf-16.cpp \
682 common/string/utf-16-case.cpp \
683 common/string/utf-16-latin-1.cpp \
684 common/string/utf-16-printf.cpp \
685 common/string/utf-8.cpp \
686 common/string/utf-8-case.cpp \
687 common/string/utf-8-case2.cpp \
688 common/string/ministring.cpp \
689 common/table/avlgcptr.cpp \
690 common/table/avlhcphys.cpp \
691 common/table/avlgcphys.cpp \
692 common/table/avllu32.cpp \
693 common/table/avlou32.cpp \
694 common/table/avlogcphys.cpp \
695 common/table/avlogcptr.cpp \
696 common/table/avlohcphys.cpp \
697 common/table/avloioport.cpp \
698 common/table/avlpv.cpp \
699 common/table/avlrgcptr.cpp \
700 common/table/avlrogcphys.cpp \
701 common/table/avlrogcptr.cpp \
702 common/table/avlroioport.cpp \
703 common/table/avlroogcptr.cpp \
704 common/table/avlrpv.cpp \
705 common/table/avlruintptr.cpp \
706 common/table/avlrfoff.cpp \
707 common/table/avlru64.cpp \
708 common/table/avlu32.cpp \
709 common/table/avlu64.cpp \
710 common/table/avluintptr.cpp \
711 common/table/avlul.cpp \
712 common/table/table.cpp \
713 common/time/time.cpp \
714 common/time/timeprog.cpp \
715 common/time/timesup.cpp \
716 common/time/timezoneinfo.cpp \
717 common/vfs/vfsbase.cpp \
718 common/vfs/vfschain.cpp \
719 common/vfs/vfsfss2dir.cpp \
720 common/vfs/vfsiosmisc.cpp \
721 common/vfs/vfsmemory.cpp \
722 common/vfs/vfsmisc.cpp \
723 common/vfs/vfsmount.cpp \
724 common/vfs/vfsmsg.cpp \
725 common/vfs/vfsprogress.cpp \
726 common/vfs/vfsreadahead.cpp \
727 common/vfs/vfsstddir.cpp \
728 common/vfs/vfsstdfile.cpp \
729 common/vfs/vfsstdpipe.cpp \
730 common/vfs/vfsprintf.cpp \
731 common/zip/cpiovfs.cpp \
732 common/zip/tar.cpp \
733 common/zip/tarcmd.cpp \
734 common/zip/tarvfs.cpp \
735 common/zip/tarvfswriter.cpp \
736 common/zip/gzipvfs.cpp \
737 common/zip/gzipcmd.cpp \
738 common/zip/pkzip.cpp \
739 common/zip/pkzipvfs.cpp \
740 common/zip/unzipcmd.cpp \
741 common/zip/zip.cpp \
742 generic/createtemp-generic.cpp \
743 generic/critsect-generic.cpp \
744 generic/critsectrw-generic.cpp \
745 generic/env-generic.cpp \
746 generic/http.cpp \
747 generic/RTDirCreateUniqueNumbered-generic.cpp \
748 generic/RTEnvDupEx-generic.cpp \
749 generic/RTFileCopy-generic.cpp \
750 generic/RTFileCopyAttributes-generic.cpp \
751 generic/RTFileCopyEx-generic.cpp \
752 generic/RTFileCopyByHandlesEx-generic.cpp \
753 generic/RTFileCopyPart-generic.cpp \
754 generic/RTFileQuerySize-generic.cpp \
755 generic/RTFileReadAll-generic.cpp \
756 generic/RTFileReadAllEx-generic.cpp \
757 generic/RTFileReadAllByHandle-generic.cpp \
758 generic/RTFileReadAllByHandleEx-generic.cpp \
759 generic/RTFileReadAllFree-generic.cpp \
760 generic/RTLogWriteStdErr-generic.cpp \
761 generic/RTLogWriteStdOut-generic.cpp \
762 generic/RTLogWriteUser-generic.cpp \
763 generic/RTPathGetCurrentDrive-generic.cpp \
764 generic/RTPathIsSame-generic.cpp \
765 generic/RTTimerLRCreate-generic.cpp \
766 generic/rtStrFormatKernelAddress-generic.cpp \
767 generic/mempool-generic.cpp \
768 generic/semfastmutex-generic.cpp \
769 generic/semxroads-generic.cpp \
770 generic/spinlock-generic.cpp \
771 generic/timerlr-generic.cpp \
772 r3/alloc-ef.cpp \
773 r3/alloc.cpp \
774 r3/allocex.cpp \
775 r3/dir.cpp \
776 r3/dir2.cpp \
777 r3/fileio.cpp \
778 r3/fs.cpp \
779 r3/ftp-server.cpp \
780 r3/http-server.cpp \
781 r3/init.cpp \
782 r3/memsafer-r3.cpp \
783 r3/path.cpp \
784 r3/RTPathTemp.cpp \
785 r3/poll.cpp \
786 r3/process.cpp \
787 r3/socket.cpp \
788 r3/stream.cpp \
789 r3/test.cpp \
790 r3/testi.cpp \
791 r3/tcp.cpp \
792 r3/udp.cpp \
793 r3/generic/semspinmutex-r3-generic.cpp \
794 r3/xml.cpp \
795 common/zip/xarvfs.cpp
796
797
798#if1of ($(KBUILD_TARGET_ARCH),amd64 x86)
799# RuntimeBaseR3_SOURCES += common/time/timesupA.asm
800#else
801 RuntimeBaseR3_SOURCES += common/time/timesupref.cpp
802#endif
803
804RuntimeBaseR3_SOURCES.x86 += \
805 generic/RTMpGetDescription-generic.cpp \
806 common/misc/zero.asm \
807 common/misc/RTSystemIsInsideVM-amd64-x86.cpp \
808 common/string/RTStrMemFind32.asm
809RuntimeBaseR3_SOURCES.amd64 += \
810 generic/RTMpGetDescription-generic.cpp \
811 common/misc/zero.asm \
812 common/misc/RTSystemIsInsideVM-amd64-x86.cpp \
813 common/string/RTStrMemFind32.asm
814RuntimeBaseR3_SOURCES.arm32 := \
815 common/asm/ASMBitFirstClear-generic.cpp \
816 common/asm/ASMBitNextClear-generic.cpp \
817 common/asm/ASMBitFirstSet-generic.cpp \
818 common/asm/ASMBitNextSet-generic.cpp \
819 common/asm/ASMMemZeroPage-generic.cpp \
820 common/asm/ASMMemZero32-generic.cpp \
821 common/asm/ASMMemFill32-generic.cpp \
822 common/asm/ASMMemFirstMismatchingU8-generic.cpp \
823 common/asm/ASMMemFirstNonZero-generic.cpp \
824 common/misc/zero-alt.S
825RuntimeBaseR3_SOURCES.arm64 := \
826 common/asm/ASMBitFirstClear-generic.cpp \
827 common/asm/ASMBitNextClear-generic.cpp \
828 common/asm/ASMBitFirstSet-generic.cpp \
829 common/asm/ASMBitNextSet-generic.cpp \
830 common/asm/ASMMemZeroPage-generic.cpp \
831 common/asm/ASMMemZero32-generic.cpp \
832 common/asm/ASMMemFill32-generic.cpp \
833 common/asm/ASMMemFirstMismatchingU8-generic.cpp \
834 common/asm/ASMMemFirstNonZero-generic.cpp \
835 common/misc/zero-alt.S
836RuntimeBaseR3_SOURCES.sparc32 += \
837 generic/RTMpGetDescription-generic-stub.cpp \
838 generic/RTSystemIsInsideVM-generic.cpp \
839 common/asm/ASMBitFirstClear-generic.cpp \
840 common/asm/ASMBitNextClear-generic.cpp \
841 common/asm/ASMBitFirstSet-generic.cpp \
842 common/asm/ASMBitNextSet-generic.cpp \
843 common/asm/ASMMemZeroPage-generic.cpp \
844 common/asm/ASMMemZero32-generic.cpp \
845 common/asm/ASMMemFill32-generic.cpp \
846 common/asm/ASMMemFirstMismatchingU8-generic.cpp \
847 common/asm/ASMMemFirstNonZero-generic.cpp \
848 common/asm/asm-fake.cpp \
849 common/misc/zero-alt.S \
850 common/string/RTStrMemFind32.cpp
851RuntimeBaseR3_SOURCES.sparc64 += \
852 generic/RTMpGetDescription-generic-stub.cpp \
853 generic/RTSystemIsInsideVM-generic.cpp \
854 common/asm/ASMBitFirstClear-generic.cpp \
855 common/asm/ASMBitNextClear-generic.cpp \
856 common/asm/ASMBitFirstSet-generic.cpp \
857 common/asm/ASMBitNextSet-generic.cpp \
858 common/asm/ASMMemZeroPage-generic.cpp \
859 common/asm/ASMMemZero32-generic.cpp \
860 common/asm/ASMMemFill32-generic.cpp \
861 common/asm/ASMMemFirstMismatchingU8-generic.cpp \
862 common/asm/ASMMemFirstNonZero-generic.cpp \
863 common/asm/asm-fake.cpp \
864 common/misc/zero-alt.S \
865 common/string/RTStrMemFind32.cpp
866
867ifdef IPRT_WITH_LZJB
868 RuntimeBaseR3_SOURCES += common/misc/lzjb.c
869endif
870
871# AMD64 / x86 assembly code.
872RuntimeBaseR3_SOURCES.x86 += \
873 common/asm/ASMCpuIdExSlow.asm \
874 common/asm/ASMAtomicUoAndU64.asm \
875 common/asm/ASMAtomicUoAndU32.asm \
876 common/asm/ASMAtomicUoDecU32.asm \
877 common/asm/ASMAtomicUoIncU32.asm \
878 common/asm/ASMAtomicUoOrU64.asm \
879 common/asm/ASMAtomicUoOrU32.asm \
880 common/asm/ASMAtomicUoXorU32.asm \
881 common/asm/ASMMemFirstMismatchingU8.asm \
882 common/asm/ASMRdMsrEx.asm \
883 common/asm/ASMWrMsrEx.asm \
884 common/asm/ASMGetXcr0.asm \
885 common/asm/ASMSetXcr0.asm \
886 common/asm/ASMXSave.asm \
887 common/asm/ASMXRstor.asm \
888 common/asm/ASMFxSave.asm \
889 common/asm/ASMFxRstor.asm \
890 common/asm/ASMSerializeInstruction-cpuid.asm \
891 common/asm/ASMSerializeInstruction-iret.asm \
892 common/asm/ASMSerializeInstruction-rdtscp.asm \
893 common/dbg/dbgstackdumpself.cpp \
894 common/dbg/dbgstackdumpself-amd64-x86.asm \
895 common/math/bignum-amd64-x86.asm \
896 common/string/RTStrEnd.asm
897RuntimeBaseR3_SOURCES.amd64 += \
898 common/asm/ASMCpuIdExSlow.asm \
899 common/asm/ASMAtomicUoAndU64.asm \
900 common/asm/ASMAtomicUoAndU32.asm \
901 common/asm/ASMAtomicUoDecU32.asm \
902 common/asm/ASMAtomicUoIncU32.asm \
903 common/asm/ASMAtomicUoOrU64.asm \
904 common/asm/ASMAtomicUoOrU32.asm \
905 common/asm/ASMAtomicUoXorU32.asm \
906 common/asm/ASMMemFirstMismatchingU8.asm \
907 common/asm/ASMRdMsrEx.asm \
908 common/asm/ASMWrMsrEx.asm \
909 common/asm/ASMGetXcr0.asm \
910 common/asm/ASMSetXcr0.asm \
911 common/asm/ASMXSave.asm \
912 common/asm/ASMXRstor.asm \
913 common/asm/ASMFxSave.asm \
914 common/asm/ASMFxRstor.asm \
915 common/asm/ASMSerializeInstruction-cpuid.asm \
916 common/asm/ASMSerializeInstruction-iret.asm \
917 common/asm/ASMSerializeInstruction-rdtscp.asm \
918 common/dbg/dbgstackdumpself.cpp \
919 common/dbg/dbgstackdumpself-amd64-x86.asm \
920 common/math/bignum-amd64-x86.asm \
921 common/math/RTUInt128MulByU64.asm \
922 common/math/RTUInt128MulByU64Ex.asm \
923 common/string/RTStrEnd.asm
924
925# Some versions of GCC might require this.
926RuntimeBaseR3_SOURCES.x86 += \
927 common/asm/ASMAtomicXchgU64.asm \
928 common/asm/ASMAtomicCmpXchgU64.asm \
929 common/asm/ASMAtomicCmpXchgExU64.asm \
930 common/asm/ASMAtomicReadU64.asm \
931 common/asm/ASMAtomicUoReadU64.asm
932
933# Some non-assembly for non-AMD64 / non-x86 targets:
934RuntimeBaseR3_SOURCES.arm32 += \
935 common/string/RTStrEnd.cpp \
936 common/asm/ASMMultU64ByU32DivByU32-generic.cpp
937RuntimeBaseR3_SOURCES.arm64 += \
938 common/string/RTStrEnd.cpp \
939 common/asm/ASMMultU64ByU32DivByU32-generic.cpp
940RuntimeBaseR3_SOURCES.sparc32 += \
941 common/string/RTStrEnd.cpp \
942 common/asm/ASMMultU64ByU32DivByU32-generic.cpp
943RuntimeBaseR3_SOURCES.sparc64 += \
944 common/string/RTStrEnd.cpp \
945 common/asm/ASMMultU64ByU32DivByU32-generic.cpp
946
947# VBox specific stuff.
948RuntimeBaseR3_SOURCES += \
949 VBox/RTAssertShouldPanic-vbox.cpp \
950 VBox/log-vbox.cpp
951ifneq ($(KBUILD_TARGET),win)
952RuntimeBaseR3_SOURCES += \
953 common/err/errmsgxpcom.cpp
954endif
955if1of ($(KBUILD_TARGET),freebsd linux netbsd openbsd solaris)
956RuntimeBaseR3_SOURCES += \
957 $(if $(VBOX_WITH_DBUS),VBox/dbus.cpp,)
958endif
959
960VBOX_WITH_NT_DIRENUM = 1
961RuntimeBaseR3_SOURCES.win = \
962 common/dbg/dbgmoddbghelp.cpp \
963 common/ioqueue/ioqueue-aiofile-provider.cpp \
964 generic/cdrom-generic.cpp \
965 generic/RTDirExists-generic.cpp \
966 generic/RTDirSetMode-generic.cpp \
967 generic/RTDirSetTimes-generic.cpp \
968 generic/fileio-sg-generic.cpp \
969 generic/fileio-sg-at-generic.cpp \
970 generic/RTFileCopyPartEx-generic.cpp \
971 generic/RTFileExists-generic.cpp \
972 generic/RTFileSetAllocationSize-generic.cpp \
973 generic/RTMpGetCurFrequency-generic.cpp \
974 generic/RTMpGetMaxFrequency-generic.cpp \
975 generic/RTRandAdvCreateSystemFaster-generic.cpp \
976 generic/RTRandAdvCreateSystemTruer-generic.cpp \
977 generic/RTSemEventWait-2-ex-generic.cpp \
978 generic/RTSemEventWaitNoResume-2-ex-generic.cpp \
979 generic/RTSemEventMultiWait-2-ex-generic.cpp \
980 generic/RTSemEventMultiWaitNoResume-2-ex-generic.cpp \
981 generic/RTSemMutexRequest-generic.cpp \
982 generic/RTSemMutexRequestDebug-generic.cpp \
983 generic/RTTimerCreate-generic.cpp \
984 generic/RTThreadSetAffinityToCpu-generic.cpp \
985 generic/mppresent-generic-online.cpp \
986 generic/semrw-$(if-expr defined(VBOX_WITH_LOCKLESS_SEMRW),lockless-,)generic.cpp \
987 generic/uuid-generic.cpp \
988 generic/RTProcDaemonize-generic.cpp \
989 generic/RTProcIsRunningByName-generic.cpp \
990 generic/RTThreadGetNativeState-generic.cpp \
991 nt/RTErrConvertFromNtStatus.cpp \
992 nt/RTNtPathExpand8dot3Path.cpp \
993 nt/RTNtPathExpand8dot3PathA.cpp \
994 nt/RTNtPathFindPossible8dot3Name.cpp \
995 nt/fileioutils-nt.cpp \
996 r3/generic/RTLocaleQueryLocaleName-r3-generic.cpp \
997 r3/nt/dirrel-r3-nt.cpp \
998 r3/nt/fs-nt.cpp \
999 r3/nt/pathint-nt.cpp \
1000 r3/nt/RTFileQueryFsSizes-nt.cpp \
1001 r3/nt/RTFileSetMode-r3-nt.cpp \
1002 r3/nt/RTPathQueryInfo-nt.cpp \
1003 r3/nt/RTPathSetMode-r3-nt.cpp \
1004 r3/nt/RTProcQueryParent-r3-nt.cpp \
1005 nt/semevent-nt.cpp \
1006 nt/RTSemEventGetResolution-nt.cpp \
1007 nt/semeventmulti-nt.cpp \
1008 nt/RTSemEventMultiGetResolution-nt.cpp \
1009 r3/win/env-win.cpp \
1010 r3/win/RTCrStoreCreateSnapshotById-win.cpp \
1011 r3/win/RTFileQuerySectorSize-win.cpp \
1012 r3/win/RTHandleGetStandard-win.cpp \
1013 r3/win/RTLocaleQueryNormalizedBaseLocaleName-win.cpp \
1014 r3/win/RTLocaleQueryUserCountryCode-win.cpp \
1015 r3/win/RTSystemQueryOSInfo-win.cpp \
1016 r3/win/RTSystemShutdown-win.cpp \
1017 r3/win/RTSystemQueryDmiString-win.cpp \
1018 r3/win/RTSystemFirmware-win.cpp \
1019 r3/win/RTSystemQueryTotalRam-win.cpp \
1020 r3/win/RTTimeZoneGetCurrent-win.cpp \
1021 r3/win/alloc-win.cpp \
1022 r3/win/allocex-win.cpp \
1023 r3/win/dir-win.cpp \
1024 $(if-expr defined(VBOX_WITH_NT_DIRENUM),r3/nt/direnum-r3-nt.cpp,r3/win/direnum-win.cpp generic/RTDirQueryInfo-generic.cpp) \
1025 r3/win/errvars-win.cpp \
1026 r3/win/fileaio-win.cpp \
1027 r3/win/fileio-win.cpp \
1028 r3/win/init-win.cpp \
1029 r3/win/krnlmod-win.cpp \
1030 r3/win/ldrNative-win.cpp \
1031 r3/win/localipc-win.cpp \
1032 r3/win/mp-win.cpp \
1033 r3/win/path-win.cpp \
1034 r3/win/pathint-win.cpp \
1035 r3/win/pipe-win.cpp \
1036 r3/win/process-win.cpp \
1037 r3/win/RTLogWriteDebugger-win.cpp \
1038 r3/win/rtProcInitExePath-win.cpp \
1039 r3/win/sched-win.cpp \
1040 r3/win/semmutex-win.cpp \
1041 r3/win/serialport-win.cpp \
1042 r3/win/shmem-win.cpp \
1043 r3/win/symlink-win.cpp \
1044 r3/win/system-get-nt-xxx-win.cpp \
1045 r3/win/thread-win.cpp \
1046 r3/win/thread2-win.cpp \
1047 $(if-expr 1,r3/win/time-win.cpp,r3/nt/time-nt.cpp) \
1048 r3/win/time2-win.cpp \
1049 r3/win/timer-win.cpp \
1050 r3/win/tls-win.cpp \
1051 r3/win/tpm-win.cpp \
1052 r3/win/utf16locale-win.cpp \
1053 r3/win/utf8-win.cpp \
1054 r3/win/RTUuidCreate-win.cpp \
1055 win/errmsgwin.cpp \
1056 win/RTErrConvertFromWin32.cpp \
1057 common/string/mempcpy.asm
1058
1059RuntimeBaseR3_SOURCES.win.amd64 := \
1060 $(RuntimeWin64ASM_SOURCES) \
1061 common/string/memrchr.asm
1062RuntimeBaseR3_SOURCES.win.x86 := \
1063 $(RuntimeWin32ASM_SOURCES) \
1064 common/string/memrchr.asm
1065
1066RuntimeBaseR3_SOURCES.linux = \
1067 common/ioqueue/ioqueue-aiofile-provider.cpp \
1068 generic/cdrom-generic.cpp \
1069 generic/RTCrStoreCreateSnapshotById-generic.cpp \
1070 generic/RTDirQueryInfo-generic.cpp \
1071 generic/RTDirSetMode-generic.cpp \
1072 generic/RTDirSetTimes-generic.cpp \
1073 generic/RTFileMove-generic.cpp \
1074 generic/RTLogWriteDebugger-generic.cpp \
1075 generic/RTPathGetCurrentOnDrive-generic.cpp \
1076 generic/RTProcDaemonize-generic.cpp \
1077 generic/RTSemEventMultiWait-2-ex-generic.cpp \
1078 generic/RTSemEventMultiWaitNoResume-2-ex-generic.cpp \
1079 generic/RTTimeLocalNow-generic.cpp \
1080 generic/RTTimerCreate-generic.cpp \
1081 generic/RTThreadSetAffinityToCpu-generic.cpp \
1082 generic/RTUuidCreate-generic.cpp \
1083 generic/mppresent-generic.cpp \
1084 generic/utf16locale-generic.cpp \
1085 generic/uuid-generic.cpp \
1086 r3/generic/RTLocaleQueryLocaleName-r3-generic.cpp \
1087 r3/generic/RTLocaleQueryNormalizedBaseLocaleName-r3-generic.cpp \
1088 r3/generic/RTLocaleQueryUserCountryCode-r3-generic.cpp \
1089 r3/generic/dirrel-r3-generic.cpp \
1090 r3/posix/allocex-r3-posix.cpp \
1091 r3/linux/RTThreadGetNativeState-linux.cpp \
1092 r3/linux/fileaio-linux.cpp \
1093 r3/linux/ioqueue-iouringfile-provider.cpp \
1094 r3/linux/krnlmod-linux.cpp \
1095 r3/linux/mp-linux.cpp \
1096 r3/linux/rtProcInitExePath-linux.cpp \
1097 r3/linux/sched-linux.cpp \
1098 r3/linux/sysfs.cpp \
1099 r3/linux/time-linux.cpp \
1100 r3/linux/thread-affinity-linux.cpp \
1101 r3/linux/tpm-linux.cpp \
1102 r3/linux/RTFileCopyPartEx-linux.cpp \
1103 r3/linux/RTFileQuerySectorSize-linux.cpp \
1104 r3/linux/RTFileSetAllocationSize-linux.cpp \
1105 r3/linux/RTProcIsRunningByName-linux.cpp \
1106 r3/linux/RTSystemFirmware-linux.cpp \
1107 r3/linux/RTSystemQueryDmiString-linux.cpp \
1108 r3/linux/RTSystemShutdown-linux.cpp \
1109 r3/posix/RTFileQueryFsSizes-posix.cpp \
1110 r3/posix/RTHandleGetStandard-posix.cpp \
1111 r3/posix/RTMemProtect-posix.cpp \
1112 r3/posix/RTPathUserHome-posix.cpp \
1113 r3/posix/RTSystemQueryOSInfo-posix.cpp \
1114 r3/linux/systemmem-linux.cpp \
1115 r3/posix/RTTimeNow-posix.cpp \
1116 r3/posix/RTTimeSet-posix.cpp \
1117 r3/posix/RTTimeZoneGetCurrent-posix.cpp \
1118 r3/posix/rtmempage-exec-mmap-heap-posix.cpp \
1119 r3/posix/dir-posix.cpp \
1120 r3/posix/env-posix.cpp \
1121 r3/posix/errvars-posix.cpp \
1122 r3/posix/fileio-posix.cpp \
1123 r3/posix/fileio2-posix.cpp \
1124 r3/posix/fileio-at-posix.cpp \
1125 r3/posix/fileio-sg-posix.cpp \
1126 r3/posix/fileio-sg-at-posix.cpp \
1127 r3/posix/filelock-posix.cpp \
1128 r3/posix/fs-posix.cpp \
1129 r3/posix/fs2-posix.cpp \
1130 r3/posix/fs3-posix.cpp \
1131 r3/posix/ldrNative-posix.cpp \
1132 r3/posix/localipc-posix.cpp \
1133 r3/posix/path-posix.cpp \
1134 r3/posix/path2-posix.cpp \
1135 r3/posix/pathhost-posix.cpp \
1136 r3/posix/RTPathUserDocuments-posix.cpp \
1137 r3/posix/pipe-posix.cpp \
1138 r3/posix/process-posix.cpp \
1139 r3/posix/process-creation-posix.cpp \
1140 r3/posix/rand-posix.cpp \
1141 r3/posix/semrw-posix.cpp \
1142 r3/posix/serialport-posix.cpp \
1143 r3/posix/shmem-posix.cpp \
1144 r3/posix/symlink-posix.cpp \
1145 r3/posix/thread-posix.cpp \
1146 r3/posix/thread2-posix.cpp \
1147 r3/posix/timelocal-posix.cpp \
1148 r3/posix/timer-posix.cpp \
1149 r3/posix/tls-posix.cpp \
1150 r3/posix/utf8-posix.cpp
1151ifdef IPRT_WITH_FUTEX_BASED_SEMS
1152 RuntimeBaseR3_SOURCES.linux += \
1153 r3/linux/semevent-linux.cpp \
1154 r3/linux/semeventmulti-linux.cpp \
1155 r3/linux/semmutex-linux.cpp
1156else
1157 RuntimeBaseR3_SOURCES.linux.x86 += \
1158 r3/posix/semevent-posix.cpp \
1159 r3/posix/semeventmulti-posix.cpp \
1160 r3/posix/semmutex-posix.cpp
1161 RuntimeBaseR3_SOURCES.linux.amd64 += \
1162 r3/linux/semevent-linux.cpp \
1163 r3/linux/semeventmulti-linux.cpp
1164 ifdef RT_NEW_LINUX_MUTEX_CODE
1165 RuntimeBaseR3_SOURCES.linux.amd64 += \
1166 r3/linux/semmutex-linux.cpp
1167 else
1168 RuntimeBaseR3_SOURCES.linux.amd64 += \
1169 r3/posix/semmutex-posix.cpp
1170 endif
1171endif
1172
1173RuntimeBaseR3_SOURCES.os2 = \
1174 common/string/memrchr.asm \
1175 generic/cdrom-generic.cpp \
1176 generic/RTCrStoreCreateSnapshotById-generic.cpp \
1177 generic/RTDirQueryInfo-generic.cpp \
1178 generic/RTDirSetMode-generic.cpp \
1179 generic/RTDirSetTimes-generic.cpp \
1180 generic/fileio-at-generic.cpp \
1181 generic/fileio-sg-generic.cpp \
1182 generic/fileio-sg-at-generic.cpp \
1183 generic/RTFileCopyPartEx-generic.cpp \
1184 generic/RTFileMove-generic.cpp \
1185 generic/RTFileQuerySectorSize-generic.cpp \
1186 generic/RTFileSetAllocationSize-generic.cpp \
1187 generic/RTLogWriteDebugger-generic.cpp \
1188 generic/RTPathGetCurrentOnDrive-generic.cpp \
1189 generic/RTProcDaemonize-generic.cpp \
1190 generic/RTRandAdvCreateSystemFaster-generic.cpp \
1191 generic/RTRandAdvCreateSystemTruer-generic.cpp \
1192 generic/RTSystemQueryDmiString-generic.cpp \
1193 generic/RTSystemFirmware-generic.cpp \
1194 generic/RTSystemShutdown-generic.cpp \
1195 generic/RTTimeLocalNow-generic.cpp \
1196 generic/RTTimerCreate-generic.cpp \
1197 generic/RTThreadSetAffinityToCpu-generic.cpp \
1198 generic/RTUuidCreate-generic.cpp \
1199 generic/mppresent-generic.cpp \
1200 generic/RTSemEventWait-generic.cpp \
1201 generic/RTSemEventMultiWait-generic.cpp \
1202 generic/RTSemMutexRequest-generic.cpp \
1203 generic/RTSemMutexRequestDebug-generic.cpp \
1204 generic/semrw-$(if-expr defined(VBOX_WITH_LOCKLESS_SEMRW),lockless-,)generic.cpp \
1205 generic/timer-generic.cpp \
1206 generic/utf16locale-generic.cpp \
1207 generic/uuid-generic.cpp \
1208 generic/RTMpGetCoreCount-generic.cpp \
1209 generic/RTMpGetOnlineCoreCount-generic.cpp \
1210 generic/RTMpGetCurFrequency-generic.cpp \
1211 generic/RTMpGetMaxFrequency-generic.cpp \
1212 generic/RTProcIsRunningByName-generic.cpp \
1213 generic/RTThreadGetNativeState-generic.cpp \
1214 os2/RTErrConvertFromOS2.cpp \
1215 r3/generic/allocex-r3-generic.cpp \
1216 r3/generic/RTLocaleQueryLocaleName-r3-generic.cpp \
1217 r3/generic/RTLocaleQueryNormalizedBaseLocaleName-r3-generic.cpp \
1218 r3/generic/RTLocaleQueryUserCountryCode-r3-generic.cpp \
1219 r3/generic/RTTimeZoneGetCurrent-generic.cpp \
1220 r3/generic/dirrel-r3-generic.cpp \
1221 r3/os2/RTTimeSet-os2.cpp \
1222 r3/os2/filelock-os2.cpp \
1223 r3/os2/mp-os2.cpp \
1224 r3/os2/pipe-os2.cpp \
1225 r3/os2/rtProcInitExePath-os2.cpp \
1226 r3/os2/sched-os2.cpp \
1227 r3/os2/sems-os2.cpp \
1228 r3/os2/serialport-os2.cpp \
1229 r3/os2/systemmem-os2.cpp \
1230 r3/os2/thread-os2.cpp \
1231 r3/os2/time-os2.cpp \
1232 r3/posix/RTFileQueryFsSizes-posix.cpp \
1233 r3/posix/RTHandleGetStandard-posix.cpp \
1234 r3/posix/RTMemProtect-posix.cpp \
1235 r3/posix/RTPathUserHome-posix.cpp \
1236 r3/posix/RTSystemQueryOSInfo-posix.cpp \
1237 r3/posix/RTTimeNow-posix.cpp \
1238 r3/posix/dir-posix.cpp \
1239 r3/posix/env-posix.cpp \
1240 r3/posix/errvars-posix.cpp \
1241 r3/posix/fileio-posix.cpp \
1242 r3/posix/fileio2-posix.cpp \
1243 r3/posix/fs-posix.cpp \
1244 r3/posix/fs2-posix.cpp \
1245 r3/posix/fs3-posix.cpp \
1246 r3/posix/ldrNative-posix.cpp \
1247 r3/posix/localipc-posix.cpp \
1248 r3/posix/path-posix.cpp \
1249 r3/posix/path2-posix.cpp \
1250 r3/posix/pathhost-posix.cpp \
1251 r3/posix/rtmempage-exec-mmap-heap-posix.cpp \
1252 r3/posix/RTPathUserDocuments-posix.cpp \
1253 r3/posix/process-posix.cpp \
1254 r3/posix/process-creation-posix.cpp \
1255 r3/posix/symlink-posix.cpp \
1256 r3/posix/timelocal-posix.cpp \
1257 r3/posix/utf8-posix.cpp
1258
1259RuntimeBaseR3_SOURCES.darwin = \
1260 common/ioqueue/ioqueue-aiofile-provider.cpp \
1261 darwin/RTErrConvertFromDarwin.cpp \
1262 darwin/RTErrConvertFromDarwinCOM.cpp \
1263 darwin/RTErrConvertFromDarwinIO.cpp \
1264 darwin/RTErrConvertFromDarwinKern.cpp \
1265 generic/cdrom-generic.cpp \
1266 generic/RTDirQueryInfo-generic.cpp \
1267 generic/RTDirSetMode-generic.cpp \
1268 generic/RTDirSetTimes-generic.cpp \
1269 generic/RTFileCopyPartEx-generic.cpp \
1270 generic/RTFileMove-generic.cpp \
1271 generic/RTFileSetAllocationSize-generic.cpp \
1272 generic/RTLogWriteDebugger-generic.cpp \
1273 generic/RTPathGetCurrentOnDrive-generic.cpp \
1274 generic/RTProcDaemonize-generic.cpp \
1275 generic/RTThreadGetAffinity-stub-generic.cpp \
1276 generic/RTThreadSetAffinity-stub-generic.cpp \
1277 generic/RTThreadSetAffinityToCpu-generic.cpp \
1278 generic/RTTimeLocalNow-generic.cpp \
1279 generic/RTTimerCreate-generic.cpp \
1280 generic/RTUuidCreate-generic.cpp \
1281 generic/mppresent-generic.cpp \
1282 generic/RTSemEventMultiWait-2-ex-generic.cpp \
1283 generic/RTSemEventMultiWaitNoResume-2-ex-generic.cpp \
1284 generic/semrw-$(if-expr defined(VBOX_WITH_LOCKLESS_SEMRW),lockless-,)generic.cpp \
1285 generic/RTSystemShutdown-generic.cpp \
1286 generic/timer-generic.cpp \
1287 generic/utf16locale-generic.cpp \
1288 generic/uuid-generic.cpp\
1289 generic/RTProcIsRunningByName-generic.cpp \
1290 generic/RTThreadGetNativeState-generic.cpp \
1291 generic/RTSystemFirmware-generic.cpp \
1292 r3/darwin/RTCrStoreCreateSnapshotById-darwin.cpp \
1293 r3/darwin/filelock-darwin.cpp \
1294 r3/darwin/RTFileQuerySectorSize-darwin.cpp \
1295 r3/darwin/krnlmod-darwin.cpp \
1296 r3/darwin/mp-darwin.cpp \
1297 r3/darwin/pathhost-darwin.cpp \
1298 r3/darwin/rtProcInitExePath-darwin.cpp \
1299 r3/darwin/RTSystemQueryDmiString-darwin.cpp \
1300 r3/darwin/sched-darwin.cpp \
1301 r3/darwin/systemmem-darwin.cpp \
1302 r3/darwin/time-darwin.cpp \
1303 r3/darwin/RTPathUserDocuments-darwin.cpp \
1304 r3/generic/allocex-r3-generic.cpp \
1305 r3/generic/RTLocaleQueryLocaleName-r3-generic.cpp \
1306 r3/generic/RTLocaleQueryNormalizedBaseLocaleName-r3-generic.cpp \
1307 r3/generic/RTLocaleQueryUserCountryCode-r3-generic.cpp \
1308 r3/generic/dirrel-r3-generic.cpp \
1309 r3/posix/RTFileQueryFsSizes-posix.cpp \
1310 r3/posix/RTHandleGetStandard-posix.cpp \
1311 r3/posix/RTMemProtect-posix.cpp \
1312 r3/posix/RTPathUserHome-posix.cpp \
1313 r3/posix/RTSystemQueryOSInfo-posix.cpp \
1314 r3/posix/RTTimeSet-posix.cpp \
1315 r3/posix/RTTimeZoneGetCurrent-posix.cpp \
1316 r3/posix/dir-posix.cpp \
1317 r3/posix/env-posix.cpp \
1318 r3/posix/errvars-posix.cpp \
1319 r3/posix/fileaio-posix.cpp \
1320 r3/posix/fileio-posix.cpp \
1321 r3/posix/fileio2-posix.cpp \
1322 r3/posix/fileio-at-posix.cpp \
1323 r3/posix/fileio-sg-posix.cpp \
1324 r3/posix/fileio-sg-at-posix.cpp \
1325 r3/posix/fs-posix.cpp \
1326 r3/posix/fs2-posix.cpp \
1327 r3/posix/fs3-posix.cpp \
1328 r3/posix/ldrNative-posix.cpp \
1329 r3/posix/localipc-posix.cpp \
1330 r3/posix/rtmempage-exec-mmap-heap-posix.cpp \
1331 r3/posix/path-posix.cpp \
1332 r3/posix/path2-posix.cpp \
1333 r3/posix/pipe-posix.cpp \
1334 r3/posix/process-posix.cpp \
1335 r3/posix/process-creation-posix.cpp \
1336 r3/posix/rand-posix.cpp \
1337 r3/posix/semevent-posix.cpp \
1338 r3/posix/semeventmulti-posix.cpp \
1339 r3/posix/semmutex-posix.cpp \
1340 r3/posix/serialport-posix.cpp \
1341 r3/posix/symlink-posix.cpp \
1342 r3/posix/shmem-posix.cpp \
1343 r3/posix/thread-posix.cpp \
1344 r3/posix/thread2-posix.cpp \
1345 r3/posix/timelocal-posix.cpp \
1346 r3/posix/tls-posix.cpp \
1347 r3/posix/utf8-posix.cpp
1348RuntimeBaseR3_SOURCES.darwin.x86 += \
1349 common/string/mempcpy.asm \
1350 common/string/memrchr.asm
1351RuntimeBaseR3_SOURCES.darwin.amd64 += \
1352 common/string/mempcpy.asm \
1353 common/string/memrchr.asm
1354RuntimeBaseR3_SOURCES.darwin.arm32 += \
1355 common/string/mempcpy.cpp \
1356 common/string/memrchr.cpp \
1357 r3/darwin/RTMpGetDescription-generic.cpp
1358RuntimeBaseR3_SOURCES.darwin.arm64 += \
1359 common/string/mempcpy.cpp \
1360 common/string/memrchr.cpp \
1361 r3/darwin/RTMpGetDescription-generic.cpp
1362
1363## @todo Make BSD sched, implement RTMP*.
1364RuntimeBaseR3_SOURCES.freebsd = \
1365 common/ioqueue/ioqueue-aiofile-provider.cpp \
1366 generic/cdrom-generic.cpp \
1367 generic/RTCrStoreCreateSnapshotById-generic.cpp \
1368 generic/RTDirQueryInfo-generic.cpp \
1369 generic/RTDirSetMode-generic.cpp \
1370 generic/RTDirSetTimes-generic.cpp \
1371 generic/RTFileCopyPartEx-generic.cpp \
1372 generic/RTFileMove-generic.cpp \
1373 generic/RTFileSetAllocationSize-generic.cpp \
1374 generic/RTLogWriteDebugger-generic.cpp \
1375 generic/RTPathGetCurrentOnDrive-generic.cpp \
1376 generic/RTSemEventMultiWait-2-ex-generic.cpp \
1377 generic/RTSemEventMultiWaitNoResume-2-ex-generic.cpp \
1378 generic/RTSystemQueryDmiString-generic.cpp \
1379 generic/RTSystemFirmware-generic.cpp \
1380 generic/RTSystemShutdown-generic.cpp \
1381 generic/RTThreadGetAffinity-stub-generic.cpp \
1382 generic/RTThreadSetAffinity-stub-generic.cpp \
1383 generic/RTThreadSetAffinityToCpu-generic.cpp \
1384 generic/RTTimeLocalNow-generic.cpp \
1385 generic/RTTimerCreate-generic.cpp \
1386 generic/RTUuidCreate-generic.cpp \
1387 generic/mppresent-generic.cpp \
1388 generic/sched-generic.cpp \
1389 generic/utf16locale-generic.cpp \
1390 generic/uuid-generic.cpp \
1391 generic/RTMpCpuId-generic.cpp \
1392 generic/RTMpGetCoreCount-generic.cpp \
1393 generic/RTMpGetOnlineCoreCount-generic.cpp \
1394 generic/RTProcDaemonize-generic.cpp \
1395 generic/RTProcIsRunningByName-generic.cpp \
1396 generic/RTThreadGetNativeState-generic.cpp \
1397 r3/freebsd/fileaio-freebsd.cpp \
1398 r3/freebsd/RTFileQuerySectorSize-freebsd.cpp \
1399 r3/freebsd/mp-freebsd.cpp \
1400 r3/freebsd/systemmem-freebsd.cpp \
1401 r3/freebsd/rtProcInitExePath-freebsd.cpp \
1402 r3/generic/allocex-r3-generic.cpp \
1403 r3/generic/RTLocaleQueryLocaleName-r3-generic.cpp \
1404 r3/generic/RTLocaleQueryNormalizedBaseLocaleName-r3-generic.cpp \
1405 r3/generic/RTLocaleQueryUserCountryCode-r3-generic.cpp \
1406 r3/generic/dirrel-r3-generic.cpp \
1407 r3/posix/RTFileQueryFsSizes-posix.cpp \
1408 r3/posix/RTHandleGetStandard-posix.cpp \
1409 r3/posix/RTMemProtect-posix.cpp \
1410 r3/posix/RTPathUserHome-posix.cpp \
1411 r3/posix/RTSystemQueryOSInfo-posix.cpp \
1412 r3/posix/RTTimeNow-posix.cpp \
1413 r3/posix/RTTimeSet-posix.cpp \
1414 r3/posix/RTTimeZoneGetCurrent-posix.cpp \
1415 r3/posix/dir-posix.cpp \
1416 r3/posix/env-posix.cpp \
1417 r3/posix/errvars-posix.cpp \
1418 r3/posix/fileio-posix.cpp \
1419 r3/posix/fileio2-posix.cpp \
1420 r3/posix/fileio-at-posix.cpp \
1421 r3/posix/fileio-sg-posix.cpp \
1422 r3/posix/fileio-sg-at-posix.cpp \
1423 r3/posix/filelock-posix.cpp \
1424 r3/posix/fs-posix.cpp \
1425 r3/posix/fs2-posix.cpp \
1426 r3/posix/fs3-posix.cpp \
1427 r3/posix/ldrNative-posix.cpp \
1428 r3/posix/localipc-posix.cpp \
1429 r3/posix/rtmempage-exec-mmap-heap-posix.cpp \
1430 r3/posix/path-posix.cpp \
1431 r3/posix/path2-posix.cpp \
1432 r3/posix/pathhost-posix.cpp \
1433 r3/posix/RTPathUserDocuments-posix.cpp \
1434 r3/posix/pipe-posix.cpp \
1435 r3/posix/process-posix.cpp \
1436 r3/posix/process-creation-posix.cpp \
1437 r3/posix/rand-posix.cpp \
1438 r3/posix/semevent-posix.cpp \
1439 r3/posix/semeventmulti-posix.cpp \
1440 r3/posix/semmutex-posix.cpp \
1441 r3/posix/semrw-posix.cpp \
1442 r3/posix/serialport-posix.cpp \
1443 r3/posix/symlink-posix.cpp \
1444 r3/posix/shmem-posix.cpp \
1445 r3/posix/thread-posix.cpp \
1446 r3/posix/thread2-posix.cpp \
1447 r3/posix/time-posix.cpp \
1448 r3/posix/timelocal-posix.cpp \
1449 r3/posix/timer-posix.cpp \
1450 r3/posix/tls-posix.cpp \
1451 r3/posix/utf8-posix.cpp
1452
1453RuntimeBaseR3_SOURCES.netbsd = \
1454 generic/cdrom-generic.cpp \
1455 generic/RTDirQueryInfo-generic.cpp \
1456 generic/RTDirSetMode-generic.cpp \
1457 generic/RTDirSetTimes-generic.cpp \
1458 generic/RTFileCopyPartEx-generic.cpp \
1459 generic/RTFileMove-generic.cpp \
1460 generic/RTFileQuerySectorSize-generic.cpp \
1461 generic/RTLogWriteDebugger-generic.cpp \
1462 generic/RTPathGetCurrentOnDrive-generic.cpp \
1463 generic/RTSemEventMultiWait-2-ex-generic.cpp \
1464 generic/RTSemEventMultiWaitNoResume-2-ex-generic.cpp \
1465 generic/RTSystemQueryDmiString-generic.cpp \
1466 generic/RTSystemFirmware-generic.cpp \
1467 generic/RTSystemShutdown-generic.cpp \
1468 generic/RTThreadGetAffinity-stub-generic.cpp \
1469 generic/RTThreadSetAffinity-stub-generic.cpp \
1470 generic/RTThreadSetAffinityToCpu-generic.cpp \
1471 generic/RTTimeLocalNow-generic.cpp \
1472 generic/RTTimerCreate-generic.cpp \
1473 generic/RTUuidCreate-generic.cpp \
1474 generic/mppresent-generic.cpp \
1475 generic/sched-generic.cpp \
1476 generic/utf16locale-generic.cpp \
1477 generic/uuid-generic.cpp \
1478 generic/RTMpCpuId-generic.cpp \
1479 generic/RTMpGetCoreCount-generic.cpp \
1480 generic/RTMpGetOnlineCoreCount-generic.cpp \
1481 generic/RTProcDaemonize-generic.cpp \
1482 generic/RTProcIsRunningByName-generic.cpp \
1483 generic/RTThreadGetNativeState-generic.cpp \
1484 r3/netbsd/rtProcInitExePath-netbsd.cpp \
1485 r3/generic/allocex-r3-generic.cpp \
1486 r3/generic/RTLocaleQueryLocaleName-r3-generic.cpp \
1487 r3/generic/RTLocaleQueryNormalizedBaseLocaleName-r3-generic.cpp \
1488 r3/generic/RTLocaleQueryUserCountryCode-r3-generic.cpp \
1489 r3/generic/dirrel-r3-generic.cpp \
1490 r3/posix/RTFileQueryFsSizes-posix.cpp \
1491 r3/posix/RTFileSetAllocationSize-posix.cpp \
1492 r3/posix/RTHandleGetStandard-posix.cpp \
1493 r3/posix/RTMemProtect-posix.cpp \
1494 r3/posix/RTPathUserHome-posix.cpp \
1495 r3/posix/RTSystemQueryOSInfo-posix.cpp \
1496 r3/posix/RTSystemQueryTotalRam-posix.cpp \
1497 r3/posix/RTTimeNow-posix.cpp \
1498 r3/posix/RTTimeSet-posix.cpp \
1499 r3/posix/RTTimeZoneGetCurrent-posix.cpp \
1500 r3/posix/dir-posix.cpp \
1501 r3/posix/env-posix.cpp \
1502 r3/posix/errvars-posix.cpp \
1503 r3/posix/fileio-posix.cpp \
1504 r3/posix/fileio2-posix.cpp \
1505 r3/posix/fileio-at-posix.cpp \
1506 r3/posix/fileio-sg-posix.cpp \
1507 r3/posix/fileio-sg-at-posix.cpp \
1508 r3/posix/filelock-posix.cpp \
1509 r3/posix/fs-posix.cpp \
1510 r3/posix/fs2-posix.cpp \
1511 r3/posix/fs3-posix.cpp \
1512 r3/posix/ldrNative-posix.cpp \
1513 r3/posix/rtmempage-exec-mmap-heap-posix.cpp \
1514 r3/posix/path-posix.cpp \
1515 r3/posix/path2-posix.cpp \
1516 r3/posix/pathhost-posix.cpp \
1517 r3/posix/RTPathUserDocuments-posix.cpp \
1518 r3/posix/pipe-posix.cpp \
1519 r3/posix/process-posix.cpp \
1520 r3/posix/process-creation-posix.cpp \
1521 r3/posix/rand-posix.cpp \
1522 r3/posix/semevent-posix.cpp \
1523 r3/posix/semeventmulti-posix.cpp \
1524 r3/posix/semmutex-posix.cpp \
1525 r3/posix/semrw-posix.cpp \
1526 r3/posix/serialport-posix.cpp \
1527 r3/posix/symlink-posix.cpp \
1528 r3/posix/shmem-posix.cpp \
1529 r3/posix/thread-posix.cpp \
1530 r3/posix/thread2-posix.cpp \
1531 r3/posix/time-posix.cpp \
1532 r3/posix/timelocal-posix.cpp \
1533 r3/posix/timer-posix.cpp \
1534 r3/posix/tls-posix.cpp \
1535 r3/posix/utf8-posix.cpp
1536
1537RuntimeBaseR3_SOURCES.solaris = \
1538 common/ioqueue/ioqueue-aiofile-provider.cpp \
1539 generic/cdrom-generic.cpp \
1540 generic/RTCrStoreCreateSnapshotById-generic.cpp \
1541 generic/RTDirQueryInfo-generic.cpp \
1542 generic/RTDirSetMode-generic.cpp \
1543 generic/RTDirSetTimes-generic.cpp \
1544 generic/RTFileCopyPartEx-generic.cpp \
1545 generic/RTFileMove-generic.cpp \
1546 generic/RTLogWriteDebugger-generic.cpp \
1547 generic/RTPathGetCurrentOnDrive-generic.cpp \
1548 generic/RTProcDaemonize-generic.cpp \
1549 generic/RTProcIsRunningByName-generic.cpp \
1550 generic/RTSemEventMultiWait-2-ex-generic.cpp \
1551 generic/RTSemEventMultiWaitNoResume-2-ex-generic.cpp \
1552 generic/RTThreadSetAffinityToCpu-generic.cpp \
1553 generic/RTTimeLocalNow-generic.cpp \
1554 generic/RTTimerCreate-generic.cpp \
1555 generic/RTUuidCreate-generic.cpp \
1556 generic/sched-generic.cpp \
1557 generic/utf16locale-generic.cpp \
1558 generic/uuid-generic.cpp \
1559 generic/RTThreadGetNativeState-generic.cpp \
1560 generic/RTSystemFirmware-generic.cpp \
1561 r3/generic/allocex-r3-generic.cpp \
1562 r3/generic/RTLocaleQueryLocaleName-r3-generic.cpp \
1563 r3/generic/RTLocaleQueryNormalizedBaseLocaleName-r3-generic.cpp \
1564 r3/generic/RTLocaleQueryUserCountryCode-r3-generic.cpp \
1565 r3/generic/dirrel-r3-generic.cpp \
1566 r3/posix/RTFileQueryFsSizes-posix.cpp \
1567 r3/posix/RTFileSetAllocationSize-posix.cpp \
1568 r3/posix/RTHandleGetStandard-posix.cpp \
1569 r3/posix/RTMemProtect-posix.cpp \
1570 r3/posix/RTPathUserHome-posix.cpp \
1571 r3/posix/RTSystemQueryOSInfo-posix.cpp \
1572 r3/posix/RTTimeNow-posix.cpp \
1573 r3/posix/RTTimeSet-posix.cpp \
1574 r3/posix/RTTimeZoneGetCurrent-posix.cpp \
1575 r3/posix/dir-posix.cpp \
1576 r3/posix/env-posix.cpp \
1577 r3/posix/errvars-posix.cpp \
1578 r3/posix/fileio-posix.cpp \
1579 r3/posix/fileio2-posix.cpp \
1580 r3/posix/fileio-at-posix.cpp \
1581 r3/posix/fileio-sg-posix.cpp \
1582 r3/posix/fileio-sg-at-posix.cpp \
1583 r3/posix/filelock-posix.cpp \
1584 r3/posix/fs-posix.cpp \
1585 r3/posix/fs2-posix.cpp \
1586 r3/posix/fs3-posix.cpp \
1587 r3/posix/ldrNative-posix.cpp \
1588 r3/posix/localipc-posix.cpp \
1589 r3/posix/rtmempage-exec-mmap-heap-posix.cpp \
1590 r3/posix/path-posix.cpp \
1591 r3/posix/path2-posix.cpp \
1592 r3/posix/pathhost-posix.cpp \
1593 r3/posix/RTPathUserDocuments-posix.cpp \
1594 r3/posix/pipe-posix.cpp \
1595 r3/posix/process-posix.cpp \
1596 r3/posix/process-creation-posix.cpp \
1597 r3/posix/rand-posix.cpp \
1598 r3/posix/semevent-posix.cpp \
1599 r3/posix/semeventmulti-posix.cpp \
1600 r3/posix/semmutex-posix.cpp \
1601 r3/posix/semrw-posix.cpp \
1602 r3/posix/serialport-posix.cpp \
1603 r3/posix/symlink-posix.cpp \
1604 r3/posix/shmem-posix.cpp \
1605 r3/posix/thread-posix.cpp \
1606 r3/posix/thread2-posix.cpp \
1607 r3/posix/time-posix.cpp \
1608 r3/posix/timelocal-posix.cpp \
1609 r3/posix/timer-posix.cpp \
1610 r3/posix/tls-posix.cpp \
1611 r3/posix/utf8-posix.cpp \
1612 r3/solaris/fileaio-solaris.cpp \
1613 r3/solaris/RTFileQuerySectorSize-solaris.cpp \
1614 r3/solaris/krnlmod-solaris.cpp \
1615 r3/solaris/systemmem-solaris.cpp \
1616 r3/solaris/mp-solaris.cpp \
1617 r3/solaris/rtProcInitExePath-solaris.cpp \
1618 r3/solaris/RTSystemShutdown-solaris.cpp \
1619 r3/solaris/thread-affinity-solaris.cpp
1620RuntimeBaseR3_SOURCES.solaris.amd64 = \
1621 common/string/memrchr.asm \
1622 common/string/mempcpy.asm \
1623 r3/solaris/coredumper-solaris.cpp \
1624 r3/solaris/RTSystemQueryDmiString-solaris.cpp
1625RuntimeBaseR3_SOURCES.solaris.x86 = \
1626 common/string/memrchr.asm \
1627 common/string/mempcpy.asm \
1628 r3/solaris/coredumper-solaris.cpp \
1629 r3/solaris/RTSystemQueryDmiString-solaris.cpp
1630RuntimeBaseR3_SOURCES.solaris.sparc32 = \
1631 common/string/memrchr.cpp \
1632 common/string/mempcpy.cpp \
1633 generic/RTSystemQueryDmiString-generic.cpp
1634RuntimeBaseR3_SOURCES.solaris.sparc64 = \
1635 common/string/memrchr.cpp \
1636 common/string/mempcpy.cpp \
1637 generic/RTSystemQueryDmiString-generic.cpp
1638
1639RuntimeBaseR3_SOURCES.haiku = \
1640 generic/RTCrStoreCreateSnapshotById-generic.cpp \
1641 generic/RTDirQueryInfo-generic.cpp \
1642 generic/RTDirSetMode-generic.cpp \
1643 generic/RTDirSetTimes-generic.cpp \
1644 generic/fileio-at-generic.cpp \
1645 generic/fileio-sg-generic.cpp \
1646 generic/fileio-sg-at-generic.cpp \
1647 generic/RTFileCopyPartEx-generic.cpp \
1648 generic/RTFileMove-generic.cpp \
1649 generic/RTFileQuerySectorSize-generic.cpp \
1650 generic/RTFileSetAllocationSize-generic.cpp \
1651 generic/RTLogWriteDebugger-generic.cpp \
1652 generic/RTPathGetCurrentOnDrive-generic.cpp \
1653 generic/RTProcDaemonize-generic.cpp \
1654 generic/RTTimeLocalNow-generic.cpp \
1655 generic/RTTimerCreate-generic.cpp \
1656 generic/RTUuidCreate-generic.cpp \
1657 generic/mppresent-generic.cpp \
1658 generic/RTSemEventMultiWait-2-ex-generic.cpp \
1659 generic/RTSemEventMultiWaitNoResume-2-ex-generic.cpp \
1660 generic/sched-generic.cpp \
1661 generic/semrw-$(if-expr defined(VBOX_WITH_LOCKLESS_SEMRW),lockless-,)generic.cpp \
1662 generic/timer-generic.cpp \
1663 generic/utf16locale-generic.cpp \
1664 generic/uuid-generic.cpp\
1665 generic/RTProcIsRunningByName-generic.cpp \
1666 generic/RTThreadGetNativeState-generic.cpp \
1667 generic/RTMpGetCoreCount-generic.cpp \
1668 generic/RTMpGetOnlineCoreCount-generic.cpp \
1669 r3/haiku/rtProcInitExePath-haiku.cpp \
1670 r3/haiku/time-haiku.cpp \
1671 r3/generic/allocex-r3-generic.cpp \
1672 r3/generic/RTLocaleQueryLocaleName-r3-generic.cpp \
1673 r3/generic/RTLocaleQueryNormalizedBaseLocaleName-r3-generic.cpp \
1674 r3/generic/RTLocaleQueryUserCountryCode-r3-generic.cpp \
1675 r3/generic/RTTimeZoneGetCurrent-generic.cpp \
1676 r3/generic/dirrel-r3-generic.cpp \
1677 r3/posix/RTFileQueryFsSizes-posix.cpp \
1678 r3/posix/RTHandleGetStandard-posix.cpp \
1679 r3/posix/RTMemProtect-posix.cpp \
1680 r3/posix/RTPathUserHome-posix.cpp \
1681 r3/posix/RTSystemQueryOSInfo-posix.cpp \
1682 r3/posix/RTSystemQueryTotalRam-posix.cpp \
1683 r3/posix/RTTimeNow-posix.cpp \
1684 r3/posix/dir-posix.cpp \
1685 r3/posix/env-posix.cpp \
1686 r3/posix/errvars-posix.cpp \
1687 r3/posix/fileio-posix.cpp \
1688 r3/posix/fileio2-posix.cpp \
1689 r3/posix/filelock-posix.cpp \
1690 r3/posix/fs-posix.cpp \
1691 r3/posix/fs2-posix.cpp \
1692 r3/posix/fs3-posix.cpp \
1693 r3/posix/ldrNative-posix.cpp \
1694 r3/posix/localipc-posix.cpp \
1695 r3/posix/rtmempage-exec-mmap-heap-posix.cpp \
1696 r3/posix/path-posix.cpp \
1697 r3/posix/path2-posix.cpp \
1698 r3/posix/pathhost-posix.cpp \
1699 r3/posix/pipe-posix.cpp \
1700 r3/posix/process-posix.cpp \
1701 r3/posix/process-creation-posix.cpp \
1702 r3/posix/rand-posix.cpp \
1703 r3/posix/semevent-posix.cpp \
1704 r3/posix/semeventmulti-posix.cpp \
1705 r3/posix/semmutex-posix.cpp \
1706 r3/posix/serialport-posix.cpp \
1707 r3/posix/symlink-posix.cpp \
1708 r3/posix/thread-posix.cpp \
1709 r3/posix/thread2-posix.cpp \
1710 r3/posix/timelocal-posix.cpp \
1711 r3/posix/tls-posix.cpp \
1712 r3/posix/utf8-posix.cpp
1713RuntimeBaseR3_SOURCES.haiku.x86 += common/string/memrchr.asm
1714RuntimeBaseR3_SOURCES.haiku.amd64 += common/string/memrchr.asm
1715
1716## PORTME: Porters add their selection of platform specific files for Ring-3 here.
1717
1718
1719#
1720# kBuild unit for generating nocrt aliases.
1721#
1722# This scans assembly, C and C++ source files for the target looking for macros
1723# that defines functions and variables needing aliasing.
1724#
1725UNIT_VBoxNoCrtAliases = CRT symbol alias for the rtnocr_xxx implementations
1726
1727# Only adding the VBOX_NOCRT_ALIASES property to library targets for now:
1728PROPS_ACCUMULATE_L += VBOX_NOCRT_ALIASES
1729PROPS_ACCUMULATE_L_LNK += VBOX_NOCRT_ALIASES
1730PROPS_LIBRARIES_ACCUMULATE_L += VBOX_NOCRT_ALIASES
1731PROPS_ALL += VBOX_NOCRT_ALIASES
1732
1733define def_unit_VBoxNoCrtAliases_double_expansion
1734$$($(target)_2_VBOX_NOCRT_ALIAS_KMK_FILE).ts +| $$($(target)_2_VBOX_NOCRT_ALIAS_KMK_FILE): \
1735 $$(abspathex \
1736 $$($(target)_SOURCES)\
1737 $$($(target)_SOURCES.$(bld_trg))\
1738 $$($(target)_SOURCES.$(bld_trg).$(bld_type))\
1739 $$($(target)_SOURCES.$(bld_trg).$(bld_trg_arch))\
1740 $$($(target)_SOURCES.$(bld_trg).$(bld_trg_arch).$(bld_type))\
1741 $$($(target)_SOURCES.$(bld_trg_arch))\
1742 $$($(target)_SOURCES.$(bld_trg_cpu))\
1743 $$($(target)_SOURCES.$(bld_type)) \
1744 , $(firstfile $(defpath) $(PATH_SUB_CURRENT))) \
1745 $$(VBOX_PATH_RUNTIME_SRC)//nocrt-aliases.sed \
1746 | $$$$(dir $$$$@)
1747 $$(call MSG_GENERATE,$(target),$$@,)
1748 $$(QUIET)$$(APPEND) -tn "$$@" "$(target)_2_VBOX_NOCRT_ALIASES := \\"
1749 $$(xargs $$(QUIET)$$(SED) -rn -f "$$(VBOX_PATH_RUNTIME_SRC)/nocrt-aliases.sed" --append "$$@" , $$(filter %.c %.cpp %.asm, $$^) )
1750 $$(QUIET)$$(APPEND) -n "$$@" "" ""
1751 $$(QUIET)$$(CP) --changed -f -- "$$@" "$$(patsubst %.ts,%,$$@)"
1752
1753$$($(target)_0_OUTDIR)/genalias/genalias.ts + $$($(target)_2_VBOX_NOCRT_ALIAS_FILES): | $$(VBOX_GENALIAS)
1754 $$(call MSG_GENERATE,$(target),$$@,)
1755 $$(QUIET)$$(MKDIR) -p -- "$$($(target)_0_OUTDIR)/genalias/"
1756 $$(QUIET)$$(VBOX_GENALIAS) -f $$(if-expr "$(bld_trg)" == "win",coff.$(bld_trg_arch),$$(if-expr "$(bld_trg)" == "darwin",macho,omf)) \
1757 -D "$$($(target)_0_OUTDIR)/genalias/" $$($(target)_2_VBOX_NOCRT_ALIASES) \
1758 $$($(target)_VBOX_NOCRT_ALIASES) \
1759 $$($(target)_VBOX_NOCRT_ALIASES.$(bld_trg)) \
1760 $$($(target)_VBOX_NOCRT_ALIASES.$(bld_trg).$(bld_type)) \
1761 $$($(target)_VBOX_NOCRT_ALIASES.$(bld_trg).$(bld_trg_arch)) \
1762 $$($(target)_VBOX_NOCRT_ALIASES.$(bld_trg).$(bld_trg_arch).$(bld_type)) \
1763 $$($(target)_VBOX_NOCRT_ALIASES.$(bld_trg_arch)) \
1764 $$($(target)_VBOX_NOCRT_ALIASES.$(bld_trg_cpu)) \
1765 $$($(target)_VBOX_NOCRT_ALIASES.$(bld_type))
1766 $$(QUIET)$$(APPEND) -tn "$$($(target)_0_OUTDIR)/genalias/genalias.ts" "$$($(target)_2_VBOX_NOCRT_ALIASES))"
1767
1768$(target)_2_OBJS += $$($(target)_2_VBOX_NOCRT_ALIAS_FILES)
1769OTHER_CLEAN += $$($(target)_2_VBOX_NOCRT_ALIAS_KMK_FILE) $$($(target)_2_VBOX_NOCRT_ALIAS_KMK_FILE).ts
1770endef
1771
1772define def_unit_VBoxNoCrtAliases_target_pre
1773 if1of ($(bld_trg), win os2 darwin) # Only non-ELF targets as ELF does not support aliasing.
1774 $(target)_2_VBOX_NOCRT_ALIAS_KMK_FILE := $(PATH_OUT)/nocrt-aliases-$(target).kmk
1775 include $($(target)_2_VBOX_NOCRT_ALIAS_KMK_FILE)
1776 $(target)_2_VBOX_NOCRT_ALIAS_FILES := $(foreach alias,$($(target)_2_VBOX_NOCRT_ALIASES) \
1777 $($(target)_VBOX_NOCRT_ALIASES) \
1778 $($(target)_VBOX_NOCRT_ALIASES.$(bld_trg)) \
1779 $($(target)_VBOX_NOCRT_ALIASES.$(bld_trg).$(bld_type)) \
1780 $($(target)_VBOX_NOCRT_ALIASES.$(bld_trg).$(bld_trg_arch)) \
1781 $($(target)_VBOX_NOCRT_ALIASES.$(bld_trg).$(bld_trg_arch).$(bld_type)) \
1782 $($(target)_VBOX_NOCRT_ALIASES.$(bld_trg_arch)) \
1783 $($(target)_VBOX_NOCRT_ALIASES.$(bld_trg_cpu)) \
1784 $($(target)_VBOX_NOCRT_ALIASES.$(bld_type)) \
1785 , $($(target)_0_OUTDIR)/genalias/$(firstword $(subst =, $(SPACE),$(alias))).o)
1786 $(eval $(def_unit_VBoxNoCrtAliases_double_expansion))
1787 endif
1788endef
1789
1790
1791#
1792# RuntimeR3 - Static Runtime for Ring-3 executables.
1793#
1794# We drop the windows error defines here for reason of size. The valkit tstUtf8
1795# was reduced by 175KB, from 600KB to 425KB (about 30%). Come up with a way of
1796# stripping it down or compressing it better and it can be added back.
1797# - 2022-08-17, bird.
1798#
1799RuntimeR3_TEMPLATE = VBoxR3Static
1800RuntimeR3_EXTENDS = RuntimeBaseR3
1801RuntimeR3_DEFS.win = $(RuntimeBaseR3_DEFS.win) IPRT_NO_WIN_ERROR_DATA
1802ifdef VBOX_WITH_NOCRT_STATIC
1803 if1of ($(KBUILD_TARGET), win)
1804 RuntimeR3_USES = $(RuntimeBaseR3_USES) VBoxNoCrtAliases
1805 RuntimeR3_DEFS = $(filter-out RT_WITHOUT_NOCRT_WRAPPERS,$(RuntimeBaseR3_DEFS)) \
1806 RT_FORCE_NOCRT_WRAPPERS \
1807 RT_WITH_NOCRT_ALIASES RT_WITH_NOCRT_UNDERSCORE_ALIASES RT_WITH_GENALIAS_NOCRT_ALIASES
1808
1809 RuntimeR3_SOURCES = $(filter-out \
1810 r3/alloc.cpp \
1811 r3/alloc-ef.cpp \
1812 r3/xml.cpp \
1813 common/zip/xarvfs.cpp \
1814 common/misc/json.cpp \
1815 generic/RTLogWriteStdErr-generic.cpp \
1816 generic/RTLogWriteStdOut-generic.cpp \
1817 ,$(RuntimeBaseR3_SOURCES)) \
1818 \
1819 common/err/nocrt-strerror.cpp \
1820 common/file/nocrt-open.cpp \
1821 common/file/nocrt-close.cpp \
1822 common/file/nocrt-fstat.cpp \
1823 common/file/nocrt-isatty.cpp \
1824 common/file/nocrt-read.cpp \
1825 common/math/nocrt-abs.cpp \
1826 common/math/nocrt-labs.cpp \
1827 common/math/nocrt-llabs.cpp \
1828 common/math/consts.c \
1829 common/math/copysign.cpp \
1830 common/math/copysignf.cpp \
1831 common/math/copysignl.cpp \
1832 common/math/fmax.cpp \
1833 common/math/fmaxf.cpp \
1834 common/math/fmaxl.cpp \
1835 common/math/fmin.cpp \
1836 common/math/fminf.cpp \
1837 common/math/fminl.cpp \
1838 common/math/frexp.cpp \
1839 common/math/frexpf.cpp \
1840 common/math/frexpl.cpp \
1841 common/math/__fpclassifyd.cpp \
1842 common/math/__fpclassifyf.cpp \
1843 common/math/__fpclassifyl.cpp \
1844 common/math/__isfinite.cpp \
1845 common/math/__isfinitef.cpp \
1846 common/math/__isfinitel.cpp \
1847 common/math/isinf.cpp \
1848 common/math/__isinff.cpp \
1849 common/math/__isinfl.cpp \
1850 common/math/isnan.cpp \
1851 common/math/isnanf.cpp \
1852 common/math/__isnanl.cpp \
1853 common/math/__isnormal.cpp \
1854 common/math/__isnormalf.cpp \
1855 common/math/__isnormall.cpp \
1856 common/math/llround.cpp \
1857 common/math/llroundf.cpp \
1858 common/math/llroundl.cpp \
1859 common/math/lround.cpp \
1860 common/math/lroundf.cpp \
1861 common/math/lroundl.cpp \
1862 common/math/round.cpp \
1863 common/math/roundf.cpp \
1864 common/math/roundl.cpp \
1865 common/math/__signbit.cpp \
1866 common/math/__signbitf.cpp \
1867 common/math/__signbitl.cpp \
1868 common/path/nocrt-access.cpp \
1869 common/path/nocrt-unlink.cpp \
1870 common/rand/nocrt-rand.cpp \
1871 common/sort/nocrt-qsort.cpp \
1872 common/sort/nocrt-qsort_r.cpp \
1873 common/sort/nocrt-bsearch.cpp \
1874 common/string/nocrt-strdup.cpp \
1875 common/string/nocrt-stricmp.cpp \
1876 common/string/nocrt-strtod.cpp \
1877 common/string/nocrt-atof.cpp \
1878 common/string/nocrt-strtol.cpp \
1879 common/string/nocrt-strtoll.cpp \
1880 common/string/nocrt-strtoul.cpp \
1881 common/string/nocrt-strtoull.cpp \
1882 common/string/nocrt-snprintf.cpp \
1883 common/string/nocrt-vsnprintf.cpp \
1884 common/string/nocrt-scprintf.cpp \
1885 common/string/nocrt-vscprintf.cpp \
1886 common/string/nocrt-sscanf.cpp \
1887 common/string/nocrt-vsscanf.cpp \
1888 common/string/atoi.cpp \
1889 common/string/strtok_r.cpp \
1890 r3/nocrt-per-thread-1.cpp \
1891 r3/nocrt-per-thread-2.cpp \
1892 r3/nocrt-errno.cpp \
1893 r3/nocrt-fopen.cpp \
1894 r3/nocrt-fdopen.cpp \
1895 r3/nocrt-tmpfile.cpp \
1896 r3/nocrt-tmpfile_s.cpp \
1897 r3/nocrt-fileno.cpp \
1898 r3/nocrt-fclose.cpp \
1899 r3/nocrt-fflush.cpp \
1900 r3/nocrt-setvbuf.cpp \
1901 r3/nocrt-fseek.cpp \
1902 r3/nocrt-fseeko.cpp \
1903 r3/nocrt-ftell.cpp \
1904 r3/nocrt-ftello.cpp \
1905 r3/nocrt-fwrite.cpp \
1906 r3/nocrt-fputc.cpp \
1907 r3/nocrt-putc.cpp \
1908 r3/nocrt-fputs.cpp \
1909 r3/nocrt-puts.cpp \
1910 r3/nocrt-fread.cpp \
1911 r3/nocrt-fgetc.cpp \
1912 r3/nocrt-getc.cpp \
1913 r3/nocrt-clearerr.cpp \
1914 r3/nocrt-ferror.cpp \
1915 r3/nocrt-cerr.cpp \
1916 r3/nocrt-cout.cpp \
1917
1918 RuntimeR3_SOURCES.x86 = $(RuntimeBaseR3_SOURCES.x86) \
1919 common/math/atan.asm \
1920 common/math/atanf.asm \
1921 common/math/atan2.asm \
1922 common/math/atan2f.asm \
1923 common/math/cos.asm \
1924 common/math/cosf.asm \
1925 common/math/ceil.asm \
1926 common/math/ceilf.asm \
1927 common/math/exp.asm \
1928 common/math/expf.asm \
1929 common/math/exp2.asm \
1930 common/math/exp2f.asm \
1931 common/math/fabs.asm \
1932 common/math/fabsf.asm \
1933 common/math/rtNoCrtHasSse.asm \
1934 common/math/fegetenv.asm \
1935 common/math/fesetenv.asm \
1936 common/math/feholdexcept.asm \
1937 common/math/feupdateenv.asm \
1938 common/math/fegetround.asm \
1939 common/math/fesetround.asm \
1940 common/math/fegetx87precision.asm \
1941 common/math/fesetx87precision.asm \
1942 common/math/fegetexcept.asm \
1943 common/math/feenableexcept.asm \
1944 common/math/fedisableexcept.asm \
1945 common/math/feclearexcept.asm \
1946 common/math/fegetexceptflag.asm \
1947 common/math/fesetexceptflag.asm \
1948 common/math/fetestexcept.asm \
1949 common/math/feraiseexcept.asm \
1950 common/math/floor.asm \
1951 common/math/floorf.asm \
1952 common/math/ldexp.asm \
1953 common/math/ldexpf.asm \
1954 common/math/log.asm \
1955 common/math/logf.asm \
1956 common/math/log2.asm \
1957 common/math/log2f.asm \
1958 common/math/llrint.asm \
1959 common/math/llrintf.asm \
1960 common/math/lrint.asm \
1961 common/math/lrintf.asm \
1962 common/math/pow.asm \
1963 common/math/powf.asm \
1964 common/math/powcore.asm \
1965 common/math/remainder.asm \
1966 common/math/remainderf.asm \
1967 common/math/rint.asm \
1968 common/math/rintf.asm \
1969 common/math/sin.asm \
1970 common/math/sinf.asm \
1971 common/math/sincore.asm \
1972 common/math/sqrt.asm \
1973 common/math/sqrtf.asm \
1974 common/math/tan.asm \
1975 common/math/tanf.asm \
1976 common/math/trunc.asm \
1977 common/math/truncf.asm \
1978 common/misc/setjmp.asm \
1979 common/string/memcpy.asm \
1980 common/string/memchr.asm \
1981 common/string/memcmp.asm \
1982 common/string/memmove.asm \
1983 common/string/memset.asm \
1984 common/string/strlen.asm \
1985 common/string/strnlen.cpp \
1986 common/string/strchr.asm \
1987 common/string/strcmp.asm \
1988 common/string/strncmp.asm \
1989 common/string/strcpy.asm \
1990 common/string/strncpy.asm \
1991 common/string/strcat.cpp \
1992 common/string/strncat.cpp \
1993 common/string/strrchr.cpp \
1994 common/string/strstr.cpp \
1995 common/string/strcspn.cpp \
1996 common/string/strpbrk.cpp \
1997 common/string/wcslen.asm
1998
1999 RuntimeR3_SOURCES.amd64 = $(RuntimeBaseR3_SOURCES.amd64) \
2000 common/math/atan.asm \
2001 common/math/atanf.asm \
2002 common/math/atan2.asm \
2003 common/math/atan2f.asm \
2004 common/math/cos.asm \
2005 common/math/cosf.asm \
2006 common/math/ceil.asm \
2007 common/math/ceilf.asm \
2008 common/math/exp.asm \
2009 common/math/expf.asm \
2010 common/math/exp2.asm \
2011 common/math/exp2f.asm \
2012 common/math/fabs.asm \
2013 common/math/fabsf.asm \
2014 common/math/fegetenv.asm \
2015 common/math/fesetenv.asm \
2016 common/math/feholdexcept.asm \
2017 common/math/feupdateenv.asm \
2018 common/math/fegetround.asm \
2019 common/math/fesetround.asm \
2020 common/math/fegetx87precision.asm \
2021 common/math/fesetx87precision.asm \
2022 common/math/fegetexcept.asm \
2023 common/math/feenableexcept.asm \
2024 common/math/fedisableexcept.asm \
2025 common/math/feclearexcept.asm \
2026 common/math/fegetexceptflag.asm \
2027 common/math/fesetexceptflag.asm \
2028 common/math/fetestexcept.asm \
2029 common/math/feraiseexcept.asm \
2030 common/math/floor.asm \
2031 common/math/floorf.asm \
2032 common/math/ldexp.asm \
2033 common/math/ldexpf.asm \
2034 common/math/log.asm \
2035 common/math/logf.asm \
2036 common/math/log2.asm \
2037 common/math/log2f.asm \
2038 common/math/llrint.asm \
2039 common/math/llrintf.asm \
2040 common/math/lrint.asm \
2041 common/math/lrintf.asm \
2042 common/math/pow.asm \
2043 common/math/powf.asm \
2044 common/math/powcore.asm \
2045 common/math/remainder.asm \
2046 common/math/remainderf.asm \
2047 common/math/rint.asm \
2048 common/math/rintf.asm \
2049 common/math/sin.asm \
2050 common/math/sinf.asm \
2051 common/math/sincore.asm \
2052 common/math/sqrt.asm \
2053 common/math/sqrtf.asm \
2054 common/math/tan.asm \
2055 common/math/tanf.asm \
2056 common/math/trunc.asm \
2057 common/math/truncf.asm \
2058 common/misc/setjmp.asm \
2059 common/string/memcpy.asm \
2060 common/string/memchr.asm \
2061 common/string/memcmp.asm \
2062 common/string/memmove.asm \
2063 common/string/memset.asm \
2064 common/string/strlen.asm \
2065 common/string/strnlen.cpp \
2066 common/string/strchr.asm \
2067 common/string/strcmp.asm \
2068 common/string/strncmp.asm \
2069 common/string/strcpy.asm \
2070 common/string/strncpy.asm \
2071 common/string/strcat.cpp \
2072 common/string/strncat.cpp \
2073 common/string/strrchr.cpp \
2074 common/string/strstr.cpp \
2075 common/string/strcspn.cpp \
2076 common/string/strpbrk.cpp \
2077 common/string/wcslen.asm
2078
2079 RuntimeR3_SOURCES.win = $(filter-out \
2080 r3/generic/RTLocaleQueryLocaleName-r3-generic.cpp \
2081 ,$(RuntimeBaseR3_SOURCES.win)) \
2082 \
2083 common/compiler/vcc/atexit-vcc.cpp \
2084 common/compiler/vcc/loadcfg-vcc.c \
2085 common/compiler/vcc/tlsdir-vcc.c \
2086 common/compiler/vcc/initializers-c-cpp-vcc.cpp \
2087 common/compiler/vcc/stacksup-vcc.cpp \
2088 common/compiler/vcc/fltused-vcc.cpp \
2089 common/compiler/vcc/purecall-vcc.cpp \
2090 common/file/nocrt-dup.cpp \
2091 r3/win/nocrt-startup-exe-win.cpp \
2092 r3/win/nocrt-startup-dll-win.cpp \
2093 r3/win/nocrt-startup-common-win.cpp \
2094 r3/win/nocrt-fatal-write-win.cpp \
2095 r3/win/nocrt-alloc-win.cpp \
2096 r3/win/nocrt-RTLogWriteStdErr-win.cpp \
2097 r3/win/nocrt-RTLogWriteStdOut-win.cpp \
2098 generic/new-delete-generic.cpp
2099 RuntimeR3_SOURCES.win.amd64 = $(RuntimeBaseR3_SOURCES.win.amd64) \
2100 r3/win/nocrt-atexit-win.asm \
2101 r3/win/nocrt-mainCRTStartup-win.asm \
2102 r3/win/nocrt-WinMainCRTStartup-win.asm \
2103 common/compiler/vcc/guard-vcc.asm \
2104 common/compiler/vcc/stack-vcc.asm
2105 RuntimeR3_SOURCES.win.x86 = $(RuntimeBaseR3_SOURCES.win.x86) \
2106 r3/win/nocrt-atexit-win.asm \
2107 r3/win/nocrt-mainCRTStartup-win.asm \
2108 r3/win/nocrt-WinMainCRTStartup-win.asm \
2109 common/compiler/vcc/guard-vcc.asm \
2110 common/compiler/vcc/stack-vcc.asm \
2111 common/compiler/vcc/ftol2-vcc.asm \
2112 common/compiler/vcc/except-x86-vcc.cpp
2113 RuntimeR3_VBOX_NOCRT_ALIASES.win := \
2114 strtok_s=nocrt_strtok_r _strtok_s=nocrt_strtok_r nocrt_strtok_s=nocrt_strtok_r \
2115 $(foreach fn, atan atan2 cos ceil exp fabs floor ldexp log lrint llrint remainder sin tan \
2116 ,$(fn)l=nocrt_$(fn) _$(fn)l=nocrt_$(fn))
2117 endif
2118endif
2119
2120
2121#
2122# Generate RTIsoMaker / VISO help text from the manpage xml.
2123#
2124ifn1of ($(KBUILD_TARGET), os2) # breaks validationkit, figure out later.
2125
2126 IPRT_XML_REFENTRY_FILES = \
2127 common/fs/isomakercmd-man.xml
2128
2129 #$(call KB_FN_DO_PASS0_ON_TARGET,RuntimeR3)
2130
2131 BLDDIRS += $(IPRT_OUT_DIR)/man/
2132 OTHER_CLEAN += $(foreach xml,$(basename $(notdir $(IPRT_XML_REFENTRY_FILES))), \
2133 $(IPRT_OUT_DIR)/man/$(xml).xml $(IPRT_OUT_DIR)/man/$(xml).h $(IPRT_OUT_DIR)/man/$(xml).h.ts)
2134
2135
2136 include $(PATH_ROOT)/doc/manual/Config.kmk
2137
2138 # Preprocess the xml files, applying remarks.
2139 $(foreach file,$(IPRT_XML_REFENTRY_FILES) \
2140 , $(evalcall2 def_vbox_refentry_preprocess_for_manpage,$(IPRT_OUT_DIR)/man,$(notdir $(file)),$(VBOX_PATH_RUNTIME_SRC)/$(file)))
2141
2142 # generate the header and add it as a dependency to the source using it.
2143 $(evalcall2 def_vbox_single_refentry_to_h,$(IPRT_OUT_DIR)/man/isomakercmd-man.h, $(IPRT_OUT_DIR)/man/isomakercmd-man.xml)
2144 common/fs/isomakercmd.cpp_DEPS = $(IPRT_OUT_DIR)/man/isomakercmd-man.h
2145 common/fs/isomakercmd.cpp_INCS = $(IPRT_OUT_DIR)/man/
2146
2147endif
2148
2149
2150#
2151# RuntimeR3-x86 - 32-bit version of RuntimeR3 for windows hosts.
2152#
2153RuntimeR3-x86_EXTENDS := RuntimeR3
2154RuntimeR3-x86_BLD_TRG_ARCH := x86
2155RuntimeR3-x86_DEFS = $(filter-out IN_SUP_R3 IN_SUP, $(RuntimeR3_DEFS)) IPRT_WITHOUT_LDR_VERIFY RT_NO_GIP
2156
2157
2158#
2159# RuntimeBldProg - Static Runtime for build programs.
2160#
2161# Note! This is a bit of hacky since kBuild doesn't support building libraries
2162# for build programs.
2163#
2164RuntimeBldProg_TEMPLATE := VBoxAdvBldProg
2165RuntimeBldProg_EXTENDS := RuntimeBaseR3
2166RuntimeBldProg_BLD_TRG := $(KBUILD_HOST)
2167RuntimeBldProg_BLD_TRG_ARCH := $(KBUILD_HOST_ARCH)
2168RuntimeBldProg_BLD_TRG_CPU := $(KBUILD_HOST_CPU)
2169RuntimeBldProg_DEFS := $(filter-out IN_SUP_R3 IN_SUP, $(RuntimeBaseR3_DEFS)) IPRT_WITHOUT_LDR_VERIFY RT_NO_GIP
2170RuntimeBldProg_SOURCES = \
2171 common/alloc/alloc.cpp \
2172 common/alloc/memcache.cpp \
2173 common/asn1/asn1-basics.cpp \
2174 common/asn1/asn1-cursor.cpp \
2175 common/asn1/asn1-default-allocator.cpp \
2176 common/asn1/asn1-dump.cpp \
2177 common/asn1/asn1-efence-allocator.cpp \
2178 common/asn1/asn1-encode.cpp \
2179 common/asn1/asn1-safer-allocator.cpp \
2180 common/asn1/asn1-ut-bitstring-decode.cpp \
2181 common/asn1/asn1-ut-bitstring.cpp \
2182 common/asn1/asn1-ut-boolean-decode.cpp \
2183 common/asn1/asn1-ut-boolean.cpp \
2184 common/asn1/asn1-ut-core-decode.cpp \
2185 common/asn1/asn1-ut-core.cpp \
2186 common/asn1/asn1-ut-dyntype-decode.cpp \
2187 common/asn1/asn1-ut-dyntype.cpp \
2188 common/asn1/asn1-ut-integer-decode.cpp \
2189 common/asn1/asn1-ut-integer.cpp \
2190 common/asn1/asn1-ut-null-decode.cpp \
2191 common/asn1/asn1-ut-null.cpp \
2192 common/asn1/asn1-ut-objid-decode.cpp \
2193 common/asn1/asn1-ut-objid.cpp \
2194 common/asn1/asn1-ut-octetstring-decode.cpp \
2195 common/asn1/asn1-ut-octetstring.cpp \
2196 common/asn1/asn1-ut-string-decode.cpp \
2197 common/asn1/asn1-ut-string.cpp \
2198 common/asn1/asn1-ut-time-decode.cpp \
2199 common/asn1/asn1-ut-time.cpp \
2200 common/checksum/adler32.cpp \
2201 common/checksum/alt-md2.cpp \
2202 common/checksum/alt-md4.cpp \
2203 common/checksum/alt-md5.cpp \
2204 common/checksum/alt-sha1.cpp \
2205 common/checksum/alt-sha256.cpp \
2206 common/checksum/alt-sha512.cpp \
2207 common/checksum/crc16ccitt.cpp \
2208 common/checksum/crc32.cpp \
2209 common/checksum/crc32c.cpp \
2210 common/checksum/crc64.cpp \
2211 common/checksum/manifest2.cpp \
2212 common/checksum/manifest3.cpp \
2213 common/checksum/md5str.cpp \
2214 common/checksum/sha1str.cpp \
2215 common/checksum/sha256str.cpp \
2216 common/checksum/sha512str.cpp \
2217 common/crypto/digest-core.cpp \
2218 common/crypto/pemfile-read.cpp \
2219 common/crypto/pkcs7-asn1-decoder.cpp \
2220 common/crypto/pkcs7-core.cpp \
2221 common/crypto/pkcs7-init.cpp \
2222 common/crypto/pkcs7-sanity.cpp \
2223 common/crypto/pkcs7-verify.cpp \
2224 common/crypto/spc-asn1-decoder.cpp \
2225 common/crypto/spc-core.cpp \
2226 common/crypto/spc-init.cpp \
2227 common/crypto/spc-sanity.cpp \
2228 common/crypto/taf-asn1-decoder.cpp \
2229 common/crypto/taf-core.cpp \
2230 common/crypto/taf-init.cpp \
2231 common/crypto/taf-sanity.cpp \
2232 common/crypto/tsp-asn1-decoder.cpp \
2233 common/crypto/tsp-core.cpp \
2234 common/crypto/tsp-init.cpp \
2235 common/crypto/tsp-sanity.cpp \
2236 common/crypto/x509-asn1-decoder.cpp \
2237 common/crypto/x509-core.cpp \
2238 common/crypto/x509-file.cpp \
2239 common/crypto/x509-init.cpp \
2240 common/crypto/x509-sanity.cpp \
2241 common/dbg/dbg.cpp \
2242 common/dbg/dbgcfg.cpp \
2243 common/dbg/dbgmod.cpp \
2244 common/dbg/dbgmodcodeview.cpp \
2245 common/dbg/dbgmodcontainer.cpp \
2246 common/dbg/dbgmoddeferred.cpp \
2247 common/dbg/dbgmoddwarf.cpp \
2248 common/dbg/dbgmodexports.cpp \
2249 common/dbg/dbgmodldr.cpp \
2250 common/dbg/dbgmodmapsym.cpp \
2251 common/dbg/dbgmodnm.cpp \
2252 common/err/errinfo-alloc.cpp \
2253 common/err/errinfo.cpp \
2254 common/err/errinfolog.cpp \
2255 common/err/errmsg.cpp \
2256 common/err/RTErrConvertFromErrno.cpp \
2257 common/err/RTErrConvertToErrno.cpp \
2258 common/fs/isomaker.cpp \
2259 common/fs/isomakercmd.cpp \
2260 common/fs/isomakerimport.cpp \
2261 common/fs/isovfs.cpp \
2262 common/ldr/ldr.cpp \
2263 common/ldr/ldrELF.cpp \
2264 common/ldr/ldrEx.cpp \
2265 common/ldr/ldrFile.cpp \
2266 common/ldr/ldrLX.cpp \
2267 common/ldr/ldrMachO.cpp \
2268 common/ldr/ldrNative.cpp \
2269 common/ldr/ldrPE.cpp \
2270 common/ldr/ldrVfsFile.cpp \
2271 common/log/log.cpp \
2272 common/log/logellipsis.cpp \
2273 common/log/logformat.cpp \
2274 common/log/logrel.cpp \
2275 common/log/logrelellipsis.cpp \
2276 common/log/RTLogCreateEx.cpp \
2277 common/math/bignum.cpp \
2278 common/misc/assert.cpp \
2279 common/misc/cidr.cpp \
2280 common/misc/getopt.cpp \
2281 common/misc/getoptargv.cpp \
2282 common/misc/lockvalidator.cpp \
2283 common/misc/message.cpp \
2284 common/misc/messagerefentry.cpp \
2285 common/misc/once.cpp \
2286 common/misc/RTAssertMsg1Weak.cpp \
2287 common/misc/RTAssertMsg2.cpp \
2288 common/misc/RTAssertMsg2Add.cpp \
2289 common/misc/RTAssertMsg2AddWeak.cpp \
2290 common/misc/RTAssertMsg2AddWeakV.cpp \
2291 common/misc/RTAssertMsg2Weak.cpp \
2292 common/misc/RTAssertMsg2WeakV.cpp \
2293 common/misc/RTFileModeToFlags.cpp \
2294 common/misc/RTFileOpenF.cpp \
2295 common/misc/RTFileOpenV.cpp \
2296 common/misc/RTMemWipeThoroughly.cpp \
2297 common/misc/req.cpp \
2298 common/misc/reqqueue.cpp \
2299 common/misc/reqpool.cpp \
2300 common/misc/sanity-c.c \
2301 common/misc/sanity-cpp.cpp \
2302 common/misc/sg.cpp \
2303 common/misc/term.cpp \
2304 common/misc/thread.cpp \
2305 common/net/macstr.cpp \
2306 common/net/netaddrstr2.cpp \
2307 common/path/comparepaths.cpp \
2308 common/path/RTPathAbsDup.cpp \
2309 common/path/RTPathAbsEx.cpp \
2310 common/path/RTPathAbsExDup.cpp \
2311 common/path/RTPathAppend.cpp \
2312 common/path/RTPathAppendEx.cpp \
2313 common/path/RTPathChangeToDosSlashes.cpp \
2314 common/path/RTPathChangeToUnixSlashes.cpp \
2315 common/path/RTPathCopyComponents.cpp \
2316 common/path/RTPathCountComponents.cpp \
2317 common/path/RTPathEnsureTrailingSeparator.cpp \
2318 common/path/RTPathExt.cpp \
2319 common/path/RTPathFilename.cpp \
2320 common/path/RTPathHasExt.cpp \
2321 common/path/RTPathHasPath.cpp \
2322 common/path/RTPathJoin.cpp \
2323 common/path/RTPathJoinA.cpp \
2324 common/path/RTPathJoinEx.cpp \
2325 common/path/RTPathParse.cpp \
2326 common/path/RTPathParsedReassemble.cpp \
2327 common/path/RTPathParseSimple.cpp \
2328 common/path/RTPathRealDup.cpp \
2329 common/path/rtPathRootSpecLen.cpp \
2330 common/path/RTPathSkipRootSpec.cpp \
2331 common/path/RTPathSplit.cpp \
2332 common/path/RTPathSplitA.cpp \
2333 common/path/RTPathSplitReassemble.cpp \
2334 common/path/RTPathStartsWithRoot.cpp \
2335 common/path/RTPathStripExt.cpp \
2336 common/path/RTPathStripFilename.cpp \
2337 common/path/RTPathStripTrailingSlash.cpp \
2338 common/path/RTPathTraverseList.cpp \
2339 common/path/rtPathVolumeSpecLen.cpp \
2340 common/rand/rand.cpp \
2341 common/rand/randadv.cpp \
2342 common/rand/randparkmiller.cpp \
2343 common/sort/shellsort.cpp \
2344 common/string/base64.cpp \
2345 common/string/RTStrCat.cpp \
2346 common/string/RTStrCmp.cpp \
2347 common/string/RTStrCopy.cpp \
2348 common/string/RTStrCopyEx.cpp \
2349 common/string/RTStrCopyP.cpp \
2350 common/string/RTStrIStartsWith.cpp \
2351 common/string/RTStrNCmp.cpp \
2352 common/string/RTStrNICmpAscii.cpp \
2353 common/string/RTStrNLen.cpp \
2354 common/string/RTStrPrintHexBytes.cpp \
2355 common/string/RTStrStr.cpp \
2356 common/string/simplepattern.cpp \
2357 common/string/straprintf.cpp \
2358 common/string/strcache.cpp \
2359 common/string/strformat.cpp \
2360 common/string/RTStrFormat.cpp \
2361 common/string/strformatnum.cpp \
2362 common/string/strformatrt.cpp \
2363 common/string/strformattype.cpp \
2364 common/string/strhash1.cpp \
2365 common/string/stringalloc.cpp \
2366 common/string/strprintf.cpp \
2367 common/string/strprintf-ellipsis.cpp \
2368 common/string/strprintf2.cpp \
2369 common/string/strprintf2-ellipsis.cpp \
2370 common/string/strspace.cpp \
2371 common/string/strstrip.cpp \
2372 common/string/strtonum.cpp \
2373 common/string/unidata-flags.cpp \
2374 common/string/unidata-lower.cpp \
2375 common/string/unidata-upper.cpp \
2376 common/string/utf-16-case.cpp \
2377 common/string/utf-16.cpp \
2378 common/string/utf-8-case.cpp \
2379 common/string/utf-8-case2.cpp \
2380 common/string/utf-8.cpp \
2381 common/table/avllu32.cpp \
2382 common/table/avlpv.cpp \
2383 common/table/avlrpv.cpp \
2384 common/table/avlruintptr.cpp \
2385 common/table/avlu32.cpp \
2386 common/table/avluintptr.cpp \
2387 common/time/time.cpp \
2388 common/time/timeprog.cpp \
2389 common/time/timesupref.cpp \
2390 common/time/timesysalias.cpp \
2391 common/vfs/vfsbase.cpp \
2392 common/vfs/vfschain.cpp \
2393 common/vfs/vfsmemory.cpp \
2394 common/vfs/vfsmisc.cpp \
2395 common/vfs/vfsmsg.cpp \
2396 common/vfs/vfsstddir.cpp \
2397 common/vfs/vfsstdfile.cpp \
2398 common/vfs/vfsstdpipe.cpp \
2399 common/zip/gzipvfs.cpp \
2400 common/zip/tar.cpp \
2401 common/zip/tarcmd.cpp \
2402 common/zip/tarvfs.cpp \
2403 common/zip/tarvfswriter.cpp \
2404 generic/critsect-generic.cpp \
2405 generic/critsectrw-generic.cpp \
2406 generic/env-generic.cpp \
2407 generic/mempool-generic.cpp \
2408 generic/RTEnvDupEx-generic.cpp \
2409 generic/RTFileCopy-generic.cpp \
2410 generic/RTFileCopyAttributes-generic.cpp \
2411 generic/RTFileCopyEx-generic.cpp \
2412 generic/RTFileCopyByHandlesEx-generic.cpp \
2413 generic/RTFileQuerySize-generic.cpp \
2414 generic/RTFileReadAll-generic.cpp \
2415 generic/RTFileReadAllByHandle-generic.cpp \
2416 generic/RTFileReadAllByHandleEx-generic.cpp \
2417 generic/RTFileReadAllEx-generic.cpp \
2418 generic/RTFileReadAllFree-generic.cpp \
2419 generic/RTLogWriteStdErr-generic.cpp \
2420 generic/RTLogWriteStdOut-generic.cpp \
2421 generic/RTLogWriteUser-generic.cpp \
2422 generic/RTPathIsSame-generic.cpp \
2423 generic/RTPathGetCurrentDrive-generic.cpp \
2424 generic/rtStrFormatKernelAddress-generic.cpp \
2425 generic/RTTimerLRCreate-generic.cpp \
2426 generic/semfastmutex-generic.cpp \
2427 generic/semxroads-generic.cpp \
2428 generic/spinlock-generic.cpp \
2429 r3/alloc-ef.cpp \
2430 r3/alloc.cpp \
2431 r3/allocex.cpp \
2432 r3/dir.cpp \
2433 r3/dir2.cpp \
2434 r3/fileio.cpp \
2435 r3/fs.cpp \
2436 r3/generic/semspinmutex-r3-generic.cpp \
2437 r3/init.cpp \
2438 r3/memsafer-r3.cpp \
2439 r3/path.cpp \
2440 r3/RTPathTemp.cpp \
2441 r3/process.cpp \
2442 r3/socket.cpp \
2443 r3/stream.cpp \
2444 r3/tcp.cpp \
2445 VBox/log-vbox.cpp \
2446 VBox/RTAssertShouldPanic-vbox.cpp \
2447 common/string/ministring.cpp # for main
2448ifneq ($(KBUILD_HOST),win)
2449 RuntimeBldProg_SOURCES += \
2450 common/err/errmsgxpcom.cpp
2451endif
2452
2453RuntimeBldProg_SOURCES.darwin = $(filter-out \
2454 generic/cdrom-generic.cpp \
2455 generic/RTFileMove-generic.cpp \
2456 generic/RTProcDaemonize-generic.cpp \
2457 generic/RTThreadGetAffinity-stub-generic.cpp \
2458 generic/RTThreadSetAffinity-stub-generic.cpp \
2459 generic/RTThreadSetAffinityToCpu-generic.cpp \
2460 generic/RTTimerCreate-generic.cpp \
2461 generic/mppresent-generic.cpp \
2462 generic/RTSystemShutdown-generic.cpp \
2463 generic/timer-generic.cpp \
2464 generic/utf16locale-generic.cpp \
2465 generic/RTProcIsRunningByName-generic.cpp \
2466 generic/RTThreadGetNativeState-generic.cpp \
2467 r3/darwin/RTCrStoreCreateSnapshotById-darwin.cpp \
2468 r3/darwin/filelock-darwin.cpp \
2469 r3/darwin/systemmem-darwin.cpp \
2470 r3/darwin/krnlmod-darwin.cpp \
2471 r3/darwin/filelock-darwin.cpp \
2472 r3/darwin/RTSystemQueryDmiString-darwin.cpp \
2473 r3/darwin/RTPathUserDocuments-darwin.cpp \
2474 r3/posix/RTTimeSet-posix.cpp \
2475 r3/posix/serialport-posix.cpp \
2476 r3/posix/localipc-posix.cpp \
2477 r3/generic/allocex-r3-generic.cpp \
2478 r3/generic/RTLocaleQueryLocaleName-r3-generic.cpp \
2479 r3/generic/RTLocaleQueryNormalizedBaseLocaleName-r3-generic.cpp \
2480 r3/generic/RTLocaleQueryUserCountryCode-r3-generic.cpp \
2481 , $(RuntimeBaseR3_SOURCES.darwin))
2482
2483RuntimeBldProg_SOURCES.win = \
2484 common/dbg/dbgmoddbghelp.cpp \
2485 common/string/mempcpy.asm \
2486 common/string/RTUtf16CopyAscii.cpp \
2487 common/string/RTUtf16End.cpp \
2488 common/string/RTUtf16NLenEx.cpp \
2489 common/string/RTUtf16ICmpAscii.cpp \
2490 common/string/RTUtf16NICmpAscii.cpp \
2491 generic/mppresent-generic-online.cpp \
2492 generic/RTDirExists-generic.cpp \
2493 generic/RTDirSetTimes-generic.cpp \
2494 generic/RTFileCopyPartEx-generic.cpp \
2495 generic/RTFileExists-generic.cpp \
2496 generic/RTFileSetAllocationSize-generic.cpp \
2497 generic/RTRandAdvCreateSystemFaster-generic.cpp \
2498 generic/RTRandAdvCreateSystemTruer-generic.cpp \
2499 generic/RTSemEventWait-2-ex-generic.cpp \
2500 generic/RTSemEventWaitNoResume-2-ex-generic.cpp \
2501 generic/RTSemEventMultiWait-2-ex-generic.cpp \
2502 generic/RTSemEventMultiWaitNoResume-2-ex-generic.cpp \
2503 generic/RTSemMutexRequest-generic.cpp \
2504 generic/RTSemMutexRequestDebug-generic.cpp \
2505 generic/semrw-$(if-expr defined(VBOX_WITH_LOCKLESS_SEMRW),lockless-,)generic.cpp \
2506 generic/uuid-generic.cpp \
2507 nt/fileioutils-nt.cpp \
2508 nt/RTErrConvertFromNtStatus.cpp \
2509 nt/semevent-nt.cpp \
2510 nt/semeventmulti-nt.cpp \
2511 r3/nt/direnum-r3-nt.cpp \
2512 r3/nt/dirrel-r3-nt.cpp \
2513 r3/nt/fs-nt.cpp \
2514 r3/nt/pathint-nt.cpp \
2515 r3/nt/RTFileQueryFsSizes-nt.cpp \
2516 r3/nt/RTFileSetMode-r3-nt.cpp \
2517 r3/nt/RTPathQueryInfo-nt.cpp \
2518 r3/nt/RTPathSetMode-r3-nt.cpp \
2519 r3/nt/RTProcQueryParent-r3-nt.cpp \
2520 r3/win/alloc-win.cpp \
2521 r3/win/allocex-win.cpp \
2522 r3/win/dir-win.cpp \
2523 r3/win/env-win.cpp \
2524 r3/win/errvars-win.cpp \
2525 r3/win/fileio-win.cpp \
2526 r3/win/init-win.cpp \
2527 r3/win/ldrNative-win.cpp \
2528 r3/win/path-win.cpp \
2529 r3/win/pathint-win.cpp \
2530 r3/win/pipe-win.cpp \
2531 r3/win/process-win.cpp \
2532 r3/win/RTHandleGetStandard-win.cpp \
2533 r3/win/RTLogWriteDebugger-win.cpp \
2534 r3/win/rtProcInitExePath-win.cpp \
2535 r3/win/RTUuidCreate-win.cpp \
2536 r3/win/sched-win.cpp \
2537 r3/win/semmutex-win.cpp \
2538 r3/win/symlink-win.cpp \
2539 r3/win/system-get-nt-xxx-win.cpp \
2540 r3/win/thread-win.cpp \
2541 r3/win/thread2-win.cpp \
2542 $(if-expr 1,r3/win/time-win.cpp,r3/nt/time-nt.cpp) \
2543 r3/win/time2-win.cpp \
2544 r3/win/tls-win.cpp \
2545 r3/win/utf16locale-win.cpp \
2546 r3/win/utf8-win.cpp \
2547 win/errmsgwin.cpp \
2548 win/RTErrConvertFromWin32.cpp
2549
2550RuntimeBldProg_SOURCES.win.amd64 := \
2551 $(RuntimeWin64ASM_SOURCES) \
2552 common/string/memrchr.asm
2553RuntimeBldProg_SOURCES.win.x86 := \
2554 $(RuntimeWin32ASM_SOURCES) \
2555 common/string/memrchr.asm
2556
2557## @todo reduce this
2558RuntimeBldProg_SOURCES.os2 += \
2559 common/string/memrchr.asm \
2560 generic/mppresent-generic.cpp \
2561 generic/RTCrStoreCreateSnapshotById-generic.cpp \
2562 generic/RTDirQueryInfo-generic.cpp \
2563 generic/RTDirSetTimes-generic.cpp \
2564 generic/fileio-at-generic.cpp \
2565 generic/RTFileCopyPartEx-generic.cpp \
2566 generic/RTFileMove-generic.cpp \
2567 generic/RTFileSetAllocationSize-generic.cpp \
2568 generic/RTLogWriteDebugger-generic.cpp \
2569 generic/RTPathGetCurrentOnDrive-generic.cpp \
2570 generic/RTRandAdvCreateSystemFaster-generic.cpp \
2571 generic/RTRandAdvCreateSystemTruer-generic.cpp \
2572 generic/RTSemEventMultiWait-generic.cpp \
2573 generic/RTSemEventWait-generic.cpp \
2574 generic/RTSemMutexRequest-generic.cpp \
2575 generic/RTSemMutexRequestDebug-generic.cpp \
2576 generic/RTThreadGetNativeState-generic.cpp \
2577 generic/RTUuidCreate-generic.cpp \
2578 generic/semrw-$(if-expr defined(VBOX_WITH_LOCKLESS_SEMRW),lockless-,)generic.cpp \
2579 generic/timer-generic.cpp \
2580 generic/utf16locale-generic.cpp \
2581 generic/uuid-generic.cpp \
2582 os2/RTErrConvertFromOS2.cpp \
2583 r3/generic/allocex-r3-generic.cpp \
2584 r3/generic/dirrel-r3-generic.cpp \
2585 r3/os2/filelock-os2.cpp \
2586 r3/os2/mp-os2.cpp \
2587 r3/os2/pipe-os2.cpp \
2588 r3/os2/rtProcInitExePath-os2.cpp \
2589 r3/os2/sched-os2.cpp \
2590 r3/os2/sems-os2.cpp \
2591 r3/os2/systemmem-os2.cpp \
2592 r3/os2/thread-os2.cpp \
2593 r3/os2/time-os2.cpp \
2594 r3/posix/dir-posix.cpp \
2595 r3/posix/env-posix.cpp \
2596 r3/posix/errvars-posix.cpp \
2597 r3/posix/fileio-posix.cpp \
2598 r3/posix/fileio2-posix.cpp \
2599 r3/posix/fs-posix.cpp \
2600 r3/posix/fs2-posix.cpp \
2601 r3/posix/fs3-posix.cpp \
2602 r3/posix/ldrNative-posix.cpp \
2603 r3/posix/path-posix.cpp \
2604 r3/posix/path2-posix.cpp \
2605 r3/posix/pathhost-posix.cpp \
2606 r3/posix/process-creation-posix.cpp \
2607 r3/posix/process-posix.cpp \
2608 r3/posix/RTFileQueryFsSizes-posix.cpp \
2609 r3/posix/RTHandleGetStandard-posix.cpp \
2610 r3/posix/rtmempage-exec-mmap-heap-posix.cpp \
2611 r3/posix/RTMemProtect-posix.cpp \
2612 r3/posix/RTPathUserDocuments-posix.cpp \
2613 r3/posix/RTPathUserHome-posix.cpp \
2614 r3/posix/RTTimeNow-posix.cpp \
2615 r3/posix/RTTimeSet-posix.cpp \
2616 r3/posix/symlink-posix.cpp \
2617 r3/posix/timelocal-posix.cpp \
2618 r3/posix/utf8-posix.cpp
2619
2620## @todo reduce linux, solaris and freebsd sources too.
2621
2622
2623
2624#
2625# RuntimeGuestR3 - Guest Additions Runtime (static/exe).
2626# (The KBUILD_HOST inheritance here is for cross building the linux
2627# additions, while .x86 is for cross building x86 while targeting amd64.)
2628#
2629RuntimeGuestR3_TEMPLATE := VBoxGuestR3Lib
2630RuntimeGuestR3_EXTENDS := RuntimeR3
2631RuntimeGuestR3_DEFS = $(filter-out RTCRITSECT_STRICT RT_NO_GIP IN_SUP_R3, $(RuntimeR3_DEFS))
2632RuntimeGuestR3_SOURCES = $(filter-out \
2633 common/time/timesupref.cpp \
2634 common/time/timesupA.asm \
2635 common/time/timesup.cpp \
2636 common/zip/xarvfs.cpp \
2637 r3/xml.cpp \
2638 generic/RTLogWriteUser-generic.cpp \
2639 , $(RuntimeR3_SOURCES)) \
2640 \
2641 common/time/timesysalias.cpp \
2642 VBox/logbackdoor.cpp
2643RuntimeGuestR3_DEFS.win.x86 = $(RuntimeR3_DEFS.win.x86) \
2644 VCC_FAKES_TARGET_$(VBOX_VCC_TOOL_STEM) VCC_FAKES_TARGET=$(substr $(VBOX_VCC_TOOL_STEM),-3)
2645RuntimeGuestR3_SOURCES.win.x86 = $(RuntimeR3_SOURCES.win.x86) \
2646 r3/win/vcc-fakes-kernel32.cpp \
2647 r3/win/vcc-fakes-kernel32-A.asm \
2648 r3/win/vcc-fakes-ntdll.cpp \
2649 r3/win/vcc-fakes-ntdll-A.asm \
2650 r3/win/vcc-fakes-ws2_32.cpp \
2651 r3/win/vcc-fakes-ws2_32-A.asm \
2652 r3/win/vcc-fakes-shell32.cpp \
2653 r3/win/vcc-fakes-shell32-A.asm \
2654
2655
2656#
2657# RuntimeGuestR3-x86 - Same as RuntimeGuestR3, except that it's targeting x86.
2658#
2659RuntimeGuestR3-x86_EXTENDS := RuntimeGuestR3
2660RuntimeGuestR3-x86_BLD_TRG_ARCH := x86
2661
2662
2663#
2664# RuntimeGuestR3Shared - Guest Additions Runtime (static/dll).
2665#
2666RuntimeGuestR3Shared_TEMPLATE := VBoxGuestR3Dll
2667RuntimeGuestR3Shared_EXTENDS := RuntimeGuestR3
2668RuntimeGuestR3Shared_INST = $(INST_ADDITIONS_LIB)
2669ifdef VBOX_WITH_NOCRT_STATIC
2670 if1of ($(KBUILD_TARGET), win)
2671 RuntimeGuestR3Shared_SDKS = $(filter-out VBOX_SOFTFLOAT,$(RuntimeGuestR3_SDKS)) VBOX_SOFTFLOATGUESTR3SHARED
2672 RuntimeGuestR3Shared_SOURCES = $(RuntimeGuestR3_SOURCES) \
2673 common/math/fma.cpp \
2674 common/math/fma-asm.asm \
2675 common/math/fmaf.cpp \
2676 common/math/fmaf-asm.asm \
2677
2678 endif
2679endif
2680
2681#
2682# RuntimeGuestR3Shared-x86 - Same as RuntimeGuestR3Shared, except that it's targeting x86.
2683#
2684RuntimeGuestR3Shared-x86_EXTENDS := RuntimeGuestR3Shared
2685RuntimeGuestR3Shared-x86_BLD_TRG_ARCH := x86
2686
2687
2688#
2689# VBoxRT - Shared Object / DLL version.
2690#
2691VBoxRT_TEMPLATE = VBoxR3DllNoPic
2692VBoxRT_SDKS = VBOX_LIBXML2
2693ifdef VBOX_WITH_LIBCURL
2694 VBoxRT_SDKS += VBOX_LIBCURL
2695endif
2696VBoxRT_SDKS += VBOX_OPENSSL
2697if1of ($(KBUILD_TARGET_ARCH), $(VBOX_SUPPORTED_HOST_ARCHS))
2698VBoxRT_SDKS += VBOX_SOFTFLOAT
2699endif
2700VBoxRT_SDKS.win = $(VBOX_WINPSDK) $(VBOX_WINDDK) VBOX_NTDLL
2701if1of ($(KBUILD_TARGET), win)
2702VBoxRT_INST = $(INST_DLL) $(INST_TESTCASE) $(VBOX_INST_TOOLS)
2703else if1of ($(KBUILD_TARGET)$(VBOX_WITH_HARDENING), darwin win$(VBOX_WITH_HARDENING))
2704VBoxRT_INST = $(INST_DLL) $(INST_TESTCASE)
2705endif
2706VBoxRT_DEFS := $(filter-out RT_NO_GIP, $(RuntimeBaseR3_DEFS)) \
2707 IPRT_WITH_OPENSSL \
2708 IPRT_WITH_XAR \
2709 IPRT_WITH_GHIDRA_DBG_MOD \
2710 $(if-expr !defined(VBOX_WITH_ALT_HASH_CODE),IPRT_WITHOUT_SHA512T224 IPRT_WITHOUT_SHA512T256,)
2711ifn1of ($(KBUILD_TARGET_ARCH), amd64 x86)
2712 VBoxRT_DEFS += RT_NO_GIP
2713endif
2714ifdef VBOX_WITH_LIBCURL
2715 VBoxRT_DEFS += IPRT_WITH_HTTP
2716endif
2717ifdef RTALLOC_REPLACE_MALLOC
2718 VBoxRT_DEFS += RTALLOC_REPLACE_MALLOC
2719endif
2720if defined(VBOX_WITH_DTRACE_R3) && !defined(VBOX_ONLY_VALIDATIONKIT)
2721 ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
2722 VBoxRT_DEFS += IPRT_WITH_DTRACE IPRT_DTRACE_INCLUDE="dtrace/iprt.h"
2723 else
2724 VBoxRT_DEFS += IPRT_WITH_DTRACE IPRT_DTRACE_INCLUDE=\"dtrace/iprt.h\"
2725 endif
2726endif
2727VBoxRT_DEFS.$(KBUILD_TYPE) := $(RuntimeBaseR3_DEFS.$(KBUILD_TYPE))
2728VBoxRT_DEFS.$(KBUILD_TARGET) := $(RuntimeBaseR3_DEFS.$(KBUILD_TARGET))
2729VBoxRT_SOURCES := \
2730 VBox/VBoxRTDeps.cpp \
2731 $(filter-out common/checksum/crc32.cpp, \
2732 $(if-expr defined(VBOX_WITH_ALT_HASH_CODE), $(RuntimeBaseR3_SOURCES), \
2733 $(patsubst common/checksum/alt-%,common/checksum/openssl-%,$(RuntimeBaseR3_SOURCES)) ) ) \
2734 common/checksum/crc32-zlib.cpp \
2735 common/dbg/dbgmodghidra.cpp \
2736 common/fuzz/fuzz.cpp \
2737 common/fuzz/fuzz-config.cpp \
2738 common/fuzz/fuzz-observer.cpp \
2739 common/fuzz/fuzz-target-recorder.cpp \
2740 common/fuzz/fuzzmastercmd.cpp \
2741 common/fuzz/fuzzclientcmd.cpp
2742ifneq ($(KBUILD_TARGET),win)
2743VBox/VBoxRTDeps.cpp_CXXFLAGS = -Wno-deprecated-declarations
2744endif
2745ifdef VBOX_WITH_LIBCURL
2746 VBoxRT_SOURCES += \
2747 common/misc/s3.cpp \
2748 generic/http-curl.cpp \
2749 common/rest/rest-primary-object-types.cpp \
2750 common/rest/rest-binary.cpp \
2751 common/rest/RTCRestAnyObject.cpp \
2752 common/rest/RTCRestArrayBase.cpp \
2753 common/rest/RTCRestClientApiBase.cpp \
2754 common/rest/RTCRestClientApiBaseOci.cpp \
2755 common/rest/RTCRestClientRequestBase.cpp \
2756 common/rest/RTCRestClientResponseBase.cpp \
2757 common/rest/RTCRestJsonPrimaryCursor.cpp \
2758 common/rest/RTCRestStringMapBase.cpp \
2759 common/rest/RTCRestOutputBase.cpp \
2760 common/rest/RTCRestOutputPrettyBase.cpp \
2761 common/rest/RTCRestOutputPrettyToString.cpp \
2762 common/rest/RTCRestOutputToString.cpp
2763endif
2764if defined(VBOX_WITH_DTRACE_R3) && !defined(VBOX_ONLY_VALIDATIONKIT)
2765 VBoxRT_SOURCES += \
2766 iprt.d
2767endif
2768VBoxRT_SOURCES.$(KBUILD_TARGET) = $(RuntimeBaseR3_SOURCES.$(KBUILD_TARGET))
2769VBoxRT_SOURCES.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH) := $(RuntimeBaseR3_SOURCES.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH))
2770VBoxRT_SOURCES.$(KBUILD_TARGET).x86 := $(RuntimeBaseR3_SOURCES.$(KBUILD_TARGET).x86)
2771VBoxRT_SOURCES.$(KBUILD_TARGET).amd64 := $(RuntimeBaseR3_SOURCES.$(KBUILD_TARGET).amd64)
2772VBoxRT_SOURCES.$(KBUILD_TARGET_ARCH) := $(RuntimeBaseR3_SOURCES.$(KBUILD_TARGET_ARCH))
2773VBoxRT_SOURCES.x86 := $(RuntimeBaseR3_SOURCES.x86)
2774VBoxRT_SOURCES.amd64 := $(RuntimeBaseR3_SOURCES.amd64)
2775VBoxRT_SOURCES.win += \
2776 r3/win/dllmain-win.cpp \
2777 $(VBoxRT_0_OUTDIR)/VBoxRT.def
2778VBoxRT_CLEAN.win += \
2779 $(VBoxRT_0_OUTDIR)/VBoxRT.def
2780VBoxRT_INCS := $(RuntimeBaseR3_INCS)
2781VBoxRT_INCS.$(KBUILD_TARGET) := $(RuntimeBaseR3_INCS.$(KBUILD_TARGET))
2782VBoxRT_INCS.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH) := $(RuntimeBaseR3_INCS.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH))
2783VBoxRT_LIBS = \
2784 $(SDK_VBOX_LZF_LIBS) \
2785 $(PATH_STAGE_LIB)/SUPR3$(VBOX_SUFF_LIB)
2786ifndef SDK_VBOX_LIBXML2_LIBS
2787 VBoxRT_LIBS += \
2788 $(PATH_STAGE_LIB)/VBox-libxml2$(VBOX_SUFF_LIB)
2789endif
2790VBoxRT_LIBS += \
2791 $(SDK_VBOX_ZLIB_LIBS)
2792ifndef SDK_VBOX_OPENSSL_LIBS
2793 VBoxRT_LIBS += \
2794 $(PATH_STAGE_LIB)/VBox-libcrypto$(VBOX_SUFF_LIB) \
2795 $(PATH_STAGE_LIB)/VBox-libssl$(VBOX_SUFF_LIB)
2796endif
2797ifdef IPRT_WITH_LZO
2798 VBoxRT_LIBS += lzo2
2799endif
2800ifdef RTALLOC_REPLACE_MALLOC
2801VBoxRT_LIBS += \
2802 $(PATH_STAGE_LIB)/DisasmR3$(VBOX_SUFF_LIB)
2803endif
2804VBoxRT_LIBS.darwin = \
2805 iconv
2806VBoxRT_LIBS.freebsd = \
2807 iconv \
2808 rt
2809VBoxRT_LIBS.haiku = \
2810 iconv
2811VBoxRT_LIBS.solaris = \
2812 kstat \
2813 contract
2814ifn1of ($(KBUILD_TARGET_ARCH), sparc32 sparc64)
2815 # SMBIOS not available on Solaris SPARC.
2816 VBoxRT_LIBS.solaris += smbios
2817endif
2818VBoxRT_LIBS.win += \
2819 $(PATH_SDK_$(VBOX_WINPSDK)_LIB)/wbemuuid.lib \
2820 $(PATH_TOOL_$(VBOX_VCC_TOOL)_LIB)/delayimp.lib
2821VBoxRT_LDFLAGS.darwin = \
2822 -framework IOKit \
2823 -framework CoreFoundation \
2824 -framework CoreServices \
2825 -framework Security \
2826 -framework SystemConfiguration \
2827 -install_name $(VBOX_DYLD_EXECUTABLE_PATH)/VBoxRT.dylib
2828VBoxRT_LDFLAGS.win = /MANIFEST \
2829 /delayload:user32.dll \
2830 /delayload:shell32.dll \
2831 /delayload:ole32.dll \
2832 /delayload:oleaut32.dll \
2833 /delayload:advapi32.dll
2834
2835if1of (VBoxRT,$(DLLS))
2836 $(call VBOX_SET_VER_INFO_DLL,VBoxRT,VirtualBox Runtime)
2837endif
2838
2839
2840if defined(VBOX_WITH_MORE_NT4_COMPAT_BINARIES) && "$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH)" == "win.x86"
2841 #
2842 # Hacks for running tests on NT 4. Really ugly!
2843 #
2844 # We put most of the CRT in VBoxRT because we cannot even load msvcr100.dll
2845 # or msvcp100.dll on NT4 because of kernel32.dll dependencies. More hacks
2846 # in RuntimeR3VccTricks.
2847 #
2848 TEMPLATE_VBoxR3RuntimeDllItself = xx
2849 TEMPLATE_VBoxR3RuntimeDllItself_EXTENDS = VBoxR3RuntimeDll
2850 TEMPLATE_VBoxR3RuntimeDllItself_LIBS.win.x86 = \
2851 $(filter-out $(PATH_STAGE_LIB)/RuntimeR3VccTricks%, $(TEMPLATE_VBoxR3RuntimeDll_LIBS.win.x86))
2852 TEMPLATE_VBoxR3RuntimeDllItself_DEFS += IN_RING3 VCC_FAKES_TARGET_$(VBOX_VCC_TOOL_STEM) VCC_FAKES_TARGET=$(substr $(VBOX_VCC_TOOL_STEM),-3)
2853 TEMPLATE_VBoxR3RuntimeDllItself_SOURCES = \
2854 r3/win/vcc-fakes-kernel32.cpp \
2855 r3/win/vcc-fakes-kernel32-A.asm \
2856 r3/win/vcc-fakes-ws2_32.cpp \
2857 r3/win/vcc-fakes-ws2_32-A.asm \
2858 r3/win/vcc-fakes-ntdll.cpp \
2859 r3/win/vcc-fakes-ntdll-A.asm \
2860 r3/win/vcc-fakes-msvcrt.cpp
2861 VBoxRT_TEMPLATE = VBoxR3RuntimeDllItself
2862 VBoxRT_TEMPLATE.win.x86 = VBoxR3RuntimeDllItself
2863 VBoxRT_DEFS.win.x86 = $(TEMPLATE_VBoxR3RuntimeDll_DEFS.win.x86) \
2864 _CRTIMP_PURE="__declspec(dllexport)" VCC_FAKES_TARGET_$(VBOX_VCC_TOOL_STEM) VCC_FAKES_TARGET=$(substr $(VBOX_VCC_TOOL_STEM),-3)
2865 VBoxRT_LDFLAGS.win.x86 = /IGNORE:4049 /IGNORE:4217
2866 VBoxRT_LIBS.win.x86 = \
2867 $(PATH_TOOL_$(VBOX_VCC_TOOL_STEM)X86_LIB)/oldnames.lib \
2868 $(PATH_TOOL_$(VBOX_VCC_TOOL_STEM)X86_LIB)/libcmt.lib \
2869 $(PATH_TOOL_$(VBOX_VCC_TOOL_STEM)X86_LIB)/libcpmt.lib
2870endif
2871
2872
2873#
2874# HACK ALERT! Make testcase run during build on SELinux boxes.
2875# Create a dummy DLL that ensure that VBoxRT is installed
2876# during the DLL pass and cleaned up later.
2877#
2878ifeq ($(KBUILD_TARGET),linux)
2879 if1of (VBoxRT, $(DLLS))
2880 ifneq ($(wildcard /usr/bin/chcon),)
2881VBoxRT_INSTTYPE = none
2882VBoxRT_DEBUG_INSTTYPE = both
2883
2884VBoxRT-x86_INSTTYPE = $(NO_SUCH_VARIABLE)
2885
2886DLLS += VBoxRTDummy
2887VBoxRTDummy_TEMPLATE = VBoxR3Dll
2888VBoxRTDummy_INSTTYPE = none
2889VBoxRTDummy_LIBS = $(PATH_STAGE_BIN)/VBoxRT.so
2890VBoxRTDummy_CLEAN = $(PATH_STAGE_BIN)/VBoxRT.so
2891BLDDIRS += $(PATH_STAGE_BIN)
2892
2893$(PATH_STAGE_BIN)/VBoxRT.so: $$(VBoxRT_1_TARGET) | $$(dir $$@)
2894 $(INSTALL) $< $@
2895 chcon -t texrel_shlib_t $@ || true
2896
2897VBoxRT:: VBoxRTDummy
2898 endif # chcon present.
2899 endif # building VBoxRT
2900endif # linux
2901
2902if1of ($(DLLS), VBoxRT)
2903 # .def file for windows.
2904 $(call KB_FN_DO_PASS0_ON_TARGET,VBoxRT)
2905 $(VBoxRT_0_OUTDIR)/VBoxRT.def: \
2906 $(PATH_SUB_CURRENT)/r3/win/VBoxRT-$$(if-expr $$(KBUILD_TARGET_ARCH) == amd64,win64,win32).def \
2907 $(PATH_SUB_CURRENT)/r3/win/VBoxRT-openssl-3.0.def \
2908 $(if-expr "$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH)" == "win.x86" && defined(VBOX_WITH_MORE_NT4_COMPAT_BINARIES)\
2909 ,$(PATH_SUB_CURRENT)/r3/win/VBoxRT-msvcr100-win32.def ,) \
2910 | $$(dir $$@) #$(PATH_SUB_CURRENT)/r3/win/VBoxRT-msvcp100-win32.def
2911 $(RM) -f -- $@
2912 $(SED) --output "$@" \
2913 $(if-expr "$(KBUILD_TARGET_ARCH)" == "x86" ,-e "/not-x86/d", -e "/only-x86/d") \
2914 $(if-expr "$(KBUILD_TARGET_ARCH)" == "amd64",-e "/not-amd64/d",-e "/only-amd64/d") \
2915 $(if-expr "$(KBUILD_TARGET_ARCH)" == "arm64",-e "/not-arm64/d",-e "/only-arm64/d") \
2916 $(if-expr "$(substr $(if-expr $(KBUILD_TARGET) != 'win',$(VBOX_GCC_std), $(VBOX_VCC_std)),-2)" >= "17" \
2917 ,-e "/before-noexcept/d", -e "/after-noexcept/d") \
2918 $^
2919 $(call KB_FN_AUTO_CMD_DEPS_COMMANDS)
2920 $(call KB_FN_AUTO_CMD_DEPS,$(VBoxRT_0_OUTDIR)/VBoxRT.def)
2921endif
2922
2923
2924#
2925# VBoxRT-x86 - 32-bit version of VBoxRT
2926#
2927VBoxRT-x86_EXTENDS = VBoxRT
2928VBoxRT-x86_TEMPLATE = VBoxR3Dll-x86
2929VBoxRT-x86_INST.win = $(INST_DLL)x86/
2930VBoxRT-x86_SDKS = VBOX_LIBXML2
2931ifdef VBOX_WITH_LIBCURL
2932 VBoxRT-x86_SDKS += VBOX_LIBCURL-x86
2933endif
2934VBoxRT-x86_SDKS += VBOX_OPENSSL-x86
2935
2936VBoxRT-x86_LIBS = \
2937 $(SDK_VBOX_LZF_LIBS-x86)
2938if1of ($(KBUILD_TARGET_ARCH), amd64 x86)
2939VBoxRT-x86_LIBS += \
2940 $(PATH_STAGE_LIB)/SUPR3-x86$(VBOX_SUFF_LIB)
2941endif
2942ifndef SDK_VBOX_LIBXML2_LIBS
2943 VBoxRT-x86_LIBS += \
2944 $(PATH_STAGE_LIB)/VBox-libxml2-x86$(VBOX_SUFF_LIB)
2945endif
2946VBoxRT-x86_LIBS += \
2947 $(SDK_VBOX_ZLIB_LIBS-x86)
2948ifndef SDK_VBOX_OPENSSL_LIBS
2949 VBoxRT-x86_LIBS += \
2950 $(PATH_STAGE_LIB)/VBox-libcrypto-x86$(VBOX_SUFF_LIB) \
2951 $(PATH_STAGE_LIB)/VBox-libssl-x86$(VBOX_SUFF_LIB)
2952endif
2953ifdef IPRT_WITH_LZO
2954 VBoxRT-x86_LIBS += lzo2
2955endif
2956VBoxRT-x86_LIBS.darwin = \
2957 iconv
2958VBoxRT-x86_LIBS.freebsd = \
2959 iconv \
2960 rt
2961VBoxRT-x86_LIBS.haiku = \
2962 iconv
2963VBoxRT-x86_LIBS.solaris = \
2964 kstat \
2965 contract
2966ifn1of ($(KBUILD_TARGET_ARCH), sparc32 sparc64)
2967 # SMBIOS not available on Solaris SPARC.
2968 VBoxRT-x86_LIBS.solaris += smbios
2969endif
2970VBoxRT-x86_LIBS.win += \
2971 $(PATH_SDK_$(VBOX_WINPSDK)_LIB.x86)/wbemuuid.lib \
2972 $(PATH_TOOL_$(VBOX_VCC_TOOL_STEM)X86_LIB)/delayimp.lib
2973
2974VBoxRT-x86_SOURCES.win = $(filter-out %.def %.rc,$(VBoxRT_SOURCES.win)) \
2975 $(VBoxRT-x86_0_OUTDIR)/VBoxRT-x86.def
2976VBoxRT-x86_CLEAN += $(VBoxRT-x86_0_OUTDIR)/VBoxRT-x86.def
2977
2978if1of (VBoxRT-x86,$(DLLS))
2979 $(call VBOX_SET_VER_INFO_DLL,VBoxRT-x86,VirtualBox 32-bit Runtime)
2980endif
2981
2982if1of ($(DLLS), VBoxRT-x86)
2983 # .def file for windows.
2984 $(call KB_FN_DO_PASS0_ON_TARGET,VBoxRT-x86)
2985 $(VBoxRT-x86_0_OUTDIR)/VBoxRT-x86.def: \
2986 $(VBOX_PATH_RUNTIME_SRC)/r3/win/VBoxRT-win32.def \
2987 | $$(dir $$@) # Hopefully no need to export openssl here.
2988 $(RM) -f -- $@
2989 $(SED) --output "$@" \
2990 -e "/not-x86/d" \
2991 -e "/only-amd64/d" \
2992 -e "/only-arm64/d" \
2993 $(if-expr "$(substr $(if-expr $(KBUILD_TARGET) != 'win',$(VBOX_GCC_std), $(VBOX_VCC_std)),-2)" >= "17" \
2994 ,-e "/before-noexcept/d", -e "/after-noexcept/d") \
2995 $(VBOX_PATH_RUNTIME_SRC)/r3/win/VBoxRT-win32.def
2996 $(call KB_FN_AUTO_CMD_DEPS_COMMANDS)
2997 $(call KB_FN_AUTO_CMD_DEPS,$(VBoxRT-x86_0_OUTDIR)/VBoxRT-x86.def)
2998endif
2999
3000#
3001# VBoxRTImp - Import library/hack.
3002#
3003ifeq ($(KBUILD_TARGET).$(KBUILD_TARGET_ARCH),win.amd64)
3004$(call VBOX_GENERATE_IMPORT_TARGET_FN,VBoxRTImp,VBoxRT,VBox/VBoxRTImp.def VBox/VBoxRTImp-vcc64.def r3/win/VBoxRT-win64.def)
3005else ifeq ($(KBUILD_TARGET).$(KBUILD_TARGET_ARCH),win.x86)
3006$(call VBOX_GENERATE_IMPORT_TARGET_FN,VBoxRTImp,VBoxRT,VBox/VBoxRTImp.def VBox/VBoxRTImp-vcc32.def r3/win/VBoxRT-win32.def)
3007else
3008$(call VBOX_GENERATE_IMPORT_TARGET_FN,VBoxRTImp,VBoxRT,VBox/VBoxRTImp.def VBox/VBoxRTImp-gcc.def)
3009endif
3010
3011
3012if1of ($(KBUILD_TARGET),win linux darwin) # remove later
3013if1of ($(KBUILD_TARGET_ARCH),x86 amd64) ## @todo bugref:9898
3014if1of (VBoxRT,$(DLLS))
3015 #
3016 # VBoxRTImpCheck - Import library check.
3017 #
3018 PROGRAMS += VBoxRTStableCheck
3019 VBoxRTStableCheck_TEMPLATE = VBOXR3TSTEXE
3020 VBoxRTStableCheck_SOURCES = \
3021 VBox/VBoxRTStableCheck.cpp \
3022 $(VBoxRTStableCheck_0_OUTDIR)/VBoxRTStableCheckA.asm
3023 VBoxRTStableCheck_LIBS = \
3024 $(LIB_RUNTIME)
3025 VBoxRTStableCheck_CLEAN = \
3026 $(VBoxRTStableCheck_0_OUTDIR)/VBoxRTStableCheckA.asm
3027 $(call KB_FN_DO_PASS0_ON_TARGET,VBoxRTStableCheck)
3028
3029 ifeq ($(KBUILD_TARGET).$(KBUILD_TARGET_ARCH),win.amd64)
3030 $(VBoxRTStableCheck_0_OUTDIR)/VBoxRTStableCheckA.asm: \
3031 $(PATH_SUB_CURRENT)/VBox/DefToAsmExterns.sed \
3032 $(PATH_SUB_CURRENT)/VBox/VBoxRTImp.def \
3033 $(PATH_SUB_CURRENT)/VBox/VBoxRTImp-vcc64.def \
3034 $(PATH_SUB_CURRENT)/r3/win/VBoxRT-win64.def \
3035 | $$(dir $$@)
3036 else ifeq ($(KBUILD_TARGET).$(KBUILD_TARGET_ARCH),win.x86)
3037 $(VBoxRTStableCheck_0_OUTDIR)/VBoxRTStableCheckA.asm: \
3038 $(PATH_SUB_CURRENT)/VBox/DefToAsmExternsVcc32.sed \
3039 $(PATH_SUB_CURRENT)/VBox/VBoxRTImp.def \
3040 $(PATH_SUB_CURRENT)/VBox/VBoxRTImp-vcc32.def \
3041 $(PATH_SUB_CURRENT)/r3/win/VBoxRT-win32.def | $$(dir $$@)
3042 else
3043 $(VBoxRTStableCheck_0_OUTDIR)/VBoxRTStableCheckA.asm: \
3044 $(PATH_SUB_CURRENT)/VBox/DefToAsmExterns.sed \
3045 $(PATH_SUB_CURRENT)/VBox/VBoxRTImp.def \
3046 $(PATH_SUB_CURRENT)/VBox/VBoxRTImp-gcc.def | $$(dir $$@)
3047 endif
3048 $(APPEND) -tn "$@" '%include "iprt/asmdefs.mac"' ''
3049 $(SED) --append "$@" \
3050 -e "/not-$(KBUILD_TARGET)/d" \
3051 $(if-expr "$(KBUILD_TARGET)" == "linux" ,, -e "/only-linux/d") \
3052 $(if-expr "$(KBUILD_TARGET)" == "win" ,, -e "/only-win/d") \
3053 $(if-expr "$(KBUILD_TARGET)" == "darwin",, -e "/only-darwin/d") \
3054 $(if-expr "$(KBUILD_TARGET_ARCH)" == "x86" ,-e "/not-x86/d", -e "/only-x86/d") \
3055 $(if-expr "$(KBUILD_TARGET_ARCH)" == "amd64",-e "/not-amd64/d",-e "/only-amd64/d") \
3056 $(if-expr "$(KBUILD_TARGET_ARCH)" == "arm64",-e "/not-arm64/d",-e "/only-arm64/d") \
3057 $(if-expr "$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH)" == "darwin.arm64",, -e "/only-darwin.arm64/d") \
3058 $(if-expr "$(substr $(if-expr $(KBUILD_TARGET) != 'win',$(VBOX_GCC_std), $(VBOX_VCC_std)),-2)" >= "17" \
3059 ,-e "/before-noexcept/d", -e "/after-noexcept/d") \
3060 -f "$<" $(filter %.def, $^)
3061 $(call KB_FN_AUTO_CMD_DEPS_COMMANDS)
3062 $(call KB_FN_AUTO_CMD_DEPS,$(VBoxRTStableCheck_0_OUTDIR)/VBoxRTStableCheckA.asm)
3063
3064endif
3065endif ## @todo bugref:9898
3066endif # remove later
3067
3068
3069#
3070# RuntimeR3NoCRTGCC - CRT replacement lib for VBoxREM.
3071# This is used together with VBoxRT.
3072#
3073RuntimeR3NoCRTGCC_TEMPLATE = VBoxNoCrtGccLib
3074RuntimeR3NoCRTGCC_LIBSUFF = $(VBOX_SUFF_LIB)
3075RuntimeR3NoCRTGCC_DEFS = RT_WITH_NOCRT_ALIASES
3076ifn1of ($(KBUILD_TARGET_ARCH), amd64 x86)
3077 RuntimeR3NoCRTGCC_DEFS += RT_NO_GIP
3078endif
3079RuntimeR3NoCRTGCC_INCS = include
3080RuntimeR3NoCRTGCC_SOURCES := \
3081 common/misc/sanity-cpp.cpp \
3082 common/misc/sanity-c.c \
3083 \
3084 $(RuntimeNoCrt_SOURCES)
3085
3086if1of ($(KBUILD_TARGET_ARCH), amd64 x86)
3087RuntimeR3NoCRTGCC_SOURCES += \
3088 common/math/ceill.asm \
3089 common/math/cosl.asm \
3090 common/math/fabs.asm \
3091 common/math/fabsf.asm \
3092 common/math/fabsl.asm \
3093 common/math/floor.asm \
3094 common/math/floorf.asm \
3095 common/math/floorl.asm \
3096 common/math/ldexpl.asm \
3097 common/math/llrint.asm \
3098 common/math/llrintf.asm \
3099 common/math/llrintl.asm \
3100 common/math/logl.asm \
3101 common/math/lrint.asm \
3102 common/math/lrintf.asm \
3103 common/math/lrintl.asm \
3104 common/math/remainder.asm \
3105 common/math/remainderf.asm \
3106 common/math/remainderl.asm \
3107 common/math/sinl.asm \
3108 common/math/tanl.asm \
3109 common/math/trunc.asm \
3110 common/math/truncf.asm \
3111 common/math/truncl.asm
3112endif
3113
3114RuntimeR3NoCRTGCC_SOURCES.x86 = \
3115 common/math/gcc/adddi3.c \
3116 common/math/gcc/anddi3.c \
3117 common/math/gcc/ashldi3.c \
3118 common/math/gcc/ashrdi3.c \
3119 common/math/gcc/cmpdi2.c \
3120 common/math/gcc/divdi3.c \
3121 common/math/gcc/divmoddi4.c \
3122 common/math/gcc/iordi3.c \
3123 common/math/gcc/lshldi3.c \
3124 common/math/gcc/lshrdi3.c \
3125 common/math/gcc/moddi3.c \
3126 common/math/gcc/muldi3.c \
3127 common/math/gcc/negdi2.c \
3128 common/math/gcc/notdi2.c \
3129 common/math/gcc/qdivrem.c \
3130 common/math/gcc/subdi3.c \
3131 common/math/gcc/ucmpdi2.c \
3132 common/math/gcc/udivdi3.c \
3133 common/math/gcc/udivmoddi4.c \
3134 common/math/gcc/umoddi3.c \
3135 common/math/gcc/xordi3.c
3136
3137#
3138# RuntimeR3NoCRT - For windows applications w/o any runtime library.
3139# Experimental.
3140#
3141RuntimeR3NoCrt_TEMPLATE := VBoxR3StaticNoCrt
3142RuntimeR3NoCrt_INCS := include
3143RuntimeR3NoCrt_DEFS := \
3144 RT_NO_STRICT \
3145 IPRT_NO_ALLOCA_TROUBLE \
3146 IPRT_GETOPT_WITHOUT_NETWORK_ADDRESSES \
3147 IPRT_MINIMAL_STREAM \
3148 IPRT_NO_FLOAT_FORMATTING
3149RuntimeR3NoCrt_SOURCES := \
3150 common/string/straprintf.cpp \
3151 common/string/strformat.cpp \
3152 common/string/RTStrFormat.cpp \
3153 common/string/strformatnum.cpp \
3154 common/string/strformatrt.cpp \
3155 common/string/strformattype.cpp \
3156 common/string/strprintf.cpp \
3157 common/string/strprintf-ellipsis.cpp \
3158 common/string/strprintf2.cpp \
3159 common/string/strprintf2-ellipsis.cpp \
3160 common/string/stringalloc.cpp \
3161 common/string/strtonum.cpp \
3162 common/string/RTStrNLen.cpp \
3163 common/string/RTStrCmp.cpp \
3164 common/string/RTStrNCmp.cpp \
3165 common/string/RTStrICmpAscii.cpp \
3166 common/string/RTStrNICmpAscii.cpp \
3167 common/string/RTStrCopy.cpp \
3168 common/string/RTStrEnd.asm \
3169 common/string/RTUtf16Copy.cpp \
3170 common/string/utf-16.cpp \
3171 common/string/utf-8.cpp \
3172 common/path/RTPathFilename.cpp \
3173 common/misc/getopt.cpp \
3174 common/misc/getoptargv.cpp \
3175 common/misc/message.cpp \
3176 common/err/errmsg.cpp \
3177 generic/uuid-generic.cpp \
3178 generic/rtStrFormatKernelAddress-generic.cpp
3179
3180RuntimeR3NoCrt_SOURCES.x86 := \
3181 common/string/memcpy.asm \
3182 common/string/memchr.asm \
3183 common/string/memcmp.asm \
3184 common/string/memmove.asm \
3185 common/string/memset.asm \
3186 common/string/strlen.asm \
3187 common/string/strchr.asm \
3188 common/string/strcmp.asm \
3189 common/string/strncmp.asm
3190RuntimeR3NoCrt_SOURCES.amd64 := \
3191 common/string/memcpy.asm \
3192 common/string/memchr.asm \
3193 common/string/memcmp.asm \
3194 common/string/memmove.asm \
3195 common/string/memset.asm \
3196 common/string/strlen.asm \
3197 common/string/strchr.asm \
3198 common/string/strcmp.asm \
3199 common/string/strncmp.asm \
3200
3201RuntimeR3NoCrt_SOURCES.win := \
3202 r3/win/nocrt-startup-exe-win.cpp \
3203 r3/win/nocrt-startup-common-win.cpp \
3204 r3/win/nocrt-fatal-write-win.cpp \
3205 r3/win/nocrt-alloc-win.cpp \
3206 r3/win/nocrt-streams-win.cpp \
3207 \
3208 win/errmsgwin.cpp
3209
3210#
3211# RuntimeR0 - Ring-0 library for VMMR0.
3212#
3213RuntimeR0_TEMPLATE = VBoxR0
3214RuntimeR0_DEFS = IN_RT_R0 RT_WITH_VBOX NOFILEID
3215ifn1of ($(KBUILD_TARGET_ARCH), amd64 x86)
3216 RuntimeR0_DEFS += RT_NO_GIP
3217endif
3218if defined(VBOX_WITH_DTRACE_R0) && !defined(VBOX_ONLY_VALIDATIONKIT)
3219 ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
3220 RuntimeR0_DEFS += IPRT_WITH_DTRACE IPRT_DTRACE_PREFIX=VBOXVMM_ IPRT_DTRACE_INCLUDE="dtrace/VBoxVMM.h"
3221 else
3222 RuntimeR0_DEFS += IPRT_WITH_DTRACE IPRT_DTRACE_PREFIX=VBOXVMM_ IPRT_DTRACE_INCLUDE=\"dtrace/VBoxVMM.h\"
3223 endif
3224endif
3225RuntimeR0_INCS = include
3226RuntimeR0_SOURCES := \
3227 $(if $(VBOX_ONLY_VALIDATIONKIT),,../VMM/VBoxVMM.d) \
3228 common/checksum/crc32c.cpp \
3229 common/log/logellipsis.cpp \
3230 common/log/logrelellipsis.cpp \
3231 common/log/logcom.cpp \
3232 common/log/logformat.cpp \
3233 common/log/tracebuf.cpp \
3234 common/log/tracedefault.cpp \
3235 common/log/RTLogCreateEx.cpp \
3236 common/log/RTLogSetR0ThreadNameF.cpp \
3237 common/misc/RTAssertMsg1Weak.cpp \
3238 common/misc/RTAssertMsg2.cpp \
3239 common/misc/RTAssertMsg2Add.cpp \
3240 common/misc/RTAssertMsg2AddWeak.cpp \
3241 common/misc/RTAssertMsg2AddWeakV.cpp \
3242 common/misc/RTAssertMsg2Weak.cpp \
3243 common/misc/RTAssertMsg2WeakV.cpp \
3244 common/misc/buildconfig.cpp \
3245 common/misc/once.cpp \
3246 common/misc/sanity-c.c \
3247 common/misc/sanity-cpp.cpp \
3248 common/misc/term.cpp \
3249 common/path/RTPathFilename.cpp \
3250 common/rand/rand.cpp \
3251 common/rand/randadv.cpp \
3252 common/rand/randparkmiller.cpp \
3253 common/string/strprintf-ellipsis.cpp \
3254 common/string/strprintf2-ellipsis.cpp \
3255 common/string/strhash1.cpp \
3256 common/string/strncmp.cpp \
3257 common/string/strpbrk.cpp \
3258 common/string/strtonum.cpp \
3259 common/string/RTStrCat.cpp \
3260 common/string/RTStrCatEx.cpp \
3261 common/string/RTStrCatP.cpp \
3262 common/string/RTStrCatPEx.cpp \
3263 common/string/RTStrCopyEx.cpp \
3264 common/string/RTStrCopyP.cpp \
3265 common/string/RTStrCopyPEx.cpp \
3266 common/string/RTStrCmp.cpp \
3267 common/string/RTStrICmpAscii.cpp \
3268 common/string/RTStrNICmpAscii.cpp \
3269 common/string/RTStrNLen.cpp \
3270 common/string/RTStrNLenEx.cpp \
3271 common/table/avlgcptr.cpp \
3272 common/table/avlhcphys.cpp \
3273 common/table/avllu32.cpp \
3274 common/table/avlogcphys.cpp \
3275 common/table/avlogcptr.cpp \
3276 common/table/avlohcphys.cpp \
3277 common/table/avloioport.cpp \
3278 common/table/avlpv.cpp \
3279 common/table/avlrogcphys.cpp \
3280 common/table/avlrogcptr.cpp \
3281 common/table/avlroioport.cpp \
3282 common/table/avlroogcptr.cpp \
3283 common/table/avlu32.cpp \
3284 common/table/avlou32.cpp \
3285 common/time/timesup.cpp \
3286 generic/RTAssertShouldPanic-generic.cpp \
3287 generic/critsect-generic.cpp \
3288 generic/critsectrw-generic.cpp \
3289 generic/RTRandAdvCreateSystemFaster-generic.cpp \
3290 generic/RTRandAdvCreateSystemTruer-generic.cpp \
3291 \
3292 $(RuntimeNoCrt_SOURCES)
3293
3294if1of ($(KBUILD_TARGET), darwin solaris freebsd os2)
3295RuntimeR0_SOURCES += \
3296 common/math/gcc/adddi3.c \
3297 common/math/gcc/anddi3.c \
3298 common/math/gcc/ashldi3.c \
3299 common/math/gcc/ashrdi3.c \
3300 common/math/gcc/cmpdi2.c \
3301 common/math/gcc/divdi3.c \
3302 common/math/gcc/divmoddi4.c \
3303 common/math/gcc/iordi3.c \
3304 common/math/gcc/lshldi3.c \
3305 common/math/gcc/lshrdi3.c \
3306 common/math/gcc/moddi3.c \
3307 common/math/gcc/muldi3.c \
3308 common/math/gcc/negdi2.c \
3309 common/math/gcc/notdi2.c \
3310 common/math/gcc/qdivrem.c \
3311 common/math/gcc/subdi3.c \
3312 common/math/gcc/ucmpdi2.c \
3313 common/math/gcc/udivdi3.c \
3314 common/math/gcc/udivmoddi4.c \
3315 common/math/gcc/umoddi3.c \
3316 common/math/gcc/xordi3.c
3317endif
3318
3319RuntimeR0_SOURCES.x86 += \
3320 common/asm/ASMCpuIdExSlow.asm \
3321 common/asm/ASMAtomicUoAndU64.asm \
3322 common/asm/ASMAtomicUoAndU32.asm \
3323 common/asm/ASMAtomicUoDecU32.asm \
3324 common/asm/ASMAtomicUoIncU32.asm \
3325 common/asm/ASMAtomicUoOrU64.asm \
3326 common/asm/ASMAtomicUoOrU32.asm \
3327 common/asm/ASMAtomicUoXorU32.asm \
3328 common/asm/ASMMemFirstMismatchingU8.asm \
3329 common/asm/ASMGetXcr0.asm \
3330 common/asm/ASMSetXcr0.asm \
3331 common/asm/ASMXSave.asm \
3332 common/asm/ASMXRstor.asm \
3333 common/asm/ASMFxSave.asm \
3334 common/asm/ASMFxRstor.asm \
3335 common/asm/ASMRdMsrEx.asm \
3336 common/asm/ASMWrMsrEx.asm \
3337 common/string/RTStrEnd.asm
3338RuntimeR0_SOURCES.amd64 += \
3339 common/asm/ASMCpuIdExSlow.asm \
3340 common/asm/ASMAtomicUoAndU64.asm \
3341 common/asm/ASMAtomicUoAndU32.asm \
3342 common/asm/ASMAtomicUoDecU32.asm \
3343 common/asm/ASMAtomicUoIncU32.asm \
3344 common/asm/ASMAtomicUoOrU64.asm \
3345 common/asm/ASMAtomicUoOrU32.asm \
3346 common/asm/ASMAtomicUoXorU32.asm \
3347 common/asm/ASMMemFirstMismatchingU8.asm \
3348 common/asm/ASMGetXcr0.asm \
3349 common/asm/ASMSetXcr0.asm \
3350 common/asm/ASMXSave.asm \
3351 common/asm/ASMXRstor.asm \
3352 common/asm/ASMFxSave.asm \
3353 common/asm/ASMFxRstor.asm \
3354 common/asm/ASMRdMsrEx.asm \
3355 common/asm/ASMWrMsrEx.asm \
3356 common/math/RTUInt128MulByU64Ex.asm \
3357 common/string/RTStrEnd.asm
3358RuntimeR0_SOURCES.arm32 += \
3359 common/string/RTStrEnd.cpp
3360RuntimeR0_SOURCES.arm64 += \
3361 common/string/RTStrEnd.cpp
3362RuntimeR0_SOURCES.sparc32 += \
3363 common/string/RTStrEnd.cpp
3364RuntimeR0_SOURCES.sparc64 += \
3365 common/string/RTStrEnd.cpp
3366
3367#if1of ($(KBUILD_TARGET_ARCH),amd64 x86)
3368# RuntimeR0_SOURCES += common/time/timesupA.asm
3369#else
3370 RuntimeR0_SOURCES += common/time/timesupref.cpp
3371#endif
3372
3373RuntimeR0_SOURCES.win.amd64 := $(RuntimeWin64ASM_SOURCES)
3374RuntimeR0_SOURCES.win.x86 := $(RuntimeWin32ASM_SOURCES)
3375RuntimeR0_SOURCES.win = \
3376 nt/NtProcessStartup-stub.cpp
3377
3378RuntimeR0_SOURCES.os2 = \
3379 os2/sys0.asm
3380
3381
3382#
3383# RuntimeR0Stub - Ring-0 context startup stub for Windows and Solaris.
3384#
3385RuntimeR0Stub_TEMPLATE = $(if-expr "$(KBUILD_TARGET)" == "solaris",VBoxR0DrvLib,VBoxR0)
3386RuntimeR0Stub_SOURCES.win = \
3387 nt/NtProcessStartup-stub.cpp
3388RuntimeR0Stub_SOURCES.solaris = \
3389 r0drv/solaris/modulestub-r0drv-solaris.c
3390
3391
3392#
3393# RuntimeR0Drv - Ring-0 library for host drivers.
3394#
3395RuntimeR0Drv_TEMPLATE = VBoxR0DrvLib
3396RuntimeR0Drv_SDKS.win = ReorderCompilerIncs $(VBOX_WINDDK) $(VBOX_WINPSDK_INCS) VBOX_OPENSSL
3397RuntimeR0Drv_DEFS = IN_RT_R0 RT_WITH_VBOX RT_WITHOUT_NOCRT_WRAPPERS RT_NO_EXPORT_SYMBOL NOFILEID
3398RuntimeR0Drv_DEFS.win = IN_SUP_R0 LDR_ONLY_PE IPRT_WITHOUT_DIGEST_MD4
3399RuntimeR0Drv_DEFS.darwin= IN_SUP_R0 LDR_ONLY_MACHO IPRT_WITHOUT_DIGEST_MD4 IN_RING0_DRV_ON_DARWIN
3400if ($(VBOX_SOLARIS_11_UPDATE_VERSION) > 2 \
3401 || ($(VBOX_SOLARIS_11_UPDATE_VERSION) == 2 && $(VBOX_SOLARIS_11_BUILD_VERSION) >= 22))
3402RuntimeR0Drv_DEFS.solaris += VBOX_NEW_CRASH_DUMP_FORMAT
3403endif
3404
3405RuntimeR0Drv_INCS := $(PATH_SUB_CURRENT) include
3406RuntimeR0Drv_INCS.freebsd = \
3407 $(PATH_STAGE)/gen-sys-hdrs
3408RuntimeR0Drv_INCS.solaris = \
3409 r0drv/solaris/vbi/i86pc \
3410 r0drv/solaris/vbi/i86pc/sys
3411
3412RuntimeR0Drv_SOURCES = \
3413 common/alloc/alloc.cpp \
3414 common/alloc/heapsimple.cpp \
3415 common/alloc/heapoffset.cpp \
3416 common/checksum/alt-md5.cpp \
3417 common/checksum/crc32.cpp \
3418 common/checksum/crc64.cpp \
3419 common/checksum/ipv4.cpp \
3420 common/checksum/ipv6.cpp \
3421 common/err/RTErrConvertToErrno.cpp \
3422 common/err/RTErrConvertFromErrno.cpp \
3423 common/err/errinfo.cpp \
3424 common/log/log.cpp \
3425 common/log/logellipsis.cpp \
3426 common/log/logrel.cpp \
3427 common/log/logrelellipsis.cpp \
3428 common/log/logcom.cpp \
3429 common/log/logformat.cpp \
3430 common/log/tracebuf.cpp \
3431 common/log/tracedefault.cpp \
3432 common/log/RTLogCreateEx.cpp \
3433 common/misc/RTAssertMsg1Weak.cpp \
3434 common/misc/RTAssertMsg2.cpp \
3435 common/misc/RTAssertMsg2Add.cpp \
3436 common/misc/RTAssertMsg2AddWeak.cpp \
3437 common/misc/RTAssertMsg2AddWeakV.cpp \
3438 common/misc/RTAssertMsg2Weak.cpp \
3439 common/misc/RTAssertMsg2WeakV.cpp \
3440 common/misc/assert.cpp \
3441 common/misc/buildconfig.cpp \
3442 common/misc/handletable.cpp \
3443 common/misc/handletablectx.cpp \
3444 common/misc/handletablesimple.cpp \
3445 common/misc/once.cpp \
3446 common/misc/sanity-c.c \
3447 common/misc/sanity-cpp.cpp \
3448 common/misc/term.cpp \
3449 common/misc/RTMemWipeThoroughly.cpp \
3450 common/path/rtPathVolumeSpecLen.cpp \
3451 common/path/RTPathAbsDup.cpp \
3452 common/path/RTPathAbsEx.cpp \
3453 common/path/RTPathAbsExDup.cpp \
3454 common/path/RTPathAppend.cpp \
3455 common/path/RTPathAppendEx.cpp \
3456 common/path/RTPathExt.cpp \
3457 common/path/RTPathFilename.cpp \
3458 common/path/RTPathHasExt.cpp \
3459 common/path/RTPathHasPath.cpp \
3460 common/path/RTPathParseSimple.cpp \
3461 common/path/RTPathRealDup.cpp \
3462 common/path/RTPathStripExt.cpp \
3463 common/path/RTPathStripFilename.cpp \
3464 common/path/RTPathStripTrailingSlash.cpp \
3465 common/rand/rand.cpp \
3466 common/rand/randadv.cpp \
3467 common/rand/randparkmiller.cpp \
3468 common/string/RTStrCat.cpp \
3469 common/string/RTStrCatEx.cpp \
3470 common/string/RTStrCatP.cpp \
3471 common/string/RTStrCatPEx.cpp \
3472 common/string/RTStrCmp.cpp \
3473 common/string/RTStrCopy.cpp \
3474 common/string/RTStrCopyEx.cpp \
3475 common/string/RTStrCopyP.cpp \
3476 common/string/RTStrCopyPEx.cpp \
3477 common/string/RTStrICmpAscii.cpp \
3478 common/string/RTStrNICmpAscii.cpp \
3479 common/string/RTStrNCmp.cpp \
3480 common/string/RTStrNLen.cpp \
3481 common/string/RTStrNLenEx.cpp \
3482 common/string/RTUtf16ICmpAscii.cpp \
3483 common/string/RTUtf16NICmpAscii.cpp \
3484 common/string/straprintf.cpp \
3485 common/string/strformat.cpp \
3486 common/string/RTStrFormat.cpp \
3487 common/string/strformatnum.cpp \
3488 common/string/strformatrt.cpp \
3489 common/string/strformattype.cpp \
3490 common/string/strhash1.cpp \
3491 common/string/strprintf.cpp \
3492 common/string/strprintf-ellipsis.cpp \
3493 common/string/strprintf2.cpp \
3494 common/string/strprintf2-ellipsis.cpp \
3495 common/string/strtonum.cpp \
3496 common/string/stringalloc.cpp \
3497 common/string/unidata-flags.cpp \
3498 common/string/unidata-lower.cpp \
3499 common/string/unidata-upper.cpp \
3500 common/string/utf-8.cpp \
3501 common/string/utf-8-case.cpp \
3502 common/string/utf-8-case2.cpp \
3503 common/string/utf-16.cpp \
3504 common/string/utf-16-case.cpp \
3505 common/string/utf-16-latin-1.cpp \
3506 common/string/utf-16-printf.cpp \
3507 common/table/avlpv.cpp \
3508 common/table/avlu32.cpp \
3509 common/table/avllu32.cpp \
3510 common/time/time.cpp \
3511 generic/RTLogWriteStdErr-stub-generic.cpp \
3512 generic/RTLogWriteUser-generic.cpp \
3513 generic/RTMpGetArraySize-generic.cpp \
3514 generic/RTRandAdvCreateSystemFaster-generic.cpp \
3515 generic/RTSemEventWait-2-ex-generic.cpp \
3516 generic/RTSemEventWaitNoResume-2-ex-generic.cpp \
3517 generic/RTSemEventMultiWait-2-ex-generic.cpp \
3518 generic/RTSemEventMultiWaitNoResume-2-ex-generic.cpp \
3519 generic/critsect-generic.cpp \
3520 generic/critsectrw-generic.cpp \
3521 generic/errvars-generic.cpp \
3522 generic/uuid-generic.cpp \
3523 r0drv/alloc-r0drv.cpp \
3524 r0drv/initterm-r0drv.cpp \
3525 r0drv/generic/semspinmutex-r0drv-generic.c \
3526 r0drv/RTR0DbgKrnlInfoGetSymbol.cpp \
3527 VBox/log-vbox.cpp \
3528
3529RuntimeR0Drv_SOURCES.amd64 = \
3530 common/asm/ASMCpuIdExSlow.asm \
3531 common/asm/ASMMemFirstMismatchingU8.asm \
3532 common/asm/ASMRdMsrEx.asm \
3533 common/asm/ASMWrMsrEx.asm \
3534 common/math/bignum-amd64-x86.asm \
3535 common/math/RTUInt128MulByU64.asm \
3536 common/math/RTUInt128MulByU64Ex.asm \
3537 common/string/RTStrEnd.asm
3538RuntimeR0Drv_SOURCES.x86 = \
3539 common/asm/ASMCpuIdExSlow.asm \
3540 common/asm/ASMMemFirstMismatchingU8.asm \
3541 common/asm/ASMRdMsrEx.asm \
3542 common/asm/ASMWrMsrEx.asm \
3543 common/math/bignum-amd64-x86.asm \
3544 common/string/RTStrEnd.asm
3545RuntimeR0Drv_SOURCES.arm32 += \
3546 common/string/RTStrEnd.cpp
3547RuntimeR0Drv_SOURCES.arm64 += \
3548 common/string/RTStrEnd.cpp
3549RuntimeR0Drv_SOURCES.sparc32 += \
3550 common/string/RTStrEnd.cpp
3551RuntimeR0Drv_SOURCES.sparc64 += \
3552 common/string/RTStrEnd.cpp
3553
3554RuntimeR0Drv_SOURCES.linux = \
3555 common/misc/thread.cpp \
3556 common/string/strpbrk.cpp \
3557 generic/RTAssertShouldPanic-generic.cpp \
3558 generic/RTLogWriteStdOut-stub-generic.cpp \
3559 generic/RTMpGetCoreCount-generic.cpp \
3560 generic/mppresent-generic.cpp \
3561 generic/rtStrFormatKernelAddress-generic.cpp \
3562 r0drv/linux/alloc-r0drv-linux.c \
3563 r0drv/linux/assert-r0drv-linux.c \
3564 r0drv/linux/initterm-r0drv-linux.c \
3565 r0drv/linux/memobj-r0drv-linux.c \
3566 r0drv/linux/memuserkernel-r0drv-linux.c \
3567 r0drv/linux/mp-r0drv-linux.c \
3568 r0drv/linux/mpnotification-r0drv-linux.c \
3569 r0drv/linux/process-r0drv-linux.c \
3570 r0drv/linux/RTLogWriteDebugger-r0drv-linux.c \
3571 r0drv/linux/semevent-r0drv-linux.c \
3572 r0drv/linux/semeventmulti-r0drv-linux.c \
3573 r0drv/linux/semfastmutex-r0drv-linux.c \
3574 r0drv/linux/semmutex-r0drv-linux.c \
3575 r0drv/linux/spinlock-r0drv-linux.c \
3576 r0drv/linux/thread-r0drv-linux.c \
3577 r0drv/linux/thread2-r0drv-linux.c \
3578 r0drv/linux/threadctxhooks-r0drv-linux.c \
3579 r0drv/linux/time-r0drv-linux.c \
3580 r0drv/linux/timer-r0drv-linux.c \
3581 r0drv/memobj-r0drv.cpp \
3582 r0drv/mpnotification-r0drv.c \
3583 r0drv/powernotification-r0drv.c
3584
3585RuntimeR0Drv_SOURCES.win = \
3586 common/ldr/ldr.cpp \
3587 common/ldr/ldrEx.cpp \
3588 common/ldr/ldrPE.cpp \
3589 common/asn1/asn1-basics.cpp \
3590 common/asn1/asn1-dump.cpp \
3591 common/asn1/asn1-cursor.cpp \
3592 common/asn1/asn1-default-allocator.cpp \
3593 common/asn1/asn1-safer-allocator.cpp \
3594 common/asn1/asn1-encode.cpp \
3595 common/asn1/asn1-ut-bitstring.cpp \
3596 common/asn1/asn1-ut-bitstring-decode.cpp \
3597 common/asn1/asn1-ut-boolean.cpp \
3598 common/asn1/asn1-ut-boolean-decode.cpp \
3599 common/asn1/asn1-ut-core.cpp \
3600 common/asn1/asn1-ut-core-decode.cpp \
3601 common/asn1/asn1-ut-dyntype.cpp \
3602 common/asn1/asn1-ut-dyntype-decode.cpp \
3603 common/asn1/asn1-ut-integer.cpp \
3604 common/asn1/asn1-ut-integer-decode.cpp \
3605 common/asn1/asn1-ut-null.cpp \
3606 common/asn1/asn1-ut-null-decode.cpp \
3607 common/asn1/asn1-ut-objid.cpp \
3608 common/asn1/asn1-ut-objid-decode.cpp \
3609 common/asn1/asn1-ut-octetstring.cpp \
3610 common/asn1/asn1-ut-octetstring-decode.cpp \
3611 common/asn1/asn1-ut-string.cpp \
3612 common/asn1/asn1-ut-string-decode.cpp \
3613 common/asn1/asn1-ut-time.cpp \
3614 common/asn1/asn1-ut-time-decode.cpp \
3615 common/crypto/digest-core.cpp \
3616 common/crypto/digest-builtin.cpp \
3617 common/crypto/key.cpp \
3618 common/crypto/rsa-asn1-decoder.cpp \
3619 common/crypto/rsa-core.cpp \
3620 common/crypto/rsa-init.cpp \
3621 common/crypto/rsa-sanity.cpp \
3622 common/crypto/pkcs7-asn1-decoder.cpp \
3623 common/crypto/pkcs7-core.cpp \
3624 common/crypto/pkcs7-init.cpp \
3625 common/crypto/pkcs7-sanity.cpp \
3626 common/crypto/pkcs7-verify.cpp \
3627 common/crypto/pkix-signature-builtin.cpp \
3628 common/crypto/pkix-signature-core.cpp \
3629 common/crypto/pkix-signature-rsa.cpp \
3630 common/crypto/pkix-util.cpp \
3631 common/crypto/pkix-verify.cpp \
3632 common/crypto/spc-asn1-decoder.cpp \
3633 common/crypto/spc-core.cpp \
3634 common/crypto/spc-init.cpp \
3635 common/crypto/spc-sanity.cpp \
3636 common/crypto/x509-asn1-decoder.cpp \
3637 common/crypto/x509-certpaths.cpp \
3638 common/crypto/x509-core.cpp \
3639 common/crypto/x509-init.cpp \
3640 common/crypto/x509-sanity.cpp \
3641 common/crypto/x509-verify.cpp \
3642 common/crypto/store.cpp \
3643 common/crypto/store-inmem.cpp \
3644 common/crypto/taf-asn1-decoder.cpp \
3645 common/crypto/taf-core.cpp \
3646 common/crypto/taf-init.cpp \
3647 common/crypto/taf-sanity.cpp \
3648 common/crypto/tsp-asn1-decoder.cpp \
3649 common/crypto/tsp-core.cpp \
3650 common/crypto/tsp-init.cpp \
3651 common/crypto/tsp-sanity.cpp \
3652 common/checksum/alt-md2.cpp \
3653 common/checksum/alt-sha1.cpp \
3654 common/checksum/alt-sha256.cpp \
3655 common/checksum/alt-sha512.cpp \
3656 common/checksum/alt-sha3.cpp \
3657 common/checksum/md2str.cpp \
3658 common/checksum/md4str.cpp \
3659 common/checksum/md5str.cpp \
3660 common/checksum/sha1str.cpp \
3661 common/checksum/sha224str.cpp \
3662 common/checksum/sha256str.cpp \
3663 common/checksum/sha384str.cpp \
3664 common/checksum/sha512str.cpp \
3665 common/checksum/sha512t224str.cpp \
3666 common/checksum/sha512t256str.cpp \
3667 common/err/errinfolog.cpp \
3668 common/path/RTPathFilenameUtf16.cpp \
3669 common/path/RTPathChangeToUnixSlashes.cpp \
3670 common/math/bignum.cpp \
3671 common/misc/zero.asm \
3672 common/string/RTStrPrintHexBytes.cpp \
3673 common/string/RTUtf16Copy.cpp \
3674 common/string/RTUtf16CopyAscii.cpp \
3675 common/string/RTUtf16CopyEx.cpp \
3676 common/string/RTUtf16Cat.cpp \
3677 common/string/RTUtf16CatAscii.cpp \
3678 common/string/RTUtf16End.cpp \
3679 common/string/RTUtf16NLen.cpp \
3680 common/string/RTUtf16NLenEx.cpp \
3681 common/string/RTUtf16PrintHexBytes.cpp \
3682 common/string/strstrip.cpp \
3683 generic/memsafer-generic.cpp \
3684 common/misc/thread.cpp \
3685 common/string/memcmp.asm \
3686 common/string/memchr.asm \
3687 common/string/memcpy.asm \
3688 common/string/memset.asm \
3689 common/string/memmove.asm \
3690 common/string/strlen.asm \
3691 common/string/strncmp.cpp \
3692 common/string/strpbrk.cpp \
3693 generic/RTAssertShouldPanic-generic.cpp \
3694 generic/RTLogWriteStdOut-stub-generic.cpp \
3695 generic/RTMpGetCoreCount-generic.cpp \
3696 generic/RTTimerCreate-generic.cpp \
3697 generic/mppresent-generic-online.cpp \
3698 generic/rtStrFormatKernelAddress-generic.cpp \
3699 nt/RTErrConvertFromNtStatus.cpp \
3700 nt/RTNtPathExpand8dot3Path.cpp \
3701 nt/RTNtPathExpand8dot3PathA.cpp \
3702 nt/RTNtPathFindPossible8dot3Name.cpp \
3703 nt/semevent-nt.cpp \
3704 nt/RTSemEventGetResolution-nt.cpp \
3705 nt/semeventmulti-nt.cpp \
3706 nt/RTSemEventMultiGetResolution-nt.cpp \
3707 r0drv/generic/threadctxhooks-r0drv-generic.cpp \
3708 r0drv/alloc-ef-r0drv.cpp \
3709 r0drv/memobj-r0drv.cpp \
3710 r0drv/mpnotification-r0drv.c \
3711 r0drv/powernotification-r0drv.c \
3712 r0drv/nt/alloc-r0drv-nt.cpp \
3713 r0drv/nt/assert-r0drv-nt.cpp \
3714 r0drv/nt/dbgkrnlinfo-r0drv-nt.cpp \
3715 r0drv/nt/initterm-r0drv-nt.cpp \
3716 r0drv/nt/memobj-r0drv-nt.cpp \
3717 r0drv/nt/memuserkernel-r0drv-nt.cpp \
3718 r0drv/nt/mp-r0drv-nt.cpp \
3719 r0drv/nt/process-r0drv-nt.cpp \
3720 r0drv/nt/RTLogWriteDebugger-r0drv-nt.cpp \
3721 r0drv/nt/semfastmutex-r0drv-nt.cpp \
3722 r0drv/nt/semmutex-r0drv-nt.cpp \
3723 r0drv/nt/spinlock-r0drv-nt.cpp \
3724 r0drv/nt/thread-r0drv-nt.cpp \
3725 r0drv/nt/thread2-r0drv-nt.cpp \
3726 r0drv/nt/time-r0drv-nt.cpp \
3727 r0drv/nt/timer-r0drv-nt.cpp \
3728 r0drv/nt/toxic-chkstk-r0drv-nt.asm \
3729 r0drv/nt/RTTimerGetSystemGranularity-r0drv-nt.cpp
3730
3731RuntimeR0Drv_SOURCES.win.amd64 := $(RuntimeWin64ASM_SOURCES)
3732RuntimeR0Drv_SOURCES.win.x86 := $(RuntimeWin32ASM_SOURCES) \
3733 r0drv/nt/nt3fakes-stub-r0drv-nt.cpp \
3734 r0drv/nt/alloca-x86-r0drv-nt.asm
3735
3736
3737RuntimeR0Drv_SOURCES.darwin = \
3738 common/ldr/ldr.cpp \
3739 common/ldr/ldrEx.cpp \
3740 common/ldr/ldrMachO.cpp \
3741 common/ldr/ldrMemory.cpp \
3742 common/asn1/asn1-basics.cpp \
3743 common/asn1/asn1-dump.cpp \
3744 common/asn1/asn1-cursor.cpp \
3745 common/asn1/asn1-default-allocator.cpp \
3746 common/asn1/asn1-safer-allocator.cpp \
3747 common/asn1/asn1-encode.cpp \
3748 common/asn1/asn1-ut-bitstring.cpp \
3749 common/asn1/asn1-ut-bitstring-decode.cpp \
3750 common/asn1/asn1-ut-boolean.cpp \
3751 common/asn1/asn1-ut-boolean-decode.cpp \
3752 common/asn1/asn1-ut-core.cpp \
3753 common/asn1/asn1-ut-core-decode.cpp \
3754 common/asn1/asn1-ut-dyntype.cpp \
3755 common/asn1/asn1-ut-dyntype-decode.cpp \
3756 common/asn1/asn1-ut-integer.cpp \
3757 common/asn1/asn1-ut-integer-decode.cpp \
3758 common/asn1/asn1-ut-null.cpp \
3759 common/asn1/asn1-ut-null-decode.cpp \
3760 common/asn1/asn1-ut-objid.cpp \
3761 common/asn1/asn1-ut-objid-decode.cpp \
3762 common/asn1/asn1-ut-octetstring.cpp \
3763 common/asn1/asn1-ut-octetstring-decode.cpp \
3764 common/asn1/asn1-ut-string.cpp \
3765 common/asn1/asn1-ut-string-decode.cpp \
3766 common/asn1/asn1-ut-time.cpp \
3767 common/asn1/asn1-ut-time-decode.cpp \
3768 common/crypto/digest-core.cpp \
3769 common/crypto/digest-builtin.cpp \
3770 common/crypto/key.cpp \
3771 common/crypto/rsa-asn1-decoder.cpp \
3772 common/crypto/rsa-core.cpp \
3773 common/crypto/rsa-init.cpp \
3774 common/crypto/rsa-sanity.cpp \
3775 common/crypto/pkcs7-asn1-decoder.cpp \
3776 common/crypto/pkcs7-core.cpp \
3777 common/crypto/pkcs7-init.cpp \
3778 common/crypto/pkcs7-sanity.cpp \
3779 common/crypto/pkcs7-verify.cpp \
3780 common/crypto/pkix-signature-builtin.cpp \
3781 common/crypto/pkix-signature-core.cpp \
3782 common/crypto/pkix-signature-rsa.cpp \
3783 common/crypto/pkix-util.cpp \
3784 common/crypto/pkix-verify.cpp \
3785 common/crypto/spc-asn1-decoder.cpp \
3786 common/crypto/spc-core.cpp \
3787 common/crypto/spc-init.cpp \
3788 common/crypto/spc-sanity.cpp \
3789 common/crypto/x509-asn1-decoder.cpp \
3790 common/crypto/x509-certpaths.cpp \
3791 common/crypto/x509-core.cpp \
3792 common/crypto/x509-init.cpp \
3793 common/crypto/x509-sanity.cpp \
3794 common/crypto/x509-verify.cpp \
3795 common/crypto/store.cpp \
3796 common/crypto/store-inmem.cpp \
3797 common/crypto/taf-asn1-decoder.cpp \
3798 common/crypto/taf-core.cpp \
3799 common/crypto/taf-init.cpp \
3800 common/crypto/taf-sanity.cpp \
3801 common/crypto/tsp-asn1-decoder.cpp \
3802 common/crypto/tsp-core.cpp \
3803 common/crypto/tsp-init.cpp \
3804 common/crypto/tsp-sanity.cpp \
3805 common/checksum/alt-md2.cpp \
3806 common/checksum/alt-sha1.cpp \
3807 common/checksum/alt-sha256.cpp \
3808 common/checksum/alt-sha512.cpp \
3809 common/checksum/alt-sha3.cpp \
3810 common/checksum/md2str.cpp \
3811 common/checksum/md4str.cpp \
3812 common/checksum/md5str.cpp \
3813 common/checksum/sha1str.cpp \
3814 common/checksum/sha224str.cpp \
3815 common/checksum/sha256str.cpp \
3816 common/checksum/sha384str.cpp \
3817 common/checksum/sha512str.cpp \
3818 common/checksum/sha512t224str.cpp \
3819 common/checksum/sha512t256str.cpp \
3820 common/err/errinfolog.cpp \
3821 common/math/bignum.cpp \
3822 common/misc/thread.cpp \
3823 common/string/base64.cpp \
3824 common/string/memchr.asm \
3825 common/string/mempcpy.asm \
3826 common/string/strpbrk.cpp \
3827 common/string/strstrip.cpp \
3828 common/string/RTStrPrintHexBytes.cpp \
3829 darwin/RTErrConvertFromDarwin.cpp \
3830 darwin/RTErrConvertFromDarwinIO.cpp \
3831 darwin/RTErrConvertFromDarwinKern.cpp \
3832 generic/RTAssertShouldPanic-generic.cpp \
3833 generic/RTFileReadAll-generic.cpp \
3834 generic/RTFileReadAllByHandle-generic.cpp \
3835 generic/RTFileReadAllByHandleEx-generic.cpp \
3836 generic/RTFileReadAllEx-generic.cpp \
3837 generic/RTFileReadAllFree-generic.cpp \
3838 generic/RTMpGetCoreCount-generic.cpp \
3839 generic/RTMpOnPair-generic.cpp \
3840 generic/RTThreadQueryTerminationStatus-stub-generic.cpp \
3841 generic/RTTimerCreate-generic.cpp \
3842 generic/memsafer-generic.cpp \
3843 generic/mppresent-generic.cpp \
3844 generic/timer-generic.cpp \
3845 r0drv/generic/mpnotification-r0drv-generic.cpp \
3846 r0drv/generic/threadctxhooks-r0drv-generic.cpp \
3847 r0drv/darwin/alloc-r0drv-darwin.cpp \
3848 r0drv/darwin/assert-r0drv-darwin.cpp \
3849 r0drv/darwin/initterm-r0drv-darwin.cpp \
3850 r0drv/darwin/dbgkrnlinfo-r0drv-darwin.cpp \
3851 r0drv/darwin/fileio-r0drv-darwin.cpp \
3852 r0drv/darwin/memobj-r0drv-darwin.cpp \
3853 r0drv/darwin/mp-r0drv-darwin.cpp \
3854 r0drv/darwin/memuserkernel-r0drv-darwin.cpp \
3855 r0drv/darwin/process-r0drv-darwin.cpp \
3856 r0drv/darwin/RTLogWriteDebugger-r0drv-darwin.cpp \
3857 r0drv/darwin/RTLogWriteStdOut-r0drv-darwin.cpp \
3858 r0drv/darwin/rtStrFormatKernelAddress-r0drv-darwin.cpp \
3859 r0drv/darwin/semevent-r0drv-darwin.cpp \
3860 r0drv/darwin/semeventmulti-r0drv-darwin.cpp \
3861 r0drv/darwin/semfastmutex-r0drv-darwin.cpp \
3862 r0drv/darwin/semmutex-r0drv-darwin.cpp \
3863 r0drv/darwin/spinlock-r0drv-darwin.cpp \
3864 r0drv/darwin/thread-r0drv-darwin.cpp \
3865 r0drv/darwin/thread2-r0drv-darwin.cpp \
3866 r0drv/darwin/threadpreempt-r0drv-darwin.cpp \
3867 r0drv/darwin/time-r0drv-darwin.cpp \
3868 r0drv/alloc-ef-r0drv.cpp \
3869 r0drv/memobj-r0drv.cpp \
3870 r0drv/powernotification-r0drv.c
3871# - The xnu memcpy implementation in osfmk/x86_64/bcopy.s returned 'void' rather than 'void *' for a long time, so use our own.
3872# - The memcmp and strlen implementations are still C implementations living in osfmk/x86_64/loose_ends.c, so use our asm code.
3873RuntimeR0Drv_SOURCES.darwin.amd64 = \
3874 common/string/memcpy.asm
3875# common/string/strlen.asm - try again later \
3876# common/string/memcmp.asm
3877
3878RuntimeR0Drv_SOURCES.os2 = \
3879 common/path/RTPathFilenameUtf16.cpp \
3880 common/string/RTUtf16Chr.cpp \
3881 common/string/RTUtf16CmpAscii.cpp \
3882 common/string/memchr.asm \
3883 common/string/memcmp.asm \
3884 common/string/memcpy.asm \
3885 common/string/mempcpy.asm \
3886 common/string/memmove.asm \
3887 common/string/memset.asm \
3888 common/string/strchr.asm \
3889 common/string/strcmp.asm \
3890 common/string/strcpy.asm \
3891 common/string/strlen.asm \
3892 common/string/strncmp.cpp \
3893 common/string/strpbrk.cpp \
3894 common/misc/thread.cpp \
3895 generic/RTAssertShouldPanic-generic.cpp \
3896 generic/RTLogWriteDebugger-generic.cpp \
3897 generic/RTLogWriteStdOut-stub-generic.cpp \
3898 generic/RTMpCpuId-generic.cpp \
3899 generic/RTMpCpuIdFromSetIndex-generic.cpp \
3900 generic/RTMpCpuIdToSetIndex-generic.cpp \
3901 generic/RTMpIsCpuPossible-generic.cpp \
3902 generic/RTMpGetCount-generic.cpp \
3903 generic/RTMpGetMaxCpuId-generic.cpp \
3904 generic/RTMpGetOnlineCount-generic.cpp \
3905 generic/RTMpGetOnlineSet-generic.cpp \
3906 generic/RTMpGetSet-generic.cpp \
3907 generic/RTMpIsCpuOnline-generic.cpp \
3908 generic/RTThreadQueryTerminationStatus-stub-generic.cpp \
3909 generic/RTTimerCreate-generic.cpp \
3910 generic/mppresent-generic.cpp \
3911 generic/rtStrFormatKernelAddress-generic.cpp \
3912 os2/RTErrConvertFromOS2.cpp \
3913 os2/rtSemWaitOs2ConvertTimeout.cpp \
3914 os2/sys0.asm \
3915 r0drv/generic/RTMpIsCpuWorkPending-r0drv-generic.cpp \
3916 r0drv/generic/RTMpOn-r0drv-generic.cpp \
3917 r0drv/generic/mpnotification-r0drv-generic.cpp \
3918 r0drv/generic/threadctxhooks-r0drv-generic.cpp \
3919 r0drv/memobj-r0drv.cpp \
3920 r0drv/powernotification-r0drv.c \
3921 r0drv/os2/alloc-r0drv-os2.cpp \
3922 r0drv/os2/assert-r0drv-os2.cpp \
3923 r0drv/os2/assertA-r0drv-os2.asm \
3924 r0drv/os2/initterm-r0drv-os2.cpp \
3925 r0drv/os2/memobj-r0drv-os2.cpp \
3926 r0drv/os2/memuserkernel-r0drv-os2.cpp \
3927 r0drv/os2/os2imports.imp \
3928 r0drv/os2/process-r0drv-os2.cpp \
3929 r0drv/os2/RTR0AssertPanicSystem-r0drv-os2.asm \
3930 r0drv/os2/RTR0Os2DHQueryDOSVar.asm \
3931 r0drv/os2/RTR0Os2DHVMGlobalToProcess.asm \
3932 r0drv/os2/semevent-r0drv-os2.cpp \
3933 r0drv/os2/semeventmulti-r0drv-os2.cpp \
3934 r0drv/os2/semfastmutex-r0drv-os2.cpp \
3935 r0drv/os2/spinlock-r0drv-os2.cpp \
3936 r0drv/os2/thread-r0drv-os2.cpp \
3937 r0drv/os2/thread2-r0drv-os2.cpp \
3938 r0drv/os2/time-r0drv-os2.cpp \
3939 r0drv/os2/timer-r0drv-os2.cpp \
3940 r0drv/os2/timerA-r0drv-os2.asm
3941ifndef VBOX_USE_WATCOM_FOR_OS2
3942 RuntimeR0Drv_SOURCES.os2 += \
3943 common/math/gcc/adddi3.c \
3944 common/math/gcc/anddi3.c \
3945 common/math/gcc/ashldi3.c \
3946 common/math/gcc/ashrdi3.c \
3947 common/math/gcc/cmpdi2.c \
3948 common/math/gcc/divdi3.c \
3949 common/math/gcc/divmoddi4.c \
3950 common/math/gcc/iordi3.c \
3951 common/math/gcc/lshldi3.c \
3952 common/math/gcc/lshrdi3.c \
3953 common/math/gcc/moddi3.c \
3954 common/math/gcc/muldi3.c \
3955 common/math/gcc/negdi2.c \
3956 common/math/gcc/notdi2.c \
3957 common/math/gcc/qdivrem.c \
3958 common/math/gcc/subdi3.c \
3959 common/math/gcc/ucmpdi2.c \
3960 common/math/gcc/udivdi3.c \
3961 common/math/gcc/udivmoddi4.c \
3962 common/math/gcc/umoddi3.c \
3963 common/math/gcc/xordi3.c
3964else
3965 RuntimeR0Drv_SOURCES.os2 += \
3966 common/math/watcom/I8D-x86-32.asm \
3967 common/math/watcom/U8D-x86-32.asm \
3968 common/math/watcom/RTWatcomUInt64Div.c \
3969 common/math/watcom/U8LS-x86-32.asm \
3970 common/math/watcom/U8RS-x86-32.asm \
3971 common/math/watcom/U8M-I8M-x86-32.asm \
3972 common/string/watcom/bzero.asm \
3973 common/string/watcom/memchr.asm \
3974 common/string/watcom/memcmp.asm \
3975 common/string/watcom/memcpy.asm \
3976 common/string/watcom/memmove.asm \
3977 common/string/watcom/mempcpy.asm \
3978 common/string/watcom/memrchr.asm \
3979 common/string/watcom/memset.asm \
3980 common/string/watcom/strchr.asm \
3981 common/string/watcom/strcmp.asm \
3982 common/string/watcom/strcpy.asm \
3983 common/string/watcom/strlen.asm \
3984 common/string/watcom/strncmp.asm \
3985 common/string/watcom/strncpy.asm
3986endif
3987
3988RuntimeR0Drv_SOURCES.freebsd = \
3989 common/misc/thread.cpp \
3990 common/string/memchr.asm \
3991 common/string/memmove.asm \
3992 common/string/strpbrk.cpp \
3993 common/string/memcmp.asm \
3994 common/string/strchr.asm \
3995 generic/RTAssertShouldPanic-generic.cpp \
3996 generic/RTLogWriteDebugger-generic.cpp \
3997 generic/RTLogWriteStdOut-stub-generic.cpp \
3998 generic/RTMpOnPair-generic.cpp \
3999 generic/RTTimerCreate-generic.cpp \
4000 generic/mppresent-generic.cpp \
4001 generic/rtStrFormatKernelAddress-generic.cpp \
4002 r0drv/generic/RTMpIsCpuWorkPending-r0drv-generic.cpp \
4003 r0drv/generic/mpnotification-r0drv-generic.cpp \
4004 r0drv/generic/threadctxhooks-r0drv-generic.cpp \
4005 r0drv/freebsd/alloc-r0drv-freebsd.c \
4006 r0drv/freebsd/assert-r0drv-freebsd.c \
4007 r0drv/freebsd/initterm-r0drv-freebsd.c \
4008 r0drv/freebsd/memobj-r0drv-freebsd.c \
4009 r0drv/freebsd/memuserkernel-r0drv-freebsd.c \
4010 r0drv/freebsd/process-r0drv-freebsd.c \
4011 r0drv/freebsd/semevent-r0drv-freebsd.c \
4012 r0drv/freebsd/semeventmulti-r0drv-freebsd.c \
4013 r0drv/freebsd/semfastmutex-r0drv-freebsd.c \
4014 r0drv/freebsd/semmutex-r0drv-freebsd.c \
4015 r0drv/freebsd/spinlock-r0drv-freebsd.c \
4016 r0drv/freebsd/thread-r0drv-freebsd.c \
4017 r0drv/freebsd/thread2-r0drv-freebsd.c \
4018 r0drv/freebsd/time-r0drv-freebsd.c \
4019 r0drv/freebsd/mp-r0drv-freebsd.c \
4020 generic/timer-generic.cpp \
4021 r0drv/alloc-ef-r0drv.cpp \
4022 r0drv/memobj-r0drv.cpp \
4023 r0drv/powernotification-r0drv.c
4024
4025RuntimeR0Drv_SOURCES.netbsd = \
4026 common/misc/thread.cpp \
4027 common/string/strpbrk.cpp \
4028 generic/RTAssertShouldPanic-generic.cpp \
4029 generic/RTLogWriteDebugger-generic.cpp \
4030 generic/RTThreadQueryTerminationStatus-stub-generic.cpp \
4031 generic/RTTimerCreate-generic.cpp \
4032 generic/mppresent-generic.cpp \
4033 generic/rtStrFormatKernelAddress-generic.cpp \
4034 r0drv/generic/RTMpIsCpuWorkPending-r0drv-generic.cpp \
4035 r0drv/generic/mpnotification-r0drv-generic.cpp \
4036 r0drv/generic/threadctxhooks-r0drv-generic.cpp \
4037 r0drv/netbsd/RTLogWriteStdOut-r0drv-netbsd.c \
4038 r0drv/netbsd/alloc-r0drv-netbsd.c \
4039 r0drv/netbsd/assert-r0drv-netbsd.c \
4040 r0drv/netbsd/initterm-r0drv-netbsd.c \
4041 r0drv/netbsd/memobj-r0drv-netbsd.c \
4042 r0drv/netbsd/memuserkernel-r0drv-netbsd.c \
4043 r0drv/netbsd/process-r0drv-netbsd.c \
4044 r0drv/netbsd/semevent-r0drv-netbsd.c \
4045 r0drv/netbsd/semeventmulti-r0drv-netbsd.c \
4046 r0drv/netbsd/semfastmutex-r0drv-netbsd.c \
4047 r0drv/netbsd/spinlock-r0drv-netbsd.c \
4048 r0drv/netbsd/thread-r0drv-netbsd.c \
4049 r0drv/netbsd/thread2-r0drv-netbsd.c \
4050 r0drv/netbsd/time-r0drv-netbsd.c \
4051 r0drv/netbsd/mp-r0drv-netbsd.c \
4052 generic/timer-generic.cpp \
4053 r0drv/memobj-r0drv.cpp \
4054 r0drv/powernotification-r0drv.c
4055
4056RuntimeR0Drv_SOURCES.solaris = \
4057 common/misc/thread.cpp \
4058 common/string/memchr.asm \
4059 generic/RTAssertShouldPanic-generic.cpp \
4060 generic/RTLogWriteStdOut-stub-generic.cpp \
4061 generic/RTMpGetCoreCount-generic.cpp \
4062 generic/RTThreadQueryTerminationStatus-stub-generic.cpp \
4063 generic/RTTimerCreate-generic.cpp \
4064 generic/mppresent-generic.cpp \
4065 generic/rtStrFormatKernelAddress-generic.cpp \
4066 r0drv/memobj-r0drv.cpp \
4067 r0drv/mpnotification-r0drv.c \
4068 r0drv/powernotification-r0drv.c \
4069 r0drv/solaris/RTLogWriteDebugger-r0drv-solaris.c \
4070 r0drv/solaris/RTMpPokeCpu-r0drv-solaris.c \
4071 r0drv/solaris/alloc-r0drv-solaris.c \
4072 r0drv/solaris/assert-r0drv-solaris.c \
4073 r0drv/solaris/dbgkrnlinfo-r0drv-solaris.c \
4074 r0drv/solaris/initterm-r0drv-solaris.c \
4075 r0drv/solaris/memuserkernel-r0drv-solaris.c \
4076 r0drv/solaris/mpnotification-r0drv-solaris.c \
4077 r0drv/solaris/memobj-r0drv-solaris.c \
4078 r0drv/solaris/mp-r0drv-solaris.c \
4079 r0drv/solaris/process-r0drv-solaris.c \
4080 r0drv/solaris/semevent-r0drv-solaris.c \
4081 r0drv/solaris/semeventmulti-r0drv-solaris.c \
4082 r0drv/solaris/semfastmutex-r0drv-solaris.c \
4083 r0drv/solaris/semmutex-r0drv-solaris.c \
4084 r0drv/solaris/spinlock-r0drv-solaris.c \
4085 r0drv/solaris/thread-r0drv-solaris.c \
4086 r0drv/solaris/thread2-r0drv-solaris.c \
4087 r0drv/solaris/threadctxhooks-r0drv-solaris.c \
4088 r0drv/solaris/time-r0drv-solaris.c \
4089 r0drv/solaris/timer-r0drv-solaris.c
4090
4091RuntimeR0Drv_SOURCES.haiku = \
4092 common/misc/thread.cpp \
4093 common/string/memchr.asm \
4094 common/string/memmove.asm \
4095 common/string/strpbrk.cpp \
4096 common/string/memcmp.asm \
4097 common/string/strchr.asm \
4098 generic/RTAssertShouldPanic-generic.cpp \
4099 generic/RTMpOnPair-generic.cpp \
4100 generic/RTThreadQueryTerminationStatus-stub-generic.cpp \
4101 generic/RTTimerCreate-generic.cpp \
4102 generic/mppresent-generic.cpp \
4103 generic/rtStrFormatKernelAddress-generic.cpp \
4104 r0drv/generic/RTMpIsCpuWorkPending-r0drv-generic.cpp \
4105 r0drv/generic/mpnotification-r0drv-generic.cpp \
4106 r0drv/generic/threadctxhooks-r0drv-generic.cpp \
4107 r0drv/haiku/alloc-r0drv-haiku.c \
4108 r0drv/haiku/assert-r0drv-haiku.c \
4109 r0drv/haiku/initterm-r0drv-haiku.c \
4110 r0drv/haiku/memobj-r0drv-haiku.c \
4111 r0drv/haiku/mp-r0drv-haiku.c \
4112 r0drv/haiku/process-r0drv-haiku.c \
4113 r0drv/haiku/RTLogWriteDebugger-r0drv-haiku.c \
4114 r0drv/haiku/RTLogWriteStdOut-r0drv-haiku.c \
4115 r0drv/haiku/semevent-r0drv-haiku.c \
4116 r0drv/haiku/semeventmulti-r0drv-haiku.c \
4117 r0drv/haiku/semfastmutex-r0drv-haiku.c \
4118 r0drv/haiku/semmutex-r0drv-haiku.c \
4119 r0drv/haiku/spinlock-r0drv-haiku.c \
4120 r0drv/haiku/thread-r0drv-haiku.c \
4121 r0drv/haiku/thread2-r0drv-haiku.c \
4122 r0drv/haiku/time-r0drv-haiku.c \
4123 generic/timer-generic.cpp \
4124 r0drv/memobj-r0drv.cpp \
4125 r0drv/powernotification-r0drv.c
4126
4127## PORTME: Porters create and add their selection of platform specific Ring-0 Driver files here.
4128
4129RuntimeR0Drv_ORDERDEPS.freebsd = \
4130 $(PATH_STAGE)/gen-sys-hdrs/bus_if.h \
4131 $(PATH_STAGE)/gen-sys-hdrs/device_if.h
4132
4133
4134#
4135# RuntimeGuestR0 - Guest driver runtime.
4136# This is almost the same as the RuntimeR0Drv, the main difference
4137# is in the backdoor logging and the lack of sup.h (which should be
4138# made irrelevant even for RuntimeR0Drv).
4139#
4140RuntimeGuestR0_TEMPLATE := VBOXGUESTR0LIB
4141RuntimeGuestR0_EXTENDS = RuntimeR0Drv
4142RuntimeGuestR0_DEFS.win.x86 = $(RuntimeR0Drv_DEFS.win.x86) IPRT_TARGET_NT4 # The 32-bit version needs to work on NT4 too.
4143RuntimeGuestR0_SOURCES := $(filter-out generic/RTLogWriteUser-generic.cpp, $(RuntimeR0Drv_SOURCES))
4144RuntimeGuestR0_SOURCES += \
4145 VBox/logbackdoor.cpp
4146RuntimeGuestR0_SOURCES.win := \
4147 $(filter-out common/checksum/md% common/checksum/sha%, $(RuntimeR0Drv_SOURCES.win))
4148
4149
4150ifdef VBOX_WITH_RAW_MODE
4151 #
4152 # RuntimeRC - Raw-mode context library.
4153 #
4154 RuntimeRC_TEMPLATE = VBoxRc
4155 RuntimeRC_DEFS = IN_RT_RC RT_WITH_VBOX IN_SUP_RC IN_VMM_RC NOFILEID
4156 RuntimeRC_INCS = include
4157 RuntimeRC_SOURCES := \
4158 common/asm/ASMMemFirstMismatchingU8.asm \
4159 common/asm/ASMGetXcr0.asm \
4160 common/asm/ASMSetXcr0.asm \
4161 common/asm/ASMXSave.asm \
4162 common/asm/ASMXRstor.asm \
4163 common/asm/ASMFxSave.asm \
4164 common/asm/ASMFxRstor.asm \
4165 common/checksum/alt-md5.cpp \
4166 common/checksum/crc32.cpp \
4167 common/checksum/crc64.cpp \
4168 common/log/log.cpp \
4169 common/log/logellipsis.cpp \
4170 common/log/logrel.cpp \
4171 common/log/logrelellipsis.cpp \
4172 common/log/logcom.cpp \
4173 common/log/logformat.cpp \
4174 common/log/tracebuf.cpp \
4175 common/log/tracedefault.cpp \
4176 common/log/RTLogCreateEx.cpp \
4177 common/misc/RTAssertMsg1Weak.cpp \
4178 common/misc/RTAssertMsg2.cpp \
4179 common/misc/RTAssertMsg2Add.cpp \
4180 common/misc/RTAssertMsg2AddWeak.cpp \
4181 common/misc/RTAssertMsg2AddWeakV.cpp \
4182 common/misc/RTAssertMsg2Weak.cpp \
4183 common/misc/RTAssertMsg2WeakV.cpp \
4184 common/misc/assert.cpp \
4185 common/misc/buildconfig.cpp \
4186 common/misc/sanity-c.c \
4187 common/misc/sanity-cpp.cpp \
4188 common/path/RTPathFilename.cpp \
4189 common/string/strformat.cpp \
4190 common/string/RTStrFormat.cpp \
4191 common/string/strformatnum.cpp \
4192 common/string/strformatrt.cpp \
4193 common/string/strformattype.cpp \
4194 common/string/strncmp.cpp \
4195 common/string/strpbrk.cpp \
4196 common/string/strprintf.cpp \
4197 common/string/strprintf-ellipsis.cpp \
4198 common/string/strprintf2.cpp \
4199 common/string/strprintf2-ellipsis.cpp \
4200 common/string/RTStrCmp.cpp \
4201 common/string/RTStrCopy.cpp \
4202 common/string/RTStrCopyEx.cpp \
4203 common/string/RTStrEnd.asm \
4204 common/string/RTStrICmpAscii.cpp \
4205 common/table/avllu32.cpp \
4206 common/table/avlou32.cpp \
4207 common/table/avlogcphys.cpp \
4208 common/table/avlogcptr.cpp \
4209 common/table/avlohcphys.cpp \
4210 common/table/avloioport.cpp \
4211 common/table/avlrogcphys.cpp \
4212 common/table/avlrogcptr.cpp \
4213 common/table/avlroioport.cpp \
4214 common/table/avlroogcptr.cpp \
4215 common/table/avlu32.cpp \
4216 common/time/timeprog.cpp \
4217 common/time/timesup.cpp \
4218 gc/initterm-gc.cpp \
4219 generic/RTAssertShouldPanic-generic.cpp \
4220 generic/rtStrFormatKernelAddress-generic.cpp \
4221 generic/errvars-generic.cpp \
4222 \
4223 $(RuntimeNoCrt_SOURCES)
4224
4225 #if1of ($(KBUILD_TARGET_ARCH),amd64 x86)
4226 # RuntimeRC_SOURCES += common/time/timesupA.asm
4227 #else
4228 RuntimeRC_SOURCES += common/time/timesupref.cpp
4229 #endif
4230
4231 RuntimeRC_SOURCES.win.x86 = $(RuntimeWin32ASM_SOURCES)
4232
4233 ifeq ($(VBOX_LDR_FMT32),lx)
4234 RuntimeRC_SOURCES += os2/sys0.asm
4235 endif
4236
4237 if1of ($(KBUILD_TARGET), darwin solaris freebsd os2)
4238 RuntimeRC_SOURCES += \
4239 common/math/gcc/adddi3.c \
4240 common/math/gcc/anddi3.c \
4241 common/math/gcc/ashldi3.c \
4242 common/math/gcc/ashrdi3.c \
4243 common/math/gcc/cmpdi2.c \
4244 common/math/gcc/divdi3.c \
4245 common/math/gcc/divmoddi4.c \
4246 common/math/gcc/iordi3.c \
4247 common/math/gcc/lshldi3.c \
4248 common/math/gcc/lshrdi3.c \
4249 common/math/gcc/moddi3.c \
4250 common/math/gcc/muldi3.c \
4251 common/math/gcc/negdi2.c \
4252 common/math/gcc/notdi2.c \
4253 common/math/gcc/qdivrem.c \
4254 common/math/gcc/subdi3.c \
4255 common/math/gcc/ucmpdi2.c \
4256 common/math/gcc/udivdi3.c \
4257 common/math/gcc/udivmoddi4.c \
4258 common/math/gcc/umoddi3.c \
4259 common/math/gcc/xordi3.c
4260 endif
4261
4262
4263 #
4264 # RuntimeRCStub - Raw-mode context startup stub for Windows.
4265 #
4266 RuntimeRCStub_TEMPLATE = VBoxRc
4267 RuntimeRCStub_SOURCES.win = \
4268 nt/NtProcessStartup-stub.cpp
4269
4270
4271endif # VBOX_WITH_RAW_MODE
4272
4273
4274#
4275# Static library for new & delete for the electric fence.
4276#
4277RuntimeEFCPP_TEMPLATE := $(VBoxRT_TEMPLATE)
4278RuntimeEFCPP_SDKS := $(RuntimeR3_SDKS)
4279RuntimeEFCPP_SDKS.$(KBUILD_TARGET) := $(RuntimeR3_SDKS.$(KBUILD_TARGET))
4280RuntimeEFCPP_DEFS := $(RuntimeR3_DEFS)
4281RuntimeEFCPP_DEFS.$(KBUILD_TARGET) := $(RuntimeR3_DEFS.$(KBUILD_TARGET))
4282RuntimeEFCPP_INCS := $(RuntimeR3_INCS)
4283RuntimeEFCPP_INCS.$(KBUILD_TARGET) := $(RuntimeR3_INCS.$(KBUILD_TARGET))
4284RuntimeEFCPP_SOURCES := r3/alloc-ef-cpp.cpp
4285
4286
4287
4288#
4289# The NTDLL mini import library.
4290#
4291# Note! The reason for doing this is to avoid importing CRT symbols from the
4292# NTDLL. We do not wish to do this because:
4293# - Our compiler is usually a different one and we should use the
4294# matching CRT,
4295# - Older versions of NTDLL may not sport all the exports our w2k3 or
4296# later WINDDK ntdll.lib have and thus we may easily end up with
4297# images that does not load on older windows versions.
4298#
4299if1of (win,$(KBUILD_TARGET) $(KBUILD_HOST))
4300RuntimeR3NtDll-amd64_TEMPLATE = VBoxR3Dll
4301RuntimeR3NtDll-amd64_BLD_TRG_ARCH = amd64
4302RuntimeR3NtDll-amd64_ARFLAGS = /NODEFAULTLIB /MACHINE:amd64
4303RuntimeR3NtDll-amd64_SOURCES = \
4304 r3/win/ntdll-mini-implib.def
4305
4306RuntimeR3NtDll-x86_TEMPLATE = VBoxR3Dll
4307RuntimeR3NtDll-x86_BLD_TRG_ARCH = x86
4308RuntimeR3NtDll-x86_ARFLAGS = /NODEFAULTLIB /MACHINE:x86
4309RuntimeR3NtDll-x86_SOURCES = \
4310 r3/win/ntdll-mini-implib.def \
4311 $(RuntimeR3NtDll-x86_0_OUTDIR)/ntdll-mini-implib.asm
4312RuntimeR3NtDll-x86_CLEAN = \
4313 $(RuntimeR3NtDll-x86_0_OUTDIR)/ntdll-mini-implib.asm
4314
4315$$(RuntimeR3NtDll-x86_0_OUTDIR)/ntdll-mini-implib.asm: $(PATH_SUB_CURRENT)/r3/win/ntdll-mini-implib.def | $$(dir $$@)
4316 $(call MSG_GENERATE,,$@,$<)
4317 $(QUIET)$(APPEND) -nt "$@" \
4318 ';Autogenerated, do not edit' \
4319 '%include "iprt/asmdefs.mac"' \
4320 'BEGINCODE' \
4321 '%macro IMPLIB_EXPORT 1' \
4322 'global %1:function' \
4323 '%1: nop' \
4324 '%endm' \
4325 ''
4326 $(QUIET)$(SED) -e '1,/EXPORTS/d' \
4327 -e 's/^.*;;=[[:space:]]*\([^[:space:]]*\)[[:space:]]*$$/IMPLIB_EXPORT \1/' \
4328 $< --append $@
4329endif
4330
4331#
4332# Bag of tricks required for making VCC100 output binaries work on NT4, W2K
4333# early XP and early W2K3. Used by validation kit.
4334#
4335RuntimeR3VccTricks_TEMPLATE = VBoxR3Static
4336RuntimeR3VccTricks_DEFS = VCC_FAKES_TARGET_$(VBOX_VCC_TOOL_STEM) VCC_FAKES_TARGET=$(substr $(VBOX_VCC_TOOL_STEM),-3)
4337RuntimeR3VccTricks_SOURCES = \
4338 r3/win/vcc-fakes-kernel32.cpp \
4339 r3/win/vcc-fakes-kernel32-A.asm \
4340 r3/win/vcc-fakes-shell32.cpp \
4341 r3/win/vcc-fakes-shell32-A.asm \
4342 r3/win/vcc-fakes-ntdll.cpp \
4343 r3/win/vcc-fakes-ntdll-A.asm
4344
4345if defined(VBOX_WITH_MORE_NT4_COMPAT_BINARIES) && "$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH)" == "win.x86" # Ugly hacks... :-)
4346LIBRARIES += RuntimeR3VccTricks2
4347RuntimeR3VccTricks2_TEMPLATE = VBoxR3Dll
4348RuntimeR3VccTricks2_DEFS += $(RuntimeR3VccTricks_DEFS)
4349RuntimeR3VccTricks2_SOURCES = $(RuntimeR3VccTricks_SOURCES)
4350RuntimeR3VccTricks2_SOURCES += $(RuntimeR3VccTricks2_0_OUTDIR)/dynobjs.lib
4351RuntimeR3VccTricks2_CLEAN = $(RuntimeR3VccTricks2_0_OUTDIR)/dynobjs.lib
4352RuntimeR3VccTricks2_VBOX_LIBCMT_NEEDED =
4353
4354$$(RuntimeR3VccTricks2_0_OUTDIR)/dynobjs.lib: \
4355 $$(PATH_TOOL_$$(TEMPLATE_VBoxR3Dll_TOOL.win.x86)_LIB)/msvcrt$(VBOX_VCC_CRT_TYPE).lib \
4356 $$(PATH_TOOL_$$(TEMPLATE_VBoxR3Dll_TOOL.win.x86)_LIB)/libcmt$(VBOX_VCC_CRT_TYPE).lib \
4357 $$(LIB_RUNTIME) \
4358 $(MAKEFILE) | $$(dir $$@)
4359 $(RM) -f -- "$@"
4360# $(REDIRECT) -C $(dir $@) -- $(KBUILD_DEVTOOLS)/common/openwatcom/v1.9-r2/binnt/wlib \
4361# $(PATH_TOOL_$(TEMPLATE_VBoxR3Dll_TOOL.win.x86)_LIB)/libcmt$(VBOX_VCC_CRT_TYPE).lib \
4362# $(foreach file, $(RuntimeR3VccTricks2_VBOX_LIBCMT_NEEDED), *$(file))
4363 $(KBUILD_DEVTOOLS)/common/openwatcom/v1.9-r2/binnt/wlib -o=$@.tmp.lib $< \
4364 -MSVCR100.dll \
4365 $(addprefix $(RuntimeR3VccTricks2_0_OUTDIR)/, $(RuntimeR3VccTricks2_VBOX_LIBCMT_NEEDED)) \
4366 -chandler4gs.obj
4367 $(KBUILD_DEVTOOLS)/common/openwatcom/v1.9-r2/binnt/wlib -o=$@ \
4368 $(LIB_RUNTIME) \
4369 +$@.tmp.lib
4370 $(RM) -f -- $@.tmp.lib $(addprefix $(RuntimeR3VccTricks2_0_OUTDIR)/, $(RuntimeR3VccTricks_VBOX_LIBCMT_NEEDED))
4371endif
4372
4373
4374#
4375# errmsg.cpp depends on a generated header.
4376#
4377common/err/errmsg.cpp_DEPS = \
4378 $(IPRT_OUT_DIR)/errmsgdata-all.h \
4379 $(IPRT_OUT_DIR)/errmsgdata-no-full-msg.h \
4380 $(IPRT_OUT_DIR)/errmsgdata-only-defines.h
4381common/err/errmsg.cpp_INCS = $(IPRT_OUT_DIR)
4382
4383win/errmsgwin.cpp_DEPS = $(IPRT_OUT_DIR)/errmsgwindata-only-defines.h
4384win/errmsgwin.cpp_INCS = $(IPRT_OUT_DIR)
4385
4386# Our COM errors only for R3 libraries on the host
4387define def_errmsgwin_deps
4388 $(lib)_common/err/errmsgxpcom.cpp_INCS = $(IPRT_OUT_DIR)
4389 $(lib)_common/err/errmsgxpcom.cpp_DEPS = $(IPRT_OUT_DIR)/errmsgvboxcomdata.h
4390endef
4391$(foreach lib,RuntimeR3 RuntimeBldProg VBoxRT VBoxRT-x86,$(eval $(def_errmsgwin_deps)))
4392
4393
4394#
4395# Generate the status code data.
4396#
4397$(IPRT_OUT_DIR)/errmsgdata.h: \
4398 $(VBOX_PATH_RUNTIME_SRC)/common/err/errmsg.sed \
4399 $(PATH_ROOT)/include/iprt/err.h \
4400 $(PATH_ROOT)/include/VBox/err.h \
4401 | $$(dir $$@)
4402 $(call MSG_GENERATE,,$@,$(filter %.h,$^))
4403 $(QUIET)$(SED) -f $< --output "$@" $(filter %.h,$^)
4404
4405$(IPRT_OUT_DIR)/errmsgdata-all.h.ts +| $(IPRT_OUT_DIR)/errmsgdata-all.h: \
4406 $$(bldRTErrMsgSorter_1_TARGET)
4407 $(call MSG_GENERATE,,$@,$<)
4408 $(QUIET)"$<" --all "$(IPRT_OUT_DIR)/errmsgdata-all.h.ts"
4409 $(QUIET)$(CP) --changed -fv -- "$(IPRT_OUT_DIR)/errmsgdata-all.h.ts" "$(IPRT_OUT_DIR)/errmsgdata-all.h"
4410
4411$(IPRT_OUT_DIR)/errmsgdata-no-full-msg.h.ts +| $(IPRT_OUT_DIR)/errmsgdata-no-full-msg.h: \
4412 $$(bldRTErrMsgSorter_1_TARGET)
4413 $(call MSG_GENERATE,,$@,$<)
4414 $(QUIET)"$<" --no-full-msg "$(IPRT_OUT_DIR)/errmsgdata-no-full-msg.h.ts"
4415 $(QUIET)$(CP) --changed -fv -- "$(IPRT_OUT_DIR)/errmsgdata-no-full-msg.h.ts" "$(IPRT_OUT_DIR)/errmsgdata-no-full-msg.h"
4416
4417$(IPRT_OUT_DIR)/errmsgdata-only-defines.h.ts +| $(IPRT_OUT_DIR)/errmsgdata-only-defines.h: \
4418 $$(bldRTErrMsgSorter_1_TARGET)
4419 $(call MSG_GENERATE,,$@,$<)
4420 $(QUIET)"$<" --only-defines "$(IPRT_OUT_DIR)/errmsgdata-only-defines.h.ts"
4421 $(QUIET)$(CP) --changed -fv -- "$(IPRT_OUT_DIR)/errmsgdata-only-defines.h.ts" "$(IPRT_OUT_DIR)/errmsgdata-only-defines.h"
4422
4423
4424$(IPRT_OUT_DIR)/errmsgwindata.h: \
4425 $(VBOX_PATH_RUNTIME_SRC)/common/err/errmsgcom.sed \
4426 $$(qwildcard ,$$(qaddsuffix ,/WinError.h,$$(SDK_$$(VBOX_WINPSDK)_INCS))) \
4427 | $$(dir $$@)
4428 $(call MSG_GENERATE,,$@,$(deps $@, 2))
4429 $(QUIET)$(SED) -f "$<" --output "$@" $(qdeps sh,$@,2)
4430
4431$(IPRT_OUT_DIR)/errmsgvboxcomdata.h.ts +| $(IPRT_OUT_DIR)/errmsgvboxcomdata.h: \
4432 $(VBOX_PATH_RUNTIME_SRC)/VBox/errmsgvboxcom.xsl \
4433 $(VBOX_XIDL_FILE_SRC) \
4434 | $$(dir $$@)
4435 $(call MSG_GENERATE,,$@,$(filter %.xidl,$^))
4436 $(QUIET)$(VBOX_XSLTPROC) -o $(IPRT_OUT_DIR)/errmsgvboxcomdata.h.ts $< $(filter %.xidl,$^)
4437 $(QUIET)$(CP) --changed -fv -- $(IPRT_OUT_DIR)/errmsgvboxcomdata.h.ts $(IPRT_OUT_DIR)/errmsgvboxcomdata.h
4438
4439$(IPRT_OUT_DIR)/errmsgwindata-only-defines.h.ts +| $(IPRT_OUT_DIR)/errmsgwindata-only-defines.h: \
4440 $$(bldRTErrMsgWinSorter_1_TARGET)
4441 $(call MSG_GENERATE,,$@,$<)
4442 $(QUIET)"$<" --only-defines "$(IPRT_OUT_DIR)/errmsgwindata-only-defines.h.ts"
4443 $(QUIET)$(CP) --changed -fv -- "$(IPRT_OUT_DIR)/errmsgwindata-only-defines.h.ts" "$(IPRT_OUT_DIR)/errmsgwindata-only-defines.h"
4444
4445
4446#
4447# Sorter for the IPRT status codes.
4448#
4449BLDPROGS += bldRTErrMsgSorter
4450bldRTErrMsgSorter_TEMPLATE = VBoxBldProg
4451bldRTErrMsgSorter_INCS = $(IPRT_OUT_DIR)
4452bldRTErrMsgSorter_DEPS = $(IPRT_OUT_DIR)/errmsgdata.h
4453bldRTErrMsgSorter_SOURCES = common/err/errmsg-sorter.cpp
4454
4455#
4456# Sorter for the windows error codes.
4457#
4458BLDPROGS.win += bldRTErrMsgWinSorter
4459bldRTErrMsgWinSorter_TEMPLATE = VBoxBldProg
4460bldRTErrMsgWinSorter_INCS = $(IPRT_OUT_DIR)
4461bldRTErrMsgWinSorter_DEPS = \
4462 $(IPRT_OUT_DIR)/errmsgwindata.h \
4463 $(IPRT_OUT_DIR)/errmsgvboxcomdata.h
4464bldRTErrMsgWinSorter_SOURCES = win/errmsgwin-sorter.cpp
4465
4466
4467
4468if "$(KBUILD_TARGET)" == "freebsd"
4469#
4470# FreeBSDGeneratedKernelHeaders - Generate some kernel interface headers.
4471#
4472# These are used by:
4473# - The RTMp* API in IPRT.
4474# - VBoxGuest
4475#
4476# Note! We cannot give a output path to the awk program, it will always
4477# generate the header next to the source. So, we'll have to temporarily copy
4478# the source file to the destination directory to work.
4479#
4480VBOX_AWK := /usr/bin/awk
4481INSTALLS += FreeBSDGeneratedKernelHeaders
4482FreeBSDGeneratedKernelHeaders_INST = gen-sys-hdrs/
4483FreeBSDGeneratedKernelHeaders_SOURCES = \
4484 $(FreeBSDGeneratedKernelHeaders_0_OUTDIR)/bus_if.h \
4485 $(FreeBSDGeneratedKernelHeaders_0_OUTDIR)/device_if.h \
4486 $(FreeBSDGeneratedKernelHeaders_0_OUTDIR)/pci_if.h
4487FreeBSDGeneratedKernelHeaders_CLEAN = $(FreeBSDGeneratedKernelHeaders_SOURCES)
4488
4489$$(FreeBSDGeneratedKernelHeaders_0_OUTDIR)/bus_if.h: $(VBOX_FREEBSD_SRC)/kern/bus_if.m | $$(dir $$@)
4490 $(call MSG_TOOL,awk,FreeBSDGeneratedKernelHeaders,$<,$@)
4491 $(QUIET)$(CP) -f $< $(@D)/bus_if.m
4492 $(QUIET)$(VBOX_AWK) -f $(VBOX_FREEBSD_SRC)/tools/makeobjops.awk $(@D)/bus_if.m -h -p
4493 $(QUIET)$(RM) $(@D)/bus_if.m
4494
4495$$(FreeBSDGeneratedKernelHeaders_0_OUTDIR)/device_if.h: $(VBOX_FREEBSD_SRC)/kern/device_if.m | $$(dir $$@)
4496 $(call MSG_TOOL,awk,FreeBSDGeneratedKernelHeaders,$<,$@)
4497 $(QUIET)$(CP) -f $< $(@D)/device_if.m
4498 $(QUIET)$(VBOX_AWK) -f $(VBOX_FREEBSD_SRC)/tools/makeobjops.awk $(@D)/device_if.m -h -p
4499 $(QUIET)$(RM) $(@D)/device_if.m
4500
4501$$(FreeBSDGeneratedKernelHeaders_0_OUTDIR)/pci_if.h: $(VBOX_FREEBSD_SRC)/dev/pci/pci_if.m | $$(dir $$@)
4502 $(call MSG_TOOL,awk,FreeBSDGeneratedKernelHeaders,$<,$@)
4503 $(QUIET)$(CP) -f $< $(@D)/pci_if.m
4504 $(QUIET)$(VBOX_AWK) -f $(VBOX_FREEBSD_SRC)/tools/makeobjops.awk $(@D)/pci_if.m -h -p
4505 $(QUIET)$(RM) $(@D)/pci_if.m
4506endif # FreeBSD
4507
4508
4509#
4510# Aliases for .cpp.h files so we can more easily do syntax checking from the editor.
4511#
4512ldrELFRelocatable.cpp.o: ldrELF.o
4513ldrELFRelocatable.cpp.obj: ldrELF.obj
4514
4515
4516#
4517# Doxygen documentation.
4518#
4519IPRT_DOXYFILE_INPUT_DIRS = \
4520 $(PATH_ROOT)/include/iprt \
4521 $(PATH_ROOT)/include/iprt/cpp \
4522 $(PATH_ROOT)/include/iprt/linux \
4523 $(PATH_ROOT)/include/iprt/nocrt \
4524 $(PATH_ROOT)/include/iprt/nocrt/x86 \
4525 $(PATH_ROOT)/include/iprt/nocrt/amd64 \
4526 $(PATH_ROOT)/include/iprt/nocrt/compiler \
4527 $(VBOX_PATH_RUNTIME_SRC)/include/internal \
4528 $(VBOX_PATH_RUNTIME_SRC)/common/alloc \
4529 $(VBOX_PATH_RUNTIME_SRC)/common/asm \
4530 $(VBOX_PATH_RUNTIME_SRC)/common/checksum \
4531 $(VBOX_PATH_RUNTIME_SRC)/common/dbg \
4532 $(VBOX_PATH_RUNTIME_SRC)/common/err \
4533 $(VBOX_PATH_RUNTIME_SRC)/common/ldr \
4534 $(VBOX_PATH_RUNTIME_SRC)/common/log \
4535 $(VBOX_PATH_RUNTIME_SRC)/common/math \
4536 $(VBOX_PATH_RUNTIME_SRC)/common/math/amd64 \
4537 $(VBOX_PATH_RUNTIME_SRC)/common/math/gcc \
4538 $(VBOX_PATH_RUNTIME_SRC)/common/math/x86 \
4539 $(VBOX_PATH_RUNTIME_SRC)/common/misc \
4540 $(VBOX_PATH_RUNTIME_SRC)/common/path \
4541 $(VBOX_PATH_RUNTIME_SRC)/common/rand \
4542 $(VBOX_PATH_RUNTIME_SRC)/common/string \
4543 $(VBOX_PATH_RUNTIME_SRC)/common/table \
4544 $(VBOX_PATH_RUNTIME_SRC)/common/time \
4545 $(VBOX_PATH_RUNTIME_SRC)/VBox \
4546 $(foreach dir, $(VBOX_PATH_RUNTIME_SRC) $(VBOX_PATH_RUNTIME_SRC)/r3 $(VBOX_PATH_RUNTIME_SRC)/r0drv,\
4547 $(dir) \
4548 $(dir)/darwin \
4549 $(dir)/haiku \
4550 $(dir)/linux \
4551 $(dir)/nt \
4552 $(dir)/os2 \
4553 $(dir)/solaris \
4554 $(dir)/win \
4555 $(dir)/win32 \
4556 $(dir)/win64 \
4557 $(dir)/generic \
4558 )
4559
4560# These must come first in order to make things look nice.
4561IPRT_DOXYFILE_INPUT_FIRST =\
4562 $(PATH_ROOT)/include/iprt/cdefs.h \
4563 $(PATH_ROOT)/include/iprt/types.h \
4564 $(PATH_ROOT)/include/iprt/runtime.h \
4565 $(PATH_ROOT)/include/iprt/param.h \
4566 $(PATH_ROOT)/include/iprt/assert.h \
4567 $(PATH_ROOT)/include/iprt/asm.h \
4568
4569IPRT_DOXYFILE_INPUT := \
4570 $(filter-out %.cpp.h, $(sort $(wildcard $(addsuffix /*.h, $(IPRT_DOXYFILE_INPUT_DIRS)))) ) \
4571 $(foreach dir, $(IPRT_DOXYFILE_INPUT_DIRS), $(wildcard $(dir)/*.cpp $(dir)/.c $(dir)/.asm))
4572IPRT_DOXYFILE_INPUT := \
4573 $(IPRT_DOXYFILE_INPUT_FIRST) \
4574 $(sort $(filter-out $(IPRT_DOXYFILE_INPUT_FIRST), $(IPRT_DOXYFILE_INPUT)))
4575
4576
4577IPRT_DOXYFILE_OUTPUT = $(PATH_OUT)/docs/iprt
4578BLDDIRS += $(IPRT_DOXYFILE_OUTPUT)
4579
4580includedep $(IPRT_DOXYFILE_OUTPUT)/Doxyfile.iprt.dep
4581
4582# Generate the Doxyfile
4583$(IPRT_DOXYFILE_OUTPUT)/Doxyfile.iprt: \
4584 $(VBOX_PATH_RUNTIME_SRC)/Doxyfile \
4585 $(VBOX_PATH_RUNTIME_SRC)/Makefile.kmk \
4586 $(comp-vars IPRT_DOXYFILE_INPUT,DOXYGEN_IPRT_INPUT_PREV,FORCE) \
4587 $(comp-vars IPRT_DOXYFILE_OUTPUT,DOXYGEN_IPRT_OUTPUT_PREV,FORCE) \
4588 | $$(dir $$@)
4589 $(QUIET)$(RM) -f $@ $@.tmp $@.dep
4590 $(QUIET)$(CP) -f $(VBOX_PATH_RUNTIME_SRC)/Doxyfile $@.tmp
4591 $(QUIET)$(APPEND) $@.tmp
4592 $(QUIET)$(APPEND) $@.tmp "OUTPUT_DIRECTORY = $(IPRT_DOXYFILE_OUTPUT)"
4593 $(QUIET)$(APPEND) $@.tmp "WARN_LOGFILE = $(IPRT_DOXYFILE_OUTPUT)/errors"
4594 $(QUIET)$(APPEND) $@.tmp 'INCLUDE_PATH = ' \
4595 '$(PATH_ROOT)/include' \
4596 '$(VBOX_PATH_RUNTIME_SRC)/include' \
4597 '$(VBOX_PATH_RUNTIME_SRC)/' \
4598 '$(VBOX_PATH_RUNTIME_SRC)/common/table'
4599 $(QUIET)$(APPEND) $@.tmp "INCLUDE_FILE_PATTERNS = *.cpp.h"
4600 $(QUIET)$(APPEND) $@.tmp "PREDEFINED += $(ARCH_BITS_DEFS)"
4601 $(QUIET)$(APPEND) $@.tmp 'EXCLUDE = '\
4602 '$(VBOX_PATH_RUNTIME_SRC)/common/string/unidata-flags.cpp' \
4603 '$(VBOX_PATH_RUNTIME_SRC)/common/string/unidata-lower.cpp' \
4604 '$(VBOX_PATH_RUNTIME_SRC)/common/string/unidata-upper.cpp' \
4605 $(QUIET)$(APPEND) $@.tmp
4606 $(QUIET)$(APPEND) $@.tmp 'INPUT = $(foreach x,$(IPRT_DOXYFILE_INPUT),\$(NLTAB)$(x))'
4607 $(QUIET)$(APPEND) $@.tmp
4608 $(QUIET)$(MV) -f $@.tmp $@
4609 $(QUIET)$(APPEND) $@.dep "DOXYGEN_IPRT_OUTPUT_PREV = $(IPRT_DOXYFILE_OUTPUT)"
4610 $(QUIET)$(APPEND) $@.dep "DOXYGEN_IPRT_INPUT_PREV = $(IPRT_DOXYFILE_INPUT)"
4611
4612# Do the actual job.
4613$(IPRT_DOXYFILE_OUTPUT)/docs.iprt: $(IPRT_DOXYFILE_OUTPUT)/Doxyfile.iprt $$(IPRT_DOXYFILE_INPUT) \
4614 | $(IPRT_DOXYFILE_OUTPUT)/
4615 $(QUIET)$(RM) -f $@
4616 $(QUIET)$(RM) -Rf $(IPRT_DOXYFILE_OUTPUT)/html/
4617 doxygen $(DOXYGEN_OPTS) $(IPRT_DOXYFILE_OUTPUT)/Doxyfile.iprt
4618 $(SED) -e '/warning. Unexpected tag .dd. found/d' \
4619 -e '/warning. Unsupported xml.html tag .globalScope. found/d' \
4620 --output $(IPRT_DOXYFILE_OUTPUT)/errors2 \
4621 $(IPRT_DOXYFILE_OUTPUT)/errors
4622 $(CAT) $(IPRT_DOXYFILE_OUTPUT)/errors2
4623 $(SED) -e "/[^ ]/q 1" $(IPRT_DOXYFILE_OUTPUT)/errors2
4624 $(APPEND) $@
4625
4626# aliases
4627docs.iprt: $(IPRT_DOXYFILE_OUTPUT)/docs.iprt
4628if !defined(VBOX_ONLY_DOCS) && defined(VBOX_WITH_ALL_DOXYGEN_TARGETS)
4629docs: $(IPRT_DOXYFILE_OUTPUT)/docs.iprt
4630endif
4631
4632test-doxygen::
4633 @echo test-$(comp-vars IPRT_DOXYFILE_OUTPUT,DOXYGEN_IPRT_OUTPUT_PREV,FORCE)
4634 @echo $(IPRT_DOXYFILE_OUTPUT)
4635 @echo $(DOXYGEN_IPRT_OUTPUT_PREV)
4636 @echo $(IPRT_DOXYFILE_INPUT)
4637
4638
4639#
4640# Test mangling.
4641#
4642if1of ($(LIBRARIES),RuntimeR3 RuntimeR0 RuntimeR0Drv RuntimeRC)
4643 test-mangling:: $(IPRT_OUT_DIR)/mangling.run
4644 OTHERS += $(IPRT_OUT_DIR)/mangling.run
4645 OTHER_CLEAN += $(IPRT_OUT_DIR)/mangling.run
4646 $(IPRT_OUT_DIR)/mangling.run: \
4647 $$(RuntimeR3_1_TARGET) \
4648 $$(RuntimeR0_1_TARGET) \
4649 $$(RuntimeR0Drv_1_TARGET) \
4650 $$(RuntimeRC_1_TARGET)
4651 if1of ($(KBUILD_TARGET), win os2)
4652 $(call MSG_L1,IPRT: skipped mangling test.)
4653 else
4654# Generate a SED script from mangling.h that checks for known symbols.
4655 $(QUIET)$(SED) \
4656 -e '/^# *define.*RT_MANGLER/!d' \
4657 -e 's/^.*RT_MANGLER(\([^)][^)]*\)).*$(DOLLAR)/\/^\1$(DOLLAR)\/b ok/' \
4658 $(PATH_ROOT)/include/iprt/mangling.h \
4659 --output "$@"
4660 $(QUIET)$(APPEND) -n '$@' \
4661 ':bad' \
4662 's/^\(.*\)$(DOLLAR)/error: Missing # define \1 /' \
4663 ':bad-pad' \
4664 '/^.\{0,70\}$(DOLLAR)/ { s/$(DOLLAR)/ /; bbad-pad; }' \
4665 's/define \([^ ]*\) \([ ]*\)$(DOLLAR)/define \1 \2RT_MANGLER(\1)/' \
4666 'p' \
4667 $(if-expr !defined(IPRT_IGNORE_TEST_MANGLING),'q 1') \
4668 '' \
4669 ':ok' \
4670 'd'
4671# Find the best way to generate a symbol list and subject it to mangling.h.
4672 if $(intersects $(KBUILD_TARGET), linux) && "$(VBOX_GCC_fvisibility-hidden)"
4673 $(call MSG_L1,IPRT: Testing mangling and visiblity for newer gcc...)
4674 $(QUIET)readelf -Ws $^ \
4675 | $(SED) \
4676 -e 's/[[:space:]]\+/ /g' \
4677 -e '/^ *[[:digit:]]\+:/!d' \
4678 -e 's/^ \+[[:digit:]]\+: \+[[:xdigit:]]\+ \+[[:digit:]]\+ \+//' \
4679 -e '/^SECTION/d' \
4680 -e '/^FILE/d' \
4681 -e 's/^[[:alpha:]]\+ \+//' \
4682 -e '/LOCAL/d' \
4683 -e 's/^[[:alpha:]]\+ \+//' \
4684 -e '/^HIDDEN [[:xdigit:]]\+ RT/bkeep-hidden' \
4685 -e '/^HIDDEN [[:xdigit:]]\+ g_[a-z0-9]*RT/bkeep-hidden' \
4686 -e '/^HIDDEN/d' \
4687 -e ':keep-hidden' \
4688 -e 's/^[[:alpha:]]\+ \+//' \
4689 -e '/^UND/d' \
4690 -e 's/^[[:digit:]]\+ \+//' \
4691 \
4692 -e '/^nocrt_/d' \
4693 -e '/^bzero/d' \
4694 -e '/^memchr/d' \
4695 -e '/^memcmp/d' \
4696 -e '/^memcpy/d' \
4697 -e '/^mempcpy/d' \
4698 -e '/^memmove/d' \
4699 -e '/^memset/d' \
4700 -e '/^strchr/d' \
4701 -e '/^strpbrk/d' \
4702 -e '/^_Z7strpbrk/d' \
4703 -e '/^strcmp/d' \
4704 -e '/^strcpy/d' \
4705 -e '/^strncpy/d' \
4706 -e '/^strlen/d' \
4707 -e '/^setjmp/d' \
4708 -e '/^longjmp/d' \
4709 -e '/^_Z[[:alpha:]]*[[:digit:]]\+RTC/d' \
4710 -e '/^_Z[[:alpha:]]*[[:digit:]]\+RTC/d' \
4711 \
4712 -e '/^_ZnwjPv/d' \
4713 -e '/^_ZnwmPv/d' \
4714 -e '/^_ZNSt[1-9]/d' \
4715 \
4716 -e '/^_ZN[a-zA-Z]*St[[:digit:]]*_*[lL]ist/d' \
4717 -e '/^_ZN[a-zA-Z]*[[:digit:]]*__gnu_cxx/d' \
4718 -e '/^_ZNSa.*ElementNode.*/d' \
4719 -e '/^_ZSt.*ElementNode.*/d' \
4720 \
4721 -e '/^_Z[[:digit:]]\+dbus/d' \
4722 -e '/^_Z13RTDBusLoadLibv/d' \
4723 \
4724 -e '/^g_[ac]VTG/d' \
4725 -e '/^g_VTGObjHeader/d' \
4726 -e '/^g_VTGProbeData/d' \
4727 -e '/^VTGProbeStub/d' \
4728 -e '/^g_achVTGStringTable/d' \
4729 -e '/^g_acVTGProbeEnabled/d' \
4730 \
4731 -e '/^VBoxHost_/d'\
4732 -e '/^VBoxGuest_/d'\
4733 | $(SED) -nf "$@"
4734 endif
4735 $(call MSG_L1,IPRT: Testing mangling using nm...)
4736 $(QUIET)$(VBOX_NM) $^ 2> /dev/null \
4737 | $(SED) -n \
4738 -e 's/^[0-9a-f][0-9a-f]* //' \
4739 -e '/^[TUDB] /!d' \
4740 -e 's/^. //' \
4741 $(if-expr "$(KBUILD_TARGET)" == "darwin" || "$(KBUILD_TARGET)" == "os2" || "$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH)" == "win.x86", \
4742 -e 's/^_//',) \
4743 \
4744 -e '/^g_cchrt/d'\
4745 -e '/^g_frt/d'\
4746 -e '/^g_offrt/d'\
4747 -e '/^g_pfnrt/d'\
4748 -e '/^g_rt/d'\
4749 -e '/^g_szrt/d'\
4750 -e '/^g_ProcessSelf/d'\
4751 -e '/^g_u64ProgramStart/d'\
4752 -e '/^g_enmProcessPriority/d'\
4753 -e '/^g_hDbgModStrCache/d'\
4754 -e '/^g_pfnR0Darwin/d'\
4755 -e '/^g_pDarwinLockGroup/d'\
4756 $(if-expr "$(KBUILD_TARGET)" == "solaris", \
4757 -e '/^g_kLdrRdrFileOps/d' \
4758 -e '/^g_pSUPGlobalInfoPage/d' \
4759 -e '/^g_Logger/d' \
4760 -e '/^g_RelLogger/d' \
4761 -e '/^g_VM/d',) \
4762 $(if-expr "$(KBUILD_TARGET)" == "linux", \
4763 -e '/^g_kLdrRdrFileOps/d',) \
4764 \
4765 -e '/^g_[ac]VTG/d' \
4766 -e '/^g_VTGObjHeader/d' \
4767 -e '/^g_VTGProbeData/d' \
4768 -e '/^VTGProbeStub/d' \
4769 -e '/^g_achVTGStringTable/d' \
4770 -e '/^g_acVTGProbeEnabled/d' \
4771 \
4772 -e '/^RTDBusLoadLib/d' \
4773 \
4774 -e '/^RT/p' \
4775 -e '/^g_/p' \
4776 | $(SED) -nf "$@"
4777 endif
4778endif
4779 $(QUIET)$(APPEND) -t $@
4780
4781if !defined(VBOX_ONLY_ADDITIONS) && !defined(VBOX_ONLY_VALIDATIONKIT) && !defined(VBOX_ONLY_DOCS)
4782#
4783# Windows build tool.
4784#
4785BLDPROGS.win += ntBldSymDb
4786ntBldSymDb_TEMPLATE = VBoxAdvBldProg
4787ntBldSymDb_INCS = .
4788ntBldSymDb_SOURCES = r0drv/nt/ntBldSymDb.cpp
4789endif
4790
4791
4792#
4793# Generate the rules (we're the to sub-makefile).
4794#
4795include $(FILE_KBUILD_SUB_FOOTER)
4796
4797
4798#
4799# Aliases for code templates.
4800#
4801rsa-template.o rsa-template.obj: rsa-core.o rsa-asn1-decoder.o rsa-sanity.o rsa-init.o
4802spc-template.o spc-template.obj: spc-core.o spc-asn1-decoder.o spc-sanity.o spc-init.o
4803taf-template.o taf-template.obj: taf-core.o taf-asn1-decoder.o taf-sanity.o taf-init.o
4804tsp-template.o tsp-template.obj: tsp-core.o tsp-asn1-decoder.o tsp-sanity.o tsp-init.o
4805x509-template.o x509-template.obj: x509-core.o x509-asn1-decoder.o x509-sanity.o x509-init.o
4806pkcs7-template.o pkcs7-template.obj: pkcs7-core.o pkcs7-asn1-decoder.o pkcs7-sanity.o pkcs7-init.o
Note: See TracBrowser for help on using the repository browser.

© 2023 Oracle
ContactPrivacy policyTerms of Use