VirtualBox

source: vbox/trunk/src/VBox/Additions/WINNT/Graphics/Wine_new/Makefile.kmk@ 65381

Last change on this file since 65381 was 65381, checked in by vboxsync, 8 years ago

bugref:8282: Additions/linux: submit DRM driver to the Linux kernel: move all graphics device-related header files to a separate sub-directory and add that to the include path where they are needed. The intention is too be able to remove the VBox/ include folder in the DRM driver package.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 11.4 KB
Line 
1# $Id: Makefile.kmk 65381 2017-01-20 09:23:53Z vboxsync $
2## @file
3# Makefile for the Wine D3D related dlls for VirtualBox.
4#
5
6#
7# Copyright (C) 2009-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
19SUB_DEPTH = ../../../../../..
20include $(KBUILD_PATH)/subheader.kmk
21
22#
23# Template for building wine stuff.
24#
25TEMPLATE_VBoxGuestWineDLL = Template for building a wine DLL.
26TEMPLATE_VBoxGuestWineDLL_EXTENDS = VBoxGuestR3Dll
27TEMPLATE_VBoxGuestWineDLL_DEFS = $(TEMPLATE_VBoxGuestR3Dll_DEFS) \
28 __WINESRC__ \
29 WINE_UNICODE_API="" \
30 _REENTRANT \
31 WINE_NOWINSOCK \
32 USE_WIN32_OPENGL \
33 DLLDIR=\"\" \
34 BINDIR=\"\" \
35 LIB_TO_BINDIR=\"\" \
36 LIB_TO_DLLDIR=\"\" \
37 BIN_TO_DLLDIR=\"\" \
38 LIB_TO_DATADIR=\"\" \
39 BIN_TO_DATADIR=\"\"
40
41TEMPLATE_VBoxGuestWineDLL_DEFS.x86 = __i386__
42# -wd4100: unreferenced format parameter
43# -wd4204: nonstandard extension used : non-constant initializer
44# -wd4245: '=' : conversion from 'int' to 'DWORD', signed/unsigned mismatch
45# -wd4305: 'function' : truncation from 'double' to 'GLclampf'
46# -wd4305: 'function' : truncation from 'double' to 'GLclampf'
47# -wd4018: '>' : signed/unsigned mismatch
48# -wd4389: '!=' : signed/unsigned mismatch
49# -wd4221: nonstandard extension used : 'render_targets' : cannot be initialized using address of automatic variable 'dst_surface'
50# -wd4334: '<<' : result of 32-bit shift implicitly converted to 64 bits (was 64-bit shift intended?)
51# -wd4267: 'function' : conversion from 'size_t' to 'GLsizei', possible loss of data
52TEMPLATE_VBoxGuestWineDLL_CFLAGS = $(filter-out -WX,$(TEMPLATE_VBoxGuestR3Dll_CFLAGS)) \
53 -wd4100 -wd4204 -wd4245 -wd4305 -wd4018 -wd4389 -wd4221 -wd4334 -wd4267
54
55#
56# Template for building the D3D[89] stuff.
57#
58TEMPLATE_VBoxGuestWineD3DxDLL = Template for building the D3D8/9 stuff.
59TEMPLATE_VBoxGuestWineD3DxDLL_EXTENDS = VBoxGuestR3Dll
60TEMPLATE_VBoxGuestWineD3DxDLL_EXTENDS_BY = appending
61TEMPLATE_VBoxGuestWineD3DxDLL_SDKS = ReorderCompilerIncs $(VBOX_WINDDK_GST_WLH)
62TEMPLATE_VBoxGuestWineD3DxDLL_DEFS = VBOX_USING_WINDDK_W7_OR_LATER
63TEMPLATE_VBoxGuestWineD3DxDLL_DEFS.x86 = __i386__
64#TEMPLATE_VBoxGuestWineD3DxDLL_INCS.x86 = vbox/libWineStub/include
65TEMPLATE_VBoxGuestWineD3DxDLL_DEFS = VBOX_WINE_WITH_IPRT
66TEMPLATE_VBoxGuestWineD3DxDLL_CFLAGS = -wd4100 -wd4204 -wd4245 -wd4305
67TEMPLATE_VBoxGuestWineD3DxDLL_LIBS = \
68 $(VBOX_LIB_IPRT_GUEST_R3) \
69 $(VBOX_LIB_VBGL_R3)
70
71
72if 0
73#
74# libWine - ???.
75#
76DLLS.x86 += libWine
77libWine_TEMPLATE = VBoxGuestWineDLL
78libWine_INCS = \
79 include
80libWine_SOURCES := \
81 libWine/wine.def \
82 libWine/casemap.c \
83 libWine/collation.c \
84 libWine/compose.c \
85 libWine/config.c \
86 libWine/cptable.c \
87 libWine/debug.c \
88 libWine/fold.c \
89 libWine/ldt.c \
90 libWine/loader.c \
91 libWine/mbtowc.c \
92 libWine/mmap.c \
93 libWine/port.c \
94 libWine/sortkey.c \
95 libWine/string.c \
96 libWine/utf8.c \
97 libWine/wctomb.c \
98 libWine/wctype.c \
99 libWine/c_037.c \
100 libWine/c_424.c \
101 libWine/c_437.c \
102 libWine/c_500.c \
103 libWine/c_737.c \
104 libWine/c_775.c \
105 libWine/c_850.c \
106 libWine/c_852.c \
107 libWine/c_855.c \
108 libWine/c_856.c \
109 libWine/c_857.c \
110 libWine/c_860.c \
111 libWine/c_861.c \
112 libWine/c_862.c \
113 libWine/c_863.c \
114 libWine/c_864.c \
115 libWine/c_865.c \
116 libWine/c_866.c \
117 libWine/c_869.c \
118 libWine/c_874.c \
119 libWine/c_875.c \
120 libWine/c_878.c \
121 libWine/c_932.c \
122 libWine/c_936.c \
123 libWine/c_949.c \
124 libWine/c_950.c \
125 libWine/c_1006.c \
126 libWine/c_1026.c \
127 libWine/c_1250.c \
128 libWine/c_1251.c \
129 libWine/c_1252.c \
130 libWine/c_1253.c \
131 libWine/c_1254.c \
132 libWine/c_1255.c \
133 libWine/c_1256.c \
134 libWine/c_1257.c \
135 libWine/c_1258.c \
136 libWine/c_1361.c \
137 libWine/c_10000.c \
138 libWine/c_10006.c \
139 libWine/c_10007.c \
140 libWine/c_10029.c \
141 libWine/c_10079.c \
142 libWine/c_10081.c \
143 libWine/c_20127.c \
144 libWine/c_20866.c \
145 libWine/c_20932.c \
146 libWine/c_21866.c \
147 libWine/c_28591.c \
148 libWine/c_28592.c \
149 libWine/c_28593.c \
150 libWine/c_28594.c \
151 libWine/c_28595.c \
152 libWine/c_28596.c \
153 libWine/c_28597.c \
154 libWine/c_28598.c \
155 libWine/c_28599.c \
156 libWine/c_28600.c \
157 libWine/c_28603.c \
158 libWine/c_28604.c \
159 libWine/c_28605.c \
160 libWine/c_28606.c \
161 libWine/version.c
162endif # 0
163
164#
165# wined3d - ???.
166#
167DLLS += wined3d
168wined3d_TEMPLATE = VBoxGuestWineDLL
169wined3d_SDKS = ReorderCompilerIncs $(VBOX_WINDDK_GST_WLH)
170wined3d_DEFS = \
171 _USE_MATH_DEFINES \
172 VBOX_USING_WINDDK_W7_OR_LATER \
173 VBOX_WINE_WITHOUT_LIBWINE \
174 VBOX_WINE_WITH_SINGLE_CONTEXT \
175 VBOX_WINE_WITH_IPRT
176# ^^^^ wined3d is now using iprt/asm.h, which includes iprt/assert.h, so iprt is required.
177if "$(KBUILD_TYPE)" != "debug" || defined(VBOX_WINE_NO_DEBUG_MSGS)
178 wined3d_DEFS += WINE_NO_DEBUG_MSGS
179endif
180wined3d_DEFS += \
181 VBOX_WITH_WINE_FIX_IBMTMR \
182 VBOX_WITH_WINE_FIX_BUFOFFSET \
183 VBOX_WITH_WINE_FIX_QUIRKS \
184 VBOX_WITH_WINE_FIX_PBOPSM \
185 VBOX_WITH_WINE_FIX_INITCLEAR \
186 VBOX_WITH_WINE_FIX_TEXCLEAR \
187 VBOX_WITH_WINE_FIX_STRINFOBUF \
188 VBOX_WITH_WINE_FIX_SHADERCLEANUP \
189 VBOX_WITH_WINE_FIX_SURFUPDATA \
190 VBOX_WITH_WINE_FIX_CURVBO \
191 VBOX_WITH_WINE_FIX_FTOA \
192 VBOX_WITH_WINE_FIX_SHADER_DECL \
193 VBOX_WITH_WINE_DBG
194#wined3d_DEFS += VBOX_WITH_WINE_FIXES
195wined3d_INCS := \
196 vbox/libWineStub/include \
197 $(VBOX_GRAPHICS_INCS)
198wined3d_SOURCES := \
199 wined3d/arb_program_shader.c \
200 wined3d/ati_fragment_shader.c \
201 wined3d/buffer.c \
202 wined3d/context.c \
203 wined3d/device.c \
204 wined3d/directx.c \
205 wined3d/drawprim.c \
206 wined3d/gl_compat.c \
207 wined3d/glsl_shader.c \
208 wined3d/nvidia_texture_shader.c \
209 wined3d/palette.c \
210 wined3d/query.c \
211 wined3d/resource.c \
212 wined3d/shader.c \
213 wined3d/shader_sm1.c \
214 wined3d/shader_sm4.c \
215 wined3d/state.c \
216 wined3d/stateblock.c \
217 wined3d/surface.c \
218 wined3d/swapchain.c \
219 wined3d/texture.c \
220 wined3d/utils.c \
221 wined3d/vertexdeclaration.c \
222 wined3d/view.c \
223 wined3d/volume.c \
224 wined3d/wined3d_main.c \
225 wined3d/vboxext.c \
226 wined3d/sampler.c \
227 vbox/libWineStub/debug.c \
228 vbox/VBoxDbgGl.c \
229 wined3d/wined3d.def \
230 vbox/wined3dxpdm.rc
231wined3d_LIBS = \
232 $(VBOX_LIB_IPRT_GUEST_R3) \
233 $(VBOX_LIB_VBGL_R3) \
234 $(PATH_STAGE_LIB)/VBoxOGL$(VBOX_SUFF_LIB)
235
236ifdef VBOX_WITH_WDDM
237 #
238 # wined3dwddm - ???
239 #
240 DLLS += wined3dwddm
241 wined3dwddm_EXTENDS = wined3d
242 if defined(VBOX_SIGNING_MODE)
243 wined3dwddm_INSTTYPE.win = none
244 wined3dwddm_DEBUG_INSTTYPE.win = both
245 endif
246 wined3dwddm_DEFS = $(wined3d_DEFS) \
247 VBOX_WITH_WDDM \
248 IN_VBOXLIBWINE \
249 VBOX_WINE_WITH_SHADER_CACHE
250ifdef VBOX_WINE_WITH_PROFILE
251 wined3dwddm_DEFS += VBOX_WINE_WITH_PROFILE
252endif
253 wined3dwddm_INCS = $(wined3d_INCS) \
254 $(PATH_ROOT)/src/VBox/Additions/WINNT/Graphics/Video/disp/wddm
255 wined3dwddm_SOURCES = $(subst wined3d.def,wined3dwddm.def,$(subst wined3dxpdm.rc,wined3dwddm.rc,$(wined3d_SOURCES)))
256 wined3dwddm_LIBS = $(wined3d_LIBS) \
257 $(VBOX_PATH_ADDITIONS_LIB)/VBoxDispMpLogger$(VBOX_SUFF_LIB) \
258 $(VBOX_PATH_ADDITIONS_LIB)/VBoxCrHgsmi$(VBOX_SUFF_LIB)
259
260 #
261 # wined3dwddm-x86 - ???.
262 #
263 DLLS.amd64 += wined3dwddm-x86
264 wined3dwddm-x86_EXTENDS = wined3dwddm
265 wined3dwddm-x86_BLD_TRG_ARCH = x86
266 wined3dwddm-x86_DEFS = $(wined3dwddm_DEFS) VBOX_WDDM_WOW64
267 wined3dwddm-x86_LIBS = \
268 $(VBOX_LIB_IPRT_GUEST_R3_X86) \
269 $(VBOX_LIB_VBGL_R3_X86) \
270 $(VBOX_PATH_ADDITIONS_LIB)/VBoxDispMpLogger-x86$(VBOX_SUFF_LIB) \
271 $(VBOX_PATH_ADDITIONS_LIB)/VBoxCrHgsmi-x86$(VBOX_SUFF_LIB) \
272 $(PATH_STAGE_LIB)/VBoxOGL-x86$(VBOX_SUFF_LIB)
273endif # ifdef VBOX_WITH_WDDM
274
275#
276# VBoxD3D8 - ???.
277#
278DLLS += VBoxD3D8
279VBoxD3D8_TEMPLATE = VBoxGuestWineDLL
280VBoxD3D8_SDKS = ReorderCompilerIncs $(VBOX_WINDDK_GST_WLH)
281VBoxD3D8_DEFS = _USE_MATH_DEFINES \
282 VBOX_USING_WINDDK \
283 VBOX_WINE_WITHOUT_LIBWINE
284if "$(KBUILD_TYPE)" != "debug" || defined(VBOX_WINE_NO_DEBUG_MSGS)
285 VBoxD3D8_DEFS += WINE_NO_DEBUG_MSGS
286endif
287VBoxD3D8_INCS := \
288 vbox/libWineStub/include
289VBoxD3D8_SOURCES := \
290 d3d8/d3d8_main.c \
291 d3d8/buffer.c \
292 d3d8/device.c \
293 d3d8/directx.c \
294 d3d8/shader.c \
295 d3d8/surface.c \
296 d3d8/swapchain.c \
297 d3d8/texture.c \
298 d3d8/vertexdeclaration.c \
299 d3d8/volume.c \
300 vbox/libWineStub/debug.c \
301 d3d8/d3d8.def \
302 vbox/d3d8.rc
303VBoxD3D8_LIBS = \
304 $(PATH_STAGE_LIB)/wined3d$(VBOX_SUFF_LIB)
305VBoxD3D8_DEFS += VBOX_WINE_WITH_IPRT
306VBoxD3D8_LIBS += \
307 $(VBOX_LIB_IPRT_GUEST_R3) \
308 $(VBOX_LIB_VBGL_R3)
309
310#
311# VBoxD3D9 - ???.
312#
313DLLS += VBoxD3D9
314VBoxD3D9_TEMPLATE = VBoxGuestWineDLL
315VBoxD3D9_SDKS = ReorderCompilerIncs $(VBOX_WINDDK_GST_WLH)
316VBoxD3D9_DEFS = _USE_MATH_DEFINES \
317 VBOX_USING_WINDDK \
318 VBOX_WINE_WITHOUT_LIBWINE
319if "$(KBUILD_TYPE)" != "debug" || defined(VBOX_WINE_NO_DEBUG_MSGS)
320 VBoxD3D9_DEFS += WINE_NO_DEBUG_MSGS
321endif
322#@todo: do we actually need this?
323#VBoxD3D9_DEFS += VBOX_WITH_WINE_FIX_NO9EX
324VBoxD3D9_INCS := \
325 vbox/libWineStub/include
326VBoxD3D9_SOURCES := \
327 d3d9/d3d9_main.c \
328 d3d9/buffer.c \
329 d3d9/device.c \
330 d3d9/directx.c \
331 d3d9/query.c \
332 d3d9/shader.c \
333 d3d9/stateblock.c \
334 d3d9/surface.c \
335 d3d9/swapchain.c \
336 d3d9/texture.c \
337 d3d9/vertexdeclaration.c \
338 d3d9/volume.c \
339 vbox/libWineStub/debug.c \
340 d3d9/d3d9xpdm.def \
341 vbox/d3d9xpdm.rc
342VBoxD3D9_SOURCES.amd64 = d3d9/vboxport.asm
343VBoxD3D9_LIBS = \
344 $(PATH_STAGE_LIB)/wined3d$(VBOX_SUFF_LIB)
345VBoxD3D9_DEFS += VBOX_WINE_WITH_IPRT
346VBoxD3D9_LIBS += \
347 $(VBOX_LIB_IPRT_GUEST_R3) \
348 $(VBOX_LIB_VBGL_R3)
349
350ifdef VBOX_WITH_WDDM
351 #
352 # VBoxD3D9wddm - ???.
353 #
354 DLLS += VBoxD3D9wddm
355 VBoxD3D9wddm_EXTENDS = VBoxD3D9
356 if defined(VBOX_SIGNING_MODE) && defined(VBOX_WITH_WDDM)
357 VBoxD3D9wddm_INSTTYPE = none
358 VBoxD3D9wddm_DEBUG_INSTTYPE = both
359 endif
360 VBoxD3D9wddm_INCS = $(VBoxD3D9_INCS) \
361 $(PATH_ROOT)/src/VBox/Additions/WINNT/Graphics/Video/disp/wddm
362 VBoxD3D9wddm_DEFS += $(VBoxD3D9_DEFS) \
363 VBOX_WITH_WDDM \
364 IN_VBOXWINEEX \
365 VBOX_WINE_NO_LOCK
366 VBoxD3D9wddm_SOURCES = $(subst d3d9xpdm.def,d3d9wddm.def,$(subst d3d9xpdm.rc,d3d9wddm.rc,$(VBoxD3D9_SOURCES)))
367 VBoxD3D9wddm_LIBS = \
368 $(subst $(PATH_STAGE_LIB)/wined3d$(VBOX_SUFF_LIB),$(PATH_STAGE_LIB)/wined3dwddm$(VBOX_SUFF_LIB),$(VBoxD3D9_LIBS)) \
369 $(VBOX_PATH_ADDITIONS_LIB)/VBoxDispMpLogger$(VBOX_SUFF_LIB) \
370 $(VBOX_PATH_ADDITIONS_LIB)/VBoxCrHgsmi$(VBOX_SUFF_LIB)
371
372 #
373 # VBoxD3D9wddm-x86 - For WOW64.
374 #
375 DLLS.amd64 += VBoxD3D9wddm-x86
376 VBoxD3D9wddm-x86_EXTENDS = VBoxD3D9wddm
377 VBoxD3D9wddm-x86_BLD_TRG_ARCH = x86
378 VBoxD3D9wddm-x86_DEFS = $(VBoxD3D9wddm_DEFS) VBOX_WDDM_WOW64
379 VBoxD3D9wddm-x86_LIBS = $(PATH_STAGE_LIB)/wined3dwddm-x86$(VBOX_SUFF_LIB)
380 VBoxD3D9wddm-x86_LIBS += \
381 $(VBOX_LIB_IPRT_GUEST_R3_X86) \
382 $(VBOX_LIB_VBGL_R3_X86)
383 VBoxD3D9wddm-x86_LIBS += \
384 $(VBOX_PATH_ADDITIONS_LIB)/VBoxDispMpLogger-x86$(VBOX_SUFF_LIB) \
385 $(VBOX_PATH_ADDITIONS_LIB)/VBoxCrHgsmi-x86$(VBOX_SUFF_LIB)
386endif # VBOX_WITH_WDDM
387
388#
389# d3d8 - ???.
390#
391DLLS += d3d8
392d3d8_TEMPLATE = VBoxGuestWineD3DxDLL
393d3d8_SOURCES = \
394 switcher/d3d8_main.c \
395 switcher/sw_common.c \
396 switcher/sw_d3d8.def \
397 switcher/d3d8.rc
398
399#
400# d3d9 - ???.
401#
402DLLS += d3d9
403d3d9_TEMPLATE = VBoxGuestWineD3DxDLL
404d3d9_SOURCES = \
405 switcher/d3d9_main.c \
406 switcher/sw_common.c \
407 switcher/d3d9.rc
408d3d9_SOURCES.x86 = \
409 switcher/sw_d3d9.def
410d3d9_SOURCES.amd64 = \
411 switcher/sw_d3d9xpdm.def
412
413include $(FILE_KBUILD_SUB_FOOTER)
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