File zathura.spec of Package zathura

#
# spec file for package zathura
#
# Copyright (c) 2020 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via https://bugs.opensuse.org/
#


Name:           zathura
Version:        0.4.5
Release:        0
Summary:        A customizable document viewer
License:        Zlib
URL:            http://pwmt.org/projects/zathura/
# main homepage looks dead
#Source:         http://pwmt.org/projects/zathura/download/%{name}-%{version}.tar.xz
Source:         https://git.pwmt.org/pwmt/zathura/-/archive/%{version}/%{name}-%{version}.tar.gz
BuildRequires:  appstream-glib
BuildRequires:  desktop-file-utils
BuildRequires:  file-devel
BuildRequires:  fish
BuildRequires:  libseccomp-devel
BuildRequires:  meson
BuildRequires:  pkgconfig
BuildRequires:  python3-Sphinx
BuildRequires:  zsh
BuildRequires:  pkgconfig(check)
BuildRequires:  pkgconfig(girara-gtk3) >= 0.3.2
BuildRequires:  pkgconfig(sqlite3)
Recommends:     %{name}-lang
Recommends:     zathura-pdf-poppler-plugin
Suggests:       zathura-cb-plugin
Suggests:       zathura-djvu-plugin
Suggests:       zathura-ps-plugin
BuildRequires:  rsvg-convert
%if 0%{suse_version} >= 1550
BuildRequires:  pkgconfig(synctex) >= 1.19
%endif

%description
zathura is a customizable document viewer. It provides a minimalistic
and space-saving interface as well as a keyboard-centric interaction.

%package devel
Summary:        Development files for zathura
Requires:       %{name} = %{version}

%description devel
Development and header files for the zathura package.

%package bash-completion
Summary:        Zathura Bash completion
Requires:       %{name} = %{version}
Requires:       bash-completion
Supplements:    (%{name} and bash)

%description bash-completion
Optional dependency offering bash completion for zathura

%package zsh-completion
Summary:        Zathura zsh completion
Requires:       %{name} = %{version}
Requires:       zsh
Supplements:    (%{name} and zsh)

%description zsh-completion
Optional dependency offering zsh completion for zathura

%package fish-completion
Summary:        Zathura fish completion
Requires:       %{name} = %{version}
Requires:       fish
Supplements:    (%{name} and fish)

%description fish-completion
Optional dependency offering fish completion for zathura

%lang_package

%prep
%setup -q

%build
export CFLAGS="%{optflags}"
%if 0%{suse_version} < 1550
%meson -Dsynctex=disabled
%else
%meson
%endif
%meson_build

%check
%meson_test

%install
%meson_install
%find_lang %{name} %{?no_lang_C}

%files
%license LICENSE
%doc README AUTHORS
%dir %{_datadir}/icons/scalable
%dir %{_datadir}/icons/scalable/apps
%{_bindir}/%{name}
%{_datadir}/dbus-1/interfaces/org.pwmt.%{name}.xml
%{_mandir}/man1/%{name}.1%{?ext_man}
%{_mandir}/man5/%{name}rc.5%{?ext_man}
%{_datadir}/applications/org.pwmt.zathura.desktop
%{_datadir}/icons/hicolor/*/apps/org.pwmt.zathura.png
%{_datadir}/metainfo/org.pwmt.zathura.appdata.xml
%{_datadir}/icons/scalable/apps/org.pwmt.zathura.svg

%files devel
%dir %{_includedir}/%{name}
%{_includedir}/%{name}/*.h
%{_libdir}/pkgconfig/%{name}.pc

%files bash-completion
%{_datadir}/bash-completion/completions/zathura

%files zsh-completion
%{_datadir}/zsh/site-functions/_zathura

%files fish-completion
%{_datadir}/fish/completions/zathura.fish

%files lang -f %{name}.lang

%changelog
openSUSE Build Service is sponsored by