Ripes: Compiler detection doesn't seem to work on Windows with version 2.1.0 binaries
Compiler detection, either autodetection with a should-be-valid compiler in %PATH%, or a specified path to a compiler (via using the Browse button in the Editor Settings dialog), doesn’t seem to work on Windows with the 2.1.0 binary release.
I can confirm I’m using the compiler binaries from https://static.dev.sifive.com/dev-tools/riscv64-unknown-elf-gcc-8.3.0-2020.04.1-x86_64-w64-mingw32.zip via https://github.com/sifive/freedom-tools/releases. Looking at the test program embedded in ccmanager.cpp (“int main() { return 0; }
”), I can successfully compile this with the following command line (“risc-foo.c” contains only the string above as the entire program):
riscv64-unknown-elf-gcc -march=rv32im -mabi=ilp32 -O0 -x c risc-foo.c -o risc-foo -static-libgcc -lm
I can also load the resulting (ELF) binary into Ripes (via Ctrl+O or “Load Program” under the File menu) and run it in the simulator.
Similarly, I tried a more complex sample, as shown at https://github.com/mortbopet/Ripes/wiki/Building-and-Executing-C-programs-with-Ripes:
#include <stdio.h>
int main() {
char buffer[128];
printf("Type something to be echoed:\n");
fflush(stdout);
fgets(buffer, sizeof(buffer), stdin);
printf("\nYou typed: %s", buffer);
return 0;
}
This also compiles fine with the following command line, and likewise the binary loads fine in Ripes (“risc-foo2.c” is only the program source shown above):
riscv64-unknown-elf-gcc -march=rv32im -mabi=ilp32 -O0 -x c risc-foo2.c -o risc-foo2 -static-libgcc -lm
I’m uncertain what exactly is failing (or seems to be failing) on Windows with the 2.1.0 release binary WRT compiler detection.
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 15 (8 by maintainers)
Commits related to this issue
- Handle space characters in compiler paths #59 Also forwards compiler verification error messages to the UI. — committed to mortbopet/Ripes by mortbopet 4 years ago
please tell me, how to fix this issue. I meet this issue, too