2011-07-28 14:24:55 +00:00
|
|
|
# Copyright 2011 The Android Open Source Project
|
2011-04-11 15:59:47 +00:00
|
|
|
#
|
2011-07-28 14:24:55 +00:00
|
|
|
# Use of this source code is governed by a BSD-style license that can be
|
|
|
|
# found in the LICENSE file.
|
2012-03-16 13:52:49 +00:00
|
|
|
#
|
|
|
|
# This file is automatically included by gyp_skia when building any target.
|
|
|
|
|
2011-04-11 15:59:47 +00:00
|
|
|
{
|
2012-03-16 18:28:24 +00:00
|
|
|
'includes': [
|
|
|
|
'common_variables.gypi',
|
|
|
|
],
|
2012-03-16 13:52:49 +00:00
|
|
|
|
2011-07-01 17:16:26 +00:00
|
|
|
'target_defaults': {
|
2012-07-30 20:40:50 +00:00
|
|
|
'defines': [
|
2014-04-24 21:51:58 +00:00
|
|
|
'SK_INTERNAL',
|
2012-07-30 20:40:50 +00:00
|
|
|
'SK_GAMMA_SRGB',
|
|
|
|
'SK_GAMMA_APPLY_TO_A8',
|
2016-03-01 17:34:38 +00:00
|
|
|
'QT_NO_KEYWORDS',
|
2016-03-25 16:48:45 +00:00
|
|
|
# The discardable resource cache is tested via a special bot. This is
|
|
|
|
# disabled here so we test the non-discardable use case.
|
|
|
|
# 'SK_USE_DISCARDABLE_SCALEDIMAGECACHE',
|
2012-07-30 20:40:50 +00:00
|
|
|
],
|
2011-07-01 17:16:26 +00:00
|
|
|
|
2011-07-01 20:20:07 +00:00
|
|
|
# Validate the 'skia_os' setting against 'OS', because only certain
|
|
|
|
# combinations work. You should only override 'skia_os' for certain
|
|
|
|
# situations, like building for iOS on a Mac.
|
2011-07-01 17:16:26 +00:00
|
|
|
'variables': {
|
2011-07-01 20:20:07 +00:00
|
|
|
'conditions': [
|
2016-04-29 21:01:34 +00:00
|
|
|
[ 'skia_os != OS and not (skia_os == "ios" and OS == "mac")', {
|
2012-11-01 17:43:44 +00:00
|
|
|
'error': '<!(Cannot build with skia_os=<(skia_os) on OS=<(OS))',
|
2012-04-02 20:42:26 +00:00
|
|
|
}],
|
2012-11-01 17:43:44 +00:00
|
|
|
[ 'skia_mesa and skia_os not in ["mac", "linux"]', {
|
|
|
|
'error': '<!(skia_mesa=1 only supported with skia_os="mac" or "linux".)',
|
|
|
|
}],
|
2015-10-28 15:42:29 +00:00
|
|
|
[ 'skia_angle and not (skia_os == "win" or skia_os == "linux" or skia_os == "mac")', {
|
|
|
|
'error': '<!(skia_angle=1 only supported with skia_os="win" or skia_os="linux" or skia_os="mac".)',
|
2012-11-01 17:43:44 +00:00
|
|
|
}],
|
2011-07-01 20:20:07 +00:00
|
|
|
],
|
2011-07-01 17:16:26 +00:00
|
|
|
},
|
2011-09-15 14:24:33 +00:00
|
|
|
'includes': [
|
2012-03-16 18:28:24 +00:00
|
|
|
'common_conditions.gypi',
|
2011-09-15 14:24:33 +00:00
|
|
|
],
|
|
|
|
'conditions': [
|
2011-10-19 20:43:20 +00:00
|
|
|
[ 'skia_mesa', {
|
|
|
|
'defines': [
|
|
|
|
'SK_MESA',
|
|
|
|
],
|
|
|
|
'direct_dependent_settings': {
|
|
|
|
'defines': [
|
|
|
|
'SK_MESA',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
}],
|
2012-04-02 20:42:26 +00:00
|
|
|
[ 'skia_angle', {
|
|
|
|
'defines': [
|
|
|
|
'SK_ANGLE',
|
|
|
|
],
|
|
|
|
'direct_dependent_settings': {
|
|
|
|
'defines': [
|
|
|
|
'SK_ANGLE',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
}],
|
2015-08-12 19:58:13 +00:00
|
|
|
[ 'skia_vulkan', {
|
|
|
|
'defines': [
|
|
|
|
'SK_VULKAN',
|
|
|
|
],
|
|
|
|
'direct_dependent_settings': {
|
|
|
|
'defines': [
|
|
|
|
'SK_VULKAN',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
}],
|
2015-08-27 17:38:39 +00:00
|
|
|
[ 'skia_command_buffer', {
|
|
|
|
'defines': [
|
|
|
|
'SK_COMMAND_BUFFER',
|
|
|
|
],
|
|
|
|
'direct_dependent_settings': {
|
|
|
|
'defines': [
|
|
|
|
'SK_COMMAND_BUFFER',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
}],
|
2013-03-08 18:00:16 +00:00
|
|
|
[ 'skia_win_debuggers_path and skia_os == "win"',
|
|
|
|
{
|
|
|
|
'defines': [
|
|
|
|
'SK_USE_CDB',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
],
|
2014-02-05 16:35:12 +00:00
|
|
|
[ 'skia_android_framework==0', {
|
|
|
|
# These defines are not used for skia_android_framework, where we build
|
|
|
|
# one makefile and allow someone to add SK_DEBUG etc for their own
|
|
|
|
# debugging purposes.
|
|
|
|
'configurations': {
|
2016-04-29 13:41:35 +00:00
|
|
|
'Debug': { 'defines': [ 'SK_DEBUG=1' ] },
|
2014-08-20 14:38:46 +00:00
|
|
|
'Release': { 'defines': [ 'NDEBUG' ] },
|
2014-02-05 16:35:12 +00:00
|
|
|
'Release_Developer': {
|
|
|
|
'inherit_from': ['Release'],
|
2016-04-29 13:41:35 +00:00
|
|
|
'defines': [ 'SK_DEBUG=1' ],
|
2016-04-29 20:53:05 +00:00
|
|
|
'conditions': [
|
|
|
|
[ 'skia_clang_build == 0', {
|
|
|
|
# gcc has problems providing useful warnings of these types for
|
|
|
|
# optimized builds.
|
|
|
|
'cflags': [
|
2016-05-02 13:06:02 +00:00
|
|
|
'-Wno-array-bounds',
|
2016-04-29 20:53:05 +00:00
|
|
|
'-Wno-maybe-uninitialized',
|
|
|
|
'-Wno-strict-overflow',
|
|
|
|
],
|
|
|
|
}],
|
|
|
|
],
|
2014-02-05 16:35:12 +00:00
|
|
|
},
|
|
|
|
},
|
|
|
|
}],
|
2011-09-15 14:24:33 +00:00
|
|
|
],
|
2011-07-01 17:16:26 +00:00
|
|
|
}, # end 'target_defaults'
|
2011-04-11 15:59:47 +00:00
|
|
|
}
|