diff options
| author | Stefano Rivera <github@rivera.za.net> | 2022-03-07 05:23:07 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-03-07 13:23:07 +0000 |
| commit | 3a90a6bb48313ad45bfc448637b91c630b5014ac (patch) | |
| tree | fb955284bc1a70d65787499479f04786def3fe4f /src/virtualenv/create | |
| parent | bb3131a36917a8100afa624b1da7e4971e23030e (diff) | |
| download | virtualenv-3a90a6bb48313ad45bfc448637b91c630b5014ac.tar.gz | |
Avoid symlinking the contents of /usr into PyPy3 virtualenvs (#2310)
Co-authored-by: Bernát Gábor <bgabor8@bloomberg.net>
Diffstat (limited to 'src/virtualenv/create')
| -rw-r--r-- | src/virtualenv/create/via_global_ref/builtin/pypy/pypy3.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/virtualenv/create/via_global_ref/builtin/pypy/pypy3.py b/src/virtualenv/create/via_global_ref/builtin/pypy/pypy3.py index f1726ec..cc72c14 100644 --- a/src/virtualenv/create/via_global_ref/builtin/pypy/pypy3.py +++ b/src/virtualenv/create/via_global_ref/builtin/pypy/pypy3.py @@ -42,6 +42,11 @@ class PyPy3Posix(PyPy3, PosixSupports): def sources(cls, interpreter): for src in super(PyPy3Posix, cls).sources(interpreter): yield src + # PyPy >= 3.8 supports a standard prefix installation, where older + # versions always used a portable/developent style installation. + # If this is a standard prefix installation, skip the below: + if interpreter.system_prefix == "/usr": + return # Also copy/symlink anything under prefix/lib, which, for "portable" # PyPy builds, includes the tk,tcl runtime and a number of shared # objects. In distro-specific builds or on conda this should be empty |
