Skip to content

Commit 37abe25

Browse files
committed
uucore: add feat_smack cfg alias
1 parent c821cb8 commit 37abe25

File tree

3 files changed

+3
-2
lines changed

3 files changed

+3
-2
lines changed

src/uucore/build.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ use cfg_aliases::cfg_aliases;
1515
pub fn main() -> Result<(), Box<dyn std::error::Error>> {
1616
cfg_aliases! {
1717
selinux: { all(feature = "feat_selinux", any(target_os = "android", target_os = "linux")) },
18+
smack: { all(feature = "feat_smack", target_os = "linux") },
1819
systemd_logind: { all(feature = "feat_systemd_logind", target_os = "linux") },
1920
}
2021

src/uucore/src/lib/features.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ pub mod hardware;
8585
pub mod selinux;
8686
#[cfg(all(unix, not(target_os = "fuchsia"), feature = "signals"))]
8787
pub mod signals;
88-
#[cfg(all(target_os = "linux", feature = "smack"))]
88+
#[cfg(smack)]
8989
pub mod smack;
9090
#[cfg(systemd_logind)]
9191
pub mod systemd_logind;

src/uucore/src/lib/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ pub use crate::features::fsxattr;
125125
#[cfg(selinux)]
126126
pub use crate::features::selinux;
127127

128-
#[cfg(all(target_os = "linux", feature = "smack"))]
128+
#[cfg(smack)]
129129
pub use crate::features::smack;
130130

131131
//## core functions

0 commit comments

Comments
 (0)