Julian Hall | eff4b28 | 2020-11-23 18:24:12 +0100 | [diff] [blame^] | 1 | #------------------------------------------------------------------------------- |
| 2 | # Copyright (c) 2020, Arm Limited and Contributors. All rights reserved. |
| 3 | # |
| 4 | # SPDX-License-Identifier: BSD-3-Clause |
| 5 | # |
| 6 | #------------------------------------------------------------------------------- |
| 7 | cmake_minimum_required(VERSION 3.16) |
| 8 | include(../../deployment.cmake REQUIRED) |
| 9 | |
| 10 | #------------------------------------------------------------------------------- |
| 11 | # The CMakeLists.txt for building the component-test deployment for arm-linux |
| 12 | # |
| 13 | # Used for building and running component level tests as a Linux userspace |
| 14 | # program running on Arm. Tests can be run by running the built executable |
| 15 | # called "component-test" |
| 16 | #------------------------------------------------------------------------------- |
| 17 | include(${TS_ROOT}/environments/arm-linux/env.cmake) |
| 18 | project(trusted-services LANGUAGES CXX C) |
| 19 | add_executable(component-test) |
| 20 | target_include_directories(component-test PRIVATE "${TOP_LEVEL_INCLUDE_DIRS}") |
| 21 | |
| 22 | #------------------------------------------------------------------------------- |
| 23 | # Extend with components that are common across all deployments of |
| 24 | # component-test |
| 25 | # |
| 26 | #------------------------------------------------------------------------------- |
| 27 | include(../component-test.cmake REQUIRED) |
| 28 | |
| 29 | #------------------------------------------------------------------------------- |
| 30 | # Define library options and dependencies. |
| 31 | # |
| 32 | #------------------------------------------------------------------------------- |
| 33 | env_set_link_options(TGT component-test) |
| 34 | target_link_libraries(component-test PRIVATE stdc++ gcc m) |