[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 1 | # Copyright 2014 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. |
| 4 | |
| 5 | import("//build/config/ui.gni") |
| 6 | import("//third_party/protobuf/proto_library.gni") |
| 7 | |
brettw | 542f753 | 2015-04-06 22:35:45 | [diff] [blame] | 8 | group("service") { |
| 9 | if (is_component_build) { |
| 10 | public_deps = [ |
| 11 | "//gpu", |
| 12 | ] |
| 13 | } else { |
| 14 | public_deps = [ |
| 15 | ":service_sources", |
| 16 | ] |
| 17 | } |
| 18 | } |
| 19 | |
brucedawson | 6e53a2e1 | 2016-07-23 19:35:47 | [diff] [blame] | 20 | if (is_component_build) { |
| 21 | link_target_type = "source_set" |
| 22 | } else { |
| 23 | link_target_type = "static_library" |
| 24 | } |
| 25 | target(link_target_type, "service_sources") { |
brettw | b78fc9e | 2016-03-25 21:02:51 | [diff] [blame] | 26 | # External code should depend on this via //gpu/command_buffer/service above |
| 27 | # rather than depending on this directly or the component build will break. |
| 28 | visibility = [ "//gpu/*" ] |
brettw | 542f753 | 2015-04-06 22:35:45 | [diff] [blame] | 29 | |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 30 | sources = [ |
Antoine Labour | e0990c1c | 2017-05-17 21:05:56 | [diff] [blame] | 31 | "async_api_interface.cc", |
| 32 | "async_api_interface.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 33 | "buffer_manager.cc", |
satorux | c5bd7a3 | 2015-02-18 01:54:52 | [diff] [blame] | 34 | "buffer_manager.h", |
geofflang | 851a481 | 2016-09-14 19:20:29 | [diff] [blame] | 35 | "client_service_map.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 36 | "cmd_buffer_engine.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 37 | "command_buffer_service.cc", |
| 38 | "command_buffer_service.h", |
sunnyps | d6bb1c0 | 2016-03-12 04:48:31 | [diff] [blame] | 39 | "command_executor.cc", |
| 40 | "command_executor.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 41 | "common_decoder.cc", |
| 42 | "common_decoder.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 43 | "context_group.cc", |
satorux | c5bd7a3 | 2015-02-18 01:54:52 | [diff] [blame] | 44 | "context_group.h", |
| 45 | "context_state.cc", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 46 | "context_state.h", |
| 47 | "context_state_autogen.h", |
| 48 | "context_state_impl_autogen.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 49 | "error_state.cc", |
| 50 | "error_state.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 51 | "feature_info.cc", |
satorux | c5bd7a3 | 2015-02-18 01:54:52 | [diff] [blame] | 52 | "feature_info.h", |
tobiasjs | fc199b47 | 2015-08-22 00:39:06 | [diff] [blame] | 53 | "framebuffer_completeness_cache.cc", |
| 54 | "framebuffer_completeness_cache.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 55 | "framebuffer_manager.cc", |
satorux | c5bd7a3 | 2015-02-18 01:54:52 | [diff] [blame] | 56 | "framebuffer_manager.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 57 | "gl_context_virtual.cc", |
| 58 | "gl_context_virtual.h", |
| 59 | "gl_state_restorer_impl.cc", |
| 60 | "gl_state_restorer_impl.h", |
junov | 0cad1f4 | 2016-01-07 21:48:51 | [diff] [blame] | 61 | "gl_utils.cc", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 62 | "gl_utils.h", |
adrian.belgun | 8a992f1 | 2016-06-17 16:29:05 | [diff] [blame] | 63 | "gles2_cmd_apply_framebuffer_attachment_cmaa_intel.cc", |
| 64 | "gles2_cmd_apply_framebuffer_attachment_cmaa_intel.h", |
satorux | c5bd7a3 | 2015-02-18 01:54:52 | [diff] [blame] | 65 | "gles2_cmd_clear_framebuffer.cc", |
| 66 | "gles2_cmd_clear_framebuffer.h", |
geofflang | b205ab6 | 2016-06-13 21:24:44 | [diff] [blame] | 67 | "gles2_cmd_copy_tex_image.cc", |
| 68 | "gles2_cmd_copy_tex_image.h", |
satorux | c5bd7a3 | 2015-02-18 01:54:52 | [diff] [blame] | 69 | "gles2_cmd_copy_texture_chromium.cc", |
| 70 | "gles2_cmd_copy_texture_chromium.h", |
| 71 | "gles2_cmd_decoder.cc", |
| 72 | "gles2_cmd_decoder.h", |
| 73 | "gles2_cmd_decoder_autogen.h", |
geofflang | 6aa8dd2 | 2016-05-24 21:35:33 | [diff] [blame] | 74 | "gles2_cmd_decoder_passthrough.cc", |
| 75 | "gles2_cmd_decoder_passthrough.h", |
geofflang | d00f0b2 | 2016-06-03 16:34:29 | [diff] [blame] | 76 | "gles2_cmd_decoder_passthrough_doer_prototypes.h", |
| 77 | "gles2_cmd_decoder_passthrough_doers.cc", |
| 78 | "gles2_cmd_decoder_passthrough_handlers.cc", |
| 79 | "gles2_cmd_decoder_passthrough_handlers_autogen.cc", |
yunchao.he | fd79169 | 2016-09-18 07:27:05 | [diff] [blame] | 80 | "gles2_cmd_srgb_converter.cc", |
| 81 | "gles2_cmd_srgb_converter.h", |
satorux | c5bd7a3 | 2015-02-18 01:54:52 | [diff] [blame] | 82 | "gles2_cmd_validation.cc", |
| 83 | "gles2_cmd_validation.h", |
| 84 | "gles2_cmd_validation_autogen.h", |
| 85 | "gles2_cmd_validation_implementation_autogen.h", |
penghuang | 7404df988 | 2016-02-29 23:07:29 | [diff] [blame] | 86 | "gpu_preferences.cc", |
| 87 | "gpu_preferences.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 88 | "gpu_state_tracer.cc", |
| 89 | "gpu_state_tracer.h", |
| 90 | "gpu_switches.cc", |
| 91 | "gpu_switches.h", |
satorux | c5bd7a3 | 2015-02-18 01:54:52 | [diff] [blame] | 92 | "gpu_tracer.cc", |
| 93 | "gpu_tracer.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 94 | "id_manager.cc", |
satorux | c5bd7a3 | 2015-02-18 01:54:52 | [diff] [blame] | 95 | "id_manager.h", |
reveman | eeba91b | 2014-10-28 22:49:20 | [diff] [blame] | 96 | "image_factory.cc", |
| 97 | "image_factory.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 98 | "image_manager.cc", |
| 99 | "image_manager.h", |
zmo | 6c468ba | 2016-05-04 20:00:51 | [diff] [blame] | 100 | "indexed_buffer_binding_host.cc", |
| 101 | "indexed_buffer_binding_host.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 102 | "logger.cc", |
| 103 | "logger.h", |
boliu | 8e814cb | 2015-07-13 20:47:46 | [diff] [blame] | 104 | "mailbox_manager.cc", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 105 | "mailbox_manager.h", |
sievers | b727d53 | 2014-10-24 19:11:34 | [diff] [blame] | 106 | "mailbox_manager_impl.cc", |
| 107 | "mailbox_manager_impl.h", |
| 108 | "mailbox_manager_sync.cc", |
| 109 | "mailbox_manager_sync.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 110 | "memory_program_cache.cc", |
satorux | c5bd7a3 | 2015-02-18 01:54:52 | [diff] [blame] | 111 | "memory_program_cache.h", |
kkinnunen | b959a846 | 2015-07-14 11:08:34 | [diff] [blame] | 112 | "path_manager.cc", |
| 113 | "path_manager.h", |
sunnyps | 0559d3c | 2017-03-29 19:08:17 | [diff] [blame] | 114 | "preemption_flag.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 115 | "program_cache.cc", |
satorux | c5bd7a3 | 2015-02-18 01:54:52 | [diff] [blame] | 116 | "program_cache.h", |
| 117 | "program_manager.cc", |
| 118 | "program_manager.h", |
| 119 | "query_manager.cc", |
| 120 | "query_manager.h", |
| 121 | "renderbuffer_manager.cc", |
| 122 | "renderbuffer_manager.h", |
bajones | 5141d03 | 2015-12-07 21:13:39 | [diff] [blame] | 123 | "sampler_manager.cc", |
| 124 | "sampler_manager.h", |
sunnyps | 8f9139e | 2017-05-12 17:53:25 | [diff] [blame] | 125 | "scheduler.cc", |
| 126 | "scheduler.h", |
sunnyps | c8cc93e27 | 2017-03-21 20:52:27 | [diff] [blame] | 127 | "sequence_id.h", |
ericrk | dc5eeaa | 2017-05-19 02:23:50 | [diff] [blame^] | 128 | "service_discardable_manager.cc", |
| 129 | "service_discardable_manager.h", |
geofflang | df7fff2d4 | 2016-11-11 00:34:03 | [diff] [blame] | 130 | "service_utils.cc", |
| 131 | "service_utils.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 132 | "shader_manager.cc", |
satorux | c5bd7a3 | 2015-02-18 01:54:52 | [diff] [blame] | 133 | "shader_manager.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 134 | "shader_translator.cc", |
satorux | c5bd7a3 | 2015-02-18 01:54:52 | [diff] [blame] | 135 | "shader_translator.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 136 | "shader_translator_cache.cc", |
satorux | c5bd7a3 | 2015-02-18 01:54:52 | [diff] [blame] | 137 | "shader_translator_cache.h", |
abarth | 3f181202 | 2014-11-18 23:33:07 | [diff] [blame] | 138 | "sync_point_manager.cc", |
satorux | c5bd7a3 | 2015-02-18 01:54:52 | [diff] [blame] | 139 | "sync_point_manager.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 140 | "texture_definition.cc", |
satorux | c5bd7a3 | 2015-02-18 01:54:52 | [diff] [blame] | 141 | "texture_definition.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 142 | "texture_manager.cc", |
satorux | c5bd7a3 | 2015-02-18 01:54:52 | [diff] [blame] | 143 | "texture_manager.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 144 | "transfer_buffer_manager.cc", |
| 145 | "transfer_buffer_manager.h", |
zmo | 6c468ba | 2016-05-04 20:00:51 | [diff] [blame] | 146 | "transform_feedback_manager.cc", |
| 147 | "transform_feedback_manager.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 148 | "vertex_array_manager.cc", |
satorux | c5bd7a3 | 2015-02-18 01:54:52 | [diff] [blame] | 149 | "vertex_array_manager.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 150 | "vertex_attrib_manager.cc", |
satorux | c5bd7a3 | 2015-02-18 01:54:52 | [diff] [blame] | 151 | "vertex_attrib_manager.h", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 152 | ] |
| 153 | |
brettw | 8f2fd17 | 2015-03-16 22:14:18 | [diff] [blame] | 154 | configs += [ |
brettw | bc8b2a2 | 2015-07-28 18:24:42 | [diff] [blame] | 155 | "//build/config:precompiled_headers", |
brettw | 8f2fd17 | 2015-03-16 22:14:18 | [diff] [blame] | 156 | "//gpu:gpu_implementation", |
| 157 | "//third_party/khronos:khronos_headers", |
| 158 | ] |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 159 | |
ckocagil | fc8d7f23 | 2014-09-30 19:31:43 | [diff] [blame] | 160 | # Prefer mesa GL headers to system headers, which cause problems on Win. |
| 161 | include_dirs = [ "//third_party/mesa/src/include" ] |
| 162 | |
brettw | 7dab582e | 2014-09-20 01:44:11 | [diff] [blame] | 163 | public_deps = [ |
brettw | 542f753 | 2015-04-06 22:35:45 | [diff] [blame] | 164 | "//gpu/command_buffer/common:common_sources", |
brettw | 7dab582e | 2014-09-20 01:44:11 | [diff] [blame] | 165 | ] |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 166 | deps = [ |
| 167 | ":disk_cache_proto", |
| 168 | "//base", |
| 169 | "//base/third_party/dynamic_annotations", |
| 170 | "//crypto", |
brettw | 09039c1 | 2016-03-18 03:22:46 | [diff] [blame] | 171 | "//gpu/command_buffer/client:client_sources", |
| 172 | "//gpu/command_buffer/common:gles2_utils", |
tfarina | 15525c4 | 2015-04-28 19:04:16 | [diff] [blame] | 173 | "//gpu/config:config_sources", |
sadrul | 763bd59 | 2016-09-27 14:33:44 | [diff] [blame] | 174 | "//gpu/ipc/common:surface_handle_type", |
Brett Wilson | 0748bf41 | 2016-11-22 17:55:46 | [diff] [blame] | 175 | "//media:media_features", |
geofflang | 398fb21 | 2016-07-13 16:27:42 | [diff] [blame] | 176 | "//third_party/angle:angle_image_util", |
jmadill | dc26192a | 2015-08-04 12:44:16 | [diff] [blame] | 177 | "//third_party/angle:commit_id", |
[email protected] | d5ba08c | 2014-06-18 07:01:08 | [diff] [blame] | 178 | "//third_party/angle:translator", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 179 | "//third_party/protobuf:protobuf_lite", |
| 180 | "//third_party/re2", |
| 181 | "//third_party/smhasher:cityhash", |
| 182 | "//ui/gfx", |
| 183 | "//ui/gfx/geometry", |
| 184 | "//ui/gl", |
kylechar | 5b9dec1 | 2016-05-16 15:40:57 | [diff] [blame] | 185 | "//ui/gl/init", |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 186 | ] |
| 187 | |
jiangj | 2bd42fd | 2015-04-18 13:29:06 | [diff] [blame] | 188 | if (is_mac) { |
| 189 | # Required by gles2_cmd_decoder.cc on Mac. |
| 190 | libs = [ |
| 191 | "IOSurface.framework", |
| 192 | "OpenGL.framework", |
| 193 | ] |
| 194 | } |
| 195 | |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 196 | if (is_android && !is_debug) { |
| 197 | # On Android optimize more since this component can be a bottleneck. |
brettw | 4cab0f1 | 2015-09-14 21:40:01 | [diff] [blame] | 198 | configs -= [ "//build/config/compiler:default_optimization" ] |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 199 | configs += [ "//build/config/compiler:optimize_max" ] |
| 200 | } |
| 201 | } |
| 202 | |
| 203 | proto_library("disk_cache_proto") { |
scottmg | 34fb7e5 | 2014-12-03 23:27:24 | [diff] [blame] | 204 | sources = [ |
| 205 | "disk_cache_proto.proto", |
| 206 | ] |
[email protected] | c1372a6 | 2014-05-21 19:42:31 | [diff] [blame] | 207 | } |