Commit ea5d6db4 authored by Erik Chen's avatar Erik Chen Committed by Commit Bot

Add explicit search path for linker on macOS.

Linking on macOS is invoked via clang++. If clang++ cannot find ld on the
default search path, clang++ will invoke xcrun to search for ld. This CL
explicitly passes the path to ld if we're using hermetic xcode. This way clang++
will not invoke xcrun.

Bug: 971452
Change-Id: I5bcaa577d9ccc6d3ceca6e2524482e299b371e92
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1649179Reviewed-by: default avatarNico Weber <thakis@chromium.org>
Commit-Queue: Erik Chen <erikchen@chromium.org>
Cr-Commit-Position: refs/heads/master@{#667154}
parent bcdbc4c8
......@@ -125,6 +125,10 @@ template("mac_toolchain") {
cxx = compiler_prefix + _cxx
ld = _cxx
# Set the explicit search path for clang++ so it uses the right linker
# binary.
ld += " -B " + mac_bin_path
if (defined(toolchain_args.coverage_instrumentation_input_file)) {
toolchain_coverage_instrumentation_input_file =
toolchain_args.coverage_instrumentation_input_file
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment