Switch to using upstream mk-s390image for s390 cdboot.img creation

mk-s390-cdboot has stopped working because the kernel outgrew the
hard-coded offset it used when creating cdboot.img. IBM now has a script
in s390utils that can do the same thing so use the upstream script
instead.

This drops mk-s390-cdboot script, switches the s390 templates to use
mk-s390image from s390utils.

It adds @ROOT@ to cdboot.prm, and sets inst.stage2 so that the installer
image will be found when booting the iso.

Resolves: rhbz#1903923
This commit is contained in:
Brian C. Lane 2020-10-27 14:03:58 -07:00
parent ff7cb21c0c
commit e61ef8cfc6
3 changed files with 10 additions and 7 deletions

View File

@ -1 +1 @@
ro
ro @ROOT@

View File

@ -6,6 +6,7 @@ KERNELDIR=BOOTDIR
INITRD_ADDRESS="0x02000000"
LIVEDIR="LiveOS"
LORAXDIR="usr/share/lorax/"
MKS390IMAGE="/usr/bin/mk-s390image"
# The assumption seems to be that there is only one s390 kernel, ever
kernel = kernels[0]
@ -74,10 +75,10 @@ treeinfo images-${basearch} cdboot.prm ${BOOTDIR}/cdboot.prm
%endfor
## Make a combined kernel+initrd image for the iso
runcmd mk-s390-cdboot -i ${outroot}/${KERNELDIR}/kernel.img \
runcmd ${MKS390IMAGE} ${outroot}/${KERNELDIR}/kernel.img \
${outroot}/${BOOTDIR}/cdboot.img \
-r ${outroot}/${KERNELDIR}/initrd.img \
-p ${outroot}/${BOOTDIR}/cdboot.prm \
-o ${outroot}/${BOOTDIR}/cdboot.img
-p ${outroot}/${BOOTDIR}/cdboot.prm
## make boot.iso
runcmd mkisofs -o ${outroot}/images/boot.iso \

View File

@ -5,6 +5,7 @@ BOOTDIR="images"
KERNELDIR=BOOTDIR
INITRD_ADDRESS="0x02000000"
LORAXDIR="usr/share/lorax/"
MKS390IMAGE="/usr/bin/mk-s390image"
# The assumption seems to be that there is only one s390 kernel, ever
kernel = kernels[0]
@ -24,6 +25,7 @@ install ${configdir}/generic.ins .
## configure bootloader
replace @INITRD_LOAD_ADDRESS@ ${INITRD_ADDRESS} generic.ins
replace @ROOT@ 'inst.stage2=hd:LABEL=${isolabel|udev}' ${BOOTDIR}/cdboot.prm
## install kernel
installkernel images-${basearch} ${kernel.path} ${KERNELDIR}/kernel.img
@ -61,10 +63,10 @@ treeinfo images-${basearch} generic.ins generic.ins
%endfor
## Make a combined kernel+initrd image for the iso
runcmd mk-s390-cdboot -i ${outroot}/${KERNELDIR}/kernel.img \
runcmd ${MKS390IMAGE} ${outroot}/${KERNELDIR}/kernel.img \
${outroot}/${BOOTDIR}/cdboot.img \
-r ${outroot}/${KERNELDIR}/initrd.img \
-p ${outroot}/${BOOTDIR}/cdboot.prm \
-o ${outroot}/${BOOTDIR}/cdboot.img
-p ${outroot}/${BOOTDIR}/cdboot.prm
## make boot.iso
runcmd mkisofs -o ${outroot}/images/boot.iso \