Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit bb65b5b

Browse files
committed
Issue #19788: kill_python(_d).exe is now run as a PreBuildEvent on the
pythoncore sub-project. This should prevent build errors due a previous build's python(_d).exe still running.
1 parent 99fb051 commit bb65b5b

4 files changed

Lines changed: 54 additions & 4 deletions

File tree

Misc/NEWS

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,10 @@ Documentation
9292
Build
9393
-----
9494

95+
- Issue #19788: kill_python(_d).exe is now run as a PreBuildEvent on the
96+
pythoncore sub-project. This should prevent build errors due a previous
97+
build's python(_d).exe still running.
98+
9599
- Add workaround for VS 2010 nmake clean issue. VS 2010 doesn't set up PATH
96100
for nmake.exe correctly.
97101

PCbuild/pythoncore.vcxproj

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,12 @@
181181
<IgnoreSpecificDefaultLibraries>libc;%(IgnoreSpecificDefaultLibraries)</IgnoreSpecificDefaultLibraries>
182182
<BaseAddress>0x1e000000</BaseAddress>
183183
</Link>
184+
<PreBuildEvent>
185+
<Command>$(KillPythonExe)</Command>
186+
</PreBuildEvent>
187+
<PreBuildEvent>
188+
<Message>Killing any running $(PythonExe) instances...</Message>
189+
</PreBuildEvent>
184190
</ItemDefinitionGroup>
185191
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
186192
<Midl>
@@ -206,6 +212,12 @@
206212
<IgnoreSpecificDefaultLibraries>libc;%(IgnoreSpecificDefaultLibraries)</IgnoreSpecificDefaultLibraries>
207213
<BaseAddress>0x1e000000</BaseAddress>
208214
</Link>
215+
<PreBuildEvent>
216+
<Command>$(KillPythonExe)</Command>
217+
</PreBuildEvent>
218+
<PreBuildEvent>
219+
<Message>Killing any running $(PythonExe) instances...</Message>
220+
</PreBuildEvent>
209221
</ItemDefinitionGroup>
210222
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
211223
<ClCompile>
@@ -231,6 +243,12 @@
231243
<IgnoreSpecificDefaultLibraries>libc;%(IgnoreSpecificDefaultLibraries)</IgnoreSpecificDefaultLibraries>
232244
<BaseAddress>0x1e000000</BaseAddress>
233245
</Link>
246+
<PreBuildEvent>
247+
<Command>$(KillPythonExe)</Command>
248+
</PreBuildEvent>
249+
<PreBuildEvent>
250+
<Message>Killing any running $(PythonExe) instances...</Message>
251+
</PreBuildEvent>
234252
</ItemDefinitionGroup>
235253
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
236254
<Midl>
@@ -259,6 +277,12 @@
259277
<IgnoreSpecificDefaultLibraries>libc;%(IgnoreSpecificDefaultLibraries)</IgnoreSpecificDefaultLibraries>
260278
<BaseAddress>0x1e000000</BaseAddress>
261279
</Link>
280+
<PreBuildEvent>
281+
<Command>$(KillPythonExe)</Command>
282+
</PreBuildEvent>
283+
<PreBuildEvent>
284+
<Message>Killing any running $(PythonExe) instances...</Message>
285+
</PreBuildEvent>
262286
</ItemDefinitionGroup>
263287
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='PGInstrument|Win32'">
264288
<ClCompile>
@@ -282,6 +306,12 @@
282306
<IgnoreSpecificDefaultLibraries>libc;%(IgnoreSpecificDefaultLibraries)</IgnoreSpecificDefaultLibraries>
283307
<BaseAddress>0x1e000000</BaseAddress>
284308
</Link>
309+
<PreBuildEvent>
310+
<Command>$(KillPythonExe)</Command>
311+
</PreBuildEvent>
312+
<PreBuildEvent>
313+
<Message>Killing any running $(PythonExe) instances...</Message>
314+
</PreBuildEvent>
285315
</ItemDefinitionGroup>
286316
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='PGInstrument|x64'">
287317
<Midl>
@@ -308,6 +338,12 @@
308338
<BaseAddress>0x1e000000</BaseAddress>
309339
<TargetMachine>MachineX64</TargetMachine>
310340
</Link>
341+
<PreBuildEvent>
342+
<Command>$(KillPythonExe)</Command>
343+
</PreBuildEvent>
344+
<PreBuildEvent>
345+
<Message>Killing any running $(PythonExe) instances...</Message>
346+
</PreBuildEvent>
311347
</ItemDefinitionGroup>
312348
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='PGUpdate|Win32'">
313349
<ClCompile>
@@ -331,6 +367,12 @@
331367
<IgnoreSpecificDefaultLibraries>libc;%(IgnoreSpecificDefaultLibraries)</IgnoreSpecificDefaultLibraries>
332368
<BaseAddress>0x1e000000</BaseAddress>
333369
</Link>
370+
<PreBuildEvent>
371+
<Command>$(KillPythonExe)</Command>
372+
</PreBuildEvent>
373+
<PreBuildEvent>
374+
<Message>Killing any running $(PythonExe) instances...</Message>
375+
</PreBuildEvent>
334376
</ItemDefinitionGroup>
335377
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='PGUpdate|x64'">
336378
<Midl>
@@ -357,6 +399,12 @@
357399
<BaseAddress>0x1e000000</BaseAddress>
358400
<TargetMachine>MachineX64</TargetMachine>
359401
</Link>
402+
<PreBuildEvent>
403+
<Command>$(KillPythonExe)</Command>
404+
</PreBuildEvent>
405+
<PreBuildEvent>
406+
<Message>Killing any running $(PythonExe) instances...</Message>
407+
</PreBuildEvent>
360408
</ItemDefinitionGroup>
361409
<ItemGroup>
362410
<ClInclude Include="..\Include\abstract.h" />

Tools/buildbot/build-amd64.bat

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,5 @@
22
cmd /c Tools\buildbot\external-amd64.bat
33
call "%VS100COMNTOOLS%\..\..\VC\vcvarsall.bat" x86_amd64
44
cmd /c Tools\buildbot\clean-amd64.bat
5-
msbuild PCbuild\kill_python.vcxproj /p:Configuration=Debug /p:PlatformTarget=x64
6-
PCbuild\amd64\kill_python_d.exe
5+
76
msbuild PCbuild\pcbuild.sln /p:Configuration=Debug /p:Platform=x64

Tools/buildbot/build.bat

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
cmd /c Tools\buildbot\external.bat
33
call "%VS100COMNTOOLS%vsvars32.bat"
44
cmd /c Tools\buildbot\clean.bat
5-
msbuild PCbuild\kill_python.vcxproj /p:Configuration=Debug /p:PlatformTarget=x86
6-
PCbuild\kill_python_d.exe
5+
76
msbuild PCbuild\pcbuild.sln /p:Configuration=Debug /p:Platform=Win32
87

0 commit comments

Comments
 (0)