Browse Source
Merge pull request #307 from mixi/master
Pass -static depending on crt-static on linux too.
cl-test
Alex Crichton
7 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
5 additions and
2 deletions
-
src/lib.rs
|
|
@ -1106,9 +1106,12 @@ impl Build { |
|
|
|
cmd.args.push("-m64".into()); |
|
|
|
} |
|
|
|
|
|
|
|
if self.static_flag.is_none() && target.contains("musl") { |
|
|
|
if self.static_flag.is_none() { |
|
|
|
let features = env::var("CARGO_CFG_TARGET_FEATURE").unwrap_or(String::new()); |
|
|
|
if features.contains("crt-static") { |
|
|
|
cmd.args.push("-static".into()); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
// armv7 targets get to use armv7 instructions
|
|
|
|
if target.starts_with("armv7-") && target.contains("-linux-") { |
|
|
|