diff --git a/ports/opencv3/0018-fix-depend-tesseract.patch b/ports/opencv3/0018-fix-depend-tesseract.patch new file mode 100644 index 0000000000..6a8bc7acd3 --- /dev/null +++ b/ports/opencv3/0018-fix-depend-tesseract.patch @@ -0,0 +1,11 @@ +--- a/modules/text/cmake/init.cmake ++++ b/modules/text/cmake/init.cmake +@@ -4,6 +4,8 @@ OCV_OPTION(WITH_TESSERACT "Include Tesseract OCR library support" (NOT CMAKE_CRO + if(NOT HAVE_TESSERACT + AND (WITH_TESSERACT OR OPENCV_FIND_TESSERACT) + ) ++ find_package(Tesseract CONFIG REQUIRED) ++ set(Tesseract_LIBRARIES Tesseract::libtesseract) + if(NOT Tesseract_FOUND) + find_package(Tesseract QUIET) # Prefer CMake's standard locations (including Tesseract_DIR) + endif() diff --git a/ports/opencv3/portfile.cmake b/ports/opencv3/portfile.cmake index 2567a072bf..568b1fb752 100644 --- a/ports/opencv3/portfile.cmake +++ b/ports/opencv3/portfile.cmake @@ -157,6 +157,7 @@ if("contrib" IN_LIST FEATURES) 0007-fix-hdf5.patch 0013-fix-ceres.patch 0016-fix-freetype-contrib.patch + 0018-fix-depend-tesseract.patch ) set(BUILD_WITH_CONTRIB_FLAG "-DOPENCV_EXTRA_MODULES_PATH=${CONTRIB_SOURCE_PATH}/modules") diff --git a/ports/opencv3/vcpkg.json b/ports/opencv3/vcpkg.json index a237deb535..b6787027ed 100644 --- a/ports/opencv3/vcpkg.json +++ b/ports/opencv3/vcpkg.json @@ -1,6 +1,7 @@ { "name": "opencv3", "version": "3.4.18", + "port-version": 1, "description": "Open Source Computer Vision Library", "homepage": "https://github.com/opencv/opencv", "license": "BSD-3-Clause", diff --git a/ports/opencv4/0018-fix-depend-tesseract.patch b/ports/opencv4/0018-fix-depend-tesseract.patch index 3f873bc59a..6a8bc7acd3 100644 --- a/ports/opencv4/0018-fix-depend-tesseract.patch +++ b/ports/opencv4/0018-fix-depend-tesseract.patch @@ -1,5 +1,3 @@ -diff --git a/modules/text/cmake/init.cmake b/modules/text/cmake/init.cmake -index 254757e..73194ec 100644 --- a/modules/text/cmake/init.cmake +++ b/modules/text/cmake/init.cmake @@ -4,6 +4,8 @@ OCV_OPTION(WITH_TESSERACT "Include Tesseract OCR library support" (NOT CMAKE_CRO diff --git a/ports/opencv4/vcpkg.json b/ports/opencv4/vcpkg.json index d42295f1eb..c77f11d7ea 100644 --- a/ports/opencv4/vcpkg.json +++ b/ports/opencv4/vcpkg.json @@ -1,7 +1,7 @@ { "name": "opencv4", "version": "4.6.0", - "port-version": 1, + "port-version": 2, "description": "computer vision library", "homepage": "https://github.com/opencv/opencv", "license": "Apache-2.0", diff --git a/ports/tesseract/fix-depend-libarchive.patch b/ports/tesseract/fix-depend-libarchive.patch index 1b57247126..5d510e16ec 100644 --- a/ports/tesseract/fix-depend-libarchive.patch +++ b/ports/tesseract/fix-depend-libarchive.patch @@ -1,5 +1,3 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index bd2649d..f932913 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -792,7 +792,8 @@ if(OpenCL_FOUND) diff --git a/ports/tesseract/portfile.cmake b/ports/tesseract/portfile.cmake index 3764e47ef0..a30d57a38a 100644 --- a/ports/tesseract/portfile.cmake +++ b/ports/tesseract/portfile.cmake @@ -51,6 +51,7 @@ vcpkg_cmake_config_fixup(CONFIG_PATH lib/cmake/tesseract) vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/share/tesseract/TesseractConfig.cmake" "find_dependency(Leptonica)" [[ +find_dependency(CURL) find_dependency(Leptonica) find_dependency(LibArchive) ]] diff --git a/ports/tesseract/vcpkg.json b/ports/tesseract/vcpkg.json index f62bc6cb20..04a1de7fb5 100644 --- a/ports/tesseract/vcpkg.json +++ b/ports/tesseract/vcpkg.json @@ -1,11 +1,13 @@ { "name": "tesseract", "version": "5.2.0", + "port-version": 1, "description": "An OCR Engine that was developed at HP Labs between 1985 and 1995... and now at Google.", "homepage": "https://github.com/tesseract-ocr/tesseract", "license": "Apache-2.0", "supports": "!(arm & (osx | linux))", "dependencies": [ + "curl", "leptonica", "libarchive", { diff --git a/versions/baseline.json b/versions/baseline.json index e99b3b622d..9342e60886 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -5202,11 +5202,11 @@ }, "opencv3": { "baseline": "3.4.18", - "port-version": 0 + "port-version": 1 }, "opencv4": { "baseline": "4.6.0", - "port-version": 1 + "port-version": 2 }, "opendnp3": { "baseline": "3.1.1", @@ -7046,7 +7046,7 @@ }, "tesseract": { "baseline": "5.2.0", - "port-version": 0 + "port-version": 1 }, "tfhe": { "baseline": "1.0.1", diff --git a/versions/o-/opencv3.json b/versions/o-/opencv3.json index b40aebe00a..7febef4608 100644 --- a/versions/o-/opencv3.json +++ b/versions/o-/opencv3.json @@ -1,5 +1,10 @@ { "versions": [ + { + "git-tree": "6f45f46b8a492b795cce92786a3d2048ef24ef38", + "version": "3.4.18", + "port-version": 1 + }, { "git-tree": "15c9083efa4c00674bef4fbca443a662fe6dd5cd", "version": "3.4.18", diff --git a/versions/o-/opencv4.json b/versions/o-/opencv4.json index a96d1fe034..59035e59c2 100644 --- a/versions/o-/opencv4.json +++ b/versions/o-/opencv4.json @@ -1,5 +1,10 @@ { "versions": [ + { + "git-tree": "57554ec83d4e4667344f005a1f61be8164cbf58a", + "version": "4.6.0", + "port-version": 2 + }, { "git-tree": "a6c9bded8fc4ad22bea6869caecf2881c8da2d41", "version": "4.6.0", diff --git a/versions/t-/tesseract.json b/versions/t-/tesseract.json index 1d7f6743ab..2d99c2416c 100644 --- a/versions/t-/tesseract.json +++ b/versions/t-/tesseract.json @@ -1,5 +1,10 @@ { "versions": [ + { + "git-tree": "ea93f36603ca265da43ef28d6583871ef3d97b43", + "version": "5.2.0", + "port-version": 1 + }, { "git-tree": "5ea8fcd243e8aa38e1a83eaa1c745fc53a3464cc", "version": "5.2.0",