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 81468be commit e94a533Copy full SHA for e94a533
src/lib.rs
@@ -505,9 +505,17 @@ impl Library {
505
let sysroot = config
506
.env_var_os("PKG_CONFIG_SYSROOT_DIR")
507
.or_else(|| config.env_var_os("SYSROOT"))
508
- .map(PathBuf::from)
509
- .unwrap_or_else(|| PathBuf::from("/usr"));
510
- vec![sysroot]
+ .map(PathBuf::from);
+
+ if cfg!(target_os = "windows") {
511
+ if let Some(sysroot) = sysroot {
512
+ vec![sysroot]
513
+ } else {
514
+ vec![]
515
+ }
516
517
+ vec![sysroot.unwrap_or_else(|| PathBuf::from("/usr"))]
518
519
};
520
521
let words = split_flags(output);
0 commit comments