Skip to content

Commit

Permalink
Rollup merge of rust-lang#55622 - jakllsch:netbsd-librt, r=alexcrichton
Browse files Browse the repository at this point in the history
NetBSD: link libstd with librt in addition to libpthread

Some aio(3) and mq(3) functions in the libc crate actually come from NetBSD librt, not libc or libpthread.
  • Loading branch information
pietroalbini committed Nov 15, 2018
2 parents 9c5b8aa + 2d368b5 commit 756870a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/libstd/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,11 @@ fn main() {
} else if target.contains("freebsd") {
println!("cargo:rustc-link-lib=execinfo");
println!("cargo:rustc-link-lib=pthread");
} else if target.contains("netbsd") {
println!("cargo:rustc-link-lib=pthread");
println!("cargo:rustc-link-lib=rt");
} else if target.contains("dragonfly") || target.contains("bitrig") ||
target.contains("netbsd") || target.contains("openbsd") {
target.contains("openbsd") {
println!("cargo:rustc-link-lib=pthread");
} else if target.contains("solaris") {
println!("cargo:rustc-link-lib=socket");
Expand Down

0 comments on commit 756870a

Please sign in to comment.