Merge pull request #16920 from the-kenny/rust-1.10.0

rust: 1.9.0 -> 1.10.0
This commit is contained in:
Moritz Ulrich 2016-07-13 23:56:55 +02:00 committed by GitHub
commit c1bcfd7405
6 changed files with 19 additions and 123 deletions

View file

@ -50,7 +50,11 @@ rec {
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
"$out/bin/rustc"
wrapProgram "$out/bin/rustc"
# Do NOT, I repeat, DO NOT use `wrapProgram` on $out/bin/rustc
# (or similar) here. It causes strange effects where rustc loads
# the wrong libraries in a bootstrap-build causing failures that
# are very hard to track dow. For details, see
# https://github.com/rust-lang/rust/issues/34722#issuecomment-232164943
'';
};

View file

@ -3,30 +3,30 @@
let
rustPlatform = recurseIntoAttrs (makeRustPlatform (callPackage ./bootstrap.nix {}) rustPlatform);
rustSnapshotPlatform = recurseIntoAttrs (makeRustPlatform (callPackage ./snapshot.nix {}) rustPlatform);
in
rec {
rustc = callPackage ./rustc.nix {
shortVersion = "1.9.0";
shortVersion = "1.10.0";
isRelease = true;
forceBundledLLVM = false;
configureFlags = [ "--release-channel=stable" ];
srcRev = "e4e8b666850a763fdf1c3c2c142856ab51e32779";
srcSha = "1pz4qx70mqv78fxm4w1mq7csk5pssq4qmr2vwwb5v8hyx03caff8";
patches = [ ./patches/remove-uneeded-git.patch ]
++ stdenv.lib.optional stdenv.needsPax ./patches/grsec.patch;
srcRev = "cfcb716cf0961a7e3a4eceac828d94805cf8140b";
srcSha = "15i81ybh32xymmkyz3bkb5bdgi9hx8nb0sh00ac6qba6w8ljpii9";
patches = [
./patches/disable-lockfile-check.patch
] ++ stdenv.lib.optional stdenv.needsPax ./patches/grsec.patch;
inherit targets;
inherit targetPatches;
inherit targetToolchains;
rustPlatform = rustSnapshotPlatform;
inherit rustPlatform;
};
cargo = callPackage ./cargo.nix rec {
version = "0.10.0";
version = "0.11.0";
srcRev = "refs/tags/${version}";
srcSha = "06scvx5qh60mgvlpvri9ig4np2fsnicsfd452fi9w983dkxnz4l2";
depsSha256 = "0js4697n7v93wnqnpvamhp446w58llj66za5hkd6wannmc0gsy3b";
srcSha = "0ic2093bmwiw6vl2l9yhip87ni6dbz7dhrizy9wdx61229k16hc4";
depsSha256 = "0690sgn6fcay7sazlmrbbn4jbhnvmznrpz5z3rvkbaifkjrg4w6d";
inherit rustc; # the rustc that will be wrapped by cargo
inherit rustPlatform; # used to build cargo
};

View file

@ -1,19 +0,0 @@
diff --git a/src/etc/tidy.py b/src/etc/tidy.py
index 9f5f919..a607180 100644
--- a/src/etc/tidy.py
+++ b/src/etc/tidy.py
@@ -66,13 +66,9 @@ def interesting_file(f):
return any(os.path.splitext(f)[1] == ext for ext in interesting_files)
-# Be careful to support Python 2.4, 2.6, and 3.x here!
-config_proc = subprocess.Popen(["git", "config", "core.autocrlf"],
- stdout=subprocess.PIPE)
-result = config_proc.communicate()[0]
true = "true".encode('utf8')
-autocrlf = result.strip() == true if result is not None else False
+autocrlf = False
current_name = ""
current_contents = ""

View file

@ -1,25 +0,0 @@
From 2710f3c8ae142abe1720b3476cd1ca60cee0c077 Mon Sep 17 00:00:00 2001
From: David Craven <david@craven.ch>
Date: Wed, 1 Jun 2016 00:12:35 +0200
Subject: [PATCH] Patch stage0.txt to use rustc 1.9.0
---
src/stage0.txt | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/stage0.txt b/src/stage0.txt
index 58b7f8f..3c84cab 100644
--- a/src/stage0.txt
+++ b/src/stage0.txt
@@ -12,6 +12,6 @@
# tarball for a stable release you'll likely see `1.x.0-$date` where `1.x.0` was
# released on `$date`
-rustc: beta-2016-04-13
-rustc_key: c2743eb4
+rustc: 1.9.0-2016-05-24
+rustc_key: d16b8f0e
cargo: nightly-2016-04-10
--
2.8.3

View file

@ -1,65 +0,0 @@
/* NOTE: Rust 1.9.0 is the last version that uses snapshots
This file can be deleted after the 1.10.0 release and bootstrap.nix
can be used instead
*/
{ stdenv, fetchurl, callPackage }:
let
platform = if stdenv.system == "i686-linux"
then "linux-i386"
else if stdenv.system == "x86_64-linux"
then "linux-x86_64"
else if stdenv.system == "i686-darwin"
then "macos-i386"
else if stdenv.system == "x86_64-darwin"
then "macos-x86_64"
else abort "no snapshot to bootstrap for this platform (missing platform url suffix)";
/* Rust is bootstrapped from an earlier built version. We need
to fetch these earlier versions, which vary per platform.
The shapshot info you want can be found at
https://github.com/rust-lang/rust/blob/{$shortVersion}/src/snapshots.txt
with the set you want at the top. Make sure this is the latest snapshot
for the tagged release and not a snapshot in the current HEAD.
*/
snapshotHashLinux686 = "0e0e4448b80d0a12b75485795244bb3857a0a7ef";
snapshotHashLinux64 = "1273b6b6aed421c9e40c59f366d0df6092ec0397";
snapshotHashDarwin686 = "9f9c0b4a2db09acbce54b792fb8839a735585565";
snapshotHashDarwin64 = "52570f6fd915b0210a9be98cfc933148e16a75f8";
snapshotDate = "2016-03-18";
snapshotRev = "235d774";
snapshotHash = if stdenv.system == "i686-linux"
then snapshotHashLinux686
else if stdenv.system == "x86_64-linux"
then snapshotHashLinux64
else if stdenv.system == "i686-darwin"
then snapshotHashDarwin686
else if stdenv.system == "x86_64-darwin"
then snapshotHashDarwin64
else abort "no snapshot for platform ${stdenv.system}";
snapshotName = "rust-stage0-${snapshotDate}-${snapshotRev}-${platform}-${snapshotHash}.tar.bz2";
in
rec {
rustc = stdenv.mkDerivation {
name = "rustc-snapshot";
src = fetchurl {
url = "http://static.rust-lang.org/stage0-snapshots/${snapshotName}";
sha1 = snapshotHash;
};
dontStrip = true;
installPhase = ''
mkdir -p "$out"
cp -r bin "$out/bin"
'' + stdenv.lib.optionalString stdenv.isLinux ''
patchelf --interpreter "${stdenv.glibc.out}/lib/${stdenv.cc.dynamicLinker}" \
--set-rpath "${stdenv.cc.cc.lib}/lib/:${stdenv.cc.cc.lib}/lib64/" \
"$out/bin/rustc"
'';
};
cargo = null;
}

View file

@ -7,15 +7,16 @@
{ runCommand, fetchFromGitHub, git }:
let
version = "2016-06-26";
rev = "eb6b06424a5cdc5dd0f41f06cda69714b3a0577b";
version = "2016-07-13";
rev = "8c0d367a18349078cc33df1eed7394fbaa2d602e";
sha256 = "1r59qvzrr1rmjbq8al0qwkc65nd3n512i4pgn9688192d68cjnl8";
src = fetchFromGitHub {
inherit rev;
inherit sha256;
owner = "rust-lang";
repo = "crates.io-index";
sha256 = "0iyqyyd5070whfgsg74bqk0f6rk7d2r4spb2ih9jy594ds2qinv4";
};
in