Patchwork [4/6] module.bbclass: do not use update-modules anymore

login
register
mail settings
Submitter Laurentiu Palcu
Date Jan. 17, 2013, 2:58 p.m.
Message ID <635d56cf346eb517d83b8f02c860d8539d8de57d.1358432402.git.laurentiu.palcu@intel.com>
Download mbox | patch
Permalink /patch/42817/
State Accepted
Commit 173a61826305838ba56a9da50491e657b4843f56
Headers show

Comments

Laurentiu Palcu - Jan. 17, 2013, 2:58 p.m.
update-modules is obsolete. The bbclass was updated not to use it
anymore.

[YOCTO #3598]

Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com>
---
 meta/classes/module.bbclass |   13 +++++++++----
 1 file changed, 9 insertions(+), 4 deletions(-)

Patch

diff --git a/meta/classes/module.bbclass b/meta/classes/module.bbclass
index ebb0880..d477caa 100644
--- a/meta/classes/module.bbclass
+++ b/meta/classes/module.bbclass
@@ -1,4 +1,4 @@ 
-RDEPENDS_${PN} += "kernel-image ${@oe.utils.contains('DISTRO_FEATURES', 'update-modules', 'update-modules', '', d)}"
+RDEPENDS_${PN} += "kernel-image"
 DEPENDS += "virtual/kernel"
 
 inherit module-base
@@ -27,13 +27,18 @@  module_do_install() {
 
 pkg_postinst_append () {
 if [ -z "$D" ]; then
-	depmod -a
-	update-modules || true
+	depmod -a ${KERNEL_VERSION}
+else
+	depmod -a -b $D -F ${STAGING_KERNEL_DIR}/System.map-${KERNEL_VERSION} ${KERNEL_VERSION}
 fi
 }
 
 pkg_postrm_append () {
-update-modules || true
+if [ -z "$D" ]; then
+	depmod -a ${KERNEL_VERSION}
+else
+	depmod -a -b $D -F ${STAGING_KERNEL_DIR}/System.map-${KERNEL_VERSION} ${KERNEL_VERSION}
+fi
 }
 
 EXPORT_FUNCTIONS do_compile do_install