Intel® Quartus® Prime Software
Intel® Quartus® Prime Design Software, Design Entry, Synthesis, Simulation, Verification, Timing Analysis, System Design (Platform Designer, formerly Qsys)
16556 Discussions

Nios II Eclipse stuck while compiling newlib for a smallc C library

OSeme
Beginner
4,710 Views

I am building an example project for Nios II soft core processor. The example project is board_diag , which seems to show how to interface with peripherals using Nios II processor. I couldn't find documentation that would explain all the custom functions that are out there to use with Nios II processor so going of example code (would appreciate if someone knows/can share links to programming guide for Nios).

Anyway, when building example code project compiler gets stuck at building newlib for a smallc C library. It is pretty consistent with getting stuck at 27%. See image attached. If I hit cancel and then build the bsp project again, the build process happens quickly. However, when I go to build actual project I get an error that getc and sscanf functions are undefined. I try fixing it by manual adding path to the libraries Properties -> C/C++ General -> Paths and Symbols -> Add then I add path. Anyway the error is still there when building the project. I am out of ideas. Any suggestions on how to resolve this issue?

0 Kudos
5 Replies
OSeme
Beginner
2,262 Views

Hello Anand,

 

I enabled Reduced device drivers and small C library. If I don't do that, I get error message that I am out of memory. I am using 40960 bytes of memory.

settings.PNGoverflow.PNG

 

What else I discovered yesterday, is if I redo, start new application, it works eventually. It too me over 50 minutes to build BSP package. It obviously should not take that long. Why is it taking so long? Are there any settings? Is there an issue with Nios II compiler that result in a large footprint?

 

--Alex

0 Kudos
dsmirnov
New Contributor I
2,262 Views

As for compilation time you can add precompiled standard libraries in the Build settings, or chage settings of re-build/clean by excluding compiled libraries

 

0 Kudos
AnandRaj_S_Intel
Employee
2,262 Views

​Hi Alex,

 

Good to know that it works after recreating the eclipse project.

Try the suggestion given by @dsmirnov​.

It also dependent on tool chain version for faster build times also run with administrator rights which may make it run faster.

 

Regards

Anand

0 Kudos
OSeme
Beginner
2,262 Views

Thank you for your suggestions @dsmirnov​  and @Anand​ . I just couldn't find where in Build settings I can add precompiled libraries or re-build/clean by excluding compiled libraries.

0 Kudos
Reply