Consuming FreeRTOS CMake results in errors for STM32f7xx

It seems that the compile options are not propagated to FreeRTOS files. Would you try using add_compile_options before add_subdirectory instead of target_compile_options? If that does not work, please share your code so that we can give it a try.