From 89b8fc178e692705aae265e40f950fb31fa8836f Mon Sep 17 00:00:00 2001 From: Hamish Mackenzie Date: Tue, 19 Jan 2021 23:45:51 +1300 Subject: [PATCH 1/2] LicenseRef-OtherLicense is not `free = false` The [dependent-map](https://hackage.haskell.org/package/dependent-map) package for instance is not clear on which free license applies to which parts of the code, but that does not mean it is not free. `cabal2nix` maps LicenseRef-OtherLicense to `meta.license = "unknown"` `cabal-to-nix` and `haskell.nix` map it to a more detailed attribute set but it includes `free = false` and that causes packages like `dependent-map` to fail to install when `allowUnfree` has not been set. This change removes the `free` attribute altogether, which seems more principled than asserting that the `OtherLicense` cannot be `free`. --- lib/cabal-licenses.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/cabal-licenses.nix b/lib/cabal-licenses.nix index f2b913edec..51a42c93ce 100644 --- a/lib/cabal-licenses.nix +++ b/lib/cabal-licenses.nix @@ -14,7 +14,6 @@ in licenses // { shortName = "Other License"; fullName = "Unidentified Other License"; url = "https://spdx.github.io/spdx-spec/appendix-IV-SPDX-license-expressions/"; - free = false; }; NONE = null; } From 4939aa7fd3f331d0ee047a22e48e2001d62153d7 Mon Sep 17 00:00:00 2001 From: Hamish Mackenzie Date: Wed, 20 Jan 2021 00:24:14 +1300 Subject: [PATCH 2/2] Add comment --- lib/cabal-licenses.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/cabal-licenses.nix b/lib/cabal-licenses.nix index 51a42c93ce..144ccc9859 100644 --- a/lib/cabal-licenses.nix +++ b/lib/cabal-licenses.nix @@ -14,6 +14,8 @@ in licenses // { shortName = "Other License"; fullName = "Unidentified Other License"; url = "https://spdx.github.io/spdx-spec/appendix-IV-SPDX-license-expressions/"; + # Not setting `free` here. The license may or may not be `free`. + # See https://github.com/input-output-hk/haskell.nix/pull/1006 }; NONE = null; }