File rust-chacha20poly1305-0.9.spec of Package rust-chacha20poly1305-0.9

# Generated by rust2rpm 27
%bcond check 1
%global debug_package %{nil}

%global crate chacha20poly1305

Name:           rust-%{crate}-0.9
Version:        0.9.1
Release:        1%{?dist}
Summary:        Pure Rust implementation of the ChaCha20Poly1305 Authenticated Encryption with Additional Data Cipher

License:        Apache-2.0 OR MIT
URL:            https://crates.io/crates/chacha20poly1305
Source:         https://crates.io/api/v1/crates/%crate/%version/download#/%crate-%version.crate

BuildRequires:  cargo-rpm-macros >= 24

%global _description %{expand:
Pure Rust implementation of the ChaCha20Poly1305 Authenticated
Encryption with Additional Data Cipher (RFC 8439) with optional
architecture-specific hardware acceleration. Also contains
implementations of the XChaCha20Poly1305 extended nonce variant of
ChaCha20Poly1305, and the reduced-round ChaCha8Poly1305 and
ChaCha12Poly1305 lightweight variants.}

%description %{_description}

%package        devel
Summary:        %{summary}
BuildArch:      noarch

%description    devel %{_description}

This package contains library source intended for building other packages which
use the "%{crate}" crate.

%files          devel
%license %{crate_instdir}/LICENSE-APACHE
%license %{crate_instdir}/LICENSE-MIT
%doc %{crate_instdir}/CHANGELOG.md
%doc %{crate_instdir}/README.md
%{crate_instdir}/

%package     -n %{name}+default-devel
Summary:        %{summary}
BuildArch:      noarch

%description -n %{name}+default-devel %{_description}

This package contains library source intended for building other packages which
use the "default" feature of the "%{crate}" crate.

%files       -n %{name}+default-devel
%ghost %{crate_instdir}/Cargo.toml

%package     -n %{name}+alloc-devel
Summary:        %{summary}
BuildArch:      noarch

%description -n %{name}+alloc-devel %{_description}

This package contains library source intended for building other packages which
use the "alloc" feature of the "%{crate}" crate.

%files       -n %{name}+alloc-devel
%ghost %{crate_instdir}/Cargo.toml

%package     -n %{name}+force-soft-devel
Summary:        %{summary}
BuildArch:      noarch

%description -n %{name}+force-soft-devel %{_description}

This package contains library source intended for building other packages which
use the "force-soft" feature of the "%{crate}" crate.

%files       -n %{name}+force-soft-devel
%ghost %{crate_instdir}/Cargo.toml

%package     -n %{name}+heapless-devel
Summary:        %{summary}
BuildArch:      noarch

%description -n %{name}+heapless-devel %{_description}

This package contains library source intended for building other packages which
use the "heapless" feature of the "%{crate}" crate.

%files       -n %{name}+heapless-devel
%ghost %{crate_instdir}/Cargo.toml

%package     -n %{name}+reduced-round-devel
Summary:        %{summary}
BuildArch:      noarch

%description -n %{name}+reduced-round-devel %{_description}

This package contains library source intended for building other packages which
use the "reduced-round" feature of the "%{crate}" crate.

%files       -n %{name}+reduced-round-devel
%ghost %{crate_instdir}/Cargo.toml

%package     -n %{name}+std-devel
Summary:        %{summary}
BuildArch:      noarch

%description -n %{name}+std-devel %{_description}

This package contains library source intended for building other packages which
use the "std" feature of the "%{crate}" crate.

%files       -n %{name}+std-devel
%ghost %{crate_instdir}/Cargo.toml

%package     -n %{name}+stream-devel
Summary:        %{summary}
BuildArch:      noarch

%description -n %{name}+stream-devel %{_description}

This package contains library source intended for building other packages which
use the "stream" feature of the "%{crate}" crate.

%files       -n %{name}+stream-devel
%ghost %{crate_instdir}/Cargo.toml

%prep
%autosetup -n %{crate}-%{version} -p1
%cargo_prep

%generate_buildrequires
%cargo_generate_buildrequires

%build
%cargo_build

%install
%cargo_install

%if %{with check}
%check
%cargo_test
%endif