for https://github.com/cnlohr/ch32v003fun we need to have riscv64-unknown-elf-gcc
, alas it is not on fedora so...
this looks ok binutils-riscv64-linux-gnu
but
following https://github.com/riscv-collab/riscv-gnu-toolchain we need to compile our own on fedora 6 Gb of submodules, took about 40min to dl on iffy network
sudo dnf install autoconf automake python3 libmpc-devel mpfr-devel gmp-devel gawk libusb1-devel bison flex texinfo patchutils gcc gcc-c++ zlib-devel expat-devel
#submodules take a long time, i prefer to see progress.
#but the submodules will be pulled by make later, if not specified here.
git clone --recursive --progress https://github.com/riscv-collab/riscv-gnu-toolchain && cd riscv-gnu-toolchain
sudo mkdir /opt/riscv
./configure --prefix=/opt/riscv
sudo make
as discussed in the project readme, add /opt/riscv/bin
to your path
alternativly (?) https://xpack.github.io/dev-tools/riscv-none-elf-gcc/install/
sudo dnf install npm -y
sudo npm install --global xpm@latest
cd my-project
xpm init # Only at first use.
xpm install @xpack-dev-tools/riscv-none-elf-gcc@latest --verbose