I'm trying to compile a circle OS application (known to work in another development environment) and I had dependencies problems one after the other for the last two days.
The version I use are:
Rkit-ARM for Ride7 v1.30.10.0356
Ride7 Patch v7.30.10.0169
I'm using the included Circle OS version (4.1) and the STM32Lib v3.4.0
I have added all the .h files in the relevant directory (the STM32 .h files, plus stm32f10x.h and stm32f10x_conf.h that I had to go find elsewhere) and added the relevant .c files to my project (stm32f10x_gpio.c, stm32f10x_rcc.c, stm32f10x_tim.c and stm32f10x_usart.c) as recommended on the forum, instead of using the "Use OLD precompiled libraries" option.
Now, I have the following error:
Building <project path>\Appli0.rapp
Running: LD Linker
"C:\Program Files (x86)\Raisonance\Ride\arm-gcc\bin\arm-none-eabi-gcc.exe" -mcpu=cortex-m3 -mthumb -Wl,-T -Xlinker " <project path>\objrelease\Appli0.elf.ld" -u _start -Wl,-static -Wl,--gc-sections -nostartfiles -Wl,-Map -Xlinker " <project path>\objrelease\Appli0.map"
<project path>\objrelease\stm32f10x_gpio.o: In function `GPIO_Init':
<project path>\libsrc/stm32f10x_gpio.c:178: undefined reference to `assert_param'
<project path>\libsrc/stm32f10x_gpio.c:179: undefined reference to `assert_param'
<project path>\libsrc/stm32f10x_gpio.c:180: undefined reference to `assert_param'
<project path>\libsrc/stm32f10x_gpio.c:187: undefined reference to `assert_param'
<project path>\objrelease\stm32f10x_rcc.o: In function `RCC_APB2PeriphClockCmd':
<project path>\libsrc/stm32f10x_rcc.c:1098: undefined reference to `assert_param'
<project path>\objrelease\stm32f10x_rcc.o: <project path>\libsrc/stm32f10x_rcc.c:1099: more undefined references to `assert_param' follow
collect2: ld returned 1 exit status
The only fix I've found is to add the following line to all the stm32f10x_***.c files:
That file contains the only definition of the 'assert_param' macro I've found.
With that line added on top of the 4 .c files, my application build successfully.
I can't believe ST would deliver a library without the proper dependencies resolved, so, what am I doing wrong to have to use this fix?