forked from dotnet/sdk
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Microsoft.NET.Build.Containers.csproj
104 lines (90 loc) · 4.59 KB
/
Microsoft.NET.Build.Containers.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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>$(SdkTargetFramework);net472</TargetFrameworks>
<TargetFrameworks Condition=" '$(DotNetBuildFromSource)' == 'true' ">$(SdkTargetFramework)</TargetFrameworks>
<ImplicitUsings Condition="'$(TargetFramework)' != 'net472'">enable</ImplicitUsings>
<TargetsForTfmSpecificBuildOutput>
$(TargetsForTfmSpecificBuildOutput);CopyProjectReferencesToPackage
</TargetsForTfmSpecificBuildOutput>
<!-- Tell the SDK to generate a deps.json file -->
<GenerateDependencyFile>true</GenerateDependencyFile>
<!-- Allow the packaging project to use the name `Microsoft.NET.Build.Containers` for the nuget package -->
<Packageid>.</Packageid>
<!-- While in prerelease, ship the symbols to everyone all the time. -->
<DebugType>embedded</DebugType>
<Nullable>enable</Nullable>
<NoWarn>$(NoWarn);CS8002</NoWarn>
<StrongNameKeyId>MicrosoftShared</StrongNameKeyId>
<SignAssembly>true</SignAssembly>
</PropertyGroup>
<ItemGroup>
<ProjectReference Include="..\..\Cli\Microsoft.DotNet.Cli.Utils\Microsoft.DotNet.Cli.Utils.csproj" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="Microsoft.Build.Utilities.Core" PrivateAssets="all" ExcludeAssets="runtime" />
<PackageReference Include="Microsoft.CodeAnalysis.PublicApiAnalyzers" Condition=" '$(DotNetBuildFromSource)' != 'true' ">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="Nuget.Packaging" />
<PackageReference Include="Valleysoft.DockerCredsProvider" />
<PackageReference Include="Microsoft.Extensions.Logging" />
<PackageReference Include="Microsoft.Extensions.Logging.Abstractions" />
</ItemGroup>
<!-- net472 builds manually import files to compile -->
<ItemGroup Condition="'$(TargetFramework)' == 'net472'">
<Compile Remove="**/*.*" />
<Compile Include="ReferenceParser.cs" />
<Compile Include="KnownStrings.cs" />
<Compile Include="Tasks/ParseContainerProperties.cs" />
<Compile Include="Tasks/CreateNewImage.Interface.cs" />
<Compile Include="Tasks/CreateNewImageToolTask.cs" />
<Compile Include="Tasks/ComputeDotnetBaseImageTag.cs" />
<Compile Include="ContainerHelpers.cs" />
<Compile Include="net472Definitions.cs" />
<Compile Include="VSHostObject.cs" />
<Compile Include="Port.cs" />
<Compile Include="Resources\Resource.cs" />
<Compile Include="Resources\Strings.Designer.cs" />
<Compile Include="Globals.cs" />
</ItemGroup>
<!-- core remove files specific to net472 workarounds -->
<ItemGroup Condition="'$(TargetFramework)' != 'net472'">
<Compile Remove="Tasks/CreateNewImageToolTask.cs" />
<Compile Remove="net472Definitions.cs" />
<Compile Remove="VSHostObject.cs" />
</ItemGroup>
<ItemGroup>
<Compile Update="Resources\Strings.Designer.cs">
<DesignTime>True</DesignTime>
<AutoGen>True</AutoGen>
<DependentUpon>Strings.resx</DependentUpon>
</Compile>
</ItemGroup>
<ItemGroup>
<EmbeddedResource Update="Resources\Strings.resx">
<Generator>ResXFileCodeGenerator</Generator>
<LastGenOutput>Strings.Designer.cs</LastGenOutput>
</EmbeddedResource>
</ItemGroup>
<ItemGroup>
<AdditionalFiles Include="PublicAPI/$(TargetFramework)/PublicAPI.Shipped.txt" />
<AdditionalFiles Include="PublicAPI/$(TargetFramework)/PublicAPI.Unshipped.txt" />
</ItemGroup>
<!-- This target adds all of our PackageReference and ProjectReference's runtime assets to our package output. -->
<Target Name="CopyProjectReferencesToPackage" DependsOnTargets="ResolveReferences">
<ItemGroup>
<BuildOutputInPackage Include="@(ReferenceCopyLocalPaths)" TargetPath="%(ReferenceCopyLocalPaths.DestinationSubPath)" />
</ItemGroup>
</Target>
<!-- This target adds the generated deps.json file to our package output -->
<Target Name="AddBuildDependencyFileToBuiltProjectOutputGroupOutput" BeforeTargets="BuiltProjectOutputGroup" Condition=" '$(GenerateDependencyFile)' == 'true'">
<ItemGroup>
<BuiltProjectOutputGroupOutput Include="$(ProjectDepsFilePath)" TargetPath="$(ProjectDepsFileName)" FinalOutputPath="$(ProjectDepsFilePath)" />
</ItemGroup>
</Target>
<!-- Copy to *.csproj for using in sanity checks integration tests. -->
<Target Name="CopyCsprojToTestExecutionDirectory" AfterTargets="Build">
<Copy SourceFiles="$(MSBuildThisFileFullPath)" DestinationFiles="$(ArtifactsTmpDir)Container\ProjectFiles\$(MSBuildThisFileName).csproj" />
</Target>
</Project>