OLD | NEW |
1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 import("//build/config/android/config.gni") | 5 import("//build/config/android/config.gni") |
6 if (cpu_arch == "arm") { | 6 if (cpu_arch == "arm") { |
7 import("//build/config/arm.gni") | 7 import("//build/config/arm.gni") |
8 } | 8 } |
9 | 9 |
10 # compiler --------------------------------------------------------------------- | 10 # compiler --------------------------------------------------------------------- |
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
141 "-fPIC", | 141 "-fPIC", |
142 "-pipe", # Use pipes for communicating between sub-processes. Faster. | 142 "-pipe", # Use pipes for communicating between sub-processes. Faster. |
143 ] | 143 ] |
144 if (!is_android) { | 144 if (!is_android) { |
145 cflags += [ "-pthread" ] | 145 cflags += [ "-pthread" ] |
146 } | 146 } |
147 | 147 |
148 if (cpu_arch == "x64") { | 148 if (cpu_arch == "x64") { |
149 # Use gold for linking on 64-bit Linux only (on 32-bit it runs out of | 149 # Use gold for linking on 64-bit Linux only (on 32-bit it runs out of |
150 # address space, and it doesn't support cross-compiling). | 150 # address space, and it doesn't support cross-compiling). |
151 gold_path = rebase_path("//third_party/gold", ".", root_build_dir) | 151 gold_path = rebase_path("//third_party/gold", root_build_dir) |
152 ldflags += [ | 152 ldflags += [ |
153 "-B$gold_path", | 153 "-B$gold_path", |
154 | 154 |
155 # There seems to be a conflict of --icf and -pie in gold which can | 155 # There seems to be a conflict of --icf and -pie in gold which can |
156 # generate crashy binaries. As a security measure, -pie takes | 156 # generate crashy binaries. As a security measure, -pie takes |
157 # precendence for now. | 157 # precendence for now. |
158 # TODO(brettw) common.gypi has this only for target toolset. | 158 # TODO(brettw) common.gypi has this only for target toolset. |
159 #"-Wl,--icf=safe", | 159 #"-Wl,--icf=safe", |
160 "-Wl,--icf=none", | 160 "-Wl,--icf=none", |
161 | 161 |
(...skipping 491 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
653 cflags = [ "-g1" ] | 653 cflags = [ "-g1" ] |
654 } | 654 } |
655 } | 655 } |
656 | 656 |
657 config("no_symbols") { | 657 config("no_symbols") { |
658 if (!is_win) { | 658 if (!is_win) { |
659 cflags = [ "-g0" ] | 659 cflags = [ "-g0" ] |
660 } | 660 } |
661 } | 661 } |
662 | 662 |
OLD | NEW |