From a4c4412f8e5632066d32eb0924d36dce3ad6e4f5 Mon Sep 17 00:00:00 2001 From: Jonathan Bauer Date: Thu, 1 Aug 2019 16:03:03 +0200 Subject: [*] run depmod in post_process_target --- core/bin/setup_target | 3 +++ core/includes/kernel.inc | 5 +++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/core/bin/setup_target b/core/bin/setup_target index b2087e2b..a895a38a 100755 --- a/core/bin/setup_target +++ b/core/bin/setup_target @@ -487,6 +487,9 @@ post_process_target() { pinfo "Running ldconfig" cp -r -L /etc/ld.so.conf* "${TARGET_BUILD_DIR}/etc/" ldconfig -v -r "${TARGET_BUILD_DIR}" + + # run depmod to generate the final modules.* files + depmod -b "${TARGET_BUILD_DIR}" -a "${TARGET_KERNEL_LONG}" } clean_modules() { diff --git a/core/includes/kernel.inc b/core/includes/kernel.inc index 8208dcd4..9d7ff839 100644 --- a/core/includes/kernel.inc +++ b/core/includes/kernel.inc @@ -129,8 +129,9 @@ copy_kernel_modules () { >> "${TARGET_BUILD_DIR}/${KERNEL_MODULES_DIR}/modules.order" # copy list of builtin kernel modules cp "${KERNEL_MODULES_DIR}/modules.builtin" "${TARGET_BUILD_DIR}/${KERNEL_MODULES_DIR}" - # with modules.order and modules.builtin, we can run depmod for the rest of the files - depmod -b "${TARGET_BUILD_DIR}" -a "${TARGET_KERNEL_LONG}" + # generating modules.order here is needed since REQUIRED_KERNEL_MODULES will not + # be set outside of this module's scope, depmod will be executed in post_process_target + # to allow other modules (like dnbd3) to install additional kernel modules # # Firmware -- cgit v1.2.3-55-g7522