i've got empty modules.dep file after compiling new kernel from source

after kernel compile, and then kernel module compile and then make modules_install to modules directory, i checked modules.dep file inside destination modules directory is empty, and then i ran this command

depmod -a -b <kernel-modules-dest-dir> -e -F <kernel-source-directory>/System.map -n -v 4.7.0

and the result was :

# Aliases extracted from modules themselves.
# Soft dependencies extracted from modules themselves.
# Aliases for symbols, used by symbol_request().
# Device nodes to trigger on-demand module loading.

i'am compiling kernel 4.7.0 using host with version 4.4.x (ubuntu 16.04), there are a lot of .ko files inside <kernel-modules-dest-dir> but somehow depmod don't see any compiled loadable kernel modules

these are roughly the command script i ran :

cp ../../kernel-config ./.config-x86_64 make mrproper make menuconfig make -j8 make bzImage cp arch/x86/boot/bzImage ../../vmlinuz mkdir -p ../../kernel-modules make modules make modules_install INSTALL_MOD_PATH=../../kernel-modules

is they anything wrong in my compilation step ?

1 Answer 1


The same happened to me (modules_install compressed each module), and after I disabled in menuconfig: Enable loadable module support -> Compress modules on installation, depmod successfully built modules.dep Other possibility is to inform depmod if modules are compressed, by using a flag.

Kind regards

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.