gn build: Use target OS to control whether to use/depend on llvm-ar.
When cross-compiling from Mac to non-Mac, we need to use the just-built llvm-ar instead of libtool. We're currently doing the right thing when determining which archiver command to use, but the path to ar and the toolchain dependencies were being set based on the host OS (current_os evaluated in host OS toolchain), instead of the target OS. Fix the problem by looking up current_os inside toolchain_args. Differential Revision: https://reviews.llvm.org/D123244
Loading
Please register or sign in to comment