Skia: Add Command Buffer support to Linux/Mac
Code added to load libcommand_buffer_gles2.so on linux or
mac.
Review URL: https://codereview.chromium.org/1346423002
diff --git a/gyp/common_conditions.gypi b/gyp/common_conditions.gypi
index 54fa543..a06fcb7 100644
--- a/gyp/common_conditions.gypi
+++ b/gyp/common_conditions.gypi
@@ -618,6 +618,12 @@
],
}],
+ [ 'skia_command_buffer', {
+ 'ldflags': [
+ '-Wl,-rpath,\$$ORIGIN/lib',
+ ],
+ }],
+
], # end 'conditions'
# The Xcode SYMROOT must be at the root. See build/common.gypi in chromium for more details
'xcode_settings': {
diff --git a/gyp/common_variables.gypi b/gyp/common_variables.gypi
index e8a8355..57fad1d 100644
--- a/gyp/common_variables.gypi
+++ b/gyp/common_variables.gypi
@@ -181,7 +181,7 @@
'skia_clang_build%': 0,
'skia_keep_frame_pointer%': 0,
}],
- [ 'skia_shared_lib or skia_sanitizer or skia_os == "android" or (skia_os == "linux" and skia_angle == 1)', {
+ [ 'skia_shared_lib or skia_sanitizer or skia_os == "android" or (skia_os == "linux" and (skia_angle == 1 or skia_command_buffer == 1))', {
'skia_pic%' : 1,
}, {
'skia_pic%' : 0,
diff --git a/gyp/ports.gyp b/gyp/ports.gyp
index f111650..c227a80 100644
--- a/gyp/ports.gyp
+++ b/gyp/ports.gyp
@@ -51,6 +51,9 @@
'../src/ports/SkOSFile_posix.cpp',
'../src/ports/SkOSFile_stdio.cpp',
'../src/ports/SkOSFile_win.cpp',
+ '../src/ports/SkOSLibrary.h',
+ '../src/ports/SkOSLibrary_posix.cpp',
+ '../src/ports/SkOSLibrary_win.cpp',
'../src/ports/SkDiscardableMemory_none.cpp',
'../src/ports/SkTime_Unix.cpp',
'../src/ports/SkTime_win.cpp',
@@ -171,6 +174,7 @@
'sources!': [ # these are used everywhere but windows
'../src/ports/SkDebug_stdio.cpp',
'../src/ports/SkOSFile_posix.cpp',
+ '../src/ports/SkOSLibrary_posix.cpp',
'../src/ports/SkTime_Unix.cpp',
'../src/ports/SkTLS_pthread.cpp',
],
@@ -188,6 +192,7 @@
'../src/ports/SkFontHost_win.cpp',
'../src/ports/SkFontMgr_win_dw.cpp',
'../src/ports/SkOSFile_win.cpp',
+ '../src/ports/SkOSLibrary_win.cpp',
'../src/ports/SkRemotableFontMgr_win_dw.cpp',
'../src/ports/SkTime_win.cpp',
'../src/ports/SkTLS_win.cpp',