Index: third_party/snappy/snappy.gyp |
diff --git a/third_party/snappy/snappy.gyp b/third_party/snappy/snappy.gyp |
index e6e94d0c1b0305e1987128719eecc2e884070de3..877c2a09a375db29e55c0fb6d094d512acf10559 100644 |
--- a/third_party/snappy/snappy.gyp |
+++ b/third_party/snappy/snappy.gyp |
@@ -40,28 +40,39 @@ |
'src/snappy.h', |
], |
'conditions': [ |
- ['OS=="win"', { |
- # Signed/unsigned comparison |
- 'msvs_disabled_warnings': [ |
- # https://code.google.com/p/snappy/issues/detail?id=71 |
- 4018, |
- # https://code.google.com/p/snappy/issues/detail?id=75 |
- 4267, |
- ], |
- }], |
['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!': [ '-Wheader-hygiene' ], |
- }], |
+ # 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"', { |
+ 'defines': [ |
+ # TODO(tfarina): Only Linux has the generated config.h for now. |
+ # Generate the config.h in the other platforms: mac, win and enable |
+ # this for everyone. |
+ 'HAVE_CONFIG_H=1', |
+ ], |
+ }], |
+ ['OS=="win"', { |
+ # Signed/unsigned comparison |
+ 'msvs_disabled_warnings': [ |
+ # https://code.google.com/p/snappy/issues/detail?id=71 |
+ 4018, |
+ # https://code.google.com/p/snappy/issues/detail?id=75 |
+ 4267, |
+ ], |
+ }], |
], |
}, |
{ |
'target_name': 'snappy_unittest', |
'type': 'executable', |
+ 'defines': [ |
+ 'HAVE_CONFIG_H=1', |
+ ], |
'sources': [ |
'src/snappy-test.cc', |
'src/snappy-test.h', |
@@ -73,6 +84,14 @@ |
'../../testing/gtest.gyp:gtest', |
'../../third_party/zlib/zlib.gyp:zlib', |
], |
+ 'conditions': [ |
+ ['clang == 1', { |
+ 'cflags': [ |
+ '-Wno-return-type', |
+ '-Wno-header-hygiene' |
+ ], |
+ }], |
+ ], |
}, |
], |
} |