Open-CMSIS-Pack / devtools

Open-CMSIS-Pack development tools - C++
Apache License 2.0
72 stars 52 forks source link

Incorrect CMake log with AC6 ? #232

Closed fred-r closed 1 year ago

fred-r commented 2 years ago
frq09468@LMECWL0888 MINGW64 /c/Cube/stm32cube_fw_all/examples/hal/gpio/toggle/projects/gpio-toggle.AC6+B-U585I-IOT02A_IntDir/CMakeFiles (main)
$ cat
3.22.0/                             TargetDirectories.txt               gpio-toggle.AC6+B-U585I-IOT02A.dir/
CMakeOutput.log                     cmake.check_cache                   rules.ninja

frq09468@LMECWL0888 MINGW64 /c/Cube/stm32cube_fw_all/examples/hal/gpio/toggle/projects/gpio-toggle.AC6+B-U585I-IOT02A_IntDir/CMakeFiles (main)
$ cat CMakeOutput.log
The target system is: Generic -  - cortex-m0
The host system is: Windows - 10.0.19042 - AMD64

The target system is indicated as cortex-m0.

I specify this:

solution:
  target-types:
    - type: B-U585I-IOT02A
      board: B-U585I-IOT02A

And the packs state:

    <board vendor="STMicroelectronics" name="B-U585I-IOT02A" revision="Rev.C" salesContact="http://www.st.com/stonline/contactus/contacts/index.php">
      <description>STMicroelectronics B-U585I-IOT02A Evaluation Board Support and Examples</description>
      <book category="overview" name="http://www.st.com/en/evaluation-tools/B-U585I-IOT02A.html"      title="STM32H747I_EVAL Evaluation Board Web Page"/>
      <mountedDevice    deviceIndex="0" Dvendor="STMicroelectronics:13" Dname="STM32U585ZITx"/>
      <compatibleDevice deviceIndex="0" Dvendor="STMicroelectronics:13" DsubFamily="STM32U585"/>

and:

    <devices>
        <family Dfamily="STM32U5 Series" Dvendor="STMicroelectronics:13">
            <processor Dcore="Cortex-M33" DcoreVersion="r0p0" Dfpu="SP_FPU" Dmpu="MPU" Ddsp="DSP" Dtz="TZ" Dendian="Configurable" Dclock="10000000" />

So why is Cortex-M33 not indicated ?

brondani commented 2 years ago

This is the intended behaviour. In older CMake versions we could not rely on CMake flags for AC6 (armclang), see the issue 21173 and the policy CMP0123.

For this reason the CMAKE_SYSTEM_PROCESSOR is set to a fixed value.

With the introduction of the policy CMP0123 we plan to review the mechanism, but since it breaks backward compatibility - the generated CMakeLists will require minimum CMake 3.21 - this will be done after the Ubuntu jammy release that will bring CMake 3.22.1.

ReinhardKeil commented 1 year ago

Is this still open?

jkrech commented 1 year ago

@fred-r can you please check whether Daniel's response is addressing your concern?

ReinhardKeil commented 1 year ago

closing this issue as considered as fixed