From e25fd20708e87d9f166a8b5c5fb6f97276064457 Mon Sep 17 00:00:00 2001 From: Red Bear OS Date: Sun, 28 Jun 2026 16:21:45 +0300 Subject: [PATCH] fix: define eventfd_t locally instead of re-export (cbindgen cross-module) --- src/header/sys_eventfd/mod.rs | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/header/sys_eventfd/mod.rs b/src/header/sys_eventfd/mod.rs index f9ad374a7f..1bc0926994 100644 --- a/src/header/sys_eventfd/mod.rs +++ b/src/header/sys_eventfd/mod.rs @@ -4,10 +4,13 @@ use crate::error::{Errno, ResultExt}; use crate::header::fcntl::{O_CLOEXEC, O_NONBLOCK, O_RDWR}; use crate::header::errno::EFAULT; use crate::header::errno::EINVAL; -use crate::platform::{Pal, Sys, types::{c_int, c_uint}}; +use crate::platform::{Pal, Sys, types::{c_int, c_uint, uint64_t}}; -// Re-export eventfd_t from bits/eventfd.h -pub use crate::header::bits_eventfd::eventfd_t; +// cbindgen can't resolve re-exports across modules, so eventfd_t is +// defined here directly (the C typedef lives in after_includes in +// cbindgen.toml). bits_eventfd still has its own copy for independent +// consumers that include only . +pub type eventfd_t = uint64_t; pub const EFD_SEMAPHORE: c_int = 1; pub const EFD_CLOEXEC: c_int = 0x80000;