forked from dotnet/sdk
/
Microsoft.DotNet.ApiCompat.Tool.csproj
46 lines (39 loc) · 2.15 KB
/
Microsoft.DotNet.ApiCompat.Tool.csproj
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<TargetFramework Condition="'$(DotNetBuildFromSource)' == 'true'">net8.0</TargetFramework>
<OutputType>Exe</OutputType>
<Nullable>enable</Nullable>
<IsPackable>true</IsPackable>
<IsShippingPackage>true</IsShippingPackage>
<StrongNameKeyId>Open</StrongNameKeyId>
<PackAsTool>true</PackAsTool>
<ToolCommandName>apicompat</ToolCommandName>
<PackageDescription>Tool to perform api compatibility checks on assemblies and packages.</PackageDescription>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="System.CommandLine" Version="$(SystemCommandLineVersion)" />
<ProjectReference Include="..\Microsoft.DotNet.PackageValidation\Microsoft.DotNet.PackageValidation.csproj" />
<ProjectReference Include="..\Microsoft.DotNet.ApiCompatibility\Microsoft.DotNet.ApiCompatibility.csproj" />
</ItemGroup>
<ItemGroup>
<None Include="$(RepoRoot)LICENSE.txt" PackagePath="LICENSE.txt" Pack="true" />
</ItemGroup>
<!-- Move code analysis assemblies into a sub directory so that they can be conditionally resolved. -->
<Target Name="UpdateMicrosoftCodeAnalysisFilesForBuild"
AfterTargets="ResolveAssemblyReferences">
<ItemGroup>
<ReferenceCopyLocalPaths Condition="$([System.String]::new('%(Filename)').StartsWith('Microsoft.CodeAnalysis'))"
DestinationSubDirectory="codeanalysis\%(ReferenceCopyLocalPaths.DestinationSubDirectory)" />
</ItemGroup>
</Target>
<Target Name="UpdateMicrosoftCodeAnalysisFilesForPublish"
AfterTargets="_ResolveCopyLocalAssetsForPublish"
BeforeTargets="_HandlePackageFileConflictsForPublish">
<ItemGroup>
<_ResolvedCopyLocalPublishAssets Condition="$([System.String]::new('%(Filename)').StartsWith('Microsoft.CodeAnalysis'))"
DestinationSubDirectory="codeanalysis\%(_ResolvedCopyLocalPublishAssets.DestinationSubDirectory)" />
</ItemGroup>
</Target>
<Import Project="..\Microsoft.DotNet.ApiCompat.Shared\Microsoft.DotNet.ApiCompat.Shared.projitems" Label="Shared" />
</Project>