diff --git a/config.sh b/config.sh index 1981e60b..ca089dad 100644 --- a/config.sh +++ b/config.sh @@ -40,7 +40,6 @@ function pre_build { echo '-----------------' else echo "Running for linux" - export LDFLAGS="-Wl,--no-as-needed -Wl,--no-undefined ${LDFLAGS}" fi qmake -query } diff --git a/docker/Dockerfile_i686 b/docker/Dockerfile_i686 index 49c2d32c..c39331d0 100644 --- a/docker/Dockerfile_i686 +++ b/docker/Dockerfile_i686 @@ -1,10 +1,10 @@ FROM quay.io/pypa/manylinux1_i686:latest -RUN wget --no-check-certificate https://download.qt.io/official_releases/qt/4.8/4.8.7/qt-everywhere-opensource-src-4.8.7.tar.gz && \ +RUN curl -O -L https://download.qt.io/archive/qt/4.8/4.8.7/qt-everywhere-opensource-src-4.8.7.tar.gz && \ tar -xf qt-everywhere-opensource-src-4.8.7.tar.gz && \ cd qt-everywhere* && \ - ./configure -prefix /opt/Qt4.8.7 -release -opensource -confirm-license -qtnamespace Qt4 && \ - gmake && \ + ./configure -prefix /opt/Qt4.8.7 -release -opensource -confirm-license && \ + gmake -j5 && \ gmake install && \ cd .. && \ rm -rf qt-everywhere-opensource-src-4.8.7 && \ @@ -13,7 +13,7 @@ RUN wget --no-check-certificate https://download.qt.io/official_releases/qt/4.8/ ENV QTDIR /opt/Qt4.8.7 ENV PATH "$QTDIR/bin:$PATH" -RUN wget --no-check-certificate https://cmake.org/files/v3.9/cmake-3.9.0.tar.gz && \ +RUN curl -O -L https://cmake.org/files/v3.9/cmake-3.9.0.tar.gz && \ tar -zxf cmake-3.9.0.tar.gz && \ cd cmake-3.9.0 && \ yum -y install curl-devel zlib-devel && \ diff --git a/docker/Dockerfile_x86_64 b/docker/Dockerfile_x86_64 index 51db79db..b855a73b 100644 --- a/docker/Dockerfile_x86_64 +++ b/docker/Dockerfile_x86_64 @@ -1,10 +1,10 @@ FROM quay.io/pypa/manylinux1_x86_64:latest -RUN wget --no-check-certificate https://download.qt.io/official_releases/qt/4.8/4.8.7/qt-everywhere-opensource-src-4.8.7.tar.gz && \ +RUN curl -O -L https://download.qt.io/archive/qt/4.8/4.8.7/qt-everywhere-opensource-src-4.8.7.tar.gz && \ tar -xf qt-everywhere-opensource-src-4.8.7.tar.gz && \ cd qt-everywhere* && \ - ./configure -prefix /opt/Qt4.8.7 -release -opensource -confirm-license -qtnamespace Qt4 && \ - gmake && \ + ./configure -prefix /opt/Qt4.8.7 -release -opensource -confirm-license && \ + gmake -j5 && \ gmake install && \ cd .. && \ rm -rf qt-everywhere-opensource-src-4.8.7 && \ @@ -13,7 +13,7 @@ RUN wget --no-check-certificate https://download.qt.io/official_releases/qt/4.8/ ENV QTDIR /opt/Qt4.8.7 ENV PATH "$QTDIR/bin:$PATH" -RUN wget --no-check-certificate https://cmake.org/files/v3.9/cmake-3.9.0.tar.gz && \ +RUN curl -O -L https://cmake.org/files/v3.9/cmake-3.9.0.tar.gz && \ tar -zxf cmake-3.9.0.tar.gz && \ cd cmake-3.9.0 && \ yum -y install curl-devel zlib-devel && \ diff --git a/patches/patch1.patch b/patches/patch1.patch deleted file mode 100644 index 63fc128d..00000000 --- a/patches/patch1.patch +++ /dev/null @@ -1,85 +0,0 @@ ---- opencv/modules/highgui/src/window_QT.h 2018-06-28 13:13:55.119434000 +0300 -+++ opencv/modules/highgui/src/window_QT_patched.h 2018-06-30 17:35:55.145192900 +0300 -@@ -46,43 +46,51 @@ - #define QT_NO_DEBUG_OUTPUT - #endif - --#if defined( HAVE_QT_OPENGL ) --#include --#include --#endif -- --#include - #include --#include - #include --#include --#include --#include --#include --#include --#include --#include --#include --#include --#include - #include --#include --#include --#include --#include --#include --#include --#include --#include --#include --#include -- --#include - #include -+#include - #include --#include --#include -+#include -+#include - #include -+#include -+#include -+ -+#if defined( HAVE_QT_OPENGL ) -+#include -+#include -+#endif -+ -+QT_BEGIN_NAMESPACE -+ -+class QAbstractEventDispatcher; -+class QFile; -+class QSizePolicy; -+class QInputDialog; -+class QBoxLayout; -+class QSettings; -+class QTimer; -+class QtConcurrentRun; -+class QWaitCondition; -+class QKeyEvent; -+class QMetaObject; -+class QLabel; -+class QIODevice; -+class QShortcut; -+class QStatusBar; -+class QFileInfo; -+class QDate; -+class QFileDialog; -+class QToolBar; -+class QHBoxLayout; -+ -+class QAction; -+class QButtonGroup; -+class QMenu; -+ -+QT_END_NAMESPACE - - //start private enum - enum { CV_MODE_NORMAL = 0, CV_MODE_OPENGL = 1 }; diff --git a/patches/patch2.patch b/patches/patch2.patch deleted file mode 100644 index 8ca8fbb3..00000000 --- a/patches/patch2.patch +++ /dev/null @@ -1,41 +0,0 @@ ---- opencv/modules/highgui/src/window_QT.cpp 2018-06-30 01:04:51.649121800 +0300 -+++ opencv/modules/highgui/src/window_QT_patched.cpp 2018-06-30 17:09:28.697256300 +0300 -@@ -46,6 +46,30 @@ - - #include - -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+ -+#include -+#include -+#include -+ - #include - - #ifdef _WIN32 -@@ -60,7 +84,6 @@ - #endif - #endif - -- - //Static and global first - static GuiReceiver *guiMainThread = NULL; - static int parameterSystemC = 1; diff --git a/setup.py b/setup.py index d7385ff1..6874e290 100644 --- a/setup.py +++ b/setup.py @@ -109,9 +109,6 @@ def main(): # OS-specific components if (sys.platform == 'darwin' or sys.platform.startswith('linux')) and not build_headless: cmake_args.append("-DWITH_QT=4") - # Apply Qt namespace patches to OpenCV GUI code - subprocess.check_call("patch -p0 < patches/patch1.patch", shell=True) - subprocess.check_call("patch -p0 < patches/patch2.patch", shell=True) if build_headless: # it seems that cocoa cannot be disabled so on macOS the package is not truly headless