parent
e8a14d7dde
commit
1afe79876f
@ -0,0 +1,5 @@
|
|||||||
|
/time-0.1.38.crate
|
||||||
|
/time-0.1.39.crate
|
||||||
|
/time-0.1.40.crate
|
||||||
|
/time-0.1.41.crate
|
||||||
|
/time-0.1.42.crate
|
@ -1,3 +1,3 @@
|
|||||||
# rust-time0.1
|
# rust-time
|
||||||
|
|
||||||
The rust-time0.1 package
|
The rust-time package
|
@ -0,0 +1,95 @@
|
|||||||
|
# Generated by rust2rpm 13
|
||||||
|
%bcond_without check
|
||||||
|
%global debug_package %{nil}
|
||||||
|
|
||||||
|
%global crate time
|
||||||
|
|
||||||
|
Name: rust-%{crate}0.1
|
||||||
|
Version: 0.1.42
|
||||||
|
Release: 1%{?dist}
|
||||||
|
Summary: Utilities for working with time-related functions in Rust
|
||||||
|
|
||||||
|
# Upstream license specification: MIT/Apache-2.0
|
||||||
|
License: MIT or ASL 2.0
|
||||||
|
URL: https://crates.io/crates/time
|
||||||
|
Source: %{crates_source}
|
||||||
|
# Initial patched metadata
|
||||||
|
# * No windows/redox
|
||||||
|
# * Exclude CI files, https://github.com/rust-lang-deprecated/time/pull/170
|
||||||
|
Patch0: time-fix-metadata.diff
|
||||||
|
|
||||||
|
# * Don't deny warnings
|
||||||
|
# * Adjust the recent/future test dates
|
||||||
|
Patch1: time-0.1-fix-tests.patch
|
||||||
|
|
||||||
|
ExclusiveArch: %{rust_arches}
|
||||||
|
%if %{__cargo_skip_build}
|
||||||
|
BuildArch: noarch
|
||||||
|
%endif
|
||||||
|
|
||||||
|
BuildRequires: rust-packaging
|
||||||
|
|
||||||
|
%global _description %{expand:
|
||||||
|
Utilities for working with time-related functions in Rust.}
|
||||||
|
|
||||||
|
%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-MIT LICENSE-APACHE
|
||||||
|
%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
|
||||||
|
|
||||||
|
%package -n %{name}+rustc-serialize-devel
|
||||||
|
Summary: %{summary}
|
||||||
|
BuildArch: noarch
|
||||||
|
|
||||||
|
%description -n %{name}+rustc-serialize-devel %{_description}
|
||||||
|
|
||||||
|
This package contains library source intended for building other packages
|
||||||
|
which use "rustc-serialize" feature of "%{crate}" crate.
|
||||||
|
|
||||||
|
%files -n %{name}+rustc-serialize-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 27 2020 Josh Stone <jistone@redhat.com> - 0.1.42-1
|
||||||
|
- Initial package
|
@ -0,0 +1 @@
|
|||||||
|
SHA512 (time-0.1.42.crate) = 4df662212377093b0fd8fcd88ddc30b20a8af7d989c2e100c0cf64f9741e88eea6e858e1aa4220be6b76b0cf8b62c8116b492010d74d1ebef197c66aa130aa83
|
@ -0,0 +1,23 @@
|
|||||||
|
diff --git a/src/lib.rs b/src/lib.rs
|
||||||
|
index ef44f3a1255e..be0ce334aef3 100644
|
||||||
|
--- a/src/lib.rs
|
||||||
|
+++ b/src/lib.rs
|
||||||
|
@@ -34,7 +34,6 @@
|
||||||
|
html_favicon_url = "https://www.rust-lang.org/favicon.ico",
|
||||||
|
html_root_url = "https://doc.rust-lang.org/time/")]
|
||||||
|
#![allow(trivial_numeric_casts)]
|
||||||
|
-#![cfg_attr(test, deny(warnings))]
|
||||||
|
|
||||||
|
#[cfg(target_os = "redox")] extern crate syscall;
|
||||||
|
#[cfg(unix)] extern crate libc;
|
||||||
|
@@ -694,8 +693,8 @@ mod tests {
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn test_get_time() {
|
||||||
|
- static SOME_RECENT_DATE: i64 = 1325376000i64; // 2012-01-01T00:00:00Z
|
||||||
|
- static SOME_FUTURE_DATE: i64 = 1577836800i64; // 2020-01-01T00:00:00Z
|
||||||
|
+ static SOME_RECENT_DATE: i64 = 1577836800i64; // 2020-01-01T00:00:00Z
|
||||||
|
+ static SOME_FUTURE_DATE: i64 = 1893456000i64; // 2030-01-01T00:00:00Z
|
||||||
|
|
||||||
|
let tv1 = get_time();
|
||||||
|
debug!("tv1={} sec + {} nsec", tv1.sec, tv1.nsec);
|
@ -0,0 +1,25 @@
|
|||||||
|
--- time-0.1.42/Cargo.toml 1970-01-01T00:00:00+00:00
|
||||||
|
+++ time-0.1.42/Cargo.toml 2019-06-21T20:09:19.610502+00:00
|
||||||
|
@@ -19,6 +19,7 @@
|
||||||
|
documentation = "https://doc.rust-lang.org/time"
|
||||||
|
license = "MIT/Apache-2.0"
|
||||||
|
repository = "https://github.com/rust-lang/time"
|
||||||
|
+exclude = ["/.travis.yml", "/appveyor.yml"]
|
||||||
|
[dependencies.libc]
|
||||||
|
version = "0.2.1"
|
||||||
|
|
||||||
|
@@ -28,14 +29,6 @@
|
||||||
|
[dev-dependencies.log]
|
||||||
|
version = "0.4"
|
||||||
|
|
||||||
|
-[dev-dependencies.winapi]
|
||||||
|
-version = "0.3.0"
|
||||||
|
-features = ["std", "processthreadsapi", "winbase"]
|
||||||
|
-[target."cfg(target_os = \"redox\")".dependencies.redox_syscall]
|
||||||
|
-version = "0.1"
|
||||||
|
-[target."cfg(windows)".dependencies.winapi]
|
||||||
|
-version = "0.3.0"
|
||||||
|
-features = ["std", "minwinbase", "minwindef", "ntdef", "profileapi", "sysinfoapi", "timezoneapi"]
|
||||||
|
[badges.appveyor]
|
||||||
|
repository = "alexcrichton/time"
|
||||||
|
|
Loading…
Reference in new issue