Skip to content

Commit 0667f1c

Browse files
committed
rustbuild: Pass -fPIC on 32-bit non-Windows platforms
This is a smaller and more targeted backport of rust-lang#39523 which drives to the heart of the issue, just passing `-fPIC` on 32-bit platforms. More rationale for this commit can be found in rust-lang#39523 itself.
1 parent d11639b commit 0667f1c

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/bootstrap/lib.rs

+5
Original file line numberDiff line numberDiff line change
@@ -812,6 +812,11 @@ impl Build {
812812
},
813813
_ => {},
814814
}
815+
816+
if !target.contains("windows") && target.contains("i686") {
817+
base.push("-fPIC".into());
818+
}
819+
815820
return base
816821
}
817822

0 commit comments

Comments
 (0)