Changeset 1727


Ignore:
Timestamp:
Oct 28, 2007, 7:45:35 PM (12 years ago)
Author:
bruno
Message:
  • exclusion of modules denied now works
  • Also create modules in their ordinary place, so that classical modprobe works + copy modules.dep
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.2.5/mindi/mindi

    r1726 r1727  
    28462846        list_of_groovy_mods="$list_of_groovy_mods $EXTRA_MODS"
    28472847    fi
     2848    for i in $DENY_MODS; do
     2849        echo "Removing $i from the list of modules to load" >> $LOGFILE
     2850        list_of_groovy_mods=`echo ${list_of_groovy_mods} | tr ' ' '\n' | grep -Ev "^${i}$" | tr '\n' ' '`
     2851    done
     2852
    28482853    [ -e "$floppy_modules_path" ] || LogIt "path $floppy_modules_path does not exist.\n If you're not using a modular kernel then you're NUTS."
    28492854    for i in $list_of_groovy_mods ; do
    28502855        floppy_modules="$floppy_modules `FindSpecificModuleInPath $floppy_modules_path $i`"
    2851     done
    2852     for i in $DENY_MODS; do
    2853         floppy_modules=`echo ${floppy_modules} | tr ' ' '\n' | grep -Ev "^${i}$" | tr '\n' ' '`
    28542856    done
    28552857    for i in $floppy_modules ; do
     
    28572859        [ "$YOUR_KERNEL_SUCKS" ] && i=$MINDI_TMP/$i
    28582860        echo "Adding $i ($s KB) to the rootfs" >> $LOGFILE
    2859         cp -df $i $mountpoint/ 2>/dev/null || LogIt "Unable to copy $i to $mountpoint"
     2861        cp --parents -pdf $i $mountpoint 2>/dev/null || LogIt "Unable to copy $i to $mountpoint"
     2862        if [ "`echo "$i" | grep -F ".gz"`" ]; then
     2863                gunzip -f $mountpoint/$i
     2864                i=`echo $i | sed 's/.gz//'`
     2865        fi
     2866        ln -s $mountpoint/$i $mountpoint 2>/dev/null || LogIt "Unable to link `basename $i` to $mountpoint"
    28602867        [ "`echo "$i" | grep -F ".gz"`" ] && gunzip -f $mountpoint/`basename $i`
    28612868    done
     2869    # Also copy modules.dep in case of udev so that normal modprobe works
     2870    p=`echo $i | cut -d/ -f1-3`
     2871    cp -df $p/modules.dep $mountpoint/$p 2>/dev/null || LogIt "Unable to copy modules.dep to $mountpoint"
    28622872    if [ ! -e "/sbin/devfsd" ] || [ "$disksize" -lt "2880" ] || [ "$kernelpath" = "$MINDI_LIB/vmlinuz" ] ; then
    28632873        echo "Deleting devfsd daemon from ramdisk" >> $LOGFILE
     
    31283138# If libata v2 is used then remove ide-generic as it will perturbate boot
    31293139if [ "`echo $MODULES | grep libata`" ]; then
    3130     if [ $laver -ge 2 ]; then
     3140    if [ "$laver" = "2" ]; then
    31313141        DENY_MODS="$DENY_MODS ide-generic"
    3132         echo "ide-generic removed from module list as your system uses libata v2+"
     3142        echo "ide-generic removed from module list as your system uses libata v2+" >> $LOGFILE
    31333143        echo "-------------" >> $LOGFILE
    31343144    fi
Note: See TracChangeset for help on using the changeset viewer.