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

Unified Diff: third_party/mach_override/BUILD.gn

Issue 1557733002: Prepare for -Wall for third-party code, -Wextra for chromium_code (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 12 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
« no previous file with comments | « third_party/harfbuzz-ng/src/hb-coretext.cc ('k') | third_party/mach_override/mach_override.gyp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/mach_override/BUILD.gn
diff --git a/third_party/mach_override/BUILD.gn b/third_party/mach_override/BUILD.gn
index 4672c4639f36fe23209096583fb4431b268de971..ed1c3316a998d60c86a17a799ccdb1fd806c71e7 100644
--- a/third_party/mach_override/BUILD.gn
+++ b/third_party/mach_override/BUILD.gn
@@ -2,6 +2,19 @@
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
+config("libudis86_warnings") {
+ if (is_clang) {
+ cflags = [
+ # syn.c contains a switch with an assert(false) in a default:
+ # block. In release builds, the function is missing a return.
+ "-Wno-return-type",
+
+ # Fires once in decode.c.
+ "-Wno-sometimes-uninitialized",
+ ]
+ }
+}
+
static_library("libudis86") {
sources = [
"libudis86/decode.c",
@@ -29,7 +42,12 @@ static_library("libudis86") {
cflags = [ "-Wno-return-type" ]
configs -= [ "//build/config/compiler:chromium_code" ]
- configs += [ "//build/config/compiler:no_chromium_code" ]
+ configs += [
+ "//build/config/compiler:no_chromium_code",
+
+ # Must be after no_chromium_code for warning flags to be ordered correctly.
+ ":libudis86_warnings",
+ ]
if (is_clang) {
# For UD_ASSERT(!"message");
« no previous file with comments | « third_party/harfbuzz-ng/src/hb-coretext.cc ('k') | third_party/mach_override/mach_override.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698