cancel
Showing results for 
Search instead for 
Did you mean: 

cpu_PARAMS in CMakeLists.txt misleading

KnarfB
Super User

Hi, 

the current STM32CubeIDE for Visual Studio Code 3.6.4. (and maybe before) "Create empty project" generates in CMakeLists.txt 

# Core MCU flags, CPU type, instruction set and FPU setup
set(cpu_PARAMS 
    # Other parameters
    # -mthumb
    # -mcpu, -mfloat, -mfloat-abi, ...
)

The comments are misleading, because in cmake\vscode_generated.cmake:

set(cpu_PARAMS ${cpu_PARAMS} ${CPU_FLAGS})

and therefore, my cpu_PARAMS will be combined with the CPU_FLAGS which already include -mcpu etc.

which effectively overwrites my settings.

hth

KnarfB

0 REPLIES 0