Closed Vasu-p closed 6 years ago
I'm not able to reproduce this error. Searching online for it suggests a number of possible causes. At first glance, perhaps a permission issue is the most problem? Did you install it with sudo?
Just to clarify, you shouldn't need to use sudo to install riscv-tools. Homebrew for the last few years hasn't needed sudo.
Since there has been no response in 3 weeks, I'm closing this issue. If your problem persists, please comment again to re-open it.
I'm getting that error while compiling a kernel and still couldn't find a solution :(
Can you run the following commands to let me know about how it was installed?
which riscv64-unknown-elf-gcc
ls -l `which riscv64-unknown-elf-gcc`
I'm not able to reproduce this, but re-reading the original issue, I see the original poster has a non-standard Homebrew link directory. In theory it should still work, but gcc can be extremely temperamental about paths.
I'm assuming the install used the bottles. Could you also try re-building gcc (will take some time) with brew reinstall --build-from-source riscv-gcc
?
@madScript01 @Vasu-p Either of you get a chance to double check on this?
Fixed this, using linaro GCC toolchain and after typing apt-get install aarch64-linux-gnu
@madScript01 Glad to hear your issues were resolved. Did you experience the issue originally with homebrew on macOS, or were you always using linux (linaro)?
The installation completed without any errors. But when I am trying to compile a Hello World program it gives this message:
riscv64-unknown-elf-gcc: error trying to exec 'cc1': execvp: No such file or directory
But when I try to do the same from the /usr/local/opt/riscv-gcc/bin directory it works fine.