diff options
author | thakis <thakis@chromium.org> | 2014-11-25 12:23:35 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2014-11-25 20:25:12 +0000 |
commit | 5cd4f7a2be87749d96589486eb054c7da1e55bac (patch) | |
tree | c01d905a6296f1160ba38203045c500a35ae6dd0 | |
parent | 2a1e948cc3bc735ac13e9ffa125a512e9cf2e2db (diff) | |
download | chromium_src-5cd4f7a2be87749d96589486eb054c7da1e55bac.zip chromium_src-5cd4f7a2be87749d96589486eb054c7da1e55bac.tar.gz chromium_src-5cd4f7a2be87749d96589486eb054c7da1e55bac.tar.bz2 |
clang: Suppress a few -Wstring-conversion warnings in 3rd-party code.
The warning got stricter recently.
BUG=82385
TBR=brettw
Review URL: https://codereview.chromium.org/758963003
Cr-Commit-Position: refs/heads/master@{#305685}
-rw-r--r-- | net/third_party/nss/ssl.gyp | 6 | ||||
-rw-r--r-- | net/third_party/nss/ssl/BUILD.gn | 13 | ||||
-rw-r--r-- | third_party/mesa/BUILD.gn | 5 | ||||
-rw-r--r-- | third_party/mesa/mesa.gyp | 6 |
4 files changed, 22 insertions, 8 deletions
diff --git a/net/third_party/nss/ssl.gyp b/net/third_party/nss/ssl.gyp index d6e2253..64d8551 100644 --- a/net/third_party/nss/ssl.gyp +++ b/net/third_party/nss/ssl.gyp @@ -79,6 +79,12 @@ 'USE_UTIL_DIRECTLY', ], 'msvs_disabled_warnings': [4018, 4244, 4267], + 'variables': { + 'clang_warning_flags_unset': [ + # ssl uses PR_ASSERT(!"foo") instead of PR_ASSERT(false && "foo") + '-Wstring-conversion', + ], + }, 'conditions': [ ['component == "shared_library"', { 'conditions': [ diff --git a/net/third_party/nss/ssl/BUILD.gn b/net/third_party/nss/ssl/BUILD.gn index b8fe40f..c958c13 100644 --- a/net/third_party/nss/ssl/BUILD.gn +++ b/net/third_party/nss/ssl/BUILD.gn @@ -8,14 +8,6 @@ config("ssl_config") { if (is_mac || is_win) { defines = [ "NSS_PLATFORM_CLIENT_AUTH" ] } - - if (is_clang) { - cflags = [ - # There is a broken header guard in /usr/include/nss/secmod.h: - # https://bugzilla.mozilla.org/show_bug.cgi?id=884072 - "-Wno-header-guard", - ] - } } component("libssl") { @@ -105,6 +97,11 @@ component("libssl") { libs = [ "Security.framework" ] } + if (is_clang) { + # SSL triggers some of these Clang warnings. + configs -= [ "//build/config/clang:extra_warnings" ] + } + if (is_posix) { sources -= [ "win32err.c", diff --git a/third_party/mesa/BUILD.gn b/third_party/mesa/BUILD.gn index 48b772c..511525a 100644 --- a/third_party/mesa/BUILD.gn +++ b/third_party/mesa/BUILD.gn @@ -679,6 +679,11 @@ shared_library("osmesa") { include_dirs = [ "src/src/mesa/drivers" ] + if (is_clang) { + # Mesa triggers some of these Clang warnings. + configs -= [ "//build/config/clang:extra_warnings" ] + } + deps = [ ":mesa_headers", ":mesa", diff --git a/third_party/mesa/mesa.gyp b/third_party/mesa/mesa.gyp index bc115e1..3db0d4c 100644 --- a/third_party/mesa/mesa.gyp +++ b/third_party/mesa/mesa.gyp @@ -700,6 +700,12 @@ 'src/src/mesa/drivers/osmesa/osmesa.c', 'src/src/mesa/drivers/osmesa/osmesa.def', ], + 'variables': { + 'clang_warning_flags_unset': [ + # Don't warn about string->bool used in asserts. + '-Wstring-conversion', + ], + }, }, ], 'conditions': [ |