summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile8
-rw-r--r--docs/build-matrix.html2
-rw-r--r--docs/packages.json8
-rw-r--r--src/blas.mk4
-rw-r--r--src/libshout.mk2
-rw-r--r--src/libssh2.mk6
-rw-r--r--src/llvm.mk4
-rw-r--r--src/log4cxx.mk4
-rw-r--r--src/opencv-1-fixes.patch356
-rw-r--r--src/opencv-2-fixes-cmake.patch69
-rw-r--r--src/opencv-3-fixes-pkgconfig.patch156
-rw-r--r--src/opencv-4-reverse-deps-sublist.patch37
-rw-r--r--src/opencv-5-fix-in-bad-dir.patch65
-rw-r--r--src/opencv.mk17
-rw-r--r--src/pcre.mk2
-rw-r--r--src/pcre2.mk2
-rw-r--r--src/vtk.mk4
-rwxr-xr-xtools/build-pkg.lua38
18 files changed, 228 insertions, 556 deletions
diff --git a/Makefile b/Makefile
index 0f422f3..28b6806 100644
--- a/Makefile
+++ b/Makefile
@@ -17,7 +17,7 @@ MXE_TARGETS := i686-w64-mingw32.static
DEFAULT_MAX_JOBS := 6
SOURCEFORGE_MIRROR := downloads.sourceforge.net
-PKG_MIRROR := http://s3.amazonaws.com/mxe-pkg
+PKG_MIRROR := https://s3.amazonaws.com/mxe-pkg
PKG_CDN := http://d1yihgixbnrglp.cloudfront.net
GITLAB_BACKUP := http://gitlab.com/starius/mxe-backup2/raw/master/
@@ -267,9 +267,9 @@ ESCAPE_PKG = \
BACKUP_DOWNLOAD = \
(echo "MXE Warning! Downloading $(1) from backup." >&2 && \
- ($(WGET) --no-check-certificate -O '$(PKG_DIR)/.tmp-$($(1)_FILE)' $(PKG_MIRROR)/`$(call ESCAPE_PKG,$(1))` || \
- $(WGET) --no-check-certificate -O '$(PKG_DIR)/.tmp-$($(1)_FILE)' $(PKG_CDN)/`$(call ESCAPE_PKG,$(1))` || \
- $(WGET) --no-check-certificate -O '$(PKG_DIR)/.tmp-$($(1)_FILE)' $(GITLAB_BACKUP)/`$(call ESCAPE_PKG,$(1))`_$($(1)_CHECKSUM)))
+ ($(WGET) -O '$(PKG_DIR)/.tmp-$($(1)_FILE)' $(PKG_MIRROR)/`$(call ESCAPE_PKG,$(1))` || \
+ $(WGET) -O '$(PKG_DIR)/.tmp-$($(1)_FILE)' $(PKG_CDN)/`$(call ESCAPE_PKG,$(1))` || \
+ $(WGET) -O '$(PKG_DIR)/.tmp-$($(1)_FILE)' $(GITLAB_BACKUP)/`$(call ESCAPE_PKG,$(1))`_$($(1)_CHECKSUM)))
DOWNLOAD_PKG_ARCHIVE = \
$(if $($(1)_SOURCE_TREE),\
diff --git a/docs/build-matrix.html b/docs/build-matrix.html
index a9a56f0..b845ad3 100644
--- a/docs/build-matrix.html
+++ b/docs/build-matrix.html
@@ -2839,7 +2839,7 @@ feel free to submit a pull request.
<tr>
<th class="row">opencv</th>
- <td>2.4.10</td>
+ <td>3.3.0</td>
<td class="supported">&#x2713;</td>
<td class="supported">&#x2713;</td>
<td class="supported">&#x2713;</td>
diff --git a/docs/packages.json b/docs/packages.json
index d835d39..0ede679 100644
--- a/docs/packages.json
+++ b/docs/packages.json
@@ -220,7 +220,7 @@
"libsodium": {"version": "1.0.6", "website": "https://download.libsodium.org/doc/", "description": ""},
"libsoup": {"version": "2.57.1", "website": "https://github.com/GNOME/libsoup", "description": "HTTP client/server library for GNOME"},
"libspectre": {"version": "0.2.8", "website": "https://libspectre.freedesktop.org/", "description": ""},
- "libssh2": {"version": "1.8.0", "website": "https://www.libssh2.org/", "description": ""},
+ "libssh2": {"version": "1.8.0", "website": "https://libssh2.org/", "description": ""},
"libsvm": {"version": "3.22", "website": "https://www.csie.ntu.edu.tw/~cjlin/libsvm", "description": ""},
"libtool": {"version": "2.4.4", "website": "https://www.gnu.org/software/libtool/", "description": "GNU Libtool"},
"libtorrent-rasterbar": {"version": "1.1.0", "website": "http://www.rasterbar.com/products/libtorrent/", "description": ""},
@@ -279,7 +279,7 @@
"openblas": {"version": "0.2.15", "website": "http://www.openblas.net/", "description": "OpenBLAS"},
"opencore-amr": {"version": "0.1.3", "website": "https://opencore-amr.sourceforge.io/", "description": ""},
"opencsg": {"version": "1.4.1", "website": "http://www.opencsg.org/", "description": ""},
- "opencv": {"version": "2.4.10", "website": "http://opencv.org/", "description": "OpenCV"},
+ "opencv": {"version": "3.3.0", "website": "http://opencv.org/", "description": "OpenCV"},
"openexr": {"version": "2.2.0", "website": "http://www.openexr.com/", "description": "OpenEXR"},
"openjpeg": {"version": "2.2.0", "website": "http://www.openjpeg.org/", "description": "OpenJPEG"},
"openmp-validation": {"version": "3.1", "website": "https://github.com/uhhpctools/omp-validation", "description": "OpenMP Validation Suite"},
@@ -292,8 +292,8 @@
"pango": {"version": "1.37.4", "website": "http://www.pango.org/", "description": "Pango"},
"pangomm": {"version": "2.34.0", "website": "http://www.pango.org/", "description": "Pangomm"},
"pcl": {"version": "1.8.0", "website": "http://www.pointclouds.org/", "description": "PCL (Point Cloud Library)"},
- "pcre": {"version": "8.41", "website": "http://www.pcre.org/", "description": "PCRE"},
- "pcre2": {"version": "10.30", "website": "http://www.pcre.org/", "description": "PCRE2"},
+ "pcre": {"version": "8.41", "website": "https://www.pcre.org/", "description": "PCRE"},
+ "pcre2": {"version": "10.30", "website": "https://www.pcre.org/", "description": "PCRE2"},
"pdcurses": {"version": "3.4", "website": "https://pdcurses.sourceforge.io/", "description": "PDcurses"},
"pdflib_lite": {"version": "7.0.5p3", "website": "https://www.pdflib.com/download/free-software/pdflib-lite-7/", "description": "PDFlib Lite"},
"pfstools": {"version": "2.0.4", "website": "https://pfstools.sourceforge.io/", "description": ""},
diff --git a/src/blas.mk b/src/blas.mk
index 89834bd..c379bdf 100644
--- a/src/blas.mk
+++ b/src/blas.mk
@@ -6,8 +6,8 @@ $(PKG)_IGNORE :=
$(PKG)_VERSION := 3.5.0
$(PKG)_CHECKSUM := ef7d775d380f255d1902bce374ff7c8a594846454fcaeae552292168af1aca24
$(PKG)_SUBDIR := BLAS-$($(PKG)_VERSION)
-$(PKG)_FILE := $(PKG).tgz
-$(PKG)_URL := http://www.netlib.org/404
+$(PKG)_FILE := $(PKG)-$($(PKG)_VERSION).tgz
+$(PKG)_URL := http://www.netlib.org/$(PKG)/$($(PKG)_FILE)
$(PKG)_DEPS := gcc
define $(PKG)_UPDATE
diff --git a/src/libshout.mk b/src/libshout.mk
index 7afbbce..6e598a2 100644
--- a/src/libshout.mk
+++ b/src/libshout.mk
@@ -7,7 +7,7 @@ $(PKG)_VERSION := 2.4.1
$(PKG)_CHECKSUM := f3acb8dec26f2dbf6df778888e0e429a4ce9378a9d461b02a7ccbf2991bbf24d
$(PKG)_SUBDIR := $(PKG)-$($(PKG)_VERSION)
$(PKG)_FILE := $(PKG)-$($(PKG)_VERSION).tar.gz
-$(PKG)_URL := https://downloads.us.xiph.org/releases/$(PKG)/$($(PKG)_FILE)
+$(PKG)_URL := https://downloads.xiph.org/releases/$(PKG)/$($(PKG)_FILE)
$(PKG)_DEPS := gcc ogg openssl speex theora vorbis
define $(PKG)_UPDATE
diff --git a/src/libssh2.mk b/src/libssh2.mk
index d827de0..43fa67b 100644
--- a/src/libssh2.mk
+++ b/src/libssh2.mk
@@ -1,17 +1,17 @@
# This file is part of MXE. See LICENSE.md for licensing information.
PKG := libssh2
-$(PKG)_WEBSITE := https://www.libssh2.org/
+$(PKG)_WEBSITE := https://libssh2.org/
$(PKG)_IGNORE :=
$(PKG)_VERSION := 1.8.0
$(PKG)_CHECKSUM := 39f34e2f6835f4b992cafe8625073a88e5a28ba78f83e8099610a7b3af4676d4
$(PKG)_SUBDIR := libssh2-$($(PKG)_VERSION)
$(PKG)_FILE := libssh2-$($(PKG)_VERSION).tar.gz
-$(PKG)_URL := https://www.libssh2.org/download/$($(PKG)_FILE)
+$(PKG)_URL := https://libssh2.org/download/$($(PKG)_FILE)
$(PKG)_DEPS := gcc libgcrypt zlib
define $(PKG)_UPDATE
- $(WGET) -q -O- 'https://www.libssh2.org/download/?C=M;O=D' | \
+ $(WGET) -q -O- 'https://libssh2.org/download/?C=M;O=D' | \
grep 'libssh2-' | \
$(SED) -n 's,.*libssh2-\([0-9][^>]*\)\.tar.*,\1,p' | \
head -1
diff --git a/src/llvm.mk b/src/llvm.mk
index c00d0ad..d4dec26 100644
--- a/src/llvm.mk
+++ b/src/llvm.mk
@@ -7,11 +7,11 @@ $(PKG)_VERSION := 3.4
$(PKG)_CHECKSUM := 25a5612d692c48481b9b397e2b55f4870e447966d66c96d655241702d44a2628
$(PKG)_SUBDIR := llvm-$($(PKG)_VERSION)
$(PKG)_FILE := llvm-$($(PKG)_VERSION).src.tar.gz
-$(PKG)_URL := http://releases.llvm.org/$($(PKG)_VERSION)/$($(PKG)_FILE)
+$(PKG)_URL := https://releases.llvm.org/$($(PKG)_VERSION)/$($(PKG)_FILE)
$(PKG)_DEPS := gcc
define $(PKG)_UPDATE
- $(WGET) -q -O- 'http://releases.llvm.org/download.html' | \
+ $(WGET) -q -O- 'https://releases.llvm.org/download.html' | \
grep 'Download LLVM' | \
$(SED) -n 's,.*LLVM \([0-9][^<]*\).*,\1,p' | \
head -1
diff --git a/src/log4cxx.mk b/src/log4cxx.mk
index c9a9728..c08253b 100644
--- a/src/log4cxx.mk
+++ b/src/log4cxx.mk
@@ -7,8 +7,8 @@ $(PKG)_VERSION := 0.10.0
$(PKG)_CHECKSUM := 0de0396220a9566a580166e66b39674cb40efd2176f52ad2c65486c99c920c8c
$(PKG)_SUBDIR := apache-log4cxx-$($(PKG)_VERSION)
$(PKG)_FILE := $($(PKG)_SUBDIR).tar.gz
-$(PKG)_URL := http://www.eu.apache.org/dist/logging/log4cxx/$($(PKG)_VERSION)/$($(PKG)_FILE)
-$(PKG)_URL_2 := http://apache.mirror.cdnetworks.com//logging/log4cxx/0.10.0/$($(PKG)_FILE)
+$(PKG)_URL := https://www.apache.org/dist/logging/log4cxx/$($(PKG)_VERSION)/$($(PKG)_FILE)
+$(PKG)_URL_2 := https://archive.apache.org/dist/logging/log4cxx/$($(PKG)_VERSION)/$($(PKG)_FILE)
$(PKG)_DEPS := gcc apr-util
define $(PKG)_UPDATE
diff --git a/src/opencv-1-fixes.patch b/src/opencv-1-fixes.patch
index 8cb17b9..45bce44 100644
--- a/src/opencv-1-fixes.patch
+++ b/src/opencv-1-fixes.patch
@@ -1,142 +1,35 @@
This file is part of MXE. See LICENSE.md for licensing information.
+Contains ad hoc patches for cross building.
+
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Gregorio Litenstein <g.litenstein@gmail.com>
+Date: Thu, 31 Aug 2017 18:27:53 -0300
+Subject: [PATCH] patch-1 for opencv-3.3.0
+
+
diff --git a/CMakeLists.txt b/CMakeLists.txt
-index 579312d..53e4132 100644
+index 1111111..2222222 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
-@@ -38,7 +38,7 @@ else(NOT CMAKE_TOOLCHAIN_FILE)
- #Android: set output folder to ${CMAKE_BINARY_DIR}
- set( LIBRARY_OUTPUT_PATH_ROOT ${CMAKE_BINARY_DIR} CACHE PATH "root for library output, set this to change where android libs are compiled to" )
- # any crosscompiling
-- set(CMAKE_INSTALL_PREFIX "${CMAKE_BINARY_DIR}/install" CACHE PATH "Installation Directory")
-+ #set(CMAKE_INSTALL_PREFIX "${CMAKE_BINARY_DIR}/install" CACHE PATH "Installation Directory")
- endif(NOT CMAKE_TOOLCHAIN_FILE)
-
- # --------------------------------------------------------------
-diff -ur a/modules/core/src/lapack.cpp b/modules/core/src/lapack.cpp
---- a/modules/core/src/lapack.cpp 2013-12-28 04:09:18.000000000 +1100
-+++ b/modules/core/src/lapack.cpp 2014-01-05 21:14:52.869649685 +1100
-@@ -716,7 +716,7 @@
-
- static void JacobiSVD(double* At, size_t astep, double* W, double* Vt, size_t vstep, int m, int n, int n1=-1)
- {
-- JacobiSVDImpl_(At, astep, W, Vt, vstep, m, n, !Vt ? 0 : n1 < 0 ? n : n1, DBL_MIN, DBL_EPSILON*10);
-+ JacobiSVDImpl_(At, astep, W, Vt, vstep, m, n, !Vt ? 0 : n1 < 0 ? n : n1, DBL_MIN, DBL_EPSILON*10L);
- }
-
- /* y[0:m,0:n] += diag(a[0:1,0:m]) * x[0:m,0:n] */
-diff -ur a/modules/core/src/precomp.hpp b/modules/core/src/precomp.hpp
---- a/modules/core/src/precomp.hpp 2013-12-28 04:09:18.000000000 +1100
-+++ b/modules/core/src/precomp.hpp 2014-01-05 21:05:08.968467624 +1100
-@@ -51,7 +51,7 @@
-
- #include <assert.h>
- #include <ctype.h>
--#include <float.h>
-+#include <cfloat>
- #include <limits.h>
- #include <math.h>
- #include <stdio.h>
-diff -ur a/modules/highgui/src/window_w32.cpp b/modules/highgui/src/window_w32.cpp
---- a/modules/highgui/src/window_w32.cpp 2013-12-28 04:09:18.000000000 +1100
-+++ b/modules/highgui/src/window_w32.cpp 2014-01-05 21:23:48.318950096 +1100
-@@ -75,7 +75,7 @@
- #include <vector>
- #include <functional>
- #include "opencv2/highgui/highgui.hpp"
--#include <GL\gl.h>
-+#include <GL/gl.h>
- #endif
-
- static const char* trackbar_text =
-
-diff -ur a/cmake/OpenCVFindLibsVideo.cmake b/cmake/OpenCVFindLibsVideo.cmake
---- a/cmake/OpenCVFindLibsVideo.cmake 2013-12-28 04:09:18.000000000 +1100
-+++ b/cmake/OpenCVFindLibsVideo.cmake 2014-01-07 22:34:22.291927941 +1100
-@@ -228,12 +228,12 @@
-
- # --- Extra HighGUI libs on Windows ---
- if(WIN32)
-- list(APPEND HIGHGUI_LIBRARIES comctl32 gdi32 ole32 setupapi ws2_32 vfw32)
-+ list(APPEND HIGHGUI_LIBRARIES -lcomctl32 -lgdi32 -lole32 -lsetupapi -lws2_32 -lvfw32 -lstrmiids -loleaut32 -luuid)
- if(MINGW64)
-- list(APPEND HIGHGUI_LIBRARIES avifil32 avicap32 winmm msvfw32)
-- list(REMOVE_ITEM HIGHGUI_LIBRARIES vfw32)
-+ list(APPEND HIGHGUI_LIBRARIES -lavifil32 -lavicap32 -lwinmm -lmsvfw32)
-+ list(REMOVE_ITEM HIGHGUI_LIBRARIES -lvfw32)
- elseif(MINGW)
-- list(APPEND HIGHGUI_LIBRARIES winmm)
-+ list(APPEND HIGHGUI_LIBRARIES -lwinmm)
- endif()
- endif(WIN32)
-
---- a/modules/highgui/CMakeLists.txt
-+++ b/modules/highgui/CMakeLists.txt
-@@ -262,7 +267,7 @@ set_target_properties(${the_module} PROPERTIES LINK_INTERFACE_LIBRARIES "")
- ocv_add_precompiled_headers(${the_module})
- ocv_warnings_disable(CMAKE_CXX_FLAGS -Wno-deprecated-declarations)
+@@ -36,7 +36,6 @@ if(NOT DEFINED CMAKE_INSTALL_PREFIX)
+ if(NOT CMAKE_TOOLCHAIN_FILE)
+ # it _must_ go before project(OpenCV) in order to work
+ if(WIN32)
+- set(CMAKE_INSTALL_PREFIX "${CMAKE_BINARY_DIR}/install" CACHE PATH "Installation Directory")
+ else()
+ set(CMAKE_INSTALL_PREFIX "/usr/local" CACHE PATH "Installation Directory")
+ endif()
+@@ -44,7 +43,6 @@ if(NOT DEFINED CMAKE_INSTALL_PREFIX)
+ #Android: set output folder to ${CMAKE_BINARY_DIR}
+ set( LIBRARY_OUTPUT_PATH_ROOT ${CMAKE_BINARY_DIR} CACHE PATH "root for library output, set this to change where android libs are compiled to" )
+ # any crosscompiling
+- set(CMAKE_INSTALL_PREFIX "${CMAKE_BINARY_DIR}/install" CACHE PATH "Installation Directory")
+ endif(NOT CMAKE_TOOLCHAIN_FILE)
+ endif()
--if(WIN32 AND WITH_FFMPEG)
-+if(WIN32 AND WITH_FFMPEG AND BUILD_SHARED_LIBS)
- #copy ffmpeg dll to the output folder
- if(MSVC64 OR MINGW64)
- set(FFMPEG_SUFFIX _64)
-diff --git a/cmake/OpenCVFindLZMA.cmake b/cmake/OpenCVFindLZMA.cmake
-new file mode 100644
-index 0000000..0b46b2c
---- /dev/null
-+++ b/cmake/OpenCVFindLZMA.cmake
-@@ -0,0 +1,48 @@
-+# - Find lzma and lzmadec
-+# Find the native LZMA includes and library
-+#
-+# LZMA_INCLUDE_DIR - where to find lzma.h, etc.
-+# LZMA_LIBRARIES - List of libraries when using liblzma.
-+# LZMA_FOUND - True if liblzma found.
-+# LZMADEC_INCLUDE_DIR - where to find lzmadec.h, etc.
-+# LZMADEC_LIBRARIES - List of libraries when using liblzmadec.
-+# LZMADEC_FOUND - True if liblzmadec found.
-+
-+IF (LZMA_INCLUDE_DIR)
-+ # Already in cache, be silent
-+ SET(LZMA_FIND_QUIETLY TRUE)
-+ENDIF (LZMA_INCLUDE_DIR)
-+
-+FIND_PATH(LZMA_INCLUDE_DIR lzma.h)
-+FIND_LIBRARY(LZMA_LIBRARY NAMES lzma liblzma)
-+
-+# handle the QUIETLY and REQUIRED arguments and set LZMA_FOUND to TRUE if
-+# all listed variables are TRUE
-+INCLUDE(FindPackageHandleStandardArgs)
-+FIND_PACKAGE_HANDLE_STANDARD_ARGS(LZMA DEFAULT_MSG LZMA_LIBRARY LZMA_INCLUDE_DIR)
-+
-+IF(LZMA_FOUND)
-+ SET( LZMA_LIBRARIES ${LZMA_LIBRARY} )
-+ELSE(LZMA_FOUND)
-+ SET( LZMA_LIBRARIES )
-+
-+ IF (LZMADEC_INCLUDE_DIR)
-+ # Already in cache, be silent
-+ SET(LZMADEC_FIND_QUIETLY TRUE)
-+ ENDIF (LZMADEC_INCLUDE_DIR)
-+
-+ FIND_PATH(LZMADEC_INCLUDE_DIR lzmadec.h)
-+ FIND_LIBRARY(LZMADEC_LIBRARY NAMES lzmadec )
-+
-+ # handle the QUIETLY and REQUIRED arguments and set LZMADEC_FOUND to TRUE if
-+ # all listed variables are TRUE
-+ INCLUDE(FindPackageHandleStandardArgs)
-+ FIND_PACKAGE_HANDLE_STANDARD_ARGS(LZMADEC DEFAULT_MSG LZMADEC_LIBRARY
-+ LZMADEC_INCLUDE_DIR)
-+
-+ IF(LZMADEC_FOUND)
-+ SET( LZMADEC_LIBRARIES ${LZMADEC_LIBRARY} )
-+ ELSE(LZMADEC_FOUND)
-+ SET( LZMADEC_LIBRARIES )
-+ ENDIF(LZMADEC_FOUND)
-+ENDIF(LZMA_FOUND)
diff --git a/cmake/OpenCVFindLibsGrfmt.cmake b/cmake/OpenCVFindLibsGrfmt.cmake
-index 5988169..738e1f3 100644
+index 1111111..2222222 100644
--- a/cmake/OpenCVFindLibsGrfmt.cmake
+++ b/cmake/OpenCVFindLibsGrfmt.cmake
@@ -2,6 +2,11 @@
@@ -163,45 +56,178 @@ index 5988169..738e1f3 100644
# --- libtiff (optional, should be searched after zlib) ---
if(WITH_TIFF)
if(BUILD_TIFF)
-@@ -114,6 +124,7 @@ if(WITH_PNG)
- if(BUILD_PNG)
- ocv_clear_vars(PNG_FOUND)
- else()
-+ include(CheckIncludeFile)
- include(FindPNG)
- if(PNG_FOUND)
- check_include_file("${PNG_PNG_INCLUDE_DIR}/png.h" HAVE_PNG_H)
-diff --git a/modules/core/CMakeLists.txt b/modules/core/CMakeLists.txt
-index 4c5112e..7411f32 100644
---- a/modules/core/CMakeLists.txt
-+++ b/modules/core/CMakeLists.txt
-@@ -1,12 +1,12 @@
- set(the_description "The Core Functionality")
+diff --git a/cmake/OpenCVFindLibsVideo.cmake b/cmake/OpenCVFindLibsVideo.cmake
+index 1111111..2222222 100644
+--- a/cmake/OpenCVFindLibsVideo.cmake
++++ b/cmake/OpenCVFindLibsVideo.cmake
+@@ -272,15 +272,15 @@ endif(WITH_MSMF)
- if (NOT HAVE_CUDA OR ENABLE_DYNAMIC_CUDA)
-- ocv_add_module(core PRIVATE_REQUIRED ${ZLIB_LIBRARIES})
-+ ocv_add_module(core PRIVATE_REQUIRED ${ZLIB_LIBRARIES} ${LZMA_LIBRARIES} ${LCMS_LIBRARIES})
- else()
-- ocv_add_module(core PRIVATE_REQUIRED ${ZLIB_LIBRARIES} ${CUDA_LIBRARIES} ${CUDA_npp_LIBRARY})
-+ ocv_add_module(core PRIVATE_REQUIRED ${ZLIB_LIBRARIES} ${CUDA_LIBRARIES} ${CUDA_npp_LIBRARY} ${LZMA_LIBRARIES} ${LCMS_LIBRARIES})
- endif()
-
--ocv_module_include_directories("${OpenCV_SOURCE_DIR}/modules/dynamicuda/include/" ${ZLIB_INCLUDE_DIR})
-+ocv_module_include_directories("${OpenCV_SOURCE_DIR}/modules/dynamicuda/include/" ${ZLIB_INCLUDE_DIR} ${LZMA_INCLUDE_DIR} ${LCMS_INCLUDE_DIR})
+ # --- Extra HighGUI and VideoIO libs on Windows ---
+ if(WIN32)
+- list(APPEND HIGHGUI_LIBRARIES comctl32 gdi32 ole32 setupapi ws2_32)
++ list(APPEND HIGHGUI_LIBRARIES -lcomctl32 -lcomdlg32 -lgdi32 -lole32 -lsetupapi -lws2_32 -lvfw32 -lstrmiids -loleaut32 -luuid)
+ if(HAVE_VFW)
+ list(APPEND VIDEOIO_LIBRARIES vfw32)
+ endif()
+ if(MINGW64)
+- list(APPEND VIDEOIO_LIBRARIES avifil32 avicap32 winmm msvfw32)
+- list(REMOVE_ITEM VIDEOIO_LIBRARIES vfw32)
++ list(APPEND VIDEOIO_LIBRARIES -lavifil32 -lavicap32 -lwinmm -lmsvfw32)
++ list(REMOVE_ITEM VIDEOIO_LIBRARIES -lvfw32)
+ elseif(MINGW)
+- list(APPEND VIDEOIO_LIBRARIES winmm)
++ list(APPEND VIDEOIO_LIBRARIES -lwinmm)
+ endif()
+ endif(WIN32)
- if(HAVE_WINRT_CX)
- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /ZW")
-
-diff --git a/cmake/templates/opencv-XXX.pc.cmake.in b/cmake/templates/opencv-XXX.pc.cmake.in
-index 4f6415c..ea1ed15 100644
+diff --git a/cmake/templates/opencv-XXX.pc.in b/cmake/templates/opencv-XXX.pc.in
+index 1111111..2222222 100644
--- a/cmake/templates/opencv-XXX.pc.in
+++ b/cmake/templates/opencv-XXX.pc.in
-@@ -9,5 +9,7 @@
+@@ -9,6 +9,7 @@ includedir_new=@includedir@
Name: OpenCV
Description: Open Source Computer Vision Library
- Version: @OPENCV_VERSION@
+ Version: @OPENCV_VERSION_PLAIN@
+Requires: OpenEXR libtiff-4
- Libs: @OpenCV_LIB_COMPONENTS@
-+Libs.private: -luuid -loleaut32
+ Libs: @OPENCV_PC_LIBS@
+-Libs.private: @OPENCV_PC_LIBS_PRIVATE@
++Libs.private: @OPENCV_PC_LIBS_PRIVATE@ -luuid -loleaut32
Cflags: -I${includedir_old} -I${includedir_new}
+diff --git a/modules/core/src/lapack.cpp b/modules/core/src/lapack.cpp
+index 1111111..2222222 100644
+--- a/modules/core/src/lapack.cpp
++++ b/modules/core/src/lapack.cpp
+@@ -608,7 +608,7 @@ void hal::SVD32f(float* At, size_t astep, float* W, float* U, size_t ustep, floa
+ void hal::SVD64f(double* At, size_t astep, double* W, double* U, size_t ustep, double* Vt, size_t vstep, int m, int n, int n1)
+ {
+ CALL_HAL(SVD64f, cv_hal_SVD64f, At, astep, W, U, ustep, Vt, vstep, m, n, decodeSVDParameters(U, Vt, m, n, n1))
+- JacobiSVDImpl_(At, astep, W, Vt, vstep, m, n, !Vt ? 0 : n1 < 0 ? n : n1, DBL_MIN, DBL_EPSILON*10);
++ JacobiSVDImpl_(At, astep, W, Vt, vstep, m, n, !Vt ? 0 : n1 < 0 ? n : n1, DBL_MIN, DBL_EPSILON*10L);
+ }
+
+ /* y[0:m,0:n] += diag(a[0:1,0:m]) * x[0:m,0:n] */
+diff --git a/modules/core/src/precomp.hpp b/modules/core/src/precomp.hpp
+index 1111111..2222222 100644
+--- a/modules/core/src/precomp.hpp
++++ b/modules/core/src/precomp.hpp
+@@ -60,7 +60,7 @@
+
+ #include <assert.h>
+ #include <ctype.h>
+-#include <float.h>
++#include <cfloat>
+ #include <limits.h>
+ #include <math.h>
+ #include <stdarg.h>
+diff --git a/modules/videoio/CMakeLists.txt b/modules/videoio/CMakeLists.txt
+index 1111111..2222222 100644
+--- a/modules/videoio/CMakeLists.txt
++++ b/modules/videoio/CMakeLists.txt
+@@ -231,6 +231,10 @@ if(WIN32)
+ include_directories(AFTER SYSTEM "${OpenCV_SOURCE_DIR}/3rdparty/include/ffmpeg_") # for tests
+ endif()
+
++if(WIN32)
++ add_definitions(-DSTRSAFE_NO_DEPRECATE)
++endif()
++
+ if(UNIX)
+ #these variables are set by CHECK_MODULE macro
+ foreach(P ${VIDEOIO_INCLUDE_DIRS})
+
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Gregorio Litenstein <g.litenstein@gmail.com>
+Date: Thu, 31 Aug 2017 18:32:39 -0300
+Subject: [PATCH] patch 2 for opencv-3.3.0
+
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 1111111..2222222 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -358,14 +358,7 @@ else()
+ ocv_update(OPENCV_DOC_INSTALL_PATH share/OpenCV/doc)
+ endif()
+
+-if(WIN32 AND CMAKE_HOST_SYSTEM_NAME MATCHES Windows)
+- if(DEFINED OpenCV_RUNTIME AND DEFINED OpenCV_ARCH)
+- ocv_update(OpenCV_INSTALL_BINARIES_PREFIX "${OpenCV_ARCH}/${OpenCV_RUNTIME}/")
+- else()
+- message(STATUS "Can't detect runtime and/or arch")
+- ocv_update(OpenCV_INSTALL_BINARIES_PREFIX "")
+- endif()
+-elseif(ANDROID)
++if(ANDROID)
+ ocv_update(OpenCV_INSTALL_BINARIES_PREFIX "sdk/native/")
+ else()
+ ocv_update(OpenCV_INSTALL_BINARIES_PREFIX "")
+@@ -413,12 +406,8 @@ else()
+ ocv_update(3P_LIBRARY_OUTPUT_PATH "${OpenCV_BINARY_DIR}/3rdparty/lib${LIB_SUFFIX}")
+
+ if(WIN32 AND CMAKE_HOST_SYSTEM_NAME MATCHES Windows)
+- if(OpenCV_STATIC)
+- ocv_update(OPENCV_LIB_INSTALL_PATH "${OpenCV_INSTALL_BINARIES_PREFIX}staticlib${LIB_SUFFIX}")
+- else()
+- ocv_update(OPENCV_LIB_INSTALL_PATH "${OpenCV_INSTALL_BINARIES_PREFIX}lib${LIB_SUFFIX}")
+- endif()
+- ocv_update(OPENCV_3P_LIB_INSTALL_PATH "${OpenCV_INSTALL_BINARIES_PREFIX}staticlib${LIB_SUFFIX}")
++ ocv_update(OPENCV_LIB_INSTALL_PATH "${OpenCV_INSTALL_BINARIES_PREFIX}lib${LIB_SUFFIX}")
++ ocv_update(OPENCV_3P_LIB_INSTALL_PATH "${OpenCV_INSTALL_BINARIES_PREFIX}lib${LIB_SUFFIX}")
+ ocv_update(OPENCV_SAMPLES_SRC_INSTALL_PATH samples/native)
+ ocv_update(OPENCV_JAR_INSTALL_PATH java)
+ ocv_update(OPENCV_OTHER_INSTALL_PATH etc)
+@@ -462,15 +451,9 @@ if(INSTALL_TO_MANGLED_PATHS)
+ endif()
+
+
+-if(WIN32)
+- # Postfix of DLLs:
+- set(OPENCV_DLLVERSION "${OPENCV_VERSION_MAJOR}${OPENCV_VERSION_MINOR}${OPENCV_VERSION_PATCH}")
+- set(OPENCV_DEBUG_POSTFIX d)
+-else()
+- # Postfix of so's:
+- set(OPENCV_DLLVERSION "")
+- set(OPENCV_DEBUG_POSTFIX "")
+-endif()
++# Postfix of so's and DLLs:
++set(OPENCV_DLLVERSION "")
++set(OPENCV_DEBUG_POSTFIX "")
+
+ if(DEFINED CMAKE_DEBUG_POSTFIX)
+ set(OPENCV_DEBUG_POSTFIX "${CMAKE_DEBUG_POSTFIX}")
+
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Gregorio Litenstein <g.litenstein@gmail.com>
+Date: Thu, 31 Aug 2017 18:35:23 -0300
+Subject: [PATCH] patch-3 for opencv-3.3.0
+
+Originally From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Boris Nagaev <bnagaev@gmail.com>
+Date: Sun, 20 Dec 2015 18:14:56 +0300
+Subject: [PATCH] fix CMake error if a directory contains ++
+
+See https://github.com/mxe/mxe/issues/1091
+diff --git a/cmake/OpenCVModule.cmake b/cmake/OpenCVModule.cmake
+index 1111111..2222222 100644
+--- a/cmake/OpenCVModule.cmake
++++ b/cmake/OpenCVModule.cmake
+@@ -491,12 +491,16 @@ function(__ocv_resolve_dependencies)
+ # process private deps
+ foreach(m ${OPENCV_MODULES_BUILD})
+ foreach(d ${OPENCV_MODULE_${m}_PRIVATE_REQ_DEPS})
+- if(NOT (";${deps_${m}};" MATCHES ";${d};"))
++ # can't use MATCH because file paths can include regexp special chars
++ string(FIND ";${deps_${m}};" ";${d};" d_offset)
++ if(${d_offset} EQUAL -1)
+ list(APPEND deps_${m} ${d})
+ endif()
+ endforeach()
+ foreach(d ${OPENCV_MODULE_${m}_PRIVATE_OPT_DEPS})
+- if(NOT (";${deps_${m}};" MATCHES ";${d};"))
++ # can't use MATCH because file paths can include regexp special chars
++ string(FIND ";${deps_${m}};" ";${d};" d_offset)
++ if(${d_offset} EQUAL -1)
+ if(HAVE_${d} OR TARGET ${d})
+ list(APPEND deps_${m} ${d})
+ endif()
diff --git a/src/opencv-2-fixes-cmake.patch b/src/opencv-2-fixes-cmake.patch
deleted file mode 100644
index baad1b1..0000000
--- a/src/opencv-2-fixes-cmake.patch
+++ /dev/null
@@ -1,69 +0,0 @@
-This file is part of MXE. See LICENSE.md for licensing information.
-
-diff -ru a/cmake/OpenCVGenConfig.cmake b/cmake/OpenCVGenConfig.cmake
---- a/cmake/OpenCVGenConfig.cmake 2014-10-01 08:33:36.000000000 +0100
-+++ b/cmake/OpenCVGenConfig.cmake 2015-01-06 22:41:05.094464515 +0000
-@@ -137,8 +137,8 @@
- install(FILES "${CMAKE_BINARY_DIR}/win-install/OpenCVConfig.cmake" DESTINATION "${OpenCV_INSTALL_BINARIES_PREFIX}lib" COMPONENT dev)
- install(EXPORT OpenCVModules DESTINATION "${OpenCV_INSTALL_BINARIES_PREFIX}lib" FILE OpenCVModules${modules_file_suffix}.cmake COMPONENT dev)
- else()
-- install(FILES "${CMAKE_BINARY_DIR}/win-install/OpenCVConfig.cmake" DESTINATION "${OpenCV_INSTALL_BINARIES_PREFIX}staticlib" COMPONENT dev)
-- install(EXPORT OpenCVModules DESTINATION "${OpenCV_INSTALL_BINARIES_PREFIX}staticlib" FILE OpenCVModules${modules_file_suffix}.cmake COMPONENT dev)
-+ install(FILES "${CMAKE_BINARY_DIR}/win-install/OpenCVConfig.cmake" DESTINATION "${OpenCV_INSTALL_BINARIES_PREFIX}lib" COMPONENT dev)
-+ install(EXPORT OpenCVModules DESTINATION "${OpenCV_INSTALL_BINARIES_PREFIX}lib" FILE OpenCVModules${modules_file_suffix}.cmake COMPONENT dev)
- endif()
- install(FILES "${CMAKE_BINARY_DIR}/win-install/OpenCVConfig-version.cmake" DESTINATION "${CMAKE_INSTALL_PREFIX}" COMPONENT dev)
- install(FILES "${OpenCV_SOURCE_DIR}/cmake/OpenCVConfig.cmake" DESTINATION "${CMAKE_INSTALL_PREFIX}/" COMPONENT dev)
-diff -ru a/CMakeLists.txt b/CMakeLists.txt
---- a/CMakeLists.txt 2014-10-01 08:33:36.000000000 +0100
-+++ b/CMakeLists.txt 2015-01-06 22:31:50.118454434 +0000
-@@ -269,14 +269,7 @@
- set(OPENCV_DOC_INSTALL_PATH share/OpenCV/doc)
- endif()
-
--if(WIN32)
-- if(DEFINED OpenCV_RUNTIME AND DEFINED OpenCV_ARCH)
-- set(OpenCV_INSTALL_BINARIES_PREFIX "${OpenCV_ARCH}/${OpenCV_RUNTIME}/")
-- else()
-- message(STATUS "Can't detect runtime and/or arch")
-- set(OpenCV_INSTALL_BINARIES_PREFIX "")
-- endif()
--elseif(ANDROID)
-+if(ANDROID)
- set(OpenCV_INSTALL_BINARIES_PREFIX "sdk/native/")
- else()
- set(OpenCV_INSTALL_BINARIES_PREFIX "")
-@@ -310,12 +303,8 @@
- set(LIBRARY_OUTPUT_PATH "${OpenCV_BINARY_DIR}/lib")
- set(3P_LIBRARY_OUTPUT_PATH "${OpenCV_BINARY_DIR}/3rdparty/lib${LIB_SUFFIX}")
- if(WIN32)
-- if(OpenCV_STATIC)
-- set(OPENCV_LIB_INSTALL_PATH "${OpenCV_INSTALL_BINARIES_PREFIX}staticlib${LIB_SUFFIX}")
-- else()
-- set(OPENCV_LIB_INSTALL_PATH "${OpenCV_INSTALL_BINARIES_PREFIX}lib${LIB_SUFFIX}")
-- endif()
-- set(OPENCV_3P_LIB_INSTALL_PATH "${OpenCV_INSTALL_BINARIES_PREFIX}staticlib${LIB_SUFFIX}")
-+ set(OPENCV_LIB_INSTALL_PATH "${OpenCV_INSTALL_BINARIES_PREFIX}lib${LIB_SUFFIX}")
-+ set(OPENCV_3P_LIB_INSTALL_PATH "${OpenCV_INSTALL_BINARIES_PREFIX}lib${LIB_SUFFIX}")
- set(OPENCV_SAMPLES_SRC_INSTALL_PATH samples/native)
- else()
- set(OPENCV_LIB_INSTALL_PATH lib${LIB_SUFFIX})
-@@ -339,15 +328,9 @@
- set(OPENCV_INCLUDE_INSTALL_PATH ${OPENCV_INCLUDE_INSTALL_PATH}/opencv-${OPENCV_VERSION})
- endif()
-
--if(WIN32)
-- # Postfix of DLLs:
-- set(OPENCV_DLLVERSION "${OPENCV_VERSION_MAJOR}${OPENCV_VERSION_MINOR}${OPENCV_VERSION_PATCH}")
-- set(OPENCV_DEBUG_POSTFIX d)
--else()
-- # Postfix of so's:
-- set(OPENCV_DLLVERSION "")
-- set(OPENCV_DEBUG_POSTFIX "")
--endif()
-+# Postfix of so's and DLLs:
-+set(OPENCV_DLLVERSION "")
-+set(OPENCV_DEBUG_POSTFIX "")
-
- if(DEFINED CMAKE_DEBUG_POSTFIX)
- set(OPENCV_DEBUG_POSTFIX "${CMAKE_DEBUG_POSTFIX}")
diff --git a/src/opencv-3-fixes-pkgconfig.patch b/src/opencv-3-fixes-pkgconfig.patch
deleted file mode 100644
index 6ca9761..0000000
--- a/src/opencv-3-fixes-pkgconfig.patch
+++ /dev/null
@@ -1,156 +0,0 @@
-This file is part of MXE. See LICENSE.md for licensing information.
-
-This patch was committed to OpenCV's 2.4 branch and we should be able to drop
-it in the next point release.
-
-commit eceada586bbf18fc267e437522ec4f1f23ddc656
-Author: Samuel Martin <s.martin49@gmail.com>
-Date: Fri Oct 3 00:32:40 2014 +0200
-
- cmake/OpenCVGenPkgconfig.cmake: rework opencv.pc generation
-
- Using absolute path to locate the components in the "Libs:" field of the
- *.pc can badly break cross-compilation, especially when building
- statically linked objects.
-
- Indeed, pkg-config automatically replaces the '-I...' and '-L...' paths
- when the PKG_CONFIG_SYSROOT_DIR and PKG_CONFIG_LIBDIR environment
- variables are set [1]. This feature is very helpful and common in
- cross-compilation framework like Buildroot [2,3].
-
- When there are absolute paths in the *.pc files, pkg-config won't be
- able to do the path substitions for these paths when the afromentioned
- environment variables are set.
- In such case, since the prefix is the target one, not the sysroot one,
- these libraries' abolute paths will point to:
- - in the best case: a non-existing file (i.e. these files do not exists
- on the host system;
- - at worst: the host system's libraries. This will make the linking
- failed because these host system's libraries will most likely not be
- build for the target architecture [4].
-
- So, this patch replace the components' absolute paths by the form:
- -L<libdir> -l<libname>
-
- This way, the linker will be able to resolve each dependency path,
- whatever the kind of objects/build (shared object or static build) it
- is dealing with.
-
- Note that for static link, the library order does matter [5]. The order
- of the opencv components has been carefully chosen to comply with this
- requirement.
-
- Fixes #3931
-
- [1] http://linux.die.net/man/1/pkg-config
- [2] http://buildroot.org/
- [3] http://git.buildroot.net/buildroot/tree/package/pkgconf/pkg-config.in
- [4] http://autobuild.buildroot.net/results/e8a/e8a859276db34aff87ef181b0cce98916b0afc90/build-end.log
- [5] http://stackoverflow.com/questions/45135/linker-order-gcc
-
- Signed-off-by: Samuel Martin <s.martin49@gmail.com>
-
- ---
- Note: this patch properly applies on top of the master branch, though it
- has been written on top of the 2.4 branch.
-
-diff --git a/cmake/OpenCVGenPkgconfig.cmake b/cmake/OpenCVGenPkgconfig.cmake
-index fa57db9..183c56d 100644
---- a/cmake/OpenCVGenPkgconfig.cmake
-+++ b/cmake/OpenCVGenPkgconfig.cmake
-@@ -8,10 +8,6 @@
- #
- # ${BIN_DIR}/unix-install/opencv.pc -> For use *with* "make install"
- # -------------------------------------------------------------------------------------------
--set(prefix "${CMAKE_INSTALL_PREFIX}")
--set(exec_prefix "\${prefix}")
--set(libdir "") #TODO: need link paths for OpenCV_EXTRA_COMPONENTS
--set(includedir "\${prefix}/${OPENCV_INCLUDE_INSTALL_PATH}")
-
- if(CMAKE_BUILD_TYPE MATCHES "Release")
- set(ocv_optkind OPT)
-@@ -35,42 +31,66 @@ ocv_list_reverse(OpenCV_LIB_COMPONENTS)
- ocv_list_reverse(OpenCV_EXTRA_COMPONENTS)
-
- #build the list of components
--set(OpenCV_LIB_COMPONENTS_ "")
--foreach(CVLib ${OpenCV_LIB_COMPONENTS})
-- get_target_property(libpath ${CVLib} LOCATION_${CMAKE_BUILD_TYPE})
-- get_filename_component(libname "${libpath}" NAME)
-
-- if(INSTALL_TO_MANGLED_PATHS)
-- set(libname "${libname}.${OPENCV_VERSION}")
-- endif()
-+# Note:
-+# when linking against static libraries, if libfoo depends on libbar, then
-+# libfoo must come first in the linker flags.
-+
-+# world is a special target whose library should come first, especially for
-+# static link.
-+if(OpenCV_LIB_COMPONENTS MATCHES "opencv_world")
-+ list(REMOVE_ITEM OpenCV_LIB_COMPONENTS "opencv_world")
-+ list(INSERT OpenCV_LIB_COMPONENTS 0 "opencv_world")
-+endif()
-+
-+set(OpenCV_LIB_COMPONENTS_)
-+foreach(CVLib ${OpenCV_LIB_COMPONENTS})
-
-- #need better solution....
-- if(libpath MATCHES "3rdparty")
-- set(installDir "share/OpenCV/3rdparty/${OPENCV_LIB_INSTALL_PATH}")
-+ get_target_property(libloc ${CVLib} LOCATION_${CMAKE_BUILD_TYPE})
-+ if(libloc MATCHES "3rdparty")
-+ set(libpath "\${exec_prefix}/share/OpenCV/3rdparty/${OPENCV_LIB_INSTALL_PATH}")
- else()
-- set(installDir "${OPENCV_LIB_INSTALL_PATH}")
-+ set(libpath "\${exec_prefix}/${OPENCV_LIB_INSTALL_PATH}")
- endif()
-+ list(APPEND OpenCV_LIB_COMPONENTS_ "-L${libpath}")
-+
-+ get_filename_component(libname ${CVLib} NAME_WE)
-+ string(REGEX REPLACE "^lib" "" libname "${libname}")
-+ list(APPEND OpenCV_LIB_COMPONENTS_ "-l${libname}")
-
-- set(OpenCV_LIB_COMPONENTS_ "${OpenCV_LIB_COMPONENTS_} \${exec_prefix}/${installDir}/${libname}")
- endforeach()
-
- # add extra dependencies required for OpenCV
--set(OpenCV_LIB_COMPONENTS ${OpenCV_LIB_COMPONENTS_})
- if(OpenCV_EXTRA_COMPONENTS)
- foreach(extra_component ${OpenCV_EXTRA_COMPONENTS})
-
-- if(extra_component MATCHES "^-[lL]" OR extra_component MATCHES "[\\/]")
-- set(maybe_l_prefix "")
-+ if(extra_component MATCHES "^-[lL]")
-+ set(libprefix "")
-+ set(libname "${extra_component}")
-+ elseif(extra_component MATCHES "[\\/]")
-+ get_filename_component(libdir "${extra_component}" PATH)
-+ list(APPEND OpenCV_LIB_COMPONENTS_ "-L${libdir}")
-+ get_filename_component(libname "${extra_component}" NAME_WE)
-+ string(REGEX REPLACE "^lib" "" libname "${libname}")
-+ set(libprefix "-l")
- else()
-- set(maybe_l_prefix "-l")
-+ set(libprefix "-l")
-+ set(libname "${extra_component}")
- endif()
--
-- set(OpenCV_LIB_COMPONENTS "${OpenCV_LIB_COMPONENTS} ${maybe_l_prefix}${extra_component}")
-+ list(APPEND OpenCV_LIB_COMPONENTS_ "${libprefix}${libname}")
-
- endforeach()
- endif()
-
-+list(REMOVE_DUPLICATES OpenCV_LIB_COMPONENTS_)
-+string(REPLACE ";" " " OpenCV_LIB_COMPONENTS "${OpenCV_LIB_COMPONENTS_}")
-+
- #generate the .pc file
-+set(prefix "${CMAKE_INSTALL_PREFIX}")
-+set(exec_prefix "\${prefix}")
-+set(libdir "\${exec_prefix}/${OPENCV_LIB_INSTALL_PATH}")
-+set(includedir "\${prefix}/${OPENCV_INCLUDE_INSTALL_PATH}")
-+
- if(INSTALL_TO_MANGLED_PATHS)
- set(OPENCV_PC_FILE_NAME "opencv-${OPENCV_VERSION}.pc")
- else()
diff --git a/src/opencv-4-reverse-deps-sublist.patch b/src/opencv-4-reverse-deps-sublist.patch
deleted file mode 100644
index fbd36dc..0000000
--- a/src/opencv-4-reverse-deps-sublist.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-This file is part of MXE. See LICENSE.md for licensing information.
-
-From 20cf852345e364f7e18c8721561d7c4d1ebd1d6e Mon Sep 17 00:00:00 2001
-From: Boris Nagaev <bnagaev@gmail.com>
-Date: Sun, 6 Sep 2015 00:53:13 +0100
-Subject: [PATCH] reverse deps list before inserting to another list
-
-Order of items in ${m}_EXTRA_DEPS_${ocv_optkind} corresponds
-to the order in which a linker expects items to appear:
-a depender before a dependee.
-
-But the order of items of OpenCV_EXTRA_COMPONENTS is
-reversed (afterwards this list is unique'ed and reversed).
-That is why sub-lists must be inserted in reversed form.
----
- cmake/OpenCVGenPkgconfig.cmake | 4 ++++
- 1 file changed, 4 insertions(+)
-
-diff --git a/cmake/OpenCVGenPkgconfig.cmake b/cmake/OpenCVGenPkgconfig.cmake
-index 183c56d..180210d 100644
---- a/cmake/OpenCVGenPkgconfig.cmake
-+++ b/cmake/OpenCVGenPkgconfig.cmake
-@@ -19,9 +19,11 @@ endif()
- set(OpenCV_LIB_COMPONENTS "")
- set(OpenCV_EXTRA_COMPONENTS "")
- foreach(m ${OPENCV_MODULES_PUBLIC})
- list(INSERT OpenCV_LIB_COMPONENTS 0 ${${m}_MODULE_DEPS_${ocv_optkind}} ${m})
- if(${m}_EXTRA_DEPS_${ocv_optkind})
-+ ocv_list_reverse(${m}_EXTRA_DEPS_${ocv_optkind})
- list(INSERT OpenCV_EXTRA_COMPONENTS 0 ${${m}_EXTRA_DEPS_${ocv_optkind}})
-+ ocv_list_reverse(${m}_EXTRA_DEPS_${ocv_optkind})
- endif()
- endforeach()
-
---
-2.1.4
-
diff --git a/src/opencv-5-fix-in-bad-dir.patch b/src/opencv-5-fix-in-bad-dir.patch
deleted file mode 100644
index 3d28d24..0000000
--- a/src/opencv-5-fix-in-bad-dir.patch
+++ /dev/null
@@ -1,65 +0,0 @@
-This file is part of MXE. See LICENSE.md for licensing information.
-
-Contains ad hoc patches for cross building.
-
-From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
-From: Boris Nagaev <bnagaev@gmail.com>
-Date: Sun, 20 Dec 2015 18:14:56 +0300
-Subject: [PATCH] fix CMake error if a directory contains ++
-
-See https://github.com/mxe/mxe/issues/1091
-
-diff --git a/cmake/OpenCVModule.cmake b/cmake/OpenCVModule.cmake
-index 1111111..2222222 100644
---- a/cmake/OpenCVModule.cmake
-+++ b/cmake/OpenCVModule.cmake
-@@ -364,12 +364,16 @@ function(__ocv_resolve_dependencies)
- # process private deps
- foreach(m ${OPENCV_MODULES_BUILD})
- foreach(d ${OPENCV_MODULE_${m}_PRIVATE_REQ_DEPS})
-- if(NOT (";${deps_${m}};" MATCHES ";${d};"))
-+ # can't use MATCH because file paths can include regexp special chars
-+ string(FIND ";${deps_${m}};" ";${d};" d_offset)
-+ if(${d_offset} EQUAL -1)
- list(APPEND deps_${m} ${d})
- endif()
- endforeach()
- foreach(d ${OPENCV_MODULE_${m}_PRIVATE_OPT_DEPS})
-- if(NOT (";${deps_${m}};" MATCHES ";${d};"))
-+ # can't use MATCH because file paths can include regexp special chars
-+ string(FIND ";${deps_${m}};" ";${d};" d_offset)
-+ if(${d_offset} EQUAL -1)
- if(HAVE_${d} OR TARGET ${d})
- list(APPEND deps_${m} ${d})
- endif()
-diff --git a/cmake/OpenCVPCHSupport.cmake b/cmake/OpenCVPCHSupport.cmake
-index 1111111..2222222 100644
---- a/cmake/OpenCVPCHSupport.cmake
-+++ b/cmake/OpenCVPCHSupport.cmake
-@@ -54,7 +54,9 @@ MACRO(_PCH_GET_COMPILE_FLAGS _out_compile_flags)
-
- GET_DIRECTORY_PROPERTY(DIRINC INCLUDE_DIRECTORIES )
- FOREACH(item ${DIRINC})
-- if(item MATCHES "^${OpenCV_SOURCE_DIR}/modules/")
-+ # can't use MATCH because file paths can include regexp special chars
-+ string(FIND "${item}" "${OpenCV_SOURCE_DIR}/modules/" modules_offset)
-+ if(${modules_offset} EQUAL 0)
- LIST(APPEND ${_out_compile_flags} "${_PCH_include_prefix}\"${item}\"")
- else()
- LIST(APPEND ${_out_compile_flags} "${_PCH_isystem_prefix}\"${item}\"")
-diff --git a/cmake/OpenCVUtils.cmake b/cmake/OpenCVUtils.cmake
-index 1111111..2222222 100644
---- a/cmake/OpenCVUtils.cmake
-+++ b/cmake/OpenCVUtils.cmake
-@@ -39,7 +39,10 @@ function(ocv_include_directories)
- set(__add_before "")
- foreach(dir ${ARGN})
- get_filename_component(__abs_dir "${dir}" ABSOLUTE)
-- if("${__abs_dir}" MATCHES "^${OpenCV_SOURCE_DIR}" OR "${__abs_dir}" MATCHES "^${OpenCV_BINARY_DIR}")
-+ # can't use MATCH because file paths can include regexp special chars
-+ string(FIND "${__abs_dir}" "${OpenCV_SOURCE_DIR}" OpenCV_SOURCE_DIR_offset)
-+ string(FIND "${__abs_dir}" "${OpenCV_BINARY_DIR}" OpenCV_BINARY_DIR_offset)
-+ if($OpenCV_BINARY_DIR_offset} EQUAL 0 OR ${OpenCV_BINARY_DIR_offset} EQUAL 0)
- list(APPEND __add_before "${dir}")
- else()
- include_directories(AFTER SYSTEM "${dir}")
diff --git a/src/opencv.mk b/src/opencv.mk
index f847d5b..5a90727 100644
--- a/src/opencv.mk
+++ b/src/opencv.mk
@@ -4,13 +4,13 @@ PKG := opencv
$(PKG)_WEBSITE := http://opencv.org/
$(PKG)_DESCR := OpenCV
$(PKG)_IGNORE :=
-$(PKG)_VERSION := 2.4.10
-$(PKG)_CHECKSUM := 1bf4cb87283797fd91669d4f90b622a677a903c20b4a577b7958a2164f7596c6
+$(PKG)_VERSION := 3.3.0
+$(PKG)_CHECKSUM := 3546c3837f88177c898e4172942da7a3ca6c4e8e98a33d0cbccb2b499167c5ba
$(PKG)_SUBDIR := $(PKG)-$($(PKG)_VERSION)
$(PKG)_FILE := opencv-$($(PKG)_VERSION).zip
$(PKG)_URL := https://$(SOURCEFORGE_MIRROR)/project/$(PKG)library/$(PKG)-unix/$($(PKG)_VERSION)/$($(PKG)_FILE)
$(PKG)_URL_2 := https://distfiles.macports.org/opencv/$($(PKG)_FILE)
-$(PKG)_DEPS := gcc eigen ffmpeg jasper jpeg lcms1 libpng openexr tiff xz zlib
+$(PKG)_DEPS := gcc eigen ffmpeg jasper jpeg lcms1 libpng libwebp openexr protobuf tiff xz zlib
define $(PKG)_UPDATE
$(WGET) -q -O- 'https://sourceforge.net/projects/opencvlibrary/files/opencv-unix/' | \
@@ -39,10 +39,13 @@ define $(PKG)_BUILD
-DBUILD_TIFF=OFF \
-DBUILD_JASPER=OFF \
-DBUILD_JPEG=OFF \
+ -DBUILD_WEBP=OFF \
+ -DBUILD_PROTOBUF=OFF \
+ -DPROTOBUF_UPDATE_FILES=ON \
-DBUILD_PNG=OFF \
-DBUILD_OPENEXR=OFF \
-DCMAKE_VERBOSE=ON \
- -DCMAKE_CXX_FLAGS='-D_WIN32_WINNT=0x0500 -D__STDC_LIMIT_MACROS'
+ -DCMAKE_CXX_FLAGS='-D_WIN32_WINNT=0x0500'
# install
$(MAKE) -C '$(BUILD_DIR)' -j '$(JOBS)' VERBOSE=1
@@ -53,11 +56,13 @@ define $(PKG)_BUILD
# opencv builds it's own libIlmImf.a
$(if $(findstring x86_64-w64-mingw32,$(TARGET)),\
$(SED) -i 's/OpenEXR//' '$(BUILD_DIR)/unix-install/opencv.pc')
+
$(SED) -i 's,share/OpenCV/3rdparty/,,g' '$(BUILD_DIR)/unix-install/opencv.pc'
+
$(INSTALL) -m755 '$(BUILD_DIR)/unix-install/opencv.pc' '$(PREFIX)/$(TARGET)/lib/pkgconfig'
'$(TARGET)-g++' \
- -W -Wall -Werror -ansi -pedantic \
- '$(1)/samples/c/fback_c.c' -o '$(PREFIX)/$(TARGET)/bin/test-opencv.exe' \
+ -W -Wall -Werror -ansi \
+ '$(SOURCE_DIR)/samples/cpp/fback.cpp' -o '$(PREFIX)/$(TARGET)/bin/test-opencv.exe' \
`'$(TARGET)-pkg-config' opencv --cflags --libs`
endef
diff --git a/src/pcre.mk b/src/pcre.mk
index 9113ab2..aa13b78 100644
--- a/src/pcre.mk
+++ b/src/pcre.mk
@@ -1,7 +1,7 @@
# This file is part of MXE. See LICENSE.md for licensing information.
PKG := pcre
-$(PKG)_WEBSITE := http://www.pcre.org/
+$(PKG)_WEBSITE := https://www.pcre.org/
$(PKG)_DESCR := PCRE
$(PKG)_IGNORE :=
$(PKG)_VERSION := 8.41
diff --git a/src/pcre2.mk b/src/pcre2.mk
index 7750bda..b1de6cb 100644
--- a/src/pcre2.mk
+++ b/src/pcre2.mk
@@ -1,7 +1,7 @@
# This file is part of MXE. See LICENSE.md for licensing information.
PKG := pcre2
-$(PKG)_WEBSITE := http://www.pcre.org/
+$(PKG)_WEBSITE := https://www.pcre.org/
$(PKG)_DESCR := PCRE2
$(PKG)_IGNORE :=
$(PKG)_VERSION := 10.30
diff --git a/src/vtk.mk b/src/vtk.mk
index 1e2528b..47d5419 100644
--- a/src/vtk.mk
+++ b/src/vtk.mk
@@ -6,12 +6,12 @@ $(PKG)_VERSION := 8.0.0
$(PKG)_CHECKSUM := c7e727706fb689fb6fd764d3b47cac8f4dc03204806ff19a10dfd406c6072a27
$(PKG)_SUBDIR := VTK-$($(PKG)_VERSION)
$(PKG)_FILE := $($(PKG)_SUBDIR).tar.gz
-$(PKG)_URL := http://www.vtk.org/files/release/$(call SHORT_PKG_VERSION,$(PKG))/$($(PKG)_FILE)
+$(PKG)_URL := https://www.vtk.org/files/release/$(call SHORT_PKG_VERSION,$(PKG))/$($(PKG)_FILE)
$(PKG)_QT_VERSION := 5
$(PKG)_DEPS := gcc hdf5 qtbase qttools libpng expat libxml2 jsoncpp tiff freetype lz4 hdf5 libharu glew
define $(PKG)_UPDATE
- $(WGET) -q -O- 'http://vtk.org/gitweb?p=VTK.git;a=tags' | \
+ $(WGET) -q -O- 'https://vtk.org/gitweb?p=VTK.git;a=tags' | \
grep 'refs/tags/v[0-9.]*"' | \
$(SED) 's,.*refs/tags/v\(.*\)".*,\1,g;' | \
grep -v rc | \
diff --git a/tools/build-pkg.lua b/tools/build-pkg.lua
index 3aaa08a..bed370d 100755
--- a/tools/build-pkg.lua
+++ b/tools/build-pkg.lua
@@ -896,10 +896,6 @@ local function progressPrinter(items)
return printer
end
-local function isEmpty(files)
- return #files == 1
-end
-
-- build all packages, save filelist to list file
-- prev_files is passed only to second pass.
local function buildPackages(items, item2deps, pass, prev_item2files)
@@ -953,40 +949,12 @@ local function buildPackages(items, item2deps, pass, prev_item2files)
end
local function makeDebs(items, item2deps, item2ver, item2files)
- -- start from building non-empty packages
- local to_build = {}
for _, item in ipairs(items) do
+ local deps = assert(item2deps[item], item)
+ local ver = assert(item2ver[item], item)
local files = assert(item2files[item], item)
- if not isEmpty(files) then
- table.insert(to_build, item)
- end
+ makeDeb(item, files, deps, ver)
end
- local built = {}
- repeat
- local missing_deps_set = {}
- for _, item in ipairs(to_build) do
- local deps = assert(item2deps[item], item)
- local ver = assert(item2ver[item], item)
- local files = assert(item2files[item], item)
- for _, dep in ipairs(deps) do
- local dep_files = item2files[dep]
- if isEmpty(dep_files) then
- log('Item %s depends on ' ..
- 'empty item %s', item, dep)
- missing_deps_set[dep] = true
- end
- end
- makeDeb(item, files, deps, ver)
- built[item] = true
- end
- -- empty packages built to satisfy non-empty
- to_build = {}
- for item in pairs(missing_deps_set) do
- if not built[item] then
- table.insert(to_build, item)
- end
- end
- until #to_build == 0
end
local function getMxeVersion()