Address feedback
This commit is contained in:
parent
771924914b
commit
2fa338adf0
5 changed files with 24 additions and 17 deletions
|
@ -145,6 +145,9 @@
|
|||
Example:
|
||||
dotnet-sdk-3.0.100-alpha1-009719-win-x64.exe /install DOTNETHOME_X64="D:\dotnet\x64" DOTNETHOME_X86="D:\dotnet\x86" /log "installation.log" /quiet /norestart
|
||||
-->
|
||||
<Variable Name="DOTNETHOME_X86" bal:Overridable="yes" />
|
||||
<Variable Name="DOTNETHOME_X64" bal:Overridable="yes" />
|
||||
<Variable Name="DOTNETHOME_ARM64" bal:Overridable="yes" />
|
||||
<Variable Name="DOTNETHOME" Type="string" Value="[DOTNETHOME_$(var.PlatformToken)]" bal:Overridable="no" />
|
||||
<Variable Name="BUNDLEMONIKER" Type="string" Value="$(var.ProductMoniker)" bal:Overridable="no" />
|
||||
<Variable Name="DOTNETSDKVERSION" Type="string" Value="$(var.NugetVersion)" bal:Overridable="no" />
|
||||
|
|
|
@ -54,8 +54,8 @@
|
|||
</Directory>
|
||||
</Directory>
|
||||
|
||||
<?if $(var.Platform) = x64 ?>
|
||||
<CustomActionRef Id="Set_DOTNETHOME_x64" />
|
||||
<?if $(var.Platform)~=x64?>
|
||||
<CustomActionRef Id="Set_DOTNETHOME_NON_NATIVE_ARCHITECTURE" />
|
||||
<?endif?>
|
||||
</Fragment>
|
||||
<Fragment>
|
||||
|
|
|
@ -1,33 +1,37 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- Licensed to the .NET Foundation under one or more agreements. The .NET Foundation licenses this file to you under the MIT license. -->
|
||||
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
|
||||
<?ifndef Platform ?>
|
||||
<?define Platform = "$(sys.BUILDARCH)" ?>
|
||||
<?endif ?>
|
||||
<?ifndef Platform?>
|
||||
<?define Platform = "$(sys.BUILDARCH)"?>
|
||||
<?endif?>
|
||||
|
||||
<!-- The following match the expected values for PROCESSOR_ARCHITECTURE
|
||||
https://docs.microsoft.com/en-us/windows/win32/winprog64/wow64-implementation-details -->
|
||||
<!-- InstallerArchitecture matches the expected values for PROCESSOR_ARCHITECTURE
|
||||
https://docs.microsoft.com/en-us/windows/win32/winprog64/wow64-implementation-details -->
|
||||
<?if $(var.Platform)~=x86?>
|
||||
<?define InstallerArchitecture="X86"?>
|
||||
<?elseif $(var.Platform)~=x64?>
|
||||
<?define InstallerArchitecture="AMD64"?>
|
||||
<?elseif $(var.Platform)~=arm64?>
|
||||
<?define InstallerArchitecture="ARM64"?>
|
||||
<?else?>
|
||||
<?error Unknown platform, $(var.Platform) ?>?
|
||||
<?endif?>
|
||||
|
||||
<Fragment>
|
||||
<!-- Identify when installing in emulation as when PROCESSOR_ARCHITECTURE does not match the installer architecture
|
||||
https://docs.microsoft.com/en-us/windows/win32/winprog64/wow64-implementation-details -->
|
||||
<SetProperty Action="Set_INSTALLING_IN_EMULATION" Id="INSTALLING_IN_EMULATION" Value="true" Before="CostFinalize">
|
||||
<SetProperty Action="Set_NON_NATIVE_ARCHITECTURE" Id="NON_NATIVE_ARCHITECTURE" Value="true" Before="CostFinalize">
|
||||
NOT %PROCESSOR_ARCHITECTURE="$(var.InstallerArchitecture)"
|
||||
</SetProperty>
|
||||
</Fragment>
|
||||
|
||||
<?if $(var.Platform)=x64?>
|
||||
|
||||
<?if $(var.Platform)~=x64?>
|
||||
<Fragment>
|
||||
<!-- When running in x64 emulation and user hasn't specified install directory, install to an x64 subdirectory-->
|
||||
<SetProperty Action="Set_DOTNETHOME_x64" Id="DOTNETHOME" Value="[ProgramFiles64Folder]dotnet\x64\" After="Set_INSTALLING_IN_EMULATION">
|
||||
INSTALLING_IN_EMULATION AND NOT DOTNETHOME
|
||||
<!-- When running in a non-native architecture and user hasn't specified install directory,
|
||||
install to an x64 subdirectory.
|
||||
This is only define for x64, since x86 has redirection and no other native architecture can install ARM64 today -->
|
||||
<SetProperty Action="Set_DOTNETHOME_NON_NATIVE_ARCHITECTURE" Id="DOTNETHOME" Value="[ProgramFiles64Folder]dotnet\x64\" After="Set_NON_NATIVE_ARCHITECTURE">
|
||||
NON_NATIVE_ARCHITECTURE AND NOT DOTNETHOME
|
||||
</SetProperty>
|
||||
</Fragment>
|
||||
<?endif?>
|
||||
|
|
|
@ -33,8 +33,8 @@
|
|||
</Directory>
|
||||
</Directory>
|
||||
|
||||
<?if $(var.Platform) = x64 ?>
|
||||
<CustomActionRef Id="Set_DOTNETHOME_x64" />
|
||||
<?if $(var.Platform)~=x64?>
|
||||
<CustomActionRef Id="Set_DOTNETHOME_NON_NATIVE_ARCHITECTURE" />
|
||||
<?endif?>
|
||||
</Fragment>
|
||||
</Wix>
|
||||
|
|
|
@ -33,8 +33,8 @@
|
|||
</Directory>
|
||||
</Directory>
|
||||
|
||||
<?if $(var.Platform) = x64 ?>
|
||||
<CustomActionRef Id="Set_DOTNETHOME_x64" />
|
||||
<?if $(var.Platform)~=x64?>
|
||||
<CustomActionRef Id="Set_DOTNETHOME_NON_NATIVE_ARCHITECTURE" />
|
||||
<?endif?>
|
||||
</Fragment>
|
||||
</Wix>
|
||||
|
|
Loading…
Reference in a new issue