add windows flags

This commit is contained in:
pyranota
2025-04-11 15:55:07 +02:00
parent f107936d44
commit d39b870b2a
@@ -221,6 +221,15 @@ pub async fn build_rust_crate(
.stdout(Stdio::piped())
.stderr(Stdio::piped());
#[cfg(windows)]
{
sweep_cmd.env("SystemRoot", SYSTEM_ROOT.as_str());
sweep_cmd.env(
"TMP",
std::env::var("TMP").unwrap_or_else(|_| "C:\\tmp".to_string()),
);
sweep_cmd.env("USERPROFILE", crate::USERPROFILE_ENV.as_str());
}
if let Err(e) = match start_child_process(sweep_cmd, CARGO_SWEEP_PATH.as_str()).await {
Ok(sweep_process) => {
handle_child(