debian-cd-clone/tools/boot/sarge/boot-m68k

74 lines
1.9 KiB
Bash
Executable File

#!/bin/bash
#
# Do install stuff for m68k, including making bootable CDs for bvme6000
# Works with debian-installer
#
# $1 is the CD number
# $2 is the temporary CD build dir
. $BASEDIR/tools/boot/$CODENAME/common.sh
set -e
N=$1
CDDIR=$2
INSTALLDIR=$CDDIR/install
if [ "$DI_WWW_HOME" = "default" ];then
DI_WWW_HOME="http://people.debian.org/~smarenka/d-i/images-m68k/daily"
fi
if [ ! "$DI_DIST" ]; then
DI_DIST="$DI_CODENAME"
fi
DI_BOOTLOADER="http://people.debian.org/~smarenka/d-i/images-m68k/daily"
cd $CDDIR/..
echo -n "--netatalk -J -hfs -probe -map $BASEDIR/data/hfs.map" \
> $N.mkisofs_opts
# Only disk 1 bootable
if [ $N != 1 ]; then
exit 0
fi
install_languages $CDDIR
# remove i386 stuff
rm -rf $CDDIR/tools
cd $INSTALLDIR
# create directories for different sub-archs
mkdir {amiga,atari,bvme6000,mac,mvme147,mvme16x}
wget -O bootloaders.tar.bz2 "$DI_BOOTLOADER"/../../bootloaders.tar.bz2
tar -xvjf bootloaders.tar.bz2
rm bootloaders.tar.bz2
if [ ! "$DI_WWW_HOME" ];then
DI_DIR="$MIRROR/dists/$DI_DIST/main/installer-$ARCH/current/images"
cp "$DI_DIR"/amiga/nativehd-vmlinuz* amiga/vmlinuz
cp "$DI_DIR"/mac/nativehd-vmlinuz* mac/vmlinuz
cp "$DI_DIR/cdrom-initrd.gz" root.bin
cp "$DI_DIR/cdrom22-initrd.gz" root22.bin
else
kernel_amiga=$(wget "$DI_WWW_HOME/amiga/" -O - | \
sed -n 's/.*a href="\(nativehd-vmlinuz-[0-9\.]\+-amiga\)".*/\1/p')
kernel_mac=$(wget "$DI_WWW_HOME/mac/" -O - | \
sed -n 's/.*a href="\(nativehd-vmlinuz-[0-9\.]\+-mac\)".*/\1/p')
wget -O amiga/vmlinuz "$DI_WWW_HOME/amiga/$kernel_amiga"
wget -O mac/vmlinuz "$DI_WWW_HOME/mac/$kernel_mac"
wget -O root.bin "$DI_WWW_HOME/cdrom-initrd.gz"
wget -O root22.bin "$DI_WWW_HOME/cdrom22-initrd.gz"
fi
# Amiboot and dmesg need to be executable
chmod a+x amiga/amiboot-5.6
chmod a+x amiga/dmesg
# Setup amiga icons
cp amiga/amiga.info $CDDIR/install.info
mv amiga/amiga.info .
##-----------------------------< end of file >------------------------------##