解决u-boot 2016.11 ”ERROR: Makefile:1385: recipe for target 'checkarmreloc' failed”

来源:互联网 发布:淘宝的软件靠谱么 编辑:程序博客网 时间:2024/06/02 06:10

在编译u-boot-2016.05时出现如下问题:

这里写图片描述

解决办法:
搜索 “u-boot contains unexpected relocations”,没有搜索到任何内容,那么我们再尝试搜索checkarmreloc:

lvxiaoliang@lvxiaoliang-virtual-machine:~/Ftp/tmp/u-boot-2016.05$ grep "checkarmreloc" * -nRarch/arm/config.mk:111:ALL-y += checkarmrelocMakefile:1384:checkarmreloc: u-boot

在顶层Makefile中有如下语句:

########################################################################## ARM relocations should all be R_ARM_RELATIVE (32-bit) or# R_AARCH64_RELATIVE (64-bit).checkarmreloc: u-boot        @RELOC="`$(CROSS_COMPILE)readelf -r -W $< | cut -d ' ' -f 4 | \                grep R_A | sort -u`"; \        if test "$$RELOC" != "R_ARM_RELATIVE" -a \                 "$$RELOC" != "R_AARCH64_RELATIVE"; then \                echo "$< contains unexpected relocations: $$RELOC"; \                false; \        fienv: scripts_basic        $(Q)$(MAKE) $(build)=tools/$@tools-only: scripts_basic $(version_h) $(timestamp_h)        $(Q)$(MAKE) $(build)=toolstools-all: export HOST_TOOLS_ALL=ytools-all: env tools ;cross_tools: export CROSS_BUILD_TOOLS=ycross_tools: tools ;.PHONY : CHANGELOGCHANGELOG:        git log --no-merges U-Boot-1_1_5.. | \        unexpand -a | sed -e 's/\s\s*$$//' > $@#########################################################################                                             

那么我们就别编译checkarmreloc了,所以我们注释掉arch/arm/config.mk的第111行:

#ALL-y += checkarmreloc
然后就能编译通过了
阅读全文
0 0
原创粉丝点击