aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Edgar <rocket@gentoo.org>2006-01-27 22:49:10 +0000
committerEric Edgar <rocket@gentoo.org>2006-01-27 22:49:10 +0000
commit8324187584e2545003ebcbaae751ea0ae9898dd8 (patch)
tree7a355b6cd3b9c89b70fab778d6f8ae52af093d3c
parentFix type error when kernel packages arent defined (diff)
downloadcatalyst-8324187584e2545003ebcbaae751ea0ae9898dd8.tar.gz
catalyst-8324187584e2545003ebcbaae751ea0ae9898dd8.tar.bz2
catalyst-8324187584e2545003ebcbaae751ea0ae9898dd8.zip
Fix ppc64 iso creation. Add console machine_type for ppc yaboot separation.
git-svn-id: svn+ssh://svn.gentoo.org/var/svnroot/catalyst/trunk@1051 d1e1f19c-881f-0410-ab34-b69fee027534
-rw-r--r--ChangeLog12
-rw-r--r--livecd/cdtar/yaboot-1.3.11-ppc-cdtar.tar.bz2bin0 -> 61936 bytes
-rw-r--r--modules/generic_stage_target.py4
-rwxr-xr-xtargets/support/bootloader-setup.sh126
-rwxr-xr-xtargets/support/create-iso.sh41
5 files changed, 164 insertions, 19 deletions
diff --git a/ChangeLog b/ChangeLog
index d9b6f591..91e648b8 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,15 @@
# Copyright 2002-2006 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo/src/catalyst/ChangeLog,v 1.536 2006/01/27 15:04:07 rocket Exp $
+# $Header: /var/cvsroot/gentoo/src/catalyst/ChangeLog,v 1.537 2006/01/27 22:49:10 rocket Exp $
+
+ 27 Jan 2006; Eric Edgar <rocket@gentoo.org>
+ +livecd/cdtar/yaboot-1.3.11-ppc-cdtar.tar.bz2,
+ modules/generic_stage_target.py, targets/support/bootloader-setup.sh,
+ targets/support/create-iso.sh:
+ Fix ppc64 iso creation. Add console machine_type for ppc yaboot separation.
+
+ 27 Jan 2006; Eric Edgar <rocket@gentoo.org>
+ modules/generic_stage_target.py, targets/support/bootloader-setup.sh:
+ Add ppc console and machine_type=ibm
27 Jan 2006; Eric Edgar <rocket@gentoo.org>
modules/generic_stage_target.py:
diff --git a/livecd/cdtar/yaboot-1.3.11-ppc-cdtar.tar.bz2 b/livecd/cdtar/yaboot-1.3.11-ppc-cdtar.tar.bz2
new file mode 100644
index 00000000..dfb7472a
--- /dev/null
+++ b/livecd/cdtar/yaboot-1.3.11-ppc-cdtar.tar.bz2
Binary files differ
diff --git a/modules/generic_stage_target.py b/modules/generic_stage_target.py
index 6d232426..608a992a 100644
--- a/modules/generic_stage_target.py
+++ b/modules/generic_stage_target.py
@@ -1,6 +1,6 @@
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo/src/catalyst/modules/generic_stage_target.py,v 1.124 2006/01/27 15:04:07 rocket Exp $
+# $Header: /var/cvsroot/gentoo/src/catalyst/modules/generic_stage_target.py,v 1.125 2006/01/27 22:49:10 rocket Exp $
"""
This class does all of the chroot setup, copying of files, etc. It is
@@ -483,6 +483,8 @@ class generic_stage_target(generic_target):
self.valid_values.append("boot/kernel/"+x+"/gk_action")
self.valid_values.append("boot/kernel/"+x+"/initramfs_overlay")
self.valid_values.append("boot/kernel/"+x+"/softlevel")
+ self.valid_values.append("boot/kernel/"+x+"/console")
+ self.valid_values.append("boot/kernel/"+x+"/machine_type")
self.valid_values.append("boot/kernel/"+x+"/postconf")
if addlargs.has_key("boot/kernel/"+x+"/postconf"):
print "boot/kernel/"+x+"/postconf is deprecated"
diff --git a/targets/support/bootloader-setup.sh b/targets/support/bootloader-setup.sh
index b58c1126..c0c9ca11 100755
--- a/targets/support/bootloader-setup.sh
+++ b/targets/support/bootloader-setup.sh
@@ -1,7 +1,7 @@
#!/bin/bash
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo/src/catalyst/targets/support/bootloader-setup.sh,v 1.26 2006/01/26 21:53:55 wolf31o2 Exp $
+# $Header: /var/cvsroot/gentoo/src/catalyst/targets/support/bootloader-setup.sh,v 1.27 2006/01/27 22:49:10 rocket Exp $
. ${clst_sharedir}/targets/support/functions.sh
. ${clst_sharedir}/targets/support/filesystem-functions.sh
@@ -40,7 +40,7 @@ case ${clst_mainarch} in
echo "--bootloader=boot/iplboot" >> ${icfg}
echo "--ramdisk=boot/${first}.igz" >> ${icfg}
;;
- ppc)
+ ppc|ppc64)
# NO SOFTLEVEL SUPPORT YET
# PPC requirements:
@@ -63,34 +63,130 @@ case ${clst_mainarch} in
icfg=$1/boot/yaboot.conf
kmsg=$1/boot/boot.msg
+
echo "default ${first}" > ${icfg}
echo "timeout 300" >> ${icfg}
echo "device=cd:" >> ${icfg}
echo "root=/dev/ram" >> ${icfg}
echo "fgcolor=white" >> ${icfg}
echo "bgcolor=black" >> ${icfg}
- echo "message=/boot/boot.msg" >> ${icfg}
+ echo "message=/boot" >> ${icfg}
+
+ # Setup the IBM yaboot.conf
+ etc_icfg=$1/etc/yaboot.conf
+ mkdir -p $1/etc
+ IBM_YABOOT="FALSE"
+ echo "default ${first}" > ${etc_icfg}
+ echo "timeout 300" >> ${etc_icfg}
+ echo "device=cd:" >> ${etc_icfg}
+ echo "root=/dev/ram" >> ${etc_icfg}
+ echo "fgcolor=white" >> ${etc_icfg}
+ echo "bgcolor=black" >> ${etc_icfg}
+ echo "message=/boot/boot.msg" >> ${etc_icfg}
+
for x in ${clst_boot_kernel}
do
+ eval "clst_kernel_console=\$clst_boot_kernel_${x}_console"
+ eval "clst_kernel_machine_type=\$clst_boot_kernel_${x}_machine_type"
eval custom_kopts=\$${x}_kernelopts
+
echo "APPENDING CUSTOM KERNEL ARGS: ${custom_kopts}"
- echo >> ${icfg}
- echo "image=/boot/${x}" >> ${icfg}
-
- if [ -e "$1/boot/${x}.igz" ]
+ if [ "${clst_kernel_machine_type}" == "ibm" ]
then
- echo "initrd=/boot/${x}.igz" >> ${icfg}
- fi
+ IBM_YABOOT="true"
+ if [ -n "${clst_kernel_console}" ]
+ then
+ for y in ${clst_kernel_console}
+ do
+ echo ${y}
+ echo >> ${etc_icfg}
+ echo "image=/boot/${x}" >> ${etc_icfg}
- echo "label=${x}" >> ${icfg}
- echo "read-write" >> ${icfg}
- if [ "${clst_livecd_splash_type}" == "gensplash" -a -n "${clst_livecd_splash_theme}" ]
- then
- echo "append=\"${default_append_line} splash=silent,theme:${clst_livecd_splash_theme}\"" >> ${icfg}
+ if [ -e "$1/boot/${x}.igz" ]
+ then
+ echo "initrd=/boot/${x}.igz" >> ${etc_icfg}
+ fi
+
+ echo "label=${x} [${y}] " >> ${etc_icfg}
+ echo "read-write" >> ${icfg}
+ if [ "${clst_livecd_splash_type}" == "gensplash" -a -n "${clst_livecd_splash_theme}" ]
+ then
+ echo "append=\"${default_append_line} console=${y} splash=silent,theme:${clst_livecd_splash_theme}\"" >> ${etc_icfg}
+ else
+ echo "append=\"${default_append_line} console=${y} splash=silent\"" >> ${etc_icfg}
+ fi
+ done
+ else
+ echo >> ${etc_icfg}
+ echo "image=/boot/${x}" >> ${etc_icfg}
+
+ if [ -e "$1/boot/${x}.igz" ]
+ then
+ echo "initrd=/boot/${x}.igz" >> ${etc_icfg}
+ fi
+
+ echo "label=${x}" >> ${etc_icfg}
+ echo "read-write" >> ${etc_icfg}
+ if [ "${clst_livecd_splash_type}" == "gensplash" -a -n "${clst_livecd_splash_theme}" ]
+ then
+ echo "append=\"${default_append_line} splash=silent,theme:${clst_livecd_splash_theme}\"" >> ${etc_icfg}
+ else
+ echo "append=\"${default_append_line} splash=silent\"" >> ${etc_icfg}
+ fi
+ fi
else
- echo "append=\"${default_append_line} splash=silent\"" >> ${icfg}
+ if [ -n "${clst_kernel_console}" ]
+ then
+ for y in ${clst_kernel_console}
+ do
+ echo >> ${icfg}
+ echo "image=/boot/${x}" >> ${icfg}
+
+ if [ -e "$1/boot/${x}.igz" ]
+ then
+ echo "initrd=/boot/${x}.igz" >> ${icfg}
+ fi
+
+ echo "label=${x} [${y}] " >> ${icfg}
+ echo "read-write" >> ${icfg}
+ if [ "${clst_livecd_splash_type}" == "gensplash" -a -n "${clst_livecd_splash_theme}" ]
+ then
+ echo "append=\"${default_append_line} console=${y} splash=silent,theme:${clst_livecd_splash_theme}\"" >> ${icfg}
+ else
+ echo "append=\"${default_append_line} console=${y} splash=silent\"" >> ${icfg}
+ fi
+ done
+ else
+ echo >> ${icfg}
+ echo "image=/boot/${x}" >> ${icfg}
+
+ if [ -e "$1/boot/${x}.igz" ]
+ then
+ echo "initrd=/boot/${x}.igz" >> ${icfg}
+ fi
+
+ echo "label=${x}" >> ${icfg}
+ echo "read-write" >> ${icfg}
+ if [ "${clst_livecd_splash_type}" == "gensplash" -a -n "${clst_livecd_splash_theme}" ]
+ then
+ echo "append=\"${default_append_line} splash=silent,theme:${clst_livecd_splash_theme}\"" >> ${icfg}
+ else
+ echo "append=\"${default_append_line} splash=silent\"" >> ${icfg}
+ fi
+ fi
fi
done
+
+ if [ "${IBM_YABOOT}" == "FALSE" ]
+ then
+ rm ${etc_kmsg}
+ rmdir $1/etc
+ if [ -d $1/ppc ]
+ then
+ rm -r $1/ppc
+ fi
+ fi
+
;;
sparc*)
# NO SOFTLEVEL SUPPORT YET
diff --git a/targets/support/create-iso.sh b/targets/support/create-iso.sh
index e6a4ebda..e7b0faea 100755
--- a/targets/support/create-iso.sh
+++ b/targets/support/create-iso.sh
@@ -1,7 +1,7 @@
#!/bin/bash
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo/src/catalyst/targets/support/create-iso.sh,v 1.24 2006/01/26 23:39:26 wolf31o2 Exp $
+# $Header: /var/cvsroot/gentoo/src/catalyst/targets/support/create-iso.sh,v 1.25 2006/01/27 22:49:10 rocket Exp $
. ${clst_sharedir}/targets/support/functions.sh
. ${clst_sharedir}/targets/support/filesystem-functions.sh
@@ -192,7 +192,7 @@ case ${clst_mainarch} in
*) die "SGI LiveCDs only support the 'normal' fstype!" ;;
esac
;;
- ppc*)
+ ppc)
case ${clst_livecd_cdfstype} in
zisofs)
echo "Running mkisofs to create iso image...."
@@ -222,6 +222,43 @@ case ${clst_mainarch} in
;;
esac
;;
+ ppc64)
+ if [ -f ${clst_target_path}/ppc/bootinfo.txt ]
+ then
+ echo "bootinfo.txt found .. updating it"
+ sed -i ${clst_target_path}/ppc/bootinfo.txt -e 's#^<description>.*</description>$#<description>'"${clst_iso_volume_id}"'</description>#'
+ sed -i ${clst_target_path}/ppc/bootinfo.txt -e 's#^<os-name>.*</os-name>$#<os-name>'"${clst_iso_volume_id}"'</os-name>#'
+ fi
+
+ case ${clst_livecd_cdfstype} in
+ zisofs)
+ echo "Running mkisofs to create iso image...."
+ echo "mkisofs -J -r -U -z -chrp-boot -netatalk -hfs -probe \
+ -map ${clst_target_path}/boot/map.hfs -part -no-desktop \
+ -hfs-volid \"${clst_iso_volume_id}\" -hfs-bless \
+ ${clst_target_path}/boot -V \"${clst_iso_volume_id}\" -o \
+ ${1} ${clst_target_path}"
+ mkisofs -J -r -U -z -chrp-boot -netatalk -hfs -probe -map \
+ ${clst_target_path}/boot/map.hfs -part -no-desktop \
+ -hfs-volid "${clst_iso_volume_id}" -hfs-bless \
+ ${clst_target_path}/boot -V "${clst_iso_volume_id}" -o \
+ ${1} ${clst_target_path} || die "Cannot make ISO image"
+ ;;
+ *)
+ echo "Running mkisofs to create iso image...."
+ echo "mkisofs -J -r -U -chrp-boot -netatalk -hfs -probe -map \
+ ${clst_target_path}/boot/map.hfs -part -no-desktop \
+ -hfs-volid \"${clst_iso_volume_id}\" -hfs-bless \
+ ${clst_target_path}/boot -V \"${clst_iso_volume_id}\" -o \
+ ${1} ${clst_target_path}"
+ mkisofs -J -r -U -chrp-boot -netatalk -hfs -probe -map \
+ ${clst_target_path}/boot/map.hfs -part -no-desktop \
+ -hfs-volid "${clst_iso_volume_id}" -hfs-bless \
+ ${clst_target_path}/boot -V "${clst_iso_volume_id}" -o \
+ ${1} ${clst_target_path} || die "Cannot make ISO image"
+ ;;
+ esac
+ ;;
sparc*)
# Old silo + patched mkisofs fubar magic
# Only silo 1.2.x seems to work for most hardware