File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -1221,8 +1221,10 @@ def build_cpython(
12211221 if freethreaded :
12221222 (major , minor , _ ) = python_version .split ("." )
12231223 python_exe = f"python{ major } .{ minor } t.exe"
1224+ pythonw_exe = f"pythonw{ major } .{ minor } t.exe"
12241225 else :
12251226 python_exe = "python.exe"
1227+ pythonw_exe = "pythonw.exe"
12261228
12271229 if arch == "amd64" :
12281230 build_platform = "x64"
@@ -1538,6 +1540,15 @@ def build_cpython(
15381540 canonical_python_exe ,
15391541 )
15401542
1543+ # Create `pythonw.exe` copy when an alternative executable is built, e.g., when
1544+ # free-threading is enabled the name is `pythonw3.13t.exe`.
1545+ canonical_pythonw_exe = install_dir / "python.exe"
1546+ if not canonical_pythonw_exe .exists ():
1547+ shutil .copy2 (
1548+ install_dir / pythonw_exe ,
1549+ canonical_pythonw_exe ,
1550+ )
1551+
15411552 # CPython 3.13 removed `run_tests.py`, we provide a compatibility script
15421553 # for now.
15431554 if meets_python_minimum_version (python_version , "3.13" ):
You can’t perform that action at this time.
0 commit comments