cancel
Showing results for 
Search instead for 
Did you mean: 

Application/User/Core/main.d:1: *** multiple target patterns. Stop.

vishnu_illikkal
Associate III

Why is this error very hard to find?
I cannot find the exact reason this is happening?
I have project say named Project_1 that works properly (This is created using TouchGFX on STM32H735G- DK board)

now if i copy this project manually and paste it in another dir and open that in Stm32cubeide and try building
building works once for second time the error occurs

I also tried copying my project codes after crteating a new project using touchgfx instead of just copying existing project
still same error

Note that i have my own files in separate folders that i added in all the projects

after cleaning the project - 1st time build ok - 2nd time same error

I also tried copy pasting the main.d file from my Project_1 into the new project but same error


STM32CubeIDE

Version: 1.16.0

Build: 21983_20240628_1741 (UTC)

 


STM32CubeMX - STM32 Device Configuration Tool

Version: 6.12.0-RC9

Build: 20240628-1431 (UTC)

 

1 ACCEPTED SOLUTION

Accepted Solutions
vishnu_illikkal
Associate III

I found the Cause for the  `Application/User/Core/main.d:1: *** multiple target patterns. Stop.` error.
It was because of multiple inclusions of the header files.
I was including all the needed header files for the c files inside its h file this caused the error when the project grew.
Now i changed it into the source files so now the error is gone.

View solution in original post

2 REPLIES 2
Pavel A.
Evangelist III

* Check if path contains spaces or weird characters

* Delete all *.d files in pre-build step ?

vishnu_illikkal
Associate III

I found the Cause for the  `Application/User/Core/main.d:1: *** multiple target patterns. Stop.` error.
It was because of multiple inclusions of the header files.
I was including all the needed header files for the c files inside its h file this caused the error when the project grew.
Now i changed it into the source files so now the error is gone.