skia2/gyp/tools.gyp
commit-bot@chromium.org 1f6aed0b1c Move SkImage::encode to SkImage_Codec.cpp.
Chrome depends on SkImage.cpp, but does not include SkImageDecoder,
so having SkImage::encode in SkImage.cpp breaks chromium. Temporarily
fix the problem by moving the implementation into SkImage_Codec.cpp.

The larger fix will be to solve
https://code.google.com/p/skia/issues/detail?id=1275

R=reed@google.com, robertphillips@google.com

Author: scroggo@google.com

Review URL: https://chromiumcodereview.appspot.com/15314004

git-svn-id: http://skia.googlecode.com/svn/trunk@9204 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-05-20 23:57:38 +00:00

345 lines
8.4 KiB
Python

# GYP file to build various tools.
#
# To build on Linux:
# ./gyp_skia tools.gyp && make tools
#
{
'includes': [
'apptype_console.gypi',
],
'targets': [
{
# Build all executable targets defined below.
'target_name': 'tools',
'type': 'none',
'dependencies': [
'bench_pictures',
'filter',
'lua_pictures',
'pinspect',
'render_pdfs',
'render_pictures',
'skdiff',
'skhello',
'skimage',
],
},
{
'target_name': 'skdiff',
'type': 'executable',
'sources': [
'../tools/skdiff.cpp',
'../tools/skdiff.h',
'../tools/skdiff_html.cpp',
'../tools/skdiff_html.h',
'../tools/skdiff_main.cpp',
'../tools/skdiff_utils.cpp',
'../tools/skdiff_utils.h',
],
'dependencies': [
'skia_base_libs.gyp:skia_base_libs',
'effects.gyp:effects',
'images.gyp:images',
],
},
{
'target_name': 'skimagediff',
'type': 'executable',
'sources': [
'../tools/skdiff.cpp',
'../tools/skdiff.h',
'../tools/skdiff_html.cpp',
'../tools/skdiff_html.h',
'../tools/skdiff_image.cpp',
'../tools/skdiff_utils.cpp',
'../tools/skdiff_utils.h',
],
'dependencies': [
'skia_base_libs.gyp:skia_base_libs',
'effects.gyp:effects',
'images.gyp:images',
],
},
{
'target_name': 'skhello',
'type': 'executable',
'sources': [
'../tools/skhello.cpp',
'../src/image/SkImage_Codec.cpp',
],
'dependencies': [
'skia_base_libs.gyp:skia_base_libs',
'effects.gyp:effects',
'flags.gyp:flags',
'images.gyp:images',
],
},
{
'target_name': 'skimage',
'type': 'executable',
'sources': [
'../tools/skimage_main.cpp',
],
'include_dirs': [
# For SkBitmapHasher.h
'../src/utils/',
],
'dependencies': [
'skia_base_libs.gyp:skia_base_libs',
'effects.gyp:effects',
'flags.gyp:flags',
'gm.gyp:gm_expectations',
'images.gyp:images',
'jsoncpp.gyp:jsoncpp',
'utils.gyp:utils',
],
},
{
'target_name': 'lua_pictures',
'type': 'executable',
'sources': [
'../tools/lua/lua_pictures.cpp',
'../src/utils/SkLuaCanvas.cpp',
],
'dependencies': [
'skia_base_libs.gyp:skia_base_libs',
'effects.gyp:effects',
'utils.gyp:utils',
'images.gyp:images',
'tools.gyp:picture_renderer',
'tools.gyp:picture_utils',
'ports.gyp:ports',
'flags.gyp:flags',
'lua.gyp:lua',
],
},
{
'target_name': 'render_pictures',
'type': 'executable',
'sources': [
'../tools/render_pictures_main.cpp',
],
'include_dirs': [
'../src/pipe/utils/',
],
'dependencies': [
'skia_base_libs.gyp:skia_base_libs',
'tools.gyp:picture_renderer',
'tools.gyp:picture_utils',
'ports.gyp:ports',
'flags.gyp:flags',
],
},
{
'target_name': 'bench_pictures',
'type': 'executable',
'sources': [
'../bench/SkBenchLogger.h',
'../bench/SkBenchLogger.cpp',
'../bench/TimerData.h',
'../bench/TimerData.cpp',
'../tools/bench_pictures_main.cpp',
'../tools/PictureBenchmark.cpp',
],
'include_dirs': [
'../bench',
'../src/lazy/',
],
'dependencies': [
'skia_base_libs.gyp:skia_base_libs',
'effects.gyp:effects',
'tools.gyp:picture_utils',
'tools.gyp:picture_renderer',
'bench.gyp:bench_timer',
'ports.gyp:ports',
'flags.gyp:flags',
],
},
{
'target_name': 'picture_renderer',
'type': 'static_library',
'sources': [
'../tools/PictureRenderer.h',
'../tools/PictureRenderer.cpp',
'../tools/PictureRenderingFlags.h',
'../tools/PictureRenderingFlags.cpp',
'../tools/CopyTilesRenderer.h',
'../tools/CopyTilesRenderer.cpp',
'../src/pipe/utils/SamplePipeControllers.h',
'../src/pipe/utils/SamplePipeControllers.cpp',
],
'include_dirs': [
'../src/core/',
'../src/pipe/utils/',
'../src/utils/',
],
'dependencies': [
'skia_base_libs.gyp:skia_base_libs',
'effects.gyp:effects',
'images.gyp:images',
'tools.gyp:picture_utils',
'flags.gyp:flags',
],
'conditions': [
['skia_gpu == 1',
{
'include_dirs' : [
'../src/gpu',
],
},
],
],
'export_dependent_settings': [
'images.gyp:images',
],
},
{
'target_name': 'render_pdfs',
'type': 'executable',
'sources': [
'../tools/render_pdfs_main.cpp',
'../tools/PdfRenderer.cpp',
'../tools/PdfRenderer.h',
],
'include_dirs': [
'../src/pipe/utils/',
'../src/utils/',
],
'dependencies': [
'core.gyp:core',
'effects.gyp:effects',
'images.gyp:images',
'pdf.gyp:pdf',
'ports.gyp:ports',
'tools.gyp:picture_utils',
],
'conditions': [
['skia_win_debuggers_path and skia_os == "win"',
{
'dependencies': [
'tools.gyp:win_dbghelp',
],
},
],
# VS static libraries don't have a linker option. We must set a global
# project linker option, or add it to each executable.
['skia_win_debuggers_path and skia_os == "win" and '
'skia_arch_width == 64',
{
'msvs_settings': {
'VCLinkerTool': {
'AdditionalDependencies': [
'<(skia_win_debuggers_path)/x64/DbgHelp.lib',
],
},
},
},
],
['skia_win_debuggers_path and skia_os == "win" and '
'skia_arch_width == 32',
{
'msvs_settings': {
'VCLinkerTool': {
'AdditionalDependencies': [
'<(skia_win_debuggers_path)/DbgHelp.lib',
],
},
},
},
],
],
},
{
'target_name': 'picture_utils',
'type': 'static_library',
'sources': [
'../tools/picture_utils.cpp',
'../tools/picture_utils.h',
],
'dependencies': [
'skia_base_libs.gyp:skia_base_libs',
],
'direct_dependent_settings': {
'include_dirs': [
'../tools/',
],
},
},
{
'target_name': 'pinspect',
'type': 'executable',
'sources': [
'../tools/pinspect.cpp',
],
'dependencies': [
'skia_base_libs.gyp:skia_base_libs',
'effects.gyp:effects',
'images.gyp:images',
],
},
{
'target_name': 'filter',
'type': 'executable',
'include_dirs' : [
'../src/core',
'../debugger',
],
'sources': [
'../tools/filtermain.cpp',
'../tools/path_utils.h',
'../tools/path_utils.cpp',
'../debugger/SkDrawCommand.h',
'../debugger/SkDrawCommand.cpp',
'../debugger/SkDebugCanvas.h',
'../debugger/SkDebugCanvas.cpp',
'../debugger/SkObjectParser.h',
'../debugger/SkObjectParser.cpp',
],
'dependencies': [
'skia_base_libs.gyp:skia_base_libs',
'effects.gyp:effects',
'images.gyp:images',
'tools.gyp:picture_utils',
],
},
],
'conditions': [
['skia_win_debuggers_path and skia_os == "win"',
{
'targets': [
{
'target_name': 'win_dbghelp',
'type': 'static_library',
'defines': [
'SK_CDB_PATH="<(skia_win_debuggers_path)"',
],
'sources': [
'../tools/win_dbghelp.h',
'../tools/win_dbghelp.cpp',
],
},
],
},
],
['skia_os == "win"',
{
'targets': [
{
'target_name': 'win_lcid',
'type': 'executable',
'sources': [
'../tools/win_lcid.cpp',
],
},
],
},
],
],
}
# Local Variables:
# tab-width:2
# indent-tabs-mode:nil
# End:
# vim: set expandtab tabstop=2 shiftwidth=2: