forked from MonoMod/MonoMod.Backports
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCommon.targets
More file actions
48 lines (39 loc) · 1.75 KB
/
Common.targets
File metadata and controls
48 lines (39 loc) · 1.75 KB
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
<?xml version="1.0" encoding="utf-8"?>
<Project>
<!-- NuGet Information -->
<Import Project="$(MMToolsPath)NuGet.targets" />
<!-- This contains common stuff that specific packages may wish to disable. -->
<!-- Include the language-specific targets file, if it exists -->
<Import Project="$(MMLanguageTargets)" Condition="Exists('$(MMLanguageTargets)')" />
<ItemGroup Condition="'$([MSBuild]::GetTargetFrameworkIdentifier($(TargetFramework)))' == '.NETFramework'">
<PackageReference Include="Microsoft.NETFramework.ReferenceAssemblies" Version="1.0.3">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>
<Target Name="GetProperties" Outputs="@(Properties)">
<ItemGroup>
<_PropertiesToGet Remove="@(_PropertiesToGet)" />
<Properties Remove="@(Properties)" />
</ItemGroup>
<ItemGroup>
<_PropertiesToGet Include="$([System.String]::Copy($(PropertyNames)).Split(','))" />
</ItemGroup>
<ItemGroup>
<Properties Include="%(_PropertiesToGet.Identity)" Value="$(%(_PropertiesToGet.Identity))" />
</ItemGroup>
</Target>
<!-- Fix NetCoreApp packageref -->
<ItemGroup>
<PackageReference Update="Microsoft.NETCore.App" FrameworkFile="true" />
</ItemGroup>
<Target Name="_FixNetCoreAppReferences"
BeforeTargets="_CollectPrimaryOutputDependencies"
AfterTargets="ReferenceCopyLocalPathsOutputGroup;RunResolvePackageDependencies">
<ItemGroup>
<ReferencePath Update="@(ReferencePath)" Condition="'%(NuGetPackageId)' == 'Microsoft.NETCore.App'">
<FrameworkFile>true</FrameworkFile>
</ReferencePath>
</ItemGroup>
</Target>
</Project>