Gyorgy Szing | 4909180 | 2020-11-24 00:33:09 +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 | |
| 8 | foreach(_var IN ITEMS EXPORT_SP_NAME EXPORT_SP_UUID) |
| 9 | if(NOT DEFINED ${_var}) |
| 10 | message(FATAL_ERROR |
| 11 | "Input variable ${_var} is undefined! Please define it" |
| 12 | "using set(${_var} ...) before including this file.") |
| 13 | endif() |
| 14 | endforeach() |
| 15 | |
| 16 | configure_file(${CMAKE_CURRENT_LIST_DIR}/sp.mk.in ${CMAKE_CURRENT_BINARY_DIR}/${EXPORT_SP_NAME}.mk @ONLY NEWLINE_STYLE UNIX) |
| 17 | install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${EXPORT_SP_NAME}.mk DESTINATION lib/make) |
| 18 | |
| 19 | unset(EXPORT_SP_NAME) |
| 20 | unset(EXPORT_SP_UUID) |