# Generated by rust2rpm 20 %bcond_without check %global debug_package %{nil} %global crate num_enum Name: rust-%{crate} Version: 0.5.5 Release: %autorelease Summary: Procedural macros to make inter-operation between primitives and enums easier # Upstream license specification: BSD-3-Clause OR MIT OR Apache-2.0 License: BSD or MIT or ASL 2.0 URL: https://crates.io/crates/num_enum Source: %{crates_source} ExclusiveArch: %{rust_arches} BuildRequires: rust-packaging %global _description %{expand: Procedural macros to make inter-operation between primitives and enums easier.} %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 LICENSE-APACHE LICENSE-BSD LICENSE-MIT %doc README.md %{cargo_registry}/%{crate}-%{version_no_tilde}/ %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 %{cargo_registry}/%{crate}-%{version_no_tilde}/Cargo.toml %package -n %{name}+complex-expressions-devel Summary: %{summary} BuildArch: noarch %description -n %{name}+complex-expressions-devel %{_description} This package contains library source intended for building other packages which use the "complex-expressions" feature of the "%{crate}" crate. %files -n %{name}+complex-expressions-devel %ghost %{cargo_registry}/%{crate}-%{version_no_tilde}/Cargo.toml %package -n %{name}+external_doc-devel Summary: %{summary} BuildArch: noarch %description -n %{name}+external_doc-devel %{_description} This package contains library source intended for building other packages which use the "external_doc" feature of the "%{crate}" crate. %files -n %{name}+external_doc-devel %ghost %{cargo_registry}/%{crate}-%{version_no_tilde}/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 %{cargo_registry}/%{crate}-%{version_no_tilde}/Cargo.toml %prep %autosetup -n %{crate}-%{version_no_tilde} -p1 # remove tests that rely on files that are not shipped with crates rm tests/renamed_num_enum.rs # remove broken trybuild tests that rely on exact error messages rm tests/try_build.rs rm -r tests/try_build/* %cargo_prep %generate_buildrequires %cargo_generate_buildrequires %build %cargo_build %install %cargo_install %if %{with check} %check %cargo_test %endif %changelog %autochangelog