@@ -373,6 +373,24 @@ pub(crate) fn create(
373373 & scripts,
374374 python_home,
375375 ) ?;
376+
377+ // If the GIL is disabled, copy `venvlaunchert.exe` and `venvwlaunchert.exe`.
378+ if interpreter. gil_disabled ( ) {
379+ copy_launcher_windows (
380+ WindowsExecutable :: PythonMajorMinort ,
381+ interpreter,
382+ & base_python,
383+ & scripts,
384+ python_home,
385+ ) ?;
386+ copy_launcher_windows (
387+ WindowsExecutable :: PythonwMajorMinort ,
388+ interpreter,
389+ & base_python,
390+ & scripts,
391+ python_home,
392+ ) ?;
393+ }
376394 }
377395 }
378396 }
@@ -590,8 +608,12 @@ enum WindowsExecutable {
590608 PythonMajor ,
591609 /// The `python3.<minor>.exe` executable (or `venvlauncher.exe` launcher shim).
592610 PythonMajorMinor ,
611+ /// The `python3.<minor>t.exe` executable (or `venvlaunchert.exe` launcher shim).
612+ PythonMajorMinort ,
593613 /// The `pythonw.exe` executable (or `venvwlauncher.exe` launcher shim).
594614 Pythonw ,
615+ /// The `pythonw3.<minor>t.exe` executable (or `venvwlaunchert.exe` launcher shim).
616+ PythonwMajorMinort ,
595617 /// The `pypy.exe` executable.
596618 PyPy ,
597619 /// The `pypy3.exe` executable.
@@ -602,7 +624,7 @@ enum WindowsExecutable {
602624 PyPyw ,
603625 /// The `pypy3.<minor>w.exe` executable.
604626 PyPyMajorMinorw ,
605- // The `graalpy.exe` executable
627+ /// The `graalpy.exe` executable.
606628 GraalPy ,
607629}
608630
@@ -621,7 +643,21 @@ impl WindowsExecutable {
621643 interpreter. python_minor( )
622644 )
623645 }
646+ WindowsExecutable :: PythonMajorMinort => {
647+ format ! (
648+ "python{}.{}t.exe" ,
649+ interpreter. python_major( ) ,
650+ interpreter. python_minor( )
651+ )
652+ }
624653 WindowsExecutable :: Pythonw => String :: from ( "pythonw.exe" ) ,
654+ WindowsExecutable :: PythonwMajorMinort => {
655+ format ! (
656+ "pythonw{}.{}t.exe" ,
657+ interpreter. python_major( ) ,
658+ interpreter. python_minor( )
659+ )
660+ }
625661 WindowsExecutable :: PyPy => String :: from ( "pypy.exe" ) ,
626662 WindowsExecutable :: PyPyMajor => {
627663 format ! ( "pypy{}.exe" , interpreter. python_major( ) )
@@ -656,6 +692,8 @@ impl WindowsExecutable {
656692 Self :: Python | Self :: PythonMajor | Self :: PythonMajorMinor => "venvlauncher.exe" ,
657693 Self :: Pythonw if interpreter. gil_disabled ( ) => "venvwlaunchert.exe" ,
658694 Self :: Pythonw => "venvwlauncher.exe" ,
695+ Self :: PythonMajorMinort => "venvlaunchert.exe" ,
696+ Self :: PythonwMajorMinort => "venvwlaunchert.exe" ,
659697 // From 3.13 on these should replace the `python.exe` and `pythonw.exe` shims.
660698 // These are not relevant as of now for PyPy as it doesn't yet support Python 3.13.
661699 Self :: PyPy | Self :: PyPyMajor | Self :: PyPyMajorMinor => "venvlauncher.exe" ,
0 commit comments