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
|
|
|
],
|
|
|
|
}],
|
|
|
|
['skia_os != "linux"', {
|
|
|
|
'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',
|
|
|
|
],
|
|
|
|
}],
|
|
|
|
[ 'skia_os == "linux"', {
|
|
|
|
'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': [
|
|
|
|
{
|
|
|
|
'target_name': 'skgr',
|
2012-10-10 19:45:51 +00:00
|
|
|
'product_name': 'skia_skgr',
|
2011-05-31 13:50:51 +00:00
|
|
|
'type': 'static_library',
|
2012-10-10 19:45:51 +00:00
|
|
|
'standalone_static_library': 1,
|
2012-08-23 12:55:01 +00:00
|
|
|
'includes': [
|
|
|
|
'gpu.gypi',
|
|
|
|
],
|
2011-05-31 13:50:51 +00:00
|
|
|
'include_dirs': [
|
2012-03-29 14:51:56 +00:00
|
|
|
'../include/config',
|
|
|
|
'../include/core',
|
2011-05-31 13:50:51 +00:00
|
|
|
'../src/core',
|
|
|
|
'../include/gpu',
|
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
|
|
|
'dependencies': [
|
|
|
|
'angle.gyp:*',
|
|
|
|
],
|
|
|
|
'export_dependent_settings': [
|
|
|
|
'angle.gyp:*',
|
|
|
|
],
|
2011-05-31 13:50:51 +00:00
|
|
|
'sources': [
|
2012-08-23 12:55:01 +00:00
|
|
|
'<@(skgr_sources)',
|
|
|
|
'<@(skgr_native_gl_sources)',
|
|
|
|
'<@(skgr_angle_gl_sources)',
|
|
|
|
'<@(skgr_mesa_gl_sources)',
|
|
|
|
'<@(skgr_debug_gl_sources)',
|
|
|
|
'<@(skgr_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
|
|
|
],
|
2011-10-19 20:43:20 +00:00
|
|
|
'conditions': [
|
|
|
|
[ 'not skia_mesa', {
|
|
|
|
'sources!': [
|
2012-03-28 19:37:51 +00:00
|
|
|
'../src/gpu/gl/mesa/SkMesaGLContext.cpp',
|
2011-10-19 20:43:20 +00:00
|
|
|
],
|
|
|
|
}],
|
|
|
|
[ 'skia_mesa and skia_os == "mac"', {
|
|
|
|
'include_dirs': [
|
|
|
|
'$(SDKROOT)/usr/X11/include/',
|
|
|
|
],
|
|
|
|
}],
|
2012-04-02 20:42:26 +00:00
|
|
|
[ 'not skia_angle', {
|
|
|
|
'sources!': [
|
|
|
|
'../include/gpu/gl/SkANGLEGLContext.h',
|
|
|
|
'../src/gpu/gl/angle/SkANGLEGLContext.cpp',
|
|
|
|
'../src/gpu/gl/angle/GrGLCreateANGLEInterface.cpp',
|
|
|
|
],
|
|
|
|
}],
|
2011-05-31 13:50:51 +00:00
|
|
|
],
|
|
|
|
},
|
|
|
|
{
|
|
|
|
'target_name': 'gr',
|
2012-10-10 19:45:51 +00:00
|
|
|
'product_name': 'skia_gr',
|
2011-05-31 13:50:51 +00:00
|
|
|
'type': 'static_library',
|
2012-10-10 19:45:51 +00:00
|
|
|
'standalone_static_library': 1,
|
2012-08-23 12:55:01 +00:00
|
|
|
'includes': [
|
|
|
|
'gpu.gypi',
|
|
|
|
],
|
|
|
|
'include_dirs': [
|
2011-05-31 13:50:51 +00:00
|
|
|
'../include/core',
|
|
|
|
'../include/config',
|
2011-10-12 19:53:16 +00:00
|
|
|
'../include/gpu',
|
2012-01-12 20:19:56 +00:00
|
|
|
'../src/core', # SkRasterClip.h
|
2012-05-10 12:13:36 +00:00
|
|
|
'../src/gpu'
|
2011-05-31 13:50:51 +00:00
|
|
|
],
|
|
|
|
'dependencies': [
|
2012-04-02 20:42:26 +00:00
|
|
|
'angle.gyp:*',
|
|
|
|
],
|
|
|
|
'export_dependent_settings': [
|
|
|
|
'angle.gyp:*',
|
2011-05-31 13:50:51 +00:00
|
|
|
],
|
|
|
|
'sources': [
|
2012-08-23 12:55:01 +00:00
|
|
|
'<@(gr_sources)',
|
|
|
|
'<@(gr_native_gl_sources)',
|
2012-08-23 18:14:13 +00:00
|
|
|
'<@(gr_angle_gl_sources)',
|
2012-08-23 12:55:01 +00:00
|
|
|
'<@(gr_mesa_gl_sources)',
|
|
|
|
'<@(gr_debug_gl_sources)',
|
|
|
|
'<@(gr_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',
|
|
|
|
],
|
|
|
|
}],
|
2011-07-01 20:20:07 +00:00
|
|
|
[ 'skia_os == "linux"', {
|
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
|
|
|
}],
|
|
|
|
[ 'skia_mesa and skia_os == "mac"', {
|
|
|
|
'link_settings': {
|
|
|
|
'libraries': [
|
|
|
|
'$(SDKROOT)/usr/X11/lib/libOSMesa.dylib',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
'include_dirs': [
|
|
|
|
'$(SDKROOT)/usr/X11/include/',
|
|
|
|
],
|
|
|
|
}],
|
|
|
|
[ 'not skia_mesa', {
|
|
|
|
'sources!': [
|
2012-03-28 19:37:51 +00:00
|
|
|
'../src/gpu/gl/mesa/GrGLCreateMesaInterface.cpp',
|
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!': [
|
|
|
|
'../include/gpu/gl/SkANGLEGLContext.h',
|
|
|
|
|
|
|
|
'../src/gpu/gl/angle/GrGLCreateANGLEInterface.cpp',
|
|
|
|
'../src/gpu/gl/angle/SkANGLEGLContext.cpp',
|
|
|
|
],
|
|
|
|
}],
|
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:
|