| 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 |
| 11 skia_use_freetype = is_android || is_fuchsia || is_linux | 11 skia_use_freetype = is_android || is_fuchsia || is_linux |
| 12 skia_use_giflib = !is_fuchsia | 12 skia_use_giflib = !is_fuchsia |
| 13 skia_use_libjpeg_turbo = true | 13 skia_use_libjpeg_turbo = true |
| 14 skia_use_libpng = true | 14 skia_use_libpng = true |
| 15 skia_use_libwebp = !is_fuchsia | 15 skia_use_libwebp = !is_fuchsia |
| 16 skia_use_mesa = false | 16 skia_use_mesa = false |
| 17 skia_use_sfntly = !is_fuchsia | 17 skia_use_sfntly = !is_fuchsia |
| 18 skia_use_vulkan = is_android && defined(ndk_api) && ndk_api >= 24 | 18 skia_use_vulkan = is_android && defined(ndk_api) && ndk_api >= 24 |
| 19 skia_use_zlib = true | 19 skia_use_zlib = true |
| 20 | 20 |
| 21 skia_enable_android_framework_defines = false | 21 skia_enable_android_framework_defines = false |
| 22 skia_enable_gpu = true | 22 skia_enable_gpu = true |
| 23 skia_enable_tools = !is_fuchsia | 23 skia_enable_tools = !is_fuchsia |
| 24 |
| 25 # TODO: Vulkan debug layers should be disabled for all client uses of skia as
well. |
| 26 skia_enable_vulkan_debug_layers = !is_fuchsia && is_debug |
| 24 } | 27 } |
| 25 | 28 |
| 26 # Our tools require static linking (they use non-exported symbols) and GPU suppo
rt (just lazy). | 29 # Our tools require static linking (they use non-exported symbols) and GPU suppo
rt (just lazy). |
| 27 skia_enable_tools = skia_enable_tools && skia_enable_gpu && !is_component_build | 30 skia_enable_tools = skia_enable_tools && skia_enable_gpu && !is_component_build |
| 28 | 31 |
| 29 fontmgr_android_enabled = skia_use_expat && skia_use_freetype | 32 fontmgr_android_enabled = skia_use_expat && skia_use_freetype |
| 30 | 33 |
| 31 skia_public_includes = [ | 34 skia_public_includes = [ |
| 32 "include/android", | 35 "include/android", |
| 33 "include/c", | 36 "include/c", |
| (...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 321 sources += [ "src/gpu/gl/mac/GrGLCreateNativeInterface_mac.cpp" ] | 324 sources += [ "src/gpu/gl/mac/GrGLCreateNativeInterface_mac.cpp" ] |
| 322 } else { | 325 } else { |
| 323 sources += [ "src/gpu/gl/GrGLCreateNativeInterface_none.cpp" ] | 326 sources += [ "src/gpu/gl/GrGLCreateNativeInterface_none.cpp" ] |
| 324 } | 327 } |
| 325 libs = [] | 328 libs = [] |
| 326 | 329 |
| 327 if (skia_use_vulkan) { | 330 if (skia_use_vulkan) { |
| 328 public_defines += [ "SK_VULKAN" ] | 331 public_defines += [ "SK_VULKAN" ] |
| 329 sources += skia_vk_sources | 332 sources += skia_vk_sources |
| 330 libs += [ "vulkan" ] | 333 libs += [ "vulkan" ] |
| 334 if (skia_enable_vulkan_debug_layers) { |
| 335 public_defines += [ "SK_ENABLE_VK_LAYERS" ] |
| 336 } |
| 331 } | 337 } |
| 332 } | 338 } |
| 333 | 339 |
| 334 optional("jpeg") { | 340 optional("jpeg") { |
| 335 enabled = skia_use_libjpeg_turbo | 341 enabled = skia_use_libjpeg_turbo |
| 336 public_defines = [ "SK_HAS_JPEG_LIBRARY" ] | 342 public_defines = [ "SK_HAS_JPEG_LIBRARY" ] |
| 337 | 343 |
| 338 deps = [ | 344 deps = [ |
| 339 "//third_party/libjpeg-turbo:libjpeg", | 345 "//third_party/libjpeg-turbo:libjpeg", |
| 340 ] | 346 ] |
| (...skipping 557 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 898 "tools/get_images_from_skps.cpp", | 904 "tools/get_images_from_skps.cpp", |
| 899 ] | 905 ] |
| 900 deps = [ | 906 deps = [ |
| 901 ":flags", | 907 ":flags", |
| 902 ":skia", | 908 ":skia", |
| 903 "//third_party/jsoncpp", | 909 "//third_party/jsoncpp", |
| 904 ] | 910 ] |
| 905 testonly = true | 911 testonly = true |
| 906 } | 912 } |
| 907 } | 913 } |
| OLD | NEW |