From d48bd490c0091b1904791e4efa974a0a50bba29d Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Sat, 18 Mar 2023 11:07:37 -0700 Subject: [PATCH] Use `RUSTC_WRAPPER` instead of `CARGO_RUSTC_WRAPPER`. Similar to dtolnay/anyhow#248, and as suggested [here], check `RUSTC_WRAPPER` instead of `CARGO_RUSTC_WRAPPER`. [here]: https://github.com/bytecodealliance/rustix/pull/544#discussion_r1140467731 --- build.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.rs b/build.rs index 71ad66d..ab555ba 100644 --- a/build.rs +++ b/build.rs @@ -47,7 +47,7 @@ fn can_compile>(test: T) -> bool { let rustc = var("RUSTC").unwrap(); let target = var("TARGET").unwrap(); - let mut cmd = if let Ok(wrapper) = var("CARGO_RUSTC_WRAPPER") { + let mut cmd = if let Ok(wrapper) = var("RUSTC_WRAPPER") { let mut cmd = std::process::Command::new(wrapper); // The wrapper's first argument is supposed to be the path to rustc. cmd.arg(rustc);