riscv-collab / riscv-gnu-toolchain

GNU toolchain for RISC-V, including GCC
Other
3.52k stars 1.16k forks source link

configure: WARNING: unrecognized options: --with-xlen #251

Closed salasjad closed 6 years ago

salasjad commented 7 years ago

I am trying to install the RV32I toolchain with the riscv32-unknown-elf- prefix. However, adding --with-xlen=32 or --enable-multilib doesn't seem to work.

./configure --with-xlen=32 --with-guile=no --prefix=/opt/riscv make

Building on Arch Linux, gcc version 7.1.1

aswaterman commented 7 years ago

I think you want --with-arch=rv32i rather than --with-xlen=32

salasjad commented 7 years ago

Thanks @aswaterman,--with-arch=rv32i creates the riscv32-unknown-elf- files. I get errors when I try to compile the code: riscv64-unknown-elf-gcc: error: unrecognized command line option '-m32' riscv64-unknown-elf-gcc: error: unrecognized command line option '-msoft-float'

From Makefile: CFLAGS=-m32 -msoft-float

It this related to the toolchain build process? My guess was to add --disable-float, but then I get configure: WARNING: unrecognized options: --disable-float.

TommyMurphyTM1234 commented 7 years ago

-m32 and -msoft-float were deprecated a while back in favour of -march and -mabi as far as I recall.

jim-wilson commented 6 years ago

The answer was provided by tm1234.