Skip to content

Commit 9cc113a

Browse files
committed
Issue #28846: Various installer fixes
2 parents 853ec5d + f00ef72 commit 9cc113a

8 files changed

Lines changed: 175 additions & 96 deletions

File tree

PCbuild/build.bat

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,9 @@ if "%platf%"=="x64" (
105105
)
106106
)
107107

108+
if not exist "%HG%" where hg > "%TEMP%\hg.loc" 2> nul && set /P HG= < "%TEMP%\hg.loc" & del "%TEMP%\hg.loc"
109+
if not exist "%HG%" echo Cannot find Mercurial on PATH && exit /B 1
110+
108111
rem Setup the environment
109112
call "%dir%env.bat" %vs_platf% >nul
110113

@@ -142,6 +145,7 @@ msbuild "%dir%pcbuild.proj" /t:%target% %parallel% %verbose%^
142145
/p:IncludeExternals=%IncludeExternals%^
143146
/p:IncludeSSL=%IncludeSSL% /p:IncludeTkinter=%IncludeTkinter%^
144147
/p:UseTestMarker=%UseTestMarker%^
148+
/p:HG="%HG%"^
145149
%1 %2 %3 %4 %5 %6 %7 %8 %9
146150

147151
@echo off

PCbuild/pythoncore.vcxproj

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -412,6 +412,7 @@
412412
<_HG Condition="$(HG.Contains(` `))">"$(HG)"</_HG>
413413
</PropertyGroup>
414414
<Message Text="Getting build info from $(_HG)" Importance="high" />
415+
<MakeDir Directories="$(IntDir)" Condition="!Exists($(IntDir))" />
415416
<Exec Command="$(_HG) id -b &gt; &quot;$(IntDir)hgbranch.txt&quot;" ContinueOnError="true" />
416417
<Exec Command="$(_HG) id -i &gt; &quot;$(IntDir)hgversion.txt&quot;" ContinueOnError="true" />
417418
<Exec Command="$(_HG) id -t &gt; &quot;$(IntDir)hgtag.txt&quot;" ContinueOnError="true" />

Tools/msi/buildrelease.bat

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,9 @@ if "%1" NEQ "" echo Invalid option: "%1" && exit /B 1
6565

6666
if not defined BUILDX86 if not defined BUILDX64 (set BUILDX86=1) && (set BUILDX64=1)
6767

68+
if not exist "%HG%" where hg > "%TEMP%\hg.loc" 2> nul && set /P HG= < "%TEMP%\hg.loc" & del "%TEMP%\hg.loc"
69+
if not exist "%HG%" echo Cannot find Mercurial on PATH && exit /B 1
70+
6871
call "%D%get_externals.bat"
6972

7073
:builddoc
@@ -78,9 +81,6 @@ call "%D%..\..\doc\make.bat" htmlhelp
7881
if errorlevel 1 goto :eof
7982
:skipdoc
8083

81-
where hg > "%TEMP%\hg.loc" 2> nul && set /P HG= < "%TEMP%\hg.loc" & del "%TEMP%\hg.loc"
82-
if not exist "%HG%" echo Cannot find Mercurial on PATH && exit /B 1
83-
8484
where dlltool /q && goto skipdlltoolsearch
8585
set _DLLTOOL_PATH=
8686
where /R "%EXTERNALS%\" dlltool > "%TEMP%\dlltool.loc" 2> nul && set /P _DLLTOOL_PATH= < "%TEMP%\dlltool.loc" & del "%TEMP%\dlltool.loc"
@@ -181,7 +181,7 @@ msbuild "%D%bundle\releaseweb.wixproj" /t:Rebuild %BUILDOPTS% %CERTOPTS% /p:Rebu
181181
if errorlevel 1 exit /B
182182

183183
if defined BUILDZIP (
184-
msbuild "%D%make_zip.proj" /t:Build %BUILDOPTS% %CERTOPTS%
184+
msbuild "%D%make_zip.proj" /t:Build %BUILDOPTS% %CERTOPTS% /p:OutputPath="%BUILD%en-us"
185185
if errorlevel 1 exit /B
186186
)
187187

Tools/msi/bundle/bundle.wxs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,16 @@
11
<?xml version="1.0"?>
22
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"
3-
xmlns:bal="http://schemas.microsoft.com/wix/BalExtension">
3+
xmlns:bal="http://schemas.microsoft.com/wix/BalExtension"
4+
xmlns:dep="http://schemas.microsoft.com/wix/DependencyExtension">
45
<Bundle Name="!(loc.FullProductName)"
56
UpgradeCode="$(var.CoreUpgradeCode)"
67
Version="$(var.Version)"
78
IconSourceFile="..\..\..\PC\icons\setup.ico"
89
Manufacturer="!(loc.Manufacturer)"
910
AboutUrl="http://www.python.org/"
1011
DisableModify="button"
11-
Compressed="no">
12+
Compressed="no"
13+
dep:ProviderKey="CPython-$(var.MajorVersionNumber).$(var.MinorVersionNumber)$(var.PyArchExt)$(var.PyTestExt)">
1214
<BootstrapperApplication Id="PythonBA" SourceFile="$(var.BootstrapApp)">
1315
<Payload Compressed='yes' SourceFile='Default.thm' />
1416
<Payload Compressed='yes' SourceFile='Default.wxl' />

Tools/msi/make_zip.proj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
<SignOutput>false</SignOutput>
1414
<TargetName>python-$(PythonVersion)-embed-$(ArchName)</TargetName>
1515
<TargetExt>.zip</TargetExt>
16-
<TargetPath>$(OutputPath)\en-us\$(TargetName)$(TargetExt)</TargetPath>
16+
<TargetPath>$(OutputPath)\$(TargetName)$(TargetExt)</TargetPath>
1717
<CleanCommand>rmdir /q/s "$(IntermediateOutputPath)\zip_$(ArchName)"</CleanCommand>
1818
<Arguments>"$(PythonExe)" "$(MSBuildThisFileDirectory)\make_zip.py"</Arguments>
1919
<Arguments>$(Arguments) -e -o "$(TargetPath)" -t "$(IntermediateOutputPath)\zip_$(ArchName)" -a $(ArchName)</Arguments>

Tools/nuget/make_pkg.proj

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
<SignOutput>false</SignOutput>
1919
<TargetName>$(OutputName).$(NuspecVersion)</TargetName>
2020
<TargetExt>.nupkg</TargetExt>
21-
<TargetPath>$(OutputPath)\$(TargetName)$(TargetExt)</TargetPath>
2221
<IntermediateOutputPath>$(IntermediateOutputPath)\nuget_$(ArchName)</IntermediateOutputPath>
2322

2423
<CleanCommand>rmdir /q/s "$(IntermediateOutputPath)"</CleanCommand>

0 commit comments

Comments
 (0)