Skip to content

Commit e1afddc

Browse files
committed
Haiku: fix initial platform support
1 parent 535ee6c commit e1afddc

File tree

3 files changed

+5
-1
lines changed

3 files changed

+5
-1
lines changed

src/librustc_back/target/haiku_base.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,10 @@ pub fn opts() -> TargetOptions {
1616
linker: "cc".to_string(),
1717
dynamic_linking: true,
1818
executables: true,
19-
has_rpath: true,
19+
has_rpath: false,
2020
target_family: Some("unix".to_string()),
2121
linker_is_gnu: true,
22+
no_integrated_as: true,
2223
.. Default::default()
2324
}
2425
}

src/librustc_data_structures/flock.rs

+1
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,7 @@ mod imp {
113113
pub l_sysid: libc::c_int,
114114
}
115115

116+
pub const F_RDLCK: libc::c_short = 0x0040;
116117
pub const F_UNLCK: libc::c_short = 0x0200;
117118
pub const F_WRLCK: libc::c_short = 0x0400;
118119
pub const F_SETLK: libc::c_int = 0x0080;

src/libunwind/build.rs

+2
Original file line numberDiff line numberDiff line change
@@ -39,5 +39,7 @@ fn main() {
3939
println!("cargo:rustc-link-lib=static-nobundle=pthread");
4040
} else if target.contains("fuchsia") {
4141
println!("cargo:rustc-link-lib=unwind");
42+
} else if target.contains("haiku") {
43+
println!("cargo:rustc-link-lib=gcc_s");
4244
}
4345
}

0 commit comments

Comments
 (0)