Link openlibm only in libstd

This commit is contained in:
Jeremy Soller 2016-12-20 14:30:27 -07:00
parent 86f85c1399
commit 01157e6b3c
2 changed files with 2 additions and 4 deletions

View file

@ -33,10 +33,6 @@ pub fn opts() -> TargetOptions {
// Static link
"-static".to_string()
],
late_link_args: vec![
// Link to openlibm for math functions
"-lopenlibm".to_string()
],
executables: true,
relocation_model: "static".to_string(),
disable_redzone: true,

View file

@ -62,6 +62,8 @@ fn main() {
println!("cargo:rustc-link-lib=magenta");
println!("cargo:rustc-link-lib=mxio");
println!("cargo:rustc-link-lib=launchpad"); // for std::process
} else if target.contains("redox") {
println!("cargo:rustc-link-lib=openlibm");
}
}