mirror of
https://abf.rosa.ru/djam/chromium-browser-stable-test.git
synced 2025-02-24 01:52:45 +00:00
114 lines
3.5 KiB
Diff
114 lines
3.5 KiB
Diff
From a1207cc75454e653030716948d27ec27412f6fe8 Mon Sep 17 00:00:00 2001
|
|
From: Mike Gilbert <floppym@gentoo.org>
|
|
Date: Sat, 16 Jun 2019 15:43:27 +0100
|
|
Subject: [PATCH] Disable various compiler configs
|
|
|
|
---
|
|
build/config/compiler/BUILD.gn | 64 +++++++++++++---------------------
|
|
1 file changed, 25 insertions(+), 39 deletions(-)
|
|
|
|
diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn
|
|
--- a/build/config/compiler/BUILD.gn
|
|
+++ b/build/config/compiler/BUILD.gn
|
|
@@ -256,8 +256,6 @@
|
|
|
|
configs += [
|
|
# See the definitions below.
|
|
- ":clang_revision",
|
|
- ":compiler_cpu_abi",
|
|
":compiler_codegen",
|
|
":compiler_deterministic",
|
|
]
|
|
@@ -478,20 +476,6 @@
|
|
# platforms can be added later if needed.
|
|
if (is_linux && use_lld && use_text_section_splitting) {
|
|
ldflags += [ "-Wl,-z,keep-text-section-prefix" ]
|
|
- }
|
|
-
|
|
- if (is_clang && !is_nacl && !use_xcode_clang) {
|
|
- cflags += [ "-fcrash-diagnostics-dir=" +
|
|
- rebase_path("//tools/clang/crashreports", root_build_dir) ]
|
|
-
|
|
- cflags += [
|
|
- # TODO(hans): Remove this once Clang generates better optimized debug info
|
|
- # by default. https://crbug.com/765793
|
|
- "-Xclang",
|
|
- "-mllvm",
|
|
- "-Xclang",
|
|
- "-instcombine-lower-dbg-declare=0",
|
|
- ]
|
|
}
|
|
|
|
# C11/C++11 compiler flags setup.
|
|
@@ -1512,22 +1512,12 @@
|
|
|
|
# TODO(https://crbug.com/1028110): Evaluate and possible enable.
|
|
"-Wno-deprecated-copy",
|
|
-
|
|
- # TODO(https://crbug.com/1050281): Clean up, enable.
|
|
- "-Wno-non-c-typedef-for-linkage",
|
|
]
|
|
|
|
cflags_c += [
|
|
# TODO(https://crbug.com/995993): Clean up and enable.
|
|
"-Wno-implicit-fallthrough",
|
|
]
|
|
-
|
|
- if (enable_wmax_tokens) {
|
|
- cflags += [ "-Wmax-tokens" ]
|
|
- } else {
|
|
- # TODO(https://crbug.com/1049569): Remove after Clang 87b235db.
|
|
- cflags += [ "-Wno-max-tokens" ]
|
|
- }
|
|
}
|
|
}
|
|
}
|
|
@@ -1547,7 +1494,7 @@
|
|
defines = [ "_HAS_NODISCARD" ]
|
|
}
|
|
} else {
|
|
- cflags = [ "-Wall" ]
|
|
+ cflags = []
|
|
if (treat_warnings_as_errors) {
|
|
cflags += [ "-Werror" ]
|
|
|
|
@@ -1555,10 +1502,6 @@
|
|
# the actual linker. Make sure these warnings are treated as errors as
|
|
# well.
|
|
ldflags = [ "-Werror" ]
|
|
- }
|
|
- if (is_clang) {
|
|
- # Enable extra warnings for chromium_code when we control the compiler.
|
|
- cflags += [ "-Wextra" ]
|
|
}
|
|
|
|
# In Chromium code, we define __STDC_foo_MACROS in order to get the
|
|
@@ -1567,15 +1510,6 @@
|
|
"__STDC_CONSTANT_MACROS",
|
|
"__STDC_FORMAT_MACROS",
|
|
]
|
|
-
|
|
- if (!is_debug && !using_sanitizer && current_cpu != "s390x" &&
|
|
- current_cpu != "s390" && current_cpu != "ppc64" &&
|
|
- current_cpu != "mips" && current_cpu != "mips64") {
|
|
- # Non-chromium code is not guaranteed to compile cleanly with
|
|
- # _FORTIFY_SOURCE. Also, fortified build may fail when optimizations are
|
|
- # disabled, so only do that for Release build.
|
|
- defines += [ "_FORTIFY_SOURCE=2" ]
|
|
- }
|
|
|
|
if (is_mac) {
|
|
cflags_objc = [ "-Wobjc-missing-property-synthesis" ]
|
|
@@ -1662,12 +1596,6 @@
|
|
# suppressing them individually, we just blanket suppress them here.
|
|
"-Wno-unused-variable",
|
|
]
|
|
- if (!is_nacl && (current_toolchain == host_toolchain || !use_xcode_clang)) {
|
|
- cflags += [
|
|
- # TODO(https://crbug.com/1031169): Clean up and enable.
|
|
- "-Wno-misleading-indentation",
|
|
- ]
|
|
- }
|
|
}
|
|
|
|
configs = [ ":default_warnings" ]
|