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 import("//build/config/sysroot.gni") | 6 import("//build/config/sysroot.gni") |
7 | 7 |
8 # compiler --------------------------------------------------------------------- | 8 # compiler --------------------------------------------------------------------- |
9 # | 9 # |
10 # Base compiler configuration. | 10 # Base compiler configuration. |
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
121 if (is_linux) { | 121 if (is_linux) { |
122 cflags += [ | 122 cflags += [ |
123 "-fPIC", | 123 "-fPIC", |
124 "-pipe", # Use pipes for communicating between sub-processes. Faster. | 124 "-pipe", # Use pipes for communicating between sub-processes. Faster. |
125 ] | 125 ] |
126 if (!is_android) { | 126 if (!is_android) { |
127 cflags += [ "-pthread" ] | 127 cflags += [ "-pthread" ] |
128 } | 128 } |
129 | 129 |
130 if (cpu_arch == "x64") { | 130 if (cpu_arch == "x64") { |
131 # Enable libstdc++ debugging facilities to help catch problems early, see | |
132 # http://crbug.com/65151 . | |
133 # TODO(phajdan.jr): Should we enable this for all of POSIX? | |
134 defines += [ "_GLIBCXX_DEBUG=1" ] | |
135 | |
136 # Use gold for linking on 64-bit Linux only (on 32-bit it runs out of | 131 # Use gold for linking on 64-bit Linux only (on 32-bit it runs out of |
137 # address space, and it doesn't support cross-compiling). | 132 # address space, and it doesn't support cross-compiling). |
138 gold_path = rebase_path("//third_party/gold", ".", root_build_dir) | 133 gold_path = rebase_path("//third_party/gold", ".", root_build_dir) |
139 ldflags += [ | 134 ldflags += [ |
140 "-B$gold_path", | 135 "-B$gold_path", |
141 | 136 |
142 # There seems to be a conflict of --icf and -pie in gold which can | 137 # There seems to be a conflict of --icf and -pie in gold which can |
143 # generate crashy binaries. As a security measure, -pie takes | 138 # generate crashy binaries. As a security measure, -pie takes |
144 # precendence for now. | 139 # precendence for now. |
145 # TODO(brettw) common.gypi has this only for target toolset. | 140 # TODO(brettw) common.gypi has this only for target toolset. |
(...skipping 471 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
617 } else { | 612 } else { |
618 cflags = [ "-g1" ] | 613 cflags = [ "-g1" ] |
619 } | 614 } |
620 } | 615 } |
621 | 616 |
622 config("no_symbols") { | 617 config("no_symbols") { |
623 if (!is_win) { | 618 if (!is_win) { |
624 cflags = [ "-g0" ] | 619 cflags = [ "-g0" ] |
625 } | 620 } |
626 } | 621 } |
OLD | NEW |