# Generated by rust2rpm 25 %bcond_without check %global debug_package %{nil} %global crate lz4-sys Name: rust-lz4-sys Version: 1.9.4 Release: %autorelease Summary: Rust LZ4 sys package License: MIT URL: https://crates.io/crates/lz4-sys Source: %{crates_source} # Link system liblz4 when available # https://github.com/10XGenomics/lz4-rs/pull/39 # Rebased on the released crate; some of the changes are also in # lz4-sys-fix-metadata.diff. Patch: lz4-sys-1.9.4-system-liblz4.patch # Manually created patch for downstream crate metadata changes Patch: lz4-sys-fix-metadata.diff BuildRequires: cargo-rpm-macros >= 24 %global _description %{expand: Rust LZ4 sys package.} %description %{_description} %package devel Summary: %{summary} BuildArch: noarch Requires: pkgconfig(liblz4) %description devel %{_description} This package contains library source intended for building other packages which use the "%{crate}" crate. %files devel %doc %{crate_instdir}/CHANGELOG.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 %prep %autosetup -n %{crate}-%{version} -p1 # Remove the bundled copy of liblz4. rm -rv liblz4 %cargo_prep %generate_buildrequires %cargo_generate_buildrequires echo 'pkgconfig(liblz4)' %build %cargo_build %install %cargo_install %if %{with check} %check %cargo_test %endif %changelog %autochangelog