Skip to content

Commit 3f0aa40

Browse files
authored
Use GNU AR for illumos (#585)
1 parent 3283434 commit 3f0aa40

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/lib.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2342,6 +2342,12 @@ impl Build {
23422342
Some(t) => return Ok((t, "lib.exe".to_string())),
23432343
None => "lib.exe".to_string(),
23442344
}
2345+
} else if target.contains("illumos") {
2346+
// The default 'ar' on illumos uses a non-standard flags,
2347+
// but the OS comes bundled with a GNU-compatible variant.
2348+
//
2349+
// Use the GNU-variant to match other Unix systems.
2350+
"gar".to_string()
23452351
} else if self.get_host()? != target {
23462352
match self.prefix_for_target(&target) {
23472353
Some(p) => {

0 commit comments

Comments
 (0)