From bbffc0e6bb3c20931a16317c45e6b2ddcef3b173 Mon Sep 17 00:00:00 2001 From: skepsismusic Date: Mon, 16 Feb 2026 14:05:51 +0100 Subject: [PATCH] Fix Linux build: enable ksni feature for tray-item and add libdbus-1-dev to CI Co-authored-by: Cursor --- .github/workflows/ci.yml | 4 ++++ .github/workflows/release.yml | 2 +- backend/Cargo.toml | 4 ++++ 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b3905ae..33e5498 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -13,6 +13,10 @@ jobs: steps: - uses: actions/checkout@v4 + - name: Install system dependencies (Linux) + if: runner.os == 'Linux' + run: sudo apt-get update && sudo apt-get install -y libdbus-1-dev pkg-config + - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 75a617f..16b5953 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -43,7 +43,7 @@ jobs: - name: Install system dependencies (Linux) if: runner.os == 'Linux' - run: sudo apt-get update && sudo apt-get install -y cmake + run: sudo apt-get update && sudo apt-get install -y cmake libdbus-1-dev pkg-config - name: Install Node.js uses: actions/setup-node@v4 diff --git a/backend/Cargo.toml b/backend/Cargo.toml index 08ef581..769e18f 100644 --- a/backend/Cargo.toml +++ b/backend/Cargo.toml @@ -51,6 +51,10 @@ tokio-util = { version = "0.7", features = ["io"] } # System tray (production mode) tray-item = "0.10" +# Linux: tray-item needs ksni feature (pure-Rust D-Bus StatusNotifierItem) +[target.'cfg(target_os = "linux")'.dependencies] +tray-item = { version = "0.10", features = ["ksni"] } + # Windows icon loading (for tray icon) [target.'cfg(target_os = "windows")'.dependencies] windows-sys = { version = "0.52", features = ["Win32_UI_WindowsAndMessaging", "Win32_System_LibraryLoader"] }