summaryrefslogtreecommitdiff
path: root/classes/module.bbclass
diff options
context:
space:
mode:
Diffstat (limited to 'classes/module.bbclass')
-rw-r--r--classes/module.bbclass12
1 files changed, 12 insertions, 0 deletions
diff --git a/classes/module.bbclass b/classes/module.bbclass
index 4da3f5f30b..8a13f1f858 100644
--- a/classes/module.bbclass
+++ b/classes/module.bbclass
@@ -34,6 +34,18 @@ module_do_install() {
oe_runmake DEPMOD=echo INSTALL_MOD_PATH="${D}" CC="${KERNEL_CC}" LD="${KERNEL_LD}" modules_install
}
+pkg_postinst_append () {
+ if [ -n "$D" ]; then
+ exit 1
+ fi
+ depmod -A
+ update-modules || true
+}
+
+pkg_postrm_append () {
+ update-modules || true
+}
+
EXPORT_FUNCTIONS do_compile do_install
FILES_${PN} = "/etc /lib/modules"