]> git.pld-linux.org Git - packages/libextractor.git/blame - libextractor.spec
- fix building with ffmpeg 4.0
[packages/libextractor.git] / libextractor.spec
CommitLineData
f62a8524 1#
b9f124d2 2# Conditional build:
ae0eb0ec
JB
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)
f62a8524 8#
e6895d44 9Summary: Meta-data extraction library
b0bb8262 10Summary(pl.UTF-8): Biblioteka do ekstrakcji metadanych
e6895d44 11Name: libextractor
99111149 12Version: 1.6
1ad84a1b 13Release: 2
ae0eb0ec 14License: GPL v3+
e6895d44 15Group: Libraries
ae0eb0ec 16Source0: http://ftp.gnu.org/gnu/libextractor/%{name}-%{version}.tar.gz
99111149 17# Source0-md5: cbadbfa6051ee54837299ee81732a0eb
ae0eb0ec
JB
18Patch0: %{name}-info.patch
19Patch1: %{name}-rpm5.patch
6032acdd 20Patch2: %{name}-pl.po-update.patch
1ad84a1b 21Patch3: ffmpeg4.patch
654f15d6 22URL: http://www.gnu.org/software/libextractor/
a19263be 23BuildRequires: autoconf >= 2.61
ae0eb0ec 24BuildRequires: automake >= 1:1.11
ac956507 25BuildRequires: bzip2-devel
ae0eb0ec 26BuildRequires: exiv2-devel
99111149 27BuildRequires: gdk-pixbuf2-devel >= 2.4
5d3f066e 28BuildRequires: gettext-tools >= 0.16.1
ae0eb0ec
JB
29# libavformat libavcodec libavutil libswscale
30BuildRequires: ffmpeg-devel
51643bdb 31BuildRequires: flac-devel
082fa56a 32BuildRequires: giflib-devel >= 5.1.0
f62a8524 33BuildRequires: glib2-devel >= 2.0.0
ae0eb0ec
JB
34%if %{with gstreamer}
35BuildRequires: gstreamer-devel >= 0.11.93
36BuildRequires: gstreamer-plugins-base >= 0.11.93
37%endif
38BuildRequires: gtk+3-devel >= 3.0.0
99111149 39BuildRequires: libapparmor-devel
ae0eb0ec 40BuildRequires: libarchive-devel
7e423ac2 41BuildRequires: libgsf-devel
ae0eb0ec
JB
42BuildRequires: libjpeg-devel
43BuildRequires: libltdl-devel >= 2:2
44BuildRequires: libmagic-devel
45BuildRequires: libmpeg2-devel
66bf9449 46BuildRequires: libsmf-devel
22ef719f 47BuildRequires: libstdc++-devel
ae0eb0ec
JB
48BuildRequires: libtiff-devel
49BuildRequires: libtool >= 2:2
e6895d44 50BuildRequires: libvorbis-devel
0f32d9bf 51%{?with_mp4v2:BuildRequires: mp4v2-devel >= 2.0.0}
ae0eb0ec
JB
52BuildRequires: pkgconfig >= 1:0.7
53# rpm5 patch supports rpm5.org's rpm 4.5.x and 5.x
54BuildRequires: rpm-devel >= 4.5
55BuildRequires: sed >= 4.0
51643bdb 56BuildRequires: texinfo
99111149 57%{?with_tidy:BuildRequires: tidy-devel >= 5}
22ef719f 58BuildRequires: zlib-devel
6d2f4968 59%{?with_tests:BuildRequires: zzuf}
a78ce0f6 60Obsoletes: libextractor-printable
ae0eb0ec 61Obsoletes: libextractor-thumbnail-qt
e6895d44 62BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
63
e6895d44 64%description
65libextractor is a simple library for meta-data extraction.
66libextractor uses a plugin-mechanism that makes it easy to add support
67for more file formats, allowing anybody to add new extractors quickly.
68
69libextractor currently features meta-data extractors for HTML, JPEG,
dba19c27 70Ogg, MP3, PNG, RPM, GIF, ZIP, QT, ASF, Real Audio and Video,
e6895d44 71PostScript and PDF documents. It also detects many more MIME-types in
72a fashion similar to the well-known "file" tool.
73
74Each item of meta-data that is extracted from a file is categorized
75into one of currently about 40 meta-data categories (e.g. title,
76author, description or MIME-type).
77
78This libextractor package also contains a little binary tool "extract"
79that can be used to invoke libextractor from the command line.
80"extract" can be used similar to "file", but while "file" currently
81supports a wider range of file types, "extract" should be able to
82provide more precise and more detailed information for the supported
dba19c27 83types of documents (HTML, JPEG, Ogg, MP3, PNG, GIF, RPM, RA, RM, PS,
e6895d44 84PDF, ZIP, QT, ASF).
85
3048b7f3
JR
86%description -l pl.UTF-8
87libextractor to prosta biblioteka służąca do ekstrakcji metadanych.
88libextractor używa mechanizmu "wtyczek", dzięki czemu łatwo jest dodać
89wsparcie dla nowych formatów plików.
e6895d44 90
3048b7f3 91libextractor obecnie pozwala na pozyskanie metadanych z plików w
dba19c27 92formatach HTML, JPEG, Ogg, MP3, PNG, RPM, GIF, ZIP, QT, ASF, Real
3048b7f3
JR
93Audio i Video, PostScript oraz PDF. Ponadto rozpoznaje dużo więcej
94typów MIME w sposób podobny do dobrze znanego narzędzia "file".
e6895d44 95
3048b7f3
JR
96Każda informacja pobrana z pliku należy do jednej z około 40
97kategorii (np. tytuł, autor, opis, typ MIME).
e6895d44 98
3048b7f3
JR
99Ta paczka zawiera też narzędzie "extract", które pozwala skorzystać z
100usług libextractor bezpośrednio z linii poleceń. "extract" może być
101używane w podobny sposób, co "file". "file" zna więcej typów danych,
102"extract" natomiast dostarcza bardziej precyzyjnych i szczegółowych
103informacji na temat obsługiwanych formatów (HTML, JPEG, Ogg, MP3, PNG,
e6895d44 104GIF, RPM, RA, RM, PS, PDF, ZIP, QT, ASF).
105
ae0eb0ec 106%package thumbnail-ffmpeg
6032acdd
JB
107Summary: FFmpeg Thumbnail and audio preview plugins for libextractor
108Summary(pl.UTF-8): Wtyczki obsługująca miniaturki obrazów oraz podgląd dźwięku poprzez FFmpeg dla biblioteki libextractor
6ee1ab83
JB
109Group: Libraries
110Requires: %{name} = %{version}-%{release}
6ee1ab83 111
ae0eb0ec 112%description thumbnail-ffmpeg
6032acdd
JB
113libextractor plugins that supports thumbnails and audio preview
114through FFmpeg.
6ee1ab83 115
ae0eb0ec 116%description thumbnail-ffmpeg -l pl.UTF-8
6032acdd
JB
117Wtyczki biblioteki libextractor obsługujące miniaturki obrazów oraz
118podgląd dźwięku poprzez FFmpeg.
d4fec0d7 119
ae0eb0ec
JB
120%package thumbnail-gtk
121Summary: GTK+ Thumbnail plugin for libextractor
122Summary(pl.UTF-8): Wtyczka obsługująca miniaturki obrazów poprzez GTK+ dla biblioteki libextractor
d4fec0d7
JB
123Group: Libraries
124Requires: %{name} = %{version}-%{release}
99111149 125Requires: gdk-pixbuf2 >= 2.4
ae0eb0ec 126Obsoletes: libextractor-thumbnail < 1.0.1
d4fec0d7 127
ae0eb0ec
JB
128%description thumbnail-gtk
129libextractor plugin that supports thumbnails through GTK+.
d4fec0d7 130
ae0eb0ec 131%description thumbnail-gtk -l pl.UTF-8
3048b7f3 132Wtyczka biblioteki libextractor obsługująca miniaturki obrazów poprzez
ae0eb0ec 133GTK+.
6ee1ab83 134
7a97c3f0 135%package devel
136Summary: Development files for libextractor
b0bb8262 137Summary(pl.UTF-8): Pliki nagłówkowe libextractor
7a97c3f0 138Group: Development/Libraries
30717bee 139Requires: %{name} = %{version}-%{release}
ac956507 140Requires: bzip2-devel
99111149 141Requires: libapparmor-devel
1611298c 142Requires: libltdl-devel
ae0eb0ec 143Requires: zlib-devel
7a97c3f0 144
e6895d44 145%description devel
146This package contains files to develop with libextractor, that is
147either to create plugins or to compile applications with libextractor.
148
3048b7f3
JR
149%description devel -l pl.UTF-8
150Piki nagłówkowe wymagane do tworzenia aplikacji i wtyczek
151korzystających z libextractor.
e6895d44 152
7a97c3f0 153%package static
154Summary: Static libextractor libraries
b0bb8262 155Summary(pl.UTF-8): Statyczne biblioteki libextractor
7a97c3f0 156Group: Development/Libraries
30717bee 157Requires: %{name}-devel = %{version}-%{release}
7a97c3f0 158
e6895d44 159%description static
160This package contains static libraries of libextractor.
161
3048b7f3 162%description static -l pl.UTF-8
e6895d44 163Statyczna wersja bibliotek libextractor.
164
165%prep
166%setup -q
fcbde899 167%patch0 -p1
d4fec0d7 168%patch1 -p1
654f15d6 169%patch2 -p1
1ad84a1b 170%patch3 -p1
ae0eb0ec
JB
171
172%{__rm} po/stamp-po
f62a8524 173
e6895d44 174%build
a4491c19 175%{__gettextize}
e4c3c699 176%{__libtoolize}
d809ecde 177%{__aclocal} -I m4
0271649d 178%{__autoconf}
179%{__autoheader}
180%{__automake}
9ef92358 181%configure \
ae0eb0ec
JB
182 %{!?with_tests:--disable-testruns} \
183 --enable-experimental \
d4fec0d7 184 %{?with_static_libs:--enable-static} \
ae0eb0ec 185 %{!?with_gstreamer:--without-gstreamer}
e6895d44 186
7a97c3f0 187%{__make}
e6895d44 188
ae0eb0ec
JB
189%{?with_tests:%{__make} check}
190
e6895d44 191%install
192rm -rf $RPM_BUILD_ROOT
22ef719f
JB
193
194%{__make} install \
195 DESTDIR=$RPM_BUILD_ROOT
196
ae0eb0ec
JB
197# lt_dlopen is used, but .la files are not required now
198%{__rm} $RPM_BUILD_ROOT%{_libdir}/%{name}/libextractor_*.la
199%if %{with static_libs}
22ef719f 200# useless
ae0eb0ec
JB
201%{__rm} $RPM_BUILD_ROOT%{_libdir}/%{name}/libextractor_*.a
202%endif
7a97c3f0 203
a4491c19
JB
204%find_lang %{name}
205
7a97c3f0 206%clean
207rm -rf $RPM_BUILD_ROOT
208
22ef719f
JB
209%post -p /sbin/ldconfig
210%postun -p /sbin/ldconfig
e6895d44 211
a19263be 212%post devel -p /sbin/postshell
a2621b7e 213-/usr/sbin/fix-info-dir -c %{_infodir}
51643bdb 214
a19263be 215%postun devel -p /sbin/postshell
a2621b7e 216-/usr/sbin/fix-info-dir -c %{_infodir}
51643bdb 217
a4491c19 218%files -f %{name}.lang
e6895d44 219%defattr(644,root,root,755)
22ef719f 220%doc AUTHORS ChangeLog NEWS README TODO
e6895d44 221%attr(755,root,root) %{_bindir}/extract
30717bee 222%attr(755,root,root) %{_libdir}/libextractor.so.*.*.*
a78ce0f6 223%attr(755,root,root) %ghost %{_libdir}/libextractor.so.3
ae0eb0ec
JB
224%attr(755,root,root) %{_libdir}/libextractor_common.so.*.*.*
225%attr(755,root,root) %ghost %{_libdir}/libextractor_common.so.1
b70ad6ab 226%dir %{_libdir}/%{name}
ae0eb0ec
JB
227# R: libarchive
228%attr(755,root,root) %{_libdir}/%{name}/libextractor_archive.so
b70ad6ab 229%attr(755,root,root) %{_libdir}/%{name}/libextractor_deb.so
230%attr(755,root,root) %{_libdir}/%{name}/libextractor_dvi.so
ae0eb0ec
JB
231# R: exiv2
232%attr(755,root,root) %{_libdir}/%{name}/libextractor_exiv2.so
233# R: flac
51643bdb 234%attr(755,root,root) %{_libdir}/%{name}/libextractor_flac.so
ae0eb0ec 235# R: giflib
b70ad6ab 236%attr(755,root,root) %{_libdir}/%{name}/libextractor_gif.so
ae0eb0ec
JB
237# R: gstreamer gstreamer-plugins-base
238%attr(755,root,root) %{_libdir}/%{name}/libextractor_gstreamer.so
239# R: libmagic tidy
240%{?with_tidy:%attr(755,root,root) %{_libdir}/%{name}/libextractor_html.so}
a19263be 241%attr(755,root,root) %{_libdir}/%{name}/libextractor_it.so
ae0eb0ec 242# R: libjepg
b70ad6ab 243%attr(755,root,root) %{_libdir}/%{name}/libextractor_jpeg.so
b70ad6ab 244%attr(755,root,root) %{_libdir}/%{name}/libextractor_man.so
ae0eb0ec 245# R: libsmf
66bf9449 246%attr(755,root,root) %{_libdir}/%{name}/libextractor_midi.so
ae0eb0ec 247# R: libmagic
b70ad6ab 248%attr(755,root,root) %{_libdir}/%{name}/libextractor_mime.so
ae0eb0ec
JB
249# R: mp4v2
250%{?with_mp4v2:%attr(755,root,root) %{_libdir}/%{name}/libextractor_mp4.so}
251# R: libmpeg2
b70ad6ab 252%attr(755,root,root) %{_libdir}/%{name}/libextractor_mpeg.so
62aaded9 253%attr(755,root,root) %{_libdir}/%{name}/libextractor_nsf.so
51643bdb 254%attr(755,root,root) %{_libdir}/%{name}/libextractor_nsfe.so
a78ce0f6 255%attr(755,root,root) %{_libdir}/%{name}/libextractor_odf.so
ae0eb0ec 256# R: libvorbis
b70ad6ab 257%attr(755,root,root) %{_libdir}/%{name}/libextractor_ogg.so
ae0eb0ec 258# R: libgsf
b70ad6ab 259%attr(755,root,root) %{_libdir}/%{name}/libextractor_ole2.so
99111149
JB
260%attr(755,root,root) %{_libdir}/%{name}/libextractor_pdf.so
261# R: zlib
b70ad6ab 262%attr(755,root,root) %{_libdir}/%{name}/libextractor_png.so
263%attr(755,root,root) %{_libdir}/%{name}/libextractor_ps.so
b70ad6ab 264%attr(755,root,root) %{_libdir}/%{name}/libextractor_riff.so
ae0eb0ec 265# R: rpm-lib
b70ad6ab 266%attr(755,root,root) %{_libdir}/%{name}/libextractor_rpm.so
a19263be 267%attr(755,root,root) %{_libdir}/%{name}/libextractor_s3m.so
84556c19 268%attr(755,root,root) %{_libdir}/%{name}/libextractor_sid.so
ae0eb0ec 269# R: libtiff
b70ad6ab 270%attr(755,root,root) %{_libdir}/%{name}/libextractor_tiff.so
271%attr(755,root,root) %{_libdir}/%{name}/libextractor_wav.so
a19263be 272%attr(755,root,root) %{_libdir}/%{name}/libextractor_xm.so
b70ad6ab 273%attr(755,root,root) %{_libdir}/%{name}/libextractor_zip.so
51643bdb 274%{_mandir}/man1/extract.1*
e6895d44 275
ae0eb0ec 276%files thumbnail-ffmpeg
6ee1ab83 277%defattr(644,root,root,755)
6032acdd 278%attr(755,root,root) %{_libdir}/%{name}/libextractor_previewopus.so
ae0eb0ec 279%attr(755,root,root) %{_libdir}/%{name}/libextractor_thumbnailffmpeg.so
6ee1ab83 280
ae0eb0ec 281%files thumbnail-gtk
d4fec0d7 282%defattr(644,root,root,755)
ae0eb0ec 283%attr(755,root,root) %{_libdir}/%{name}/libextractor_thumbnailgtk.so
d4fec0d7 284
e6895d44 285%files devel
286%defattr(644,root,root,755)
22ef719f 287%attr(755,root,root) %{_libdir}/libextractor.so
43713306 288%attr(755,root,root) %{_libdir}/libextractor_common.so
22ef719f 289%{_libdir}/libextractor.la
43713306 290%{_libdir}/libextractor_common.la
e6895d44 291%{_includedir}/extractor.h
84556c19 292%{_pkgconfigdir}/libextractor.pc
51643bdb 293%{_mandir}/man3/libextractor.3*
ae0eb0ec 294%{_infodir}/libextractor.info*
e6895d44 295
9ef92358 296%if %{with static_libs}
e6895d44 297%files static
298%defattr(644,root,root,755)
22ef719f 299%{_libdir}/libextractor.a
43713306 300%{_libdir}/libextractor_common.a
9ef92358 301%endif
This page took 0.112676 seconds and 4 git commands to generate.