# Generated by rust2rpm 28 %bcond check 1 %global debug_package %{nil} %global crate tonic-types Name: rust-tonic-types Version: 0.14.5 Release: %autorelease Summary: Collection of useful protobuf types that can be used with tonic License: MIT URL: https://crates.io/crates/tonic-types Source: %{crates_source} # * Move codegen to inside the crate # * See https://github.com/hyperium/tonic/blob/master/codegen/src/main.rs Source10: build.rs # Manually created patch for downstream crate metadata changes # * Add dependencies to run build.rs Patch: tonic-types-fix-metadata.diff BuildRequires: cargo-rpm-macros >= 24 BuildRequires: protobuf-devel %global _description %{expand: A collection of useful protobuf types that can be used with `tonic`.} %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 %{crate_instdir}/LICENSE %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 %prep %autosetup -n %{crate}-%{version} -p1 %cargo_prep # Remove pre-generated files rm -rf src/generated cp -p '%{SOURCE10}' . %generate_buildrequires %cargo_generate_buildrequires %build %cargo_build %install %cargo_install %if %{with check} %check # * generated::google_rpc: Interpreted as a doc test, but it is not. %cargo_test -- -- --skip generated::google_rpc:: %endif %changelog %autochangelog