Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 # Copyright 2016 Google Inc. | 1 # Copyright 2016 Google Inc. |
| 2 # | 2 # |
| 3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
| 4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
| 5 | 5 |
| 6 import("gn/shared_sources.gni") | 6 import("gn/shared_sources.gni") |
| 7 | 7 |
| 8 declare_args() { | 8 declare_args() { |
| 9 skia_use_expat = true | 9 skia_use_expat = true |
| 10 skia_use_fontconfig = is_linux | 10 skia_use_fontconfig = is_linux |
| (...skipping 285 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 296 deps = [ | 296 deps = [ |
| 297 "//third_party/giflib", | 297 "//third_party/giflib", |
| 298 ] | 298 ] |
| 299 sources = [ | 299 sources = [ |
| 300 "src/codec/SkGifCodec.cpp", | 300 "src/codec/SkGifCodec.cpp", |
| 301 ] | 301 ] |
| 302 } | 302 } |
| 303 | 303 |
| 304 optional("gpu") { | 304 optional("gpu") { |
| 305 enabled = skia_enable_gpu | 305 enabled = skia_enable_gpu |
| 306 public_defines = [] | |
| 307 | |
| 306 sources = skia_gpu_sources + [ "src/gpu/gl/GrGLDefaultInterface_native.cpp" ] | 308 sources = skia_gpu_sources + [ "src/gpu/gl/GrGLDefaultInterface_native.cpp" ] |
| 307 | 309 |
| 308 # These paths need to be absolute to match the ones produced by shared_sources .gni. | 310 # These paths need to be absolute to match the ones produced by shared_sources .gni. |
| 309 sources -= get_path_info([ | 311 sources -= get_path_info([ |
| 310 "src/gpu/gl/GrGLCreateNativeInterface_none.cpp", | 312 "src/gpu/gl/GrGLCreateNativeInterface_none.cpp", |
| 311 "src/gpu/gl/GrGLDefaultInterface_none.cpp", | 313 "src/gpu/gl/GrGLDefaultInterface_none.cpp", |
| 312 ], | 314 ], |
| 313 "abspath") | 315 "abspath") |
| 314 if (is_android) { | 316 if (is_android) { |
| 315 sources += [ "src/gpu/gl/android/GrGLCreateNativeInterface_android.cpp" ] | 317 sources += [ "src/gpu/gl/android/GrGLCreateNativeInterface_android.cpp" ] |
| 316 } else if (is_linux) { | 318 } else if (is_linux) { |
| 317 sources += [ "src/gpu/gl/glx/GrGLCreateNativeInterface_glx.cpp" ] | 319 sources += [ "src/gpu/gl/glx/GrGLCreateNativeInterface_glx.cpp" ] |
| 318 } else if (is_mac) { | 320 } else if (is_mac) { |
| 319 sources += [ "src/gpu/gl/mac/GrGLCreateNativeInterface_mac.cpp" ] | 321 sources += [ "src/gpu/gl/mac/GrGLCreateNativeInterface_mac.cpp" ] |
| 320 } else { | 322 } else { |
| 321 sources += [ "src/gpu/gl/GrGLCreateNativeInterface_none.cpp" ] | 323 sources += [ "src/gpu/gl/GrGLCreateNativeInterface_none.cpp" ] |
| 322 } | 324 } |
| 325 libs = [] | |
|
egdaniel
2016/09/20 20:52:57
is there any reason why public_defines is initiali
| |
| 326 | |
| 327 if (skia_use_vulkan) { | |
| 328 public_defines += [ "SK_VULKAN" ] | |
| 329 sources += skia_vk_sources | |
| 330 libs += [ "vulkan" ] | |
| 331 } | |
| 323 } | 332 } |
| 324 | 333 |
| 325 optional("jpeg") { | 334 optional("jpeg") { |
| 326 enabled = skia_use_libjpeg_turbo | 335 enabled = skia_use_libjpeg_turbo |
| 327 public_defines = [ "SK_HAS_JPEG_LIBRARY" ] | 336 public_defines = [ "SK_HAS_JPEG_LIBRARY" ] |
| 328 | 337 |
| 329 deps = [ | 338 deps = [ |
| 330 "//third_party/libjpeg-turbo:libjpeg", | 339 "//third_party/libjpeg-turbo:libjpeg", |
| 331 ] | 340 ] |
| 332 sources = [ | 341 sources = [ |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 372 | 381 |
| 373 deps = [ | 382 deps = [ |
| 374 "//third_party/freetype2", | 383 "//third_party/freetype2", |
| 375 ] | 384 ] |
| 376 sources = [ | 385 sources = [ |
| 377 "src/ports/SkFontHost_FreeType.cpp", | 386 "src/ports/SkFontHost_FreeType.cpp", |
| 378 "src/ports/SkFontHost_FreeType_common.cpp", | 387 "src/ports/SkFontHost_FreeType_common.cpp", |
| 379 ] | 388 ] |
| 380 } | 389 } |
| 381 | 390 |
| 382 optional("vulkan") { | |
| 383 enabled = skia_use_vulkan | |
| 384 public_defines = [ "SK_VULKAN" ] | |
| 385 libs = [ "vulkan" ] | |
| 386 sources = skia_vk_sources | |
| 387 } | |
| 388 | |
| 389 optional("webp") { | 391 optional("webp") { |
| 390 enabled = skia_use_libwebp | 392 enabled = skia_use_libwebp |
| 391 public_defines = [ "SK_HAS_WEBP_LIBRARY" ] | 393 public_defines = [ "SK_HAS_WEBP_LIBRARY" ] |
| 392 | 394 |
| 393 deps = [ | 395 deps = [ |
| 394 "//third_party/libwebp", | 396 "//third_party/libwebp", |
| 395 ] | 397 ] |
| 396 sources = [ | 398 sources = [ |
| 397 "src/codec/SkWebpAdapterCodec.cpp", | 399 "src/codec/SkWebpAdapterCodec.cpp", |
| 398 "src/codec/SkWebpCodec.cpp", | 400 "src/codec/SkWebpCodec.cpp", |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 431 ":gpu", | 433 ":gpu", |
| 432 ":jpeg", | 434 ":jpeg", |
| 433 ":none", | 435 ":none", |
| 434 ":pdf", | 436 ":pdf", |
| 435 ":png", | 437 ":png", |
| 436 ":sse2", | 438 ":sse2", |
| 437 ":sse41", | 439 ":sse41", |
| 438 ":sse42", | 440 ":sse42", |
| 439 ":ssse3", | 441 ":ssse3", |
| 440 ":typeface_freetype", | 442 ":typeface_freetype", |
| 441 ":vulkan", | |
| 442 ":webp", | 443 ":webp", |
| 443 ":xml", | 444 ":xml", |
| 444 ] | 445 ] |
| 445 | 446 |
| 446 sources = [] | 447 sources = [] |
| 447 sources += skia_core_sources | 448 sources += skia_core_sources |
| 448 sources += skia_effects_sources | 449 sources += skia_effects_sources |
| 449 sources += skia_sksl_sources | 450 sources += skia_sksl_sources |
| 450 sources += skia_utils_sources | 451 sources += skia_utils_sources |
| 451 sources += [ | 452 sources += [ |
| (...skipping 445 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 897 "tools/get_images_from_skps.cpp", | 898 "tools/get_images_from_skps.cpp", |
| 898 ] | 899 ] |
| 899 deps = [ | 900 deps = [ |
| 900 ":flags", | 901 ":flags", |
| 901 ":skia", | 902 ":skia", |
| 902 "//third_party/jsoncpp", | 903 "//third_party/jsoncpp", |
| 903 ] | 904 ] |
| 904 testonly = true | 905 testonly = true |
| 905 } | 906 } |
| 906 } | 907 } |
| OLD | NEW |