Forum Discussion
Altera_Forum
Honored Contributor
15 years agoHow to comiple a single C file in Nios
When I right click a C file and choose "Build selected file(s)", an error message turned up which says "..Operation not enabled".
https://sites.google.com/site/nswbanana/store_1/build_file.PNG?attredirects=0 And when I click "Clean selected file(s)", an error message turned up again https://sites.google.com/site/nswbanana/store_1/clean_file.JPG?attredirects=0 I am using Nios10.1 SP14 Replies
- Altera_Forum
Honored Contributor
Try going through one of the included examples and/or tutorials. You have to create a Nios II project, compile it, and then "Run" or "Debug" the result on a target board.
In general, you can't do what you're asking to do unless you're already _running_ in the runtime environment that you'd like to compile for... i.e.: Compiling a program for Windows while running in Windows...same for Linux. Regards, slacker - Altera_Forum
Honored Contributor
--- Quote Start --- Try going through one of the included examples and/or tutorials. You have to create a Nios II project, compile it, and then "Run" or "Debug" the result on a target board. In general, you can't do what you're asking to do unless you're already _running_ in the runtime environment that you'd like to compile for... i.e.: Compiling a program for Windows while running in Windows...same for Linux. Regards, slacker --- Quote End --- thanks for your answer. I think I haven't explained my question clearly. I do have a working project. I just want to compile a single C file in the project. - Altera_Forum
Honored Contributor
I have seen a lot of errors in the Nios tools, this one is new for me :)
What do the details say when you try to clean the project? Have you tried building the Hello World example?? - Altera_Forum
Honored Contributor
Certainly my experience of the IDE is that it did rather like running the compiler! Which wouldn't quite be so bad if the tcl (or whatever) actually ran an a sane speed!
However I switched my build environment to vi+make so don't have that problem any more! Made easier by the fact that I don't need any of the Altera tools to get my code onto the fpga.