File rust-futures.spec of Package rust-futures

# Generated by rust2rpm 25
%bcond_without check
%global debug_package %{nil}

%global crate futures

Name:           rust-futures
Version:        0.3.30
Release:        %autorelease
Summary:        Implementation of futures and streams

License:        MIT OR Apache-2.0
URL:            https://crates.io/crates/futures
Source:         https://crates.io/api/v1/crates/%crate/%version/download#/%crate-%version.crate
# Manually created patch for downstream crate metadata changes
# * add missing futures-test dev-dependency
Patch:          futures-fix-metadata.diff

BuildRequires:  cargo-rpm-macros >= 24

%global _description %{expand:
An implementation of futures and streams featuring zero allocations,
composability, and iterator-like interfaces.}

%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}/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}+async-await-devel
Summary:        %{summary}
BuildArch:      noarch

%description -n %{name}+async-await-devel %{_description}

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

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

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

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

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

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

%package     -n %{name}+cfg-target-has-atomic-devel
Summary:        %{summary}
BuildArch:      noarch

%description -n %{name}+cfg-target-has-atomic-devel %{_description}

This package contains library source intended for building other packages which
use the "cfg-target-has-atomic" feature of the "%{crate}" crate.

%files       -n %{name}+cfg-target-has-atomic-devel
%ghost %{crate_instdir}/Cargo.toml

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

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

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

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

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

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

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

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

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

%description -n %{name}+futures-executor-devel %{_description}

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

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

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

%description -n %{name}+io-compat-devel %{_description}

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

%files       -n %{name}+io-compat-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}+thread-pool-devel
Summary:        %{summary}
BuildArch:      noarch

%description -n %{name}+thread-pool-devel %{_description}

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

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

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

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

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

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

%package     -n %{name}+write-all-vectored-devel
Summary:        %{summary}
BuildArch:      noarch

%description -n %{name}+write-all-vectored-devel %{_description}

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

%files       -n %{name}+write-all-vectored-devel
%ghost %{crate_instdir}/Cargo.toml

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

%generate_buildrequires

%build

%install
dir=%{buildroot}/%{crate_instdir}; mkdir -pv "$dir"; cp -R ./* $dir/; echo "{\"files\":{},\"package\":\"\"}" > "$dir/.cargo-checksum.json"  -a

%if %{with check}
%check
# * always skip a test that is officially "flaky"
# * skip a possibly flaky test:
#   https://github.com/rust-lang/futures-rs/issues/2539
# * skip a test which fails depending on Rust version:
#   sizes of some structs and enums changed between Rust 1.62 and 1.63
%endif

%changelog
%autochangelog
openSUSE Build Service is sponsored by