From 2d3fbfc3d24fda7750696d8458d3fbcedfb6a139 Mon Sep 17 00:00:00 2001 From: Arturo Buzarra Date: Thu, 16 Apr 2020 11:29:44 +0200 Subject: [PATCH] zeus migration: opencv: Fix warning applying this patch https://jira.digi.com/browse/DEL-7013 Signed-off-by: Arturo Buzarra --- .../recipes-support/opencv/opencv/download.patch | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/meta-digi-dey/recipes-support/opencv/opencv/download.patch b/meta-digi-dey/recipes-support/opencv/opencv/download.patch index 800839338..938d5ee1b 100644 --- a/meta-digi-dey/recipes-support/opencv/opencv/download.patch +++ b/meta-digi-dey/recipes-support/opencv/opencv/download.patch @@ -1,10 +1,15 @@ -This CMake module will download files during do_configure. This is bad as it -means we can't do offline builds. +From: Arturo Buzarra +Date: Thu, 16 Apr 2020 09:15:06 +0200 +Subject: [PATCH] This CMake module will download files during do_configure. + This is bad as it means we can't do offline builds. Add an option to disallow downloads by emitting a fatal error. Upstream-Status: Pending Signed-off-by: Ross Burton +--- + cmake/OpenCVDownload.cmake | 6 ++++++ + 1 file changed, 6 insertions(+) diff --git a/cmake/OpenCVDownload.cmake b/cmake/OpenCVDownload.cmake index 63cf6d3238..4acf477f70 100644 @@ -13,13 +18,13 @@ index 63cf6d3238..4acf477f70 100644 @@ -14,6 +14,7 @@ # RELATIVE_URL - if set, then URL is treated as a base, and FILENAME will be appended to it # Note: uses OPENCV_DOWNLOAD_PATH folder as cache, default is /.cache - + +set(OPENCV_ALLOW_DOWNLOADS ON CACHE BOOL "Allow downloads") set(HELP_OPENCV_DOWNLOAD_PATH "Cache directory for downloaded files") if(DEFINED ENV{OPENCV_DOWNLOAD_PATH}) set(OPENCV_DOWNLOAD_PATH "$ENV{OPENCV_DOWNLOAD_PATH}" CACHE PATH "${HELP_OPENCV_DOWNLOAD_PATH}") @@ -156,6 +157,11 @@ function(ocv_download) - + # Download if(NOT EXISTS "${CACHE_CANDIDATE}") + if(NOT OPENCV_ALLOW_DOWNLOADS)