Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(315)

Unified Diff: third_party/snappy/snappy.gyp

Issue 437543007: Refactor how clang warning flags are set. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/snappy/snappy.gyp
diff --git a/third_party/snappy/snappy.gyp b/third_party/snappy/snappy.gyp
index da237009ef060d5bc2d983ea2be113f3d8f8b5c4..de055578f2a937149710a8aa05ba7dbc7a832f1f 100644
--- a/third_party/snappy/snappy.gyp
+++ b/third_party/snappy/snappy.gyp
@@ -30,6 +30,13 @@
'src',
],
},
+ 'variables': {
+ 'clang_warning_flags_unset': [
+ # snappy-stubs-internal.h unapologetically has: using namespace std
+ # https://code.google.com/p/snappy/issues/detail?id=70
+ '-Wheader-hygiene',
+ ],
+ },
'sources': [
'src/snappy-internal.h',
'src/snappy-sinksource.cc',
@@ -40,14 +47,6 @@
'src/snappy.h',
],
'conditions': [
- ['clang == 1', {
- # snappy-stubs-internal.h unapologetically has: using namespace std
- # https://code.google.com/p/snappy/issues/detail?id=70
- 'xcode_settings': {
- 'WARNING_CFLAGS!': [ '-Wheader-hygiene' ],
- },
- 'cflags': [ '-Wno-header-hygiene' ],
- }],
['OS=="linux" or OS=="mac"', {
'defines': [
# TODO(tfarina): Only Mac and Linux has the generated config.h for
@@ -81,6 +80,10 @@
'../../testing/gtest.gyp:gtest',
'../../third_party/zlib/zlib.gyp:zlib',
],
+ 'variables': {
+ 'clang_warning_flags': [ 'Wno-return-type' ],
hans 2014/08/01 21:23:29 There's a dash missing here.
Nico 2014/08/01 21:25:06 Hm, so I guess if this still gets green runs, this
Nico 2014/08/01 21:35:20 …looks like not bot builds this target. So I added
+ 'clang_warning_flags_unset': [ '-Wheader-hygiene' ],
+ },
'conditions': [
['OS=="linux" or OS=="mac"', {
'defines': [
@@ -90,12 +93,6 @@
'HAVE_CONFIG_H=1',
],
}],
- ['clang == 1', {
- 'cflags': [
- '-Wno-return-type',
- '-Wno-header-hygiene'
- ],
- }],
],
},
],

Powered by Google App Engine
This is Rietveld 408576698