about summary refs log tree commit diff
diff options
context:
space:
mode:
authorRobert Schütz <nix@dotlambda.de>2023-10-26 20:28:06 -0700
committerGitHub <noreply@github.com>2023-10-26 20:28:06 -0700
commitc585eaf8d88cbcd32935f7865f1e2568f8f5e9ce (patch)
tree4e1d0f475ee2a1039f549c648a6cfe59df8c66d7
parent65f93084d588187d32d48a1c95929e9098e15af3 (diff)
parent03170e3f52ca9c87dba791935985392e02dab302 (diff)
downloadnixlib-c585eaf8d88cbcd32935f7865f1e2568f8f5e9ce.tar
nixlib-c585eaf8d88cbcd32935f7865f1e2568f8f5e9ce.tar.gz
nixlib-c585eaf8d88cbcd32935f7865f1e2568f8f5e9ce.tar.bz2
nixlib-c585eaf8d88cbcd32935f7865f1e2568f8f5e9ce.tar.lz
nixlib-c585eaf8d88cbcd32935f7865f1e2568f8f5e9ce.tar.xz
nixlib-c585eaf8d88cbcd32935f7865f1e2568f8f5e9ce.tar.zst
nixlib-c585eaf8d88cbcd32935f7865f1e2568f8f5e9ce.zip
Merge pull request #263500 from vancluever/vancluever-python311Packages.keyutils-fix-build
python311Packages.keyutils: fix build
-rw-r--r--pkgs/development/python-modules/keyutils/default.nix21
1 files changed, 19 insertions, 2 deletions
diff --git a/pkgs/development/python-modules/keyutils/default.nix b/pkgs/development/python-modules/keyutils/default.nix
index 031ae5a65c39..c387c10ebc34 100644
--- a/pkgs/development/python-modules/keyutils/default.nix
+++ b/pkgs/development/python-modules/keyutils/default.nix
@@ -1,4 +1,10 @@
-{ lib, buildPythonPackage, fetchFromGitHub, keyutils, pytest-runner, pytest }:
+{ lib
+, buildPythonPackage
+, cython
+, fetchFromGitHub
+, keyutils
+, pytestCheckHook
+}:
 
 buildPythonPackage rec {
   pname = "keyutils";
@@ -16,8 +22,19 @@ buildPythonPackage rec {
     substituteInPlace setup.py --replace '"pytest-runner"' ""
   '';
 
+  preBuild = ''
+    cython keyutils/_keyutils.pyx
+  '';
+
+  preCheck = ''
+    rm -rf keyutils
+  '';
+
   buildInputs = [ keyutils ];
-  nativeCheckInputs = [ pytest pytest-runner ];
+  nativeBuildInputs = [ cython ];
+  nativeCheckInputs = [
+    pytestCheckHook
+  ];
 
   meta = {
     description = "A set of python bindings for keyutils";