Compiling error for LPC2106 FreeRTOS example

catalin80 wrote on Monday, February 24, 2014:

Hi,
I need to build the LPC2106 example using Sourcery CodeBench Lite 2013.05-24 and I receive an error:

arm-none-linux-gnueabi-gcc -Wall -Wextra -Wshadow -Wpointer-arith -Wbad-function-cast -Wcast-align -Wsign-compare -Waggregate-return -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wunused -D RUN_FROM_RAM -DGCC_ARM7 -I. -I…/…/Source/include -I. -I…/…/…/FreeRTOS/Source/portable/RVDS/ARM7_LPC21xx -I…/Common/include -mcpu=arm7tdmi -T -fomit-frame-pointer -fno-strict-aliasing -fno-dwarf2-cfi-asm …/…/Source/portable/GCC/ARM7_LPC2000/portISR.o serial/serialISR.o main.o serial/serial.o ParTest/ParTest.o …/Common/Minimal/integer.o …/Common/Minimal/flash.o …/Common/Minimal/PollQ.o …/Common/Minimal/comtest.o …/Common/Minimal/flop.o …/Common/Minimal/semtest.o …/Common/Minimal/dynamic.o …/Common/Minimal/BlockQ.o …/…/Source/tasks.o …/…/Source/queue.o …/…/Source/list.o …/…/Source/portable/MemMang/heap_2.o …/…/Source/portable/GCC/ARM7_LPC2000/port.o -nostartfiles boot.s -Xlinker -ortosdemo.elf -Xlinker -M -Xlinker -Map=rtosdemo.map
/home/catalin/CodeSourcery/Sourcery_CodeBench_Lite_for_ARM_GNU_Linux/bin/…/lib/gcc/arm-none-linux-gnueabi/4.7.3/…/…/…/…/arm-none-linux-gnueabi/bin/ld: cannot open linker script file -fomit-frame-pointer: No such file or directory
collect2: error: ld returned 1 exit status
make: *** [rtosdemo.elf] Error 1

The FreeRTOS release is 8.0.0.

Is there someone that solved this problem (or know an suitable solution)?

Thank you !

epvuc wrote on Tuesday, March 04, 2014:

Your makefile or whatever is generating that link command is not inserting the name of the desired linker script, leaving just a blank in it’s place, so that gcc is trying to interpret whatever comes after “-T” as the filename of the linker script; in this case “-fomit-frame-pointer”. Probably you just have to define the name of the linker script. In the default LPC2106 demo on freertos v8, it’s “LDSCRIPT=lpc2106-rom.ld”.

rtel wrote on Wednesday, March 05, 2014:

That demo (which is very old) has multiple build configurations (RAM/ROM, THUMB/ARM) etc., and is build using the batch files that exist in the same directory as the makefile. The batch files set the correct linker script and a few other command line options for the build configuration selected. The information should be documented on the webpage for that demo.

Regards.