Skip to content

Commit 6a00f38

Browse files
author
Жунёва Мария Михайловна
committed
Add structures for freebsd
1 parent 7d7151c commit 6a00f38

File tree

3 files changed

+21
-3
lines changed

3 files changed

+21
-3
lines changed

.cirrus.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ task:
33
freebsd_instance:
44
image_family: freebsd-13-3
55
setup_script:
6-
- pkg install -y libnghttp2 curl
6+
- pkg install -y libnghttp2 curl evdev-proto
77
- curl https://sh.rustup.rs -sSf --output rustup.sh
88
- sh rustup.sh -y --default-toolchain nightly --profile=minimal
99
- . $HOME/.cargo/env
@@ -17,7 +17,7 @@ task:
1717
freebsd_instance:
1818
image: freebsd-14-1-release-amd64-ufs
1919
setup_script:
20-
- pkg install -y libnghttp2 curl
20+
- pkg install -y libnghttp2 curl evdev-proto
2121
- curl https://sh.rustup.rs -sSf --output rustup.sh
2222
- sh rustup.sh -y --default-toolchain nightly --profile=minimal
2323
- . $HOME/.cargo/env
@@ -31,7 +31,7 @@ task:
3131
freebsd_instance:
3232
image_family: freebsd-15-0-snap
3333
setup_script:
34-
- pkg install -y libnghttp2 curl
34+
- pkg install -y libnghttp2 curl evdev-proto
3535
- curl https://sh.rustup.rs -sSf --output rustup.sh
3636
- sh rustup.sh -y --default-toolchain nightly --profile=minimal
3737
- . $HOME/.cargo/env

libc-test/build.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2066,6 +2066,7 @@ fn test_freebsd(target: &str) {
20662066
"sys/eui64.h",
20672067
"sys/event.h",
20682068
[freebsd13]:"sys/eventfd.h",
2069+
[freebsd13]:"sys/input.h",
20692070
"sys/extattr.h",
20702071
"sys/file.h",
20712072
"sys/ioctl.h",
@@ -2091,6 +2092,7 @@ fn test_freebsd(target: &str) {
20912092
"sys/thr.h",
20922093
"sys/time.h",
20932094
[freebsd14 || freebsd15]:"sys/timerfd.h",
2095+
[freebsd14 || freebsd15]:"sys/input.h",
20942096
"sys/times.h",
20952097
"sys/timex.h",
20962098
"sys/types.h",

src/unix/bsd/freebsdlike/freebsd/mod.rs

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -288,6 +288,22 @@ s! {
288288
pub sem_flg: ::c_short,
289289
}
290290

291+
pub struct input_event {
292+
pub time: ::timeval,
293+
pub type_: ::u_short,
294+
pub code: ::u_short,
295+
pub value: ::c_int,
296+
}
297+
298+
pub struct input_absinfo {
299+
pub value: ::c_int,
300+
pub minimum: ::c_int,
301+
pub maximum: ::c_int,
302+
pub fuzz: ::c_int,
303+
pub flat: ::c_int,
304+
pub resolution: ::c_int,
305+
}
306+
291307
pub struct msqid_ds {
292308
pub msg_perm: ::ipc_perm,
293309
__unused1: *mut ::c_void,

0 commit comments

Comments
 (0)