2024-01-05 19:49:42 +01:00
|
|
|
%define majver %(echo %version | cut -dp -f1)
|
|
|
|
%define minver %(echo %{version}p | cut -dp -f2)
|
|
|
|
Name: xpdf
|
2024-02-11 20:11:54 +01:00
|
|
|
Version: 4.05
|
2024-01-05 19:49:42 +01:00
|
|
|
Release: 1mamba
|
|
|
|
Summary: An open source viewer for Portable Document Format (PDF) files
|
|
|
|
Group: Graphical Desktop/Applications/Publishing
|
|
|
|
Vendor: openmamba
|
|
|
|
Distribution: openmamba
|
|
|
|
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
|
2024-01-05 19:49:42 +01:00
|
|
|
URL: https://www.xpdfreader.com
|
|
|
|
Source0: https://dl.xpdfreader.com/xpdf-%{version}.tar.gz
|
|
|
|
Source1: https://dl.xpdfreader.com/xpdf-arabic.tar.gz
|
|
|
|
Source2: https://dl.xpdfreader.com/xpdf-chinese-simplified.tar.gz
|
|
|
|
Source3: https://dl.xpdfreader.com/xpdf-chinese-traditional.tar.gz
|
|
|
|
Source4: https://dl.xpdfreader.com/xpdf-cyrillic.tar.gz
|
|
|
|
Source5: https://dl.xpdfreader.com/xpdf-greek.tar.gz
|
|
|
|
Source6: https://dl.xpdfreader.com/xpdf-hebrew.tar.gz
|
|
|
|
Source7: https://dl.xpdfreader.com/xpdf-japanese.tar.gz
|
|
|
|
Source8: https://dl.xpdfreader.com/xpdf-korean.tar.gz
|
|
|
|
Source9: https://dl.xpdfreader.com/xpdf-latin2.tar.gz
|
|
|
|
Source10: https://dl.xpdfreader.com/xpdf-thai.tar.gz
|
|
|
|
Source11: https://dl.xpdfreader.com/xpdf-turkish.tar.gz
|
2024-01-05 19:49:42 +01:00
|
|
|
Source12: xpdf-xpdf_desktop
|
|
|
|
#%if "%{minver}" != ""
|
|
|
|
#Source13: ftp://ftp.foolabs.com/pub/xpdf/%{name}-%{majver}pl1.patch
|
|
|
|
#Source14: ftp://ftp.foolabs.com/pub/xpdf/%{name}-%{majver}p%{minver}.patch
|
|
|
|
#%endif
|
|
|
|
Patch0: %{name}-2.03-fonts.patch
|
|
|
|
Patch1: %{name}-3.00-gcc4.patch
|
2024-01-05 19:49:42 +01:00
|
|
|
Patch2: %{name}-3.04-xpdfrc.patch
|
2024-01-05 19:49:42 +01:00
|
|
|
Patch4: %{name}-3.01-crash.patch
|
|
|
|
Patch5: %{name}-3.00-can_2005_0206.patch
|
|
|
|
Patch6: %{name}-3.01-can_2005_2097.patch
|
|
|
|
Patch7: %{name}-3.01-can_2005_3191_2_3.patch
|
|
|
|
Patch8: %{name}-3.01-can_2005_3624_5_6_7.patch
|
|
|
|
Patch9: %{name}-3.01-cve_2006_0301.patch
|
|
|
|
Patch10: %{name}-3.03-libXpm-3.5.10.patch
|
|
|
|
License: GPL
|
|
|
|
## AUTOBUILDREQ-BEGIN
|
|
|
|
BuildRequires: glibc-devel
|
2024-01-05 19:49:42 +01:00
|
|
|
BuildRequires: libcups-devel
|
|
|
|
BuildRequires: libfontconfig-devel
|
2024-01-05 19:49:42 +01:00
|
|
|
BuildRequires: libfreetype-devel
|
|
|
|
BuildRequires: libgcc
|
2024-02-11 20:11:54 +01:00
|
|
|
BuildRequires: libglvnd-devel
|
2024-01-05 19:49:42 +01:00
|
|
|
BuildRequires: libpaper-devel
|
|
|
|
BuildRequires: libstdc++6-devel
|
2024-02-11 20:11:54 +01:00
|
|
|
BuildRequires: qt6-qtbase-devel
|
2024-01-05 19:49:42 +01:00
|
|
|
## AUTOBUILDREQ-END
|
|
|
|
Requires: ghostscript-fonts >= 6.0
|
|
|
|
Requires: libpoppler-tools
|
|
|
|
|
|
|
|
%description
|
|
|
|
Xpdf is an open source viewer for Portable Document Format (PDF) files.
|
|
|
|
(These are also sometimes also called 'Acrobat' files, from the name of Adobe's PDF software.)
|
|
|
|
The Xpdf project also includes a PDF text extractor, PDF-to-PostScript converter, and various other utilities.
|
|
|
|
|
2024-01-05 19:49:42 +01:00
|
|
|
%debug_package
|
|
|
|
|
2024-01-05 19:49:42 +01:00
|
|
|
%prep
|
|
|
|
%setup -q -a1 -a2 -a3 -a4 -a5 -a6 -a7 -a8 -a9 -a10 -a11 -n %{name}-%{majver}
|
2024-01-05 19:49:42 +01:00
|
|
|
#%patch0 -p1 -b .fonts
|
|
|
|
#%patch2 -p1 -b .xpdfrc
|
2024-01-05 19:49:42 +01:00
|
|
|
%if "%{minver}" != ""
|
|
|
|
patch -p1 < %{SOURCE13}
|
|
|
|
patch -p1 < %{SOURCE14}
|
|
|
|
%endif
|
2024-02-11 20:11:54 +01:00
|
|
|
%patch 6 -p1 -b .can_2005_2097
|
2024-01-05 19:49:42 +01:00
|
|
|
#%patch10 -p1
|
2024-01-05 19:49:42 +01:00
|
|
|
|
|
|
|
languages='
|
|
|
|
arabic
|
|
|
|
chinese-simplified
|
|
|
|
chinese-traditional
|
|
|
|
cyrillic
|
|
|
|
greek
|
|
|
|
hebrew
|
|
|
|
japanese
|
|
|
|
korean
|
|
|
|
latin2
|
|
|
|
thai
|
|
|
|
turkish'
|
|
|
|
> languages.lst
|
|
|
|
for lang in $languages; do echo "$lang" >> languages.lst; done
|
|
|
|
|
|
|
|
%build
|
|
|
|
# FIXME: -D__STRICT_ANSI__ needed as long as gcc provides a fixed header
|
|
|
|
# for paper.h
|
2024-01-05 19:49:42 +01:00
|
|
|
%cmake -d build \
|
|
|
|
-DMULTITHREADED=ON \
|
|
|
|
-DOPI_SUPPORT=ON \
|
|
|
|
-DXPDFWIDGET_PRINTING=ON \
|
|
|
|
-DSYSTEM_XPDFRC=%{_sysconfdir}/xpdfrc \
|
|
|
|
-DCMAKE_C_FLAGS="%{optflags} -fPIC" \
|
|
|
|
-DCMAKE_CXX_FLAGS="%{optflags} -fPIC" \
|
2024-01-05 19:49:42 +01:00
|
|
|
|
|
|
|
%make
|
|
|
|
|
|
|
|
for lang in `cat languages.lst`; do
|
|
|
|
sed -i '
|
|
|
|
s,/usr/local/share/xpdf,%{_datadir}/xpdf,g
|
|
|
|
s,/usr/local/etc/xpdfrc,%{_sysconfdir}/X11/xpdf/xpdfrc,g' \
|
|
|
|
xpdf-$lang/{add-to-xpdfrc,README}
|
|
|
|
echo >> doc/sample-xpdfrc
|
|
|
|
cat xpdf-$lang/add-to-xpdfrc >> doc/sample-xpdfrc
|
|
|
|
rm xpdf-$lang/add-to-xpdfrc
|
|
|
|
done
|
|
|
|
|
|
|
|
%install
|
|
|
|
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
|
2024-01-05 19:49:42 +01:00
|
|
|
%makeinstall -C build
|
2024-01-05 19:49:42 +01:00
|
|
|
|
|
|
|
for lang in `cat languages.lst`; do
|
|
|
|
install -d %{buildroot}%{_datadir}/%{name}/$lang
|
|
|
|
cp -a xpdf-$lang/* %{buildroot}%{_datadir}/%{name}/$lang/
|
|
|
|
done
|
|
|
|
|
|
|
|
# fix wrong paths
|
|
|
|
find %{buildroot}/%{_mandir}/man? -type f -name "*.[15]" \
|
2024-01-05 19:49:42 +01:00
|
|
|
-exec sed -i 's,/usr/local/etc/xpdfrc,/etc/xpdfrc,g' {} \;
|
2024-01-05 19:49:42 +01:00
|
|
|
sed -i 's,/usr/local/share/,/usr/share/,g' \
|
|
|
|
%{buildroot}/%{_mandir}/man5/xpdfrc.5
|
|
|
|
|
2024-01-05 19:49:42 +01:00
|
|
|
install -D -m644 doc/sample-xpdfrc %{buildroot}%{_sysconfdir}/xpdfrc
|
|
|
|
|
2024-01-05 19:49:42 +01:00
|
|
|
install -D -m644 %{SOURCE12} \
|
|
|
|
%{buildroot}%{_datadir}/applications/xpdf.desktop
|
|
|
|
|
2024-01-05 19:49:42 +01:00
|
|
|
install -D -m644 xpdf-qt/xpdf-icon.svg %{buildroot}%{_datadir}/pixmaps/xpdf.svg
|
|
|
|
|
|
|
|
# remove stuff provided by poppler
|
2024-01-05 19:49:42 +01:00
|
|
|
rm -f %{buildroot}%{_bindir}/pdf*
|
|
|
|
rm -f %{buildroot}%{_mandir}/man1/pdf*.1*
|
|
|
|
|
|
|
|
%clean
|
|
|
|
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
|
|
|
|
|
|
|
|
%files
|
|
|
|
%defattr(-,root,root)
|
2024-01-05 19:49:42 +01:00
|
|
|
%config %{_sysconfdir}/xpdfrc
|
2024-01-05 19:49:42 +01:00
|
|
|
%{_bindir}/xpdf
|
|
|
|
%dir %{_datadir}/xpdf
|
|
|
|
%{_datadir}/xpdf/*
|
|
|
|
%{_datadir}/applications/xpdf.desktop
|
2024-01-05 19:49:42 +01:00
|
|
|
%{_datadir}/pixmaps/xpdf.svg
|
|
|
|
%{_mandir}/man1/xpdf.1*
|
|
|
|
%{_mandir}/man5/xpdfrc.5*
|
2024-01-05 19:49:42 +01:00
|
|
|
%doc COPYING
|
|
|
|
#%doc ANNOUNCE CHANGES COPYING README
|
|
|
|
|
|
|
|
%changelog
|
2024-02-11 20:11:54 +01:00
|
|
|
* Sat Feb 10 2024 Automatic Build System <autodist@openmamba.org> 4.05-1mamba
|
|
|
|
- automatic version update by autodist
|
|
|
|
|
2024-01-05 19:49:42 +01:00
|
|
|
* Mon Mar 22 2021 Silvan Calarco <silvan.calarco@mambasoft.it> 4.03-1mamba
|
|
|
|
- update to 4.03
|
|
|
|
|
2024-01-05 19:49:42 +01:00
|
|
|
* Thu May 14 2020 Silvan Calarco <silvan.calarco@mambasoft.it> 4.02-1mamba
|
|
|
|
- update to 4.02
|
|
|
|
|
2024-01-05 19:49:42 +01:00
|
|
|
* Sun Dec 13 2015 Automatic Build System <autodist@mambasoft.it> 3.04-1mamba
|
|
|
|
- automatic update by autodist
|
|
|
|
|
2024-01-05 19:49:42 +01:00
|
|
|
* Mon Oct 24 2011 Automatic Build System <autodist@mambasoft.it> 3.03-1mamba
|
|
|
|
- update to 3.03
|
|
|
|
|
|
|
|
* Wed Jun 09 2010 Silvan Calarco <silvan.calarco@mambasoft.it> 3.02pl4-3mamba
|
|
|
|
- don't install pdf* man pages provided by libpoppler-tools 0.13
|
|
|
|
|
|
|
|
* Thu Dec 03 2009 Silvan Calarco <silvan.calarco@mambasoft.it> 3.02pl4-2mamba
|
|
|
|
- don't provide pdf conversion tools but use libpoppler-tools (added as requirement)
|
|
|
|
|
|
|
|
* Sat Oct 24 2009 Automatic Build System <autodist@mambasoft.it> 3.02pl4-1mamba
|
|
|
|
- automatic update by autodist
|
|
|
|
|
|
|
|
* Fri Jul 10 2009 Automatic Build System <autodist@mambasoft.it> 3.02pl3-1mamba
|
|
|
|
- automatic update by autodist
|
|
|
|
|
|
|
|
* Tue Dec 30 2008 Silvan Calarco <silvan.calarco@mambasoft.it> 3.02pl2-1mamba
|
|
|
|
- update to 3.02pl2
|
|
|
|
|
|
|
|
* Tue Jul 15 2008 Silvan Calarco <silvan.calarco@mambasoft.it> 3.02-1mamba
|
|
|
|
- update to 3.02
|
|
|
|
|
|
|
|
* Thu Apr 27 2006 Davide Madrisan <davide.madrisan@qilinux.it> 3.01-7qilnx
|
|
|
|
- fixed desktop file
|
|
|
|
|
|
|
|
* Fri Feb 03 2006 Davide Madrisan <davide.madrisan@qilinux.it> 3.01-6qilnx
|
|
|
|
- security update for CVE-2006-0301 (qibug#122)
|
|
|
|
|
|
|
|
* Fri Jan 20 2006 Davide Madrisan <davide.madrisan@qilinux.it> 3.01-5qilnx
|
|
|
|
- security update for CVE-2005-2006, and CVE-2005-362[4,5,6,7] (qibug#105)
|
|
|
|
|
|
|
|
* Tue Dec 13 2005 Davide Madrisan <davide.madrisan@qilinux.it> 3.01-4qilnx
|
|
|
|
- fixed desktop file
|
|
|
|
|
|
|
|
* Wed Dec 07 2005 Davide Madrisan <davide.madrisan@qilinux.it> 3.01-3qilnx
|
|
|
|
- security fix CAN-2005-3193 (qibug#90)
|
|
|
|
|
|
|
|
* Wed Nov 09 2005 Davide Madrisan <davide.madrisan@qilinux.it> 3.01-2qilnx
|
|
|
|
- added desktop file
|
|
|
|
|
|
|
|
* Mon Aug 22 2005 Davide Madrisan <davide.madrisan@qilinux.it> 3.01-1qilnx
|
|
|
|
- update to version 3.01 by autospec
|
|
|
|
- fixed security issue QSA-2005-090 (CAN-2005-2097)
|
|
|
|
|
|
|
|
* Mon Feb 14 2005 Davide Madrisan <davide.madrisan@qilinux.it> 3.00-2qilnx
|
|
|
|
- rebuilt with new libt1 libraries
|
|
|
|
|
|
|
|
* Thu Jan 20 2005 Davide Madrisan <davide.madrisan@qilinux.it> 3.00-1qilnx
|
|
|
|
- update to version 3.00 by autospec
|
|
|
|
- fixed security issue QSA-2005-003 (CAN-2004-1125)
|
|
|
|
- added support for arabic, chinese-simplified, chinese-traditional,
|
|
|
|
cyrillic, greek, hebrew, japanese, korean, latin2, thai, turkish
|
|
|
|
|
|
|
|
* Sat Nov 27 2004 Davide Madrisan <davide.madrisan@qilinux.it> 2.03-4qilnx
|
|
|
|
- fixed size of `times-medium-r-normal' in XPDFViewer.cc
|
|
|
|
|
|
|
|
* Sat Oct 30 2004 Davide Madrisan <davide.madrisan@qilinux.it> 2.03-3qilnx
|
|
|
|
- added a patch to customize the xpdf configuration file:
|
|
|
|
- ghostscript and TTF fonts path fixed/added
|
|
|
|
- font anti-aliasing enabled
|
|
|
|
- paper size default set to A4
|
|
|
|
- default printer set to kprinter (KDE printer)
|
|
|
|
- browser for URL hyperlink set to konqueror
|
|
|
|
- added the requirement `ghostscript-fonts'
|
|
|
|
|
|
|
|
* Thu Oct 28 2004 Davide Madrisan <davide.madrisan@qilinux.it> 2.03-2qilnx
|
|
|
|
- security fix (QSA-2004-047): CAN-2004-0888
|
|
|
|
|
|
|
|
* Mon Jan 12 2004 Davide Madrisan <davide.madrisan@qilinux.it> 2.03-1qilnx
|
|
|
|
- package updated
|
|
|
|
|
|
|
|
* Thu Sep 25 2003 Silvan Calarco <silvan.calarco@mambasoft.it> 2.02pl1-1qilnx
|
|
|
|
- first build
|