Skip to content

Commit

Permalink
[main] Update dependencies from dotnet/arcade (dotnet#46512)
Browse files Browse the repository at this point in the history
[main] Update dependencies from dotnet/arcade


 - Attempt to move ExcludeFromBuild logic earlier

 - Set cross targeting build common targets
  • Loading branch information
dotnet-maestro[bot] authored Feb 15, 2023
1 parent 63a0251 commit e655394
Show file tree
Hide file tree
Showing 8 changed files with 51 additions and 45 deletions.
24 changes: 24 additions & 0 deletions Directory.Build.BeforeCommonTargets.targets
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
<Project>
<PropertyGroup>
<!-- Only build Microsoft.AspNetCore.App, Microsoft.AspNetCore.App.Ref, ref/ assemblies, and ProjectTemplates in source build. -->
<!-- Analyzer package are needed in source build for WebSDK -->
<ExcludeFromSourceBuild
Condition="'$(ExcludeFromSourceBuild)' == '' and
'$(DotNetBuildFromSource)' == 'true' and
'$(IsAspNetCoreApp)' != 'true' and
'$(MSBuildProjectName)' != '$(TargetingPackName)' and
'$(IsAnalyzersProject)' != 'true' and
'$(IsProjectTemplateProject)' != 'true'">true</ExcludeFromSourceBuild>

<!-- If the user has specified that they want to skip building any test related projects with SkipTestBuild,
suppress all targets for TestProjects using ExcludeFromBuild. -->
<ExcludeFromBuild Condition="'$(IsPackable)' != 'true' and
'$(SkipTestBuild)' == 'true' and
($(IsTestProject) or
'$(IsTestAssetProject)' == 'true' or
'$(IsBenchmarkProject)' == 'true' or
'$(IsSampleProject)' == 'true' or
'$(IsSpecificationTestProject)' == 'true' or
'$(IsMicrobenchmarksProject)' == 'true')">true</ExcludeFromBuild>
</PropertyGroup>
</Project>
6 changes: 6 additions & 0 deletions Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -240,6 +240,12 @@
<ArchiveExtension Condition="'$(TargetOsName)' == 'win'">.zip</ArchiveExtension>
</PropertyGroup>

<PropertyGroup>
<!-- Set the arcade before common targets so we compute ExcludeFromBuild before arcade uses it. -->
<CustomBeforeMicrosoftCommonTargets>$(MSBuildThisFileDirectory)Directory.Build.BeforeCommonTargets.targets</CustomBeforeMicrosoftCommonTargets>
<CustomBeforeMicrosoftCommonCrossTargetingTargets>$(MSBuildThisFileDirectory)Directory.Build.BeforeCommonTargets.targets</CustomBeforeMicrosoftCommonCrossTargetingTargets>
</PropertyGroup>

<Import Project="eng\Workarounds.props" />
<Import Project="artifacts\bin\GenerateFiles\Directory.Build.props" Condition=" '$(MSBuildProjectName)' != 'GenerateFiles' " />
<Import Project="eng\Dependencies.props" />
Expand Down
21 changes: 0 additions & 21 deletions Directory.Build.targets
Original file line number Diff line number Diff line change
@@ -1,27 +1,6 @@
<Project>
<PropertyGroup>
<!-- Only build Microsoft.AspNetCore.App, Microsoft.AspNetCore.App.Ref, ref/ assemblies, and ProjectTemplates in source build. -->
<!-- Analyzer package are needed in source build for WebSDK -->
<ExcludeFromSourceBuild
Condition="'$(ExcludeFromSourceBuild)' == '' and
'$(DotNetBuildFromSource)' == 'true' and
'$(IsAspNetCoreApp)' != 'true' and
'$(MSBuildProjectName)' != '$(TargetingPackName)' and
'$(IsAnalyzersProject)' != 'true' and
'$(IsProjectTemplateProject)' != 'true'">true</ExcludeFromSourceBuild>

<EnableAOTAnalyzer Condition=" '$(EnableAOTAnalyzer)' == '' ">$([MSBuild]::ValueOrDefault($(IsTrimmable),'false'))</EnableAOTAnalyzer>

<!-- If the user has specified that they want to skip building any test related projects with SkipTestBuild,
suppress all targets for TestProjects using ExcludeFromBuild. -->
<ExcludeFromBuild Condition="'$(IsPackable)' != 'true' and
'$(SkipTestBuild)' == 'true' and
($(IsTestProject) or
'$(IsTestAssetProject)' == 'true' or
'$(IsBenchmarkProject)' == 'true' or
'$(IsSampleProject)' == 'true' or
'$(IsSpecificationTestProject)' == 'true' or
'$(IsMicrobenchmarksProject)' == 'true')">true</ExcludeFromBuild>
</PropertyGroup>

<PropertyGroup>
Expand Down
20 changes: 10 additions & 10 deletions eng/Version.Details.xml
Original file line number Diff line number Diff line change
Expand Up @@ -302,26 +302,26 @@
<Uri>https://github.com/dotnet/runtime</Uri>
<Sha>53bb518ea482a5960577b151c11cc1297e5dea6d</Sha>
</Dependency>
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="8.0.0-beta.23103.1">
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="8.0.0-beta.23110.3">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>c453dfef2f41533de5cb03b2115aab9d0dfc74c6</Sha>
<Sha>96d8be74c39a4765ec919ff9bebf9e0c875fc195</Sha>
<SourceBuild RepoName="arcade" ManagedOnly="true" />
</Dependency>
<Dependency Name="Microsoft.DotNet.Build.Tasks.Installers" Version="8.0.0-beta.23103.1">
<Dependency Name="Microsoft.DotNet.Build.Tasks.Installers" Version="8.0.0-beta.23110.3">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>c453dfef2f41533de5cb03b2115aab9d0dfc74c6</Sha>
<Sha>96d8be74c39a4765ec919ff9bebf9e0c875fc195</Sha>
</Dependency>
<Dependency Name="Microsoft.DotNet.Build.Tasks.Templating" Version="8.0.0-beta.23103.1">
<Dependency Name="Microsoft.DotNet.Build.Tasks.Templating" Version="8.0.0-beta.23110.3">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>c453dfef2f41533de5cb03b2115aab9d0dfc74c6</Sha>
<Sha>96d8be74c39a4765ec919ff9bebf9e0c875fc195</Sha>
</Dependency>
<Dependency Name="Microsoft.DotNet.Helix.Sdk" Version="8.0.0-beta.23103.1">
<Dependency Name="Microsoft.DotNet.Helix.Sdk" Version="8.0.0-beta.23110.3">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>c453dfef2f41533de5cb03b2115aab9d0dfc74c6</Sha>
<Sha>96d8be74c39a4765ec919ff9bebf9e0c875fc195</Sha>
</Dependency>
<Dependency Name="Microsoft.DotNet.RemoteExecutor" Version="8.0.0-beta.23103.1">
<Dependency Name="Microsoft.DotNet.RemoteExecutor" Version="8.0.0-beta.23110.3">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>c453dfef2f41533de5cb03b2115aab9d0dfc74c6</Sha>
<Sha>96d8be74c39a4765ec919ff9bebf9e0c875fc195</Sha>
</Dependency>
</ToolsetDependencies>
</Dependencies>
6 changes: 3 additions & 3 deletions eng/Versions.props
Original file line number Diff line number Diff line change
Expand Up @@ -135,9 +135,9 @@
<MicrosoftEntityFrameworkCoreVersion>8.0.0-preview.2.23115.5</MicrosoftEntityFrameworkCoreVersion>
<MicrosoftEntityFrameworkCoreDesignVersion>8.0.0-preview.2.23115.5</MicrosoftEntityFrameworkCoreDesignVersion>
<!-- Packages from dotnet/arcade -->
<MicrosoftDotNetBuildTasksInstallersVersion>8.0.0-beta.23103.1</MicrosoftDotNetBuildTasksInstallersVersion>
<MicrosoftDotNetBuildTasksTemplatingVersion>8.0.0-beta.23103.1</MicrosoftDotNetBuildTasksTemplatingVersion>
<MicrosoftDotNetRemoteExecutorVersion>8.0.0-beta.23103.1</MicrosoftDotNetRemoteExecutorVersion>
<MicrosoftDotNetBuildTasksInstallersVersion>8.0.0-beta.23110.3</MicrosoftDotNetBuildTasksInstallersVersion>
<MicrosoftDotNetBuildTasksTemplatingVersion>8.0.0-beta.23110.3</MicrosoftDotNetBuildTasksTemplatingVersion>
<MicrosoftDotNetRemoteExecutorVersion>8.0.0-beta.23110.3</MicrosoftDotNetRemoteExecutorVersion>
<!-- Packages from dotnet/source-build-externals -->
<MicrosoftSourceBuildIntermediatesourcebuildexternalsVersion>8.0.0-alpha.1.23110.2</MicrosoftSourceBuildIntermediatesourcebuildexternalsVersion>
<!-- Packages from dotnet/xdt -->
Expand Down
9 changes: 3 additions & 6 deletions eng/common/init-tools-native.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,8 @@ try {
Select-Object -Expand 'native-tools' -ErrorAction SilentlyContinue
if ($NativeTools) {
if ($PathPromotion -eq $True) {
if ($env:SYSTEM_TEAMPROJECT) { # check to see if we're in an Azure pipelines build
$ArcadeToolsDirectory = "$env:SYSTEMDRIVE\arcade-tools"
if (Test-Path $ArcadeToolsDirectory) { # if this directory exists, we should use native tools on machine
$NativeTools.PSObject.Properties | ForEach-Object {
$ToolName = $_.Name
$ToolVersion = $_.Value
Expand All @@ -93,11 +94,6 @@ try {
if ($ToolVersion -eq "latest") {
$ToolVersion = ""
}
$ArcadeToolsDirectory = "C:\arcade-tools"
if (-not (Test-Path $ArcadeToolsDirectory)) {
Write-Error "Arcade tools directory '$ArcadeToolsDirectory' was not found; artifacts were not properly installed."
exit 1
}
$ToolDirectories = (Get-ChildItem -Path "$ArcadeToolsDirectory" -Filter "$ToolName-$ToolVersion*" | Sort-Object -Descending)
if ($ToolDirectories -eq $null) {
Write-Error "Unable to find directory for $ToolName $ToolVersion; please make sure the tool is installed on this image."
Expand Down Expand Up @@ -125,6 +121,7 @@ try {

if ((Get-Command "$ToolName" -ErrorAction SilentlyContinue) -eq $null) {
Write-PipelineTelemetryError -Category 'NativeToolsBootstrap' -Message "$ToolName not found on path. Please install $ToolName $ToolVersion before proceeding."
Write-PipelineTelemetryError -Category 'NativeToolsBootstrap' -Message "If this is running on a build machine, the arcade-tools directory was not found, which means there's an error with the image."
}
}
exit 0
Expand Down
6 changes: 3 additions & 3 deletions eng/common/templates/job/job.yml
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ jobs:
- ${{ if and(eq(parameters.runAsPublic, 'false'), eq(variables['System.TeamProject'], 'internal')) }}:
- task: NuGetAuthenticate@0

- ${{ if or(eq(parameters.artifacts.download, 'true'), ne(parameters.artifacts.download, '')) }}:
- ${{ if and(ne(parameters.artifacts.download, 'false'), ne(parameters.artifacts.download, '')) }}:
- task: DownloadPipelineArtifact@2
inputs:
buildType: current
Expand Down Expand Up @@ -171,7 +171,7 @@ jobs:
TeamName: $(_TeamName)

- ${{ if ne(parameters.artifacts.publish, '') }}:
- ${{ if or(eq(parameters.artifacts.publish.artifacts, 'true'), ne(parameters.artifacts.publish.artifacts, '')) }}:
- ${{ if and(ne(parameters.artifacts.publish.artifacts, 'false'), ne(parameters.artifacts.publish.artifacts, '')) }}:
- task: CopyFiles@2
displayName: Gather binaries for publish to artifacts
inputs:
Expand All @@ -192,7 +192,7 @@ jobs:
ArtifactName: ${{ coalesce(parameters.artifacts.publish.artifacts.name , 'Artifacts_$(Agent.Os)_$(_BuildConfig)') }}
continueOnError: true
condition: always()
- ${{ if or(eq(parameters.artifacts.publish.logs, 'true'), ne(parameters.artifacts.publish.logs, '')) }}:
- ${{ if and(ne(parameters.artifacts.publish.logs, 'false'), ne(parameters.artifacts.publish.logs, '')) }}:
- publish: artifacts/log
artifact: ${{ coalesce(parameters.artifacts.publish.logs.name, 'Logs_Build_$(Agent.Os)_$(_BuildConfig)') }}
displayName: Publish logs
Expand Down
4 changes: 2 additions & 2 deletions global.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
},
"msbuild-sdks": {
"Yarn.MSBuild": "1.22.10",
"Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.23103.1",
"Microsoft.DotNet.Helix.Sdk": "8.0.0-beta.23103.1"
"Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.23110.3",
"Microsoft.DotNet.Helix.Sdk": "8.0.0-beta.23110.3"
}
}

0 comments on commit e655394

Please sign in to comment.