From 8454a9e75362d7c5031b927a3ee641b721453f8f Mon Sep 17 00:00:00 2001 From: 3noch Date: Sat, 4 Feb 2017 02:01:10 -0500 Subject: [PATCH] haskellPackages.callCabal2nix: provide fallback name if source is not package --- pkgs/development/haskell-modules/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/haskell-modules/default.nix b/pkgs/development/haskell-modules/default.nix index cf30a7699ed6..31b20ab19f36 100644 --- a/pkgs/development/haskell-modules/default.nix +++ b/pkgs/development/haskell-modules/default.nix @@ -87,7 +87,7 @@ let # Creates a Haskell package from a source package by calling cabal2nix on the source. callCabal2nix = src: self.callPackage (haskellSrc2nix { inherit src; - name = src.name; + name = src.name or baseNameOf src; }); ghcWithPackages = selectFrom: withPackages (selectFrom self);