Bladeren bron

[main] Update dependencies from dotnet/arcade (#53528)

[main] Update dependencies from dotnet/arcade


 - Merge branch 'main' into darc-main-b53c7ee8-482a-44eb-8859-45b8b9099279

 - Fix Version.Details.xml

 - Fix incorrect shas from manual merge.

 - Pass DotNetBuildSourceOnly through to repo tasks build

 - Pass DotNetBuildSourceOnly through to repo tasks build

 - Merge remote-tracking branch 'upstream/main' into darc-main-b53c7ee8-482a-44eb-8859-45b8b9099279

 - Propagate some additional properties

 - Unpropagate some additional properties

 - Only add if not already added.

 - Only add if not already added.

 - Keep Duplicates=false.

 - Odd

 - New approach

 - More feeling

 - Attempt using 17,8

 - Revert "Attempt using 17,8"

This reverts commit 7ccf5160f84d1acf65f3ec92c725371aab235f6a.

 - Temporarily switch to VS preview queues

 - Merge remote-tracking branch 'upstream/main' into darc-main-b53c7ee8-482a-44eb-8859-45b8b9099279

 - Revert googletest
dotnet-maestro[bot] 2 jaren geleden
bovenliggende
commit
6cfd675cc0

+ 2 - 2
.azure/pipelines/jobs/default-build.yml

@@ -124,11 +124,11 @@ jobs:
       ${{ if eq(parameters.agentOs, 'Windows') }}:
         ${{ if eq(variables['System.TeamProject'], 'public') }}:
           name: $(DncEngPublicBuildPool)
-          demands: ImageOverride -equals 1es-windows-2022-open
+          demands: ImageOverride -equals windows.vs2022preview.amd64.open
         ${{ if eq(variables['System.TeamProject'], 'internal') }}:
           name: $(DncEngInternalBuildPool)
           # Visual Studio Enterprise - contains some stuff, like SQL Server and IIS Express, that we use for testing
-          demands: ImageOverride -equals 1es-windows-2022
+          demands: ImageOverride -equals windows.vs2022preview.amd64
     ${{ if ne(parameters.container, '') }}:
       container: ${{ parameters.container }}
     ${{ if ne(parameters.disableComponentGovernance, '') }}:

+ 34 - 30
eng/Dependencies.props

@@ -100,38 +100,41 @@ and are generated based on the last package release.
     <LatestPackageReference Include="System.ValueTuple" />
 
     <!-- Runtime packages required for crossgen -->
-    <LatestPackageReference Include="Microsoft.NETCore.App.Runtime.win-x64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Runtime.win-x86" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Runtime.win-arm" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Runtime.win-arm64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Runtime.osx-x64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Runtime.osx-arm64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Runtime.linux-x64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Runtime.linux-arm" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Runtime.linux-arm64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Runtime.linux-musl-x64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Runtime.linux-musl-arm" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Runtime.linux-musl-arm64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Runtime.freebsd-x64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Runtime.freebsd-arm64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Runtime.$(TargetRuntimeIdentifier)" Condition=" '$(DotNetBuildSourceOnly)' == 'true' " />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Runtime.win-x64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Runtime.win-x86" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Runtime.win-arm" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Runtime.win-arm64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Runtime.osx-x64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Runtime.osx-arm64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Runtime.linux-x64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Runtime.linux-arm" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Runtime.linux-arm64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Runtime.linux-musl-x64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Runtime.linux-musl-arm" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Runtime.linux-musl-arm64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Runtime.freebsd-x64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Runtime.freebsd-arm64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Runtime.$(TargetRuntimeIdentifier)" Condition=" '$(DotNetBuildSourceOnly)' == 'true'" />
 
     <!-- Crossgen2 compiler -->
-    <LatestPackageReference Include="Microsoft.NETCore.App.Crossgen2.osx-x64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Crossgen2.osx-arm64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Crossgen2.linux-arm" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Crossgen2.linux-arm64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Crossgen2.linux-musl-arm" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Crossgen2.linux-musl-arm64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Crossgen2.linux-musl-x64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Crossgen2.linux-x64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Crossgen2.win-x64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Crossgen2.win-x86" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Crossgen2.win-arm" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Crossgen2.win-arm64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Crossgen2.freebsd-x64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Crossgen2.freebsd-arm64" />
-    <LatestPackageReference Include="Microsoft.NETCore.App.Crossgen2.$(TargetRuntimeIdentifier)" Condition=" '$(DotNetBuildSourceOnly)' == 'true' " />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Crossgen2.win-x64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Crossgen2.win-x86" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Crossgen2.win-arm" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Crossgen2.win-arm64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Crossgen2.osx-x64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Crossgen2.osx-arm64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Crossgen2.linux-x64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Crossgen2.linux-arm" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Crossgen2.linux-arm64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Crossgen2.linux-musl-x64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Crossgen2.linux-musl-arm" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Crossgen2.linux-musl-arm64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Crossgen2.freebsd-x64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Crossgen2.freebsd-arm64" />
+    <_LatestRuntimePackageReference Include="Microsoft.NETCore.App.Crossgen2.$(TargetRuntimeIdentifier)" Condition=" '$(DotNetBuildSourceOnly)' == 'true' " />
+
+    <!-- Remove duplicates potentially introduced by the 'unknown' target runtime identifier in source-only modes. -->
+    <LatestPackageReference Include="@(_LatestRuntimePackageReference->Distinct())" />
   </ItemGroup>
 
   <ItemGroup Label=".NET team dependencies (Non-source-build)" Condition="'$(DotNetBuildFromSource)' != 'true'">
@@ -232,6 +235,7 @@ and are generated based on the last package release.
   </ItemGroup>
 
   <ItemGroup Label="Dependencies with versions.">
+
     <!-- Get name prefixes for version properties. -->
     <LatestPackageReference Update="@(LatestPackageReference)">
       <VersionName>$([System.String]::new('%(Identity)').Replace('.',''))</VersionName>

+ 1 - 0
eng/SourceBuild.props

@@ -48,6 +48,7 @@
       <InnerBuildEnv Condition="'$(FullAssemblySigningSupported)' != ''" Include="FullAssemblySigningSupported=$(FullAssemblySigningSupported)" />
       <InnerBuildEnv Include="DotNetBuildFromSource=$(ArcadeBuildFromSource)" />
       <InnerBuildEnv Include="DotNetBuildVertical=$(ArcadeBuildVertical)" />
+      <InnerBuildEnv Include="DotNetBuildSourceOnly=$(DotNetBuildSourceOnly)" />
     </ItemGroup>
 
     <!-- Call the build.sh script to build the repo tasks. Set IgnoreStandardErrorWarningFormat

+ 12 - 12
eng/Version.Details.xml

@@ -383,31 +383,31 @@
       <Uri>https://github.com/dotnet/winforms</Uri>
       <Sha>dd5ae276be5f5e8c2203fd5f07bdc725a9891945</Sha>
     </Dependency>
-    <Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="9.0.0-beta.24062.5">
+    <Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="9.0.0-beta.24129.2">
       <Uri>https://github.com/dotnet/arcade</Uri>
-      <Sha>d731f58a502086842739a358ab490bec08fdb8a7</Sha>
+      <Sha>85ae8b264f3312aac5ca08dcab039556e99fcb00</Sha>
     </Dependency>
     <!-- Intermediate is necessary for source build. -->
-    <Dependency Name="Microsoft.SourceBuild.Intermediate.arcade" Version="9.0.0-beta.24062.5">
+    <Dependency Name="Microsoft.SourceBuild.Intermediate.arcade" Version="9.0.0-beta.24129.2">
       <Uri>https://github.com/dotnet/arcade</Uri>
-      <Sha>d731f58a502086842739a358ab490bec08fdb8a7</Sha>
+      <Sha>85ae8b264f3312aac5ca08dcab039556e99fcb00</Sha>
       <SourceBuild RepoName="arcade" ManagedOnly="true" />
     </Dependency>
-    <Dependency Name="Microsoft.DotNet.Build.Tasks.Installers" Version="9.0.0-beta.24062.5">
+    <Dependency Name="Microsoft.DotNet.Build.Tasks.Installers" Version="9.0.0-beta.24129.2">
       <Uri>https://github.com/dotnet/arcade</Uri>
-      <Sha>d731f58a502086842739a358ab490bec08fdb8a7</Sha>
+      <Sha>85ae8b264f3312aac5ca08dcab039556e99fcb00</Sha>
     </Dependency>
-    <Dependency Name="Microsoft.DotNet.Build.Tasks.Templating" Version="9.0.0-beta.24062.5">
+    <Dependency Name="Microsoft.DotNet.Build.Tasks.Templating" Version="9.0.0-beta.24129.2">
       <Uri>https://github.com/dotnet/arcade</Uri>
-      <Sha>d731f58a502086842739a358ab490bec08fdb8a7</Sha>
+      <Sha>85ae8b264f3312aac5ca08dcab039556e99fcb00</Sha>
     </Dependency>
-    <Dependency Name="Microsoft.DotNet.Helix.Sdk" Version="9.0.0-beta.24062.5">
+    <Dependency Name="Microsoft.DotNet.Helix.Sdk" Version="9.0.0-beta.24129.2">
       <Uri>https://github.com/dotnet/arcade</Uri>
-      <Sha>d731f58a502086842739a358ab490bec08fdb8a7</Sha>
+      <Sha>85ae8b264f3312aac5ca08dcab039556e99fcb00</Sha>
     </Dependency>
-    <Dependency Name="Microsoft.DotNet.RemoteExecutor" Version="9.0.0-beta.24062.5">
+    <Dependency Name="Microsoft.DotNet.RemoteExecutor" Version="9.0.0-beta.24129.2">
       <Uri>https://github.com/dotnet/arcade</Uri>
-      <Sha>d731f58a502086842739a358ab490bec08fdb8a7</Sha>
+      <Sha>85ae8b264f3312aac5ca08dcab039556e99fcb00</Sha>
     </Dependency>
     <Dependency Name="Microsoft.Extensions.Diagnostics.Testing" Version="9.0.0-preview.2.24123.2">
       <Uri>https://github.com/dotnet/extensions</Uri>

+ 4 - 4
eng/Versions.props

@@ -159,10 +159,10 @@
     <NuGetVersioningVersion>6.2.4</NuGetVersioningVersion>
     <NuGetFrameworksVersion>6.2.4</NuGetFrameworksVersion>
     <!-- Packages from dotnet/arcade -->
-    <MicrosoftDotNetBuildTasksInstallersVersion>9.0.0-beta.24062.5</MicrosoftDotNetBuildTasksInstallersVersion>
-    <MicrosoftDotNetBuildTasksTemplatingVersion>9.0.0-beta.24062.5</MicrosoftDotNetBuildTasksTemplatingVersion>
-    <MicrosoftDotNetRemoteExecutorVersion>9.0.0-beta.24062.5</MicrosoftDotNetRemoteExecutorVersion>
-    <MicrosoftSourceBuildIntermediatearcadeVersion>9.0.0-beta.24062.5</MicrosoftSourceBuildIntermediatearcadeVersion>
+    <MicrosoftDotNetBuildTasksInstallersVersion>9.0.0-beta.24129.2</MicrosoftDotNetBuildTasksInstallersVersion>
+    <MicrosoftDotNetBuildTasksTemplatingVersion>9.0.0-beta.24129.2</MicrosoftDotNetBuildTasksTemplatingVersion>
+    <MicrosoftDotNetRemoteExecutorVersion>9.0.0-beta.24129.2</MicrosoftDotNetRemoteExecutorVersion>
+    <MicrosoftSourceBuildIntermediatearcadeVersion>9.0.0-beta.24129.2</MicrosoftSourceBuildIntermediatearcadeVersion>
     <!-- Packages from dotnet/source-build-externals -->
     <MicrosoftSourceBuildIntermediatesourcebuildexternalsVersion>9.0.0-alpha.1.24112.1</MicrosoftSourceBuildIntermediatesourcebuildexternalsVersion>
     <!-- Packages from dotnet/source-build-reference-packages -->

+ 3 - 0
eng/common/build.ps1

@@ -20,6 +20,7 @@ Param(
   [switch] $publish,
   [switch] $clean,
   [switch] $verticalBuild,
+  [switch][Alias('pb')]$productBuild,
   [switch][Alias('bl')]$binaryLog,
   [switch][Alias('nobl')]$excludeCIBinarylog,
   [switch] $ci,
@@ -60,6 +61,7 @@ function Print-Usage() {
   Write-Host "  -publish                Publish artifacts (e.g. symbols)"
   Write-Host "  -clean                  Clean the solution"
   Write-Host "  -verticalBuild          Run in 'vertical build' infra mode."
+  Write-Host "  -productBuild           Build the solution in the way it will be built in the full .NET product (VMR) build (short: -pb)"
   Write-Host ""
 
   Write-Host "Advanced settings:"
@@ -122,6 +124,7 @@ function Build {
     /p:Deploy=$deploy `
     /p:Test=$test `
     /p:Pack=$pack `
+    /p:DotNetBuildRepo=$($productBuild -or $verticalBuild) `
     /p:ArcadeBuildVertical=$verticalBuild `
     /p:IntegrationTest=$integrationTest `
     /p:PerformanceTest=$performanceTest `

+ 14 - 0
eng/common/build.sh

@@ -22,6 +22,9 @@ usage()
   echo "  --sourceBuild              Source-build the solution (short: -sb)"
   echo "                             Will additionally trigger the following actions: --restore, --build, --pack"
   echo "                             If --configuration is not set explicitly, will also set it to 'Release'"
+  echo "  --productBuild             Build the solution in the way it will be built in the full .NET product (VMR) build (short: -pb)"
+  echo "                             Will additionally trigger the following actions: --restore, --build, --pack"
+  echo "                             If --configuration is not set explicitly, will also set it to 'Release'"
   echo "  --rebuild                  Rebuild solution"
   echo "  --test                     Run all unit tests in the solution (short: -t)"
   echo "  --integrationTest          Run all integration tests in the solution"
@@ -60,6 +63,7 @@ restore=false
 build=false
 source_build=false
 vertical_build=false
+product_build=false
 rebuild=false
 test=false
 integration_test=false
@@ -127,12 +131,20 @@ while [[ $# > 0 ]]; do
     -sourcebuild|-sb)
       build=true
       source_build=true
+      product_build=true
+      restore=true
+      pack=true
+      ;;
+    -productBuild|-pb)
+      build=true
+      product_build=true
       restore=true
       pack=true
       ;;
     -verticalbuild|-vb)
       build=true
       vertical_build=true
+      product_build=true
       restore=true
       pack=true
       ;;
@@ -226,7 +238,9 @@ function Build {
     /p:RepoRoot="$repo_root" \
     /p:Restore=$restore \
     /p:Build=$build \
+    /p:DotNetBuildRepo=$product_build \
     /p:ArcadeBuildFromSource=$source_build \
+    /p:DotNetBuildSourceOnly=$source_build \
     /p:ArcadeBuildVertical=$vertical_build \
     /p:Rebuild=$rebuild \
     /p:Test=$test \

+ 7 - 7
eng/common/cross/build-rootfs.sh

@@ -8,7 +8,7 @@ usage()
     echo "BuildArch can be: arm(default), arm64, armel, armv6, ppc64le, riscv64, s390x, x64, x86"
     echo "CodeName - optional, Code name for Linux, can be: xenial(default), zesty, bionic, alpine"
     echo "                               for alpine can be specified with version: alpineX.YY or alpineedge"
-    echo "                               for FreeBSD can be: freebsd12, freebsd13"
+    echo "                               for FreeBSD can be: freebsd13, freebsd14"
     echo "                               for illumos can be: illumos"
     echo "                               for Haiku can be: haiku."
     echo "lldbx.y - optional, LLDB version, can be: lldb3.9(default), lldb4.0, lldb5.0, lldb6.0 no-lldb. Ignored for alpine and FreeBSD"
@@ -71,9 +71,9 @@ __AlpinePackages+=" krb5-dev"
 __AlpinePackages+=" openssl-dev"
 __AlpinePackages+=" zlib-dev"
 
-__FreeBSDBase="12.4-RELEASE"
+__FreeBSDBase="13.2-RELEASE"
 __FreeBSDPkg="1.17.0"
-__FreeBSDABI="12"
+__FreeBSDABI="13"
 __FreeBSDPackages="libunwind"
 __FreeBSDPackages+=" icu"
 __FreeBSDPackages+=" libinotify"
@@ -334,14 +334,14 @@ while :; do
                 __AlpineVersion="$__AlpineMajorVersion.$__AlpineMinoVersion"
             fi
             ;;
-        freebsd12)
+        freebsd13)
             __CodeName=freebsd
             __SkipUnmount=1
             ;;
-        freebsd13)
+        freebsd14)
             __CodeName=freebsd
-            __FreeBSDBase="13.2-RELEASE"
-            __FreeBSDABI="13"
+            __FreeBSDBase="14.0-RELEASE"
+            __FreeBSDABI="14"
             __SkipUnmount=1
             ;;
         illumos)

+ 38 - 42
eng/common/native/init-distro-rid.sh

@@ -1,4 +1,4 @@
-#!/usr/bin/env bash
+#!/bin/sh
 
 # getNonPortableDistroRid
 #
@@ -11,21 +11,20 @@
 #   non-portable rid
 getNonPortableDistroRid()
 {
-    local targetOs="$1"
-    local targetArch="$2"
-    local rootfsDir="$3"
-    local nonPortableRid=""
+    targetOs="$1"
+    targetArch="$2"
+    rootfsDir="$3"
+    nonPortableRid=""
 
     if [ "$targetOs" = "linux" ]; then
+        # shellcheck disable=SC1091
         if [ -e "${rootfsDir}/etc/os-release" ]; then
-            source "${rootfsDir}/etc/os-release"
-
-            if [[ "${ID}" == "rhel" || "${ID}" == "rocky" || "${ID}" == "alpine" ]]; then
-                # remove the last version digit
-                VERSION_ID="${VERSION_ID%.*}"
+            . "${rootfsDir}/etc/os-release"
+            if [ "${ID}" = "rhel" ] || [ "${ID}" = "rocky" ] || [ "${ID}" = "alpine" ]; then
+                VERSION_ID="${VERSION_ID%.*}" # Remove the last version digit for these distros
             fi
 
-            if [[ "${VERSION_ID:-}" =~ ^([[:digit:]]|\.)+$ ]]; then
+            if echo "${VERSION_ID:-}" | grep -qE '^([[:digit:]]|\.)+$'; then
                 nonPortableRid="${ID}.${VERSION_ID}-${targetArch}"
             else
                 # Rolling release distros either do not set VERSION_ID, set it as blank or
@@ -33,45 +32,45 @@ getNonPortableDistroRid()
                 # so omit it here to be consistent with everything else.
                 nonPortableRid="${ID}-${targetArch}"
             fi
-
         elif [ -e "${rootfsDir}/android_platform" ]; then
-            source "$rootfsDir"/android_platform
+            # shellcheck disable=SC1091
+            . "${rootfsDir}/android_platform"
             nonPortableRid="$RID"
         fi
     fi
 
     if [ "$targetOs" = "freebsd" ]; then
-        # $rootfsDir can be empty. freebsd-version is shell script and it should always work.
-        __freebsd_major_version=$($rootfsDir/bin/freebsd-version | { read v; echo "${v%%.*}"; })
+        # $rootfsDir can be empty. freebsd-version is a shell script and should always work.
+        __freebsd_major_version=$("$rootfsDir"/bin/freebsd-version | cut -d'.' -f1)
         nonPortableRid="freebsd.$__freebsd_major_version-${targetArch}"
-    elif command -v getprop && getprop ro.product.system.model 2>&1 | grep -qi android; then
+    elif command -v getprop >/dev/null && getprop ro.product.system.model | grep -qi android; then
         __android_sdk_version=$(getprop ro.build.version.sdk)
         nonPortableRid="android.$__android_sdk_version-${targetArch}"
     elif [ "$targetOs" = "illumos" ]; then
         __uname_version=$(uname -v)
         case "$__uname_version" in
             omnios-*)
-                __omnios_major_version=$(echo "${__uname_version:8:2}")
-                nonPortableRid=omnios."$__omnios_major_version"-"$targetArch"
-            ;;
+                __omnios_major_version=$(echo "$__uname_version" | cut -c9-10)
+                nonPortableRid="omnios.$__omnios_major_version-${targetArch}"
+                ;;
             joyent_*)
-                __smartos_major_version=$(echo "${__uname_version:7:4}")
-                nonPortableRid=smartos."$__smartos_major_version"-"$targetArch"
-            ;;
-            illumos_*)
-                nonPortableRid=openindiana-"$targetArch"
-            ;;
+                __smartos_major_version=$(echo "$__uname_version" | cut -c9-10)
+                nonPortableRid="smartos.$__smartos_major_version-${targetArch}"
+                ;;
+            *)
+                nonPortableRid="illumos-${targetArch}"
+                ;;
         esac
     elif [ "$targetOs" = "solaris" ]; then
         __uname_version=$(uname -v)
-        __solaris_major_version=$(echo "${__uname_version%.*}")
-        nonPortableRid=solaris."$__solaris_major_version"-"$targetArch"
+        __solaris_major_version=$(echo "$__uname_version" | cut -d'.' -f1)
+        nonPortableRid="solaris.$__solaris_major_version-${targetArch}"
     elif [ "$targetOs" = "haiku" ]; then
-        __uname_release=$(uname -r)
+        __uname_release="$(uname -r)"
         nonPortableRid=haiku.r"$__uname_release"-"$targetArch"
     fi
 
-    echo "$(echo $nonPortableRid | tr '[:upper:]' '[:lower:]')"
+    echo "$nonPortableRid" | tr '[:upper:]' '[:lower:]'
 }
 
 # initDistroRidGlobal
@@ -85,26 +84,23 @@ getNonPortableDistroRid()
 #   None
 #
 # Notes:
-#
-# It is important to note that the function does not return anything, but it
-# exports the following variables on success:
-#
-#   __DistroRid   : Non-portable rid of the target platform.
-#   __PortableTargetOS  : OS-part of the portable rid that corresponds to the target platform.
-#
+#   It is important to note that the function does not return anything, but it
+#   exports the following variables on success:
+#     __DistroRid   : Non-portable rid of the target platform.
+#     __PortableTargetOS  : OS-part of the portable rid that corresponds to the target platform.
 initDistroRidGlobal()
 {
-    local targetOs="$1"
-    local targetArch="$2"
-    local rootfsDir=""
-    if [ "$#" -ge 3 ]; then
+    targetOs="$1"
+    targetArch="$2"
+    rootfsDir=""
+    if [ $# -ge 3 ]; then
         rootfsDir="$3"
     fi
 
     if [ -n "${rootfsDir}" ]; then
         # We may have a cross build. Check for the existence of the rootfsDir
         if [ ! -e "${rootfsDir}" ]; then
-            echo "Error rootfsDir has been passed, but the location is not valid."
+            echo "Error: rootfsDir has been passed, but the location is not valid."
             exit 1
         fi
     fi
@@ -119,7 +115,7 @@ initDistroRidGlobal()
             STRINGS="$(command -v llvm-strings || true)"
         fi
 
-        # Check for musl-based distros (e.g Alpine Linux, Void Linux).
+        # Check for musl-based distros (e.g. Alpine Linux, Void Linux).
         if "${rootfsDir}/usr/bin/ldd" --version 2>&1 | grep -q musl ||
                 ( [ -n "$STRINGS" ] && "$STRINGS" "${rootfsDir}/usr/bin/ldd" 2>&1 | grep -q musl ); then
             __PortableTargetOS="linux-musl"

+ 6 - 1
eng/common/native/init-os-and-arch.sh

@@ -1,4 +1,4 @@
-#!/usr/bin/env bash
+#!/bin/sh
 
 # Use uname to determine what the OS is.
 OSName=$(uname -s | tr '[:upper:]' '[:lower:]')
@@ -35,6 +35,10 @@ fi
 case "$CPUName" in
     arm64|aarch64)
         arch=arm64
+        if [ "$(getconf LONG_BIT)" -lt 64 ]; then
+            # This is 32-bit OS running on 64-bit CPU (for example Raspberry Pi OS)
+            arch=arm
+        fi
         ;;
 
     loongarch64)
@@ -50,6 +54,7 @@ case "$CPUName" in
         ;;
 
     armv7l|armv8l)
+        # shellcheck disable=SC1091
         if (NAME=""; . /etc/os-release; test "$NAME" = "Tizen"); then
             arch=armel
         else

+ 2 - 2
eng/common/post-build/publish-using-darc.ps1

@@ -12,7 +12,7 @@ param(
 try {
   . $PSScriptRoot\post-build-utils.ps1
 
-  $darc = Get-Darc 
+  $darc = Get-Darc
 
   $optionalParams = [System.Collections.ArrayList]::new()
 
@@ -46,7 +46,7 @@ try {
   }
 
   Write-Host 'done.'
-} 
+}
 catch {
   Write-Host $_
   Write-PipelineTelemetryError -Category 'PromoteBuild' -Message "There was an error while trying to publish build '$BuildId' to default channels."

+ 1 - 1
eng/common/sdk-task.ps1

@@ -64,7 +64,7 @@ try {
       $GlobalJson.tools | Add-Member -Name "vs" -Value (ConvertFrom-Json "{ `"version`": `"16.5`" }") -MemberType NoteProperty
     }
     if( -not ($GlobalJson.tools.PSObject.Properties.Name -match "xcopy-msbuild" )) {
-      $GlobalJson.tools | Add-Member -Name "xcopy-msbuild" -Value "17.8.1-2" -MemberType NoteProperty
+      $GlobalJson.tools | Add-Member -Name "xcopy-msbuild" -Value "17.8.5" -MemberType NoteProperty
     }
     if ($GlobalJson.tools."xcopy-msbuild".Trim() -ine "none") {
         $xcopyMSBuildToolsFolder = InitializeXCopyMSBuild $GlobalJson.tools."xcopy-msbuild" -install $true

+ 8 - 8
eng/common/templates/job/publish-build-assets.yml

@@ -58,7 +58,7 @@ jobs:
       demands: Cmd
     # If it's not devdiv, it's dnceng
     ${{ if ne(variables['System.TeamProject'], 'DevDiv') }}:
-      name: $(DncEngInternalBuildPool)
+      name: NetCore1ESPool-Publishing-Internal
       demands: ImageOverride -equals windows.vs2019.amd64
 
   steps:
@@ -66,7 +66,7 @@ jobs:
     - checkout: self
       fetchDepth: 3
       clean: true
-      
+
     - task: DownloadBuildArtifacts@0
       displayName: Download artifact
       inputs:
@@ -75,7 +75,7 @@ jobs:
         checkDownloadedFiles: true
       condition: ${{ parameters.condition }}
       continueOnError: ${{ parameters.continueOnError }}
-    
+
     - task: NuGetAuthenticate@1
 
     - task: PowerShell@2
@@ -90,7 +90,7 @@ jobs:
           /p:OfficialBuildId=$(Build.BuildNumber)
       condition: ${{ parameters.condition }}
       continueOnError: ${{ parameters.continueOnError }}
-    
+
     - task: powershell@2
       displayName: Create ReleaseConfigs Artifact
       inputs:
@@ -99,7 +99,7 @@ jobs:
           Add-Content -Path "$(Build.StagingDirectory)/ReleaseConfigs.txt" -Value $(BARBuildId)
           Add-Content -Path "$(Build.StagingDirectory)/ReleaseConfigs.txt" -Value "$(DefaultChannels)"
           Add-Content -Path "$(Build.StagingDirectory)/ReleaseConfigs.txt" -Value $(IsStableBuild)
-    
+
     - task: PublishBuildArtifacts@1
       displayName: Publish ReleaseConfigs Artifact
       inputs:
@@ -125,7 +125,7 @@ jobs:
 
     - task: PublishBuildArtifacts@1
       displayName: Publish SymbolPublishingExclusionsFile Artifact
-      condition: eq(variables['SymbolExclusionFile'], 'true') 
+      condition: eq(variables['SymbolExclusionFile'], 'true')
       inputs:
         PathtoPublish: '$(Build.SourcesDirectory)/eng/SymbolPublishingExclusionsFile.txt'
         PublishLocation: Container
@@ -141,7 +141,7 @@ jobs:
         displayName: Publish Using Darc
         inputs:
           filePath: $(Build.SourcesDirectory)/eng/common/post-build/publish-using-darc.ps1
-          arguments: -BuildId $(BARBuildId) 
+          arguments: -BuildId $(BARBuildId)
             -PublishingInfraVersion 3
             -AzdoToken '$(publishing-dnceng-devdiv-code-r-build-re)'
             -MaestroToken '$(MaestroApiAccessToken)'
@@ -152,4 +152,4 @@ jobs:
     - ${{ if eq(parameters.enablePublishBuildArtifacts, 'true') }}:
       - template: /eng/common/templates/steps/publish-logs.yml
         parameters:
-          JobLabel: 'Publish_Artifacts_Logs'     
+          JobLabel: 'Publish_Artifacts_Logs'

+ 1 - 1
eng/common/templates/post-build/common-variables.yml

@@ -18,7 +18,7 @@ variables:
   - name: SymbolToolVersion
     value: 1.0.1
   - name: BinlogToolVersion
-    value: 1.0.9
+    value: 1.0.11
 
   - name: runCodesignValidationInjection
     value: false

+ 8 - 8
eng/common/templates/post-build/post-build.yml

@@ -39,7 +39,7 @@ parameters:
     displayName: Enable NuGet validation
     type: boolean
     default: true
-    
+
   - name: publishInstallersAndChecksums
     displayName: Publish installers and checksums
     type: boolean
@@ -131,8 +131,8 @@ stages:
           displayName: Validate
           inputs:
             filePath: $(Build.SourcesDirectory)/eng/common/post-build/nuget-validation.ps1
-            arguments: -PackagesPath $(Build.ArtifactStagingDirectory)/PackageArtifacts/ 
-              -ToolDestinationPath $(Agent.BuildDirectory)/Extract/ 
+            arguments: -PackagesPath $(Build.ArtifactStagingDirectory)/PackageArtifacts/
+              -ToolDestinationPath $(Agent.BuildDirectory)/Extract/
 
     - job:
       displayName: Signing Validation
@@ -222,9 +222,9 @@ stages:
           displayName: Validate
           inputs:
             filePath: $(Build.SourcesDirectory)/eng/common/post-build/sourcelink-validation.ps1
-            arguments: -InputPath $(Build.ArtifactStagingDirectory)/BlobArtifacts/ 
-              -ExtractPath $(Agent.BuildDirectory)/Extract/ 
-              -GHRepoName $(Build.Repository.Name) 
+            arguments: -InputPath $(Build.ArtifactStagingDirectory)/BlobArtifacts/
+              -ExtractPath $(Agent.BuildDirectory)/Extract/
+              -GHRepoName $(Build.Repository.Name)
               -GHCommit $(Build.SourceVersion)
               -SourcelinkCliVersion $(SourceLinkCLIVersion)
           continueOnError: true
@@ -259,7 +259,7 @@ stages:
           demands: Cmd
         # If it's not devdiv, it's dnceng
         ${{ else }}:
-          name: $(DncEngInternalBuildPool)
+          name: NetCore1ESPool-Publishing-Internal
           demands: ImageOverride -equals windows.vs2019.amd64
       steps:
         - template: setup-maestro-vars.yml
@@ -273,7 +273,7 @@ stages:
           displayName: Publish Using Darc
           inputs:
             filePath: $(Build.SourcesDirectory)/eng/common/post-build/publish-using-darc.ps1
-            arguments: -BuildId $(BARBuildId) 
+            arguments: -BuildId $(BARBuildId)
               -PublishingInfraVersion ${{ parameters.publishingInfraVersion }}
               -AzdoToken '$(publishing-dnceng-devdiv-code-r-build-re)'
               -MaestroToken '$(MaestroApiAccessToken)'

+ 1 - 1
eng/common/templates/steps/publish-logs.yml

@@ -3,7 +3,7 @@ parameters:
   JobLabel: ''
   CustomSensitiveDataList: ''
   # A default - in case value from eng/common/templates/post-build/common-variables.yml is not passed
-  BinlogToolVersion: '1.0.9'
+  BinlogToolVersion: '1.0.11'
 
 steps:
 - task: Powershell@2

+ 4 - 2
eng/common/templates/steps/send-to-helix.yml

@@ -5,6 +5,8 @@ parameters:
   HelixBuild: $(Build.BuildNumber)       # required -- the build number Helix will use to identify this -- automatically set to the AzDO build number
   HelixTargetQueues: ''                  # required -- semicolon-delimited list of Helix queues to test on; see https://helix.dot.net/ for a list of queues
   HelixAccessToken: ''                   # required -- access token to make Helix API requests; should be provided by the appropriate variable group
+  HelixProjectPath: 'eng/common/helixpublish.proj'  # optional -- path to the project file to build relative to BUILD_SOURCESDIRECTORY
+  HelixProjectArguments: ''              # optional -- arguments passed to the build command
   HelixConfiguration: ''                 # optional -- additional property attached to a job
   HelixPreCommands: ''                   # optional -- commands to run before Helix work item execution
   HelixPostCommands: ''                  # optional -- commands to run after Helix work item execution
@@ -29,7 +31,7 @@ parameters:
   continueOnError: false                 # optional -- determines whether to continue the build if the step errors; defaults to false
 
 steps:
-  - powershell: 'powershell "$env:BUILD_SOURCESDIRECTORY\eng\common\msbuild.ps1 $env:BUILD_SOURCESDIRECTORY\eng\common\helixpublish.proj /restore /p:TreatWarningsAsErrors=false /t:Test /bl:$env:BUILD_SOURCESDIRECTORY\artifacts\log\$env:BuildConfig\SendToHelix.binlog"'
+  - powershell: 'powershell "$env:BUILD_SOURCESDIRECTORY\eng\common\msbuild.ps1 $env:BUILD_SOURCESDIRECTORY/${{ parameters.HelixProjectPath }} /restore /p:TreatWarningsAsErrors=false ${{ parameters.HelixProjectArguments }} /t:Test /bl:$env:BUILD_SOURCESDIRECTORY\artifacts\log\$env:BuildConfig\SendToHelix.binlog"'
     displayName: ${{ parameters.DisplayNamePrefix }} (Windows)
     env:
       BuildConfig: $(_BuildConfig)
@@ -59,7 +61,7 @@ steps:
       SYSTEM_ACCESSTOKEN: $(System.AccessToken)
     condition: and(${{ parameters.condition }}, eq(variables['Agent.Os'], 'Windows_NT'))
     continueOnError: ${{ parameters.continueOnError }}
-  - script: $BUILD_SOURCESDIRECTORY/eng/common/msbuild.sh $BUILD_SOURCESDIRECTORY/eng/common/helixpublish.proj /restore /p:TreatWarningsAsErrors=false /t:Test /bl:$BUILD_SOURCESDIRECTORY/artifacts/log/$BuildConfig/SendToHelix.binlog
+  - script: $BUILD_SOURCESDIRECTORY/eng/common/msbuild.sh $BUILD_SOURCESDIRECTORY/${{ parameters.HelixProjectPath }} /restore /p:TreatWarningsAsErrors=false ${{ parameters.HelixProjectArguments }} /t:Test /bl:$BUILD_SOURCESDIRECTORY/artifacts/log/$BuildConfig/SendToHelix.binlog
     displayName: ${{ parameters.DisplayNamePrefix }} (Unix)
     env:
       BuildConfig: $(_BuildConfig)

+ 2 - 0
eng/common/templates/steps/source-build.yml

@@ -94,6 +94,8 @@ steps:
       $baseOsArgs \
       /p:SourceBuildNonPortable=${{ parameters.platform.nonPortable }} \
       /p:ArcadeBuildFromSource=true \
+      /p:DotNetBuildSourceOnly=true \
+      /p:DotNetBuildRepo=true \
       /p:AssetManifestFileName=$assetManifestFileName
   displayName: Build
 

+ 6 - 6
eng/common/templates/variables/pool-providers.yml

@@ -1,15 +1,15 @@
-# Select a pool provider based off branch name. Anything with branch name containing 'release' must go into an -Svc pool, 
+# Select a pool provider based off branch name. Anything with branch name containing 'release' must go into an -Svc pool,
 # otherwise it should go into the "normal" pools. This separates out the queueing and billing of released branches.
 
-# Motivation: 
+# Motivation:
 #   Once a given branch of a repository's output has been officially "shipped" once, it is then considered to be COGS
 #   (Cost of goods sold) and should be moved to a servicing pool provider. This allows both separation of queueing
 #   (allowing release builds and main PR builds to not intefere with each other) and billing (required for COGS.
-#   Additionally, the pool provider name itself may be subject to change when the .NET Core Engineering Services 
-#   team needs to move resources around and create new and potentially differently-named pools. Using this template 
+#   Additionally, the pool provider name itself may be subject to change when the .NET Core Engineering Services
+#   team needs to move resources around and create new and potentially differently-named pools. Using this template
 #   file from an Arcade-ified repo helps guard against both having to update one's release/* branches and renaming.
 
-# How to use: 
+# How to use:
 #  This yaml assumes your shipped product branches use the naming convention "release/..." (which many do).
 #  If we find alternate naming conventions in broad usage it can be added to the condition below.
 #
@@ -54,4 +54,4 @@ variables:
           False,
           'NetCore1ESPool-Internal'
         )
-      ]
+      ]

+ 11 - 5
eng/common/tools.ps1

@@ -65,6 +65,11 @@ $ErrorActionPreference = 'Stop'
 # Base-64 encoded SAS token that has permission to storage container described by $runtimeSourceFeed
 [string]$runtimeSourceFeedKey = if (Test-Path variable:runtimeSourceFeedKey) { $runtimeSourceFeedKey } else { $null }
 
+# True if the build is a product build
+[bool]$productBuild = if (Test-Path variable:productBuild) { $productBuild } else { $false }
+
+[String[]]$properties = if (Test-Path variable:properties) { $properties } else { @() }
+
 function Create-Directory ([string[]] $path) {
     New-Item -Path $path -Force -ItemType 'Directory' | Out-Null
 }
@@ -379,8 +384,8 @@ function InitializeVisualStudioMSBuild([bool]$install, [object]$vsRequirements =
 
   # If the version of msbuild is going to be xcopied,
   # use this version. Version matches a package here:
-  # https://dev.azure.com/dnceng/public/_artifacts/feed/dotnet-eng/NuGet/RoslynTools.MSBuild/versions/17.8.1-2
-  $defaultXCopyMSBuildVersion = '17.8.1-2'
+  # https://dev.azure.com/dnceng/public/_artifacts/feed/dotnet-eng/NuGet/Microsoft.DotNet.Arcade.MSBuild.Xcopy/versions/17.8.5
+  $defaultXCopyMSBuildVersion = '17.8.5'
 
   if (!$vsRequirements) {
     if (Get-Member -InputObject $GlobalJson.tools -Name 'vs') {
@@ -445,7 +450,7 @@ function InitializeVisualStudioMSBuild([bool]$install, [object]$vsRequirements =
     if ($xcopyMSBuildVersion.Trim() -ine "none") {
         $vsInstallDir = InitializeXCopyMSBuild $xcopyMSBuildVersion $install
         if ($vsInstallDir -eq $null) {
-            throw "Could not xcopy msbuild. Please check that package 'RoslynTools.MSBuild @ $xcopyMSBuildVersion' exists on feed 'dotnet-eng'."
+            throw "Could not xcopy msbuild. Please check that package 'Microsoft.DotNet.Arcade.MSBuild.Xcopy @ $xcopyMSBuildVersion' exists on feed 'dotnet-eng'."
         }
     }
     if ($vsInstallDir -eq $null) {
@@ -482,7 +487,7 @@ function InstallXCopyMSBuild([string]$packageVersion) {
 }
 
 function InitializeXCopyMSBuild([string]$packageVersion, [bool]$install) {
-  $packageName = 'RoslynTools.MSBuild'
+  $packageName = 'Microsoft.DotNet.Arcade.MSBuild.Xcopy'
   $packageDir = Join-Path $ToolsDir "msbuild\$packageVersion"
   $packagePath = Join-Path $packageDir "$packageName.$packageVersion.nupkg"
 
@@ -850,7 +855,8 @@ function MSBuild-Core() {
     }
 
     # When running on Azure Pipelines, override the returned exit code to avoid double logging.
-    if ($ci -and $env:SYSTEM_TEAMPROJECT -ne $null) {
+    # Skip this when the build is a child of the VMR orchestrator build.
+    if ($ci -and $env:SYSTEM_TEAMPROJECT -ne $null -and !$productBuild -and $properties -notlike "*DotNetBuildRepo=true*") {
       Write-PipelineSetResult -Result "Failed" -Message "msbuild execution failed."
       # Exiting with an exit code causes the azure pipelines task to log yet another "noise" error
       # The above Write-PipelineSetResult will cause the task to be marked as failure without adding yet another error

+ 6 - 2
eng/common/tools.sh

@@ -68,6 +68,9 @@ fi
 runtime_source_feed=${runtime_source_feed:-''}
 runtime_source_feed_key=${runtime_source_feed_key:-''}
 
+# True if the build is a product build
+product_build=${product_build:-false}
+
 # Resolve any symlinks in the given path.
 function ResolvePath {
   local path=$1
@@ -141,7 +144,7 @@ function InitializeDotNetCli {
   if [[ $global_json_has_runtimes == false && -n "${DOTNET_INSTALL_DIR:-}" && -d "$DOTNET_INSTALL_DIR/sdk/$dotnet_sdk_version" ]]; then
     dotnet_root="$DOTNET_INSTALL_DIR"
   else
-    dotnet_root="$repo_root/.dotnet"
+    dotnet_root="${repo_root}.dotnet"
 
     export DOTNET_INSTALL_DIR="$dotnet_root"
 
@@ -503,7 +506,8 @@ function MSBuild-Core {
       echo "Build failed with exit code $exit_code. Check errors above."
 
       # When running on Azure Pipelines, override the returned exit code to avoid double logging.
-      if [[ "$ci" == "true" && -n ${SYSTEM_TEAMPROJECT:-} ]]; then
+      # Skip this when the build is a child of the VMR orchestrator build.
+      if [[ "$ci" == true && -n ${SYSTEM_TEAMPROJECT:-} && "$product_build" != true && "$properties" != *"DotNetBuildRepo=true"* ]]; then
         Write-PipelineSetResult -result "Failed" -message "msbuild execution failed."
         # Exiting with an exit code causes the azure pipelines task to log yet another "noise" error
         # The above Write-PipelineSetResult will cause the task to be marked as failure without adding yet another error

+ 2 - 2
global.json

@@ -26,7 +26,7 @@
     "xcopy-msbuild": "17.1.0"
   },
   "msbuild-sdks": {
-    "Microsoft.DotNet.Arcade.Sdk": "9.0.0-beta.24062.5",
-    "Microsoft.DotNet.Helix.Sdk": "9.0.0-beta.24062.5"
+    "Microsoft.DotNet.Arcade.Sdk": "9.0.0-beta.24129.2",
+    "Microsoft.DotNet.Helix.Sdk": "9.0.0-beta.24129.2"
   }
 }