mirror of
https://github.com/nix-community/dream2nix.git
synced 2024-12-23 06:21:30 +03:00
pip: switch to format = "pyproject"
This should resolve collision issues with the setuptools that gets propagated by setuptoolsBuildHook
This commit is contained in:
parent
0f2d06b43e
commit
a6837ba21e
@ -44,15 +44,24 @@
|
||||
)
|
||||
metadata.sources;
|
||||
|
||||
dependencyModule = {config, ...}: {
|
||||
dependencyModule = {config, ...}: let
|
||||
setuptools =
|
||||
if config.name == "setuptools"
|
||||
then config.deps.python.pkgs.setuptools
|
||||
else config.pip.drvs.setuptools.public or config.deps.python.pkgs.setuptools;
|
||||
in {
|
||||
# deps.python cannot be defined in commonModule as this would trigger an
|
||||
# infinite recursion.
|
||||
deps = {inherit python;};
|
||||
buildPythonPackage.format = l.mkDefault (
|
||||
if l.hasSuffix ".whl" config.mkDerivation.src
|
||||
then "wheel"
|
||||
else "setuptools"
|
||||
else "pyproject"
|
||||
);
|
||||
mkDerivation.buildInputs =
|
||||
lib.optionals
|
||||
(! lib.hasSuffix ".whl" config.mkDerivation.src)
|
||||
[setuptools];
|
||||
};
|
||||
|
||||
fetchers = {
|
||||
|
Loading…
Reference in New Issue
Block a user