Skip to content

Commit 4d42380

Browse files
Add devstat items
1 parent 6e2d113 commit 4d42380

File tree

2 files changed

+366
-0
lines changed

2 files changed

+366
-0
lines changed

libc-test/build.rs

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1876,6 +1876,7 @@ fn test_freebsd(target: &str) {
18761876
"sys/vmmeter.h",
18771877
"sys/wait.h",
18781878
"libprocstat.h",
1879+
"devstat.h",
18791880
"syslog.h",
18801881
"termios.h",
18811882
"time.h",
@@ -1919,6 +1920,7 @@ fn test_freebsd(target: &str) {
19191920
// Field is named `type` in C but that is a Rust keyword,
19201921
// so these fields are translated to `type_` in the bindings.
19211922
"type_" if struct_ == "rtprio" => "type".to_string(),
1923+
"type_" if struct_ == "devstat_match_table" => "type".to_string(),
19221924
s => s.to_string(),
19231925
}
19241926
});
@@ -2170,6 +2172,10 @@ fn test_freebsd(target: &str) {
21702172
// https://github.com/gnzlbg/ctest/issues/68
21712173
"lio_listio" => true,
21722174

2175+
// It returns a `long double`, but it's a nightmare to bind correctly in rust
2176+
// for the moment, so it's a best effort thing...
2177+
"devstat_compute_etime" => true,
2178+
21732179
_ => false,
21742180
}
21752181
});
@@ -2242,6 +2248,11 @@ fn test_freebsd(target: &str) {
22422248

22432249
// `__sem_base` is a private struct field
22442250
("semid_ds", "__sem_base") => true,
2251+
2252+
// `snap_time` is a `long double`, but it's a nightmare to bind correctly in rust
2253+
// for the moment, so it's a best effort thing...
2254+
("statinfo", "snap_time") => true,
2255+
22452256
_ => false,
22462257
}
22472258
});

0 commit comments

Comments
 (0)