fix aarch64 and riscv64 images

This commit is contained in:
Tobias Powalowski 2023-07-24 17:20:32 +02:00
parent 6631be8e7e
commit 65e1120ca8
2 changed files with 3 additions and 3 deletions

View file

@ -68,7 +68,7 @@ _kver() {
# requirement for CONFIG_LOCALVERSION to be set.
local kver re='^[[:digit:]]+(\.[[:digit:]]+)+'
local arch bytes reader
arch="${_RUNNING_ARCH}"
arch="${_ARCH}"
if [[ $arch == @(i?86|x86_64) ]]; then
local -i offset
offset="$(od -An -j0x20E -dN2 "$1")" || return

View file

@ -34,14 +34,14 @@ _create_iso() {
# create container
archboot-"${_ARCH}"-create-container.sh "${_W_DIR}" -cc --install-source="${2}" || exit 1
_create_archboot_db "${_W_DIR}${_CACHEDIR}"
. "${_W_DIR}/etc/archboot/presets/${_ARCH}"
_ISONAME="archboot-$(date +%Y.%m.%d-%H.%M)-$(_kver ${_W_DIR}/${ALL_kver})"
# riscv64 does not support kexec at the moment
if ! [[ "${_ARCH}" == "riscv64" ]]; then
# generate tarball in container, umount tmp container tmpfs, else weird things could happen
# removing not working lvm2 from latest and local image first
echo "Removing lvm2 from container ${_W_DIR}..."
${_NSPAWN} "${_W_DIR}" pacman -Rdd lvm2 --noconfirm &>/dev/null
. "${_W_DIR}/etc/archboot/presets/${_ARCH}"
_ISONAME="archboot-$(date +%Y.%m.%d-%H.%M)-$(_kver ${_W_DIR}/${ALL_kver})"
echo "Generating local ISO..."
# generate local iso in container
#if [[ "${_ARCH}" == "x86_64" ]]; then