Skip to main content
Associate II
August 11, 2026
Question

ABI conflict between X-CUBE-AI runtime and STM32H7 Safety STL with ArmClang

  • August 11, 2026
  • 1 reply
  • 26 views

I am integrating X-CUBE-AI and the STM32H7 Safety STL into the same STM32H743 Keil/ArmClang project.

The X-CUBE-AI Keil runtime requires short enums and 16-bit wchar_t (-fshort-enums -fshort-wchar). However, the Safety STL library appears to require full-size enums and 32-bit wchar_t.

Configuring the project for X-CUBE-AI causes the Safety STL library to fail linking. Configuring it for the Safety STL causes Arm linker ABI errors when linking the X-CUBE-AI runtime, including enum-size and wchar_t mismatches.

Is there an officially supported compiler configuration or compatible library variant that allows X-CUBE-AI and the STM32H7 Safety STL to coexist in the same ArmClang application?

1 reply

cartergray733
Explorer
August 11, 2026

This looks like an ABI mismatch rather than a linker configuration issue. Armclang requires the same wchar_t size across linked objects, so the safest route is to use an STL library variant built for X-CUBE-AI’s -fshort-enums -fshort-wchar settings. If ST doesn’t provide that variant, the two libraries cannot safely coexist with conflicting ABI settings; I’d confirm the supported combination with ST.