haskell.compiler.ghc{96,98,910}: use emscripten installCC for ghcjs

An oversight in 884a76c5e6: We need to
mirror the isGhcjs condition of targetCC (toolsForTarget) for installCC
as well. (Note that in practice, targetCC == installCC for ghcjs since
it is cross-only (?).)
This commit is contained in:
sternenseemann
2024-09-09 12:04:18 +02:00
parent 5cd41e16a6
commit 7fff04332d

View File

@@ -285,7 +285,10 @@ let
buildCC = buildPackages.stdenv.cc;
targetCC = builtins.head toolsForTarget;
installCC = pkgsHostTarget.targetPackages.stdenv.cc;
installCC =
if targetPlatform.isGhcjs
then pkgsHostTarget.emscripten
else pkgsHostTarget.targetPackages.stdenv.cc;
# toolPath calculates the absolute path to the name tool associated with a
# given `stdenv.cc` derivation, i.e. it picks the correct derivation to take