lpcware

Recreate Example001 from FreeRTOS manual

Discussion created by lpcware Employee on Jun 15, 2016
Latest reply on Jun 15, 2016 by lpcware
Content originally posted in LPCWare by mwoodmansee on Mon Jul 29 18:41:42 MST 2013
I am trying to learn about the LPC1769 and am rewriting the examples used in Richard Barry's FreeRTOS manual.  When I compile a retyped version of Example01 called example01_rework I get the following compilation dump. 

Please provide your thoughts.


****************************************************************************************
20:28:54 **** Incremental Build of configuration Debug for project example01_rework ****
make all
Building file: ../src/cr_startup_lpc17.c
Invoking: MCU C Compiler
arm-none-eabi-gcc -D__NEWLIB__ -DDEBUG -D__CODE_RED -DPACK_STRUCT_END=__attribute\(\(packed\)\) -DGCC_ARMCM3 -I"C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\FreeRTOS_Library\demo_code" -I"C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\CMSISv1p30_LPC17xx\inc" -I../src -I../FreeRTOS_include -I../FreeRTOS_portable -O0 -g3 -Wall -c -fmessage-length=0 -fno-builtin -ffunction-sections -fdata-sections -mcpu=cortex-m3 -mthumb -MMD -MP -MF"src/cr_startup_lpc17.d" -MT"src/cr_startup_lpc17.d" -o "src/cr_startup_lpc17.o" "../src/cr_startup_lpc17.c"
Finished building: ../src/cr_startup_lpc17.c

Building file: ../src/main.c
Invoking: MCU C Compiler
arm-none-eabi-gcc -D__NEWLIB__ -DDEBUG -D__CODE_RED -DPACK_STRUCT_END=__attribute\(\(packed\)\) -DGCC_ARMCM3 -I"C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\FreeRTOS_Library\demo_code" -I"C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\CMSISv1p30_LPC17xx\inc" -I../src -I../FreeRTOS_include -I../FreeRTOS_portable -O0 -g3 -Wall -c -fmessage-length=0 -fno-builtin -ffunction-sections -fdata-sections -mcpu=cortex-m3 -mthumb -MMD -MP -MF"src/main.d" -MT"src/main.d" -o "src/main.o" "../src/main.c"
../src/main.c: In function 'main':
../src/main.c:38:2: warning: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
../src/main.c:41:2: warning: pointer targets in passing argument 2 of 'xTaskGenericCreate' differ in signedness [-Wpointer-sign]
../FreeRTOS_include/task.h:1299:22: note: expected 'const signed char * const' but argument is of type 'char *'
../src/main.c:49:2: warning: pointer targets in passing argument 2 of 'xTaskGenericCreate' differ in signedness [-Wpointer-sign]
../FreeRTOS_include/task.h:1299:22: note: expected 'const signed char * const' but argument is of type 'char *'
../src/main.c: At top level:
../src/main.c:23:13: warning: 'setupHardware' defined but not used [-Wunused-function]
Finished building: ../src/main.c

Building file: ../FreeRTOS_src/croutine.c
Invoking: MCU C Compiler
arm-none-eabi-gcc -D__NEWLIB__ -DDEBUG -D__CODE_RED -DPACK_STRUCT_END=__attribute\(\(packed\)\) -DGCC_ARMCM3 -I"C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\FreeRTOS_Library\demo_code" -I"C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\CMSISv1p30_LPC17xx\inc" -I../src -I../FreeRTOS_include -I../FreeRTOS_portable -O0 -g3 -Wall -c -fmessage-length=0 -fno-builtin -ffunction-sections -fdata-sections -mcpu=cortex-m3 -mthumb -MMD -MP -MF"FreeRTOS_src/croutine.d" -MT"FreeRTOS_src/croutine.d" -o "FreeRTOS_src/croutine.o" "../FreeRTOS_src/croutine.c"
Finished building: ../FreeRTOS_src/croutine.c

Building file: ../FreeRTOS_src/list.c
Invoking: MCU C Compiler
arm-none-eabi-gcc -D__NEWLIB__ -DDEBUG -D__CODE_RED -DPACK_STRUCT_END=__attribute\(\(packed\)\) -DGCC_ARMCM3 -I"C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\FreeRTOS_Library\demo_code" -I"C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\CMSISv1p30_LPC17xx\inc" -I../src -I../FreeRTOS_include -I../FreeRTOS_portable -O0 -g3 -Wall -c -fmessage-length=0 -fno-builtin -ffunction-sections -fdata-sections -mcpu=cortex-m3 -mthumb -MMD -MP -MF"FreeRTOS_src/list.d" -MT"FreeRTOS_src/list.d" -o "FreeRTOS_src/list.o" "../FreeRTOS_src/list.c"
Finished building: ../FreeRTOS_src/list.c

Building file: ../FreeRTOS_src/queue.c
Invoking: MCU C Compiler
arm-none-eabi-gcc -D__NEWLIB__ -DDEBUG -D__CODE_RED -DPACK_STRUCT_END=__attribute\(\(packed\)\) -DGCC_ARMCM3 -I"C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\FreeRTOS_Library\demo_code" -I"C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\CMSISv1p30_LPC17xx\inc" -I../src -I../FreeRTOS_include -I../FreeRTOS_portable -O0 -g3 -Wall -c -fmessage-length=0 -fno-builtin -ffunction-sections -fdata-sections -mcpu=cortex-m3 -mthumb -MMD -MP -MF"FreeRTOS_src/queue.d" -MT"FreeRTOS_src/queue.d" -o "FreeRTOS_src/queue.o" "../FreeRTOS_src/queue.c"
Finished building: ../FreeRTOS_src/queue.c

Building file: ../FreeRTOS_src/tasks.c
Invoking: MCU C Compiler
arm-none-eabi-gcc -D__NEWLIB__ -DDEBUG -D__CODE_RED -DPACK_STRUCT_END=__attribute\(\(packed\)\) -DGCC_ARMCM3 -I"C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\FreeRTOS_Library\demo_code" -I"C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\CMSISv1p30_LPC17xx\inc" -I../src -I../FreeRTOS_include -I../FreeRTOS_portable -O0 -g3 -Wall -c -fmessage-length=0 -fno-builtin -ffunction-sections -fdata-sections -mcpu=cortex-m3 -mthumb -MMD -MP -MF"FreeRTOS_src/tasks.d" -MT"FreeRTOS_src/tasks.d" -o "FreeRTOS_src/tasks.o" "../FreeRTOS_src/tasks.c"
Finished building: ../FreeRTOS_src/tasks.c

Building file: ../FreeRTOS_src/timers.c
Invoking: MCU C Compiler
arm-none-eabi-gcc -D__NEWLIB__ -DDEBUG -D__CODE_RED -DPACK_STRUCT_END=__attribute\(\(packed\)\) -DGCC_ARMCM3 -I"C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\FreeRTOS_Library\demo_code" -I"C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\CMSISv1p30_LPC17xx\inc" -I../src -I../FreeRTOS_include -I../FreeRTOS_portable -O0 -g3 -Wall -c -fmessage-length=0 -fno-builtin -ffunction-sections -fdata-sections -mcpu=cortex-m3 -mthumb -MMD -MP -MF"FreeRTOS_src/timers.d" -MT"FreeRTOS_src/timers.d" -o "FreeRTOS_src/timers.o" "../FreeRTOS_src/timers.c"
Finished building: ../FreeRTOS_src/timers.c

Building file: ../FreeRTOS_portable/MemMang/heap_2.c
Invoking: MCU C Compiler
arm-none-eabi-gcc -D__NEWLIB__ -DDEBUG -D__CODE_RED -DPACK_STRUCT_END=__attribute\(\(packed\)\) -DGCC_ARMCM3 -I"C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\FreeRTOS_Library\demo_code" -I"C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\CMSISv1p30_LPC17xx\inc" -I../src -I../FreeRTOS_include -I../FreeRTOS_portable -O0 -g3 -Wall -c -fmessage-length=0 -fno-builtin -ffunction-sections -fdata-sections -mcpu=cortex-m3 -mthumb -MMD -MP -MF"FreeRTOS_portable/MemMang/heap_2.d" -MT"FreeRTOS_portable/MemMang/heap_2.d" -o "FreeRTOS_portable/MemMang/heap_2.o" "../FreeRTOS_portable/MemMang/heap_2.c"
Finished building: ../FreeRTOS_portable/MemMang/heap_2.c

Building file: ../FreeRTOS_portable/port.c
Invoking: MCU C Compiler
arm-none-eabi-gcc -D__NEWLIB__ -DDEBUG -D__CODE_RED -DPACK_STRUCT_END=__attribute\(\(packed\)\) -DGCC_ARMCM3 -I"C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\FreeRTOS_Library\demo_code" -I"C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\CMSISv1p30_LPC17xx\inc" -I../src -I../FreeRTOS_include -I../FreeRTOS_portable -O0 -g3 -Wall -c -fmessage-length=0 -fno-builtin -ffunction-sections -fdata-sections -mcpu=cortex-m3 -mthumb -MMD -MP -MF"FreeRTOS_portable/port.d" -MT"FreeRTOS_portable/port.d" -o "FreeRTOS_portable/port.o" "../FreeRTOS_portable/port.c"
Finished building: ../FreeRTOS_portable/port.c

Building target: example01_rework.axf
Invoking: MCU Linker
arm-none-eabi-gcc -nostdlib -Xlinker -Map="example01_rework.map" -Xlinker --gc-sections -mcpu=cortex-m3 -mthumb -T "example01_rework_Debug.ld" -o "example01_rework.axf"  ./src/cr_startup_lpc17.o ./src/main.o  ./FreeRTOS_src/croutine.o ./FreeRTOS_src/list.o ./FreeRTOS_src/queue.o ./FreeRTOS_src/tasks.o ./FreeRTOS_src/timers.o  ./FreeRTOS_portable/MemMang/heap_2.o  ./FreeRTOS_portable/port.o  
./src/main.o: In function `vTask1':
C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\example01_rework\Debug/../src/main.c:71: undefined reference to `vPrintString'
./src/main.o: In function `vTask2':
C:\Users\h117018\Documents\LPCXpresso_5.2.6_2137\workspace\example01_rework\Debug/../src/main.c:93: undefined reference to `vPrintString'
c:/nxp/lpcxpresso_5.2.6_2137/lpcxpresso/tools/bin/../lib/gcc/arm-none-eabi/4.6.2/../../../../arm-none-eabi/lib/armv7-m\libc.a(lib_a-sbrkr.o): In function `_sbrk_r':
sbrkr.c:(.text._sbrk_r+0xc): undefined reference to `_sbrk'
c:/nxp/lpcxpresso_5.2.6_2137/lpcxpresso/tools/bin/../lib/gcc/arm-none-eabi/4.6.2/../../../../arm-none-eabi/lib/armv7-m\libc.a(lib_a-writer.o): In function `_write_r':
writer.c:(.text._write_r+0x10): undefined reference to `_write'
c:/nxp/lpcxpresso_5.2.6_2137/lpcxpresso/tools/bin/../lib/gcc/arm-none-eabi/4.6.2/../../../../arm-none-eabi/lib/armv7-m\libc.a(lib_a-closer.o): In function `_close_r':
closer.c:(.text._close_r+0xc): undefined reference to `_close'
c:/nxp/lpcxpresso_5.2.6_2137/lpcxpresso/tools/bin/../lib/gcc/arm-none-eabi/4.6.2/../../../../arm-none-eabi/lib/armv7-m\libc.a(lib_a-fstatr.o): In function `_fstat_r':
fstatr.c:(.text._fstat_r+0xe): undefined reference to `_fstat'
c:/nxp/lpcxpresso_5.2.6_2137/lpcxpresso/tools/bin/../lib/gcc/arm-none-eabi/4.6.2/../../../../arm-none-eabi/lib/armv7-m\libc.a(lib_a-isattyr.o): In function `_isatty_r':
isattyr.c:(.text._isatty_r+0xc): undefined reference to `_isatty'
c:/nxp/lpcxpresso_5.2.6_2137/lpcxpresso/tools/bin/../lib/gcc/arm-none-eabi/4.6.2/../../../../arm-none-eabi/lib/armv7-m\libc.a(lib_a-lseekr.o): In function `_lseek_r':
lseekr.c:(.text._lseek_r+0x10): undefined reference to `_lseek'
c:/nxp/lpcxpresso_5.2.6_2137/lpcxpresso/tools/bin/../lib/gcc/arm-none-eabi/4.6.2/../../../../arm-none-eabi/lib/armv7-m\libc.a(lib_a-readr.o): In function `_read_r':
readr.c:(.text._read_r+0x10): undefined reference to `_read'
collect2: ld returned 1 exit status
make: *** [example01_rework.axf] Error 1

20:29:04 Build Finished (took 9s.773ms)

Outcomes