Files
compute-runtime/scripts/lint/CMakeLists.txt
Artur Harasimiuk 803a946e3f cmake: add lint target
This wraps around commands used to format code and exposes them as
single build system target: 'lint'.

Change-Id: Ide88b8f080582221b1832be06fd2fd0f2cd44ab4
Signed-off-by: Artur Harasimiuk <artur.harasimiuk@intel.com>
2018-09-19 16:14:31 +02:00

26 lines
650 B
CMake

#
# Copyright (C) 2018 Intel Corporation
#
# SPDX-License-Identifier: MIT
#
if(IS_DIRECTORY ${IGDRCL_SOURCE_DIR}/.git)
add_custom_target(lint
${IGDRCL_SOURCE_DIR}/scripts/lint${BRANCH_DIR_SUFFIX}/set_copyright.sh
WORKING_DIRECTORY ${IGDRCL_SOURCE_DIR}
)
set_target_properties(lint PROPERTIES
EXCLUDE_FROM_DEFAULT_BUILD TRUE
EXCLUDE_FROM_ALL TRUE
)
add_custom_target(lint_head
${IGDRCL_SOURCE_DIR}/scripts/lint${BRANCH_DIR_SUFFIX}/set_copyright.sh HEAD
WORKING_DIRECTORY ${IGDRCL_SOURCE_DIR}
)
set_target_properties(lint_head PROPERTIES
EXCLUDE_FROM_DEFAULT_BUILD TRUE
EXCLUDE_FROM_ALL TRUE
)
endif()