From c8b2c3592c1a8dd2cc9d578e9624e3660ef34088 Mon Sep 17 00:00:00 2001 From: Theodore Ni <3806110+tjni@users.noreply.github.com> Date: Thu, 17 Aug 2023 18:11:11 -0700 Subject: [PATCH] python3.pkgs.correctionlib: clean up / fix up build dependencies --- .../python-modules/correctionlib/default.nix | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/pkgs/development/python-modules/correctionlib/default.nix b/pkgs/development/python-modules/correctionlib/default.nix index 41ac4a8f8f36..2156bd978229 100644 --- a/pkgs/development/python-modules/correctionlib/default.nix +++ b/pkgs/development/python-modules/correctionlib/default.nix @@ -1,11 +1,13 @@ { lib , buildPythonPackage +, fetchpatch , fetchPypi , cmake , numpy , scikit-build , setuptools , setuptools-scm +, wheel , pybind11 , pydantic , pytestCheckHook @@ -24,12 +26,27 @@ buildPythonPackage rec { hash = "sha256-h3eggtPLSF/8ShQ5xzowZW1KSlcI/YBsPu3lsSyzHkw="; }; + patches = [ + (fetchpatch { + name = "ci-maintenance.patch"; + url = "https://github.com/cms-nanoAOD/correctionlib/commit/924031637b040f6e8e4930c46a9f7560c59db23d.patch"; + hash = "sha256-jq3ojMsO2Ex9om8tVpEY9uwwelXPzgQ+KCPN0bgda8w="; + includes = [ "pyproject.toml" ]; + }) + (fetchpatch { + name = "clean-up-build-dependencies.patch"; + url = "https://github.com/cms-nanoAOD/correctionlib/commit/c4fd64ca0e5ce806890e8f0ae8e792dcc4537d38.patch"; + hash = "sha256-8ID2jEnmfYmPxWMtRviBc3t1W4p3Y+lAzijFtYBEtyk="; + }) + ]; + nativeBuildInputs = [ cmake numpy scikit-build setuptools setuptools-scm + wheel pybind11 ]; @@ -44,7 +61,7 @@ buildPythonPackage rec { dontUseCmakeConfigure = true; - SETUPTOOLS_SCM_PRETEND_VERSION = version; + env.SETUPTOOLS_SCM_PRETEND_VERSION = version; nativeCheckInputs = [ pytestCheckHook