From e118d69b142dea7690555fc4502f288030c1d4ed Mon Sep 17 00:00:00 2001 From: Florian Friesdorf Date: Wed, 18 Sep 2024 18:26:08 +0200 Subject: [PATCH] Enable building python reuse from source --- overrides/python/reuse/default.nix | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 overrides/python/reuse/default.nix diff --git a/overrides/python/reuse/default.nix b/overrides/python/reuse/default.nix new file mode 100644 index 00000000..ef29cc0e --- /dev/null +++ b/overrides/python/reuse/default.nix @@ -0,0 +1,12 @@ +{ + config, + lib, + dream2nix, + ... +}: let + isSdist = lib.hasSuffix ".tar.gz" config.mkDerivation.src; + python = config.deps.python; +in { + buildPythonPackage.pyproject = lib.mkIf isSdist true; + mkDerivation.nativeBuildInputs = lib.mkIf isSdist [python.pkgs.poetry-core]; +}