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

Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
Co-authored-by: Oleksandr Didyk <odidyk@microsoft.com>
This commit is contained in:
dotnet-maestro[bot] 2023-08-10 08:49:52 -05:00 committed by GitHub
parent 6247929f67
commit b68c0967d6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 261 additions and 15 deletions

View file

@ -206,18 +206,18 @@
</Dependency>
</ProductDependencies>
<ToolsetDependencies>
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="8.0.0-beta.23402.2">
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="8.0.0-beta.23409.5">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>3addc5d978d01e864792d2c6bce0b50ec105f857</Sha>
<Sha>bebd2de1988036b47ecefc7e72b66ce2f403e43d</Sha>
<SourceBuild RepoName="arcade" ManagedOnly="true" />
</Dependency>
<Dependency Name="Microsoft.DotNet.CMake.Sdk" Version="8.0.0-beta.23402.2">
<Dependency Name="Microsoft.DotNet.CMake.Sdk" Version="8.0.0-beta.23409.5">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>3addc5d978d01e864792d2c6bce0b50ec105f857</Sha>
<Sha>bebd2de1988036b47ecefc7e72b66ce2f403e43d</Sha>
</Dependency>
<Dependency Name="Microsoft.DotNet.Build.Tasks.Installers" Version="8.0.0-beta.23402.2">
<Dependency Name="Microsoft.DotNet.Build.Tasks.Installers" Version="8.0.0-beta.23409.5">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>3addc5d978d01e864792d2c6bce0b50ec105f857</Sha>
<Sha>bebd2de1988036b47ecefc7e72b66ce2f403e43d</Sha>
</Dependency>
<Dependency Name="Microsoft.DotNet.Darc" Version="1.1.0-beta.23374.1">
<Uri>https://github.com/dotnet/arcade-services</Uri>
@ -236,9 +236,9 @@
<Sha>41f1a158d460e11ded6cffd6340f9e671e2b0a5c</Sha>
<SourceBuild RepoName="source-build-reference-packages" ManagedOnly="true" />
</Dependency>
<Dependency Name="Microsoft.DotNet.XliffTasks" Version="1.0.0-beta.23381.1" CoherentParentDependency="Microsoft.DotNet.Arcade.Sdk">
<Dependency Name="Microsoft.DotNet.XliffTasks" Version="1.0.0-beta.23408.1" CoherentParentDependency="Microsoft.DotNet.Arcade.Sdk">
<Uri>https://github.com/dotnet/xliff-tasks</Uri>
<Sha>d3553ca27fb1c128f302f52b73c0079e65d62ea8</Sha>
<Sha>493329204079519072f0241ed26f692bdee0d60c</Sha>
<SourceBuild RepoName="xliff-tasks" ManagedOnly="true" />
</Dependency>
</ToolsetDependencies>

View file

@ -39,7 +39,7 @@
</PropertyGroup>
<PropertyGroup>
<!-- Dependency from https://github.com/dotnet/arcade -->
<MicrosoftDotNetBuildTasksInstallersPackageVersion>8.0.0-beta.23402.2</MicrosoftDotNetBuildTasksInstallersPackageVersion>
<MicrosoftDotNetBuildTasksInstallersPackageVersion>8.0.0-beta.23409.5</MicrosoftDotNetBuildTasksInstallersPackageVersion>
</PropertyGroup>
<PropertyGroup>
<!-- Dependency from https://github.com/dotnet/arcade-services -->

View file

@ -0,0 +1,132 @@
#!/usr/bin/env bash
# getNonPortableDistroRid
#
# Input:
# targetOs: (str)
# targetArch: (str)
# rootfsDir: (str)
#
# Return:
# non-portable rid
getNonPortableDistroRid()
{
local targetOs="$1"
local targetArch="$2"
local rootfsDir="$3"
local nonPortableRid=""
if [ "$targetOs" = "linux" ]; then
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%.*}"
fi
if [[ "${VERSION_ID:-}" =~ ^([[:digit:]]|\.)+$ ]]; then
nonPortableRid="${ID}.${VERSION_ID}-${targetArch}"
else
# Rolling release distros either do not set VERSION_ID, set it as blank or
# set it to non-version looking string (such as TEMPLATE_VERSION_ID on ArchLinux);
# so omit it here to be consistent with everything else.
nonPortableRid="${ID}-${targetArch}"
fi
elif [ -e "${rootfsDir}/android_platform" ]; then
source "$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%%.*}"; })
nonPortableRid="freebsd.$__freebsd_major_version-${targetArch}"
elif command -v getprop && getprop ro.product.system.model 2>&1 | 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"
;;
joyent_*)
__smartos_major_version=$(echo "${__uname_version:7:4}")
nonPortableRid=smartos."$__smartos_major_version"-"$targetArch"
;;
illumos_*)
nonPortableRid=openindiana-"$targetArch"
;;
esac
elif [ "$targetOs" = "solaris" ]; then
__uname_version=$(uname -v)
__solaris_major_version=$(echo "${__uname_version%.*}")
nonPortableRid=solaris."$__solaris_major_version"-"$targetArch"
elif [ "$targetOs" = "haiku" ]; then
__uname_release=$(uname -r)
nonPortableRid=haiku.r"$__uname_release"-"$targetArch"
fi
echo "$(echo $nonPortableRid | tr '[:upper:]' '[:lower:]')"
}
# initDistroRidGlobal
#
# Input:
# os: (str)
# arch: (str)
# isPortable: (int)
# rootfsDir?: (nullable:string)
#
# Return:
# 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.
#
initDistroRidGlobal()
{
local targetOs="$1"
local targetArch="$2"
local isPortable="$3"
local rootfsDir=""
if [ "$#" -ge 4 ]; then
rootfsDir="$4"
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."
exit 1
fi
fi
__DistroRid=$(getNonPortableDistroRid "${targetOs}" "${targetArch}" "${rootfsDir}")
if [ -z "${__PortableTargetOS:-}" ]; then
__PortableTargetOS="$targetOs"
STRINGS="$(command -v strings || true)"
if [ -z "$STRINGS" ]; then
STRINGS="$(command -v llvm-strings || true)"
fi
# 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"
fi
fi
export __DistroRid __PortableTargetOS
}

View file

@ -0,0 +1,80 @@
#!/usr/bin/env bash
# Use uname to determine what the OS is.
OSName=$(uname -s | tr '[:upper:]' '[:lower:]')
if command -v getprop && getprop ro.product.system.model 2>&1 | grep -qi android; then
OSName="android"
fi
case "$OSName" in
freebsd|linux|netbsd|openbsd|sunos|android|haiku)
os="$OSName" ;;
darwin)
os=osx ;;
*)
echo "Unsupported OS $OSName detected!"
exit 1 ;;
esac
# On Solaris, `uname -m` is discouraged, see https://docs.oracle.com/cd/E36784_01/html/E36870/uname-1.html
# and `uname -p` returns processor type (e.g. i386 on amd64).
# The appropriate tool to determine CPU is isainfo(1) https://docs.oracle.com/cd/E36784_01/html/E36870/isainfo-1.html.
if [ "$os" = "sunos" ]; then
if uname -o 2>&1 | grep -q illumos; then
os="illumos"
else
os="solaris"
fi
CPUName=$(isainfo -n)
else
# For the rest of the operating systems, use uname(1) to determine what the CPU is.
CPUName=$(uname -m)
fi
case "$CPUName" in
arm64|aarch64)
arch=arm64
;;
loongarch64)
arch=loongarch64
;;
riscv64)
arch=riscv64
;;
amd64|x86_64)
arch=x64
;;
armv7l|armv8l)
if (NAME=""; . /etc/os-release; test "$NAME" = "Tizen"); then
arch=armel
else
arch=arm
fi
;;
armv6l)
arch=armv6
;;
i[3-6]86)
echo "Unsupported CPU $CPUName detected, build might not succeed!"
arch=x86
;;
s390x)
arch=s390x
;;
ppc64le)
arch=ppc64le
;;
*)
echo "Unknown CPU $CPUName detected!"
exit 1
;;
esac

View file

@ -118,3 +118,12 @@ steps:
artifactName: BuildLogs_SourceBuild_${{ parameters.platform.name }}_Attempt$(System.JobAttempt)
continueOnError: true
condition: succeededOrFailed()
# Manually inject component detection so that we can ignore the source build upstream cache, which contains
# a nupkg cache of input packages (a local feed).
# This path must match the upstream cache path in property 'CurrentRepoSourceBuiltNupkgCacheDir'
# in src\Microsoft.DotNet.Arcade.Sdk\tools\SourceBuild\SourceBuildArcade.targets
- task: ComponentGovernanceComponentDetection@0
displayName: Component Detection (Exclude upstream cache)
inputs:
ignoreDirectories: '$(Build.SourcesDirectory)/artifacts/source-build/self/src/artifacts/obj/source-built-upstream-cache'

View file

@ -1,6 +1,6 @@
{
"tools": {
"dotnet": "8.0.100-preview.6.23330.14",
"dotnet": "8.0.100-preview.7.23376.3",
"runtimes": {
"dotnet": [
"$(VSRedistCommonNetCoreSharedFrameworkx6480PackageVersion)"
@ -11,7 +11,7 @@
"cmake": "3.21.0"
},
"msbuild-sdks": {
"Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.23402.2",
"Microsoft.DotNet.CMake.Sdk": "8.0.0-beta.23402.2"
"Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.23409.5",
"Microsoft.DotNet.CMake.Sdk": "8.0.0-beta.23409.5"
}
}

View file

@ -2,9 +2,6 @@
<Import Project="Sdk.props" Sdk="Microsoft.NET.Sdk" />
<PropertyGroup>
<!-- Addresses empty intermediate issue originally found by https://github.com/dotnet/arcade/pull/13067 -->
<!-- Should be removed once https://github.com/NuGet/Home/issues/11059 is implemented -->
<AllowEmptySourceBuiltIntermediates>true</AllowEmptySourceBuiltIntermediates>
<NuGetKeyFilePath>$(KeysDir)NuGet.Client.snk</NuGetKeyFilePath>
<DeterministicBuildOptOut>true</DeterministicBuildOptOut>
<!-- SYSLIB0051 - Type or member is obsolete: https://github.com/NuGet/Home/issues/12626 -->

View file

@ -0,0 +1,28 @@
From d0ca55c1bccc7bc69148576375976b79a648d693 Mon Sep 17 00:00:00 2001
From: Oleksandr Didyk <odidyk@microsoft.com>
Date: Thu, 10 Aug 2023 12:12:24 +0000
Subject: [PATCH] allow empty sb intermediate
Backport: https://github.com/NuGet/NuGet.Client/pull/5352
---
eng/SourceBuild.props | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/eng/SourceBuild.props b/eng/SourceBuild.props
index d0ca9808f..b44c9e837 100644
--- a/eng/SourceBuild.props
+++ b/eng/SourceBuild.props
@@ -6,6 +6,10 @@
<GitHubRepositoryName>nuget-client</GitHubRepositoryName>
<SourceBuildManagedOnly>true</SourceBuildManagedOnly>
<VersionPrefix>1.0.0</VersionPrefix>
+
+ <!-- Addresses empty intermediate issue originally found by https://github.com/dotnet/arcade/pull/13067 -->
+ <!-- Should be removed once https://github.com/NuGet/Home/issues/11059 is implemented -->
+ <AllowEmptySourceBuiltIntermediates>true</AllowEmptySourceBuiltIntermediates>
</PropertyGroup>
</Project>
--
2.25.1