Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Beginner
142 Views

NIOS application build fail

Hi,


I have recently created a NIOS II application for UART which has built and run correctly up until today. I have not made any changes other than to rebuild the release/debug app.


In fact all my apps now wont build in Eclipse (again no changes to settings or code have been made).


I am running Quartus Lite 20.1 using EDS (Eclipse Mars 4.5.2 release) to create the NIOS application.
The only thing I can see is different is that my Windows box updated to 2004 build between builds (I know there have been changes to WSL in this).


This is the output from the toolchain:


Info: Linking uart_int_app.elf
nios2-elf-g++.exe -T'C:/Users/xxx/Desktop/Quartus/DE0/UART/software/uart_int_app_bsp/linker.x' -msys-crt0='C:/Users/xxx/Desktop/Quartus/DE0/UART/software/uart_int_app_bsp/obj/HAL/src/crt0.o' -msys-lib= -LC:/Users/xxx/Desktop/Quartus/DE0/UART/software/uart_int_app_bsp -msmallc -Wl,-Map=uart_int_app.map -O0 -g -Wall -mno-hw-div -mno-hw-mul -mno-hw-mulx -mgpopt=global -o uart_int_app.elf obj/default/InterruptHandlerForUart.o obj/default/hello_world.o -lm -msys-lib=m
nios2-elf-g++.exe: error: missing argument to '-msys-lib='
Makefile:1011: recipe for target 'uart_int_app.elf' failed
make: *** [uart_int_app.elf] Error 1

Any ideas?

0 Kudos
7 Replies
Highlighted
Beginner
105 Views

So, 

Rolling back to 18.1 (Cygwin based) version and importing the project works ok. Anyone else seeing this issue with v20?

0 Kudos
Highlighted
New Contributor I
102 Views

"I have recently created a NIOS II application for UART which has built and run correctly up until today. I have not made any changes other than to rebuild the release/debug app."

 

Hi @Boondoggler , I'm interesting to your NIOS Application for UART ,  if possible, can you share it here for us for  reference.  3Tanks

Tags (1)
0 Kudos
Highlighted
Beginner
92 Views

Hi, really that's for another thread and doesn't answer my question. Unfotunately I can't give the source out.

The inspirations came from:

https://ralphexe.wordpress.com/2016/11/01/altera-uart-ip-core-using-de0-nano/

which the first part is useful but very basic, but is pretty standard adding UART to NIOS builds and this:

https://community.intel.com/t5/Nios-II-Embedded-Design-Suite/NiosII-Uart-Interrupt-Handler/td-p/8469...

which gave me direction on creating my own. Or use DMA which requires working out the code to understand how many characters are in the Rx buffer. If so, this worth a read:

https://community.intel.com/t5/Programmable-Devices/Nios-Uart-And-Dma/td-p/15995

Also this is a useful source:

https://class.ece.uw.edu/469/peckol/index.html

0 Kudos
Highlighted
53 Views

Hi Boon,


Can you try to find a new computer to install or remove NiosII EDS and reinstall it?


You may try below manually.

 

1. install WSL for windows

i. https://www.intel.com/content/dam/www/programmable/us/en/pdfs/literature/hb/nios2/n2sw_nii5v2gen2.pd... (chapter 2.1)

 Note: Windows 10 build version 16215.0 or higher is the recommended operating system version.

ii. After installation has successfully completed, launch Ubuntu 18.04.

iii. Install additional distro packages required for Nios II EDS using the following commands:

 a. sudo apt install wsl

 b. sudo apt install doc2unix

 c. sudo apt install make

 

before"sudo apt install wsl"

run:

sudo apt-get update

 

2. install nios2 eclipse folder

https://www.intel.com/content/altera-www/global/en_us/index/support/support-resources/knowledge-base...


Eric


0 Kudos
Highlighted
Beginner
32 Views

Hi,

I'm having similar issues, with all my pre-existing Nios project compiling but unable to run/debug and have tried those workarounds (and succesfully upgraded to wsl 2) and other solutions seen in previous post such as :

change

APP_LDFLAGS += -msys-lib=$(call adjust-path-mixed,$(SYS_LIB)) 

to 

APP_LDFLAGS += -msys-lib=hal_bsp

 

and manually making an project.elf.srec file with
BUILD_PRE_PROCESS := touch $(ELF).srec

 

but it still display the following errors :

wslpath: ./Found: No such file or directory
wslpath: ./Found.srec: No such file or directory

nios2-elf-objcopy.exe: supported targets: elf32-littlenios2 elf32-bignios2 elf32-little elf32-big srec symbolsrec verilog tekhex binary ihex plugin
wslpath: ./Found.srec: No such file or directory
Using cable "USB-BlasterII [USB-1]", device 1, instance 0x00
Pausing target processor: not responding.
Resetting and trying again: FAILED
Leaving target processor paused
rm: cannot remove './Found.srec': No such file or directory

 

So is there any other workaround you can think of ? I'm also interested in understanding what causes all this previously functioning project to stop working.

Any ideas would be welcome

Kindly,

0 Kudos
Highlighted
Beginner
9 Views

Hi Eric

I haven't seen any notification emails of new posts, so sorry for missing these. Currently working on v18 environment as all is well.

I will try your suggestions and post back shortly.

Thanks

BD

 

0 Kudos