[arch-projects] [mkinitcpio][PATCH] functions: bugfix: honor $BASEDIR in auto_modules

Dave Reisner d at falconindy.com
Sun Jun 12 20:18:01 EDT 2011

Signed-off-by: Dave Reisner <d at falconindy.com>
Another small bug I let slip by.

I'm a bit wary of the whole $BASEDIR thing to begin with, as we pull binaries
from the host and not the guest... This is bound to be problematic in certain
setups, especially if/when udev is included and differs in version from the
real root. We either need to fix this so that _everything_ is taken from
the $BASEDIR, or just scrap this and tell people to chroot.

 functions |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/functions b/functions
index 75ea0a0..0381aec 100644
--- a/functions
+++ b/functions
@@ -43,7 +43,7 @@ auto_modules ()
     IFS=$'\n' read -rd '' -a mods < \
         <(find /sys/devices -name modalias -exec sort -zu {} + |
-        xargs -0 modprobe -aRS "$KERNELVERSION" |
+        xargs -0 modprobe -d "$BASEDIR" -aRS "$KERNELVERSION" |
         sort -u)
     printf "%s\n" "${mods[@]//-/_}"

More information about the arch-projects mailing list