summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorJohn Mylchreest <johnm@gentoo.org>2005-01-15 21:46:00 +0000
committerJohn Mylchreest <johnm@gentoo.org>2005-01-15 21:46:00 +0000
commit95a4d8f2de20e25f515e19b810e0dec7da764d89 (patch)
tree3a37a23ecd9f8f89c06f4d5db494eb81aa3161c2 /eclass
parentchanged app-cdr/cdrtools dependency to virtual/cdrtools. see bug #77817. (Man... (diff)
downloadgentoo-2-95a4d8f2de20e25f515e19b810e0dec7da764d89.tar.gz
gentoo-2-95a4d8f2de20e25f515e19b810e0dec7da764d89.tar.bz2
gentoo-2-95a4d8f2de20e25f515e19b810e0dec7da764d89.zip
Update to be less specific with @OPTION:module
Diffstat (limited to 'eclass')
-rw-r--r--eclass/linux-info.eclass4
-rw-r--r--eclass/linux-mod.eclass34
2 files changed, 25 insertions, 13 deletions
diff --git a/eclass/linux-info.eclass b/eclass/linux-info.eclass
index 75d92638b817..2b9c8eb3c5e2 100644
--- a/eclass/linux-info.eclass
+++ b/eclass/linux-info.eclass
@@ -1,6 +1,6 @@
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/linux-info.eclass,v 1.17 2005/01/15 21:19:02 johnm Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/linux-info.eclass,v 1.18 2005/01/15 21:46:00 johnm Exp $
#
# Description: This eclass is used as a central eclass for accessing kernel
# related information for sources already installed.
@@ -429,7 +429,7 @@ check_extra_config() {
for i in ${MODULE_NAMES}
do
n="${i//${temp_config}}"
- [ -z "${n//(*}" ] && MODULE_IGNORE="${MODULE_IGNORE} ${i}"
+ [ -z "${n//(*}" ] && MODULE_IGNORE="${MODULE_IGNORE} ${temp_config}"
done
error=0
fi
diff --git a/eclass/linux-mod.eclass b/eclass/linux-mod.eclass
index 8b9ec24893e2..b8984fae0971 100644
--- a/eclass/linux-mod.eclass
+++ b/eclass/linux-mod.eclass
@@ -1,6 +1,6 @@
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/linux-mod.eclass,v 1.19 2005/01/15 21:19:02 johnm Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/linux-mod.eclass,v 1.20 2005/01/15 21:46:00 johnm Exp $
# Description: This eclass is used to interface with linux-info in such a way
# to provide the functionality required and initial functions
@@ -229,19 +229,22 @@ display_postinst() {
file=${ROOT}/etc/modules.autoload.d/kernel-${KV_MAJOR}.${KV_MINOR}
file=${file/\/\///}
+ for i in ${MODULE_IGNORE}
+ do
+ MODULE_NAMES=${MODULE_NAMES//${i}(*}
+ done
+
einfo "If you would like to load this module automatically upon boot"
einfo "please type the following as root:"
for i in ${MODULE_NAMES}
do
- moduletemp="$(echo ${i} | sed -e "s:\(.*\)(\(.*\)):\1 \2:")"
- modulename="${moduletemp/ */}"
- moduletemp="${moduletemp/* /}"
- # if we specify two args, then we can set moduledir
- [ -z "${moduletemp/*:*/}" ] && moduledir="${moduletemp/:*/}"
- # if we didnt pass the brackets, then we shouldnt accept anything
- [ -n "${moduletemp/${modulename}/}" ] && sourcedir="${moduletemp/*:/}"
- moduledir="${moduledir:-misc}"
- sourcedir="${sourcedir:-${S}}"
+ for n in $(find_module_params ${i})
+ do
+ eval ${n/:*}=${n/*:/}
+ done
+ libdir=${libdir:-misc}
+ srcdir=${srcdir:-${S}}
+ objdir=${objdir:-${srcdir}}
einfo " # echo \"${modulename}\" >> ${file}"
done
@@ -302,7 +305,11 @@ linux-mod_src_compile() {
local modulename libdir srcdir objdir i n
BUILD_TARGETS=${BUILD_TARGETS:-clean module}
- MODULE_NAMES=${MODULE_NAMES//${MODULE_IGNORE}}
+
+ for i in ${MODULE_IGNORE}
+ do
+ MODULE_NAMES=${MODULE_NAMES//${i}(*}
+ done
for i in ${MODULE_NAMES}
do
@@ -329,6 +336,11 @@ linux-mod_src_compile() {
linux-mod_src_install() {
local modulename libdir srcdir objdir i n
+
+ for i in ${MODULE_IGNORE}
+ do
+ MODULE_NAMES=${MODULE_NAMES//${i}(*}
+ done
for i in ${MODULE_NAMES}
do