Require adduser on Debian and shadow on Arch for the package installation hooks. For GUI packages, derive the minimum glibc version from the tray ELF imports so the dependency follows the binary built by each runner. Checked generated Debian control files and Arch package metadata for both variants on macOS using the released tray binary (glibc 2.43). Checked shell syntax; no Rust changes or release rebuild.
14 lines
368 B
Bash
14 lines
368 B
Bash
#!/usr/bin/env bash
|
|
# Print the highest glibc symbol version imported by the Linux tray binary.
|
|
set -euo pipefail
|
|
export LC_ALL=C
|
|
|
|
minimum=$(objdump -T "$1" |
|
|
sed -nE '/\*UND\*/s/.*GLIBC_([0-9]+(\.[0-9]+)+).*/\1/p' |
|
|
sort -V | tail -n 1)
|
|
if [[ -z "$minimum" ]]; then
|
|
echo "No versioned glibc imports found in $1" >&2
|
|
exit 1
|
|
fi
|
|
printf '%s\n' "$minimum"
|