Name: zathura-pdf-mupdf Version: 0.2.8 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: 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(zathura) BuildRequires: pkgconfig(gtk+-3.0) BuildRequires: pkgconfig(girara-gtk3) BuildRequires: pkgconfig(libcrypto) 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} 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 * Wed Jul 01 2015 Petr Šabata - 0.2.8-3 - Handle the desktop file properly * Tue Jun 23 2015 Petr Šabata - 0.2.8-2 - Correct the %%files section * Tue Jun 09 2015 Petr Šabata - 0.2.8-1 - Initial packaging