| 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/clang/clang.gni") |
| 5 import("//build/config/nacl/config.gni") | 6 import("//build/config/nacl/config.gni") |
| 6 import("//build/config/sanitizers/sanitizers.gni") | 7 import("//build/config/sanitizers/sanitizers.gni") |
| 7 import("//build/toolchain/cc_wrapper.gni") | 8 import("//build/toolchain/cc_wrapper.gni") |
| 8 import("//build/toolchain/goma.gni") | 9 import("//build/toolchain/goma.gni") |
| 9 import("//build/toolchain/toolchain.gni") | 10 import("//build/toolchain/toolchain.gni") |
| 10 import("//build/toolchain/concurrent_links.gni") | 11 import("//build/toolchain/concurrent_links.gni") |
| 11 | 12 |
| 12 # This template defines a toolchain for something that works like gcc | 13 # This template defines a toolchain for something that works like gcc |
| 13 # (including clang). | 14 # (including clang). |
| 14 # | 15 # |
| (...skipping 488 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 503 "clang_toolchain() must specify a \"toolchain_cpu\"") | 504 "clang_toolchain() must specify a \"toolchain_cpu\"") |
| 504 assert(defined(invoker.toolchain_os), | 505 assert(defined(invoker.toolchain_os), |
| 505 "clang_toolchain() must specify a \"toolchain_os\"") | 506 "clang_toolchain() must specify a \"toolchain_os\"") |
| 506 if (defined(invoker.toolprefix)) { | 507 if (defined(invoker.toolprefix)) { |
| 507 toolprefix = invoker.toolprefix | 508 toolprefix = invoker.toolprefix |
| 508 } else { | 509 } else { |
| 509 toolprefix = "" | 510 toolprefix = "" |
| 510 } | 511 } |
| 511 | 512 |
| 512 gcc_toolchain(target_name) { | 513 gcc_toolchain(target_name) { |
| 513 prefix = rebase_path("//third_party/llvm-build/Release+Asserts/bin", | 514 prefix = rebase_path("$clang_base_path/bin", root_build_dir) |
| 514 root_build_dir) | |
| 515 cc = "$prefix/clang" | 515 cc = "$prefix/clang" |
| 516 cxx = "$prefix/clang++" | 516 cxx = "$prefix/clang++" |
| 517 ld = cxx | 517 ld = cxx |
| 518 is_clang = true | 518 is_clang = true |
| 519 | 519 |
| 520 readelf = "${toolprefix}readelf" | 520 readelf = "${toolprefix}readelf" |
| 521 ar = "${toolprefix}ar" | 521 ar = "${toolprefix}ar" |
| 522 nm = "${toolprefix}nm" | 522 nm = "${toolprefix}nm" |
| 523 | 523 |
| 524 forward_variables_from(invoker, | 524 forward_variables_from(invoker, |
| 525 [ | 525 [ |
| 526 "toolchain_cpu", | 526 "toolchain_cpu", |
| 527 "toolchain_os", | 527 "toolchain_os", |
| 528 "use_gold", | 528 "use_gold", |
| 529 "strip", | 529 "strip", |
| 530 ]) | 530 ]) |
| 531 | 531 |
| 532 if (defined(invoker.use_debug_fission)) { | 532 if (defined(invoker.use_debug_fission)) { |
| 533 use_debug_fission = invoker.use_debug_fission | 533 use_debug_fission = invoker.use_debug_fission |
| 534 } | 534 } |
| 535 } | 535 } |
| 536 } | 536 } |
| OLD | NEW |