diff --git a/num_threads-fix-metadata.diff b/num_threads-fix-metadata-auto.diff similarity index 62% rename from num_threads-fix-metadata.diff rename to num_threads-fix-metadata-auto.diff index e5380a7..314e023 100644 --- a/num_threads-fix-metadata.diff +++ b/num_threads-fix-metadata-auto.diff @@ -1,9 +1,8 @@ --- num_threads-0.1.6/Cargo.toml 1970-01-01T00:00:01+00:00 -+++ num_threads-0.1.6/Cargo.toml 2022-05-13T19:38:33.207825+00:00 -@@ -31,6 +31,3 @@ - targets = ["x86_64-unknown-linux-gnu"] ++++ num_threads-0.1.6/Cargo.toml 1970-01-01T00:00:01+00:00 +@@ -32,5 +32,3 @@ [dependencies] -- + -[target."cfg(any(target_os = \"macos\", target_os = \"ios\", target_os = \"freebsd\"))".dependencies.libc] -version = "0.2.107" diff --git a/rust-num_threads.spec b/rust-num_threads.spec index 80d8832..8c56b27 100644 --- a/rust-num_threads.spec +++ b/rust-num_threads.spec @@ -1,23 +1,21 @@ -# Generated by rust2rpm 21 -%bcond_without check +# Generated by rust2rpm 23 +# * tests are broken due to test runner changes in Rust 1.67+: +# https://github.com/jhpratt/num_threads/issues/13 +%bcond_with check %global debug_package %{nil} %global crate num_threads -Name: rust-%{crate} +Name: rust-num_threads Version: 0.1.6 Release: %autorelease Summary: Determine the number of running threads for the current process -# Upstream license specification: MIT OR Apache-2.0 -License: MIT or ASL 2.0 +License: MIT OR Apache-2.0 URL: https://crates.io/crates/num_threads Source: %{crates_source} -# Initial patched metadata -# * drop non-linux dependencies -Patch0: num_threads-fix-metadata.diff - -ExclusiveArch: %{rust_arches} +# Automatically generated patch to strip foreign dependencies +Patch: num_threads-fix-metadata-auto.diff BuildRequires: rust-packaging >= 21 @@ -68,8 +66,7 @@ use the "default" feature of the "%{crate}" crate. %if %{with check} %check -# * tests expect to be run from a single thread -%cargo_test -- -- --test-threads 1 +%cargo_test %endif %changelog