# Generated by rust2rpm %bcond_without check %global debug_package %{nil} %global crate cssparser Name: rust-%{crate} Version: 0.23.2 Release: 1%{?dist} Summary: Rust implementation of CSS Syntax Level 3 License: MPLv2.0 URL: https://crates.io/crates/cssparser Source0: https://crates.io/api/v1/crates/%{crate}/%{version}/download#/%{crate}-%{version}.crate # Initial patched metadata # * Bump difference to 2.0, https://github.com/servo/rust-cssparser/pull/212 Patch0: cssparser-0.23.2-fix-metadata.diff ExclusiveArch: %{rust_arches} BuildRequires: rust-packaging # [dependencies] BuildRequires: (crate(cssparser-macros) >= 0.3.0 with crate(cssparser-macros) < 0.4.0) BuildRequires: (crate(dtoa-short) >= 0.3.0 with crate(dtoa-short) < 0.4.0) BuildRequires: (crate(heapsize) >= 0.3.0 with crate(heapsize) < 0.5.0) BuildRequires: (crate(itoa) >= 0.3.0 with crate(itoa) < 0.4.0) BuildRequires: (crate(matches) >= 0.1.0 with crate(matches) < 0.2.0) BuildRequires: (crate(phf) >= 0.7.0 with crate(phf) < 0.8.0) BuildRequires: (crate(procedural-masquerade) >= 0.1.0 with crate(procedural-masquerade) < 0.2.0) BuildRequires: (crate(serde) >= 1.0.0 with crate(serde) < 2.0.0) BuildRequires: (crate(smallvec) >= 0.6.0 with crate(smallvec) < 0.7.0) # [build-dependencies] BuildRequires: (crate(quote) >= 0.3.0 with crate(quote) < 0.4.0) BuildRequires: (crate(syn) >= 0.11.0 with crate(syn) < 0.12.0) %if %{with check} # [dev-dependencies] BuildRequires: (crate(difference) >= 2.0.0 with crate(difference) < 3.0.0) BuildRequires: (crate(encoding_rs) >= 0.7.0 with crate(encoding_rs) < 0.8.0) BuildRequires: (crate(rustc-serialize) >= 0.3.0 with crate(rustc-serialize) < 0.4.0) %endif %description %{summary}. %package devel Summary: %{summary} BuildArch: noarch %description devel Rust implementation of CSS Syntax Level 3. This package contains library source intended for building other packages which use %{crate} from crates.io. %prep %autosetup -n %{crate}-%{version} -p1 %cargo_prep %build %cargo_build %install %cargo_install %if %{with check} %check # https://github.com/servo/rust-cssparser/issues/213 %cargo_test --doc %endif %files devel %{cargo_registry}/%{crate}-%{version}/ %changelog * Wed Jan 24 2018 Igor Gnatenko - 0.23.2-1 - Initial package