从linux主目录中的makefile文件分析编译构成。。。
来源:互联网 发布:手指数算法5加6怎么算 编辑:程序博客网 时间:2024/05/19 15:44
在嵌入式linux系统的编译中,makefile文件是最重要也是最有效的分析文件。
配置好内核之后,都需要编译内核。执行命令:make zImage或者 make uImage.(这两个镜像文件有一点点区别)
在顶层makefile中:
export KBUILD_IMAGE ?= vmlinux
找到vmlinux,便可知道依赖文件。
# The all: target is the default when no target is given on the
# command line.
# This allow a user to issue only 'make' to build a kernel including modules
# Defaults to vmlinux, but the arch makefile usually adds further targets
all: vmlinux
① :export KBUILD_VMLINUX_INIT := $(head-y) $(init-y) (初始化函数)
head-y :=arch/arm/kernel/head$(MMUEXT).o //目标架构目录
init-y :=init/
② :export KBUILD_VMLINUX_MAIN := $(core-y) $(libs-y) $(drivers-y)$(net-y) (主函数)
drivers-y :=drivers/ sound/ firmware/
net-y :=net/
libs-y :=lib/
core-y :=usr/
// 链接脚本文件,由各个架构的目录下的脚本文件生成。包括:程序的起始地址等
③:export KBUILD_LDS :=arch/$(SRCARCH)/kernel/vmlinux.lds
- 从linux主目录中的makefile文件分析编译构成。。。
- linux用户中的主目录
- Linux中的makefile文件
- Linux驱动Makefile文件分析
- Linux顶层Makefile文件分析
- Linux中的Makefile.in文件
- DevKitPro(GBA),MakeFile文件大概分析(编译)
- linux kernel Makefile编译流程分析
- linux系统中的主目录结构及其作用
- Linux下C多文件编译Makefile
- linux makefile 编译c和c++文件
- linux下makefile多文件编译
- linux下多个cpp文件的Makefile编译
- linux多文件编译—makefile
- linux下多个cpp文件的Makefile编译
- Linux内核源代码中的Makefile分析
- Linux内核源代码中的Makefile分析
- Linux内核源代码的Makefile文件分析
- Android对SQLite批量添加数据
- VC CComboBox用法
- android使用startActivityForResult多级回传参数
- 20. Valid Parentheses
- Scala学习笔记三
- 从linux主目录中的makefile文件分析编译构成。。。
- ONE-CLASS SVM FOR LEARNING IN IMAGE RETRIEVAL
- sql 升序 ,降序
- 在ActionBar中进行Fragment之间的切换
- 实时操作系统与非实时操作系统到底有什么区别?
- iOS try catch
- Android版本和API Level对应关系
- ContentObserver 介绍
- JPush推送 之 RegistrationID 精确对点推送