import python-backports-tarfile-1.2.0-1.el9

i9 changed/i9/python-backports-tarfile-1.2.0-1.el9
Arkady L. Shane 4 months ago
commit 830c9da09d
Signed by: tigro
GPG Key ID: 1EC08A25C9DB2503

1
.gitignore vendored

@ -0,0 +1 @@
SOURCES/backports_tarfile-1.2.0.tar.gz

@ -0,0 +1 @@
3558f85d00164fadbd9d4112fddb4a5621782e65 SOURCES/backports_tarfile-1.2.0.tar.gz

@ -0,0 +1,88 @@
## START: Set by rpmautospec
## (rpmautospec version 0.7.2)
## RPMAUTOSPEC: autorelease, autochangelog
%define autorelease(e:s:pb:n) %{?-p:0.}%{lua:
release_number = 1;
base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}"));
print(release_number + base_release_number - 1);
}%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{!?-n:%{?dist}}
## END: Set by rpmautospec
# Circular dependencies in the testing chain
%if 0%{?epel} == 9
%bcond_with test
%else
%bcond_without test
%endif
Name: python-backports-tarfile
Version: 1.2.0
Release: %autorelease
Summary: Backport of CPython tarfile module
License: MIT
URL: https://github.com/jaraco/backports.tarfile
Source: %{pypi_source backports_tarfile}
BuildArch: noarch
BuildRequires: python3-devel
BuildRequires: tomcli
%global _description %{expand:
Backport of CPython tarfile module.}
%description %_description
%package -n python3-backports-tarfile
Summary: %{summary}
%description -n python3-backports-tarfile %_description
%prep
%autosetup -p1 -n backports_tarfile-%{version}
# Remove dev dependencies
tomcli set pyproject.toml lists delitem "project.optional-dependencies.testing" "pytest-.*"
%if 0%{?epel} == 9
# Change the build backend in EPEL9 because `setuptools>=61.2` is needed for PEP621
tomcli set pyproject.toml lists str "build-system.requires" "hatchling" "hatch-vcs"
tomcli set pyproject.toml str "build-system.build-backend" "hatchling.build"
tomcli set pyproject.toml str "tool.hatch.version.source" "vcs"
tomcli set pyproject.toml lists str "tool.hatch.build.targets.wheel.packages" "backports"
%endif
# tests are calling `python3 -m ...` which would need to keep PYTHONPATH env-var pointing to the installed package
sed -i "s/\\('-m', 'backports.tarfile',\\)/\\1 __cleanenv=False,/g" tests/test_tarfile.py
%generate_buildrequires
%pyproject_buildrequires %{?with_test:-x testing}
%build
%pyproject_wheel
%install
%pyproject_install
%pyproject_save_files backports
%check
%pyproject_check_import
%if %{with test}
%pytest
%endif
%files -n python3-backports-tarfile -f %{pyproject_files}
%license LICENSE
%doc README.rst
%changelog
* Sat Sep 28 2024 Arkady L. Shane <tigro@msvsphere-os.ru> - 1.2.0-1
- Rebuilt for MSVSphere 9.4
## START: Generated by rpmautospec
* Fri Sep 20 2024 Cristian Le <cristian.le@mpsd.mpg.de> - 1.2.0-1
- import rhbz#2312851
## END: Generated by rpmautospec
Loading…
Cancel
Save