# 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.121 2006/01/20 14:34:57 rocket Exp $
+# $Header: /var/cvsroot/gentoo/src/catalyst/modules/generic_stage_target.py,v 1.122 2006/01/25 16:07:35 rocket Exp $
"""
This class does all of the chroot setup, copying of files, etc. It is
if os.path.isdir(self.settings["source_path"]):
print "Source path set to "+self.settings["source_path"]
print "\tIf this is not desired, remove this directory or turn of seedcache in the options of catalyst.conf"
- print "\tthe source path will then be "+normpath(self.settings["storedir"]+"/builds/"+self.settings["source_subpath"]+".tar.bz2\n")
+ print "\tthe source path with then be "+normpath(self.settings["storedir"]+"/builds/"+self.settings["source_subpath"]+".tar.bz2\n")
else:
print "Source path set to "+self.settings["source_path"]
self.valid_values.append("boot/kernel/"+x+"/aliases")
self.valid_values.append("boot/kernel/"+x+"/extraversion")
self.valid_values.append("boot/kernel/"+x+"/packages")
+ if type(addlargs["boot/kernel/"+x+"/packages"]) == types.StringType:
+ addlargs["boot/kernel/"+x+"/packages"]=[addlargs["boot/kernel/"+x+"/packages"]]
self.valid_values.append("boot/kernel/"+x+"/use")
self.valid_values.append("boot/kernel/"+x+"/gk_kernargs")
self.valid_values.append("boot/kernel/"+x+"/gk_action")
loop2=addlargs["boot/kernel/"+x+"/postconf"]
for y in loop2:
- addlargs["boot/kernel/"+x+"/packages"].append(y)
+ if not addlargs.has_key("boot/kernel/"+x+"/packages"):
+ addlargs["boot/kernel/"+x+"/packages"]=[[y]]
+ else:
+ addlargs["boot/kernel/"+x+"/packages"].append(y)
def set_build_kernel_vars(self):
if self.settings.has_key(self.settings["spec_prefix"]+"/devmanager"):
#!/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.24 2006/01/24 19:30:47 wolf31o2 Exp $
+# $Header: /var/cvsroot/gentoo/src/catalyst/targets/support/bootloader-setup.sh,v 1.25 2006/01/25 16:07:35 rocket Exp $
. ${clst_sharedir}/targets/support/functions.sh
. ${clst_sharedir}/targets/support/filesystem-functions.sh
check_bootargs
check_filesystem_type
-eval "clst_kernel_softlevel=\$clst_boot_kernel_${clst_kname}_softlevel"
-
default_append_line="root=/dev/ram0 init=/linuxrc ${cmdline_opts} ${custom_kopts} cdroot"
-if ${clst_kernel_softlevel}
-then
- default_append_line="${default_append_line} softlevel=${clst_kernel_softlevel}"
-fi
-
case ${clst_mainarch} in
alpha)
+ # NO SOFTLEVEL SUPPORT YET
acfg=$1/etc/aboot.conf
bctr=0
for x in ${clst_boot_kernel}
done
;;
arm)
+ # NO SOFTLEVEL SUPPORT YET
;;
hppa)
+ # NO SOFTLEVEL SUPPORT YET
icfg=$1/boot/palo.conf
kmsg=$1/boot/kernels.msg
hmsg=$1/boot/help.msg
echo "--ramdisk=boot/${first}.igz" >> ${icfg}
;;
ppc)
+ # NO SOFTLEVEL SUPPORT YET
+
# PPC requirements:
# -----------------
# The specs indicate the kernels to be build. We need to put
# but the following suffices for now:
# this sets up the config file for yaboot
+
+
+ # ADD RUNLEVEL SUPPORT ???
+
icfg=$1/boot/yaboot.conf
kmsg=$1/boot/boot.msg
echo "default ${first}" > ${icfg}
echo "bgcolor=black" >> ${icfg}
echo "message=/boot/boot.msg" >> ${icfg}
for x in ${clst_boot_kernel}
- do
+ do
eval custom_kopts=\$${x}_kernelopts
echo "APPENDING CUSTOM KERNEL ARGS: ${custom_kopts}"
echo >> ${icfg}
done
;;
sparc*)
+ # NO SOFTLEVEL SUPPORT YET
+
scfg=$1/boot/silo.conf
echo "default=\"help\"" > ${scfg}
echo "message=\"/boot/boot.msg\"" >> ${scfg}
echo -e "label=\"help\"" >> ${scfg}
;;
ia64)
+ # NO SOFTLEVEL SUPPORT YET
+
iacfg=$1/boot/elilo.conf
echo 'prompt' > ${iacfg}
echo 'message=/efi/boot/elilo.msg' >> ${iacfg}
echo 'chooser=simple' >> ${iacfg}
echo 'timeout=50' >> ${iacfg}
- echo 'relocatable' >> ${iacfg}
echo >> ${iacfg}
for x in ${clst_boot_kernel}
do
eval custom_kopts=\$${x}_kernelopts
echo "APPENDING CUSTOM KERNEL ARGS: ${custom_kopts}"
echo >> ${icfg}
- echo "label ${x}" >> ${icfg}
- echo " kernel ${x}" >> ${icfg}
- if [ "${clst_livecd_splash_type}" == "gensplash" -a -n "${clst_livecd_splash_theme}" ]
+
+ eval "clst_kernel_softlevel=\$clst_boot_kernel_${x}_softlevel"
+
+ if [ -n "${clst_kernel_softlevel}" ]
then
- echo " append ${default_append_line} initrd=${x}.igz vga=791 splash=silent,theme:${clst_livecd_splash_theme} CONSOLE=/dev/tty1 quiet" >> ${icfg}
+ for y in ${clst_kernel_softlevel}
+ do
+ echo "label ${x}-${y}" >> ${icfg}
+ echo " kernel ${x}" >> ${icfg}
+ if [ "${clst_livecd_splash_type}" == "gensplash" -a -n "${clst_livecd_splash_theme}" ]
+ then
+ echo " append ${default_append_line} softlevel=${y} initrd=${x}.igz vga=791 splash=silent,theme:${clst_livecd_splash_theme} CONSOLE=/dev/tty1 quiet" >> ${icfg}
+ else
+ echo " append ${default_append_line} softlevel=${y} initrd=${x}.igz vga=791 splash=silent" >> ${icfg}
+ fi
+
+ echo >> ${icfg}
+ echo " ${x}" >> ${kmsg}
+ echo "label ${x}-${y}-nofb" >> ${icfg}
+ echo " kernel ${x}" >> ${icfg}
+ echo " append ${default_append_line} softlevel=${y} initrd=${x}.igz" >> ${icfg}
+ echo >> ${icfg}
+ echo " ${x}-nofb" >> ${kmsg}
+ done
else
- echo " append ${default_append_line} initrd=${x}.igz vga=791 splash=silent" >> ${icfg}
+ echo "label ${x}" >> ${icfg}
+ echo " kernel ${x}" >> ${icfg}
+ if [ "${clst_livecd_splash_type}" == "gensplash" -a -n "${clst_livecd_splash_theme}" ]
+ then
+ echo " append ${default_append_line} initrd=${x}.igz vga=791 splash=silent,theme:${clst_livecd_splash_theme} CONSOLE=/dev/tty1 quiet" >> ${icfg}
+ else
+ echo " append ${default_append_line} initrd=${x}.igz vga=791 splash=silent" >> ${icfg}
+ fi
+
+ echo >> ${icfg}
+ echo " ${x}" >> ${kmsg}
+ echo "label ${x}-nofb" >> ${icfg}
+ echo " kernel ${x}" >> ${icfg}
+ echo " append ${default_append_line} initrd=${x}.igz" >> ${icfg}
+ echo >> ${icfg}
+ echo " ${x}-nofb" >> ${kmsg}
fi
-
- echo >> ${icfg}
- echo " ${x}" >> ${kmsg}
- echo "label ${x}-nofb" >> ${icfg}
- echo " kernel ${x}" >> ${icfg}
- echo " append ${default_append_line} initrd=${x}.igz" >> ${icfg}
- echo >> ${icfg}
- echo " ${x}-nofb" >> ${kmsg}
done
if [ -f $1/isolinux/memtest86 ]
eval custom_kopts=\$${x}_kernelopts
echo "APPENDING CUSTOM KERNEL ARGS: ${custom_kopts}"
echo >> ${icfg}
- echo "title ${x}" >> ${icfg}
-
- if [ "${clst_livecd_splash_type}" == "gensplash" -a -n "${clst_livecd_splash_theme}" ]
+
+ eval "clst_kernel_softlevel=\$clst_boot_kernel_${x}_softlevel"
+
+ if [ -n "${clst_kernel_softlevel}" ]
then
- echo "kernel /boot/${x} ${default_append_line} vga=791 splash=silent,theme:${clst_livecd_splash_theme} CONSOLE=/dev/tty1 quiet" >> ${icfg}
+ for y in ${clst_kernel_softlevel}
+ do
+ echo "title ${x}-${y}" >> ${icfg}
+ if [ "${clst_livecd_splash_type}" == "gensplash" -a -n "${clst_livecd_splash_theme}" ]
+ then
+ echo "kernel /boot/${x} softlevel=${y} ${default_append_line} vga=791 splash=silent,theme:${clst_livecd_splash_theme} CONSOLE=/dev/tty1 quiet" >> ${icfg}
+ else
+ echo "kernel /boot/${x} softlevel=${y} ${default_append_line} vga=791 splash=silent" >> ${icfg}
+ fi
+ if [ -e $1/boot/${x}.igz ]
+ then
+ echo "initrd /boot/${x}.igz" >> ${icfg}
+ fi
+ echo >> ${icfg}
+ echo "title ${x}-${y} [ No FrameBuffer ]" >> ${icfg}
+ echo "kernel ${x} /boot/${x} softlevel=${y} ${default_append_line}" >> ${icfg}
+ if [ -e $1/boot/${x}.igz ]
+ then
+ echo "initrd /boot/${x}.igz" >> ${icfg}
+ fi
+ echo >> ${icfg}
+ done
else
- echo "kernel /boot/${x} ${default_append_line} vga=791 splash=silent" >> ${icfg}
+ echo "title ${x}" >> ${icfg}
+ if [ "${clst_livecd_splash_type}" == "gensplash" -a -n "${clst_livecd_splash_theme}" ]
+ then
+ echo "kernel /boot/${x} ${default_append_line} vga=791 splash=silent,theme:${clst_livecd_splash_theme} CONSOLE=/dev/tty1 quiet" >> ${icfg}
+ else
+ echo "kernel /boot/${x} ${default_append_line} vga=791 splash=silent" >> ${icfg}
+ fi
+ if [ -e $1/boot/${x}.igz ]
+ then
+ echo "initrd /boot/${x}.igz" >> ${icfg}
+ fi
+ echo >> ${icfg}
+ echo "title ${x} [ No FrameBuffer ]" >> ${icfg}
+ echo "kernel ${x} /boot/${x} ${default_append_line}" >> ${icfg}
+ if [ -e $1/boot/${x}.igz ]
+ then
+ echo "initrd /boot/${x}.igz" >> ${icfg}
+ fi
fi
- if [ -e $1/boot/${x}.igz ]
- then
- echo "initrd /boot/${x}.igz" >> ${icfg}
- fi
-
- echo >> ${icfg}
- echo "title ${x} [ No FrameBuffer ]" >> ${icfg}
- echo "kernel ${x} /boot/${x} ${default_append_line}" >> ${icfg}
- if [ -e $1/boot/${x}.igz ]
- then
- echo "initrd /boot/${x}.igz" >> ${icfg}
- fi
done
if [ -f $1/boot/memtest86 ]
fi
;;
mips)
+
+ # NO SOFTLEVEL SUPPORT YET
+
+
# Mips is an interesting arch -- where most archs will
# use ${1} as the root of the LiveCD, an SGI LiveCD lacks
# such a root. Instead, we will use ${1} as a scratch