VirtualBox

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

Last change on this file since 85959 was 85875, checked in by vboxsync, 4 years ago

Main: bugref:9224: Added RTFileQuerySectorSize into IPRT

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