Update scripts to set distro RID and properties to use it as TargetRid if set
This commit is contained in:
parent
2029cca492
commit
262a84c9be
4 changed files with 12 additions and 0 deletions
|
@ -63,4 +63,8 @@ while [[ $# > 0 ]]; do
|
||||||
shift
|
shift
|
||||||
done
|
done
|
||||||
|
|
||||||
|
source $REPOROOT/eng/common/native/init-os-and-arch.sh
|
||||||
|
source $REPOROOT/eng/common/native/init-distro-rid.sh
|
||||||
|
initDistroRidGlobal "$os" "$arch" ""
|
||||||
|
|
||||||
. "$REPOROOT/eng/common/build.sh" --build --restore "${args[@]}"
|
. "$REPOROOT/eng/common/build.sh" --build --restore "${args[@]}"
|
||||||
|
|
|
@ -159,6 +159,8 @@
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
|
<!-- Use current machine distro RID if set. Otherwise, fall back to RuntimeInformation.RuntimeIdentifier -->
|
||||||
|
<TargetRid Condition="'$(TargetRid)' == ''">$(__DistroRid)</TargetRid>
|
||||||
<TargetRid Condition="'$(TargetRid)' == ''">$([System.Runtime.InteropServices.RuntimeInformation]::RuntimeIdentifier)</TargetRid>
|
<TargetRid Condition="'$(TargetRid)' == ''">$([System.Runtime.InteropServices.RuntimeInformation]::RuntimeIdentifier)</TargetRid>
|
||||||
|
|
||||||
<TargetOS Condition="'$(TargetOS)' == '' AND $([MSBuild]::IsOSPlatform('WINDOWS'))">Windows_NT</TargetOS>
|
<TargetOS Condition="'$(TargetOS)' == '' AND $([MSBuild]::IsOSPlatform('WINDOWS'))">Windows_NT</TargetOS>
|
||||||
|
|
|
@ -247,6 +247,10 @@ echo "Found bootstrap SDK $SDK_VERSION, bootstrap Arcade $ARCADE_BOOTSTRAP_VERSI
|
||||||
export DOTNET_CLI_TELEMETRY_OPTOUT=1
|
export DOTNET_CLI_TELEMETRY_OPTOUT=1
|
||||||
export NUGET_PACKAGES=$packagesRestoredDir/
|
export NUGET_PACKAGES=$packagesRestoredDir/
|
||||||
|
|
||||||
|
source $SCRIPT_ROOT/eng/common/native/init-os-and-arch.sh
|
||||||
|
source $SCRIPT_ROOT/eng/common/native/init-distro-rid.sh
|
||||||
|
initDistroRidGlobal "$os" "$arch" ""
|
||||||
|
|
||||||
LogDateStamp=$(date +"%m%d%H%M%S")
|
LogDateStamp=$(date +"%m%d%H%M%S")
|
||||||
|
|
||||||
"$CLI_ROOT/dotnet" build-server shutdown
|
"$CLI_ROOT/dotnet" build-server shutdown
|
||||||
|
|
|
@ -1,6 +1,8 @@
|
||||||
<Project>
|
<Project>
|
||||||
<Target Name="GetCurrentRuntimeInformation">
|
<Target Name="GetCurrentRuntimeInformation">
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
|
<!-- Use current machine distro RID if set. Otherwise, fall back to RuntimeInformation.RuntimeIdentifier -->
|
||||||
|
<HostRid Condition="'$(HostRid)' == '' and '$(MSBuildRuntimeType)' == 'core'">$(__DistroRid)</HostRid>
|
||||||
<HostRid Condition="'$(HostRid)' == '' and '$(MSBuildRuntimeType)' == 'core'">$([System.Runtime.InteropServices.RuntimeInformation]::RuntimeIdentifier)</HostRid>
|
<HostRid Condition="'$(HostRid)' == '' and '$(MSBuildRuntimeType)' == 'core'">$([System.Runtime.InteropServices.RuntimeInformation]::RuntimeIdentifier)</HostRid>
|
||||||
<HostRid Condition="'$(HostRid)' == '' and '$(MSBuildRuntimeType)' != 'core'">win-$([System.Runtime.InteropServices.RuntimeInformation]::OSArchitecture.ToString().ToLowerInvariant)</HostRid>
|
<HostRid Condition="'$(HostRid)' == '' and '$(MSBuildRuntimeType)' != 'core'">win-$([System.Runtime.InteropServices.RuntimeInformation]::OSArchitecture.ToString().ToLowerInvariant)</HostRid>
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue