X-Git-Url: https://git.grml.org/?p=grml-autoconfig.git;a=blobdiff_plain;f=autoconfig.functions;h=1f764760617b5092e3ee5b00df8733641fead11f;hp=48d98dad34ade3739bd4dedb5ccb108e333b17c8;hb=29f3db9a59bc180f790416e3d282cbce8dd56503;hpb=947f7c8e323bb1371d2347c7dd277fe3b9ee9f0b diff --git a/autoconfig.functions b/autoconfig.functions index 48d98da..1f76476 100755 --- a/autoconfig.functions +++ b/autoconfig.functions @@ -4,7 +4,7 @@ # Authors: grml-team (grml.org), (c) Klaus Knopper , (c) Michael Prokop # Bug-Reports: see http://grml.org/bugs/ # License: This file is licensed under the GPL v2. -# Latest change: Sam Mai 17 22:15:54 CEST 2008 [mika] +# Latest change: Fre Aug 15 23:06:21 CEST 2008 [mika] ################################################################################ # {{{ path, variables, signals, umask, zsh @@ -128,6 +128,8 @@ config_debug(){ if [ -n "$BOOTDEBUG" ]; then einfo "Starting intermediate shell stage $stage as requested by \"debug\" option." if [ grep -q "debug=noscreen" "$CMDLINE" ] ; then + einfo "Notice that the shell does not provide job handling: ctrl-z, bg and fg won't work!" + einfo "Just exit the shell to continue boot process..." /bin/zsh else eindent @@ -1240,10 +1242,12 @@ if checkbootparam "nocpu"; then else # check module dependencies cpufreq_check() { - if [ -e /lib64 ] ; then - [ -e /lib/modules/${KERNEL}/kernel/arch/x86_64/kernel/cpufreq ] || return 1 - else - [ -e /lib/modules/${KERNEL}/kernel/arch/i386/kernel/cpu/cpufreq -o ! -e /lib/modules/${KERNEL}/kernel/drivers/cpufreq ] || return 1 + if ! [ -e /lib/modules/${KERNEL}/kernel/arch/x86/kernel/cpu/cpufreq ] ; then + if [ -e /lib64 ] ; then + [ -e /lib/modules/${KERNEL}/kernel/arch/x86_64/kernel/cpufreq ] || return 1 + else + [ -e /lib/modules/${KERNEL}/kernel/arch/i386/kernel/cpu/cpufreq -o ! -e /lib/modules/${KERNEL}/kernel/drivers/cpufreq ] || return 1 + fi fi } @@ -1637,10 +1641,14 @@ config_gpm(){ if checkbootparam "nogpm"; then ewarn "Not starting GPM as requested on boot commandline." ; eend 0 else - einfo "Starting gpm in background." -# /etc/init.d/gpm start 1>>$DEBUG & - ( while [ ! -e /dev/psaux ]; do sleep 5; done; /etc/init.d/gpm start 1>>$DEBUG ) & - eend 0 + if ! [ -r /dev/input/mice ] ; then + eerror "No mouse found - not starting GPM." ; eend 1 + else + einfo "Starting gpm in background." + /etc/init.d/gpm start 1>>$DEBUG & + # ( while [ ! -e /dev/psaux ]; do sleep 5; done; /etc/init.d/gpm start 1>>$DEBUG ) & + eend 0 + fi fi } # }}} @@ -1929,11 +1937,11 @@ if checkbootparam "mypath" ; then for i in $(echo $MY_PATH | sed 's/:/\n/g') ; do if ! [ -d "$i" ] ; then einfo "Creating directory $i" - mkdir -d "$i" ; eend $? + mkdir -p "$i" ; eend $? fi done + grep -q "${MY_PATH}" /etc/grml/my_path || echo "${MY_PATH}" >> /etc/grml/my_path ; eend $? eoutdent - echo "$MY_PATH" >> /etc/grml/my_path ; eend $? fi } # }}}