• u-boot 用哪个lds链接脚本


    顶层Makefile文件中 :

    ifndef LDSCRIPT
        #LDSCRIPT := $(srctree)/board/$(BOARDDIR)/u-boot.lds.debug
        ifdef CONFIG_SYS_LDSCRIPT
            # need to strip off double quotes
            LDSCRIPT := $(srctree)/$(CONFIG_SYS_LDSCRIPT:"%"=%)
        endif
    endif

    # If there is no specified link script, we look in a number of places for it
    ifndef LDSCRIPT
        ifeq ($(wildcard $(LDSCRIPT)),)
            LDSCRIPT := $(srctree)/board/$(BOARDDIR)/u-boot.lds
        endif
        ifeq ($(wildcard $(LDSCRIPT)),)
            LDSCRIPT := $(srctree)/$(CPUDIR)/u-boot.lds
        endif
        ifeq ($(wildcard $(LDSCRIPT)),)
            LDSCRIPT := $(srctree)/arch/$(ARCH)/cpu/u-boot.lds
        endif
    endif

    之前一直在后面几条里面找,board目录下没有,以为是arch/arm/cpu/u-boot.lds

    结果发现是/arch/arm/mach-fmxx/u-boot.lds

    grep果然是好东西,

    grep -nwr u-boot.lds

    发现了

    include/configs/fmxx-common.h:120:#define CONFIG_SYS_LDSCRIPT   "arch/arm/mach-fmxx/u-boot.lds"
    在头文件里定义了这个。

    u-boot链接最终所使用的链接脚本u-boot.lds位于根目录下,通过编译(准确说是预处理)才能生成。

  • 相关阅读:
    朴素贝叶斯
    用极大似然解释最小二乘法
    1(2).生成模型和判别模型
    1(1).有监督 VS 无监督
    python 进程与线程
    ASP.NET MVC 项目直接预览PDF文件
    有关层的垂直居中
    js的正则表达式编程,悬赏解决下面的问题
    jQuery-contextMenu使用教程
    【自己开发】Jquery的loading插件
  • 原文地址:https://www.cnblogs.com/idyllcheung/p/11606460.html
Copyright © 2020-2023  润新知