|
1 |
| -From 75b620ad19491a1f8b8e9ec891d242d017016972 Mon Sep 17 00:00:00 2001 |
| 1 | +From fc3a1af7d8d6ed6bc54d096e72cbf3d35ff4fa97 Mon Sep 17 00:00:00 2001 |
2 | 2 | From: Khem Raj < [email protected]>
|
3 | 3 | Date: Wed, 4 Dec 2019 19:06:54 -0800
|
4 | 4 | Subject: [PATCH] Delete compiler options not available in release versions of
|
5 | 5 | clang _yet_
|
6 | 6 |
|
| 7 | +* CREL feature is not supported on the current clang toolchain version, |
| 8 | + which causes build to fail with the following error: |
| 9 | + |
| 10 | +| clang++: error: unsupported argument '--crel' to option '-Wa,' |
| 11 | +| clang++: error: unsupported argument '--allow-experimental-crel' |
| 12 | + to option '-Wa,' |
| 13 | + |
7 | 14 | Upstream-Status: Inappropriate [ clang/master already supports them ]
|
8 | 15 | Signed-off-by: Khem Raj < [email protected]>
|
9 | 16 | Signed-off-by: Randy MacLeod < [email protected]>
|
| 17 | +Signed-off-by: Ariel D'Alessandro < [email protected]> |
10 | 18 |
|
11 | 19 | ---
|
12 |
| - build/config/compiler/BUILD.gn | 5 +++++ |
13 |
| - 1 file changed, 5 insertions(+) |
| 20 | + build/config/compiler/BUILD.gn | 13 +++++-------- |
| 21 | + 1 file changed, 5 insertions(+), 8 deletions(-) |
14 | 22 |
|
15 | 23 | diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn
|
16 |
| -index 309c3078a2..8951f6006c 100644 |
| 24 | +index 309c3078a2647..5eeb241fc9038 100644 |
17 | 25 | --- a/build/config/compiler/BUILD.gn
|
18 | 26 | +++ b/build/config/compiler/BUILD.gn
|
19 |
| -@@ -1924,6 +1924,11 @@ config("default_warnings") { |
| 27 | +@@ -615,14 +615,6 @@ config("compiler") { |
| 28 | + } else { |
| 29 | + cflags += [ "-ffp-contract=off" ] |
| 30 | + } |
| 31 | +- |
| 32 | +- # Enable ELF CREL (see crbug.com/357878242) for all platforms that use ELF |
| 33 | +- # (excluding toolchains that use an older version of LLVM). |
| 34 | +- # TODO(crbug.com/376278218): This causes segfault on Linux ARM builds. |
| 35 | +- if (is_linux && !llvm_android_mainline && current_cpu != "arm" && |
| 36 | +- default_toolchain != "//build/toolchain/cros:target") { |
| 37 | +- cflags += [ "-Wa,--crel,--allow-experimental-crel" ] |
| 38 | +- } |
| 39 | + } |
| 40 | + |
| 41 | + # C11/C++11 compiler flags setup. |
| 42 | +@@ -1924,6 +1916,11 @@ config("default_warnings") { |
20 | 43 | }
|
21 | 44 |
|
22 | 45 | cflags += [
|
|
0 commit comments