bump patches & versions
This commit is contained in:
@@ -22,6 +22,11 @@ B = "${S}"
|
||||
# where the issue occured
|
||||
export RUST_BACKTRACE = "1"
|
||||
|
||||
# The pkg-config-rs library used by cargo build scripts disables itself when
|
||||
# cross compiling unless this is defined. We set up pkg-config appropriately
|
||||
# for cross compilation, so tell it we know better than it.
|
||||
export PKG_CONFIG_ALLOW_CROSS = "1"
|
||||
|
||||
EXTRA_OECARGO_PATHS ??= ""
|
||||
|
||||
cargo_do_configure () {
|
||||
|
||||
+30
-15
@@ -1,13 +1,10 @@
|
||||
# 2015-2-12
|
||||
SRCREV_cargo = "0b84923203dce67ff8cf051728b6908c9c2e303c"
|
||||
# 2015-2-19
|
||||
SRCREV_cargo = "43755c00e8a93a3478a1179bca98a7f8b56ecbca"
|
||||
|
||||
require cargo.inc
|
||||
|
||||
SRC_URI += " \
|
||||
file:///0001-update-Rust.patch \
|
||||
\
|
||||
git://github.com/carllerche/curl-rust.git;protocol=https;destsuffix=curl-rust;name=curl-rust \
|
||||
git://github.com/alexcrichton/curl.git;protocol=https;destsuffix=curl-rust/curl-sys/curl;name=curl;branch=configure \
|
||||
file://curl-rust/0001-curl-sys-avoid-explicitly-linking-in-openssl.-If-it-.patch;patchdir=../curl-rust \
|
||||
file://curl-rust/0002-openssl-sys-is-used-in-curl-rust-so-include-it-expli.patch;patchdir=../curl-rust \
|
||||
file://curl-rust/0003-remove-per-triple-deps-on-openssl-sys.patch;patchdir=../curl-rust \
|
||||
@@ -18,23 +15,41 @@ SRC_URI += " \
|
||||
\
|
||||
git://github.com/alexcrichton/git2-rs.git;protocol=https;name=git2-rs;destsuffix=git2-rs \
|
||||
file://git2-rs/0001-Add-generic-openssl-sys-dep.patch;patchdir=../git2-rs \
|
||||
\
|
||||
\
|
||||
git://github.com/sfackler/rust-openssl.git;protocol=https;name=rust-openssl;destsuffix=rust-openssl \
|
||||
\
|
||||
\
|
||||
git://github.com/alexcrichton/curl.git;protocol=https;destsuffix=curl-rust/curl-sys/curl;name=curl;branch=configure \
|
||||
git://github.com/alexcrichton/libgit2.git;protocol=https;destsuffix=git2-rs/libgit2-sys/libgit2;name=libgit2;branch=libgit2-2014-12-19 \
|
||||
"
|
||||
|
||||
SRCREV_git2-rs = "d0d21ca14b4a410806b577b04c2d29f7f8e45f61"
|
||||
# 0.1.17
|
||||
SRCREV_curl-rust = "b7089a71fba5757e36f8cb1b3767183d4b79c20f"
|
||||
|
||||
# 0.1.14
|
||||
SRCREV_curl-rust = "9181ea8f4ea2c7eb60224b5ebf464751165e2881"
|
||||
# 0.1.11 / -sys 0.1.8
|
||||
SRCREV_ssh2-rs = "c4c46c2d68dd207371c0565e2de2439bac583edc"
|
||||
|
||||
# FIXME: we don't actually use this, and shouldn't need to fetch it, but not having it results in:
|
||||
## target/snapshot/bin/cargo build --target x86_64-linux --verbose
|
||||
## Failed to resolve path '/home/cody/obj/y/tmp/work/x86_64-linux/cargo-native/git+gitAUTOINC+0b84923203_9181ea8f4e_8baa8ccb39-r0/curl-rust/curl-sys/curl/.git': No such file or directory
|
||||
SRCREV_curl = "ac30e9a7746c8641f4871e59b831ec28530c5c73"
|
||||
# 0.1.20
|
||||
SRCREV_git2-rs = "4f2757055ecb3c52346d7163e321eb9d510f94ba"
|
||||
|
||||
# libssh2-sys 0.1.5 +2015-2-10
|
||||
SRCREV_ssh2-rs = "8baa8ccb39cd1a43362d2a1ee87d8c3b91496cd7"
|
||||
SRCREV_FORMAT = "cargo_curl-rust_curl_ssh2-rs_git2-rs"
|
||||
## This is only included to avoid cargo spuriously complaining about us having
|
||||
## 2 versions of openssl-sys linked in
|
||||
# 0.4.3 +2015-02-22
|
||||
SRCREV_rust-openssl = "ebd906293376ee8ed3b7ddafa4573d2a9222d8b7"
|
||||
SRCREV_rustc-serialize = "213ef7b16e21a8b1a84e4d7c120e317ec0a66824"
|
||||
|
||||
|
||||
SRCREV_FORMAT = "cargo_curl-rust_curl_ssh2-rs_git2-rs_rust-openssl"
|
||||
EXTRA_OECARGO_PATHS = "\
|
||||
${WORKDIR}/curl-rust \
|
||||
${WORKDIR}/ssh2-rs \
|
||||
${WORKDIR}/git2-rs \
|
||||
${WORKDIR}/rust-openssl \
|
||||
"
|
||||
|
||||
# FIXME: we don't actually use these, and shouldn't need to fetch it, but not having it results in:
|
||||
## target/snapshot/bin/cargo build --target x86_64-linux --verbose
|
||||
## Failed to resolve path '/home/cody/obj/y/tmp/work/x86_64-linux/cargo-native/git+gitAUTOINC+0b84923203_9181ea8f4e_8baa8ccb39-r0/curl-rust/curl-sys/curl/.git': No such file or directory
|
||||
SRCREV_curl = "ac30e9a7746c8641f4871e59b831ec28530c5c73"
|
||||
SRCREV_libgit2 = "3b48f7f30c271ec9569f722215ee55cc5e922242"
|
||||
|
||||
@@ -0,0 +1,906 @@
|
||||
From d122d57536df9fbfcdfda08b2918dc6e0c6209c0 Mon Sep 17 00:00:00 2001
|
||||
From: Andrew Paseltiner <apaseltiner@gmail.com>
|
||||
Date: Thu, 12 Feb 2015 23:10:07 -0500
|
||||
Subject: [PATCH] update Rust
|
||||
|
||||
---
|
||||
Cargo.lock | 32 ++++++++++++------------
|
||||
src/bin/build.rs | 4 +--
|
||||
src/bin/cargo.rs | 2 +-
|
||||
src/bin/clean.rs | 4 +--
|
||||
src/bin/generate_lockfile.rs | 4 +--
|
||||
src/bin/new.rs | 4 +--
|
||||
src/bin/update.rs | 4 +--
|
||||
src/bin/verify_project.rs | 4 +--
|
||||
src/bin/version.rs | 4 +--
|
||||
src/cargo/lib.rs | 2 +-
|
||||
src/cargo/ops/cargo_new.rs | 4 +--
|
||||
src/cargo/ops/cargo_rustc/engine.rs | 2 +-
|
||||
src/cargo/ops/registry.rs | 4 +--
|
||||
src/cargo/sources/git/utils.rs | 3 ++-
|
||||
src/cargo/util/config.rs | 2 +-
|
||||
src/cargo/util/hex.rs | 5 ++--
|
||||
src/cargo/util/profile.rs | 2 +-
|
||||
src/rustversion.txt | 2 +-
|
||||
tests/support/mod.rs | 2 +-
|
||||
tests/test_cargo.rs | 2 +-
|
||||
tests/test_cargo_compile.rs | 10 ++++----
|
||||
tests/test_cargo_compile_custom_build.rs | 42 ++++++++++++++++----------------
|
||||
tests/test_cargo_compile_git_deps.rs | 24 +++++++++---------
|
||||
tests/test_cargo_compile_plugins.rs | 6 ++---
|
||||
tests/test_cargo_cross_compile.rs | 28 ++++++++++-----------
|
||||
tests/test_cargo_profiles.rs | 6 ++---
|
||||
26 files changed, 103 insertions(+), 105 deletions(-)
|
||||
|
||||
diff --git a/Cargo.lock b/Cargo.lock
|
||||
index 14dd876..629585c 100644
|
||||
--- a/Cargo.lock
|
||||
+++ b/Cargo.lock
|
||||
@@ -4,7 +4,7 @@ version = "0.1.0"
|
||||
dependencies = [
|
||||
"advapi32-sys 0.0.4 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"curl 0.1.14 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "docopt 0.6.36 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "docopt 0.6.37 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"env_logger 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"flate2 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"git2 0.1.17 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
@@ -18,8 +18,8 @@ dependencies = [
|
||||
"semver 0.1.14 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"tar 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"term 0.1.11 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "time 0.1.16 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "toml 0.1.16 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "time 0.1.17 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "toml 0.1.17 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"url 0.2.20 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"winapi 0.1.11 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
@@ -44,7 +44,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"curl-sys 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"libc 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "openssl-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "openssl-sys 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"url 0.2.20 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
|
||||
@@ -55,13 +55,13 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"libc 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"libz-sys 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "openssl-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "openssl-sys 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"pkg-config 0.1.7 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "docopt"
|
||||
-version = "0.6.36"
|
||||
+version = "0.6.37"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"regex 0.1.14 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
@@ -97,7 +97,7 @@ version = "0.1.17"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"bitflags 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "libgit2-sys 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "libgit2-sys 0.1.13 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"url 0.2.20 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
|
||||
@@ -136,13 +136,13 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
|
||||
[[package]]
|
||||
name = "libgit2-sys"
|
||||
-version = "0.1.12"
|
||||
+version = "0.1.13"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"libssh2-sys 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"libz-sys 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "openssl-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "pkg-config 0.1.7 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "openssl-sys 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "pkg-config 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
@@ -159,7 +159,7 @@ version = "0.1.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"libz-sys 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "openssl-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "openssl-sys 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"pkg-config 0.1.7 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
|
||||
@@ -192,12 +192,12 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "openssl-sys"
|
||||
-version = "0.3.3"
|
||||
+version = "0.3.6"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"gcc 0.1.7 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"libressl-pnacl-sys 2.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "pkg-config 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "pkg-config 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
@@ -207,7 +207,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
|
||||
[[package]]
|
||||
name = "pkg-config"
|
||||
-version = "0.2.0"
|
||||
+version = "0.2.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
|
||||
[[package]]
|
||||
@@ -255,7 +255,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "time"
|
||||
-version = "0.1.16"
|
||||
+version = "0.1.17"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"gcc 0.1.7 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
@@ -264,7 +264,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "toml"
|
||||
-version = "0.1.16"
|
||||
+version = "0.1.17"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"rustc-serialize 0.2.12 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
diff --git a/src/bin/build.rs b/src/bin/build.rs
|
||||
index a617f64..0784c04 100644
|
||||
--- a/src/bin/build.rs
|
||||
+++ b/src/bin/build.rs
|
||||
@@ -1,4 +1,4 @@
|
||||
-use std::os;
|
||||
+use std::env;
|
||||
|
||||
use cargo::ops::CompileOptions;
|
||||
use cargo::ops;
|
||||
@@ -47,7 +47,7 @@ the --release flag will use the `release` profile instead.
|
||||
";
|
||||
|
||||
pub fn execute(options: Options, config: &Config) -> CliResult<Option<()>> {
|
||||
- debug!("executing; cmd=cargo-build; args={:?}", os::args());
|
||||
+ debug!("executing; cmd=cargo-build; args={:?}", env::args().collect::<Vec<_>>());
|
||||
config.shell().set_verbose(options.flag_verbose);
|
||||
|
||||
let root = try!(find_root_manifest_for_cwd(options.flag_manifest_path));
|
||||
diff --git a/src/bin/cargo.rs b/src/bin/cargo.rs
|
||||
index 7bf0a11..53c904d 100644
|
||||
--- a/src/bin/cargo.rs
|
||||
+++ b/src/bin/cargo.rs
|
||||
@@ -245,7 +245,7 @@ fn list_command_directory() -> Vec<Path> {
|
||||
dirs.push(path.join("../lib/cargo"));
|
||||
dirs.push(path);
|
||||
}
|
||||
- if let Some(val) = env::var("PATH") {
|
||||
+ if let Some(val) = env::var_os("PATH") {
|
||||
dirs.extend(env::split_paths(&val));
|
||||
}
|
||||
dirs
|
||||
diff --git a/src/bin/clean.rs b/src/bin/clean.rs
|
||||
index dcc013e..a530b9b 100644
|
||||
--- a/src/bin/clean.rs
|
||||
+++ b/src/bin/clean.rs
|
||||
@@ -1,4 +1,4 @@
|
||||
-use std::os;
|
||||
+use std::env;
|
||||
|
||||
use cargo::ops;
|
||||
use cargo::util::{CliResult, CliError, Config};
|
||||
@@ -33,7 +33,7 @@ and its format, see the `cargo help pkgid` command.
|
||||
|
||||
pub fn execute(options: Options, config: &Config) -> CliResult<Option<()>> {
|
||||
config.shell().set_verbose(options.flag_verbose);
|
||||
- debug!("executing; cmd=cargo-clean; args={:?}", os::args());
|
||||
+ debug!("executing; cmd=cargo-clean; args={:?}", env::args().collect::<Vec<_>>());
|
||||
|
||||
let root = try!(find_root_manifest_for_cwd(options.flag_manifest_path));
|
||||
let opts = ops::CleanOptions {
|
||||
diff --git a/src/bin/generate_lockfile.rs b/src/bin/generate_lockfile.rs
|
||||
index a350ab6..d9777ef 100644
|
||||
--- a/src/bin/generate_lockfile.rs
|
||||
+++ b/src/bin/generate_lockfile.rs
|
||||
@@ -1,4 +1,4 @@
|
||||
-use std::os;
|
||||
+use std::env;
|
||||
|
||||
use cargo::ops;
|
||||
use cargo::util::{CliResult, CliError, Config};
|
||||
@@ -23,7 +23,7 @@ Options:
|
||||
";
|
||||
|
||||
pub fn execute(options: Options, config: &Config) -> CliResult<Option<()>> {
|
||||
- debug!("executing; cmd=cargo-generate-lockfile; args={:?}", os::args());
|
||||
+ debug!("executing; cmd=cargo-generate-lockfile; args={:?}", env::args().collect::<Vec<_>>());
|
||||
config.shell().set_verbose(options.flag_verbose);
|
||||
let root = try!(find_root_manifest_for_cwd(options.flag_manifest_path));
|
||||
|
||||
diff --git a/src/bin/new.rs b/src/bin/new.rs
|
||||
index 4126e38..0abff6a 100644
|
||||
--- a/src/bin/new.rs
|
||||
+++ b/src/bin/new.rs
|
||||
@@ -1,4 +1,4 @@
|
||||
-use std::os;
|
||||
+use std::env;
|
||||
|
||||
use cargo::ops;
|
||||
use cargo::util::{CliResult, CliError, Config};
|
||||
@@ -28,7 +28,7 @@ Options:
|
||||
";
|
||||
|
||||
pub fn execute(options: Options, config: &Config) -> CliResult<Option<()>> {
|
||||
- debug!("executing; cmd=cargo-new; args={:?}", os::args());
|
||||
+ debug!("executing; cmd=cargo-new; args={:?}", env::args().collect::<Vec<_>>());
|
||||
config.shell().set_verbose(options.flag_verbose);
|
||||
|
||||
let Options { flag_bin, arg_path, flag_vcs, .. } = options;
|
||||
diff --git a/src/bin/update.rs b/src/bin/update.rs
|
||||
index fa75506..4fdeebf 100644
|
||||
--- a/src/bin/update.rs
|
||||
+++ b/src/bin/update.rs
|
||||
@@ -1,4 +1,4 @@
|
||||
-use std::os;
|
||||
+use std::env;
|
||||
|
||||
use cargo::ops;
|
||||
use cargo::util::{CliResult, CliError, Config};
|
||||
@@ -49,7 +49,7 @@ For more information about package id specifications, see `cargo help pkgid`.
|
||||
";
|
||||
|
||||
pub fn execute(options: Options, config: &Config) -> CliResult<Option<()>> {
|
||||
- debug!("executing; cmd=cargo-update; args={:?}", os::args());
|
||||
+ debug!("executing; cmd=cargo-update; args={:?}", env::args().collect::<Vec<_>>());
|
||||
config.shell().set_verbose(options.flag_verbose);
|
||||
let root = try!(find_root_manifest_for_cwd(options.flag_manifest_path));
|
||||
|
||||
diff --git a/src/bin/verify_project.rs b/src/bin/verify_project.rs
|
||||
index 54f8d6e..816c5e9 100644
|
||||
--- a/src/bin/verify_project.rs
|
||||
+++ b/src/bin/verify_project.rs
|
||||
@@ -1,8 +1,8 @@
|
||||
extern crate toml;
|
||||
|
||||
use std::collections::HashMap;
|
||||
+use std::env;
|
||||
use std::old_io::File;
|
||||
-use std::os;
|
||||
|
||||
use cargo::util::{CliResult, Config};
|
||||
|
||||
@@ -47,6 +47,6 @@ pub fn execute(args: Flags, config: &Config) -> CliResult<Option<Error>> {
|
||||
fn fail(reason: &str, value: &str) -> CliResult<Option<Error>>{
|
||||
let mut h = HashMap::new();
|
||||
h.insert(reason.to_string(), value.to_string());
|
||||
- os::set_exit_status(1);
|
||||
+ env::set_exit_status(1);
|
||||
Ok(Some(h))
|
||||
}
|
||||
diff --git a/src/bin/version.rs b/src/bin/version.rs
|
||||
index e1bc011..b5622f2 100644
|
||||
--- a/src/bin/version.rs
|
||||
+++ b/src/bin/version.rs
|
||||
@@ -1,4 +1,4 @@
|
||||
-use std::os;
|
||||
+use std::env;
|
||||
|
||||
use cargo;
|
||||
use cargo::util::{CliResult, Config};
|
||||
@@ -16,7 +16,7 @@ Options:
|
||||
";
|
||||
|
||||
pub fn execute(_: Options, _: &Config) -> CliResult<Option<()>> {
|
||||
- debug!("executing; cmd=cargo-version; args={:?}", os::args());
|
||||
+ debug!("executing; cmd=cargo-version; args={:?}", env::args().collect::<Vec<_>>());
|
||||
|
||||
println!("{}", cargo::version());
|
||||
|
||||
diff --git a/src/cargo/lib.rs b/src/cargo/lib.rs
|
||||
index 609e1bd..d5737ef 100644
|
||||
--- a/src/cargo/lib.rs
|
||||
+++ b/src/cargo/lib.rs
|
||||
@@ -95,7 +95,7 @@ fn process<V, F>(mut callback: F)
|
||||
let mut shell = shell(true);
|
||||
process_executed((|| {
|
||||
let config = try!(Config::new(&mut shell));
|
||||
- let args: Vec<_> = try!(env::args().map(|s| {
|
||||
+ let args: Vec<_> = try!(env::args_os().map(|s| {
|
||||
s.into_string().map_err(|s| {
|
||||
human(format!("invalid unicode in argument: {:?}", s))
|
||||
})
|
||||
diff --git a/src/cargo/ops/cargo_new.rs b/src/cargo/ops/cargo_new.rs
|
||||
index 09d8318..ae9d5e5 100644
|
||||
--- a/src/cargo/ops/cargo_new.rs
|
||||
+++ b/src/cargo/ops/cargo_new.rs
|
||||
@@ -134,8 +134,8 @@ fn discover_author() -> CargoResult<(String, Option<String>)> {
|
||||
let git_config = git_config.as_ref();
|
||||
let name = git_config.and_then(|g| g.get_str("user.name").ok())
|
||||
.map(|s| s.to_string())
|
||||
- .or_else(|| env::var_string("USER").ok()) // unix
|
||||
- .or_else(|| env::var_string("USERNAME").ok()); // windows
|
||||
+ .or_else(|| env::var("USER").ok()) // unix
|
||||
+ .or_else(|| env::var("USERNAME").ok()); // windows
|
||||
let name = match name {
|
||||
Some(name) => name,
|
||||
None => {
|
||||
diff --git a/src/cargo/ops/cargo_rustc/engine.rs b/src/cargo/ops/cargo_rustc/engine.rs
|
||||
index 5c6a0ef..9d234f8 100644
|
||||
--- a/src/cargo/ops/cargo_rustc/engine.rs
|
||||
+++ b/src/cargo/ops/cargo_rustc/engine.rs
|
||||
@@ -85,7 +85,7 @@ impl CommandPrototype {
|
||||
|
||||
pub fn get_env(&self, var: &str) -> Option<CString> {
|
||||
self.env.get(var).cloned().or_else(|| {
|
||||
- Some(env::var_string(var).ok().map(|s| CString::from_vec(s.into_bytes())))
|
||||
+ Some(env::var(var).ok().map(|s| CString::from_vec(s.into_bytes())))
|
||||
}).and_then(|val| val)
|
||||
}
|
||||
|
||||
diff --git a/src/cargo/ops/registry.rs b/src/cargo/ops/registry.rs
|
||||
index 2461981..59754f2 100644
|
||||
--- a/src/cargo/ops/registry.rs
|
||||
+++ b/src/cargo/ops/registry.rs
|
||||
@@ -191,7 +191,7 @@ pub fn http_proxy(config: &Config) -> CargoResult<Option<String>> {
|
||||
}
|
||||
Err(..) => {}
|
||||
}
|
||||
- Ok(env::var_string("HTTP_PROXY").ok())
|
||||
+ Ok(env::var("HTTP_PROXY").ok())
|
||||
}
|
||||
|
||||
pub fn http_timeout(config: &Config) -> CargoResult<Option<i64>> {
|
||||
@@ -199,7 +199,7 @@ pub fn http_timeout(config: &Config) -> CargoResult<Option<i64>> {
|
||||
Some((s, _)) => return Ok(Some(s)),
|
||||
None => {}
|
||||
}
|
||||
- Ok(env::var_string("HTTP_TIMEOUT").ok().and_then(|s| s.parse().ok()))
|
||||
+ Ok(env::var("HTTP_TIMEOUT").ok().and_then(|s| s.parse().ok()))
|
||||
}
|
||||
|
||||
pub fn registry_login(config: &Config, token: String) -> CargoResult<()> {
|
||||
diff --git a/src/cargo/sources/git/utils.rs b/src/cargo/sources/git/utils.rs
|
||||
index 898f082..9861ed6 100644
|
||||
--- a/src/cargo/sources/git/utils.rs
|
||||
+++ b/src/cargo/sources/git/utils.rs
|
||||
@@ -308,7 +308,8 @@ impl<'a> GitCheckout<'a> {
|
||||
// as the submodule's head, then we can bail out and go to the
|
||||
// next submodule.
|
||||
let head_and_repo = child.open().and_then(|repo| {
|
||||
- Ok((try!(repo.head()).target(), repo))
|
||||
+ let target = try!(repo.head()).target();
|
||||
+ Ok((target, repo))
|
||||
});
|
||||
let repo = match head_and_repo {
|
||||
Ok((head, repo)) => {
|
||||
diff --git a/src/cargo/util/config.rs b/src/cargo/util/config.rs
|
||||
index 217d028..076e68d 100644
|
||||
--- a/src/cargo/util/config.rs
|
||||
+++ b/src/cargo/util/config.rs
|
||||
@@ -380,7 +380,7 @@ impl ConfigValue {
|
||||
}
|
||||
|
||||
fn homedir() -> Option<Path> {
|
||||
- let cargo_home = env::var_string("CARGO_HOME").map(|p| Path::new(p)).ok();
|
||||
+ let cargo_home = env::var("CARGO_HOME").map(|p| Path::new(p)).ok();
|
||||
let user_home = env::home_dir().map(|p| p.join(".cargo"));
|
||||
return cargo_home.or(user_home);
|
||||
}
|
||||
diff --git a/src/cargo/util/hex.rs b/src/cargo/util/hex.rs
|
||||
index 2bce7ea..3e8d962 100644
|
||||
--- a/src/cargo/util/hex.rs
|
||||
+++ b/src/cargo/util/hex.rs
|
||||
@@ -1,12 +1,11 @@
|
||||
-use std::old_io::MemWriter;
|
||||
use std::hash::{Hasher, Hash, SipHasher};
|
||||
|
||||
use rustc_serialize::hex::ToHex;
|
||||
|
||||
pub fn to_hex(num: u64) -> String {
|
||||
- let mut writer = MemWriter::with_capacity(8);
|
||||
+ let mut writer = Vec::with_capacity(8);
|
||||
writer.write_le_u64(num).unwrap(); // this should never fail
|
||||
- writer.get_ref().to_hex()
|
||||
+ writer.to_hex()
|
||||
}
|
||||
|
||||
pub fn short_hash<H: Hash<SipHasher>>(hashable: &H) -> String {
|
||||
diff --git a/src/cargo/util/profile.rs b/src/cargo/util/profile.rs
|
||||
index 9d19c36..100fd2c 100644
|
||||
--- a/src/cargo/util/profile.rs
|
||||
+++ b/src/cargo/util/profile.rs
|
||||
@@ -14,7 +14,7 @@ pub struct Profiler {
|
||||
desc: String,
|
||||
}
|
||||
|
||||
-fn enabled() -> bool { env::var("CARGO_PROFILE").is_some() }
|
||||
+fn enabled() -> bool { env::var_os("CARGO_PROFILE").is_some() }
|
||||
|
||||
pub fn start<T: fmt::Display>(desc: T) -> Profiler {
|
||||
if !enabled() { return Profiler { desc: String::new() } }
|
||||
diff --git a/src/rustversion.txt b/src/rustversion.txt
|
||||
index e2a057d..17cae77 100644
|
||||
--- a/src/rustversion.txt
|
||||
+++ b/src/rustversion.txt
|
||||
@@ -1 +1 @@
|
||||
-2015-02-09
|
||||
+2015-02-12
|
||||
diff --git a/tests/support/mod.rs b/tests/support/mod.rs
|
||||
index 83be295..7c10756 100644
|
||||
--- a/tests/support/mod.rs
|
||||
+++ b/tests/support/mod.rs
|
||||
@@ -227,7 +227,7 @@ impl<T, E: fmt::Display> ErrMsg<T> for Result<T, E> {
|
||||
|
||||
// Path to cargo executables
|
||||
pub fn cargo_dir() -> Path {
|
||||
- env::var_string("CARGO_BIN_PATH").map(Path::new).ok()
|
||||
+ env::var("CARGO_BIN_PATH").map(Path::new).ok()
|
||||
.or_else(|| env::current_exe().ok().map(|s| s.dir_path()))
|
||||
.unwrap_or_else(|| {
|
||||
panic!("CARGO_BIN_PATH wasn't set. Cannot continue running test")
|
||||
diff --git a/tests/test_cargo.rs b/tests/test_cargo.rs
|
||||
index b4b1abd..64e4c75 100644
|
||||
--- a/tests/test_cargo.rs
|
||||
+++ b/tests/test_cargo.rs
|
||||
@@ -25,7 +25,7 @@ fn fake_executable(proj: ProjectBuilder, dir: &Path, name: &str) -> ProjectBuild
|
||||
}
|
||||
|
||||
fn path() -> Vec<Path> {
|
||||
- env::split_paths(&env::var("PATH").unwrap_or(OsString::new())).collect()
|
||||
+ env::split_paths(&env::var_os("PATH").unwrap_or(OsString::new())).collect()
|
||||
}
|
||||
|
||||
test!(list_commands_looks_at_path {
|
||||
diff --git a/tests/test_cargo_compile.rs b/tests/test_cargo_compile.rs
|
||||
index 20fcab8..9c5b934 100644
|
||||
--- a/tests/test_cargo_compile.rs
|
||||
+++ b/tests/test_cargo_compile.rs
|
||||
@@ -1259,7 +1259,7 @@ test!(freshness_ignores_excluded {
|
||||
exclude = ["src/b*.rs"]
|
||||
"#)
|
||||
.file("build.rs", "fn main() {}")
|
||||
- .file("src/lib.rs", "pub fn bar() -> int { 1 }");
|
||||
+ .file("src/lib.rs", "pub fn bar() -> i32 { 1 }");
|
||||
foo.build();
|
||||
foo.root().move_into_the_past().unwrap();
|
||||
|
||||
@@ -1297,15 +1297,15 @@ test!(rebuild_preserves_out_dir {
|
||||
use std::old_io::File;
|
||||
|
||||
fn main() {
|
||||
- let path = Path::new(env::var_string("OUT_DIR").unwrap()).join("foo");
|
||||
- if env::var("FIRST").is_some() {
|
||||
+ let path = Path::new(env::var("OUT_DIR").unwrap()).join("foo");
|
||||
+ if env::var_os("FIRST").is_some() {
|
||||
File::create(&path).unwrap();
|
||||
} else {
|
||||
File::create(&path).unwrap();
|
||||
}
|
||||
}
|
||||
"#)
|
||||
- .file("src/lib.rs", "pub fn bar() -> int { 1 }");
|
||||
+ .file("src/lib.rs", "pub fn bar() -> i32 { 1 }");
|
||||
foo.build();
|
||||
foo.root().move_into_the_past().unwrap();
|
||||
|
||||
@@ -1335,7 +1335,7 @@ test!(dep_no_libs {
|
||||
[dependencies.bar]
|
||||
path = "bar"
|
||||
"#)
|
||||
- .file("src/lib.rs", "pub fn bar() -> int { 1 }")
|
||||
+ .file("src/lib.rs", "pub fn bar() -> i32 { 1 }")
|
||||
.file("bar/Cargo.toml", r#"
|
||||
[package]
|
||||
name = "bar"
|
||||
diff --git a/tests/test_cargo_compile_custom_build.rs b/tests/test_cargo_compile_custom_build.rs
|
||||
index b110b86..4ef727b 100644
|
||||
--- a/tests/test_cargo_compile_custom_build.rs
|
||||
+++ b/tests/test_cargo_compile_custom_build.rs
|
||||
@@ -79,32 +79,32 @@ test!(custom_build_env_vars {
|
||||
use std::env;
|
||||
use std::old_io::fs::PathExtensions;
|
||||
fn main() {{
|
||||
- let _target = env::var_string("TARGET").unwrap();
|
||||
+ let _target = env::var("TARGET").unwrap();
|
||||
|
||||
- let _ncpus = env::var_string("NUM_JOBS").unwrap();
|
||||
+ let _ncpus = env::var("NUM_JOBS").unwrap();
|
||||
|
||||
- let out = env::var_string("CARGO_MANIFEST_DIR").unwrap();
|
||||
+ let out = env::var("CARGO_MANIFEST_DIR").unwrap();
|
||||
let p1 = Path::new(out);
|
||||
let cwd = env::current_dir().unwrap();
|
||||
let p2 = cwd.join(Path::new(file!()).dir_path().dir_path());
|
||||
assert!(p1 == p2, "{{}} != {{}}", p1.display(), p2.display());
|
||||
|
||||
- let opt = env::var_string("OPT_LEVEL").unwrap();
|
||||
+ let opt = env::var("OPT_LEVEL").unwrap();
|
||||
assert_eq!(opt.as_slice(), "0");
|
||||
|
||||
- let opt = env::var_string("PROFILE").unwrap();
|
||||
+ let opt = env::var("PROFILE").unwrap();
|
||||
assert_eq!(opt.as_slice(), "compile");
|
||||
|
||||
- let debug = env::var_string("DEBUG").unwrap();
|
||||
+ let debug = env::var("DEBUG").unwrap();
|
||||
assert_eq!(debug.as_slice(), "true");
|
||||
|
||||
- let out = env::var_string("OUT_DIR").unwrap();
|
||||
+ let out = env::var("OUT_DIR").unwrap();
|
||||
assert!(out.as_slice().starts_with(r"{0}"));
|
||||
assert!(Path::new(out).is_dir());
|
||||
|
||||
- let _host = env::var_string("HOST").unwrap();
|
||||
+ let _host = env::var("HOST").unwrap();
|
||||
|
||||
- let _feat = env::var_string("CARGO_FEATURE_FOO").unwrap();
|
||||
+ let _feat = env::var("CARGO_FEATURE_FOO").unwrap();
|
||||
}}
|
||||
"#,
|
||||
p.root().join("target").join("build").display());
|
||||
@@ -269,8 +269,8 @@ test!(overrides_and_links {
|
||||
.file("build.rs", r#"
|
||||
use std::env;
|
||||
fn main() {
|
||||
- assert_eq!(env::var_string("DEP_FOO_FOO").unwrap().as_slice(), "bar");
|
||||
- assert_eq!(env::var_string("DEP_FOO_BAR").unwrap().as_slice(), "baz");
|
||||
+ assert_eq!(env::var("DEP_FOO_FOO").unwrap().as_slice(), "bar");
|
||||
+ assert_eq!(env::var("DEP_FOO_BAR").unwrap().as_slice(), "baz");
|
||||
}
|
||||
"#)
|
||||
.file(".cargo/config", format!(r#"
|
||||
@@ -342,8 +342,8 @@ test!(links_passes_env_vars {
|
||||
.file("build.rs", r#"
|
||||
use std::env;
|
||||
fn main() {
|
||||
- assert_eq!(env::var_string("DEP_FOO_FOO").unwrap().as_slice(), "bar");
|
||||
- assert_eq!(env::var_string("DEP_FOO_BAR").unwrap().as_slice(), "baz");
|
||||
+ assert_eq!(env::var("DEP_FOO_FOO").unwrap().as_slice(), "bar");
|
||||
+ assert_eq!(env::var("DEP_FOO_BAR").unwrap().as_slice(), "baz");
|
||||
}
|
||||
"#)
|
||||
.file("a/Cargo.toml", r#"
|
||||
@@ -441,8 +441,8 @@ test!(rebuild_continues_to_pass_env_vars {
|
||||
.file("build.rs", r#"
|
||||
use std::env;
|
||||
fn main() {
|
||||
- assert_eq!(env::var_string("DEP_FOO_FOO").unwrap().as_slice(), "bar");
|
||||
- assert_eq!(env::var_string("DEP_FOO_BAR").unwrap().as_slice(), "baz");
|
||||
+ assert_eq!(env::var("DEP_FOO_FOO").unwrap().as_slice(), "bar");
|
||||
+ assert_eq!(env::var("DEP_FOO_BAR").unwrap().as_slice(), "baz");
|
||||
}
|
||||
"#);
|
||||
|
||||
@@ -727,7 +727,7 @@ test!(out_dir_is_preserved {
|
||||
use std::env;
|
||||
use std::old_io::File;
|
||||
fn main() {
|
||||
- let out = env::var_string("OUT_DIR").unwrap();
|
||||
+ let out = env::var("OUT_DIR").unwrap();
|
||||
File::create(&Path::new(out).join("foo")).unwrap();
|
||||
}
|
||||
"#);
|
||||
@@ -742,7 +742,7 @@ test!(out_dir_is_preserved {
|
||||
use std::env;
|
||||
use std::old_io::File;
|
||||
fn main() {
|
||||
- let out = env::var_string("OUT_DIR").unwrap();
|
||||
+ let out = env::var("OUT_DIR").unwrap();
|
||||
File::open(&Path::new(out).join("foo")).unwrap();
|
||||
}
|
||||
"#).unwrap();
|
||||
@@ -808,7 +808,7 @@ test!(code_generation {
|
||||
use std::old_io::File;
|
||||
|
||||
fn main() {
|
||||
- let dst = Path::new(env::var_string("OUT_DIR").unwrap());
|
||||
+ let dst = Path::new(env::var("OUT_DIR").unwrap());
|
||||
let mut f = File::create(&dst.join("hello.rs")).unwrap();
|
||||
f.write_str("
|
||||
pub fn message() -> &'static str {
|
||||
@@ -972,9 +972,9 @@ test!(test_a_lib_with_a_build_command {
|
||||
use std::old_io::File;
|
||||
|
||||
fn main() {
|
||||
- let out = Path::new(env::var_string("OUT_DIR").unwrap());
|
||||
+ let out = Path::new(env::var("OUT_DIR").unwrap());
|
||||
File::create(&out.join("foo.rs")).write_str("
|
||||
- fn foo() -> int { 1 }
|
||||
+ fn foo() -> i32 { 1 }
|
||||
").unwrap();
|
||||
}
|
||||
"#);
|
||||
@@ -1062,7 +1062,7 @@ test!(build_script_with_dynamic_native_dependency {
|
||||
use std::env;
|
||||
|
||||
fn main() {
|
||||
- let src = Path::new(env::var_string("SRC").unwrap());
|
||||
+ let src = Path::new(env::var("SRC").unwrap());
|
||||
println!("cargo:rustc-flags=-L {}", src.dir_path().display());
|
||||
}
|
||||
"#)
|
||||
diff --git a/tests/test_cargo_compile_git_deps.rs b/tests/test_cargo_compile_git_deps.rs
|
||||
index 5777e1a..11a152f 100644
|
||||
--- a/tests/test_cargo_compile_git_deps.rs
|
||||
+++ b/tests/test_cargo_compile_git_deps.rs
|
||||
@@ -461,7 +461,7 @@ test!(two_revs_same_deps {
|
||||
version = "0.0.0"
|
||||
authors = []
|
||||
"#)
|
||||
- .file("src/lib.rs", "pub fn bar() -> int { 1 }")
|
||||
+ .file("src/lib.rs", "pub fn bar() -> i32 { 1 }")
|
||||
}).unwrap();
|
||||
|
||||
let repo = git2::Repository::open(&bar.root()).unwrap();
|
||||
@@ -469,7 +469,7 @@ test!(two_revs_same_deps {
|
||||
|
||||
// Commit the changes and make sure we trigger a recompile
|
||||
File::create(&bar.root().join("src/lib.rs")).write_str(r#"
|
||||
- pub fn bar() -> int { 2 }
|
||||
+ pub fn bar() -> i32 { 2 }
|
||||
"#).unwrap();
|
||||
add(&repo);
|
||||
let rev2 = commit(&repo);
|
||||
@@ -511,7 +511,7 @@ test!(two_revs_same_deps {
|
||||
"#, bar.url(), rev2).as_slice())
|
||||
.file("src/lib.rs", r#"
|
||||
extern crate bar;
|
||||
- pub fn baz() -> int { bar::bar() }
|
||||
+ pub fn baz() -> i32 { bar::bar() }
|
||||
"#);
|
||||
|
||||
baz.build();
|
||||
@@ -860,7 +860,7 @@ test!(stale_cached_version {
|
||||
version = "0.0.0"
|
||||
authors = []
|
||||
"#)
|
||||
- .file("src/lib.rs", "pub fn bar() -> int { 1 }")
|
||||
+ .file("src/lib.rs", "pub fn bar() -> i32 { 1 }")
|
||||
}).unwrap();
|
||||
|
||||
// Update the git database in the cache with the current state of the git
|
||||
@@ -887,7 +887,7 @@ test!(stale_cached_version {
|
||||
// Update the repo, and simulate someone else updating the lockfile and then
|
||||
// us pulling it down.
|
||||
File::create(&bar.root().join("src/lib.rs")).write_str(r#"
|
||||
- pub fn bar() -> int { 1 + 0 }
|
||||
+ pub fn bar() -> i32 { 1 + 0 }
|
||||
"#).unwrap();
|
||||
let repo = git2::Repository::open(&bar.root()).unwrap();
|
||||
add(&repo);
|
||||
@@ -1090,7 +1090,7 @@ test!(git_build_cmd_freshness {
|
||||
build = "build.rs"
|
||||
"#)
|
||||
.file("build.rs", "fn main() {}")
|
||||
- .file("src/lib.rs", "pub fn bar() -> int { 1 }")
|
||||
+ .file("src/lib.rs", "pub fn bar() -> i32 { 1 }")
|
||||
.file(".gitignore", "
|
||||
src/bar.rs
|
||||
")
|
||||
@@ -1166,7 +1166,7 @@ test!(git_repo_changing_no_rebuild {
|
||||
version = "0.5.0"
|
||||
authors = ["wycats@example.com"]
|
||||
"#)
|
||||
- .file("src/lib.rs", "pub fn bar() -> int { 1 }")
|
||||
+ .file("src/lib.rs", "pub fn bar() -> i32 { 1 }")
|
||||
}).unwrap();
|
||||
|
||||
// Lock p1 to the first rev in the git repo
|
||||
@@ -1193,7 +1193,7 @@ test!(git_repo_changing_no_rebuild {
|
||||
|
||||
// Make a commit to lock p2 to a different rev
|
||||
File::create(&bar.root().join("src/lib.rs")).write_str(r#"
|
||||
- pub fn bar() -> int { 2 }
|
||||
+ pub fn bar() -> i32 { 2 }
|
||||
"#).unwrap();
|
||||
let repo = git2::Repository::open(&bar.root()).unwrap();
|
||||
add(&repo);
|
||||
@@ -1256,7 +1256,7 @@ test!(git_dep_build_cmd {
|
||||
name = "bar"
|
||||
"#)
|
||||
.file("bar/src/bar.rs.in", r#"
|
||||
- pub fn gimme() -> int { 0 }
|
||||
+ pub fn gimme() -> i32 { 0 }
|
||||
"#)
|
||||
.file("bar/build.rs", r#"
|
||||
use std::old_io::fs;
|
||||
@@ -1278,7 +1278,7 @@ test!(git_dep_build_cmd {
|
||||
|
||||
// Touching bar.rs.in should cause the `build` command to run again.
|
||||
let mut file = fs::File::create(&p.root().join("bar/src/bar.rs.in")).unwrap();
|
||||
- file.write_str(r#"pub fn gimme() -> int { 1 }"#).unwrap();
|
||||
+ file.write_str(r#"pub fn gimme() -> i32 { 1 }"#).unwrap();
|
||||
drop(file);
|
||||
|
||||
assert_that(p.process(cargo_dir().join("cargo")).arg("build"),
|
||||
@@ -1297,7 +1297,7 @@ test!(fetch_downloads {
|
||||
version = "0.5.0"
|
||||
authors = ["wycats@example.com"]
|
||||
"#)
|
||||
- .file("src/lib.rs", "pub fn bar() -> int { 1 }")
|
||||
+ .file("src/lib.rs", "pub fn bar() -> i32 { 1 }")
|
||||
}).unwrap();
|
||||
|
||||
let p = project("p1")
|
||||
@@ -1569,7 +1569,7 @@ test!(update_one_source_updates_all_packages_in_that_git_source {
|
||||
|
||||
// Just be sure to change a file
|
||||
File::create(&dep.root().join("src/lib.rs")).write_str(r#"
|
||||
- pub fn bar() -> int { 2 }
|
||||
+ pub fn bar() -> i32 { 2 }
|
||||
"#).unwrap();
|
||||
add(&repo);
|
||||
commit(&repo);
|
||||
diff --git a/tests/test_cargo_compile_plugins.rs b/tests/test_cargo_compile_plugins.rs
|
||||
index 853038f..ca44a4d 100644
|
||||
--- a/tests/test_cargo_compile_plugins.rs
|
||||
+++ b/tests/test_cargo_compile_plugins.rs
|
||||
@@ -23,14 +23,14 @@ test!(plugin_to_the_max {
|
||||
"#)
|
||||
.file("src/main.rs", r#"
|
||||
#![feature(plugin)]
|
||||
- #[plugin] #[no_link] extern crate bar;
|
||||
+ #![plugin(bar)]
|
||||
extern crate foo_lib;
|
||||
|
||||
fn main() { foo_lib::foo(); }
|
||||
"#)
|
||||
.file("src/foo_lib.rs", r#"
|
||||
#![feature(plugin)]
|
||||
- #[plugin] #[no_link] extern crate bar;
|
||||
+ #![plugin(bar)]
|
||||
|
||||
pub fn foo() {}
|
||||
"#);
|
||||
@@ -122,7 +122,7 @@ test!(plugin_with_dynamic_native_dependency {
|
||||
"#)
|
||||
.file("src/main.rs", r#"
|
||||
#![feature(plugin)]
|
||||
- #[plugin] #[no_link] extern crate bar;
|
||||
+ #![plugin(bar)]
|
||||
|
||||
fn main() {}
|
||||
"#)
|
||||
diff --git a/tests/test_cargo_cross_compile.rs b/tests/test_cargo_cross_compile.rs
|
||||
index a2d53e0..cf6b9a5 100644
|
||||
--- a/tests/test_cargo_cross_compile.rs
|
||||
+++ b/tests/test_cargo_cross_compile.rs
|
||||
@@ -12,7 +12,7 @@ fn setup() {
|
||||
|
||||
fn disabled() -> bool {
|
||||
// First, disable if ./configure requested so
|
||||
- match env::var_string("CFG_DISABLE_CROSS_TESTS") {
|
||||
+ match env::var("CFG_DISABLE_CROSS_TESTS") {
|
||||
Ok(ref s) if s.as_slice() == "1" => return true,
|
||||
_ => {}
|
||||
}
|
||||
@@ -44,7 +44,7 @@ test!(simple_cross {
|
||||
"#)
|
||||
.file("build.rs", format!(r#"
|
||||
fn main() {{
|
||||
- assert_eq!(std::env::var_string("TARGET").unwrap().as_slice(), "{}");
|
||||
+ assert_eq!(std::env::var("TARGET").unwrap().as_slice(), "{}");
|
||||
}}
|
||||
"#, alternate()).as_slice())
|
||||
.file("src/main.rs", r#"
|
||||
@@ -119,8 +119,7 @@ test!(plugin_deps {
|
||||
"#)
|
||||
.file("src/main.rs", r#"
|
||||
#![feature(plugin)]
|
||||
- #[plugin] #[no_link]
|
||||
- extern crate bar;
|
||||
+ #![plugin(bar)]
|
||||
extern crate baz;
|
||||
fn main() {
|
||||
assert_eq!(bar!(), baz::baz());
|
||||
@@ -155,7 +154,7 @@ test!(plugin_deps {
|
||||
|
||||
fn expand_bar(cx: &mut ExtCtxt, sp: Span, tts: &[TokenTree])
|
||||
-> Box<MacResult + 'static> {
|
||||
- MacExpr::new(quote_expr!(cx, 1i))
|
||||
+ MacExpr::new(quote_expr!(cx, 1))
|
||||
}
|
||||
"#);
|
||||
let baz = project("baz")
|
||||
@@ -165,7 +164,7 @@ test!(plugin_deps {
|
||||
version = "0.0.1"
|
||||
authors = []
|
||||
"#)
|
||||
- .file("src/lib.rs", "pub fn baz() -> int { 1 }");
|
||||
+ .file("src/lib.rs", "pub fn baz() -> i32 { 1 }");
|
||||
bar.build();
|
||||
baz.build();
|
||||
|
||||
@@ -197,8 +196,7 @@ test!(plugin_to_the_max {
|
||||
"#)
|
||||
.file("src/main.rs", r#"
|
||||
#![feature(plugin)]
|
||||
- #[plugin] #[no_link]
|
||||
- extern crate bar;
|
||||
+ #![plugin(bar)]
|
||||
extern crate baz;
|
||||
fn main() {
|
||||
assert_eq!(bar!(), baz::baz());
|
||||
@@ -320,7 +318,7 @@ test!(plugin_with_extra_dylib_dep {
|
||||
"#)
|
||||
.file("src/main.rs", r#"
|
||||
#![feature(plugin)]
|
||||
- #[plugin] #[no_link] extern crate bar;
|
||||
+ #![plugin(bar)]
|
||||
|
||||
fn main() {}
|
||||
"#);
|
||||
@@ -362,7 +360,7 @@ test!(plugin_with_extra_dylib_dep {
|
||||
name = "baz"
|
||||
crate_type = ["dylib"]
|
||||
"#)
|
||||
- .file("src/lib.rs", "pub fn baz() -> int { 1 }");
|
||||
+ .file("src/lib.rs", "pub fn baz() -> i32 { 1 }");
|
||||
bar.build();
|
||||
baz.build();
|
||||
|
||||
@@ -464,8 +462,8 @@ test!(cross_with_a_build_script {
|
||||
.file("build.rs", format!(r#"
|
||||
use std::env;
|
||||
fn main() {{
|
||||
- assert_eq!(env::var_string("TARGET").unwrap().as_slice(), "{0}");
|
||||
- let mut path = Path::new(env::var_string("OUT_DIR").unwrap());
|
||||
+ assert_eq!(env::var("TARGET").unwrap().as_slice(), "{0}");
|
||||
+ let mut path = Path::new(env::var("OUT_DIR").unwrap());
|
||||
assert_eq!(path.filename().unwrap(), b"out");
|
||||
path.pop();
|
||||
assert!(path.filename().unwrap().starts_with(b"foo-"));
|
||||
@@ -530,7 +528,7 @@ test!(build_script_needed_for_host_and_target {
|
||||
.file("d1/build.rs", r#"
|
||||
use std::env;
|
||||
fn main() {
|
||||
- let target = env::var_string("TARGET").unwrap();
|
||||
+ let target = env::var("TARGET").unwrap();
|
||||
println!("cargo:rustc-flags=-L /path/to/{}", target);
|
||||
}
|
||||
"#)
|
||||
@@ -643,9 +641,9 @@ test!(build_script_only_host {
|
||||
use std::env;
|
||||
|
||||
fn main() {
|
||||
- assert!(env::var_string("OUT_DIR").unwrap()
|
||||
+ assert!(env::var("OUT_DIR").unwrap()
|
||||
.contains("target/build/d1-"),
|
||||
- "bad: {:?}", env::var_string("OUT_DIR"));
|
||||
+ "bad: {:?}", env::var("OUT_DIR"));
|
||||
}
|
||||
"#);
|
||||
|
||||
diff --git a/tests/test_cargo_profiles.rs b/tests/test_cargo_profiles.rs
|
||||
index b71eadb..827393f 100644
|
||||
--- a/tests/test_cargo_profiles.rs
|
||||
+++ b/tests/test_cargo_profiles.rs
|
||||
@@ -1,4 +1,4 @@
|
||||
-use std::os;
|
||||
+use std::env;
|
||||
use std::old_path;
|
||||
|
||||
use support::{project, execs};
|
||||
@@ -110,6 +110,6 @@ test!(top_level_overrides_deps {
|
||||
dir = p.root().display(),
|
||||
url = p.url(),
|
||||
sep = old_path::SEP,
|
||||
- prefix = os::consts::DLL_PREFIX,
|
||||
- suffix = os::consts::DLL_SUFFIX).as_slice()));
|
||||
+ prefix = env::consts::DLL_PREFIX,
|
||||
+ suffix = env::consts::DLL_SUFFIX).as_slice()));
|
||||
});
|
||||
--
|
||||
2.3.0
|
||||
|
||||
@@ -0,0 +1,138 @@
|
||||
From f32fa685610399739a2584ae02653753a372d6ed Mon Sep 17 00:00:00 2001
|
||||
From: Cody P Schafer <dev@codyps.com>
|
||||
Date: Fri, 13 Feb 2015 15:24:16 -0500
|
||||
Subject: [PATCH] update pkg versions
|
||||
|
||||
---
|
||||
Cargo.lock | 32 ++++++++++++++++----------------
|
||||
1 file changed, 16 insertions(+), 16 deletions(-)
|
||||
|
||||
diff --git a/Cargo.lock b/Cargo.lock
|
||||
index 14dd876..629585c 100644
|
||||
--- a/Cargo.lock
|
||||
+++ b/Cargo.lock
|
||||
@@ -4,7 +4,7 @@ version = "0.1.0"
|
||||
dependencies = [
|
||||
"advapi32-sys 0.0.4 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"curl 0.1.14 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "docopt 0.6.36 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "docopt 0.6.37 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"env_logger 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"flate2 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"git2 0.1.17 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
@@ -18,8 +18,8 @@ dependencies = [
|
||||
"semver 0.1.14 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"tar 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"term 0.1.11 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "time 0.1.16 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "toml 0.1.16 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "time 0.1.17 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "toml 0.1.17 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"url 0.2.20 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"winapi 0.1.11 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
@@ -44,7 +44,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"curl-sys 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"libc 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "openssl-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "openssl-sys 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"url 0.2.20 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
|
||||
@@ -55,13 +55,13 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"libc 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"libz-sys 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "openssl-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "openssl-sys 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"pkg-config 0.1.7 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "docopt"
|
||||
-version = "0.6.36"
|
||||
+version = "0.6.37"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"regex 0.1.14 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
@@ -97,7 +97,7 @@ version = "0.1.17"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"bitflags 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "libgit2-sys 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "libgit2-sys 0.1.13 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"url 0.2.20 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
|
||||
@@ -136,13 +136,13 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
|
||||
[[package]]
|
||||
name = "libgit2-sys"
|
||||
-version = "0.1.12"
|
||||
+version = "0.1.13"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"libssh2-sys 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"libz-sys 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "openssl-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "pkg-config 0.1.7 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "openssl-sys 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "pkg-config 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
@@ -159,7 +159,7 @@ version = "0.1.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"libz-sys 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "openssl-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "openssl-sys 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"pkg-config 0.1.7 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
|
||||
@@ -192,12 +192,12 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "openssl-sys"
|
||||
-version = "0.3.3"
|
||||
+version = "0.3.6"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"gcc 0.1.7 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"libressl-pnacl-sys 2.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
- "pkg-config 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
+ "pkg-config 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
@@ -207,7 +207,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
|
||||
[[package]]
|
||||
name = "pkg-config"
|
||||
-version = "0.2.0"
|
||||
+version = "0.2.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
|
||||
[[package]]
|
||||
@@ -255,7 +255,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "time"
|
||||
-version = "0.1.16"
|
||||
+version = "0.1.17"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"gcc 0.1.7 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
@@ -264,7 +264,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "toml"
|
||||
-version = "0.1.16"
|
||||
+version = "0.1.17"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
dependencies = [
|
||||
"rustc-serialize 0.2.12 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
--
|
||||
2.3.0
|
||||
|
||||
+12
-12
@@ -1,4 +1,4 @@
|
||||
From f975a2796178c840d54cb1070cabf84b79829388 Mon Sep 17 00:00:00 2001
|
||||
From 979f3ed5cff5356b67d8bbf946d51b0132272c87 Mon Sep 17 00:00:00 2001
|
||||
From: Cody P Schafer <dev@codyps.com>
|
||||
Date: Tue, 25 Nov 2014 11:50:28 -0500
|
||||
Subject: [PATCH 1/3] curl-sys: avoid explicitly linking in openssl. If it is
|
||||
@@ -10,7 +10,7 @@ Subject: [PATCH 1/3] curl-sys: avoid explicitly linking in openssl. If it is
|
||||
2 files changed, 19 deletions(-)
|
||||
|
||||
diff --git a/curl-sys/Cargo.toml b/curl-sys/Cargo.toml
|
||||
index 13c8425..6b0c22a 100644
|
||||
index dfd001f..3b58919 100644
|
||||
--- a/curl-sys/Cargo.toml
|
||||
+++ b/curl-sys/Cargo.toml
|
||||
@@ -18,21 +18,3 @@ path = "lib.rs"
|
||||
@@ -20,26 +20,26 @@ index 13c8425..6b0c22a 100644
|
||||
-
|
||||
-# Unix platforms use OpenSSL for now to provide SSL functionality
|
||||
-[target.i686-apple-darwin.dependencies]
|
||||
-openssl-sys = "0.3.0"
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.x86_64-apple-darwin.dependencies]
|
||||
-openssl-sys = "0.3.0"
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.i686-unknown-linux-gnu.dependencies]
|
||||
-openssl-sys = "0.3.0"
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.x86_64-unknown-linux-gnu.dependencies]
|
||||
-openssl-sys = "0.3.0"
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.arm-unknown-linux-gnueabihf.dependencies]
|
||||
-openssl-sys = "0.3.0"
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.aarch64-unknown-linux-gnu.dependencies]
|
||||
-openssl-sys = "0.3.0"
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.i686-unknown-freebsd.dependencies]
|
||||
-openssl-sys = "0.3.0"
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.x86_64-unknown-freebsd.dependencies]
|
||||
-openssl-sys = "0.3.0"
|
||||
-openssl-sys = "0.4.0"
|
||||
diff --git a/curl-sys/lib.rs b/curl-sys/lib.rs
|
||||
index ea21503..99dab99 100644
|
||||
index 0a224a4..1328834 100644
|
||||
--- a/curl-sys/lib.rs
|
||||
+++ b/curl-sys/lib.rs
|
||||
@@ -3,7 +3,6 @@
|
||||
@@ -2,7 +2,6 @@
|
||||
|
||||
extern crate libc;
|
||||
extern crate "libz-sys" as libz;
|
||||
|
||||
+2
-2
@@ -1,4 +1,4 @@
|
||||
From 09e25bc8799eb05d7fade240d6a12d9b7642046a Mon Sep 17 00:00:00 2001
|
||||
From 8e66b372f0e2ac5818ec5de14324451fc2357234 Mon Sep 17 00:00:00 2001
|
||||
From: Cody P Schafer <dev@codyps.com>
|
||||
Date: Tue, 25 Nov 2014 12:26:48 -0500
|
||||
Subject: [PATCH 2/3] openssl-sys is used in curl-rust, so include it
|
||||
@@ -9,7 +9,7 @@ Subject: [PATCH 2/3] openssl-sys is used in curl-rust, so include it
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/Cargo.toml b/Cargo.toml
|
||||
index f9671e4..c845da1 100644
|
||||
index c813796..9fd56f5 100644
|
||||
--- a/Cargo.toml
|
||||
+++ b/Cargo.toml
|
||||
@@ -15,6 +15,9 @@ libc = "0.1"
|
||||
|
||||
@@ -0,0 +1,71 @@
|
||||
From 0214ac430f8dcd31ef4dbb88540da3c805d4ccf6 Mon Sep 17 00:00:00 2001
|
||||
From: Cody P Schafer <dev@codyps.com>
|
||||
Date: Fri, 13 Feb 2015 13:34:11 -0500
|
||||
Subject: [PATCH 3/3] remove per-triple deps on openssl-sys
|
||||
|
||||
---
|
||||
Cargo.toml | 48 ++++++++++++++----------------------------------
|
||||
1 file changed, 14 insertions(+), 34 deletions(-)
|
||||
|
||||
diff --git a/Cargo.toml b/Cargo.toml
|
||||
index 9fd56f5..3b58919 100644
|
||||
--- a/Cargo.toml
|
||||
+++ b/Cargo.toml
|
||||
@@ -1,40 +1,20 @@
|
||||
[package]
|
||||
-
|
||||
-name = "curl"
|
||||
-version = "0.1.17"
|
||||
-authors = ["Carl Lerche <me@carllerche.com>"]
|
||||
+name = "curl-sys"
|
||||
+version = "0.1.10"
|
||||
+authors = ["Carl Lerche <me@carllerche.com"]
|
||||
+links = "curl"
|
||||
+build = "build.rs"
|
||||
license = "MIT"
|
||||
repository = "https://github.com/carllerche/curl-rust"
|
||||
-description = "Rust bindings to libcurl for making HTTP requests"
|
||||
-
|
||||
-[dependencies]
|
||||
-url = "0.2.0"
|
||||
-libc = "0.1"
|
||||
+description = "Native bindings to the libcurl library"
|
||||
|
||||
-[dependencies.curl-sys]
|
||||
-path = "curl-sys"
|
||||
-version = "0.1.0"
|
||||
+[build-dependencies]
|
||||
+pkg-config = "0.1.0"
|
||||
|
||||
-[dependencies.openssl-sys]
|
||||
-version = "*"
|
||||
+[lib]
|
||||
+name = "curl-sys"
|
||||
+path = "lib.rs"
|
||||
|
||||
-[dev-dependencies]
|
||||
-log = "0.2"
|
||||
-
|
||||
-# Unix platforms use OpenSSL for now to provide SSL functionality
|
||||
-[target.i686-apple-darwin.dependencies]
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.x86_64-apple-darwin.dependencies]
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.i686-unknown-linux-gnu.dependencies]
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.x86_64-unknown-linux-gnu.dependencies]
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.arm-unknown-linux-gnueabihf.dependencies]
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.aarch64-unknown-linux-gnu.dependencies]
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.i686-unknown-freebsd.dependencies]
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.x86_64-unknown-freebsd.dependencies]
|
||||
-openssl-sys = "0.4.0"
|
||||
+[dependencies]
|
||||
+libz-sys = "0.1.0"
|
||||
+libc = "0.1"
|
||||
--
|
||||
2.3.0
|
||||
|
||||
@@ -0,0 +1,49 @@
|
||||
From b8dc01fd6e70d9e0dcc883fe7e2167c4830d0724 Mon Sep 17 00:00:00 2001
|
||||
From: Cody P Schafer <dev@codyps.com>
|
||||
Date: Mon, 10 Nov 2014 15:06:29 -0500
|
||||
Subject: [PATCH] Add generic openssl-sys dep
|
||||
|
||||
---
|
||||
libgit2-sys/Cargo.toml | 26 +-------------------------
|
||||
1 file changed, 1 insertion(+), 25 deletions(-)
|
||||
|
||||
diff --git a/libgit2-sys/Cargo.toml b/libgit2-sys/Cargo.toml
|
||||
index d4e36ee..0e08422 100644
|
||||
--- a/libgit2-sys/Cargo.toml
|
||||
+++ b/libgit2-sys/Cargo.toml
|
||||
@@ -15,31 +15,7 @@ description = "Native bindings to the libgit2 library"
|
||||
|
||||
[dependencies]
|
||||
libssh2-sys = "0.1.0"
|
||||
+openssl-sys = "*"
|
||||
|
||||
[build-dependencies]
|
||||
pkg-config = "0.2"
|
||||
-
|
||||
-[target.i686-apple-darwin.dependencies]
|
||||
-openssl-sys = "0.4.0"
|
||||
-libz-sys = "0.1.0"
|
||||
-[target.x86_64-apple-darwin.dependencies]
|
||||
-openssl-sys = "0.4.0"
|
||||
-libz-sys = "0.1.0"
|
||||
-[target.i686-unknown-linux-gnu.dependencies]
|
||||
-openssl-sys = "0.4.0"
|
||||
-libz-sys = "0.1.0"
|
||||
-[target.x86_64-unknown-linux-gnu.dependencies]
|
||||
-openssl-sys = "0.4.0"
|
||||
-libz-sys = "0.1.0"
|
||||
-[target.aarch64-unknown-linux-gnu.dependencies]
|
||||
-openssl-sys = "0.4.0"
|
||||
-libz-sys = "0.1.0"
|
||||
-[target.arm-unknown-linux-gnueabihf.dependencies]
|
||||
-openssl-sys = "0.4.0"
|
||||
-libz-sys = "0.1.0"
|
||||
-[target.i686-unknown-freebsd.dependencies]
|
||||
-openssl-sys = "0.4.0"
|
||||
-libz-sys = "0.1.0"
|
||||
-[target.x86_64-unknown-freebsd.dependencies]
|
||||
-openssl-sys = "0.4.0"
|
||||
-libz-sys = "0.1.0"
|
||||
--
|
||||
2.3.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
From a5542bbf95e6d8f9f994439e652defddf5b91984 Mon Sep 17 00:00:00 2001
|
||||
From 7e7a5527024dbc0e45c1d4b284466a499c9580fe Mon Sep 17 00:00:00 2001
|
||||
From: Cody P Schafer <dev@codyps.com>
|
||||
Date: Mon, 1 Dec 2014 10:51:31 -0500
|
||||
Subject: [PATCH 1/2] Unconditionally depend on openssl-sys
|
||||
@@ -8,32 +8,32 @@ Subject: [PATCH 1/2] Unconditionally depend on openssl-sys
|
||||
1 file changed, 18 deletions(-)
|
||||
|
||||
diff --git a/libssh2-sys/Cargo.toml b/libssh2-sys/Cargo.toml
|
||||
index fe5d039..914d72a 100644
|
||||
index a91df02..e58515a 100644
|
||||
--- a/libssh2-sys/Cargo.toml
|
||||
+++ b/libssh2-sys/Cargo.toml
|
||||
@@ -14,24 +14,6 @@ path = "lib.rs"
|
||||
|
||||
@@ -15,24 +15,6 @@ path = "lib.rs"
|
||||
[dependencies]
|
||||
libz-sys = "0.1.0"
|
||||
libc = "0.1"
|
||||
-
|
||||
-[target.i686-apple-darwin.dependencies]
|
||||
-openssl-sys = "0.3.0"
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.x86_64-apple-darwin.dependencies]
|
||||
-openssl-sys = "0.3.0"
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.i686-unknown-linux-gnu.dependencies]
|
||||
-openssl-sys = "0.3.0"
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.x86_64-unknown-linux-gnu.dependencies]
|
||||
-openssl-sys = "0.3.0"
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.aarch64-unknown-linux-gnu.dependencies]
|
||||
-openssl-sys = "0.2.0"
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.arm-unknown-linux-gnueabihf.dependencies]
|
||||
-openssl-sys = "0.3.0"
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.i686-unknown-freebsd.dependencies]
|
||||
-openssl-sys = "0.3.0"
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.x86_64-unknown-freebsd.dependencies]
|
||||
-openssl-sys = "0.3.0"
|
||||
-openssl-sys = "0.4.0"
|
||||
-[target.x86_64-unknown-dragonfly.dependencies]
|
||||
openssl-sys = "0.3.0"
|
||||
openssl-sys = "0.4.0"
|
||||
|
||||
[build-dependencies]
|
||||
--
|
||||
|
||||
@@ -0,0 +1,150 @@
|
||||
From 1ddeb7b82b0f2a03a2f3054970ad24284b11fe64 Mon Sep 17 00:00:00 2001
|
||||
From: Cody P Schafer <dev@codyps.com>
|
||||
Date: Fri, 13 Feb 2015 14:01:14 -0500
|
||||
Subject: [PATCH 2/2] libssh2-sys: only support pkg-config
|
||||
|
||||
---
|
||||
libssh2-sys/build.rs | 125 +--------------------------------------------------
|
||||
1 file changed, 2 insertions(+), 123 deletions(-)
|
||||
|
||||
diff --git a/libssh2-sys/build.rs b/libssh2-sys/build.rs
|
||||
index 9cab3b0..c10361c 100644
|
||||
--- a/libssh2-sys/build.rs
|
||||
+++ b/libssh2-sys/build.rs
|
||||
@@ -1,131 +1,10 @@
|
||||
-#![feature(old_io, old_path, env, core)]
|
||||
-
|
||||
extern crate "pkg-config" as pkg_config;
|
||||
|
||||
-use std::env;
|
||||
-use std::old_io::{self, fs, Command};
|
||||
-use std::old_io::process::InheritFd;
|
||||
-use std::old_io::fs::PathExtensions;
|
||||
-
|
||||
fn main() {
|
||||
match pkg_config::find_library("libssh2") {
|
||||
Ok(..) => return,
|
||||
- Err(..) => {}
|
||||
- }
|
||||
-
|
||||
- let mut cflags = env::var("CFLAGS").unwrap_or(String::new());
|
||||
- let target = env::var("TARGET").unwrap();
|
||||
- let windows = target.contains("windows") || target.contains("mingw");
|
||||
- cflags.push_str(" -ffunction-sections -fdata-sections");
|
||||
-
|
||||
- if target.contains("i686") {
|
||||
- cflags.push_str(" -m32");
|
||||
- } else if target.as_slice().contains("x86_64") {
|
||||
- cflags.push_str(" -m64");
|
||||
- }
|
||||
- if !target.contains("i686") {
|
||||
- cflags.push_str(" -fPIC");
|
||||
- }
|
||||
-
|
||||
- match env::var("DEP_OPENSSL_ROOT") {
|
||||
- Ok(s) => {
|
||||
- cflags.push_str(format!(" -I{}/include", s).as_slice());
|
||||
- cflags.push_str(format!(" -L{}/lib", s).as_slice());
|
||||
+ Err(..) => {
|
||||
+ panic!("Could not find libssh2");
|
||||
}
|
||||
- Err(..) => {}
|
||||
}
|
||||
-
|
||||
- let src = Path::new(env::var("CARGO_MANIFEST_DIR").unwrap());
|
||||
- let dst = Path::new(env::var("OUT_DIR").unwrap());
|
||||
-
|
||||
- let mut config_opts = Vec::new();
|
||||
- if windows {
|
||||
- config_opts.push("--without-openssl".to_string());
|
||||
- config_opts.push("--with-wincng".to_string());
|
||||
- }
|
||||
- config_opts.push("--enable-shared=no".to_string());
|
||||
- config_opts.push("--disable-examples-build".to_string());
|
||||
- config_opts.push(format!("--prefix={}", dst.display()));
|
||||
-
|
||||
- let _ = fs::rmdir_recursive(&dst.join("include"));
|
||||
- let _ = fs::rmdir_recursive(&dst.join("lib"));
|
||||
- let _ = fs::rmdir_recursive(&dst.join("build"));
|
||||
- fs::mkdir(&dst.join("build"), old_io::USER_DIR).unwrap();
|
||||
-
|
||||
- let root = src.join("libssh2-1.4.4-20140901");
|
||||
- // Can't run ./configure directly on msys2 b/c we're handing in
|
||||
- // Windows-style paths (those starting with C:\), but it chokes on those.
|
||||
- // For that reason we build up a shell script with paths converted to
|
||||
- // posix versions hopefully...
|
||||
- //
|
||||
- // Also apparently the buildbots choke unless we manually set LD, who knows
|
||||
- // why?!
|
||||
- run(Command::new("sh")
|
||||
- .env("CFLAGS", cflags)
|
||||
- .env("LD", which("ld").unwrap())
|
||||
- .cwd(&dst.join("build"))
|
||||
- .arg("-c")
|
||||
- .arg(format!("{} {}", root.join("configure").display(),
|
||||
- config_opts.connect(" "))
|
||||
- .replace("C:\\", "/c/")
|
||||
- .replace("\\", "/")));
|
||||
- run(Command::new(make())
|
||||
- .arg(format!("-j{}", env::var("NUM_JOBS").unwrap()))
|
||||
- .cwd(&dst.join("build/src")));
|
||||
-
|
||||
- // Don't run `make install` because apparently it's a little buggy on mingw
|
||||
- // for windows.
|
||||
- fs::mkdir_recursive(&dst.join("lib/pkgconfig"), old_io::USER_DIR).unwrap();
|
||||
-
|
||||
- // Which one does windows generate? Who knows!
|
||||
- let p1 = dst.join("build/src/.libs/libssh2.a");
|
||||
- let p2 = dst.join("build/src/.libs/libssh2.lib");
|
||||
- if p1.exists() {
|
||||
- fs::rename(&p1, &dst.join("lib/libssh2.a")).unwrap();
|
||||
- } else {
|
||||
- fs::rename(&p2, &dst.join("lib/libssh2.a")).unwrap();
|
||||
- }
|
||||
- fs::rename(&dst.join("build/libssh2.pc"),
|
||||
- &dst.join("lib/pkgconfig/libssh2.pc")).unwrap();
|
||||
-
|
||||
- {
|
||||
- let root = root.join("include");
|
||||
- let dst = dst.join("include");
|
||||
- for file in fs::walk_dir(&root).unwrap() {
|
||||
- if fs::stat(&file).unwrap().kind != old_io::FileType::RegularFile { continue }
|
||||
-
|
||||
- let part = file.path_relative_from(&root).unwrap();
|
||||
- let dst = dst.join(part);
|
||||
- fs::mkdir_recursive(&dst.dir_path(), old_io::USER_DIR).unwrap();
|
||||
- fs::copy(&file, &dst).unwrap();
|
||||
- }
|
||||
- }
|
||||
-
|
||||
- if windows {
|
||||
- println!("cargo:rustc-flags=-l ws2_32 -l bcrypt -l crypt32");
|
||||
- }
|
||||
- println!("cargo:rustc-flags=-L {}/lib -l ssh2:static", dst.display());
|
||||
- println!("cargo:root={}", dst.display());
|
||||
- println!("cargo:include={}/include", dst.display());
|
||||
-}
|
||||
-
|
||||
-fn make() -> &'static str {
|
||||
- if cfg!(target_os = "freebsd") {"gmake"} else {"make"}
|
||||
-}
|
||||
-
|
||||
-fn run(cmd: &mut Command) {
|
||||
- println!("running: {:?}", cmd);
|
||||
- assert!(cmd.stdout(InheritFd(1))
|
||||
- .stderr(InheritFd(2))
|
||||
- .status()
|
||||
- .unwrap()
|
||||
- .success());
|
||||
-
|
||||
-}
|
||||
-
|
||||
-fn which(cmd: &str) -> Option<Path> {
|
||||
- let cmd = format!("{}{}", cmd, env::consts::EXE_SUFFIX);
|
||||
- env::split_paths(&env::var("PATH").unwrap()).map(|p| {
|
||||
- p.join(&cmd)
|
||||
- }).find(|p| p.exists())
|
||||
}
|
||||
--
|
||||
2.3.0
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
From 9c7368781c5ea57ee6dadd5e985f12a76fe74dc4 Mon Sep 17 00:00:00 2001
|
||||
From 9011cf63782130e0acc72b9f53878dc2d3ac3971 Mon Sep 17 00:00:00 2001
|
||||
From: Cody P Schafer <dev@codyps.com>
|
||||
Date: Wed, 26 Nov 2014 10:00:32 -0500
|
||||
Subject: [PATCH 01/11] libstd/io/process/Command: fully quote and escape the
|
||||
Subject: [PATCH 01/10] libstd/io/process/Command: fully quote and escape the
|
||||
command and all args
|
||||
|
||||
This makes the command (which may have trailing or leading white space
|
||||
@@ -15,18 +15,18 @@ shell.
|
||||
1 file changed, 28 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/src/libstd/old_io/process.rs b/src/libstd/old_io/process.rs
|
||||
index 195d33c..db0dd91 100644
|
||||
index c803cfb..e875435 100644
|
||||
--- a/src/libstd/old_io/process.rs
|
||||
+++ b/src/libstd/old_io/process.rs
|
||||
@@ -31,6 +31,7 @@ use sys::fs::FileDesc;
|
||||
@@ -30,6 +30,7 @@ use sync::mpsc::{channel, Receiver};
|
||||
use sys::fs::FileDesc;
|
||||
use sys::process::Process as ProcessImp;
|
||||
use sys;
|
||||
use thread::Thread;
|
||||
+use string::CowString;
|
||||
use thread;
|
||||
|
||||
#[cfg(windows)] use hash;
|
||||
#[cfg(windows)] use str;
|
||||
@@ -394,15 +395,39 @@ impl Command {
|
||||
@@ -406,15 +407,39 @@ impl Command {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,19 +1,19 @@
|
||||
From cc9dd9db3f96de835226c955d0ed979c68f85841 Mon Sep 17 00:00:00 2001
|
||||
From 26ddca33f8ef01680f74f81177017bc94a38a8cd Mon Sep 17 00:00:00 2001
|
||||
From: Cody P Schafer <dev@codyps.com>
|
||||
Date: Mon, 1 Dec 2014 15:50:13 -0500
|
||||
Subject: [PATCH 02/11] std/io/process: add Debug tests
|
||||
Subject: [PATCH 02/10] std/io/process: add Debug tests
|
||||
|
||||
---
|
||||
src/libstd/old_io/process.rs | 12 ++++++++++++
|
||||
1 file changed, 12 insertions(+)
|
||||
|
||||
diff --git a/src/libstd/old_io/process.rs b/src/libstd/old_io/process.rs
|
||||
index db0dd91..d715848 100644
|
||||
index e875435..0e7394d 100644
|
||||
--- a/src/libstd/old_io/process.rs
|
||||
+++ b/src/libstd/old_io/process.rs
|
||||
@@ -1254,4 +1254,16 @@ mod tests {
|
||||
let val = env.get(&EnvKey(CString::from_slice(b"PATH")));
|
||||
assert!(val.unwrap() == &CString::from_slice(b"bar"));
|
||||
@@ -1266,4 +1266,16 @@ mod tests {
|
||||
let val = env.get(&EnvKey(CString::new(b"PATH").unwrap()));
|
||||
assert!(val.unwrap() == &CString::new(b"bar").unwrap());
|
||||
}
|
||||
+
|
||||
+ fn check_debug<D : fmt::Debug>(c: D, v: &str) {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
From d4ce12b74f22143bfbd8060809cfdd3617cbee44 Mon Sep 17 00:00:00 2001
|
||||
From b7fe3ef0254ab2dc302d7e24a2033f58a52fe412 Mon Sep 17 00:00:00 2001
|
||||
From: Cody P Schafer <dev@codyps.com>
|
||||
Date: Sat, 15 Nov 2014 20:12:48 -0500
|
||||
Subject: [PATCH 03/11] platform.mk: avoid choking on i586
|
||||
Subject: [PATCH 03/10] platform.mk: avoid choking on i586
|
||||
|
||||
---
|
||||
mk/platform.mk | 4 +++-
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
From e48a1c3c2901d12f4870f897c940eb1bfb322053 Mon Sep 17 00:00:00 2001
|
||||
From 2aea9850a8bbeb51e3e0daed015843b00718bea1 Mon Sep 17 00:00:00 2001
|
||||
From: Cody P Schafer <dev@codyps.com>
|
||||
Date: Mon, 17 Nov 2014 16:14:15 -0500
|
||||
Subject: [PATCH 04/11] mk/rt/compiler_rt: pass LDFLAGS from
|
||||
Subject: [PATCH 04/10] mk/rt/compiler_rt: pass LDFLAGS from
|
||||
CFG_GCCISH_LINK_FLAGS
|
||||
|
||||
---
|
||||
@@ -9,10 +9,10 @@ Subject: [PATCH 04/11] mk/rt/compiler_rt: pass LDFLAGS from
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/mk/rt.mk b/mk/rt.mk
|
||||
index a8bbeb4..a8ac839 100644
|
||||
index 527485c..21280be 100644
|
||||
--- a/mk/rt.mk
|
||||
+++ b/mk/rt.mk
|
||||
@@ -232,6 +232,7 @@ $$(COMPRT_LIB_$(1)): $$(COMPRT_DEPS) $$(MKFILE_DEPS)
|
||||
@@ -230,6 +230,7 @@ $$(COMPRT_LIB_$(1)): $$(COMPRT_DEPS) $$(MKFILE_DEPS)
|
||||
AR="$$(AR_$(1))" \
|
||||
RANLIB="$$(AR_$(1)) s" \
|
||||
CFLAGS="$$(CFG_GCCISH_CFLAGS_$(1))" \
|
||||
|
||||
+13
-14
@@ -1,17 +1,17 @@
|
||||
From a598b496c1298b5a861a8cf7ce0d1ff14dc6dc64 Mon Sep 17 00:00:00 2001
|
||||
From 6f53a8bd370f1e9984c49736219193bac8f9d9e5 Mon Sep 17 00:00:00 2001
|
||||
From: Cody P Schafer <dev@codyps.com>
|
||||
Date: Tue, 18 Nov 2014 01:40:21 -0500
|
||||
Subject: [PATCH 05/11] Target: add default target.json path:
|
||||
Subject: [PATCH 05/10] Target: add default target.json path:
|
||||
$libdir/rust/targets
|
||||
|
||||
---
|
||||
src/librustc/session/config.rs | 6 +++---
|
||||
src/librustc/session/config.rs | 4 ++--
|
||||
src/librustc/session/mod.rs | 8 ++++++--
|
||||
src/librustc_back/target/mod.rs | 9 ++++++---
|
||||
3 files changed, 15 insertions(+), 8 deletions(-)
|
||||
3 files changed, 14 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/src/librustc/session/config.rs b/src/librustc/session/config.rs
|
||||
index 8340a49..2219b3c 100644
|
||||
index 93a25de..7897379 100644
|
||||
--- a/src/librustc/session/config.rs
|
||||
+++ b/src/librustc/session/config.rs
|
||||
@@ -633,12 +633,12 @@ pub fn build_configuration(sess: &Session) -> ast::CrateConfig {
|
||||
@@ -19,9 +19,8 @@ index 8340a49..2219b3c 100644
|
||||
}
|
||||
|
||||
-pub fn build_target_config(opts: &Options, sp: &SpanHandler) -> Config {
|
||||
- let target = match Target::search(&opts.target_triple[]) {
|
||||
+pub fn build_target_config(sysroot: &std::old_io::Path, opts: &Options, sp: &SpanHandler) -> Config {
|
||||
+ let target = match Target::search(sysroot, &opts.target_triple[]) {
|
||||
+pub fn build_target_config(sysroot: &Path, opts: &Options, sp: &SpanHandler) -> Config {
|
||||
let target = match Target::search(&opts.target_triple[]) {
|
||||
Ok(t) => t,
|
||||
Err(e) => {
|
||||
sp.handler().fatal(&format!("Error loading target specification: {}", e));
|
||||
@@ -31,7 +30,7 @@ index 8340a49..2219b3c 100644
|
||||
|
||||
let (int_type, uint_type) = match &target.target_pointer_width[] {
|
||||
diff --git a/src/librustc/session/mod.rs b/src/librustc/session/mod.rs
|
||||
index bd44dbe..cb7b709 100644
|
||||
index c1c5518..2de99e7 100644
|
||||
--- a/src/librustc/session/mod.rs
|
||||
+++ b/src/librustc/session/mod.rs
|
||||
@@ -328,14 +328,18 @@ pub fn build_session_(sopts: config::Options,
|
||||
@@ -56,10 +55,10 @@ index bd44dbe..cb7b709 100644
|
||||
let default_sysroot = match sopts.maybe_sysroot {
|
||||
Some(_) => None,
|
||||
diff --git a/src/librustc_back/target/mod.rs b/src/librustc_back/target/mod.rs
|
||||
index 4d90c49..ba8bf1e 100644
|
||||
index 01a5f0d..4f6a75b 100644
|
||||
--- a/src/librustc_back/target/mod.rs
|
||||
+++ b/src/librustc_back/target/mod.rs
|
||||
@@ -302,12 +302,13 @@ impl Target {
|
||||
@@ -306,12 +306,13 @@ impl Target {
|
||||
///
|
||||
/// The error string could come from any of the APIs called, including filesystem access and
|
||||
/// JSON decoding.
|
||||
@@ -74,9 +73,9 @@ index 4d90c49..ba8bf1e 100644
|
||||
|
||||
fn load_file(path: &Path) -> Result<Target, String> {
|
||||
let mut f = try!(File::open(path).map_err(|e| format!("{:?}", e)));
|
||||
@@ -387,9 +388,11 @@ impl Target {
|
||||
let target_path = env::var_os("RUST_TARGET_PATH")
|
||||
.unwrap_or(OsString::from_str(""));
|
||||
@@ -391,9 +392,11 @@ impl Target {
|
||||
|
||||
let target_path = env::var_os("RUST_TARGET_PATH").unwrap_or(OsString::from_str(""));
|
||||
|
||||
- // FIXME 16351: add a sane default search path?
|
||||
+ let paths = env::split_paths(&target_path)
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
From 213c2b7d572eb399756de786b531c6d45d683416 Mon Sep 17 00:00:00 2001
|
||||
From e34ddb7a1201fc552b6ed5f344b320518325d545 Mon Sep 17 00:00:00 2001
|
||||
From: Cody P Schafer <dev@codyps.com>
|
||||
Date: Tue, 18 Nov 2014 14:52:56 -0500
|
||||
Subject: [PATCH 06/11] mk: for stage0, use RUSTFLAGS to override target libs
|
||||
Subject: [PATCH 06/10] mk: for stage0, use RUSTFLAGS to override target libs
|
||||
dir
|
||||
|
||||
Setting HLIB specially for stage0 (and even more specially for windows)
|
||||
@@ -13,10 +13,10 @@ stage0-rustc at the appropriate location.
|
||||
1 file changed, 11 insertions(+), 8 deletions(-)
|
||||
|
||||
diff --git a/mk/main.mk b/mk/main.mk
|
||||
index a6b201a..ab75a47 100644
|
||||
index 9752ee2..8f09d7c 100644
|
||||
--- a/mk/main.mk
|
||||
+++ b/mk/main.mk
|
||||
@@ -357,21 +357,22 @@ define SREQ
|
||||
@@ -361,21 +361,22 @@ define SREQ
|
||||
# Destinations of artifacts for the host compiler
|
||||
HROOT$(1)_H_$(3) = $(3)/stage$(1)
|
||||
HBIN$(1)_H_$(3) = $$(HROOT$(1)_H_$(3))/bin
|
||||
@@ -47,7 +47,7 @@ index a6b201a..ab75a47 100644
|
||||
# Preqrequisites for using the stageN compiler
|
||||
ifeq ($(1),0)
|
||||
HSREQ$(1)_H_$(3) = $$(HBIN$(1)_H_$(3))/rustc$$(X_$(3))
|
||||
@@ -483,6 +484,7 @@ STAGE$(1)_T_$(2)_H_$(3) := \
|
||||
@@ -487,6 +488,7 @@ STAGE$(1)_T_$(2)_H_$(3) := \
|
||||
$$(HBIN$(1)_H_$(3))/rustc$$(X_$(3)) \
|
||||
--cfg $$(CFGFLAG$(1)_T_$(2)_H_$(3)) \
|
||||
$$(CFG_RUSTC_FLAGS) $$(EXTRAFLAGS_STAGE$(1)) --target=$(2)) \
|
||||
@@ -55,7 +55,7 @@ index a6b201a..ab75a47 100644
|
||||
$$(RUSTC_FLAGS_$(2))
|
||||
|
||||
PERF_STAGE$(1)_T_$(2)_H_$(3) := \
|
||||
@@ -491,6 +493,7 @@ PERF_STAGE$(1)_T_$(2)_H_$(3) := \
|
||||
@@ -495,6 +497,7 @@ PERF_STAGE$(1)_T_$(2)_H_$(3) := \
|
||||
$$(HBIN$(1)_H_$(3))/rustc$$(X_$(3)) \
|
||||
--cfg $$(CFGFLAG$(1)_T_$(2)_H_$(3)) \
|
||||
$$(CFG_RUSTC_FLAGS) $$(EXTRAFLAGS_STAGE$(1)) --target=$(2)) \
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
From ab3ace1fda3abb216d538b86b4110cd4a25e3b4f Mon Sep 17 00:00:00 2001
|
||||
From 0788fd7a54cc24aad08959230dab460eaa4429e8 Mon Sep 17 00:00:00 2001
|
||||
From: Cody P Schafer <dev@codyps.com>
|
||||
Date: Tue, 18 Nov 2014 13:48:14 -0500
|
||||
Subject: [PATCH 07/11] mk: add missing CFG_LIBDIR_RELATIVE
|
||||
Subject: [PATCH 07/10] mk: add missing CFG_LIBDIR_RELATIVE
|
||||
|
||||
---
|
||||
mk/grammar.mk | 4 ++--
|
||||
|
||||
+14
-14
@@ -1,7 +1,7 @@
|
||||
From 9b5ca76506f84c1e8df5da39255d050969f225ec Mon Sep 17 00:00:00 2001
|
||||
From a6ad7db7efb8b3501e965a080be833933e11db85 Mon Sep 17 00:00:00 2001
|
||||
From: Cody P Schafer <dev@codyps.com>
|
||||
Date: Mon, 24 Nov 2014 13:10:15 -0500
|
||||
Subject: [PATCH 08/11] configure: support --bindir, and extend libdir to
|
||||
Subject: [PATCH 08/10] configure: support --bindir, and extend libdir to
|
||||
non-blessed dirs
|
||||
|
||||
Adds --bindir, and:
|
||||
@@ -24,7 +24,7 @@ windows platforms
|
||||
8 files changed, 87 insertions(+), 70 deletions(-)
|
||||
|
||||
diff --git a/configure b/configure
|
||||
index e6b8d23..1216964 100755
|
||||
index d1b27a9..b8a89f0 100755
|
||||
--- a/configure
|
||||
+++ b/configure
|
||||
@@ -309,6 +309,31 @@ envopt() {
|
||||
@@ -100,7 +100,7 @@ index e6b8d23..1216964 100755
|
||||
# Validate Options
|
||||
step_msg "validating $CFG_SELF args"
|
||||
validate_opt
|
||||
@@ -1343,6 +1365,7 @@ putvar CFG_PREFIX
|
||||
@@ -1344,6 +1366,7 @@ putvar CFG_PREFIX
|
||||
putvar CFG_HOST
|
||||
putvar CFG_TARGET
|
||||
putvar CFG_LIBDIR_RELATIVE
|
||||
@@ -128,10 +128,10 @@ index 59a0095..b8e8345 100644
|
||||
|
||||
endef
|
||||
diff --git a/mk/main.mk b/mk/main.mk
|
||||
index ab75a47..6659dc9 100644
|
||||
index 8f09d7c..0252e18 100644
|
||||
--- a/mk/main.mk
|
||||
+++ b/mk/main.mk
|
||||
@@ -326,7 +326,9 @@ export CFG_RELEASE_CHANNEL
|
||||
@@ -330,7 +330,9 @@ export CFG_RELEASE_CHANNEL
|
||||
export CFG_LLVM_ROOT
|
||||
export CFG_PREFIX
|
||||
export CFG_LIBDIR
|
||||
@@ -141,7 +141,7 @@ index ab75a47..6659dc9 100644
|
||||
export CFG_DISABLE_INJECT_STD_VERSION
|
||||
ifdef CFG_DISABLE_UNSTABLE_FEATURES
|
||||
CFG_INFO := $(info cfg: disabling unstable features (CFG_DISABLE_UNSTABLE_FEATURES))
|
||||
@@ -356,7 +358,16 @@ define SREQ
|
||||
@@ -360,7 +362,16 @@ define SREQ
|
||||
|
||||
# Destinations of artifacts for the host compiler
|
||||
HROOT$(1)_H_$(3) = $(3)/stage$(1)
|
||||
@@ -327,20 +327,20 @@ index 3caa0f5..39dafa2 100644
|
||||
|
||||
// The name of rustc's own place to organize libraries.
|
||||
diff --git a/src/librustc/session/config.rs b/src/librustc/session/config.rs
|
||||
index 2219b3c..20f2762 100644
|
||||
index 7897379..4b2ca89 100644
|
||||
--- a/src/librustc/session/config.rs
|
||||
+++ b/src/librustc/session/config.rs
|
||||
@@ -633,7 +633,7 @@ pub fn build_configuration(sess: &Session) -> ast::CrateConfig {
|
||||
v
|
||||
@@ -634,7 +634,7 @@ pub fn build_configuration(sess: &Session) -> ast::CrateConfig {
|
||||
}
|
||||
|
||||
-pub fn build_target_config(sysroot: &std::old_io::Path, opts: &Options, sp: &SpanHandler) -> Config {
|
||||
+pub fn build_target_config(sysroot: &Path, opts: &Options, sp: &SpanHandler) -> Config {
|
||||
let target = match Target::search(sysroot, &opts.target_triple[]) {
|
||||
pub fn build_target_config(sysroot: &Path, opts: &Options, sp: &SpanHandler) -> Config {
|
||||
- let target = match Target::search(&opts.target_triple[]) {
|
||||
+ let target = match Target::search(sysroot, &opts.target_triple[]) {
|
||||
Ok(t) => t,
|
||||
Err(e) => {
|
||||
sp.handler().fatal(&format!("Error loading target specification: {}", e));
|
||||
diff --git a/src/librustc_trans/back/link.rs b/src/librustc_trans/back/link.rs
|
||||
index 9f26e91..7f50224 100644
|
||||
index ef849bb..57cc5c9 100644
|
||||
--- a/src/librustc_trans/back/link.rs
|
||||
+++ b/src/librustc_trans/back/link.rs
|
||||
@@ -1004,11 +1004,10 @@ fn link_args(cmd: &mut Command,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
From 58cfcc79553014c3c335885f2bd141b1e564f9fb Mon Sep 17 00:00:00 2001
|
||||
From 80aecbad6306514ce20222e7c542f7f51468be0e Mon Sep 17 00:00:00 2001
|
||||
From: Cody P Schafer <dev@codyps.com>
|
||||
Date: Mon, 24 Nov 2014 13:54:42 -0500
|
||||
Subject: [PATCH 09/11] Parallelize submake invocations
|
||||
Subject: [PATCH 09/10] Parallelize submake invocations
|
||||
|
||||
---
|
||||
mk/clean.mk | 2 +-
|
||||
@@ -25,7 +25,7 @@ index 5b90d41..2a7ba6d 100644
|
||||
clean-llvm$(1): ;
|
||||
|
||||
diff --git a/mk/install.mk b/mk/install.mk
|
||||
index 60c0a6b..a3a44ed 100644
|
||||
index 8850cd7..8878cf5 100644
|
||||
--- a/mk/install.mk
|
||||
+++ b/mk/install.mk
|
||||
@@ -17,9 +17,9 @@ endif
|
||||
@@ -75,10 +75,10 @@ index ba2e073..3998806 100644
|
||||
touch $$@
|
||||
|
||||
diff --git a/mk/rt.mk b/mk/rt.mk
|
||||
index a8ac839..d609cd2 100644
|
||||
index 21280be..7f5af72 100644
|
||||
--- a/mk/rt.mk
|
||||
+++ b/mk/rt.mk
|
||||
@@ -183,7 +183,7 @@ $$(JEMALLOC_LOCAL_$(1)): $$(JEMALLOC_DEPS) $$(MKFILE_DEPS)
|
||||
@@ -181,7 +181,7 @@ $$(JEMALLOC_LOCAL_$(1)): $$(JEMALLOC_DEPS) $$(MKFILE_DEPS)
|
||||
RANLIB="$$(AR_$(1)) s" \
|
||||
CPPFLAGS="-I $(S)src/rt/" \
|
||||
EXTRA_CFLAGS="-g1 -ffunction-sections -fdata-sections"
|
||||
@@ -87,7 +87,7 @@ index a8ac839..d609cd2 100644
|
||||
|
||||
ifeq ($$(CFG_DISABLE_JEMALLOC),)
|
||||
RUSTFLAGS_alloc := --cfg jemalloc
|
||||
@@ -225,7 +225,7 @@ COMPRT_BUILD_DIR_$(1) := $$(RT_OUTPUT_DIR_$(1))/compiler-rt
|
||||
@@ -223,7 +223,7 @@ COMPRT_BUILD_DIR_$(1) := $$(RT_OUTPUT_DIR_$(1))/compiler-rt
|
||||
|
||||
$$(COMPRT_LIB_$(1)): $$(COMPRT_DEPS) $$(MKFILE_DEPS)
|
||||
@$$(call E, make: compiler-rt)
|
||||
@@ -96,7 +96,7 @@ index a8ac839..d609cd2 100644
|
||||
ProjSrcRoot="$(S)src/compiler-rt" \
|
||||
ProjObjRoot="$$(abspath $$(COMPRT_BUILD_DIR_$(1)))" \
|
||||
CC="$$(CC_$(1))" \
|
||||
@@ -303,7 +303,7 @@ $$(BACKTRACE_BUILD_DIR_$(1))/Makefile: $$(BACKTRACE_DEPS) $$(MKFILE_DEPS)
|
||||
@@ -301,7 +301,7 @@ $$(BACKTRACE_BUILD_DIR_$(1))/Makefile: $$(BACKTRACE_DEPS) $$(MKFILE_DEPS)
|
||||
|
||||
$$(BACKTRACE_LIB_$(1)): $$(BACKTRACE_BUILD_DIR_$(1))/Makefile $$(MKFILE_DEPS)
|
||||
@$$(call E, make: libbacktrace)
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
From d380a3383a12e59b8534d4d70c31e4c759fc3843 Mon Sep 17 00:00:00 2001
|
||||
From 2d7aabfa767ccb88b81a1260cd4b8f25ddf6eddc Mon Sep 17 00:00:00 2001
|
||||
From: Cody P Schafer <dev@codyps.com>
|
||||
Date: Wed, 3 Dec 2014 19:15:19 -0500
|
||||
Subject: [PATCH 10/11] std/thread_local: workaround for NULL __dso_handle
|
||||
Subject: [PATCH 10/10] std/thread_local: workaround for NULL __dso_handle
|
||||
|
||||
---
|
||||
src/libstd/thread_local/mod.rs | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/libstd/thread_local/mod.rs b/src/libstd/thread_local/mod.rs
|
||||
index eab9cd8..cc5cefc 100644
|
||||
index 2ed296e..c9beb04 100644
|
||||
--- a/src/libstd/thread_local/mod.rs
|
||||
+++ b/src/libstd/thread_local/mod.rs
|
||||
@@ -397,7 +397,7 @@ mod imp {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
# 2014-02-12
|
||||
SRCREV = "cf636c233dfeef5abf0de8fb35e23c0a161810d2"
|
||||
# 2015-02-21
|
||||
SRCREV = "2b01a37ec38db9301239f0c0abcf3c695055b0ff"
|
||||
require rust-git.inc
|
||||
|
||||
SRC_URI_append = "\
|
||||
@@ -13,5 +13,4 @@ SRC_URI_append = "\
|
||||
file://0008-configure-support-bindir-and-extend-libdir-to-non-bl.patch \
|
||||
file://0009-Parallelize-submake-invocations.patch \
|
||||
file://0010-std-thread_local-workaround-for-NULL-__dso_handle.patch \
|
||||
file://0011-librustc_back-target-rename-json-field-from-target-w.patch \
|
||||
"
|
||||
|
||||
Reference in New Issue
Block a user