Skip to main content
Graduate
May 31, 2025
Solved

cmake with stm32_lock.h

  • May 31, 2025
  • 2 replies
  • 512 views

I am generating my cmake project with STM32MX and are using FreeRTOS os.

I have the advance option set to generate the reentrant protection files stm32_lock.h and newlib_lock_glue.c.

These are indeed being generated and included in the root project folder.

I do not see them included in the CMakeLists.txt though so I assume, while included, they are not being built.

The app note that describes the reentrant issue does not cover the cmake build option.

Does the CmakeLists.txt file need to be manually modified to add newlib_lock_glue.c and the stm32_lock.h path?  

 

    This topic has been closed for replies.
    Best answer by Pavel A.

    Here you're in a kind of gray zone. You can integrate these files in your project in various ways, either literally or just use them for inspiration. Depending on how you do it, adjust your cmakelists.txt accordingly.

     

     

    2 replies

    Pavel A.Answer
    Super User
    May 31, 2025

    Here you're in a kind of gray zone. You can integrate these files in your project in various ways, either literally or just use them for inspiration. Depending on how you do it, adjust your cmakelists.txt accordingly.

     

     

    dvescoviAuthor
    Graduate
    June 1, 2025

    got it