Gyorgy Szing | 386433f | 2023-03-31 12:52:25 +0000 | [diff] [blame^] | 1 | #------------------------------------------------------------------------------- |
| 2 | # Copyright (c) 2023, Arm Limited and Contributors. All rights reserved. |
| 3 | # |
| 4 | # SPDX-License-Identifier: BSD-3-Clause |
| 5 | # |
| 6 | # Common components used for any deployment of the fwu service provider. |
| 7 | #------------------------------------------------------------------------------- |
| 8 | |
| 9 | if (NOT DEFINED TGT) |
| 10 | message(FATAL_ERROR "Mandatory parameter TGT is not defined.") |
| 11 | endif() |
| 12 | |
| 13 | #------------------------------------------------------------------------------- |
| 14 | # Components common to all deployments |
| 15 | # |
| 16 | #------------------------------------------------------------------------------- |
| 17 | add_components(TARGET ${TGT} |
| 18 | BASE_DIR ${TS_ROOT} |
| 19 | COMPONENTS |
| 20 | "components/app/fwu-tool" |
| 21 | "components/common/uuid" |
| 22 | "components/common/endian" |
| 23 | "components/media/disk/gpt_iterator" |
| 24 | "components/media/volume/index" |
| 25 | "components/service/common/include" |
| 26 | "components/service/fwu/agent" |
| 27 | "components/service/fwu/config" |
| 28 | "components/service/fwu/config/gpt" |
| 29 | "components/service/fwu/fw_store/banked" |
| 30 | "components/service/fwu/fw_store/banked/metadata_serializer/v1" |
| 31 | "components/service/fwu/fw_store/banked/metadata_serializer/v2" |
| 32 | "components/service/fwu/installer" |
| 33 | "components/service/fwu/installer/raw" |
| 34 | "components/service/fwu/installer/copy" |
| 35 | "components/service/fwu/installer/factory/default" |
| 36 | "components/service/fwu/inspector/direct" |
| 37 | ) |
| 38 | |
| 39 | ################################################################# |
| 40 | |
| 41 | target_include_directories(${TGT} PRIVATE |
| 42 | ${TS_ROOT} |
| 43 | ${TS_ROOT}/components |
| 44 | ) |
| 45 | |
| 46 | #------------------------------------------------------------------------------- |
| 47 | # Define install content. |
| 48 | # |
| 49 | #------------------------------------------------------------------------------- |
| 50 | if (CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) |
| 51 | set(CMAKE_INSTALL_PREFIX ${CMAKE_BINARY_DIR}/install CACHE PATH "location to install build output to." FORCE) |
| 52 | endif() |
| 53 | install(TARGETS ${TGT} |
| 54 | RUNTIME DESTINATION ${TS_ENV}/bin |
| 55 | PUBLIC_HEADER DESTINATION ${TS_ENV}/include) |