## START: Set by rpmautospec ## (rpmautospec version 0.6.0) ## RPMAUTOSPEC: autorelease, autochangelog %define autorelease(e:s:pb:n) %{?-p:0.}%{lua: release_number = 2; 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 25 %bcond_without check %global debug_package %{nil} %global crate libcst Name: rust-libcst Version: 1.1.0 Release: %autorelease Summary: Python parser and Concrete Syntax Tree library License: MIT AND PSF-2.0 URL: https://crates.io/crates/libcst Source: %{crates_source} # Manually created patch for downstream crate metadata changes # * specify license in crate metadata (only MIT and PSF-2.0 apply to this crate) # * drop unused, benchmark-only criterion dev-dependency # * prevent unused "parse" binary from being built and shipped # * drop unused support for building the crate as a Python extension module Patch: libcst-fix-metadata.diff BuildRequires: cargo-rpm-macros >= 24 %global _description %{expand: A Python parser and Concrete Syntax Tree library.} %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 %license %{crate_instdir}/src/tokenizer/core/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 %package -n %{name}+trace-devel Summary: %{summary} BuildArch: noarch %description -n %{name}+trace-devel %{_description} This package contains library source intended for building other packages which use the "trace" feature of the "%{crate}" crate. %files -n %{name}+trace-devel %ghost %{crate_instdir}/Cargo.toml %prep %autosetup -n %{crate}-%{version} -p1 %cargo_prep # drop a test that requires fixtures which are not included in published crates rm tests/parser_roundtrip.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 Jan 26 2024 Fedora Release Engineering - 1.1.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild * Mon Oct 23 2023 Fabio Valentini - 1.1.0-1 - Update to version 1.1.0; Fixes RHBZ#2242416 * Sun Sep 24 2023 Fabio Valentini - 0.1.0-1 - Initial import (#2239534) ## END: Generated by rpmautospec