I have been attempting to clone the risc-v GNU toolchain on Linux but failing.
On:
git clone --recursive https://github.com/riscv/riscv-gnu-toolchain
I get (fragment):
Checking connectivity... done.
Submodule path 'riscv-glibc': checked out '7395b0964db9cc4dd544926414960e9a16842180'
Cloning into 'riscv-newlib'...
fatal: unable to connect to sourceware.org:
sourceware.org[0: 8.43.85.97]: errno=Connection refused
sourceware.org[1: 2620:52:3:1:0:246e:9693:128c]: errno=Network is unreachable
I thought this might be a transient network problem but it has persisted for days now.
Subsequently trying:
git submodule update --init --recursive
Similarly fails:
Cloning into 'riscv-newlib'...
fatal: unable to connect to sourceware.org:
sourceware.org[0: 8.43.85.97]: errno=Connection refused
sourceware.org[1: 2620:52:3:1:0:246e:9693:128c]: errno=Network is unreachable
fatal: clone of 'git://sourceware.org/git/newlib-cygwin.git' into submodule path 'riscv-newlib' failed
I have tried this:
git config --global url.https://github.com/.insteadOf git://github.com
But it makes no difference.
Anyone know of a way round this?
The repo's CI tools report that the most recent patch is failing. so reversing that fixed this problem for me.
Specifically:
git clone https://github.com/riscv/riscv-gnu-toolchain
(ie don't start recursion at this point)
cd riscv-gnu-toolchain
Edit .gitmodules to reverse this:
@@ -12,7 +12,7 @@
url = ../riscv-dejagnu.git
[submodule "riscv-newlib"]
path = riscv-newlib
- url = ../riscv-newlib.git
+ url = git://sourceware.org/git/newlib-cygwin.git
[submodule "riscv-gdb"]
path = riscv-gdb
url = ../riscv-binutils-gdb.git
Then:
git submodule update --init --recursive