mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-15 10:12:58 +00:00
python: execute pythonImportsCheckPhase in subshell
Execute in subshell so that the cwd returns back to the original directory. This is important as it enables pythonImportsCheck to work with checkPhase
This commit is contained in:
parent
504f8bffaa
commit
cd97c055a0
@ -6,7 +6,7 @@ pythonImportsCheckPhase () {
|
||||
|
||||
if [ -n "$pythonImportsCheck" ]; then
|
||||
echo "Check whether the following modules can be imported: $pythonImportsCheck"
|
||||
cd $out && eval "@pythonCheckInterpreter@ -c 'import os; import importlib; list(map(lambda mod: importlib.import_module(mod), os.environ[\"pythonImportsCheck\"].split()))'"
|
||||
( cd $out && eval "@pythonCheckInterpreter@ -c 'import os; import importlib; list(map(lambda mod: importlib.import_module(mod), os.environ[\"pythonImportsCheck\"].split()))'" )
|
||||
fi
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user