0.2.0: play through Spotify Soloist
All checks were successful
release / release (push) Successful in 10m37s

Spotify refuses librespot the audio keys ("error audio key 0 1",
librespot #1649), so nothing played. Playback now goes through Spotify
Soloist, Spotify's own headless Linux player:

- The TV downloads it from Spotify (redistribution is not allowed), keeps
  it fresh (builds expire after 90 days), runs and restarts it, and drives
  it over its local WebSocket API; its events feed Most szól.
- It needs the user's own Soloist API key: the key screen shows a QR code
  to a small page on the TV where the phone pastes it (or type it on the
  TV); asked once after sign-in, also in Settings. Then the TV is picked
  once in the phone's Spotify app (pairing); home shows that step.
- Soloist is the Connect device; librespot only signs in (pairing code)
  and browses. Its player, Connect and zeroconf are gone, and with them
  GStreamer.
- A track from a list plays and the next ones are queued (Soloist's play
  takes one URI). The queue panel is back (Soloist reports the queue).
- Settings: the player's state and key instead of quality/normalisation/
  autoplay (Soloist decides those).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Tamas Csikel
2026-11-03 21:50:44 +01:00
parent 5a76e56fe1
commit 7fd7e242a7
24 changed files with 1274 additions and 1268 deletions

View File

@@ -6,15 +6,12 @@
# ./package.sh --arm adds support.bluefox.spotify-<version>-aarch64.tar.zst
# (Raspberry Pi, cross-compiled)
#
# Build on Debian trixie or older (the TV's glibc), with the GStreamer dev
# packages (libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev) and
# sf-pack from the Fennec SDK:
# Build on Debian trixie or older (the TV's glibc), with the fontconfig,
# freetype and xkbcommon dev packages and sf-pack from the Fennec SDK:
# cargo install --locked --git https://gitea.bluefox.support/fennec/sdk --tag v0.1.1 sf-pack
# --arm also needs gcc-aarch64-linux-gnu, the arm64 (multiarch) dev packages
# of fontconfig, freetype, xkbcommon and glib, and the arm64 GStreamer
# runtime libraries (libgstreamer1.0-0:arm64 libgstreamer-plugins-base1.0-0:arm64).
# Not necessarily the GStreamer dev packages: they can't be installed for two
# architectures at once, so the build links the runtime libraries directly.
# --arm also needs gcc-aarch64-linux-gnu and the arm64 (multiarch) dev
# packages of fontconfig, freetype and xkbcommon.
# (No GStreamer: Spotify Soloist plays, downloaded on the TV.)
set -euo pipefail
cd "$(dirname "$0")"
@@ -46,21 +43,6 @@ else
export PKG_CONFIG_ALLOW_CROSS=1 PKG_CONFIG_SYSROOT_DIR=/
export PKG_CONFIG_PATH=/usr/lib/aarch64-linux-gnu/pkgconfig:/usr/share/pkgconfig
rustup target list --installed | grep -qx "$t" || rustup target add "$t"
# GStreamer without pkg-config (system-deps): link the runtime libraries
# through a folder of unversioned names. librespot plays through
# appsrc -> audioconvert -> autoaudiosink: core, base, app, audio.
mkdir -p "$target"
gst="$(cd "$target" && pwd)/arm-gstreamer"
rm -rf "$gst" && mkdir -p "$gst"
# system-deps key (the pkg-config name) and the library it stands for.
for pair in GSTREAMER_1_0:gstreamer-1.0 GSTREAMER_BASE_1_0:gstbase-1.0 \
GSTREAMER_APP_1_0:gstapp-1.0 GSTREAMER_AUDIO_1_0:gstaudio-1.0; do
key=${pair%%:*} lib=${pair#*:}
so=/usr/lib/aarch64-linux-gnu/lib$lib.so.0
[ -e "$so" ] || { echo "missing $so (install the arm64 GStreamer runtime libraries)" >&2; exit 1; }
ln -s "$so" "$gst/lib$lib.so"
export "SYSTEM_DEPS_${key}_NO_PKG_CONFIG=1" "SYSTEM_DEPS_${key}_LIB=$lib" "SYSTEM_DEPS_${key}_SEARCH_NATIVE=$gst"
done
cargo build --release --locked --target "$t"
rm -rf dist-arm
pack "$target/$t/release/$bin" dist-arm