Ken Liu | e40f9a2 | 2019-06-03 16:42:47 +0800 | [diff] [blame] | 1 | #------------------------------------------------------------------------------- |
Gabor Abonyi | de5e8db | 2020-03-05 13:14:22 +0100 | [diff] [blame] | 2 | # Copyright (c) 2019-2020, Arm Limited. All rights reserved. |
Ken Liu | e40f9a2 | 2019-06-03 16:42:47 +0800 | [diff] [blame] | 3 | # |
| 4 | # SPDX-License-Identifier: BSD-3-Clause |
| 5 | # |
| 6 | #------------------------------------------------------------------------------- |
| 7 | |
| 8 | #This file holds information of a specific build configuration of this project. |
| 9 | |
| 10 | if(NOT DEFINED TFM_ROOT_DIR) |
| 11 | message(FATAL_ERROR "Variable TFM_ROOT_DIR is not set!") |
| 12 | endif() |
| 13 | |
| 14 | #Include board specific config (CPU, etc...), select platform specific build |
| 15 | #system settings file |
| 16 | if(NOT DEFINED TARGET_PLATFORM) |
| 17 | message(FATAL_ERROR "ERROR: TARGET_PLATFORM is not set in command line") |
| 18 | elseif(${TARGET_PLATFORM} STREQUAL "AN521") |
| 19 | set(PLATFORM_CMAKE_FILE "${TFM_ROOT_DIR}/platform/ext/Mps2AN521.cmake") |
| 20 | elseif(${TARGET_PLATFORM} STREQUAL "AN519") |
| 21 | set(PLATFORM_CMAKE_FILE "${TFM_ROOT_DIR}/platform/ext/Mps2AN519.cmake") |
Gabor Abonyi | de5e8db | 2020-03-05 13:14:22 +0100 | [diff] [blame] | 22 | elseif(${TARGET_PLATFORM} STREQUAL "AN539") |
| 23 | set(PLATFORM_CMAKE_FILE "${TFM_ROOT_DIR}/platform/ext/Mps2AN539.cmake") |
Ken Liu | e40f9a2 | 2019-06-03 16:42:47 +0800 | [diff] [blame] | 24 | elseif(${TARGET_PLATFORM} STREQUAL "MUSCA_A") |
| 25 | set(PLATFORM_CMAKE_FILE "${TFM_ROOT_DIR}/platform/ext/musca_a.cmake") |
| 26 | elseif(${TARGET_PLATFORM} STREQUAL "MUSCA_B1") |
| 27 | set(PLATFORM_CMAKE_FILE "${TFM_ROOT_DIR}/platform/ext/musca_b1.cmake") |
Gabor Abonyi | de5e8db | 2020-03-05 13:14:22 +0100 | [diff] [blame] | 28 | elseif(${TARGET_PLATFORM} STREQUAL "MUSCA_S1") |
| 29 | set(PLATFORM_CMAKE_FILE "${TFM_ROOT_DIR}/platform/ext/musca_s1.cmake") |
Tamas Kaman | 80f1729 | 2019-07-30 17:12:11 +0200 | [diff] [blame] | 30 | elseif(${TARGET_PLATFORM} STREQUAL "AN524") |
| 31 | set(PLATFORM_CMAKE_FILE "${TFM_ROOT_DIR}/platform/ext/Mps3AN524.cmake") |
Ken Liu | e40f9a2 | 2019-06-03 16:42:47 +0800 | [diff] [blame] | 32 | else() |
| 33 | message(FATAL_ERROR "ERROR: Target \"${TARGET_PLATFORM}\" is not supported.") |
| 34 | endif() |
| 35 | |
| 36 | #These variables select how the projects are built. Each project will set |
| 37 | #various project specific settings (e.g. what files to build, macro |
| 38 | #definitions) based on these. |
| 39 | set (REGRESSION False) |
| 40 | set (CORE_TEST False) |
| 41 | set (CORE_IPC False) |
| 42 | set (PSA_API_TEST True) |
| 43 | |
Edison Ai | cb0ecf6 | 2019-07-10 18:43:51 +0800 | [diff] [blame] | 44 | #TF-M isolation level: 1 |
Ken Liu | e40f9a2 | 2019-06-03 16:42:47 +0800 | [diff] [blame] | 45 | set (TFM_LVL 1) |
| 46 | |
| 47 | #Service specific configuration for the PSA API Compliance test requirements |
| 48 | if(PSA_API_TEST_CRYPTO) |
| 49 | set(CRYPTO_ENGINE_BUF_SIZE 20480) |
| 50 | endif() |
| 51 | |
| 52 | include ("${TFM_ROOT_DIR}/CommonConfig.cmake") |