Unfortunately the original fix doesn't hold for all targets in the online
compiler. I think this is because when we override target.c_lib with
target.default_lib, the default_lib isn't in the target.supported_c_libs
list. Removing the default_lib patch altogether seems to work in the
sense that compilation works. This may cause issues down the line if the
tools inadevertently swap out the user's selected c_lib with something
else. This is another problem we have to solve in a generic way which
supports all use cases we want for offline and online tools. At the
moment this is just a patch to get things working for mbed 6.
The online compiler requires mbed os 2 support. Now release_version has
been partially removed from the tools, we just need to return all targets
when any version is given. This doesn't really make sense, as now we just
claim to support all targets in all release_versions. However, it allows the
online compiler to find targets for mbed 2 projects, which we still need
to support online.
We need to come up with a mechanism for maintaining release_version
support in the online tools, this unfortunate patch is just to get
things working for the Mbed 6 release.
The online compiler mandates we maintain support for NRF51 targets in
the tools.
* Add NRF51 targets back into latest_targets.json.
* Reintroduce NRF51 post build hook.
TF-M and PSA have experimental APIs. Musca targets must initialize the
tfm_ns_lock, via the experimental API tfm_ns_lock_init(), as part of
their ordinary initialization procedure. Therefore, Musca targets must
have experimental APIs present in order to function. Add the
experimental API feature to Musca targets by default to ease usability
of the Musca targets, rather than requiring all users and CI to manually
enable experimental APIs when using these targets.
TF-M provides its own PSA headers for TF-M targets. Single v7-M targets
need to get PSA crypto from Mbed Crypto.
Note that we don't yet move crypto_struct.h to its new location. This is
to avoid breaking v8-M targets for the time being. When TF-M provides
the PSA implementation on v8-M, we will add crypto_struct.h to the
correct place.
Likewise, none of the PSA-implementing source is moved out of
COMPONENT_PSA_SRV_IMPL yet, as still must not be built for PSA NS
targets. When PSA NS targets switch to using TF-M provided
implementations rather than MBED_PSA_SRV, we can take the source out of
COMPONENT_PSA_SRV_IMPL.
Signed-off-by: Jaeden Amero <jaeden.amero@arm.com>
Make single Armv7-M PSA targets pick up files under TARGET_MBED_PSA_SRV.
We'll be moving the Mbed implementation of PSA to TARGET_MBED_PSA_SRV
folders soon.
Targets (dual-core and Armv8-M) that expect to use TF-M for their PSA
implementation also have MBED_PSA_SRV labels added to them so that they
continue working with the Mbed PSA implementation for the time being.
Give a warning rather than error if an unrecognised feature is used.
This will help compatibility when new features are added.
Signed-off-by: Darryl Green <darryl.green@arm.com>
For backwards compatibility reasons, since the latest Mbed OS tools must
be able to build any previous online-compiler-supported version of Mbed
OS, allow targets to use `default_lib` or `c_lib`. This should enable
the tools to work with Mbed OS 5 style targets.json.
For backwards compatibility reasons, as the Mbed tools must be able to
build any online-compiler-supported version of Mbed, revert back to
emitting a warning when ARMC5 is used. This will enable ARMC5 to
continue working in the online compiler for Mbed OS 5 and other previous
versions. ARMC5 remains unsupported in Mbed 6.
This reverts commit 03d57b7ba2.
Every target is assumed to supported Mbed OS. If its not the case, it supports
only baremetal. Thus removing rtos, and adding bare-metal to the app profile.
We cant afford to raise an exception now. As anyone using this out there do not catch it. Rather
an empty list, as it can work after this fix - won't do anything.
This is non trivial fix as the function is being used outside of this repository.
Tools rely on it to return list of targets for 2 or 5. As we removed release_version from many targets,
this broke the logic. To keep the logic as it was, without updating all tools out there now,
lets just return full set of targets - all are supported.
In case for Mbed 2, returning all targets does not make sense, but rather raise an exception here. Not supported. This avoids suprised. If you look at build api functions there are many checks for 2 or 5 so more
clean up needed to actually get release_version out of the tools.