nxp-mcuxpresso / mcux-sdk

MCUXpresso SDK
BSD 3-Clause "New" or "Revised" License
301 stars 136 forks source link

[BUG] CONFIG_USE_middleware_freertos-kernel requires *-kernel_template and *-kernel_extension #185

Open stefanct opened 3 months ago

stefanct commented 3 months ago

Describe the bug

The SDK's FreeRTOS setup requires CONFIG_USE_middleware_freertos-kernel_template and CONFIG_USE_middleware_freertos-kernel_extension to be set if CONFIG_USE_middleware_freertos-kernel is to be used (i.e., whenever FreeRTOS is selected).

The respective test is here and produces the typical "middleware_freertos-kernel dependency does not meet, please check..." message here.

I don't see a reason for this check at all... I noticed it because the template adds its own FreeRTOSConfig.h which in my case had precedence over my own config due to the order of include directories. This led to unwanted behavior.

To Reproduce

Should be rather obvious from the code but please ask if not! This is with the source code from MCUX SDK 2.15.0.

Expected behavior

The extension and template should not be required by the base kernel (but the other way around only - which is not explicitly checked AFAICT, which is another bug hidden by this one).

Additional context

I simply deleted the whole check at line 47 and the corresponding else clause if no obvious ill intent.

MichalPrincNXP commented 2 months ago

Hello @stefanct , thanks for your report, it deals with known limitation. Extension and template is forced to be added into the project because we wanted