mirror of
https://github.com/tahoe-lafs/tahoe-lafs.git
synced 2025-03-25 21:17:37 +00:00
Find the Python executable when building for PyPy
This commit is contained in:
parent
a80effe290
commit
538dbe5ce9
@ -1,4 +1,5 @@
|
||||
{ lib
|
||||
, python
|
||||
, pythonPackages
|
||||
, buildPythonPackage
|
||||
, tahoe-lafs-src
|
||||
@ -80,6 +81,10 @@ let
|
||||
|
||||
doUnit = builtins.elem "unit" checks;
|
||||
doIntegration = builtins.elem "integration" checks;
|
||||
|
||||
# "python" is on $PATH for the cpython case but not for the PyPy case.
|
||||
# python.executable is on $PATH for both cases.
|
||||
py = python.executable;
|
||||
in
|
||||
buildPythonPackage rec {
|
||||
inherit pname version;
|
||||
@ -142,8 +147,8 @@ buildPythonPackage rec {
|
||||
in
|
||||
''
|
||||
runHook preCheck
|
||||
${lib.optionalString doUnit "python -m twisted.trial -j $NIX_BUILD_CORES allmydata"}
|
||||
${lib.optionalString doIntegration "python -m pytest --timeout=1800 -s -v ${pytestFlags} integration"}
|
||||
${lib.optionalString doUnit "${py} -m twisted.trial -j $NIX_BUILD_CORES allmydata"}
|
||||
${lib.optionalString doIntegration "${py} -m pytest --timeout=1800 -s -v ${pytestFlags} integration"}
|
||||
runHook postCheck
|
||||
'';
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user