VirtualBox

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

Last change on this file since 96525 was 96525, checked in by vboxsync, 2 years ago

/Config.kmk,IPRT/Makefile.kmk: We need a RuntimR3NoAsan.lib for asan builds on Windows, so the VBoxR3StaticExeNoAsan and VBoxR3StaticDllNoAsan templates can use IPRT. The former is necessary for VBOXR3AUTOTST on older hosts, and the latter for the installer components in no-CRT mode. bugref:10261

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

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette