Index: gyp/libjpeg.gyp |
=================================================================== |
--- gyp/libjpeg.gyp (revision 8147) |
+++ gyp/libjpeg.gyp (working copy) |
@@ -80,22 +80,40 @@ |
], |
}, |
'conditions': [ |
- ['OS!="win"', { |
+ [ 'skia_os != "win"', { |
'product_name': 'jpeg', |
'cflags': [ |
'-Wno-main', # supresses warnings about naming things "main" |
], |
}], |
- ['OS=="android"', { |
+ [ 'skia_os == "android"', { |
'cflags!': [ |
'-fno-rtti', # supresses warnings about invalid option of non-C++ code |
'-Wall', |
- '-Werror', |
], |
}], |
- ['OS in ["linux", "freebsd", "openbsd", "solaris", "nacl"]', { |
- 'cflags!': [ |
- '-Werror', |
+ # Turn off warnings as errors. |
+ [ 'skia_warnings_as_errors', { |
+ 'conditions': [ |
+ [ 'skia_os == "mac"', { |
+ 'xcode_settings': { |
+ 'OTHER_CPLUSPLUSFLAGS!': [ |
+ '-Werror', |
+ ] |
+ }, |
+ }], |
+ [ 'skia_os == "win"', { |
+ 'msvs_settings': { |
+ 'VCCLCompilerTool': { |
+ 'WarnAsError': 'false', |
+ }, |
+ }, |
+ }], |
+ [ 'skia_os in ["linux", "freebsd", "openbsd", "solaris", "nacl", "android"]', { |
+ 'cflags!': [ |
+ '-Werror', |
+ ], |
+ }], |
], |
}], |
], |