mirror of
https://github.com/uutils/coreutils.git
synced 2026-06-10 15:48:22 -07:00
xattr feature: enable it on mac too
This commit is contained in:
+3
-3
@@ -17,7 +17,7 @@ use std::os::unix::ffi::OsStrExt;
|
||||
#[cfg(unix)]
|
||||
use std::os::unix::fs::{FileTypeExt, PermissionsExt};
|
||||
use std::path::{Path, PathBuf, StripPrefixError};
|
||||
#[cfg(all(unix, not(any(target_os = "android", target_os = "macos"))))]
|
||||
#[cfg(all(unix, not(target_os = "android")))]
|
||||
use uucore::fsxattr::copy_xattrs;
|
||||
|
||||
use clap::{builder::ValueParser, crate_version, Arg, ArgAction, ArgMatches, Command};
|
||||
@@ -1605,11 +1605,11 @@ pub(crate) fn copy_attributes(
|
||||
})?;
|
||||
|
||||
handle_preserve(&attributes.xattr, || -> CopyResult<()> {
|
||||
#[cfg(all(unix, not(any(target_os = "android", target_os = "macos"))))]
|
||||
#[cfg(all(unix, not(target_os = "android")))]
|
||||
{
|
||||
copy_xattrs(source, dest)?;
|
||||
}
|
||||
#[cfg(not(all(unix, not(any(target_os = "android", target_os = "macos")))))]
|
||||
#[cfg(not(all(unix, not(target_os = "android"))))]
|
||||
{
|
||||
// The documentation for GNU cp states:
|
||||
//
|
||||
|
||||
@@ -54,7 +54,7 @@ pub mod process;
|
||||
#[cfg(all(target_os = "linux", feature = "tty"))]
|
||||
pub mod tty;
|
||||
|
||||
#[cfg(all(unix, not(target_os = "macos"), feature = "fsxattr"))]
|
||||
#[cfg(all(unix, feature = "fsxattr"))]
|
||||
pub mod fsxattr;
|
||||
#[cfg(all(unix, not(target_os = "fuchsia"), feature = "signals"))]
|
||||
pub mod signals;
|
||||
|
||||
@@ -99,7 +99,7 @@ pub use crate::features::wide;
|
||||
#[cfg(feature = "fsext")]
|
||||
pub use crate::features::fsext;
|
||||
|
||||
#[cfg(all(unix, not(target_os = "macos"), feature = "fsxattr"))]
|
||||
#[cfg(all(unix, feature = "fsxattr"))]
|
||||
pub use crate::features::fsxattr;
|
||||
|
||||
//## core functions
|
||||
|
||||
Reference in New Issue
Block a user