2019-08-24 03:48:09 +08:00
|
|
|
diff --git a/cmake/OpenCVDownload.cmake b/cmake/OpenCVDownload.cmake
|
|
|
|
index cdc47ad..175aaf3 100644
|
2018-02-22 08:47:42 +08:00
|
|
|
--- a/cmake/OpenCVDownload.cmake
|
|
|
|
+++ b/cmake/OpenCVDownload.cmake
|
2019-08-24 03:48:09 +08:00
|
|
|
@@ -154,6 +154,8 @@ function(ocv_download)
|
2018-02-22 08:47:42 +08:00
|
|
|
# Download
|
|
|
|
if(NOT EXISTS "${CACHE_CANDIDATE}")
|
|
|
|
ocv_download_log("#cmake_download \"${CACHE_CANDIDATE}\" \"${DL_URL}\"")
|
|
|
|
+ string(REPLACE "${OPENCV_DOWNLOAD_PATH}/" "opencv-cache/" CACHE_SUBPATH "${CACHE_CANDIDATE}")
|
|
|
|
+ message(FATAL_ERROR " Downloads are not permitted during configure. Please pre-download the file \"${CACHE_CANDIDATE}\":\n \n vcpkg_download_distfile(OCV_DOWNLOAD\n URLS \"${DL_URL}\"\n FILENAME \"${CACHE_SUBPATH}\"\n SHA512 0\n )")
|
|
|
|
file(DOWNLOAD "${DL_URL}" "${CACHE_CANDIDATE}"
|
|
|
|
INACTIVITY_TIMEOUT 60
|
|
|
|
TIMEOUT 600
|