adding in the sparc stuff
authorJohn P. Davis <zhen@gentoo.org>
Wed, 31 Mar 2004 15:22:41 +0000 (15:22 +0000)
committerJohn P. Davis <zhen@gentoo.org>
Wed, 31 Mar 2004 15:22:41 +0000 (15:22 +0000)
git-svn-id: svn+ssh://svn.gentoo.org/var/svnroot/catalyst/trunk@331 d1e1f19c-881f-0410-ab34-b69fee027534

livecd/isogen/sparc-isogen.sh [new file with mode: 0755]
livecd/runscript/sparc-archscript.sh [new file with mode: 0644]

diff --git a/livecd/isogen/sparc-isogen.sh b/livecd/isogen/sparc-isogen.sh
new file mode 100755 (executable)
index 0000000..0645c3d
--- /dev/null
@@ -0,0 +1,2 @@
+#!/bin/bash
+mkisofs -J -R -l -o ../gentoo.iso  -G /boot/isofs.b -B ... .
diff --git a/livecd/runscript/sparc-archscript.sh b/livecd/runscript/sparc-archscript.sh
new file mode 100644 (file)
index 0000000..f2ea231
--- /dev/null
@@ -0,0 +1,88 @@
+# Copyright 1999-2004 Gentoo Technologies, Inc.
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo/src/catalyst/livecd/runscript/Attic/sparc-archscript.sh,v 1.1 2004/03/31 15:22:41 zhen Exp $
+
+case $1 in
+       kernel)
+               # Workaround until new genkernel is released
+               genkernel_args="--makeopts=-j1"
+               export genkernel_args
+       ;;
+
+       preclean)
+       ;;
+
+       clean)
+       ;;
+
+       bootloader)
+               # Time to create a filesystem tree for the ISO at
+               # $clst_cdroot_path. We extract the "cdtar" to this directory,
+               # which will normally contains a pre-built binary
+               # boot-loader/filesystem skeleton for the ISO. 
+               
+               cdtar=$clst_livecd_cdtar
+               [ "$cdtar" = "" ] && die "No livecd/cdtar specified (required)"
+               tar xjpvf $cdtar -C $clst_cdroot_path || die \
+                   "Couldn't extract cdtar $cdtar"
+               if [ "$clst_boot_kernel" = "" ]
+               then
+                       echo "No boot/kernel setting defined, exiting."
+                       exit 1
+               fi
+               first=""
+               for x in $clst_boot_kernel
+               do
+                       if [ "$first" = "" ]
+                       then
+                               #grab name of first kernel
+                               first="$x"
+                       fi
+                       if [ ! -e "$clst_chroot_path/tmp/binaries/$x.tar.bz2" ] 
+                       then
+                               echo "Can't find kernel tarball at $clst_chroot_path/tmp/binaries/$x.tar.bz2"
+                               exit 1
+                       fi
+                       tar xjvf $clst_chroot_path/tmp/binaries/$x.tar.bz2 -C \
+                           $clst_cdroot_path/boot
+                       # change kernel name from "kernel" to "gentoo", for
+                       # example
+                       mv $clst_cdroot_path/boot/kernel \
+                           $clst_cdroot_path/boot/$x
+                       # change initrd name from "initrd" to "gentoo.igz",
+                       # for example
+                       mv $clst_cdroot_path/boot/initrd \
+                           $clst_cdroot_path/boot/$x.igz
+               done
+               scfg=$clst_cdroot_path/boot/silo.conf
+               kmsg=$clst_cdroot_path/boot/kernels.msg
+               hmsg=$clst_cdroot_path/boot/help.msg
+               echo "default=\"$first\"" > $scfg
+               echo "timeout=\"150\"" >> $scfg
+               echo "message=\"/boot/boot.msg\"" >> $scfg
+
+               echo "Available kernels:" > $kmsg
+               echo "TEST HELP MESSAGE" > $hmsg
+
+               for x in $clst_boot_kernel
+               do
+                       echo >> $icfg
+                       echo "image=\"/boot/$x\"" >> $scfg
+                       echo -e "\tlabel=\"$x\"" >> $scfg
+                       echo -e "\tappend=\"initrd=/boot/$x.igz root=/dev/ram0 init=/linuxrc ${cmdline_opts} cdroot\"" >> $scfg
+
+               done
+
+               echo "image=\"cat /boot/silo.conf\"" >> $scfg
+               echo -e "label=\"config\"" >> $scfg
+       ;;
+
+       cdfs)
+       ;;
+
+       iso)
+               # this is for the livecd-final target, and calls the proper
+               # command to build the iso file
+               mkisofs -J -R -l -o ${2} -G /boot/isofs.b -B ... ${clst_cdroot_path}
+       ;;
+esac