d1-nezha-baremeta icon indicating copy to clipboard operation
d1-nezha-baremeta copied to clipboard

Error when building src/3.uart

Open leanrdchen00918 opened this issue 2 years ago • 1 comments

I've successfully built src/1.startup and run the Image on D1-nezha board. However, there is a problem when building 3.uart.

~/d1-nezha-baremeta/src/3.uart$ make all TOOLPREFIX=riscv64-unknown-elf-
riscv64-unknown-elf-gcc -Wall -O2 -fno-omit-frame-pointer -ggdb -march=rv64gcvxtheadc -mabi=lp64d -mtune=c906 -MD -mcmodel=medany -ffreestanding -fno-common -nostdlib -mno-relax -I. -I printf -fno-stack-protector -fno-pie -no-pie   -c -o printf.o printf.c
cc1: error: unknown cpu 'c906' for '-mtune'
make: *** [<builtin>: printf.o] Error 1

leanrdchen00918 avatar May 13 '22 15:05 leanrdchen00918

I've successfully built src/1.startup and run the Image on D1-nezha board. However, there is a problem when building 3.uart.

~/d1-nezha-baremeta/src/3.uart$ make all TOOLPREFIX=riscv64-unknown-elf-
riscv64-unknown-elf-gcc -Wall -O2 -fno-omit-frame-pointer -ggdb -march=rv64gcvxtheadc -mabi=lp64d -mtune=c906 -MD -mcmodel=medany -ffreestanding -fno-common -nostdlib -mno-relax -I. -I printf -fno-stack-protector -fno-pie -no-pie   -c -o printf.o printf.c
cc1: error: unknown cpu 'c906' for '-mtune'
make: *** [<builtin>: printf.o] Error 1

you can download Xuantie-900-gcc-elf-newlib from https://occ.t-head.cn/community/download

bigmagic123 avatar May 17 '22 09:05 bigmagic123