mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-21 22:34:05 +00:00
Add system libs when cross compiling for Windows
This commit is contained in:
parent
1ae268816c
commit
7223fd8085
@ -220,7 +220,10 @@ fn main() {
|
|||||||
let mut cmd = Command::new(&llvm_config);
|
let mut cmd = Command::new(&llvm_config);
|
||||||
cmd.arg(llvm_link_arg).arg("--libs");
|
cmd.arg(llvm_link_arg).arg("--libs");
|
||||||
|
|
||||||
if !is_crossed {
|
// Don't link system libs if cross-compiling unless targetting Windows.
|
||||||
|
// On Windows system DLLs aren't linked directly, instead import libraries are used.
|
||||||
|
// These import libraries are independent of the host.
|
||||||
|
if !is_crossed || target.contains("windows") {
|
||||||
cmd.arg("--system-libs");
|
cmd.arg("--system-libs");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user