Spec URL: https://smani.fedorapeople.org/review/mingw-opencv.spec SRPM URL: https://smani.fedorapeople.org/review/mingw-opencv-4.2.0-1.fc33.src.rpm Description: MinGW Windows OpenCV library Fedora Account System Username: smani
# RUN opencv-clean.sh TO PREPARE TARBALLS FOR FEDORA - You need to add the script as a Source - My local build is failing with tons of errors. I'll try Koji. Errors are like: In file included from /builddir/build/BUILD/opencv-4.2.0/build_win32/modules/dnn/opencv-caffe.pb.cc:4: /builddir/build/BUILD/opencv-4.2.0/build_win32/modules/dnn/opencv-caffe.pb.h:21322:62: error: invalid use of incomplete type 'class opencv_caffe::PriorBoxParameter' 21322 | inline void PriorBoxParameter::_internal_set_step(float value) { | ^ /builddir/build/BUILD/opencv-4.2.0/build_win32/modules/dnn/opencv-caffe.pb.cc:985:51: error: incomplete type 'opencv_caffe::NonMaximumSuppressionParameter' used in nested name specifier 985 | ::opencv_caffe::NonMaximumSuppressionParameter::InitAsDefaultInstance(); | ^~~~~~~~~~~~~~~~~~~~~
It still fails with many errors on Koji: https://koji.fedoraproject.org/koji/taskinfo?taskID=46093212
Maybe this is due to this part: CMake Warning at /usr/share/cmake/Modules/FindProtobuf.cmake:500 (message): Protobuf compiler version 3.12.3 doesn't match library version 3.11.4 Call Stack (most recent call first): cmake/OpenCVFindProtobuf.cmake:26 (find_package) CMakeLists.txt:676 (include) -- Performing Test HAVE_C_WNO_UNUSED_VARIABLE -- Performing Test HAVE_C_WNO_UNUSED_VARIABLE - Success -- Performing Test HAVE_C_WNO_SHADOW -- Performing Test HAVE_C_WNO_SHADOW - Success -- ADE: Download: v0.1.1f.zip -- Try 1 failed -- ======================================================================= Couldn't download files from the Internet. Please check the Internet access on this host. ======================================================================= CMake Warning at cmake/OpenCVDownload.cmake:202 (message): ADE: Download failed: 6;"Couldn't resolve host name" For details please refer to the download log file: /builddir/build/BUILD/opencv-4.2.0/build_win32/CMakeDownloadLog.txt Call Stack (most recent call first): modules/gapi/cmake/DownloadADE.cmake:10 (ocv_download) modules/gapi/cmake/init.cmake:19 (include) cmake/OpenCVModule.cmake:312 (include) cmake/OpenCVModule.cmake:375 (_add_modules_1) modules/CMakeLists.txt:7 (ocv_glob_modules) -- Looking for dshow.h -- Looking for dshow.h - found -- Performing Test HAVE_CXX_WNO_UNDEF -- Performing Test HAVE_CXX_WNO_UNDEF - Success -- Caffe: NO CMake Warning at /usr/share/cmake/Modules/FindProtobuf.cmake:500 (message): Protobuf compiler version 3.12.3 doesn't match library version 3.11.4
Ok bumping mingw-protobuf to 3.12.3 seems co fix the issue.
Another error: error: File not found: /builddir/build/BUILDROOT/mingw-opencv-4.2.0-1.fc33.x86_64/usr/i686-w64-mingw32/sys-root/mingw/lib/python3.9/site-packages/cv2-cpython-38.dll Deprecated external dependency generator is used! File not found: /builddir/build/BUILDROOT/mingw-opencv-4.2.0-1.fc33.x86_64/usr/i686-w64-mingw32/sys-root/mingw/lib/python3.9/site-packages/cv2-cpython-38.dll Child return code was: 1 We got Python 3.9 now so this probably needs to be adjusted: %files -n mingw32-python3-%{pkgname} %{mingw32_python3_sitearch}/cv2-cpython-%{python_version_nodots}.dll %files -n mingw64-python3-%{pkgname} %{mingw64_python3_sitearch}/cv2-cpython-%{python_version_nodots}.dll
Should rather be %files -n mingw32-python3-%{pkgname} %{mingw32_python3_sitearch}/cv2-cpython-%{mingw32_python3_version_nodots}.dll and %files -n mingw64-python3-%{pkgname} %{mingw64_python3_sitearch}/cv2-cpython-%{mingw64_python3_version_nodots}.dll I've sent a PR to mingw-python3 to add these macros: https://src.fedoraproject.org/rpms/mingw-python3/pull-request/1
Spec URL: https://smani.fedorapeople.org/review/mingw-opencv.spec SRPM URL: https://smani.fedorapeople.org/review/mingw-opencv-4.2.0-2.fc33.src.rpm %changelog * Sat Jun 27 2020 Sandro Mani <manisandro> - 4.3.0-2 - Use %%{mingw32,64_python3_version_nodots} * Sun May 31 2020 Sandro Mani <manisandro> - 4.3.0-1 - Update to 4.3.0
Missed this: # RUN opencv-clean.sh TO PREPARE TARBALLS FOR FEDORA - You need to add the script to generate the tarball as a Source, it should end up in the SRPM.
Ups yes indeed Spec URL: https://smani.fedorapeople.org/review/mingw-opencv.spec SRPM URL: https://smani.fedorapeople.org/review/mingw-opencv-4.2.0-3.fc33.src.rpm %changelog * Tue Jun 30 2020 Sandro Mani <manisandro> - 4.3.0-3 - Add opencv-clean.sh to sources
Package approved.
(fedscm-admin): The Pagure repository was created at https://src.fedoraproject.org/rpms/mingw-opencv