6 years, 9 months ago.

Online Compiler JSON Errors

I have several important projects that are using an older version of mbed-rtos that still included mbed_lib.json, which unofficially enables thread safety on mbed-dev. This configuration has been working fine up until today, when the online compiler started throwing erroneous Target does not support mbed OS 5 errors when I try to compile. Removing mbed_lib.json fixes the error, but also removes thread safety... I realize this is a somewhat unsupported configuration, but can somebody please look into this? I can't afford to migrate to mbed OS 5, since I'm relying on the ARM Micro Toolchain.

1 Answer

6 years, 9 months ago.

Hi Neil,

looking at the source code, these lines are causing the error:

        resources = scan_resources(src_paths, toolchain, inc_dirs=inc_dirs)
        if  (hasattr(toolchain.target, "release_versions") and
             "5" not in toolchain.target.release_versions and
             "rtos" in toolchain.config.lib_config_data):
            if "Cortex-A" in toolchain.target.core:
                raise NotSupportedException(
                    ("%s Will be supported in mbed OS 5.6. "
                     "To use the %s, please checkout the mbed OS 5.4 release branch. "
                     "See https://developer.mbed.org/platforms/Renesas-GR-PEACH/#important-notice "
                     "for more information") % (toolchain.target.name, toolchain.target.name))
            else:
                raise NotSupportedException("Target does not support mbed OS 5")

You can see rtos in the config data with not having 5 in the release version is invoking the exception

Means your target is not properly configured. what target are you using?

I'm using the LPC11U35 and LPC1549.

posted by Neil Thiessen 20 Jul 2017

I managed to fix my issue by adding a custom mbed_lib.json file to my super-library, and manually defining the MBED_CONF_RTOS_PRESENT macro.

posted by Neil Thiessen 01 Aug 2017