about summary refs log tree commit diff
path: root/src/libstd/sys/common
diff options
context:
space:
mode:
authorJorge Aparicio <japaricious@gmail.com>2016-01-25 16:23:31 -0500
committerJorge Aparicio <japaricious@gmail.com>2016-01-29 18:46:25 -0500
commit7b026f0355a5394358e6a9758185db8eec850e0f (patch)
treeb4ef4e77aa3ce77f5886dbd39caf5417daf89475 /src/libstd/sys/common
parent0f196bcc3b23925854e3d758c03f56c7520e9b99 (diff)
downloadrust-7b026f0355a5394358e6a9758185db8eec850e0f.tar.gz
rust-7b026f0355a5394358e6a9758185db8eec850e0f.zip
add support for mips(el)-unknown-linux-musl
This target covers MIPS devices that run the trunk version of OpenWRT.

The x86_64-unknown-linux-musl target always links statically to C libraries. For
the mips(el)-unknown-linux-musl target, we opt for dynamic linking (like most of
other targets do) to keep binary size down.

As for the C compiler flags used in the build system, we use the same flags used
for the mips(el)-unknown-linux-gnu target.
Diffstat (limited to 'src/libstd/sys/common')
-rw-r--r--src/libstd/sys/common/libunwind.rs5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/libstd/sys/common/libunwind.rs b/src/libstd/sys/common/libunwind.rs
index 77d1eed9623..179a27a2ec8 100644
--- a/src/libstd/sys/common/libunwind.rs
+++ b/src/libstd/sys/common/libunwind.rs
@@ -101,9 +101,10 @@ pub type _Unwind_Exception_Cleanup_Fn =
                       exception: *mut _Unwind_Exception);
 
 #[cfg_attr(any(all(target_os = "linux", not(target_env = "musl")),
-               target_os = "freebsd"),
+               target_os = "freebsd",
+               all(target_os = "linux", target_env = "musl", not(target_arch = "x86_64"))),
            link(name = "gcc_s"))]
-#[cfg_attr(all(target_os = "linux", target_env = "musl", not(test)),
+#[cfg_attr(all(target_os = "linux", target_env = "musl", target_arch = "x86_64", not(test)),
            link(name = "unwind", kind = "static"))]
 #[cfg_attr(any(target_os = "android", target_os = "openbsd"),
            link(name = "gcc"))]