2015-08-17 19:58:10 +00:00
|
|
|
# Description:
|
|
|
|
# Skia graphics library.
|
|
|
|
#
|
|
|
|
# Definitions for Google BUILD file.
|
|
|
|
|
|
|
|
exports_files(["BUILD.public"])
|
|
|
|
|
2015-11-18 21:26:10 +00:00
|
|
|
# All platform-independent SRCS.
|
|
|
|
BASE_SRCS = glob(
|
2015-08-17 19:58:10 +00:00
|
|
|
[
|
2015-08-18 15:51:49 +00:00
|
|
|
"include/private/*.h",
|
2015-10-15 15:09:44 +00:00
|
|
|
"src/**/*.h",
|
|
|
|
"src/**/*.cpp",
|
2015-08-17 19:58:10 +00:00
|
|
|
|
2015-08-18 15:51:49 +00:00
|
|
|
# Third Party
|
2015-08-17 19:58:10 +00:00
|
|
|
"third_party/etc1/*.cpp",
|
2015-10-15 15:09:44 +00:00
|
|
|
"third_party/etc1/*.h",
|
2015-08-17 19:58:10 +00:00
|
|
|
"third_party/ktx/*.cpp",
|
2015-10-15 15:09:44 +00:00
|
|
|
"third_party/ktx/*.h",
|
2015-08-17 19:58:10 +00:00
|
|
|
],
|
|
|
|
exclude = [
|
2015-10-15 15:09:44 +00:00
|
|
|
# Exclude platform-dependent files.
|
|
|
|
"src/device/xps/*", # Windows-only. Move to ports?
|
|
|
|
"src/doc/*_XPS.cpp", # Windows-only. Move to ports?
|
2015-12-01 19:12:05 +00:00
|
|
|
"src/fonts/SkFontMgr_fontconfig.cpp",
|
2015-10-15 15:09:44 +00:00
|
|
|
"src/gpu/gl/android/*",
|
2015-10-26 17:46:25 +00:00
|
|
|
"src/gpu/gl/egl/*",
|
|
|
|
"src/gpu/gl/glx/*",
|
2015-10-15 15:09:44 +00:00
|
|
|
"src/gpu/gl/iOS/*",
|
|
|
|
"src/gpu/gl/mac/*",
|
|
|
|
"src/gpu/gl/win/*",
|
|
|
|
"src/opts/**/*",
|
|
|
|
"src/ports/**/*",
|
|
|
|
"src/utils/android/**/*",
|
|
|
|
"src/utils/mac/**/*",
|
|
|
|
"src/utils/SkThreadUtils_win.cpp", # Windows-only. Move to ports?
|
|
|
|
"src/utils/win/**/*",
|
|
|
|
"src/views/sdl/*",
|
|
|
|
"src/views/win/*",
|
|
|
|
"src/views/unix/*",
|
|
|
|
|
|
|
|
# Exclude multiple definitions.
|
|
|
|
# TODO(mtklein): Move to opts?
|
2015-08-18 15:51:49 +00:00
|
|
|
"src/doc/SkDocument_PDF_None.cpp", # We use SkDocument_PDF.cpp.
|
2015-10-26 17:46:25 +00:00
|
|
|
"src/gpu/gl/GrGLCreateNativeInterface_none.cpp",
|
|
|
|
"src/gpu/gl/GrGLDefaultInterface_native.cpp",
|
2015-10-15 15:09:44 +00:00
|
|
|
|
|
|
|
# Exclude files that don't compile with the current DEFINES.
|
2015-10-27 16:14:29 +00:00
|
|
|
"src/codec/SkJpegCodec.cpp", # libjpeg_turbo version mismatch.
|
2015-10-15 15:09:44 +00:00
|
|
|
"src/gpu/gl/angle/*", # Requires SK_ANGLE define.
|
|
|
|
"src/gpu/gl/command_buffer/*", # unknown type name 'HMODULE'
|
|
|
|
"src/gpu/gl/mesa/*", # Requires SK_MESA define.
|
|
|
|
"src/svg/parser/*", # Missing SkSVG.h.
|
|
|
|
|
2015-11-18 21:26:10 +00:00
|
|
|
# Conflicting dependencies among Lua versions. See cl/107087297.
|
|
|
|
"src/utils/SkLua*",
|
|
|
|
|
2015-10-15 15:09:44 +00:00
|
|
|
# Not used.
|
|
|
|
"src/animator/**/*",
|
|
|
|
"src/views/**/*",
|
|
|
|
"src/xml/SkBML_Verbs.h",
|
|
|
|
"src/xml/SkBML_XMLParser.cpp",
|
|
|
|
"src/xml/SkXMLPullParser.cpp",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
|
|
|
# Platform-dependent SRCS for google3-default platform.
|
2015-11-18 21:26:10 +00:00
|
|
|
BASE_SRCS_UNIX = glob(
|
2015-10-15 15:09:44 +00:00
|
|
|
[
|
2015-12-01 19:12:05 +00:00
|
|
|
"src/fonts/SkFontMgr_fontconfig.cpp",
|
2015-10-15 15:09:44 +00:00
|
|
|
"src/opts/**/*.cpp",
|
|
|
|
"src/opts/**/*.h",
|
|
|
|
"src/ports/**/*.cpp",
|
|
|
|
"src/ports/**/*.h",
|
|
|
|
],
|
|
|
|
exclude = [
|
|
|
|
"src/opts/*arm*",
|
|
|
|
"src/opts/*mips*",
|
|
|
|
"src/opts/*NEON*",
|
|
|
|
"src/opts/*neon*",
|
2015-10-26 17:46:25 +00:00
|
|
|
# Included in :opts_ssse3 library.
|
2015-10-15 15:09:44 +00:00
|
|
|
"src/opts/*SSSE3*",
|
|
|
|
"src/opts/*ssse3*",
|
2015-10-26 17:46:25 +00:00
|
|
|
# Included in :opts_sse4 library.
|
2015-10-15 15:09:44 +00:00
|
|
|
"src/opts/*SSE4*",
|
|
|
|
"src/opts/*sse4*",
|
|
|
|
"src/opts/SkBitmapProcState_opts_none.cpp",
|
2015-10-26 17:46:25 +00:00
|
|
|
"src/opts/SkBlitMask_opts_none.cpp",
|
2015-10-15 15:09:44 +00:00
|
|
|
"src/opts/SkBlitRow_opts_none.cpp",
|
|
|
|
"src/ports/*android*",
|
|
|
|
"src/ports/*chromium*",
|
|
|
|
"src/ports/*mac*",
|
|
|
|
"src/ports/*mozalloc*",
|
|
|
|
"src/ports/*nacl*",
|
|
|
|
"src/ports/*win*",
|
2015-12-01 19:12:05 +00:00
|
|
|
"src/ports/SkFontConfigInterface_direct_factory.cpp",
|
|
|
|
"src/ports/SkFontMgr_custom_directory_factory.cpp",
|
2015-10-15 15:09:44 +00:00
|
|
|
"src/ports/SkFontMgr_custom_embedded_factory.cpp",
|
|
|
|
"src/ports/SkFontMgr_empty_factory.cpp",
|
2015-12-03 13:04:03 +00:00
|
|
|
"src/ports/SkFontMgr_fontconfig.cpp",
|
2015-11-02 13:53:38 +00:00
|
|
|
"src/ports/SkImageDecoder_CG.cpp",
|
2015-12-01 19:12:05 +00:00
|
|
|
"src/ports/SkFontMgr_fontconfig_factory.cpp",
|
2015-10-15 15:09:44 +00:00
|
|
|
"src/ports/SkImageDecoder_WIC.cpp",
|
|
|
|
"src/ports/SkImageDecoder_empty.cpp",
|
|
|
|
"src/ports/SkImageGenerator_none.cpp",
|
|
|
|
"src/ports/SkTLS_none.cpp",
|
2015-08-18 15:51:49 +00:00
|
|
|
],
|
|
|
|
)
|
|
|
|
|
2015-10-26 17:46:25 +00:00
|
|
|
# Platform-dependent SRCS for google3-default Android.
|
2015-11-18 21:26:10 +00:00
|
|
|
BASE_SRCS_ANDROID = glob(
|
2015-10-26 17:46:25 +00:00
|
|
|
[
|
|
|
|
# TODO(benjaminwagner): Figure out how to compile with EGL.
|
|
|
|
"src/opts/**/*.cpp",
|
|
|
|
"src/opts/**/*.h",
|
|
|
|
"src/ports/**/*.cpp",
|
|
|
|
"src/ports/**/*.h",
|
|
|
|
],
|
|
|
|
exclude = [
|
|
|
|
"src/opts/*mips*",
|
|
|
|
"src/opts/*SSE2*",
|
|
|
|
"src/opts/*SSSE3*",
|
|
|
|
"src/opts/*ssse3*",
|
|
|
|
"src/opts/*SSE4*",
|
|
|
|
"src/opts/*sse4*",
|
|
|
|
"src/opts/*x86*",
|
|
|
|
"src/opts/SkBitmapProcState_opts_none.cpp",
|
|
|
|
"src/opts/SkBlitMask_opts_none.cpp",
|
|
|
|
"src/opts/SkBlitRow_opts_none.cpp",
|
|
|
|
"src/ports/*chromium*",
|
|
|
|
"src/ports/*fontconfig*",
|
|
|
|
"src/ports/*FontConfig*",
|
|
|
|
"src/ports/*mac*",
|
|
|
|
"src/ports/*mozalloc*",
|
|
|
|
"src/ports/*nacl*",
|
|
|
|
"src/ports/*win*",
|
|
|
|
"src/ports/SkDebug_stdio.cpp",
|
2015-12-01 19:12:05 +00:00
|
|
|
"src/ports/SkFontConfigInterface_direct_factory.cpp",
|
|
|
|
"src/ports/SkFontConfigInterface_direct_google3_factory.cpp",
|
2015-10-26 17:46:25 +00:00
|
|
|
"src/ports/SkFontMgr_custom_directory_factory.cpp",
|
|
|
|
"src/ports/SkFontMgr_custom_embedded_factory.cpp",
|
|
|
|
"src/ports/SkFontMgr_empty_factory.cpp",
|
2015-11-02 13:53:38 +00:00
|
|
|
"src/ports/SkImageDecoder_CG.cpp",
|
2015-10-26 17:46:25 +00:00
|
|
|
"src/ports/SkImageDecoder_WIC.cpp",
|
|
|
|
"src/ports/SkImageDecoder_empty.cpp",
|
|
|
|
"src/ports/SkImageGenerator_none.cpp",
|
|
|
|
"src/ports/SkTLS_none.cpp",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
2015-11-02 19:11:21 +00:00
|
|
|
# Platform-dependent SRCS for google3-default iOS.
|
2015-11-18 21:26:10 +00:00
|
|
|
BASE_SRCS_IOS = glob(
|
2015-11-02 19:11:21 +00:00
|
|
|
[
|
|
|
|
"src/opts/**/*.cpp",
|
|
|
|
"src/opts/**/*.h",
|
|
|
|
"src/ports/**/*.cpp",
|
|
|
|
"src/ports/**/*.h",
|
|
|
|
],
|
|
|
|
exclude = [
|
|
|
|
"src/opts/*mips*",
|
|
|
|
"src/opts/*NEON*",
|
|
|
|
"src/opts/*neon*",
|
|
|
|
"src/opts/*SSE2*",
|
|
|
|
"src/opts/*SSSE3*",
|
|
|
|
"src/opts/*ssse3*",
|
|
|
|
"src/opts/*SSE4*",
|
|
|
|
"src/opts/*sse4*",
|
|
|
|
"src/opts/*x86*",
|
|
|
|
"src/opts/SkBitmapProcState_opts_none.cpp",
|
|
|
|
"src/opts/SkBlitMask_opts_none.cpp",
|
|
|
|
"src/opts/SkBlitRow_opts_none.cpp",
|
|
|
|
"src/ports/*android*",
|
|
|
|
"src/ports/*chromium*",
|
|
|
|
"src/ports/*fontconfig*",
|
|
|
|
"src/ports/*FontConfig*",
|
|
|
|
"src/ports/*FreeType*",
|
|
|
|
"src/ports/*mozalloc*",
|
|
|
|
"src/ports/*nacl*",
|
|
|
|
"src/ports/*win*",
|
|
|
|
"src/ports/SkDebug_stdio.cpp",
|
|
|
|
"src/ports/SkFontMgr_custom.cpp",
|
2015-12-01 19:12:05 +00:00
|
|
|
"src/ports/SkFontConfigInterface_direct_factory.cpp",
|
|
|
|
"src/ports/SkFontConfigInterface_direct_google3_factory.cpp",
|
2015-11-02 19:11:21 +00:00
|
|
|
"src/ports/SkFontMgr_custom_directory_factory.cpp",
|
|
|
|
"src/ports/SkFontMgr_custom_embedded_factory.cpp",
|
|
|
|
"src/ports/SkFontMgr_empty_factory.cpp",
|
|
|
|
"src/ports/SkImageDecoder_CG.cpp",
|
|
|
|
"src/ports/SkImageDecoder_WIC.cpp",
|
|
|
|
"src/ports/SkImageDecoder_empty.cpp",
|
|
|
|
"src/ports/SkImageGenerator_none.cpp",
|
|
|
|
"src/ports/SkTLS_none.cpp",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
2015-11-18 21:26:10 +00:00
|
|
|
BASE_SRCS_PLATFORM = select({
|
|
|
|
CONDITION_ANDROID: BASE_SRCS_ANDROID,
|
|
|
|
CONDITION_IOS: BASE_SRCS_IOS,
|
|
|
|
"//conditions:default": BASE_SRCS_UNIX,
|
2015-10-26 17:46:25 +00:00
|
|
|
})
|
|
|
|
|
2015-11-18 21:26:10 +00:00
|
|
|
SSSE3_SRCS = glob(
|
2015-08-18 15:51:49 +00:00
|
|
|
[
|
|
|
|
"src/opts/*SSSE3*.cpp",
|
|
|
|
"src/opts/*ssse3*.cpp",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
2015-11-18 21:26:10 +00:00
|
|
|
SSE4_SRCS = glob(
|
2015-08-18 15:51:49 +00:00
|
|
|
[
|
|
|
|
"src/opts/*SSE4*.cpp",
|
|
|
|
"src/opts/*sse4*.cpp",
|
2015-08-17 19:58:10 +00:00
|
|
|
],
|
|
|
|
)
|
|
|
|
|
2015-11-18 21:26:10 +00:00
|
|
|
BASE_HDRS = glob(
|
2015-08-17 19:58:10 +00:00
|
|
|
[
|
|
|
|
"include/**/*.h",
|
|
|
|
],
|
2015-08-18 15:51:49 +00:00
|
|
|
exclude = [
|
2015-10-15 15:09:44 +00:00
|
|
|
"include/private/**/*",
|
|
|
|
|
|
|
|
# Not used.
|
|
|
|
"include/animator/**/*",
|
|
|
|
"include/views/**/*",
|
|
|
|
"include/xml/SkBML_WXMLParser.h",
|
|
|
|
"include/xml/SkBML_XMLParser.h",
|
2015-08-18 15:51:49 +00:00
|
|
|
],
|
2015-08-17 19:58:10 +00:00
|
|
|
)
|
|
|
|
|
2015-11-18 21:26:10 +00:00
|
|
|
# Dependencies.
|
|
|
|
BASE_DEPS_UNIX = [
|
|
|
|
":opts_sse4",
|
|
|
|
":opts_ssse3",
|
|
|
|
]
|
|
|
|
|
|
|
|
BASE_DEPS_ANDROID = []
|
|
|
|
|
|
|
|
BASE_DEPS_IOS = []
|
|
|
|
|
|
|
|
BASE_DEPS = select({
|
|
|
|
CONDITION_ANDROID: BASE_DEPS_ANDROID + BASE_EXTERNAL_DEPS_ANDROID,
|
|
|
|
CONDITION_IOS: BASE_DEPS_IOS + BASE_EXTERNAL_DEPS_IOS,
|
|
|
|
"//conditions:default": BASE_DEPS_UNIX + BASE_EXTERNAL_DEPS_UNIX,
|
|
|
|
}) + EXTERNAL_DEPS_ALL
|
|
|
|
|
2015-08-17 19:58:10 +00:00
|
|
|
# Includes needed by Skia implementation. Not public includes.
|
|
|
|
INCLUDES = [
|
2015-11-13 20:27:08 +00:00
|
|
|
"include/android",
|
2015-08-17 19:58:10 +00:00
|
|
|
"include/c",
|
|
|
|
"include/codec",
|
|
|
|
"include/config",
|
|
|
|
"include/core",
|
|
|
|
"include/effects",
|
|
|
|
"include/gpu",
|
|
|
|
"include/images",
|
|
|
|
"include/pathops",
|
|
|
|
"include/pipe",
|
|
|
|
"include/ports",
|
|
|
|
"include/private",
|
|
|
|
"include/utils",
|
2015-11-02 19:11:21 +00:00
|
|
|
"include/utils/mac",
|
|
|
|
"include/utils/win",
|
2015-10-15 15:09:44 +00:00
|
|
|
"include/svg",
|
2015-08-17 19:58:10 +00:00
|
|
|
"include/xml",
|
2015-11-13 20:27:08 +00:00
|
|
|
"src/codec",
|
2015-08-17 19:58:10 +00:00
|
|
|
"src/core",
|
|
|
|
"src/gpu",
|
|
|
|
"src/image",
|
|
|
|
"src/lazy",
|
|
|
|
"src/opts",
|
2015-12-01 19:12:05 +00:00
|
|
|
"src/ports",
|
2015-08-17 19:58:10 +00:00
|
|
|
"src/pdf",
|
|
|
|
"src/sfnt",
|
|
|
|
"src/utils",
|
|
|
|
"third_party/etc1",
|
|
|
|
"third_party/ktx",
|
2015-12-01 19:12:05 +00:00
|
|
|
] + EXTERNAL_INCLUDES
|
2015-08-17 19:58:10 +00:00
|
|
|
|
2015-11-18 21:26:10 +00:00
|
|
|
## :dm
|
2015-10-26 17:46:25 +00:00
|
|
|
|
|
|
|
# Platform-independent SRCS for DM.
|
2015-10-15 15:09:44 +00:00
|
|
|
DM_SRCS = glob(
|
|
|
|
[
|
|
|
|
"dm/*.cpp",
|
|
|
|
"dm/*.h",
|
|
|
|
"gm/*.c",
|
|
|
|
"gm/*.cpp",
|
|
|
|
"gm/*.h",
|
|
|
|
"tests/*.cpp",
|
|
|
|
"tests/*.h",
|
|
|
|
"tools/CrashHandler.cpp",
|
|
|
|
"tools/CrashHandler.h",
|
|
|
|
"tools/LazyDecodeBitmap.cpp",
|
|
|
|
"tools/LazyDecodeBitmap.h",
|
|
|
|
"tools/ProcStats.cpp",
|
|
|
|
"tools/ProcStats.h",
|
|
|
|
"tools/Resources.cpp",
|
|
|
|
"tools/Resources.h",
|
2015-10-24 14:55:31 +00:00
|
|
|
"tools/SkBitmapRegionCanvas.cpp",
|
|
|
|
"tools/SkBitmapRegionCanvas.h",
|
|
|
|
"tools/SkBitmapRegionCodec.cpp",
|
|
|
|
"tools/SkBitmapRegionCodec.h",
|
2015-11-06 16:56:32 +00:00
|
|
|
"tools/SkBitmapRegionDecoder.cpp",
|
|
|
|
"tools/SkBitmapRegionDecoder.h",
|
2015-10-15 15:09:44 +00:00
|
|
|
"tools/SkBitmapRegionSampler.cpp",
|
|
|
|
"tools/SkBitmapRegionSampler.h",
|
|
|
|
"tools/flags/*.cpp",
|
|
|
|
"tools/flags/*.h",
|
|
|
|
"tools/sk_tool_utils.cpp",
|
|
|
|
"tools/sk_tool_utils.h",
|
2015-10-24 14:55:31 +00:00
|
|
|
"tools/sk_tool_utils_font.cpp",
|
|
|
|
"tools/timer/*.cpp",
|
|
|
|
"tools/timer/*.h",
|
2015-10-15 15:09:44 +00:00
|
|
|
],
|
|
|
|
exclude = [
|
2015-10-26 17:46:25 +00:00
|
|
|
"dm/DMSrcSinkAndroid.cpp", # Android-only.
|
|
|
|
"tests/FontMgrAndroidParserTest.cpp", # Android-only.
|
|
|
|
"tests/PathOpsSkpClipTest.cpp", # Alternate main.
|
2015-10-15 15:09:44 +00:00
|
|
|
"tests/skia_test.cpp", # Old main.
|
|
|
|
"tests/SkpSkGrTest.cpp", # Alternate main.
|
|
|
|
"tools/timer/SysTimer_mach.cpp",
|
2015-10-26 17:46:25 +00:00
|
|
|
"tools/timer/SysTimer_windows.cpp",
|
2015-10-15 15:09:44 +00:00
|
|
|
],
|
|
|
|
)
|
|
|
|
|
2015-10-26 17:46:25 +00:00
|
|
|
DM_SRCS_UNIX = []
|
|
|
|
|
|
|
|
DM_SRCS_ANDROID = glob(
|
|
|
|
[
|
|
|
|
# Depends on Android HWUI library that is not available in google3.
|
|
|
|
#"dm/DMSrcSinkAndroid.cpp",
|
|
|
|
"tests/FontMgrAndroidParserTest.cpp",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
|
|
|
DM_PLATFORM_SRCS = select({
|
|
|
|
CONDITION_ANDROID: DM_SRCS_ANDROID,
|
|
|
|
"//conditions:default": DM_SRCS_UNIX,
|
|
|
|
})
|
|
|
|
|
2015-10-15 15:09:44 +00:00
|
|
|
DM_INCLUDES = [
|
|
|
|
"gm",
|
|
|
|
"src/codec",
|
|
|
|
"src/effects",
|
|
|
|
"src/fonts",
|
|
|
|
"src/pathops",
|
|
|
|
"src/pipe/utils",
|
2015-10-26 17:46:25 +00:00
|
|
|
"src/ports",
|
2015-10-15 15:09:44 +00:00
|
|
|
"src/utils/debugger",
|
|
|
|
"tests",
|
|
|
|
"tools",
|
|
|
|
"tools/flags",
|
|
|
|
"tools/timer",
|
|
|
|
]
|
|
|
|
|
2015-11-18 21:26:10 +00:00
|
|
|
COPTS_ANDROID = ["-mfpu=neon"]
|
2015-10-26 17:46:25 +00:00
|
|
|
|
2015-11-18 21:26:10 +00:00
|
|
|
COPTS_IOS = []
|
2015-11-02 19:11:21 +00:00
|
|
|
|
2015-10-26 17:46:25 +00:00
|
|
|
COPTS_UNIX = [
|
2015-08-17 19:58:10 +00:00
|
|
|
"-Wno-implicit-fallthrough", # Some intentional fallthrough.
|
2015-10-19 20:55:55 +00:00
|
|
|
"-Wno-deprecated-declarations", # Internal use of deprecated methods. :(
|
2015-08-17 19:58:10 +00:00
|
|
|
]
|
|
|
|
|
2015-10-26 17:46:25 +00:00
|
|
|
COPTS = select({
|
|
|
|
CONDITION_ANDROID: COPTS_ANDROID,
|
2015-11-02 19:11:21 +00:00
|
|
|
CONDITION_IOS: COPTS_IOS,
|
2015-10-26 17:46:25 +00:00
|
|
|
"//conditions:default": COPTS_UNIX,
|
|
|
|
})
|
|
|
|
|
|
|
|
DEFINES_ANDROID = [
|
|
|
|
"SK_BUILD_FOR_ANDROID",
|
|
|
|
# TODO(benjaminwagner): Try to get png library updated?
|
|
|
|
"SK_PNG_NO_INDEX_SUPPORTED",
|
|
|
|
]
|
|
|
|
|
2015-11-02 19:11:21 +00:00
|
|
|
DEFINES_IOS = [
|
|
|
|
"SK_BUILD_FOR_IOS",
|
|
|
|
"SK_IGNORE_ETC1_SUPPORT",
|
|
|
|
]
|
|
|
|
|
2015-10-26 17:46:25 +00:00
|
|
|
DEFINES_UNIX = [
|
|
|
|
"SK_BUILD_FOR_UNIX",
|
|
|
|
"SK_SAMPLES_FOR_X",
|
|
|
|
]
|
|
|
|
|
|
|
|
DEFINES_ALL = [
|
2015-08-17 19:58:10 +00:00
|
|
|
# Chrome DEFINES.
|
|
|
|
"SK_USE_FLOATBITS",
|
|
|
|
"SK_USE_FREETYPE_EMBOLDEN",
|
|
|
|
# Turn on a few Google3-specific build fixes.
|
|
|
|
"GOOGLE3",
|
|
|
|
]
|
|
|
|
|
2015-10-26 17:46:25 +00:00
|
|
|
DEFINES = select({
|
|
|
|
CONDITION_ANDROID: DEFINES_ANDROID,
|
2015-11-02 19:11:21 +00:00
|
|
|
CONDITION_IOS: DEFINES_IOS,
|
2015-10-26 17:46:25 +00:00
|
|
|
"//conditions:default": DEFINES_UNIX,
|
|
|
|
}) + DEFINES_ALL
|
|
|
|
|
|
|
|
LINKOPTS = select({
|
|
|
|
CONDITION_ANDROID: [
|
|
|
|
"-ldl",
|
|
|
|
"-lEGL",
|
|
|
|
],
|
|
|
|
"//conditions:default": ["-ldl"],
|
|
|
|
})
|
2015-10-15 15:09:44 +00:00
|
|
|
|
|
|
|
cc_library(
|
|
|
|
name = "opts_ssse3",
|
2015-11-18 21:26:10 +00:00
|
|
|
srcs = SSSE3_SRCS,
|
2015-10-15 15:09:44 +00:00
|
|
|
copts = COPTS + ["-mssse3"],
|
|
|
|
defines = DEFINES,
|
|
|
|
includes = INCLUDES,
|
2015-10-29 20:40:27 +00:00
|
|
|
deps = EXTERNAL_DEPS_ALL,
|
2015-10-15 15:09:44 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
cc_library(
|
|
|
|
name = "opts_sse4",
|
2015-11-18 21:26:10 +00:00
|
|
|
srcs = SSE4_SRCS,
|
2015-10-15 15:09:44 +00:00
|
|
|
copts = COPTS + ["-msse4"],
|
|
|
|
defines = DEFINES,
|
|
|
|
includes = INCLUDES,
|
2015-10-29 20:40:27 +00:00
|
|
|
deps = EXTERNAL_DEPS_ALL,
|
2015-10-15 15:09:44 +00:00
|
|
|
)
|
|
|
|
|
2015-11-18 21:48:47 +00:00
|
|
|
# If you need Ganesh (GPU) support in Skia, please contact skia-team@google.com
|
|
|
|
# for help.
|
2015-10-15 15:09:44 +00:00
|
|
|
cc_library(
|
|
|
|
name = "skia",
|
2015-11-18 21:26:10 +00:00
|
|
|
srcs = BASE_SRCS + BASE_SRCS_PLATFORM,
|
|
|
|
hdrs = BASE_HDRS,
|
2015-10-15 15:09:44 +00:00
|
|
|
copts = COPTS,
|
|
|
|
defines = DEFINES,
|
|
|
|
includes = INCLUDES,
|
|
|
|
linkopts = LINKOPTS,
|
|
|
|
visibility = [":skia_clients"],
|
2015-11-18 21:26:10 +00:00
|
|
|
deps = BASE_DEPS,
|
2015-11-02 13:53:38 +00:00
|
|
|
alwayslink = 1,
|
2015-10-15 15:09:44 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
cc_test(
|
|
|
|
name = "dm",
|
|
|
|
size = "large",
|
2015-10-26 17:46:25 +00:00
|
|
|
srcs = DM_SRCS + DM_PLATFORM_SRCS,
|
2015-10-15 15:09:44 +00:00
|
|
|
args = [
|
|
|
|
"--nogpu",
|
|
|
|
"--verbose",
|
|
|
|
# TODO(mtklein): maybe investigate why these fail?
|
2015-11-20 21:58:18 +00:00
|
|
|
"--match ~FontMgr ~Scalar ~Canvas ~Codec_stripes ~Codec_Dimensions ~Codec ~Stream ~skps ~RecordDraw_TextBounds",
|
2015-10-15 15:09:44 +00:00
|
|
|
"--resourcePath %s/resources" % BASE_DIR,
|
|
|
|
"--images %s/resources" % BASE_DIR,
|
|
|
|
],
|
|
|
|
copts = COPTS,
|
2015-10-20 20:00:48 +00:00
|
|
|
data = glob(["resources/**/*"]),
|
2015-10-15 15:09:44 +00:00
|
|
|
defines = DEFINES,
|
|
|
|
includes = DM_INCLUDES,
|
|
|
|
deps = DM_EXTERNAL_DEPS + [
|
|
|
|
":skia",
|
2015-10-29 20:40:27 +00:00
|
|
|
] + EXTERNAL_DEPS_ALL,
|
2015-10-15 15:09:44 +00:00
|
|
|
)
|