On 9/25/24 2:56 AM, Troy Mitchell via Gcc wrote:
Hi everyone, I'm new to the world of gcc.
I don't know if this is the right place to post, but I'm having some issues that are really annoying.

I've created a Unix-like system, and although it's not very complete yet, I want to make a cross-compilation chain for it so that I can use some open source c libraries.

I modify these files:

config.sub, fixincludes/mkfixinc.sh, config.gcc, gcc/config/caffeinix.h, libgcc/config.host

But after I compiled gcc, I ran into problems when I ran it.
I tried to compile a test file (it has nothing but the main function), but I got the following error:
❯ ./riscv64-caffeinix-gcc -o test test.c

Assembler messages:
Fatal error: invalid -march= option: `rv64imafdc_zicsr'

Information I can provide:
Host: Ubuntu 22.04
Newlib (compiled by myself): 2.5.0

And the compiled gcc information:

❯ ./riscv64-caffeinix-gcc -march=rv64gc -Q --help=target

[ ... ]

Assembler messages:
Fatal error: invalid -march= option: `rv64gc'
❯ ./riscv64-caffeinix-gcc -v
More important would be to see the -v output when you ran the compiler and got the error message from the compiler. Most likely it's not finding a risc-v assembler.

jeff

Reply via email to