Add skia_enable_discrete_gpu argument to GN
This forces all of our testing tools to run with the discrete GPU in
laptop systems that have that option.
BUG=skia:
Change-Id: Ibd7629d6de5f063cdf219b3c7469210af5085d90
Reviewed-on: https://skia-review.googlesource.com/6474
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Brian Osman <brianosman@google.com>
diff --git a/BUILD.gn b/BUILD.gn
index 102b785..24651c7 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -26,6 +26,7 @@
skia_use_zlib = true
skia_enable_android_framework_defines = false
+ skia_enable_discrete_gpu = true
skia_enable_gpu = true
skia_enable_tools = is_skia_standalone
skia_enable_vulkan_debug_layers = is_skia_standalone && is_debug
@@ -148,6 +149,9 @@
if (skia_use_angle) {
defines += [ "SK_ANGLE" ]
}
+ if (skia_enable_discrete_gpu) {
+ defines += [ "SK_ENABLE_DISCRETE_GPU" ]
+ }
}
# Any code that's linked into Skia-the-library should use this config via += skia_library_configs.