forked from pool/python-PyMuPDF
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-PyMuPDF?expand=0&rev=3
71 lines
2.3 KiB
RPMSpec
71 lines
2.3 KiB
RPMSpec
#
|
|
# spec file for package python-PyMuPDF
|
|
#
|
|
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
|
|
#
|
|
# 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/
|
|
#
|
|
|
|
|
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
|
%define pypi_name PyMuPDF
|
|
Name: python-%{pypi_name}
|
|
Version: 1.14.14
|
|
Release: 0
|
|
Summary: Python binding for MuPDF - a lightweight PDF and XPS viewer
|
|
License: GPL-3.0-only AND AGPL-3.0-only
|
|
Group: Development/Languages/Python
|
|
URL: https://github.com/rk700/PyMuPDF
|
|
Source0: %{url}/archive/%{version}/%{pypi_name}-%{version}.tar.gz
|
|
Patch1: fix-library-linking.patch
|
|
BuildRequires: %{python_module devel}
|
|
BuildRequires: %{python_module setuptools}
|
|
BuildRequires: fdupes
|
|
BuildRequires: gcc
|
|
BuildRequires: jbig2dec-devel
|
|
BuildRequires: mupdf-devel-static
|
|
BuildRequires: pkgconfig
|
|
BuildRequires: python-rpm-macros
|
|
BuildRequires: pkgconfig(freetype2)
|
|
BuildRequires: pkgconfig(harfbuzz)
|
|
BuildRequires: pkgconfig(libjpeg)
|
|
BuildRequires: pkgconfig(libopenjp2)
|
|
BuildRequires: pkgconfig(zlib)
|
|
%python_subpackages
|
|
|
|
%description
|
|
|
|
This is PyMuPDF, a Python binding for MuPDF - a lightweight PDF and XPS
|
|
viewer. MuPDF can access files in PDF, XPS, OpenXPS, epub, comic and fiction
|
|
book formats, and it is known for its top performance and high rendering
|
|
quality. With PyMuPDF you therefore can also access files with extensions
|
|
*.pdf, *.xps, *.oxps, *.epub, *.cbz or *.fb2 from your Python scripts.
|
|
|
|
%prep
|
|
%setup -q -n %{pypi_name}-%{version}
|
|
%patch1 -p1
|
|
|
|
%build
|
|
export CFLAGS="%{optflags}"
|
|
%python_build
|
|
|
|
%install
|
|
%python_install
|
|
%python_expand %fdupes %{buildroot}%{$python_sitearch}
|
|
|
|
%files %{python_files}
|
|
%license COPYING
|
|
%doc README.md doc/PyMuPDF.pdf
|
|
%{python_sitearch}/*
|
|
|
|
%changelog
|