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.
rust-weezl/rust-weezl.spec

142 lines
3.5 KiB

# Generated by rust2rpm 26
%bcond_without check
%global crate weezl
Name: rust-weezl
Version: 0.1.8
Release: %autorelease
Summary: Fast LZW compression and decompression
License: MIT OR Apache-2.0
URL: https://crates.io/crates/weezl
Source: %{crates_source}
# Manually created patch for downstream crate metadata changes
# * drop unused, benchmark-only criterion dev-dependency
# * Update the tokio-util dev-dependency to 0.7.x
# (https://github.com/image-rs/weezl/pull/44)
Patch: weezl-fix-metadata.diff
BuildRequires: cargo-rpm-macros >= 24
%global _description %{expand:
Fast LZW compression and decompression.}
%description %{_description}
%package -n %{crate}
Summary: %{summary}
# MIT OR Apache-2.0
License: MIT OR Apache-2.0
# LICENSE.dependencies contains a full license breakdown
%description -n %{crate} %{_description}
%files -n %{crate}
%license LICENSE-APACHE
%license LICENSE-MIT
%license LICENSE.dependencies
%doc Changes.md
%doc README.md
%{_bindir}/lzw
%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}/Changes.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}+async-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+async-devel %{_description}
This package contains library source intended for building other packages which
use the "async" feature of the "%{crate}" crate.
%files -n %{name}+async-devel
%ghost %{crate_instdir}/Cargo.toml
%package -n %{name}+futures-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+futures-devel %{_description}
This package contains library source intended for building other packages which
use the "futures" feature of the "%{crate}" crate.
%files -n %{name}+futures-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
%prep
%autosetup -n %{crate}-%{version} -p1
%cargo_prep
%generate_buildrequires
%cargo_generate_buildrequires
%build
%cargo_build
%{cargo_license_summary}
%{cargo_license} > LICENSE.dependencies
%install
%cargo_install
%if %{with check}
%check
# * files needed for encode/decode tests are not included in published crates
%cargo_test -- --doc
%endif
%changelog
%autochangelog