Skip to content

Commit 4d5e328

Browse files
Merged PR 48566: [internal/release/8.0] Merge from public
Merge from public release/8.0 to internal/release/8.0 and resolve conflicts if necessary ---- #### AI description (iteration 1) #### PR Classification Merge from public branch to internal release branch. #### PR Summary This pull request updates dependencies and improves the handling of SBOM (Software Bill of Materials) generation. - Updated dependencies in `/eng/Version.Details.xml` and `/global.json` to newer versions. - Enhanced SBOM generation scripts in `/eng/common/generate-sbom-prep.ps1` and `/eng/common/generate-sbom-prep.sh` to handle special characters in artifact names. - Added `HelixProjectArguments` parameter in `/eng/common/templates-official/steps/send-to-helix.yml` and `/eng/common/templates/steps/send-to-helix.yml`. - Modified `/eng/common/tools.ps1` and `/eng/common/tools.sh` to update the URL for the dotnet-install scripts. - Added support for `s390x` architecture in `/eng/common/cross/toolchain.cmake`. <!-- GitOpsUserAgent=GitOps.Apps.Server.pullrequestcopilot -->
2 parents b929fc7 + 6d720da commit 4d5e328

File tree

9 files changed

+48
-34
lines changed

9 files changed

+48
-34
lines changed

eng/Version.Details.xml

+10-10
Original file line numberDiff line numberDiff line change
@@ -156,25 +156,25 @@
156156
</Dependency>
157157
</ProductDependencies>
158158
<ToolsetDependencies>
159-
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="8.0.0-beta.25120.1">
159+
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="8.0.0-beta.25164.5">
160160
<Uri>https://github.com/dotnet/arcade</Uri>
161-
<Sha>4ff4ce248e95ae74b0040de6a6c5939aa63120dc</Sha>
161+
<Sha>802042c6e779b73b4edb012ee1d5bae02ec8d41c</Sha>
162162
</Dependency>
163-
<Dependency Name="Microsoft.DotNet.CodeAnalysis" Version="8.0.0-beta.25120.1">
163+
<Dependency Name="Microsoft.DotNet.CodeAnalysis" Version="8.0.0-beta.25164.5">
164164
<Uri>https://github.com/dotnet/arcade</Uri>
165-
<Sha>4ff4ce248e95ae74b0040de6a6c5939aa63120dc</Sha>
165+
<Sha>802042c6e779b73b4edb012ee1d5bae02ec8d41c</Sha>
166166
</Dependency>
167-
<Dependency Name="Microsoft.DotNet.Helix.Sdk" Version="8.0.0-beta.25120.1">
167+
<Dependency Name="Microsoft.DotNet.Helix.Sdk" Version="8.0.0-beta.25164.5">
168168
<Uri>https://github.com/dotnet/arcade</Uri>
169-
<Sha>4ff4ce248e95ae74b0040de6a6c5939aa63120dc</Sha>
169+
<Sha>802042c6e779b73b4edb012ee1d5bae02ec8d41c</Sha>
170170
</Dependency>
171-
<Dependency Name="Microsoft.DotNet.ApiCompat" Version="8.0.0-beta.25120.1">
171+
<Dependency Name="Microsoft.DotNet.ApiCompat" Version="8.0.0-beta.25164.5">
172172
<Uri>https://github.com/dotnet/arcade</Uri>
173-
<Sha>4ff4ce248e95ae74b0040de6a6c5939aa63120dc</Sha>
173+
<Sha>802042c6e779b73b4edb012ee1d5bae02ec8d41c</Sha>
174174
</Dependency>
175-
<Dependency Name="Microsoft.DotNet.GenAPI" Version="8.0.0-beta.25120.1">
175+
<Dependency Name="Microsoft.DotNet.GenAPI" Version="8.0.0-beta.25164.5">
176176
<Uri>https://github.com/dotnet/arcade</Uri>
177-
<Sha>4ff4ce248e95ae74b0040de6a6c5939aa63120dc</Sha>
177+
<Sha>802042c6e779b73b4edb012ee1d5bae02ec8d41c</Sha>
178178
</Dependency>
179179
<Dependency Name="Microsoft.SourceLink.AzureRepos.Git" Version="8.0.0-beta.23409.2">
180180
<Uri>https://github.com/dotnet/sourcelink</Uri>

eng/Versions.props

+2-2
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,8 @@
4949
</PropertyGroup>
5050
<!-- Packages that come from https://github.com/dotnet/arcade -->
5151
<PropertyGroup>
52-
<MicrosoftDotNetApiCompatVersion>8.0.0-beta.25120.1</MicrosoftDotNetApiCompatVersion>
53-
<MicrosoftDotNetCodeAnalysisPackageVersion>8.0.0-beta.25120.1</MicrosoftDotNetCodeAnalysisPackageVersion>
52+
<MicrosoftDotNetApiCompatVersion>8.0.0-beta.25164.5</MicrosoftDotNetApiCompatVersion>
53+
<MicrosoftDotNetCodeAnalysisPackageVersion>8.0.0-beta.25164.5</MicrosoftDotNetCodeAnalysisPackageVersion>
5454
</PropertyGroup>
5555
<!-- Sourcelink -->
5656
<PropertyGroup>

eng/common/generate-sbom-prep.ps1

+14-6
Original file line numberDiff line numberDiff line change
@@ -4,18 +4,26 @@ Param(
44

55
. $PSScriptRoot\pipeline-logging-functions.ps1
66

7+
# Normally - we'd listen to the manifest path given, but 1ES templates will overwrite if this level gets uploaded directly
8+
# with their own overwriting ours. So we create it as a sub directory of the requested manifest path.
9+
$ArtifactName = "${env:SYSTEM_STAGENAME}_${env:AGENT_JOBNAME}_SBOM"
10+
$SafeArtifactName = $ArtifactName -replace '["/:<>\\|?@*"() ]', '_'
11+
$SbomGenerationDir = Join-Path $ManifestDirPath $SafeArtifactName
12+
13+
Write-Host "Artifact name before : $ArtifactName"
14+
Write-Host "Artifact name after : $SafeArtifactName"
15+
716
Write-Host "Creating dir $ManifestDirPath"
17+
818
# create directory for sbom manifest to be placed
9-
if (!(Test-Path -path $ManifestDirPath))
19+
if (!(Test-Path -path $SbomGenerationDir))
1020
{
11-
New-Item -ItemType Directory -path $ManifestDirPath
12-
Write-Host "Successfully created directory $ManifestDirPath"
21+
New-Item -ItemType Directory -path $SbomGenerationDir
22+
Write-Host "Successfully created directory $SbomGenerationDir"
1323
}
1424
else{
1525
Write-PipelineTelemetryError -category 'Build' "Unable to create sbom folder."
1626
}
1727

1828
Write-Host "Updating artifact name"
19-
$artifact_name = "${env:SYSTEM_STAGENAME}_${env:AGENT_JOBNAME}_SBOM" -replace '["/:<>\\|?@*"() ]', '_'
20-
Write-Host "Artifact name $artifact_name"
21-
Write-Host "##vso[task.setvariable variable=ARTIFACT_NAME]$artifact_name"
29+
Write-Host "##vso[task.setvariable variable=ARTIFACT_NAME]$SafeArtifactName"

eng/common/generate-sbom-prep.sh

+11-6
Original file line numberDiff line numberDiff line change
@@ -14,19 +14,24 @@ done
1414
scriptroot="$( cd -P "$( dirname "$source" )" && pwd )"
1515
. $scriptroot/pipeline-logging-functions.sh
1616

17+
# replace all special characters with _, some builds use special characters like : in Agent.Jobname, that is not a permissible name while uploading artifacts.
18+
artifact_name=$SYSTEM_STAGENAME"_"$AGENT_JOBNAME"_SBOM"
19+
safe_artifact_name="${artifact_name//["/:<>\\|?@*$" ]/_}"
20+
1721
manifest_dir=$1
1822

19-
if [ ! -d "$manifest_dir" ] ; then
20-
mkdir -p "$manifest_dir"
21-
echo "Sbom directory created." $manifest_dir
23+
# Normally - we'd listen to the manifest path given, but 1ES templates will overwrite if this level gets uploaded directly
24+
# with their own overwriting ours. So we create it as a sub directory of the requested manifest path.
25+
sbom_generation_dir="$manifest_dir/$safe_artifact_name"
26+
27+
if [ ! -d "$sbom_generation_dir" ] ; then
28+
mkdir -p "$sbom_generation_dir"
29+
echo "Sbom directory created." $sbom_generation_dir
2230
else
2331
Write-PipelineTelemetryError -category 'Build' "Unable to create sbom folder."
2432
fi
2533

26-
artifact_name=$SYSTEM_STAGENAME"_"$AGENT_JOBNAME"_SBOM"
2734
echo "Artifact name before : "$artifact_name
28-
# replace all special characters with _, some builds use special characters like : in Agent.Jobname, that is not a permissible name while uploading artifacts.
29-
safe_artifact_name="${artifact_name//["/:<>\\|?@*$" ]/_}"
3035
echo "Artifact name after : "$safe_artifact_name
3136
export ARTIFACT_NAME=$safe_artifact_name
3237
echo "##vso[task.setvariable variable=ARTIFACT_NAME]$safe_artifact_name"

eng/common/templates-official/job/job.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ parameters:
3838
enableSbom: true
3939
PackageVersion: 7.0.0
4040
BuildDropPath: '$(Build.SourcesDirectory)/artifacts'
41+
ManifestDirPath: $(Build.ArtifactStagingDirectory)/sbom
4142

4243
jobs:
4344
- job: ${{ parameters.name }}
@@ -261,4 +262,4 @@ jobs:
261262
targetPath: '$(Build.SourcesDirectory)\eng\common\BuildConfiguration'
262263
artifactName: 'BuildConfiguration'
263264
displayName: 'Publish build retry configuration'
264-
continueOnError: true
265+
continueOnError: true

eng/common/templates-official/steps/generate-sbom.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ steps:
3535
PackageName: ${{ parameters.packageName }}
3636
BuildDropPath: ${{ parameters.buildDropPath }}
3737
PackageVersion: ${{ parameters.packageVersion }}
38-
ManifestDirPath: ${{ parameters.manifestDirPath }}
38+
ManifestDirPath: ${{ parameters.manifestDirPath }}/$(ARTIFACT_NAME)
3939
${{ if ne(parameters.IgnoreDirectories, '') }}:
4040
AdditionalComponentDetectorArgs: '--IgnoreDirectories ${{ parameters.IgnoreDirectories }}'
4141

eng/common/tools.ps1

+2-2
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
[bool]$useInstalledDotNetCli = if (Test-Path variable:useInstalledDotNetCli) { $useInstalledDotNetCli } else { $true }
4343

4444
# Enable repos to use a particular version of the on-line dotnet-install scripts.
45-
# default URL: https://dotnet.microsoft.com/download/dotnet/scripts/v1/dotnet-install.ps1
45+
# default URL: https://builds.dotnet.microsoft.com/dotnet/scripts/v1/dotnet-install.ps1
4646
[string]$dotnetInstallScriptVersion = if (Test-Path variable:dotnetInstallScriptVersion) { $dotnetInstallScriptVersion } else { 'v1' }
4747

4848
# True to use global NuGet cache instead of restoring packages to repository-local directory.
@@ -263,7 +263,7 @@ function GetDotNetInstallScript([string] $dotnetRoot) {
263263
if (!(Test-Path $installScript)) {
264264
Create-Directory $dotnetRoot
265265
$ProgressPreference = 'SilentlyContinue' # Don't display the console progress UI - it's a huge perf hit
266-
$uri = "https://dotnet.microsoft.com/download/dotnet/scripts/$dotnetInstallScriptVersion/dotnet-install.ps1"
266+
$uri = "https://builds.dotnet.microsoft.com/dotnet/scripts/$dotnetInstallScriptVersion/dotnet-install.ps1"
267267

268268
Retry({
269269
Write-Host "GET $uri"

eng/common/tools.sh

+2-2
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ warn_as_error=${warn_as_error:-true}
5454
use_installed_dotnet_cli=${use_installed_dotnet_cli:-true}
5555

5656
# Enable repos to use a particular version of the on-line dotnet-install scripts.
57-
# default URL: https://dotnet.microsoft.com/download/dotnet/scripts/v1/dotnet-install.sh
57+
# default URL: https://builds.dotnet.microsoft.com/dotnet/scripts/v1/dotnet-install.sh
5858
dotnetInstallScriptVersion=${dotnetInstallScriptVersion:-'v1'}
5959

6060
# True to use global NuGet cache instead of restoring packages to repository-local directory.
@@ -297,7 +297,7 @@ function with_retries {
297297
function GetDotNetInstallScript {
298298
local root=$1
299299
local install_script="$root/dotnet-install.sh"
300-
local install_script_url="https://dotnet.microsoft.com/download/dotnet/scripts/$dotnetInstallScriptVersion/dotnet-install.sh"
300+
local install_script_url="https://builds.dotnet.microsoft.com/dotnet/scripts/$dotnetInstallScriptVersion/dotnet-install.sh"
301301

302302
if [[ ! -a "$install_script" ]]; then
303303
mkdir -p "$root"

global.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"tools": {
3-
"dotnet": "8.0.113",
3+
"dotnet": "8.0.114",
44
"runtimes": {
55
"dotnet": [
66
"2.1.7",
@@ -12,11 +12,11 @@
1212
}
1313
},
1414
"msbuild-sdks": {
15-
"Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.25120.1",
16-
"Microsoft.DotNet.Helix.Sdk": "8.0.0-beta.25120.1"
15+
"Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.25164.5",
16+
"Microsoft.DotNet.Helix.Sdk": "8.0.0-beta.25164.5"
1717
},
1818
"sdk": {
19-
"version": "8.0.113"
19+
"version": "8.0.114"
2020
},
2121
"native-tools": {
2222
"strawberry-perl": "5.28.1.1-1",

0 commit comments

Comments
 (0)