Some fix that doesn't prevent a FTBFS still

This commit is contained in:
Nicolas Chauvet 2011-02-03 18:01:15 +01:00
parent 1292d04d83
commit 6f18b86f65
3 changed files with 37 additions and 1 deletions

11
OpenCV-2.2-gcc46.patch Normal file
View File

@ -0,0 +1,11 @@
diff -up OpenCV-2.2.0/modules/core/include/opencv2/core/core.hpp.gcc46 OpenCV-2.2.0/modules/core/include/opencv2/core/core.hpp
--- OpenCV-2.2.0/modules/core/include/opencv2/core/core.hpp.gcc46 2010-12-05 04:35:24.000000000 +0100
+++ OpenCV-2.2.0/modules/core/include/opencv2/core/core.hpp 2011-02-02 16:44:02.177243993 +0100
@@ -52,6 +52,7 @@
#ifdef __cplusplus
#ifndef SKIP_INCLUDES
+#include <cstddef>
#include <limits.h>
#include <algorithm>
#include <cmath>

13
OpenCV-2.2-nov4l1.patch Normal file
View File

@ -0,0 +1,13 @@
diff -up OpenCV-2.2.0/modules/highgui/src/cap_v4l.cpp.nov4l1 OpenCV-2.2.0/modules/highgui/src/cap_v4l.cpp
--- OpenCV-2.2.0/modules/highgui/src/cap_v4l.cpp.nov4l1 2011-02-02 16:55:22.844244001 +0100
+++ OpenCV-2.2.0/modules/highgui/src/cap_v4l.cpp 2011-02-02 16:53:22.224244002 +0100
@@ -214,7 +214,9 @@ make & enjoy!
#include <sys/types.h>
#include <sys/mman.h>
+#ifdef HAVE_LINUX_VIDEODEV_H
#include <linux/videodev.h>
+#endif
#include <string.h>
#include <stdlib.h>

View File

@ -4,7 +4,7 @@
Name: opencv
Version: 2.2.0
Release: 1%{?dist}
Release: 2%{?dist}
Summary: Collection of algorithms for computer vision
Group: Development/Libraries
@ -22,6 +22,8 @@ Patch3: OpenCV-2.2-fixpc.patch
# the cmake bump, if that's preferable -- Rex
Patch4: opencv-2.1.0-opencvconfig.patch
Patch5: OpenCV-2.2-numpy.patch
Patch6: OpenCV-2.2-gcc46.patch
Patch7: OpenCV-2.2-nov4l1.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: libtool
@ -101,6 +103,8 @@ This package contains Python bindings for the OpenCV library.
%patch3 -p1 -b .fixpc
%patch4 -p1 -b .opencvconfig
%patch5 -p1 -b .numpy
%patch6 -p1 -b .gcc46
%patch7 -p1 -b .nov4l1
#Save some convant headers for now:
cp -p 3rdparty/include/cblas.h 3rdparty
@ -155,6 +159,9 @@ sed -i -e 's/ENABLE_SSE2 ON/ENABLE_SSE2 OFF/' CMakeLists.txt
-DINSTALL_C_EXAMPLES=1 \
-DINSTALL_PYTHON_EXAMPLES=1 \
-DWITH_LAPACK=1 \
%if 0%{?fedora} >= 15
-DWITH_V4L=0 \
%endif
.
make VERBOSE=1 %{?_smp_mflags}
@ -237,6 +244,11 @@ rm -rf $RPM_BUILD_ROOT
%changelog
* Wed Feb 02 2011 Nicolas Chauvet <kwizart@gmail.com> - 2.2.0-2
- Fix with gcc46
- Disable V4L as V4L1 is disabled for Fedora 15
This still needs work to escape from FTBFS
* Thu Jan 06 2011 Nicolas Chauvet <kwizart@gmail.com> - 2.2.0-1
- Update to 2.2.0
- Disable -msse and -msse2 on x86_32