diff options
author | Vinay Sajip <vinay_sajip@yahoo.co.uk> | 2014-05-28 07:06:24 (GMT) |
---|---|---|
committer | Vinay Sajip <vinay_sajip@yahoo.co.uk> | 2014-05-28 07:06:24 (GMT) |
commit | 432810f9f35c014afecbd24edda6b26a3cf04fd9 (patch) | |
tree | 92f337986c193237ab8ccfa43ca17ff4a8ffef66 /Lib/venv | |
parent | 3207a03035deabbff8a68f4f29dc33d1da944801 (diff) | |
download | cpython-432810f9f35c014afecbd24edda6b26a3cf04fd9.zip cpython-432810f9f35c014afecbd24edda6b26a3cf04fd9.tar.gz cpython-432810f9f35c014afecbd24edda6b26a3cf04fd9.tar.bz2 |
Issue #18807: If copying (no symlinks) specified for a venv, then the python interpreter aliases (python, python3) are now created by copying rather than symlinking.
Diffstat (limited to 'Lib/venv')
-rw-r--r-- | Lib/venv/__init__.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Lib/venv/__init__.py b/Lib/venv/__init__.py index 20dafc0..252bffb 100644 --- a/Lib/venv/__init__.py +++ b/Lib/venv/__init__.py @@ -212,7 +212,10 @@ class EnvBuilder: for suffix in ('python', 'python3'): path = os.path.join(binpath, suffix) if not os.path.exists(path): - os.symlink(exename, path) + # Issue 18807: make copies if + # symlinks are not wanted + copier(context.env_exe, path) + os.chmod(path, 0o755) else: subdir = 'DLLs' include = self.include_binary |