Hi aoi-kin,
now I working with my NIOS II and I have a problem when to build a project. this error appeared when I build the project
**** Build of configuration Nios II for project lights ****
make all
Info: Building ../lights_bsp
make --no-print-directory -C ../lights_bsp
[BSP build complete]
Info: Linking lights.elf
nios2-elf-g++ -T'../lights_bsp/linker.x' -msys-crt0='../lights_bsp/obj/HAL/src/crt0.o' -msys-lib=hal_bsp -L../lights_bsp -msmallc -Wl,-Map=lights.map -O0 -g -Wall -mno-hw-div -mno-hw-mul -mno-hw-mulx -o lights.elf obj/lights.o -lm
/cygdrive/c/altera/91/nios2eds/bin/nios2-gnutools/H-i686-pc-cygwin/bin/../lib/gcc/nios2-elf/3.4.6/../../../../nios2-elf/bin/ld: region onchip_memory2_0 is full (lights.elf section .rwdata). Region needs to be 244 bytes larger.
/cygdrive/c/altera/91/nios2eds/bin/nios2-gnutools/H-i686-pc-cygwin/bin/../lib/gcc/nios2-elf/3.4.6/../../../../nios2-elf/bin/ld: section .bss [00001020 -> 00001023] overlaps section .text [00001020 -> 00001e6f]
../lights_bsp/libhal_bsp.a(alt_close.o)(.text+0x128): In function `alt_get_errno':
HAL/inc/sys/alt_errno.h:81: Unable to reach errno (at 0x00001020) from the global pointer (at 0x0000a0cc) because the offset (-37036) is out of the allowed range, -32678 to 32767.
collect2: ld returned 1 exit status
make: *** [lights.elf] Error 1
do you have any idea regarding this problem? what the causes of this error actually?
Thank you.