update to 3.2.1 [release 3.2.1-1mamba;Wed Jan 18 2023]

This commit is contained in:
Silvan Calarco 2024-01-05 16:28:07 +01:00
parent a5727121ac
commit 3ada78df26

View File

@ -1,22 +1,20 @@
%define pkgname %(echo %name | cut -d- -f2- | tr - _)
Name: python-pypdf
Version: 1.13
Release: 2mamba
Version: 3.2.1
Release: 1mamba
Summary: PDF toolkit
Group: System/Libraries/Python
Vendor: openmamba
Distribution: openmamba
Packager: Automatic Build System <autodist@mambasoft.it>
URL: http://pybrary.net/pyPdf/
Source: http://pybrary.net/pyPdf/pyPdf-%{version}.tar.gz
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
URL: https://pypi.org/project/pypdf/
Source: https://pypi.debian.net/pypdf/pypdf-%{version}.tar.gz
Patch: python-pypdf-1.12-git20100718.patch
License: BSD
## AUTOBUILDREQ-BEGIN
BuildRequires: libpython-devel
BuildRequires: libpython3-devel
BuildRequires: python3.7dist(typing-extensions)
## AUTOBUILDREQ-END
Provides: python-pyPdf
Obsoletes: python-pyPdf
Requires: python >= %python_version
BuildRoot: %{_tmppath}/%{name}-%{version}-root
BuildArch: noarch
%description
@ -30,32 +28,44 @@ It is capable of:
* merging multiple pages into a single page,
* encrypting and decrypting PDF files.
%if 0%{?with_pyver}
%define py_requires_append \
Provides: python-pyPdf \
Obsoletes: python-pyPdf < 3.2.1 \
Provides: python-pypdf \
Obsoletes: python-pypdf < 3.2.1
%pyver_package
%endif
%prep
%setup -q -n pyPdf-%{version}
%setup -q -n pypdf-%{version}
#%patch -p1
%build
%{__python} setup.py build
CFLAGS="%{optflags}" %{__python} -m build --no-isolation --wheel
%install
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%{__python} setup.py install \
-O1 --skip-build \
--root="%{buildroot}" \
--install-headers=%{_includedir}/python \
--install-lib=%{python_sitearch} \
--record=%{name}.filelist
%{__python} -m installer --destdir=%{buildroot} dist/*.whl
sed -i "\,\.egg-info/,d;s,.*/man/.*,&.gz," %{name}.filelist
#%if "%{?with_pyver}" != "3"
## Rename any conflicting file outside of python site packages tree
#for f in %{_bindir}/pdm; do
# mv %{buildroot}${f}{,-%{?pyappend}}
#done
#%endif
%clean
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%files -f %{name}.filelist
%files %{?pyappend}
%defattr(-,root,root)
%doc README CHANGELOG
%dir %{python_sitelib}/%{pkgname}-%{version}.dist-info
%{python_sitelib}/%{pkgname}-%{version}.dist-info/*
%dir %{python_sitelib}/%{pkgname}
%{python_sitelib}/%{pkgname}/*
%changelog
* Wed Jan 18 2023 Silvan Calarco <silvan.calarco@mambasoft.it> 3.2.1-1mamba
- update to 3.2.1
* Fri May 17 2013 Silvan Calarco <silvan.calarco@mambasoft.it> 1.13-2mamba
- python 2.7 mass rebuild