I was trying to build a program, it passed compiling, but stucked at linking:
E:/SEGGER/SEGGER Embedded Studio 3.12/lib/libc_v7em_fpv4_sp_d16_hard_t_le_eabi.a(libc2.o): In function `malloc':
libc2.c:(.text.libc.malloc+0xe): undefined reference to `__heap_lock'
libc2.c:(.text.libc.malloc+0x3a): undefined reference to `__heap_unlock'
libc2.c:(.text.libc.malloc+0x74): undefined reference to `__heap_unlock'
libc2.c:(.text.libc.malloc+0x7e): undefined reference to `__heap_unlock'
E:/SEGGER/SEGGER Embedded Studio 3.12/lib/libc_v7em_fpv4_sp_d16_hard_t_le_eabi.a(libc2.o): In function `free':
libc2.c:(.text.libc.free+0x8): undefined reference to `__heap_lock'
libc2.c:(.text.libc.free+0x76): undefined reference to `__heap_unlock'
Build failed
I checked linker script file and noticed something different than before:
__HEAPSIZE__ = 1024;
__STACKSIZE_ABT__ = 0;
__STACKSIZE_FIQ__ = 0;
__STACKSIZE_IRQ__ = 0;
__STACKSIZE_PROCESS__ = 0;
__STACKSIZE_SVC__ = 0;
__STACKSIZE_UND__ = 0;
__STACKSIZE__ = 2048;
Tabed lines are newly added.
Any ideas on what's wrong?
E:/SEGGER/SEGGER Embedded Studio 3.12/lib/libc_v7em_fpv4_sp_d16_hard_t_le_eabi.a(libc2.o): In function `malloc':
libc2.c:(.text.libc.malloc+0xe): undefined reference to `__heap_lock'
libc2.c:(.text.libc.malloc+0x3a): undefined reference to `__heap_unlock'
libc2.c:(.text.libc.malloc+0x74): undefined reference to `__heap_unlock'
libc2.c:(.text.libc.malloc+0x7e): undefined reference to `__heap_unlock'
E:/SEGGER/SEGGER Embedded Studio 3.12/lib/libc_v7em_fpv4_sp_d16_hard_t_le_eabi.a(libc2.o): In function `free':
libc2.c:(.text.libc.free+0x8): undefined reference to `__heap_lock'
libc2.c:(.text.libc.free+0x76): undefined reference to `__heap_unlock'
Build failed
I checked linker script file and noticed something different than before:
__HEAPSIZE__ = 1024;
__STACKSIZE_ABT__ = 0;
__STACKSIZE_FIQ__ = 0;
__STACKSIZE_IRQ__ = 0;
__STACKSIZE_PROCESS__ = 0;
__STACKSIZE_SVC__ = 0;
__STACKSIZE_UND__ = 0;
__STACKSIZE__ = 2048;
Tabed lines are newly added.
Any ideas on what's wrong?