## START: Set by rpmautospec ## (rpmautospec version 0.7.3) ## RPMAUTOSPEC: autorelease, autochangelog %define autorelease(e:s:pb:n) %{?-p:0.}%{lua: release_number = 1; base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}")); print(release_number + base_release_number - 1); }%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{!?-n:%{?dist}} ## END: Set by rpmautospec # Generated by rust2rpm 27 %bcond check 1 %global debug_package %{nil} %global crate protox-parse Name: rust-protox-parse Version: 0.8.0 Release: %autorelease Summary: Parsing of protobuf source files License: MIT OR Apache-2.0 URL: https://crates.io/crates/protox-parse Source: %{crates_source} BuildRequires: cargo-rpm-macros >= 24 BuildRequires: tomcli %global _description %{expand: Parsing of protobuf source files.} %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-APACHE %license %{crate_instdir}/LICENSE-MIT %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 # Relax logos dependency tomcli set Cargo.toml str dependencies.logos '>=0.14.0,<0.16' # Broken test because tests.rs is not in crate sed -i '/#\[cfg(test)\]/,/mod tests/d' src/lex/mod.rs sed -i '/#\[cfg(test)\]/,/mod tests/d' src/lib.rs sed -i '/#\[cfg(test)\]/,/mod tests/d' src/parse/mod.rs %generate_buildrequires %cargo_generate_buildrequires %build %cargo_build %install %cargo_install %if %{with check} %check %cargo_test %endif %changelog ## START: Generated by rpmautospec * Fri Apr 11 2025 John Doe - 0.8.0-1 - Uncommitted changes ## END: Generated by rpmautospec