7 years, 5 months ago.

Mbed with GCC ARM Compiler

I have exported the project file in gcc arm compiler and tried to run it as per the link ->https://developer.mbed.org/handbook/Exporting-to-GCC-ARM-Embedded

But i am getting this error. " arun@arunmag:/Downloads/mbed_serialget$ sudo make arm-none-eabi-gcc -Wl,gc-sections -Wl,wrap,main -Wl,wrap,_malloc_r -Wl,wrap,_free_r -Wl,wrap,_realloc_r -Wl,wrap,_calloc_r -mcpu=cortex-m3 -mthumb -T../mbed/TARGET_LPC1768/TOOLCHAIN_GCC_ARM/LPC1768.ld -L../mbed/TARGET_LPC1768/TOOLCHAIN_GCC_ARM -o mbed_serialget.elf MODSERIAL/ChangeLog.o main.o MODSERIAL/FLUSH.o MODSERIAL/GETC.o MODSERIAL/INIT.o MODSERIAL/ISR_RX.o MODSERIAL/ISR_TX.o MODSERIAL/MODSERIAL.o MODSERIAL/MODSERIAL_IRQ_INFO.o MODSERIAL/PUTC.o MODSERIAL/RESIZE.o MODSERIAL/example1.o MODSERIAL/example2.o MODSERIAL/example3a.o MODSERIAL/example3b.o MODSERIAL/example_dma.o ../mbed/TARGET_LPC1768/TOOLCHAIN_GCC_ARM/board.o ../mbed/TARGET_LPC1768/TOOLCHAIN_GCC_ARM/cmsis_nvic.o ../mbed/TARGET_LPC1768/TOOLCHAIN_GCC_ARM/retarget.o ../mbed/TARGET_LPC1768/TOOLCHAIN_GCC_ARM/startup_LPC17xx.o ../mbed/TARGET_LPC1768/TOOLCHAIN_GCC_ARM/system_LPC17xx.o -Wl,start-group -lmbed -lstdc++ -lsupc++ -lm -lc -lgcc -lnosys -Wl,end-group /usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/lib/armv7-m/libc.a(lib_a-mprec.o): In function `_Balloc': /build/newlib-5zwpxE/newlib-2.2.0+git20150830.5a3d536/build/arm-none-eabi/armv7-m/newlib/libc/stdlib/../../../../../../newlib/libc/stdlib/mprec.c:106: undefined reference to `wrapcalloc_r' /build/newlib-5zwpxE/newlib-2.2.0+git20150830.5a3d536/build/arm-none-eabi/armv7-m/newlib/libc/stdlib/../../../../../../newlib/libc/stdlib/mprec.c:123: undefined reference to `wrapcalloc_r' collect2: error: ld returned 1 exit status /home/arun/Downloads/mbed_serialget/Makefile:97: recipe for target 'mbed_serialget.elf' failed make[1]: * [mbed_serialget.elf] Error 1 Makefile:21: recipe for target 'all' failed make: * [all] Error 2 "

1 Answer

7 years, 5 months ago.

Hi Arun,

We are having issues with exporters at the moment, but these should be fixed very very soon :). Sorry for all of that.

You could try using mbed-CLI, this allows you to pull code from our repositories and compile offline.

https://github.com/ARMmbed/mbed-cli

For examples use "mbed import'

If you need any help, let me know

Regards, Andrea team mbed

I am also trying to get elf file - debug and symbol file for debugging in gdb. Will mbed-cli works for that?

posted by Arun Magesh 24 Oct 2016