diff options
-rw-r--r-- | init | 2 | ||||
-rw-r--r-- | mkinitramfs | 9 |
2 files changed, 7 insertions, 4 deletions
@@ -48,7 +48,7 @@ run_scripts /scripts/init-top # Load the modules # FIXME - do module options here for x in $(cat /conf/modules); do - insmod /modules/$x + modprobe $x done # Populate /dev tree diff --git a/mkinitramfs b/mkinitramfs index 94cf4c5..bfb0007 100644 --- a/mkinitramfs +++ b/mkinitramfs @@ -12,11 +12,13 @@ manual_add_modules() for x in $(sed -e '/^#/d' ${1}); do for y in $(modprobe --set-version=${version} --show-depends ${x} | awk '{ print $2 }'); do # Prune duplicates - if [ -e ${TMPDIR}/modules/$(basename ${y}) ]; then + if [ -e ${TMPDIR}/${y} ]; then continue fi - ln -s ${y} ${TMPDIR}/modules + mkdir -p ${TMPDIR}/$(dirname ${y}) + ln -s ${y} ${TMPDIR}/$(dirname ${y}) + depmod -b ${TMPDIR} ${version} echo $(basename ${y}) >>${TMPDIR}/conf/modules done done @@ -113,9 +115,10 @@ rm ${TMPDIR}/lib/*lsb* # Busybox rm ${TMPDIR}/bin/sh ln -s /usr/lib/initramfs-tools/bin/busybox ${TMPDIR}/bin/sh +# This is ugly, but needed atm to make the builtins work =( +ln -s /usr/lib/initramfs-tools/bin/busybox ${TMPDIR}/bin/busybox # Modutils -ln -s /sbin/insmod ${TMPDIR}/bin ln -s /sbin/modprobe ${TMPDIR}/bin # Raid |