cmake: fix CMake error

"install DIRECTORY does not allow "COMPONENT" after PATTERN or REGEX."
pull/7896/head
Alexander Alekhin 8 years ago
parent 07004a46ca
commit 35308bc45f
  1. 4
      cmake/OpenCVUtils.cmake

@ -1098,16 +1098,16 @@ endfunction()
macro(ocv_add_testdata basedir dest_subdir)
if(BUILD_TESTS)
cmake_parse_arguments(__TESTDATA "" "COMPONENT" "" ${ARGN})
if(NOT CMAKE_CROSSCOMPILING AND NOT INSTALL_TESTS)
file(COPY ${basedir}/
DESTINATION ${CMAKE_BINARY_DIR}/${OPENCV_TEST_DATA_INSTALL_PATH}/${dest_subdir}
${__TESTDATA_UNPARSED_ARGUMENTS}
${ARGN}
)
endif()
if(INSTALL_TESTS)
install(DIRECTORY ${basedir}/
DESTINATION ${OPENCV_TEST_DATA_INSTALL_PATH}/contrib/text
COMPONENT "tests"
${ARGN}
)
endif()

Loading…
Cancel
Save