diff options
Diffstat (limited to 'gyp')
-rw-r--r-- | gyp/common_conditions.gypi | 10 | ||||
-rw-r--r-- | gyp/common_variables.gypi | 4 |
2 files changed, 14 insertions, 0 deletions
diff --git a/gyp/common_conditions.gypi b/gyp/common_conditions.gypi index 6d1a4f84a9..332d342be2 100644 --- a/gyp/common_conditions.gypi +++ b/gyp/common_conditions.gypi @@ -125,6 +125,11 @@ '-Wno-c++11-extensions' ], 'conditions' : [ + ['skia_warnings_as_errors == 1', { + 'cflags': [ + '-Werror', + ], + }], ['skia_arch_width == 64', { 'cflags': [ '-m64', @@ -290,6 +295,11 @@ '<(android_base)/toolchains/<(android_toolchain)/sysroot/usr/include', ], 'conditions': [ + [ 'skia_warnings_as_errors == 1', { + 'cflags': [ + '-Werror', + ], + }], [ 'skia_profile_enabled == 1', { 'cflags': ['-g', '-fno-omit-frame-pointer', '-marm', '-mapcs'], }], diff --git a/gyp/common_variables.gypi b/gyp/common_variables.gypi index 1c900c52bb..042340b449 100644 --- a/gyp/common_variables.gypi +++ b/gyp/common_variables.gypi @@ -87,6 +87,9 @@ 'skia_gpu%': 1, 'skia_osx_sdkroot%': 'macosx', 'skia_profile_enabled%': 0, + # Note: This is currently only turned on for linux and android. + # TODO: Turn on for Win and Mac as well. + 'skia_warnings_as_errors%': 0, }, # Re-define all variables defined within the level-2 'variables' dict, @@ -106,6 +109,7 @@ 'skia_gpu%': '<(skia_gpu)', 'skia_osx_sdkroot%': '<(skia_osx_sdkroot)', 'skia_profile_enabled%': '<(skia_profile_enabled)', + 'skia_warnings_as_errors%': '<(skia_warnings_as_errors)', 'skia_static_initializers%': '<(skia_static_initializers)', 'ios_sdk_version%': '6.0', |