git-svn-id: http://phraktured.net/archiso@13 00a9fe69-e71b-0410-bb23-df0e5024db41
This commit is contained in:
parent
59ddc5be61
commit
c464db5951
@ -15,9 +15,8 @@ run_hook ()
|
|||||||
squashimg="/tmpfs/bootcd/archlive.sqfs"
|
squashimg="/tmpfs/bootcd/archlive.sqfs"
|
||||||
|
|
||||||
/bin/modprobe -q isofs >/dev/null 2>&1
|
/bin/modprobe -q isofs >/dev/null 2>&1
|
||||||
PS1="ramfs$ " /bin/sh -i
|
|
||||||
for cdrom in /dev/cd/*; do
|
for cdrom in /dev/cd/*; do
|
||||||
if mount -r -t isofs "${cdrom}" /tmpfs/bootcd >/dev/null 2>&1; then
|
if mount -r -t iso9660 "${cdrom}" /tmpfs/bootcd >/dev/null 2>&1; then
|
||||||
if [ -e "${squashimg}" ]; then
|
if [ -e "${squashimg}" ]; then
|
||||||
squashfound=1
|
squashfound=1
|
||||||
msg "${cdrom}"
|
msg "${cdrom}"
|
||||||
@ -34,26 +33,24 @@ run_hook ()
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "${copytoram}" == "y" ]; then
|
if [ "${copytoram}" = "y" ]; then
|
||||||
/bin/cat /tmpfs/bootcd/archlive.sqfs > /tmpfs/archlive.sqfs
|
/bin/cat /tmpfs/bootcd/archlive.sqfs > /tmpfs/archlive.sqfs
|
||||||
squashimg="/tmpfs/archlive.sqfs"
|
squashimg="/tmpfs/archlive.sqfs"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
msg -n ":: Mounting squashfs image..."
|
msg ":: Mounting squashfs image"
|
||||||
/bin/modprobe -q squashfs >/dev/null 2>&1
|
/bin/modprobe -q squashfs >/dev/null 2>&1
|
||||||
/bin/mkdir -p /tmpfs/squashfs_root
|
/bin/mkdir -p /tmpfs/squashfs_root
|
||||||
if ! /bin/losetup /dev/loop0 "${squashimg}"; then
|
if ! /bin/losetup /dev/loop0 "${squashimg}" >/dev/null 2>&1; then
|
||||||
echo "ERROR: Cannot mount loop device /dev/loop0...aborting"
|
echo "ERROR: Cannot mount loop device /dev/loop0...aborting"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
/bin/mount -r -t squashfs /dev/loop0 /tmpfs/squashfs_root
|
/bin/mount -r -t squashfs /dev/loop0 /tmpfs/squashfs_root
|
||||||
msg "done."
|
|
||||||
|
|
||||||
msg -n ":: Mounting root (union) filesystem..."
|
msg ":: Mounting root (union) filesystem"
|
||||||
/bin/modprobe -q unionfs >/dev/null 2>&1
|
/bin/modprobe -q unionfs >/dev/null 2>&1
|
||||||
/bin/mount -t unionfs -o dirs=/tmpfs=rw:/tmpfs/squashfs_root=ro,debug=0 none /real_root
|
/bin/mount -t unionfs -o dirs=/tmpfs=rw:/tmpfs/squashfs_root=ro none /real_root
|
||||||
msg "done."
|
|
||||||
|
|
||||||
if [ -d /proc/sys/dev/cdrom ]; then
|
if [ -d /proc/sys/dev/cdrom ]; then
|
||||||
echo 0 > /proc/sys/dev/cdrom/lock
|
echo 0 > /proc/sys/dev/cdrom/lock
|
||||||
|
@ -14,12 +14,3 @@ pause Press enter to continue...
|
|||||||
title HOW-TO: Do some other shit
|
title HOW-TO: Do some other shit
|
||||||
cat /boot/help/othershit.txt
|
cat /boot/help/othershit.txt
|
||||||
pause Press enter to continue...
|
pause Press enter to continue...
|
||||||
|
|
||||||
title MANUAL: Grub
|
|
||||||
cat /boot/help/grub.txt
|
|
||||||
pause Press enter to continue...
|
|
||||||
|
|
||||||
title MANUAL: Lilo
|
|
||||||
cat /boot/help/lilo.txt
|
|
||||||
pause Press enter to continue...
|
|
||||||
|
|
||||||
|
@ -8,18 +8,18 @@ title Boot ArchLive
|
|||||||
kernel /boot/vmlinuz26 lang=en locale=en_US.UTF-8 ramdisk_size=75%
|
kernel /boot/vmlinuz26 lang=en locale=en_US.UTF-8 ramdisk_size=75%
|
||||||
initrd /boot/archlive.img
|
initrd /boot/archlive.img
|
||||||
|
|
||||||
|
title Tools...
|
||||||
|
configfile /boot/grub/tools.lst
|
||||||
|
|
||||||
|
title View Help...
|
||||||
|
configfile /boot/grub/help.lst
|
||||||
|
|
||||||
|
title More Options...
|
||||||
|
configfile /boot/grub/more.lst
|
||||||
|
|
||||||
title Shutdown the Computer
|
title Shutdown the Computer
|
||||||
halt
|
halt
|
||||||
|
|
||||||
title Reboot the Computer
|
title Reboot the Computer
|
||||||
reboot
|
reboot
|
||||||
|
|
||||||
title Tools...
|
|
||||||
configgile /boot/grub/tools.lst
|
|
||||||
|
|
||||||
title View Help...
|
|
||||||
configfile /boot/grub/help.lst
|
|
||||||
|
|
||||||
|
|
||||||
title More Options...
|
|
||||||
configfile /boot/grub/more.lst
|
|
||||||
|
@ -9,27 +9,19 @@ configfile /boot/grub/menu.lst
|
|||||||
title Run memtest86+ (Memory Testing)
|
title Run memtest86+ (Memory Testing)
|
||||||
kernel /boot/memtest86+/memtest.bin
|
kernel /boot/memtest86+/memtest.bin
|
||||||
|
|
||||||
# TODO package
|
|
||||||
# http://www.vortex.prodigynet.co.uk/x86test/
|
# http://www.vortex.prodigynet.co.uk/x86test/
|
||||||
title Run x86test (CPU Info)
|
title Run x86test (CPU Info)
|
||||||
kernel /boot/x86test.img
|
kernel /boot/x86test_zImage.bin
|
||||||
|
#wget http://www.vortex.prodigynet.co.uk/x86test/x86test_zImage.bin
|
||||||
|
|
||||||
# TODO package
|
|
||||||
# http://home.san.rr.com/johninsd/pub/linux/lilo/boot/
|
# http://home.san.rr.com/johninsd/pub/linux/lilo/boot/
|
||||||
title LILO Diagnostic 1 (diag1)
|
title LILO Diagnostic
|
||||||
kernel /boot/lilo_diagnostic1.img
|
kernel /boot/diag2.img
|
||||||
|
|
||||||
title LILO Diagnostic 2 (diag1)
|
|
||||||
kernel /boot/lilo_diagnostic2.img
|
|
||||||
|
|
||||||
title Install GRUB to hd0 MBR
|
title Install GRUB to hd0 MBR
|
||||||
root (hd0,0)
|
root (hd0,0)
|
||||||
setup (hd0)
|
setup (hd0)
|
||||||
|
|
||||||
title Install GRUB to hd1 MBR
|
|
||||||
root (hd1,0)
|
|
||||||
setup (hd1)
|
|
||||||
|
|
||||||
# http://www.erikyyy.de/invaders/
|
# http://www.erikyyy.de/invaders/
|
||||||
title Space Invaders!!
|
title Space Invaders!!
|
||||||
kernel /boot/invaders.img
|
kernel /boot/invaders.img
|
||||||
|
File diff suppressed because it is too large
Load Diff
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -1,11 +1,13 @@
|
|||||||
# vim: set ft=sh:
|
# vim: set ft=sh:
|
||||||
|
|
||||||
cmdline_param ()
|
cmdline_param ()
|
||||||
{
|
{
|
||||||
while param do;
|
read cmdline < /proc/cmdline
|
||||||
|
for param in ${cmdline}; do
|
||||||
case "${param}" in
|
case "${param}" in
|
||||||
$1=*) echo "${param##*=}"; break ;;
|
$1=*) echo "${param##*=}"; break ;;
|
||||||
*) continue ;;
|
*) continue ;;
|
||||||
esac
|
esac
|
||||||
echo "${2}"
|
done
|
||||||
done < read /proc/cmdline
|
[ -n "${2}" ] && echo "${2}"
|
||||||
}
|
}
|
||||||
|
@ -1,17 +0,0 @@
|
|||||||
# runlevel 4 is typically "text mode", but is not specified in LSB
|
|
||||||
id:4:initdefault:
|
|
||||||
|
|
||||||
rc::sysinit:/etc/rc.sysinit-proxy
|
|
||||||
rs:S1:wait:/etc/rc.single
|
|
||||||
rm:2345:wait:/etc/rc.multi
|
|
||||||
rh:06:wait:/etc/rc.shutdown
|
|
||||||
su:S:wait:/sbin/sulogin -p
|
|
||||||
|
|
||||||
c1:2345:respawn:/sbin/agetty 38400 vc/1 linux
|
|
||||||
c2:2345:respawn:/sbin/agetty 38400 vc/2 linux
|
|
||||||
c3:2345:respawn:/sbin/agetty 38400 vc/3 linux
|
|
||||||
c4:2345:respawn:/sbin/agetty 38400 vc/4 linux
|
|
||||||
c5:2345:respawn:/sbin/agetty 38400 vc/5 linux
|
|
||||||
c6:2345:respawn:/sbin/agetty 38400 vc/6 linux
|
|
||||||
|
|
||||||
ca::ctrlaltdel:/sbin/shutdown -t3 -r now
|
|
@ -1,3 +1,4 @@
|
|||||||
|
[H[2J
|
||||||
Arch Linux Live ISO 0.1 (Snicklefritz) \n [\s \m \r] (\n)
|
Arch Linux Live ISO 0.1 (Snicklefritz) \n [\s \m \r] (\n)
|
||||||
Started at \b \t
|
\s-\r \v \m started at \d \t
|
||||||
Default login is "arch" with no password.
|
Default login is "arch" with no password.
|
||||||
|
@ -4,4 +4,4 @@ daemon:x:2:2:daemon:/sbin:
|
|||||||
mail:x:8:12:mail:/var/spool/mail:
|
mail:x:8:12:mail:/var/spool/mail:
|
||||||
ftp:x:14:11:ftp:/home/ftp:
|
ftp:x:14:11:ftp:/home/ftp:
|
||||||
nobody:x:99:99:nobody:/:
|
nobody:x:99:99:nobody:/:
|
||||||
arch::1000:100::/home/arch:/bin/bash
|
arch::1000:100:users:/home/arch:/bin/bash
|
||||||
|
@ -1,12 +1,18 @@
|
|||||||
#
|
#
|
||||||
# /etc/rc.conf - Main Configuration for Arch Linux
|
# /etc/rc.conf - Main Configuration for Arch Linux
|
||||||
|
|
||||||
LOCALE="##LOCALE##"
|
. /etc/archiso/functions
|
||||||
|
|
||||||
|
LOCALE_DEFAULT="en_US.UTF-8"
|
||||||
|
TIMEZONE_DEFAULT="America/Chicago"
|
||||||
|
KEYMAP_DEFAULT="us"
|
||||||
|
|
||||||
|
LOCALE="$(cmdline_param locale ${LOCALE_DEFAULT})"
|
||||||
HARDWARECLOCK="UTC"
|
HARDWARECLOCK="UTC"
|
||||||
TIMEZONE="##TIMEZONE##"
|
TIMEZONE="$(cmdline_param timezone ${TIMEZONE_DEFAULT})"
|
||||||
KEYMAP="##KEYMAP##"
|
KEYMAP="$(cmdline_param keymap ${KEYMAP_DEFAULT})"
|
||||||
CONSOLEFONT=""
|
CONSOLEFONT="$(cmdline_param consolefont)"
|
||||||
CONSOLEMAP=""
|
CONSOLEMAP="$(cmdline_param consolefont)"
|
||||||
USECOLOR="yes"
|
USECOLOR="yes"
|
||||||
|
|
||||||
MOD_AUTOLOAD="yes"
|
MOD_AUTOLOAD="yes"
|
||||||
|
@ -1,16 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
# we need a proxy script here to convert some /proc/cmdline
|
|
||||||
# parameters to rc.conf settings.
|
|
||||||
|
|
||||||
. /etc/archlive/functions
|
|
||||||
|
|
||||||
LOCALE_DEFAULT="en_US.UTF-8"
|
|
||||||
TIMEZONE_DEFAULT="America/Chicago"
|
|
||||||
KEYMAP_DEFAULT="us"
|
|
||||||
|
|
||||||
sed -i "s|##LOCALE##|$(cmdline_param locale ${LOCALE_DEFAULT})|" /etc/rc.conf
|
|
||||||
sed -i "s|##TIMEZONE##|$(cmdline_param timezone ${TIMEZONE_DEFAULT})|" /etc/rc.conf
|
|
||||||
sed -i "s|##KEYMAP##|$(cmdline_param keymap ${KEYMAP_DEFAULT})|" /etc/rc.conf
|
|
||||||
|
|
||||||
#now go to the real sysinit
|
|
||||||
exec /etc/rc.sysinit
|
|
49
mkarchiso
49
mkarchiso
@ -32,17 +32,18 @@ usage ()
|
|||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
|
||||||
while getopts 'c:i:n:s:pvh' arg; do
|
while getopts 'c:i:fvh' arg; do
|
||||||
case "${arg}" in
|
case "${arg}" in
|
||||||
c) CONFIG="${OPTARG}" ;;
|
c) CONFIG="${OPTARG}" ;;
|
||||||
i) CPIOCONFIG="${OPTARG}" ;;
|
i) CPIOCONFIG="${OPTARG}" ;;
|
||||||
v) FORCE="f" ;;
|
f) FORCE="y" ;;
|
||||||
v) QUIET="n" ;;
|
v) QUIET="n" ;;
|
||||||
h|?) usage ;;
|
h|?) usage ;;
|
||||||
*) echo "invalid argument '${arg}'"; usage ;;
|
*) echo "invalid argument '${arg}'"; usage ;;
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
shift $(($OPTIND - 1))
|
shift $(($OPTIND - 1))
|
||||||
|
echo "ARGS: $@"
|
||||||
|
|
||||||
[ $# -le 1 ] && usage
|
[ $# -le 1 ] && usage
|
||||||
|
|
||||||
@ -57,23 +58,6 @@ esac
|
|||||||
|
|
||||||
[ "x${work_dir}" = "x" ] && (echo "please specify a working directory" && usage)
|
[ "x${work_dir}" = "x" ] && (echo "please specify a working directory" && usage)
|
||||||
|
|
||||||
if [ -e "${work_dir}" -a "${FORCE}" = "n" ]; then
|
|
||||||
echo "Working dir '${work_dir}' already exists, aborting..."
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "${command_name}" = "iso" -o "${command_name}" = "all" ]; then
|
|
||||||
[ "x${isoname}" = "x" ] && (echo "please specify an iso name" && usage)
|
|
||||||
if [ -e "${isoname}" -a "${FORCE}" = "n"]; then
|
|
||||||
echo "ISO Image '${isoname}' already exists, aborting..."
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
if [ -e "${CPIOCONFIG}" ]; then
|
|
||||||
echo "mkinitcpio config '${CPIOCONFIG}' does not exist, aborting..."
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
#TODO - do we even need a config file?
|
#TODO - do we even need a config file?
|
||||||
if [ -e "${CONFIG}" ]; then
|
if [ -e "${CONFIG}" ]; then
|
||||||
source "${CONFIG}"
|
source "${CONFIG}"
|
||||||
@ -134,6 +118,11 @@ install_pkgfile ()
|
|||||||
}
|
}
|
||||||
|
|
||||||
if [ "${command_name}" = "install" -o "${command_name}" = "all" ]; then
|
if [ "${command_name}" = "install" -o "${command_name}" = "all" ]; then
|
||||||
|
if [ -e "${work_dir}" -a "${FORCE}" = "n" ]; then
|
||||||
|
echo "Working dir '${work_dir}' already exists, aborting..."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
mkdir -p "${isoroot}"
|
mkdir -p "${isoroot}"
|
||||||
mkdir -p "${instroot}"
|
mkdir -p "${instroot}"
|
||||||
|
|
||||||
@ -176,7 +165,7 @@ if [ "${command_name}" = "install" -o "${command_name}" = "all" ]; then
|
|||||||
find "${instroot}/boot" -name *.img -delete #TODO, will this delete our special stuff?
|
find "${instroot}/boot" -name *.img -delete #TODO, will this delete our special stuff?
|
||||||
|
|
||||||
echo "Applying default configuration for the Arch ISO."
|
echo "Applying default configuration for the Arch ISO."
|
||||||
cp -rf ${DEF_CONFIG_DIR}/* "${instroot}"
|
cp -rfa ${DEF_CONFIG_DIR}/* "${instroot}"
|
||||||
|
|
||||||
echo "Copyright (C) 2006, Arch Linux (Judd Vinet)" > "${instroot}/etc/copyright"
|
echo "Copyright (C) 2006, Arch Linux (Judd Vinet)" > "${instroot}/etc/copyright"
|
||||||
|
|
||||||
@ -228,6 +217,20 @@ if [ "${command_name}" = "squash" -o "${command_name}" = "all" ]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "${command_name}" = "iso" -o "${command_name}" = "all" ]; then
|
if [ "${command_name}" = "iso" -o "${command_name}" = "all" ]; then
|
||||||
|
[ "x${isoname}" = "x" ] && (echo "please specify an iso name" && usage)
|
||||||
|
if [ -e "${isoname}" ]; then
|
||||||
|
if [ "${FORCE}" = "y" ]; then
|
||||||
|
rm -rf "${isoname}"
|
||||||
|
else
|
||||||
|
echo "ISO Image '${isoname}' already exists, aborting..."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
if [ ! -e "${CPIOCONFIG}" ]; then
|
||||||
|
echo "mkinitcpio config '${CPIOCONFIG}' does not exist, aborting..."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
kernelver=$(_kversion)
|
kernelver=$(_kversion)
|
||||||
basedir=${instroot}
|
basedir=${instroot}
|
||||||
[ "${instroot:0:1}" != "/" ] && basedir="$(pwd)/${instroot}"
|
[ "${instroot:0:1}" != "/" ] && basedir="$(pwd)/${instroot}"
|
||||||
@ -238,13 +241,11 @@ if [ "${command_name}" = "iso" -o "${command_name}" = "all" ]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
cp ${instroot}/usr/lib/grub/i386-pc/* "${isoroot}/boot/grub"
|
cp ${instroot}/usr/lib/grub/i386-pc/* "${isoroot}/boot/grub"
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "${SKIP_ISO}" = "n" ]; then
|
|
||||||
echo "Creating ISO image..."
|
echo "Creating ISO image..."
|
||||||
q=""
|
q=""
|
||||||
[ "${QUIET}" = "y" ] && q="-q"
|
#[ "${QUIET}" = "y" ] && q="-q"
|
||||||
mkisofs "${q}" -r -l -b "boot/grub/stage2_eltorito" -uid 0 -gid 0 -no-emul-boot \
|
mkisofs ${q} -r -l -b "boot/grub/stage2_eltorito" -uid 0 -gid 0 -no-emul-boot \
|
||||||
-boot-load-size 4 -boot-info-table -publisher "Arch Linux <archlinux.org>" \
|
-boot-load-size 4 -boot-info-table -publisher "Arch Linux <archlinux.org>" \
|
||||||
-input-charset=UTF-8 -p "prepared by $NAME" -A "Arch Linux Live/Rescue CD" \
|
-input-charset=UTF-8 -p "prepared by $NAME" -A "Arch Linux Live/Rescue CD" \
|
||||||
-copyright /etc/copyright -o "${isoname}" "${isoroot}"
|
-copyright /etc/copyright -o "${isoname}" "${isoroot}"
|
||||||
|
Loading…
Reference in New Issue
Block a user