From 88871480f243503e4efb4bdc96c8933acf74e509 Mon Sep 17 00:00:00 2001 From: Igor Gnatenko Date: Mon, 6 Nov 2017 13:19:48 +0100 Subject: [PATCH] initial import Signed-off-by: Igor Gnatenko --- .gitignore | 1 + rust-thread-id.spec | 73 +++++++++++++++++++++++++++++++ sources | 1 + thread-id-3.2.0-fix-metadata.diff | 10 +++++ 4 files changed, 85 insertions(+) create mode 100644 .gitignore create mode 100644 rust-thread-id.spec create mode 100644 sources create mode 100644 thread-id-3.2.0-fix-metadata.diff diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..a49f6ab --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +/thread-id-3.2.0.crate diff --git a/rust-thread-id.spec b/rust-thread-id.spec new file mode 100644 index 0000000..2385e90 --- /dev/null +++ b/rust-thread-id.spec @@ -0,0 +1,73 @@ +# Generated by rust2rpm +%bcond_without check +%global debug_package %{nil} + +%global crate thread-id + +Name: rust-%{crate} +Version: 3.2.0 +Release: 1%{?dist} +Summary: Get a unique thread ID + +License: MIT or ASL 2.0 +URL: https://crates.io/crates/thread-id +Source0: https://crates.io/api/v1/crates/%{crate}/%{version}/download#/%{crate}-%{version}.crate +# Initial patched metadata +# * No windows +# * No redox +Patch0: thread-id-3.2.0-fix-metadata.diff + +ExclusiveArch: %{rust_arches} + +BuildRequires: rust-packaging +# [dependencies] +BuildRequires: (crate(libc) >= 0.2.6 with crate(libc) < 0.3.0) + +%description +%{summary}. + +%package devel +Summary: %{summary} +BuildArch: noarch + +%description devel +Get a unique thread ID. + +This package contains library source intended for building other packages +which use %{crate} from crates.io. + +%prep +%autosetup -n %{crate}-%{version} -p1 +%cargo_prep + +%build +%cargo_build + +%install +%cargo_install + +%if %{with check} +%check +%cargo_test +%endif + +%files devel +%license license-mit license-apache +%doc readme.md +%{cargo_registry}/%{crate}-%{version}/ + +%changelog +* Sat Jul 01 2017 Igor Gnatenko - 3.2.0-1 +- Update to 3.2.0 + +* Wed Jun 14 2017 Igor Gnatenko - 3.1.0-1 +- Update to 3.1.0 + +* Wed Jun 14 2017 Igor Gnatenko - 3.0.0-3 +- Port to use rust-packaging + +* Fri Feb 24 2017 Igor Gnatenko - 3.0.0-2 +- Use rich dependencies + +* Sat Feb 18 2017 Igor Gnatenko - 3.0.0-1 +- Initial package diff --git a/sources b/sources new file mode 100644 index 0000000..87db4a9 --- /dev/null +++ b/sources @@ -0,0 +1 @@ +SHA512 (thread-id-3.2.0.crate) = 251ebc0fb83a270b8fab9669ebbb7bc2cc44b1858fd298cb5f9ada0fc63ec6b46b44daf7d91c03f5ba646c14a2d6067c90988b59808e96f71e550b4cda290aa0 diff --git a/thread-id-3.2.0-fix-metadata.diff b/thread-id-3.2.0-fix-metadata.diff new file mode 100644 index 0000000..1b7e55c --- /dev/null +++ b/thread-id-3.2.0-fix-metadata.diff @@ -0,0 +1,10 @@ +--- thread-id-3.2.0/Cargo.toml 1970-01-01T01:00:00+01:00 ++++ thread-id-3.2.0/Cargo.toml 2017-07-01T19:42:32.549811+02:00 +@@ -22,7 +22,3 @@ + repository = "https://github.com/ruuda/thread-id" + [target."cfg(unix)".dependencies.libc] + version = "0.2.6" +-[target."cfg(target_os = \"redox\")".dependencies.redox_syscall] +-version = "0.1" +-[target."cfg(windows)".dependencies.kernel32-sys] +-version = "0.2.1"