From b58e991272dca9dd906f71870da10ded1a61f6cb Mon Sep 17 00:00:00 2001 From: Peter Simons Date: Mon, 11 Feb 2013 16:50:39 +0100 Subject: [PATCH] all-packages.nix: provide a variant of Darcs that includes the executable, but not the library The reduced 'darcs' derivation is supposed to be run-time independent of the Haskell compiler. Unfortunately, this isn't quite true yet because the HTTP package bakes its own store path into the library. This causes Darcs -- which links the HTTP library statically -- to depend on 'HTTP', which in turn depends on lot of other Haskell stuff. Patching HTTP to get rid of that reference looks feasible, though. --- pkgs/top-level/all-packages.nix | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 7a5639fe2dd..1a3b1043e25 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -6813,7 +6813,14 @@ let d4x = callPackage ../applications/misc/d4x { }; - darcs = lib.setName "darcs-${haskellPackages.darcs.version}" haskellPackages.darcs; + darcs = haskellPackages.darcs.override { + # A variant of the Darcs derivation that containts only the executable and + # thus has no dependencies on other Haskell packages. + cabal = { mkDerivation = x: rec { final = haskellPackages.cabal.mkDerivation (self: (x final) // { + isLibrary = false; + configureFlags = "-f-library"; }); }.final; + }; + }; darktable = callPackage ../applications/graphics/darktable { inherit (gnome) GConf libglade;