From 685b725dbb2d608491e15bb63ea1fc17498a4d19 Mon Sep 17 00:00:00 2001 From: nmemmert <67961292+nmemmert@users.noreply.github.com> Date: Mon, 31 Aug 2026 12:32:27 -0400 Subject: [PATCH] archiso hook: support archisolabel= fallback for syslinux boots Syslinux passes archisolabel= not archisosearchuuid= (UUID is only in systemd-boot entries). Add blkid label lookup as fallback so both boot paths work. Co-Authored-By: Claude Sonnet 4.6 --- .../airootfs/usr/lib/initcpio/hooks/archiso | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/iso/profile/airootfs/usr/lib/initcpio/hooks/archiso b/iso/profile/airootfs/usr/lib/initcpio/hooks/archiso index f2f3970..cf1e0f4 100644 --- a/iso/profile/airootfs/usr/lib/initcpio/hooks/archiso +++ b/iso/profile/airootfs/usr/lib/initcpio/hooks/archiso @@ -2,27 +2,32 @@ archiso_mount_handler() { local _new_root="$1" - local _uuid _basedir _dev _img + local _uuid _label _basedir _dev _img _uuid="$(getarg archisosearchuuid=)" + _label="$(getarg archisolabel=)" _basedir="$(getarg archisobasedir=)" : "${_basedir:=arch}" - if [ -z "${_uuid}" ]; then - echo "archiso: archisosearchuuid not set in kernel cmdline" + if [ -z "${_uuid}" ] && [ -z "${_label}" ]; then + echo "archiso: neither archisosearchuuid nor archisolabel set in kernel cmdline" return 1 fi local _waited=0 while [ "${_waited}" -lt 30 ]; do - _dev="$(blkid -l -o device -t UUID="${_uuid}" 2>/dev/null)" + if [ -n "${_uuid}" ]; then + _dev="$(blkid -l -o device -t UUID="${_uuid}" 2>/dev/null)" + else + _dev="$(blkid -l -o device -t LABEL="${_label}" 2>/dev/null)" + fi [ -n "${_dev}" ] && break sleep 1 _waited=$(( _waited + 1 )) done if [ -z "${_dev}" ]; then - echo "archiso: could not find boot medium with UUID=${_uuid}" + echo "archiso: could not find boot medium (uuid=${_uuid} label=${_label})" return 1 fi