diff --git a/usr/bin/archboot-setup.sh b/usr/bin/archboot-setup.sh index ccef80e79..86af32382 100755 --- a/usr/bin/archboot-setup.sh +++ b/usr/bin/archboot-setup.sh @@ -19,7 +19,6 @@ . /usr/lib/archboot/installer/bootloader_uboot.sh . /usr/lib/archboot/installer/bootloader_uki.sh . /usr/lib/archboot/installer/bootloader_pacman_hooks.sh -. /usr/lib/archboot/installer/bootloader_systemd_services.sh . /usr/lib/archboot/installer/btrfs.sh . /usr/lib/archboot/installer/configuration.sh . /usr/lib/archboot/installer/mountpoints.sh diff --git a/usr/lib/archboot/installer/bootloader_systemd_services.sh b/usr/lib/archboot/installer/bootloader_systemd_services.sh deleted file mode 100644 index 6ba3e3ee9..000000000 --- a/usr/lib/archboot/installer/bootloader_systemd_services.sh +++ /dev/null @@ -1,25 +0,0 @@ -#!/usr/bin/env bash -# SPDX-License-Identifier: GPL-3.0-or-later -# created by Tobias Powalowski -_uki_autobuild() { - sleep 2 - _progress "50" "Enable automatic UKI creation on installed system..." - cat << CONFEOF > "${_DESTDIR}/etc/systemd/system/run_ukify.path" -[Unit] -Description=Run systemd ukify -[Path] -PathChanged=/boot/${_INITRAMFS} -PathChanged=/boot/${_UCODE} -Unit=run_ukify.service -[Install] -WantedBy=multi-user.target -CONFEOF - cat << CONFEOF > "${_DESTDIR}/etc/systemd/system/run_ukify.service" -[Unit] -Description=Run systemd ukify -[Service] -Type=oneshot -ExecStart="/usr/lib/systemd/ukify build --config=/etc/ukify.conf --output ${_UEFISYS_MP}/EFI/Linux/arch-linux.efi" -CONFEOF - ${_NSPAWN} systemctl enable run_ukify.path &>"${_NO_LOG}" -} diff --git a/usr/lib/archboot/installer/bootloader_uki.sh b/usr/lib/archboot/installer/bootloader_uki.sh index 4ee502070..0ec3b9389 100644 --- a/usr/lib/archboot/installer/bootloader_uki.sh +++ b/usr/lib/archboot/installer/bootloader_uki.sh @@ -2,7 +2,7 @@ # SPDX-License-Identifier: GPL-3.0-or-later # created by Tobias Powalowski _uki_config() { - _UKIFY_CONFIG="${_DESTDIR}/etc/ukify.conf" + _UKIFY_CONFIG="${_DESTDIR}/etc/kernel/uki.conf" _CMDLINE="${_DESTDIR}/etc/kernel/cmdline" echo "${_KERNEL_PARAMS_MOD}" > "${_CMDLINE}" echo "[UKI]" > "${_UKIFY_CONFIG}" @@ -22,7 +22,6 @@ CONFEOF } _uki_install() { - _uki_autobuild _BOOTMGR_LABEL="Arch Linux - Unified Kernel Image" _BOOTMGR_LOADER_PATH="/EFI/Linux/arch-linux.efi" _uefi_bootmgr_setup @@ -45,7 +44,10 @@ _uki_uefi() { _geteditor || return 1 "${_EDITOR}" "${_CMDLINE}" "${_EDITOR}" "${_UKIFY_CONFIG}" - ${_NSPAWN} /usr/lib/systemd/ukify build --config=/etc/ukify.conf --output "${_UEFISYS_MP}"/EFI/Linux/arch-linux.efi >>"${_LOG}" + # enable uki handling in presets + sd '#default_uki' 'default_uki' "${_DESTDIR}/etc/mkinitcpio.d/presets" + _run_mkinitcpio + _mkinitcpio_error if [[ -e "${_DESTDIR}/${_UEFISYS_MP}/EFI/Linux/arch-linux.efi" ]]; then _uki_install | _dialog --title " Logging to ${_VC} | ${_LOG} " --gauge "Setting up Unified Kernel Image..." 6 75 0 else diff --git a/usr/lib/archboot/installer/configuration.sh b/usr/lib/archboot/installer/configuration.sh index 75c170090..0c29426d2 100644 --- a/usr/lib/archboot/installer/configuration.sh +++ b/usr/lib/archboot/installer/configuration.sh @@ -15,15 +15,15 @@ _mkinitcpio() { _run_mkinitcpio() { _chroot_mount - echo "Initramfs progress..." > /tmp/mkinitcpio.log + echo "Mkinitcpio progress..." > /tmp/mkinitcpio.log : > /.archboot _mkinitcpio & - _progress_wait "0" "99" "Rebuilding initramfs on installed system..." "0.1" + _progress_wait "0" "99" "Running mkinitcpio on installed system..." "0.1" if [[ -e "/tmp/.mkinitcpio-success" ]]; then - _progress "100" "Rebuilding initramfs complete." 6 75 + _progress "100" "Mkinitcpio complete." 6 75 sleep 2 else - _progress "100" "Rebuilding initramfs failed." 6 75 + _progress "100" "Mkinitcpio failed." 6 75 sleep 2 fi _chroot_umount