about summary refs log tree commit diff
path: root/pkgs/development/haskell-modules/configuration-ghcjs.nix
diff options
context:
space:
mode:
authorLeon Isenberg <ljli@users.noreply.github.com>2017-04-06 20:30:44 +0200
committerLeon Isenberg <ljli@users.noreply.github.com>2017-04-07 19:02:52 +0200
commit7a08e57b9e077dc5abcca090621fa688413832c3 (patch)
tree2c74938f94ee0d32b8bb0edcacf02ee526b59c74 /pkgs/development/haskell-modules/configuration-ghcjs.nix
parenta5ee494046b4259a4a2dfea95776faa898d1bd26 (diff)
downloadnixlib-7a08e57b9e077dc5abcca090621fa688413832c3.tar
nixlib-7a08e57b9e077dc5abcca090621fa688413832c3.tar.gz
nixlib-7a08e57b9e077dc5abcca090621fa688413832c3.tar.bz2
nixlib-7a08e57b9e077dc5abcca090621fa688413832c3.tar.lz
nixlib-7a08e57b9e077dc5abcca090621fa688413832c3.tar.xz
nixlib-7a08e57b9e077dc5abcca090621fa688413832c3.tar.zst
nixlib-7a08e57b9e077dc5abcca090621fa688413832c3.zip
haskell: ghcjs packages: Break dependency cycle less invasive
Between cabal and hscolour.
Diffstat (limited to 'pkgs/development/haskell-modules/configuration-ghcjs.nix')
-rw-r--r--pkgs/development/haskell-modules/configuration-ghcjs.nix10
1 files changed, 7 insertions, 3 deletions
diff --git a/pkgs/development/haskell-modules/configuration-ghcjs.nix b/pkgs/development/haskell-modules/configuration-ghcjs.nix
index d6d7277cc9d9..fd7f15008d26 100644
--- a/pkgs/development/haskell-modules/configuration-ghcjs.nix
+++ b/pkgs/development/haskell-modules/configuration-ghcjs.nix
@@ -58,9 +58,13 @@ self: super:
   # Almost all packages require Cabal to build their Setup.hs,
   # but usually they don't declare it explicitly as they don't need to for normal GHC.
   # To account for that we add Cabal by default.
-  mkDerivation = args:
-    if args.pname == "Cabal" then super.mkDerivation args else super.mkDerivation (args //
-      { setupHaskellDepends = (args.setupHaskellDepends or []) ++ [ self.Cabal ]; });
+  mkDerivation = args: super.mkDerivation (args // {
+    setupHaskellDepends = (args.setupHaskellDepends or []) ++
+      (if args.pname == "Cabal" then [ ]
+      # Break the dependency cycle between Cabal and hscolour
+      else if args.pname == "hscolour" then [ (dontHyperlinkSource self.Cabal) ]
+      else [ self.Cabal ]);
+  });
 
 ## OTHER PACKAGES