Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at master 1.2 kB view raw
1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 replaceVars, 6 cpu_features, 7 8 # build-system 9 cmake, 10 ninja, 11 pybind11, 12 scikit-build-core, 13 14 # buildInputs 15 eigen, 16 gtest, 17 matio, 18 19 # tests 20 numpy, 21 scipy, 22 pytestCheckHook, 23}: 24buildPythonPackage rec { 25 pname = "piqp"; 26 version = "0.6.2"; 27 pyproject = true; 28 29 src = fetchFromGitHub { 30 owner = "PREDICT-EPFL"; 31 repo = "piqp"; 32 tag = "v${version}"; 33 hash = "sha256-W9t7d+wV5WcphL54e6tpnKxiWFay9UrFmIRKsGk2yMM="; 34 }; 35 36 patches = [ 37 (replaceVars ./use-nix-packages.patch { 38 cpu_features_src = cpu_features.src; 39 }) 40 ]; 41 42 build-system = [ 43 cmake 44 ninja 45 pybind11 46 scikit-build-core 47 ]; 48 dontUseCmakeConfigure = true; 49 50 buildInputs = [ 51 eigen 52 gtest 53 matio 54 ]; 55 56 pythonImportsCheck = [ "piqp" ]; 57 58 nativeCheckInputs = [ 59 numpy 60 pytestCheckHook 61 scipy 62 ]; 63 64 meta = { 65 description = "Proximal Interior Point Quadratic Programming solver"; 66 homepage = "https://github.com/PREDICT-EPFL/piqp"; 67 changelog = "https://github.com/PREDICT-EPFL/piqp/releases/tag/v${version}"; 68 license = lib.licenses.bsd2; 69 maintainers = with lib.maintainers; [ renesat ]; 70 }; 71}