Skip to content

Commit 1e1c168

Browse files
committed
restore versioned launchers in venv + cleanup
1 parent 2293bf6 commit 1e1c168

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

Lib/venv/__init__.py

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -376,8 +376,18 @@ def setup_python(self, context):
376376
f'pythonw{exe_t}{exe_d}.exe': pythonw_exe,
377377
}
378378

379+
if sys._is_mingw:
380+
for key, value in list(link_sources.items()):
381+
if key.startswith('python'):
382+
link_sources[key.replace('python', 'python3')] = value
383+
link_sources[key.replace('python', f'python3.{sys.version_info[1]}')] = value
384+
for key, value in list(copy_sources.items()):
385+
if key.startswith('python'):
386+
copy_sources[key.replace('python', 'python3')] = value
387+
copy_sources[key.replace('python', f'python3.{sys.version_info[1]}')] = value
388+
379389
do_copies = True
380-
if self.symlinks:
390+
if self.symlinks and not sys._is_mingw:
381391
do_copies = False
382392
# For symlinking, we need all the DLLs to be available alongside
383393
# the executables.

0 commit comments

Comments
 (0)