3
0
Fork 0
forked from mirrors/nixpkgs

Merge pull request #197604 from wegank/cvxpy-aarch64-darwin

python310Packages.cvxpy: fix build
This commit is contained in:
Fabian Affolter 2022-10-30 21:17:18 +01:00 committed by GitHub
commit 946ff82ce0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 0 deletions

View file

@ -9,6 +9,7 @@
, osqp
, scipy
, scs
, setuptools
, useOpenmp ? (!stdenv.isDarwin)
# Check inputs
, pytestCheckHook
@ -33,6 +34,7 @@ buildPythonPackage rec {
osqp
scipy
scs
setuptools
];
# Required flags from https://github.com/cvxgrp/cvxpy/releases/tag/v1.1.11
@ -49,6 +51,8 @@ buildPythonPackage rec {
disabledTests = [
"test_tv_inpainting"
"test_diffcp_sdp_example"
"test_huber"
"test_partial_problem"
] ++ lib.optionals stdenv.isAarch64 [
"test_ecos_bb_mi_lp_2" # https://github.com/cvxgrp/cvxpy/issues/1241#issuecomment-780912155
];

View file

@ -24,6 +24,10 @@ buildPythonPackage rec {
hash = "sha256-svoXquQqftSY7CYbM/Jiu0s2BefoRkBiFZ2froF/DWE=";
};
postPatch = ''
sed -i 's/sp.random/np.random/g' src/osqp/tests/*.py
'';
SETUPTOOLS_SCM_PRETEND_VERSION = version;
dontUseCmakeConfigure = true;