ghcHEAD: Fix Windows cross-compilation with lld.

By specifying pkgs.libffi here instead of letting callPackage handle
it, we confuse the splicing logic and put the host libffi into
NIX_LDFLAGS_FOR_TARGET. This previously hasn't been a problem, as we
also pass an explicit configure flag pointing to the target libffi,
and so the only side-effect is a senseless -rpath flag.

ld.lld (rightly) does not recognize the -rpath flag when targeting
Windows, however, so this causes build failures.
main
Shea Levy 2 years ago
parent 5e8a857310
commit ece10a711f
No known key found for this signature in database
GPG Key ID: 5C0BD6957D86FE27
  1. 1
      pkgs/top-level/haskell-packages.nix

@ -145,7 +145,6 @@ in {
inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_12;
llvmPackages = pkgs.llvmPackages_12;
libffi = pkgs.libffi;
};
ghcjs = compiler.ghcjs810;

Loading…
Cancel
Save