内核Kbuild-Makefile-Kconfig之间的关系
来源:互联网 发布:mac照片如何复制粘贴 编辑:程序博客网 时间:2024/05/16 09:44
参见/Documentation/kbuild:
The Makefiles have five parts:
Makefile the top Makefile.
.config the kernel configuration file.
arch/$(ARCH)/Makefile the arch Makefile.
scripts/Makefile.* common rules etc. for all kbuild Makefiles.
kbuild Makefiles there are about 500 of these.
The top Makefile reads the .config file, which comes from the kernel
configuration process.
The top Makefile is responsible for building two major products: vmlinux
(the resident kernel image) and modules (any module files).
It builds these goals by recursively descending into the subdirectories of
the kernel source tree.
The list of subdirectories which are visited depends upon the kernel
configuration. The top Makefile textually includes an arch Makefile
with the name arch/$(ARCH)/Makefile. The arch Makefile supplies
architecture-specific information to the top Makefile.
Each subdirectory has a kbuild Makefile which carries out the commands
passed down from above. The kbuild Makefile uses information from the
.config file to construct various file lists used by kbuild to build
any built-in or modular targets.
scripts/Makefile.* contains all the definitions/rules etc. that
are used to build the kernel based on the kbuild makefiles.
Makefile
Makefile总共包含五个部分,分别为:①顶层Makefile文件,②内核配置文件,③在各个体系结构下的makefile,在目录arch/$(ARCH)中,④一系列用于kbuild Makefile的通用规则,这些文件主要在scripts目录中,⑤kbuild Makefiles,这类文件大约有500个左右。
顶层Makefile读取.config文件,该文件主要在内核的配置过程中生成。有关内核的具体配置可参见这里。顶层的Makefile主要用来构造两个最主要的文件:vmlinux——固定内核映像,以及任意的模块,这种构造过程是通过递归进入内核源代码树的子目录而完成的。需要访问的子目录列表依据内核的配置而定。顶层Makefile包含一个具体体系结构下的Makefile文件,该文件主要向顶层Makefile提供指定体系结构的信息。
每一个子目录都包含kbuild Makefile,其用来执行由上级目录传递下来的一些命令。kbuild Makefile通过使用.config文件中包含的信息来构造各种各样的文件清单,最终kbuild根据这些文件清单构造任一内置的或模块化的目标。
而scripts目录中包含的一些Makefile.*文件中则包含了一系列的定义或是规则,这些规则根据kbuild makefile构造内核。
- 内核Kbuild-Makefile-Kconfig之间的关系
- Kconfig,.config,Makefile之间的关系(转载)
- Kconfig 、menuconfig、.config、Makefile之间的关系
- Kconfig、Kbuild Makefile
- Kconfig、Kbuild Makefile
- Kconfig menuconfig .config Makefile之间的关系及如何在内核中添加驱动
- kconfig .config makefile 之间关系
- Kconfig与Kbuild Makefile 的驱动方向简单解析
- Kconfig和makefile的关系
- linux 内核驱动动态加载和静态加载和 .config makefile kconfig 三个文件之间关系
- linux中kconfig-kbuild-makefile分析
- Linux内核编译中遇到的Kconfig,.confi和Makefile的关系
- .config 和 kconfig以及 makefile的关系
- .config、kconfig和Makefile的关系
- .config 和 kconfig以及 makefile的关系
- .config、kconfig和Makefile的关系
- .config 和 kconfig以及 makefile的关系
- 【总结】嵌入式linux内核中Makefile、Kconfig、.config的关系及增加开机Hello World
- 在访问 Internet Explorer 中的网页时,为什么收到"中止操作"错误消息?
- UML 基础:类图
- QT中线程及其同步的用法
- 你必须懂的 T4 模板:深入浅出
- 修改指定用户权限
- 内核Kbuild-Makefile-Kconfig之间的关系
- java classpath: what does it mean?
- 优秀的开发者博文
- 你必须懂的 T4 模板:体系架构
- oracle audit
- oracle 删除重复的记录
- maven学习笔记(四)仓库、nexus私服
- Android权限大全
- fork - 子进程在复制父进程的信号处理方式