nixpkgs/pkgs/development/compilers/ghc
Adam Joseph c0085404bd lib/systems/inspect.nix: remove isPowerPC
Very confusingly, the `isPowerPC` predicate in
`lib/systems/inspect.nix` does *not* match `powerpc64le`!

This is because `isPowerPC` is defined as

  isPowerPC      = { cpu = cpuTypes.powerpc; };

Where `cpuTypes.powerpc` is:

  { bits = 32; significantByte = bigEndian; family = "power"; };

This means that the `isPowerPC` predicate actually only matches the
subset of machines marketed under this name which happen to be 32-bit
and running in big-endian mode which is equivalent to:

  with stdenv.hostPlatform; isPower && isBigEndian && is32bit

This seems like a sharp edge that people could easily cut themselves
on.  In fact, that has already happened: in
`linux/kernel/common-config.nix` there is a test which will always
fail:

  (stdenv.hostPlatform.isPowerPC && stdenv.hostPlatform.is64bit)

A more subtle case of the strict isPowerPC being used instead of the
moreg general isPower accidentally are the GHC expressions:

  Update pkgs/development/compilers/ghc/8.10.7.nix
  Update pkgs/development/compilers/ghc/8.8.4.nix
  Update pkgs/development/compilers/ghc/9.2.2.nix
  Update pkgs/development/compilers/ghc/9.0.2.nix
  Update pkgs/development/compilers/ghc/head.nix

Since the remaining legitimate use sites of isPowerPC are so few, remove
the isPowerPC predicate completely. The alternative expression above is
noted in the release notes as an alternative.

Co-authored-by: sternenseemann <sternenseemann@systemli.org>
2022-05-25 09:45:42 +02:00
..
8.6.5-binary.nix haskell.compiler.ghc*Binary: add all missing runtimeDeps to PATH 2021-11-25 15:42:47 +01:00
8.8.4.nix lib/systems/inspect.nix: remove isPowerPC 2022-05-25 09:45:42 +02:00
8.10.2-binary.nix haskell.compiler: fix binary GHCs with store paths containing "xxx" 2022-04-22 14:25:53 +02:00
8.10.7-binary.nix haskell.compiler: fix binary GHCs with store paths containing "xxx" 2022-04-22 14:25:53 +02:00
8.10.7.nix lib/systems/inspect.nix: remove isPowerPC 2022-05-25 09:45:42 +02:00
9.0.2.nix lib/systems/inspect.nix: remove isPowerPC 2022-05-25 09:45:42 +02:00
9.2.2.nix lib/systems/inspect.nix: remove isPowerPC 2022-05-25 09:45:42 +02:00
backport-dylib-command-size-limit.patch
cabal-paths.patch haskell.compiler.ghc8107: fix seperate bin outputs on aarch64-darwin 2022-01-21 15:34:05 +00:00
gcc-clang-wrapper.sh treewide: use ${stdenv.shell} instead of /bin/sh where possible 2019-01-16 20:37:15 +01:00
head.nix lib/systems/inspect.nix: remove isPowerPC 2022-05-25 09:45:42 +02:00
issue-18549.patch #95747: fix build of GHC 8.10.2 2020-08-18 15:56:45 +02:00
rename-numa-api-call.patch ghc8.8.4: fix mingw build 2021-09-09 03:35:17 +01:00
respect-ar-path.patch Fix ar command path in GHC. 2021-02-05 22:54:09 +01:00
sphinx-4-configuration.patch haskell.compiler.ghc8104: patch for sphinx >= 4.0 2021-06-22 13:42:55 +02:00