Restores the ALSA layout binds in both snap recipes (bit-perfect hw: access inside the snap), lets the build cache save on main as well as slint-mvp, installs the desktop file as com.blitzfc.qbz.desktop so the AppStream launchable and the MPRIS DesktopEntry resolve in deb/rpm, clears the stale boot-restore error when a new browser sign-in starts, and adds the X11 dlopen libraries to the flake's runtime set. The flake version/rev/srcHash bump remains a tag-time step (documented in the release checklist, which is rewritten for the 2.0 Slint flow). cc
162 lines
5.3 KiB
YAML
162 lines
5.3 KiB
YAML
# QBZ Snap recipe — SOURCE build of the Slint app (crates/ workspace).
|
|
#
|
|
# Rewritten 2026-07-02 for the Tauri -> Slint migration (v2.0). This root
|
|
# file is what `snapcraft` picks up when building from the repo (local
|
|
# builds / any builder pointed at the repo root). packaging/snap/snapcraft.yaml
|
|
# is a symlink to THIS file — keep it that way.
|
|
#
|
|
# NOTE: the CI release path (release-snap.yml) does NOT use this file — it
|
|
# builds the binary on a swap-equipped 16 GB runner and wraps it with the
|
|
# dump-plugin recipe in packaging/snap-slint/snapcraft.yaml. Reason: the
|
|
# qbz_ui rustc peaks ~30 GB (RSS+swap); small remote builders (e.g.
|
|
# Launchpad) will OOM building this recipe from source. Keep the runtime
|
|
# sections (apps/plugs/stage-packages) in sync with packaging/snap-slint/.
|
|
|
|
name: qbz-player # keep the existing registered Snap Store name
|
|
title: "QBZ — Native Qobuz Client for Linux"
|
|
version: git
|
|
summary: Native Qobuz player for Linux with bit-perfect audio and DAC control
|
|
description: |
|
|
QBZ is a native Linux desktop client for Qobuz(TM), built for high-fidelity
|
|
playback with a native audio pipeline (direct ALSA and PipeWire), bit-perfect
|
|
output, exclusive device access, and per-track sample-rate switching for
|
|
external DACs — up to 24-bit / 192 kHz.
|
|
|
|
This is the native (Slint) build: a single self-contained binary, no web
|
|
runtime. Features: native Qobuz(TM) streaming, bit-perfect ALSA exclusive
|
|
mode, DAC passthrough, Hi-Res FLAC, queue/playlists/favorites/offline cache,
|
|
local library, Chromecast and DLNA, MPRIS media keys and desktop integration.
|
|
|
|
QBZ uses the Qobuz(TM) API but is not affiliated with, endorsed by, or
|
|
certified by Qobuz.
|
|
|
|
license: MIT
|
|
contact: https://github.com/vicrodh/qbz/discussions
|
|
website: https://qbz.lol
|
|
source-code: https://github.com/vicrodh/qbz
|
|
issues: https://github.com/vicrodh/qbz/issues
|
|
|
|
grade: stable
|
|
confinement: strict
|
|
base: core24
|
|
icon: packaging/snap/snap/gui/qbz.png
|
|
|
|
platforms:
|
|
amd64:
|
|
arm64:
|
|
|
|
# ALSA config/plugin binds: without these the snap's alsa-lib cannot find the
|
|
# host's ALSA configuration and plugin set, and the direct hw: (bit-perfect)
|
|
# path breaks. Restored from the 1.2.x recipe (review fix 2026-07-03).
|
|
layout:
|
|
/usr/share/alsa:
|
|
bind: $SNAP/usr/share/alsa
|
|
/etc/alsa:
|
|
bind: $SNAP/etc/alsa
|
|
/usr/lib/x86_64-linux-gnu/alsa-lib:
|
|
bind: $SNAP/usr/lib/x86_64-linux-gnu/alsa-lib
|
|
/usr/lib/aarch64-linux-gnu/alsa-lib:
|
|
bind: $SNAP/usr/lib/aarch64-linux-gnu/alsa-lib
|
|
|
|
apps:
|
|
qbz:
|
|
command: bin/qbz
|
|
desktop: usr/share/applications/qbz.desktop
|
|
# The gnome extension provides the graphics/font platform (Mesa GL, EGL,
|
|
# fontconfig, wayland) that a femtovg-wgpu + winit app needs — it is NOT
|
|
# about GTK here, just the runtime platform. It wires desktop/wayland/x11/
|
|
# gsettings plugs automatically.
|
|
extensions: [gnome]
|
|
plugs:
|
|
- network
|
|
- network-status
|
|
- audio-playback
|
|
- home
|
|
- removable-media
|
|
- alsa
|
|
- pipewire
|
|
- opengl
|
|
slots:
|
|
- mpris
|
|
|
|
slots:
|
|
mpris:
|
|
interface: mpris
|
|
name: qbz
|
|
|
|
parts:
|
|
qbz:
|
|
plugin: nil
|
|
source: .
|
|
build-packages:
|
|
- curl
|
|
- pkg-config
|
|
- clang
|
|
- nasm
|
|
- mold
|
|
- libasound2-dev
|
|
- libjack-jackd2-dev
|
|
- libfontconfig1-dev
|
|
- libfreetype-dev
|
|
- libxkbcommon-dev
|
|
- libwayland-dev
|
|
- libxcb1-dev
|
|
- libgl1-mesa-dev
|
|
- libegl1-mesa-dev
|
|
- libdbus-1-dev
|
|
- libssl-dev
|
|
- libharfbuzz-dev
|
|
- libjbig2dec0-dev
|
|
- libopenjp2-7-dev
|
|
- libjpeg-dev
|
|
- zlib1g-dev
|
|
- libgumbo-dev
|
|
override-build: |
|
|
# Rust via rustup (the archive's rustc is too old for Slint).
|
|
export RUSTUP_HOME="$SNAPCRAFT_PART_BUILD/.rustup"
|
|
export CARGO_HOME="$SNAPCRAFT_PART_BUILD/.cargo"
|
|
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | \
|
|
sh -s -- -y --profile minimal --default-toolchain stable
|
|
export PATH="$CARGO_HOME/bin:$PATH"
|
|
|
|
# MIN memory tier: the qbz_ui rustc peaks ~30 GB. Symbols are stripped
|
|
# by the workspace [profile.release].
|
|
export CARGO_INCREMENTAL=0
|
|
export CARGO_BUILD_JOBS=1
|
|
export CARGO_PROFILE_RELEASE_CODEGEN_UNITS=256
|
|
export CARGO_PROFILE_RELEASE_OPT_LEVEL=2
|
|
export RUSTFLAGS="-C link-arg=-fuse-ld=mold"
|
|
cargo build --release --manifest-path crates/Cargo.toml -p qbz
|
|
|
|
install -Dm755 crates/target/release/qbz "$SNAPCRAFT_PART_INSTALL/bin/qbz"
|
|
install -Dm644 packaging/linux/qbz.desktop \
|
|
"$SNAPCRAFT_PART_INSTALL/usr/share/applications/qbz.desktop"
|
|
install -Dm644 packaging/icons/256x256.png \
|
|
"$SNAPCRAFT_PART_INSTALL/usr/share/icons/hicolor/256x256/apps/qbz.png"
|
|
stage-packages:
|
|
# Audio (the bit-perfect path)
|
|
- libasound2t64
|
|
- libasound2-plugins
|
|
- libpipewire-0.3-0
|
|
- libjack-jackd2-0
|
|
# GPU stack for femtovg-wgpu (Vulkan first, GL fallback)
|
|
- libvulkan1
|
|
- mesa-vulkan-drivers
|
|
- libegl1
|
|
- libgl1
|
|
# winit windowing (Wayland + X11)
|
|
- libwayland-client0
|
|
- libwayland-cursor0
|
|
- libwayland-egl1
|
|
- libxkbcommon0
|
|
- libxcb1
|
|
- libx11-6
|
|
- libxcursor1
|
|
- libxi6
|
|
- libxrandr2
|
|
# Fonts / text shaping (femtovg)
|
|
- libfontconfig1
|
|
- libfreetype6
|
|
# Tray (ksni) + portals + media controls over D-Bus
|
|
- libdbus-1-3
|