diff --git a/src/lib.rs b/src/lib.rs index 5bccca215..17a9c057d 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -2472,7 +2472,7 @@ impl Build { let target = self.get_target()?; let (mut cmd, program, any_flags) = self.get_ar()?; - if target.contains("msvc") && !program.to_string_lossy().contains("llvm-") { + if target.contains("msvc") && !program.to_string_lossy().contains("llvm-ar") { // NOTE: -out: here is an I/O flag, and so must be included even if $ARFLAGS/ar_flag is // in use. -nologo on the other hand is just a regular flag, and one that we'll skip if // the caller has explicitly dictated the flags they want. See