diff --git a/pkgs/development/haskell-modules/configuration-common.nix b/pkgs/development/haskell-modules/configuration-common.nix index b73d72d99a3ae..3adc0fa27236f 100644 --- a/pkgs/development/haskell-modules/configuration-common.nix +++ b/pkgs/development/haskell-modules/configuration-common.nix @@ -1566,13 +1566,36 @@ self: super: { doJailbreak ]; - jsaddle-dom = overrideCabal (old: { - postPatch = old.postPatch or "" + '' - rm Setup.hs - ''; - }) super.jsaddle-dom; - jsaddle-hello = doJailbreak super.jsaddle-hello; - ghcjs-dom-hello = doJailbreak super.ghcjs-dom-hello; + ghcjs-dom-hello = appendPatches [ + (fetchpatch { + url = "https://github.com/ghcjs/ghcjs-dom-hello/commit/53991df6a4eba9f1e9633eb22f6a0486a79491c3.patch"; + sha256 = "sha256-HQeUgjvzYyY14+CDYiMahAMn7fBcy2d7p8/kqGq+rnI="; + }) + (fetchpatch { + url = "https://github.com/ghcjs/ghcjs-dom-hello/commit/d766d937121f7ea5c4c154bd533a1eae47f531c9.patch"; + sha256 = "sha256-QTkH+L+JMwGyuoqzHBnrokT7KzpHC4YiAWoeiaFBLUw="; + }) + (fetchpatch { + url = "https://github.com/ghcjs/ghcjs-dom-hello/commit/831464d995f4033c9aa84f9ed9fb37a268f34d4e.patch"; + sha256 = "sha256-hQMy+78geTuxd3kbdiyYqoAFrauu90HbpPi0EEKjMzM="; + }) + ] super.ghcjs-dom-hello; + + # Needs https://github.com/ghcjs/jsaddle-hello/pull/5 and hackage release + jsaddle-hello = appendPatches [ + (fetchpatch { + url = "https://github.com/ghcjs/jsaddle-hello/commit/c4de837675117b821c50a5079d20d84ec16ff26a.patch"; + sha256 = "sha256-NsM7QqNLt5V8i5bveYgMrawGnZVsIuAoJfBF75jBwV0="; + }) + (fetchpatch { + url = "https://github.com/ghcjs/jsaddle-hello/commit/5c437363833684ea951ec74a0d0fdf5b6fbaca85.patch"; + sha256 = "sha256-CUyZsts0FAQ3c8Z+zfvwbmlAJCMcidV80n8dA/SoRls="; + }) + (fetchpatch { + url = "https://github.com/ghcjs/jsaddle-hello/commit/e2da9e266fbfa8f7fcf3009ab6cfbf825a8bcf7a.patch"; + sha256 = "sha256-WL0CcnlMt6KI7MOZMg74fNN/I4gYSO3n+GiaXB2BOP0="; + }) + ] super.jsaddle-hello; # Too strict upper bounds on text lsql-csv = doJailbreak super.lsql-csv; diff --git a/pkgs/development/haskell-modules/configuration-darwin.nix b/pkgs/development/haskell-modules/configuration-darwin.nix index 5985d29f8b591..16e5d2613fb2e 100644 --- a/pkgs/development/haskell-modules/configuration-darwin.nix +++ b/pkgs/development/haskell-modules/configuration-darwin.nix @@ -323,6 +323,20 @@ self: super: ({ # Tests fail on macOS https://github.com/mrkkrp/zip/issues/112 zip = dontCheck super.zip; + warp = super.warp.overrideAttrs (drv: { + __darwinAllowLocalNetworking = true; + }); + + ghcjs-dom-hello = overrideCabal (drv: { + libraryHaskellDepends = with self; [ jsaddle jsaddle-warp ]; + executableHaskellDepends = with self; [ ghcjs-dom jsaddle-wkwebview ]; + }) super.ghcjs-dom-hello; + + jsaddle-hello = overrideCabal (drv: { + libraryHaskellDepends = with self; [ jsaddle lens ]; + executableHaskellDepends = with self; [ jsaddle-warp jsaddle-wkwebview ]; + }) super.jsaddle-hello; + jsaddle-wkwebview = overrideCabal (drv: { libraryFrameworkDepends = with pkgs.buildPackages.darwin.apple_sdk.frameworks; [ Cocoa WebKit ]; libraryHaskellDepends = with self; [ aeson data-default jsaddle ]; # cabal2nix doesn't add darwin-only deps diff --git a/pkgs/development/haskell-modules/configuration-ghc-9.8.x.nix b/pkgs/development/haskell-modules/configuration-ghc-9.8.x.nix index ba0f6c31a216e..8b5ad996c24b9 100644 --- a/pkgs/development/haskell-modules/configuration-ghc-9.8.x.nix +++ b/pkgs/development/haskell-modules/configuration-ghc-9.8.x.nix @@ -68,6 +68,7 @@ self: super: { stylish-haskell = self.stylish-haskell_0_14_6_0; hlint = self.hlint_3_8; ghc-syntax-highlighter = self.ghc-syntax-highlighter_0_0_11_0; + websockets = self.websockets_0_13_0_0; # A given major version of ghc-exactprint only supports one version of GHC. ghc-exactprint = self.ghc-exactprint_1_8_0_0; diff --git a/pkgs/development/haskell-modules/configuration-hackage2nix/main.yaml b/pkgs/development/haskell-modules/configuration-hackage2nix/main.yaml index 93eebf297e8e8..07a8550643996 100644 --- a/pkgs/development/haskell-modules/configuration-hackage2nix/main.yaml +++ b/pkgs/development/haskell-modules/configuration-hackage2nix/main.yaml @@ -670,7 +670,6 @@ unsupported-platforms: freenect: [ platforms.darwin ] FTGL: [ platforms.darwin ] fuzzytime: [ platforms.darwin ] # https://github.com/kamwitsta/fuzzytime/issues/2 - ghcjs-dom-hello: [ platforms.darwin ] ghc-gc-hook: [ platforms.darwin ] # requires C11 threads which Apple doesn't support gi-adwaita: [ platforms.darwin ] gi-dbusmenugtk3: [ platforms.darwin ] @@ -699,7 +698,6 @@ unsupported-platforms: intricacy: [ platforms.darwin ] # depends on mesa iwlib: [ platforms.darwin ] Jazzkell: [ platforms.darwin ] # depends on Euterpea - jsaddle-hello: [ platforms.darwin ] # depends on jsaddle-webkit2gtk jsaddle-webkit2gtk: [ platforms.darwin ] Kulitta: [ platforms.darwin ] # depends on Euterpea LambdaHack: [ platforms.darwin ] diff --git a/pkgs/development/haskell-modules/hackage-packages.nix b/pkgs/development/haskell-modules/hackage-packages.nix index 1b67efe86b389..1376ba10f54ce 100644 --- a/pkgs/development/haskell-modules/hackage-packages.nix +++ b/pkgs/development/haskell-modules/hackage-packages.nix @@ -121415,7 +121415,6 @@ self: { ]; description = "GHCJS DOM Hello World, an example package"; license = lib.licenses.mit; - badPlatforms = lib.platforms.darwin; maintainers = [ lib.maintainers.alexfmpe ]; }) {}; @@ -178683,7 +178682,6 @@ self: { ]; description = "JSaddle Hello World, an example package"; license = lib.licenses.mit; - badPlatforms = lib.platforms.darwin; maintainers = [ lib.maintainers.alexfmpe ]; }) {};