Move around GL dependencies.
:gpu gets GL and GLU
:gpu_tool_utils gets X11
:views gets GL and X11
{shared,static}x{gpu,no-gpu} all seem to link.
May not be perfect, but it's a start.
CQ_INCLUDE_TRYBOTS=skia.primary:Build-Ubuntu-GCC-x86_64-Debug-NoGPU,Build-Ubuntu-GCC-x86_64-Release-Shared
Change-Id: Ia6f595a9d601f623a3c686aa00528a80401bcb24
Reviewed-on: https://skia-review.googlesource.com/8911
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
diff --git a/BUILD.gn b/BUILD.gn
index 8aaa913..c162842 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -407,6 +407,10 @@
sources += [ "src/gpu/gl/android/GrGLCreateNativeInterface_android.cpp" ]
} else if (is_linux) {
sources += [ "src/gpu/gl/glx/GrGLCreateNativeInterface_glx.cpp" ]
+ libs += [
+ "GL",
+ "GLU",
+ ]
} else if (is_mac) {
sources += [ "src/gpu/gl/mac/GrGLCreateNativeInterface_mac.cpp" ]
} else if (is_ios) {
@@ -674,11 +678,6 @@
}
if (is_linux) {
- libs += [
- "GL",
- "GLU",
- "X11",
- ]
sources += [ "src/ports/SkDebug_stdio.cpp" ]
}
@@ -857,6 +856,7 @@
libs += [ "OpenGLES.framework" ]
} else if (is_linux) {
sources += [ "tools/gpu/gl/glx/CreatePlatformGLTestContext_glx.cpp" ]
+ libs += [ "X11" ]
} else if (is_mac) {
sources += [ "tools/gpu/gl/mac/CreatePlatformGLTestContext_mac.cpp" ]
} else if (is_win) {
@@ -1033,6 +1033,10 @@
"src/views/unix/SkOSWindow_Unix.cpp",
"src/views/unix/keysym2ucs.c",
]
+ libs += [
+ "GL",
+ "X11",
+ ]
} else if (is_mac) {
sources += [
"src/views/mac/SkEventNotifier.mm",