VirtualBox

source: vbox/trunk/src/VBox/Additions/WINNT/Graphics/Video/mp/Makefile.kmk@ 94524

Last change on this file since 94524 was 94524, checked in by vboxsync, 3 years ago

WDDM: rename and enable D3D context in miniport. bugref:9845

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 6.2 KB
Line 
1# $Id: Makefile.kmk 94524 2022-04-08 05:19:50Z vboxsync $
2## @file
3# Makefile for the Windows guest miniport driver.
4#
5
6#
7# Copyright (C) 2011-2022 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
21ifdef VBOX_WITH_MESA3D
22 ifndef VBOX_MESA3D_CONFIG_KMK_INCLUDED
23 include $(PATH_ROOT)/src/VBox/Additions/3D/Config.kmk
24 endif
25endif
26
27#
28# VBoxVideo - Windows Guest Additions XPDM Miniport Video Driver
29#
30# Note. This has to run on NT4! (*_NT4 => *_W2K3 when targeting 64-bit.)
31#
32SYSMODS += VBoxVideo
33VBoxVideo_TEMPLATE = VBOXGUESTR0
34VBoxVideo_SDKS = ReorderCompilerIncs $(VBOX_WINDDK_GST_NT4)
35VBoxVideo_DEFS = VBOX_XPDM_MINIPORT VBOX_WITH_8BPP_MODES VBOX_USING_$(VBOX_WINDDK_GST_NT4)
36VBoxVideo_DEFS += LOG_TO_BACKDOOR #LOG_ENABLED
37VBoxVideo_DEFS += VBOX_SVN_REV=$(VBOX_SVN_REV)
38ifdef VBOX_WITH_VIDEOHWACCEL
39 VBoxVideo_DEFS += VBOX_WITH_VIDEOHWACCEL
40endif
41VBoxVideo_INCS = \
42 ../../../include \
43 .. \
44 . \
45 $(VBOX_GRAPHICS_INCS)
46VBoxVideo_LDFLAGS.x86 = /Entry:DriverEntry@8
47VBoxVideo_LDFLAGS.amd64 = /Entry:DriverEntry
48VBoxVideo_SOURCES = \
49 xpdm/VBoxMPDriver.cpp \
50 xpdm/VBoxMP.def \
51 xpdm/VBoxMP.rc \
52 xpdm/VBoxMPVideoPortAPI.cpp \
53 xpdm/VBoxMPInternal.cpp \
54 xpdm/VBoxMPRegistry.cpp \
55 xpdm/VBoxMPIOCTL.cpp \
56 common/VBoxMPUtils.cpp \
57 common/VBoxMPCommon.cpp \
58 common/VBoxMPHGSMI.cpp \
59 common/VBoxMPVidModes.cpp \
60 $(PATH_ROOT)/src/VBox/Additions/common/VBoxVideo/HGSMIBase.cpp \
61 $(PATH_ROOT)/src/VBox/Additions/common/VBoxVideo/HGSMIBuffers.cpp \
62 $(PATH_ROOT)/src/VBox/Additions/common/VBoxVideo/HGSMIHostCmd.cpp \
63 $(PATH_ROOT)/src/VBox/Additions/common/VBoxVideo/Modesetting.cpp
64VBoxVideo_LIBS = \
65 $(PATH_SDK_$(VBOX_WINDDK_GST)_LIB)/videoprt.lib \
66 $(PATH_SDK_$(VBOX_WINDDK_GST)_LIB)/ntoskrnl.lib \
67 $(PATH_SDK_$(VBOX_WINDDK_GST)_LIB)/hal.lib \
68 $(VBOX_LIB_VBGL_R0) \
69 $(VBOX_LIB_IPRT_GUEST_R0_NT4) \
70 $(VBOX_PATH_ADDITIONS_LIB)/HGSMIGuestR0Lib$(VBOX_SUFF_LIB)
71ifeq ($(KBUILD_TARGET_ARCH),x86)
72 VBoxVideo_LIBS += \
73 $(PATH_SDK_$(VBOX_WINDDK_GST_NT4)_LIB)/exsup.lib \
74 $(PATH_SDK_$(VBOX_WINDDK_GST)_LIB)/BufferOverflowK.lib # Needed for ___security_cookie.
75endif
76VBoxVideo_USES.win = vboximportchecker
77VBoxVideo_VBOX_IMPORT_CHECKER.win.x86 = nt4/r0
78VBoxVideo_VBOX_IMPORT_CHECKER.win.amd64 = xp64/r0
79
80ifdef VBOX_WITH_WDDM
81 #
82 # VBoxWddm - Windows Guest Additions WDDM Miniport Video Driver
83 #
84 SYSMODS += VBoxWddm
85 VBoxWddm_TEMPLATE = VBOXGUESTR0
86 VBoxWddm_SDKS = $(VBOX_WINDDK_GST_W8)
87 VBoxWddm_DEFS += VBOX_WDDM_MINIPORT VBOX_WITH_WDDM VBOX_WITH_HGCM
88 # WIN9X_COMPAT_SPINLOCK inlines KeInitializeSpinLock in W8 DDK (Windows 7 or older ntoskrnl does not export it).
89 VBoxWddm_DEFS += WIN9X_COMPAT_SPINLOCK
90 VBoxWddm_DEFS += VBOX_WITH_8BPP_MODES
91 ifdef VBOX_WITH_VIDEOHWACCEL
92 VBoxWddm_DEFS += VBOX_WITH_VIDEOHWACCEL
93 endif
94 ifdef VBOXWDDM_WITH_VBVA
95 VBoxWddm_DEFS += VBOXWDDM_WITH_VBVA
96 VBoxWddm_DEFS += VBOXWDDM_RENDER_FROM_SHADOW
97 ifdef VBOXVDMA_WITH_VBVA
98 VBoxWddm_DEFS += VBOXVDMA_WITH_VBVA
99 endif
100 endif
101 VBoxWddm_DEFS += LOG_TO_BACKDOOR
102 VBoxWddm_DEFS += VBOX_SVN_REV=$(VBOX_SVN_REV)
103 VBoxWddm_INCS += \
104 ../../../include \
105 .. \
106 . \
107 $(VBOX_GRAPHICS_INCS)
108
109 VBoxWddm_LDFLAGS.x86 += /Entry:DriverEntry@8
110 VBoxWddm_LDFLAGS.amd64 += /Entry:DriverEntry
111
112 VBoxWddm_SOURCES = \
113 wddm/VBoxMPWddm.cpp \
114 wddm/VBoxMPLegacy.cpp \
115 wddm/VBoxMPVidPn.cpp \
116 wddm/VBoxMPVdma.cpp \
117 wddm/VBoxMPShgsmi.cpp \
118 wddm/VBoxMPCm.cpp \
119 wddm/VBoxMPSa.cpp \
120 wddm/VBoxMPMisc.cpp \
121 wddm/VBoxWddm.rc \
122 wddm/VBoxMPRegistry.cpp \
123 wddm/VBoxMPVModes.cpp \
124 common/VBoxMPUtils.cpp \
125 common/VBoxMPCommon.cpp \
126 common/VBoxMPHGSMI.cpp \
127 $(PATH_ROOT)/src/VBox/Additions/common/VBoxVideo/HGSMIBase.cpp \
128 $(PATH_ROOT)/src/VBox/Additions/common/VBoxVideo/HGSMIBuffers.cpp \
129 $(PATH_ROOT)/src/VBox/Additions/common/VBoxVideo/HGSMIHostCmd.cpp \
130 $(PATH_ROOT)/src/VBox/Additions/common/VBoxVideo/VBVABase.cpp \
131 $(PATH_ROOT)/src/VBox/Additions/common/VBoxVideo/Modesetting.cpp
132
133 ifdef VBOXWDDM_WITH_VBVA
134 VBoxWddm_SOURCES += \
135 wddm/VBoxMPVbva.cpp
136 endif
137 ifdef VBOX_WITH_VIDEOHWACCEL
138 VBoxWddm_SOURCES += \
139 wddm/VBoxMPVhwa.cpp
140 endif
141
142 VBoxWddm_LIBS = \
143 $(PATH_SDK_$(VBOX_WINDDK_GST_W8)_LIB)/BufferOverflowK.lib \
144 $(PATH_SDK_$(VBOX_WINDDK_GST_W8)_LIB)/ntoskrnl.lib \
145 $(PATH_SDK_$(VBOX_WINDDK_GST_W8)_LIB)/hal.lib \
146 $(PATH_SDK_$(VBOX_WINDDK_GST_W8)_LIB)/displib.lib \
147 $(VBOX_LIB_VBGL_R0) \
148 $(VBOX_LIB_IPRT_GUEST_R0) \
149 $(VBOX_PATH_ADDITIONS_LIB)/HGSMIGuestR0Lib$(VBOX_SUFF_LIB)
150
151 VBoxWddm_LIBS.x86 = \
152 $(PATH_SDK_$(VBOX_WINDDK_GST_W8)_LIB)/memcmp.lib
153
154 ifdef VBOX_WITH_MESA3D
155 VBoxWddm_DEFS += VBOX_WITH_MESA3D
156 VBoxWddm_DEFS += __STDC_VERSION__=0 # for mesa include/c99_compat.h
157 VBoxWddm_DEFS += WIN9X_COMPAT_SPINLOCK # to avoid multiple KeInitializeSpinLock on amd64
158 VBoxWddm_INCS += \
159 $(VBOX_PATH_3D)/win/include \
160 $(VBOX_PATH_VMSVGA_INC)
161 VBoxWddm_SOURCES += \
162 wddm/gallium/Svga.cpp \
163 wddm/gallium/SvgaCmd.cpp \
164 wddm/gallium/SvgaFifo.cpp \
165 wddm/gallium/SvgaHostObjects.cpp \
166 wddm/gallium/SvgaHw.cpp \
167 wddm/gallium/VBoxMPGaFence.cpp \
168 wddm/gallium/VBoxMPGaUtils.cpp \
169 wddm/gallium/VBoxMPGaWddm.cpp
170 endif
171
172 ifdef VBOX_WITH_VMSVGA3D_DX
173 VBoxWddm_DEFS += VBOX_WITH_VMSVGA3D_DX
174 endif
175
176endif # VBOX_WITH_WDDM
177
178#
179# Signing requires both miniport and display drivers
180# so it'd be dealt with in the parent makefile.
181#
182ifdef VBOX_SIGN_ADDITIONS
183 VBoxVideo_INSTTYPE = none
184 VBoxVideo_DEBUG_INSTTYPE = both
185 ifdef VBOX_WITH_WDDM
186 VBoxWddm_INSTTYPE = none
187 VBoxWddm_DEBUG_INSTTYPE = both
188 endif
189endif # VBOX_SIGN_ADDITIONS
190
191include $(FILE_KBUILD_SUB_FOOTER)
192
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