VirtualBox

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

Last change on this file since 11347 was 11347, checked in by vboxsync, 16 years ago

iprt/rand: Added a generic RTRandAdv API for use with any random number generator. Implemented the classic Park-Miller pseudo random number generator.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 46.2 KB
Line 
1# $Id: Makefile.kmk 11347 2008-08-11 21:12:55Z vboxsync $
2## @file
3# Sub-Makefile for the IPRT (IPRT).
4#
5
6#
7# Copyright (C) 2006-2007 Sun Microsystems, Inc.
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# Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa
27# Clara, CA 95054 USA or visit http://www.sun.com if you need
28# additional information or have any questions.
29#
30
31ifdef VBOX_KBUILD_HACKING
32SUB_DEPTH = ../../..
33else
34SUB_DEPTH = .
35DEPTH ?= ../../..
36endif
37include $(KBUILD_PATH)/subheader.kmk
38
39ifdef VBOX_ONLY_ADDITIONS
40 #
41 # Only build the additions, sort out the legacy names first.
42 #
43 LIBRARIES += RuntimeGuestR0 RuntimeGuestR3 RuntimeGuestR3Mini
44 #LIBRARIES.os2 = RuntimeGuestR0OS2Warp3
45 LIBRARIES.win.x86 += RuntimeGuestR0NT4
46 ifndef VBOX_WITH_ADDITION_DRIVERS
47 if1of ($(KBUILD_TARGET), linux l4) # All drivers are optional, can skip RuntimeGuestR0.
48 LIBRARIES := $(filter-out RuntimeGuestR0, $(LIBRARIES))
49 endif
50 endif
51
52else
53
54 #
55 # Normal build.
56 #
57 include $(PATH_SUB_CURRENT)/testcase/Makefile.kmk
58
59 BLDPROGS += uniread
60 LIBRARIES += RuntimeR3 RuntimeR0 RuntimeGC RuntimeEFCPP RuntimeR3NoCRTGCC
61 ifdef VBOX_WITH_VBOXDRV
62 LIBRARIES += RuntimeR0Drv
63 endif
64 ifdef VBOX_WITH_ADDITIONS
65 LIBRARIES += RuntimeGuestR0 RuntimeGuestR3 RuntimeGuestR3Mini
66 #LIBRARIES.os2 += RuntimeGuestR0OS2Warp3
67 LIBRARIES.win.x86 += RuntimeGuestR0NT4
68 ifndef VBOX_WITH_ADDITION_DRIVERS
69 if1of ($(KBUILD_TARGET), linux l4) # All drivers are optional, can skip RuntimeGuestR0.
70 LIBRARIES := $(filter-out RuntimeGuestR0, $(LIBRARIES))
71 endif
72 endif
73 endif # VBOX_WITH_ADDITIONS
74 LIBRARIES.l4 += RuntimeR3L4 RuntimeLnxHostR3
75 DLLS += VBoxRT
76 OTHER_CLEAN += \
77 $(PATH_TARGET)/errmsgdata.h \
78 $(PATH_TARGET)/errmsgcomdata.h \
79 $(PATH_TARGET)/Doxyfile.iprt \
80 $(PATH_TARGET)/Doxyfile.iprt.dep \
81 $(PATH_TARGET)/docs.iprt
82
83endif
84
85
86#
87# Globals
88#
89VBOX_PATH_RUNTIME_SRC := $(PATH_SUB_CURRENT)
90
91
92#
93# Unicode Specification reader used to regenerate unidata.cpp.
94#
95uniread_TEMPLATE = VBOXBLDPROG
96uniread_SOURCES = common/string/uniread.cpp
97uniread_INCS = include
98
99#
100# Win64 assembly sources.
101#
102RuntimeWin64ASM_SOURCES = \
103 win/amd64/ASMAtomicBitClear.asm \
104 win/amd64/ASMAtomicBitTestAndToggle.asm \
105 win/amd64/ASMAtomicBitToggle.asm \
106 win/amd64/ASMAtomicReadU64.asm \
107 win/amd64/ASMAtomicXchgU16.asm \
108 win/amd64/ASMAtomicXchgU8.asm \
109 win/amd64/ASMBitFirstClear.asm \
110 win/amd64/ASMBitFirstSet.asm \
111 win/amd64/ASMGetCS.asm \
112 win/amd64/ASMGetDS.asm \
113 win/amd64/ASMGetES.asm \
114 win/amd64/ASMGetFlags.asm \
115 win/amd64/ASMGetFS.asm \
116 win/amd64/ASMGetGS.asm \
117 win/amd64/ASMGetIDTR.asm \
118 win/amd64/ASMGetGDTR.asm \
119 win/amd64/ASMGetTR.asm \
120 win/amd64/ASMGetSS.asm \
121 win/amd64/ASMProbeReadByte.asm \
122 win/amd64/ASMSetFlags.asm \
123 win/amd64/ASMGetDR0.asm \
124 win/amd64/ASMGetDR1.asm \
125 win/amd64/ASMGetDR2.asm \
126 win/amd64/ASMGetDR3.asm \
127 win/amd64/ASMGetDR6.asm \
128 win/amd64/ASMGetDR7.asm \
129 common/asm/ASMMultU64ByU32DivByU32.asm
130
131#
132# Win32 assembly sources.
133#
134RuntimeWin32ASM_SOURCES = \
135 common/asm/ASMMultU64ByU32DivByU32.asm
136
137#
138# RuntimeR3 - Static Runtime for Ring-3 executables.
139#
140RuntimeR3_TEMPLATE = VBOXR3EXE
141RuntimeR3_SDKS.win = WINPSDK W2K3DDK
142RuntimeR3_DEFS = IN_RT_R3 IN_SUP_R3 LDR_WITH_NATIVE LDR_WITH_ELF32 LDR_WITH_PE RT_WITH_VBOX
143ifdef IPRT_WITH_KSTUFF
144 RuntimeR3_DEFS += LDR_WITH_KLDR
145endif
146ifdef VBOX_MAIN_RELEASE_LOG ## @todo (dmik): temporary, until RTThreadSelf/RTThreadAdopt are properly updated
147 RuntimeR3_DEFS += RTCRITSECT_STRICT
148endif
149RuntimeR3_INCS = \
150 include \
151 $(PATH_ROOT)/src/libs/liblzf-1.51
152ifdef IPRT_WITH_KSTUFF
153 RuntimeR3_INCS += \
154 $(PATH_ROOT)/src/libs/kStuff/kStuff/include
155endif
156RuntimeR3_INCS.l4 = \
157 $(L4_INCDIR)
158# for iconv.h
159RuntimeR3_INCS.freebsd = \
160 /usr/local/include
161
162
163# RuntimeR3_INCS.solaris = \
164# /usr/include
165
166RuntimeR3_SOURCES = \
167 common/alloc/alloc.cpp \
168 common/alloc/heapsimple.cpp \
169 common/checksum/crc32.cpp \
170 common/checksum/crc64.cpp \
171 common/checksum/md5.cpp \
172 common/checksum/ipv4.cpp \
173 common/err/errmsg.cpp \
174 common/err/RTErrConvertFromErrno.cpp \
175 common/ldr/ldr.cpp \
176 common/ldr/ldrELF.cpp \
177 common/ldr/ldrEx.cpp \
178 common/ldr/ldrFile.cpp \
179 common/ldr/ldrNative.cpp \
180 common/ldr/ldrPE.cpp \
181 common/log/log.cpp \
182 common/log/logcom.cpp \
183 common/log/logformat.cpp \
184 common/misc/assert.cpp \
185 common/misc/cache.cpp \
186 common/misc/cidr.cpp \
187 common/misc/getopt.cpp \
188 common/misc/handletable.cpp \
189 common/misc/handletablectx.cpp \
190 common/misc/handletablesimple.cpp \
191 common/misc/once.cpp \
192 common/misc/req.cpp \
193 common/misc/sanity-c.c \
194 common/misc/sanity-cpp.cpp \
195 common/misc/semspingpong.cpp \
196 common/misc/thread.cpp \
197 common/misc/zip.cpp \
198 common/rand/rand.cpp \
199 common/rand/randadv.cpp \
200 common/rand/randparkmiller.cpp \
201 common/string/RTStrNLen.cpp \
202 common/string/RTStrNLenEx.cpp \
203 common/string/straprintf.cpp \
204 common/string/strformat.cpp \
205 common/string/strformatrt.cpp \
206 common/string/strformattype.cpp \
207 common/string/string.cpp \
208 common/string/strprintf.cpp \
209 common/string/strspace.cpp \
210 common/string/strstrip.cpp \
211 common/string/strtonum.cpp \
212 common/string/uni.cpp \
213 common/string/unidata.cpp \
214 common/string/utf-16.cpp \
215 common/string/utf-8.cpp \
216 common/table/avlgcptr.cpp \
217 common/table/avlhcphys.cpp \
218 common/table/avllu32.cpp \
219 common/table/avlou32.cpp \
220 common/table/avlogcphys.cpp \
221 common/table/avlogcptr.cpp \
222 common/table/avlohcphys.cpp \
223 common/table/avloioport.cpp \
224 common/table/avlpv.cpp \
225 common/table/avlrgcptr.cpp \
226 common/table/avlrogcphys.cpp \
227 common/table/avlrogcptr.cpp \
228 common/table/avlroioport.cpp \
229 common/table/avlroogcptr.cpp \
230 common/table/avlu32.cpp \
231 common/table/avlul.cpp \
232 common/table/table.cpp \
233 common/time/time.cpp \
234 common/time/timeprog.cpp \
235 common/time/timesup.cpp \
236 generic/critsect-generic.cpp \
237 generic/env-generic.cpp \
238 generic/RTFileCopy-generic.cpp \
239 generic/RTFileReadAll-generic.cpp \
240 generic/RTFileReadAllEx-generic.cpp \
241 generic/RTFileReadAllByHandle-generic.cpp \
242 generic/RTFileReadAllByHandleEx-generic.cpp \
243 generic/RTFileReadAllFree-generic.cpp \
244 generic/RTLogWriteStdErr-generic.cpp \
245 generic/RTLogWriteStdOut-generic.cpp \
246 generic/RTLogWriteUser-generic.cpp \
247 generic/RTTimerLRCreate-generic.cpp \
248 generic/semfastmutex-generic.cpp \
249 generic/spinlock-generic.cpp \
250 generic/timerlr-generic.cpp \
251 r3/alloc-ef.cpp \
252 r3/alloc.cpp \
253 r3/dir.cpp \
254 r3/fileio.cpp \
255 r3/fs.cpp \
256 r3/init.cpp \
257 r3/path.cpp \
258 r3/process.cpp \
259 r3/stream.cpp \
260 r3/tcp.cpp
261
262#if1of ($(KBUILD_TARGET_ARCH),amd64 x86)
263# RuntimeR3_SOURCES += common/time/timesupA.asm
264#else
265 RuntimeR3_SOURCES += common/time/timesupref.cpp
266#endif
267
268ifdef IPRT_WITH_KSTUFF
269 RuntimeR3_SOURCES += \
270 common/ldr/ldrkStuff.cpp
271endif
272
273# VBox specific stuff.
274RuntimeR3_SOURCES += \
275 VBox/strformat-vbox.cpp \
276 VBox/RTAssertDoBreakpoint-vbox.cpp \
277 VBox/log-vbox.cpp
278ifneq ($(KBUILD_TARGET),win)
279RuntimeR3_SOURCES += \
280 common/err/errmsgxpcom.cpp
281endif
282
283RuntimeR3_SOURCES.win = \
284 generic/rand-stubs-generic.cpp \
285 generic/RTDirQueryInfo-generic.cpp \
286 generic/RTDirSetTimes-generic.cpp \
287 generic/semnoint-generic.cpp \
288 generic/semsrw-generic.cpp \
289 generic/RTMpGetCurFrequency-generic.cpp \
290 generic/RTMpGetMaxFrequency-generic.cpp \
291 nt/RTErrConvertFromNtStatus.cpp \
292 r3/posix/env-posix.cpp \
293 r3/win/alloc-win.cpp \
294 r3/win/dir-win.cpp \
295 r3/win/fileio-win.cpp \
296 r3/win/fs-win.cpp \
297 r3/win/ldrNative-win.cpp \
298 r3/win/mp-win.cpp \
299 r3/win/path-win.cpp \
300 r3/win/process-win.cpp \
301 r3/win/RTLogWriteDebugger-win.cpp \
302 r3/win/sched-win.cpp \
303 r3/win/sems-win.cpp \
304 r3/win/thread-win.cpp \
305 r3/win/time-win.cpp \
306 r3/win/timer-win.cpp \
307 r3/win/tls-win.cpp \
308 r3/win/utf16locale-win.cpp \
309 r3/win/utf8-win.cpp \
310 r3/win/uuid-win.cpp \
311 r3/win/RTUuidCreate-win.cpp \
312 win/errmsgwin.cpp \
313 win/RTErrConvertFromWin32.cpp
314
315RuntimeR3_SOURCES.win.amd64 = $(RuntimeWin64ASM_SOURCES)
316RuntimeR3_SOURCES.win.x86 = $(RuntimeWin32ASM_SOURCES)
317
318RuntimeR3_SOURCES.linux = \
319 generic/pathhost-generic.cpp \
320 generic/RTDirQueryInfo-generic.cpp \
321 generic/RTDirSetTimes-generic.cpp \
322 generic/RTFileMove-generic.cpp \
323 generic/RTLogWriteDebugger-generic.cpp \
324 generic/RTTimeLocalNow-generic.cpp \
325 generic/RTTimerCreate-generic.cpp \
326 generic/RTUuidCreate-generic.cpp \
327 generic/utf16locale-generic.cpp \
328 generic/uuid-generic.cpp \
329 r3/linux/mp-linux.cpp \
330 r3/linux/sched-linux.cpp \
331 r3/linux/time-linux.cpp \
332 r3/posix/alloc-posix.cpp \
333 r3/posix/dir-posix.cpp \
334 r3/posix/env-posix.cpp \
335 r3/posix/fileio-posix.cpp \
336 r3/posix/filelock-posix.cpp \
337 r3/posix/fs-posix.cpp \
338 r3/posix/ldrNative-posix.cpp \
339 r3/posix/path-posix.cpp \
340 r3/posix/process-posix.cpp \
341 r3/posix/rand-posix.cpp \
342 r3/posix/RTTimeNow-posix.cpp \
343 r3/posix/semrw-posix.cpp \
344 r3/posix/thread-posix.cpp \
345 r3/posix/timelocal-posix.cpp \
346 r3/posix/timer-posix.cpp \
347 r3/posix/tls-posix.cpp \
348 r3/posix/utf8-posix.cpp
349RuntimeR3_SOURCES.linux.x86 += \
350 r3/posix/semevent-posix.cpp \
351 r3/posix/semeventmulti-posix.cpp \
352 r3/posix/semmutex-posix.cpp
353RuntimeR3_SOURCES.linux.amd64 += \
354 r3/linux/semevent-linux.cpp \
355 r3/linux/semeventmulti-linux.cpp
356ifdef RT_NEW_LINUX_MUTEX_CODE
357 RuntimeR3_SOURCES.linux.amd64 += \
358 r3/linux/semmutex-linux.cpp
359else
360 RuntimeR3_SOURCES.linux.amd64 += \
361 r3/posix/semmutex-posix.cpp
362endif
363
364RuntimeR3_SOURCES.os2 = \
365 generic/pathhost-generic.cpp \
366 generic/rand-stubs-generic.cpp \
367 generic/RTDirQueryInfo-generic.cpp \
368 generic/RTDirSetTimes-generic.cpp \
369 generic/RTFileMove-generic.cpp \
370 generic/RTLogWriteDebugger-generic.cpp \
371 generic/RTTimeLocalNow-generic.cpp \
372 generic/RTTimerCreate-generic.cpp \
373 generic/RTUuidCreate-generic.cpp \
374 generic/semnoint-generic.cpp \
375 generic/semsrw-generic.cpp \
376 generic/timer-generic.cpp \
377 generic/utf16locale-generic.cpp \
378 generic/uuid-generic.cpp \
379 generic/RTMpGetCurFrequency-generic.cpp \
380 generic/RTMpGetMaxFrequency-generic.cpp \
381 os2/RTErrConvertFromOS2.cpp \
382 r3/os2/filelock-os2.cpp \
383 r3/os2/mp-os2.cpp \
384 r3/os2/sched-os2.cpp \
385 r3/os2/sems-os2.cpp \
386 r3/os2/thread-os2.cpp \
387 r3/os2/time-os2.cpp \
388 r3/posix/alloc-posix.cpp \
389 r3/posix/dir-posix.cpp \
390 r3/posix/env-posix.cpp \
391 r3/posix/fileio-posix.cpp \
392 r3/posix/fs-posix.cpp \
393 r3/posix/ldrNative-posix.cpp \
394 r3/posix/path-posix.cpp \
395 r3/posix/process-posix.cpp \
396 r3/posix/RTTimeNow-posix.cpp \
397 r3/posix/timelocal-posix.cpp \
398 r3/posix/utf8-posix.cpp
399
400RuntimeR3_SOURCES.darwin = \
401 darwin/RTErrConvertFromDarwin.cpp \
402 darwin/RTErrConvertFromDarwinCOM.cpp \
403 darwin/RTErrConvertFromDarwinIO.cpp \
404 darwin/RTErrConvertFromDarwinKern.cpp \
405 generic/pathhost-generic.cpp \
406 generic/RTDirQueryInfo-generic.cpp \
407 generic/RTDirSetTimes-generic.cpp \
408 generic/RTFileMove-generic.cpp \
409 generic/RTLogWriteDebugger-generic.cpp \
410 generic/RTTimeLocalNow-generic.cpp \
411 generic/RTTimerCreate-generic.cpp \
412 generic/RTUuidCreate-generic.cpp \
413 generic/sched-generic.cpp \
414 generic/timer-generic.cpp \
415 generic/utf16locale-generic.cpp \
416 generic/uuid-generic.cpp\
417 r3/darwin/alloc-darwin.cpp \
418 r3/darwin/filelock-darwin.cpp \
419 r3/darwin/mp-darwin.cpp \
420 r3/darwin/time-darwin.cpp \
421 r3/posix/dir-posix.cpp \
422 r3/posix/env-posix.cpp \
423 r3/posix/fileio-posix.cpp \
424 r3/posix/fs-posix.cpp \
425 r3/posix/ldrNative-posix.cpp \
426 r3/posix/path-posix.cpp \
427 r3/posix/process-posix.cpp \
428 r3/posix/rand-posix.cpp \
429 r3/posix/semevent-posix.cpp \
430 r3/posix/semeventmulti-posix.cpp \
431 r3/posix/semmutex-posix.cpp \
432 r3/posix/semrw-posix.cpp \
433 r3/posix/thread-posix.cpp \
434 r3/posix/timelocal-posix.cpp \
435 r3/posix/tls-posix.cpp \
436 r3/posix/utf8-posix.cpp
437
438## @todo Make BSD sched.
439RuntimeR3_SOURCES.freebsd = \
440 generic/pathhost-generic.cpp \
441 generic/RTDirQueryInfo-generic.cpp \
442 generic/RTDirSetTimes-generic.cpp \
443 generic/RTFileMove-generic.cpp \
444 generic/RTLogWriteDebugger-generic.cpp \
445 generic/RTTimeLocalNow-generic.cpp \
446 generic/RTTimerCreate-generic.cpp \
447 generic/RTUuidCreate-generic.cpp \
448 generic/sched-generic.cpp \
449 generic/utf16locale-generic.cpp \
450 generic/uuid-generic.cpp \
451 generic/RTMpGetCurFrequency-generic.cpp \
452 generic/RTMpGetMaxFrequency-generic.cpp \
453 r3/freebsd/alloc-freebsd.cpp \
454 r3/posix/dir-posix.cpp \
455 r3/posix/env-posix.cpp \
456 r3/posix/fileio-posix.cpp \
457 r3/posix/filelock-posix.cpp \
458 r3/posix/fs-posix.cpp \
459 r3/posix/ldrNative-posix.cpp \
460 r3/posix/path-posix.cpp \
461 r3/posix/process-posix.cpp \
462 r3/posix/rand-posix.cpp \
463 r3/posix/RTMpGetCount-posix.cpp \
464 r3/posix/RTTimeNow-posix.cpp \
465 r3/posix/semevent-posix.cpp \
466 r3/posix/semeventmulti-posix.cpp \
467 r3/posix/semmutex-posix.cpp \
468 r3/posix/semrw-posix.cpp \
469 r3/posix/thread-posix.cpp \
470 r3/posix/time-posix.cpp \
471 r3/posix/timelocal-posix.cpp \
472 r3/posix/timer-posix.cpp \
473 r3/posix/tls-posix.cpp \
474 r3/posix/utf8-posix.cpp
475
476RuntimeR3_SOURCES.solaris = \
477 generic/pathhost-generic.cpp \
478 generic/RTDirQueryInfo-generic.cpp \
479 generic/RTDirSetTimes-generic.cpp \
480 generic/RTFileMove-generic.cpp \
481 generic/RTLogWriteDebugger-generic.cpp \
482 generic/RTTimeLocalNow-generic.cpp \
483 generic/RTTimerCreate-generic.cpp \
484 generic/RTUuidCreate-generic.cpp \
485 generic/sched-generic.cpp \
486 generic/utf16locale-generic.cpp \
487 generic/uuid-generic.cpp \
488 r3/posix/dir-posix.cpp \
489 r3/posix/env-posix.cpp \
490 r3/posix/fileio-posix.cpp \
491 r3/posix/filelock-posix.cpp \
492 r3/posix/fs-posix.cpp \
493 r3/posix/ldrNative-posix.cpp \
494 r3/posix/path-posix.cpp \
495 r3/posix/process-posix.cpp \
496 r3/posix/rand-posix.cpp \
497 r3/posix/RTTimeNow-posix.cpp \
498 r3/posix/semevent-posix.cpp \
499 r3/posix/semeventmulti-posix.cpp \
500 r3/posix/semmutex-posix.cpp \
501 r3/posix/semrw-posix.cpp \
502 r3/posix/thread-posix.cpp \
503 r3/posix/time-posix.cpp \
504 r3/posix/timelocal-posix.cpp \
505 r3/posix/timer-posix.cpp \
506 r3/posix/tls-posix.cpp \
507 r3/posix/utf8-posix.cpp \
508 r3/solaris/alloc-solaris.cpp \
509 r3/solaris/mp-solaris.cpp
510
511## PORTME: Porters add their selection of platform specific files for Ring-3 here.
512
513
514#
515# L4 RuntimeR3 subtarget since L4 headers won't work with VBOXR3.
516#
517RuntimeR3L4_TEMPLATE = VBOXR3NP
518RuntimeR3L4_DEFS = IN_RT_R3 IN_SUP_R3 LDR_WITH_NATIVE LDR_WITH_ELF LDR_WITH_PE
519ifneq ($(KBUILD_TARGET_ARCH),amd64)
520RuntimeR3L4_DEFS += __PIC__
521endif
522RuntimeR3L4_INCS = \
523 include \
524 $(L4_INCDIR)
525
526RuntimeR3L4_SOURCES = \
527 generic/fs-stubs-generic.cpp \
528 generic/pathhost-generic.cpp \
529 generic/RTDirQueryInfo-generic.cpp \
530 generic/RTDirSetTimes-generic.cpp \
531 generic/RTFileMove-generic.cpp \
532 generic/RTLogWriteDebugger-generic.cpp \
533 generic/RTTimeLocalNow-generic.cpp \
534 generic/RTUuidCreate-generic.cpp \
535 generic/sched-generic.cpp \
536 generic/semnoint-generic.cpp \
537 generic/semsrw-generic.cpp \
538 generic/utf16locale-generic.cpp \
539 generic/uuid-generic.cpp \
540 l4/l4-errno.cpp \
541 l4/process-l4env.cpp \
542 l4/sems-l4env.cpp \
543 l4/thread-l4env.cpp \
544 l4/timer-l4env.cpp \
545 l4/utf8-l4env.cpp \
546 r3/posix/alloc-posix.cpp \
547 r3/posix/dir-posix.cpp \
548 r3/posix/env-posix.cpp \
549 r3/posix/fileio-posix.cpp \
550 r3/posix/filelock-posix.cpp \
551 r3/posix/ldrNative-posix.cpp \
552 r3/posix/path-posix.cpp \
553 r3/posix/rand-posix.cpp \
554 r3/posix/RTTimeNow-posix.cpp \
555 r3/posix/time-posix.cpp \
556 r3/posix/timelocal-posix.cpp
557
558
559#
560# RuntimeGuestR3 - Guest Additions Runtime (static).
561# (The KBUILD_HOST inheritance here is for l4 cross building the linux
562# additions, while .x86 is for cross building x86 while targeting amd64.)
563#
564RuntimeGuestR3_TEMPLATE := VBOXGUESTR3LIB
565## @todo change this to EXTEND the RuntimeR3 target.
566RuntimeGuestR3_SDKS.win := $(RuntimeR3_SDKS.win)
567RuntimeGuestR3_DEFS := $(filter-out RTCRITSECT_STRICT, $(RuntimeR3_DEFS))
568RuntimeGuestR3_DEFS.$(KBUILD_TARGET) := $(RuntimeR3_DEFS.$(KBUILD_TARGET))
569RuntimeGuestR3_DEFS.$(KBUILD_HOST) := $(RuntimeR3_DEFS.$(KBUILD_HOST))
570RuntimeGuestR3_INCS := $(RuntimeR3_INCS)
571RuntimeGuestR3_INCS.$(KBUILD_TARGET) := $(RuntimeR3_INCS.$(KBUILD_TARGET))
572RuntimeGuestR3_INCS.$(KBUILD_HOST) := $(RuntimeR3_INCS.$(KBUILD_HOST))
573RuntimeGuestR3_SOURCES := $(filter-out \
574 common/time/timesupref.cpp \
575 common/time/timesupA.asm \
576 common/time/timesup.cpp \
577 generic/RTLogWriteUser-generic.cpp \
578 , $(RuntimeR3_SOURCES))
579RuntimeGuestR3_SOURCES += \
580 common/time/timesysalias.cpp \
581 VBox/logbackdoor.cpp
582RuntimeGuestR3_SOURCES.$(KBUILD_TARGET) := $(RuntimeR3_SOURCES.$(KBUILD_TARGET))
583RuntimeGuestR3_SOURCES.$(KBUILD_HOST) := $(RuntimeR3_SOURCES.$(KBUILD_HOST))
584RuntimeGuestR3_SOURCES.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH) := $(RuntimeR3_SOURCES.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH))
585RuntimeGuestR3_SOURCES.$(KBUILD_HOST).$(KBUILD_TARGET_ARCH) := $(RuntimeR3_SOURCES.$(KBUILD_HOST).$(KBUILD_TARGET_ARCH))
586
587
588#
589# RuntimeGuestR3Mini - Minimal Guest Additions Runtime which does not require
590# initialization and can be linked into an .so. Intended
591# for X11 drivers, GRADD and similar.
592#
593RuntimeGuestR3Mini_TEMPLATE := VBOXGUESTR3DLL
594## @todo change this to EXTEND the RuntimeGuestR3 target.
595RuntimeGuestR3Mini_INST := $(INST_ADDITIONS_LIB)
596RuntimeGuestR3Mini_SDKS.win := $(RuntimeR3_SDKS.win)
597RuntimeGuestR3Mini_DEFS := $(filter-out RTCRITSECT_STRICT, $(RuntimeR3_DEFS)) RT_MINI
598RuntimeGuestR3Mini_DEFS.$(KBUILD_TARGET) := $(RuntimeR3_DEFS.$(KBUILD_TARGET))
599RuntimeGuestR3Mini_DEFS.$(KBUILD_HOST) := $(RuntimeR3_DEFS.$(KBUILD_HOST))
600RuntimeGuestR3Mini_INCS := $(RuntimeR3_INCS)
601RuntimeGuestR3Mini_INCS.$(KBUILD_TARGET) := $(RuntimeR3_INCS.$(KBUILD_TARGET))
602RuntimeGuestR3Mini_INCS.$(KBUILD_HOST) := $(RuntimeR3_INCS.$(KBUILD_HOST))
603RuntimeGuestR3Mini_SOURCES = \
604 common/err/errmsg.cpp \
605 common/err/errmsgxpcom.cpp \
606 common/err/RTErrConvertFromErrno.cpp \
607 common/log/logformat.cpp \
608 common/misc/assert.cpp \
609 common/misc/sanity-c.c \
610 common/misc/sanity-cpp.cpp \
611 common/string/strformat.cpp \
612 common/string/strformatrt.cpp \
613 common/string/strformattype.cpp \
614 common/string/string.cpp \
615 common/string/strprintf.cpp \
616 common/string/strtonum.cpp \
617 common/string/unidata.cpp \
618 common/string/utf-8.cpp \
619 common/string/utf-16.cpp \
620 generic/pathhost-generic.cpp \
621 generic/RTAssertDoBreakpoint-generic.cpp \
622 r3/alloc.cpp \
623 r3/fileio.cpp \
624 r3/fs.cpp \
625 r3/path.cpp
626RuntimeGuestR3Mini_SOURCES.linux = \
627 r3/posix/fileio-posix.cpp \
628 r3/posix/path-posix.cpp \
629 r3/posix/utf8-posix.cpp
630RuntimeGuestR3Mini_SOURCES.solaris = \
631 r3/posix/fileio-posix.cpp \
632 r3/posix/path-posix.cpp \
633 r3/posix/utf8-posix.cpp
634RuntimeGuestR3Mini_SOURCES.freebsd = \
635 r3/posix/fileio-posix.cpp \
636 r3/posix/path-posix.cpp \
637 r3/posix/utf8-posix.cpp
638# VBox specific stuff.
639RuntimeGuestR3Mini_SOURCES += \
640 VBox/logbackdoor.cpp \
641 VBox/logbackdoor-redirect.cpp \
642 VBox/strformat-vbox.cpp
643
644
645#
646# RuntimeLnxHostR3 Linux host program runtime
647# (Only used when building L4.)
648#
649RuntimeLnxHostR3_TEMPLATE = VBOXLNXHOSTR3LIB
650RuntimeLnxHostR3_DEFS = IN_RT_R3 IN_SUP_R3 RT_WITH_VBOX RT_NO_GIP
651RuntimeLnxHostR3_SOURCES = \
652 $(RuntimeR3_SOURCES.linux.$(KBUILD_TARGET_ARCH)) \
653 $(RuntimeR3_SOURCES.linux) \
654 $(RuntimeR3_SOURCES)
655RuntimeLnxHostR3_INCS = \
656 $(RuntimeR3_INCS.linux.$(KBUILD_TARGET_ARCH)) \
657 $(RuntimeR3_INCS.linux) \
658 $(RuntimeR3_INCS)
659
660
661#
662# VBoxRT - Shared Object / DLL version.
663#
664VBoxRT_TEMPLATE = VBOXR3
665VBoxRT_SDKS.win = WINPSDK W2K3DDK VBOX_NTDLL
666ifeq ($(KBUILD_TARGET),darwin)
667VBoxRT_INST = $(INST_DLL) $(INST_TESTCASE)
668endif
669VBoxRT_DEFS = $(RuntimeR3_DEFS) IN_SUP_R3 IN_SUP_R3
670VBoxRT_DEFS.$(KBUILD_TYPE) = $(RuntimeR3_DEFS.$(KBUILD_TYPE))
671VBoxRT_SOURCES = \
672 VBox/VBoxRTDeps.cpp \
673 $(RuntimeR3_SOURCES)
674VBoxRT_SOURCES.$(KBUILD_TARGET) = $(RuntimeR3_SOURCES.$(KBUILD_TARGET))
675VBoxRT_SOURCES.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH) = $(RuntimeR3_SOURCES.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH))
676VBoxRT_SOURCES.win += r3/win/dllmain-win.cpp
677VBoxRT_SOURCES.win.x86 += r3/win/VBoxRT-win32.def
678VBoxRT_SOURCES.win.amd64 += r3/win/VBoxRT-win64.def
679VBoxRT_INCS = $(RuntimeR3_INCS)
680VBoxRT_INCS.$(KBUILD_TARGET) = $(RuntimeR3_INCS.$(KBUILD_TARGET))
681VBoxRT_INCS.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH) = $(RuntimeR3_INCS.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH))
682VBoxRT_LIBS = \
683 $(PATH_LIB)/SUPR3$(VBOX_SUFF_LIB) \
684 $(PATH_LIB)/VBox-liblzf$(VBOX_SUFF_LIB)
685ifdef IPRT_WITH_KSTUFF
686 VBoxRT_LIBS += \
687 $(PATH_LIB)/VBox-kStuff$(VBOX_SUFF_LIB)
688endif
689VBoxRT_LIBS.darwin = \
690 iconv
691VBoxRT_LIBS.freebsd = \
692 iconv
693VBoxRT_LIBS.solaris = \
694 kstat
695VBoxRT_LIBPATH.freebsd = \
696 /usr/local/lib
697VBoxRT_LDFLAGS.darwin = -framework IOKit -install_name @executable_path/VBoxRT.dylib
698ifdef VBOX_USE_VCC80
699VBoxRT_LDFLAGS.win = /MANIFEST
700endif
701VBoxRT_LDFLAGS.l4 = \
702 -Wl,-whole-archive \
703 $(PATH_LIB)/RuntimeR3L4$(VBOX_SUFF_LIB) \
704 -Wl,-no-whole-archive
705ifeq ($(KBUILD_TARGET),l4)
706VBoxRT_LIBS += \
707 $(L4_LIBDIR)/libl4sys.a \
708 $(L4_LIBDIR)/libl4sys.p.a
709endif
710VBoxRT_LIBS.l4 = \
711 $(PATH_LIB)/RuntimeR3L4$(VBOX_SUFF_LIB)
712
713
714#
715# RuntimeR3NoCRTGCC - CRT replacement lib for VBoxREM.
716# This is used together with VBoxRT.
717#
718RuntimeR3NoCRTGCC_TEMPLATE = VBOXNOCRTGCC
719RuntimeR3NoCRTGCC_LIBSUFF = $(VBOX_SUFF_LIB)
720RuntimeR3NoCRTGCC_INCS = include
721RuntimeR3NoCRTGCC_SOURCES = \
722 common/misc/sanity-cpp.cpp \
723 common/misc/sanity-c.c \
724 \
725 common/math/ceill.asm \
726 common/math/cosl.asm \
727 common/math/fabs.asm \
728 common/math/fabsf.asm \
729 common/math/fabsl.asm \
730 common/math/floor.asm \
731 common/math/floorf.asm \
732 common/math/floorl.asm \
733 common/math/ldexpl.asm \
734 common/math/llrint.asm \
735 common/math/llrintf.asm \
736 common/math/llrintl.asm \
737 common/math/logl.asm \
738 common/math/lrint.asm \
739 common/math/lrintf.asm \
740 common/math/lrintl.asm \
741 common/math/remainder.asm \
742 common/math/remainderf.asm \
743 common/math/remainderl.asm \
744 common/math/sinl.asm \
745 common/math/tanl.asm \
746 common/math/trunc.asm \
747 common/math/truncf.asm \
748 common/math/truncl.asm \
749 \
750 common/misc/setjmp.asm \
751 \
752 common/string/memchr.asm \
753 common/string/memchr_alias.c \
754 common/string/memcmp.asm \
755 common/string/memcmp_alias.c \
756 common/string/memcpy.asm \
757 common/string/memcpy_alias.c \
758 common/string/mempcpy.asm \
759 common/string/memmove.asm \
760 common/string/memmove_alias.c \
761 common/string/memset.asm \
762 common/string/memset_alias.c \
763 common/string/strchr.asm \
764 common/string/strchr_alias.c \
765 common/string/strcmp.asm \
766 common/string/strcmp_alias.c \
767 common/string/strlen.asm \
768 common/string/strlen_alias.c
769
770RuntimeR3NoCRTGCC_SOURCES.x86 = \
771 common/math/x86/fenv-x86.c \
772 common/math/gcc/adddi3.c \
773 common/math/gcc/anddi3.c \
774 common/math/gcc/ashldi3.c \
775 common/math/gcc/ashrdi3.c \
776 common/math/gcc/cmpdi2.c \
777 common/math/gcc/divdi3.c \
778 common/math/gcc/iordi3.c \
779 common/math/gcc/lshldi3.c \
780 common/math/gcc/lshrdi3.c \
781 common/math/gcc/moddi3.c \
782 common/math/gcc/muldi3.c \
783 common/math/gcc/negdi2.c \
784 common/math/gcc/notdi2.c \
785 common/math/gcc/qdivrem.c \
786 common/math/gcc/subdi3.c \
787 common/math/gcc/ucmpdi2.c \
788 common/math/gcc/udivdi3.c \
789 common/math/gcc/umoddi3.c \
790 common/math/gcc/xordi3.c
791
792
793## @todo stop using the old memcpy.c and memset.c code.
794
795#
796# RuntimeR0 - Ring0 library for VMMR0.
797#
798RuntimeR0_TEMPLATE = VBOXR0
799RuntimeR0_DEFS = IN_RT_R0 RT_WITH_VBOX RT_WITHOUT_NOCRT_WRAPPERS
800RuntimeR0_INCS = include
801RuntimeR0_SOURCES = \
802 common/checksum/crc32.cpp \
803 common/checksum/crc64.cpp \
804 common/checksum/md5.cpp \
805 common/checksum/ipv4.cpp \
806 common/log/logcom.cpp \
807 common/log/logformat.cpp \
808 common/misc/assert.cpp \
809 common/misc/handletable.cpp \
810 common/misc/handletablectx.cpp \
811 common/misc/handletablesimple.cpp \
812 common/misc/sanity-c.c \
813 common/misc/sanity-cpp.cpp \
814 common/string/memchr.cpp \
815 common/string/memcmp.cpp \
816 common/string/memcpy.cpp \
817 common/string/memmove.asm \
818 common/string/memset.cpp \
819 common/string/strcmp.asm \
820 common/string/strcpy.cpp \
821 common/string/strformat.cpp \
822 common/string/strformatrt.cpp \
823 common/string/strformattype.cpp \
824 common/string/strlen.asm \
825 common/string/strncmp.cpp \
826 common/string/strpbrk.cpp \
827 common/string/strprintf.cpp \
828 common/table/avlgcptr.cpp \
829 common/table/avlhcphys.cpp \
830 common/table/avllu32.cpp \
831 common/table/avlogcphys.cpp \
832 common/table/avlogcptr.cpp \
833 common/table/avlohcphys.cpp \
834 common/table/avloioport.cpp \
835 common/table/avlpv.cpp \
836 common/table/avlrogcphys.cpp \
837 common/table/avlrogcptr.cpp \
838 common/table/avlroioport.cpp \
839 common/table/avlroogcptr.cpp \
840 common/table/avlu32.cpp \
841 common/time/timesup.cpp \
842 generic/RTAssertDoBreakpoint-generic.cpp \
843 VBox/strformat-vbox.cpp
844
845#if1of ($(KBUILD_TARGET_ARCH),amd64 x86)
846# RuntimeR0_SOURCES += common/time/timesupA.asm
847#else
848 RuntimeR0_SOURCES += common/time/timesupref.cpp
849#endif
850
851RuntimeR0_SOURCES.win.amd64 = $(RuntimeWin64ASM_SOURCES)
852RuntimeR0_SOURCES.win.x86 = $(RuntimeWin32ASM_SOURCES)
853
854RuntimeR0_SOURCES.os2 = \
855 os2/RTErrConvertFromOS2.cpp \
856 os2/sys0.asm
857
858ifeq ($(filter-out darwin solaris freebsd,$(KBUILD_TARGET)),)
859RuntimeR0_SOURCES += \
860 common/math/gcc/adddi3.c \
861 common/math/gcc/anddi3.c \
862 common/math/gcc/ashldi3.c \
863 common/math/gcc/ashrdi3.c \
864 common/math/gcc/cmpdi2.c \
865 common/math/gcc/divdi3.c \
866 common/math/gcc/iordi3.c \
867 common/math/gcc/lshldi3.c \
868 common/math/gcc/lshrdi3.c \
869 common/math/gcc/moddi3.c \
870 common/math/gcc/muldi3.c \
871 common/math/gcc/negdi2.c \
872 common/math/gcc/notdi2.c \
873 common/math/gcc/qdivrem.c \
874 common/math/gcc/subdi3.c \
875 common/math/gcc/ucmpdi2.c \
876 common/math/gcc/udivdi3.c \
877 common/math/gcc/umoddi3.c \
878 common/math/gcc/xordi3.c
879endif
880
881
882common/string/memchr.cpp_CXXFLAGS.win = -Oi-
883common/string/memcmp.cpp_CXXFLAGS.win = -Oi-
884common/string/memcpy.cpp_CXXFLAGS.win = -Oi-
885common/string/memset.cpp_CXXFLAGS.win = -Oi-
886common/string/strcpy.cpp_CXXFLAGS.win = -Oi-
887common/string/strlen.cpp_CXXFLAGS.win = -Oi-
888
889#
890# RuntimeR0Drv - Ring0 library for host drivers.
891#
892RuntimeR0Drv_TEMPLATE = VBOXR0DRV
893RuntimeR0Drv_SDKS.win = W2K3DDK WINPSDKINCS
894RuntimeR0Drv_INCS := $(PATH_SUB_CURRENT) include
895RuntimeR0Drv_DEFS = IN_RT_R0 RT_WITH_VBOX RT_WITHOUT_NOCRT_WRAPPERS
896RuntimeR0Drv_DEFS.win = IN_SUP_R0
897RuntimeR0Drv_DEFS.linux = MODULE KBUILD_MODNAME=KBUILD_STR\(vboxdrv\) KBUILD_BASENAME=KBUILD_STR\(vboxdrv\) IN_SUP_R0 # why is IN_SUP_R0 here? because!
898
899RuntimeR0Drv_INCS.linux = \
900 r0drv/linux
901ifdef VBOX_WITH_SOLARIS_VBI
902 RuntimeR0Drv_INCS.solaris = \
903 r0drv/solaris/vbi/i86pc
904endif
905
906RuntimeR0Drv_SOURCES = \
907 common/checksum/crc32.cpp \
908 common/checksum/crc64.cpp \
909 common/checksum/md5.cpp \
910 common/checksum/ipv4.cpp \
911 common/log/log.cpp \
912 common/log/logcom.cpp \
913 common/log/logformat.cpp \
914 common/misc/assert.cpp \
915 common/misc/handletable.cpp \
916 common/misc/handletablectx.cpp \
917 common/misc/handletablesimple.cpp \
918 common/misc/sanity-c.c \
919 common/misc/sanity-cpp.cpp \
920 common/string/strformat.cpp \
921 common/string/strformatrt.cpp \
922 common/string/strformattype.cpp \
923 common/string/strprintf.cpp \
924 common/string/strtonum.cpp \
925 common/table/avlpv.cpp \
926 generic/RTLogWriteStdErr-stub-generic.cpp \
927 generic/RTLogWriteUser-generic.cpp \
928 generic/uuid-generic.cpp \
929 r0drv/alloc-r0drv.cpp \
930 r0drv/initterm-r0drv.cpp \
931 VBox/log-vbox.cpp \
932 VBox/strformat-vbox.cpp
933
934RuntimeR0Drv_SOURCES.linux = \
935 common/alloc/heapsimple.cpp \
936 common/string/strpbrk.cpp \
937 common/err/RTErrConvertToErrno.cpp \
938 generic/RTAssertDoBreakpoint-generic.cpp \
939 generic/RTLogWriteStdOut-stub-generic.cpp \
940 r0drv/linux/alloc-r0drv-linux.c \
941 r0drv/linux/initterm-r0drv-linux.c \
942 r0drv/linux/memobj-r0drv-linux.c \
943 r0drv/linux/mp-r0drv-linux.c \
944 r0drv/linux/mpnotification-r0drv-linux.c \
945 r0drv/linux/process-r0drv-linux.c \
946 r0drv/linux/RTLogWriteDebugger-r0drv-linux.c \
947 r0drv/linux/semevent-r0drv-linux.c \
948 r0drv/linux/semeventmulti-r0drv-linux.c \
949 r0drv/linux/semfastmutex-r0drv-linux.c \
950 r0drv/linux/spinlock-r0drv-linux.c \
951 r0drv/linux/thread-r0drv-linux.c \
952 r0drv/linux/time-r0drv-linux.c \
953 r0drv/linux/timer-r0drv-linux.c \
954 r0drv/memobj-r0drv.cpp \
955 r0drv/mpnotification-r0drv.c
956## @todo thread2-r0drv-linux.c and assert-r0drv-linux.c
957
958RuntimeR0Drv_SOURCES.win = \
959 common/misc/thread.cpp \
960 common/string/memcmp.asm \
961 common/string/memchr.asm \
962 common/string/memcpy.asm \
963 common/string/memset.asm \
964 common/string/memmove.asm \
965 common/string/strlen.asm \
966 common/string/strncmp.cpp \
967 common/string/strpbrk.cpp \
968 generic/RTAssertDoBreakpoint-generic.cpp \
969 generic/RTLogWriteStdOut-stub-generic.cpp \
970 nt/RTErrConvertFromNtStatus.cpp \
971 r0drv/memobj-r0drv.cpp \
972 r0drv/mpnotification-r0drv.c \
973 r0drv/nt/alloc-r0drv-nt.cpp \
974 r0drv/nt/initterm-r0drv-nt.cpp \
975 r0drv/nt/memobj-r0drv-nt.cpp \
976 r0drv/nt/mp-r0drv-nt.cpp \
977 r0drv/nt/mpnotification-r0drv-nt.cpp \
978 r0drv/nt/process-r0drv-nt.cpp \
979 r0drv/nt/RTLogWriteDebugger-r0drv-nt.cpp \
980 r0drv/nt/semevent-r0drv-nt.cpp \
981 r0drv/nt/semeventmulti-r0drv-nt.cpp \
982 r0drv/nt/semfastmutex-r0drv-nt.cpp \
983 r0drv/nt/semmutex-r0drv-nt.cpp \
984 r0drv/nt/spinlock-r0drv-nt.cpp \
985 r0drv/nt/thread-r0drv-nt.cpp \
986 r0drv/nt/thread2-r0drv-nt.cpp \
987 r0drv/nt/time-r0drv-nt.cpp \
988 r0drv/nt/timer-r0drv-nt.cpp
989## @todo assert-r0drv-nt.cpp
990
991RuntimeR0Drv_SOURCES.win.amd64 = $(RuntimeWin64ASM_SOURCES)
992RuntimeR0Drv_SOURCES.win.x86 = $(RuntimeWin32ASM_SOURCES)
993
994RuntimeR0Drv_SOURCES.darwin = \
995 common/err/RTErrConvertFromErrno.cpp \
996 common/misc/thread.cpp \
997 common/string/memchr.asm \
998 common/string/strpbrk.cpp \
999 darwin/RTErrConvertFromDarwin.cpp \
1000 darwin/RTErrConvertFromDarwinIO.cpp \
1001 darwin/RTErrConvertFromDarwinKern.cpp \
1002 generic/RTAssertDoBreakpoint-generic.cpp \
1003 generic/RTMpCpuId-generic.cpp \
1004 generic/RTMpCpuIdFromSetIndex-generic.cpp \
1005 generic/RTMpCpuIdToSetIndex-generic.cpp \
1006 generic/RTMpIsCpuPossible-generic.cpp \
1007 generic/RTMpGetCount-generic.cpp \
1008 generic/RTMpGetMaxCpuId-generic.cpp \
1009 generic/RTMpGetOnlineCount-generic.cpp \
1010 generic/RTMpGetOnlineSet-generic.cpp \
1011 generic/RTMpGetSet-generic.cpp \
1012 generic/RTMpIsCpuOnline-generic.cpp \
1013 generic/RTTimerCreate-generic.cpp \
1014 generic/timer-generic.cpp \
1015 r0drv/generic/RTMpOn-r0drv-generic.cpp \
1016 r0drv/generic/mpnotification-r0drv-generic.cpp \
1017 r0drv/darwin/alloc-r0drv-darwin.cpp \
1018 r0drv/darwin/assert-r0drv-darwin.cpp \
1019 r0drv/darwin/initterm-r0drv-darwin.cpp \
1020 r0drv/darwin/memobj-r0drv-darwin.cpp \
1021 r0drv/darwin/process-r0drv-darwin.cpp \
1022 r0drv/darwin/RTLogWriteDebugger-r0drv-darwin.cpp \
1023 r0drv/darwin/RTLogWriteStdOut-r0drv-darwin.cpp \
1024 r0drv/darwin/semaphore-r0drv-darwin.cpp \
1025 r0drv/darwin/spinlock-r0drv-darwin.cpp \
1026 r0drv/darwin/thread-r0drv-darwin.cpp \
1027 r0drv/darwin/thread2-r0drv-darwin.cpp \
1028 r0drv/darwin/time-r0drv-darwin.cpp \
1029 r0drv/memobj-r0drv.cpp
1030
1031RuntimeR0Drv_SOURCES.os2 = \
1032 common/string/memchr.asm \
1033 common/string/memcmp.asm \
1034 common/string/memcpy.asm \
1035 common/string/mempcpy.asm \
1036 common/string/memmove.asm \
1037 common/string/memset.asm \
1038 common/string/strchr.asm \
1039 common/string/strcmp.asm \
1040 common/string/strlen.asm \
1041 \
1042 common/string/strcpy.cpp \
1043 common/string/strncmp.cpp \
1044 common/string/strpbrk.cpp \
1045 \
1046 common/misc/thread.cpp \
1047 generic/RTLogWriteDebugger-generic.cpp \
1048 generic/RTLogWriteStdOut-stub-generic.cpp \
1049 generic/RTMpCpuId-generic.cpp \
1050 generic/RTMpCpuIdFromSetIndex-generic.cpp \
1051 generic/RTMpCpuIdToSetIndex-generic.cpp \
1052 generic/RTMpIsCpuPossible-generic.cpp \
1053 generic/RTMpGetCount-generic.cpp \
1054 generic/RTMpGetMaxCpuId-generic.cpp \
1055 generic/RTMpGetOnlineCount-generic.cpp \
1056 generic/RTMpGetOnlineSet-generic.cpp \
1057 generic/RTMpGetSet-generic.cpp \
1058 generic/RTMpIsCpuOnline-generic.cpp \
1059 generic/RTTimerCreate-generic.cpp \
1060 os2/RTErrConvertFromOS2.cpp \
1061 os2/sys0.asm \
1062 r0drv/memobj-r0drv.cpp \
1063 r0drv/generic/RTMpOn-r0drv-generic.cpp \
1064 r0drv/generic/mpnotification-r0drv-generic.cpp \
1065 r0drv/os2/alloc-r0drv-os2.cpp \
1066 r0drv/os2/assert-r0drv-os2.cpp \
1067 r0drv/os2/assertA-r0drv-os2.asm \
1068 r0drv/os2/initterm-r0drv-os2.cpp \
1069 r0drv/os2/memobj-r0drv-os2.cpp \
1070 r0drv/os2/os2imports.imp \
1071 r0drv/os2/process-r0drv-os2.cpp \
1072 r0drv/os2/RTAssertDoBreakpoint-r0drv-os2.asm \
1073 r0drv/os2/RTR0Os2DHQueryDOSVar.asm \
1074 r0drv/os2/RTR0Os2DHVMGlobalToProcess.asm \
1075 r0drv/os2/semevent-r0drv-os2.cpp \
1076 r0drv/os2/semeventmulti-r0drv-os2.cpp \
1077 r0drv/os2/semfastmutex-r0drv-os2.cpp \
1078 r0drv/os2/spinlock-r0drv-os2.cpp \
1079 r0drv/os2/thread-r0drv-os2.cpp \
1080 r0drv/os2/thread2-r0drv-os2.cpp \
1081 r0drv/os2/time-r0drv-os2.cpp \
1082 r0drv/os2/timer-r0drv-os2.cpp \
1083 r0drv/os2/timerA-r0drv-os2.asm
1084
1085RuntimeR0Drv_SOURCES.freebsd = \
1086 common/err/RTErrConvertFromErrno.cpp \
1087 common/err/RTErrConvertToErrno.cpp \
1088 common/misc/thread.cpp \
1089 common/string/memchr.asm \
1090 common/string/memmove.asm \
1091 common/string/strpbrk.cpp \
1092 common/string/memcmp.asm \
1093 common/string/strchr.asm \
1094 generic/RTAssertDoBreakpoint-generic.cpp \
1095 generic/RTLogWriteDebugger-generic.cpp \
1096 generic/RTLogWriteStdOut-stub-generic.cpp \
1097 generic/RTMpCpuId-generic.cpp \
1098 generic/RTMpCpuIdFromSetIndex-generic.cpp \
1099 generic/RTMpCpuIdToSetIndex-generic.cpp \
1100 generic/RTMpIsCpuPossible-generic.cpp \
1101 generic/RTMpGetCount-generic.cpp \
1102 generic/RTMpGetMaxCpuId-generic.cpp \
1103 generic/RTMpGetOnlineCount-generic.cpp \
1104 generic/RTMpGetOnlineSet-generic.cpp \
1105 generic/RTMpGetSet-generic.cpp \
1106 generic/RTMpIsCpuOnline-generic.cpp \
1107 generic/RTTimerCreate-generic.cpp \
1108 r0drv/generic/RTMpOn-r0drv-generic.cpp \
1109 r0drv/generic/mpnotification-r0drv-generic.cpp \
1110 r0drv/freebsd/alloc-r0drv-freebsd.c \
1111 r0drv/freebsd/assert-r0drv-freebsd.c \
1112 r0drv/freebsd/initterm-r0drv-freebsd.c \
1113 r0drv/freebsd/memobj-r0drv-freebsd.c \
1114 r0drv/freebsd/process-r0drv-freebsd.c \
1115 r0drv/freebsd/semevent-r0drv-freebsd.c \
1116 r0drv/freebsd/semeventmulti-r0drv-freebsd.c \
1117 r0drv/freebsd/semfastmutex-r0drv-freebsd.c \
1118 r0drv/freebsd/spinlock-r0drv-freebsd.c \
1119 r0drv/freebsd/thread-r0drv-freebsd.c \
1120 r0drv/freebsd/thread2-r0drv-freebsd.c \
1121 r0drv/freebsd/time-r0drv-freebsd.c \
1122 r0drv/freebsd/timer-r0drv-freebsd.c \
1123 r0drv/memobj-r0drv.cpp
1124
1125RuntimeR0Drv_SOURCES.solaris = \
1126 common/err/RTErrConvertFromErrno.cpp \
1127 common/misc/thread.cpp \
1128 common/string/memchr.asm \
1129 generic/RTAssertDoBreakpoint-generic.cpp \
1130 generic/RTLogWriteStdOut-stub-generic.cpp \
1131 generic/RTTimerCreate-generic.cpp \
1132 r0drv/memobj-r0drv.cpp \
1133 r0drv/mpnotification-r0drv.c
1134
1135ifdef VBOX_WITH_SOLARIS_VBI
1136 RuntimeR0Drv_SOURCES.solaris += \
1137 r0drv/solaris/vbi/mpnotification-r0drv-solaris.c \
1138 r0drv/solaris/vbi/alloc-r0drv-solaris.c \
1139 r0drv/solaris/vbi/assert-r0drv-solaris.c \
1140 r0drv/solaris/vbi/initterm-r0drv-solaris.c \
1141 r0drv/solaris/vbi/memobj-r0drv-solaris.c \
1142 r0drv/solaris/vbi/mp-r0drv-solaris.c \
1143 r0drv/solaris/vbi/process-r0drv-solaris.c \
1144 r0drv/solaris/vbi/RTLogWriteDebugger-r0drv-solaris.c \
1145 r0drv/solaris/vbi/semevent-r0drv-solaris.c \
1146 r0drv/solaris/vbi/semeventmulti-r0drv-solaris.c \
1147 r0drv/solaris/vbi/semfastmutex-r0drv-solaris.c \
1148 r0drv/solaris/vbi/spinlock-r0drv-solaris.c \
1149 r0drv/solaris/vbi/thread-r0drv-solaris.c \
1150 r0drv/solaris/vbi/thread2-r0drv-solaris.c \
1151 r0drv/solaris/vbi/time-r0drv-solaris.c \
1152 r0drv/solaris/vbi/timer-r0drv-solaris.c
1153else # !VBOX_WITH_SOLARIS_VBI
1154 RuntimeR0Drv_SOURCES.solaris += \
1155 r0drv/solaris/mpnotification-r0drv-solaris.c \
1156 r0drv/solaris/alloc-r0drv-solaris.c \
1157 r0drv/solaris/assert-r0drv-solaris.c \
1158 r0drv/solaris/initterm-r0drv-solaris.c \
1159 r0drv/solaris/memobj-r0drv-solaris.c \
1160 r0drv/solaris/process-r0drv-solaris.c \
1161 r0drv/solaris/RTLogWriteDebugger-r0drv-solaris.c \
1162 r0drv/solaris/semevent-r0drv-solaris.c \
1163 r0drv/solaris/semeventmulti-r0drv-solaris.c \
1164 r0drv/solaris/semfastmutex-r0drv-solaris.c \
1165 r0drv/solaris/spinlock-r0drv-solaris.c \
1166 r0drv/solaris/thread-r0drv-solaris.c \
1167 r0drv/solaris/thread2-r0drv-solaris.c \
1168 r0drv/solaris/time-r0drv-solaris.c \
1169 r0drv/solaris/timer-r0drv-solaris.c
1170 # Don't use mp-r0drv-solaris.c because it will cause crashes due to incorrect memobj-r0drv-solaris.c code.
1171 ifeq (0,0)
1172 # Stub it. ## @todo limit the stubbing to RTMpOn*.
1173 RuntimeR0Drv_SOURCES.solaris += \
1174 generic/RTMpCpuId-generic.cpp \
1175 generic/RTMpCpuIdFromSetIndex-generic.cpp \
1176 generic/RTMpCpuIdToSetIndex-generic.cpp \
1177 generic/RTMpIsCpuPossible-generic.cpp \
1178 generic/RTMpGetCount-generic.cpp \
1179 generic/RTMpGetMaxCpuId-generic.cpp \
1180 generic/RTMpGetOnlineCount-generic.cpp \
1181 generic/RTMpGetOnlineSet-generic.cpp \
1182 generic/RTMpGetSet-generic.cpp \
1183 generic/RTMpIsCpuOnline-generic.cpp \
1184 r0drv/generic/RTMpOn-r0drv-generic.cpp
1185 else
1186 # Use mp-r0drv-solaris.c.
1187 RuntimeR0Drv_SOURCES.solaris += \
1188 r0drv/solaris/mp-r0drv-solaris.c
1189# r0drv/solaris/mpnotification-r0drv-solaris.c
1190 endif
1191
1192endif # !VBOX_WITH_SOLARIS_VBI
1193
1194## PORTME: Porters create and add their selection of platform specific Ring-0 Driver files here.
1195
1196
1197#
1198# RuntimeGuestR0 - Guest driver runtime.
1199# This is almost the same as the RuntimeR0Drv, the main difference
1200# is in the backdoor logging and the lack of sup.h (which should be
1201# made irrelevant even for RuntimeR0Drv).
1202#
1203RuntimeGuestR0_TEMPLATE := VBOXGUESTR0LIB
1204RuntimeGuestR0_SOURCES := $(filter-out generic/RTLogWriteUser-generic.cpp, $(RuntimeR0Drv_SOURCES))
1205RuntimeGuestR0_SOURCES += VBox/logbackdoor.cpp
1206RuntimeGuestR0_EXTENDS = RuntimeR0Drv
1207
1208# HACK: no vbi for the solaris guest additions - yet.
1209RuntimeGuestR0_SOURCES.solaris = \
1210 common/err/RTErrConvertFromErrno.cpp \
1211 common/err/RTErrConvertToErrno.cpp \
1212 common/misc/thread.cpp \
1213 common/string/memchr.asm \
1214 generic/RTAssertDoBreakpoint-generic.cpp \
1215 generic/RTTimerCreate-generic.cpp \
1216 r0drv/memobj-r0drv.cpp \
1217 generic/RTMpCpuId-generic.cpp \
1218 generic/RTMpCpuIdFromSetIndex-generic.cpp \
1219 generic/RTMpCpuIdToSetIndex-generic.cpp \
1220 generic/RTMpIsCpuPossible-generic.cpp \
1221 generic/RTMpGetCount-generic.cpp \
1222 generic/RTMpGetMaxCpuId-generic.cpp \
1223 generic/RTMpGetOnlineCount-generic.cpp \
1224 generic/RTMpGetOnlineSet-generic.cpp \
1225 generic/RTMpGetSet-generic.cpp \
1226 generic/RTMpIsCpuOnline-generic.cpp \
1227 generic/RTLogWriteStdOut-stub-generic.cpp \
1228 r0drv/generic/RTMpOn-r0drv-generic.cpp \
1229 r0drv/generic/mpnotification-r0drv-generic.cpp \
1230 r0drv/solaris/alloc-r0drv-solaris.c \
1231 r0drv/solaris/assert-r0drv-solaris.c \
1232 r0drv/solaris/initterm-r0drv-solaris.c \
1233 r0drv/solaris/memobj-r0drv-solaris.c \
1234 r0drv/solaris/process-r0drv-solaris.c \
1235 r0drv/solaris/RTLogWriteDebugger-r0drv-solaris.c \
1236 r0drv/solaris/semevent-r0drv-solaris.c \
1237 r0drv/solaris/semeventmulti-r0drv-solaris.c \
1238 r0drv/solaris/semfastmutex-r0drv-solaris.c \
1239 r0drv/solaris/spinlock-r0drv-solaris.c \
1240 r0drv/solaris/thread-r0drv-solaris.c \
1241 r0drv/solaris/thread2-r0drv-solaris.c \
1242 r0drv/solaris/time-r0drv-solaris.c \
1243 r0drv/solaris/timer-r0drv-solaris.c
1244
1245#
1246# RuntimeGuestR0NT4 - Win32 NT4 guest driver runtime.
1247#
1248RuntimeGuestR0NT4_EXTENDS = RuntimeGuestR0
1249RuntimeGuestR0NT4_EXTENDS_BY = appending
1250RuntimeGuestR0NT4_DEFS = IPRT_TARGET_NT4
1251
1252
1253#
1254# RuntimeGC - Guest context library.
1255#
1256RuntimeGC_TEMPLATE = VBOXGC
1257RuntimeGC_DEFS = IN_RT_GC RT_WITH_VBOX RT_WITHOUT_NOCRT_WRAPPERS
1258RuntimeGC_INCS = include
1259RuntimeGC_SOURCES = \
1260 common/log/log.cpp \
1261 common/log/logcom.cpp \
1262 common/log/logformat.cpp \
1263 common/misc/assert.cpp \
1264 common/misc/sanity-c.c \
1265 common/misc/sanity-cpp.cpp \
1266 common/string/memchr.cpp \
1267 common/string/memcmp.cpp \
1268 common/string/memcpy.cpp \
1269 common/string/memset.cpp \
1270 common/string/memmove.asm \
1271 common/string/strcpy.cpp \
1272 common/string/strformat.cpp \
1273 common/string/strformatrt.cpp \
1274 common/string/strformattype.cpp \
1275 common/string/strlen.asm \
1276 common/string/strncmp.cpp \
1277 common/string/strpbrk.cpp \
1278 common/string/strprintf.cpp \
1279 common/table/avllu32.cpp \
1280 common/table/avlou32.cpp \
1281 common/table/avlogcphys.cpp \
1282 common/table/avlogcptr.cpp \
1283 common/table/avlohcphys.cpp \
1284 common/table/avloioport.cpp \
1285 common/table/avlrogcphys.cpp \
1286 common/table/avlrogcptr.cpp \
1287 common/table/avlroioport.cpp \
1288 common/table/avlroogcptr.cpp \
1289 common/table/avlu32.cpp \
1290 common/time/timeprog.cpp \
1291 common/time/timesup.cpp \
1292 gc/initterm-gc.cpp \
1293 generic/RTAssertDoBreakpoint-generic.cpp \
1294 VBox/strformat-vbox.cpp \
1295
1296#if1of ($(KBUILD_TARGET_ARCH),amd64 x86)
1297# RuntimeGC_SOURCES += common/time/timesupA.asm
1298#else
1299 RuntimeGC_SOURCES += common/time/timesupref.cpp
1300#endif
1301
1302RuntimeGC_SOURCES.win.x86 = $(RuntimeWin32ASM_SOURCES)
1303
1304ifeq ($(VBOX_LDR_FMT32),lx)
1305 RuntimeGC_SOURCES += os2/sys0.asm
1306endif
1307
1308if1of ($(KBUILD_TARGET), darwin solaris freebsd)
1309RuntimeGC_SOURCES += \
1310 common/math/gcc/adddi3.c \
1311 common/math/gcc/anddi3.c \
1312 common/math/gcc/ashldi3.c \
1313 common/math/gcc/ashrdi3.c \
1314 common/math/gcc/cmpdi2.c \
1315 common/math/gcc/divdi3.c \
1316 common/math/gcc/iordi3.c \
1317 common/math/gcc/lshldi3.c \
1318 common/math/gcc/lshrdi3.c \
1319 common/math/gcc/moddi3.c \
1320 common/math/gcc/muldi3.c \
1321 common/math/gcc/negdi2.c \
1322 common/math/gcc/notdi2.c \
1323 common/math/gcc/qdivrem.c \
1324 common/math/gcc/subdi3.c \
1325 common/math/gcc/ucmpdi2.c \
1326 common/math/gcc/udivdi3.c \
1327 common/math/gcc/umoddi3.c \
1328 common/math/gcc/xordi3.c
1329endif
1330
1331
1332#
1333# Static library for new & delete for the electric fence.
1334#
1335RuntimeEFCPP_TEMPLATE = $(RuntimeR3_TEMPLATE)
1336RuntimeEFCPP_SDKS = $(RuntimeR3_SDKS)
1337RuntimeEFCPP_SDKS.$(KBUILD_TARGET) = $(RuntimeR3_SDKS.$(KBUILD_TARGET))
1338RuntimeEFCPP_DEFS = $(RuntimeR3_DEFS)
1339RuntimeEFCPP_DEFS.$(KBUILD_TARGET) = $(RuntimeR3_DEFS.$(KBUILD_TARGET))
1340RuntimeEFCPP_INCS = $(RuntimeR3_INCS)
1341RuntimeEFCPP_INCS.$(KBUILD_TARGET) = $(RuntimeR3_INCS.$(KBUILD_TARGET))
1342RuntimeEFCPP_SOURCES = r3/alloc-ef-cpp.cpp
1343
1344
1345
1346#
1347# errmsg.cpp depends on a generated header.
1348#
1349common/err/errmsg.cpp_DEPS = $(PATH_TARGET)/errmsgdata.h
1350common/err/errmsg.cpp_INCS = $(PATH_TARGET)
1351
1352win/errmsgwin.cpp_DEPS = $(PATH_TARGET)/errmsgcomdata.h
1353win/errmsgwin.cpp_INCS = $(PATH_TARGET)
1354
1355
1356#
1357# Generate the rules (we're the to sub-makefile).
1358#
1359include $(KBUILD_PATH)/subfooter.kmk
1360
1361
1362ifneq ($(wildcard /usr/bin/chcon),)
1363# this is needed for testcases executed at build time
1364## @todo Make a special installer tool that does this.
1365$(PATH_BIN)/VBoxRT.so:
1366 $(INSTALL) $(TARGET_VBoxRT) $@
1367 chcon -t texrel_shlib_t $@ || true
1368endif
1369
1370
1371#
1372# Generate the status code data.
1373#
1374$(PATH_TARGET)/errmsgdata.h: \
1375 $(VBOX_PATH_RUNTIME_SRC)/common/err/errmsg.sed \
1376 $(PATH_ROOT)/include/iprt/err.h \
1377 $(PATH_ROOT)/include/VBox/err.h
1378 $(call MSG_GENERATE,,$@,$(filter %.h,$^))
1379 $(QUIET)$(MKDIR) -p $(PATH_TARGET)
1380 $(QUIET)$(REDIRECT) -wo $@ -- $(SED) -f $< $(filter %.h,$^)
1381
1382## @todo r=bird: rename this to indicate that it's not only COM errors, but all win32/64 errors.
1383$(PATH_TARGET)/errmsgcomdata.h: \
1384 $(VBOX_PATH_RUNTIME_SRC)/common/err/errmsgcom.sed \
1385 $$(PATH_SDK_WINPSDK_INC)/WinError.h
1386 $(call MSG_GENERATE,,$@,$(filter %.h,$^))
1387 $(QUIET)$(MKDIR) -p $(PATH_TARGET)
1388 $(QUIET)$(REDIRECT) -wo $@ -- $(SED) -f $< $(filter %.h,$^)
1389
1390
1391#
1392# Aliases for .cpp.h files so we can more easily do syntax checking from the editor.
1393#
1394ldrELFRelocatable.cpp.o: ldrELF.o
1395ldrELFRelocatable.cpp.obj: ldrELF.obj
1396
1397
1398#
1399# Doxygen documentation.
1400#
1401IPRT_DOXYFILE_INPUT_DIRS = \
1402 $(PATH_ROOT)/include/iprt \
1403 $(PATH_ROOT)/include/iprt/nocrt \
1404 $(PATH_ROOT)/include/iprt/nocrt/x86 \
1405 $(PATH_ROOT)/include/iprt/nocrt/amd64 \
1406 $(VBOX_PATH_RUNTIME_SRC)/include/internal \
1407 $(VBOX_PATH_RUNTIME_SRC)/common/alloc \
1408 $(VBOX_PATH_RUNTIME_SRC)/common/checksum \
1409 $(VBOX_PATH_RUNTIME_SRC)/common/err \
1410 $(VBOX_PATH_RUNTIME_SRC)/common/ldr \
1411 $(VBOX_PATH_RUNTIME_SRC)/common/log \
1412 $(VBOX_PATH_RUNTIME_SRC)/common/misc \
1413 $(VBOX_PATH_RUNTIME_SRC)/common/string \
1414 $(VBOX_PATH_RUNTIME_SRC)/common/table \
1415 $(VBOX_PATH_RUNTIME_SRC)/common/time \
1416 $(VBOX_PATH_RUNTIME_SRC)/VBox \
1417 $(foreach dir, $(VBOX_PATH_RUNTIME_SRC) $(VBOX_PATH_RUNTIME_SRC)/r3 $(VBOX_PATH_RUNTIME_SRC)/r0drv,\
1418 $(dir) \
1419 $(dir)/darwin \
1420 $(dir)/l4 \
1421 $(dir)/linux \
1422 $(dir)/nt \
1423 $(dir)/os2 \
1424 $(dir)/win \
1425 $(dir)/win32 \
1426 $(dir)/win64 \
1427 $(dir)/generic \
1428 )
1429
1430# These must come first in order to make things look nice.
1431IPRT_DOXYFILE_INPUT_FIRST =\
1432 $(PATH_ROOT)/include/iprt/cdefs.h \
1433 $(PATH_ROOT)/include/iprt/types.h \
1434 $(PATH_ROOT)/include/iprt/runtime.h \
1435 $(PATH_ROOT)/include/iprt/param.h \
1436 $(PATH_ROOT)/include/iprt/assert.h \
1437 $(PATH_ROOT)/include/iprt/asm.h \
1438
1439IPRT_DOXYFILE_INPUT := \
1440 $(filter-out %.cpp.h, $(sort $(wildcard $(addsuffix /*.h, $(IPRT_DOXYFILE_INPUT_DIRS)))) ) \
1441 $(foreach dir, $(IPRT_DOXYFILE_INPUT_DIRS), $(wildcard $(dir)/*.cpp $(dir)/.c $(dir)/.asm))
1442IPRT_DOXYFILE_INPUT := \
1443 $(IPRT_DOXYFILE_INPUT_FIRST) \
1444 $(filter-out $(IPRT_DOXYFILE_INPUT_FIRST), $(IPRT_DOXYFILE_INPUT))
1445
1446
1447IPRT_DOXYFILE_OUTPUT = $(PATH_OUT)/docs/iprt
1448
1449-include $(PATH_TARGET)/Doxyfile.iprt.dep
1450
1451# Generate the Doxyfile
1452$(PATH_TARGET)/Doxyfile.iprt: \
1453 $(VBOX_PATH_RUNTIME_SRC)/Doxyfile \
1454 $(VBOX_PATH_RUNTIME_SRC)/Makefile.kmk \
1455 $(comp-vars IPRT_DOXYFILE_INPUT,DOXYGEN_INPUT_PREV,FORCE) \
1456 $(comp-vars IPRT_DOXYFILE_OUTPUT,DOXYGEN_OUTPUT_PREV,FORCE) \
1457 | $(call DIRDEP, $(PATH_TARGET))
1458 $(RM) -f $@ $@.tmp $(PATH_TARGET)/Doxyfile.iprt.dep
1459 $(CP) -f $(VBOX_PATH_RUNTIME_SRC)/Doxyfile $@.tmp
1460 $(APPEND) $@.tmp
1461 $(APPEND) $@.tmp "OUTPUT_DIRECTORY = $(IPRT_DOXYFILE_OUTPUT)"
1462 $(APPEND) $@.tmp "WARN_LOGFILE = $(IPRT_DOXYFILE_OUTPUT)/errors"
1463 $(APPEND) $@.tmp "INCLUDE_PATH = $(PATH_ROOT)/include include . common/table"
1464 $(APPEND) $@.tmp "INCLUDE_FILE_PATTERNS = *.cpp.h"
1465 $(APPEND) $@.tmp "PREDEFINED += $(ARCH_BITS_DEFS)"
1466 $(APPEND) $@.tmp
1467 $(APPEND) $@.tmp "INPUT = $(IPRT_DOXYFILE_INPUT)"
1468 $(APPEND) $@.tmp
1469 $(MV) -f $@.tmp $@
1470 @$(APPEND) $(PATH_TARGET)/Doxyfile.iprt.dep "DOXYGEN_OUTPUT_PREV = $(IPRT_DOXYFILE_OUTPUT)"
1471 @$(APPEND) $(PATH_TARGET)/Doxyfile.iprt.dep "DOXYGEN_INPUT_PREV = $(IPRT_DOXYFILE_INPUT)"
1472
1473# Create the output directory.
1474$(call DIRDEP, $(IPRT_DOXYFILE_OUTPUT)):
1475 $(MKDIR) -p $@
1476
1477# Do the actual job.
1478$(PATH_TARGET)/docs.iprt: $(PATH_TARGET)/Doxyfile.iprt $(IPRT_DOXYFILE_INPUT) | $(call DIRDEP, $(IPRT_DOXYFILE_OUTPUT))
1479 $(RM) -f $(wildcard $(IPRT_DOXYFILE_OUTPUT)/html/*) $(PATH_TARGET)/docs.iprt
1480 doxygen $(PATH_TARGET)/Doxyfile.iprt
1481 $(APPEND) $(PATH_TARGET)/docs.iprt
1482
1483# alias
1484docs: $(PATH_TARGET)/docs.iprt
1485
1486test:
1487 @echo test-$(comp-vars IPRT_DOXYFILE_OUTPUT,DOXYGEN_OUTPUT_PREV,FORCE)
1488 @echo $(IPRT_DOXYFILE_OUTPUT)
1489 @echo $(DOXYGEN_OUTPUT_PREV)
1490 @echo $(IPRT_DOXYFILE_INPUT)
1491
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