rustc: use llvm5 for bootstrapping
This commit is contained in:
parent
f4d9adff9a
commit
f0b7561275
@ -2,6 +2,8 @@
|
|||||||
, buildPackages
|
, buildPackages
|
||||||
, newScope, callPackage
|
, newScope, callPackage
|
||||||
, CoreFoundation, Security
|
, CoreFoundation, Security
|
||||||
|
, llvmPackages_5
|
||||||
|
, pkgsBuildTarget, pkgsBuildBuild, pkgsBuildHost
|
||||||
}: rec {
|
}: rec {
|
||||||
makeRustPlatform = { rustc, cargo, ... }: {
|
makeRustPlatform = { rustc, cargo, ... }: {
|
||||||
rust = {
|
rust = {
|
||||||
@ -48,10 +50,15 @@
|
|||||||
buildRustPackages = buildPackages.rust.packages.stable;
|
buildRustPackages = buildPackages.rust.packages.stable;
|
||||||
# Analogous to stdenv
|
# Analogous to stdenv
|
||||||
rustPlatform = makeRustPlatform self.buildRustPackages;
|
rustPlatform = makeRustPlatform self.buildRustPackages;
|
||||||
rustc = self.callPackage ./rustc.nix {
|
rustc = self.callPackage ./rustc.nix ({
|
||||||
# Use boot package set to break cycle
|
# Use boot package set to break cycle
|
||||||
rustPlatform = bootRustPlatform;
|
rustPlatform = bootRustPlatform;
|
||||||
};
|
} // lib.optionalAttrs (stdenv.cc.isClang && stdenv.hostPlatform == stdenv.buildPlatform) {
|
||||||
|
stdenv = llvmPackages_5.stdenv;
|
||||||
|
pkgsBuildBuild = pkgsBuildBuild // { targetPackages.stdenv = llvmPackages_5.stdenv; };
|
||||||
|
pkgsBuildHost = pkgsBuildBuild // { targetPackages.stdenv = llvmPackages_5.stdenv; };
|
||||||
|
pkgsBuildTarget = pkgsBuildTarget // { targetPackages.stdenv = llvmPackages_5.stdenv; };
|
||||||
|
});
|
||||||
cargo = self.callPackage ./cargo.nix {
|
cargo = self.callPackage ./cargo.nix {
|
||||||
# Use boot package set to break cycle
|
# Use boot package set to break cycle
|
||||||
rustPlatform = bootRustPlatform;
|
rustPlatform = bootRustPlatform;
|
||||||
|
Loading…
Reference in New Issue
Block a user