This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

am335x最新的UBOOT,5.2版本,在Make的时候,如何设置优化选项?



我在顶层的Makefile文件中将

HOSTCFLAGS = -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer \
$(if $(CONFIG_TOOLS_DEBUG),-g)
HOSTCXXFLAGS = -O2

中的O2换成O0,然后make,出现以下错误:

tools/image-host.o:在函数‘fit_image_setup_sig’中:
image-host.c:(.text+0x58c):对‘image_get_checksum_algo’未定义的引用
image-host.c:(.text+0x5a5):对‘image_get_crypto_algo’未定义的引用
tools/image-host.o:在函数‘fit_config_get_data’中:
image-host.c:(.text+0x114d):对‘fit_region_make_list’未定义的引用
collect2: error: ld returned 1 exit status
scripts/Makefile.host:108: recipe for target 'tools/dumpimage' failed
make[1]: *** [tools/dumpimage] Error 1
Makefile:1285: recipe for target 'tools' failed
make: *** [tools] Error 2

这是什么原因呢,如何设置优化选项?