python3Package.albucore: fix build

pkg_resources is removed in setuptools 82 ([src][1])

  [1]: https://github.com/pypa/setuptools/blob/v82.0.0/NEWS.rst
This commit is contained in:
Andrew Marshall
2026-07-12 20:56:20 -04:00
parent e7a3ca8092
commit 8a4dad5b70
@@ -22,6 +22,13 @@ buildPythonPackage rec {
hash = "sha256-frVMPW3au/6vPRY89GIt7chCPkUMl13DpPqCPqIjz/o=";
};
postPatch = ''
substituteInPlace setup.py \
--replace-fail \
'from pkg_resources import DistributionNotFound, get_distribution' \
'from importlib.metadata import PackageNotFoundError as DistributionNotFound, distribution as get_distribution'
'';
pythonRelaxDeps = [ "opencv-python" ];
build-system = [ setuptools ];