Skip to content

Commit 59f78a4

Browse files
committed
Fix issue with cc
1 parent b73e930 commit 59f78a4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/cc.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ impl CompileCommand {
7272
}
7373
pub fn build(&self) -> Result<Command, cc::Error> {
7474
let mut build = cc::Build::new();
75-
build.opt_level(0).cargo_metadata(false).warnings(false);
75+
build.opt_level(0).cargo_metadata(false).warnings(false).host(env!("HOST"));
7676
let default = inkwell::targets::TargetMachine::get_default_triple();
7777
let default = default.as_str().to_str().unwrap();
7878
build.target(self.target_.as_deref().unwrap_or(default));
@@ -85,4 +85,4 @@ impl CompileCommand {
8585
else {panic!("C compiler is not like Clang, GNU, or MSVC!")}
8686
Ok(cmd)
8787
}
88-
}
88+
}

0 commit comments

Comments
 (0)