@@ -898,24 +898,18 @@ let
898898 # depends on (e.g. text), because nix + GHC already do this for us:
899899 # https://github.com/ghc/ghc/blob/ghc-8.4.3-release/ghc.mk#L620-L626
900900 # https://github.com/peterhoeg/nixpkgs/commit/50050f3cc9e006daa6800f15a29e258c6e6fa4b3#diff-2f6f8fd152c14d37ebd849aa6382257aR35
901- then previous . haskell . packages . integer-simple . "${ compiler } "
902- else previous . haskell . packages . "${ compiler } " ;
901+ then final . haskell . packages . integer-simple . "${ compiler } "
902+ else final . haskell . packages . "${ compiler } " ;
903903 in
904904 {
905- haskellPackages = initialHaskellPackages . override ( old : {
906-
907- # To override GHC, we need to override both `ghc` and the one in
908- # `buildHaskellPackages` because otherwise this code in `geneic-builder.nix`
909- # will make our package depend on 2 different GHCs:
910- # nativeGhc = buildHaskellPackages.ghc;
911- # depsBuildBuild = [ nativeGhc ] ...
912- # nativeBuildInputs = [ ghc removeReferencesTo ] ...
913- #
914- ghc = fixGhc old . ghc ;
915- buildHaskellPackages = old . buildHaskellPackages . override ( oldBuildHaskellPackages : {
916- ghc = fixGhc oldBuildHaskellPackages . ghc ;
917- } ) ;
918- } ) ;
905+ haskell = previous . haskell // {
906+ packages = previous . haskell . packages // {
907+ "${ compiler } " = previous . haskell . packages . "${ compiler } " . override {
908+ ghc = fixGhc previous . haskell . compiler . "${ compiler } " ;
909+ } ;
910+ } ;
911+ } ;
912+ haskellPackages = initialHaskellPackages ;
919913 } ;
920914
921915 pkgsWithGhc = pkgsWithArchiveFiles . extend setupGhcOverlay ;
0 commit comments