Making the build work on linux
authorMatthew Leibowitz <mattleibow@live.com>
Sat, 10 Mar 2018 06:35:36 +0000 (08:35 +0200)
committerMatthew Leibowitz <mattleibow@live.com>
Sat, 10 Mar 2018 06:35:36 +0000 (08:35 +0200)
BUILD.gn
gn/BUILD.gn
gn/BUILDCONFIG.gn

index 53477bc..0d4fd79 100644 (file)
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -432,9 +432,11 @@ optional("gpu") {
     libs += [ "EGL" ]
   } else if (is_linux) {
     sources += [ "src/gpu/gl/glx/GrGLCreateNativeInterface_glx.cpp" ]
+    # GPU is not linked in, but loaded at runtime
     libs += [
-      "GL",
-      "GLU",
+      # "GL",
+      # "GLU",
+      "dl",
     ]
   } else if (is_mac) {
     sources += [ "src/gpu/gl/mac/GrGLCreateNativeInterface_mac.cpp" ]
index 0d78ccc..559aead 100644 (file)
@@ -698,6 +698,9 @@ toolchain("gcc_like") {
 
   tool("solink") {
     soname = "{{target_output_name}}{{output_extension}}"
+    if (linux_soname_version != "") {
+      soname += ".$linux_soname_version"
+    }
 
     rpath = "-Wl,-soname,$soname"
     if (is_mac) {
index 334deb6..6e1d00b 100644 (file)
@@ -16,6 +16,7 @@ declare_args() {
   } else {
     ndk_api = 21
   }
+  linux_soname_version = ""
   sanitize = ""
 }
 declare_args() {