You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
cargo2rpm/cargo2rpm.spec

55 lines
1.0 KiB

%bcond_without check
%if %{defined el9}
%global python3_pkgversion 3.11
%endif
Name: cargo2rpm
Version: 0.1.16
Release: %autorelease
Summary: Translation layer between cargo and RPM
License: MIT
URL: https://pagure.io/fedora-rust/cargo2rpm
Source: %{url}/archive/%{version}/cargo2rpm-%{version}.tar.gz
BuildArch: noarch
BuildRequires: python%{python3_pkgversion}-devel
%if %{with check}
BuildRequires: %{py3_dist pytest}
%endif
Requires: cargo
%description
cargo2rpm implements a translation layer between cargo and RPM. It
provides a CLI interface (for implementing RPM macros and generators)
and a Python API (which rust2rpm is built upon).
%prep
%autosetup -p1
%generate_buildrequires
%pyproject_buildrequires
%build
%pyproject_wheel
%install
%pyproject_install
%pyproject_save_files cargo2rpm
%check
%pyproject_check_import
%if %{with check}
%pytest
%endif
%files -f %{pyproject_files}
%doc README.md
%doc CHANGELOG.md
%{_bindir}/cargo2rpm
%changelog
%autochangelog