编译镜像时报了这个错,是什么原因呢?
riscv64-unknown-linux-gnu-gcc -ggdb3 -gdwarf-2 -DLZ4_USER_MEMORY_FUNCTIONS=1 -DNO_ALLOCS -DARGTYPE=3 -DLTC_NO_FILE -DLTM_NO_FILE -DLTM_DESC -DLTC_SOURCE -DDDR2 -D_mem_freq_1333 -DREAL_DDRPHY -DREAL_LOCK -DX16_MODE -DRISCV=/home/EveRYouNg/riscv-gnu-toolchain -DTEST_FROM_SPINOR1=0 -DPAGE_SIZE_64KB=1 -DPRINTF_TIMESTAMP=0 -DENABLE_ASSERTIONS=1 -DLOG_LEVEL=2 -D__CVITEK__ -DNANDBOOT_V2=1 -DTOC_HEADER_NAME=0xC906B001 -DRTOS_ENABLE_FREERTOS=y -DRTOS_DUMP_PRINT_SZ_IDX=17 -DRTOS_FAST_IMAGE_TYPE=0 -DRTOS_DUMP_PRINT_ENABLE=1 -DFSBL_SECURE_BOOT_SUPPORT=0 -D USB_DL_BY_FSBL -Iinclude -Iinclude/cpu/riscv -Iplat/ -Iplat/cv180x/include/uart -Iplat/cv180x/include/usb -Iplat/cv180x/include -Iplat/cv180x/include/riscv -Ilib/utils -Ilib/lzma -Ilib/lz4 -Ilib/crc -Iinclude/stdlib -Iinclude/stdlib/sys -Ilib/libtommath -Ilib/libtomcrypt/src/headers -Ilib/BigDigits -Iplat/cv180x/include/ddr -Iplat/cv180x/include/ddr/ddr_config/ddr2_1333_x16 -Ibuild -Iinclude/cpu -nostdinc -Wmissing-include-dirs -Werror -DRISCV -march=rv64imafdcvxthead -mcmodel=medany -mabi=lp64d -ffreestanding -fno-builtin -Wall -std=gnu99 -Os -ffunction-sections -fdata-sections -fno-delete-null-pointer-checks -DIMAGE_BL2 -Wp,-MD,/home/EveRYouNg/milkV_duo/duo-buildroot-sdk/fsbl/build/cv1800b_milkv_duo_sd/bl2/assert.d -MT /home/EveRYouNg/milkV_duo/duo-buildroot-sdk/fsbl/build/cv1800b_milkv_duo_sd/bl2/assert.o -MP -c lib/stdlib/assert.c -o /home/EveRYouNg/milkV_duo/duo-buildroot-sdk/fsbl/build/cv1800b_milkv_duo_sd/bl2/assert.o
<command-line>: error: "RISCV" redefined [-Werror]
<command-line>: note: this is the location of the previous definition
<command-line>: error: "RISCV" redefined [-Werror]
<command-line>: note: this is the location of the previous definition
<command-line>: error: "RISCV" redefined [-Werror]
<command-line>: note: this is the location of the previous definition
CC lib/stdlib/mem.c
riscv64-unknown-linux-gnu-gcc -ggdb3 -gdwarf-2 -DLZ4_USER_MEMORY_FUNCTIONS=1 -DNO_ALLOCS -DARGTYPE=3 -DLTC_NO_FILE -DLTM_NO_FILE -DLTM_DESC -DLTC_SOURCE -DDDR2 -D_mem_freq_1333 -DREAL_DDRPHY -DREAL_LOCK -DX16_MODE -DRISCV=/home/EveRYouNg/riscv-gnu-toolchain -DTEST_FROM_SPINOR1=0 -DPAGE_SIZE_64KB=1 -DPRINTF_TIMESTAMP=0 -DENABLE_ASSERTIONS=1 -DLOG_LEVEL=2 -D__CVITEK__ -DNANDBOOT_V2=1 -DTOC_HEADER_NAME=0xC906B001 -DRTOS_ENABLE_FREERTOS=y -DRTOS_DUMP_PRINT_SZ_IDX=17 -DRTOS_FAST_IMAGE_TYPE=0 -DRTOS_DUMP_PRINT_ENABLE=1 -DFSBL_SECURE_BOOT_SUPPORT=0 -D USB_DL_BY_FSBL -Iinclude -Iinclude/cpu/riscv -Iplat/ -Iplat/cv180x/include/uart -Iplat/cv180x/include/usb -Iplat/cv180x/include -Iplat/cv180x/include/riscv -Ilib/utils -Ilib/lzma -Ilib/lz4 -Ilib/crc -Iinclude/stdlib -Iinclude/stdlib/sys -Ilib/libtommath -Ilib/libtomcrypt/src/headers -Ilib/BigDigits -Iplat/cv180x/include/ddr -Iplat/cv180x/include/ddr/ddr_config/ddr2_1333_x16 -Ibuild -Iinclude/cpu -nostdinc -Wmissing-include-dirs -Werror -DRISCV -march=rv64imafdcvxthead -mcmodel=medany -mabi=lp64d -ffreestanding -fno-builtin -Wall -std=gnu99 -Os -ffunction-sections -fdata-sections -fno-delete-null-pointer-checks -DIMAGE_BL2 -Wp,-MD,/home/EveRYouNg/milkV_duo/duo-buildroot-sdk/fsbl/build/cv1800b_milkv_duo_sd/bl2/mem.d -MT /home/EveRYouNg/milkV_duo/duo-buildroot-sdk/fsbl/build/cv1800b_milkv_duo_sd/bl2/mem.o -MP -c lib/stdlib/mem.c -o /home/EveRYouNg/milkV_duo/duo-buildroot-sdk/fsbl/build/cv1800b_milkv_duo_sd/bl2/mem.o
<command-line>: error: "RISCV" redefined [-Werror]
<command-line>: note: this is the location of the previous definition
<command-line>: error: "RISCV" redefined [-Werror]
<command-line>: note: this is the location of the previous definition
<command-line>: error: "RISCV" redefined [-Werror]
<command-line>: note: this is the location of the previous definition
cc1: all warnings being treated as errors
make[1]: *** [Makefile:195: /home/EveRYouNg/milkV_duo/duo-buildroot-sdk/fsbl/build/cv1800b_milkv_duo_sd/bl2/misc_helpers.o] Error 1
make[1]: *** Waiting for unfinished jobs....
<command-line>: error: "RISCV" redefined [-Werror]
<command-line>: note: this is the location of the previous definition
<command-line>: error: "RISCV" redefined [-Werror]
<command-line>: note: this is the location of the previous definition
<command-line>: error: "RISCV" redefined [-Werror]
<command-line>: note: this is the location of the previous definition
<command-line>: error: "RISCV" redefined [-Werror]
<command-line>: note: this is the location of the previous definition
cc1: all warnings being treated as errors
<command-line>: error: "RISCV" redefined [-Werror]
<command-line>: note: this is the location of the previous definition
make[1]: *** [Makefile:195: /home/EveRYouNg/milkV_duo/duo-buildroot-sdk/fsbl/build/cv1800b_milkv_duo_sd/bl2/cpu_helper.o] Error 1
cc1: all warnings being treated as errors
cc1: all warnings being treated as errors
make[1]: *** [Makefile:195: /home/EveRYouNg/milkV_duo/duo-buildroot-sdk/fsbl/build/cv1800b_milkv_duo_sd/bl2/cache.o] Error 1
cc1: all warnings being treated as errors
make[1]: *** [Makefile:195: /home/EveRYouNg/milkV_duo/duo-buildroot-sdk/fsbl/build/cv1800b_milkv_duo_sd/bl2/delay_timer.o] Error 1
make[1]: *** [Makefile:195: /home/EveRYouNg/milkV_duo/duo-buildroot-sdk/fsbl/build/cv1800b_milkv_duo_sd/bl2/bl2_helper.o] Error 1
cc1: all warnings being treated as errors
make[1]: *** [Makefile:195: /home/EveRYouNg/milkV_duo/duo-buildroot-sdk/fsbl/build/cv1800b_milkv_duo_sd/bl2/assert.o] Error 1
<command-line>: error: "RISCV" redefined [-Werror]
<command-line>: note: this is the location of the previous definition
cc1: all warnings being treated as errors
cc1: all warnings being treated as errors
make[1]: *** [Makefile:195: /home/EveRYouNg/milkV_duo/duo-buildroot-sdk/fsbl/build/cv1800b_milkv_duo_sd/bl2/uart_dw.o] Error 1
make[1]: *** [Makefile:195: /home/EveRYouNg/milkV_duo/duo-buildroot-sdk/fsbl/build/cv1800b_milkv_duo_sd/bl2/misc.o] Error 1
cc1: all warnings being treated as errors
make[1]: *** [Makefile:195: /home/EveRYouNg/milkV_duo/duo-buildroot-sdk/fsbl/build/cv1800b_milkv_duo_sd/bl2/tf_printf.o] Error 1
cc1: all warnings being treated as errors
cc1: all warnings being treated as errors
make[1]: *** [Makefile:195: /home/EveRYouNg/milkV_duo/duo-buildroot-sdk/fsbl/build/cv1800b_milkv_duo_sd/bl2/mem.o] Error 1
make[1]: *** [Makefile:195: /home/EveRYouNg/milkV_duo/duo-buildroot-sdk/fsbl/build/cv1800b_milkv_duo_sd/bl2/security.o] Error 1
cc1: all warnings being treated as errors
make[1]: *** [Makefile:195: /home/EveRYouNg/milkV_duo/duo-buildroot-sdk/fsbl/build/cv1800b_milkv_duo_sd/bl2/platform.o] Error 1
make[1]: Leaving directory '/home/EveRYouNg/milkV_duo/duo-buildroot-sdk/fsbl'
make: *** [scripts/fip_v2.mk:32: fsbl-build] Error 2
Error: Build board milkv-duo-sd failed!
EveRYouNg@Matrix-F-58-54-4C:~/milkV_duo/duo-buildroot-sdk$
放个图清楚些: