- if [ -z "$INSTALLED" ] ; then
- einfo "Searching for device(s) labeled with GRMLCFG. (Disable this via boot option: noautoconfig)" ; eend 0
- eindent
- [ -d /mnt/grml ] || mkdir /mnt/grml
- umount /mnt/grml 1>>$DEBUG 2>&1 # make sure it is not mounted
-# We do need the following fix so floppy disk is available to blkid in any case :-/
- if [ -r /dev/fd0 ] ; then
- einfo "Floppy device detected. Trying to access floppy disk."
-# dd if=/dev/fd0 of=/dev/null bs=512 count=1 1>>$DEBUG 2>&1
- if timeout 4 dd if=/dev/fd0 of=/dev/null bs=512 count=1 1>>$DEBUG 2>&1 ; then
- blkid /dev/fd0 1>>$DEBUG 2>&1
- fi
- fi
- DEVICE=$(blkid -t LABEL=GRMLCFG | head -1 | awk -F: '{print $1}')
- [ -n "$DEVICE" ] && mount -t auto -o ro $DEVICE /mnt/grml ; RC="$?"
- if [[ $RC == 0 ]]; then
- einfo "Mounting device $DEVICE labeled GRMLCFG succeeded." ; eend 0
-
- CONFIG=''
- CONFIG="$(/bin/ls -1d /mnt/grml/[Cc][Oo][Nn][Ff][Ii][Gg].[Tt][Bb][Zz] 2>>$DEBUG)"
- if [ -n "$CONFIG" ]; then
- einfo "Found file ${WHITE}${CONFIG}${NORMAL} - trying to extract it."
- cd /
- unp $CONFIG $EXTRACTOPTIONS ; eend $?
- else
- ewarn "Sorry, could not find file config.tbz on device with label GRMLCFG." ; eend 1
+ if [ -z "$INSTALLED" ] ; then
+ if checkbootparam 'myconfig' ; then
+ DCSDEVICE="$(getbootparam 'myconfig' 2>>$DEBUG)"
+ if [ -z "$DCSDEVICE" ]; then
+ eerror "Error: No device for bootoption myconfig provided." ; eend 1
+ fi # [ -z "$DCSDEVICE" ]
+ elif checkvalue $CONFIG_MYCONFIG; then # checkbootparam myconfig
+ einfo "Searching for device(s) labeled with GRMLCFG. (Disable this via boot option: noautoconfig)" ; eend 0
+ eindent
+ # We do need the following fix so floppy disk is available to blkid in any case :-/
+ if [ -r /dev/fd0 ] ; then
+ einfo "Floppy device detected. Trying to access floppy disk."
+ if timeout 4 dd if=/dev/fd0 of=/dev/null bs=512 count=1 1>>$DEBUG 2>&1 ; then
+ blkid /dev/fd0 1>>$DEBUG 2>&1
+ fi
+ fi
+ DCSDEVICE=$(blkid -t LABEL=GRMLCFG | head -1 | awk -F: '{print $1}')
+ if [ -n "$DCSDEVICE" ]; then
+ DCSMP="/mnt/grmlcfg"
+ fi
+ eoutdent