public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [rpms/opencv] opencv5: Small fix to build with Pyhton-3.7
@ 2026-08-28 13:30
0 siblings, 0 replies; only message in thread
From: @ 2026-08-28 13:30 UTC (permalink / raw)
To: git-commits
A new commit has been pushed.
Repo : rpms/opencv
Branch : opencv5
Commit : c8823019a699b9a831c8f243f0f44eeb677ee98f
Author : Sérgio M. Basto <sergio@serjux.com>
Date : 2018-07-12T03:53:41+01:00
Stats : +19/-2 in 2 file(s)
URL : https://src.fedoraproject.org/rpms/opencv/c/c8823019a699b9a831c8f243f0f44eeb677ee98f?branch=opencv5
Log:
Small fix to build with Pyhton-3.7
---
diff --git a/opencv-3.4.1-python37.patch b/opencv-3.4.1-python37.patch
new file mode 100644
index 0000000..321d61a
--- /dev/null
+++ b/opencv-3.4.1-python37.patch
@@ -0,0 +1,13 @@
+diff --git a/modules/python/src2/cv2.cpp b/modules/python/src2/cv2.cpp
+index fab60fd03..2c48041dc 100644
+--- a/modules/python/src2/cv2.cpp
++++ b/modules/python/src2/cv2.cpp
+@@ -886,7 +886,7 @@ bool pyopencv_to(PyObject* obj, String& value, const char* name)
+ (void)name;
+ if(!obj || obj == Py_None)
+ return true;
+- char* str = PyString_AsString(obj);
++ const char* str = PyString_AsString(obj);
+ if(!str)
+ return false;
+ value = String(str);
diff --git a/opencv.spec b/opencv.spec
index 24a70cb..c2ede94 100644
--- a/opencv.spec
+++ b/opencv.spec
@@ -47,7 +47,7 @@
Name: opencv
Version: 3.4.1
-Release: 4%{?dist}
+Release: 5%{?dist}
Summary: Collection of algorithms for computer vision
# This is normal three clause BSD.
License: BSD
@@ -63,10 +63,11 @@ Source1: %{name}_contrib-clean-%{version}.tar.gz
# https://bugzilla.redhat.com/1031312
Patch1: opencv-3.4.1-cmake_paths.patch
Patch2: opencv-3.4.1-cmake_va_intel_fix.patch
+Patch3: opencv-3.4.1-python37.patch
+
BuildRequires: libtool
BuildRequires: cmake >= 2.6.3
BuildRequires: chrpath
-
%{?with_eigen2:BuildRequires: eigen2-devel}
%{?with_eigen3:BuildRequires: eigen3-devel}
BuildRequires: gtk3-devel
@@ -394,6 +395,9 @@ popd
%{_libdir}/libopencv_xphoto.so.%{abiver}*
%changelog
+* Wed Jul 11 2018 Sérgio Basto <sergio@serjux.com> - 3.4.1-5
+- Small fix to build with Pyhton-3.7
+
* Tue Jun 19 2018 Miro Hrončok <mhroncok@redhat.com> - 3.4.1-4
- Rebuilt for Python 3.7
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2026-08-28 13:30 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-08-28 13:30 [rpms/opencv] opencv5: Small fix to build with Pyhton-3.7
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox