[packages/cargo] - fix build with more recent environment (there is much newer release available but -ENOTIME to up
hawk
hawk at pld-linux.org
Sat Sep 21 22:53:44 CEST 2019
commit 564fa063a4fe0e78d410ce55d7c6041e8a39e569
Author: Marcin Krol <hawk at tld-linux.org>
Date: Sat Sep 21 22:45:49 2019 +0200
- fix build with more recent environment (there is much newer release
available but -ENOTIME to update)
build_fix.patch | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
cargo.spec | 5 ++++-
2 files changed, 58 insertions(+), 1 deletion(-)
---
diff --git a/cargo.spec b/cargo.spec
index 26f72f0..40366cd 100644
--- a/cargo.spec
+++ b/cargo.spec
@@ -10,7 +10,7 @@ Summary: Rust's package manager and build tool
Summary(pl.UTF-8): Zarządca pakietów i narzędzie do budowania
Name: cargo
Version: 0.26.0
-Release: 1
+Release: 2
License: Apache v2.0 or MIT
Group: Development/Tools
Source0: https://github.com/rust-lang/cargo/archive/%{cargo_version}/%{name}-%{cargo_version}.tar.gz
@@ -28,6 +28,7 @@ Source3: https://static.rust-lang.org/dist/%{name}-%{cargo_bootstrap}-i686-unkno
Source4: https://src.fedoraproject.org/repo/pkgs/cargo/%{name}-%{version}-vendor.tar.xz/sha512/6ed2a1644c9b18fc24ddad5350d41b6c36cd5b62de4cf0b748a57b589f4f0ac12f91461989158d58d0892bf6fc2c1626cf574e7e2b9da4b0e35f72dfd88f9048/%{name}-%{version}-vendor.tar.xz
# Source4-md5: bf5dd065f46ece6a0d30dbd3216508a0
Patch0: x32.patch
+Patch1: build_fix.patch
URL: https://crates.io/
%{!?with_bootstrap:BuildRequires: %{name} >= 0.13.0}
BuildRequires: cmake
@@ -101,6 +102,8 @@ Dopełnianie parametrów polecenia cargo w powłoce Zsh.
%patch0 -p1
%endif
+%patch1 -p1
+
%if %{with bootstrap}
%ifarch %{x8664}
tar xf %{SOURCE2}
diff --git a/build_fix.patch b/build_fix.patch
new file mode 100644
index 0000000..45d0af2
--- /dev/null
+++ b/build_fix.patch
@@ -0,0 +1,54 @@
+diff -ur cargo-0.26.0.orig/src/cargo/core/features.rs cargo-0.26.0/src/cargo/core/features.rs
+--- cargo-0.26.0.orig/src/cargo/core/features.rs 2018-02-26 22:17:55.000000000 +0100
++++ cargo-0.26.0/src/cargo/core/features.rs 2019-09-21 22:39:56.881000000 +0200
+@@ -132,17 +132,17 @@
+ (unstable) => (Status::Unstable);
+ }
+
+-/// A listing of all features in Cargo
+-///
+-/// "look here"
+-///
+-/// This is the macro that lists all stable and unstable features in Cargo.
+-/// You'll want to add to this macro whenever you add a feature to Cargo, also
+-/// following the directions above.
+-///
+-/// Note that all feature names here are valid Rust identifiers, but the `_`
+-/// character is translated to `-` when specified in the `cargo-features`
+-/// manifest entry in `Cargo.toml`.
++// A listing of all features in Cargo
++//
++// "look here"
++//
++// This is the macro that lists all stable and unstable features in Cargo.
++// You'll want to add to this macro whenever you add a feature to Cargo, also
++// following the directions above.
++//
++// Note that all feature names here are valid Rust identifiers, but the `_`
++// character is translated to `-` when specified in the `cargo-features`
++// manifest entry in `Cargo.toml`.
+ features! {
+ pub struct Features {
+
+diff -ur cargo-0.26.0.orig/src/cargo/util/errors.rs cargo-0.26.0/src/cargo/util/errors.rs
+--- cargo-0.26.0.orig/src/cargo/util/errors.rs 2018-02-26 22:17:55.000000000 +0100
++++ cargo-0.26.0/src/cargo/util/errors.rs 2019-09-21 22:18:35.758000000 +0200
+@@ -199,7 +199,6 @@
+ #[cfg(unix)]
+ fn status_to_string(status: &ExitStatus) -> String {
+ use std::os::unix::process::*;
+- use libc;
+
+ if let Some(signal) = status.signal() {
+ let name = match signal as libc::c_int {
+diff -ur cargo-0.26.0.orig/src/cargo/util/paths.rs cargo-0.26.0/src/cargo/util/paths.rs
+--- cargo-0.26.0.orig/src/cargo/util/paths.rs 2018-02-26 22:17:55.000000000 +0100
++++ cargo-0.26.0/src/cargo/util/paths.rs 2019-09-21 22:23:14.922000000 +0200
+@@ -138,7 +138,6 @@
+ #[cfg(unix)]
+ pub fn bytes2path(bytes: &[u8]) -> CargoResult<PathBuf> {
+ use std::os::unix::prelude::*;
+- use std::ffi::OsStr;
+ Ok(PathBuf::from(OsStr::from_bytes(bytes)))
+ }
+ #[cfg(windows)]
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/cargo.git/commitdiff/564fa063a4fe0e78d410ce55d7c6041e8a39e569
More information about the pld-cvs-commit
mailing list