VirtualBox

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

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

IPRT/nocrt: Implemented x86 and amd64 fenv.h to assist with the testing. More tests. bugref:10261

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