VirtualBox

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

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

Audio/HDA: flexible audio format support (disabled).

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