diff options
Diffstat (limited to 'vendor/rustix/src/fs/mod.rs')
-rw-r--r-- | vendor/rustix/src/fs/mod.rs | 48 |
1 files changed, 29 insertions, 19 deletions
diff --git a/vendor/rustix/src/fs/mod.rs b/vendor/rustix/src/fs/mod.rs index e28ddab6f..fc2c3368b 100644 --- a/vendor/rustix/src/fs/mod.rs +++ b/vendor/rustix/src/fs/mod.rs @@ -4,7 +4,7 @@ mod abs; #[cfg(not(target_os = "redox"))] mod at; mod constants; -#[cfg(any(target_os = "android", target_os = "linux"))] +#[cfg(linux_kernel)] mod copy_file_range; #[cfg(not(target_os = "redox"))] mod cwd; @@ -28,41 +28,46 @@ pub(crate) mod fd; mod file_type; #[cfg(apple)] mod getpath; -#[cfg(not(any(solarish, target_os = "haiku", target_os = "redox", target_os = "wasi")))] +#[cfg(not(target_os = "wasi"))] // WASI doesn't have get[gpu]id. +mod id; +#[cfg(not(target_os = "wasi"))] +mod ioctl; +#[cfg(not(any(target_os = "haiku", target_os = "redox", target_os = "wasi")))] mod makedev; -#[cfg(any(target_os = "android", target_os = "freebsd", target_os = "linux"))] +#[cfg(any(linux_kernel, target_os = "freebsd"))] mod memfd_create; -#[cfg(any(target_os = "android", target_os = "linux"))] +#[cfg(linux_kernel)] mod mount; -#[cfg(any(target_os = "android", target_os = "linux"))] +#[cfg(linux_kernel)] mod openat2; -#[cfg(any(target_os = "android", target_os = "linux"))] +#[cfg(linux_kernel)] mod raw_dir; +mod seek_from; #[cfg(target_os = "linux")] mod sendfile; -#[cfg(any(target_os = "android", target_os = "linux"))] +#[cfg(linux_kernel)] mod statx; #[cfg(not(any(target_os = "redox", target_os = "wasi")))] mod sync; -#[cfg(any(apple, target_os = "android", target_os = "linux"))] +#[cfg(any(apple, linux_kernel))] mod xattr; -#[cfg(any(target_os = "android", target_os = "linux"))] +#[cfg(linux_kernel)] pub use crate::backend::fs::inotify; pub use abs::*; #[cfg(not(target_os = "redox"))] pub use at::*; pub use constants::*; -#[cfg(any(target_os = "android", target_os = "linux"))] +#[cfg(linux_kernel)] pub use copy_file_range::copy_file_range; #[cfg(not(target_os = "redox"))] -pub use cwd::cwd; +pub use cwd::*; #[cfg(not(target_os = "redox"))] pub use dir::{Dir, DirEntry}; #[cfg(not(any( apple, - solarish, netbsdlike, + solarish, target_os = "dragonfly", target_os = "haiku", target_os = "redox", @@ -77,23 +82,28 @@ pub use fd::*; pub use file_type::FileType; #[cfg(apple)] pub use getpath::getpath; -#[cfg(not(any(solarish, target_os = "haiku", target_os = "redox", target_os = "wasi")))] +#[cfg(not(target_os = "wasi"))] +pub use id::*; +#[cfg(not(target_os = "wasi"))] +pub use ioctl::*; +#[cfg(not(any(target_os = "haiku", target_os = "redox", target_os = "wasi")))] pub use makedev::*; -#[cfg(any(target_os = "android", target_os = "freebsd", target_os = "linux"))] +#[cfg(any(linux_kernel, target_os = "freebsd"))] pub use memfd_create::{memfd_create, MemfdFlags}; -#[cfg(any(target_os = "android", target_os = "linux"))] +#[cfg(linux_kernel)] pub use mount::*; -#[cfg(any(target_os = "android", target_os = "linux"))] +#[cfg(linux_kernel)] pub use openat2::openat2; -#[cfg(any(target_os = "android", target_os = "linux"))] +#[cfg(linux_kernel)] pub use raw_dir::{RawDir, RawDirEntry}; +pub use seek_from::SeekFrom; #[cfg(target_os = "linux")] pub use sendfile::sendfile; -#[cfg(any(target_os = "android", target_os = "linux"))] +#[cfg(linux_kernel)] pub use statx::{statx, Statx, StatxFlags, StatxTimestamp}; #[cfg(not(any(target_os = "redox", target_os = "wasi")))] pub use sync::sync; -#[cfg(any(apple, target_os = "android", target_os = "linux"))] +#[cfg(any(apple, linux_kernel))] pub use xattr::*; /// Re-export types common to POSIX-ish platforms. |