简体   繁体   中英

Is it meaningful to execute “make modules_install” without executing “make modules”?

From KernelBuild tutorial from http://kernelnewbies.org , I don't see " make modules " command. This article only executes " make " command before " sudo make modules_install install ".

But from make help output:

  all             - Build all targets marked with [*]
* vmlinux         - Build the bare kernel
* modules         - Build all modules
  modules_install - Install all modules to INSTALL_MOD_PATH (default: /)

It seems that without " make modules " command, there is no need to execute " make modules_install " command. Is it meaningful to execute " make modules_install " without executing " make modules "?

Is it meaningful to execute “make modules_install” without executing “make modules”?

Yes, but only if you have already executed make before the make modules_install . You can't execute modules_install if modules weren't built with the make modules or just make . There is only one difference between make and make modules : the make modules compiles only modules or source code which is set as

obj-CONFIG_OPTION_NAME=m

in the Makefile. If you want just to build Linux kernel, just use make , the make modules already included there.

No, if you understand the procedure correctly.

make modules
This will just compile all modules just like any other program. Creating object files.

make modules_install
Once your files are compiled without any error then this command will put generated .so files to the appropriate directories.

So if you run modules_install without make modules then there will be nothing to copy.

I hope this helps.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM