package/rust: bump to 1.40
authorPatrick Havelange <patrick.havelange@essensium.com>
Fri, 7 Feb 2020 18:08:28 +0000 (19:08 +0100)
committerThomas Petazzoni <thomas.petazzoni@bootlin.com>
Mon, 27 Jul 2020 11:31:00 +0000 (13:31 +0200)
- remove of the llvm workaround patch as it is integrated in this
  newer version.
- bump cargo-bin to 0.41 (corresponds to rust 1.40) and update
  licenses hashes.
- bump rust-bin to 1.40.

Signed-off-by: Patrick Havelange <patrick.havelange@essensium.com>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Reviewed-by: David Pierret <david.pierret@smile.fr>
Tested-by: David Pierret <david.pierret@smile.fr>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
package/cargo-bin/cargo-bin.hash
package/cargo-bin/cargo-bin.mk
package/rust-bin/rust-bin.hash
package/rust-bin/rust-bin.mk
package/rust/0001-Workaround-presence-of-LLVM-library-in-stage0-lib.patch [deleted file]
package/rust/rust.hash
package/rust/rust.mk

index 0e9e9c5c616204989fbd4aa39b251cfed44ecfca..22cad3c0ee7be10ec6c5a155b935d0e8530beee6 100644 (file)
@@ -1,13 +1,13 @@
-# From https://static.rust-lang.org/dist/cargo-0.33.0-i686-unknown-linux-gnu.tar.xz.sha256
-# Verified using https://static.rust-lang.org/dist/cargo-0.33.0-i686-unknown-linux-gnu.tar.xz.asc
-sha256 13acdb3c9f2505805ceed8a696f5f62ab8cd73e443cd43d6edd588aad88e1c32  cargo-0.33.0-i686-unknown-linux-gnu.tar.xz
-# From https://static.rust-lang.org/dist/cargo-0.33.0-powerpc64le-unknown-linux-gnu.tar.xz.sha256
-# Verified using https://static.rust-lang.org/dist/cargo-0.33.0-powerpc64le-unknown-linux-gnu.tar.xz.asc
-sha256 6628db22370f397676195555d768f0449a60f0a694bcac24611f4cd1cfc97cdc  cargo-0.33.0-powerpc64le-unknown-linux-gnu.tar.xz
-# From https://static.rust-lang.org/dist/cargo-0.33.0-x86_64-unknown-linux-gnu.tar.xz.sha256
-# Verified using https://static.rust-lang.org/dist/cargo-0.33.0-x86_64-unknown-linux-gnu.tar.xz.asc
-sha256 c2c31db68c4dcb50ad856a19e6f11489a0d4df1212f31bd068dfbb73c5425761  cargo-0.33.0-x86_64-unknown-linux-gnu.tar.xz
+# From https://static.rust-lang.org/dist/cargo-0.41.0-i686-unknown-linux-gnu.tar.xz.sha256
+# Verified using https://static.rust-lang.org/dist/cargo-0.41.0-i686-unknown-linux-gnu.tar.xz.asc
+sha256 c48bc132f4025ff39b1b6dc52aef9d406c3f926ce05fe92d943ceab7a5fd6058  cargo-0.41.0-i686-unknown-linux-gnu.tar.xz
+# From https://static.rust-lang.org/dist/cargo-0.41.0-powerpc64le-unknown-linux-gnu.tar.xz.sha256
+# Verified using https://static.rust-lang.org/dist/cargo-0.41.0-powerpc64le-unknown-linux-gnu.tar.xz.asc
+sha256 7705f21d938a72ba6f01818661b2dea29183209940a335f18d1761e1e03d3710  cargo-0.41.0-powerpc64le-unknown-linux-gnu.tar.xz
+# From https://static.rust-lang.org/dist/cargo-0.41.0-x86_64-unknown-linux-gnu.tar.xz.sha256
+# Verified using https://static.rust-lang.org/dist/cargo-0.41.0-x86_64-unknown-linux-gnu.tar.xz.asc
+sha256 9b6ae643fa240c5ecbc1dc390f4020b6a683f25bac6f7437ebd4b9d32a8d0b6c  cargo-0.41.0-x86_64-unknown-linux-gnu.tar.xz
 # Locally generated
-sha256 a60eea817514531668d7e00765731449fe14d059d3249e0bc93b36de45f759f2  LICENSE-APACHE
+sha256 8ada45cd9f843acf64e4722ae262c622a2b3b3007c7310ef36ac1061a30f6adb  LICENSE-APACHE
 sha256 23f18e03dc49df91622fe2a76176497404e46ced8a715d9d2b67a7446571cca3  LICENSE-MIT
-sha256 8bd89f9222dc80292f4107347103b693ac66f3a083371f0629ccf42338abe880  LICENSE-THIRD-PARTY
+sha256 cbc759b1f17a2ac38fe3eb9e9563b1a08ba0f900611c49faaf68b46907b6d898  LICENSE-THIRD-PARTY
index 3eaf417531091d26dbd2ba2081a062d7444c410d..246fdbf856f63e15750974b8ca95baddc795dcdd 100644 (file)
@@ -4,7 +4,7 @@
 #
 ################################################################################
 
-CARGO_BIN_VERSION = 0.33.0
+CARGO_BIN_VERSION = 0.41.0
 CARGO_BIN_SITE = https://static.rust-lang.org/dist
 CARGO_BIN_SOURCE = cargo-$(CARGO_BIN_VERSION)-$(RUSTC_HOST_NAME).tar.xz
 CARGO_BIN_LICENSE = Apache-2.0 or MIT
index 96d81a347c062ea7a051df589371347914371667..12195f29117b0bd78c0030879d8388e8e6475bce 100644 (file)
@@ -1,48 +1,48 @@
-# From https://static.rust-lang.org/dist/rustc-1.33.0-i686-unknown-linux-gnu.tar.xz.sha256
-# Verified using https://static.rust-lang.org/dist/rustc-1.33.0-i686-unknown-linux-gnu.tar.xz.asc
-sha256 90b6414eddbce4a245cdcaea8353d3a637ef565d2bd119e25a6c2bf3e38cdf63  rustc-1.33.0-i686-unknown-linux-gnu.tar.xz
-# From https://static.rust-lang.org/dist/rustc-1.33.0-x86_64-unknown-linux-gnu.tar.xz.sha256
-# Verified using https://static.rust-lang.org/dist/rustc-1.33.0-x86_64-unknown-linux-gnu.tar.xz.asc
-sha256 57c5ced1a826d34f26e50adf041528dd0000f2a59e8be32d2359386843382ce1  rustc-1.33.0-x86_64-unknown-linux-gnu.tar.xz
-# From https://static.rust-lang.org/dist/rust-std-1.33.0-aarch64-unknown-linux-gnu.tar.xz.sha256
-# Verified using https://static.rust-lang.org/dist/rust-std-1.33.0-aarch64-unknown-linux-gnu.tar.xz.asc
-sha256 3e3449dada8306b3ff91f23c7803c7312a47e93af140f757b29b74f1e226a505  rust-std-1.33.0-aarch64-unknown-linux-gnu.tar.xz
-# From https://static.rust-lang.org/dist/rust-std-1.33.0-arm-unknown-linux-gnueabi.tar.xz.sha256
-# Verified using https://static.rust-lang.org/dist/rust-std-1.33.0-arm-unknown-linux-gnueabi.tar.xz.asc
-sha256 ddb372a43fb2ba9949e78643df43d6ae447b70cefd440ccdd6b9f6c2ff929ea7  rust-std-1.33.0-arm-unknown-linux-gnueabi.tar.xz
-# From https://static.rust-lang.org/dist/rust-std-1.33.0-arm-unknown-linux-gnueabihf.tar.xz.sha256
-# Verified using https://static.rust-lang.org/dist/rust-std-1.33.0-arm-unknown-linux-gnueabihf.tar.xz.asc
-sha256 1142d5064d8cbfab16ab71130e5a84804a1ebdfeb10173e6238adc0d757937b6  rust-std-1.33.0-arm-unknown-linux-gnueabihf.tar.xz
-# From https://static.rust-lang.org/dist/rust-std-1.33.0-armv7-unknown-linux-gnueabihf.tar.xz.sha256
-# Verified using https://static.rust-lang.org/dist/rust-std-1.33.0-armv7-unknown-linux-gnueabihf.tar.xz.asc
-sha256 8492b5c91a9ea7ee7e22881382c1b9ad8bb9a4147aff0dfee09940b34783e3d5  rust-std-1.33.0-armv7-unknown-linux-gnueabihf.tar.xz
-# From https://static.rust-lang.org/dist/rust-std-1.33.0-i686-unknown-linux-gnu.tar.xz.sha256
-# Verified using https://static.rust-lang.org/dist/rust-std-1.33.0-i686-unknown-linux-gnu.tar.xz.asc
-sha256 e945dd37ab9b143dbcbcdbeaba63b8de47411a4ff815d2e178f745e183078127  rust-std-1.33.0-i686-unknown-linux-gnu.tar.xz
-# From https://static.rust-lang.org/dist/rust-std-1.33.0-mips-unknown-linux-gnu.tar.xz.sha256
-# Verified using https://static.rust-lang.org/dist/rust-std-1.33.0-mips-unknown-linux-gnu.tar.xz.asc
-sha256 abf6b7050c1cdef092ecfde5128067434bb7989def19cfe95c06bfd71de07ba0  rust-std-1.33.0-mips-unknown-linux-gnu.tar.xz
-# From https://static.rust-lang.org/dist/rust-std-1.33.0-mips64-unknown-linux-gnuabi64.tar.xz.sha256
-# Verified using https://static.rust-lang.org/dist/rust-std-1.33.0-mips64-unknown-linux-gnuabi64.tar.xz.asc
-sha256 9cad816c989c991ffd342d03956b54209d7d32743ebb9b0624b2d36d5bbd525f  rust-std-1.33.0-mips64-unknown-linux-gnuabi64.tar.xz
-# From https://static.rust-lang.org/dist/rust-std-1.33.0-mips64el-unknown-linux-gnuabi64.tar.xz.sha256
-# Verified using https://static.rust-lang.org/dist/rust-std-1.33.0-mips64el-unknown-linux-gnuabi64.tar.xz.asc
-sha256 c7ac98e7a7c3757b5bb8bde596455d50a8787236e290bc1f49e2d59d486ae564  rust-std-1.33.0-mips64el-unknown-linux-gnuabi64.tar.xz
-# From https://static.rust-lang.org/dist/rust-std-1.33.0-mipsel-unknown-linux-gnu.tar.xz.sha256
-# Verified using https://static.rust-lang.org/dist/rust-std-1.33.0-mipsel-unknown-linux-gnu.tar.xz.asc
-sha256 4ec3cade12e2e527f81d0b315e6a37152bf73938aab4a9216aef7d06ef913eb6  rust-std-1.33.0-mipsel-unknown-linux-gnu.tar.xz
-# From https://static.rust-lang.org/dist/rust-std-1.33.0-powerpc-unknown-linux-gnu.tar.xz.sha256
-# Verified using https://static.rust-lang.org/dist/rust-std-1.33.0-powerpc-unknown-linux-gnu.tar.xz.asc
-sha256 0ab78e0cb710f35d108abce90bbf426947fed6222d2f6c04c9eba4ca00adea06  rust-std-1.33.0-powerpc-unknown-linux-gnu.tar.xz
-# From https://static.rust-lang.org/dist/rust-std-1.33.0-powerpc64-unknown-linux-gnu.tar.xz.sha256
-# Verified using https://static.rust-lang.org/dist/rust-std-1.33.0-powerpc64-unknown-linux-gnu.tar.xz.asc
-sha256 4bc32bf4660a9fc5cd2af9e09f1bfb668b335442097fed6f3892b50950e97d3c  rust-std-1.33.0-powerpc64-unknown-linux-gnu.tar.xz
-# From https://static.rust-lang.org/dist/rust-std-1.33.0-powerpc64le-unknown-linux-gnu.tar.xz.sha256
-# Verified using https://static.rust-lang.org/dist/rust-std-1.33.0-powerpc64le-unknown-linux-gnu.tar.xz.asc
-sha256 984d3ca2a47db04345a2bddd657761f66d209ef95a02097ad4bd549f45a0dc9f  rust-std-1.33.0-powerpc64le-unknown-linux-gnu.tar.xz
-# From https://static.rust-lang.org/dist/rust-std-1.33.0-x86_64-unknown-linux-gnu.tar.xz.sha256
-# Verified using https://static.rust-lang.org/dist/rust-std-1.33.0-x86_64-unknown-linux-gnu.tar.xz.asc
-sha256 6f20343ed73faf5fdfc423bec38a9bb1910a0a962af6f2dddd7184407543ed0e  rust-std-1.33.0-x86_64-unknown-linux-gnu.tar.xz
+# From https://static.rust-lang.org/dist/rustc-1.40.0-i686-unknown-linux-gnu.tar.xz.sha256
+# Verified using https://static.rust-lang.org/dist/rustc-1.40.0-i686-unknown-linux-gnu.tar.xz.asc
+sha256 257e4789043098a5e3b4fa85ea988019f37d640a10f83d39ada00fb23e057b8a  rustc-1.40.0-i686-unknown-linux-gnu.tar.xz
+# From https://static.rust-lang.org/dist/rustc-1.40.0-x86_64-unknown-linux-gnu.tar.xz.sha256
+# Verified using https://static.rust-lang.org/dist/rustc-1.40.0-x86_64-unknown-linux-gnu.tar.xz.asc
+sha256 b1c00618b7a98156e88b14682508a503284f85748eab23de749a20dcc8847111  rustc-1.40.0-x86_64-unknown-linux-gnu.tar.xz
+# From https://static.rust-lang.org/dist/rust-std-1.40.0-aarch64-unknown-linux-gnu.tar.xz.sha256
+# Verified using https://static.rust-lang.org/dist/rust-std-1.40.0-aarch64-unknown-linux-gnu.tar.xz.asc
+sha256 1abd1865e8339c2cac6992a11f6f98b66fa2b97f67acaddcf1992e39a7001bfc  rust-std-1.40.0-aarch64-unknown-linux-gnu.tar.xz
+# From https://static.rust-lang.org/dist/rust-std-1.40.0-arm-unknown-linux-gnueabi.tar.xz.sha256
+# Verified using https://static.rust-lang.org/dist/rust-std-1.40.0-arm-unknown-linux-gnueabi.tar.xz.asc
+sha256 14bd261dfc586dc8e1cb336b3c58b63de2af4881c970dd9b1e87f1364a866bcb  rust-std-1.40.0-arm-unknown-linux-gnueabi.tar.xz
+# From https://static.rust-lang.org/dist/rust-std-1.40.0-arm-unknown-linux-gnueabihf.tar.xz.sha256
+# Verified using https://static.rust-lang.org/dist/rust-std-1.40.0-arm-unknown-linux-gnueabihf.tar.xz.asc
+sha256 f16b2cf9103127140f85d21c2753d85d45b90a9309967e3a788867fd7d95a6c1  rust-std-1.40.0-arm-unknown-linux-gnueabihf.tar.xz
+# From https://static.rust-lang.org/dist/rust-std-1.40.0-armv7-unknown-linux-gnueabihf.tar.xz.sha256
+# Verified using https://static.rust-lang.org/dist/rust-std-1.40.0-armv7-unknown-linux-gnueabihf.tar.xz.asc
+sha256 9d4aad78db894a76e9682f2095ac024cc4748b2933f9f7248bf571923f7693c4  rust-std-1.40.0-armv7-unknown-linux-gnueabihf.tar.xz
+# From https://static.rust-lang.org/dist/rust-std-1.40.0-i686-unknown-linux-gnu.tar.xz.sha256
+# Verified using https://static.rust-lang.org/dist/rust-std-1.40.0-i686-unknown-linux-gnu.tar.xz.asc
+sha256 beab29565d12a6b9db4ef471c34d4c034295760095f7edc3f7b6c51fc08589a0  rust-std-1.40.0-i686-unknown-linux-gnu.tar.xz
+# From https://static.rust-lang.org/dist/rust-std-1.40.0-mips-unknown-linux-gnu.tar.xz.sha256
+# Verified using https://static.rust-lang.org/dist/rust-std-1.40.0-mips-unknown-linux-gnu.tar.xz.asc
+sha256 c25790d43e0a01e5f45607b067b22ae96163d5eae877cee1b2b35ce0d43ab9b5  rust-std-1.40.0-mips-unknown-linux-gnu.tar.xz
+# From https://static.rust-lang.org/dist/rust-std-1.40.0-mips64-unknown-linux-gnuabi64.tar.xz.sha256
+# Verified using https://static.rust-lang.org/dist/rust-std-1.40.0-mips64-unknown-linux-gnuabi64.tar.xz.asc
+sha256 7000ab95cd64f177af831d8880b9a5d7b5a23e5a18b9e9adab32bf90859bfa4e  rust-std-1.40.0-mips64-unknown-linux-gnuabi64.tar.xz
+# From https://static.rust-lang.org/dist/rust-std-1.40.0-mips64el-unknown-linux-gnuabi64.tar.xz.sha256
+# Verified using https://static.rust-lang.org/dist/rust-std-1.40.0-mips64el-unknown-linux-gnuabi64.tar.xz.asc
+sha256 9a4cfebee845dfd50f0f10c3019b89af3747c3aed1a797042285f3cea5a3eb30  rust-std-1.40.0-mips64el-unknown-linux-gnuabi64.tar.xz
+# From https://static.rust-lang.org/dist/rust-std-1.40.0-mipsel-unknown-linux-gnu.tar.xz.sha256
+# Verified using https://static.rust-lang.org/dist/rust-std-1.40.0-mipsel-unknown-linux-gnu.tar.xz.asc
+sha256 ab738a37c1cac1aaec7cb34556fa9bfff46dc912baf360a27e9d81311120ec4a  rust-std-1.40.0-mipsel-unknown-linux-gnu.tar.xz
+# From https://static.rust-lang.org/dist/rust-std-1.40.0-powerpc-unknown-linux-gnu.tar.xz.sha256
+# Verified using https://static.rust-lang.org/dist/rust-std-1.40.0-powerpc-unknown-linux-gnu.tar.xz.asc
+sha256 5c29b326d4d564c9fa9b82292890f47794496d3cedf106f83f935189b7ecaca5  rust-std-1.40.0-powerpc-unknown-linux-gnu.tar.xz
+# From https://static.rust-lang.org/dist/rust-std-1.40.0-powerpc64-unknown-linux-gnu.tar.xz.sha256
+# Verified using https://static.rust-lang.org/dist/rust-std-1.40.0-powerpc64-unknown-linux-gnu.tar.xz.asc
+sha256 da7af341b3a01f684a2d9fea23f098816aa8a0f9588b58d25ec7f0622743b5b0  rust-std-1.40.0-powerpc64-unknown-linux-gnu.tar.xz
+# From https://static.rust-lang.org/dist/rust-std-1.40.0-powerpc64le-unknown-linux-gnu.tar.xz.sha256
+# Verified using https://static.rust-lang.org/dist/rust-std-1.40.0-powerpc64le-unknown-linux-gnu.tar.xz.asc
+sha256 4eb3141fb6c3d3e101b5d4493664c9a01d4bb9eebdf4b96f5c26a81188c2452d  rust-std-1.40.0-powerpc64le-unknown-linux-gnu.tar.xz
+# From https://static.rust-lang.org/dist/rust-std-1.40.0-x86_64-unknown-linux-gnu.tar.xz.sha256
+# Verified using https://static.rust-lang.org/dist/rust-std-1.40.0-x86_64-unknown-linux-gnu.tar.xz.asc
+sha256 5a0b14a51f51b0194f70a2023749d9cb49c3b2e11f0d4c8232960b91fad336ac  rust-std-1.40.0-x86_64-unknown-linux-gnu.tar.xz
 # Locally generated
 sha256 a60eea817514531668d7e00765731449fe14d059d3249e0bc93b36de45f759f2  LICENSE-APACHE
 sha256 23f18e03dc49df91622fe2a76176497404e46ced8a715d9d2b67a7446571cca3  LICENSE-MIT
index bef3102450c7c456b61c550876e63baaa72bea1d..a5966768a45e0149f203448577f19511fc2a3855 100644 (file)
@@ -4,7 +4,7 @@
 #
 ################################################################################
 
-RUST_BIN_VERSION = 1.33.0
+RUST_BIN_VERSION = 1.40.0
 RUST_BIN_SITE = https://static.rust-lang.org/dist
 RUST_BIN_LICENSE = Apache-2.0 or MIT
 RUST_BIN_LICENSE_FILES = LICENSE-APACHE LICENSE-MIT
diff --git a/package/rust/0001-Workaround-presence-of-LLVM-library-in-stage0-lib.patch b/package/rust/0001-Workaround-presence-of-LLVM-library-in-stage0-lib.patch
deleted file mode 100644 (file)
index 0c756e3..0000000
+++ /dev/null
@@ -1,264 +0,0 @@
-From 2d21df8a3fd7a68ba9f52389ead7f06f13190c12 Mon Sep 17 00:00:00 2001
-From: Mark Rousskov <mark.simulacrum@gmail.com>
-Date: Mon, 21 Jan 2019 17:47:57 -0700
-Subject: [PATCH] Workaround presence of LLVM library in stage0/lib
-
-This commit works around the newly-introduced LLVM shared library.
-
-This is needed such that llvm-config run from
-librustc_llvm's build script can correctly locate it's own LLVM, not the
-one in stage0/lib. The LLVM build system uses the DT_RUNPATH/RUNPATH
-header within the llvm-config binary, which we want to use, but because
-Cargo always adds the host compiler's "libdir" (stage0/lib in our
-case) to the dynamic linker's search path, we weren't properly finding
-the freshly-built LLVM in llvm/lib. By restoring the environment
-variable setting the search path to what bootstrap sees, the problem is
-resolved and librustc_llvm correctly links and finds the appropriate
-LLVM.
-
-Several run-make-fulldeps tests are also updated with similar handling.
-
-Signed-off-by: Eric Le Bihan <eric.le.bihan.dev@free.fr>
----
- src/bootstrap/builder.rs                      |  9 ++++++++-
- src/bootstrap/compile.rs                      |  1 +
- src/bootstrap/util.rs                         |  6 +++++-
- src/build_helper/lib.rs                       | 19 +++++++++++++++++++
- src/librustc_asan/build.rs                    |  2 ++
- src/librustc_llvm/build.rs                    |  2 ++
- src/librustc_lsan/build.rs                    |  2 ++
- src/librustc_msan/build.rs                    |  2 ++
- src/librustc_tsan/build.rs                    |  2 ++
- .../cross-lang-lto-upstream-rlibs/Makefile    |  4 ++--
- .../run-make-fulldeps/cross-lang-lto/Makefile | 19 ++++++++++---------
- 11 files changed, 55 insertions(+), 13 deletions(-)
-
-diff --git a/src/bootstrap/builder.rs b/src/bootstrap/builder.rs
-index a69ba20749..f742bce180 100644
---- a/src/bootstrap/builder.rs
-+++ b/src/bootstrap/builder.rs
-@@ -21,7 +21,7 @@ use crate::install;
- use crate::native;
- use crate::test;
- use crate::tool;
--use crate::util::{add_lib_path, exe, libdir};
-+use crate::util::{self, add_lib_path, exe, libdir};
- use crate::{Build, DocTests, Mode, GitRepo};
- pub use crate::Compiler;
-@@ -791,6 +791,13 @@ impl<'a> Builder<'a> {
-             .env("CARGO_TARGET_DIR", out_dir)
-             .arg(cmd);
-+        // See comment in librustc_llvm/build.rs for why this is necessary, largely llvm-config
-+        // needs to not accidentally link to libLLVM in stage0/lib.
-+        cargo.env("REAL_LIBRARY_PATH_VAR", &util::dylib_path_var());
-+        if let Some(e) = env::var_os(util::dylib_path_var()) {
-+            cargo.env("REAL_LIBRARY_PATH", e);
-+        }
-+
-         if cmd != "install" {
-             cargo.arg("--target")
-                  .arg(target);
-diff --git a/src/bootstrap/compile.rs b/src/bootstrap/compile.rs
-index b581271663..ec04dee6c3 100644
---- a/src/bootstrap/compile.rs
-+++ b/src/bootstrap/compile.rs
-@@ -712,6 +712,7 @@ pub fn build_codegen_backend(builder: &Builder,
-             if builder.is_rust_llvm(target) && backend != "emscripten" {
-                 cargo.env("LLVM_RUSTLLVM", "1");
-             }
-+
-             cargo.env("LLVM_CONFIG", &llvm_config);
-             if backend != "emscripten" {
-                 let target_config = builder.config.target_config.get(&target);
-diff --git a/src/bootstrap/util.rs b/src/bootstrap/util.rs
-index 2880f1a084..37c6c040da 100644
---- a/src/bootstrap/util.rs
-+++ b/src/bootstrap/util.rs
-@@ -70,7 +70,11 @@ pub fn dylib_path_var() -> &'static str {
- /// Parses the `dylib_path_var()` environment variable, returning a list of
- /// paths that are members of this lookup path.
- pub fn dylib_path() -> Vec<PathBuf> {
--    env::split_paths(&env::var_os(dylib_path_var()).unwrap_or_default()).collect()
-+    let var = match env::var_os(dylib_path_var()) {
-+        Some(v) => v,
-+        None => return vec![],
-+    };
-+    env::split_paths(&var).collect()
- }
- /// `push` all components to `buf`. On windows, append `.exe` to the last component.
-diff --git a/src/build_helper/lib.rs b/src/build_helper/lib.rs
-index 5a704e5577..c66c5c9249 100644
---- a/src/build_helper/lib.rs
-+++ b/src/build_helper/lib.rs
-@@ -23,6 +23,25 @@ macro_rules! t {
-     };
- }
-+// Because Cargo adds the compiler's dylib path to our library search path, llvm-config may
-+// break: the dylib path for the compiler, as of this writing, contains a copy of the LLVM
-+// shared library, which means that when our freshly built llvm-config goes to load it's
-+// associated LLVM, it actually loads the compiler's LLVM. In particular when building the first
-+// compiler (i.e., in stage 0) that's a problem, as the compiler's LLVM is likely different from
-+// the one we want to use. As such, we restore the environment to what bootstrap saw. This isn't
-+// perfect -- we might actually want to see something from Cargo's added library paths -- but
-+// for now it works.
-+pub fn restore_library_path() {
-+    println!("cargo:rerun-if-env-changed=REAL_LIBRARY_PATH_VAR");
-+    println!("cargo:rerun-if-env-changed=REAL_LIBRARY_PATH");
-+    let key = env::var_os("REAL_LIBRARY_PATH_VAR").expect("REAL_LIBRARY_PATH_VAR");
-+    if let Some(env) = env::var_os("REAL_LIBRARY_PATH") {
-+        env::set_var(&key, &env);
-+    } else {
-+        env::remove_var(&key);
-+    }
-+}
-+
- pub fn run(cmd: &mut Command) {
-     println!("running: {:?}", cmd);
-     run_silent(cmd);
-diff --git a/src/librustc_asan/build.rs b/src/librustc_asan/build.rs
-index 2d921b6669..b42d775deb 100644
---- a/src/librustc_asan/build.rs
-+++ b/src/librustc_asan/build.rs
-@@ -8,6 +8,8 @@ use cmake::Config;
- fn main() {
-     if let Some(llvm_config) = env::var_os("LLVM_CONFIG") {
-+        build_helper::restore_library_path();
-+
-         let (native, target) = match sanitizer_lib_boilerplate("asan") {
-             Ok(native) => native,
-             _ => return,
-diff --git a/src/librustc_llvm/build.rs b/src/librustc_llvm/build.rs
-index ec3dff783c..cd91fcb299 100644
---- a/src/librustc_llvm/build.rs
-+++ b/src/librustc_llvm/build.rs
-@@ -24,6 +24,8 @@ fn main() {
-         return;
-     }
-+    build_helper::restore_library_path();
-+
-     let target = env::var("TARGET").expect("TARGET was not set");
-     let llvm_config = env::var_os("LLVM_CONFIG")
-         .map(PathBuf::from)
-diff --git a/src/librustc_lsan/build.rs b/src/librustc_lsan/build.rs
-index 470f2bb3e5..ad528bb039 100644
---- a/src/librustc_lsan/build.rs
-+++ b/src/librustc_lsan/build.rs
-@@ -8,6 +8,8 @@ use cmake::Config;
- fn main() {
-     if let Some(llvm_config) = env::var_os("LLVM_CONFIG") {
-+        build_helper::restore_library_path();
-+
-         let (native, target) = match sanitizer_lib_boilerplate("lsan") {
-             Ok(native) => native,
-             _ => return,
-diff --git a/src/librustc_msan/build.rs b/src/librustc_msan/build.rs
-index e1140278f2..085514b5a0 100644
---- a/src/librustc_msan/build.rs
-+++ b/src/librustc_msan/build.rs
-@@ -8,6 +8,8 @@ use cmake::Config;
- fn main() {
-     if let Some(llvm_config) = env::var_os("LLVM_CONFIG") {
-+        build_helper::restore_library_path();
-+
-         let (native, target) = match sanitizer_lib_boilerplate("msan") {
-             Ok(native) => native,
-             _ => return,
-diff --git a/src/librustc_tsan/build.rs b/src/librustc_tsan/build.rs
-index f63bb46b87..0db3db392d 100644
---- a/src/librustc_tsan/build.rs
-+++ b/src/librustc_tsan/build.rs
-@@ -8,6 +8,8 @@ use cmake::Config;
- fn main() {
-     if let Some(llvm_config) = env::var_os("LLVM_CONFIG") {
-+        build_helper::restore_library_path();
-+
-         let (native, target) = match sanitizer_lib_boilerplate("tsan") {
-             Ok(native) => native,
-             _ => return,
-diff --git a/src/test/run-make-fulldeps/cross-lang-lto-upstream-rlibs/Makefile b/src/test/run-make-fulldeps/cross-lang-lto-upstream-rlibs/Makefile
-index 0a6f226a02..6992dab1a1 100644
---- a/src/test/run-make-fulldeps/cross-lang-lto-upstream-rlibs/Makefile
-+++ b/src/test/run-make-fulldeps/cross-lang-lto-upstream-rlibs/Makefile
-@@ -9,7 +9,7 @@ all: staticlib.rs upstream.rs
-       # Check No LTO
-       $(RUSTC) staticlib.rs -Z cross-lang-lto -Ccodegen-units=1 -L. -o $(TMPDIR)/staticlib.a
--      (cd $(TMPDIR); llvm-ar x ./staticlib.a)
-+      (cd $(TMPDIR); $(LD_LIB_PATH_ENVVAR)=$(REAL_LD_LIBRARY_PATH) llvm-ar x ./staticlib.a)
-       # Make sure the upstream object file was included
-       ls $(TMPDIR)/upstream.*.rcgu.o
-@@ -19,5 +19,5 @@ all: staticlib.rs upstream.rs
-       # Check ThinLTO
-       $(RUSTC) upstream.rs -Z cross-lang-lto -Ccodegen-units=1 -Clto=thin
-       $(RUSTC) staticlib.rs -Z cross-lang-lto -Ccodegen-units=1 -Clto=thin -L. -o $(TMPDIR)/staticlib.a
--      (cd $(TMPDIR); llvm-ar x ./staticlib.a)
-+      (cd $(TMPDIR); $(LD_LIB_PATH_ENVVAR)=$(REAL_LD_LIBRARY_PATH) llvm-ar x ./staticlib.a)
-       ls $(TMPDIR)/upstream.*.rcgu.o
-diff --git a/src/test/run-make-fulldeps/cross-lang-lto/Makefile b/src/test/run-make-fulldeps/cross-lang-lto/Makefile
-index 1d072e03de..4d1fb7b953 100644
---- a/src/test/run-make-fulldeps/cross-lang-lto/Makefile
-+++ b/src/test/run-make-fulldeps/cross-lang-lto/Makefile
-@@ -5,8 +5,9 @@
- # LLVM bitcode files (as used by linker LTO plugins) when compiling with
- # -Z cross-lang-lto.
--ASSERT_IS_BITCODE_OBJ=llvm-bcanalyzer # this only succeeds for bitcode files
--EXTRACT_OBJS=(cd $(TMPDIR); rm -f ./*.o; llvm-ar x $(1))
-+# this only succeeds for bitcode files
-+ASSERT_IS_BITCODE_OBJ=($(LD_LIB_PATH_ENVVAR)=$(REAL_LD_LIBRARY_PATH) llvm-bcanalyzer $(1))
-+EXTRACT_OBJS=(cd $(TMPDIR); rm -f ./*.o; $(LD_LIB_PATH_ENVVAR)=$(REAL_LD_LIBRARY_PATH) llvm-ar x $(1))
- BUILD_LIB=$(RUSTC) lib.rs -Copt-level=2 -Z cross-lang-lto=on -Ccodegen-units=1
- BUILD_EXE=$(RUSTC) main.rs -Copt-level=2 -Z cross-lang-lto=on -Ccodegen-units=1 --emit=obj
-@@ -16,31 +17,31 @@ all: staticlib staticlib-fat-lto staticlib-thin-lto rlib exe cdylib rdylib
- staticlib: lib.rs
-       $(BUILD_LIB) --crate-type=staticlib -o $(TMPDIR)/liblib.a
-       $(call EXTRACT_OBJS, liblib.a)
--      for file in $(TMPDIR)/liblib.*.rcgu.o; do $(ASSERT_IS_BITCODE_OBJ) $$file; done
-+      for file in $(TMPDIR)/liblib.*.rcgu.o; do $(call ASSERT_IS_BITCODE_OBJ, $$file); done
- staticlib-fat-lto: lib.rs
-       $(BUILD_LIB) --crate-type=staticlib -o $(TMPDIR)/liblib-fat-lto.a -Clto=fat
-       $(call EXTRACT_OBJS, liblib-fat-lto.a)
--      for file in $(TMPDIR)/liblib-fat-lto.*.rcgu.o; do $(ASSERT_IS_BITCODE_OBJ) $$file; done
-+      for file in $(TMPDIR)/liblib-fat-lto.*.rcgu.o; do $(call ASSERT_IS_BITCODE_OBJ, $$file); done
- staticlib-thin-lto: lib.rs
-       $(BUILD_LIB) --crate-type=staticlib -o $(TMPDIR)/liblib-thin-lto.a -Clto=thin
-       $(call EXTRACT_OBJS, liblib-thin-lto.a)
--      for file in $(TMPDIR)/liblib-thin-lto.*.rcgu.o; do $(ASSERT_IS_BITCODE_OBJ) $$file; done
-+      for file in $(TMPDIR)/liblib-thin-lto.*.rcgu.o; do $(call ASSERT_IS_BITCODE_OBJ, $$file); done
- rlib: lib.rs
-       $(BUILD_LIB) --crate-type=rlib -o $(TMPDIR)/liblib.rlib
-       $(call EXTRACT_OBJS, liblib.rlib)
--      for file in $(TMPDIR)/liblib.*.rcgu.o; do $(ASSERT_IS_BITCODE_OBJ) $$file; done
-+      for file in $(TMPDIR)/liblib.*.rcgu.o; do $(call ASSERT_IS_BITCODE_OBJ, $$file); done
- cdylib: lib.rs
-       $(BUILD_LIB) --crate-type=cdylib --emit=obj -o $(TMPDIR)/cdylib.o
--      $(ASSERT_IS_BITCODE_OBJ) $(TMPDIR)/cdylib.o
-+      $(call ASSERT_IS_BITCODE_OBJ, $(TMPDIR)/cdylib.o)
- rdylib: lib.rs
-       $(BUILD_LIB) --crate-type=dylib --emit=obj -o $(TMPDIR)/rdylib.o
--      $(ASSERT_IS_BITCODE_OBJ) $(TMPDIR)/rdylib.o
-+      $(call ASSERT_IS_BITCODE_OBJ, $(TMPDIR)/rdylib.o)
- exe: lib.rs
-       $(BUILD_EXE) -o $(TMPDIR)/exe.o
--      $(ASSERT_IS_BITCODE_OBJ) $(TMPDIR)/exe.o
-+      $(call ASSERT_IS_BITCODE_OBJ, $(TMPDIR)/exe.o)
--- 
-2.17.2
-
index 62e2e1855ce4bc4f7d458bb9acaee7d6c2fceefb..67c537f670771aebf7cedbd0f1ed10fb4e91c4f1 100644 (file)
@@ -1,6 +1,6 @@
-# From https://static.rust-lang.org/dist/rustc-1.33.0-src.tar.xz.sha256
-# Verified using https://static.rust-lang.org/dist/rustc-1.33.0-src.tar.xz.asc
-sha256 f4b1a72f1a29b23dcc9d7be5f60878f0434560513273906aa93dcd5c0de39b71  rustc-1.33.0-src.tar.xz
+# From https://static.rust-lang.org/dist/rustc-1.40.0-src.tar.xz.sha256
+# Verified using https://static.rust-lang.org/dist/rustc-1.40.0-src.tar.xz.asc
+sha256 6e2aa3a91697f4b225c6b394cbae6b97666f061dba491f666a5281698fe2aace  rustc-1.40.0-src.tar.xz
 # Locally generated
 sha256 a60eea817514531668d7e00765731449fe14d059d3249e0bc93b36de45f759f2  LICENSE-APACHE
 sha256 23f18e03dc49df91622fe2a76176497404e46ced8a715d9d2b67a7446571cca3  LICENSE-MIT
index c05d912ffa453f9ef6fc047fa09142dc53ae5f0b..2f6a212e590cdba072a96d479499f7e659a40009 100644 (file)
@@ -4,7 +4,7 @@
 #
 ################################################################################
 
-RUST_VERSION = 1.33.0
+RUST_VERSION = 1.40.0
 RUST_SOURCE = rustc-$(RUST_VERSION)-src.tar.xz
 RUST_SITE = https://static.rust-lang.org/dist
 RUST_LICENSE = Apache-2.0 or MIT