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