Skip to content

Commit 240b639

Browse files
authored
Gate x86_64-w64-mingw32-nmakehlp.exe removal to builds where it is present (#671)
Fixes https://github.com/astral-sh/python-build-standalone/actions/runs/15939854940/job/44966313482
1 parent 97c36a3 commit 240b639

File tree

1 file changed

+10
-9
lines changed

1 file changed

+10
-9
lines changed

cpython-windows/build.py

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1401,15 +1401,16 @@ def build_cpython(
14011401
shutil.copyfile(source, dest)
14021402

14031403
# Delete the tk nmake helper, it's not needed and links msvc
1404-
tcltk_commit: str = DOWNLOADS[tk_bin_entry]["git_commit"]
1405-
tcltk_path = td / ("cpython-bin-deps-%s" % tcltk_commit)
1406-
(
1407-
tcltk_path
1408-
/ build_directory
1409-
/ "lib"
1410-
/ "nmake"
1411-
/ "x86_64-w64-mingw32-nmakehlp.exe"
1412-
).unlink()
1404+
if tk_bin_entry == "tk-windows-bin":
1405+
tcltk_commit: str = DOWNLOADS[tk_bin_entry]["git_commit"]
1406+
tcltk_path = td / ("cpython-bin-deps-%s" % tcltk_commit)
1407+
(
1408+
tcltk_path
1409+
/ build_directory
1410+
/ "lib"
1411+
/ "nmake"
1412+
/ "x86_64-w64-mingw32-nmakehlp.exe"
1413+
).unlink()
14131414

14141415
cpython_source_path = td / ("Python-%s" % python_version)
14151416
pcbuild_path = cpython_source_path / "PCbuild"

0 commit comments

Comments
 (0)