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/chrome_build.gni") | 6 import("//build/config/chrome_build.gni") |
7 import("//build/config/compiler/compiler.gni") | 7 import("//build/config/compiler/compiler.gni") |
8 import("//build/config/nacl/config.gni") | 8 import("//build/config/nacl/config.gni") |
9 import("//build/toolchain/cc_wrapper.gni") | 9 import("//build/toolchain/cc_wrapper.gni") |
10 import("//build/toolchain/toolchain.gni") | 10 import("//build/toolchain/toolchain.gni") |
(...skipping 399 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
410 } | 410 } |
411 | 411 |
412 # Allows the linker to apply ICF to the LTO object file. Also, when | 412 # Allows the linker to apply ICF to the LTO object file. Also, when |
413 # targeting ARM, without this flag, LTO produces a .text section that is | 413 # targeting ARM, without this flag, LTO produces a .text section that is |
414 # larger than the maximum call displacement, preventing the linker from | 414 # larger than the maximum call displacement, preventing the linker from |
415 # relocating calls (http://llvm.org/PR22999). | 415 # relocating calls (http://llvm.org/PR22999). |
416 if (is_linux) { | 416 if (is_linux) { |
417 ldflags += [ "-Wl,-plugin-opt,-function-sections" ] | 417 ldflags += [ "-Wl,-plugin-opt,-function-sections" ] |
418 } | 418 } |
419 | 419 |
420 arflags = [ | |
421 "--plugin", | |
422 rebase_path("//third_party/llvm-build/Release+Asserts/lib/LLVMgold.so", | |
423 root_build_dir), | |
424 ] | |
brucedawson
2016/04/19 20:59:32
This arflags initialization is under "if (!is_debu
| |
425 | |
420 # TODO(pcc): Make these flags work correctly with CFI. | 426 # TODO(pcc): Make these flags work correctly with CFI. |
421 if (!is_cfi) { | 427 if (!is_cfi) { |
422 cflags += [ | 428 cflags += [ |
423 "-fwhole-program-vtables", | 429 "-fwhole-program-vtables", |
424 | 430 |
425 # TODO(pcc): Remove this flag once the upstream interface change | 431 # TODO(pcc): Remove this flag once the upstream interface change |
426 # (http://reviews.llvm.org/D18635) lands. | 432 # (http://reviews.llvm.org/D18635) lands. |
427 "-fwhole-program-vtables-blacklist=" + | 433 "-fwhole-program-vtables-blacklist=" + |
428 rebase_path("//tools/cfi/blacklist.txt", root_build_dir), | 434 rebase_path("//tools/cfi/blacklist.txt", root_build_dir), |
429 ] | 435 ] |
(...skipping 970 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1400 | 1406 |
1401 if (is_ios || is_mac) { | 1407 if (is_ios || is_mac) { |
1402 # On Mac and iOS, this enables support for ARC (automatic ref-counting). | 1408 # On Mac and iOS, this enables support for ARC (automatic ref-counting). |
1403 # See http://clang.llvm.org/docs/AutomaticReferenceCounting.html. | 1409 # See http://clang.llvm.org/docs/AutomaticReferenceCounting.html. |
1404 config("enable_arc") { | 1410 config("enable_arc") { |
1405 common_flags = [ "-fobjc-arc" ] | 1411 common_flags = [ "-fobjc-arc" ] |
1406 cflags_objc = common_flags | 1412 cflags_objc = common_flags |
1407 cflags_objcc = common_flags | 1413 cflags_objcc = common_flags |
1408 } | 1414 } |
1409 } | 1415 } |
OLD | NEW |