commit 606edf1a371fd4b56b8519f30b799c31a6267768 Author: tigro Date: Mon Jan 15 21:46:36 2024 +0300 import rust-linreg-0.2.0-4.el9 diff --git a/.rust-linreg.metadata b/.rust-linreg.metadata new file mode 100644 index 0000000..e69de29 diff --git a/SOURCES/linreg-0.2.0.crate b/SOURCES/linreg-0.2.0.crate new file mode 100644 index 0000000..4c034b2 Binary files /dev/null and b/SOURCES/linreg-0.2.0.crate differ diff --git a/SOURCES/linreg-update-displaydoc.patch b/SOURCES/linreg-update-displaydoc.patch new file mode 100644 index 0000000..fd3a8f5 --- /dev/null +++ b/SOURCES/linreg-update-displaydoc.patch @@ -0,0 +1,27 @@ +diff -Naur a/Cargo.toml b/Cargo.toml +--- a/Cargo.toml 1969-12-31 16:00:00.000000000 -0800 ++++ b/Cargo.toml 2021-08-05 08:38:54.484222554 -0700 +@@ -21,7 +21,7 @@ + license = "MIT" + repository = "https://github.com/49nord/linreg-rs.git" + [dependencies.displaydoc] +-version = "0.1.5" ++version = "0.2" + default-features = false + + [dependencies.num-traits] +diff -Naur a/src/lib.rs b/src/lib.rs +--- a/src/lib.rs 2019-12-08 08:38:28.000000000 -0800 ++++ b/src/lib.rs 2021-08-05 08:39:12.167403464 -0700 +@@ -53,9 +53,8 @@ + pub enum Error { + /// The slope is too steep to represent, approaching infinity. + TooSteep, +- /// Failed to calculate mean. +- /// +- /// This means the input was empty or had too many elements. ++ /** Failed to calculate mean. ++ This means the input was empty or had too many elements. */ + Mean, + /// Lengths of the inputs are different. + InputLenDif, diff --git a/SPECS/rust-linreg.spec b/SPECS/rust-linreg.spec new file mode 100644 index 0000000..d67f39c --- /dev/null +++ b/SPECS/rust-linreg.spec @@ -0,0 +1,100 @@ +## START: Set by rpmautospec +## (rpmautospec version 0.3.1) +## RPMAUTOSPEC: autorelease, autochangelog +%define autorelease(e:s:pb:n) %{?-p:0.}%{lua: + release_number = 4; + 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 18 +%bcond_without check +%global debug_package %{nil} + +%global crate linreg + +Name: rust-%{crate} +Version: 0.2.0 +Release: %autorelease +Summary: Calculates linear regresssions of two-dimensional data + +# Upstream license specification: MIT +License: MIT +URL: https://crates.io/crates/linreg +Source: %{crates_source} +# Backport of PR#8: Update displaydoc to 0.2 +Patch0: linreg-update-displaydoc.patch + +ExclusiveArch: %{rust_arches} +%if %{__cargo_skip_build} +BuildArch: noarch +%endif + +BuildRequires: rust-packaging + +%global _description %{expand: +Calculates linear regresssions of two-dimensional data. Does not use stdlib, +only depends on numeric traits.} + +%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 +%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 "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 + +%generate_buildrequires +%cargo_generate_buildrequires + +%build +%cargo_build + +%install +%cargo_install + +%if %{with check} +%check +%cargo_test +%endif + +%changelog +* Mon Jan 15 2024 Arkady L. Shane - 0.2.0-4 +- Rebuilt for MSVSphere 9.3 + +* Fri Jan 20 2023 Fedora Release Engineering - 0.2.0-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild + +* Sat Jul 23 2022 Fedora Release Engineering - 0.2.0-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild + +* Fri Jan 21 2022 Fedora Release Engineering - 0.2.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild + +* Mon Sep 06 2021 Davide Cavalca - 0.2.0-1 +- Initial import; Fixes: RHBZ#1990538