Enable building python reuse from source

This commit is contained in:
Florian Friesdorf 2024-09-18 18:26:08 +02:00 committed by DavHau
parent 607c99076d
commit e118d69b14

View File

@ -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];
}