diff --git a/library/std/src/sys/fs/unix.rs b/library/std/src/sys/fs/unix.rs index d9a7fcb0e2d39..32dc1a5e89766 100644 --- a/library/std/src/sys/fs/unix.rs +++ b/library/std/src/sys/fs/unix.rs @@ -14,9 +14,10 @@ use libc::c_char; target_os = "fuchsia", target_os = "hurd", target_os = "illumos", + target_vendor = "apple", ))] use libc::dirfd; -#[cfg(any(target_os = "fuchsia", target_os = "illumos"))] +#[cfg(any(target_os = "fuchsia", target_os = "illumos", target_vendor = "apple"))] use libc::fstatat as fstatat64; #[cfg(any(all(target_os = "linux", not(target_env = "musl")), target_os = "hurd"))] use libc::fstatat64; @@ -907,6 +908,7 @@ impl DirEntry { target_os = "fuchsia", target_os = "hurd", target_os = "illumos", + target_vendor = "apple", ), not(miri) // no dirfd on Miri ))] @@ -937,6 +939,7 @@ impl DirEntry { target_os = "fuchsia", target_os = "hurd", target_os = "illumos", + target_vendor = "apple", )), miri ))]