130 ifeq ($(obj)include/config.mk,$(wildcard $(obj)include/config.mk)) //判断include目录下是否有config.mk文件,该文件是在make x210_sd_config时配置得来的
131
132 # load ARCH, BOARD, and CPU configuration
133 include $(obj)include/config.mk //将config.mk配置文件包含在主Makefile中
134 export ARCH CPU BOARD VENDOR SOC //并将此文件中的5个变量导出到环境变量,供子makefile使用
include/config.mk文件内容为如下
ARCH = arm
CPU = s5pc11x
BOARD = x210
VENDOR = samsung
SOC = s5pc110
配置时执行的make x210_sd_config是在主Makefile的第2589行
这里的x210_sd_config是Makefile的目标
2589 x210_sd_config : unconfig
2590 @$(MKCONFIG) $(@:_config=) arm s5pc11x x210 samsung s5pc110
2591 @echo "TEXT_BASE = 0xc3e00000" > $(obj)board/samsung/x210/config.mk