summaryrefslogtreecommitdiffstats
path: root/functions
diff options
context:
space:
mode:
authorDave Reisner <dreisner@archlinux.org>2012-07-28 05:52:02 +0200
committerDave Reisner <dreisner@archlinux.org>2012-07-28 17:53:45 +0200
commit6a585950c5a014c35e449861b6b2040dca2d2516 (patch)
treecdf5aa65a7d55e54299baa6bca187ccf1dd43ad9 /functions
parentb8459a2ac067b05925d660fdf2b62855eae544da (diff)
downloadmkinitcpio-6a585950c5a014c35e449861b6b2040dca2d2516.tar.gz
mkinitcpio-6a585950c5a014c35e449861b6b2040dca2d2516.tar.xz
implement --moduleroot option
This might be useful for creating an initramfs image as part of a kernel package. Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Diffstat (limited to 'functions')
-rw-r--r--functions4
1 files changed, 2 insertions, 2 deletions
diff --git a/functions b/functions
index 9c577f0..b42daf7 100644
--- a/functions
+++ b/functions
@@ -212,7 +212,7 @@ auto_modules() {
IFS=$'\n' read -rd '' -a mods < \
<(find /sys/devices -name modalias -exec sort -u {} + |
# delimit each input by a newline, expanded in place
- xargs -d $'\n' modprobe -qaRS "$KERNELVERSION" |
+ xargs -d $'\n' modprobe -d "$MODULEROOT" -qaRS "$KERNELVERSION" |
sort -u)
printf "%s\n" "${mods[@]//-/_}"
@@ -332,7 +332,7 @@ add_module() {
fi
;;
esac
- done < <(modinfo -k "$KERNELVERSION" -0 "$module" 2>/dev/null)
+ done < <(modinfo -b "$MODULEROOT" -k "$KERNELVERSION" -0 "$module" 2>/dev/null)
if [[ -z $path ]]; then
(( ign_errors )) && return 0