Files
packages/sound/mpd/test-version.sh
Alexandru Ardelean 3242c61757 mpd: match the version in the binary for the CI tests
mpd 0.24 aborts in main() when /proc/self/status reports more than one
thread, before it even parses the command line (src/Main.cxx). qemu-user
always reports several, so "mpd --version" cannot run on the emulated CI
targets and the generic version check fails there.

Add test-version.sh matching the version string compiled into the
binary, and drop the two unusable "mpd --version" calls from test.sh,
whose failures it silently ignored anyway.

Signed-off-by: Alexandru Ardelean <alex@shruggie.ro>
2026-10-06 22:26:57 +03:00

21 lines
452 B
Bash
Executable File

#!/bin/sh
# shellcheck shell=busybox
# mpd 0.24 refuses to start when /proc/self/status reports more than one
# thread before main() runs, which it does under qemu-user, so the binary
# cannot be asked for its version on the emulated CI targets. Match the
# version string compiled into it instead.
case "$1" in
mpd-full | mpd-mini)
grep -aqF "$2" /usr/bin/mpd
;;
mpd-avahi-service)
exit 0
;;
*)
echo "Untested package: $1" >&2
exit 1
;;
esac