]> git.pld-linux.org Git - packages/opencv.git/blame - opencv.spec
- files updated
[packages/opencv.git] / opencv.spec
CommitLineData
901927d3 1%bcond_with xine
901927d3
AM
2Summary: A library of programming functions mainly aimed at real time computer vision
3Name: opencv
95daeb66 4Version: 2.1.0
4bd2eae7 5Release: 1
901927d3
AM
6Epoch: 1
7License: BSD
8Group: Libraries
95daeb66
AM
9Source0: http://downloads.sourceforge.net/opencvlibrary/OpenCV-%{version}.tar.bz2
10# Source0-md5: 1d71584fb4e04214c0085108f95e24c8
11Patch0: %{name}-2.0.0-libpng14.patch
12Patch1: %{name}-2.1.0-mmap.patch
13Patch2: %{name}-2.1.0-multilib.patch
54551f29 14Patch3: %{name}-cflags.patch
901927d3 15URL: http://opencv.willowgarage.com
95daeb66 16BuildRequires: cmake
901927d3
AM
17BuildRequires: ffmpeg-devel
18BuildRequires: jasper-devel
19BuildRequires: libdc1394-devel
20BuildRequires: libjpeg-devel
21BuildRequires: libpng-devel
22BuildRequires: libraw1394-devel
23BuildRequires: libtiff-devel
148338c5 24BuildRequires: libtool
af6d2888 25BuildRequires: pkgconfig
901927d3
AM
26BuildRequires: python-devel
27BuildRequires: rpm-pythonprov
996927aa 28BuildRequires: swig-python
901927d3
AM
29BuildRequires: zlib-devel
30%pyrequires_eq python-libs
31%{?with_xine:BuildRequires: xine-lib-devel}
32BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
33
34%description
35OpenCV (Open Source Computer Vision) is a library of programming
36functions mainly aimed at real time computer vision.
37
38Example applications of the OpenCV library are Human-Computer
39Interaction (HCI); Object Identification, Segmentation and
40Recognition; Face Recognition; Gesture Recognition; Motion Tracking,
41Ego Motion, Motion Understanding; Structure From Motion (SFM); Stereo
42and Multi-Camera Calibration and Depth Computation; Mobile Robotics.
43
44%package devel
45Summary: Header files and develpment documentation for opencv
46Group: Development/Libraries
47Requires: %{name} = %{epoch}:%{version}-%{release}
48
49%description devel
50Header files and opencv documentation.
51
52%package static
53Summary: Static opencv library
54Group: Development/Libraries
55Requires: %{name}-devel = %{epoch}:%{version}-%{release}
56
57%description static
58This package contains the static library used for development.
59
60%package -n python-opencv
61Summary: OpenCV Python bindings
62Group: Development/Languages/Python
63%pyrequires_eq python
cd1f0136 64Requires: %{name} = %{epoch}:%{version}-%{release}
901927d3
AM
65
66%description -n python-opencv
67OpenCV Python bindings.
68
69%prep
95daeb66 70%setup -q -n OpenCV-%{version}
54551f29 71
72%undos src/ml/CMakeLists.txt
73%undos CMakeLists.txt
74%undos src/cv/CMakeLists.txt
75%undos src/cxcore/CMakeLists.txt
76
148338c5 77%patch0 -p0
95daeb66 78%patch1 -p0
29d82ddf 79%patch2 -p1
54551f29 80%patch3 -p1
148338c5 81
901927d3 82%build
95daeb66
AM
83install -d build
84cd build
85%cmake \
4bd2eae7 86 -DCMAKE_INSTALL_PREFIX=%{_prefix} \
901927d3 87%ifarch i686 pentium4 athlon %{x8664}
95daeb66
AM
88 -DENABLE_SSE2=ON \
89%endif
90 -DBUILD_NEW_PYTHON_SUPPORT=ON \
91%if %{with xine}
92 -DWITH_XINE=ON \
93%endif
94 -DWITH_GSTREAMER=OFF \
95 -DWITH_1394=ON \
96 -DWITH_FFMPEG=ON \
97 -DWITH_GTK=ON \
4bd2eae7 98 -DWITH_V4L=ON \
95daeb66 99%if "%{_lib}" == "lib64"
4bd2eae7 100 -DLIB_SUFFIX=64 \
901927d3 101%endif
95daeb66 102 ../
54551f29 103
95daeb66
AM
104%{__make} \
105 VERBOSE=1
901927d3
AM
106
107%install
108rm -rf $RPM_BUILD_ROOT
109
95daeb66 110%{__make} -C build install \
901927d3
AM
111 DESTDIR=$RPM_BUILD_ROOT
112
4bd2eae7
AM
113install -d $RPM_BUILD_ROOT%{_pkgconfigdir}
114install build/unix-install/opencv.pc $RPM_BUILD_ROOT%{_pkgconfigdir}
115
901927d3
AM
116%clean
117rm -rf $RPM_BUILD_ROOT
118
119%post -p /sbin/ldconfig
120%postun -p /sbin/ldconfig
121
122%files
123%defattr(644,root,root,755)
901927d3
AM
124%attr(755,root,root) %{_bindir}/*
125%attr(755,root,root) %{_libdir}/lib*so.*.*
4bd2eae7
AM
126%attr(755,root,root) %ghost %{_libdir}/lib*.so.2.1
127%dir %{_datadir}/opencv
128%{_datadir}/opencv/doc
129%{_datadir}/opencv/haarcascades
130%{_datadir}/opencv/lbpcascades
901927d3
AM
131
132%files devel
133%defattr(644,root,root,755)
134%attr(755,root,root) %{_libdir}/lib*.so
901927d3 135%{_includedir}/opencv
4bd2eae7 136%{_datadir}/opencv/OpenCVConfig.cmake
901927d3
AM
137%{_pkgconfigdir}/*.pc
138
4bd2eae7
AM
139#%files static
140#%defattr(644,root,root,755)
141#%{_libdir}/lib*.a
901927d3
AM
142
143%files -n python-opencv
144%defattr(644,root,root,755)
4bd2eae7 145%attr(755,root,root) %{py_sitedir}/cv.so
This page took 0.780439 seconds and 4 git commands to generate.