2003-03-14 21:10:45 -01:00
|
|
|
#!/bin/bash
|
|
|
|
#
|
|
|
|
# Do install stuff for alpha, including making bootable CDs
|
|
|
|
# Works with debian-installer
|
|
|
|
#
|
2003-09-20 19:05:09 +00:00
|
|
|
#Vorlon:
|
|
|
|
#
|
|
|
|
#The following pieces are still missing:
|
|
|
|
#
|
|
|
|
#- MILO bootloader & images. I have no way to test this directly, and
|
|
|
|
# haven't used MILO for years, so I'm giving this a pass on the first
|
|
|
|
# run.
|
|
|
|
#- Floppy images. Currently, debian-installer claims not to support
|
|
|
|
# the floppy target on alpha, which is arbitrary, but there may just not
|
|
|
|
# be any reason to continue supporting this install method. Another
|
|
|
|
# decision that can be made later.
|
|
|
|
#
|
2003-03-14 21:10:45 -01:00
|
|
|
# $1 is the CD number
|
|
|
|
# $2 is the temporary CD build dir
|
|
|
|
|
2004-07-11 09:34:59 +00:00
|
|
|
. $BASEDIR/tools/boot/$DI_CODENAME/common.sh
|
2003-09-20 19:05:09 +00:00
|
|
|
|
2003-03-14 21:10:45 -01:00
|
|
|
set -e
|
|
|
|
|
|
|
|
N=$1
|
|
|
|
CDDIR=$2
|
2003-09-20 19:05:09 +00:00
|
|
|
BOOTDIR=
|
2004-04-18 12:05:46 +00:00
|
|
|
if [ "$DI_WWW_HOME" = "default" ];then
|
2004-08-05 17:48:35 +00:00
|
|
|
DI_WWW_HOME="http://people.debian.org/~jbailey/d-i/alpha/daily/cdrom/"
|
2004-04-18 12:05:46 +00:00
|
|
|
fi
|
|
|
|
if [ ! "$DI_DIST" ]; then
|
|
|
|
DI_DIST="$DI_CODENAME"
|
2003-11-13 16:33:50 -01:00
|
|
|
fi
|
2003-03-14 21:10:45 -01:00
|
|
|
|
|
|
|
cd $CDDIR/..
|
|
|
|
|
|
|
|
#
|
|
|
|
# This script is called with $1 (now $N) as the CD to
|
|
|
|
# make bootable. N may be in the form "n" or "n_NONUS"
|
|
|
|
# There may be more than 4 disks...support extras.
|
|
|
|
|
|
|
|
# Strip NONUS part of disk number
|
|
|
|
# NN will be 1...N so it can be used as an index
|
|
|
|
#
|
|
|
|
NN=`echo $N | sed -e 's/_NONUS//'`
|
|
|
|
|
2004-04-18 12:05:46 +00:00
|
|
|
mkdir boot$N
|
|
|
|
ab_deb=`ls $MIRROR/pool/main/a/aboot/aboot-base_*.deb | tail -1`
|
|
|
|
ar p $ab_deb data.tar.gz | tar zxf - -C boot$N/ ./boot/bootlx
|
|
|
|
|
2003-03-14 21:10:45 -01:00
|
|
|
# Download boot images
|
2003-09-20 19:05:09 +00:00
|
|
|
# XXX: Driver floppies? Any alpha that /has/ a CDROM should be able to
|
|
|
|
# boot from it, so this would be pure convenience of distribution.
|
|
|
|
#for image in cd_drivers-image.img cdrom-image.img cdrom-initrd.gz floppy-image.img floppy-initrd.gz net_drivers-image.img netboot-initrd.gz vmlinuz ; do
|
|
|
|
|
2004-04-18 12:05:46 +00:00
|
|
|
for image in initrd.gz vmlinuz; do
|
2003-03-14 21:10:45 -01:00
|
|
|
if [ ! -e "$image" ]; then
|
2004-04-18 12:05:46 +00:00
|
|
|
if [ ! "$DI_WWW_HOME" ];then
|
|
|
|
cp "$MIRROR/dists/$DI_DIST/main/installer-$ARCH/current/images/cdrom/$image" .
|
|
|
|
else
|
2003-09-20 19:05:09 +00:00
|
|
|
# XXX: not really 'daily'...
|
2004-04-18 12:05:46 +00:00
|
|
|
wget "$DI_WWW_HOME/$image"
|
|
|
|
fi
|
2003-03-14 21:10:45 -01:00
|
|
|
fi
|
|
|
|
done
|
|
|
|
|
2003-09-20 19:05:09 +00:00
|
|
|
if [ $NN = 1 ]; then
|
|
|
|
echo "Using $THISTYPE boot-disks image on CD$N"
|
|
|
|
mkdir -p boot$N/boot
|
2004-04-18 12:05:46 +00:00
|
|
|
cp initrd.gz vmlinuz boot$N/boot/
|
2003-03-14 21:10:45 -01:00
|
|
|
|
2003-09-20 19:05:09 +00:00
|
|
|
mkdir -p boot$N/etc
|
|
|
|
cat <<EOF > boot$N/etc/aboot.conf
|
2004-04-18 12:05:46 +00:00
|
|
|
0:boot/vmlinuz ramdisk_size=16384 initrd=/boot/initrd.gz root=/dev/ram devfs=mount,dall
|
|
|
|
1:boot/vmlinuz ramdisk_size=16384 initrd=/boot/initrd.gz root=/dev/ram devfs=mount,dall console=ttyS0
|
|
|
|
2:boot/vmlinuz ramdisk_size=16384 initrd=/boot/initrd.gz root=/dev/ram devfs=mount,dall console=ttyS1
|
2003-03-14 21:10:45 -01:00
|
|
|
EOF
|
|
|
|
|
2003-09-20 19:05:09 +00:00
|
|
|
echo -n "-cache-inodes -J -l " > $N.mkisofs_opts
|
|
|
|
mkdir -p boot$N/milo
|
|
|
|
# XXX: we need to build milo first.
|
|
|
|
#cp linload.exe ldmilo.exe boot$N/milo
|
|
|
|
#cp -f $(ls MILO/milo_*.bin | sed 's,\(.*\)milo_\(.*\).bin,\1\2,') \
|
|
|
|
# boot$N/milo/
|
|
|
|
|
|
|
|
# XXX: populate the install directory as well, if we want floppies.
|
|
|
|
#cp -lf *.img $CDDIR/install
|
|
|
|
#cp -lf floppy-initrd.gz $CDDIR/install
|
2003-03-14 21:10:45 -01:00
|
|
|
|
2003-09-20 19:05:09 +00:00
|
|
|
# write final lines to mkisofs_opts
|
2003-03-14 21:10:45 -01:00
|
|
|
echo -n "boot$N " >> $N.mkisofs_opts
|
2003-09-20 19:05:09 +00:00
|
|
|
|
2003-03-14 21:10:45 -01:00
|
|
|
else
|
2003-09-20 19:05:09 +00:00
|
|
|
echo -n "-cache-inodes -J -l " > $N.mkisofs_opts
|
2003-03-14 21:10:45 -01:00
|
|
|
fi
|
|
|
|
|
2003-09-20 19:05:09 +00:00
|
|
|
#install_languages $CDDIR
|