]>
Commit | Line | Data |
---|---|---|
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}.1 | |
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 | URL: http://opencv.willowgarage.com | |
13 | BuildRequires: autoconf >= 2.53 | |
14 | BuildRequires: automake | |
15 | BuildRequires: ffmpeg-devel | |
16 | BuildRequires: jasper-devel | |
17 | BuildRequires: libdc1394-devel | |
18 | BuildRequires: libjpeg-devel | |
19 | BuildRequires: libpng-devel | |
20 | BuildRequires: libraw1394-devel | |
21 | BuildRequires: libtiff-devel | |
22 | BuildRequires: python-devel | |
23 | BuildRequires: rpm-pythonprov | |
24 | BuildRequires: swig-python | |
25 | BuildRequires: zlib-devel | |
26 | %pyrequires_eq python-libs | |
27 | %{?with_xine:BuildRequires: xine-lib-devel} | |
28 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
29 | ||
30 | %description | |
31 | OpenCV (Open Source Computer Vision) is a library of programming | |
32 | functions mainly aimed at real time computer vision. | |
33 | ||
34 | Example applications of the OpenCV library are Human-Computer | |
35 | Interaction (HCI); Object Identification, Segmentation and | |
36 | Recognition; Face Recognition; Gesture Recognition; Motion Tracking, | |
37 | Ego Motion, Motion Understanding; Structure From Motion (SFM); Stereo | |
38 | and Multi-Camera Calibration and Depth Computation; Mobile Robotics. | |
39 | ||
40 | %package devel | |
41 | Summary: Header files and develpment documentation for opencv | |
42 | Group: Development/Libraries | |
43 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
44 | ||
45 | %description devel | |
46 | Header files and opencv documentation. | |
47 | ||
48 | %package static | |
49 | Summary: Static opencv library | |
50 | Group: Development/Libraries | |
51 | Requires: %{name}-devel = %{epoch}:%{version}-%{release} | |
52 | ||
53 | %description static | |
54 | This package contains the static library used for development. | |
55 | ||
56 | %package -n python-opencv | |
57 | Summary: OpenCV Python bindings | |
58 | Group: Development/Languages/Python | |
59 | %pyrequires_eq python | |
60 | Requires: %{name} = %{version}-%{release} | |
61 | ||
62 | %description -n python-opencv | |
63 | OpenCV Python bindings. | |
64 | ||
65 | %prep | |
66 | %setup -q -n %{name}-%{version}.0 | |
67 | ||
68 | %build | |
69 | %configure \ | |
70 | %ifarch i686 pentium4 athlon %{x8664} | |
71 | --enable-sse2 \ | |
72 | %else | |
73 | --disable-sse2 \ | |
74 | %endif | |
75 | --with-python \ | |
76 | --with%{!?with_xine:-out}-xine \ | |
77 | --with-ffmpeg \ | |
78 | --with-1394libs \ | |
79 | --with-v4l \ | |
80 | --with-gtk \ | |
81 | --without-gstreamer \ | |
82 | --without-quicktime | |
83 | %{__make} | |
84 | ||
85 | %install | |
86 | rm -rf $RPM_BUILD_ROOT | |
87 | ||
88 | %{__make} install \ | |
89 | DESTDIR=$RPM_BUILD_ROOT | |
90 | ||
91 | %clean | |
92 | rm -rf $RPM_BUILD_ROOT | |
93 | ||
94 | %post -p /sbin/ldconfig | |
95 | %postun -p /sbin/ldconfig | |
96 | ||
97 | %files | |
98 | %defattr(644,root,root,755) | |
99 | %doc AUTHORS COPYING ChangeLog THANKS TODO | |
100 | %doc docs/*.{htm,rtf,png,txt} docs/papers docs/ref | |
101 | %attr(755,root,root) %{_bindir}/* | |
102 | %attr(755,root,root) %{_libdir}/lib*so.*.* | |
103 | %attr(755,root,root) %ghost %{_libdir}/lib*.so.2 | |
104 | ||
105 | %files devel | |
106 | %defattr(644,root,root,755) | |
107 | %attr(755,root,root) %{_libdir}/lib*.so | |
108 | %{_libdir}/lib*.la | |
109 | %{_includedir}/opencv | |
110 | %{_pkgconfigdir}/*.pc | |
111 | ||
112 | %files static | |
113 | %defattr(644,root,root,755) | |
114 | %{_libdir}/lib*.a | |
115 | ||
116 | %files -n python-opencv | |
117 | %defattr(644,root,root,755) | |
118 | %dir %{py_sitedir}/opencv | |
119 | %attr(755,root,root) %{py_sitedir}/opencv/*.so | |
120 | %{py_sitedir}/opencv/*.py[co] |