Forum Discussion
Altera_Forum
Honored Contributor
20 years agoHi Mountain8848,
Which linux distribution do you use? I have built on Slackware 10.2 and Fedora core4. You should use gcc 3.xx to build the tools. There are problems when using gcc 4.xx. On Redhat/Fedora , there were compat-gcc packages. cd /usr/bin mv gcc gcc4 ln -s gcc32 gcc I didn't use the source from linux nios2 cd. You maybe right about the exec binary size differeces between them, static/dynamic. About the libs/includes, there are two sets. The newlib is used by altera IDE as default. And uClibc is used by busybox/uclinux. You don't need newlib if most of your works on uclinux. The uClibc build refers to kernel build include. You must follow the steps, build kernel before build uCLibc. The uClibc build in my first post, make install will place the includes and libs into /usr/local/nios2-elf/ include and lib. I did build both, and install into different dirs. You can select with -nostdinc and -nostdlib flags. 1. newlib place the source in /usr/local/src/nios2/ newlib. after you build the nios2-elf-gcc. cd /usr/local/src/nios2/newlib/newlib cp configure.host.smallc configure.host mkdir /usr/local/src/nios2/build/newlib cd /usr/local/src/nios2/build/newlib ../../newlib/configure --target=nios2-elf make make install Then the include and lib will be placed in /usr/local/nios2-elf . 2. uClibc if you install both lib set, follow the steps, as in the first post. but set the RUNTIME/DEVEL install dirs to another place. change the UCLIBC_PLUGIN when building busybox, and apps.