8 years, 4 months ago.

gcc-arm-embedded export for LPC4088


I'm sorry to repost it as a question but I didn't get an answer in the forum.

I'm having trouble to compile mbed projects offline with the gcc-arm-embedded toolchain. I exported the blinking LED Hello World program for both the EA LPC4088 QS and the mbed LPC1768. Building the project for the LPC1768 works, for the LPC4088 I get several errors with the VFP register arguments:

"/usr/bin/../lib/gcc/arm-none-eabi/4.8.3/../../../../arm-none-eabi/bin/ld: error: /mbed/TARGET_LPC4088/TOOLCHAIN_GCC_ARM/libmbed.a(pinmap.o) uses VFP register arguments, blink.elf does not"

I tried changing the -mfloat-abi parameter with no success. I also updated the latest mbed libary before exporting. The system is arch linux with the latest 4.8 gcc-arm-embedded. Any suggestions how I can get this work?


I have the same problem here. Grateful for any ideas!

posted by Chris Hunt 27 Feb 2014

3 Answers

8 years, 4 months ago.

Got it! You need to add the "-mfpu=fpv4-sp-d16 -mfloat-abi=hard" switches to LD_FLAGS in the makefile. Boom.

Accepted Answer

That's great news, it works for me as well. Since those arguments were in the compiler flags I didn't try to move them to the linker, but that solved the problem. Thanks Chris!

posted by Hannes Schenk 28 Feb 2014
8 years, 2 months ago.

FP support is still confusing... I try to use emWin Lib and got VFP linker errors because lib types mismatch: mbed used abi-hard, emWin abi-soft. Now NXP has recompiled the emWin Lib to supply also abi-hard, but when exported my mbed testproject today I got a mbed lib with abi-soft. The project settings for the (LPCXpresso) project are still -mfloat-abi=hard, so compiling does not work. Is there a setting for what I get exported?

8 years, 4 months ago.

Hi Chris,

unfortunately I can't provide a solution. There was no answer here on mbed and I tried searching the web for solutions, but all I could find were hints to the -mfloat-abi parameter which did not help. Let's hope there will be some fix anytime soon.