Skip to content

Commit f3a7aad

Browse files
committed
Auto merge of #1355 - gnzlbg:openbsdlike, r=gnzlbg
Refactor OpenBSD-like module into OpenBSD The only OpenBSD-like OS that we support after bitrig's removal is OpenBSD itself. cc @semarie
2 parents 50f4b67 + 7b45788 commit f3a7aad

File tree

7 files changed

+490
-516
lines changed

7 files changed

+490
-516
lines changed

libc-test/build.rs

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2815,20 +2815,14 @@ fn test_linux(target: &str) {
28152815
cfg.skip_fn(|_| true)
28162816
.skip_const(|_| true)
28172817
.skip_static(|_| true)
2818-
.type_name(move |ty, _is_struct, _is_union| {
2819-
ty.to_string()
2820-
});
2821-
cfg.skip_struct(move |ty| {
2822-
match ty {
2823-
"Elf64_Phdr" | "Elf32_Phdr" => false,
2824-
_ => true,
2825-
}
2818+
.type_name(move |ty, _is_struct, _is_union| ty.to_string());
2819+
cfg.skip_struct(move |ty| match ty {
2820+
"Elf64_Phdr" | "Elf32_Phdr" => false,
2821+
_ => true,
28262822
});
2827-
cfg.skip_type(move |ty| {
2828-
match ty {
2829-
"Elf64_Phdr" | "Elf32_Phdr" => false,
2830-
_ => true,
2831-
}
2823+
cfg.skip_type(move |ty| match ty {
2824+
"Elf64_Phdr" | "Elf32_Phdr" => false,
2825+
_ => true,
28322826
});
28332827
cfg.header("elf.h");
28342828
cfg.generate("../src/lib.rs", "linux_elf.rs");

src/unix/bsd/netbsdlike/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -677,8 +677,8 @@ cfg_if! {
677677
mod netbsd;
678678
pub use self::netbsd::*;
679679
} else if #[cfg(target_os = "openbsd")] {
680-
mod openbsdlike;
681-
pub use self::openbsdlike::*;
680+
mod openbsd;
681+
pub use self::openbsd::*;
682682
} else {
683683
// Unknown target_os
684684
}

0 commit comments

Comments
 (0)