Merge pull request #171580 from adisbladis/poetry2nix-1_28_0
poetry2nix: 1.27.1 -> 1.28.0
This commit is contained in:
commit
98df69fed4
4 changed files with 262 additions and 12 deletions
|
@ -5,7 +5,7 @@
|
||||||
}:
|
}:
|
||||||
let
|
let
|
||||||
# Poetry2nix version
|
# Poetry2nix version
|
||||||
version = "1.27.1";
|
version = "1.28.0";
|
||||||
|
|
||||||
inherit (poetryLib) isCompatible readTOML moduleName;
|
inherit (poetryLib) isCompatible readTOML moduleName;
|
||||||
|
|
||||||
|
@ -287,12 +287,20 @@ lib.makeScope pkgs.newScope (self: {
|
||||||
(name: value: projectDir + "/${value.path}")
|
(name: value: projectDir + "/${value.path}")
|
||||||
(lib.filterAttrs (name: dep: dep.develop or false && hasAttr "path" dep) set);
|
(lib.filterAttrs (name: dep: dep.develop or false && hasAttr "path" dep) set);
|
||||||
|
|
||||||
editablePackageSources' = (
|
excludedEditablePackageNames = builtins.filter
|
||||||
|
(pkg: editablePackageSources."${pkg}" == null)
|
||||||
|
(builtins.attrNames editablePackageSources);
|
||||||
|
|
||||||
|
allEditablePackageSources = (
|
||||||
(getEditableDeps (pyProject.tool.poetry."dependencies" or { }))
|
(getEditableDeps (pyProject.tool.poetry."dependencies" or { }))
|
||||||
// (getEditableDeps (pyProject.tool.poetry."dev-dependencies" or { }))
|
// (getEditableDeps (pyProject.tool.poetry."dev-dependencies" or { }))
|
||||||
// editablePackageSources
|
// editablePackageSources
|
||||||
);
|
);
|
||||||
|
|
||||||
|
editablePackageSources' = builtins.removeAttrs
|
||||||
|
allEditablePackageSources
|
||||||
|
excludedEditablePackageNames;
|
||||||
|
|
||||||
poetryPython = self.mkPoetryPackages {
|
poetryPython = self.mkPoetryPackages {
|
||||||
inherit pyproject poetrylock overrides python pwd preferWheels pyProject;
|
inherit pyproject poetrylock overrides python pwd preferWheels pyProject;
|
||||||
editablePackageSources = editablePackageSources';
|
editablePackageSources = editablePackageSources';
|
||||||
|
|
|
@ -180,7 +180,7 @@ let
|
||||||
hasGitIgnore = builtins.pathExists gitIgnore;
|
hasGitIgnore = builtins.pathExists gitIgnore;
|
||||||
gitIgnores = if hasGitIgnore then [ gitIgnore ] else [ ];
|
gitIgnores = if hasGitIgnore then [ gitIgnore ] else [ ];
|
||||||
in
|
in
|
||||||
lib.optionals (builtins.toString path != "/" && ! isGitRoot) (findGitIgnores parent) ++ gitIgnores;
|
lib.optionals (builtins.pathExists path && builtins.toString path != "/" && ! isGitRoot) (findGitIgnores parent) ++ gitIgnores;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
Provides a source filtering mechanism that:
|
Provides a source filtering mechanism that:
|
||||||
|
|
|
@ -29,6 +29,9 @@
|
||||||
"aioflo": [
|
"aioflo": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
"aiogithubapi": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
"aioguardian": [
|
"aioguardian": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
@ -89,9 +92,21 @@
|
||||||
"amqtt": [
|
"amqtt": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
"ansible-doctor": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
|
"ansible-later": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
|
"ansible-runner": [
|
||||||
|
"pbr"
|
||||||
|
],
|
||||||
"apache-beam": [
|
"apache-beam": [
|
||||||
"cython"
|
"cython"
|
||||||
],
|
],
|
||||||
|
"aplpy": [
|
||||||
|
"cython"
|
||||||
|
],
|
||||||
"argon2_cffi": [
|
"argon2_cffi": [
|
||||||
"flitBuildHook"
|
"flitBuildHook"
|
||||||
],
|
],
|
||||||
|
@ -114,15 +129,24 @@
|
||||||
"atomman": [
|
"atomman": [
|
||||||
"cython"
|
"cython"
|
||||||
],
|
],
|
||||||
|
"atpublic": [
|
||||||
|
"pdm-pep517"
|
||||||
|
],
|
||||||
"autarco": [
|
"autarco": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
"authcaptureproxy": [
|
"authcaptureproxy": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
"av": [
|
||||||
|
"cython"
|
||||||
|
],
|
||||||
"awesomeversion": [
|
"awesomeversion": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
"aws-adfs": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
"aws-error-utils": [
|
"aws-error-utils": [
|
||||||
"poetry"
|
"poetry"
|
||||||
],
|
],
|
||||||
|
@ -147,6 +171,9 @@
|
||||||
"boltztrap2": [
|
"boltztrap2": [
|
||||||
"cython"
|
"cython"
|
||||||
],
|
],
|
||||||
|
"bsblan": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
"build": [
|
"build": [
|
||||||
"flit-core"
|
"flit-core"
|
||||||
],
|
],
|
||||||
|
@ -183,6 +210,9 @@
|
||||||
"clikit": [
|
"clikit": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
"cloudflare-dyndns": [
|
||||||
|
"poetry"
|
||||||
|
],
|
||||||
"collections-extended": [
|
"collections-extended": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
@ -210,7 +240,8 @@
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
"cssselect2": [
|
"cssselect2": [
|
||||||
"flit"
|
"flit",
|
||||||
|
"flit-core"
|
||||||
],
|
],
|
||||||
"cwcwidth": [
|
"cwcwidth": [
|
||||||
"cython"
|
"cython"
|
||||||
|
@ -224,9 +255,15 @@
|
||||||
"cypari2": [
|
"cypari2": [
|
||||||
"cython"
|
"cython"
|
||||||
],
|
],
|
||||||
|
"cypherpunkpay": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
"cysignals": [
|
"cysignals": [
|
||||||
"cython"
|
"cython"
|
||||||
],
|
],
|
||||||
|
"datadog": [
|
||||||
|
"hatchling"
|
||||||
|
],
|
||||||
"datrie": [
|
"datrie": [
|
||||||
"cython"
|
"cython"
|
||||||
],
|
],
|
||||||
|
@ -260,6 +297,9 @@
|
||||||
"doc8": [
|
"doc8": [
|
||||||
"pbr"
|
"pbr"
|
||||||
],
|
],
|
||||||
|
"docstring-parser": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
"dtlssocket": [
|
"dtlssocket": [
|
||||||
"cython"
|
"cython"
|
||||||
],
|
],
|
||||||
|
@ -301,7 +341,8 @@
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
"entrypoints": [
|
"entrypoints": [
|
||||||
"flit"
|
"flit",
|
||||||
|
"flit-core"
|
||||||
],
|
],
|
||||||
"enturclient": [
|
"enturclient": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
|
@ -309,6 +350,13 @@
|
||||||
"enumatch": [
|
"enumatch": [
|
||||||
"poetry"
|
"poetry"
|
||||||
],
|
],
|
||||||
|
"exceptiongroup": [
|
||||||
|
"flit-core",
|
||||||
|
"flitBuildHook"
|
||||||
|
],
|
||||||
|
"falcon": [
|
||||||
|
"cython"
|
||||||
|
],
|
||||||
"fastapi": [
|
"fastapi": [
|
||||||
"flitBuildHook"
|
"flitBuildHook"
|
||||||
],
|
],
|
||||||
|
@ -378,6 +426,9 @@
|
||||||
"generic": [
|
"generic": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
"gensim": [
|
||||||
|
"cython"
|
||||||
|
],
|
||||||
"glances-api": [
|
"glances-api": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
@ -492,9 +543,15 @@
|
||||||
"ipwhl": [
|
"ipwhl": [
|
||||||
"flitBuildHook"
|
"flitBuildHook"
|
||||||
],
|
],
|
||||||
|
"iso8601": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
"isort": [
|
"isort": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
"jarowinkler": [
|
||||||
|
"cython"
|
||||||
|
],
|
||||||
"jedi-language-server": [
|
"jedi-language-server": [
|
||||||
"poetry"
|
"poetry"
|
||||||
],
|
],
|
||||||
|
@ -519,6 +576,12 @@
|
||||||
"jupyterlab": [
|
"jupyterlab": [
|
||||||
"jupyter-packaging"
|
"jupyter-packaging"
|
||||||
],
|
],
|
||||||
|
"jupyterlab-code-formatter": [
|
||||||
|
"jupyter-packaging"
|
||||||
|
],
|
||||||
|
"jupyterlab-pygments": [
|
||||||
|
"jupyter-packaging"
|
||||||
|
],
|
||||||
"keystoneauth1": [
|
"keystoneauth1": [
|
||||||
"pbr"
|
"pbr"
|
||||||
],
|
],
|
||||||
|
@ -537,6 +600,9 @@
|
||||||
"ldappool": [
|
"ldappool": [
|
||||||
"pbr"
|
"pbr"
|
||||||
],
|
],
|
||||||
|
"levenshtein": [
|
||||||
|
"cython"
|
||||||
|
],
|
||||||
"libgpuarray": [
|
"libgpuarray": [
|
||||||
"cython"
|
"cython"
|
||||||
],
|
],
|
||||||
|
@ -564,6 +630,9 @@
|
||||||
"lockfile": [
|
"lockfile": [
|
||||||
"pbr"
|
"pbr"
|
||||||
],
|
],
|
||||||
|
"lsassy": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
"luftdaten": [
|
"luftdaten": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
@ -585,6 +654,9 @@
|
||||||
"marisa-trie": [
|
"marisa-trie": [
|
||||||
"cython"
|
"cython"
|
||||||
],
|
],
|
||||||
|
"markdown-it-py": [
|
||||||
|
"flit-core"
|
||||||
|
],
|
||||||
"mask-rcnn": [
|
"mask-rcnn": [
|
||||||
"cython"
|
"cython"
|
||||||
],
|
],
|
||||||
|
@ -607,6 +679,9 @@
|
||||||
"memory-allocator": [
|
"memory-allocator": [
|
||||||
"cython"
|
"cython"
|
||||||
],
|
],
|
||||||
|
"meteofrance-api": [
|
||||||
|
"poetry"
|
||||||
|
],
|
||||||
"metprint": [
|
"metprint": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
@ -618,6 +693,7 @@
|
||||||
"poetry"
|
"poetry"
|
||||||
],
|
],
|
||||||
"mkdocs-jupyter": [
|
"mkdocs-jupyter": [
|
||||||
|
"ipython_genutils",
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
"mkdocs-literate-nav": [
|
"mkdocs-literate-nav": [
|
||||||
|
@ -674,6 +750,9 @@
|
||||||
"netdata": [
|
"netdata": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
"netutils": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
"newversion": [
|
"newversion": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
@ -689,6 +768,9 @@
|
||||||
"nkdfu": [
|
"nkdfu": [
|
||||||
"flitBuildHook"
|
"flitBuildHook"
|
||||||
],
|
],
|
||||||
|
"notebook-shim": [
|
||||||
|
"jupyter-packaging"
|
||||||
|
],
|
||||||
"notus-scanner": [
|
"notus-scanner": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
@ -728,6 +810,9 @@
|
||||||
"openvino": [
|
"openvino": [
|
||||||
"cython"
|
"cython"
|
||||||
],
|
],
|
||||||
|
"ordered-set": [
|
||||||
|
"flit-core"
|
||||||
|
],
|
||||||
"ormar": [
|
"ormar": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
@ -807,6 +892,9 @@
|
||||||
"poetry": [
|
"poetry": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
"poetry-dynamic-versioning": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
"poetry2conda": [
|
"poetry2conda": [
|
||||||
"poetry"
|
"poetry"
|
||||||
],
|
],
|
||||||
|
@ -930,6 +1018,9 @@
|
||||||
"pymaven-patch": [
|
"pymaven-patch": [
|
||||||
"pbr"
|
"pbr"
|
||||||
],
|
],
|
||||||
|
"pymdown-extensions": [
|
||||||
|
"hatchling"
|
||||||
|
],
|
||||||
"pymfy": [
|
"pymfy": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
@ -954,6 +1045,9 @@
|
||||||
"pyoverkiz": [
|
"pyoverkiz": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
"pyparsing": [
|
||||||
|
"flit-core"
|
||||||
|
],
|
||||||
"pypass": [
|
"pypass": [
|
||||||
"pbr"
|
"pbr"
|
||||||
],
|
],
|
||||||
|
@ -978,12 +1072,21 @@
|
||||||
"pyproject-flake8": [
|
"pyproject-flake8": [
|
||||||
"flit-core"
|
"flit-core"
|
||||||
],
|
],
|
||||||
|
"pypsrp": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
"pyquil": [
|
"pyquil": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
"pyrad": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
"pyregion": [
|
"pyregion": [
|
||||||
"cython"
|
"cython"
|
||||||
],
|
],
|
||||||
|
"pyrevolve": [
|
||||||
|
"cython"
|
||||||
|
],
|
||||||
"pyrmvtransport": [
|
"pyrmvtransport": [
|
||||||
"flit"
|
"flit"
|
||||||
],
|
],
|
||||||
|
@ -999,6 +1102,9 @@
|
||||||
"pysigma": [
|
"pysigma": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
"pysigma-backend-insightidr": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
"pysigma-backend-splunk": [
|
"pysigma-backend-splunk": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
@ -1008,14 +1114,30 @@
|
||||||
"pysigma-pipeline-sysmon": [
|
"pysigma-pipeline-sysmon": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
"pysigma-pipeline-windows": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
|
"pyslurm": [
|
||||||
|
"cython"
|
||||||
|
],
|
||||||
"pysmf": [
|
"pysmf": [
|
||||||
"cython"
|
"cython"
|
||||||
],
|
],
|
||||||
"pysml": [
|
"pysml": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
"pysnmp-pyasn1": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
|
"pysnmp-pysmi": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
|
"pysnmplib": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
"pysnow": [
|
"pysnow": [
|
||||||
"poetry"
|
"poetry",
|
||||||
|
"poetry-core"
|
||||||
],
|
],
|
||||||
"pysptk": [
|
"pysptk": [
|
||||||
"cython"
|
"cython"
|
||||||
|
@ -1035,6 +1157,9 @@
|
||||||
"pytest-httpserver": [
|
"pytest-httpserver": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
"pytest-isort": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
"pytest-mockservers": [
|
"pytest-mockservers": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
@ -1097,6 +1222,9 @@
|
||||||
"python-openstackclient": [
|
"python-openstackclient": [
|
||||||
"pbr"
|
"pbr"
|
||||||
],
|
],
|
||||||
|
"python-pae": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
"python-pkcs11": [
|
"python-pkcs11": [
|
||||||
"cython"
|
"cython"
|
||||||
],
|
],
|
||||||
|
@ -1215,7 +1343,8 @@
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
"rokuecp": [
|
"rokuecp": [
|
||||||
"poetry"
|
"poetry",
|
||||||
|
"poetry-core"
|
||||||
],
|
],
|
||||||
"roombapy": [
|
"roombapy": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
|
@ -1280,6 +1409,9 @@
|
||||||
"sentinel": [
|
"sentinel": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
"seventeentrack": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
"sfepy": [
|
"sfepy": [
|
||||||
"cython"
|
"cython"
|
||||||
],
|
],
|
||||||
|
@ -1301,9 +1433,15 @@
|
||||||
"slowapi": [
|
"slowapi": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
"socksio": [
|
||||||
|
"flit-core"
|
||||||
|
],
|
||||||
"solo-python": [
|
"solo-python": [
|
||||||
"flitBuildHook"
|
"flitBuildHook"
|
||||||
],
|
],
|
||||||
|
"soupsieve": [
|
||||||
|
"hatchling"
|
||||||
|
],
|
||||||
"spacy-pkuseg": [
|
"spacy-pkuseg": [
|
||||||
"cython"
|
"cython"
|
||||||
],
|
],
|
||||||
|
@ -1425,7 +1563,8 @@
|
||||||
"cython"
|
"cython"
|
||||||
],
|
],
|
||||||
"testpath": [
|
"testpath": [
|
||||||
"flit"
|
"flit",
|
||||||
|
"flit-core"
|
||||||
],
|
],
|
||||||
"testrepository": [
|
"testrepository": [
|
||||||
"pbr"
|
"pbr"
|
||||||
|
@ -1505,6 +1644,9 @@
|
||||||
"typing-extensions": [
|
"typing-extensions": [
|
||||||
"flit-core"
|
"flit-core"
|
||||||
],
|
],
|
||||||
|
"uharfbuzz": [
|
||||||
|
"cython"
|
||||||
|
],
|
||||||
"unpaddedbase64": [
|
"unpaddedbase64": [
|
||||||
"poetry-core"
|
"poetry-core"
|
||||||
],
|
],
|
||||||
|
@ -1550,8 +1692,14 @@
|
||||||
"yoda": [
|
"yoda": [
|
||||||
"cython"
|
"cython"
|
||||||
],
|
],
|
||||||
|
"yte": [
|
||||||
|
"poetry-core"
|
||||||
|
],
|
||||||
"zeversolarlocal": [
|
"zeversolarlocal": [
|
||||||
"flit-core",
|
"flit-core",
|
||||||
"flitBuildHook"
|
"flitBuildHook"
|
||||||
|
],
|
||||||
|
"zwave-me-ws": [
|
||||||
|
"poetry-core"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
|
@ -8,13 +8,14 @@ let
|
||||||
{ self
|
{ self
|
||||||
, drv
|
, drv
|
||||||
, attr
|
, attr
|
||||||
|
, extraAttrs ? [ ]
|
||||||
}:
|
}:
|
||||||
let
|
let
|
||||||
buildSystem = if attr == "cython" then self.python.pythonForBuild.pkgs.cython else self.${attr};
|
buildSystem = if attr == "cython" then self.python.pythonForBuild.pkgs.cython else self.${attr};
|
||||||
in
|
in
|
||||||
(
|
(
|
||||||
# Flit only works on Python3
|
# Flit only works on Python3
|
||||||
if (attr == "flit-core" || attr == "flit") && !self.isPy3k then drv
|
if (attr == "flit-core" || attr == "flit" || attr == "hatchling") && !self.isPy3k then drv
|
||||||
else
|
else
|
||||||
drv.overridePythonAttrs (
|
drv.overridePythonAttrs (
|
||||||
old:
|
old:
|
||||||
|
@ -23,7 +24,7 @@ let
|
||||||
{ }
|
{ }
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
nativeBuildInputs = (old.nativeBuildInputs or [ ]) ++ [ self.${attr} ];
|
nativeBuildInputs = (old.nativeBuildInputs or [ ]) ++ [ self.${attr} ] ++ map (a: self.${a}) extraAttrs;
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
@ -55,6 +56,16 @@ lib.composeManyExtensions [
|
||||||
systems)
|
systems)
|
||||||
buildSystems)
|
buildSystems)
|
||||||
|
|
||||||
|
# Build systems with conditionals
|
||||||
|
(self: super: {
|
||||||
|
|
||||||
|
platformdirs =
|
||||||
|
if lib.versionAtLeast super.platformdirs.version "2.5.2"
|
||||||
|
then addBuildSystem { inherit self; drv = super.platformdirs; attr = "hatchling"; extraAttrs = [ "hatch-vcs" ]; }
|
||||||
|
else super.platformdirs;
|
||||||
|
|
||||||
|
})
|
||||||
|
|
||||||
# Build fixes
|
# Build fixes
|
||||||
(self: super:
|
(self: super:
|
||||||
let
|
let
|
||||||
|
@ -437,6 +448,17 @@ lib.composeManyExtensions [
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
# Setuptools >= 60 broke build_py_2to3
|
||||||
|
docutils =
|
||||||
|
if lib.versionOlder super.docutils.version "0.16" && lib.versionAtLeast super.setuptools.version "60" then
|
||||||
|
(
|
||||||
|
super.docutils.overridePythonAttrs (
|
||||||
|
old: {
|
||||||
|
SETUPTOOLS_USE_DISTUTILS = "stdlib";
|
||||||
|
}
|
||||||
|
)
|
||||||
|
) else super.docutils;
|
||||||
|
|
||||||
# Environment markers are not always included (depending on how a dep was defined)
|
# Environment markers are not always included (depending on how a dep was defined)
|
||||||
enum34 = if self.pythonAtLeast "3.4" then null else super.enum34;
|
enum34 = if self.pythonAtLeast "3.4" then null else super.enum34;
|
||||||
|
|
||||||
|
@ -844,6 +866,17 @@ lib.composeManyExtensions [
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
lsassy =
|
||||||
|
if super.lsassy.version == "3.1.1" then
|
||||||
|
super.lsassy.overridePythonAttrs
|
||||||
|
(old: {
|
||||||
|
# pyproject.toml contains a constraint `rich = "^10.6.0"` which is not replicated in setup.py
|
||||||
|
# hence pypi misses it and poetry pins rich to 11.0.0
|
||||||
|
preConfigure = (old.preConfigure or "") + ''
|
||||||
|
rm pyproject.toml
|
||||||
|
'';
|
||||||
|
}) else super.lsassy;
|
||||||
|
|
||||||
lxml = super.lxml.overridePythonAttrs (
|
lxml = super.lxml.overridePythonAttrs (
|
||||||
old: {
|
old: {
|
||||||
nativeBuildInputs = with pkgs.buildPackages; (old.nativeBuildInputs or [ ]) ++ [ pkg-config libxml2.dev libxslt.dev ] ++ lib.optionals stdenv.isDarwin [ xcodebuild ];
|
nativeBuildInputs = with pkgs.buildPackages; (old.nativeBuildInputs or [ ]) ++ [ pkg-config libxml2.dev libxslt.dev ] ++ lib.optionals stdenv.isDarwin [ xcodebuild ];
|
||||||
|
@ -1143,6 +1176,26 @@ lib.composeManyExtensions [
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
orjson =
|
||||||
|
let
|
||||||
|
getCargoHash = version: {
|
||||||
|
"3.6.7" = "sha256-sz2k9podPB6QSptkyOu7+BoVTrKhefizRtYU+MICPt4=";
|
||||||
|
"3.6.8" = "sha256-vpfceVtYkU09xszNIihY1xbqGWieqDquxwsAmDH8jd4=";
|
||||||
|
}.${version} or null;
|
||||||
|
in
|
||||||
|
super.orjson.overridePythonAttrs (old: {
|
||||||
|
cargoDeps = pkgs.rustPlatform.fetchCargoTarball {
|
||||||
|
inherit (old) src;
|
||||||
|
name = "${old.pname}-${old.version}";
|
||||||
|
hash = getCargoHash old.version;
|
||||||
|
};
|
||||||
|
nativeBuildInputs = (old.nativeBuildInputs or [ ]) ++ [
|
||||||
|
pkgs.rustPlatform.cargoSetupHook
|
||||||
|
pkgs.rustPlatform.maturinBuildHook
|
||||||
|
];
|
||||||
|
buildInputs = (old.buildInputs or [ ]) ++ lib.optional pkgs.stdenv.isDarwin pkgs.libiconv;
|
||||||
|
});
|
||||||
|
|
||||||
osqp = super.osqp.overridePythonAttrs (
|
osqp = super.osqp.overridePythonAttrs (
|
||||||
old: {
|
old: {
|
||||||
nativeBuildInputs = (old.nativeBuildInputs or [ ]) ++ [ pkgs.cmake ];
|
nativeBuildInputs = (old.nativeBuildInputs or [ ]) ++ [ pkgs.cmake ];
|
||||||
|
@ -1150,6 +1203,29 @@ lib.composeManyExtensions [
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
|
pandas = super.pandas.overridePythonAttrs (old: {
|
||||||
|
|
||||||
|
buildInputs = old.buildInputs or [ ] ++ lib.optional stdenv.isDarwin pkgs.libcxx;
|
||||||
|
|
||||||
|
# Doesn't work with -Werror,-Wunused-command-line-argument
|
||||||
|
# https://github.com/NixOS/nixpkgs/issues/39687
|
||||||
|
hardeningDisable = lib.optional stdenv.cc.isClang "strictoverflow";
|
||||||
|
|
||||||
|
# For OSX, we need to add a dependency on libcxx, which provides
|
||||||
|
# `complex.h` and other libraries that pandas depends on to build.
|
||||||
|
postPatch = lib.optionalString stdenv.isDarwin ''
|
||||||
|
cpp_sdk="${lib.getDev pkgs.libcxx}/include/c++/v1";
|
||||||
|
echo "Adding $cpp_sdk to the setup.py common_include variable"
|
||||||
|
substituteInPlace setup.py \
|
||||||
|
--replace "['pandas/src/klib', 'pandas/src']" \
|
||||||
|
"['pandas/src/klib', 'pandas/src', '$cpp_sdk']"
|
||||||
|
'';
|
||||||
|
|
||||||
|
|
||||||
|
enableParallelBuilding = true;
|
||||||
|
});
|
||||||
|
|
||||||
pantalaimon = super.pantalaimon.overridePythonAttrs (old: {
|
pantalaimon = super.pantalaimon.overridePythonAttrs (old: {
|
||||||
nativeBuildInputs = old.nativeBuildInputs or [ ] ++ [ pkgs.installShellFiles ];
|
nativeBuildInputs = old.nativeBuildInputs or [ ] ++ [ pkgs.installShellFiles ];
|
||||||
postInstall = old.postInstall or "" + ''
|
postInstall = old.postInstall or "" + ''
|
||||||
|
@ -1196,8 +1272,12 @@ lib.composeManyExtensions [
|
||||||
|
|
||||||
pillow = super.pillow.overridePythonAttrs (
|
pillow = super.pillow.overridePythonAttrs (
|
||||||
old: {
|
old: {
|
||||||
nativeBuildInputs = [ pkg-config self.pytest-runner ] ++ (old.nativeBuildInputs or [ ]);
|
nativeBuildInputs = (old.nativeBuildInputs or [ ])
|
||||||
buildInputs = with pkgs; [ freetype libjpeg zlib libtiff libwebp tcl lcms2 ] ++ (old.buildInputs or [ ]);
|
++ [ pkg-config self.pytest-runner ];
|
||||||
|
buildInputs = with pkgs; (old.buildInputs or [ ])
|
||||||
|
++ [ freetype libjpeg zlib libtiff libwebp tcl lcms2 ]
|
||||||
|
++ lib.optionals (lib.versionAtLeast old.version "7.1.0") [ xorg.libxcb ]
|
||||||
|
++ lib.optionals (self.isPyPy) [ tk xorg.libX11 ];
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
@ -1246,6 +1326,14 @@ lib.composeManyExtensions [
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
psycopg2cffi = super.psycopg2cffi.overridePythonAttrs (
|
||||||
|
old: {
|
||||||
|
buildInputs = (old.buildInputs or [ ])
|
||||||
|
++ lib.optional stdenv.isDarwin pkgs.openssl;
|
||||||
|
nativeBuildInputs = (old.nativeBuildInputs or [ ]) ++ [ pkgs.postgresql ];
|
||||||
|
}
|
||||||
|
);
|
||||||
|
|
||||||
py-solc-x = super.py-solc-x.overridePythonAttrs (
|
py-solc-x = super.py-solc-x.overridePythonAttrs (
|
||||||
old: {
|
old: {
|
||||||
preConfigure = ''
|
preConfigure = ''
|
||||||
|
@ -1860,6 +1948,12 @@ lib.composeManyExtensions [
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
|
soundfile = super.soundfile.overridePythonAttrs (old: {
|
||||||
|
postPatch = ''
|
||||||
|
substituteInPlace soundfile.py --replace "_find_library('sndfile')" "'${pkgs.libsndfile.out}/lib/libsndfile${stdenv.hostPlatform.extensions.sharedLibrary}'"
|
||||||
|
'';
|
||||||
|
});
|
||||||
|
|
||||||
systemd-python = super.systemd-python.overridePythonAttrs (old: {
|
systemd-python = super.systemd-python.overridePythonAttrs (old: {
|
||||||
buildInputs = old.buildInputs ++ [ pkgs.systemd ];
|
buildInputs = old.buildInputs ++ [ pkgs.systemd ];
|
||||||
nativeBuildInputs = old.nativeBuildInputs ++ [ pkgs.pkg-config ];
|
nativeBuildInputs = old.nativeBuildInputs ++ [ pkgs.pkg-config ];
|
||||||
|
|
Loading…
Reference in a new issue