lol

haskell.compiler.*: fix stack overrun on 32bit (#402925)

+20
+11
pkgs/development/compilers/ghc/common-hadrian.nix
··· 279 279 includes = [ "configure.ac" ]; 280 280 hash = "sha256-L3FQvcm9QB59BOiR2g5/HACAufIG08HiT53EIOjj64g="; 281 281 }) 282 + ] 283 + # Fixes stack overrun in rts which crashes an process whenever 284 + # freeHaskellFunPtr is called with nixpkgs' hardening flags. 285 + # https://gitlab.haskell.org/ghc/ghc/-/issues/25485 286 + # https://gitlab.haskell.org/ghc/ghc/-/merge_requests/13599 287 + ++ lib.optionals (lib.versionOlder version "9.13" && stdenv.hostPlatform.is32bit) [ 288 + (fetchpatch { 289 + name = "ghc-rts-adjustor-fix-i386-stack-overrun.patch"; 290 + url = "https://gitlab.haskell.org/ghc/ghc/-/commit/39bb6e583d64738db51441a556d499aa93a4fc4a.patch"; 291 + sha256 = "0w5fx413z924bi2irsy1l4xapxxhrq158b5gn6jzrbsmhvmpirs0"; 292 + }) 282 293 ]; 283 294 284 295 stdenv = stdenvNoCC;
+9
pkgs/development/haskell-modules/configuration-common.nix
··· 2302 2302 # Overwrite the build cores 2303 2303 raaz = disableParallelBuilding super.raaz; 2304 2304 2305 + # Test suite uses SHA as a point of comparison which doesn't 2306 + # succeeds its own test suite on 32bit: 2307 + # https://github.com/GaloisInc/SHA/issues/16 2308 + cryptohash-sha256 = 2309 + if pkgs.stdenv.hostPlatform.is32bit then 2310 + dontCheck super.cryptohash-sha256 2311 + else 2312 + super.cryptohash-sha256; 2313 + 2305 2314 # https://github.com/andreymulik/sdp/issues/3 2306 2315 sdp = disableLibraryProfiling super.sdp; 2307 2316 sdp-binary = disableLibraryProfiling super.sdp-binary;