cancel
Showing results for 
Search instead for 
Did you mean: 

Cannot Build imported stm32 project

aelgammal
Associate II

Hi,

I have imported a stm32 project from Git Hub that was there from 2 years ago to my stm32cudeide but when I try to build using internal builder: I get this error message:
Info: Internal Builder is used for build
arm-none-eabi-gcc "..\\..\\..\\..\\..\\..\\..\\..\\Drivers\\BSP\\X-NUCLEO-IHMxx\\x_nucleo_ihmxx.c" -mcpu=cortex-m4 -std=gnu11 -g3 -DUSE_HAL_DRIVER -DSTM32F401xE -DUSE_STM32F4XX_NUCLEO -DNUCLEO_F401RE -DSTM32F401RETx -DSTM32 -DSTM32F4 -DDEBUG -c -I../../../Inc -I../../../../../../../../Drivers/BSP/STM32F4xx-Nucleo -I../../../../../../../../Drivers/BSP/X-NUCLEO-IHMxx -I../../../../../../../../Drivers/BSP/Components/Common -I../../../../../../../../Drivers/BSP/Components/l6474 -I../../../../../../../../Drivers/CMSIS/Include -I../../../../../../../../Drivers/CMSIS/Device/ST/STM32F4xx/Include -I../../../../../../../../Drivers/STM32F4xx_HAL_Driver/Inc -O0 -ffunction-sections -Wall -fstack-usage -mfpu=fpv4-sp-d16 -mfloat-abi=hard -mthumb -o "Drivers\\BSP\\X-NUCLEO-IHMxx\\x_nucleo_ihmxx.o"
Cannot run program "arm-none-eabi-gcc": The directory name is invalid.

and using external builder: 
5:00:36 **** Incremental Build of configuration Debug for project STM32F401RE-Nucleo ****
make all

15:46:32 **** Build of configuration Debug for project STM32F401RE-Nucleo ****

make all

Cannot run program "make": Code 0x10b: The directory name is invalid.

I don't know how to tackle this problem. Can someone help me with regards to this issue?

1 ACCEPTED SOLUTION

Accepted Solutions

Hi Pavel and Semer,

After a lot of debugging and trying to figure out why my project wasnt building .I built  a simple to project and realised it has nothing to do with the builder being used or the toolchain. It was actually funny. I realised it might be a path issue. Basically, some of the files that it was trying to build had a path that was very lengthy, so i reduced the folders name length and voila it worked. So luckily i was able to find my own solution. Thanks for all  the help @Pavel A. and @Semer CHERNI.

View solution in original post

12 REPLIES 12
Pavel A.
Evangelist III

Well, both internal and external builders fail with  same error, so this is objective. Check in the project (or workspace) properties which  toolchain is used. Is an old toolchain selected, which is no longer installed? If so, install this older toolchain (preferred) or try to jump ahead and choose a toolchain that is available.

Try to reinstall CubeIDE (again, the same version that you've used then, is preferred).

 

 

I'm still getting the same problem after trying that. The thing is the project is not mine so i don't know which version ide was used back then when it was made.

Pavel A.
Evangelist III

Can you post a screenshot of the toolchain selection in your project?

PavelA_0-1705247447304.png

PavelA_1-1705247491317.png

 

 

 

 

Semer CHERNI
ST Employee

Hello @aelgammal 

First let me thank you for posting.

Could you try to make the build using the "GNU Tools for STM32(11.3.rev1) toolchain.

KR,
Semer.

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

Hi @Semer CHERNI 

Thank you for the reply. I  tried that and still getting the same issue.

Regards,

Amro

Pavel A.
Evangelist III

Still get "Cannot run program "arm-none-eabi-gcc": The directory name is invalid" ?

Have you imported this SW4STM project into CubeIDE?

 

yup same exact issue for both internal and external builder

Pavel A.
Evangelist III

The message means that the builder cannot find the gcc compiler. Either CubeIDE setup is broken or the project is broken too badly. Maybe the author of that github project would be able to port his work from SW4STM to CubeIDE - try motivate them?