diff --git a/src/backend/libc/fs/dir.rs b/src/backend/libc/fs/dir.rs index 790f22a2b..fca90733e 100644 --- a/src/backend/libc/fs/dir.rs +++ b/src/backend/libc/fs/dir.rs @@ -24,7 +24,7 @@ use crate::fs::{fstat, Stat}; target_os = "wasi", )))] use crate::fs::{fstatfs, StatFs}; -#[cfg(not(any(solarish, target_os = "redox", target_os = "vita", target_os = "wasi")))] +#[cfg(not(any(solarish, target_os = "vita", target_os = "wasi")))] use crate::fs::{fstatvfs, StatVfs}; use crate::io; #[cfg(not(any(target_os = "fuchsia", target_os = "vita", target_os = "wasi")))] @@ -238,7 +238,6 @@ impl Dir { #[cfg(not(any( solarish, target_os = "horizon", - target_os = "redox", target_os = "vita", target_os = "wasi" )))] diff --git a/src/backend/libc/fs/syscalls.rs b/src/backend/libc/fs/syscalls.rs index ab69d4aef..8cbd3a2c1 100644 --- a/src/backend/libc/fs/syscalls.rs +++ b/src/backend/libc/fs/syscalls.rs @@ -60,7 +60,7 @@ use crate::fs::Timestamps; )))] use crate::fs::{Dev, FileType}; use crate::fs::{Mode, OFlags, SeekFrom, Stat}; -#[cfg(not(any(target_os = "redox", target_os = "wasi")))] +#[cfg(not(target_os = "wasi"))] use crate::fs::{StatVfs, StatVfsMountFlags}; use crate::io; #[cfg(all(target_env = "gnu", fix_y2038))] @@ -271,7 +271,7 @@ pub(crate) fn statfs(filename: &CStr) -> io::Result { } } -#[cfg(not(any(target_os = "redox", target_os = "wasi")))] +#[cfg(not(target_os = "wasi"))] #[inline] pub(crate) fn statvfs(filename: &CStr) -> io::Result { unsafe { @@ -1591,7 +1591,7 @@ pub(crate) fn fstatfs(fd: BorrowedFd<'_>) -> io::Result { } } -#[cfg(not(any(target_os = "redox", target_os = "wasi")))] +#[cfg(not(target_os = "wasi"))] pub(crate) fn fstatvfs(fd: BorrowedFd<'_>) -> io::Result { let mut statvfs = MaybeUninit::::uninit(); unsafe { @@ -1600,7 +1600,7 @@ pub(crate) fn fstatvfs(fd: BorrowedFd<'_>) -> io::Result { } } -#[cfg(not(any(target_os = "redox", target_os = "wasi")))] +#[cfg(not(target_os = "wasi"))] fn libc_statvfs_to_statvfs(from: c::statvfs) -> StatVfs { StatVfs { f_bsize: from.f_bsize as u64, diff --git a/src/backend/libc/fs/types.rs b/src/backend/libc/fs/types.rs index 471219e5e..d570c5b28 100644 --- a/src/backend/libc/fs/types.rs +++ b/src/backend/libc/fs/types.rs @@ -845,7 +845,7 @@ bitflags! { } } -#[cfg(not(any(target_os = "redox", target_os = "wasi")))] +#[cfg(not(target_os = "wasi"))] bitflags! { /// `ST_*` constants for use with [`StatVfs`]. #[repr(transparent)] @@ -877,11 +877,11 @@ bitflags! { const NOEXEC = c::ST_NOEXEC as u64; /// `ST_NOSUID` - #[cfg(not(any(target_os = "espidf", target_os = "haiku", target_os = "horizon", target_os = "vita")))] + #[cfg(not(any(target_os = "espidf", target_os = "haiku", target_os = "horizon", target_os = "redox", target_os = "vita")))] const NOSUID = c::ST_NOSUID as u64; /// `ST_RDONLY` - #[cfg(not(any(target_os = "espidf", target_os = "haiku", target_os = "horizon", target_os = "vita")))] + #[cfg(not(any(target_os = "espidf", target_os = "haiku", target_os = "horizon", target_os = "redox", target_os = "vita")))] const RDONLY = c::ST_RDONLY as u64; /// `ST_RELATIME` @@ -1077,7 +1077,7 @@ pub type Fsid = c::fsid_t; /// /// [`statvfs`]: crate::fs::statvfs /// [`fstatvfs`]: crate::fs::fstatvfs -#[cfg(not(any(target_os = "redox", target_os = "wasi")))] +#[cfg(not(target_os = "wasi"))] #[allow(missing_docs)] pub struct StatVfs { pub f_bsize: u64, diff --git a/src/fs/abs.rs b/src/fs/abs.rs index 236a833ad..307698b53 100644 --- a/src/fs/abs.rs +++ b/src/fs/abs.rs @@ -15,7 +15,7 @@ use crate::fs::Access; target_os = "wasi", )))] use crate::fs::StatFs; -#[cfg(not(any(target_os = "haiku", target_os = "redox", target_os = "wasi")))] +#[cfg(not(any(target_os = "haiku", target_os = "wasi")))] use crate::fs::StatVfs; use crate::fs::{Mode, OFlags, Stat}; #[cfg(not(target_os = "wasi"))] @@ -283,7 +283,7 @@ pub fn statfs(path: P) -> io::Result { /// /// [POSIX]: https://pubs.opengroup.org/onlinepubs/9799919799/functions/statvfs.html /// [Linux]: https://man7.org/linux/man-pages/man2/statvfs.2.html -#[cfg(not(any(target_os = "haiku", target_os = "redox", target_os = "wasi")))] +#[cfg(not(any(target_os = "haiku", target_os = "wasi")))] #[inline] pub fn statvfs(path: P) -> io::Result { path.into_with_c_str(backend::fs::syscalls::statvfs) diff --git a/src/fs/fd.rs b/src/fs/fd.rs index c440f69de..61cd3f47d 100644 --- a/src/fs/fd.rs +++ b/src/fs/fd.rs @@ -40,7 +40,7 @@ use backend::fs::types::Stat; target_os = "wasi", )))] use backend::fs::types::StatFs; -#[cfg(not(any(target_os = "redox", target_os = "wasi")))] +#[cfg(not(target_os = "wasi"))] use backend::fs::types::StatVfs; /// Timestamps used by [`utimensat`] and [`futimens`]. @@ -196,7 +196,7 @@ pub fn fstatfs(fd: Fd) -> io::Result { /// /// [POSIX]: https://pubs.opengroup.org/onlinepubs/9799919799/functions/fstatvfs.html /// [Linux]: https://man7.org/linux/man-pages/man2/fstatvfs.2.html -#[cfg(not(any(target_os = "redox", target_os = "wasi")))] +#[cfg(not(target_os = "wasi"))] #[inline] pub fn fstatvfs(fd: Fd) -> io::Result { backend::fs::syscalls::fstatvfs(fd.as_fd())