nixpkgs/pkgs/development/haskell-modules
sternenseemann 9dbcebd154 haskellPackages.mkDerivation: profiling depends on hostPlatform
Whether profiling should or should not be enabled does indeed depend on
GHC's target platform (or GHC in general, i.e. if it happens to be
ghcjs, we need to disable it). The profiling objects it produces are
excessively big if it is producing them for aarch64.

However, in a Haskell packages' derivation, GHC's and the resulting
derivation's platforms are offset

    GHC:  BUILD--HOST---TARGET
    DRV:         BUILD--HOST--(TARGET)

since we need to execute GHC in the derivation (so its host is our build
platform) and the machine code it produces need to be executable on the
host platform we are targeting. Unless our derivation is building a
compiler (or similar), the target platform of the derivation doesn't
matter.

stdenv exposes the platforms of the current derivation, not of GHC, so
checking the host platform is prudent. Changing this doesn't have a lot
of impact, since when cross-compiling Haskell packages (e.g. via
pkgsCross), host and target platform will usually be the same.
It does save unnecessary rebuilds in the buildHaskellPackages set
though, since most of the packages in here don't care about the target
platform, so they should be the same as their corresponding packages in
the ordinary (natively compiled) haskellPackages set. In short, after
this change

     pkgsCross.aarch64-multiplatform.hoogle == haskellPackages.hoogle

holds whereas it would erroneously be compiled with different profiling
settings before.
2023-06-08 18:17:38 +02:00
..
configuration-hackage2nix haskellPackages.uuagc-cabal: no longer broken 2023-06-08 08:45:27 +02:00
lib haskell.packages.ghc94.gtk2hs-buildtools: gtk2hs setup hook broken for ghc-9.4.4 2023-02-04 12:34:07 +01:00
patches haskell.packages.ghc94.gtk2hs-buildtools: remove patch for upstream fix 2023-06-07 10:24:38 +12:00
cabal2nix-unstable.nix haskellPackages.cabal2nix-unstable: 2023-04-11 -> 2023-05-05 2023-05-05 22:28:32 +02:00
configuration-arm.nix haskellPackages.wiringPi: Add wiringpi as a dependency on aarch 2023-04-17 23:43:23 +01:00
configuration-common.nix haskellPackages.aeson: fix test suite for QuickCheck-2.14.3 2023-06-08 16:40:33 +02:00
configuration-darwin.nix haskellPackages.streamly-0.9.0: Add required framework on Darwin 2023-05-31 08:26:53 +08:00
configuration-ghc-8.6.x.nix haskell.packages.*: reflect terminfo update for cross compilation 2023-03-02 13:58:51 +01:00
configuration-ghc-8.8.x.nix haskell.packages.*.vector: clean up and unify overrides, run tests 2023-03-20 14:14:41 +01:00
configuration-ghc-8.10.x.nix haskell.packages.*: reflect terminfo update for cross compilation 2023-03-02 13:58:51 +01:00
configuration-ghc-9.0.x.nix haskell.packages.*.vector: clean up and unify overrides, run tests 2023-03-20 14:14:41 +01:00
configuration-ghc-9.2.x.nix haskellPackages.clash-prelude: Mark broken only for GHC 9.2 2023-06-03 12:30:09 +02:00
configuration-ghc-9.4.x.nix haskell.packages.ghc94.gtk2hs-buildtools: remove patch for upstream fix 2023-06-07 10:24:38 +12:00
configuration-ghc-9.6.x.nix haskell.packages.ghc96.haskell-language-server: explicitly disable fourmolu plugin 2023-05-30 08:56:03 +09:00
configuration-ghc-9.8.x.nix haskell.packages.*: reflect terminfo update for cross compilation 2023-03-02 13:58:51 +01:00
configuration-ghcjs.nix haskell.packages.ghcjs: misc fixes 2023-05-09 18:13:50 +02:00
configuration-nix.nix haskellPackages.dyre: remove unneeded patch 2023-05-29 13:08:29 +09:00
configuration-tensorflow.nix haskell-tensorflow: unbreak build 2023-02-23 08:55:42 +01:00
default.nix treewide: use isAarch where appropriate 2022-07-30 16:18:27 +00:00
generic-builder.nix haskellPackages.mkDerivation: profiling depends on hostPlatform 2023-06-08 18:17:38 +02:00
generic-stack-builder.nix treewide: add names to all setup hooks 2023-01-19 15:00:36 +00:00
hackage-packages.nix Remove hydraPlatforms clause for uuagc-cabal 2023-06-08 11:49:04 +02:00
HACKING.md haskell: Fix typo 2022-11-24 11:03:06 +01:00
hoogle-local-wrapper.sh
hoogle.nix lib.closePropagation: Remove the quadratic behavior in lib.closePropagation 2022-10-07 18:03:42 +02:00
initial-packages.nix
make-package-set.nix haskellPackages: ghcWithPackages needs buildHaskellPackages scope 2023-05-05 18:58:08 +02:00
non-hackage-packages.nix haskellPackages.distribution-nixpkgs: 1.6.2 -> 1.7.0 2022-07-20 12:05:09 +02:00
package-list.nix treewide: use optionalString 2023-02-13 21:52:34 +01:00
stack-hook.sh
with-packages-wrapper.nix haskellPackages.ghcWithPackages: fix whitespace alignment 2023-02-05 14:01:25 +01:00