VirtualBox

source: vbox/trunk/src/VBox/GuestHost/OpenGL/Makefile.kmk@ 46147

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

Additions/linux: build 32-bit versions too for COMPATIBLE builds.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 26.0 KB
Line 
1# $Id: Makefile.kmk 46147 2013-05-17 15:35:09Z vboxsync $
2## @file
3# Sub-Makefile for the VirtualBox Guest/Host OpenGL part
4#
5
6#
7# Copyright (C) 2008-2013 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#
23# Target lists.
24#
25BLDDIRS += \
26 $(VBOX_PATH_CROGL_GENFILES)/ \
27 $(VBOX_PATH_CROGL_GENFILES)/state/
28
29ifdef VBOX_WITH_ADDITIONS
30 ifn1of ($(KBUILD_TARGET), darwin os2)
31 VBOX_WITH_CROGL_ADDITIONS = 1
32 endif
33endif
34
35ifdef VBOX_WITH_CROGL_ADDITIONS
36 DLLS += VBoxOGLcrutil VBoxOGLerrorspu
37 LIBRARIES += VBoxOGLcrpacker VBoxOGLspuload VBoxOGLcrstate
38endif
39
40ifndef VBOX_ONLY_ADDITIONS
41 DLLS += VBoxOGLhostcrutil VBoxOGLhosterrorspu
42 LIBRARIES += VBoxOGLhostcrpacker VBoxOGLhostspuload VBoxOGLhostcrstate
43endif
44
45VBOX_OGL_X86_COMMON_DLLS = \
46 VBoxOGLcrutil-x86 \
47 VBoxOGLerrorspu-x86
48VBOX_OGL_X86_COMMON_LIBS = \
49 VBoxOGLcrpacker-x86 \
50 VBoxOGLspuload-x86 \
51 VBoxOGLcrstate-x86
52if defined(VBOX_WITH_WDDM) && defined(VBOX_WITH_CROGL_ADDITIONS)
53 DLLS.win.amd64 += $(VBOX_OGL_X86_COMMON_DLLS)
54endif
55if defined(VBOX_WITH_WDDM) && defined(VBOX_WITH_CROGL_ADDITIONS)
56 LIBRARIES.win.amd64 += $(VBOX_OGL_X86_COMMON_LIBS)
57endif
58# 32-bit version for the 64-bit Linux Additions
59ifeq ($(KBUILD_TARGET).$(KBUILD_TARGET_ARCH),linux.amd64)
60 ifneq ($(VBOX_WITH_COMPATIBLE_LINUX_GUEST_PACKAGE),)
61 LIBRARIES += $(VBOX_OGL_X86_COMMON_LIBS)
62 DLLS += $(VBOX_OGL_X86_COMMON_DLLS)
63 $(foreach i,$(VBOX_OGL_X86_COMMON_DLLS),$(eval $(i)_INST = $(INST_ADDITIONS)/32/))
64 $(foreach i,$(VBOX_OGL_X86_COMMON_DLLS),$(eval $(i)_NAME = $(subst -x86,,$(i))))
65 endif
66endif
67
68#
69# VBoxOGLcrutil
70#
71VBoxOGLcrutil_TEMPLATE = VBOXCROGLR3GUESTDLL
72if defined(VBOX_SIGNING_MODE) && defined(VBOX_WITH_WDDM)
73 VBoxOGLcrutil_INSTTYPE.win = none
74 VBoxOGLcrutil_DEBUG_INSTTYPE.win = both
75endif
76VBoxOGLcrutil_SDKS.win = ReorderCompilerIncs $(VBOX_WINPSDK) $(VBOX_WINDDK)
77VBoxOGLcrutil_INTERMEDIATES = $(VBOX_PATH_CROGL_GENFILES)/cr_opcodes.h
78if1of ($(KBUILD_TARGET), linux solaris freebsd)
79 VBoxOGLcrutil_INCS += \
80 $(VBOX_MESA_INCS)
81endif
82VBoxOGLcrutil_SOURCES = \
83 util/bbox.c \
84 util/bufpool.c \
85 util/calllists.c \
86 util/devnull.c \
87 util/dll.c \
88 util/endian.c \
89 util/environment.c \
90 util/error.c \
91 util/filenet.c \
92 util/hash.c \
93 util/hull.c \
94 util/list.c \
95 util/matrix.c \
96 util/mem.c \
97 util/net.c \
98 util/pixel.c \
99 util/process.c \
100 util/rand.c \
101 util/string.c \
102 util/threads.c \
103 util/tcpip.c \
104 util/udptcpip.c \
105 util/timer.c \
106 util/url.c \
107 util/warp.c \
108 util/vreg.cpp \
109 util/blitter.cpp \
110 util/vboxhgcm.c \
111 $(VBOX_PATH_CROGL_GENFILES)/debug_opcodes.c
112VBoxOGLcrutil_SOURCES.win.x86 = \
113 util/util.def \
114 util/util.rc
115VBoxOGLcrutil_LIBS.win = \
116 $(PATH_SDK_$(VBOX_WINDDK)_LIB)/ddraw.lib \
117 $(PATH_SDK_$(VBOX_WINDDK)_LIB)/dxguid.lib
118VBoxOGLcrutil_LIBS = \
119 $(VBOX_LIB_IPRT_GUEST_R3_SHARED) \
120 $(VBOX_LIB_VBGL_R3_SHARED)
121ifdef VBOX_WITH_CRHGSMI
122VBoxOGLcrutil_DEFS.win += VBOX_WITH_CRHGSMI
123VBoxOGLcrutil_LIBS.win += $(VBOX_PATH_ADDITIONS_LIB)/VBoxCrHgsmi$(VBOX_SUFF_LIB)
124endif
125ifdef VBOX_WITH_WDDM
126VBoxOGLcrutil_DEFS.win += VBOX_WITH_WDDM
127VBoxOGLcrutil_DEFS.win += CR_DEBUG_BACKDOOR_ENABLE
128VBoxOGLcrutil_INCS.win += $(PATH_ROOT)/src/VBox/Additions/WINNT/Graphics/Video/disp/wddm
129VBoxOGLcrutil_LIBS.win += $(VBOX_PATH_ADDITIONS_LIB)/VBoxDispMpLogger$(VBOX_SUFF_LIB)
130endif
131VBoxOGLcrutil_CLEAN = \
132 $(VBOX_PATH_CROGL_GENFILES)/debug_opcodes.c
133
134# vc7 hangs during compilation of this file when optimizations are enabled.
135VBoxOGLcrutil_pixel.c_CFLAGS.win.x86 += -Od
136VBoxOGLhostcrutil_pixel.c_CFLAGS.win.x86 += -Od
137
138#
139# VBoxOGLcrutil-x86 - x86 VBoxOGLcrutil version built for amd64 build
140#
141VBoxOGLcrutil-x86_TEMPLATE = VBOXCROGLR3GUESTDLL
142VBoxOGLcrutil-x86_EXTENDS = VBoxOGLcrutil
143VBoxOGLcrutil-x86_BLD_TRG_ARCH = x86
144VBoxOGLcrutil-x86_LIBS = $(VBOX_LIB_IPRT_GUEST_R3_SHARED_X86) \
145 $(VBOX_LIB_VBGL_R3_SHARED_X86)
146VBoxOGLcrutil-x86_LIBS.win = \
147 $(PATH_SDK_$(VBOX_WINDDK)_LIB.x86)/ddraw.lib \
148 $(PATH_SDK_$(VBOX_WINDDK)_LIB.x86)/dxguid.lib
149ifdef VBOX_WITH_CRHGSMI
150# VBOX_WITH_CRHGSMI define is inherited from VBoxOGLcrutil
151VBoxOGLcrutil-x86_LIBS.win += $(VBOX_PATH_ADDITIONS_LIB)/VBoxCrHgsmi-x86$(VBOX_SUFF_LIB)
152endif
153VBoxOGLcrutil-x86_DEFS = $(VBoxOGLcrutil_DEFS) VBOX_WDDM_WOW64
154ifdef VBOX_WITH_WDDM
155# CR_DEBUG_BACKDOOR_ENABLE define is inherited from VBoxOGLcrutil
156VBoxOGLcrutil-x86_INCS.win += $(PATH_ROOT)/src/VBox/Additions/WINNT/Graphics/Video/disp/wddm
157VBoxOGLcrutil-x86_LIBS.win += $(VBOX_PATH_ADDITIONS_LIB)/VBoxDispMpLogger-x86$(VBOX_SUFF_LIB)
158endif
159# vc7 hangs during compilation of this file when optimizations are enabled.
160VBoxOGLcrutil-x86_pixel.c_CFLAGS += -Od
161VBoxOGLcrutil-x86_pixel.c_CFLAGS += -Od
162
163#
164# VBoxOGLhostcrutil
165#
166VBoxOGLhostcrutil_EXTENDS = VBoxOGLcrutil
167VBoxOGLhostcrutil_TEMPLATE = VBOXCROGLR3HOSTDLL
168if defined(VBOX_SIGNING_MODE) && defined(VBOX_WITH_WDDM)
169 VBoxOGLhostcrutil_INSTTYPE.win = both
170endif
171VBoxOGLhostcrutil_LDFLAGS.darwin = $(VBoxOGLcrutil_LDFLAGS.darwin) \
172 -install_name $(VBOX_DYLD_EXECUTABLE_PATH)/VBoxOGLhostcrutil.dylib
173VBoxOGLhostcrutil_LIBS.win = \
174 $(PATH_SDK_$(VBOX_WINDDK)_LIB)/ddraw.lib \
175 $(PATH_SDK_$(VBOX_WINDDK)_LIB)/dxguid.lib
176VBoxOGLhostcrutil_LIBS = $(LIB_RUNTIME)
177ifdef VBOX_WITH_CRHGSMI
178VBoxOGLhostcrutil_DEFS += VBOX_WITH_CRHGSMI
179endif
180ifdef VBOX_WITH_WDDM
181VBoxOGLhostcrutil_INCS.win = $(NO_SUCH_VARIABLE)
182VBoxOGLhostcrutil_DEFS.win = $(NO_SUCH_VARIABLE)
183endif
184
185#
186# Generate files for VBoxOGLcrutil and VBoxOGLhostcrutil.
187#
188$(VBOX_PATH_CROGL_GENFILES)/debug_opcodes.c: $(PATH_SUB_CURRENT)/util/debug_opcodes.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
189 $(call MSG_GENERATE,python,$@,$<)
190 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
191
192#
193# VBoxOGLcrpacker
194#
195VBoxOGLcrpacker_TEMPLATE = VBOXCROGLR3GUESTLIB
196VBoxOGLcrpacker_INCS = \
197 packer
198if1of ($(KBUILD_TARGET), linux solaris freebsd)
199 VBoxOGLcrpacker_INCS += \
200 $(VBOX_MESA_INCS)
201endif
202VBoxOGLcrpacker_INTERMEDIATES = \
203 $(VBOX_PATH_CROGL_GENFILES)/cr_packfunctions.h \
204 $(VBOX_PATH_CROGL_GENFILES)/cr_opcodes.h \
205 $(VBOX_PATH_CROGL_GENFILES)/state/cr_currentpointers.h \
206 $(VBOX_PATH_CROGL_GENFILES)/state/cr_statefuncs.h \
207 $(VBOX_PATH_CROGL_GENFILES)/spu_dispatch_table.h
208VBoxOGLcrpacker_SOURCES = \
209 packer/pack_arrays.c \
210 packer/pack_beginend.c \
211 packer/pack_bounds.c \
212 packer/pack_buffer.c \
213 packer/pack_bufferobject.c \
214 packer/pack_client.c \
215 packer/pack_clipplane.c \
216 packer/pack_context.c \
217 packer/pack_error.c \
218 packer/pack_extensions.c \
219 packer/pack_feedback.c \
220 packer/pack_fence.c \
221 packer/pack_fog.c \
222 packer/pack_init.c \
223 packer/pack_lights.c \
224 packer/pack_lists.c \
225 packer/pack_swap_lists.c \
226 packer/pack_map.c \
227 packer/pack_point.c \
228 packer/pack_swap_map.c \
229 packer/pack_misc.c \
230 packer/pack_materials.c \
231 packer/pack_matrices.c \
232 packer/pack_pixels.c \
233 packer/pack_pixelmap.c \
234 packer/pack_swap_pixelmap.c \
235 packer/pack_program.c \
236 packer/pack_regcombiner.c \
237 packer/pack_stipple.c \
238 packer/pack_texture.c \
239 packer/pack_swap_texture.c \
240 packer/pack_visibleregion.c \
241 packer/pack_shaders.c \
242 packer/pack_framebuffer.c \
243 $(VBOX_PATH_CROGL_GENFILES)/pack_arrays_swap.c \
244 $(VBOX_PATH_CROGL_GENFILES)/pack_bounds_swap.c \
245 $(VBOX_PATH_CROGL_GENFILES)/pack_bufferobject_swap.c \
246 $(VBOX_PATH_CROGL_GENFILES)/pack_client_swap.c \
247 $(VBOX_PATH_CROGL_GENFILES)/pack_clipplane_swap.c \
248 $(VBOX_PATH_CROGL_GENFILES)/pack_fog_swap.c \
249 $(VBOX_PATH_CROGL_GENFILES)/pack_lights_swap.c \
250 $(VBOX_PATH_CROGL_GENFILES)/pack_materials_swap.c \
251 $(VBOX_PATH_CROGL_GENFILES)/pack_matrices_swap.c \
252 $(VBOX_PATH_CROGL_GENFILES)/pack_misc_swap.c \
253 $(VBOX_PATH_CROGL_GENFILES)/pack_pixels_swap.c \
254 $(VBOX_PATH_CROGL_GENFILES)/pack_point_swap.c \
255 $(VBOX_PATH_CROGL_GENFILES)/pack_program_swap.c \
256 $(VBOX_PATH_CROGL_GENFILES)/pack_regcombiner_swap.c \
257 $(VBOX_PATH_CROGL_GENFILES)/pack_stipple_swap.c \
258 $(VBOX_PATH_CROGL_GENFILES)/pack_bbox.c \
259 $(VBOX_PATH_CROGL_GENFILES)/pack_current.c \
260 $(VBOX_PATH_CROGL_GENFILES)/packer.c
261VBoxOGLcrpacker_CLEAN = \
262 $(VBOX_PATH_CROGL_GENFILES)/pack_arrays_swap.c \
263 $(VBOX_PATH_CROGL_GENFILES)/pack_bounds_swap.c \
264 $(VBOX_PATH_CROGL_GENFILES)/pack_bufferobject_swap.c \
265 $(VBOX_PATH_CROGL_GENFILES)/pack_client_swap.c \
266 $(VBOX_PATH_CROGL_GENFILES)/pack_clipplane_swap.c \
267 $(VBOX_PATH_CROGL_GENFILES)/pack_fog_swap.c \
268 $(VBOX_PATH_CROGL_GENFILES)/pack_lights_swap.c \
269 $(VBOX_PATH_CROGL_GENFILES)/pack_materials_swap.c \
270 $(VBOX_PATH_CROGL_GENFILES)/pack_matrices_swap.c \
271 $(VBOX_PATH_CROGL_GENFILES)/pack_misc_swap.c \
272 $(VBOX_PATH_CROGL_GENFILES)/pack_pixels_swap.c \
273 $(VBOX_PATH_CROGL_GENFILES)/pack_point_swap.c \
274 $(VBOX_PATH_CROGL_GENFILES)/pack_program_swap.c \
275 $(VBOX_PATH_CROGL_GENFILES)/pack_regcombiner_swap.c \
276 $(VBOX_PATH_CROGL_GENFILES)/pack_stipple_swap.c \
277 $(VBOX_PATH_CROGL_GENFILES)/pack_bbox.c \
278 $(VBOX_PATH_CROGL_GENFILES)/pack_current.c \
279 $(VBOX_PATH_CROGL_GENFILES)/packer.c \
280 $(VBOX_PATH_CROGL_GENFILES)/cr_packfunctions.h \
281 $(VBOX_PATH_CROGL_GENFILES)/cr_opcodes.h \
282 $(VBOX_PATH_CROGL_GENFILES)/state/cr_currentpointers.h
283ifdef VBOX_WITH_CRHGSMI
284VBoxOGLcrpacker_DEFS.win += VBOX_WITH_CRHGSMI
285endif
286ifdef VBOX_WITH_WDDM
287VBoxOGLcrpacker_DEFS.win += VBOX_WITH_WDDM
288endif
289
290#
291# VBoxOGLcrpacker-x86 - x86 VBoxOGLcrpacker version built for amd64 build
292#
293VBoxOGLcrpacker-x86_TEMPLATE = VBOXCROGLR3GUESTLIB
294VBoxOGLcrpacker-x86_EXTENDS = VBoxOGLcrpacker
295VBoxOGLcrpacker-x86_BLD_TRG_ARCH = x86
296VBoxOGLcrpacker-x86_DEFS = $(VBoxOGLcrpacker_DEFS) VBOX_WDDM_WOW64
297
298#
299# VBoxOGLhostcrpacker
300#
301VBoxOGLhostcrpacker_EXTENDS = VBoxOGLcrpacker
302VBoxOGLhostcrpacker_TEMPLATE = VBOXCROGLR3HOSTLIB
303
304#
305# Generate files for VBoxOGLcrpacker and VBoxOGLhostcrpacker.
306#
307$(VBOX_PATH_CROGL_GENFILES)/packer.def: $(PATH_SUB_CURRENT)/packer/packer_defs.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
311$(VBOX_PATH_CROGL_GENFILES)/cr_packfunctions.h: $(PATH_SUB_CURRENT)/packer/pack_header.py $(PATH_SUB_CURRENT)/packer/packer_special $(VBOX_CROGL_API_FILES) | $$(dir $$@)
312 $(call MSG_GENERATE,python,$@,$<)
313 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI) $(<D)
314
315$(VBOX_PATH_CROGL_GENFILES)/cr_opcodes.h: $(PATH_SUB_CURRENT)/packer/opcodes.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
316 $(call MSG_GENERATE,python,$@,$<)
317 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
318
319$(VBOX_PATH_CROGL_GENFILES)/state/cr_currentpointers.h: $(PATH_SUB_CURRENT)/packer/pack_currentheader.py $(PATH_SUB_CURRENT)/packer/pack_currenttypes.py | $$(dir $(VBOX_PATH_CROGL_GENFILES)) $$(dir $$@)
320 $(call MSG_GENERATE,python,$@,$<)
321 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $<
322
323$(VBOX_PATH_CROGL_GENFILES)/packer.c: $(PATH_SUB_CURRENT)/packer/packer.py $(PATH_SUB_CURRENT)/packer/packer_special $(VBOX_CROGL_API_FILES) | $$(dir $$@)
324 $(call MSG_GENERATE,python,$@,$<)
325 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI) $(<D)
326
327$(VBOX_PATH_CROGL_GENFILES)/pack_bbox.c: $(PATH_SUB_CURRENT)/packer/packer_bbox.py | $$(dir $$@)
328 $(call MSG_GENERATE,python,$@,$<)
329 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
330
331$(VBOX_PATH_CROGL_GENFILES)/pack_current.c: $(PATH_SUB_CURRENT)/packer/pack_current.py $(PATH_SUB_CURRENT)/packer/pack_currenttypes.py | $$(dir $$@)
332 $(call MSG_GENERATE,python,$@,$<)
333 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $<
334
335$(VBOX_PATH_CROGL_GENFILES)/%_swap.c: $(PATH_SUB_CURRENT)/packer/%.c $(PATH_SUB_CURRENT)/packer/pack_swap.py | $$(dir $$@)
336 $(call MSG_GENERATE,python,$@,$<)
337 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $(<D)/pack_swap.py $<
338
339
340#
341# VBoxOGLspuload
342#
343VBoxOGLspuload_TEMPLATE = VBOXCROGLR3GUESTLIB
344VBoxOGLspuload_INTERMEDIATES = \
345 $(VBOX_PATH_CROGL_GENFILES)/spu_dispatch_table.h
346if1of ($(KBUILD_TARGET), linux solaris freebsd)
347 VBoxOGLspuload_INCS += \
348 $(VBOX_MESA_INCS)
349endif
350VBoxOGLspuload_SOURCES = \
351 spu_loader/spuinit.c \
352 spu_loader/spuload.c \
353 spu_loader/choosevisual.c \
354 $(VBOX_PATH_CROGL_GENFILES)/spuchange.c \
355 $(VBOX_PATH_CROGL_GENFILES)/spucopy.c \
356 $(VBOX_PATH_CROGL_GENFILES)/dispatch.c \
357 $(VBOX_PATH_CROGL_GENFILES)/glloader.c
358VBoxOGLspuload_CLEAN = \
359 $(VBOX_PATH_CROGL_GENFILES)/spuchange.c \
360 $(VBOX_PATH_CROGL_GENFILES)/spucopy.c \
361 $(VBOX_PATH_CROGL_GENFILES)/dispatch.c \
362 $(VBOX_PATH_CROGL_GENFILES)/glloader.c \
363 $(VBOX_PATH_CROGL_GENFILES)/spu_dispatch_table.h
364ifdef VBOX_WITH_CRHGSMI
365VBoxOGLspuload_DEFS.win += VBOX_WITH_CRHGSMI
366endif
367ifdef VBOX_WITH_WDDM
368VBoxOGLspuload_DEFS.win += VBOX_WITH_WDDM
369endif
370
371#
372# VBoxOGLspuload-x86 - x86 VBoxOGLspuload version built for amd64 build
373#
374VBoxOGLspuload-x86_TEMPLATE = VBOXCROGLR3GUESTLIB
375VBoxOGLspuload-x86_EXTENDS = VBoxOGLspuload
376VBoxOGLspuload-x86_BLD_TRG_ARCH = x86
377VBoxOGLspuload-x86_DEFS = $(VBoxOGLspuload_DEFS) VBOX_WDDM_WOW64
378
379
380#
381# VBoxOGLhostspuload
382#
383VBoxOGLhostspuload_EXTENDS = VBoxOGLspuload
384VBoxOGLhostspuload_TEMPLATE = VBOXCROGLR3HOSTLIB
385
386#
387# Generate files for VBoxOGLspuload and VBoxOGLhostspuload.
388#
389$(VBOX_PATH_CROGL_GENFILES)/dispatch.c: $(PATH_SUB_CURRENT)/spu_loader/dispatch.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
390 $(call MSG_GENERATE,python,$@,$<)
391 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
392
393$(VBOX_PATH_CROGL_GENFILES)/spucopy.c: $(PATH_SUB_CURRENT)/spu_loader/spucopy.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
394 $(call MSG_GENERATE,python,$@,$<)
395 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
396
397$(VBOX_PATH_CROGL_GENFILES)/spuchange.c: $(PATH_SUB_CURRENT)/spu_loader/spuchange.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
398 $(call MSG_GENERATE,python,$@,$<)
399 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
400
401$(VBOX_PATH_CROGL_GENFILES)/glloader.c: $(PATH_SUB_CURRENT)/spu_loader/glloader.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
402 $(call MSG_GENERATE,python,$@,$<)
403 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
404
405$(VBOX_PATH_CROGL_GENFILES)/spu_dispatch_table.h: $(PATH_SUB_CURRENT)/spu_loader/dispatchheader.py $(VBOX_CROGL_API_FILES) | $$(dir $$@)
406 $(call MSG_GENERATE,python,$@,$<)
407 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
408
409
410#
411# VBoxOGLcrstate
412#
413VBoxOGLcrstate_TEMPLATE = VBOXCROGLR3GUESTLIB
414VBoxOGLcrstate_INCS = \
415 state_tracker
416if1of ($(KBUILD_TARGET), linux solaris freebsd)
417 VBoxOGLcrstate_INCS += \
418 $(VBOX_MESA_INCS)
419endif
420VBoxOGLcrstate_INTERMEDIATES = \
421 $(VBOX_PATH_CROGL_GENFILES)/state/cr_statefuncs.h \
422 $(VBOX_PATH_CROGL_GENFILES)/state/cr_currentpointers.h \
423 $(VBOX_PATH_CROGL_GENFILES)/spu_dispatch_table.h
424VBoxOGLcrstate_SOURCES = \
425 state_tracker/state_attrib.c \
426 state_tracker/state_buffer.c \
427 state_tracker/state_bufferobject.c \
428 state_tracker/state_client.c \
429 state_tracker/state_current.c \
430 state_tracker/state_diff.c \
431 state_tracker/state_enable.c \
432 state_tracker/state_error.c \
433 state_tracker/state_evaluators.c \
434 state_tracker/state_feedback.c \
435 state_tracker/state_fence.c \
436 state_tracker/state_flush.c \
437 state_tracker/state_fog.c \
438 state_tracker/state_getstring.c \
439 state_tracker/state_hint.c \
440 state_tracker/state_init.c \
441 state_tracker/state_lighting.c \
442 state_tracker/state_limits.c \
443 state_tracker/state_line.c \
444 state_tracker/state_lists.c \
445 state_tracker/state_multisample.c \
446 state_tracker/state_occlude.c \
447 state_tracker/state_pixel.c \
448 state_tracker/state_point.c \
449 state_tracker/state_polygon.c \
450 state_tracker/state_program.c \
451 state_tracker/state_rasterpos.c \
452 state_tracker/state_regcombiner.c \
453 state_tracker/state_stencil.c \
454 state_tracker/state_texture.c \
455 state_tracker/state_teximage.c \
456 state_tracker/state_texdiff.c \
457 state_tracker/state_transform.c \
458 state_tracker/state_viewport.c \
459 state_tracker/state_framebuffer.c \
460 state_tracker/state_glsl.c \
461 $(VBOX_PATH_CROGL_GENFILES)/state_buffer_gen.c \
462 $(VBOX_PATH_CROGL_GENFILES)/state_current_gen.c \
463 $(VBOX_PATH_CROGL_GENFILES)/state_fog_gen.c \
464 $(VBOX_PATH_CROGL_GENFILES)/state_hint_gen.c \
465 $(VBOX_PATH_CROGL_GENFILES)/state_lighting_gen.c \
466 $(VBOX_PATH_CROGL_GENFILES)/state_line_gen.c \
467 $(VBOX_PATH_CROGL_GENFILES)/state_multisample_gen.c \
468 $(VBOX_PATH_CROGL_GENFILES)/state_point_gen.c \
469 $(VBOX_PATH_CROGL_GENFILES)/state_polygon_gen.c \
470 $(VBOX_PATH_CROGL_GENFILES)/state_regcombiner_gen.c \
471 $(VBOX_PATH_CROGL_GENFILES)/state_viewport_gen.c \
472 $(VBOX_PATH_CROGL_GENFILES)/state_get.c \
473 $(VBOX_PATH_CROGL_GENFILES)/state_isenabled.c
474VBoxOGLcrstate_CLEAN = \
475 $(VBOX_PATH_CROGL_GENFILES)/state_buffer_gen.c \
476 $(VBOX_PATH_CROGL_GENFILES)/state_current_gen.c \
477 $(VBOX_PATH_CROGL_GENFILES)/state_fog_gen.c \
478 $(VBOX_PATH_CROGL_GENFILES)/state_hint_gen.c \
479 $(VBOX_PATH_CROGL_GENFILES)/state_lighting_gen.c \
480 $(VBOX_PATH_CROGL_GENFILES)/state_line_gen.c \
481 $(VBOX_PATH_CROGL_GENFILES)/state_multisample_gen.c \
482 $(VBOX_PATH_CROGL_GENFILES)/state_point_gen.c \
483 $(VBOX_PATH_CROGL_GENFILES)/state_polygon_gen.c \
484 $(VBOX_PATH_CROGL_GENFILES)/state_regcombiner_gen.c \
485 $(VBOX_PATH_CROGL_GENFILES)/state_viewport_gen.c \
486 $(VBOX_PATH_CROGL_GENFILES)/state_get.c \
487 $(VBOX_PATH_CROGL_GENFILES)/state_isenabled.c \
488 $(VBOX_PATH_CROGL_GENFILES)/state/cr_statefuncs.h
489ifneq ($(KBUILD_TARGET),win)
490 ifeq ($(VBOX_WITH_COMPATIBLE_LINUX_GUEST_PACKAGE),)
491state_tracker/state_lists.c_CFLAGS += $(VBOX_GCC_Wno-pointer-sign)
492VBoxOGLcrstate_CFLAGS +=
493 endif
494endif
495ifdef VBOX_WITH_CRHGSMI
496VBoxOGLcrstate_DEFS.win += VBOX_WITH_CRHGSMI
497endif
498ifdef VBOX_WITH_WDDM
499VBoxOGLcrstate_DEFS.win += VBOX_WITH_WDDM
500endif
501
502#
503# VBoxOGLcrstate-x86 - x86 VBoxOGLcrstate version built for amd64 build
504#
505VBoxOGLcrstate-x86_TEMPLATE = VBOXCROGLR3GUESTLIB
506VBoxOGLcrstate-x86_EXTENDS = VBoxOGLcrstate
507VBoxOGLcrstate-x86_BLD_TRG_ARCH = x86
508VBoxOGLcrstate-x86_DEFS = $(VBoxOGLcrstate_DEFS) VBOX_WDDM_WOW64
509
510
511#
512# VBoxOGLhostcrstate
513#
514VBoxOGLhostcrstate_EXTENDS = VBoxOGLcrstate
515VBoxOGLhostcrstate_TEMPLATE = VBOXCROGLR3HOSTLIB
516VBoxOGLhostcrstate_SOURCES = \
517 $(VBoxOGLcrstate_SOURCES) \
518 state_tracker/state_snapshot.c
519
520#
521# Generate files for VBoxOGLcrstate and VBoxOGLhostcrstate.
522#
523
524
525$(VBOX_PATH_CROGL_GENFILES)/state_buffer_gen.c: $(addprefix $(PATH_SUB_CURRENT)/state_tracker/, state_buffer.txt gendiffcode.py) | $$(dir $$@)
526 $(call MSG_GENERATE,python,$@,$<)
527 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $(<D)/gendiffcode.py buffer Buffer $(<D)
528
529$(VBOX_PATH_CROGL_GENFILES)/state_client_gen.c: $(addprefix $(PATH_SUB_CURRENT)/state_tracker/, state_client.txt gendiffcode.py) | $$(dir $$@)
530 $(call MSG_GENERATE,python,$@,$<)
531 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $(<D)/gendiffcode.py client Client $(<D)
532
533$(VBOX_PATH_CROGL_GENFILES)/state_current_gen.c: $(addprefix $(PATH_SUB_CURRENT)/state_tracker/, state_current.py convert.py) $(VBOX_CROGL_API_FILES) | $$(dir $$@)
534 $(call MSG_GENERATE,python,$@,$<)
535 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $(<D)/state_current.py
536
537$(VBOX_PATH_CROGL_GENFILES)/state_fog_gen.c: $(addprefix $(PATH_SUB_CURRENT)/state_tracker/, state_fog.txt gendiffcode.py) | $$(dir $$@)
538 $(call MSG_GENERATE,python,$@,$<)
539 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $(<D)/gendiffcode.py fog Fog $(<D)
540
541$(VBOX_PATH_CROGL_GENFILES)/state_hint_gen.c: $(addprefix $(PATH_SUB_CURRENT)/state_tracker/, state_hint.txt gendiffcode.py) | $$(dir $$@)
542 $(call MSG_GENERATE,python,$@,$<)
543 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $(<D)/gendiffcode.py hint Hint $(<D)
544
545$(VBOX_PATH_CROGL_GENFILES)/state_lighting_gen.c: $(addprefix $(PATH_SUB_CURRENT)/state_tracker/, state_lighting.txt gendiffcode.py) | $$(dir $$@)
546 $(call MSG_GENERATE,python,$@,$<)
547 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $(<D)/gendiffcode.py lighting Lighting $(<D)
548
549$(VBOX_PATH_CROGL_GENFILES)/state_line_gen.c: $(addprefix $(PATH_SUB_CURRENT)/state_tracker/, state_line.txt gendiffcode.py) | $$(dir $$@)
550 $(call MSG_GENERATE,python,$@,$<)
551 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $(<D)/gendiffcode.py line Line $(<D)
552
553$(VBOX_PATH_CROGL_GENFILES)/state_multisample_gen.c: $(addprefix $(PATH_SUB_CURRENT)/state_tracker/, state_multisample.txt gendiffcode.py) | $$(dir $$@)
554 $(call MSG_GENERATE,python,$@,$<)
555 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $(<D)/gendiffcode.py multisample Multisample $(<D)
556
557$(VBOX_PATH_CROGL_GENFILES)/state_point_gen.c: $(addprefix $(PATH_SUB_CURRENT)/state_tracker/, state_point.txt gendiffcode.py) | $$(dir $$@)
558 $(call MSG_GENERATE,python,$@,$<)
559 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $(<D)/gendiffcode.py point Point $(<D)
560
561$(VBOX_PATH_CROGL_GENFILES)/state_polygon_gen.c: $(addprefix $(PATH_SUB_CURRENT)/state_tracker/, state_polygon.txt gendiffcode.py) | $$(dir $$@)
562 $(call MSG_GENERATE,python,$@,$<)
563 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $(<D)/gendiffcode.py polygon Polygon $(<D)
564
565$(VBOX_PATH_CROGL_GENFILES)/state_regcombiner_gen.c: $(addprefix $(PATH_SUB_CURRENT)/state_tracker/, state_regcombiner.txt gendiffcode.py) | $$(dir $$@)
566 $(call MSG_GENERATE,python,$@,$<)
567 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $(<D)/gendiffcode.py regcombiner RegCombiner $(<D)
568
569$(VBOX_PATH_CROGL_GENFILES)/state_viewport_gen.c: $(addprefix $(PATH_SUB_CURRENT)/state_tracker/, state_viewport.txt gendiffcode.py) | $$(dir $$@)
570 $(call MSG_GENERATE,python,$@,$<)
571 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $(<D)/gendiffcode.py viewport Viewport $(<D)
572
573$(VBOX_PATH_CROGL_GENFILES)/state_get.c: $(addprefix $(PATH_SUB_CURRENT)/state_tracker/, state_get.py state_get.txt state_extensions_get.txt) $(VBOX_CROGL_API_FILES) | $$(dir $$@)
574 $(call MSG_GENERATE,python,$@,$<)
575 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $(<D)/state_get.py $(VBOX_PATH_CROGL_GLAPI) $(<D)
576
577$(VBOX_PATH_CROGL_GENFILES)/state_isenabled.c: $(addprefix $(PATH_SUB_CURRENT)/state_tracker/, state_isenabled.py state_isenabled.txt state_extensions_isenabled.txt) $(VBOX_CROGL_API_FILES) | $$(dir $$@)
578 $(call MSG_GENERATE,python,$@,$<)
579 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $(<D)/state_isenabled.py $(VBOX_PATH_CROGL_GLAPI) $(<D)
580
581$(VBOX_PATH_CROGL_GENFILES)/state.def: $(addprefix $(PATH_SUB_CURRENT)/state_tracker/, state_defs.py state_special state_select_special state_feedback_special) $(VBOX_CROGL_API_FILES) | $$(dir $$@)
582 $(call MSG_GENERATE,python,$@,$<)
583 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $(<D)/state_defs.py $(VBOX_PATH_CROGL_GLAPI) $(<D)
584
585$(VBOX_PATH_CROGL_GENFILES)/state/cr_statefuncs.h: $(addprefix $(PATH_SUB_CURRENT)/state_tracker/, state_funcs.py state_special state_feedback_special state_select_special) $(VBOX_CROGL_API_FILES) | $$(dir $$@)
586 $(call MSG_GENERATE,python,$@,$<)
587 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $(<D)/state_funcs.py $(VBOX_PATH_CROGL_GLAPI) $(<D)
588
589
590#
591# VBoxOGLerrorspu
592# @remark See HostServices/OpenGL/Makefile for and explanation of the gl.h
593# and glu.h intermediate files on darwin.
594#
595VBoxOGLerrorspu_TEMPLATE = VBOXCROGLR3GUESTDLL
596if defined(VBOX_SIGNING_MODE) && defined(VBOX_WITH_WDDM)
597 VBoxOGLerrorspu_INSTTYPE.win = none
598 VBoxOGLerrorspu_DEBUG_INSTTYPE.win = both
599endif
600VBoxOGLerrorspu_INTERMEDIATES = \
601 $(VBOX_PATH_CROGL_GENFILES)/spu_dispatch_table.h
602if1of ($(KBUILD_TARGET), linux solaris freebsd)
603 VBoxOGLerrorspu_INCS += \
604 $(VBOX_MESA_INCS)
605endif
606VBoxOGLerrorspu_SOURCES = \
607 $(VBOX_PATH_CROGL_GENFILES)/errorspu.c \
608 error/errorspu_init.c
609VBoxOGLerrorspu_SOURCES.win.x86 = \
610 error/error.def \
611 error/errorspu.rc
612VBoxOGLerrorspu_CLEAN = \
613 $(VBOX_PATH_CROGL_GENFILES)/errorspu.c
614VBoxOGLerrorspu_LIBS = \
615 $(VBOX_LIB_OGL_CRUTIL)
616ifdef VBOX_WITH_CRHGSMI
617VBoxOGLerrorspu_DEFS.win += VBOX_WITH_CRHGSMI
618endif
619ifdef VBOX_WITH_WDDM
620VBoxOGLerrorspu_DEFS.win += VBOX_WITH_WDDM
621endif
622
623
624#
625# VBoxOGLerrorspu-x86 - x86 VBoxOGLerrorspu version built for amd64 build
626#
627VBoxOGLerrorspu-x86_TEMPLATE = VBOXCROGLR3GUESTDLL
628VBoxOGLerrorspu-x86_EXTENDS = VBoxOGLerrorspu
629VBoxOGLerrorspu-x86_BLD_TRG_ARCH = x86
630VBoxOGLerrorspu-x86_LIBS = \
631 $(VBOX_LIB_OGL_CRUTIL_X86)
632VBoxOGLerrorspu-x86_DEFS = $(VBoxOGLerrorspu_DEFS) VBOX_WDDM_WOW64
633
634#
635# VBoxOGLhosterrorspu
636#
637VBoxOGLhosterrorspu_EXTENDS = VBoxOGLerrorspu
638VBoxOGLhosterrorspu_TEMPLATE = VBOXCROGLR3HOSTDLL
639if defined(VBOX_SIGNING_MODE) && defined(VBOX_WITH_WDDM)
640 VBoxOGLhosterrorspu_INSTTYPE.win = both
641endif
642VBoxOGLhosterrorspu_LDFLAGS.darwin += $(VBoxOGLerrorspu_LDFLAGS.darwin) \
643 -install_name $(VBOX_DYLD_EXECUTABLE_PATH)/VBoxOGLhosterrorspu.dylib
644VBoxOGLhosterrorspu_LIBS = \
645 $(VBOX_LIB_OGL_HOSTCRUTIL) \
646 $(LIB_RUNTIME)
647
648#
649# Generate files for VBoxOGLerrorspu and VBoxOGLhosterrorspu.
650#
651$(VBOX_PATH_CROGL_GENFILES)/errorspu.c: $(PATH_SUB_CURRENT)/error/error.py $(VBOX_CROGL_API_FILES)
652 $(call MSG_GENERATE,python,$@,$<)
653 $(QUIET)$(call VBOX_CROGL_PYTHON_ENV,$(VBOX_PATH_CROGL_PYTHON_INCLUDE),$@) $(VBOX_BLD_PYTHON) $< $(VBOX_PATH_CROGL_GLAPI)
654include $(FILE_KBUILD_SUB_FOOTER)
655
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