summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2007-02-05 00:10:55 +0000
committerMike Frysinger <vapier@gentoo.org>2007-02-05 00:10:55 +0000
commit942c69c97e68290c89113f9b6775b0b688c5602f (patch)
tree8c8068ba9f6ebf3a1b3d0453b1c7a720988a685e /sys-apps/module-init-tools/files
parentRegenerate digest in Manifest2 format. (diff)
downloadgentoo-2-942c69c97e68290c89113f9b6775b0b688c5602f.tar.gz
gentoo-2-942c69c97e68290c89113f9b6775b0b688c5602f.tar.bz2
gentoo-2-942c69c97e68290c89113f9b6775b0b688c5602f.zip
tweak genkernel find a little
(Portage version: 2.1.2-r6)
Diffstat (limited to 'sys-apps/module-init-tools/files')
-rwxr-xr-xsys-apps/module-init-tools/files/modules-update9
1 files changed, 6 insertions, 3 deletions
diff --git a/sys-apps/module-init-tools/files/modules-update b/sys-apps/module-init-tools/files/modules-update
index bd6b8ebccc6b..161a7f5bd1d7 100755
--- a/sys-apps/module-init-tools/files/modules-update
+++ b/sys-apps/module-init-tools/files/modules-update
@@ -397,13 +397,16 @@ depfile=$(grab_depfile)
if [[ -d ${depfile%/*} ]] ; then
if [[ ${CFG_NEW_FILE} -nt ${depfile} ]] ; then
+ arch=$(uname -m)
ebegin "Updating modules.dep"
- for cfg in /lib/modules/${KV}/build /usr/src/linux-${KV} \
+ for cfg in /boot /lib/modules/${KV}/build /usr/src/linux-${KV} \
/boot /usr/src/linux ""
do
cfg="${cfg}/System.map"
- for suffix in -genkernel-${KV} -${KV} "" ; do
- [[ -f ${cfg}${suffix} ]] && cfg="${cfg}${suffix}" && break 2
+ for suffix in -genkernel-{${arch},'*'}-${KV} -${KV} "" ; do
+ scfg=$(echo ${cfg}${suffix})
+ scfg=${scfg%% *}
+ [[ -f ${scfg} ]] && cfg=${scfg} && break 2
done
done
[[ -n ${cfg} ]] && cfg="-F ${cfg}"