]>
Commit | Line | Data |
---|---|---|
59f6d029 | 1 | # |
708b49cb | 2 | # Conditional build: |
8d5d1be9 | 3 | %bcond_without apidocs # disable gtk-doc |
7122799d | 4 | %bcond_without cairo # disable Cairo backend |
59f6d029 | 5 | %bcond_without qt4 # disable qt4 wrapper |
931ab1e2 | 6 | %bcond_without cpp # disable cpp wrapper |
cfe3ca2f | 7 | %bcond_without glib # disable glib wrapper |
708b49cb | 8 | # |
a6475984 | 9 | %define cairo_ver 1.10.0 |
e2a6dd23 | 10 | # |
9e116569 | 11 | Summary: PDF rendering library |
ef9a130a | 12 | Summary(pl.UTF-8): Biblioteka renderująca PDF |
9e116569 | 13 | Name: poppler |
5ee7d9e8 | 14 | Version: 0.22.0 |
aa82c819 | 15 | Release: 1 |
434ea14d | 16 | License: GPL v2+ |
9e116569 | 17 | Group: Libraries |
18 | Source0: http://poppler.freedesktop.org/%{name}-%{version}.tar.gz | |
5ee7d9e8 JB |
19 | # Source0-md5: c7038be37a7d446544e83a7df3c26196 |
20 | Patch0: %{name}-am.patch | |
9e116569 | 21 | URL: http://poppler.freedesktop.org/ |
d84a04fd JB |
22 | %{?with_qt4:BuildRequires: QtGui-devel >= 4.4.0} |
23 | %{?with_qt4:BuildRequires: QtTest-devel >= 4.4.0} | |
24 | %{?with_qt4:BuildRequires: QtXml-devel >= 4.4.0} | |
7e0143fb JB |
25 | BuildRequires: autoconf >= 2.59 |
26 | BuildRequires: automake | |
e2a6dd23 | 27 | %{?with_cairo:BuildRequires: cairo-devel >= %{cairo_ver}} |
bd2cd4db | 28 | BuildRequires: curl-devel |
ea3f193d | 29 | BuildRequires: docbook-dtd412-xml |
d84a04fd | 30 | BuildRequires: fontconfig-devel >= 2.0.0 |
708b49cb | 31 | BuildRequires: freetype-devel >= 2.0 |
2b8c2f20 | 32 | BuildRequires: gettext-devel |
161e58e8 | 33 | %{?with_glib:BuildRequires: glib2-devel >= 1:2.18.0} |
a6475984 JB |
34 | BuildRequires: gobject-introspection-devel >= 0.6.7 |
35 | %{?with_apidocs:BuildRequires: gtk-doc >= 1.14} | |
aa82c819 | 36 | BuildRequires: lcms2-devel |
9e1eea06 | 37 | BuildRequires: libjpeg-devel |
d9c2dc15 | 38 | BuildRequires: libpng-devel |
708b49cb | 39 | BuildRequires: libstdc++-devel |
d9c2dc15 | 40 | BuildRequires: libtiff-devel |
7e0143fb | 41 | BuildRequires: libtool >= 2:1.5 |
9148ca80 | 42 | BuildRequires: libxml2-devel >= 2.0 |
5ee7d9e8 | 43 | BuildRequires: openjpeg-devel >= 1.5 |
a6475984 | 44 | BuildRequires: pkgconfig >= 1:0.18 |
5ee7d9e8 JB |
45 | # wanted cairo backends |
46 | BuildRequires: pkgconfig(cairo-pdf) >= %{cairo_ver} | |
47 | BuildRequires: pkgconfig(cairo-ps) >= %{cairo_ver} | |
48 | BuildRequires: pkgconfig(cairo-svg) >= %{cairo_ver} | |
9148ca80 | 49 | %{?with_qt4:BuildRequires: qt4-build} |
21021625 | 50 | BuildRequires: sed >= 4.0 |
9542becb | 51 | BuildRequires: which |
bf5184f7 | 52 | BuildRequires: zlib-devel |
5ee7d9e8 | 53 | Requires: openjpeg >= 1.5 |
9e116569 | 54 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
55 | ||
56 | %description | |
256ec317 | 57 | A common PDF rendering library for integrating PDF viewing into |
58 | desktop applications (based on the xpdf-3.0 code base). | |
9e116569 | 59 | |
4d968103 JR |
60 | %description -l pl.UTF-8 |
61 | Wspólna biblioteka renderująca PDF do integrowania oglądania PDF w | |
943507a4 JB |
62 | aplikacjach desktopowych (oparta na kodzie xpdf-3.0). |
63 | ||
9e116569 | 64 | %package devel |
943507a4 | 65 | Summary: Poppler header files |
ef9a130a | 66 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki Poppler |
9e116569 | 67 | Group: Development/Libraries |
68 | Requires: %{name} = %{version}-%{release} | |
d9c2dc15 | 69 | Requires: curl-devel |
d84a04fd | 70 | Requires: fontconfig-devel >= 2.0.0 |
708b49cb | 71 | Requires: freetype-devel >= 2.0 |
aa82c819 | 72 | Requires: lcms2-devel |
d9c2dc15 JB |
73 | Requires: libjpeg-devel |
74 | Requires: libpng-devel | |
708b49cb | 75 | Requires: libstdc++-devel |
d9c2dc15 | 76 | Requires: libtiff-devel |
5ee7d9e8 | 77 | Requires: openjpeg-devel >= 1.5 |
d9c2dc15 | 78 | Requires: zlib-devel |
9e116569 | 79 | |
80 | %description devel | |
943507a4 JB |
81 | Header files for the Poppler library. |
82 | ||
4d968103 JR |
83 | %description devel -l pl.UTF-8 |
84 | Pliki nagłówkowe biblioteki Poppler. | |
9e116569 | 85 | |
86 | %package static | |
87 | Summary: Poppler static libraries | |
ef9a130a | 88 | Summary(pl.UTF-8): Statyczne biblioteki Poppler |
9e116569 | 89 | Group: Development/Libraries |
90 | Requires: %{name}-devel = %{version}-%{release} | |
91 | ||
92 | %description static | |
93 | Poppler static libraries. | |
94 | ||
4d968103 | 95 | %description static -l pl.UTF-8 |
943507a4 JB |
96 | Statyczne biblioteki Poppler. |
97 | ||
356581a6 MB |
98 | %package apidocs |
99 | Summary: Poppler library API documentation | |
100 | Summary(pl.UTF-8): Dokumentacja API biblioteki Poppler | |
101 | Group: Documentation | |
102 | Requires: gtk-doc-common | |
103 | ||
104 | %description apidocs | |
105 | Poppler library API documentation. | |
106 | ||
107 | %description apidocs -l pl.UTF-8 | |
108 | Dokumentacja API biblioteki Poppler. | |
109 | ||
931ab1e2 | 110 | %package cpp |
111 | Summary: Cpp wrapper for poppler | |
112 | Summary(pl.UTF-8): Wrapper cpp dla popplera | |
113 | Group: Libraries | |
114 | Requires: %{name} = %{version}-%{release} | |
115 | ||
116 | %description cpp | |
117 | Cpp wrapper for poppler. | |
118 | ||
119 | %description cpp -l pl.UTF-8 | |
120 | Wrapper cpp dla popplera. | |
121 | ||
122 | %package cpp-devel | |
123 | Summary: Header files for cpp wrapper for poppler | |
124 | Summary(pl.UTF-8): Pliki nagłówkowe wrappera cpp dla popplera | |
125 | Group: Development/Libraries | |
126 | Requires: %{name}-cpp = %{version}-%{release} | |
127 | Requires: %{name}-devel = %{version}-%{release} | |
128 | ||
129 | %description cpp-devel | |
130 | Header files for cpp wrapper for poppler. | |
131 | ||
132 | %description cpp-devel -l pl.UTF-8 | |
133 | Pliki nagłówkowe wrappera cpp dla popplera. | |
134 | ||
135 | %package cpp-static | |
136 | Summary: Static version of cpp wrapper for poppler | |
137 | Summary(pl.UTF-8): Statyczna wersja wrappera cpp dla popplera | |
138 | Group: Development/Libraries | |
139 | Requires: %{name}-cpp-devel = %{version}-%{release} | |
140 | ||
141 | %description cpp-static | |
142 | Static version of cpp wrapper for poppler. | |
143 | ||
144 | %description cpp-static -l pl.UTF-8 | |
145 | Statyczna wersja wrappera cpp dla popplera. | |
146 | ||
c858408d JB |
147 | %package glib |
148 | Summary: GLib wrapper for poppler | |
ef9a130a | 149 | Summary(pl.UTF-8): Wrapper GLib dla popplera |
c858408d JB |
150 | Group: Libraries |
151 | Requires: %{name} = %{version}-%{release} | |
59f6d029 | 152 | %{?with_cairo:Requires: cairo >= %{cairo_ver}} |
d84a04fd | 153 | Requires: glib2 >= 1:2.18.0 |
c858408d JB |
154 | |
155 | %description glib | |
156 | GLib wrapper for poppler. | |
157 | ||
4d968103 | 158 | %description glib -l pl.UTF-8 |
c858408d JB |
159 | Wrapper GLib dla popplera. |
160 | ||
161 | %package glib-devel | |
162 | Summary: Header files for GLib wrapper for poppler | |
ef9a130a | 163 | Summary(pl.UTF-8): Pliki nagłówkowe wrappera GLib dla popplera |
c858408d JB |
164 | Group: Development/Libraries |
165 | Requires: %{name}-devel = %{version}-%{release} | |
166 | Requires: %{name}-glib = %{version}-%{release} | |
59f6d029 | 167 | %{?with_cairo:Requires: cairo-devel >= %{cairo_ver}} |
d84a04fd | 168 | Requires: glib2-devel >= 1:2.18.0 |
c858408d JB |
169 | |
170 | %description glib-devel | |
171 | Header files for GLib wrapper for poppler. | |
172 | ||
4d968103 JR |
173 | %description glib-devel -l pl.UTF-8 |
174 | Pliki nagłówkowe wrappera GLib dla popplera. | |
c858408d JB |
175 | |
176 | %package glib-static | |
177 | Summary: Static version of GLib wrapper for poppler | |
ef9a130a | 178 | Summary(pl.UTF-8): Statyczna wersja wrappera GLib dla popplera |
c858408d JB |
179 | Group: Development/Libraries |
180 | Requires: %{name}-glib-devel = %{version}-%{release} | |
181 | ||
182 | %description glib-static | |
183 | Static version of GLib wrapper for poppler. | |
184 | ||
4d968103 | 185 | %description glib-static -l pl.UTF-8 |
c858408d JB |
186 | Statyczna wersja wrappera GLib dla popplera. |
187 | ||
3ed2c139 PS |
188 | %package Qt |
189 | Summary: Qt4 wrapper for poppler | |
ef9a130a | 190 | Summary(pl.UTF-8): Wrapper Qt4 dla popplera |
3ed2c139 PS |
191 | Group: Libraries |
192 | Requires: %{name} = %{version}-%{release} | |
d84a04fd JB |
193 | Requires: QtGui >= 4.4.0 |
194 | Requires: QtXml >= 4.4.0 | |
d9c2dc15 | 195 | Obsoletes: poppler-qt |
3ed2c139 PS |
196 | |
197 | %description Qt | |
198 | Qt4 wrapper for poppler. | |
199 | ||
4d968103 | 200 | %description Qt -l pl.UTF-8 |
3ed2c139 PS |
201 | Wrapper Qt4 dla popplera. |
202 | ||
203 | %package Qt-devel | |
204 | Summary: Header files for Qt4 wrapper for poppler | |
ef9a130a | 205 | Summary(pl.UTF-8): Pliki nagłówkowe wrappera Qt4 dla popplera |
3ed2c139 | 206 | Group: Development/Libraries |
3ed2c139 | 207 | Requires: %{name}-Qt = %{version}-%{release} |
9148ca80 | 208 | Requires: %{name}-devel = %{version}-%{release} |
d84a04fd JB |
209 | Requires: QtGui-devel >= 4.4.0 |
210 | Requires: QtXml-devel >= 4.4.0 | |
d9c2dc15 | 211 | Obsoletes: poppler-qt-devel |
3ed2c139 PS |
212 | |
213 | %description Qt-devel | |
214 | Header files for Qt4 wrapper for poppler. | |
215 | ||
4d968103 JR |
216 | %description Qt-devel -l pl.UTF-8 |
217 | Pliki nagłówkowe wrapper Qt4 dla popplera. | |
3ed2c139 PS |
218 | |
219 | %package Qt-static | |
220 | Summary: Static version of Qt4 wrapper for poppler | |
ef9a130a | 221 | Summary(pl.UTF-8): Statyczna wersja wrappera Qt4 dla popplera |
3ed2c139 PS |
222 | Group: Development/Libraries |
223 | Requires: %{name}-Qt-devel = %{version}-%{release} | |
d9c2dc15 | 224 | Obsoletes: poppler-qt-static |
3ed2c139 PS |
225 | |
226 | %description Qt-static | |
227 | Static version of Qt4 wrapper for poppler. | |
228 | ||
4d968103 | 229 | %description Qt-static -l pl.UTF-8 |
3ed2c139 PS |
230 | Statyczna wersja wrappera Qt4 dla popplera. |
231 | ||
3085c5f7 | 232 | %package progs |
6d515f80 | 233 | Summary: Set of tools for viewing information and converting PDF files |
ef9a130a | 234 | Summary(pl.UTF-8): Zestaw narzędzi do wyświetlania informacji i konwertowania plików PDF |
6d515f80 | 235 | Group: Applications/Publishing |
6d515f80 | 236 | Provides: pdftops |
237 | Obsoletes: pdftohtml | |
238 | Obsoletes: pdftohtml-pdftops | |
5ba7dac4 | 239 | Obsoletes: poppler-utils |
9148ca80 | 240 | Obsoletes: xpdf-tools |
6d515f80 | 241 | |
3085c5f7 | 242 | %description progs |
4be74f1d | 243 | Package contains utilites for PDF files. These utilities allow to |
bd2cd4db TP |
244 | - extract information about PDF files, |
245 | - extract images from PDF files, | |
246 | - convert PDF files to HTML, plain text and PS formats. | |
6d515f80 | 247 | |
4d968103 | 248 | %description progs -l pl.UTF-8 |
9117833e | 249 | Pakiet zawiera zestaw narzędzi do plików PDF. Programy te umożliwiają |
bd2cd4db TP |
250 | - wyświetlanie informacji o plikach PDF, |
251 | - wydobywanie obrazków z plików PDF, | |
2ddaee26 | 252 | - konwersję plików PDF do formatów takich jak HTML, PS czy też |
bd2cd4db | 253 | czystego tekstu. |
6d515f80 | 254 | |
9e116569 | 255 | %prep |
256 | %setup -q | |
5ee7d9e8 | 257 | %patch0 -p1 |
59f6d029 | 258 | |
9e116569 | 259 | %build |
13fe12a3 | 260 | %{?with_apidocs:%{__gtkdocize}} |
7e0143fb | 261 | %{__libtoolize} |
6d515f80 | 262 | %{__aclocal} -I m4 |
b9e0e47d | 263 | %{__autoconf} -f |
7e0143fb JB |
264 | %{__autoheader} |
265 | %{__automake} | |
943507a4 | 266 | %configure \ |
c1800e6e | 267 | MOCQT4=/usr/bin/moc-qt4 \ |
5b64d6c1 | 268 | --disable-gtk-test \ |
bd2cd4db TP |
269 | --enable-libcurl \ |
270 | %{?with_apidocs:--enable-gtk-doc} \ | |
7e0143fb | 271 | %{!?with_cairo:--disable-cairo-output} \ |
931ab1e2 | 272 | %{!?with_cpp:--disable-poppler-cpp} \ |
cfe3ca2f | 273 | %{!?with_glib:--disable-poppler-glib} \ |
bd2cd4db | 274 | %{!?with_qt4:--disable-poppler-qt4} \ |
d84a04fd | 275 | --disable-silent-rules \ |
30316221 | 276 | --enable-xpdf-headers \ |
bf5184f7 | 277 | --enable-zlib \ |
8d5d1be9 | 278 | --enable-dependency-tracking \ |
5d1986fc | 279 | --with-html-dir=%{_gtkdocdir} |
9148ca80 | 280 | |
9e116569 | 281 | %{__make} |
282 | ||
283 | %install | |
284 | rm -rf $RPM_BUILD_ROOT | |
285 | ||
286 | %{__make} install \ | |
287 | DESTDIR=$RPM_BUILD_ROOT | |
288 | ||
9148ca80 ER |
289 | %if %{without apidocs} |
290 | # why it still installs them, brr | |
fb471923 | 291 | %{__rm} -rf $RPM_BUILD_ROOT%{_gtkdocdir}/poppler || : |
9148ca80 ER |
292 | %endif |
293 | ||
797490cf AF |
294 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/*.la |
295 | ||
9e116569 | 296 | %clean |
297 | rm -rf $RPM_BUILD_ROOT | |
298 | ||
943507a4 JB |
299 | %post -p /sbin/ldconfig |
300 | %postun -p /sbin/ldconfig | |
9e116569 | 301 | |
d84a04fd JB |
302 | %post cpp -p /sbin/ldconfig |
303 | %postun cpp -p /sbin/ldconfig | |
304 | ||
c858408d JB |
305 | %post glib -p /sbin/ldconfig |
306 | %postun glib -p /sbin/ldconfig | |
307 | ||
dff19bfc PS |
308 | %post Qt -p /sbin/ldconfig |
309 | %postun Qt -p /sbin/ldconfig | |
310 | ||
9e116569 | 311 | %files |
312 | %defattr(644,root,root,755) | |
313 | %doc AUTHORS ChangeLog NEWS README* TODO | |
c858408d | 314 | %attr(755,root,root) %{_libdir}/libpoppler.so.*.*.* |
5ee7d9e8 | 315 | %attr(755,root,root) %ghost %{_libdir}/libpoppler.so.34 |
9e116569 | 316 | |
317 | %files devel | |
318 | %defattr(644,root,root,755) | |
c858408d | 319 | %attr(755,root,root) %{_libdir}/libpoppler.so |
9e1eea06 JB |
320 | %dir %{_includedir}/poppler |
321 | %{_includedir}/poppler/poppler-config.h | |
35d1caed | 322 | %{_includedir}/poppler/[ABCDEFGHJLMNOPRSTUVX]*.h |
40c95880 | 323 | %{_includedir}/poppler/fofi |
d84a04fd | 324 | %{_includedir}/poppler/goo |
9e1eea06 | 325 | %{_includedir}/poppler/splash |
c858408d JB |
326 | %{_pkgconfigdir}/poppler.pc |
327 | %{?with_cairo:%{_pkgconfigdir}/poppler-cairo.pc} | |
328 | %{_pkgconfigdir}/poppler-splash.pc | |
9e116569 | 329 | |
330 | %files static | |
331 | %defattr(644,root,root,755) | |
c858408d JB |
332 | %{_libdir}/libpoppler.a |
333 | ||
356581a6 MB |
334 | %if %{with apidocs} |
335 | %files apidocs | |
336 | %defattr(644,root,root,755) | |
337 | %{_gtkdocdir}/poppler | |
338 | %endif | |
339 | ||
cfe3ca2f | 340 | %if %{with cpp} |
931ab1e2 | 341 | %files cpp |
342 | %defattr(644,root,root,755) | |
343 | %attr(755,root,root) %{_libdir}/libpoppler-cpp.so.*.*.* | |
344 | %attr(755,root,root) %ghost %{_libdir}/libpoppler-cpp.so.0 | |
345 | ||
346 | %files cpp-devel | |
347 | %defattr(644,root,root,755) | |
348 | %attr(755,root,root) %{_libdir}/libpoppler-cpp.so | |
931ab1e2 | 349 | %{_includedir}/poppler/cpp |
350 | %{_pkgconfigdir}/poppler-cpp.pc | |
351 | ||
352 | %files cpp-static | |
353 | %defattr(644,root,root,755) | |
354 | %{_libdir}/libpoppler-cpp.a | |
cfe3ca2f | 355 | %endif |
931ab1e2 | 356 | |
cfe3ca2f | 357 | %if %{with glib} |
c858408d JB |
358 | %files glib |
359 | %defattr(644,root,root,755) | |
360 | %attr(755,root,root) %{_libdir}/libpoppler-glib.so.*.*.* | |
35d1caed AM |
361 | %attr(755,root,root) %ghost %{_libdir}/libpoppler-glib.so.8 |
362 | %{_libdir}/girepository-1.0/Poppler-0.18.typelib | |
c858408d JB |
363 | |
364 | %files glib-devel | |
365 | %defattr(644,root,root,755) | |
366 | %attr(755,root,root) %{_libdir}/libpoppler-glib.so | |
c858408d JB |
367 | %{_includedir}/poppler/glib |
368 | %{_pkgconfigdir}/poppler-glib.pc | |
35d1caed | 369 | %{_datadir}/gir-1.0/Poppler-0.18.gir |
c858408d JB |
370 | |
371 | %files glib-static | |
372 | %defattr(644,root,root,755) | |
373 | %{_libdir}/libpoppler-glib.a | |
cfe3ca2f | 374 | %endif |
c858408d | 375 | |
3ed2c139 PS |
376 | %if %{with qt4} |
377 | %files Qt | |
378 | %defattr(644,root,root,755) | |
379 | %attr(755,root,root) %{_libdir}/libpoppler-qt4.so.*.*.* | |
aa82c819 | 380 | %attr(755,root,root) %ghost %{_libdir}/libpoppler-qt4.so.4 |
3ed2c139 PS |
381 | |
382 | %files Qt-devel | |
383 | %defattr(644,root,root,755) | |
384 | %attr(755,root,root) %{_libdir}/libpoppler-qt4.so | |
9e1eea06 | 385 | %{_includedir}/poppler/qt4 |
3ed2c139 PS |
386 | %{_pkgconfigdir}/poppler-qt4.pc |
387 | ||
388 | %files Qt-static | |
389 | %defattr(644,root,root,755) | |
390 | %{_libdir}/libpoppler-qt4.a | |
391 | %endif | |
392 | ||
3085c5f7 | 393 | %files progs |
6d515f80 | 394 | %defattr(644,root,root,755) |
395 | %attr(755,root,root) %{_bindir}/pdf* | |
396 | %{_mandir}/man1/pdf* |