We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c591de6 commit 274732fCopy full SHA for 274732f
src/lib.rs
@@ -387,7 +387,11 @@ impl Build {
387
let mut cc = cc::Build::new();
388
cc.target(target).host(host).warnings(false).opt_level(2);
389
let compiler = cc.get_compiler();
390
- configure.env("CC", compiler.path());
+ let mut cc_env = compiler.cc_env();
391
+ if cc_env.is_empty() {
392
+ cc_env = compiler.path().to_path_buf().into_os_string();
393
+ }
394
+ configure.env("CC", cc_env);
395
let path = compiler.path().to_str().unwrap();
396
397
// Both `cc::Build` and `./Configure` take into account
0 commit comments