Remove invocation of WebSettings::setFontRenderingNormal, which is a no-op.
[chromium-blink-merge.git] / gpu / gpu.gyp
blob35e771e4009a392137773c3aaad7ea8b18144ba8
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
6   'variables': {
7     'nacl_win64_target': 0,
8   },
9   'includes': [
10     'gpu_common.gypi',
11   ],
12   'targets': [
13     {
14       # Library emulates GLES2 using command_buffers.
15       'target_name': 'gles2_implementation',
16       'type': '<(component)',
17       'dependencies': [
18         '../base/base.gyp:base',
19         '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
20         '../third_party/khronos/khronos.gyp:khronos_headers',
21         '../ui/gl/gl.gyp:gl',
22         '../ui/ui.gyp:ui',
23         'command_buffer/command_buffer.gyp:gles2_utils',
24         'gles2_cmd_helper',
25       ],
26       'defines': [
27         'GLES2_IMPL_IMPLEMENTATION',
28       ],
29       'sources': [
30         '<@(gles2_implementation_source_files)',
31         'command_buffer/client/gl_in_process_context.h',
32         'command_buffer/client/gl_in_process_context.cc',
33       ],
34       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
35       'msvs_disabled_warnings': [4267, ],
36     },
37     {
38       # Library emulates GLES2 using command_buffers.
39       'target_name': 'gles2_implementation_client_side_arrays',
40       'type': '<(component)',
41       'defines': [
42         'GLES2_IMPL_IMPLEMENTATION',
43         'GLES2_SUPPORT_CLIENT_SIDE_ARRAYS=1',
44       ],
45       'dependencies': [
46         '../base/base.gyp:base',
47         '../third_party/khronos/khronos.gyp:khronos_headers',
48         '../ui/gl/gl.gyp:gl',
49         'command_buffer/command_buffer.gyp:gles2_utils',
50         'gles2_cmd_helper',
51       ],
52       'sources': [
53         '<@(gles2_implementation_source_files)',
54       ],
55       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
56       'msvs_disabled_warnings': [ 4267, ],
57     },
58     {
59       # Library emulates GLES2 using command_buffers.
60       'target_name': 'gles2_implementation_client_side_arrays_no_check',
61       'type': '<(component)',
62       'defines': [
63         'GLES2_IMPL_IMPLEMENTATION',
64         'GLES2_SUPPORT_CLIENT_SIDE_ARRAYS=1',
65         'GLES2_CONFORMANCE_TESTS=1',
66       ],
67       'dependencies': [
68         '../base/base.gyp:base',
69         '../third_party/khronos/khronos.gyp:khronos_headers',
70         'command_buffer/command_buffer.gyp:gles2_utils',
71         'gles2_cmd_helper',
72       ],
73       'sources': [
74         '<@(gles2_implementation_source_files)',
75       ],
76       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
77       'msvs_disabled_warnings': [ 4267, ],
78     },
79     {
80       # Stub to expose gles2_implemenation in C instead of C++.
81       # so GLES2 C programs can work with no changes.
82       'target_name': 'gles2_c_lib',
83       'type': '<(component)',
84       'dependencies': [
85         '../base/base.gyp:base',
86         '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
87         'command_buffer/command_buffer.gyp:gles2_utils',
88         'command_buffer_client',
89         'gles2_implementation',
90       ],
91       'defines': [
92         'GLES2_C_LIB_IMPLEMENTATION',
93       ],
94       'sources': [
95         '<@(gles2_c_lib_source_files)',
96       ],
97       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
98       'msvs_disabled_warnings': [4267, ],
99     },
100     {
101       # Same as gles2_c_lib except with no parameter checking. Required for
102       # OpenGL ES 2.0 conformance tests.
103       'target_name': 'gles2_c_lib_nocheck',
104       'type': '<(component)',
105       'defines': [
106         'GLES2_C_LIB_IMPLEMENTATION',
107         'GLES2_CONFORMANCE_TESTS=1',
108       ],
109       'dependencies': [
110         '../base/base.gyp:base',
111         '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
112         'command_buffer/command_buffer.gyp:gles2_utils',
113         'command_buffer_client',
114         'gles2_implementation_client_side_arrays_no_check',
115       ],
116       'sources': [
117         '<@(gles2_c_lib_source_files)',
118       ],
119     },
120     {
121       'target_name': 'gpu_unittests',
122       'type': '<(gtest_target_type)',
123       'dependencies': [
124         '../base/base.gyp:base',
125         '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
126         '../testing/gmock.gyp:gmock',
127         '../testing/gtest.gyp:gtest',
128         '<(angle_path)/src/build_angle.gyp:translator_glsl',
129         '../ui/gl/gl.gyp:gl',
130         '../ui/ui.gyp:ui',
131         'command_buffer/command_buffer.gyp:gles2_utils',
132         'command_buffer_client',
133         'command_buffer_common',
134         'command_buffer_service',
135         'gpu',
136         'gpu_unittest_utils',
137         'gles2_implementation_client_side_arrays',
138         'gles2_cmd_helper',
139       ],
140       'defines': [
141         'GLES2_C_LIB_IMPLEMENTATION',
142       ],
143       'sources': [
144         '<@(gles2_c_lib_source_files)',
145         'command_buffer/client/buffer_tracker_unittest.cc',
146         'command_buffer/client/client_test_helper.cc',
147         'command_buffer/client/client_test_helper.h',
148         'command_buffer/client/cmd_buffer_helper_test.cc',
149         'command_buffer/client/fenced_allocator_test.cc',
150         'command_buffer/client/gles2_interface_stub.cc',
151         'command_buffer/client/gles2_interface_stub.h',
152         'command_buffer/client/gles2_implementation_unittest.cc',
153         'command_buffer/client/mapped_memory_unittest.cc',
154         'command_buffer/client/query_tracker_unittest.cc',
155         'command_buffer/client/program_info_manager_unittest.cc',
156         'command_buffer/client/ring_buffer_test.cc',
157         'command_buffer/client/transfer_buffer_unittest.cc',
158         'command_buffer/client/vertex_array_object_manager_unittest.cc',
159         'command_buffer/common/bitfield_helpers_test.cc',
160         'command_buffer/common/command_buffer_mock.cc',
161         'command_buffer/common/command_buffer_mock.h',
162         'command_buffer/common/command_buffer_shared_test.cc',
163         'command_buffer/common/debug_marker_manager_unittest.cc',
164         'command_buffer/common/gles2_cmd_format_test.cc',
165         'command_buffer/common/gles2_cmd_format_test_autogen.h',
166         'command_buffer/common/gles2_cmd_utils_unittest.cc',
167         'command_buffer/common/id_allocator_test.cc',
168         'command_buffer/common/trace_event.h',
169         'command_buffer/common/unittest_main.cc',
170         'command_buffer/service/async_pixel_transfer_delegate_mock.h',
171         'command_buffer/service/async_pixel_transfer_delegate_mock.cc',
172         'command_buffer/service/async_pixel_transfer_manager_mock.h',
173         'command_buffer/service/async_pixel_transfer_manager_mock.cc',
174         'command_buffer/service/buffer_manager_unittest.cc',
175         'command_buffer/service/cmd_parser_test.cc',
176         'command_buffer/service/command_buffer_service_unittest.cc',
177         'command_buffer/service/common_decoder_unittest.cc',
178         'command_buffer/service/context_group_unittest.cc',
179         'command_buffer/service/feature_info_unittest.cc',
180         'command_buffer/service/framebuffer_manager_unittest.cc',
181         'command_buffer/service/gles2_cmd_decoder_unittest.cc',
182         'command_buffer/service/gles2_cmd_decoder_unittest_0_autogen.h',
183         'command_buffer/service/gles2_cmd_decoder_unittest_1.cc',
184         'command_buffer/service/gles2_cmd_decoder_unittest_1_autogen.h',
185         'command_buffer/service/gles2_cmd_decoder_unittest_2.cc',
186         'command_buffer/service/gles2_cmd_decoder_unittest_2_autogen.h',
187         'command_buffer/service/gles2_cmd_decoder_unittest_3.cc',
188         'command_buffer/service/gles2_cmd_decoder_unittest_3_autogen.h',
189         'command_buffer/service/gles2_cmd_decoder_unittest_base.cc',
190         'command_buffer/service/gles2_cmd_decoder_unittest_base.h',
191         'command_buffer/service/gl_surface_mock.cc',
192         'command_buffer/service/gl_surface_mock.h',
193         'command_buffer/service/gpu_scheduler_unittest.cc',
194         'command_buffer/service/id_manager_unittest.cc',
195         'command_buffer/service/mailbox_manager_unittest.cc',
196         'command_buffer/service/memory_program_cache_unittest.cc',
197         'command_buffer/service/mocks.cc',
198         'command_buffer/service/mocks.h',
199         'command_buffer/service/program_manager_unittest.cc',
200         'command_buffer/service/query_manager_unittest.cc',
201         'command_buffer/service/renderbuffer_manager_unittest.cc',
202         'command_buffer/service/program_cache_lru_helper_unittest.cc',
203         'command_buffer/service/program_cache_unittest.cc',
204         'command_buffer/service/shader_manager_unittest.cc',
205         'command_buffer/service/shader_translator_unittest.cc',
206         'command_buffer/service/stream_texture_mock.cc',
207         'command_buffer/service/stream_texture_mock.h',
208         'command_buffer/service/stream_texture_manager_mock.cc',
209         'command_buffer/service/stream_texture_manager_mock.h',
210         'command_buffer/service/test_helper.cc',
211         'command_buffer/service/test_helper.h',
212         'command_buffer/service/texture_manager_unittest.cc',
213         'command_buffer/service/transfer_buffer_manager_unittest.cc',
214         'command_buffer/service/vertex_attrib_manager_unittest.cc',
215         'command_buffer/service/vertex_array_manager_unittest.cc',
216         'config/gpu_blacklist_unittest.cc',
217         'config/gpu_control_list_entry_unittest.cc',
218         'config/gpu_control_list_machine_model_info_unittest.cc',
219         'config/gpu_control_list_number_info_unittest.cc',
220         'config/gpu_control_list_os_info_unittest.cc',
221         'config/gpu_control_list_string_info_unittest.cc',
222         'config/gpu_control_list_unittest.cc',
223         'config/gpu_control_list_version_info_unittest.cc',
224         'config/gpu_driver_bug_list_unittest.cc',
225         'config/gpu_info_collector_unittest.cc',
226         'config/gpu_info_unittest.cc',
227         'config/gpu_switching_list_unittest.cc',
228         'config/gpu_test_config_unittest.cc',
229         'config/gpu_test_expectations_parser_unittest.cc',
230         'config/gpu_util_unittest.cc',
231       ],
232       'conditions': [
233         ['OS == "android" and gtest_target_type == "shared_library"', {
234           'dependencies': [
235             '../testing/android/native_test.gyp:native_test_native_code',
236           ],
237         }],
238         # See http://crbug.com/162998#c4 for why this is needed.
239         ['OS=="linux" and linux_use_tcmalloc==1', {
240           'dependencies': [
241             '../base/allocator/allocator.gyp:allocator',
242           ],
243         }],
244       ],
245       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
246       'msvs_disabled_warnings': [ 4267, ],
247     },
248     {
249       'target_name': 'gl_tests',
250       'type': '<(gtest_target_type)',
251       'dependencies': [
252         '../base/base.gyp:base',
253         '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
254         '../testing/gmock.gyp:gmock',
255         '../testing/gtest.gyp:gtest',
256         '<(angle_path)/src/build_angle.gyp:translator_glsl',
257         '../ui/ui.gyp:ui',
258         'command_buffer/command_buffer.gyp:gles2_utils',
259         'command_buffer_client',
260         'command_buffer_common',
261         'command_buffer_service',
262         'gpu',
263         'gpu_unittest_utils',
264         'gles2_implementation_client_side_arrays',
265         'gles2_cmd_helper',
266         #'gl_unittests',
267       ],
268       'defines': [
269         'GLES2_C_LIB_IMPLEMENTATION',
270         'GL_GLEXT_PROTOTYPES',
271       ],
272       'sources': [
273         '<@(gles2_c_lib_source_files)',
274         'command_buffer/client/gpu_memory_buffer_mock.cc',
275         'command_buffer/client/gpu_memory_buffer_mock.h',
276         'command_buffer/client/image_factory_mock.cc',
277         'command_buffer/client/image_factory_mock.h',
278         'command_buffer/tests/gl_bind_uniform_location_unittest.cc',
279         'command_buffer/tests/gl_chromium_framebuffer_multisample_unittest.cc',
280         'command_buffer/tests/gl_copy_texture_CHROMIUM_unittest.cc',
281         'command_buffer/tests/gl_depth_texture_unittest.cc',
282         'command_buffer/tests/gl_gpu_memory_buffer_unittests.cc',
283         'command_buffer/tests/gl_lose_context_chromium_unittests.cc',
284         'command_buffer/tests/gl_manager.cc',
285         'command_buffer/tests/gl_manager.h',
286         'command_buffer/tests/gl_pointcoord_unittest.cc',
287         'command_buffer/tests/gl_program_unittests.cc',
288         'command_buffer/tests/gl_query_unittests.cc',
289         'command_buffer/tests/gl_readback_unittests.cc',
290         'command_buffer/tests/gl_shared_resources_unittests.cc',
291         'command_buffer/tests/gl_stream_draw_unittests.cc',
292         'command_buffer/tests/gl_test_utils.cc',
293         'command_buffer/tests/gl_test_utils.h',
294         'command_buffer/tests/gl_tests_main.cc',
295         'command_buffer/tests/gl_texture_mailbox_unittests.cc',
296         'command_buffer/tests/gl_texture_storage_unittests.cc',
297         'command_buffer/tests/gl_unittests.cc',
298         'command_buffer/tests/gl_unittests_android.cc',
299         'command_buffer/tests/gl_virtual_contexts_unittests.cc',
300         'command_buffer/tests/occlusion_query_unittests.cc',
301       ],
302       'conditions': [
303         ['OS == "android" and gtest_target_type == "shared_library"', {
304           'dependencies': [
305             '../testing/android/native_test.gyp:native_test_native_code',
306           ],
307         }],
308       ],
309       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
310       'msvs_disabled_warnings': [ 4267, ],
311     },
312     {
313       'target_name': 'gpu_unittest_utils',
314       'type': 'static_library',
315       'dependencies': [
316         '../testing/gmock.gyp:gmock',
317         '../testing/gtest.gyp:gtest',
318         '../third_party/khronos/khronos.gyp:khronos_headers',
319         '../ui/gl/gl.gyp:gl_unittest_utils',
320         'gpu',
321       ],
322       'include_dirs': [
323         '..',
324       ],
325       'sources': [
326         'command_buffer/service/gles2_cmd_decoder_mock.cc',
327         'command_buffer/service/error_state_mock.cc',
328       ],
329     },
330   ],
331   'conditions': [
332     ['component=="static_library"', {
333       'targets': [
334          {
335           'target_name': 'disk_cache_proto',
336           'type': 'static_library',
337           'sources': [ 'command_buffer/service/disk_cache_proto.proto' ],
338           'variables': {
339             'proto_in_dir': 'command_buffer/service',
340             'proto_out_dir': 'gpu/command_buffer/service',
341           },
342           'includes': [ '../build/protoc.gypi' ],
343         },
344         {
345           'target_name': 'gpu',
346           'type': 'none',
347           'dependencies': [
348             'command_buffer_client',
349             'command_buffer_common',
350             'command_buffer_service',
351             'gles2_cmd_helper',
352             'gpu_config',
353             'gpu_ipc',
354           ],
355           'sources': [
356             'gpu_export.h',
357           ],
358           # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
359           'msvs_disabled_warnings': [4267, ],
360         },
361         {
362           'target_name': 'command_buffer_common',
363           'type': 'static_library',
364           'includes': [
365             'command_buffer_common.gypi',
366           ],
367           'dependencies': [
368             '../base/base.gyp:base',
369             'command_buffer/command_buffer.gyp:gles2_utils',
370           ],
371           'export_dependent_settings': [
372             '../base/base.gyp:base',
373           ],
374         },
375         {
376           # Library helps make GLES2 command buffers.
377           'target_name': 'gles2_cmd_helper',
378           'type': 'static_library',
379           'includes': [
380             'gles2_cmd_helper.gypi',
381           ],
382           'dependencies': [
383             'command_buffer_client',
384           ],
385           # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
386           'msvs_disabled_warnings': [4267, ],
387         },
388         {
389           'target_name': 'command_buffer_client',
390           'type': 'static_library',
391           'includes': [
392             'command_buffer_client.gypi',
393           ],
394           'dependencies': [
395             'command_buffer_common',
396           ],
397           # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
398           'msvs_disabled_warnings': [4267, ],
399         },
400         {
401           'target_name': 'command_buffer_service',
402           'type': 'static_library',
403           'includes': [
404             'command_buffer_service.gypi',
405           ],
406           'dependencies': [
407             'command_buffer_common',
408             'disk_cache_proto',
409           ],
410           # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
411           'msvs_disabled_warnings': [4267, ],
412         },
413         {
414           'target_name': 'gpu_ipc',
415           'type': 'static_library',
416           'includes': [
417             'gpu_ipc.gypi',
418           ],
419           'dependencies': [
420             'command_buffer_common',
421           ],
422         },
423         {
424           'target_name': 'gpu_config',
425           'type': 'static_library',
426           'includes': [
427             'gpu_config.gypi',
428           ],
429         },
430       ],
431     },
432     { # component != static_library
433       'targets': [
434          {
435           'target_name': 'disk_cache_proto',
436           'type': 'static_library',
437           'sources': [ 'command_buffer/service/disk_cache_proto.proto' ],
438           'variables': {
439             'proto_in_dir': 'command_buffer/service',
440             'proto_out_dir': 'gpu/command_buffer/service',
441           },
442           'includes': [ '../build/protoc.gypi' ],
443         },
444         {
445           'target_name': 'gpu',
446           'type': 'shared_library',
447           'includes': [
448             'command_buffer_client.gypi',
449             'command_buffer_common.gypi',
450             'command_buffer_service.gypi',
451             'gles2_cmd_helper.gypi',
452             'gpu_config.gypi',
453             'gpu_ipc.gypi',
454           ],
455           'defines': [
456             'GPU_IMPLEMENTATION',
457           ],
458           'sources': [
459             'gpu_export.h',
460           ],
461           'dependencies': [
462             '../base/base.gyp:base',
463             'command_buffer/command_buffer.gyp:gles2_utils',
464             'disk_cache_proto',
465           ],
466           # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
467           'msvs_disabled_warnings': [4267, ],
468         },
469         {
470           'target_name': 'command_buffer_common',
471           'type': 'none',
472           'dependencies': [
473             'gpu',
474           ],
475         },
476         {
477           # Library helps make GLES2 command buffers.
478           'target_name': 'gles2_cmd_helper',
479           'type': 'none',
480           'dependencies': [
481             'gpu',
482           ],
483           # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
484           'msvs_disabled_warnings': [4267, ],
485         },
486         {
487           'target_name': 'command_buffer_client',
488           'type': 'none',
489           'dependencies': [
490             'gpu',
491           ],
492         },
493         {
494           'target_name': 'command_buffer_service',
495           'type': 'none',
496           'dependencies': [
497             'gpu',
498           ],
499         },
500         {
501           'target_name': 'gpu_ipc',
502           'type': 'none',
503           'dependencies': [
504             'gpu',
505           ],
506         },
507       ],
508     }],
509     ['disable_nacl!=1 and OS=="win" and target_arch=="ia32"', {
510       'targets': [
511         {
512           'target_name': 'gpu_ipc_win64',
513           'type': 'static_library',
514           'variables': {
515             'nacl_win64_target': 1,
516           },
517           'includes': [
518             'gpu_ipc.gypi',
519           ],
520           'dependencies': [
521             '../base/base.gyp:base_nacl_win64',
522             '../ipc/ipc.gyp:ipc_win64',
523           ],
524           'defines': [
525             '<@(nacl_win64_defines)',
526             'GPU_IMPLEMENTATION',
527           ],
528           'configurations': {
529             'Common_Base': {
530               'msvs_target_platform': 'x64',
531             },
532           },
533         },
534       ],
535     }],
536     ['OS == "android" and gtest_target_type == "shared_library"', {
537       'targets': [
538         {
539           'target_name': 'gl_tests_apk',
540           'type': 'none',
541           'dependencies': [
542             'gl_tests',
543           ],
544           'variables': {
545             'test_suite_name': 'gl_tests',
546             'input_shlib_path': '<(SHARED_LIB_DIR)/<(SHARED_LIB_PREFIX)gl_tests<(SHARED_LIB_SUFFIX)',
547           },
548           'includes': [
549             '../build/apk_test.gypi',
550           ],
551         },
552       ],
553     }],
554   ],