Setting Up Eclipse IDE for Programming NEORV32 with OpenOCD – Encountering Linker Errors #667
Replies: 1 comment 2 replies
-
This looks like a GCC/toolchain issue. I assume you have a toolchain, where the C standard library expects a "full-scale" Linux-like OS. Btw, do you use any functions from
You could use an "embedded" toolchain that uses When using newlib you still need to provide those system primitves, but you can implement them as stubs (see
Yes, there is a pre-configured openOCD script:
I'm not really familiar with Eclipse - I prefer the console + editor approach 😉 But if you are using GCC/GDB then it should not be too difficult to integrate NEORV32. Just make sure you use the core's linker script and optimally also the pre-defined Makefile for compilation. |
Beta Was this translation helpful? Give feedback.
-
Hello NEORV32 Community,
I'm currently working on a project using the NEORV32 processor, and I'm looking to set up my development environment with Eclipse IDE, utilizing OpenOCD for debugging.
I have attempted to install the GCC RISC-V toolchain (gcc-riscv64-unknown-elf), but during the setup, I encountered several linker errors related to libc.a:
Copy code
C:\SysGCC\risc-v\riscv64-unknown-elf\lib\libc.a(lib_a-closer.o): in function
_close_r': Test8 C/C++ Problem C:\SysGCC\risc-v\riscv64-unknown-elf\lib\libc.a(lib_a-fstatr.o): in function
_fstat_r': Test8 C/C++ ProblemC:\SysGCC\risc-v\riscv64-unknown-elf\lib\libc.a(lib_a-isattyr.o): in function
_isatty_r': Test8 C/C++ Problem C:\SysGCC\risc-v\riscv64-unknown-elf\lib\libc.a(lib_a-lseekr.o): in function
_lseek_r': Test8 C/C++ ProblemC:\SysGCC\risc-v\riscv64-unknown-elf\lib\libc.a(lib_a-openr.o): in function
_open_r': Test8 C/C++ Problem C:\SysGCC\risc-v\riscv64-unknown-elf\lib\libc.a(lib_a-readr.o): in function
_read_r': Test8 C/C++ ProblemC:\SysGCC\risc-v\riscv64-unknown-elf\lib\libc.a(lib_a-signalr.o): in function
_getpid_r': Test8 C/C++ Problem C:\SysGCC\risc-v\riscv64-unknown-elf\lib\libc.a(lib_a-signalr.o): in function
_kill_r': Test8 C/C++ ProblemC:\SysGCC\risc-v\riscv64-unknown-elf\lib\libc.a(lib_a-writer.o): in function `_write_r': Test8 C/C++ Problem
My specific questions are:
Are there any known issues with the gcc-riscv64-unknown-elf toolchain that might be causing these linker errors?
What might be the correct way to resolve these issues?
Are there any specific OpenOCD scripts or configurations tailored for NEORV32?
What are the recommended settings for debugging NEORV32 in Eclipse using OpenOCD?
I would greatly appreciate any assistance or pointers from those who have experience with this configuration. If there's existing documentation or tutorials that cover this setup, please direct me to them.
Thank you very much for your time and help!
Best regards,
Beta Was this translation helpful? Give feedback.
All reactions