From 2eb736c20ec7e9499661fe8057c09387404e3a5c Mon Sep 17 00:00:00 2001 From: Tobias Powalowski Date: Thu, 9 Feb 2023 12:09:57 +0100 Subject: [PATCH] restore presets --- etc/archboot/{init.conf => aarch64-init.conf} | 0 etc/archboot/presets/aarch64 | 9 ++++++ etc/archboot/presets/aarch64-init | 9 ++++++ etc/archboot/presets/aarch64-latest | 9 ++++++ etc/archboot/presets/aarch64-local | 9 ++++++ etc/archboot/presets/initial | 8 +++++ etc/archboot/presets/riscv64 | 9 ++++++ etc/archboot/presets/riscv64-init | 9 ++++++ etc/archboot/presets/riscv64-latest | 9 ++++++ etc/archboot/presets/riscv64-local | 9 ++++++ etc/archboot/presets/x86_64 | 8 +++++ etc/archboot/presets/x86_64-init | 8 +++++ etc/archboot/presets/x86_64-latest | 8 +++++ etc/archboot/presets/x86_64-local | 8 +++++ etc/archboot/riscv64-init.conf | 29 +++++++++++++++++++ etc/archboot/x86_64-init.conf | 29 +++++++++++++++++++ usr/lib/archboot/iso.sh | 2 +- .../archboot/grub/archboot-main-grub.cfg | 8 ++--- 18 files changed, 175 insertions(+), 5 deletions(-) rename etc/archboot/{init.conf => aarch64-init.conf} (100%) create mode 100644 etc/archboot/presets/aarch64 create mode 100644 etc/archboot/presets/aarch64-init create mode 100644 etc/archboot/presets/aarch64-latest create mode 100644 etc/archboot/presets/aarch64-local create mode 100644 etc/archboot/presets/initial create mode 100644 etc/archboot/presets/riscv64 create mode 100644 etc/archboot/presets/riscv64-init create mode 100644 etc/archboot/presets/riscv64-latest create mode 100644 etc/archboot/presets/riscv64-local create mode 100644 etc/archboot/presets/x86_64 create mode 100644 etc/archboot/presets/x86_64-init create mode 100644 etc/archboot/presets/x86_64-latest create mode 100644 etc/archboot/presets/x86_64-local create mode 100644 etc/archboot/riscv64-init.conf create mode 100644 etc/archboot/x86_64-init.conf diff --git a/etc/archboot/init.conf b/etc/archboot/aarch64-init.conf similarity index 100% rename from etc/archboot/init.conf rename to etc/archboot/aarch64-init.conf diff --git a/etc/archboot/presets/aarch64 b/etc/archboot/presets/aarch64 new file mode 100644 index 000000000..0d4842672 --- /dev/null +++ b/etc/archboot/presets/aarch64 @@ -0,0 +1,9 @@ +# Created by Tobias Powalowski +# SPDX-License-Identifier: GPL-2.0-only +# mkinitcpio config file, defaulted to stock config file +MKINITCPIO_CONFIG="/etc/archboot/aarch64.conf" + +# kernel version, defaulted to build for runtime kernel +ALL_kver="/boot/Image.gz" + +# vim: set ft=sh ts=4 sw=4 et: diff --git a/etc/archboot/presets/aarch64-init b/etc/archboot/presets/aarch64-init new file mode 100644 index 000000000..1324691c5 --- /dev/null +++ b/etc/archboot/presets/aarch64-init @@ -0,0 +1,9 @@ +# Created by Tobias Powalowski +# SPDX-License-Identifier: GPL-2.0-only +# mkinitcpio config file, defaulted to stock config file +MKINITCPIO_CONFIG="/etc/archboot/aarch64-init.conf" + +# kernel version, defaulted to build for runtime kernel +ALL_kver="/boot/Image.gz" + +# vim: set ft=sh ts=4 sw=4 et: diff --git a/etc/archboot/presets/aarch64-latest b/etc/archboot/presets/aarch64-latest new file mode 100644 index 000000000..1e7193767 --- /dev/null +++ b/etc/archboot/presets/aarch64-latest @@ -0,0 +1,9 @@ +# Created by Tobias Powalowski +# SPDX-License-Identifier: GPL-2.0-only +# mkinitcpio config file, defaulted to stock config file +MKINITCPIO_CONFIG="/etc/archboot/aarch64-latest.conf" + +# kernel version, defaulted to build for runtime kernel +ALL_kver="/boot/Image.gz" + +# vim: set ft=sh ts=4 sw=4 et: diff --git a/etc/archboot/presets/aarch64-local b/etc/archboot/presets/aarch64-local new file mode 100644 index 000000000..ca797aca0 --- /dev/null +++ b/etc/archboot/presets/aarch64-local @@ -0,0 +1,9 @@ +# Created by Tobias Powalowski +# SPDX-License-Identifier: GPL-2.0-only +# mkinitcpio config file, defaulted to stock config file +MKINITCPIO_CONFIG="/etc/archboot/aarch64-local.conf" + +# kernel version, defaulted to build for runtime kernel +ALL_kver="/boot/Image.gz" + +# vim: set ft=sh ts=4 sw=4 et: diff --git a/etc/archboot/presets/initial b/etc/archboot/presets/initial new file mode 100644 index 000000000..5c5795356 --- /dev/null +++ b/etc/archboot/presets/initial @@ -0,0 +1,8 @@ +# Created by Tobias Powalowski +# SPDX-License-Identifier: GPL-2.0-only +# mkinitcpio config file, defaulted to stock config file +MKINITCPIO_CONFIG="/etc/archboot/initial.conf" + +# kernel version, defaulted to build for runtime kernel +ALL_kver="/boot/vmlinuz-linux" +# vim: set ft=sh ts=4 sw=4 et: diff --git a/etc/archboot/presets/riscv64 b/etc/archboot/presets/riscv64 new file mode 100644 index 000000000..803ffc67f --- /dev/null +++ b/etc/archboot/presets/riscv64 @@ -0,0 +1,9 @@ +# Created by Tobias Powalowski +# SPDX-License-Identifier: GPL-2.0-only +# mkinitcpio config file, defaulted to stock config file +MKINITCPIO_CONFIG="/etc/archboot/riscv64.conf" + +# kernel version, defaulted to build for runtime kernel +ALL_kver="/boot/vmlinuz-linux" + +# vim: set ft=sh ts=4 sw=4 et: diff --git a/etc/archboot/presets/riscv64-init b/etc/archboot/presets/riscv64-init new file mode 100644 index 000000000..d99f88af0 --- /dev/null +++ b/etc/archboot/presets/riscv64-init @@ -0,0 +1,9 @@ +# Created by Tobias Powalowski +# SPDX-License-Identifier: GPL-2.0-only +# mkinitcpio config file, defaulted to stock config file +MKINITCPIO_CONFIG="/etc/archboot/riscv64-init.conf" + +# kernel version, defaulted to build for runtime kernel +ALL_kver="/boot/vmlinuz-linux" + +# vim: set ft=sh ts=4 sw=4 et: diff --git a/etc/archboot/presets/riscv64-latest b/etc/archboot/presets/riscv64-latest new file mode 100644 index 000000000..30b37824b --- /dev/null +++ b/etc/archboot/presets/riscv64-latest @@ -0,0 +1,9 @@ +# Created by Tobias Powalowski +# SPDX-License-Identifier: GPL-2.0-only +# mkinitcpio config file, defaulted to stock config file +MKINITCPIO_CONFIG="/etc/archboot/riscv64-latest.conf" + +# kernel version, defaulted to build for runtime kernel +ALL_kver="/boot/vmlinuz-linux" + +# vim: set ft=sh ts=4 sw=4 et: diff --git a/etc/archboot/presets/riscv64-local b/etc/archboot/presets/riscv64-local new file mode 100644 index 000000000..8639d5759 --- /dev/null +++ b/etc/archboot/presets/riscv64-local @@ -0,0 +1,9 @@ +# Created by Tobias Powalowski +# SPDX-License-Identifier: GPL-2.0-only +# mkinitcpio config file, defaulted to stock config file +MKINITCPIO_CONFIG="/etc/archboot/riscv64-local.conf" + +# kernel version, defaulted to build for runtime kernel +ALL_kver="/boot/vmlinuz-linux" + +# vim: set ft=sh ts=4 sw=4 et: diff --git a/etc/archboot/presets/x86_64 b/etc/archboot/presets/x86_64 new file mode 100644 index 000000000..148bc8c79 --- /dev/null +++ b/etc/archboot/presets/x86_64 @@ -0,0 +1,8 @@ +# Created by Tobias Powalowski +# SPDX-License-Identifier: GPL-2.0-only +# mkinitcpio config file, defaulted to stock config file +MKINITCPIO_CONFIG="/etc/archboot/x86_64.conf" + +# kernel version, defaulted to build for runtime kernel +ALL_kver="/boot/vmlinuz-linux" +# vim: set ft=sh ts=4 sw=4 et: diff --git a/etc/archboot/presets/x86_64-init b/etc/archboot/presets/x86_64-init new file mode 100644 index 000000000..4030f9e26 --- /dev/null +++ b/etc/archboot/presets/x86_64-init @@ -0,0 +1,8 @@ +# Created by Tobias Powalowski +# SPDX-License-Identifier: GPL-2.0-only +# mkinitcpio config file, defaulted to stock config file +MKINITCPIO_CONFIG="/etc/archboot/x86_64-init.conf" + +# kernel version, defaulted to build for runtime kernel +ALL_kver="/boot/vmlinuz-linux" +# vim: set ft=sh ts=4 sw=4 et: diff --git a/etc/archboot/presets/x86_64-latest b/etc/archboot/presets/x86_64-latest new file mode 100644 index 000000000..07860b14d --- /dev/null +++ b/etc/archboot/presets/x86_64-latest @@ -0,0 +1,8 @@ +# Created by Tobias Powalowski +# SPDX-License-Identifier: GPL-2.0-only +# mkinitcpio config file, defaulted to stock config file +MKINITCPIO_CONFIG="/etc/archboot/x86_64-latest.conf" + +# kernel version, defaulted to build for runtime kernel +ALL_kver="/boot/vmlinuz-linux" +# vim: set ft=sh ts=4 sw=4 et: diff --git a/etc/archboot/presets/x86_64-local b/etc/archboot/presets/x86_64-local new file mode 100644 index 000000000..7099ef8a0 --- /dev/null +++ b/etc/archboot/presets/x86_64-local @@ -0,0 +1,8 @@ +# Created by Tobias Powalowski +# SPDX-License-Identifier: GPL-2.0-only +# mkinitcpio config file, defaulted to stock config file +MKINITCPIO_CONFIG="/etc/archboot/x86_64-local.conf" + +# kernel version, defaulted to build for runtime kernel +ALL_kver="/boot/vmlinuz-linux" +# vim: set ft=sh ts=4 sw=4 et: diff --git a/etc/archboot/riscv64-init.conf b/etc/archboot/riscv64-init.conf new file mode 100644 index 000000000..2355fe8c3 --- /dev/null +++ b/etc/archboot/riscv64-init.conf @@ -0,0 +1,29 @@ +# Created by Tobias Powalowski +# SPDX-License-Identifier: GPL-2.0-only +# For more information on how using mkinitcpio please refer to the main config file +# or check the wiki. +MODULES=() +BINARIES=() +FILES=() + +# SETUP +# +# Please change the hooks only if you know what you are doing. +HOOKS=(archboot_init) + +# COMPRESSION +# Use this to compress the initramfs image. By default, gzip compression +# is used. Use 'cat' to create an uncompressed image. +COMPRESSION="zstd" +#COMPRESSION="gzip" +#COMPRESSION="bzip2" +#COMPRESSION="lzma" +#COMPRESSION="xz" +#COMPRESSION="lzop" +#COMPRESSION="lz4" + +# COMPRESSION_OPTIONS +# Additional options for the compressor +COMPRESSION_OPTIONS=(-19) +MODULES_DECOMPRESS="no" +# vim: set ft=sh ts=4 sw=4 et: diff --git a/etc/archboot/x86_64-init.conf b/etc/archboot/x86_64-init.conf new file mode 100644 index 000000000..2355fe8c3 --- /dev/null +++ b/etc/archboot/x86_64-init.conf @@ -0,0 +1,29 @@ +# Created by Tobias Powalowski +# SPDX-License-Identifier: GPL-2.0-only +# For more information on how using mkinitcpio please refer to the main config file +# or check the wiki. +MODULES=() +BINARIES=() +FILES=() + +# SETUP +# +# Please change the hooks only if you know what you are doing. +HOOKS=(archboot_init) + +# COMPRESSION +# Use this to compress the initramfs image. By default, gzip compression +# is used. Use 'cat' to create an uncompressed image. +COMPRESSION="zstd" +#COMPRESSION="gzip" +#COMPRESSION="bzip2" +#COMPRESSION="lzma" +#COMPRESSION="xz" +#COMPRESSION="lzop" +#COMPRESSION="lz4" + +# COMPRESSION_OPTIONS +# Additional options for the compressor +COMPRESSION_OPTIONS=(-19) +MODULES_DECOMPRESS="no" +# vim: set ft=sh ts=4 sw=4 et: diff --git a/usr/lib/archboot/iso.sh b/usr/lib/archboot/iso.sh index 33d339f3e..4590b81a7 100644 --- a/usr/lib/archboot/iso.sh +++ b/usr/lib/archboot/iso.sh @@ -45,7 +45,7 @@ _prepare_kernel_initramfs_files() { source "${_PRESET}" mkdir -p "${_ISODIR}"/EFI/{BOOT,TOOLS} mkdir -p "${_ISODIR}/boot" - mkinitcpio -c "/etc/archboot/init.conf" -k "${ALL_kver}" -g "${_ISODIR}/boot/initramfs.img" || exit 1 + mkinitcpio -c "/etc/archboot/init-${_ARCH}.conf" -k "${ALL_kver}" -g "${_ISODIR}/boot/init-${_ARCH}.img" || exit 1 #shellcheck disable=SC2154 mkinitcpio -c "${MKINITCPIO_CONFIG}" -k "${ALL_kver}" -g "${_ISODIR}/boot/initramfs-${_ARCH}.img" || exit 1 # delete cachedir on archboot environment diff --git a/usr/share/archboot/grub/archboot-main-grub.cfg b/usr/share/archboot/grub/archboot-main-grub.cfg index fb703f47c..02a85a659 100644 --- a/usr/share/archboot/grub/archboot-main-grub.cfg +++ b/usr/share/archboot/grub/archboot-main-grub.cfg @@ -65,7 +65,7 @@ if [ ${grub_platform} == "pc" ]; then menuentry "Archboot Arch Linux x86_64 - BIOS Mode" { _menu_running linux /boot/vmlinuz-x86_64 rootfstype=ramfs console=ttyS0,115200 console=tty0 audit=0 - initrd /boot/intel-ucode.img /boot/amd-ucode.img /boot/initramfs.img + initrd /boot/intel-ucode.img /boot/amd-ucode.img /boot/init-x86_64.img } menuentry "Memory Tester (memtest86+)" { _menu_running @@ -79,7 +79,7 @@ if [ ${grub_platform} == "efi" ]; then menuentry "Archboot Arch Linux x86_64" { _menu_running linux /boot/vmlinuz-x86_64 rootfstype=ramfs console=ttyS0,115200 console=tty0 audit=0 - initrd /boot/intel-ucode.img /boot/amd-ucode.img /boot/initramfs.img + initrd /boot/intel-ucode.img /boot/amd-ucode.img /boot/init-x86_64.img } _efi_shell elif [ ${grub_cpu} == "arm64" ]; then @@ -87,14 +87,14 @@ if [ ${grub_platform} == "efi" ]; then menuentry "Archboot Arch Linux AA64" { _menu_running linux /boot/Image-aarch64.gz rootfstype=ramfs nr_cpus=1 console=ttyAMA0,115200 console=tty0 loglevel=4 audit=0 - initrd /boot/amd-ucode.img /boot/initramfs.img + initrd /boot/amd-ucode.img /boot/init-aarch64.img } elif [ ${grub_cpu} == "i386" ]; then set default="Archboot Arch Linux x86_64 - EFI MIXED MODE" menuentry "Archboot Arch Linux x86_64 - EFI MIXED MODE" { _menu_running linux /boot/vmlinuz-x86_64 rootfstype=ramfs _IA32_UEFI=1 console=ttyS0,115200 console=tty0 audit=0 - initrd /boot/intel-ucode.img /boot/amd-ucode.img /boot/initramfs.img + initrd /boot/intel-ucode.img /boot/amd-ucode.img /boot/init-x86_64.img } _efi_shell fi