Merge pull request #3530 from jet47:win-install-testdata
This commit is contained in:
commit
9c2ef369ed
@ -294,6 +294,16 @@ if(NOT OPENCV_TEST_INSTALL_PATH)
|
||||
set(OPENCV_TEST_INSTALL_PATH "${OPENCV_BIN_INSTALL_PATH}")
|
||||
endif()
|
||||
|
||||
if(OPENCV_TEST_DATA_PATH AND NOT OPENCV_TEST_DATA_INSTALL_PATH)
|
||||
if(ANDROID)
|
||||
set(OPENCV_TEST_DATA_INSTALL_PATH "sdk/etc/testdata")
|
||||
elseif(WIN32)
|
||||
set(OPENCV_TEST_DATA_INSTALL_PATH "testdata")
|
||||
else()
|
||||
set(OPENCV_TEST_DATA_INSTALL_PATH "share/OpenCV/testdata")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(ANDROID)
|
||||
set(LIBRARY_OUTPUT_PATH "${OpenCV_BINARY_DIR}/lib/${ANDROID_NDK_ABI_NAME}")
|
||||
set(3P_LIBRARY_OUTPUT_PATH "${OpenCV_BINARY_DIR}/3rdparty/lib/${ANDROID_NDK_ABI_NAME}")
|
||||
|
@ -10,13 +10,5 @@ elseif(NOT WIN32)
|
||||
endif()
|
||||
|
||||
if(INSTALL_TESTS AND OPENCV_TEST_DATA_PATH)
|
||||
if(ANDROID)
|
||||
install(DIRECTORY ${OPENCV_TEST_DATA_PATH} DESTINATION sdk/etc/testdata COMPONENT tests)
|
||||
elseif(NOT WIN32)
|
||||
# CPack does not set correct permissions by default, so we do it explicitly.
|
||||
install(DIRECTORY ${OPENCV_TEST_DATA_PATH}
|
||||
DIRECTORY_PERMISSIONS OWNER_WRITE OWNER_READ OWNER_EXECUTE
|
||||
GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE
|
||||
DESTINATION share/OpenCV/testdata COMPONENT tests)
|
||||
endif()
|
||||
install(DIRECTORY "${OPENCV_TEST_DATA_PATH}/" DESTINATION "${OPENCV_TEST_DATA_INSTALL_PATH}" COMPONENT "tests")
|
||||
endif()
|
Loading…
x
Reference in New Issue
Block a user