Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Correctly infer ranlib/ar for cross-gcc toolchains
A second try at alexcrichton#163. The GCC convention is that if the toolchain is named `$target-gnu-gcc`, then ranlib and ar will be available as `$target-gnu-gcc-ranlib` and `$target-gnu-gcc-ar` respectively. The code as written would infer them to be `$target-gnu-{ranlib,ar}`, which will only work if the tools from `binutils` (which follow that convention) are on `$PATH`. I've also updated the logic in line with the `cc` crate to check that the inferred `AR`/`RANLIB` is actually executable before setting it as an override. See also rust-lang/cc-rs#736.
- Loading branch information