VirtualBox

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

Last change on this file since 42355 was 42310, checked in by vboxsync, 12 years ago

VBoxDD: Use dxguid.lib from the DDK instead of the DirectX SDK.

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