Build: Generalize build steps for various toolchains
Various toolchains have different behaviours and requirements in CMake
implementation.
Generalize several steps in build sequence in NS build, to conceal
differences between various toolchains.
- Accept TFM_TOOLCHAIN_FILE from command line as the existing build
system does. TFM_TOOLCHAIN_FILE conceals different setup steps in
toolchains.
- Call tfm_toolchain_reload_compiler() after project() to support
Armclang to setup compiler flags after project().
- Code of some build steps is moved from TF-M NS build example to
tests build. NS target names are hard-coded in those steps.
Remove those code from TF-M to avoid coupling NS and S again.
Signed-off-by: David Hu <david.hu@arm.com>
Change-Id: I1a2964ffed83e45f3d0aafce7ac4f4e9b553f3a6
3 files changed