seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 1 | # conditions used in both common.gypi and skia.gyp in chromium |
| 2 | # |
| 3 | { |
chudy@google.com | bbad34d | 2012-08-13 14:26:36 +0000 | [diff] [blame] | 4 | 'defines': [ |
| 5 | 'SK_ALLOW_STATIC_GLOBAL_INITIALIZERS=<(skia_static_initializers)', |
mtklein@google.com | dad7070 | 2013-11-20 18:06:10 +0000 | [diff] [blame] | 6 | 'SK_SUPPORT_GPU=<(skia_gpu)', |
| 7 | 'SK_SUPPORT_OPENCL=<(skia_opencl)', |
commit-bot@chromium.org | ae79612 | 2014-03-12 17:05:46 +0000 | [diff] [blame] | 8 | 'SK_FORCE_DISTANCEFIELD_FONTS=<(skia_force_distancefield_fonts)', |
chudy@google.com | bbad34d | 2012-08-13 14:26:36 +0000 | [diff] [blame] | 9 | ], |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 10 | 'conditions' : [ |
commit-bot@chromium.org | 6f2d4d4 | 2014-04-02 15:03:56 +0000 | [diff] [blame] | 11 | [ 'skia_arch_type == "arm64"', { |
| 12 | 'cflags': [ |
| 13 | '-ffp-contract=off', |
| 14 | ], |
| 15 | }], |
| 16 | |
borenet@google.com | a72aef8 | 2013-03-22 13:16:06 +0000 | [diff] [blame] | 17 | [ 'skia_os == "win"', |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 18 | { |
| 19 | 'defines': [ |
| 20 | 'SK_BUILD_FOR_WIN32', |
bsalomon@google.com | 8b5abec | 2011-09-28 14:32:01 +0000 | [diff] [blame] | 21 | '_CRT_SECURE_NO_WARNINGS', |
senorblanco@chromium.org | 5f47a39 | 2012-07-12 00:34:39 +0000 | [diff] [blame] | 22 | 'GR_GL_FUNCTION_TYPE=__stdcall', |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 23 | ], |
| 24 | 'msvs_cygwin_shell': 0, |
| 25 | 'msvs_settings': { |
| 26 | 'VCCLCompilerTool': { |
bsalomon@google.com | b58a639 | 2013-03-21 20:29:05 +0000 | [diff] [blame] | 27 | 'WarningLevel': '3', |
| 28 | 'ProgramDataBaseFileName': '$(OutDir)\\$(ProjectName).pdb', |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 29 | 'DebugInformationFormat': '3', |
bsalomon@google.com | b58a639 | 2013-03-21 20:29:05 +0000 | [diff] [blame] | 30 | 'ExceptionHandling': '0', |
| 31 | 'AdditionalOptions': [ '/MP', ], |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 32 | }, |
| 33 | 'VCLinkerTool': { |
| 34 | 'AdditionalDependencies': [ |
| 35 | 'OpenGL32.lib', |
| 36 | 'usp10.lib', |
bungeman@google.com | f51e125 | 2013-06-05 18:35:22 +0000 | [diff] [blame] | 37 | |
| 38 | # Prior to gyp r1584, the following were included automatically. |
| 39 | 'kernel32.lib', |
| 40 | 'gdi32.lib', |
| 41 | 'winspool.lib', |
| 42 | 'comdlg32.lib', |
| 43 | 'advapi32.lib', |
| 44 | 'shell32.lib', |
| 45 | 'ole32.lib', |
| 46 | 'oleaut32.lib', |
| 47 | 'user32.lib', |
| 48 | 'uuid.lib', |
| 49 | 'odbc32.lib', |
| 50 | 'odbccp32.lib', |
bsalomon@google.com | bbba784 | 2013-06-06 18:34:13 +0000 | [diff] [blame] | 51 | 'DelayImp.lib', |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 52 | ], |
| 53 | }, |
| 54 | }, |
| 55 | 'configurations': { |
| 56 | 'Debug': { |
| 57 | 'msvs_settings': { |
| 58 | 'VCCLCompilerTool': { |
bsalomon@google.com | 8b5abec | 2011-09-28 14:32:01 +0000 | [diff] [blame] | 59 | 'DebugInformationFormat': '4', # editAndContiue (/ZI) |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 60 | 'Optimization': '0', # optimizeDisabled (/Od) |
| 61 | 'PreprocessorDefinitions': ['_DEBUG'], |
| 62 | 'RuntimeLibrary': '3', # rtMultiThreadedDebugDLL (/MDd) |
bsalomon@google.com | 8b5abec | 2011-09-28 14:32:01 +0000 | [diff] [blame] | 63 | 'RuntimeTypeInfo': 'false', # /GR- |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 64 | }, |
| 65 | 'VCLinkerTool': { |
bsalomon@google.com | 8b5abec | 2011-09-28 14:32:01 +0000 | [diff] [blame] | 66 | 'GenerateDebugInformation': 'true', # /DEBUG |
| 67 | 'LinkIncremental': '2', # /INCREMENTAL |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 68 | }, |
| 69 | }, |
| 70 | }, |
| 71 | 'Release': { |
| 72 | 'msvs_settings': { |
| 73 | 'VCCLCompilerTool': { |
bsalomon@google.com | 9aabfc7 | 2012-05-31 14:12:46 +0000 | [diff] [blame] | 74 | 'DebugInformationFormat': '3', # programDatabase (/Zi) |
commit-bot@chromium.org | 06b3864 | 2013-06-20 20:28:54 +0000 | [diff] [blame] | 75 | 'Optimization': '<(skia_release_optimization_level)', |
bsalomon@google.com | d971869 | 2013-04-22 14:56:50 +0000 | [diff] [blame] | 76 | 'WholeProgramOptimization': 'true', #/GL |
bsalomon@google.com | 8b5abec | 2011-09-28 14:32:01 +0000 | [diff] [blame] | 77 | # Changing the floating point model requires rebaseling gm images |
bsalomon@google.com | 9aabfc7 | 2012-05-31 14:12:46 +0000 | [diff] [blame] | 78 | #'FloatingPointModel': '2', # fast (/fp:fast) |
| 79 | 'FavorSizeOrSpeed': '1', # speed (/Ot) |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 80 | 'PreprocessorDefinitions': ['NDEBUG'], |
bsalomon@google.com | 9aabfc7 | 2012-05-31 14:12:46 +0000 | [diff] [blame] | 81 | 'RuntimeLibrary': '2', # rtMultiThreadedDLL (/MD) |
bsalomon@google.com | 9aabfc7 | 2012-05-31 14:12:46 +0000 | [diff] [blame] | 82 | 'EnableEnhancedInstructionSet': '2',# /arch:SSE2 |
| 83 | 'RuntimeTypeInfo': 'false', # /GR- |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 84 | }, |
| 85 | 'VCLinkerTool': { |
bsalomon@google.com | 8b5abec | 2011-09-28 14:32:01 +0000 | [diff] [blame] | 86 | 'GenerateDebugInformation': 'true', # /DEBUG |
bsalomon@google.com | d971869 | 2013-04-22 14:56:50 +0000 | [diff] [blame] | 87 | 'LinkTimeCodeGeneration': '1', # useLinkTimeCodeGeneration /LTCG |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 88 | }, |
bungeman@google.com | 983297e | 2011-10-03 19:36:51 +0000 | [diff] [blame] | 89 | 'VCLibrarianTool': { |
bsalomon@google.com | d971869 | 2013-04-22 14:56:50 +0000 | [diff] [blame] | 90 | 'LinkTimeCodeGeneration': 'true', # useLinkTimeCodeGeneration /LTCG |
bungeman@google.com | 983297e | 2011-10-03 19:36:51 +0000 | [diff] [blame] | 91 | }, |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 92 | }, |
| 93 | }, |
epoger@google.com | 58d69d8 | 2014-04-01 07:02:41 +0000 | [diff] [blame] | 94 | # Gyp's ninja generator depends on these specially named |
| 95 | # configurations to build 64-bit on Windows. |
| 96 | # See http://skbug.com/2348 |
| 97 | # |
| 98 | # We handle the 64- vs 32-bit variations elsewhere, so I think it's |
| 99 | # OK for us to just make these inherit non-archwidth-specific |
| 100 | # configurations without modification. |
| 101 | 'Debug_x64': { |
| 102 | 'inherit_from': ['Debug'], |
| 103 | }, |
| 104 | 'Release_x64': { |
| 105 | 'inherit_from': ['Release'], |
| 106 | }, |
| 107 | 'Release_Developer_x64': { |
| 108 | 'inherit_from': ['Release_Developer'], |
| 109 | }, |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 110 | }, |
borenet@google.com | b796119 | 2012-08-20 18:58:26 +0000 | [diff] [blame] | 111 | 'conditions' : [ |
borenet@google.com | a72aef8 | 2013-03-22 13:16:06 +0000 | [diff] [blame] | 112 | [ 'skia_arch_width == 64', { |
bsalomon@google.com | 1d03ba9 | 2013-01-08 20:40:22 +0000 | [diff] [blame] | 113 | 'msvs_configuration_platform': 'x64', |
borenet@google.com | a72aef8 | 2013-03-22 13:16:06 +0000 | [diff] [blame] | 114 | }], |
| 115 | [ 'skia_arch_width == 32', { |
| 116 | 'msvs_configuration_platform': 'Win32', |
| 117 | }], |
| 118 | [ 'skia_warnings_as_errors', { |
bsalomon@google.com | 1d03ba9 | 2013-01-08 20:40:22 +0000 | [diff] [blame] | 119 | 'msvs_settings': { |
| 120 | 'VCCLCompilerTool': { |
borenet@google.com | a72aef8 | 2013-03-22 13:16:06 +0000 | [diff] [blame] | 121 | 'WarnAsError': 'true', |
| 122 | 'AdditionalOptions': [ |
| 123 | '/we4189', # initialized but unused var warning |
| 124 | ], |
bsalomon@google.com | 1d03ba9 | 2013-01-08 20:40:22 +0000 | [diff] [blame] | 125 | }, |
| 126 | }, |
borenet@google.com | b796119 | 2012-08-20 18:58:26 +0000 | [diff] [blame] | 127 | }], |
commit-bot@chromium.org | 5a6c2d8 | 2013-06-14 17:10:09 +0000 | [diff] [blame] | 128 | [ 'skia_win_exceptions', { |
| 129 | 'msvs_settings': { |
| 130 | 'VCCLCompilerTool': { |
| 131 | 'AdditionalOptions': [ |
| 132 | '/EHsc', |
| 133 | ], |
| 134 | }, |
| 135 | }, |
| 136 | }], |
borenet@google.com | b796119 | 2012-08-20 18:58:26 +0000 | [diff] [blame] | 137 | ], |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 138 | }, |
| 139 | ], |
| 140 | |
commit-bot@chromium.org | 183f7f5 | 2013-07-11 12:48:14 +0000 | [diff] [blame] | 141 | # The following section is common to linux + derivatives and android |
| 142 | [ 'skia_os in ["linux", "freebsd", "openbsd", "solaris", "nacl", "chromeos", "android"]', |
| 143 | { |
mtklein@google.com | f1077f9 | 2013-11-20 15:13:49 +0000 | [diff] [blame] | 144 | 'cflags': [ |
mtklein@google.com | dad7070 | 2013-11-20 18:06:10 +0000 | [diff] [blame] | 145 | '-g', |
mtklein@google.com | f1077f9 | 2013-11-20 15:13:49 +0000 | [diff] [blame] | 146 | '-fno-exceptions', |
| 147 | '-fstrict-aliasing', |
mtklein@google.com | dad7070 | 2013-11-20 18:06:10 +0000 | [diff] [blame] | 148 | |
mtklein@google.com | f1077f9 | 2013-11-20 15:13:49 +0000 | [diff] [blame] | 149 | '-Wall', |
| 150 | '-Wextra', |
| 151 | '-Winit-self', |
| 152 | '-Wpointer-arith', |
| 153 | |
| 154 | '-Wno-unused-parameter', |
mtklein@google.com | f1077f9 | 2013-11-20 15:13:49 +0000 | [diff] [blame] | 155 | ], |
| 156 | 'cflags_cc': [ |
| 157 | '-fno-rtti', |
| 158 | '-Wnon-virtual-dtor', |
| 159 | ], |
commit-bot@chromium.org | 183f7f5 | 2013-07-11 12:48:14 +0000 | [diff] [blame] | 160 | 'conditions': [ |
commit-bot@chromium.org | 93f5e51 | 2014-02-17 15:22:26 +0000 | [diff] [blame] | 161 | [ 'skia_android_framework==0', { |
| 162 | 'cflags': [ |
| 163 | # This flag is not supported by Android build system. |
| 164 | '-Wno-c++11-extensions', |
| 165 | ], |
| 166 | }], |
commit-bot@chromium.org | 183f7f5 | 2013-07-11 12:48:14 +0000 | [diff] [blame] | 167 | [ 'skia_warnings_as_errors', { |
| 168 | 'cflags': [ |
| 169 | '-Werror', |
| 170 | ], |
| 171 | }], |
commit-bot@chromium.org | 35d4872 | 2014-02-13 18:36:36 +0000 | [diff] [blame] | 172 | # For profiling; reveals some costs, exaggerates others (e.g. trivial setters & getters). |
| 173 | [ 'skia_disable_inlining', { |
| 174 | 'cflags': [ |
| 175 | '-fno-inline', |
| 176 | '-fno-default-inline', |
| 177 | '-finline-limit=0', |
| 178 | '-fno-omit-frame-pointer', |
| 179 | ], |
| 180 | }], |
commit-bot@chromium.org | 183f7f5 | 2013-07-11 12:48:14 +0000 | [diff] [blame] | 181 | [ 'skia_arch_type == "arm" and arm_thumb == 1', { |
| 182 | 'cflags': [ |
| 183 | '-mthumb', |
| 184 | ], |
djsollen@google.com | f7542ba | 2013-07-31 12:57:27 +0000 | [diff] [blame] | 185 | # The --fix-cortex-a8 switch enables a link-time workaround for |
| 186 | # an erratum in certain Cortex-A8 processors. The workaround is |
| 187 | # enabled by default if you target the ARM v7-A arch profile. |
| 188 | # It can be enabled otherwise by specifying --fix-cortex-a8, or |
| 189 | # disabled unconditionally by specifying --no-fix-cortex-a8. |
| 190 | # |
| 191 | # The erratum only affects Thumb-2 code. |
| 192 | 'conditions': [ |
| 193 | [ 'arm_version < 7', { |
| 194 | 'ldflags': [ |
| 195 | '-Wl,--fix-cortex-a8', |
| 196 | ], |
| 197 | }], |
commit-bot@chromium.org | 183f7f5 | 2013-07-11 12:48:14 +0000 | [diff] [blame] | 198 | ], |
djsollen@google.com | f7542ba | 2013-07-31 12:57:27 +0000 | [diff] [blame] | 199 | }], |
| 200 | [ 'skia_arch_type == "arm" and arm_version >= 7', { |
commit-bot@chromium.org | 183f7f5 | 2013-07-11 12:48:14 +0000 | [diff] [blame] | 201 | 'cflags': [ |
| 202 | '-march=armv7-a', |
commit-bot@chromium.org | 183f7f5 | 2013-07-11 12:48:14 +0000 | [diff] [blame] | 203 | ], |
djsollen@google.com | f7542ba | 2013-07-31 12:57:27 +0000 | [diff] [blame] | 204 | 'ldflags': [ |
| 205 | '-march=armv7-a', |
| 206 | ], |
commit-bot@chromium.org | 183f7f5 | 2013-07-11 12:48:14 +0000 | [diff] [blame] | 207 | 'conditions': [ |
| 208 | [ 'arm_neon == 1', { |
| 209 | 'defines': [ |
| 210 | '__ARM_HAVE_NEON', |
| 211 | ], |
| 212 | 'cflags': [ |
| 213 | '-mfpu=neon', |
| 214 | ], |
commit-bot@chromium.org | 183f7f5 | 2013-07-11 12:48:14 +0000 | [diff] [blame] | 215 | }], |
| 216 | [ 'arm_neon_optional == 1', { |
| 217 | 'defines': [ |
| 218 | '__ARM_HAVE_OPTIONAL_NEON_SUPPORT', |
| 219 | ], |
| 220 | }], |
borenet@google.com | e2b9037 | 2013-07-11 18:46:30 +0000 | [diff] [blame] | 221 | [ 'skia_os != "chromeos"', { |
| 222 | 'cflags': [ |
| 223 | '-mfloat-abi=softfp', |
| 224 | ], |
| 225 | }], |
commit-bot@chromium.org | 183f7f5 | 2013-07-11 12:48:14 +0000 | [diff] [blame] | 226 | ], |
| 227 | }], |
| 228 | ], |
| 229 | }, |
| 230 | ], |
| 231 | |
scroggo@google.com | d4adfa3 | 2014-02-05 16:35:12 +0000 | [diff] [blame] | 232 | ['skia_android_framework', { |
| 233 | 'cflags': [ |
| 234 | # Skia does not enforce this usage pattern so we disable it here to avoid |
| 235 | # unecessary log spew when building |
| 236 | '-Wno-unused-parameter', |
| 237 | |
| 238 | # Android's -D_FORTIFY_SOURCE=2 extensions are incompatibile with SkString. |
| 239 | # Revert to -D_FORTIFY_SOURCE=1 |
| 240 | '-U_FORTIFY_SOURCE', |
| 241 | '-D_FORTIFY_SOURCE=1', |
| 242 | ], |
commit-bot@chromium.org | 2fe641b | 2014-03-25 15:14:18 +0000 | [diff] [blame] | 243 | # Remove flags which are either unnecessary or problematic for the |
| 244 | # Android framework build. Many of these flags are removed simply because |
| 245 | # they were not previously in the Android framework makefile, and we did |
| 246 | # did not intend to add them when generating the makefile. |
| 247 | # TODO (scroggo): Investigate whether any of these flags are actually |
| 248 | # needed/would be beneficial. |
commit-bot@chromium.org | e72a408 | 2014-02-28 16:07:39 +0000 | [diff] [blame] | 249 | 'cflags!': [ |
commit-bot@chromium.org | 2fe641b | 2014-03-25 15:14:18 +0000 | [diff] [blame] | 250 | # Android has one makefile, used for both debugging (after manual |
| 251 | # modification) and release. Turn off debug info by default. |
commit-bot@chromium.org | e72a408 | 2014-02-28 16:07:39 +0000 | [diff] [blame] | 252 | '-g', |
| 253 | '-march=armv7-a', |
| 254 | '-mthumb', |
| 255 | '-mfpu=neon', |
| 256 | '-mfloat-abi=softfp', |
commit-bot@chromium.org | 2fe641b | 2014-03-25 15:14:18 +0000 | [diff] [blame] | 257 | # This flag is not supported by Android build system. |
| 258 | '-Wno-c++11-extensions', |
| 259 | '-fno-exceptions', |
| 260 | '-fstrict-aliasing', |
| 261 | # Remove flags to turn on warnings, since most people building Android |
| 262 | # are not focused on Skia and do not need the extra warning info. |
| 263 | '-Wall', |
| 264 | '-Wextra', |
| 265 | '-Winit-self', |
| 266 | '-Wpointer-arith', |
| 267 | ], |
| 268 | 'cflags_cc!': [ |
| 269 | '-fno-rtti', |
| 270 | '-Wnon-virtual-dtor', |
commit-bot@chromium.org | e72a408 | 2014-02-28 16:07:39 +0000 | [diff] [blame] | 271 | ], |
scroggo@google.com | d4adfa3 | 2014-02-05 16:35:12 +0000 | [diff] [blame] | 272 | 'defines': [ |
| 273 | 'DCT_IFAST_SUPPORTED', |
| 274 | # using freetype's embolden allows us to adjust fake bold settings at |
| 275 | # draw-time, at which point we know which SkTypeface is being drawn |
| 276 | 'SK_USE_FREETYPE_EMBOLDEN', |
commit-bot@chromium.org | ba0c5ea | 2014-03-28 15:59:04 +0000 | [diff] [blame] | 277 | 'SK_SFNTLY_SUBSETTER "sample/chromium/font_subsetter.h"', |
| 278 | # When built as part of the system image we can enable certian non-NDK |
| 279 | # compliant optimizations. |
| 280 | 'SK_BUILD_FOR_ANDROID_FRAMEWORK', |
commit-bot@chromium.org | ba0c5ea | 2014-03-28 15:59:04 +0000 | [diff] [blame] | 281 | # Optimizations for chromium (m30) |
| 282 | 'GR_GL_CUSTOM_SETUP_HEADER "gl/GrGLConfig_chrome.h"', |
| 283 | 'IGNORE_ROT_AA_RECT_OPT', |
| 284 | # Disable this check because it is too strict for some chromium-specific |
| 285 | # subclasses of SkPixelRef. See bug: crbug.com/171776. |
| 286 | 'SK_DISABLE_PIXELREF_LOCKCOUNT_BALANCE_CHECK', |
| 287 | 'SkLONGLONG int64_t', |
| 288 | 'SK_DEFAULT_FONT_CACHE_LIMIT (768 * 1024)', |
| 289 | 'SK_ATOMICS_PLATFORM_H "../../src/ports/SkAtomics_android.h"', |
| 290 | 'SK_MUTEX_PLATFORM_H "../../src/ports/SkMutex_pthread.h"', |
commit-bot@chromium.org | 848fdb0 | 2014-04-04 21:19:53 +0000 | [diff] [blame] | 291 | # FIXME: b/13729784: Need to rework LayerRasterizer.cpp |
| 292 | 'SK_SUPPORT_LEGACY_LAYERRASTERIZER_API', |
| 293 | # Temporary until https:#googleplex-android-review.git.corp.google.com/#/c/442220/ |
| 294 | # lands. |
| 295 | 'SK_SUPPORT_LEGACY_GETTOTALCLIP', |
commit-bot@chromium.org | 28fcae2 | 2014-04-11 17:15:40 +0000 | [diff] [blame] | 296 | # Still need to switch Android to the new name for N32. |
| 297 | 'kNative_8888_SkColorType kN32_SkColorType', |
commit-bot@chromium.org | 04f6c4c | 2014-04-16 22:08:32 +0000 | [diff] [blame] | 298 | 'SK_SUPPORT_LEGACY_PICTURE_CAN_RECORD', |
commit-bot@chromium.org | 03f2f81 | 2014-04-16 23:06:29 +0000 | [diff] [blame] | 299 | 'SK_SUPPORT_DEPRECATED_RECORD_FLAGS', |
commit-bot@chromium.org | 5fb2ce3 | 2014-04-17 23:35:06 +0000 | [diff] [blame] | 300 | 'SK_SUPPORT_LEGACY_DERIVED_PICTURE_CLASSES', |
robertphillips@google.com | 770963f | 2014-04-18 18:04:41 +0000 | [diff] [blame^] | 301 | 'SK_SUPPORT_LEGACY_PICTURE_HEADERS', |
commit-bot@chromium.org | 03f2f81 | 2014-04-16 23:06:29 +0000 | [diff] [blame] | 302 | 'SK_SUPPORT_LEGACY_BLURDRAWLOOPERCONSTRUCTORS', |
scroggo@google.com | d4adfa3 | 2014-02-05 16:35:12 +0000 | [diff] [blame] | 303 | ], |
| 304 | }], |
commit-bot@chromium.org | 183f7f5 | 2013-07-11 12:48:14 +0000 | [diff] [blame] | 305 | |
borenet@google.com | 05d550e | 2013-06-11 15:52:19 +0000 | [diff] [blame] | 306 | [ 'skia_os in ["linux", "freebsd", "openbsd", "solaris", "nacl", "chromeos"]', |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 307 | { |
| 308 | 'defines': [ |
| 309 | 'SK_SAMPLES_FOR_X', |
| 310 | 'SK_BUILD_FOR_UNIX', |
| 311 | ], |
| 312 | 'configurations': { |
mtklein@google.com | 1fb04e2 | 2013-09-13 19:32:43 +0000 | [diff] [blame] | 313 | 'Coverage': { |
mtklein@google.com | dad7070 | 2013-11-20 18:06:10 +0000 | [diff] [blame] | 314 | 'cflags': ['--coverage'], |
mtklein@google.com | 1fb04e2 | 2013-09-13 19:32:43 +0000 | [diff] [blame] | 315 | 'ldflags': ['--coverage'], |
| 316 | }, |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 317 | 'Debug': { |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 318 | }, |
| 319 | 'Release': { |
commit-bot@chromium.org | 06b3864 | 2013-06-20 20:28:54 +0000 | [diff] [blame] | 320 | 'cflags': [ |
| 321 | '-O<(skia_release_optimization_level)', |
commit-bot@chromium.org | 06b3864 | 2013-06-20 20:28:54 +0000 | [diff] [blame] | 322 | ], |
senorblanco@chromium.org | 7288c49 | 2012-01-19 19:59:22 +0000 | [diff] [blame] | 323 | 'defines': [ 'NDEBUG' ], |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 324 | }, |
| 325 | }, |
borenet@google.com | a37a517 | 2012-08-09 20:44:32 +0000 | [diff] [blame] | 326 | 'conditions' : [ |
zachr@google.com | 28c27c8 | 2013-06-20 17:15:05 +0000 | [diff] [blame] | 327 | [ 'skia_shared_lib', { |
| 328 | 'cflags': [ |
| 329 | '-fPIC', |
| 330 | ], |
| 331 | 'defines': [ |
zachr@google.com | 28c27c8 | 2013-06-20 17:15:05 +0000 | [diff] [blame] | 332 | 'SKIA_DLL', |
| 333 | 'SKIA_IMPLEMENTATION=1', |
| 334 | ], |
| 335 | }], |
borenet@google.com | 7158e6a | 2012-11-01 17:43:44 +0000 | [diff] [blame] | 336 | [ 'skia_os == "nacl"', { |
| 337 | 'defines': [ |
| 338 | 'SK_BUILD_FOR_NACL', |
| 339 | ], |
commit-bot@chromium.org | fe42410 | 2014-02-21 00:40:16 +0000 | [diff] [blame] | 340 | 'variables': { |
commit-bot@chromium.org | 25595ed | 2014-04-04 18:16:04 +0000 | [diff] [blame] | 341 | 'nacl_sdk_root': '<!(echo ${NACL_SDK_ROOT})', |
commit-bot@chromium.org | fe42410 | 2014-02-21 00:40:16 +0000 | [diff] [blame] | 342 | }, |
borenet@google.com | 7158e6a | 2012-11-01 17:43:44 +0000 | [diff] [blame] | 343 | 'link_settings': { |
| 344 | 'libraries': [ |
| 345 | '-lppapi', |
| 346 | '-lppapi_cpp', |
| 347 | '-lnosys', |
| 348 | '-pthread', |
| 349 | ], |
commit-bot@chromium.org | fe42410 | 2014-02-21 00:40:16 +0000 | [diff] [blame] | 350 | 'ldflags': [ |
| 351 | '-L<(nacl_sdk_root)/lib/newlib_x86_<(skia_arch_width)/Release', |
| 352 | '-L<(nacl_sdk_root)/ports/lib/newlib_x86_<(skia_arch_width)/Release', |
| 353 | ], |
borenet@google.com | 7158e6a | 2012-11-01 17:43:44 +0000 | [diff] [blame] | 354 | }, |
borenet@google.com | cb9445d | 2013-08-19 18:26:04 +0000 | [diff] [blame] | 355 | }, { # skia_os != "nacl" |
| 356 | 'link_settings': { |
| 357 | 'ldflags': [ |
| 358 | '-lstdc++', |
| 359 | '-lm', |
| 360 | ], |
| 361 | }, |
borenet@google.com | 7158e6a | 2012-11-01 17:43:44 +0000 | [diff] [blame] | 362 | }], |
borenet@google.com | cb9445d | 2013-08-19 18:26:04 +0000 | [diff] [blame] | 363 | [ 'skia_os != "chromeos"', { |
borenet@google.com | 05d550e | 2013-06-11 15:52:19 +0000 | [diff] [blame] | 364 | 'conditions': [ |
commit-bot@chromium.org | 183f7f5 | 2013-07-11 12:48:14 +0000 | [diff] [blame] | 365 | [ 'skia_arch_width == 64 and skia_arch_type == "x86"', { |
borenet@google.com | 05d550e | 2013-06-11 15:52:19 +0000 | [diff] [blame] | 366 | 'cflags': [ |
| 367 | '-m64', |
| 368 | ], |
| 369 | 'ldflags': [ |
| 370 | '-m64', |
| 371 | ], |
| 372 | }], |
commit-bot@chromium.org | 183f7f5 | 2013-07-11 12:48:14 +0000 | [diff] [blame] | 373 | [ 'skia_arch_width == 32 and skia_arch_type == "x86"', { |
borenet@google.com | 05d550e | 2013-06-11 15:52:19 +0000 | [diff] [blame] | 374 | 'cflags': [ |
| 375 | '-m32', |
| 376 | ], |
| 377 | 'ldflags': [ |
| 378 | '-m32', |
| 379 | ], |
| 380 | }], |
| 381 | ], |
| 382 | }], |
mtklein@google.com | 9f3b0e4 | 2013-10-08 15:16:36 +0000 | [diff] [blame] | 383 | # Enable asan, tsan, etc. |
| 384 | [ 'skia_sanitizer', { |
borenet@google.com | 0d19309 | 2013-07-03 15:55:05 +0000 | [diff] [blame] | 385 | 'cflags': [ |
mtklein@google.com | 9f3b0e4 | 2013-10-08 15:16:36 +0000 | [diff] [blame] | 386 | '-fsanitize=<(skia_sanitizer)', |
borenet@google.com | 0d19309 | 2013-07-03 15:55:05 +0000 | [diff] [blame] | 387 | ], |
| 388 | 'ldflags': [ |
mtklein@google.com | 9f3b0e4 | 2013-10-08 15:16:36 +0000 | [diff] [blame] | 389 | '-fsanitize=<(skia_sanitizer)', |
bungeman@google.com | 1435f9f | 2013-09-25 22:39:22 +0000 | [diff] [blame] | 390 | ], |
mtklein@google.com | 3a19fb5 | 2013-10-09 16:12:23 +0000 | [diff] [blame] | 391 | 'conditions' : [ |
| 392 | [ 'skia_sanitizer == "thread"', { |
| 393 | 'defines': [ 'DYNAMIC_ANNOTATIONS_ENABLED=1' ], |
bungeman@google.com | 0fbe01f | 2013-10-10 17:24:17 +0000 | [diff] [blame] | 394 | 'cflags': [ '-fPIC' ], |
bungeman@google.com | 27d4ffe | 2013-10-10 17:09:49 +0000 | [diff] [blame] | 395 | 'target_conditions': [ |
| 396 | [ '_type == "executable"', { |
| 397 | 'cflags': [ '-fPIE' ], |
| 398 | 'ldflags': [ '-pie' ], |
| 399 | }], |
| 400 | ], |
mtklein@google.com | 3a19fb5 | 2013-10-09 16:12:23 +0000 | [diff] [blame] | 401 | }], |
| 402 | ], |
bungeman@google.com | 1435f9f | 2013-09-25 22:39:22 +0000 | [diff] [blame] | 403 | }], |
borenet@google.com | 47ae4b0 | 2013-08-21 18:02:50 +0000 | [diff] [blame] | 404 | [ 'skia_clang_build', { |
| 405 | 'cflags': [ |
mtklein@google.com | 9f3b0e4 | 2013-10-08 15:16:36 +0000 | [diff] [blame] | 406 | # Extra warnings we like but that only Clang knows about. |
borenet@google.com | 47ae4b0 | 2013-08-21 18:02:50 +0000 | [diff] [blame] | 407 | '-Wstring-conversion', |
| 408 | ], |
| 409 | }], |
commit-bot@chromium.org | 5003bde | 2013-10-25 18:14:54 +0000 | [diff] [blame] | 410 | [ 'skia_keep_frame_pointer', { |
| 411 | 'cflags': [ '-fno-omit-frame-pointer' ], |
| 412 | }], |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 413 | ], |
| 414 | }, |
| 415 | ], |
| 416 | |
borenet@google.com | a72aef8 | 2013-03-22 13:16:06 +0000 | [diff] [blame] | 417 | [ 'skia_os == "mac"', |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 418 | { |
| 419 | 'defines': [ |
| 420 | 'SK_BUILD_FOR_MAC', |
| 421 | ], |
djsollen@google.com | e341cb3 | 2012-06-28 16:08:05 +0000 | [diff] [blame] | 422 | 'conditions' : [ |
borenet@google.com | a72aef8 | 2013-03-22 13:16:06 +0000 | [diff] [blame] | 423 | [ 'skia_arch_width == 64', { |
djsollen@google.com | e341cb3 | 2012-06-28 16:08:05 +0000 | [diff] [blame] | 424 | 'xcode_settings': { |
commit-bot@chromium.org | 5d7ca95 | 2013-04-22 20:26:44 +0000 | [diff] [blame] | 425 | 'ARCHS': ['x86_64'], |
djsollen@google.com | e341cb3 | 2012-06-28 16:08:05 +0000 | [diff] [blame] | 426 | }, |
| 427 | }], |
borenet@google.com | a72aef8 | 2013-03-22 13:16:06 +0000 | [diff] [blame] | 428 | [ 'skia_arch_width == 32', { |
djsollen@google.com | e341cb3 | 2012-06-28 16:08:05 +0000 | [diff] [blame] | 429 | 'xcode_settings': { |
commit-bot@chromium.org | 5d7ca95 | 2013-04-22 20:26:44 +0000 | [diff] [blame] | 430 | 'ARCHS': ['i386'], |
borenet@google.com | a72aef8 | 2013-03-22 13:16:06 +0000 | [diff] [blame] | 431 | }, |
| 432 | }], |
| 433 | [ 'skia_warnings_as_errors', { |
| 434 | 'xcode_settings': { |
humper@google.com | fe0d680 | 2013-01-07 20:28:16 +0000 | [diff] [blame] | 435 | 'OTHER_CPLUSPLUSFLAGS': [ |
| 436 | '-Werror', |
commit-bot@chromium.org | faa5ae4 | 2013-07-23 11:13:56 +0000 | [diff] [blame] | 437 | '-Wall', |
| 438 | '-Wextra', |
| 439 | '-Wno-unused-parameter', |
commit-bot@chromium.org | 6a18079 | 2014-01-15 21:39:18 +0000 | [diff] [blame] | 440 | '-Wno-uninitialized', # Disabled because we think GCC 4.2 is bad at this. |
mtklein@google.com | 8d725b2 | 2013-07-24 16:20:05 +0000 | [diff] [blame] | 441 | ], |
| 442 | }, |
| 443 | }], |
djsollen@google.com | e341cb3 | 2012-06-28 16:08:05 +0000 | [diff] [blame] | 444 | ], |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 445 | 'configurations': { |
commit-bot@chromium.org | 866f4e3 | 2013-11-21 17:04:29 +0000 | [diff] [blame] | 446 | 'Coverage': { |
| 447 | 'xcode_settings': { |
| 448 | 'GCC_OPTIMIZATION_LEVEL': '0', |
| 449 | 'GCC_GENERATE_TEST_COVERAGE_FILES': 'YES', |
| 450 | 'GCC_INSTRUMENT_PROGRAM_FLOW_ARCS' : 'YES', |
| 451 | }, |
| 452 | }, |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 453 | 'Debug': { |
| 454 | 'xcode_settings': { |
| 455 | 'GCC_OPTIMIZATION_LEVEL': '0', |
| 456 | }, |
| 457 | }, |
reed@google.com | e05cc8e | 2011-10-10 14:19:40 +0000 | [diff] [blame] | 458 | 'Release': { |
| 459 | 'xcode_settings': { |
commit-bot@chromium.org | 06b3864 | 2013-06-20 20:28:54 +0000 | [diff] [blame] | 460 | 'GCC_OPTIMIZATION_LEVEL': '<(skia_release_optimization_level)', |
reed@google.com | e05cc8e | 2011-10-10 14:19:40 +0000 | [diff] [blame] | 461 | }, |
senorblanco@chromium.org | 7288c49 | 2012-01-19 19:59:22 +0000 | [diff] [blame] | 462 | 'defines': [ 'NDEBUG' ], |
reed@google.com | e05cc8e | 2011-10-10 14:19:40 +0000 | [diff] [blame] | 463 | }, |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 464 | }, |
| 465 | 'xcode_settings': { |
robertphillips@google.com | 0229765 | 2012-04-05 19:29:04 +0000 | [diff] [blame] | 466 | 'GCC_SYMBOLS_PRIVATE_EXTERN': 'NO', |
senorblanco@chromium.org | 29f351a | 2014-01-20 16:14:02 +0000 | [diff] [blame] | 467 | 'conditions': [ |
| 468 | [ 'skia_osx_deployment_target==""', { |
| 469 | 'MACOSX_DEPLOYMENT_TARGET': '10.6', # -mmacos-version-min, passed in environment to ld. |
| 470 | }, { |
| 471 | 'MACOSX_DEPLOYMENT_TARGET': '<(skia_osx_deployment_target)', |
| 472 | }], |
| 473 | ], |
reed@google.com | 0069aa5 | 2011-11-17 15:35:47 +0000 | [diff] [blame] | 474 | # trying to get this to work, but it needs clang I think... |
| 475 | # 'WARNING_CFLAGS': '-Wexit-time-destructors', |
mike@reedtribe.org | e51755f | 2011-12-10 19:36:56 +0000 | [diff] [blame] | 476 | 'CLANG_WARN_CXX0X_EXTENSIONS': 'NO', |
caryclark@google.com | b462a42 | 2012-06-06 12:12:28 +0000 | [diff] [blame] | 477 | 'GCC_WARN_64_TO_32_BIT_CONVERSION': 'YES', |
| 478 | 'GCC_WARN_ABOUT_DEPRECATED_FUNCTIONS': 'YES', |
| 479 | 'GCC_WARN_ABOUT_INVALID_OFFSETOF_MACRO': 'YES', |
| 480 | 'GCC_WARN_ABOUT_MISSING_NEWLINE': 'YES', |
| 481 | 'GCC_WARN_ABOUT_MISSING_PROTOTYPES': 'YES', |
| 482 | 'GCC_WARN_ABOUT_POINTER_SIGNEDNESS': 'YES', |
| 483 | 'GCC_WARN_ABOUT_RETURN_TYPE': 'YES', |
| 484 | 'GCC_WARN_ALLOW_INCOMPLETE_PROTOCOL': 'YES', |
| 485 | 'GCC_WARN_INITIALIZER_NOT_FULLY_BRACKETED': 'YES', |
| 486 | 'GCC_WARN_MISSING_PARENTHESES': 'YES', |
| 487 | 'GCC_WARN_PROTOTYPE_CONVERSION': 'YES', |
| 488 | 'GCC_WARN_SIGN_COMPARE': 'YES', |
| 489 | 'GCC_WARN_TYPECHECK_CALLS_TO_PRINTF': 'YES', |
| 490 | 'GCC_WARN_UNKNOWN_PRAGMAS': 'YES', |
| 491 | 'GCC_WARN_UNUSED_FUNCTION': 'YES', |
| 492 | 'GCC_WARN_UNUSED_LABEL': 'YES', |
| 493 | 'GCC_WARN_UNUSED_VALUE': 'YES', |
| 494 | 'GCC_WARN_UNUSED_VARIABLE': 'YES', |
bungeman@google.com | 43b4ed5 | 2012-10-02 15:42:21 +0000 | [diff] [blame] | 495 | 'OTHER_CPLUSPLUSFLAGS': [ |
| 496 | '-mssse3', |
| 497 | '-fvisibility=hidden', |
| 498 | '-fvisibility-inlines-hidden', |
| 499 | ], |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 500 | }, |
| 501 | }, |
| 502 | ], |
| 503 | |
borenet@google.com | a72aef8 | 2013-03-22 13:16:06 +0000 | [diff] [blame] | 504 | [ 'skia_os == "ios"', |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 505 | { |
| 506 | 'defines': [ |
| 507 | 'SK_BUILD_FOR_IOS', |
| 508 | ], |
borenet@google.com | a72aef8 | 2013-03-22 13:16:06 +0000 | [diff] [blame] | 509 | 'conditions' : [ |
| 510 | [ 'skia_warnings_as_errors', { |
| 511 | 'xcode_settings': { |
| 512 | 'OTHER_CPLUSPLUSFLAGS': [ |
| 513 | '-Werror', |
| 514 | ], |
| 515 | }, |
| 516 | }], |
| 517 | ], |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 518 | 'configurations': { |
| 519 | 'Debug': { |
| 520 | 'xcode_settings': { |
| 521 | 'GCC_OPTIMIZATION_LEVEL': '0', |
| 522 | }, |
| 523 | }, |
caryclark@google.com | 594dd3c | 2012-09-24 19:33:57 +0000 | [diff] [blame] | 524 | 'Release': { |
| 525 | 'xcode_settings': { |
commit-bot@chromium.org | 06b3864 | 2013-06-20 20:28:54 +0000 | [diff] [blame] | 526 | 'GCC_OPTIMIZATION_LEVEL': '<(skia_release_optimization_level)', |
caryclark@google.com | 594dd3c | 2012-09-24 19:33:57 +0000 | [diff] [blame] | 527 | }, |
| 528 | 'defines': [ 'NDEBUG' ], |
| 529 | }, |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 530 | }, |
| 531 | 'xcode_settings': { |
commit-bot@chromium.org | ae0054e | 2014-04-05 01:13:43 +0000 | [diff] [blame] | 532 | 'ARCHS': ['armv7'], |
caryclark@google.com | 867cbd8 | 2012-09-20 15:45:41 +0000 | [diff] [blame] | 533 | 'CODE_SIGNING_REQUIRED': 'NO', |
| 534 | 'CODE_SIGN_IDENTITY[sdk=iphoneos*]': '', |
caryclark@google.com | 594dd3c | 2012-09-24 19:33:57 +0000 | [diff] [blame] | 535 | 'IPHONEOS_DEPLOYMENT_TARGET': '<(ios_sdk_version)', |
caryclark@google.com | 867cbd8 | 2012-09-20 15:45:41 +0000 | [diff] [blame] | 536 | 'SDKROOT': 'iphoneos', |
caryclark@google.com | 594dd3c | 2012-09-24 19:33:57 +0000 | [diff] [blame] | 537 | 'TARGETED_DEVICE_FAMILY': '1,2', |
borenet@google.com | a72aef8 | 2013-03-22 13:16:06 +0000 | [diff] [blame] | 538 | 'OTHER_CPLUSPLUSFLAGS': [ |
| 539 | '-fvisibility=hidden', |
| 540 | '-fvisibility-inlines-hidden', |
| 541 | ], |
bsalomon@google.com | 89dec58 | 2012-09-28 18:33:11 +0000 | [diff] [blame] | 542 | 'GCC_THUMB_SUPPORT': 'NO', |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 543 | }, |
| 544 | }, |
| 545 | ], |
chudy@google.com | bbad34d | 2012-08-13 14:26:36 +0000 | [diff] [blame] | 546 | |
borenet@google.com | a72aef8 | 2013-03-22 13:16:06 +0000 | [diff] [blame] | 547 | [ 'skia_os == "android"', |
djsollen@google.com | 5862929 | 2011-11-03 13:08:29 +0000 | [diff] [blame] | 548 | { |
| 549 | 'defines': [ |
djsollen@google.com | 5862929 | 2011-11-03 13:08:29 +0000 | [diff] [blame] | 550 | 'SK_BUILD_FOR_ANDROID', |
bungeman@google.com | 451b596 | 2013-11-11 18:36:46 +0000 | [diff] [blame] | 551 | 'SK_FONTHOST_DOES_NOT_USE_FONTMGR', |
djsollen@google.com | 968757e | 2014-04-11 13:09:21 +0000 | [diff] [blame] | 552 | |
| 553 | # Android Text Tuning |
| 554 | 'SK_GAMMA_EXPONENT=1.4', |
| 555 | 'SK_GAMMA_CONTRAST=0.0', |
| 556 | ], |
| 557 | # Android defines a fixed gamma exponent instead of using SRGB |
| 558 | 'defines!': [ |
| 559 | 'SK_GAMMA_SRGB', |
djsollen@google.com | 5862929 | 2011-11-03 13:08:29 +0000 | [diff] [blame] | 560 | ], |
scroggo@google.com | eb62950 | 2014-02-04 16:08:48 +0000 | [diff] [blame] | 561 | 'configurations': { |
| 562 | 'Debug': { |
| 563 | 'cflags': ['-g'] |
| 564 | }, |
| 565 | 'Release': { |
| 566 | 'cflags': ['-O2'], |
| 567 | 'defines': [ 'NDEBUG' ], |
| 568 | }, |
| 569 | }, |
djsollen@google.com | 5862929 | 2011-11-03 13:08:29 +0000 | [diff] [blame] | 570 | 'libraries': [ |
scroggo@google.com | eb62950 | 2014-02-04 16:08:48 +0000 | [diff] [blame] | 571 | '-lstdc++', |
| 572 | '-lm', |
djsollen@google.com | 318cf92 | 2011-11-08 19:03:43 +0000 | [diff] [blame] | 573 | '-llog', |
djsollen@google.com | 5862929 | 2011-11-03 13:08:29 +0000 | [diff] [blame] | 574 | ], |
djsollen@google.com | 44360bc | 2011-12-05 13:55:55 +0000 | [diff] [blame] | 575 | 'cflags': [ |
borenet@google.com | de9ac14 | 2012-07-25 15:17:03 +0000 | [diff] [blame] | 576 | '-fuse-ld=gold', |
djsollen@google.com | 44360bc | 2011-12-05 13:55:55 +0000 | [diff] [blame] | 577 | ], |
djsollen@google.com | 5862929 | 2011-11-03 13:08:29 +0000 | [diff] [blame] | 578 | 'conditions': [ |
scroggo@google.com | d4adfa3 | 2014-02-05 16:35:12 +0000 | [diff] [blame] | 579 | [ 'skia_android_framework', { |
| 580 | 'libraries!': [ |
| 581 | '-lstdc++', |
| 582 | '-lm', |
| 583 | ], |
commit-bot@chromium.org | 2fe641b | 2014-03-25 15:14:18 +0000 | [diff] [blame] | 584 | 'cflags!': [ |
| 585 | '-fuse-ld=gold', |
| 586 | ], |
scroggo@google.com | d4adfa3 | 2014-02-05 16:35:12 +0000 | [diff] [blame] | 587 | }], |
djsollen@google.com | 52f0297 | 2013-06-03 12:10:19 +0000 | [diff] [blame] | 588 | [ 'skia_shared_lib', { |
| 589 | 'cflags': [ |
| 590 | '-fPIC', |
| 591 | ], |
| 592 | 'defines': [ |
djsollen@google.com | 52f0297 | 2013-06-03 12:10:19 +0000 | [diff] [blame] | 593 | 'SKIA_DLL', |
| 594 | 'SKIA_IMPLEMENTATION=1', |
| 595 | ], |
| 596 | }], |
commit-bot@chromium.org | 183f7f5 | 2013-07-11 12:48:14 +0000 | [diff] [blame] | 597 | [ 'skia_profile_enabled == 1', { |
| 598 | 'cflags': ['-g', '-fno-omit-frame-pointer', '-marm', '-mapcs'], |
djsollen@google.com | 3839ca1 | 2011-11-03 17:31:41 +0000 | [diff] [blame] | 599 | }], |
chudy@google.com | bbad34d | 2012-08-13 14:26:36 +0000 | [diff] [blame] | 600 | ], |
djsollen@google.com | 5862929 | 2011-11-03 13:08:29 +0000 | [diff] [blame] | 601 | }, |
| 602 | ], |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 603 | |
digit@google.com | 1771cbf | 2012-01-26 21:26:40 +0000 | [diff] [blame] | 604 | # We can POD-style initialization of static mutexes to avoid generating |
| 605 | # static initializers if we're using a pthread-compatible thread interface. |
| 606 | [ 'skia_os != "win"', { |
| 607 | 'defines': [ |
borenet@google.com | 7158e6a | 2012-11-01 17:43:44 +0000 | [diff] [blame] | 608 | 'SK_USE_POSIX_THREADS', |
digit@google.com | 1771cbf | 2012-01-26 21:26:40 +0000 | [diff] [blame] | 609 | ], |
| 610 | }], |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 611 | ], # end 'conditions' |
caryclark@google.com | 4588ce8 | 2012-09-26 15:48:43 +0000 | [diff] [blame] | 612 | # The Xcode SYMROOT must be at the root. See build/common.gypi in chromium for more details |
| 613 | 'xcode_settings': { |
| 614 | 'SYMROOT': '<(DEPTH)/xcodebuild', |
| 615 | }, |
seanpaul@google.com | 1134f98 | 2011-09-15 14:24:33 +0000 | [diff] [blame] | 616 | } |