| 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 # ============================================================================= | 5 # ============================================================================= |
| 6 # PLATFORM SELECTION | 6 # PLATFORM SELECTION |
| 7 # ============================================================================= | 7 # ============================================================================= |
| 8 # | 8 # |
| 9 # There are two main things to set: "os" and "cpu". The "toolchain" is the name | 9 # There are two main things to set: "os" and "cpu". The "toolchain" is the name |
| 10 # of the GN thing that encodes combinations of these things. | 10 # of the GN thing that encodes combinations of these things. |
| (...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 186 | 186 |
| 187 if (target_os == "android") { | 187 if (target_os == "android") { |
| 188 assert(host_os == "linux" || host_os == "mac", | 188 assert(host_os == "linux" || host_os == "mac", |
| 189 "Android builds are only supported on Linux and Mac hosts.") | 189 "Android builds are only supported on Linux and Mac hosts.") |
| 190 if (is_clang) { | 190 if (is_clang) { |
| 191 _default_toolchain = "//build/toolchain/android:clang_$target_cpu" | 191 _default_toolchain = "//build/toolchain/android:clang_$target_cpu" |
| 192 } else { | 192 } else { |
| 193 _default_toolchain = "//build/toolchain/android:$target_cpu" | 193 _default_toolchain = "//build/toolchain/android:$target_cpu" |
| 194 } | 194 } |
| 195 } else if (target_os == "chromeos") { | 195 } else if (target_os == "chromeos") { |
| 196 # See comments in build/toolchain/cros/BUILD.gn about board compiles. |
| 196 assert(host_os == "linux", | 197 assert(host_os == "linux", |
| 197 "ChromeOS builds are only supported on Linux hosts.") | 198 "ChromeOS builds are only supported on Linux hosts.") |
| 198 if (is_clang) { | 199 if (is_clang) { |
| 199 _default_toolchain = "//build/toolchain/linux:clang_$target_cpu" | 200 _default_toolchain = "//build/toolchain/cros:clang_target" |
| 200 } else { | 201 } else { |
| 201 _default_toolchain = "//build/toolchain/linux:$target_cpu" | 202 _default_toolchain = "//build/toolchain/cros:target" |
| 202 } | 203 } |
| 203 } else if (target_os == "ios") { | 204 } else if (target_os == "ios") { |
| 204 _default_toolchain = "//build/toolchain/mac:ios_clang_arm" | 205 _default_toolchain = "//build/toolchain/mac:ios_clang_arm" |
| 205 } else if (target_os == "linux") { | 206 } else if (target_os == "linux") { |
| 206 if (is_clang) { | 207 if (is_clang) { |
| 207 _default_toolchain = "//build/toolchain/linux:clang_$target_cpu" | 208 _default_toolchain = "//build/toolchain/linux:clang_$target_cpu" |
| 208 } else { | 209 } else { |
| 209 _default_toolchain = "//build/toolchain/linux:$target_cpu" | 210 _default_toolchain = "//build/toolchain/linux:$target_cpu" |
| 210 } | 211 } |
| 211 } else if (target_os == "mac") { | 212 } else if (target_os == "mac") { |
| (...skipping 381 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 593 forward_variables_from(invoker, "*") | 594 forward_variables_from(invoker, "*") |
| 594 | 595 |
| 595 # All shared libraries must have the sanitizer deps to properly link in | 596 # All shared libraries must have the sanitizer deps to properly link in |
| 596 # asan mode (this target will be empty in other cases). | 597 # asan mode (this target will be empty in other cases). |
| 597 if (!defined(deps)) { | 598 if (!defined(deps)) { |
| 598 deps = [] | 599 deps = [] |
| 599 } | 600 } |
| 600 deps += [ "//build/config/sanitizers:deps" ] | 601 deps += [ "//build/config/sanitizers:deps" ] |
| 601 } | 602 } |
| 602 } | 603 } |
| OLD | NEW |