Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(587)

Side by Side Diff: ui/gl/BUILD.gn

Issue 1354483004: Re-land: ui: Add GLImage unit test framework. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « gpu/command_buffer/service/in_process_command_buffer.cc ('k') | ui/gl/gl.gyp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright 2014 The Chromium Authors. All rights reserved. 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 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 import("//build/config/ui.gni") 5 import("//build/config/ui.gni")
6 import("//testing/test.gni") 6 import("//testing/test.gni")
7 7
8 if (is_android) { 8 if (is_android) {
9 import("//build/config/android/config.gni") 9 import("//build/config/android/config.gni")
10 import("//build/config/android/rules.gni") 10 import("//build/config/android/rules.gni")
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 } 150 }
151 if (is_android || is_linux) { 151 if (is_android || is_linux) {
152 sources += [ 152 sources += [
153 "gl_implementation_osmesa.cc", 153 "gl_implementation_osmesa.cc",
154 "gl_implementation_osmesa.h", 154 "gl_implementation_osmesa.h",
155 ] 155 ]
156 } 156 }
157 if (is_linux) { 157 if (is_linux) {
158 deps += [ "//third_party/libevent" ] 158 deps += [ "//third_party/libevent" ]
159 } 159 }
160 if (!is_android) { # TODO(GYP) Enable on Android when osmesa links.
161 deps += [ "//third_party/mesa:osmesa" ]
162 }
160 if (use_x11) { 163 if (use_x11) {
161 sources += [ 164 sources += [
162 "gl_bindings_autogen_glx.cc", 165 "gl_bindings_autogen_glx.cc",
163 "gl_bindings_autogen_glx.h", 166 "gl_bindings_autogen_glx.h",
164 "gl_context_glx.cc", 167 "gl_context_glx.cc",
165 "gl_context_glx.h", 168 "gl_context_glx.h",
166 "gl_context_x11.cc", 169 "gl_context_x11.cc",
167 "gl_egl_api_implementation.cc", 170 "gl_egl_api_implementation.cc",
168 "gl_egl_api_implementation.h", 171 "gl_egl_api_implementation.h",
169 "gl_glx_api_implementation.cc", 172 "gl_glx_api_implementation.cc",
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
278 281
279 configs += [ "//third_party/khronos:khronos_headers" ] 282 configs += [ "//third_party/khronos:khronos_headers" ]
280 283
281 deps = [ 284 deps = [
282 ":gl", 285 ":gl",
283 "//testing/gmock", 286 "//testing/gmock",
284 ] 287 ]
285 } 288 }
286 289
287 source_set("test_support") { 290 source_set("test_support") {
291 testonly = true
288 sources = [ 292 sources = [
293 "test/gl_image_test_support.cc",
294 "test/gl_image_test_support.h",
295 "test/gl_image_test_template.h",
289 "test/gl_surface_test_support.cc", 296 "test/gl_surface_test_support.cc",
290 "test/gl_surface_test_support.h", 297 "test/gl_surface_test_support.h",
298 "test/gl_test_helper.cc",
299 "test/gl_test_helper.h",
291 ] 300 ]
292 301
293 configs += [ "//third_party/khronos:khronos_headers" ] 302 configs += [ "//third_party/khronos:khronos_headers" ]
294 303
295 deps = [ 304 deps = [
305 "//testing/gtest",
296 ":gl", 306 ":gl",
297 ] 307 ]
298 308
299 if (use_x11) { 309 if (use_x11) {
300 configs += [ "//build/config/linux:x11" ] 310 configs += [ "//build/config/linux:x11" ]
301 deps += [ 311 deps += [
302 "//ui/gfx/x", 312 "//ui/gfx/x",
303 "//ui/platform_window/x11", 313 "//ui/platform_window/x11",
304 ] 314 ]
305 } 315 }
306 } 316 }
307 317
308 # TODO(GYP): Delete this after we've converted everything to GN. 318 # TODO(GYP): Delete this after we've converted everything to GN.
309 # The _run targets exist only for compatibility w/ GYP. 319 # The _run targets exist only for compatibility w/ GYP.
310 group("gl_unittests_run") { 320 group("gl_unittests_run") {
311 testonly = true 321 testonly = true
312 deps = [ 322 deps = [
313 ":gl_unittests", 323 ":gl_unittests",
314 ] 324 ]
315 } 325 }
316 326
317 test("gl_unittests") { 327 test("gl_unittests") {
318 sources = [ 328 sources = [
319 "gl_api_unittest.cc", 329 "gl_api_unittest.cc",
330 "gl_image_ref_counted_memory_unittest.cc",
331 "gl_image_shared_memory_unittest.cc",
320 "gpu_timing_unittest.cc", 332 "gpu_timing_unittest.cc",
321 "test/run_all_unittests.cc", 333 "test/run_all_unittests.cc",
322 ] 334 ]
323 335
324 if (is_win || is_android || is_linux) { 336 if (is_win || is_android || is_linux) {
325 sources += [ 337 sources += [
326 "egl_api_unittest.cc", 338 "egl_api_unittest.cc",
327 "test/egl_initialization_displays_unittest.cc", 339 "test/egl_initialization_displays_unittest.cc",
328 ] 340 ]
329 } 341 }
330 342
331 if (use_x11) { 343 if (use_x11) {
332 sources += [ "glx_api_unittest.cc" ] 344 sources += [ "glx_api_unittest.cc" ]
333 } 345 }
334 346
335 include_dirs = [ "//third_party/khronos" ] 347 include_dirs = [ "//third_party/khronos" ]
336 348
337 deps = [ 349 deps = [
338 ":gl", 350 ":gl",
339 ":gl_unittest_utils", 351 ":gl_unittest_utils",
340 ":test_support", 352 ":test_support",
341 "//base", 353 "//base",
342 "//base/test:test_support", 354 "//base/test:test_support",
355 "//skia",
343 "//testing/gmock", 356 "//testing/gmock",
344 "//testing/gtest", 357 "//testing/gtest",
358 "//ui/gfx",
359 ]
360
361 data_deps = [
362 "//third_party/mesa:osmesa",
345 ] 363 ]
346 } 364 }
347 365
348 if (is_android) { 366 if (is_android) {
349 generate_jar_jni("surface_jni_headers") { 367 generate_jar_jni("surface_jni_headers") {
350 jni_package = "ui/gl" 368 jni_package = "ui/gl"
351 classes = [ "android/view/Surface.class" ] 369 classes = [ "android/view/Surface.class" ]
352 } 370 }
353 371
354 generate_jni("gl_jni_headers") { 372 generate_jni("gl_jni_headers") {
355 sources = [ 373 sources = [
356 "../android/java/src/org/chromium/ui/gl/SurfaceTextureListener.java", 374 "../android/java/src/org/chromium/ui/gl/SurfaceTextureListener.java",
357 "../android/java/src/org/chromium/ui/gl/SurfaceTexturePlatformWrapper.java ", 375 "../android/java/src/org/chromium/ui/gl/SurfaceTexturePlatformWrapper.java ",
358 ] 376 ]
359 public_deps = [ 377 public_deps = [
360 ":surface_jni_headers", 378 ":surface_jni_headers",
361 ] 379 ]
362 jni_package = "ui/gl" 380 jni_package = "ui/gl"
363 } 381 }
364 } 382 }
OLDNEW
« no previous file with comments | « gpu/command_buffer/service/in_process_command_buffer.cc ('k') | ui/gl/gl.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698