2011-05-31 13:50:51 +00:00
|
|
|
{
|
2011-10-13 13:33:08 +00:00
|
|
|
'target_defaults': {
|
|
|
|
'conditions': [
|
|
|
|
['skia_os != "win"', {
|
|
|
|
'sources/': [ ['exclude', '_win.(h|cpp)$'],
|
|
|
|
],
|
|
|
|
}],
|
|
|
|
['skia_os != "mac"', {
|
2012-10-02 15:25:12 +00:00
|
|
|
'sources/': [ ['exclude', '_mac.(h|cpp|m|mm)$'],
|
2011-10-13 13:33:08 +00:00
|
|
|
],
|
|
|
|
}],
|
2013-06-11 15:52:19 +00:00
|
|
|
['skia_os != "linux" and skia_os != "chromeos"', {
|
2011-10-13 13:33:08 +00:00
|
|
|
'sources/': [ ['exclude', '_unix.(h|cpp)$'],
|
|
|
|
],
|
|
|
|
}],
|
|
|
|
['skia_os != "ios"', {
|
2012-10-02 15:25:12 +00:00
|
|
|
'sources/': [ ['exclude', '_iOS.(h|cpp|m|mm)$'],
|
2011-10-13 13:33:08 +00:00
|
|
|
],
|
|
|
|
}],
|
|
|
|
['skia_os != "android"', {
|
|
|
|
'sources/': [ ['exclude', '_android.(h|cpp)$'],
|
|
|
|
],
|
|
|
|
}],
|
2012-11-01 17:43:44 +00:00
|
|
|
['skia_os != "nacl"', {
|
|
|
|
'sources/': [ ['exclude', '_nacl.(h|cpp)$'],
|
|
|
|
],
|
|
|
|
}],
|
2011-10-13 13:33:08 +00:00
|
|
|
[ 'skia_os == "android"', {
|
|
|
|
'defines': [
|
|
|
|
'GR_ANDROID_BUILD=1',
|
|
|
|
],
|
|
|
|
}],
|
|
|
|
[ 'skia_os == "mac"', {
|
|
|
|
'defines': [
|
|
|
|
'GR_MAC_BUILD=1',
|
|
|
|
],
|
|
|
|
}],
|
2013-06-11 15:52:19 +00:00
|
|
|
[ 'skia_os == "linux" or skia_os == "chromeos"', {
|
2011-10-13 13:33:08 +00:00
|
|
|
'defines': [
|
|
|
|
'GR_LINUX_BUILD=1',
|
|
|
|
],
|
|
|
|
}],
|
|
|
|
[ 'skia_os == "ios"', {
|
|
|
|
'defines': [
|
|
|
|
'GR_IOS_BUILD=1',
|
|
|
|
],
|
|
|
|
}],
|
|
|
|
[ 'skia_os == "win"', {
|
|
|
|
'defines': [
|
|
|
|
'GR_WIN32_BUILD=1',
|
|
|
|
],
|
|
|
|
}],
|
2012-08-02 14:03:32 +00:00
|
|
|
# nullify the targets in this gyp file if skia_gpu is 0
|
|
|
|
[ 'skia_gpu == 0', {
|
|
|
|
'sources/': [
|
|
|
|
['exclude', '.*'],
|
|
|
|
],
|
|
|
|
'defines/': [
|
|
|
|
['exclude', '.*'],
|
|
|
|
],
|
|
|
|
'include_dirs/': [
|
|
|
|
['exclude', '.*'],
|
|
|
|
],
|
|
|
|
'link_settings': {
|
|
|
|
'libraries/': [
|
|
|
|
['exclude', '.*'],
|
|
|
|
],
|
|
|
|
},
|
|
|
|
'direct_dependent_settings': {
|
|
|
|
'defines/': [
|
|
|
|
['exclude', '.*'],
|
|
|
|
],
|
|
|
|
'include_dirs/': [
|
|
|
|
['exclude', '.*'],
|
|
|
|
],
|
|
|
|
},
|
|
|
|
}],
|
2012-10-29 19:24:45 +00:00
|
|
|
[ 'skia_texture_cache_mb_limit != 0', {
|
|
|
|
'defines': [
|
|
|
|
'GR_DEFAULT_TEXTURE_CACHE_MB_LIMIT=<(skia_texture_cache_mb_limit)',
|
|
|
|
],
|
|
|
|
}],
|
2011-10-13 13:33:08 +00:00
|
|
|
],
|
|
|
|
'direct_dependent_settings': {
|
|
|
|
'conditions': [
|
|
|
|
[ 'skia_os == "android"', {
|
|
|
|
'defines': [
|
|
|
|
'GR_ANDROID_BUILD=1',
|
|
|
|
],
|
|
|
|
}],
|
|
|
|
[ 'skia_os == "mac"', {
|
|
|
|
'defines': [
|
|
|
|
'GR_MAC_BUILD=1',
|
|
|
|
],
|
|
|
|
}],
|
|
|
|
[ 'skia_os == "linux"', {
|
|
|
|
'defines': [
|
|
|
|
'GR_LINUX_BUILD=1',
|
|
|
|
],
|
|
|
|
}],
|
|
|
|
[ 'skia_os == "ios"', {
|
|
|
|
'defines': [
|
|
|
|
'GR_IOS_BUILD=1',
|
|
|
|
],
|
|
|
|
}],
|
|
|
|
[ 'skia_os == "win"', {
|
|
|
|
'defines': [
|
|
|
|
'GR_WIN32_BUILD=1',
|
|
|
|
'GR_GL_FUNCTION_TYPE=__stdcall',
|
|
|
|
],
|
|
|
|
}],
|
|
|
|
],
|
|
|
|
'include_dirs': [
|
|
|
|
'../include/gpu',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
},
|
2011-05-31 13:50:51 +00:00
|
|
|
'targets': [
|
|
|
|
{
|
2013-06-18 14:43:53 +00:00
|
|
|
'target_name': 'skgpu',
|
|
|
|
'product_name': 'skia_skgpu',
|
2011-05-31 13:50:51 +00:00
|
|
|
'type': 'static_library',
|
2012-10-10 19:45:51 +00:00
|
|
|
'standalone_static_library': 1,
|
2013-07-22 14:39:45 +00:00
|
|
|
'dependencies': [
|
|
|
|
'angle.gyp:*',
|
|
|
|
'core.gyp:*',
|
|
|
|
'utils.gyp:*',
|
|
|
|
],
|
2012-08-23 12:55:01 +00:00
|
|
|
'includes': [
|
|
|
|
'gpu.gypi',
|
|
|
|
],
|
2011-05-31 13:50:51 +00:00
|
|
|
'include_dirs': [
|
2013-07-20 00:24:35 +00:00
|
|
|
'../include/gpu',
|
2013-07-22 14:39:45 +00:00
|
|
|
'../src/core',
|
2012-05-07 17:09:37 +00:00
|
|
|
'../src/gpu',
|
2011-05-31 13:50:51 +00:00
|
|
|
],
|
2012-04-02 20:42:26 +00:00
|
|
|
'export_dependent_settings': [
|
|
|
|
'angle.gyp:*',
|
|
|
|
],
|
2011-05-31 13:50:51 +00:00
|
|
|
'sources': [
|
2013-06-18 14:43:53 +00:00
|
|
|
'<@(skgpu_sources)',
|
|
|
|
'<@(skgpu_native_gl_sources)',
|
|
|
|
'<@(skgpu_angle_gl_sources)',
|
|
|
|
'<@(skgpu_mesa_gl_sources)',
|
|
|
|
'<@(skgpu_debug_gl_sources)',
|
|
|
|
'<@(skgpu_null_gl_sources)',
|
2012-09-04 14:37:12 +00:00
|
|
|
'gpu.gypi', # Makes the gypi appear in IDEs (but does not modify the build).
|
2011-05-31 13:50:51 +00:00
|
|
|
],
|
|
|
|
'defines': [
|
|
|
|
'GR_IMPLEMENTATION=1',
|
|
|
|
],
|
|
|
|
'conditions': [
|
2012-06-28 18:48:06 +00:00
|
|
|
[ 'skia_nv_path_rendering', {
|
|
|
|
'defines': [
|
|
|
|
'GR_GL_USE_NV_PATH_RENDERING=1',
|
|
|
|
],
|
|
|
|
}],
|
2013-01-07 14:26:40 +00:00
|
|
|
[ 'skia_stroke_path_rendering', {
|
|
|
|
'sources': [
|
|
|
|
'../experimental/StrokePathRenderer/GrStrokePathRenderer.h',
|
|
|
|
'../experimental/StrokePathRenderer/GrStrokePathRenderer.cpp',
|
|
|
|
],
|
|
|
|
'defines': [
|
|
|
|
'GR_STROKE_PATH_RENDERING=1',
|
|
|
|
],
|
|
|
|
}],
|
2013-01-09 21:04:52 +00:00
|
|
|
[ 'skia_android_path_rendering', {
|
|
|
|
'sources': [
|
|
|
|
'../experimental/AndroidPathRenderer/GrAndroidPathRenderer.cpp',
|
|
|
|
'../experimental/AndroidPathRenderer/GrAndroidPathRenderer.h',
|
|
|
|
'../experimental/AndroidPathRenderer/AndroidPathRenderer.cpp',
|
|
|
|
'../experimental/AndroidPathRenderer/AndroidPathRenderer.h',
|
|
|
|
'../experimental/AndroidPathRenderer/Vertex.h',
|
|
|
|
],
|
|
|
|
'defines': [
|
|
|
|
'GR_ANDROID_PATH_RENDERING=1',
|
|
|
|
],
|
|
|
|
}],
|
2013-06-11 15:52:19 +00:00
|
|
|
[ 'skia_os == "linux" or skia_os == "chromeos"', {
|
2011-05-31 13:50:51 +00:00
|
|
|
'sources!': [
|
2012-02-10 21:35:06 +00:00
|
|
|
'../src/gpu/gl/GrGLDefaultInterface_none.cpp',
|
|
|
|
'../src/gpu/gl/GrGLCreateNativeInterface_none.cpp',
|
2011-05-31 13:50:51 +00:00
|
|
|
],
|
|
|
|
'link_settings': {
|
|
|
|
'libraries': [
|
|
|
|
'-lGL',
|
2012-11-01 17:43:44 +00:00
|
|
|
'-lGLU',
|
2012-11-12 20:55:02 +00:00
|
|
|
'-lX11',
|
2011-05-31 13:50:51 +00:00
|
|
|
],
|
|
|
|
},
|
|
|
|
}],
|
2012-11-01 17:43:44 +00:00
|
|
|
[ 'skia_os == "nacl"', {
|
|
|
|
'link_settings': {
|
|
|
|
'libraries': [
|
|
|
|
'-lppapi_gles2',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
}],
|
2011-10-19 20:43:20 +00:00
|
|
|
[ 'skia_mesa and skia_os == "linux"', {
|
|
|
|
'link_settings': {
|
|
|
|
'libraries': [
|
|
|
|
'-lOSMesa',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
}],
|
2011-07-01 20:20:07 +00:00
|
|
|
[ 'skia_os == "mac"', {
|
2011-05-31 13:50:51 +00:00
|
|
|
'link_settings': {
|
|
|
|
'libraries': [
|
|
|
|
'$(SDKROOT)/System/Library/Frameworks/OpenGL.framework',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
'sources!': [
|
2012-02-10 21:35:06 +00:00
|
|
|
'../src/gpu/gl/GrGLDefaultInterface_none.cpp',
|
|
|
|
'../src/gpu/gl/GrGLCreateNativeInterface_none.cpp',
|
2011-05-31 13:50:51 +00:00
|
|
|
],
|
2011-10-19 20:43:20 +00:00
|
|
|
}],
|
2013-06-18 14:43:53 +00:00
|
|
|
[ 'not skia_mesa', {
|
|
|
|
'sources!': [
|
|
|
|
'../src/gpu/gl/mesa/SkMesaGLContext.cpp',
|
|
|
|
'../src/gpu/gl/mesa/GrGLCreateMesaInterface.cpp',
|
|
|
|
],
|
|
|
|
}],
|
2011-10-19 20:43:20 +00:00
|
|
|
[ 'skia_mesa and skia_os == "mac"', {
|
|
|
|
'link_settings': {
|
|
|
|
'libraries': [
|
2013-02-04 22:17:13 +00:00
|
|
|
'/opt/X11/lib/libOSMesa.dylib',
|
2011-10-19 20:43:20 +00:00
|
|
|
],
|
|
|
|
},
|
|
|
|
'include_dirs': [
|
2013-02-04 22:17:13 +00:00
|
|
|
'/opt/X11/include/',
|
2011-10-19 20:43:20 +00:00
|
|
|
],
|
|
|
|
}],
|
2012-09-28 16:56:28 +00:00
|
|
|
[ 'skia_os in ["win", "ios"]', {
|
2011-05-31 13:50:51 +00:00
|
|
|
'sources!': [
|
2012-02-10 21:35:06 +00:00
|
|
|
'../src/gpu/gl/GrGLDefaultInterface_none.cpp',
|
|
|
|
'../src/gpu/gl/GrGLCreateNativeInterface_none.cpp',
|
2011-05-31 13:50:51 +00:00
|
|
|
],
|
|
|
|
}],
|
2012-04-02 20:42:26 +00:00
|
|
|
[ 'not skia_angle', {
|
|
|
|
'sources!': [
|
2013-06-18 14:43:53 +00:00
|
|
|
'<@(skgpu_angle_gl_sources)',
|
2013-05-03 14:00:34 +00:00
|
|
|
],
|
|
|
|
'dependencies!': [
|
|
|
|
'angle.gyp:*',
|
|
|
|
],
|
|
|
|
'export_dependent_settings!': [
|
|
|
|
'angle.gyp:*',
|
2012-04-02 20:42:26 +00:00
|
|
|
],
|
|
|
|
}],
|
2011-11-03 13:08:29 +00:00
|
|
|
[ 'skia_os == "android"', {
|
|
|
|
'sources!': [
|
2012-02-10 21:35:06 +00:00
|
|
|
'../src/gpu/gl/GrGLDefaultInterface_none.cpp',
|
|
|
|
'../src/gpu/gl/GrGLCreateNativeInterface_none.cpp',
|
2011-11-03 13:08:29 +00:00
|
|
|
],
|
|
|
|
'link_settings': {
|
|
|
|
'libraries': [
|
|
|
|
'-lGLESv2',
|
|
|
|
'-lEGL',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
}],
|
2011-05-31 13:50:51 +00:00
|
|
|
],
|
|
|
|
},
|
|
|
|
],
|
|
|
|
}
|
|
|
|
|
|
|
|
# Local Variables:
|
|
|
|
# tab-width:2
|
|
|
|
# indent-tabs-mode:nil
|
|
|
|
# End:
|
|
|
|
# vim: set expandtab tabstop=2 shiftwidth=2:
|