mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-06-05 21:03:40 +00:00
pkgsLLVM: Fix unwanted target offset
pkgsLLVM introduced an unwanted target offset, as can be seen with the following commands. Before this commit: ``` $ nix eval --system x86_64-linux -f . pkgsCross.aarch64-multiplatform.buildPackages.stdenv.hostPlatform.config "x86_64-unknown-linux-gnu" $ nix eval --system x86_64-linux -f . pkgsCross.aarch64-multiplatform.buildPackages.pkgsLLVM.stdenv.hostPlatform.config "aarch64-unknown-linux-gnu" Explaination: These two should be the same, since the only difference between them is the addition of "pkgsLLVM". The buildPackages of the pkgsCross set should have a hostPlatform which is the native platform. ``` After this commit: ``` $ nix eval --system x86_64-linux -f . pkgsCross.aarch64-multiplatform.buildPackages.stdenv.hostPlatform.config "x86_64-unknown-linux-gnu" $ nix eval --system x86_64-linux -f . pkgsCross.aarch64-multiplatform.buildPackages.pkgsLLVM.stdenv.hostPlatform.config "x86_64-unknown-linux-gnu" ```
This commit is contained in:
@@ -201,7 +201,7 @@ let
|
||||
# Bootstrap a cross stdenv using the LLVM toolchain.
|
||||
# This is currently not possible when compiling natively,
|
||||
# so we don't need to check hostPlatform != buildPlatform.
|
||||
crossSystem = stdenv.targetPlatform // {
|
||||
crossSystem = stdenv.hostPlatform // {
|
||||
useLLVM = true;
|
||||
linker = "lld";
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user