buildPython*: run runtime dependency check hook for wheels

This commit is contained in:
Martin Weinelt
2026-01-14 21:50:50 +01:00
parent ef618a7ad7
commit 7465728763

View File

@@ -283,6 +283,14 @@ lib.extendMkDerivation {
name = namePrefix + attrs.name or "${finalAttrs.pname}-${finalAttrs.version}";
runtimeDepsCheckHook =
if isBootstrapPackage then
pythonRuntimeDepsCheckHook.override {
inherit (python.pythonOnBuildForHost.pkgs.bootstrap) packaging;
}
else
pythonRuntimeDepsCheckHook;
in
{
inherit name;
@@ -330,17 +338,11 @@ lib.extendMkDerivation {
else
pypaBuildHook
)
(
if isBootstrapPackage then
pythonRuntimeDepsCheckHook.override {
inherit (python.pythonOnBuildForHost.pkgs.bootstrap) packaging;
}
else
pythonRuntimeDepsCheckHook
)
runtimeDepsCheckHook
]
++ optionals (format' == "wheel") [
wheelUnpackHook
runtimeDepsCheckHook
]
++ optionals (format' == "egg") [
eggUnpackHook