| Index: build/toolchain/mac/BUILD.gn
|
| diff --git a/build/toolchain/mac/BUILD.gn b/build/toolchain/mac/BUILD.gn
|
| index 75e84d88eb0b0f25a6de0a5083c751612b611f00..c7dd43a9aa1e1c2e67ad267c77cb73f0d83dcef7 100644
|
| --- a/build/toolchain/mac/BUILD.gn
|
| +++ b/build/toolchain/mac/BUILD.gn
|
| @@ -32,6 +32,13 @@ if (current_toolchain == default_toolchain) {
|
| }
|
| }
|
|
|
| +if (is_clang_xcode) {
|
| + _clang_prefix = ""
|
| +} else {
|
| + _clang_prefix = rebase_path("//third_party/llvm-build/Release+Asserts/bin/",
|
| + root_build_dir)
|
| +}
|
| +
|
| # This will copy the gyp-mac-tool to the build directory. We pass in the source
|
| # file of the mac tool.
|
| gyp_mac_tool_source =
|
| @@ -350,81 +357,71 @@ template("mac_toolchain") {
|
| mac_toolchain("clang_arm") {
|
| toolchain_cpu = "arm"
|
| toolchain_os = "mac"
|
| - prefix = rebase_path("//third_party/llvm-build/Release+Asserts/bin",
|
| - root_build_dir)
|
| - cc = "${goma_prefix}$prefix/clang"
|
| - cxx = "${goma_prefix}$prefix/clang++"
|
| + cc = "${goma_prefix}${_clang_prefix}clang"
|
| + cxx = "${goma_prefix}${_clang_prefix}clang++"
|
| ld = cxx
|
| is_clang = true
|
| }
|
|
|
| -mac_toolchain("ios_clang_arm") {
|
| +mac_toolchain("arm") {
|
| toolchain_cpu = "arm"
|
| toolchain_os = "mac"
|
| -
|
| - # TODO(GYP): We need to support being able to use the version of clang
|
| - # shipped w/ XCode instead of the one pulled from upstream.
|
| - prefix = rebase_path("//third_party/llvm-build/Release+Asserts/bin",
|
| - root_build_dir)
|
| - cc = "${goma_prefix}$prefix/clang"
|
| - cxx = "${goma_prefix}$prefix/clang++"
|
| + cc = "${goma_prefix}gcc"
|
| + cxx = "${goma_prefix}g++"
|
| ld = cxx
|
| - is_clang = true
|
| + is_clang = false
|
| }
|
|
|
| -mac_toolchain("ios_clang_armv7") {
|
| - toolchain_cpu = "armv7"
|
| +mac_toolchain("clang_x64") {
|
| + toolchain_cpu = "x64"
|
| toolchain_os = "mac"
|
| -
|
| - # TODO(GYP): We need to support being able to use the version of clang
|
| - # shipped w/ XCode instead of the one pulled from upstream.
|
| - prefix = rebase_path("//third_party/llvm-build/Release+Asserts/bin",
|
| - root_build_dir)
|
| - cc = "${goma_prefix}$prefix/clang"
|
| - cxx = "${goma_prefix}$prefix/clang++"
|
| + cc = "${goma_prefix}${_clang_prefix}clang"
|
| + cxx = "${goma_prefix}${_clang_prefix}clang++"
|
| ld = cxx
|
| is_clang = true
|
| }
|
|
|
| -mac_toolchain("ios_clang_arm64") {
|
| - toolchain_cpu = "arm64"
|
| +mac_toolchain("x64") {
|
| + toolchain_cpu = "x64"
|
| toolchain_os = "mac"
|
| + cc = "${goma_prefix}gcc"
|
| + cxx = "${goma_prefix}g++"
|
| + ld = cxx
|
| + is_clang = false
|
| +}
|
|
|
| - # TODO(GYP): We need to support being able to use the version of clang
|
| - # shipped w/ XCode instead of the one pulled from upstream.
|
| - prefix = rebase_path("//third_party/llvm-build/Release+Asserts/bin",
|
| - root_build_dir)
|
| - cc = "${goma_prefix}$prefix/clang"
|
| - cxx = "${goma_prefix}$prefix/clang++"
|
| +mac_toolchain("ios_clang_arm") {
|
| + toolchain_cpu = "arm"
|
| + toolchain_os = "mac"
|
| + cc = "${goma_prefix}${_clang_prefix}clang"
|
| + cxx = "${goma_prefix}${_clang_prefix}clang++"
|
| ld = cxx
|
| is_clang = true
|
| }
|
|
|
| -mac_toolchain("arm") {
|
| - toolchain_cpu = "arm"
|
| +mac_toolchain("ios_clang_arm64") {
|
| + toolchain_cpu = "arm64"
|
| toolchain_os = "mac"
|
| - cc = "${goma_prefix}/gcc"
|
| - cxx = "${goma_prefix}/g++"
|
| + cc = "${goma_prefix}${_clang_prefix}clang"
|
| + cxx = "${goma_prefix}${_clang_prefix}clang++"
|
| ld = cxx
|
| - is_clang = false
|
| + is_clang = true
|
| }
|
|
|
| -mac_toolchain("clang_x64") {
|
| - toolchain_cpu = "x64"
|
| +mac_toolchain("ios_clang_x86") {
|
| + toolchain_cpu = "x86"
|
| toolchain_os = "mac"
|
| - prefix = rebase_path("//third_party/llvm-build/Release+Asserts/bin",
|
| - root_build_dir)
|
| - cc = "${goma_prefix}$prefix/clang"
|
| - cxx = "${goma_prefix}$prefix/clang++"
|
| + cc = "${goma_prefix}${_clang_prefix}clang"
|
| + cxx = "${goma_prefix}${_clang_prefix}clang++"
|
| ld = cxx
|
| is_clang = true
|
| }
|
|
|
| -mac_toolchain("x64") {
|
| +mac_toolchain("ios_clang_x64") {
|
| toolchain_cpu = "x64"
|
| toolchain_os = "mac"
|
| - cc = "${goma_prefix}/gcc"
|
| - cxx = "${goma_prefix}/g++"
|
| + cc = "${goma_prefix}${_clang_prefix}clang"
|
| + cxx = "${goma_prefix}${_clang_prefix}clang++"
|
| ld = cxx
|
| - is_clang = false
|
| + is_clang = true
|
| }
|
|
|