22 lines
517 B
Bash
Executable File
22 lines
517 B
Bash
Executable File
#! /bin/bash
|
|
set -ex
|
|
|
|
# make sure the repo is properly setup by bootstrap-repo.sh
|
|
|
|
required_binfmt="/proc/sys/fs/binfmt_misc/qemu-aarch64"
|
|
|
|
if [ ! -e "$required_binfmt" ]; then
|
|
echo "missing qemu-aarch64 binfmt registration" >&2
|
|
exit 1
|
|
fi
|
|
|
|
if ! grep -q '^enabled$' "$required_binfmt"; then
|
|
echo "qemu-aarch64 binfmt is not enabled" >&2
|
|
exit 1
|
|
fi
|
|
|
|
if ! grep -q 'flags:.*F' "$required_binfmt"; then
|
|
echo "qemu-aarch64 binfmt lacks F flag; this builder expects systemd-binfmt with fixed interpreter" >&2
|
|
exit 1
|
|
fi
|