diff --git a/crates/radicle-systemd/Cargo.toml b/crates/radicle-systemd/Cargo.toml index cd1c9984..5d6e9064 100644 --- a/crates/radicle-systemd/Cargo.toml +++ b/crates/radicle-systemd/Cargo.toml @@ -10,6 +10,8 @@ rust-version.workspace = true [dependencies] log = { workspace = true, optional = true } + +[target.'cfg(target_os = "linux")'.dependencies] systemd-journal-logger = { version = "2.2.2", optional = true } [features] diff --git a/crates/radicle-systemd/src/lib.rs b/crates/radicle-systemd/src/lib.rs index 3e47b694..48ea1b2c 100644 --- a/crates/radicle-systemd/src/lib.rs +++ b/crates/radicle-systemd/src/lib.rs @@ -1,6 +1,6 @@ //! Library for interaction with systemd, specialized for Radicle. -#[cfg(feature = "journal")] +#[cfg(all(feature = "journal", target_os = "linux"))] pub mod journal; #[cfg(feature = "listen")]