1# SPDX-License-Identifier: Apache-2.0
2
3# The purpose of this script is to ensure that no runners targets contains
4# additional dependencies.
5#
6# If the target contains dependencies, an error will be printed.
7#
8# Arguments to the script
9#
10# TARGET:       The target being checked.
11# DEPENDENCIES: List containing dependencies on target.
12
13if(DEPENDENCIES)
14  string(REPLACE ";" " " DEPENDENCIES "${DEPENDENCIES}")
15  message(FATAL_ERROR
16          "`${TARGET}` cannot have dependencies, please remove "
17          "`add_dependencies(${TARGET} ${DEPENDENCIES})` in build system."
18  )
19endif()
20