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

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

Issue 2060753004: gl: Build drm dependent test only when target_os == "chromeos". (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 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 | « no previous file | no next file » | 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/linux/pkg_config.gni") 5 import("//build/config/linux/pkg_config.gni")
6 import("//build/config/ui.gni") 6 import("//build/config/ui.gni")
7 import("//testing/test.gni") 7 import("//testing/test.gni")
8 8
9 use_egl = is_win || is_android || is_linux 9 use_egl = is_win || is_android || is_linux
10 use_glx = use_x11 10 use_glx = use_x11
11 11
12 if (is_android) { 12 if (is_android) {
13 import("//build/config/android/config.gni") 13 import("//build/config/android/config.gni")
14 import("//build/config/android/rules.gni") 14 import("//build/config/android/rules.gni")
15 } 15 }
16 16
17 if (is_chromeos) { 17 if (target_os == "chromeos") {
18 pkg_config("libdrm") { 18 pkg_config("libdrm") {
19 packages = [ "libdrm" ] 19 packages = [ "libdrm" ]
20 } 20 }
21 } 21 }
22 22
23 config("gl_config") { 23 config("gl_config") {
24 defines = [] 24 defines = []
25 if (use_glx) { 25 if (use_glx) {
26 defines += [ 26 defines += [
27 "GL_GLEXT_PROTOTYPES", 27 "GL_GLEXT_PROTOTYPES",
(...skipping 324 matching lines...) Expand 10 before | Expand all | Expand 10 after
352 "test/egl_initialization_displays_unittest.cc", 352 "test/egl_initialization_displays_unittest.cc",
353 ] 353 ]
354 } 354 }
355 355
356 if (use_glx) { 356 if (use_glx) {
357 sources += [ "glx_api_unittest.cc" ] 357 sources += [ "glx_api_unittest.cc" ]
358 } 358 }
359 359
360 if (use_ozone) { 360 if (use_ozone) {
361 sources += [ "gl_image_ozone_native_pixmap_unittest.cc" ] 361 sources += [ "gl_image_ozone_native_pixmap_unittest.cc" ]
362 if (is_chromeos && target_cpu != "arm") { 362 if (target_os == "chromeos" && target_cpu != "arm") {
363 sources += [ "gl_image_ozone_native_pixmap_drm_unittest.cc" ] 363 sources += [ "gl_image_ozone_native_pixmap_drm_unittest.cc" ]
364 } 364 }
365 } 365 }
366 366
367 if (is_mac) { 367 if (is_mac) {
368 sources += [ "gl_image_io_surface_unittest.cc" ] 368 sources += [ "gl_image_io_surface_unittest.cc" ]
369 libs = [ "IOSurface.framework" ] 369 libs = [ "IOSurface.framework" ]
370 } 370 }
371 371
372 if (is_win) { 372 if (is_win) {
373 sources += [ "wgl_api_unittest.cc" ] 373 sources += [ "wgl_api_unittest.cc" ]
374 } 374 }
375 375
376 include_dirs = [ "//third_party/khronos" ] 376 include_dirs = [ "//third_party/khronos" ]
377 377
378 deps = [ 378 deps = [
379 ":gl", 379 ":gl",
380 ":gl_unittest_utils", 380 ":gl_unittest_utils",
381 ":test_support", 381 ":test_support",
382 "//base", 382 "//base",
383 "//base/test:test_support", 383 "//base/test:test_support",
384 "//testing/gmock", 384 "//testing/gmock",
385 "//testing/gtest", 385 "//testing/gtest",
386 "//ui/gfx", 386 "//ui/gfx",
387 "//ui/gfx/geometry", 387 "//ui/gfx/geometry",
388 "//ui/gl/init", 388 "//ui/gl/init",
389 ] 389 ]
390 390
391 if (is_chromeos) { 391 if (target_os == "chromeos") {
392 configs += [ ":libdrm" ] 392 configs += [ ":libdrm" ]
393 } 393 }
394 394
395 data_deps = [ 395 data_deps = [
396 "//third_party/mesa:osmesa", 396 "//third_party/mesa:osmesa",
397 ] 397 ]
398 398
399 if (use_ozone) { 399 if (use_ozone) {
400 deps += [ "//ui/ozone" ] 400 deps += [ "//ui/ozone" ]
401 } 401 }
402 } 402 }
403 403
404 if (is_android) { 404 if (is_android) {
405 generate_jar_jni("surface_jni_headers") { 405 generate_jar_jni("surface_jni_headers") {
406 jni_package = "ui/gl" 406 jni_package = "ui/gl"
407 classes = [ "android/view/Surface.class" ] 407 classes = [ "android/view/Surface.class" ]
408 } 408 }
409 409
410 generate_jni("gl_jni_headers") { 410 generate_jni("gl_jni_headers") {
411 sources = [ 411 sources = [
412 "../android/java/src/org/chromium/ui/gl/SurfaceTextureListener.java", 412 "../android/java/src/org/chromium/ui/gl/SurfaceTextureListener.java",
413 "../android/java/src/org/chromium/ui/gl/SurfaceTexturePlatformWrapper.java ", 413 "../android/java/src/org/chromium/ui/gl/SurfaceTexturePlatformWrapper.java ",
414 ] 414 ]
415 public_deps = [ 415 public_deps = [
416 ":surface_jni_headers", 416 ":surface_jni_headers",
417 ] 417 ]
418 jni_package = "ui/gl" 418 jni_package = "ui/gl"
419 } 419 }
420 } 420 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698