Skip to content

Commit 1c5defa

Browse files
committed
Don't erase all env vars, they are needed on linux
1 parent 1251340 commit 1c5defa

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

tests/compiletest.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ fn run_tests(mode: Mode, path: &str, target: Option<String>) -> Result<()> {
6868
std::env::current_dir()?.join("miri").display().to_string(),
6969
"cargo".to_string(),
7070
],
71-
envs: vec![("MIRI_SYSROOT".to_string(), std::env::var("MIRI_SYSROOT").unwrap())],
71+
envs: vec![],
7272
}),
7373
};
7474
ui_test::run_tests(config)

ui_test/src/dependencies.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,10 @@ pub fn build_dependencies(config: &Config) -> Result<Vec<(String, PathBuf)>> {
1717
None => (Path::new("cargo"), &[], &[]),
1818
};
1919
let mut build = Command::new(program);
20-
build.env_clear();
21-
build.env("PATH", std::env::var_os("PATH").unwrap());
20+
21+
// Avoid poisoning the sysroot and causing unnecessary rebuilds.
22+
build.env_remove("RUSTFLAGS");
23+
2224
build.envs(envs.iter().map(|(k, v)| (k, v)));
2325
build.args(args);
2426
build.arg("run");

0 commit comments

Comments
 (0)