]> git.lizzy.rs Git - rust.git/blobdiff - src/librustuv/uvll.rs
Register new snapshots
[rust.git] / src / librustuv / uvll.rs
index c802803251090deecd82751909d825b101ffadc0..09ebd29bc2216ef29691bbd12fe0365f1bd4329d 100644 (file)
@@ -524,8 +524,9 @@ pub unsafe fn guess_handle(handle: c_int) -> c_int {
 // second copies of everything. We obviously don't want this, so instead of
 // dying horribly during testing, we allow all of the test rustuv's references
 // to get resolved to the original rustuv crate.
-#[link_args = "-luv_support -luv"]
 #[cfg(not(test))]
+#[link(name = "uv_support", kind = "static")]
+#[link(name = "uv", kind = "static")]
 extern {}
 
 extern {
@@ -717,12 +718,19 @@ pub fn uv_signal_start(h: *uv_signal_t, cb: uv_signal_cb,
     pub fn uv_signal_stop(handle: *uv_signal_t) -> c_int;
 }
 
-// libuv requires various system libraries to successfully link on some
-// platforms
-#[cfg(target_os = "linux")]
-#[link_args = "-lpthread"]
+// libuv requires other native libraries on various platforms. These are all
+// listed here (for each platform)
+
+#[cfg(not(target_os = "android"))] // apparently pthreads isn't on android?
+#[link(name = "pthread")]
 extern {}
 
 #[cfg(target_os = "win32")]
-#[link_args = "-lWs2_32 -lpsapi -liphlpapi"]
+#[link(name = "ws2_32")]
+#[link(name = "psapi")]
+#[link(name = "iphlpapi")]
+extern {}
+
+#[cfg(target_os = "freebsd")]
+#[link(name = "kvm")]
 extern {}