Julian Hall | 4834e63 | 2021-05-26 15:33:06 +0100 | [diff] [blame] | 1 | #------------------------------------------------------------------------------- |
Balint Dobszay | 047aea8 | 2022-05-16 14:20:53 +0200 | [diff] [blame] | 2 | # Copyright (c) 2021-2022, Arm Limited and Contributors. All rights reserved. |
Julian Hall | 4834e63 | 2021-05-26 15:33:06 +0100 | [diff] [blame] | 3 | # |
| 4 | # SPDX-License-Identifier: BSD-3-Clause |
| 5 | # |
| 6 | #------------------------------------------------------------------------------- |
Balint Dobszay | 047aea8 | 2022-05-16 14:20:53 +0200 | [diff] [blame] | 7 | cmake_minimum_required(VERSION 3.18 FATAL_ERROR) |
Julian Hall | 4834e63 | 2021-05-26 15:33:06 +0100 | [diff] [blame] | 8 | include(../../deployment.cmake REQUIRED) |
| 9 | |
| 10 | #------------------------------------------------------------------------------- |
| 11 | # Required for use of stdout/stderr file pointers from the application. |
| 12 | # |
| 13 | #------------------------------------------------------------------------------- |
| 14 | set(CMAKE_POSITION_INDEPENDENT_CODE True) |
| 15 | |
| 16 | #------------------------------------------------------------------------------- |
| 17 | # The CMakeLists.txt for building the platform-inspect deployment for arm-linux |
| 18 | # |
| 19 | #------------------------------------------------------------------------------- |
| 20 | include(${TS_ROOT}/environments/arm-linux/env.cmake) |
| 21 | project(trusted-services LANGUAGES CXX C) |
| 22 | add_executable(platform-inspect) |
| 23 | target_include_directories(platform-inspect PRIVATE "${TOP_LEVEL_INCLUDE_DIRS}") |
| 24 | |
| 25 | #------------------------------------------------------------------------------- |
| 26 | # Extend with components that are common across all deployments of |
| 27 | # platform-inspect |
| 28 | # |
| 29 | #------------------------------------------------------------------------------- |
| 30 | include(../platform-inspect.cmake REQUIRED) |
| 31 | |
| 32 | #------------------------------------------------------------------------------- |
| 33 | # Define library options and dependencies. |
| 34 | # |
| 35 | #------------------------------------------------------------------------------- |
| 36 | env_set_link_options(TGT platform-inspect) |
| 37 | target_link_libraries(platform-inspect PRIVATE stdc++ gcc m) |
| 38 | |
| 39 | #------------------------------------------------------------------------------- |
| 40 | # Linker option to enable repeated searches for undefined references. |
| 41 | # Required to resolve dependencies between t_cose and qcbor libraries. |
| 42 | #------------------------------------------------------------------------------- |
| 43 | target_link_options(platform-inspect PRIVATE |
| 44 | -Wl,--start-group |
| 45 | ) |