From be29f4575e6ba2f0610180ab765f1b767578968e Mon Sep 17 00:00:00 2001 From: Nick Cao Date: Tue, 30 Nov 2021 14:49:53 +0800 Subject: [PATCH] rustc: expose correct llvmPackages for cross compile --- pkgs/development/compilers/rust/1_60.nix | 2 +- pkgs/development/compilers/rust/default.nix | 4 ++-- pkgs/development/compilers/rust/rustc.nix | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/pkgs/development/compilers/rust/1_60.nix b/pkgs/development/compilers/rust/1_60.nix index 0153b5d23a90..16f8512952d4 100644 --- a/pkgs/development/compilers/rust/1_60.nix +++ b/pkgs/development/compilers/rust/1_60.nix @@ -33,7 +33,7 @@ import ./default.nix { llvmShared = llvm_14.override { enableSharedLibraries = true; }; # Expose llvmPackages used for rustc from rustc via passthru for LTO in Firefox - llvmPackagesForBuild = pkgsBuildBuild.llvmPackages_14; + llvmPackages = llvmPackages_14; # Note: the version MUST be one version prior to the version we're # building diff --git a/pkgs/development/compilers/rust/default.nix b/pkgs/development/compilers/rust/default.nix index 6dfc8a49063f..6c579373f5dc 100644 --- a/pkgs/development/compilers/rust/default.nix +++ b/pkgs/development/compilers/rust/default.nix @@ -10,7 +10,7 @@ , llvmSharedForBuild , llvmSharedForHost , llvmSharedForTarget -, llvmPackagesForBuild # Exposed through rustc for LTO in Firefox +, llvmPackages # Exposed through rustc for LTO in Firefox }: { stdenv, lib , buildPackages @@ -64,7 +64,7 @@ in version = rustcVersion; sha256 = rustcSha256; inherit enableRustcDev; - inherit llvmShared llvmSharedForBuild llvmSharedForHost llvmSharedForTarget llvmPackagesForBuild; + inherit llvmShared llvmSharedForBuild llvmSharedForHost llvmSharedForTarget llvmPackages; patches = rustcPatches; diff --git a/pkgs/development/compilers/rust/rustc.nix b/pkgs/development/compilers/rust/rustc.nix index 1087ac059082..d167cf91c361 100644 --- a/pkgs/development/compilers/rust/rustc.nix +++ b/pkgs/development/compilers/rust/rustc.nix @@ -1,5 +1,5 @@ { lib, stdenv, removeReferencesTo, pkgsBuildBuild, pkgsBuildHost, pkgsBuildTarget -, llvmShared, llvmSharedForBuild, llvmSharedForHost, llvmSharedForTarget, llvmPackagesForBuild +, llvmShared, llvmSharedForBuild, llvmSharedForHost, llvmSharedForTarget, llvmPackages , fetchurl, file, python3 , darwin, cmake, rust, rustPlatform , pkg-config, openssl @@ -179,7 +179,7 @@ in stdenv.mkDerivation rec { passthru = { llvm = llvmShared; - llvmPackages = llvmPackagesForBuild; + inherit llvmPackages; }; meta = with lib; {