[packages/opencv] - added cmake patch (fixes undefined list_filterout macro under some conditions)

qboosh qboosh at pld-linux.org
Tue May 19 19:25:09 CEST 2015


commit dadee4672641272b129410bc097f5c199bb4fb43
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Tue May 19 19:26:51 2015 +0200

    - added cmake patch (fixes undefined list_filterout macro under some conditions)

 opencv-cmake.patch | 34 ++++++++++++++++++++++++++++++++++
 opencv.spec        |  2 ++
 2 files changed, 36 insertions(+)
---
diff --git a/opencv.spec b/opencv.spec
index a74feca..a71837b 100644
--- a/opencv.spec
+++ b/opencv.spec
@@ -55,6 +55,7 @@ Group:		Libraries
 Source0:	https://github.com/Itseez/opencv/archive/%{version}/%{name}-%{version}.tar.gz
 # Source0-md5:	fa06384719cb0be48183b4de972f0b2a
 Patch0:		%{name}-cflags.patch
+Patch1:		%{name}-cmake.patch
 Patch2:		%{name}-unicap-c++.patch
 Patch3:		%{name}-c.patch
 Patch4:		%{name}-gcc.patch
@@ -268,6 +269,7 @@ Wiązania Pythona do OpenCV.
 %undos modules/gpu/CMakeLists.txt
 
 %patch0 -p1
+%patch1 -p1
 %patch2 -p1
 %patch3 -p1
 %patch4 -p1
diff --git a/opencv-cmake.patch b/opencv-cmake.patch
new file mode 100644
index 0000000..14de6e2
--- /dev/null
+++ b/opencv-cmake.patch
@@ -0,0 +1,34 @@
+--- opencv-2.4.11/samples/gpu/CMakeLists.txt.orig	2015-02-25 13:10:31.000000000 +0100
++++ opencv-2.4.11/samples/gpu/CMakeLists.txt	2015-05-19 18:35:11.803554049 +0200
+@@ -4,6 +4,15 @@
+                                      opencv_superres)
+ ocv_check_dependencies(${OPENCV_GPU_SAMPLES_REQUIRED_DEPS})
+ 
++# remove all matching elements from the list
++MACRO(list_filterout lst regex)
++  foreach(item ${${lst}})
++    if(item MATCHES "${regex}")
++      list(REMOVE_ITEM ${lst} "${item}")
++    endif()
++  endforeach()
++ENDMACRO()
++
+ if(BUILD_EXAMPLES AND OCV_DEPENDENCIES_FOUND)
+   set(project "gpu")
+   string(TOUPPER "${project}" project_upper)
+@@ -69,15 +78,6 @@
+     endif()
+   ENDMACRO()
+ 
+-  # remove all matching elements from the list
+-  MACRO(list_filterout lst regex)
+-    foreach(item ${${lst}})
+-      if(item MATCHES "${regex}")
+-        list(REMOVE_ITEM ${lst} "${item}")
+-      endif()
+-    endforeach()
+-  ENDMACRO()
+-
+   file(GLOB all_samples RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.cpp)
+ 
+   if(NOT HAVE_OPENGL)
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/opencv.git/commitdiff/dadee4672641272b129410bc097f5c199bb4fb43



More information about the pld-cvs-commit mailing list