mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-11-17 14:19:58 +03:00
gcc.libgcc: compare host and target platforms, rathern than their triples
The rest of our gcc expression prepends "${targetPlatform.config}-" to paths and binaries if `hostPlatform!=targetPlatform`. The `libgcc.nix` expression was using 'hostPlatform.config!=targetPlatform.config`, which caused it to look in the wrong place when moving files. This commit corrects that.
This commit is contained in:
parent
72c279f477
commit
36f5b2e42b
@ -36,7 +36,7 @@ lib.optionals (lib.versionAtLeast version "11.0")
|
||||
|
||||
(let
|
||||
targetPlatformSlash =
|
||||
if hostPlatform.config == targetPlatform.config
|
||||
if hostPlatform == targetPlatform
|
||||
then ""
|
||||
else "${targetPlatform.config}/";
|
||||
|
||||
@ -83,7 +83,7 @@ in
|
||||
lib.optionalString (!langC) ''
|
||||
rm -f $out/lib/libgcc_s.so*
|
||||
''
|
||||
+ lib.optionalString (hostPlatform.config != targetPlatform.config) ''
|
||||
+ lib.optionalString (hostPlatform != targetPlatform) ''
|
||||
mkdir -p $lib/lib/
|
||||
ln -s ${targetPlatformSlash}lib $lib/lib
|
||||
''
|
||||
|
Loading…
Reference in New Issue
Block a user