blob: 053041adaca1bcdc85d5cd1f067167d591c278be [file] [log] [blame]
Julian Hall1911a122021-12-06 15:20:12 +00001#-------------------------------------------------------------------------------
2# Copyright (c) 2021, Arm Limited and Contributors. All rights reserved.
3#
4# SPDX-License-Identifier: BSD-3-Clause
5#
6#-------------------------------------------------------------------------------
7cmake_minimum_required(VERSION 3.16)
8include(../../deployment.cmake REQUIRED)
9
10#-------------------------------------------------------------------------------
11# The CMakeLists.txt for building the uefi-test deployment for arm-linux
12#
13# Used for building and running service level tests from Linux user-space
14# on an Arm platform with real deployments of UEFI SMM services
15#-------------------------------------------------------------------------------
16include(${TS_ROOT}/environments/arm-linux/env.cmake)
17project(trusted-services LANGUAGES CXX C)
18add_executable(uefi-test)
19target_include_directories(uefi-test PRIVATE "${TOP_LEVEL_INCLUDE_DIRS}")
20
21add_components(
22 TARGET "uefi-test"
23 BASE_DIR ${TS_ROOT}
24 COMPONENTS
25 "components/app/test-runner"
26 )
27
28include(${TS_ROOT}/external/CppUTest/CppUTest.cmake)
29target_link_libraries(uefi-test PRIVATE CppUTest)
30
31#-------------------------------------------------------------------------------
32# Extend with components that are common across all deployments of
33# uefi-test
34#
35#-------------------------------------------------------------------------------
36include(../uefi-test.cmake REQUIRED)
37
38#-------------------------------------------------------------------------------
39# Define library options and dependencies.
40#
41#-------------------------------------------------------------------------------
42env_set_link_options(TGT uefi-test)
43target_link_libraries(uefi-test PRIVATE stdc++ gcc m)