diff options
author | Frederik Rietdijk <fridh@fridh.nl> | 2017-12-30 15:33:59 +0100 |
---|---|---|
committer | Frederik Rietdijk <fridh@fridh.nl> | 2017-12-30 17:09:09 +0100 |
commit | 5920579a3dbdd2fddb9e60ff47029858e61fc53a (patch) | |
tree | 3cdb99231b26130dd1368b1a265a8cd030a9f2e7 /pkgs/development/interpreters | |
parent | 2d0bead714eb5f99a08c54a3b25cd84379c251c2 (diff) | |
download | nixlib-5920579a3dbdd2fddb9e60ff47029858e61fc53a.tar nixlib-5920579a3dbdd2fddb9e60ff47029858e61fc53a.tar.gz nixlib-5920579a3dbdd2fddb9e60ff47029858e61fc53a.tar.bz2 nixlib-5920579a3dbdd2fddb9e60ff47029858e61fc53a.tar.lz nixlib-5920579a3dbdd2fddb9e60ff47029858e61fc53a.tar.xz nixlib-5920579a3dbdd2fddb9e60ff47029858e61fc53a.tar.zst nixlib-5920579a3dbdd2fddb9e60ff47029858e61fc53a.zip |
Python: disable user site-packages in setup hook
Wrappers already included `PYTHONNOUSERSITE=1`, but now this env var is also set in the Python setup hook. This improves purity in case of non-sandboxes builds and nix-shell.
Diffstat (limited to 'pkgs/development/interpreters')
-rw-r--r-- | pkgs/development/interpreters/python/setup-hook.sh | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/pkgs/development/interpreters/python/setup-hook.sh b/pkgs/development/interpreters/python/setup-hook.sh index dda9bed39f85..35726280a75f 100644 --- a/pkgs/development/interpreters/python/setup-hook.sh +++ b/pkgs/development/interpreters/python/setup-hook.sh @@ -19,3 +19,6 @@ envHooks+=(addPythonPath) export DETERMINISTIC_BUILD=1; # Determinism: We fix the hashes of str, bytes and datetime objects. export PYTHONHASHSEED=0; +# Determinism. Whenever Python is included, it should not check user site-packages. +# This option is only relevant when the sandbox is disabled. +export PYTHONNOUSERSITE=1; |