2020-10-08 10:03:10 +00:00
|
|
|
#
|
|
|
|
# spec file for package python-python-poppler
|
|
|
|
#
|
2025-01-13 01:29:49 +00:00
|
|
|
# Copyright (c) 2025 SUSE LLC
|
2020-10-08 10:03:10 +00:00
|
|
|
# Copyright (c) 2020 LISA GmbH ,Bingen, 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/
|
|
|
|
#
|
|
|
|
|
|
|
|
|
|
|
|
Name: python-python-poppler
|
2025-01-13 01:29:49 +00:00
|
|
|
Version: 0.4.1
|
2020-10-08 10:03:10 +00:00
|
|
|
Release: 0
|
|
|
|
Summary: Python binding to the poppler-cpp library
|
|
|
|
License: GPL-2.0-only
|
|
|
|
URL: https://github.com/cbrunet/python-poppler
|
2025-01-13 01:29:49 +00:00
|
|
|
Source: https://github.com/cbrunet/python-poppler/archive/refs/tags/v%{version}.tar.gz#/python-poppler-%{version}.tar.gz
|
|
|
|
# PATCH-FEATURE-OPENSUSE Build against system pybind11
|
|
|
|
Patch0: use-system-pybind11.patch
|
2025-01-20 01:37:27 +00:00
|
|
|
# PATCH-FIX-UPSTREAM gh#cbrunet/python-poppler#92
|
|
|
|
Patch1: support-poppler-25.01.patch
|
2025-01-13 01:29:49 +00:00
|
|
|
BuildRequires: %{python_module devel >= 3.7}
|
|
|
|
BuildRequires: %{python_module meson-python}
|
|
|
|
BuildRequires: %{python_module pip}
|
2020-10-08 10:03:10 +00:00
|
|
|
BuildRequires: %{python_module pybind11-devel}
|
|
|
|
BuildRequires: %{python_module pytest}
|
2025-01-13 01:29:49 +00:00
|
|
|
BuildRequires: %{python_module wheel}
|
2020-10-08 10:03:10 +00:00
|
|
|
BuildRequires: c++_compiler
|
|
|
|
BuildRequires: fdupes
|
2025-01-13 01:29:49 +00:00
|
|
|
BuildRequires: ninja
|
2021-03-22 01:35:42 +00:00
|
|
|
BuildRequires: pkg-config
|
2020-10-08 10:03:10 +00:00
|
|
|
BuildRequires: python-rpm-macros
|
|
|
|
BuildRequires: pkgconfig(poppler)
|
2021-08-28 09:07:46 +00:00
|
|
|
# some tests require this
|
2020-10-08 10:03:10 +00:00
|
|
|
BuildRequires: poppler-data
|
|
|
|
%python_subpackages
|
|
|
|
|
|
|
|
%description
|
|
|
|
python-poppler is a Python binding to the poppler-cpp library. It allows to
|
|
|
|
read, render, or modify PDF documents. More specifically, it currently allows
|
|
|
|
to:
|
|
|
|
read an modify document meta data;
|
|
|
|
list and read embedded documents;
|
|
|
|
list the fonts used by the document;
|
|
|
|
search or extract text on a given page of the document;
|
|
|
|
render a page to a raw image;
|
|
|
|
get info about transitions effects between the pages;
|
|
|
|
read the table of contents of the document.
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%autosetup -p1 -n python-poppler-%version
|
2025-01-13 01:29:49 +00:00
|
|
|
rm -rf subprojects
|
2020-10-08 10:03:10 +00:00
|
|
|
|
|
|
|
%build
|
|
|
|
export CXXFLAGS="%{optflags}"
|
2025-01-13 01:29:49 +00:00
|
|
|
%pyproject_wheel
|
2020-10-08 10:03:10 +00:00
|
|
|
|
|
|
|
%install
|
2025-01-13 01:29:49 +00:00
|
|
|
%pyproject_install
|
2020-10-08 10:03:10 +00:00
|
|
|
%python_expand %fdupes %{buildroot}%{$python_sitearch}
|
|
|
|
|
|
|
|
%check
|
2025-01-13 01:29:49 +00:00
|
|
|
%pytest_arch tests
|
2020-10-08 10:03:10 +00:00
|
|
|
|
|
|
|
%files %{python_files}
|
|
|
|
%license LICENSE.txt
|
2021-03-22 01:35:42 +00:00
|
|
|
%doc README.md
|
2021-08-28 09:07:46 +00:00
|
|
|
%{python_sitearch}/poppler
|
2025-01-13 01:29:49 +00:00
|
|
|
%{python_sitearch}/python_poppler-%{version}.dist-info
|
2020-10-08 10:03:10 +00:00
|
|
|
|
|
|
|
%changelog
|