VirtualBox

source: vbox/trunk/src/VBox/Additions/common/crOpenGL/Makefile.kmk@ 42500

Last change on this file since 42500 was 42499, checked in by vboxsync, 12 years ago

crOgl/wddm: per-context connections

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 24.9 KB
Line 
1# $Id: Makefile.kmk 42499 2012-08-01 10:26:43Z vboxsync $
2## @file
3# Sub-Makefile for the VirtualBox Guest OpenGL part
4#
5
6#
7# Copyright (C) 2008-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#
22# Target lists.
23#
24BLDDIRS += \
25 $(VBOX_PATH_CROGL_GENFILES)/
26
27DLLS.win += \
28 VBoxOGL \
29 VBoxOGLarrayspu \
30 VBoxOGLpassthroughspu \
31 VBoxOGLpackspu \
32 VBoxOGLfeedbackspu
33
34if1of ($(KBUILD_TARGET), linux solaris freebsd)
35DLLS += \
36 VBoxOGL \
37 VBoxOGLarrayspu \
38 VBoxOGLpassthroughspu \
39 VBoxOGLpackspu \
40 VBoxOGLfeedbackspu
41endif
42
43if1of ($(KBUILD_TARGET), linux solaris freebsd)
44 #VBoxOGL_DRI = 1
45 ifn1of ($(KBUILD_TARGET),solaris freebsd) # No DRI on Solaris yet
46 VBoxOGL_FAKEDRI = 1
47 endif
48
49 # Only Solaris right now needs C stubs because I can't figure out how to
50 # generate the GOT based relocation ASM yet.
51 ifdef VBoxOGL_FAKEDRI
52 if1of ($(KBUILD_TARGET).$(KBUILD_TARGET_ARCH),solaris.x86 solaris.amd64 linux.x86 linux.amd64 freebsd.x86 freebsd.amd64)
53 VBOX_OGL_GLX_USE_CSTUBS = 1
54 endif
55 endif
56endif
57
58
59#
60# VBoxOGL
61#
62VBoxOGL_TEMPLATE = VBOXCROGLR3GUESTDLL
63VBoxOGL_INCS = .
64if1of ($(KBUILD_TARGET), linux solaris freebsd)
65 VBoxOGL_INCS += \
66 $(VBOX_PATH_X11_ROOT)/libXdamage-1.1 \
67 $(VBOX_PATH_X11_ROOT)/libXcomposite-0.4.0 \
68 $(VBOX_PATH_X11_ROOT)/libXfixes-4.0.3 \
69 $(VBOX_PATH_X11_ROOT)/damageproto-1.1.0 \
70 $(VBOX_PATH_X11_ROOT)/compositeproto-0.4 \
71 $(VBOX_PATH_X11_ROOT)/fixesproto-4.0 \
72 $(VBOX_PATH_X11_ROOT)/libx11-1.1.5-other \
73 $(VBOX_PATH_X11_ROOT)/1.3/xorg \
74 $(VBOX_MESA_INCS) \
75 $(PATH_ROOT)/src/VBox/Additions/x11/x11include/libdrm-2.4.13
76 VBoxOGL_DEFS += VBOX_NO_NATIVEGL
77endif
78
79ifdef VBoxOGL_DRI
80 VBoxOGL_DEFS += VBOXOGL_DRI IN_DRI_DRIVER
81else ifdef VBoxOGL_FAKEDRI
82 VBoxOGL_DEFS += VBOXOGL_FAKEDRI
83 ifdef VBOX_OGL_GLX_USE_CSTUBS
84 VBoxOGL_DEFS += VBOX_OGL_GLX_USE_CSTUBS
85 endif
86endif
87
88ifdef VBOX_WITH_WDDM
89 VBoxOGL_DEFS.win += VBOX_WITH_WDDM
90 VBoxOGL_SDKS.win += $(VBOX_WINDDK_GST_WLH)
91endif
92
93ifeq ($(KBUILD_TARGET),win)
94#fixme?, INTERMEDIATES.win ain't working
95 VBoxOGL_INTERMEDIATES += $(VBOX_PATH_CROGL_GENFILES)/cr_gl.h
96 if defined(VBOX_SIGNING_MODE) && defined(VBOX_WITH_WDDM)
97 VBoxOGL_INSTTYPE.win = none
98 VBoxOGL_DEBUG_INSTTYPE.win = both
99 endif
100endif
101ifdef VBoxOGL_DRI
102 VBoxOGL_INTERMEDIATES += \
103 $(VBOX_PATH_CROGL_GENFILES)/cr_gl.h \
104 $(VBOX_PATH_CROGL_GENFILES)/DD_gl.h
105else ifdef VBoxOGL_FAKEDRI
106 VBoxOGL_INTERMEDIATES += \
107 $(VBOX_PATH_CROGL_GENFILES)/cr_gl.h
108endif
109VBoxOGL_SOURCES += \
110 load.c \
111 stub.c \
112 context.c \
113 $(VBOX_PATH_CROGL_GENFILES)/getprocaddress.c \
114 $(VBOX_PATH_CROGL_GENFILES)/NULLfuncs.c \
115 $(VBOX_PATH_CROGL_GENFILES)/tsfuncs.c
116
117if1of ($(KBUILD_TARGET), linux solaris freebsd)
118 VBoxOGL_SOURCES += \
119 glx.c \
120 xfont.c
121 ifdef VBOX_OGL_GLX_USE_CSTUBS
122 VBoxOGL_SOURCES += glx_c_exports.c
123 endif
124
125 ifdef VBoxOGL_DRI
126 VBoxOGL_SOURCES += \
127 $(VBOX_PATH_CROGL_GENFILES)/DD_gl.c \
128 dri_drv.c
129 VBoxOGL_SOURCES.linux += \
130 $(VBOX_PATH_CROGL_GENFILES)/linux_exports_dri.asm
131 VBoxOGL_SOURCES.solaris += \
132 $(VBOX_PATH_CROGL_GENFILES)/solaris_exports_dri.asm
133 VBoxOGL_SOURCES.freebsd += \
134 $(VBOX_PATH_CROGL_GENFILES)/freebsd_exports_dri.asm
135 else ifdef VBoxOGL_FAKEDRI
136 VBoxOGL_SOURCES += \
137 fakedri_drv.c
138 ifndef VBOX_OGL_GLX_USE_CSTUBS
139 VBoxOGL_SOURCES.solaris += \
140 $(VBOX_PATH_CROGL_GENFILES)/solaris_glxapi_exports.asm \
141 $(VBOX_PATH_CROGL_GENFILES)/solaris_exports_dri.asm
142 VBoxOGL_SOURCES.linux += \
143 $(VBOX_PATH_CROGL_GENFILES)/linux_glxapi_exports.asm \
144 $(VBOX_PATH_CROGL_GENFILES)/linux_exports_dri.asm
145 VBoxOGL_SOURCES.freebsd += \
146 $(VBOX_PATH_CROGL_GENFILES)/freebsd_glxapi_exports.asm \
147 $(VBOX_PATH_CROGL_GENFILES)/freebsd_exports_dri.asm
148 else
149 VBoxOGL_SOURCES.solaris += \
150 $(VBOX_PATH_CROGL_GENFILES)/solaris_exports.c
151 VBoxOGL_SOURCES.linux += \
152 $(VBOX_PATH_CROGL_GENFILES)/linux_exports.c
153 VBoxOGL_SOURCES.freebsd += \
154 $(VBOX_PATH_CROGL_GENFILES)/freebsd_exports.c
155 endif
156 else
157 VBoxOGL_SOURCES.linux += \
158 $(VBOX_PATH_CROGL_GENFILES)/linux_exports.asm
159 VBoxOGL_SOURCES.solaris += \
160 $(VBOX_PATH_CROGL_GENFILES)/solaris_exports.c
161 VBoxOGL_SOURCES.freebsd += \
162 $(VBOX_PATH_CROGL_GENFILES)/freebsd_exports.c
163 endif
164endif
165
166VBoxOGL_SOURCES.win = \
167 wgl.c \
168 icd_drv.c \
169 VBoxCROGL.rc \
170 $(VBOX_PATH_CROGL_GENFILES)/windows_exports.asm \
171 $(VBOX_PATH_CROGL_GENFILES)/cropengl.def
172VBoxOGL_CLEAN = \
173 $(VBOX_PATH_CROGL_GENFILES)/getprocaddress.c \
174 $(VBOX_PATH_CROGL_GENFILES)/NULLfuncs.c \
175 $(VBOX_PATH_CROGL_GENFILES)/tsfuncs.c
176VBoxOGL_CLEAN.linux += \
177 $(VBOX_PATH_CROGL_GENFILES)/linux_exports.asm
178VBoxOGL_CLEAN.solaris += \
179 $(VBOX_PATH_CROGL_GENFILES)/solaris_exports.c
180VBoxOGL_CLEAN.win = \
181 $(VBOX_PATH_CROGL_GENFILES)/windows_exports.asm \
182 $(VBOX_PATH_CROGL_GENFILES)/cropengl.def
183if1of ($(KBUILD_TARGET), linux solaris)
184 ifdef VBoxOGL_DRI
185 VBoxOGL_CLEAN += \
186 $(VBOX_PATH_CROGL_GENFILES)/cr_gl.h \
187 $(VBOX_PATH_CROGL_GENFILES)/DD_gl.h \
188 $(VBOX_PATH_CROGL_GENFILES)/DD_gl.c
189 else ifdef VBoxOGL_FAKEDRI
190 VBoxOGL_CLEAN += \
191 $(VBOX_PATH_CROGL_GENFILES)/cr_gl.h
192 VBoxOGL_CLEAN.linux += \
193 $(VBOX_PATH_CROGL_GENFILES)/linux_glxapi_exports.asm
194 VBoxOGL_CLEAN.solaris += \
195 $(VBOX_PATH_CROGL_GENFILES)/solaris_glxapi_exports.asm
196 endif
197endif
198VBoxOGL_LIBS = \
199 $(VBOX_LIB_IPRT_GUEST_R3_SHARED) \
200 $(VBOX_LIB_VBGL_R3_SHARED) \
201 $(VBOX_LIB_OGL_CRUTIL) \
202 $(PATH_STAGE_LIB)/additions/VBoxOGLspuload$(VBOX_SUFF_LIB)
203if1of ($(KBUILD_TARGET), linux solaris freebsd)
204 VBoxOGL_LIBS += \
205 $(PATH_STAGE_LIB)/libXcomposite.so \
206 $(PATH_STAGE_LIB)/libXdamage.so \
207 $(PATH_STAGE_LIB)/libXfixes.so \
208 $(PATH_STAGE_LIB)/libXext.so
209 ifdef VBoxOGL_FAKEDRI
210 VBoxOGL_LIBS += \
211 dl
212 endif
213endif
214ifdef VBOX_WITH_CRHGSMI
215VBoxOGL_DEFS.win += VBOX_WITH_CRHGSMI
216endif
217ifdef VBOX_WITH_WDDM
218VBoxOGL_DEFS.win += VBOX_WITH_WDDM
219endif
220
221ifdef VBOX_WITH_WDDM
222#
223# VBoxOGL-x86 - x86 VBoxOGL version built for amd64 build
224#
225DLLS.win.amd64 += VBoxOGL-x86
226VBoxOGL-x86_EXTENDS = VBoxOGL
227VBoxOGL-x86_BLD_TRG_ARCH = x86
228VBoxOGL-x86_LIBS = $(VBOX_LIB_IPRT_GUEST_R3_SHARED_X86) \
229 $(VBOX_LIB_VBGL_R3_SHARED_X86) \
230 $(VBOX_LIB_OGL_CRUTIL_X86) \
231 $(PATH_STAGE_LIB)/additions/VBoxOGLspuload-x86$(VBOX_SUFF_LIB)
232VBoxOGL-x86_SOURCES.win = $(subst cropengl.def,cropengl-x86.def,$(VBoxOGL_SOURCES.win))
233VBoxOGL-x86_CLEAN.win = $(subst cropengl.def,cropengl-x86.def,$(VBoxOGL_CLEAN.win))
234VBoxOGL-x86_DEFS = $(VBoxOGL_DEFS) VBOX_WDDM_WOW64
235endif
236
237#
238# Generate files for VBoxOGL.
239#
240$(VBOX_PATH_CROGL_GENFILES)/NULLfuncs.c: $(PATH_SUB_CURRENT)/NULLfuncs.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
241 $(call MSG_GENERATE,python,$@,$<)
242 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
243$(VBOX_PATH_CROGL_GENFILES)/tsfuncs.c: $(PATH_SUB_CURRENT)/tsfuncs.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
244 $(call MSG_GENERATE,python,$@,$<)
245 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
246
247ifeq ($(KBUILD_TARGET),win)
248$(VBOX_PATH_CROGL_GENFILES)/getprocaddress.c: $(PATH_SUB_CURRENT)/windows_getprocaddress.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
249 $(call MSG_GENERATE,python,$@,$<)
250 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
251 ifeq ($(KBUILD_TARGET_ARCH),amd64)
252$(VBOX_PATH_CROGL_GENFILES)/cropengl.def: $(PATH_SUB_CURRENT)/defs64.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
253 $(call MSG_GENERATE,python,$@,$<)
254 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
255 else
256$(VBOX_PATH_CROGL_GENFILES)/cropengl.def: $(PATH_SUB_CURRENT)/defs.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
257 $(call MSG_GENERATE,python,$@,$<)
258 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
259 endif
260$(VBOX_PATH_CROGL_GENFILES)/cr_gl.h: $(PATH_SUB_CURRENT)/cr_gl.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
261 $(call MSG_GENERATE,python,$@,$<)
262 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
263$(VBOX_PATH_CROGL_GENFILES)/windows_exports.asm: \
264 $(PATH_SUB_CURRENT)/windows_i386_exports.py \
265 $(VBOX_CROGL_API_FILES) $(PATH_SUB_CURRENT)/entrypoints.py \
266 | $$(dir $$@)
267 $(call MSG_GENERATE,python,$@,$<)
268 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
269 ifdef VBOX_WITH_WDDM
270 ifeq ($(KBUILD_TARGET).$(KBUILD_TARGET_ARCH),win.amd64)
271$(VBOX_PATH_CROGL_GENFILES)/cropengl-x86.def: $(PATH_SUB_CURRENT)/defs.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
272 $(call MSG_GENERATE,python,$@,$<)
273 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
274 endif #ifeq ($(KBUILD_TARGET).$(KBUILD_TARGET_ARCH),win.amd64)
275 endif #ifdef VBOX_WITH_WDDM
276else if1of ($(KBUILD_TARGET), linux solaris freebsd)
277$(VBOX_PATH_CROGL_GENFILES)/getprocaddress.c: $(PATH_SUB_CURRENT)/getprocaddress.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
278 $(call MSG_GENERATE,python,$@,$<)
279 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
280if !defined(VBoxOGL_DRI) && !defined(VBoxOGL_FAKEDRI)
281 ifeq ($(KBUILD_TARGET),solaris)
282$(VBOX_PATH_CROGL_GENFILES)/solaris_exports.c: \
283 $(PATH_SUB_CURRENT)/SunOS_exports.py \
284 $(VBOX_CROGL_API_FILES) $(PATH_SUB_CURRENT)/entrypoints.py \
285 | $$(dir $$@)
286 $(call MSG_GENERATE,python,$@,$<)
287 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
288 else ifeq ($(KBUILD_TARGET),freebsd)
289$(VBOX_PATH_CROGL_GENFILES)/freebsd_exports.c: \
290 $(PATH_SUB_CURRENT)/FreeBSD_exports.py \
291 $(VBOX_CROGL_API_FILES) $(PATH_SUB_CURRENT)/entrypoints.py \
292 | $$(dir $$@)
293 $(call MSG_GENERATE,python,$@,$<)
294 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
295 else
296$(VBOX_PATH_CROGL_GENFILES)/linux_exports.asm: \
297 $(PATH_SUB_CURRENT)/Linux_i386_exports.py \
298 $(VBOX_CROGL_API_FILES) $(PATH_SUB_CURRENT)/entrypoints.py \
299 | $$(dir $$@)
300 $(call MSG_GENERATE,python,$@,$<)
301 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
302 endif
303else ifdef VBoxOGL_DRI
304$(VBOX_PATH_CROGL_GENFILES)/cr_gl.h: $(PATH_SUB_CURRENT)/cr_gl.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
305 $(call MSG_GENERATE,python,$@,$<)
306 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
307$(VBOX_PATH_CROGL_GENFILES)/DD_gl.h: $(PATH_SUB_CURRENT)/DD_glh.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
308 $(call MSG_GENERATE,python,$@,$<)
309 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
310$(VBOX_PATH_CROGL_GENFILES)/DD_gl.c: $(PATH_SUB_CURRENT)/DD_glc.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
311 $(call MSG_GENERATE,python,$@,$<)
312 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
313 ifeq ($(KBUILD_TARGET),solaris)
314$(VBOX_PATH_CROGL_GENFILES)/solaris_exports_dri.asm: \
315 $(PATH_SUB_CURRENT)/SunOS_i386_exports_dri.py \
316 $(VBOX_CROGL_API_FILES) $(PATH_SUB_CURRENT)/entrypoints.py \
317 | $$(dir $$@)
318 $(call MSG_GENERATE,python,$@,$<)
319 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
320 else ifeq ($(KBUILD_TARGET),freebsd)
321$(VBOX_PATH_CROGL_GENFILES)/freebsd_exports_dri.asm: \
322 $(PATH_SUB_CURRENT)/FreeBSD_i386_exports_dri.py \
323 $(VBOX_CROGL_API_FILES) $(PATH_SUB_CURRENT)/entrypoints.py \
324 | $$(dir $$@)
325 $(call MSG_GENERATE,python,$@,$<)
326 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
327 else
328$(VBOX_PATH_CROGL_GENFILES)/linux_exports_dri.asm: \
329 $(PATH_SUB_CURRENT)/Linux_i386_exports_dri.py \
330 $(VBOX_CROGL_API_FILES) $(PATH_SUB_CURRENT)/entrypoints.py \
331 | $$(dir $$@)
332 $(call MSG_GENERATE,python,$@,$<)
333 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
334 endif
335else ifdef VBoxOGL_FAKEDRI
336$(VBOX_PATH_CROGL_GENFILES)/cr_gl.h: $(PATH_SUB_CURRENT)/cr_gl.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
337 $(call MSG_GENERATE,python,$@,$<)
338 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
339 ifndef VBOX_OGL_GLX_USE_CSTUBS
340 ifeq ($(KBUILD_TARGET),solaris)
341$(VBOX_PATH_CROGL_GENFILES)/solaris_exports_dri.asm: \
342 $(PATH_SUB_CURRENT)/SunOS_i386_exports_dri.py \
343 $(VBOX_CROGL_API_FILES) $(PATH_SUB_CURRENT)/entrypoints.py \
344 | $$(dir $$@)
345 $(call MSG_GENERATE,python,$@,$<)
346 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
347$(VBOX_PATH_CROGL_GENFILES)/solaris_glxapi_exports.asm: $(PATH_SUB_CURRENT)/SunOS_i386_glxapi_exports.py | $$(dir $$@)
348 $(call MSG_GENERATE,python,$@,$<)
349 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $<
350 else
351$(VBOX_PATH_CROGL_GENFILES)/linux_exports_dri.asm: \
352 $(PATH_SUB_CURRENT)/Linux_i386_exports_dri.py \
353 $(VBOX_CROGL_API_FILES) $(PATH_SUB_CURRENT)/entrypoints.py \
354 | $$(dir $$@)
355 $(call MSG_GENERATE,python,$@,$<)
356 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
357$(VBOX_PATH_CROGL_GENFILES)/linux_glxapi_exports.asm: $(PATH_SUB_CURRENT)/Linux_i386_glxapi_exports.py | $$(dir $$@)
358 $(call MSG_GENERATE,python,$@,$<)
359 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $<
360 endif
361 else
362 ifeq ($(KBUILD_TARGET),solaris)
363$(VBOX_PATH_CROGL_GENFILES)/solaris_exports.c: \
364 $(PATH_SUB_CURRENT)/SunOS_exports.py \
365 $(VBOX_CROGL_API_FILES) $(PATH_SUB_CURRENT)/entrypoints.py \
366 | $$(dir $$@)
367 $(call MSG_GENERATE,python,$@,$<)
368 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
369 else
370$(VBOX_PATH_CROGL_GENFILES)/linux_exports.c: \
371 $(PATH_SUB_CURRENT)/Linux_exports.py \
372 $(VBOX_CROGL_API_FILES) $(PATH_SUB_CURRENT)/entrypoints.py \
373 | $$(dir $$@)
374 $(call MSG_GENERATE,python,$@,$<)
375 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
376 endif
377 endif # VBOX_OGL_GLX_USE_CSTUBS
378endif
379endif
380
381#
382# VBoxOGLarrayspu
383#
384VBoxOGLarrayspu_TEMPLATE = VBOXCROGLR3GUESTDLL
385VBoxOGLarrayspu_INCS = \
386 array
387if1of ($(KBUILD_TARGET), linux solaris freebsd)
388 VBoxOGLarrayspu_INCS += \
389 $(VBOX_MESA_INCS)
390endif
391if defined(VBOX_SIGNING_MODE) && defined(VBOX_WITH_WDDM)
392 VBoxOGLarrayspu_INSTTYPE.win = none
393 VBoxOGLarrayspu_DEBUG_INSTTYPE.win = both
394endif
395VBoxOGLarrayspu_INCS.darwin += $(PATH_OUT)/obj/VBoxOGL
396VBoxOGLarrayspu_INTERMEDIATES = \
397 $(VBOX_PATH_CROGL_GENFILES)/state/cr_currentpointers.h \
398 $(VBOX_PATH_CROGL_GENFILES)/state/cr_statefuncs.h
399VBoxOGLarrayspu_SOURCES = \
400 array/arrayspu.c \
401 array/arrayspu_config.c \
402 array/arrayspu_init.c
403VBoxOGLarrayspu_SOURCES.win = \
404 array/arrayspu.def \
405 array/arrayspu.rc
406VBoxOGLarrayspu_LIBS = \
407 $(VBOX_LIB_OGL_CRUTIL) \
408 $(PATH_STAGE_LIB)/additions/VBoxOGLspuload$(VBOX_SUFF_LIB) \
409 $(PATH_STAGE_LIB)/additions/VBoxOGLcrstate$(VBOX_SUFF_LIB)
410ifdef VBOX_WITH_CRHGSMI
411VBoxOGLarrayspu_DEFS.win += VBOX_WITH_CRHGSMI
412endif
413ifdef VBOX_WITH_WDDM
414VBoxOGLarrayspu_DEFS.win += VBOX_WITH_WDDM
415endif
416
417ifdef VBOX_WITH_WDDM
418#
419# VBoxOGLarrayspu-x86 - x86 version of VBoxOGLarrayspu built for amd64 build
420#
421DLLS.win.amd64 += VBoxOGLarrayspu-x86
422VBoxOGLarrayspu-x86_EXTENDS = VBoxOGLarrayspu
423VBoxOGLarrayspu-x86_BLD_TRG_ARCH = x86
424VBoxOGLarrayspu-x86_LIBS = $(VBOX_LIB_OGL_CRUTIL_X86) \
425 $(PATH_STAGE_LIB)/additions/VBoxOGLspuload-x86$(VBOX_SUFF_LIB) \
426 $(PATH_STAGE_LIB)/additions/VBoxOGLcrstate-x86$(VBOX_SUFF_LIB)
427VBoxOGLarrayspu-x86_DEFS = $(VBoxOGLarrayspu_DEFS) VBOX_WDDM_WOW64
428endif
429
430#
431# VBoxOGLpassthroughspu
432#
433VBoxOGLpassthroughspu_TEMPLATE = VBOXCROGLR3GUESTDLL
434VBoxOGLpassthroughspu_INCS = \
435 passthrough
436if1of ($(KBUILD_TARGET), linux solaris freebsd)
437 VBoxOGLpassthroughspu_INCS += \
438 $(VBOX_MESA_INCS)
439endif
440if defined(VBOX_SIGNING_MODE) && defined(VBOX_WITH_WDDM)
441 VBoxOGLpassthroughspu_INSTTYPE.win = none
442 VBoxOGLpassthroughspu_DEBUG_INSTTYPE.win = both
443endif
444VBoxOGLpassthroughspu_SOURCES = \
445 passthrough/passthroughspu_init.c \
446 $(VBOX_PATH_CROGL_GENFILES)/passthroughspu.c
447VBoxOGLpassthroughspu_SOURCES.win = \
448 passthrough/passthrough.def \
449 passthrough/passthroughspu.rc
450VBoxOGLpassthroughspu_CLEAN = \
451 $(VBOX_PATH_CROGL_GENFILES)/passthroughspu.c
452VBoxOGLpassthroughspu_LIBS = \
453 $(VBOX_LIB_OGL_CRUTIL)
454ifdef VBOX_WITH_CRHGSMI
455VBoxOGLpassthroughspu_DEFS.win += VBOX_WITH_CRHGSMI
456endif
457ifdef VBOX_WITH_WDDM
458VBoxOGLpassthroughspu_DEFS.win += VBOX_WITH_WDDM
459endif
460
461ifdef VBOX_WITH_WDDM
462#
463# VBoxOGLpassthroughspu-x86 - x86 version of VBoxOGLpassthroughspu built for amd64 build
464#
465DLLS.win.amd64 += VBoxOGLpassthroughspu-x86
466VBoxOGLpassthroughspu-x86_EXTENDS = VBoxOGLpassthroughspu
467VBoxOGLpassthroughspu-x86_BLD_TRG_ARCH = x86
468VBoxOGLpassthroughspu-x86_LIBS = $(VBOX_LIB_OGL_CRUTIL_X86)
469VBoxOGLpassthroughspu-x86_DEFS = $(VBoxOGLpassthroughspu_DEFS) VBOX_WDDM_WOW64
470endif
471
472#
473# Generate files for VBoxOGLpassthroughspu.
474#
475$(VBOX_PATH_CROGL_GENFILES)/passthroughspu.c: $(PATH_SUB_CURRENT)/passthrough/passthrough.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
476 $(call MSG_GENERATE,python,$@,$<)
477 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
478
479#
480# VBoxOGLpackspu
481#
482VBoxOGLpackspu_TEMPLATE = VBOXCROGLR3GUESTDLL
483VBoxOGLpackspu_DEFS = TRACKS_STATE=1 PACKS=1
484VBoxOGLpackspu_INCS = \
485 pack
486if1of ($(KBUILD_TARGET), linux solaris freebsd)
487 VBoxOGLpackspu_INCS += \
488 $(VBOX_MESA_INCS)
489endif
490if defined(VBOX_SIGNING_MODE) && defined(VBOX_WITH_WDDM)
491 VBoxOGLpackspu_INSTTYPE.win = none
492 VBoxOGLpackspu_DEBUG_INSTTYPE.win = both
493endif
494VBoxOGLpackspu_INTERMEDIATES = \
495 $(VBOX_PATH_CROGL_GENFILES)/packspu_proto.h \
496 $(VBOX_PATH_CROGL_GENFILES)/cr_packfunctions.h
497VBoxOGLpackspu_SOURCES = \
498 pack/packspu_bufferobject.c \
499 pack/packspu_client.c \
500 pack/packspu_config.c \
501 pack/packspu_context.c \
502 pack/packspu_getstring.c \
503 pack/packspu_init.c \
504 pack/packspu_misc.c \
505 pack/packspu_net.c \
506 pack/packspu_swapbuf.c \
507 pack/packspu_pixel.c \
508 pack/packspu_texture.c \
509 pack/packspu_getshaders.c \
510 pack/packspu_glsl.c \
511 pack/packspu_framebuffer.c \
512 $(VBOX_PATH_CROGL_GENFILES)/packspu.c \
513 $(VBOX_PATH_CROGL_GENFILES)/packspu_get.c \
514 $(VBOX_PATH_CROGL_GENFILES)/packspu_flush.c \
515 $(VBOX_PATH_CROGL_GENFILES)/packspu_beginend.c
516VBoxOGLpackspu_SOURCES.win = \
517 pack/pack.def \
518 pack/packspu.rc
519VBoxOGLpackspu_CLEAN = \
520 $(VBOX_PATH_CROGL_GENFILES)/packspu_proto.h \
521 $(VBOX_PATH_CROGL_GENFILES)/packspu.c \
522 $(VBOX_PATH_CROGL_GENFILES)/packspu_get.c \
523 $(VBOX_PATH_CROGL_GENFILES)/packspu_flush.c \
524 $(VBOX_PATH_CROGL_GENFILES)/packspu_beginend.c
525VBoxOGLpackspu_LIBS = \
526 $(VBOX_LIB_OGL_CRUTIL) \
527 $(PATH_STAGE_LIB)/additions/VBoxOGLspuload$(VBOX_SUFF_LIB) \
528 $(PATH_STAGE_LIB)/additions/VBoxOGLcrstate$(VBOX_SUFF_LIB) \
529 $(PATH_STAGE_LIB)/additions/VBoxOGLcrpacker$(VBOX_SUFF_LIB)
530ifdef VBOX_WITH_CRHGSMI
531VBoxOGLpackspu_DEFS.win += VBOX_WITH_CRHGSMI
532endif
533ifdef VBOX_WITH_WDDM
534VBoxOGLpackspu_DEFS.win += VBOX_WITH_WDDM
535endif
536
537ifdef VBOX_WITH_WDDM
538#
539# VBoxOGLpackspu-x86 - x86 version of VBoxOGLpackspu built for amd64 build
540#
541DLLS.win.amd64 += VBoxOGLpackspu-x86
542VBoxOGLpackspu-x86_EXTENDS = VBoxOGLpackspu
543VBoxOGLpackspu-x86_BLD_TRG_ARCH = x86
544VBoxOGLpackspu-x86_LIBS = $(VBOX_LIB_OGL_CRUTIL_X86) \
545 $(PATH_STAGE_LIB)/additions/VBoxOGLspuload-x86$(VBOX_SUFF_LIB) \
546 $(PATH_STAGE_LIB)/additions/VBoxOGLcrstate-x86$(VBOX_SUFF_LIB) \
547 $(PATH_STAGE_LIB)/additions/VBoxOGLcrpacker-x86$(VBOX_SUFF_LIB)
548VBoxOGLpackspu-x86_DEFS = $(VBoxOGLpackspu_DEFS) VBOX_WDDM_WOW64
549endif
550
551#
552# Generate files for VBoxOGLpackspu.
553#
554$(VBOX_PATH_CROGL_GENFILES)/packspu.c: $(addprefix $(PATH_SUB_CURRENT)/pack/,pack.py packspu_special packspu_unimplemented_special) $(VBOX_CROGL_API_FILES) | $$(dir $$@)
555 $(call MSG_GENERATE,python,$@,$<)
556 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI) $(<D)
557
558$(VBOX_PATH_CROGL_GENFILES)/packspu_get.c: $(PATH_SUB_CURRENT)/pack/packspu_get.py $(PATH_SUB_CURRENT)/pack/packspu_special $(PATH_ROOT)/src/VBox/HostServices/SharedOpenGL/crserverlib/get_sizes.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
559 $(call MSG_GENERATE,python,$@,$<)
560 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI) $(<D)
561
562$(VBOX_PATH_CROGL_GENFILES)/packspu_flush.c: $(PATH_SUB_CURRENT)/pack/packspu_flush.py $(PATH_SUB_CURRENT)/pack/packspu_flush_special $(VBOX_CROGL_API_FILES) | $$(dir $$@)
563 $(call MSG_GENERATE,python,$@,$<)
564 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI) $(<D)
565
566$(VBOX_PATH_CROGL_GENFILES)/packspu_beginend.c: $(PATH_SUB_CURRENT)/pack/packspu_beginend.py $(PATH_SUB_CURRENT)/pack/packspu_vertex_special $(VBOX_CROGL_API_FILES) | $$(dir $$@)
567 $(call MSG_GENERATE,python,$@,$<)
568 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI) $(<D)
569
570$(VBOX_PATH_CROGL_GENFILES)/packspu_proto.h: $(addprefix $(PATH_SUB_CURRENT)/pack/,packspu_proto.py packspu_special packspu_unimplemented_special) $(VBOX_CROGL_API_FILES) | $$(dir $$@)
571 $(call MSG_GENERATE,python,$@,$<)
572 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI) $(<D)
573
574#
575# VBoxOGLfeedbackspu
576#
577VBoxOGLfeedbackspu_TEMPLATE = VBOXCROGLR3GUESTDLL
578VBoxOGLfeedbackspu_INCS = \
579 feedback
580if1of ($(KBUILD_TARGET), linux solaris freebsd)
581 VBoxOGLfeedbackspu_INCS += \
582 $(VBOX_MESA_INCS)
583endif
584if defined(VBOX_SIGNING_MODE) && defined(VBOX_WITH_WDDM)
585 VBoxOGLfeedbackspu_INSTTYPE.win = none
586 VBoxOGLfeedbackspu_DEBUG_INSTTYPE.win = both
587endif
588VBoxOGLarrayspu_INTERMEDIATES = \
589 $(VBOX_PATH_CROGL_GENFILES)/feedbackspu_proto.h
590VBoxOGLfeedbackspu_SOURCES = \
591 feedback/feedbackspu_config.c \
592 feedback/feedbackspu_init.c \
593 feedback/feedback_context.c \
594 $(VBOX_PATH_CROGL_GENFILES)/feedbackspu.c \
595 $(VBOX_PATH_CROGL_GENFILES)/feedbackspu_state.c
596VBoxOGLfeedbackspu_SOURCES.win = \
597 feedback/feedback.def \
598 feedback/feedbackspu.rc
599VBoxOGLfeedbackspu_CLEAN = \
600 $(VBOX_PATH_CROGL_GENFILES)/feedbackspu_proto.h \
601 $(VBOX_PATH_CROGL_GENFILES)/feedbackspu.c \
602 $(VBOX_PATH_CROGL_GENFILES)/feedbackspu_state.c
603VBoxOGLfeedbackspu_LIBS = \
604 $(VBOX_LIB_OGL_CRUTIL) \
605 $(PATH_STAGE_LIB)/additions/VBoxOGLspuload$(VBOX_SUFF_LIB) \
606 $(PATH_STAGE_LIB)/additions/VBoxOGLcrstate$(VBOX_SUFF_LIB)
607ifdef VBOX_WITH_CRHGSMI
608VBoxOGLfeedbackspu_DEFS.win += VBOX_WITH_CRHGSMI
609endif
610ifdef VBOX_WITH_WDDM
611VBoxOGLfeedbackspu_DEFS.win += VBOX_WITH_WDDM
612endif
613
614ifdef VBOX_WITH_WDDM
615#
616# VBoxOGLfeedbackspu-x86 - x86 version of VBoxOGLfeedbackspu built for amd64 build
617#
618DLLS.win.amd64 += VBoxOGLfeedbackspu-x86
619VBoxOGLfeedbackspu-x86_EXTENDS = VBoxOGLfeedbackspu
620VBoxOGLfeedbackspu-x86_BLD_TRG_ARCH = x86
621VBoxOGLfeedbackspu-x86_LIBS = $(VBOX_LIB_OGL_CRUTIL_X86) \
622 $(PATH_STAGE_LIB)/additions/VBoxOGLspuload-x86$(VBOX_SUFF_LIB) \
623 $(PATH_STAGE_LIB)/additions/VBoxOGLcrstate-x86$(VBOX_SUFF_LIB)
624VBoxOGLfeedbackspu-x86_DEFS = $(VBoxOGLfeedbackspu_DEFS) VBOX_WDDM_WOW64
625endif
626
627#
628# Generate files for VBoxOGLfeedbackspu.
629#
630$(VBOX_PATH_CROGL_GENFILES)/feedbackspu.c: $(addprefix $(PATH_SUB_CURRENT)/feedback/,feedback.py feedback_special select_special feedback_state_special) $(VBOX_CROGL_API_FILES) | $$(dir $$@)
631 $(call MSG_GENERATE,python,$@,$<)
632 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI) $(<D)
633
634$(VBOX_PATH_CROGL_GENFILES)/feedbackspu_state.c: $(addprefix $(PATH_SUB_CURRENT)/feedback/,feedback_state.py feedback_state_special) $(VBOX_CROGL_API_FILES) | $$(dir $$@)
635 $(call MSG_GENERATE,python,$@,$<)
636 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI) $(<D)
637
638$(VBOX_PATH_CROGL_GENFILES)/feedbackspu_proto.h: $(addprefix $(PATH_SUB_CURRENT)/feedback/,feedbackspu_proto.py feedback_special select_special feedback_state_special) $(VBOX_CROGL_API_FILES) | $$(dir $$@)
639 $(call MSG_GENERATE,python,$@,$<)
640 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI) $(<D)
641
642include $(FILE_KBUILD_SUB_FOOTER)
643
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