1 | # $Id: Makefile.kmk 62522 2016-07-22 19:17:25Z vboxsync $
|
---|
2 | ## @file
|
---|
3 | # Makefile for the Windows guest display driver.
|
---|
4 | #
|
---|
5 |
|
---|
6 | #
|
---|
7 | # Copyright (C) 2011-2016 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 |
|
---|
18 | SUB_DEPTH = ../../../../../../..
|
---|
19 | include $(KBUILD_PATH)/subheader.kmk
|
---|
20 |
|
---|
21 | #
|
---|
22 | # VBoxDisp - Windows Guest Additions XPDM Display Driver
|
---|
23 | #
|
---|
24 | # Note. This has to run on NT4! (*_NT4 => *_W2K3 when targeting 64-bit.)
|
---|
25 | #
|
---|
26 | SYSMODS += VBoxDisp
|
---|
27 | VBoxDisp_TEMPLATE = VBOXGUESTR0
|
---|
28 | VBoxDisp_SYSSUFF = .dll
|
---|
29 | VBoxDisp_SDKS = ReorderCompilerIncs $(VBOX_WINDDK_GST_NT4)
|
---|
30 | VBoxDisp_DEFS.x86 = _WIN32_WINNT=0x0501
|
---|
31 | VBoxDisp_DEFS = VBOX_WITH_DDRAW
|
---|
32 | VBoxDisp_DEFS += LOG_TO_BACKDOOR #LOG_ENABLED
|
---|
33 | ifdef VBOX_WITH_VIDEOHWACCEL
|
---|
34 | VBoxDisp_DEFS += VBOX_WITH_VIDEOHWACCEL
|
---|
35 | endif
|
---|
36 | ifdef VBOX_WITH_CROGL
|
---|
37 | VBoxDisp_DEFS += VBOX_WITH_CROGL
|
---|
38 | endif
|
---|
39 | #VBoxDisp_DEFS += VBOX_VBVA_ADJUST_RECT
|
---|
40 | VBoxDisp_INCS = ../../../include ..
|
---|
41 | VBoxDisp_LDFLAGS.x86 = /Entry:DrvEnableDriver@12
|
---|
42 | VBoxDisp_LDFLAGS.amd64 = /Entry:DrvEnableDriver
|
---|
43 | VBoxDisp_SOURCES = \
|
---|
44 | xpdm/VBoxDispDriver.cpp \
|
---|
45 | xpdm/VBoxDispMini.cpp \
|
---|
46 | xpdm/VBoxDispMouse.cpp \
|
---|
47 | xpdm/VBoxDispPalette.cpp \
|
---|
48 | xpdm/VBoxDispVBVA.cpp \
|
---|
49 | xpdm/VBoxDispDrawCmd.cpp \
|
---|
50 | xpdm/VBoxDispVRDP.cpp \
|
---|
51 | xpdm/VBoxDispVrdpBmp.cpp \
|
---|
52 | xpdm/VBoxDispVrdpTxt.cpp \
|
---|
53 | xpdm/VBoxDispDriverDDraw.cpp \
|
---|
54 | xpdm/VBoxDispDDraw.cpp \
|
---|
55 | xpdm/VBoxDisp.def \
|
---|
56 | xpdm/VBoxDisp.rc \
|
---|
57 | $(PATH_ROOT)/src/VBox/Additions/common/VBoxVideo/HGSMIBase.cpp \
|
---|
58 | $(PATH_ROOT)/src/VBox/Additions/common/VBoxVideo/VBVABase.cpp \
|
---|
59 | $(PATH_ROOT)/src/VBox/Additions/common/VBoxVideo/Modesetting.cpp
|
---|
60 | ifdef VBOX_WITH_VIDEOHWACCEL
|
---|
61 | VBoxDisp_SOURCES += \
|
---|
62 | xpdm/VBoxDispVHWA.cpp \
|
---|
63 | xpdm/VBoxDispDDrawVHWA.cpp
|
---|
64 | endif
|
---|
65 | VBoxDisp_LIBS = \
|
---|
66 | $(PATH_SDK_$(VBOX_WINDDK_GST_NT4)_LIB)/win32k.lib \
|
---|
67 | $(VBOX_LIB_IPRT_GUEST_R0_NT4) \
|
---|
68 | $(VBOX_PATH_ADDITIONS_LIB)/HGSMIGuestR0Lib$(VBOX_SUFF_LIB)
|
---|
69 |
|
---|
70 | # Signing requires both miniport and display drivers
|
---|
71 | # so it'd be dealt with in the parent makefile.
|
---|
72 | ifdef VBOX_SIGN_ADDITIONS
|
---|
73 | VBoxDisp_INSTTYPE = none
|
---|
74 | VBoxDisp_DEBUG_INSTTYPE = both
|
---|
75 | ifdef VBOX_WITH_WDDM
|
---|
76 | VBoxDispD3D_INSTTYPE = none
|
---|
77 | VBoxDispD3D_DEBUG_INSTTYPE = both
|
---|
78 | endif
|
---|
79 | endif
|
---|
80 |
|
---|
81 | ifdef VBOX_WITH_WDDM
|
---|
82 | #
|
---|
83 | # VBoxDispD3D - Windows Guest Additions WDDM R3 Display Driver
|
---|
84 | #
|
---|
85 | DLLS += VBoxDispD3D
|
---|
86 | VBoxDispD3D_TEMPLATE = VBOXGUESTR3DLL
|
---|
87 | VBoxDispD3D_SDKS = ReorderCompilerIncs $(VBOX_WINDDK_GST_WLH)
|
---|
88 | VBoxDispD3D_DEFS = UNICODE _UNICODE VBOX_WITH_WDDM VBOXWDDMDISP LOG_TO_BACKDOOR LOG_TO_BACKDOOR_DRV VBOX_WITH_HGCM D3D_UMD_INTERFACE_VERSION=0x000C
|
---|
89 | ifdef DEBUG_misha
|
---|
90 | VBoxDispD3D_DEFS += LOG_ENABLED
|
---|
91 | endif
|
---|
92 | ifdef VBOXWDDM_WITH_VBVA
|
---|
93 | VBoxDispD3D_DEFS += VBOXWDDM_WITH_VBVA
|
---|
94 | endif
|
---|
95 | ifdef VBOX_WITH_VIDEOHWACCEL
|
---|
96 | VBoxDispD3D_DEFS += VBOX_WITH_VIDEOHWACCEL
|
---|
97 | endif
|
---|
98 | ifdef VBOX_WDDMDISP_WITH_PROFILE
|
---|
99 | VBoxDispD3D_DEFS += VBOX_WDDMDISP_WITH_PROFILE
|
---|
100 | endif
|
---|
101 | ifdef VBOXWDDM_TEST_UHGSMI
|
---|
102 | VBoxDispD3D_DEFS += VBOXWDDM_TEST_UHGSMI
|
---|
103 | endif
|
---|
104 | ifdef VBOX_WITH_CROGL
|
---|
105 | VBoxDispD3D_DEFS += VBOX_WITH_CROGL
|
---|
106 | endif
|
---|
107 | VBoxDispD3D_INCS = \
|
---|
108 | ../../../include \
|
---|
109 | .. \
|
---|
110 | $(VBOX_PATH_CROGL_INCLUDE)
|
---|
111 | VBoxDispD3D_SOURCES = \
|
---|
112 | wddm/VBoxDispD3D.cpp \
|
---|
113 | wddm/VBoxDispD3DIf.cpp \
|
---|
114 | wddm/VBoxDispCm.cpp \
|
---|
115 | wddm/VBoxDispKmt.cpp \
|
---|
116 | wddm/VBoxDispDbg.cpp \
|
---|
117 | wddm/VBoxD3DIf.cpp \
|
---|
118 | wddm/VBoxDispD3D.rc \
|
---|
119 | wddm/VBoxDispD3D.def
|
---|
120 | ifdef VBOX_WITH_CRHGSMI
|
---|
121 | VBoxDispD3D_DEFS += VBOX_WITH_CRHGSMI
|
---|
122 | endif
|
---|
123 | VBoxDispD3D_LIBS = \
|
---|
124 | $(VBOX_LIB_IPRT_GUEST_R3) \
|
---|
125 | $(VBOX_LIB_VBGL_R3) \
|
---|
126 | Psapi.lib \
|
---|
127 | $(VBOX_PATH_ADDITIONS_LIB)/VBoxDispMpLogger$(VBOX_SUFF_LIB) \
|
---|
128 | $(VBOX_PATH_ADDITIONS_LIB)/VBoxCrHgsmi$(VBOX_SUFF_LIB)
|
---|
129 |
|
---|
130 | #
|
---|
131 | # 64-bit systems needs a 32-bit version of VBoxDispD3D.
|
---|
132 | #
|
---|
133 | DLLS.amd64 += VBoxDispD3D-x86
|
---|
134 | VBoxDispD3D-x86_EXTENDS = VBoxDispD3D
|
---|
135 | VBoxDispD3D-x86_BLD_TRG_ARCH = x86
|
---|
136 | VBoxDispD3D-x86_LIBS = \
|
---|
137 | $(VBOX_LIB_IPRT_GUEST_R3_X86) \
|
---|
138 | $(VBOX_LIB_VBGL_R3_X86) \
|
---|
139 | Psapi.lib \
|
---|
140 | $(VBOX_PATH_ADDITIONS_LIB)/VBoxDispMpLogger-x86$(VBOX_SUFF_LIB) \
|
---|
141 | $(VBOX_PATH_ADDITIONS_LIB)/VBoxCrHgsmi-x86$(VBOX_SUFF_LIB)
|
---|
142 | VBoxDispD3D-x86_DEFS = $(VBoxDispD3D_DEFS) VBOX_WDDM_WOW64
|
---|
143 |
|
---|
144 | ifdef VBOX_WITH_CRHGSMI
|
---|
145 | #
|
---|
146 | # VBoxCrHgsmi - Chromium HGSMI API library
|
---|
147 | #
|
---|
148 | LIBRARIES += VBoxCrHgsmi
|
---|
149 | VBoxCrHgsmi_TEMPLATE = VBOXGUESTR3LIB
|
---|
150 | VBoxCrHgsmi_SDKS = ReorderCompilerIncs $(VBOX_WINDDK_GST_WLH)
|
---|
151 | #use same defines as VBoxDispD3D to ensure structure definitions match
|
---|
152 | VBoxCrHgsmi_DEFS = $(subst VBOXWDDMDISP,IN_VBOXCRHGSMI,$(VBoxDispD3D_DEFS))
|
---|
153 | VBoxCrHgsmi_INCS = ../../../include .. $(VBOX_PATH_CROGL_INCLUDE)
|
---|
154 | VBoxCrHgsmi_SOURCES = \
|
---|
155 | wddm/VBoxCrHgsmi.cpp \
|
---|
156 | wddm/VBoxDispKmt.cpp \
|
---|
157 | wddm/VBoxDispDbg.cpp \
|
---|
158 | wddm/VBoxUhgsmiKmt.cpp \
|
---|
159 | wddm/VBoxUhgsmiBase.cpp \
|
---|
160 | wddm/VBoxUhgsmiDisp.cpp
|
---|
161 |
|
---|
162 | #
|
---|
163 | # 64-bit systems needs a 32-bit version of VBoxCrHgsmi.
|
---|
164 | #
|
---|
165 | LIBRARIES.amd64 += VBoxCrHgsmi-x86
|
---|
166 | VBoxCrHgsmi-x86_TEMPLATE = VBOXGUESTR3LIB
|
---|
167 | VBoxCrHgsmi-x86_EXTENDS = VBoxCrHgsmi
|
---|
168 | VBoxCrHgsmi-x86_BLD_TRG_ARCH = x86
|
---|
169 | VBoxCrHgsmi-x86_DEFS = $(VBoxCrHgsmi_DEFS) VBOX_WDDM_WOW64
|
---|
170 | endif #VBOX_WITH_CRHGSMI
|
---|
171 |
|
---|
172 | #
|
---|
173 | # VBoxDispMpLogger - display backdoor logger library
|
---|
174 | #
|
---|
175 | LIBRARIES += VBoxDispMpLogger
|
---|
176 | VBoxDispMpLogger_TEMPLATE = VBOXGUESTR3LIB
|
---|
177 | VBoxDispMpLogger_SDKS = ReorderCompilerIncs $(VBOX_WINDDK_GST_WLH)
|
---|
178 | VBoxDispMpLogger_DEFS = UNICODE _UNICODE VBOX_WITH_CRHGSMI IN_VBOXCRHGSMI VBOX_WITH_WDDM VBOX_WITH_VDMA VBOX_WITH_HGCM
|
---|
179 | VBoxDispMpLogger_INCS = ../../../include ..
|
---|
180 | VBoxDispMpLogger_SOURCES = \
|
---|
181 | wddm/VBoxDispMpLogger.cpp
|
---|
182 |
|
---|
183 | #
|
---|
184 | # 64-bit systems needs a 32-bit version of VBoxCrHgsmi.
|
---|
185 | #
|
---|
186 | LIBRARIES.amd64 += VBoxDispMpLogger-x86
|
---|
187 | VBoxDispMpLogger-x86_TEMPLATE = VBOXGUESTR3LIB
|
---|
188 | VBoxDispMpLogger-x86_EXTENDS = VBoxDispMpLogger
|
---|
189 | VBoxDispMpLogger-x86_BLD_TRG_ARCH = x86
|
---|
190 | VBoxDispMpLogger-x86_DEFS = $(VBoxDispMpLogger_DEFS) VBOX_WDDM_WOW64
|
---|
191 |
|
---|
192 | endif #ifdef VBOX_WITH_WDDM
|
---|
193 |
|
---|
194 | ifdef VBOXVIDEOWINDBG
|
---|
195 | DLLS += vbvdbg
|
---|
196 | vbvdbg_TEMPLATE = VBOXR3STATIC
|
---|
197 | vbvdbg_SDKS = ReorderCompilerIncs $(VBOX_WINDDK_GST_WLH)
|
---|
198 | vbvdbg_DEFS = UNICODE _UNICODE
|
---|
199 | vbvdbg_SOURCES = \
|
---|
200 | wddm/dbg/VBoxVideoWinDbg.cpp \
|
---|
201 | wddm/dbg/VBoxVideoWinDbg.def
|
---|
202 |
|
---|
203 | PROGRAMS += tstMvWnd
|
---|
204 | tstMvWnd_TEMPLATE = VBOXR3EXE
|
---|
205 | tstMvWnd_DEFS = UNICODE _UNICODE
|
---|
206 | tstMvWnd_SOURCES = \
|
---|
207 | wddm/dbg/tstMvWnd.cpp
|
---|
208 | tstMvWnd_LIBS = $(VBOX_LIB_IPRT_GUEST_R3)
|
---|
209 | tstMvWnd_LDFLAGS.win = /SUBSYSTEM:windows
|
---|
210 |
|
---|
211 | PROGRAMS += DumpD3DCaps9
|
---|
212 | DumpD3DCaps9_TEMPLATE = VBOXR3EXE
|
---|
213 | DumpD3DCaps9_SDKS = ReorderCompilerIncs $(VBOX_WINDDK_GST_WLH)
|
---|
214 | DumpD3DCaps9_DEFS = UNICODE _UNICODE
|
---|
215 | DumpD3DCaps9_SOURCES = \
|
---|
216 | wddm/dbg/DumpD3DCaps9.cpp
|
---|
217 | DumpD3DCaps9_LIBS = $(VBOX_LIB_IPRT_GUEST_R3) d3d9.lib
|
---|
218 | DumpD3DCaps9_LDFLAGS.win = /SUBSYSTEM:CONSOLE
|
---|
219 |
|
---|
220 | PROGRAMS += D3DFeatureLevel
|
---|
221 | D3DFeatureLevel_TEMPLATE = VBOXR3EXE
|
---|
222 | D3DFeatureLevel_SDKS = ReorderCompilerIncs $(VBOX_WINDDK_GST_WLH)
|
---|
223 | D3DFeatureLevel_SOURCES = \
|
---|
224 | wddm/dbg/D3DFeatureLevel.cpp
|
---|
225 | D3DFeatureLevel_LIBS = $(VBOX_LIB_IPRT_GUEST_R3) d3d11.lib
|
---|
226 | D3DFeatureLevel_LDFLAGS.win = /SUBSYSTEM:CONSOLE
|
---|
227 |
|
---|
228 | endif #VBOXVIDEOWINDBG
|
---|
229 |
|
---|
230 | include $(FILE_KBUILD_SUB_FOOTER)
|
---|