Build problem wth Coocox and ARM GCC

Asked by Amin Kamalzadeh

I had setup the toolchain directory for GNU ARM in Coocox, and configured a project.
Here is the error I'm getting while building.
Anybody can help about the root cause of the error?
thanks,
Amin

hardware: STM32F407ZG
Debugger: ST-link V2
==================================
GCC HOME: C:\Program Files (x86)\GNU Tools ARM Embedded\4.6 2012q2\bin
compile:
    [mkdir] Created dir: C:\CooCox\CoIDE\workspace\test_proj_01\Debug\bin
    [mkdir] Created dir: C:\CooCox\CoIDE\workspace\test_proj_01\Debug\obj
       [cc] 6 total files to be compiled.
       [cc] arm-none-eabi-gcc -mcpu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=softfp -mthumb -Wall -ffunction-sections -O0 -g -c -DSTM32F407ZG -IC:\CooCox\CoIDE\workspace\test_proj_01 -IC:\CooCox\CoIDE\workspace\test_proj_01\cmsis_lib -IC:\CooCox\CoIDE\workspace\test_proj_01\cmsis_lib\include -IC:\CooCox\CoIDE\workspace\test_proj_01\cmsis_boot C:\CooCox\CoIDE\workspace\test_proj_01\cmsis_boot\startup\startup_stm32f4xx.c C:\CooCox\CoIDE\workspace\test_proj_01\main.c C:\CooCox\CoIDE\workspace\test_proj_01\cmsis_lib\source\stm32f4xx_rcc.c C:\CooCox\CoIDE\workspace\test_proj_01\cmsis_lib\source\stm32f4xx_gpio.c C:\CooCox\CoIDE\workspace\test_proj_01\cmsis_boot\system_stm32f4xx.c C:\CooCox\CoIDE\workspace\test_proj_01\example\IOToggle.c
       [cc] In file included from C:\CooCox\CoIDE\workspace\test_proj_01\cmsis_lib\include/stm32f4xx_rcc.h:31:0,
       [cc] C:\CooCox\CoIDE\workspace\test_proj_01\cmsis_boot/stm32f4xx.h:240:81: fatal error: core_cm4.h: No such file or directory
       [cc] from C:\CooCox\CoIDE\workspace\test_proj_01\cmsis_lib\source\stm32f4xx_rcc.c:56:
       [cc] compilation terminated.
       [cc] In file included from C:\CooCox\CoIDE\workspace\test_proj_01\cmsis_lib\include/stm32f4xx_gpio.h:32:0,
       [cc] from C:\CooCox\CoIDE\workspace\test_proj_01\cmsis_lib\source\stm32f4xx_gpio.c:79:
       [cc] C:\CooCox\CoIDE\workspace\test_proj_01\cmsis_boot/stm32f4xx.h:240:81: fatal error: core_cm4.h: No such file or directory
       [cc] compilation terminated.
       [cc] In file included from C:\CooCox\CoIDE\workspace\test_proj_01\cmsis_boot\system_stm32f4xx.c:117:0:
       [cc] C:\CooCox\CoIDE\workspace\test_proj_01\cmsis_boot\/stm32f4xx.h:240:81: fatal error: core_cm4.h: No such file or directory
       [cc] compilation terminated.
       [cc] C:\CooCox\CoIDE\workspace\test_proj_01\cmsis_boot/stm32f4xx.h:240:81: fatal error: core_cm4.h: No such file or directory
       [cc] In file included from C:\CooCox\CoIDE\workspace\test_proj_01\example\IOToggle.c:2:0:
       [cc] compilation terminated.

BUILD FAILED
Total time: 0 seconds
=======================================

Question information

Language:
English Edit question
Status:
Solved
For:
GNU Arm Embedded Toolchain Edit question
Assignee:
No assignee Edit question
Solved by:
Terry Guo
Solved:
Last query:
Last reply:
Revision history for this message
Terry Guo (terry.guo) said :
#1

Hi Amin,

Thanks for trying our tool chain. Can you share the CooCox IDE version you are using? And can you manually verify the core_cm4.h is in your path?

BR,
Terry

Revision history for this message
Best Terry Guo (terry.guo) said :
#2

Hi Amin,

If you have experience on creating M3 project with CoIDE 1.5, you will find similar file (core_cm3.h) is provided by "CMSIS core for M3" module of CoIDE. Now for M4, seems this module isn't provided. A workaround is to download CMSIS package and add PATH-TO-CMSIS/Include into your project include path. It should work.

BR,
Terry

Revision history for this message
Amin Kamalzadeh (amin-kamalzadeh) said :
#3

I'm using CoIDE version 1.5.
The description says for this version, the CMSIS lib is included. (http://www.coocox.org/CoIDE/CoIDE_Updates.htm)

"...
CMSIS lib for ST STM32F4x and Nuvoton Nano1xx series uploaded, CMSIS lib for Holtek HT32F125x and HT32F1755_2755 series updated
..."

If I have to add the "CMSIS package", where can i download it? could you please provide a link?

Thanks!
Amin

Revision history for this message
Joey Ye (jinyun-ye) said :
#4

Http://WWW.onarm.com
You can also find the link in readme
On Sep 15, 2012 6:41 AM, "Amin Kamalzadeh" <
<email address hidden>> wrote:

> Question #206989 on GCC ARM Embedded changed:
> https://answers.launchpad.net/gcc-arm-embedded/+question/206989
>
> Status: Answered => Open
>
> Amin Kamalzadeh is still having a problem:
> I'm using CoIDE version 1.5.
> The description says for this version, the CMSIS lib is included. (
> http://www.coocox.org/CoIDE/CoIDE_Updates.htm)
>
> "...
> CMSIS lib for ST STM32F4x and Nuvoton Nano1xx series uploaded, CMSIS lib
> for Holtek HT32F125x and HT32F1755_2755 series updated
> ..."
>
> If I have to add the "CMSIS package", where can i download it? could you
> please provide a link?
>
> Thanks!
> Amin
>
> --
> You received this question notification because you are an answer
> contact for GCC ARM Embedded.
>

Revision history for this message
Amin Kamalzadeh (amin-kamalzadeh) said :
#5

Thanks Terry Guo, that solved my question.