From 608a8b5af6ba4ead9c0002d72daf4a1cac596128 Mon Sep 17 00:00:00 2001 From: MSVSphere Packaging Team Date: Fri, 25 Oct 2024 18:51:35 +0300 Subject: [PATCH] import python-rpds-py-0.17.1-5.el10 --- .gitignore | 2 + .python-rpds-py.metadata | 2 + SPECS/python-rpds-py.spec | 111 ++++++++++++++++++++++++++++++++++++++ 3 files changed, 115 insertions(+) create mode 100644 .gitignore create mode 100644 .python-rpds-py.metadata create mode 100644 SPECS/python-rpds-py.spec diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..351a4b6 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +SOURCES/rpds_py-0.17.1-vendor.tar.xz +SOURCES/rpds_py-0.17.1.tar.gz diff --git a/.python-rpds-py.metadata b/.python-rpds-py.metadata new file mode 100644 index 0000000..b7a9281 --- /dev/null +++ b/.python-rpds-py.metadata @@ -0,0 +1,2 @@ +17eddad501f79f666bb1cca5485fd28715e8e522 SOURCES/rpds_py-0.17.1-vendor.tar.xz +2a7e3b4ea7f023c554d1b4d21d6332207810e37a SOURCES/rpds_py-0.17.1.tar.gz diff --git a/SPECS/python-rpds-py.spec b/SPECS/python-rpds-py.spec new file mode 100644 index 0000000..33e031c --- /dev/null +++ b/SPECS/python-rpds-py.spec @@ -0,0 +1,111 @@ +## START: Set by rpmautospec +## (rpmautospec version 0.6.1) +## RPMAUTOSPEC: autorelease, autochangelog +%define autorelease(e:s:pb:n) %{?-p:0.}%{lua: + release_number = 5; + 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 + +%global srcname rpds-py +%global modname rpds_py + +Name: python-rpds-py +Version: 0.17.1 +Release: %autorelease +Summary: Python bindings to the Rust rpds crate +# Full license breakdown in LICENSES.dependencies +License: MIT AND Apache-2.0 AND (MIT OR Apache-2.0) AND MPL-2.0 +URL: https://github.com/crate-py/rpds +Source: %{pypi_source %{modname}} +# To create the vendor tarball: +# tar xf %%{modname}-%%{version}.tar.gz ; pushd %%{modname}-%%{version} ; \ +# cargo vendor && tar Jcvf ../%%{modname}-%%{version}-vendor.tar.xz vendor/ ; pushd +Source: %{modname}-%{version}-vendor.tar.xz + +%if 0%{?rhel} +BuildRequires: rust-toolset +%else +BuildRequires: cargo-rpm-macros +%endif +BuildRequires: dos2unix +BuildRequires: python3-devel +BuildRequires: python3-pytest + +%global _description %{expand: +Python bindings to the Rust rpds crate.} + +%description %_description + +%package -n python3-%{srcname} +Summary: %{summary} + +%description -n python3-%{srcname} %_description + + +%prep +%autosetup -p1 -n %{modname}-%{version} %{?rhel:-a1} + +# Fix line terminations +dos2unix README* LICENSE* *.pyi + +# Fix for bad requirements dependency +sed -r -i 's/^file:/# &/' tests/requirements.in + +%cargo_prep %{?rhel:-v vendor} +rm -f Cargo.lock + + +%generate_buildrequires +%pyproject_buildrequires tests/requirements.in +%if %{undefined rhel} +%cargo_generate_buildrequires +%endif + + +%build +export RUSTFLAGS='%{build_rustflags}' +%cargo_license_summary +%{cargo_license} > LICENSES.dependencies +%if %{defined rhel} +%cargo_vendor_manifest +%endif +%pyproject_wheel + + +%install +%pyproject_install + +%pyproject_save_files rpds + + +%check +%pytest -vv + + +%files -n python3-%{srcname} -f %{pyproject_files} +%license LICENSE LICENSES.dependencies +%if %{defined rhel} +%license cargo-vendor.txt +%endif +%doc README.rst + + +%changelog +* Fri Oct 25 2024 MSVSphere Packaging Team - 0.17.1-5 +- Rebuilt for MSVSphere 10 + +## START: Generated by rpmautospec +* Mon Jun 24 2024 Troy Dawson - 0.17.1-5 +- Bump release for June 2024 mass rebuild + +* Thu Feb 01 2024 Yaakov Selkowitz - 0.17.1-4 +- Update Rust macro usage + +* Mon Jan 29 2024 Yaakov Selkowitz - 0.17.1-3 +- Revendor + +* Sun Jan 28 2024 Yaakov Selkowitz - 0.17.1-2 +- RPMAUTOSPEC: unresolvable merge +## END: Generated by rpmautospec