You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
zathura-pdf-mupdf/zathura-pdf-mupdf.spec

108 lines
3.6 KiB

Name: zathura-pdf-mupdf
Version: 0.3.1
Release: 3%{?dist}
Summary: PDF support for zathura via mupdf
License: zlib
URL: http://pwmt.org/projects/zathura/plugins/%{name}
Source0: http://pwmt.org/projects/zathura/plugins/download/%{name}-%{version}.tar.gz
BuildRequires: binutils
BuildRequires: coreutils
BuildRequires: desktop-file-utils
BuildRequires: gcc
BuildRequires: make
BuildRequires: pkgconfig
BuildRequires: sed
BuildRequires: jbig2dec-devel
BuildRequires: libjpeg-turbo-devel
BuildRequires: mujs-static
BuildRequires: mupdf-devel
BuildRequires: openjpeg2-devel
BuildRequires: pkgconfig(girara-gtk3)
BuildRequires: pkgconfig(gtk+-3.0)
BuildRequires: pkgconfig(libcrypto)
BuildRequires: pkgconfig(zathura)
Requires: zathura
Requires(post): %{_sbindir}/update-alternatives
Requires(post): desktop-file-utils
Requires(postun): %{_sbindir}/update-alternatives
Requires(postun): desktop-file-utils
# Ensure zathura-pdf-poppler supports alternatives
Conflicts: zathura-pdf-poppler < 0.2.5-5
%description
This plugin adds PDF support to zathura using the mupdf rendering engine.
%prep
%setup -q
# Don't rebuild during install phase
sed -i 's/^install:\s*all/install:/' Makefile
%build
CFLAGS='%{optflags}' make %{?_smp_mflags} LIBDIR=%{_libdir} MUPDF_LIB=-lmupdf debug
mv pdf-debug.so pdf.so
%install
make DESTDIR=%{buildroot} LIBDIR=%{_libdir} install
mv %{buildroot}/%{_libdir}/zathura/pdf.so \
%{buildroot}/%{_libdir}/zathura/pdf.so.mupdf
touch %{buildroot}/%{_libdir}/zathura/pdf.so
desktop-file-validate %{buildroot}/%{_datadir}/applications/%{name}.desktop
%post
%{_sbindir}/update-alternatives --install \
%{_libdir}/zathura/pdf.so %{name} %{_libdir}/zathura/pdf.so.mupdf 5
update-desktop-database &> /dev/null || :
%postun
if [ $1 -eq 0 ] ; then
%{_sbindir}/update-alternatives --remove \
%{name} %{_libdir}/zathura/pdf.so.mupdf
fi
update-desktop-database &> /dev/null || :
%files
%license LICENSE
%doc AUTHORS
%ghost %{_libdir}/zathura/pdf.so
%{_libdir}/zathura/pdf.so.mupdf
%{_datadir}/applications/%{name}.desktop
%changelog
* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.3.1-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.3.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
* Tue Apr 04 2017 Petr Šabata <contyk@redhat.com> - 0.3.1-1
- 0.3.1 bump
- Don't link against the no longer provided libmupdfthird,
see rhbz#1438824 for more info
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.3.0-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
* Wed Nov 16 2016 Petr Šabata <contyk@redhat.com> - 0.3.0-3
- Rebuild against mujs-0-6.20161031gita0ceaf5
* Thu Sep 29 2016 Petr Šabata <contyk@redhat.com> - 0.3.0-2
- Rebuild against mujs-0-5.20160921git5c337af
* Fri Feb 26 2016 Petr Šabata <contyk@redhat.com> - 0.3.0-1
- 0.3.0 bump
* Fri Feb 05 2016 Fedora Release Engineering <releng@fedoraproject.org> - 0.2.8-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
* Mon Nov 16 2015 Petr Šabata <contyk@redhat.com> - 0.2.8-4
- Rebuild with mujs-0-1.20150929git0827611
* Wed Jul 01 2015 Petr Šabata <contyk@redhat.com> - 0.2.8-3
- Handle the desktop file properly
* Tue Jun 23 2015 Petr Šabata <contyk@redhat.com> - 0.2.8-2
- Correct the %%files section
* Tue Jun 09 2015 Petr Šabata <contyk@redhat.com> - 0.2.8-1
- Initial packaging