3 %bcond_without static_libs # static library
4 %bcond_with tests # perform tests [some problems with rpm extractor?]
5 %bcond_without gstreamer # GStreamer plugin
6 %bcond_without mp4v2 # MP4v2 plugin
7 %bcond_without tidy # HTML plugin (based on tidy library)
9 Summary: Meta-data extraction library
10 Summary(pl.UTF-8): Biblioteka do ekstrakcji metadanych
16 Source0: http://ftp.gnu.org/gnu/libextractor/%{name}-%{version}.tar.gz
17 # Source0-md5: 35b8913dbebafe583a2781bf71509c48
18 Patch0: %{name}-info.patch
19 Patch1: %{name}-rpm5.patch
20 Patch2: %{name}-pl.po-update.patch
21 Patch3: %{name}-giflib.patch
22 URL: http://www.gnu.org/software/libextractor/
23 BuildRequires: autoconf >= 2.61
24 BuildRequires: automake >= 1:1.11
25 BuildRequires: bzip2-devel
26 BuildRequires: exiv2-devel
27 BuildRequires: gettext-devel >= 0.16.1
28 # libavformat libavcodec libavutil libswscale
29 BuildRequires: ffmpeg-devel
30 BuildRequires: flac-devel
31 BuildRequires: giflib-devel >= 5.1.0
32 BuildRequires: glib2-devel >= 2.0.0
34 BuildRequires: gstreamer-devel >= 0.11.93
35 BuildRequires: gstreamer-plugins-base >= 0.11.93
37 BuildRequires: gtk+3-devel >= 3.0.0
38 BuildRequires: libarchive-devel
39 BuildRequires: libgsf-devel
40 BuildRequires: libjpeg-devel
41 BuildRequires: libltdl-devel >= 2:2
42 BuildRequires: libmagic-devel
43 BuildRequires: libmpeg2-devel
44 BuildRequires: libsmf-devel
45 BuildRequires: libstdc++-devel
46 BuildRequires: libtiff-devel
47 BuildRequires: libtool >= 2:2
48 BuildRequires: libvorbis-devel
49 %{?with_mp4v2:BuildRequires: mp4v2-devel >= 2.0.0}
50 BuildRequires: pkgconfig >= 1:0.7
51 # rpm5 patch supports rpm5.org's rpm 4.5.x and 5.x
52 BuildRequires: rpm-devel >= 4.5
53 BuildRequires: sed >= 4.0
54 BuildRequires: texinfo
55 %{?with_tidy:BuildRequires: tidy-devel}
56 BuildRequires: zlib-devel
57 %{?with_tests:BuildRequires: zzuf}
58 Obsoletes: libextractor-printable
59 Obsoletes: libextractor-thumbnail-qt
60 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
63 libextractor is a simple library for meta-data extraction.
64 libextractor uses a plugin-mechanism that makes it easy to add support
65 for more file formats, allowing anybody to add new extractors quickly.
67 libextractor currently features meta-data extractors for HTML, JPEG,
68 Ogg, MP3, PNG, RPM, GIF, ZIP, QT, ASF, Real Audio and Video,
69 PostScript and PDF documents. It also detects many more MIME-types in
70 a fashion similar to the well-known "file" tool.
72 Each item of meta-data that is extracted from a file is categorized
73 into one of currently about 40 meta-data categories (e.g. title,
74 author, description or MIME-type).
76 This libextractor package also contains a little binary tool "extract"
77 that can be used to invoke libextractor from the command line.
78 "extract" can be used similar to "file", but while "file" currently
79 supports a wider range of file types, "extract" should be able to
80 provide more precise and more detailed information for the supported
81 types of documents (HTML, JPEG, Ogg, MP3, PNG, GIF, RPM, RA, RM, PS,
84 %description -l pl.UTF-8
85 libextractor to prosta biblioteka służąca do ekstrakcji metadanych.
86 libextractor używa mechanizmu "wtyczek", dzięki czemu łatwo jest dodać
87 wsparcie dla nowych formatów plików.
89 libextractor obecnie pozwala na pozyskanie metadanych z plików w
90 formatach HTML, JPEG, Ogg, MP3, PNG, RPM, GIF, ZIP, QT, ASF, Real
91 Audio i Video, PostScript oraz PDF. Ponadto rozpoznaje dużo więcej
92 typów MIME w sposób podobny do dobrze znanego narzędzia "file".
94 Każda informacja pobrana z pliku należy do jednej z około 40
95 kategorii (np. tytuł, autor, opis, typ MIME).
97 Ta paczka zawiera też narzędzie "extract", które pozwala skorzystać z
98 usług libextractor bezpośrednio z linii poleceń. "extract" może być
99 używane w podobny sposób, co "file". "file" zna więcej typów danych,
100 "extract" natomiast dostarcza bardziej precyzyjnych i szczegółowych
101 informacji na temat obsługiwanych formatów (HTML, JPEG, Ogg, MP3, PNG,
102 GIF, RPM, RA, RM, PS, PDF, ZIP, QT, ASF).
104 %package thumbnail-ffmpeg
105 Summary: FFmpeg Thumbnail and audio preview plugins for libextractor
106 Summary(pl.UTF-8): Wtyczki obsługująca miniaturki obrazów oraz podgląd dźwięku poprzez FFmpeg dla biblioteki libextractor
108 Requires: %{name} = %{version}-%{release}
110 %description thumbnail-ffmpeg
111 libextractor plugins that supports thumbnails and audio preview
114 %description thumbnail-ffmpeg -l pl.UTF-8
115 Wtyczki biblioteki libextractor obsługujące miniaturki obrazów oraz
116 podgląd dźwięku poprzez FFmpeg.
118 %package thumbnail-gtk
119 Summary: GTK+ Thumbnail plugin for libextractor
120 Summary(pl.UTF-8): Wtyczka obsługująca miniaturki obrazów poprzez GTK+ dla biblioteki libextractor
122 Requires: %{name} = %{version}-%{release}
123 Obsoletes: libextractor-thumbnail < 1.0.1
125 %description thumbnail-gtk
126 libextractor plugin that supports thumbnails through GTK+.
128 %description thumbnail-gtk -l pl.UTF-8
129 Wtyczka biblioteki libextractor obsługująca miniaturki obrazów poprzez
133 Summary: Development files for libextractor
134 Summary(pl.UTF-8): Pliki nagłówkowe libextractor
135 Group: Development/Libraries
136 Requires: %{name} = %{version}-%{release}
137 Requires: bzip2-devel
138 Requires: libltdl-devel
142 This package contains files to develop with libextractor, that is
143 either to create plugins or to compile applications with libextractor.
145 %description devel -l pl.UTF-8
146 Piki nagłówkowe wymagane do tworzenia aplikacji i wtyczek
147 korzystających z libextractor.
150 Summary: Static libextractor libraries
151 Summary(pl.UTF-8): Statyczne biblioteki libextractor
152 Group: Development/Libraries
153 Requires: %{name}-devel = %{version}-%{release}
156 This package contains static libraries of libextractor.
158 %description static -l pl.UTF-8
159 Statyczna wersja bibliotek libextractor.
169 %{__sed} -i -e 's,tidy/\(tidy\|buffio\)\.h,\1.h,' configure.ac src/plugins/html_extractor.c
179 %{!?with_tests:--disable-testruns} \
180 --enable-experimental \
181 %{?with_static_libs:--enable-static} \
182 %{!?with_gstreamer:--without-gstreamer}
186 %{?with_tests:%{__make} check}
189 rm -rf $RPM_BUILD_ROOT
192 DESTDIR=$RPM_BUILD_ROOT
194 # lt_dlopen is used, but .la files are not required now
195 %{__rm} $RPM_BUILD_ROOT%{_libdir}/%{name}/libextractor_*.la
196 %if %{with static_libs}
198 %{__rm} $RPM_BUILD_ROOT%{_libdir}/%{name}/libextractor_*.a
204 rm -rf $RPM_BUILD_ROOT
206 %post -p /sbin/ldconfig
207 %postun -p /sbin/ldconfig
209 %post devel -p /sbin/postshell
210 -/usr/sbin/fix-info-dir -c %{_infodir}
212 %postun devel -p /sbin/postshell
213 -/usr/sbin/fix-info-dir -c %{_infodir}
215 %files -f %{name}.lang
216 %defattr(644,root,root,755)
217 %doc AUTHORS ChangeLog NEWS README TODO
218 %attr(755,root,root) %{_bindir}/extract
219 %attr(755,root,root) %{_libdir}/libextractor.so.*.*.*
220 %attr(755,root,root) %ghost %{_libdir}/libextractor.so.3
221 %attr(755,root,root) %{_libdir}/libextractor_common.so.*.*.*
222 %attr(755,root,root) %ghost %{_libdir}/libextractor_common.so.1
223 %dir %{_libdir}/%{name}
225 %attr(755,root,root) %{_libdir}/%{name}/libextractor_archive.so
226 %attr(755,root,root) %{_libdir}/%{name}/libextractor_deb.so
227 %attr(755,root,root) %{_libdir}/%{name}/libextractor_dvi.so
229 %attr(755,root,root) %{_libdir}/%{name}/libextractor_exiv2.so
231 %attr(755,root,root) %{_libdir}/%{name}/libextractor_flac.so
233 %attr(755,root,root) %{_libdir}/%{name}/libextractor_gif.so
234 # R: gstreamer gstreamer-plugins-base
235 %attr(755,root,root) %{_libdir}/%{name}/libextractor_gstreamer.so
237 %{?with_tidy:%attr(755,root,root) %{_libdir}/%{name}/libextractor_html.so}
238 %attr(755,root,root) %{_libdir}/%{name}/libextractor_it.so
240 %attr(755,root,root) %{_libdir}/%{name}/libextractor_jpeg.so
241 %attr(755,root,root) %{_libdir}/%{name}/libextractor_man.so
243 %attr(755,root,root) %{_libdir}/%{name}/libextractor_midi.so
245 %attr(755,root,root) %{_libdir}/%{name}/libextractor_mime.so
247 %{?with_mp4v2:%attr(755,root,root) %{_libdir}/%{name}/libextractor_mp4.so}
249 %attr(755,root,root) %{_libdir}/%{name}/libextractor_mpeg.so
250 %attr(755,root,root) %{_libdir}/%{name}/libextractor_nsf.so
251 %attr(755,root,root) %{_libdir}/%{name}/libextractor_nsfe.so
252 %attr(755,root,root) %{_libdir}/%{name}/libextractor_odf.so
254 %attr(755,root,root) %{_libdir}/%{name}/libextractor_ogg.so
256 %attr(755,root,root) %{_libdir}/%{name}/libextractor_ole2.so
257 %attr(755,root,root) %{_libdir}/%{name}/libextractor_png.so
258 %attr(755,root,root) %{_libdir}/%{name}/libextractor_ps.so
259 %attr(755,root,root) %{_libdir}/%{name}/libextractor_riff.so
261 %attr(755,root,root) %{_libdir}/%{name}/libextractor_rpm.so
262 %attr(755,root,root) %{_libdir}/%{name}/libextractor_s3m.so
263 %attr(755,root,root) %{_libdir}/%{name}/libextractor_sid.so
265 %attr(755,root,root) %{_libdir}/%{name}/libextractor_tiff.so
266 %attr(755,root,root) %{_libdir}/%{name}/libextractor_wav.so
267 %attr(755,root,root) %{_libdir}/%{name}/libextractor_xm.so
268 %attr(755,root,root) %{_libdir}/%{name}/libextractor_zip.so
269 %{_mandir}/man1/extract.1*
271 %files thumbnail-ffmpeg
272 %defattr(644,root,root,755)
273 %attr(755,root,root) %{_libdir}/%{name}/libextractor_previewopus.so
274 %attr(755,root,root) %{_libdir}/%{name}/libextractor_thumbnailffmpeg.so
277 %defattr(644,root,root,755)
278 %attr(755,root,root) %{_libdir}/%{name}/libextractor_thumbnailgtk.so
281 %defattr(644,root,root,755)
282 %attr(755,root,root) %{_libdir}/libextractor.so
283 %attr(755,root,root) %{_libdir}/libextractor_common.so
284 %{_libdir}/libextractor.la
285 %{_libdir}/libextractor_common.la
286 %{_includedir}/extractor.h
287 %{_pkgconfigdir}/libextractor.pc
288 %{_mandir}/man3/libextractor.3*
289 %{_infodir}/libextractor.info*
291 %if %{with static_libs}
293 %defattr(644,root,root,755)
294 %{_libdir}/libextractor.a
295 %{_libdir}/libextractor_common.a