VirtualBox

source: vbox/trunk/src/VBox/Devices/Makefile.kmk@ 30863

Last change on this file since 30863 was 30772, checked in by vboxsync, 14 years ago

VMMDevTesting/test1: Report the results to the host via a RTTest* like framework.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 30.2 KB
Line 
1# $Id: Makefile.kmk 30772 2010-07-10 04:58:28Z vboxsync $
2## @file
3# Top-level sub-makefile for the devices, drivers and services.
4#
5
6#
7# Copyright (C) 2006-2010 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
18SUB_DEPTH = ../../..
19include $(KBUILD_PATH)/subheader.kmk
20
21
22VBOX_PATH_DEVICES_SRC := $(PATH_SUB_CURRENT)
23
24# Include sub-makefiles.
25include $(PATH_SUB_CURRENT)/PC/BIOS/Makefile.kmk
26include $(PATH_SUB_CURRENT)/Graphics/BIOS/Makefile.kmk
27include $(PATH_SUB_CURRENT)/testcase/Makefile.kmk
28include $(PATH_SUB_CURRENT)/Storage/testcase/Makefile.kmk
29ifndef VBOX_OSE
30 include $(PATH_SUB_CURRENT)/Storage/VBoxHDDFormats/Makefile.kmk
31endif
32ifdef VBOX_WITH_EFI
33 include $(PATH_SUB_CURRENT)/EFI/Thunk/Makefile.kmk
34endif
35ifdef VBOX_WITH_INTEL_PXE
36 include $(PATH_SUB_CURRENT)/PC/PXE/Makefile.kmk
37else
38 # Subdir with complex makefile.
39 SUBDIRS_LIBRARIES += $(VBOX_PATH_DEVICES_SRC)/PC/Etherboot-src
40 SUBDIRS_CLEAN += $(VBOX_PATH_DEVICES_SRC)/PC/Etherboot-src
41 # Disable the unsafe pass order optimizations.
42 KBUILD_SAFE_PARALLEL = 1
43endif
44
45#
46# Main targets.
47#
48LIBRARIES += DevicesR3 Drivers ServicesR0
49DLLS += VBoxDDU VBoxDD VBoxDD2
50SYSMODS += VBoxDDR0 VBoxDD2R0
51ifdef VBOX_WITH_RAW_MODE
52 SYSMODS += VBoxDDGC VBoxDD2GC
53endif
54
55
56#
57# VBoxDDU (shared object)
58#
59VBoxDDU_TEMPLATE = VBOXR3
60VBoxDDU_NAME = $(basename $(notdir $(LIB_DDU)))
61VBoxDDU_INST.darwin = $(INST_DLL) $(INST_TESTCASE)
62VBoxDDU_DEFS = IN_VBOXDDU
63ifdef VBOX_WITH_VUSB
64 VBoxDDU_DEFS += VBOX_WITH_VUSB
65endif
66ifdef VBOX_WITH_USB
67 VBoxDDU_DEFS += VBOX_WITH_USB IN_USBLIB
68 VBoxDDU_SDKS.win = WINPSDK W2K3DDK
69 ifdef VBOX_WITH_EHCI
70 VBoxDDU_DEFS += VBOX_WITH_EHCI
71 endif
72 ifdef VBOX_WITH_NEW_USB_CODE_ON_DARWIN
73 VBoxDDU_DEFS.darwin += VBOX_WITH_NEW_USB_CODE_ON_DARWIN
74 endif
75else
76 VBoxDDU_SDKS.win = WINPSDK
77endif
78ifdef VBOX_WITH_NEW_IO_CODE
79 VBoxDDU_DEFS += VBOX_WITH_NEW_IO_CODE
80endif
81VBoxDDU_SOURCES = \
82 Storage/VBoxHDD.cpp \
83 Storage/VDIHDDCore.cpp \
84 Storage/VHDHDDCore.cpp \
85 Storage/VmdkHDDCore.cpp \
86 Storage/RawHDDCore.cpp \
87 Storage/ParallelsHDDCore.cpp \
88 Storage/VSCSI/VSCSIDevice.cpp \
89 Storage/VSCSI/VSCSILun.cpp \
90 Storage/VSCSI/VSCSILunSbc.cpp \
91 Storage/VSCSI/VSCSISense.cpp \
92 Storage/VSCSI/VSCSISgBuf.cpp \
93 Storage/VSCSI/VSCSIIoReq.cpp \
94 VBoxDDUDeps.cpp
95ifdef VBOX_WITH_USB
96 VBoxDDU_INCS.os2 += \
97 $(PATH_ROOT)/src/VBox/HostDrivers/VBoxUSB/os2
98endif
99VBoxDDU_LIBS = \
100 $(LIB_RUNTIME)
101ifdef VBOX_WITH_USB
102 VBoxDDU_LIBS += \
103 $(PATH_LIB)/USBLib$(VBOX_SUFF_LIB)
104endif
105ifeq ($(KBUILD_TARGET),l4)
106 VBoxDDU_LIBS += \
107 $(L4_LIBDIR)/libl4sys.p.a
108endif
109VBoxDDU_LDFLAGS.darwin = -install_name $(VBOX_DYLD_EXECUTABLE_PATH)/VBoxDDU.dylib
110ifdef VBOX_WITH_USB
111 ifdef VBOX_WITH_NEW_USB_CODE_ON_DARWIN
112 VBoxDDU_LDFLAGS.darwin += -framework IOKit
113 endif
114endif
115
116VBoxDDU_LDFLAGS.linux = -Wl,--no-undefined
117VBoxDDU_LDFLAGS.l4 = -Wl,--no-undefined
118
119#
120# VBoxDDULnxHostR3 (Only needed for l4, currently for executing vditool on L4Linux.)
121#
122ifeq ($(KBUILD_TARGET),l4)
123 LIBRARIES += VBoxDDULnxHostR3
124 VBoxDDULnxHostR3_TEMPLATE = VBOXLNXHOSTR3LIB
125 VBoxDDULnxHostR3_DEFS = IN_VBOXDDU
126 VBoxDDULnxHostR3_SOURCES = $(VBoxDDU_SOURCES)
127endif
128
129#
130# VBoxDD (shared object)
131#
132VBoxDD_TEMPLATE = VBOXR3
133ifdef VBOX_WITH_DTRACE_R3
134 VBoxDD_TEMPLATE = VBOXR3OSX105
135endif
136VBoxDD_SDKS.win = WINPSDK DXSDK W2K3DDK VBOX_NTDLL
137VBoxDD_SOURCES = \
138 Builtins.cpp
139VBoxDD_DEFS = VBOX_ACPI
140ifdef VBOX_WITH_USB
141 VBoxDD_DEFS += VBOX_WITH_USB
142 ifdef VBOX_WITH_EHCI
143 VBoxDD_DEFS += VBOX_WITH_EHCI
144 endif
145endif
146ifdef VBOX_WITH_VUSB
147 VBoxDD_DEFS += VBOX_WITH_VUSB
148endif
149ifdef VBOX_WITH_AHCI
150 VBoxDD_DEFS += VBOX_WITH_AHCI
151endif
152ifdef VBOX_WITH_INIP
153 VBoxDD_DEFS += VBOX_WITH_INIP
154endif
155ifdef VBOX_WITH_E1000
156 VBoxDD_DEFS += VBOX_WITH_E1000
157endif
158ifdef VBOX_WITH_VIRTIO
159 VBoxDD_DEFS += VBOX_WITH_VIRTIO
160endif
161ifdef VBOX_WITH_BUSLOGIC
162 VBoxDD_DEFS += VBOX_WITH_BUSLOGIC
163endif
164ifdef VBOX_WITH_PDM_ASYNC_COMPLETION
165 VBoxDD_DEFS += VBOX_WITH_PDM_ASYNC_COMPLETION
166endif
167ifdef VBOX_WITH_SCSI
168 VBoxDD_DEFS += VBOX_WITH_SCSI
169endif
170ifdef VBOX_WITH_LSILOGIC
171 VBoxDD_DEFS += VBOX_WITH_LSILOGIC
172endif
173ifdef VBOX_WITH_HPET
174 VBoxDD_DEFS += VBOX_WITH_HPET
175endif
176ifdef VBOX_WITH_SMC
177 VBoxDD_DEFS += VBOX_WITH_SMC
178endif
179ifdef VBOX_WITH_EFI
180 VBoxDD_DEFS += VBOX_WITH_EFI
181endif
182ifdef VBOX_WITH_DRV_DISK_INTEGRITY
183 VBoxDD_DEFS += VBOX_WITH_DRV_DISK_INTEGRITY
184endif
185ifdef VBOX_WITH_VDE
186 VBoxDD_DEFS += VBOX_WITH_VDE
187endif
188
189VBoxDD_LIBS = \
190 $(PATH_LIB)/DevicesR3$(VBOX_SUFF_LIB) \
191 $(PATH_LIB)/Drivers$(VBOX_SUFF_LIB) \
192 $(PATH_LIB)/VgaDefBiosLogo$(VBOX_SUFF_LIB) \
193 $(LIB_VMM) \
194 $(LIB_RUNTIME)
195ifeq ($(KBUILD_TARGET),win)
196 VBoxDD_LIBS += \
197 $(LIB_DDU) \
198 $(PATH_LIB)/VBoxDD2.lib \
199 $(PATH_SDK_DXSDK_LIB)/dxguid.lib
200else
201 VBoxDD_LIBS += \
202 $(INSTARGET_VBoxDDU) \
203 $(INSTARGET_VBoxDD2)
204endif
205ifeq ($(KBUILD_TARGET),l4)
206 VBoxDD_LIBS += \
207 $(L4_LIBDIR)/libl4sys.p.a
208endif
209
210ifdef VBOX_WITH_HGSMI
211 VBoxDD_LIBS += \
212 $(PATH_LIB)/HGSMIHostR3Lib$(VBOX_SUFF_LIB)
213endif
214
215ifdef VBOX_WITH_NETFLT
216 VBoxDD_LIBS.win += $(PATH_LIB)/WinNetConfig.lib
217endif
218
219ifdef VBOX_WITH_EFI
220 VBoxDD_LIBS += $(PATH_LIB)/EfiThunkBin$(VBOX_SUFF_LIB)
221endif
222
223ifeq ($(KBUILD_TARGET),solaris)
224 VBoxDD_LIBS += adm
225 ifdef VBOX_WITH_SUID_WRAPPER
226 VBoxDD_LIBS += secdb
227 endif
228 ifdef VBOX_WITH_USB
229 VBoxDD_LIBS += aio
230 endif
231endif
232
233VBoxDD_LIBS.darwin += \
234 $(LIB_REM)
235
236VBoxDD_LDFLAGS.darwin = -install_name $(VBOX_DYLD_EXECUTABLE_PATH)/VBoxDD.dylib \
237 -framework CoreAudio \
238 -framework AudioUnit \
239 -framework AudioToolbox \
240 -framework IOKit \
241 -framework Carbon \
242 -framework DiskArbitration
243VBoxDD_LDFLAGS.linux = -Wl,--no-undefined
244VBoxDD_LDFLAGS.l4 = -Wl,--no-undefined
245
246
247#
248# VBoxDD2 (shared object)
249#
250VBoxDD2_TEMPLATE = VBOXR3
251VBoxDD2_DEFS = IN_VBOXDD2
252VBoxDD2_INCS := \
253 $(PATH_SUB_CURRENT)
254VBoxDD2_SOURCES = \
255 Builtins2.cpp \
256 PC/DevAPIC.cpp
257ifdef VBOX_WITH_SMC
258 VBoxDD2_DEFS += VBOX_WITH_SMC
259 VBoxDD2_SOURCES += PC/DevSMC.cpp
260endif
261ifdef VBOX_WITH_LPC
262 VBoxDD2_DEFS += VBOX_WITH_LPC
263 VBoxDD2_SOURCES += PC/DevLPC.cpp
264endif
265VBoxDD2_LIBS = \
266 $(PATH_LIB)/PcBiosBin$(VBOX_SUFF_LIB) \
267 $(PATH_LIB)/VgaBiosBin$(VBOX_SUFF_LIB) \
268 $(PATH_LIB)/NetBiosBin$(VBOX_SUFF_LIB) \
269 $(LIB_VMM) \
270 $(LIB_RUNTIME)
271ifeq ($(KBUILD_TARGET),l4)
272VBoxDD2_LIBS += \
273 $(L4_LIBDIR)/libl4sys.p.a
274endif
275VBoxDD2_LIBS.darwin += $(LIB_REM)
276VBoxDD2_LDFLAGS.darwin = -install_name $(VBOX_DYLD_EXECUTABLE_PATH)/VBoxDD2.dylib
277VBoxDD2_LDFLAGS.linux = -Wl,--no-undefined
278VBoxDD2_LDFLAGS.l4 = -Wl,--no-undefined
279
280
281#
282# DevicesR3 (library)
283#
284DevicesR3_TEMPLATE = VBOXR3
285DevicesR3_SDKS.win = WINPSDK W2K3DDK
286DevicesR3_DEFS.darwin.x86 = VBOX_WITH_2X_4GB_ADDR_SPACE
287DevicesR3_DEFS += VBOX_HGCM_HOST_CODE \
288 VBOX_WITH_HGCM
289DevicesR3_DEFS.linux += _GNU_SOURCE
290DevicesR3_DEFS.l4 += _GNU_SOURCE
291
292DevicesR3_INCS = \
293 .
294
295DevicesR3_SOURCES = \
296 Input/DevPS2.cpp \
297 Input/UsbKbd.cpp \
298 Input/UsbMouse.cpp \
299 Bus/DevPCI.cpp \
300 Graphics/DevVGA.cpp \
301 Storage/DevATA.cpp \
302 PC/DevPit-i8254.cpp \
303 PC/DevPIC.cpp \
304 PC/DevACPI.cpp \
305 PC/ACPI/VBoxAcpi.cpp \
306 PC/DevRTC.cpp \
307 PC/DevPcBios.cpp \
308 PC/DevFwCommon.cpp \
309 PC/DevPcArch.c \
310 VMMDev/VMMDev.cpp \
311 VMMDev/VMMDevHGCM.cpp \
312 VMMDev/VMMDevTesting.cpp \
313 Network/DevPCNet.cpp \
314 Audio/DevIchAc97.cpp \
315 Audio/DevSB16.cpp \
316 PC/DevDMA.cpp \
317 Storage/fdc.c \
318 Serial/DevSerial.cpp \
319 Parallel/DevParallel.cpp
320
321ifdef VBOX_DYNAMIC_NET_ATTACH
322 DevicesR3_DEFS += VBOX_DYNAMIC_NET_ATTACH
323endif
324ifdef VBOX_BIOS_DMI_FALLBACK
325 DevicesR3_DEFS += VBOX_BIOS_DMI_FALLBACK
326endif
327
328ifdef VBOX_WITH_E1000
329 DevicesR3_DEFS += VBOX_WITH_E1000
330 DevicesR3_SOURCES += \
331 Network/DevE1000.cpp \
332 Network/DevE1000Phy.cpp \
333 Network/DevEEPROM.cpp
334endif
335
336ifdef VBOX_WITH_VIRTIO
337 DevicesR3_DEFS += VBOX_WITH_VIRTIO
338 DevicesR3_SOURCES += \
339 VirtIO/Virtio.cpp \
340 Network/DevVirtioNet.cpp
341endif
342
343ifdef VBOX_WITH_HGSMI
344 DevicesR3_DEFS += VBOX_WITH_HGSMI
345 DevicesR3_SOURCES += \
346 Graphics/DevVGA_VBVA.cpp \
347 Graphics/HGSMI/HGSMIHost.cpp \
348 Graphics/HGSMI/HGSMIHostHlp.cpp
349
350endif
351ifdef VBOXVDMA
352 DevicesR3_DEFS += VBOXVDMA
353 DevicesR3_SOURCES += \
354 Graphics/HGSMI/SHGSMIHost.cpp \
355 Graphics/DevVGA_VDMA.cpp
356endif
357ifdef VBOXWDDM_WITH_VBVA
358 DevicesR3_DEFS += VBOXWDDM_WITH_VBVA
359endif
360
361ifdef VBOX_WITH_VIDEOHWACCEL
362 DevicesR3_DEFS += VBOX_WITH_VIDEOHWACCEL
363endif
364ifdef VBOX_WITH_DMI_CHASSIS
365 DevicesR3_DEFS += VBOX_WITH_DMI_CHASSIS
366endif
367ifdef VBOX_WITH_DMI_OEMSTRINGS
368 DevicesR3_DEFS += VBOX_WITH_DMI_OEMSTRINGS
369endif
370
371ifdef VBOX_WITH_INIP
372 DevicesR3_INCS += \
373 Network/lwip/src/include \
374 Network/lwip/src/include/ipv4 \
375 Network/lwip/vbox/include
376 DevicesR3_SOURCES += \
377 Network/lwip/src/api/api_lib.c \
378 Network/lwip/src/api/api_msg.c \
379 Network/lwip/src/api/err.c \
380 Network/lwip/src/api/sockets.c \
381 Network/lwip/src/api/tcpip.c \
382 Network/lwip/src/core/tcp_in.c \
383 Network/lwip/src/core/dhcp.c \
384 Network/lwip/src/core/inet.c \
385 Network/lwip/src/core/mem.c \
386 Network/lwip/src/core/memp.c \
387 Network/lwip/src/core/netif.c \
388 Network/lwip/src/core/pbuf.c \
389 Network/lwip/src/core/raw.c \
390 Network/lwip/src/core/stats.c \
391 Network/lwip/src/core/sys.c \
392 Network/lwip/src/core/tcp.c \
393 Network/lwip/src/core/ipv4/ip_addr.c \
394 Network/lwip/src/core/ipv4/icmp.c \
395 Network/lwip/src/core/ipv4/ip.c \
396 Network/lwip/src/core/ipv4/ip_frag.c \
397 Network/lwip/src/core/tcp_out.c \
398 Network/lwip/src/core/udp.c \
399 Network/lwip/src/netif/etharp.c \
400 Network/lwip/vbox/sys_arch.c \
401 Network/DevINIP.cpp
402 DevicesR3_DEFS += VBOX_WITH_INIP
403endif
404
405ifdef VBOX_WITH_AHCI
406 DevicesR3_DEFS += VBOX_WITH_AHCI IN_AHCI_R3
407 DevicesR3_SOURCES += \
408 Storage/DevAHCI.cpp \
409 Storage/ATAController.cpp
410endif
411
412ifdef VBOX_WITH_BUSLOGIC
413 DevicesR3_DEFS += VBOX_WITH_BUSLOGIC
414 DevicesR3_SOURCES += \
415 Storage/DevBusLogic.cpp \
416 Storage/VBoxSCSI.cpp
417endif
418
419ifdef VBOX_WITH_LSILOGIC
420 DevicesR3_DEFS += VBOX_WITH_LSILOGIC
421 DevicesR3_SOURCES += \
422 Storage/DevLsiLogicSCSI.cpp
423endif
424
425ifdef VBOX_WITH_HPET
426 DevicesR3_DEFS += VBOX_WITH_HPET
427 DevicesR3_SOURCES += PC/DevHPET.cpp
428endif
429
430ifdef VBOX_WITH_EFI
431 DevicesR3_DEFS += VBOX_WITH_EFI
432 ifdef VBOX_WITH_ALT_EFITHUNK
433 DevicesR3_DEFS += VBOX_WITH_ALT_EFITHUNK
434 endif
435 DevicesR3_SOURCES += EFI/DevEFI.cpp
436 EFI/DevEFI.cpp_INCS += EFI/tools/include
437 EFI/DevEFI.cpp_INCS.x86 += EFI/tools/include/Ia32
438 EFI/DevEFI.cpp_INCS.amd64 += EFI/tools/include/X64
439endif
440
441ifdef VBOX_WITH_DYNAMIC_DSDT
442 DevicesR3_DEFS += VBOX_WITH_DYNAMIC_DSDT
443endif
444
445ifdef VBOX_WITH_VUSB
446 DevicesR3_DEFS += VBOX_WITH_VUSB
447 DevicesR3_SOURCES += \
448 USB/DevOHCI.cpp
449endif
450ifdef VBOX_WITH_USB
451 DevicesR3_DEFS += VBOX_WITH_USB
452 ifdef VBOX_WITH_EHCI
453 DevicesR3_DEFS += VBOX_WITH_EHCI
454 DevicesR3_SOURCES += \
455 USB/DevEHCI.cpp
456 endif
457endif
458
459ifdef VBOX_WITH_DTRACE_R3
460 DevicesR3_TEMPLATE = VBOXR3OSX105
461 DevicesR3_DEFS += VBOX_WITH_DTRACE
462 DevicesR3_INCS += $(DevicesR3_0_OUTDIR)
463 DevicesR3_INTERMEDIATES += $(DevicesR3_0_OUTDIR)/VBoxDD-dtrace.h
464 $$(DevicesR3_0_OUTDIR)/VBoxDD-dtrace.h: $(PATH_CURRENT)/VBoxDD-dtrace.d | $$(dir $$@)
465 dtrace -C -h -o $@ -s $<
466endif
467
468ifdef VBOX_WITH_DYNAMIC_DSDT
469 DevicesR3_CLEAN += $(PATH_DevicesR3)/vboxdsl.hex
470 PC/ACPI/VBoxAcpi.cpp_DEPS = $(PATH_DevicesR3)/vboxdsl.hex
471
472 $$(PATH_DevicesR3)/vboxdsl.hex: $(PATH_SUB_CURRENT)/PC/vbox.dsl | $$(dir $$@)
473 $(call MSG_TOOL,bin2c,DevicesR3,$<,$@)
474 $(QUIET)$(VBOX_BIN2C) -export VboxDslSource $< $@
475
476 vboxdsl.hex:: $$(PATH_DevicesR3)/vboxdsl.hex
477
478else # !VBOX_WITH_DYNAMIC_DSDT
479 # VBoxAcpi.cpp needs vboxaml.hex which we generate from PC/vbox.dsl
480 DevicesR3_CLEAN += \
481 $(PATH_DevicesR3)/vboxaml.hex \
482 $(PATH_DevicesR3)/vboxaml.aml \
483 $(PATH_DevicesR3)/vboxssdt-standard.hex \
484 $(PATH_DevicesR3)/vboxssdt-standard.aml \
485 $(PATH_DevicesR3)/vboxssdt-standard.aml.tmp \
486 $(PATH_DevicesR3)/vboxssdt-cpuhotplug.hex \
487 $(PATH_DevicesR3)/vboxssdt-cpuhotplug.aml \
488 $(PATH_DevicesR3)/vboxssdt-cpuhotplug.aml.tmp \
489 $(PATH_DevicesR3)/vboxssdt-cpuhotplug.aml.pre
490 PC/ACPI/VBoxAcpi.cpp_DEPS = \
491 $(PATH_DevicesR3)/vboxaml.hex \
492 $(PATH_DevicesR3)/vboxssdt-standard.hex \
493 $(PATH_DevicesR3)/vboxssdt-cpuhotplug.hex
494
495 $$(PATH_DevicesR3)/vboxaml.hex: $(PATH_SUB_CURRENT)/PC/vbox.dsl | $$(dir $$@)
496 $(call MSG_TOOL,iasl,DevicesR3,$<,$@)
497 $(QUIET)$(VBOX_IASLCMD) -tc -vs -p $@ $<
498
499 vboxaml.hex:: $$(PATH_DevicesR3)/vboxaml.hex
500
501 $$(PATH_DevicesR3)/vboxssdt-standard.hex: $(PATH_SUB_CURRENT)/PC/vbox-standard.dsl | $$(dir $$@)
502 $(call MSG_TOOL,iasl,DevicesR3,$<,$@)
503 $(QUIET)$(RM) -f $@ $@.tmp
504 $(QUIET)$(VBOX_IASLCMD) -tc -vs -p $@ $<
505 $(QUIET)$(MV) -f $@ $@.tmp
506 $(QUIET)$(SED) "s/AmlCode/AmlCodeSsdtStandard/g" \
507 --output $@ $@.tmp
508 $(QUIET)$(RM) -f $@.tmp
509
510
511 vboxssdt-standard.hex:: $$(PATH_DevicesR3)/vboxssdt-standard.hex
512
513 $$(PATH_DevicesR3)/vboxssdt-cpuhotplug.hex: $(PATH_SUB_CURRENT)/PC/vbox-cpuhotplug.dsl | $$(dir $$@)
514 $(call MSG_TOOL,iasl,DevicesR3,$<,$@)
515 $(QUIET)$(RM) -f $@ $@.tmp $@.pre
516 $(QUIET)$(TOOL_$(VBOX_GCC_TOOL)_CC) -E -P -x c -o $@.pre $<
517 $(QUIET)$(VBOX_IASLCMD) -tc -vs -p $@ $@.pre
518 $(QUIET)$(MV) -f $@ $@.tmp
519 $(QUIET)$(SED) "s/AmlCode/AmlCodeSsdtCpuHotPlug/g" \
520 --output $@ $@.tmp
521 $(QUIET)$(RM) -f $@.tmp $@.pre
522
523
524 vboxssdt-cpuhotplug.hex:: $$(PATH_DevicesR3)/vboxssdt-cpuhotplug.hex
525
526endif # !VBOX_WITH_DYNAMIC_DSDT
527PC/ACPI/VBoxAcpi.cpp_INCS = $(PATH_DevicesR3)
528
529# For finding PCIInternal.h from VBox/pci.h.
530Bus/DevPCI.cpp_INCS = Bus
531
532# For finding and generating vbetables.h (see Graphics/BIOS/Makefile.kmk).
533Graphics/DevVGA.cpp_INCS = $(PATH_VgaBiosBin)
534Graphics/DevVGA.cpp_DEPS = $(PATH_VgaBiosBin)/vbetables.h
535
536
537ifdef VBOX_WITH_RAW_MODE
538 #
539 # VBoxDDGC (sysmod)
540 #
541 VBoxDDGC_TEMPLATE = VBoxRc
542 ifeq ($(KBUILD_TARGET_ARCH),x86)
543 VBoxDDGC_DEFS.darwin = VBOX_WITH_2X_4GB_ADDR_SPACE
544 endif
545 VBoxDDGC_DEFS = VBOX_WITH_HGCM
546 VBoxDDGC_INCS := \
547 $(PATH_SUB_CURRENT)
548 VBoxDDGC_SOURCES = \
549 Bus/DevPCI.cpp \
550 Graphics/DevVGA.cpp \
551 Input/DevPS2.cpp \
552 PC/DevACPI.cpp \
553 PC/DevPit-i8254.cpp \
554 PC/DevPIC.cpp \
555 PC/DevRTC.cpp \
556 Storage/DevATA.cpp \
557 Network/DevPCNet.cpp \
558 Serial/DevSerial.cpp \
559 Parallel/DevParallel.cpp \
560 VMMDev/VMMDevTesting.cpp
561
562 ifdef VBOX_DYNAMIC_NET_ATTACH
563 VBoxDDGC_DEFS += VBOX_DYNAMIC_NET_ATTACH
564 endif
565
566 ifdef VBOX_WITH_E1000
567 VBoxDDGC_DEFS += VBOX_WITH_E1000
568 VBoxDDGC_SOURCES += \
569 Network/DevE1000.cpp \
570 Network/DevE1000Phy.cpp
571 endif
572
573 ifdef VBOX_WITH_VIRTIO
574 VBoxDDGC_DEFS += VBOX_WITH_VIRTIO
575 VBoxDDGC_SOURCES += \
576 VirtIO/Virtio.cpp \
577 Network/DevVirtioNet.cpp
578 endif
579
580 ifdef VBOX_WITH_HGSMI
581 VBoxDDGC_DEFS += VBOX_WITH_HGSMI
582 endif
583 ifdef VBOXVDMA
584 VBoxDDGC_DEFS += VBOXVDMA
585 endif
586 ifdef VBOXWDDM_WITH_VBVA
587 VBoxDDGC_DEFS += VBOXWDDM_WITH_VBVA
588 endif
589
590 ifdef VBOX_WITH_VUSB
591 VBoxDDGC_DEFS += VBOX_WITH_VUSB
592 VBoxDDGC_SOURCES += \
593 USB/DevOHCI.cpp
594 endif
595
596 ifdef VBOX_WITH_USB
597 VBoxDDGC_DEFS += VBOX_WITH_USB
598 ifdef VBOX_WITH_EHCI
599 VBoxDDGC_DEFS += VBOX_WITH_EHCI
600 VBoxDDGC_SOURCES += \
601 USB/DevEHCI.cpp
602 endif
603 endif
604
605 ifdef VBOX_WITH_HGSMI
606 VBoxDDGC_DEFS += VBOX_WITH_HGSMI
607 endif
608 ifdef VBOXVDMA
609 VBoxDDGC_DEFS += VBOXVDMA
610 endif
611 ifdef VBOXWDDM_WITH_VBVA
612 VBoxDDGC_DEFS += VBOXWDDM_WITH_VBVA
613 endif
614
615 ifdef VBOX_WITH_VIDEOHWACCEL
616 VBoxDDGC_DEFS += VBOX_WITH_VIDEOHWACCEL
617 endif
618
619 ifdef VBOX_WITH_AHCI
620 VBoxDDGC_DEFS += VBOX_WITH_AHCI IN_AHCI_GC
621 VBoxDDGC_SOURCES += \
622 Storage/DevAHCI.cpp \
623 Storage/ATAController.cpp
624 endif
625
626 ifdef VBOX_WITH_BUSLOGIC
627 VBoxDDGC_DEFS += VBOX_WITH_BUSLOGIC
628 VBoxDDGC_SOURCES += \
629 Storage/DevBusLogic.cpp
630 endif
631
632 ifdef VBOX_WITH_LSILOGIC
633 VBoxDDGC_DEFS += VBOX_WITH_LSILOGIC
634 VBoxDDGC_SOURCES += \
635 Storage/DevLsiLogicSCSI.cpp
636 endif
637
638 ifdef VBOX_WITH_HPET
639 VBoxDDGC_DEFS += VBOX_WITH_HPET
640 VBoxDDGC_SOURCES += PC/DevHPET.cpp
641 endif
642
643 if1of ($(VBOX_LDR_FMT32), pe lx)
644 VBoxDDGC_LIBS = \
645 $(PATH_LIB)/VMMGCBuiltin$(VBOX_SUFF_LIB) \
646 $(PATH_LIB)/VMMGCImp$(VBOX_SUFF_LIB)
647 endif
648endif # VBOX_WITH_RAW_MODE
649
650
651#
652# VBoxDDR0 (sysmod)
653#
654VBoxDDR0_TEMPLATE = VBoxR0
655VBoxDDR0_DEFS.darwin.x86= VBOX_WITH_2X_4GB_ADDR_SPACE_IN_R0 VBOX_WITH_2X_4GB_ADDR_SPACE
656VBoxDDR0_DEFS = IN_RT_R0 VBOX_WITH_HGCM # - WTF is IN_RT_R0 doing here?
657VBoxDDR0_INCS := \
658 $(PATH_SUB_CURRENT)
659VBoxDDR0_SOURCES = \
660 Bus/DevPCI.cpp \
661 Graphics/DevVGA.cpp \
662 Input/DevPS2.cpp \
663 PC/DevACPI.cpp \
664 PC/DevPit-i8254.cpp \
665 PC/DevPIC.cpp \
666 PC/DevRTC.cpp \
667 Storage/DevATA.cpp \
668 Network/DevPCNet.cpp \
669 Serial/DevSerial.cpp \
670 Parallel/DevParallel.cpp \
671 VMMDev/VMMDevTesting.cpp \
672 \
673 Network/DrvIntNet.cpp \
674 Network/DrvDedicatedNic.cpp
675
676ifdef VBOX_DYNAMIC_NET_ATTACH
677 VBoxDDR0_DEFS += VBOX_DYNAMIC_NET_ATTACH
678endif
679
680ifdef VBOX_WITH_E1000
681 VBoxDDR0_DEFS += VBOX_WITH_E1000
682 VBoxDDR0_SOURCES += \
683 Network/DevE1000.cpp \
684 Network/DevE1000Phy.cpp
685endif
686
687ifdef VBOX_WITH_VIRTIO
688 VBoxDDR0_DEFS += VBOX_WITH_VIRTIO
689 VBoxDDR0_SOURCES += \
690 VirtIO/Virtio.cpp \
691 Network/DevVirtioNet.cpp
692endif
693
694ifdef VBOX_WITH_HGSMI
695 VBoxDDR0_DEFS += VBOX_WITH_HGSMI
696endif
697ifdef VBOXVDMA
698 VBoxDDR0_DEFS += VBOXVDMA
699endif
700ifdef VBOXWDDM_WITH_VBVA
701 VBoxDDR0_DEFS += VBOXWDDM_WITH_VBVA
702endif
703
704ifdef VBOX_WITH_VUSB
705 VBoxDDR0_DEFS += VBOX_WITH_VUSB
706 VBoxDDR0_SOURCES += \
707 USB/DevOHCI.cpp
708endif
709ifdef VBOX_WITH_USB
710VBoxDDR0_DEFS += VBOX_WITH_USB
711 ifdef VBOX_WITH_EHCI
712 VBoxDDR0_DEFS += VBOX_WITH_EHCI
713 VBoxDDR0_SOURCES += \
714 USB/DevEHCI.cpp
715 endif
716endif
717
718ifdef VBOX_WITH_AHCI
719VBoxDDR0_DEFS += VBOX_WITH_AHCI IN_AHCI_R0
720VBoxDDR0_SOURCES += \
721 Storage/DevAHCI.cpp \
722 Storage/ATAController.cpp
723endif
724
725ifdef VBOX_WITH_BUSLOGIC
726VBoxDDR0_DEFS += VBOX_WITH_BUSLOGIC
727VBoxDDR0_SOURCES += \
728 Storage/DevBusLogic.cpp
729endif
730
731ifdef VBOX_WITH_LSILOGIC
732VBoxDDR0_DEFS += VBOX_WITH_LSILOGIC
733VBoxDDR0_SOURCES += \
734 Storage/DevLsiLogicSCSI.cpp
735endif
736
737ifdef VBOX_WITH_HGSMI
738 VBoxDDR0_DEFS += VBOX_WITH_HGSMI
739endif
740ifdef VBOX_WITH_VIDEOHWACCEL
741 VBoxDDR0_DEFS += VBOX_WITH_VIDEOHWACCEL
742endif
743ifdef VBOXVDMA
744 VBoxDDR0_DEFS += VBOXVDMA
745endif
746ifdef VBOXWDDM_WITH_VBVA
747 VBoxDDR0_DEFS += VBOXWDDM_WITH_VBVA
748endif
749
750
751ifdef VBOX_WITH_HPET
752 VBoxDDR0_DEFS += VBOX_WITH_HPET
753 VBoxDDR0_SOURCES += PC/DevHPET.cpp
754endif
755
756if1of ($(VBOX_LDR_FMT), pe lx)
757VBoxDDR0_LIBS = \
758 $(PATH_LIB)/VMMR0Imp$(VBOX_SUFF_LIB) \
759 $(PATH_LIB)/SUPR0$(VBOX_SUFF_LIB)
760endif
761
762
763ifdef VBOX_WITH_RAW_MODE
764 #
765 # VBoxDD2GC (LGPL sysmod)
766 #
767 VBoxDD2GC_TEMPLATE = VBoxRc
768 VBoxDD2GC_DEFS =
769 VBoxDD2GC_INCS := \
770 $(PATH_SUB_CURRENT)
771 VBoxDD2GC_SOURCES = \
772 PC/DevAPIC.cpp
773 if1of ($(VBOX_LDR_FMT32), pe lx)
774 VBoxDD2GC_LIBS = \
775 $(PATH_LIB)/VMMGCBuiltin$(VBOX_SUFF_LIB) \
776 $(PATH_LIB)/VMMGCImp$(VBOX_SUFF_LIB)
777 endif
778endif
779
780#
781# VBoxDD2R0 (LGPL sysmod)
782#
783VBoxDD2R0_TEMPLATE = VBoxR0
784VBoxDD2R0_DEFS = IN_RT_R0
785VBoxDD2R0_INCS := \
786 $(PATH_SUB_CURRENT)
787VBoxDD2R0_SOURCES = \
788 PC/DevAPIC.cpp
789
790ifdef VBOX_WITH_SMC
791 VBoxDD2R0_DEFS += VBOX_WITH_SMC
792 VBoxDD2R0_SOURCES += PC/DevSMC.cpp
793endif
794
795if1of ($(VBOX_LDR_FMT), pe lx)
796VBoxDD2R0_LIBS = \
797 $(PATH_LIB)/VMMR0Imp$(VBOX_SUFF_LIB) \
798 $(PATH_LIB)/SUPR0$(VBOX_SUFF_LIB)
799endif
800
801
802#
803# Drivers (library)
804#
805ifeq ($(KBUILD_TARGET),l4) # We are using real Linux headers, not the cleaned up user space ones
806Drivers_TEMPLATE = VBOXR3NP
807else
808Drivers_TEMPLATE = VBOXR3
809endif
810Drivers_SDKS.win = WINPSDK W2K3DDK
811Storage/DrvHostDVD.cpp_SDKS.win = W2K3DDK
812Drivers_DEFS.win += _WIN32_WINNT=0x0510
813Drivers_DEFS = IN_IDE_R3
814ifdef VBOX_WITH_NETFLT
815Drivers_DEFS += VBOX_WITH_NETFLT
816endif
817ifdef VBOX_WITH_INIP
818Drivers_DEFS += VBOX_WITH_INIP
819endif
820ifdef VBOX_WITH_DRV_DISK_INTEGRITY
821Drivers_DEFS += VBOX_WITH_DRV_DISK_INTEGRITY
822endif
823
824Drivers_INCS := \
825 $(PATH_SUB_CURRENT) \
826 Network/slirp
827Drivers_SOURCES = \
828 Audio/audio.c \
829 Audio/audiosniffer.c \
830 Audio/mixeng.c \
831 Audio/noaudio.c \
832 Input/DrvKeyboardQueue.cpp \
833 Input/DrvMouseQueue.cpp \
834 Network/DrvIntNet.cpp \
835 Network/DrvDedicatedNic.cpp \
836 PC/DrvACPI.cpp \
837 PC/DrvAcpiCpu.cpp \
838 Serial/DrvChar.cpp \
839 Serial/DrvNamedPipe.cpp \
840 Serial/DrvRawFile.cpp \
841 Storage/DrvBlock.cpp \
842 Storage/DrvHostBase.cpp \
843 Storage/DrvHostDVD.cpp \
844 Storage/DrvHostFloppy.cpp \
845 Storage/DrvMediaISO.cpp \
846 Storage/DrvRawImage.cpp \
847 Storage/Debug.cpp \
848 Storage/DrvVD.cpp \
849 Network/DrvNetSniffer.cpp \
850 Network/Pcap.cpp
851
852VBOX_SLIRP_SOURCES = \
853 Network/DrvNAT.cpp \
854 Network/slirp/bootp.c \
855 Network/slirp/debug.c \
856 Network/slirp/ip_icmp.c \
857 Network/slirp/ip_input.c \
858 Network/slirp/ip_output.c \
859 Network/slirp/misc.c \
860 Network/slirp/sbuf.c \
861 Network/slirp/slirp.c \
862 Network/slirp/socket.c \
863 Network/slirp/tcp_input.c \
864 Network/slirp/tcp_output.c \
865 Network/slirp/tcp_subr.c \
866 Network/slirp/tcp_timer.c \
867 Network/slirp/udp.c \
868 Network/slirp/dnsproxy/hash.c \
869 Network/slirp/tftp.c \
870 Network/slirp/dnsproxy/dnsproxy.c
871
872ifdef VBOX_WITH_SLIRP_BSD_SBUF
873VBOX_SLIRP_SOURCES += Network/slirp/bsd/kern/subr_sbuf.c
874endif
875
876VBOX_SLIRP_BSD_ARCH = $(subst x86,i386,$(KBUILD_TARGET_ARCH))
877VBOX_SLIRP_BSD_SOURCES += \
878 Network/slirp/bsd/kern/kern_mbuf.c \
879 Network/slirp/bsd/kern/uipc_mbuf.c \
880 Network/slirp/bsd/kern/uipc_mbuf2.c \
881 Network/slirp/bsd/$(VBOX_SLIRP_BSD_ARCH)/in_cksum.c
882
883VBOX_SLIRP_ALIAS_SOURCES = \
884 Network/slirp/libalias/alias.c \
885 Network/slirp/libalias/alias_db.c \
886 Network/slirp/libalias/alias_mod.c \
887 Network/slirp/libalias/alias_proxy.c \
888 Network/slirp/libalias/alias_ftp.c \
889 Network/slirp/libalias/alias_dns.c \
890 Network/slirp/libalias/alias_nbt.c \
891 Network/slirp/libalias/alias_util.c
892
893# some day will be deleted
894
895Drivers_SOURCES += $(VBOX_SLIRP_SOURCES)
896define def_vbox_slirp_cflags
897 $(file)_DEFS += \
898 $(if $(VBOX_WITH_SLIRP_BSD_SBUF),VBOX_WITH_SLIRP_BSD_SBUF,) \
899 $(if $(VBOX_WITH_SLIRP_MEMORY_CHECK),RTMEM_WRAP_TO_EF_APIS,) \
900 $(if $(VBOX_WITH_DEBUG_NAT_SOCKETS),VBOX_WITH_DEBUG_NAT_SOCKETS,) \
901 $(if $(VBOX_WITH_SLIRP_MT),VBOX_WITH_SLIRP_MT,)
902 $(file)_INCS += $(1)/slirp/bsd/sys
903 $(file)_INCS += $(1)/slirp/bsd/sys/sys
904 $(file)_INCS += $(1)/slirp/bsd/$(VBOX_SLIRP_BSD_ARCH)/include
905 $(file)_INCS += $(1)/slirp/bsd/netinet
906 $(file)_INCS += $(1)/slirp
907 $(file)_INCS += $(1)/slirp/libalias
908 ifeq ($(KBUILD_TARGET),win)
909 $(file)_CFLAGS = -wd4018
910 else
911 $(file)_CFLAGS += -Wno-sign-compare
912 $(file)_CFLAGS += -Wno-format
913 $(file)_CFLAGS += -Wno-bad-function-cast
914 endif
915endef
916
917$(foreach file,$(VBOX_SLIRP_SOURCES),$(eval $(call def_vbox_slirp_cflags, Network)))
918
919Drivers_SOURCES += $(VBOX_SLIRP_ALIAS_SOURCES)
920define def_vbox_slirp_alias_cflags
921 $(file)_DEFS += VBOX_SLIRP_ALIAS \
922 $(if $(VBOX_WITH_DEBUG_LIBALIAS),VBOX_WITH_DEBUG_LIBALIAS,)
923 $(file)_INCS += $(1)/slirp/libalias
924 $(file)_INCS += $(1)/slirp
925 $(file)_INCS += $(1)/slirp/dnsproxy
926 ifneq ($(KBUILD_TARGET),win)
927 $(file)_CFLAGS += -Wno-shadow
928 endif
929endef
930$(foreach file,$(VBOX_SLIRP_ALIAS_SOURCES),$(eval $(call def_vbox_slirp_cflags, Network)))
931$(foreach file,$(VBOX_SLIRP_ALIAS_SOURCES),$(eval $(call def_vbox_slirp_alias_cflags, Network)))
932
933VBOX_SLIRP_BSD_SOURCES += $(VBOX_SLIRP_BSD_SOURCES.${KBUILD_TARGET_ARCH})
934Drivers_SOURCES += $(VBOX_SLIRP_BSD_SOURCES)
935define def_vbox_slirp_bsd_cflags
936 $(file)_DEFS += VBOX_SLIRP_BSD
937 $(file)_INCS += $(1)/slirp/dnsproxy
938endef
939$(foreach file,$(VBOX_SLIRP_BSD_SOURCES),$(eval $(call def_vbox_slirp_cflags, Network)))
940$(foreach file,$(VBOX_SLIRP_BSD_SOURCES),$(eval $(call def_vbox_slirp_bsd_cflags, Network)))
941
942ifdef VBOX_WITH_DRV_DISK_INTEGRITY
943Drivers_SOURCES += \
944 Storage/DrvDiskIntegrity.cpp
945endif
946
947ifdef VBOX_WITH_VDE
948 Drivers_SOURCES += \
949 Network/DrvVDE.cpp \
950 Network/VDEPlug.cpp
951 Drivers_DEFS += \
952 VBOX_WITH_VDE
953endif
954
955# -- OS specific --
956
957ifeq ($(KBUILD_TARGET),darwin)
958Drivers_SOURCES := $(filter-out \
959 Storage/DrvHostRaw% \
960 Storage/DrvHostFloppy% \
961 , $(Drivers_SOURCES)) \
962 Audio/coreaudio.c
963Drivers_SOURCES.darwin = \
964 Serial/DrvHostSerial.cpp
965endif # darwin
966
967ifeq ($(KBUILD_TARGET),freebsd)
968Drivers_SOURCES := $(filter-out \
969 Storage/DrvHostFloppy% \
970 , $(Drivers_SOURCES)) \
971 Audio/ossaudio.c \
972 Serial/DrvHostSerial.cpp
973Drivers_SOURCES.freebsd = \
974 Network/DrvTAP.cpp
975endif # freebsd
976
977
978ifeq ($(KBUILD_TARGET),l4)
979Drivers_SOURCES = \
980 Input/DrvMouseQueue.cpp \
981 Input/DrvKeyboardQueue.cpp \
982 Storage/DrvBlock.cpp \
983 Storage/DrvMediaISO.cpp \
984 Storage/DrvRawImage.cpp \
985 Storage/DrvHostBase.cpp \
986 Storage/DrvHostDVD.cpp \
987 Storage/DrvVD.cpp \
988 PC/DrvACPI.cpp \
989 Network/DrvIntNet.cpp \
990 Network/DHCPServerRunner.cpp \
991 Network/DrvNetSniffer.cpp \
992 Network/Pcap.cpp \
993 Audio/audio.c \
994 Audio/mixeng.c \
995 Audio/noaudio.c \
996 Audio/audiosniffer.c
997
998Drivers_SOURCES.l4 = \
999 Audio/ossaudio.c
1000endif # l4
1001
1002Drivers_SOURCES.linux = \
1003 Network/DrvTAP.cpp \
1004 Audio/ossaudio.c \
1005 Parallel/DrvHostParallel.cpp \
1006 Serial/DrvHostSerial.cpp
1007
1008ifeq ($(KBUILD_TARGET),os2)
1009Drivers_SOURCES := $(filter-out \
1010 Storage/DrvHost% \
1011 , $(Drivers_SOURCES))
1012endif
1013
1014ifeq ($(KBUILD_TARGET),solaris)
1015Drivers_SOURCES := $(filter-out \
1016 Storage/DrvHost% \
1017 , $(Drivers_SOURCES))
1018Drivers_SOURCES.solaris = \
1019 Audio/solaudio.c \
1020 Storage/DrvHostBase.cpp \
1021 Storage/DrvHostDVD.cpp \
1022 Serial/DrvHostSerial.cpp
1023 ifdef VBOX_WITH_SOLARIS_OSS
1024 Drivers_SOURCES += Audio/ossaudio.c
1025 Drivers_DEFS += VBOX_WITH_SOLARIS_OSS
1026 endif
1027 ifdef VBOX_WITH_CROSSBOW
1028 Drivers_SOURCES += Network/solaris/vbox-libdlpi.cpp
1029 Drivers_DEFS += VBOX_WITH_CROSSBOW
1030 endif
1031 ifdef VBOX_WITH_SUID_WRAPPER
1032 Drivers_DEFS += VBOX_WITH_SUID_WRAPPER
1033 endif
1034endif
1035
1036Drivers_SOURCES.win = \
1037 Audio/dsoundaudio.c \
1038 Serial/DrvHostSerial.cpp
1039
1040if defined(VBOX_WITH_NETFLT)
1041 if defined(VBOX_NETFLT_ONDEMAND_BIND)
1042 Drivers_DEFS.win += VBOX_NETFLT_ONDEMAND_BIND
1043 endif
1044endif
1045
1046# -- features --
1047
1048ifdef VBOX_WITH_ISCSI
1049 VBoxDDU_SOURCES += \
1050 Storage/ISCSIHDDCore.cpp
1051 VBoxDDU_DEFS += VBOX_WITH_ISCSI
1052 Storage/DrvVD.cpp_INCS = \
1053 Network/lwip/src/include \
1054 Network/lwip/src/include/ipv4 \
1055 Network/lwip/vbox/include
1056endif # VBOX_WITH_ISCSI
1057
1058ifdef VBOX_WITH_ALSA
1059 Drivers_DEFS.linux += VBOX_WITH_ALSA
1060 Drivers_SOURCES.linux+= \
1061 Audio/alsaaudio.c \
1062 Audio/alsa_stubs.c
1063endif
1064
1065ifdef VBOX_WITH_PULSE
1066 Drivers_DEFS.linux += VBOX_WITH_PULSE
1067 Drivers_SOURCES.linux+= \
1068 Audio/pulseaudio.c \
1069 Audio/pulse_stubs.c
1070 Drivers_DEFS.freebsd += VBOX_WITH_PULSE
1071 Drivers_SOURCES.freebsd+= \
1072 Audio/pulseaudio.c \
1073 Audio/pulse_stubs.c
1074endif
1075
1076ifdef VBOX_WITH_VUSB
1077 Drivers_DEFS += VBOX_WITH_VUSB
1078 Drivers_SOURCES += \
1079 USB/DrvVUSBRootHub.cpp \
1080 USB/VUSBDevice.cpp \
1081 USB/VUSBReadAhead.cpp \
1082 USB/VUSBUrb.cpp
1083
1084endif # VBOX_WITH_VUSB
1085
1086ifdef VBOX_WITH_USB
1087 Drivers_DEFS += VBOX_WITH_USB
1088
1089 ifdef VBOX_WITH_VRDP
1090 Drivers_DEFS += VBOX_WITH_VRDP
1091 Drivers_SOURCES += \
1092 USB/vrdp/USBProxyDevice-vrdp.cpp
1093 endif
1094
1095 Drivers_DEFS.darwin += VUSB_HAVE_USBPROXY_DEVICE
1096 ifdef VBOX_WITH_NEW_USB_CODE_ON_DARWIN
1097 Drivers_DEFS.darwin += VBOX_WITH_NEW_USB_CODE_ON_DARWIN
1098 endif
1099 Drivers_SOURCES.darwin += \
1100 USB/USBProxyDevice.cpp \
1101 USB/darwin/USBProxyDevice-darwin.cpp
1102
1103 Drivers_DEFS.linux += \
1104 VUSB_HAVE_USBPROXY_DEVICE \
1105 $(if $(VBOX_WITH_LINUX_COMPILER_H),VBOX_WITH_LINUX_COMPILER_H,) \
1106 $(if $(VBOX_USB_WITH_SYSFS),VBOX_USB_WITH_SYSFS,)
1107 Drivers_SOURCES.linux += \
1108 USB/USBProxyDevice.cpp \
1109 USB/linux/USBProxyDevice-linux.cpp
1110
1111 Drivers_DEFS.l4 += VUSB_HAVE_USBPROXY_DEVICE
1112 Drivers_SOURCES.l4 += \
1113 USB/USBProxyDevice.cpp \
1114 USB/linux/USBProxyDevice-linux.cpp
1115
1116 Drivers_DEFS.os2 += VUSB_HAVE_USBPROXY_DEVICE
1117 Drivers_INCS.os2 += $(PATH_ROOT)/src/VBox/HostDrivers/VBoxUSB/os2
1118 Drivers_SOURCES.os2 += \
1119 USB/USBProxyDevice.cpp \
1120 USB/os2/USBProxyDevice-os2.cpp
1121
1122 Drivers_DEFS.win += VUSB_HAVE_USBPROXY_DEVICE
1123 Drivers_SOURCES.win += \
1124 USB/USBProxyDevice.cpp \
1125 USB/win/USBProxyDevice-win.cpp
1126
1127 Drivers_DEFS.solaris += VUSB_HAVE_USBPROXY_DEVICE
1128 Drivers_SOURCES.solaris += \
1129 USB/USBProxyDevice.cpp \
1130 USB/solaris/$(if $(VBOX_WITH_NEW_USB_CODE_ON_SOLARIS),USBProxyDevice2-solaris.cpp,USBProxyDevice-solaris.cpp)
1131
1132 Drivers_DEFS.freebsd += VUSB_HAVE_USBPROXY_DEVICE
1133 Drivers_SOURCES.freebsd += \
1134 USB/USBProxyDevice.cpp \
1135 USB/freebsd/USBProxyDevice-freebsd.cpp
1136
1137 ifdef VBOX_WITH_SCSI
1138 Drivers_SOURCES += \
1139 Storage/UsbMsd.cpp
1140 endif
1141
1142endif # VBOX_WITH_USB
1143
1144ifdef VBOX_WITH_PDM_ASYNC_COMPLETION
1145 Drivers_DEFS += VBOX_WITH_PDM_ASYNC_COMPLETION
1146endif #VBOX_WITH_PDM_ASYNC_COMPLETION
1147
1148ifdef VBOX_WITH_SCSI
1149 Drivers_DEFS += VBOX_WITH_SCSI
1150 Drivers_SOURCES += \
1151 Storage/DrvSCSI.cpp
1152 Drivers_SOURCES.linux += \
1153 Storage/DrvSCSIHost.cpp
1154endif # VBOX_WITH_SCSI
1155
1156#
1157# Ring-0 Services (library, linked into VMMR0.r0)
1158#
1159ServicesR0_TEMPLATE = VBoxR0
1160ServicesR0_DEFS = IN_INTNET_R0 IN_RT_R0
1161ServicesR0_SOURCES = \
1162 Network/SrvIntNetR0.cpp
1163
1164
1165#
1166# Internal Networking - Ring-3 Testcase for the Ring-0 code (a bit hackish).
1167#
1168ifdef VBOX_WITH_TESTCASES
1169 PROGRAMS += tstIntNetR0
1170 tstIntNetR0_TEMPLATE = VBOXR3TSTEXE
1171 tstIntNetR0_DEFS = IN_INTNET_R0
1172 tstIntNetR0_SOURCES = \
1173 Network/testcase/tstIntNetR0.cpp
1174endif
1175
1176#
1177# Internal Networking - Ring-3 Testcase for the Ring-0 code (a bit hackish).
1178#
1179ifdef VBOX_WITH_TESTCASES
1180 PROGRAMS += tstIntNet-1
1181 tstIntNet-1_TEMPLATE = VBOXR3TSTEXE
1182 tstIntNet-1_SOURCES = \
1183 Network/testcase/tstIntNet-1.cpp \
1184 Network/Pcap.cpp
1185endif
1186
1187
1188#
1189# EEPROM device unit test requires cppunit
1190#
1191ifdef VBOX_WITH_CPPUNIT_TESTCASES
1192ifdef VBOX_WITH_E1000
1193 PROGRAMS += tstDevEEPROM
1194 tstDevEEPROM_TEMPLATE = VBOXCPPUNITEXE
1195 tstDevEEPROM_SOURCES = \
1196 Network/testcase/tstDevEEPROM.cpp
1197 tstDevEEPROM_LIBS = \
1198 $(TARGET_DevicesR3)
1199 PROGRAMS += tstDevPhy
1200 tstDevPhy_TEMPLATE = VBOXCPPUNITEXE
1201 tstDevPhy_SOURCES = \
1202 Network/testcase/tstDevPhy.cpp \
1203 Network/DevE1000Phy.cpp
1204 tstDevPhy_DEFS = PHY_UNIT_TEST
1205endif
1206endif
1207
1208include $(KBUILD_PATH)/subfooter.kmk
1209
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