Skip to content

Commit b54163c

Browse files
committed
windows: install pythonw.exe
To round out the completeness of the distribution.
1 parent 67a1039 commit b54163c

File tree

1 file changed

+3
-14
lines changed

1 file changed

+3
-14
lines changed

cpython-windows/build.py

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -830,18 +830,13 @@ def hack_project_files(
830830

831831
copy_link_to_lib(pythoncore_proj)
832832

833-
# We don't need to produce pythonw.exe and python_uwp.exe
834-
# and their *w variants. Or the python3.dll, pyshellext, or pylauncher.
833+
# We don't need to produce python_uwp.exe and its *w variant. Or the
834+
# python3.dll, pyshellext, or pylauncher.
835835
# Cut them from the build to save time and so their presence doesn't
836836
# interfere with packaging up the build artifacts.
837837

838838
pcbuild_proj = pcbuild_path / "pcbuild.proj"
839839

840-
static_replace_in_file(
841-
pcbuild_proj,
842-
b'<Projects2 Include="python.vcxproj;pythonw.vcxproj" />',
843-
b'<Projects2 Include="python.vcxproj" />',
844-
)
845840
static_replace_in_file(
846841
pcbuild_proj,
847842
b'<Projects2 Include="python_uwp.vcxproj;pythonw_uwp.vcxproj" Condition="$(IncludeUwp)" />',
@@ -1037,13 +1032,6 @@ def hack_source_files(source_path: pathlib.Path, static: bool):
10371032
layout_main, b" yield from in_build(PYTHON_DLL_NAME)\n", b""
10381033
)
10391034

1040-
# We don't produce a pythonw.exe.
1041-
static_replace_in_file(
1042-
layout_main,
1043-
b' yield from in_build("pythonw.exe", new_name="pythonw")\n',
1044-
b"",
1045-
)
1046-
10471035

10481036
def run_msbuild(
10491037
msbuild: pathlib.Path,
@@ -1235,6 +1223,7 @@ def collect_python_build_artifacts(
12351223
ignore_projects = {
12361224
# We don't care about build artifacts for the python executable.
12371225
"python",
1226+
"pythonw",
12381227
# Don't care about venvlauncher executable.
12391228
"venvlauncher",
12401229
"venvwlauncher",

0 commit comments

Comments
 (0)