From 3bca8966cfbe0ec58e3a58cc4a592b7002b0e1c6 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sat, 14 May 2016 15:54:33 +0100 Subject: plug all parts together...from now on, chainloader will be created automatically --- buildiso | 7 +++++++ kvasile | 2 +- libkvasile | 4 ++++ 3 files changed, 12 insertions(+), 1 deletion(-) diff --git a/buildiso b/buildiso index 86c20b3..fdf993b 100755 --- a/buildiso +++ b/buildiso @@ -41,6 +41,13 @@ prepareiso () { # copy efi image into cdroot mv ""$isosyncdir"/root/bootx64.efi" "$isoefibootdir" chmod 755 ""$isoefibootdir"/bootx64.efi" + # generate grub chainloader for syslinux + isostart + isochainload + isostop + # copy chainloader parts into cdroot + mv ""$isosyncdir"/root/core.img" "$isobootdir" + cp -avx ""$isosyncdir"/usr/lib64/grub/i386-pc/lnxboot.img" "$isobootdir" # configure portage && give up control for package / desktop environment installation isostart isooverlays diff --git a/kvasile b/kvasile index bae83c6..5259e7a 100755 --- a/kvasile +++ b/kvasile @@ -40,7 +40,7 @@ export local isobuildgit="cd /opt && git clone https://gitlab.com/"$releasename" export local isodracutcmd="dracut -N -a dmsquash-live -a pollcdrom -o systemd -o systemd-initrd -o systemd-networkd -o dracut-systemd --force --kver "$kernelver"" export local isodracutrd="initramfs-"$kernelver".img" export local isoeficmd="grub2-mkimage -d /usr/lib64/grub/x86_64-efi -o bootx64.efi -O x86_64-efi ext2 fat udf btrfs ntfs reiserfs xfs hfsplus lvm ata part_msdos part_gpt part_apple bsd search_fs_uuid normal chain iso9660 configfile help loadenv reboot cat search memdisk tar boot linux chain" -export local isoubncmd="grub2-mkimage -d /usr/lib64/grub/i386-pc -o core.img -O i386-pc biosdisk part_msdos fat" +export local isochainloadcmd="grub2-mkimage -d /usr/lib64/grub/i386-pc -o core.img -O i386-pc biosdisk part_msdos fat" export local isomainarch="x86_64" export local isorootdir=""$releasename"-"$releasetarget"-"$releaseversion"-"$isomainarch"" export local isokernelname="kernel-genkernel-"$isomainarch"-"$kernelver"" diff --git a/libkvasile b/libkvasile index d187456..73ea8d7 100755 --- a/libkvasile +++ b/libkvasile @@ -180,6 +180,10 @@ isoefiimg () { chroot "$isosyncdir" su - "$isouser" -c "$isoeficmd" } +isochainload () { + chroot "$isosyncdir" su - "$isouser" -c "$isochainloadcmd" +} + isochroot () { echo -e "" echo -e "DROPPING YOU TO A ROOT SHELL INTO ISO ENVIRONMENT" -- cgit v1.2.3