Blame rust-maybe-owned.spec

56af0b4
# Generated by rust2rpm 17
56af0b4
%bcond_without check
56af0b4
%global debug_package %{nil}
56af0b4
56af0b4
%global crate maybe-owned
56af0b4
56af0b4
Name:           rust-%{crate}
56af0b4
Version:        0.3.4
56af0b4
Release:        1%{?dist}
56af0b4
Summary:        Provides Rust enums MaybeOwned and MaybeOwnedMut
56af0b4
56af0b4
# Upstream license specification: MIT OR Apache-2.0
56af0b4
License:        MIT or ASL 2.0
56af0b4
URL:            https://crates.io/crates/maybe-owned
56af0b4
Source:         %{crates_source}
56af0b4
56af0b4
ExclusiveArch:  %{rust_arches}
56af0b4
%if %{__cargo_skip_build}
56af0b4
BuildArch:      noarch
56af0b4
%endif
56af0b4
56af0b4
BuildRequires:  rust-packaging
56af0b4
56af0b4
%global _description %{expand:
56af0b4
Provides a `MaybeOwned` (and `MaybeOwnedMut`) type similar to std's `Cow` but
56af0b4
it implements `From<T>` and `From<&'a T>` and does not require `ToOwned`.}
56af0b4
56af0b4
%description %{_description}
56af0b4
56af0b4
%package        devel
56af0b4
Summary:        %{summary}
56af0b4
BuildArch:      noarch
56af0b4
56af0b4
%description    devel %{_description}
56af0b4
56af0b4
This package contains library source intended for building other packages
56af0b4
which use "%{crate}" crate.
56af0b4
56af0b4
%files          devel
56af0b4
%doc README.md
56af0b4
%license LICENSE-APACHE LICENSE-MIT
56af0b4
%{cargo_registry}/%{crate}-%{version_no_tilde}/
56af0b4
56af0b4
%package     -n %{name}+default-devel
56af0b4
Summary:        %{summary}
56af0b4
BuildArch:      noarch
56af0b4
56af0b4
%description -n %{name}+default-devel %{_description}
56af0b4
56af0b4
This package contains library source intended for building other packages
56af0b4
which use "default" feature of "%{crate}" crate.
56af0b4
56af0b4
%files       -n %{name}+default-devel
56af0b4
%ghost %{cargo_registry}/%{crate}-%{version_no_tilde}/Cargo.toml
56af0b4
56af0b4
%package     -n %{name}+serde-devel
56af0b4
Summary:        %{summary}
56af0b4
BuildArch:      noarch
56af0b4
56af0b4
%description -n %{name}+serde-devel %{_description}
56af0b4
56af0b4
This package contains library source intended for building other packages
56af0b4
which use "serde" feature of "%{crate}" crate.
56af0b4
56af0b4
%files       -n %{name}+serde-devel
56af0b4
%ghost %{cargo_registry}/%{crate}-%{version_no_tilde}/Cargo.toml
56af0b4
56af0b4
%prep
56af0b4
%autosetup -n %{crate}-%{version_no_tilde} -p1
56af0b4
%cargo_prep
56af0b4
56af0b4
%generate_buildrequires
56af0b4
%cargo_generate_buildrequires
56af0b4
56af0b4
%build
56af0b4
%cargo_build
56af0b4
56af0b4
%install
56af0b4
%cargo_install
56af0b4
56af0b4
%if %{with check}
56af0b4
%check
56af0b4
%cargo_test
56af0b4
%endif
56af0b4
56af0b4
%changelog
56af0b4
* Wed May 26 23:38:29 CEST 2021 Olivier Lemasle <o.lemasle@gmail.com> - 0.3.4-1
56af0b4
- Initial package