]> git.pld-linux.org Git - packages/opencv.git/blob - opencv.spec
- killed duplicate install
[packages/opencv.git] / opencv.spec
1 %bcond_with     xine
2 %define snap    pre1
3 Summary:        A library of programming functions mainly aimed at real time computer vision
4 Name:           opencv
5 Version:        1.1
6 Release:        0.%{snap}.3
7 Epoch:          1
8 License:        BSD
9 Group:          Libraries
10 Source0:        http://dl.sourceforge.net/opencvlibrary/%{name}-%{version}%{snap}.tar.gz
11 # Source0-md5:  b147b7cd3c059831c415c5a2bcecdf95
12 Patch0:         %{name}-ffmpeg.patch
13 Patch1:         %{name}-am.patch
14 URL:            http://opencv.willowgarage.com
15 BuildRequires:  autoconf >= 2.53
16 BuildRequires:  automake
17 BuildRequires:  ffmpeg-devel
18 BuildRequires:  jasper-devel
19 BuildRequires:  libdc1394-devel
20 BuildRequires:  libjpeg-devel
21 BuildRequires:  libpng-devel
22 BuildRequires:  libraw1394-devel
23 BuildRequires:  libtiff-devel
24 BuildRequires:  libtool
25 BuildRequires:  python-devel
26 BuildRequires:  rpm-pythonprov
27 BuildRequires:  swig-python
28 BuildRequires:  zlib-devel
29 %pyrequires_eq  python-libs
30 %{?with_xine:BuildRequires:     xine-lib-devel}
31 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
32
33 %description
34 OpenCV (Open Source Computer Vision) is a library of programming
35 functions mainly aimed at real time computer vision.
36
37 Example applications of the OpenCV library are Human-Computer
38 Interaction (HCI); Object Identification, Segmentation and
39 Recognition; Face Recognition; Gesture Recognition; Motion Tracking,
40 Ego Motion, Motion Understanding; Structure From Motion (SFM); Stereo
41 and Multi-Camera Calibration and Depth Computation; Mobile Robotics.
42
43 %package devel
44 Summary:        Header files and develpment documentation for opencv
45 Group:          Development/Libraries
46 Requires:       %{name} = %{epoch}:%{version}-%{release}
47
48 %description devel
49 Header files and opencv documentation.
50
51 %package static
52 Summary:        Static opencv library
53 Group:          Development/Libraries
54 Requires:       %{name}-devel = %{epoch}:%{version}-%{release}
55
56 %description static
57 This package contains the static library used for development.
58
59 %package -n python-opencv
60 Summary:        OpenCV Python bindings
61 Group:          Development/Languages/Python
62 %pyrequires_eq  python
63 Requires:       %{name} = %{version}-%{release}
64
65 %description -n python-opencv
66 OpenCV Python bindings.
67
68 %prep
69 %setup -q -n %{name}-%{version}.0
70 %patch0 -p0
71 %patch1 -p1
72
73 sed -i -e 's#ACLOCAL_AMFLAGS.*##g' Makefile.am
74 sed -i -e 's#pkgpython#pkgpyexec#g' interfaces/swig/python/Makefile.am
75 sed -i -e 's#-L$(SWIG_PYTHON_LIBS)#$(NOTING_NOT_EMPTY_LINE)#g' interfaces/swig/python/Makefile.am
76
77 %build
78 %{__libtoolize}
79 %{__aclocal} -I autotools/aclocal
80 %{__autoconf}
81 %{__automake}
82 %configure \
83 %ifarch i686 pentium4 athlon %{x8664}
84         --enable-sse2 \
85 %else
86         --disable-sse2 \
87 %endif
88         --with-python \
89         --with%{!?with_xine:out}-xine \
90         --with-ffmpeg \
91         --with-1394libs \
92         --with-v4l \
93         --with-gtk \
94         --without-gstreamer \
95         --without-quicktime
96 %{__make}
97
98 %install
99 rm -rf $RPM_BUILD_ROOT
100
101 %{__make} install \
102         DESTDIR=$RPM_BUILD_ROOT
103
104 %clean
105 rm -rf $RPM_BUILD_ROOT
106
107 %post   -p /sbin/ldconfig
108 %postun -p /sbin/ldconfig
109
110 %files
111 %defattr(644,root,root,755)
112 %doc AUTHORS COPYING ChangeLog THANKS TODO
113 %doc docs/*.{htm,rtf,png,txt} docs/papers docs/ref
114 %attr(755,root,root) %{_bindir}/*
115 %attr(755,root,root) %{_libdir}/lib*so.*.*
116 %attr(755,root,root) %ghost %{_libdir}/lib*.so.2
117
118 %files devel
119 %defattr(644,root,root,755)
120 %attr(755,root,root) %{_libdir}/lib*.so
121 %{_libdir}/lib*.la
122 %{_includedir}/opencv
123 %{_pkgconfigdir}/*.pc
124
125 %files static
126 %defattr(644,root,root,755)
127 %{_libdir}/lib*.a
128
129 %files -n python-opencv
130 %defattr(644,root,root,755)
131 %dir %{py_sitedir}/opencv
132 %attr(755,root,root) %{py_sitedir}/opencv/*.so
133 %{py_sitedir}/opencv/*.py[co]
This page took 0.040829 seconds and 3 git commands to generate.