Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Arcade TFMs according to TFM docs #14332

Merged
merged 4 commits into from
Jan 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Directory.Build.targets
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
ExcludeAssets="runtime"
VersionOverride="2.0.3"
Condition="'$(TargetFrameworkIdentifier)' != '.NETStandard' and
$([MSBuild]::IsTargetFrameworkCompatible('$(TargetFramework)', 'netstandard2.0'))" />
'$(SkipNETStandardLibraryPackageAutoInclude)' != 'true'" />
</ItemGroup>

</Project>
4 changes: 2 additions & 2 deletions eng/Microsoft.DotNet.XliffTasks.InTree.targets
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<XliffTasksProjectDirectory>$([MSBuild]::NormalizeDirectory('$(RepoRoot)', 'src', 'Microsoft.DotNet.XliffTasks'))</XliffTasksProjectDirectory>
<XliffTasksBaseOutputDirectory>$(ArtifactsBinDir)Microsoft.DotNet.XliffTasks\$(Configuration)\</XliffTasksBaseOutputDirectory>
<!-- Keep TFMs in sync with Microsoft.DotNet.XliffTasks.csproj -->
<XliffTasksDirectory Condition="'$(MSBuildRuntimeType)' == 'Core'">$(XliffTasksBaseOutputDirectory)$(NetCurrent)\</XliffTasksDirectory>
<XliffTasksDirectory Condition="'$(MSBuildRuntimeType)' == 'Core'">$(XliffTasksBaseOutputDirectory)$(NetToolCurrent)\</XliffTasksDirectory>
<XliffTasksDirectory Condition="'$(MSBuildRuntimeType)' != 'Core'">$(XliffTasksBaseOutputDirectory)$(NetFrameworkToolCurrent)\</XliffTasksDirectory>
<!-- XliffTasks tasks should be invoked out-of-proc in this repository to avoid assembly lock issues. -->
<XliffTasksTaskFactory>TaskHostFactory</XliffTasksTaskFactory>
Expand All @@ -25,7 +25,7 @@
PrivateAssets="all"
Private="false">
<!-- Keep TFMs in sync with Microsoft.DotNet.XliffTasks.csproj -->
<SetTargetFramework Condition="'$(MSBuildRuntimeType)' == 'Core'">TargetFramework=$(NetCurrent)</SetTargetFramework>
<SetTargetFramework Condition="'$(MSBuildRuntimeType)' == 'Core'">TargetFramework=$(NetToolCurrent)</SetTargetFramework>
<SetTargetFramework Condition="'$(MSBuildRuntimeType)' != 'Core'">TargetFramework=$(NetFrameworkToolCurrent)</SetTargetFramework>
</ProjectReference>
</ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>$(NetCurrent)</TargetFramework>
<TargetFramework>$(NetToolCurrent)</TargetFramework>
<Nullable>enable</Nullable>
</PropertyGroup>

Expand Down
5 changes: 3 additions & 2 deletions src/Common/Microsoft.Arcade.Common/FileSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
using System.IO;

#nullable enable

namespace Microsoft.Arcade.Common
{
public class FileSystem : IFileSystem
Expand All @@ -28,8 +29,8 @@ public class FileSystem : IFileSystem

public void WriteToFile(string path, string content)
{
string dirPath = Path.GetDirectoryName(path);
Directory.CreateDirectory(dirPath);
string? dirPath = Path.GetDirectoryName(path);
Directory.CreateDirectory(dirPath!);
File.WriteAllText(path, content);
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>netstandard2.0;$(NetFrameworkToolCurrent)</TargetFrameworks>
<!-- Treat this as a tooling library as it references msbuild. -->
<TargetFrameworks>$(NetToolCurrent);netstandard2.0;$(NetFrameworkToolCurrent)</TargetFrameworks>
<IsPackable>true</IsPackable>
<DefaultExcludesInProjectFolder Condition="$([MSBuild]::GetTargetFrameworkIdentifier('$(TargetFramework)')) != '.NETFramework'">**/*.Desktop.*</DefaultExcludesInProjectFolder>
</PropertyGroup>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>$(NetCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<TargetFrameworks>$(NetToolCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<IsTestUtilityProject>true</IsTestUtilityProject>
</PropertyGroup>

Expand Down
9 changes: 7 additions & 2 deletions src/Microsoft.Cci.Extensions/Microsoft.Cci.Extensions.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>$(NetCurrent);netstandard2.0</TargetFrameworks>
<!-- Treat this as a tooling library. -->
<TargetFrameworks>$(NetToolCurrent);netstandard2.0;$(NetFrameworkToolCurrent)</TargetFrameworks>
<ExcludeFromSourceBuild>true</ExcludeFromSourceBuild>
<IsPackable>true</IsPackable>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
Expand All @@ -19,9 +20,13 @@
<PackageReference Include="System.Composition" />
</ItemGroup>

<ItemGroup Condition="'$(TargetFrameworkIdentifier)' == '.NETStandard'">
<ItemGroup Condition="'$(TargetFrameworkIdentifier)' != '.NETCoreApp'">
<PackageReference Include="System.Memory" />
<PackageReference Include="System.Reflection.Metadata" />
</ItemGroup>

<ItemGroup Condition="'$(TargetFrameworkIdentifier)' == '.NETFramework'">
<Reference Include="System.Net.Http" />
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>$(NetCurrent)</TargetFramework>
<TargetFramework>$(NetToolCurrent)</TargetFramework>
<DefaultItemExcludes>$(DefaultItemExcludes);testassets\**\*</DefaultItemExcludes>
</PropertyGroup>

Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>$(NetCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<TargetFrameworks>$(NetToolCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<ExcludeFromSourceBuild>false</ExcludeFromSourceBuild>

<IsPackable>true</IsPackable>
<!-- Generate package during Build, rather than Pack, so that it can be used during Test. -->
Expand Down Expand Up @@ -44,8 +43,6 @@
<None Include="$(_GeneratedVersionFilePath)"
Pack="true"
PackagePath="tools\DefaultVersions.Generated.props" />
<Compile Remove="obj\**" />
<EmbeddedResource Remove="obj\**" />
</ItemGroup>

<ItemGroup>
Expand Down
1 change: 1 addition & 0 deletions src/Microsoft.DotNet.Arcade.Sdk/tools/Imports.targets
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<!-- Licensed to the .NET Foundation under one or more agreements. The .NET Foundation licenses this file to you under the MIT license. -->
<Project>

<Import Project="ProjectDefaults.targets"/>
<Import Project="StrongName.targets"/>
<Import Project="GenerateChecksums.targets" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@

<!-- Lowest version of .NET at the time of the release of NetCurrent that is supported by tooling.
Undefined when NetToolCurrent and NetToolMinimum are identical. -->
<NetToolMinimum>net6.0</NetToolMinimum>
<NetToolMinimum>net8.0</NetToolMinimum>

<!-- The version of .NET Framework that tools (i.e. msbuild tasks) should target. -->
<NetFrameworkToolCurrent>net472</NetFrameworkToolCurrent>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
<IsPackable>true</IsPackable>
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The library was marked as packable but never got consumed anywhere else than directly in Arcade.Sdk.csproj. It doesn't make sense to be packaged up.

<TargetFrameworks>$(NetToolCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
</PropertyGroup>

<ItemGroup>
Expand Down
6 changes: 3 additions & 3 deletions src/Microsoft.DotNet.ArcadeLogging/PipelinesLogger.cs
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.

using Microsoft.Build.Framework;
using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.IO;
using System.Collections;
using System.Linq;
using Microsoft.Build.Framework;

namespace Microsoft.DotNet.ArcadeLogging
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<!-- Most of the code has been ported from https://devdiv.visualstudio.com/DevDiv/_git/CoreFxTools repo.-->
<PropertyGroup>
<TargetFramework>$(NetCurrent)</TargetFramework>
<TargetFramework>$(NetToolCurrent)</TargetFramework>
<OutputType>Exe</OutputType>
<IsPackable>true</IsPackable>
<PackAsTool>true</PackAsTool>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>$(NetCurrent)</TargetFramework>
<TargetFramework>$(NetToolCurrent)</TargetFramework>
<IsPackable>true</IsPackable>
<PackTasks>false</PackTasks>
<Description>Targets for producing an archive of file outputs.</Description>
Expand Down
18 changes: 9 additions & 9 deletions src/Microsoft.DotNet.Build.Tasks.Archives/build/archives.targets
Original file line number Diff line number Diff line change
@@ -1,6 +1,15 @@
<!-- Licensed to the .NET Foundation under one or more agreements. The .NET Foundation licenses this file to you under the MIT license. -->
<Project>

<PropertyGroup>
<BuildDependsOn>
$(BuildDependsOn);
_GetSkipArchivesBuildProps;
_CreateArchive;
_CreateSymbolsArchive
</BuildDependsOn>
</PropertyGroup>

<Target Name="_GetCurrentProjectServicingConfiguration">
<ItemGroup>
<CurrentProjectServicingConfiguration
Expand Down Expand Up @@ -118,13 +127,4 @@
<Message Text="$(_SymbolsOutputPathRoot) -> $(_DestinationFileName)" Importance="high" />
</Target>

<PropertyGroup>
<BuildDependsOn>
$(BuildDependsOn);
_GetSkipArchivesBuildProps;
_CreateArchive;
_CreateSymbolsArchive
</BuildDependsOn>
</PropertyGroup>

</Project>
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>$(NetCurrent)</TargetFramework>
<TargetFramework>$(NetToolCurrent)</TargetFramework>
</PropertyGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>$(NetCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<TargetFrameworks>$(NetToolCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<SignAssembly>true</SignAssembly>
<Description>This package provides support for publishing assets to a NuGet protocol based feed.</Description>
<DevelopmentDependency>true</DevelopmentDependency>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>$(NetCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<TargetFrameworks>$(NetToolCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<IsPackable>true</IsPackable>
<Description>Installer task package</Description>
Expand Down Expand Up @@ -34,11 +34,6 @@
<Reference Include="WindowsBase" />
</ItemGroup>

<ItemGroup>
<Compile Remove="obj\**" />
<EmbeddedResource Remove="obj\**" />
</ItemGroup>

<ItemGroup>
<Compile Include="..\Common\Internal\BuildTask.cs" />
</ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
<!-- Licensed to the .NET Foundation under one or more agreements. The .NET Foundation licenses this file to you under the MIT license. -->
<Project>

<!--
These targets use MSBuild Exec tasks to run WiX 3 toolset commands.

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>$(NetCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<TargetFrameworks>$(NetToolCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<IsPackable>true</IsPackable>
<PackageType>MSBuildSdk</PackageType>
<Title>Packaging Targets and Tasks used by Dotnet repos</Title>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>$(NetCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<TargetFrameworks>$(NetToolCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<SignAssembly>false</SignAssembly>
<NoWarn>$(NoWarn);xUnit2013</NoWarn>
</PropertyGroup>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>$(NetCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<TargetFrameworks>$(NetToolCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<IsPackable>true</IsPackable>
<Title>Configuration system for cross-targeting projects.</Title>
<PackageDescription>This package provides the following MSBuild tasks: ChooseBestTargetFrameworksTask and ChooseBestP2PTargetFrameworkTask.</PackageDescription>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
<TargetFrameworks>$(NetToolCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<Description>Templating task package</Description>
<IsPackable>true</IsPackable>
<PackageTags>Arcade Build Tool Templating</PackageTags>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
<Project>

<PropertyGroup>
<MicrosoftDotNetBuildTasksTemplatingAssembly>$(MSBuildThisFileDirectory)..\tools\netstandard2.0\Microsoft.DotNet.Build.Tasks.Templating.dll</MicrosoftDotNetBuildTasksTemplatingAssembly>
<MicrosoftDotNetBuildTasksTemplatingAssembly Condition="'$(MSBuildRuntimeType)' == 'Core'">$(MSBuildThisFileDirectory)..\tools\net9.0\Microsoft.DotNet.Build.Tasks.Templating.dll</MicrosoftDotNetDeploymentTasksLinksTaskAssembly>
<MicrosoftDotNetBuildTasksTemplatingAssembly Condition="'$(MSBuildRuntimeType)' != 'Core'">$(MSBuildThisFileDirectory)..\tools\net472\Microsoft.DotNet.Build.Tasks.Templating.dll</MicrosoftDotNetDeploymentTasksLinksTaskAssembly>
</PropertyGroup>

<UsingTask TaskName="Microsoft.DotNet.Build.Tasks.Templating.GenerateFileFromTemplate" AssemblyFile="$(MicrosoftDotNetBuildTasksTemplatingAssembly)" />
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>$(NetCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<TargetFrameworks>$(NetToolCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
</PropertyGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>$(NetCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<TargetFrameworks>$(NetToolCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
</PropertyGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>$(NetCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<TargetFrameworks>$(NetToolCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<IsPackable>true</IsPackable>
<Description>Workload pack installer generation task package</Description>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.Build.NoTargets">

<PropertyGroup>
<TargetFramework>$(NetCurrent)</TargetFramework>
<TargetFramework>$(NetToolCurrent)</TargetFramework>
<IsPackable>true</IsPackable>
<Description>Common toolset for calling into CMake from MSBuild and easily reference native assets from managed projects.</Description>
<PackageType>MSBuildSdk</PackageType>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>$(NetCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<TargetFrameworks>$(NetToolCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<IsPackable>true</IsPackable>
<Description>Aka.ms link manager</Description>
<PackageTags>Arcade aka.ms</PackageTags>
Expand Down
2 changes: 1 addition & 1 deletion src/Microsoft.DotNet.GenAPI/Microsoft.DotNet.GenAPI.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>$(NetCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<TargetFrameworks>$(NetToolCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<ExcludeFromSourceBuild>true</ExcludeFromSourceBuild>
<PackageType>MSBuildSdk</PackageType>
<IsPackable>true</IsPackable>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>$(NetCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<TargetFrameworks>$(NetToolCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<PackageType>MSBuildSdk</PackageType>
<IsPackable>true</IsPackable>
</PropertyGroup>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>$(NetCurrent);$(NetFrameworkToolCurrent)</TargetFrameworks>
<TargetFrameworks>$(NetMinimum);$(NetFrameworkMinimum)</TargetFrameworks>
<SignAssembly>false</SignAssembly>
<IsPackable>true</IsPackable>
<ExcludeFromSourceBuild>true</ExcludeFromSourceBuild>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>netstandard2.0;$(NetFrameworkToolCurrent)</TargetFrameworks>
<!-- Treat this as a tooling library. -->
<TargetFrameworks>$(NetToolCurrent);netstandard2.0;$(NetFrameworkToolCurrent)</TargetFrameworks>
<IsPackable>true</IsPackable>
<Description>This package provides access to the Helix Api located at https://helix.dot.net/</Description>
<SwaggerDocumentUri>https://helix.dot.net/api/openapi.json</SwaggerDocumentUri>
<SwaggerClientName>HelixApi</SwaggerClientName>
<ExcludeFromSourceBuild>true</ExcludeFromSourceBuild>
</PropertyGroup>

<ItemGroup>
Expand Down
Loading
Loading