Skip to content

Commit 17571c5

Browse files
bpo-39930: Convert error to warning for more silent failure (GH-18921)
Makes it an error to create a layout without vcruntime DLL (cherry picked from commit fde44ae) Co-authored-by: Steve Dower <[email protected]>
1 parent d01c550 commit 17571c5

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

PC/layout/main.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,8 +173,12 @@ def in_build(f, dest="", new_name=None):
173173
if ns.include_stable:
174174
yield from in_build(PYTHON_STABLE_DLL_NAME)
175175

176+
found_any = False
176177
for dest, src in rglob(ns.build, "vcruntime*.dll"):
178+
found_any = True
177179
yield dest, src
180+
if not found_any:
181+
log_error("Failed to locate vcruntime DLL in the build.")
178182

179183
yield "LICENSE.txt", ns.build / "LICENSE.txt"
180184

PCbuild/pyproject.props

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,7 @@ public override bool Execute() {
218218
<VCRuntimeDLL Include="$(VCRedistDir)\Microsoft.VC*.CRT\vcruntime*.dll" />
219219
</ItemGroup>
220220

221-
<Error Text="vcruntime14*.dll not found under $(VCInstallDir)" Condition="@(VCRuntimeDLL) == ''" />
221+
<Warning Text="vcruntime14*.dll not found under $(VCInstallDir)" Condition="@(VCRuntimeDLL) == ''" />
222222
<Message Text="VCRuntimeDLL: @(VCRuntimeDLL)" Importance="high" />
223223
</Target>
224224
</Project>

0 commit comments

Comments
 (0)