From b31ed489b977662292aa39978ee737b94b60af14 Mon Sep 17 00:00:00 2001 From: Aaron Griffin Date: Tue, 6 Jun 2006 05:22:35 +0000 Subject: New error conditions: fail on missing hook or missing module Filesystem hook changes (parseblock handling) Init changes to allow /arch.cmd command line parsing Misc install script cleanups git-svn-id: http://projects.archlinux.org/svn/initramfs/mkinitcpio@123 880c04e9-e011-0410-abf7-b926e227c9cd --- install/autodetect | 13 +++++++------ install/keymap | 2 +- install/pcmcia | 11 ++++------- install/sata | 2 +- install/scsi | 2 +- 5 files changed, 14 insertions(+), 16 deletions(-) (limited to 'install') diff --git a/install/autodetect b/install/autodetect index e3543e7..ec7e624 100644 --- a/install/autodetect +++ b/install/autodetect @@ -4,15 +4,16 @@ install () { MODULE_FILE="$(mktemp /tmp/initcpio_modules.XXXXXX)" #blegh, we'll let /tmp clean itself up - AUTODETECT="$(auto_modules -e "/scsi/" -e "/block" -e "/fusion/" \ - -e "/usb/" -e "/ide/" -e "/ieee1394/" -e "/cdrom"\ - -e "/net/" -e "/pcmcia") + AUTODETECT="$(auto_modules -e '/scsi/' -e '/block' -e '/fusion/' \ + -e '/usb/' -e '/ide/' -e '/ieee1394/' -e '/cdrom' \ + -e '/net/' -e '/pcmcia') $(cat /proc/filesystems | grep -v nodev) " if [ -e /sbin/mdadm ]; then - if [ $UID -eq 0 -o "$(groups | grep disk)" != "" ]; then \ - AUTODETECT="$AUTODETECT $(mdadm -E -s /dev/hd* /dev/sd* /dev/rd/* /dev/ida/* \ - /dev/cciss/* /dev/ataraid/* | awk -Flevel= '{print $2}' | awk '{print $1}')" + if [ $UID -eq 0 -o "$(groups | grep disk)" != "" ]; then + AUTODETECT="$AUTODETECT + $(mdadm -E -s /dev/hd* /dev/sd* /dev/rd/* /dev/ida/* /dev/cciss/* /dev/ataraid/* \ + | awk -Flevel= '{print $2}' | awk '{print $1}')" else err "User does not have proper permissions to read superblocks, raid modules are not detected" fi diff --git a/install/keymap b/install/keymap index 800ab47..0518802 100644 --- a/install/keymap +++ b/install/keymap @@ -14,7 +14,7 @@ install () grep "KEYMAP=" /etc/rc.conf >> ${KEYMAP_FILE} grep "CONSOLEFONT=" /etc/rc.conf >> ${KEYMAP_FILE} grep "CONSOLEMAP=" /etc/rc.conf >> ${KEYMAP_FILE} - if [ "`echo $LOCALE | /bin/grep -i utf`" ]; then + if [ "$(echo $LOCALE | /bin/grep -i utf)" != "" ]; then echo UTF8="yes" >> ${KEYMAP_FILE} fi . ${KEYMAP_FILE} diff --git a/install/pcmcia b/install/pcmcia index 4e419c0..b5ca7fb 100644 --- a/install/pcmcia +++ b/install/pcmcia @@ -2,17 +2,14 @@ install () { - MODULES=" $(checked_modules "/pcmcia/" | grep -ve "sound" -e "net") $(checked_modules "/ide/legacy")" + MODULES=" $(checked_modules '/pcmcia/' | grep -ve 'sound' -e 'net') $(checked_modules '/ide/legacy')" MODULES=$(echo ${MODULES}) #trim whitespace if [ "x${MODULES}" != "x" ]; then - MODULES="${MODULES} sd_mod\nsr_mod\nide-disk\nide-cd" + MODULES="${MODULES} sd_mod sr_mod ide-disk ide-cd" fi - BINARIES="" - FILES="" + BINARIES="/sbin/pcmcia-socket-startup.static /sbin/pcmcia-check-broken-cis.static" + FILES="/etc/pcmcia/config.opts" SCRIPT="" - add_file "/sbin/pcmcia-socket-startup.static" "/sbin/pcmcia-socket-startup" - add_file "/sbin/pcmcia-check-broken-cis.static" "/sbin/pcmcia-check-broken-cis" - add_file "/etc/pcmcia/config.opts" } help () diff --git a/install/sata b/install/sata index 45484c7..dc20045 100644 --- a/install/sata +++ b/install/sata @@ -2,7 +2,7 @@ install () { - MODULES=" $(checked_modules "scsi/.*ata") $(checked_modules "block/sx8") \ + MODULES=" $(checked_modules "scsi/.*ata") $(checked_modules "block/sx8") $(checked_modules "scsi/ahci") $(checked_modules "scsi/pdc_adma")" MODULES=$(echo ${MODULES}) #trim whitespace diff --git a/install/scsi b/install/scsi index 8e8694b..396de33 100644 --- a/install/scsi +++ b/install/scsi @@ -8,7 +8,7 @@ install () MODULES=$(echo ${MODULES}) #trim whitespace if [ "x${MODULES}" != "x" ]; then - MODULES="${MODULES} sd_mod\nsr_mod" + MODULES="${MODULES} sd_mod sr_mod" fi BINARIES="" FILES="" -- cgit v1.2.3-24-g4f1b