3 # Please insert new packages *alphabetically*
4 # in the OTHER PACKAGES section.
8 removeLibraryHaskellDepends = pnames: depends:
9 builtins.filter (e: !(builtins.elem (e.pname or "") pnames)) depends;
16 ## GENERAL SETUP BASE PACKAGES
18 inherit (self.ghc.bootPkgs)
19 jailbreak-cabal alex happy gtk2hs-buildtools rehoo hoogle;
21 # Test suite fails; https://github.com/ghcjs/ghcjs-base/issues/133
22 ghcjs-base = dontCheck (self.callPackage ../compilers/ghcjs/ghcjs-base.nix {
23 fetchFromGitHub = pkgs.buildPackages.fetchFromGitHub;
24 aeson = self.aeson_1_5_6_0;
27 # GHCJS does not ship with the same core packages as GHC.
28 # https://github.com/ghcjs/ghcjs/issues/676
29 stm = doJailbreak self.stm_2_5_1_0;
30 exceptions = dontCheck self.exceptions_0_10_7;
34 # Runtime exception in tests, missing C API h$realloc
35 base-compat-batteries = dontCheck super.base-compat-batteries;
37 # nodejs crashes during test
38 ChasingBottoms = dontCheck super.ChasingBottoms;
41 text-short = dontCheck super.text-short;
43 # doctest doesn't work on ghcjs, but sometimes dontCheck doesn't seem to get rid of the dependency
44 doctest = pkgs.lib.warn "ignoring dependency on doctest" null;
46 ghcjs-dom = overrideCabal (drv: {
47 libraryHaskellDepends = with self; [
48 ghcjs-base ghcjs-dom-jsffi text transformers
50 configureFlags = [ "-fjsffi" "-f-webkit" ];
53 ghcjs-dom-jsffi = overrideCabal (drv: {
54 libraryHaskellDepends = (drv.libraryHaskellDepends or []) ++ [ self.ghcjs-base self.text ];
56 }) super.ghcjs-dom-jsffi;
58 # https://github.com/Deewiant/glob/issues/39
59 Glob = dontCheck super.Glob;
61 # Test fails to compile during the hsc2hs stage
62 hashable = dontCheck super.hashable;
65 http-types = dontCheck super.http-types;
67 jsaddle = overrideCabal (drv: {
68 libraryHaskellDepends = (drv.libraryHaskellDepends or []) ++ [ self.ghcjs-base ];
71 # Tests hang, possibly some issue with tasty and race(async) usage in the nonTerminating tests
72 logict = dontCheck super.logict;
74 patch = dontCheck super.patch;
77 pcre-light = dontCheck super.pcre-light;
79 # Terminal test not supported on ghcjs
80 QuickCheck = dontCheck super.QuickCheck;
82 reflex = overrideCabal (drv: {
83 libraryHaskellDepends = (drv.libraryHaskellDepends or []) ++ [ self.ghcjs-base ];
86 reflex-dom = overrideCabal (drv: {
87 libraryHaskellDepends = removeLibraryHaskellDepends ["jsaddle-webkit2gtk"] (drv.libraryHaskellDepends or []);
90 # https://github.com/dreixel/syb/issues/21
91 syb = dontCheck super.syb;
93 # nodejs crashes during test
94 scientific = dontCheck super.scientific;
96 # Tests use TH which gives error
97 tasty-quickcheck = dontCheck super.tasty-quickcheck;
99 temporary = dontCheck super.temporary;
101 # 2 tests fail, related to time precision
102 time-compat = dontCheck super.time-compat;
104 # TODO: The tests have a TH error, which has been fixed in ghc
105 # https://gitlab.haskell.org/ghc/ghc/-/issues/15481 but somehow the issue is
106 # still present here https://github.com/glguy/th-abstraction/issues/53
107 th-abstraction = dontCheck super.th-abstraction;
109 # Need hedgehog for tests, which fails to compile due to dep on concurrent-output
110 zenc = dontCheck super.zenc;
112 hspec = self.hspec_2_7_10;
113 hspec-core = self.hspec-core_2_7_10;
114 hspec-meta = self.hspec-meta_2_7_8;
115 hspec-discover = self.hspec-discover_2_7_10;
117 # ReferenceError: h$primop_ShrinkSmallMutableArrayOp_Char is not defined
118 unordered-containers = dontCheck super.unordered-containers;
120 # Without this revert, test suites using tasty fail with:
121 # ReferenceError: h$getMonotonicNSec is not defined
122 # https://github.com/UnkindPartition/tasty/pull/345#issuecomment-1538216407
123 tasty = appendPatch (pkgs.fetchpatch {
124 name = "tasty-ghcjs.patch";
125 url = "https://github.com/UnkindPartition/tasty/commit/e692065642fd09b82acccea610ad8f49edd207df.patch";
128 hash = "sha256-ryABU2ywkVOEPC/jWv8humT3HaRpCwMYEk+Ux3hhi/M=";
131 # Tests take unacceptably long.
132 vector = dontCheck super.vector;