summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Lib/venv/__init__.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/Lib/venv/__init__.py b/Lib/venv/__init__.py
index ce1f5d7..6f1af29 100644
--- a/Lib/venv/__init__.py
+++ b/Lib/venv/__init__.py
@@ -281,8 +281,9 @@ class EnvBuilder:
os.path.normcase(f).startswith(('python', 'vcruntime'))
]
else:
- suffixes = ['python.exe', 'python_d.exe', 'pythonw.exe',
- 'pythonw_d.exe']
+ suffixes = {'python.exe', 'python_d.exe', 'pythonw.exe', 'pythonw_d.exe'}
+ base_exe = os.path.basename(context.env_exe)
+ suffixes.add(base_exe)
for suffix in suffixes:
src = os.path.join(dirname, suffix)