cancel
Showing results for 
Search instead for 
Did you mean: 

Makefile toolchain corrupts makefile

William1
Associate II

A blank project with the Makefile toolchain will cause the following issue

# C includes
C_INCLUDES =  \
-ICore/Inc \
-IDrivers/STM32F4xx_HAL_Driver/Inc \
-IDrivers/STM32F4xx_HAL_Driver/Inc/Legacy \
-IDrivers/CMSIS/Device/ST/STM32F4xx/Include \
-IDrivers/CMSIS/Include \
-IDrivers/CMSIS/Include

Notice the double include in the bottom. This is not initially harmful, but if you tell it to generate the project again, it modifies it slightly into this.

# C includes
C_INCLUDES =  \
-ICore/Inc \
-IDrivers/STM32F4xx_HAL_Driver/Inc \
-IDrivers/STM32F4xx_HAL_Driver/Inc/Legacy \
-IDrivers/CMSIS/Device/ST/STM32F4xx/Include \
-IDrivers/CMSIS/Include
-IDrivers/CMSIS/Include

Notice the missing backslash on line 7, which now means the makefile is invalid and wont run anymore.

Manually fixing the problem is possible, but is not viable for advanced setups with continuous integration.

  • Version: STM32CubeMX 6.0.1
  • Operating System: Windows 10
1 REPLY 1
Khouloud ZEMMELI
ST Employee

Hello @William​ ,

Thanks for your feedback, it will be internally checked.

Best Regards,

Khouloud