# Generated by rust2rpm 18 %bcond_without check %global debug_package %{nil} %global crate exitfailure %global forgeurl https://github.com/tismith/exitfailure Name: rust-%{crate} Version: 0.5.1 Release: %autorelease Summary: Basic newtype wrappers for use with ? in main # Upstream license specification: MIT OR Apache-2.0 License: MIT or ASL 2.0 URL: https://crates.io/crates/exitfailure Source: %{crates_source} # Initial patched metadata # Bump assert_cmd and predicates to 1.0 # https://github.com/tismith/exitfailure/pull/38 # https://github.com/tismith/exitfailure/pull/41 Patch0: exitfailure-fix-metadata.diff ExclusiveArch: %{rust_arches} %if %{__cargo_skip_build} BuildArch: noarch %endif BuildRequires: rust-packaging BuildRequires: sed %global _description %{expand: Basic newtype wrappers for use with ? in main.} %description %{_description} %package devel Summary: %{summary} BuildArch: noarch %description devel %{_description} This package contains library source intended for building other packages which use "%{crate}" crate. %files devel %license LICENSE-MIT LICENSE-APACHE %doc README.md CONTRIBUTING.md CHANGELOG.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 "default" feature of "%{crate}" crate. %files -n %{name}+default-devel %ghost %{cargo_registry}/%{crate}-%{version_no_tilde}/Cargo.toml %prep %autosetup -n %{crate}-%{version_no_tilde} -p1 %cargo_prep # This test hardcodes target/debug to shell out to the examples, which won't # work as we run the tests in release mode sed -i 's:target/debug/:target/release/:g' tests/test.rs %generate_buildrequires %cargo_generate_buildrequires %build %cargo_build %install %cargo_install %if %{with check} %check # https://github.com/tismith/exitfailure/issues/42 %cargo_test -- -- --skip test_backtrace %endif %changelog %autochangelog