| 1 | Summary: PDF rendering library
|
|---|
| 2 | Name: poppler
|
|---|
| 3 | Version: 0.26.0
|
|---|
| 4 | Release: 1%{?dist}
|
|---|
| 5 | License: (GPLv2 or GPLv3) and GPLv2+ and LGPLv2+ and MIT
|
|---|
| 6 | Group: Development/Libraries
|
|---|
| 7 | # Source0: http://poppler.freedesktop.org/%{name}-%{version}.tar.xz
|
|---|
| 8 | # Source1: http://poppler.freedesktop.org/%{name}-data-%{data_ver}.tar.gz
|
|---|
| 9 | URL: http://poppler.freedesktop.org/
|
|---|
| 10 | %define svn_url http://svn.netlabs.org/repos/ports/poppler/trunk
|
|---|
| 11 | %define svn_rev 874
|
|---|
| 12 |
|
|---|
| 13 | Source: %{name}-%{version}-r%{svn_rev}.zip
|
|---|
| 14 |
|
|---|
| 15 | BuildRequires: gcc make subversion zip
|
|---|
| 16 |
|
|---|
| 17 | BuildRequires: libqt4-devel
|
|---|
| 18 | BuildRequires: autoconf
|
|---|
| 19 | BuildRequires: automake
|
|---|
| 20 | BuildRequires: libtool
|
|---|
| 21 | BuildRequires: pkgconfig
|
|---|
| 22 | BuildRequires: zlib-devel
|
|---|
| 23 | BuildRequires: libjpeg-devel
|
|---|
| 24 | BuildRequires: libpng-devel
|
|---|
| 25 | BuildRequires: libtiff-devel
|
|---|
| 26 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
|
|---|
| 27 |
|
|---|
| 28 | %description
|
|---|
| 29 | Poppler, a PDF rendering library, is a fork of the xpdf PDF
|
|---|
| 30 | viewer developed by Derek Noonburg of Glyph and Cog, LLC.
|
|---|
| 31 |
|
|---|
| 32 | %package devel
|
|---|
| 33 | Summary: Libraries and headers for poppler
|
|---|
| 34 | Group: Development/Libraries
|
|---|
| 35 | Requires: %{name}%{?_isa} = %{version}-%{release}
|
|---|
| 36 |
|
|---|
| 37 | %description devel
|
|---|
| 38 | You should install the poppler-devel package if you would like to
|
|---|
| 39 | compile applications based on poppler.
|
|---|
| 40 |
|
|---|
| 41 | %package qt
|
|---|
| 42 | Summary: Qt4 wrapper for poppler
|
|---|
| 43 | Group: System Environment/Libraries
|
|---|
| 44 | Requires: %{name}%{?_isa} = %{version}-%{release}
|
|---|
| 45 | %{?_qt4:Requires: qt4%{?_isa} >= %{_qt4_version}}
|
|---|
| 46 | Obsoletes: poppler-qt4 < 0.16.0-3
|
|---|
| 47 | Provides: poppler-qt4 = %{version}-%{release}
|
|---|
| 48 |
|
|---|
| 49 | %description qt
|
|---|
| 50 | Qt4 wrapper for poppler.
|
|---|
| 51 |
|
|---|
| 52 | %package qt-devel
|
|---|
| 53 | Summary: Development files for Qt4 wrapper
|
|---|
| 54 | Group: Development/Libraries
|
|---|
| 55 | Requires: %{name}-qt%{?_isa} = %{version}-%{release}
|
|---|
| 56 | Requires: %{name}-devel%{?_isa} = %{version}-%{release}
|
|---|
| 57 | Obsoletes: poppler-qt4-devel < 0.16.0-3
|
|---|
| 58 | Provides: poppler-qt4-devel = %{version}-%{release}
|
|---|
| 59 | Requires: qt4-devel-kit
|
|---|
| 60 |
|
|---|
| 61 | %description qt-devel
|
|---|
| 62 | Header files for Qt4 wrapper for poppler.
|
|---|
| 63 |
|
|---|
| 64 | %package utils
|
|---|
| 65 | Summary: Command line utilities for converting PDF files
|
|---|
| 66 | Group: Applications/Text
|
|---|
| 67 | Requires: %{name}%{?_isa} = %{version}-%{release}
|
|---|
| 68 |
|
|---|
| 69 | %description utils
|
|---|
| 70 | Poppler, a PDF rendering library, is a fork of the xpdf PDF
|
|---|
| 71 | viewer developed by Derek Noonburg of Glyph and Cog, LLC.
|
|---|
| 72 |
|
|---|
| 73 | This utils package installs a number of command line tools for
|
|---|
| 74 | converting PDF files to a number of other formats.
|
|---|
| 75 |
|
|---|
| 76 | %package demos
|
|---|
| 77 | Summary: Demos for poppler
|
|---|
| 78 | Group: Applications/Text
|
|---|
| 79 | Requires: %{name}-glib%{?_isa} = %{version}-%{release}
|
|---|
| 80 |
|
|---|
| 81 | %description demos
|
|---|
| 82 | %{summary}.
|
|---|
| 83 |
|
|---|
| 84 | %prep
|
|---|
| 85 | %if %(sh -c 'if test -f "%{_sourcedir}/%{name}-%{version}-r%{svn_rev}.zip" ; then echo 1 ; else echo 0 ; fi')
|
|---|
| 86 | %setup -q
|
|---|
| 87 | %else
|
|---|
| 88 | %setup -n "%{name}-%{version}" -Tc
|
|---|
| 89 | svn export -r %{svn_rev} %{svn_url} . --force
|
|---|
| 90 | rm -f "%{_sourcedir}/%{name}-%{version}-r%{svn_rev}.zip"
|
|---|
| 91 | (cd .. && zip -SrX9 "%{_sourcedir}/%{name}-%{version}-r%{svn_rev}.zip" "%{name}-%{version}")
|
|---|
| 92 | %endif
|
|---|
| 93 |
|
|---|
| 94 | # hammer to nuke rpaths, recheck on new releases
|
|---|
| 95 | autoreconf -f -i
|
|---|
| 96 |
|
|---|
| 97 | %build
|
|---|
| 98 |
|
|---|
| 99 | POPPLER_QT4_CFLAGS='-D__OS2__'
|
|---|
| 100 | POPPLER_QT4_LIBS='-lQtCore4 -lQtGui4 -lQtNetwork4 -lQtXml4'
|
|---|
| 101 | POPPLER_QT4_TEST_CFLAGS=$POPPLER_QT4_CFLAGS
|
|---|
| 102 | POPPLER_QT4_TEST_LIBS=$POPPLER_QT4_LIBS
|
|---|
| 103 | LDFLAGS='-Zomf -Zhigh-mem'
|
|---|
| 104 |
|
|---|
| 105 | export LDFLAGS
|
|---|
| 106 | export POPPLER_QT4_CFLAGS
|
|---|
| 107 | export POPPLER_QT4_LIBS
|
|---|
| 108 | export POPPLER_QT4_TEST_CFLAGS
|
|---|
| 109 | export POPPLER_QT4_TEST_LIBS
|
|---|
| 110 |
|
|---|
| 111 | %configure \
|
|---|
| 112 | --enable-poppler-qt4=yes --enable-zlib=yes \
|
|---|
| 113 | FREETYPE_LIBS=-lfreetype FREETYPE_CFLAGS=-D__OS2__ \
|
|---|
| 114 | FONTCONFIG_LIBS=-lfontconfig FONTCONFIG_CFLAGS=-D__OS2__ \
|
|---|
| 115 | --enable-shared --disable-static \
|
|---|
| 116 | --enable-xpdf-headers
|
|---|
| 117 |
|
|---|
| 118 | %{__make} %{?_smp_mflags}
|
|---|
| 119 |
|
|---|
| 120 | %install
|
|---|
| 121 | rm -rf $RPM_BUILD_ROOT
|
|---|
| 122 |
|
|---|
| 123 | %{__make} install \
|
|---|
| 124 | DESTDIR=$RPM_BUILD_ROOT
|
|---|
| 125 |
|
|---|
| 126 | rm -rf $RPM_BUILD_ROOT%{_libdir}/lib*.la
|
|---|
| 127 |
|
|---|
| 128 | %clean
|
|---|
| 129 | rm -rf $RPM_BUILD_ROOT
|
|---|
| 130 |
|
|---|
| 131 | %files
|
|---|
| 132 | %defattr(644,root,root,755)
|
|---|
| 133 | %doc COPYING README
|
|---|
| 134 | %attr(755,root,root) %{_libdir}/poppl*46.dll
|
|---|
| 135 |
|
|---|
| 136 | %files devel
|
|---|
| 137 | %defattr(644,root,root,755)
|
|---|
| 138 | %attr(755,root,root) %{_libdir}/poppler*_dll.a
|
|---|
| 139 | %{_libdir}/pkgconfig/poppler.pc
|
|---|
| 140 | %{_libdir}/pkgconfig/poppler-splash.pc
|
|---|
| 141 | %dir %{_includedir}/poppler/
|
|---|
| 142 | # xpdf headers
|
|---|
| 143 | %{_includedir}/poppler/*.h
|
|---|
| 144 | %{_includedir}/poppler/fofi/
|
|---|
| 145 | %{_includedir}/poppler/goo/
|
|---|
| 146 | %{_includedir}/poppler/splash/
|
|---|
| 147 |
|
|---|
| 148 | %files qt
|
|---|
| 149 | %defattr(644,root,root,755)
|
|---|
| 150 | %attr(755,root,root) %{_libdir}/poppler*.dll
|
|---|
| 151 |
|
|---|
| 152 | %files qt-devel
|
|---|
| 153 | %defattr(644,root,root,755)
|
|---|
| 154 | %attr(755,root,root) %{_libdir}/poppler-qt4*_dll.a
|
|---|
| 155 | %{_libdir}/pkgconfig/poppler-qt4.pc
|
|---|
| 156 | %{_includedir}/poppler/qt4/
|
|---|
| 157 |
|
|---|
| 158 | %files utils
|
|---|
| 159 | %defattr(644,root,root,755)
|
|---|
| 160 | %{_bindir}/pdf*
|
|---|
| 161 | %{_mandir}/man1/*
|
|---|
| 162 |
|
|---|
| 163 | %changelog
|
|---|
| 164 | * Fri Sep 26 2014 Silvan Scherrer <silvan.scherrer@aroa.ch> 0.26.4
|
|---|
| 165 | - update poppler to 0.26.4
|
|---|
| 166 | - first rpm version
|
|---|