-
Notifications
You must be signed in to change notification settings - Fork 4.7k
/
Microsoft.NETCore.App.Runtime.sfxproj
145 lines (131 loc) · 8.6 KB
/
Microsoft.NETCore.App.Runtime.sfxproj
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
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
<Project>
<Import Project="Sdk.props" Sdk="Microsoft.NET.Sdk" />
<Import Project="Sdk.props" Sdk="Microsoft.DotNet.SharedFramework.Sdk" />
<PropertyGroup>
<PlatformPackageType>RuntimePack</PlatformPackageType>
<ArchiveName>dotnet-runtime-internal</ArchiveName>
<InstallerName Condition="'$(TargetOS)' != 'OSX'">dotnet-runtime</InstallerName>
<InstallerName Condition="'$(TargetOS)' == 'OSX'">dotnet-runtime-internal</InstallerName>
<GenerateSymbolsArchive>true</GenerateSymbolsArchive>
<SymbolsArchiveName>dotnet-runtime-symbols</SymbolsArchiveName>
<VSInsertionShortComponentName>NetCore.SharedFramework</VSInsertionShortComponentName>
<UseTemplatedPlatformManifest>true</UseTemplatedPlatformManifest>
<IncludeFallbacksInDepsFile>true</IncludeFallbacksInDepsFile>
<GetSharedFrameworkFilesForReadyToRunDependsOn>
AddRuntimeFilesToPackage;
AddFrameworkFilesToPackage
</GetSharedFrameworkFilesForReadyToRunDependsOn>
<PublishReadyToRun Condition="'$(RuntimeFlavor)' != 'Mono'">true</PublishReadyToRun>
<PublishReadyToRun Condition="'$(RuntimeFlavor)' == 'Mono'">false</PublishReadyToRun>
<!-- Disable crossgen on FreeBSD, NetBSD, illumos and Solaris for now. This can be revisited when we have full support. -->
<PublishReadyToRun Condition="'$(TargetOS)'=='FreeBSD' Or '$(TargetOS)'=='NetBSD' Or '$(TargetOS)'=='illumos' Or '$(TargetOS)'=='Solaris'">false</PublishReadyToRun>
<!-- These components are installed by the root shared framework, but not others. -->
<IncludeWerRelatedKeys>true</IncludeWerRelatedKeys>
<IncludeBreadcrumbStoreFolder>true</IncludeBreadcrumbStoreFolder>
<MacOSPackageDescription>The .NET Shared Framework</MacOSPackageDescription>
</PropertyGroup>
<PropertyGroup Condition="'$(RuntimeFlavor)' == 'Mono' and '$(TargetsMobile)' != 'true'">
<RuntimeSpecificFrameworkSuffix>Mono</RuntimeSpecificFrameworkSuffix>
</PropertyGroup>
<PropertyGroup Condition="'$(MonoEnableLLVM)' == 'true' and '$(RuntimeFlavor)' == 'Mono' and '$(TargetsMobile)' != 'true' and '$(TargetsBrowser)' != 'true'">
<RuntimeSpecificFrameworkSuffix>Mono.LLVM</RuntimeSpecificFrameworkSuffix>
</PropertyGroup>
<PropertyGroup Condition="'$(MonoBundleLLVMOptimizer)' == 'true' and '$(RuntimeFlavor)' == 'Mono' and '$(TargetsMobile)' != 'true' and '$(TargetsBrowser)' != 'true'">
<RuntimeSpecificFrameworkSuffix>Mono.LLVM.AOT</RuntimeSpecificFrameworkSuffix>
</PropertyGroup>
<PropertyGroup Condition="'$(RuntimeSpecificFrameworkSuffix)' != ''">
<OverridePackageId>$(SharedFrameworkName).Runtime.$(RuntimeSpecificFrameworkSuffix).$(RuntimeIdentifier)</OverridePackageId>
</PropertyGroup>
<!--
hostpolicy and hostfxr aren't in the platform manifest in the ref pack and cannot be without breaking things upstack.
We add the entries here to ensure that we don't fail the validation that every file included in the runtime pack is in the platform manifest
without adding the entries to the manifest in the ref pack.
-->
<ItemGroup>
<PlatformManifestFileEntry Include="hostpolicy.dll" IsNative="true" />
<PlatformManifestFileEntry Include="libhostpolicy.so" IsNative="true" />
<PlatformManifestFileEntry Include="libhostpolicy.dylib" IsNative="true" />
<PlatformManifestFileEntry Include="hostfxr.dll" IsNative="true" />
<PlatformManifestFileEntry Include="libhostfxr.so" IsNative="true" />
<PlatformManifestFileEntry Include="libhostfxr.dylib" IsNative="true" />
</ItemGroup>
<Target Name="AddLinuxPackageInformation" BeforeTargets="GetDebInstallerJsonProperties;GetRpmInstallerJsonProperties">
<ItemGroup>
<LinuxPackageDependency Include="dotnet-hostfxr-$(MajorVersion).$(MinorVersion);dotnet-runtime-deps-$(MajorVersion).$(MinorVersion)" Version="$(InstallerPackageVersion)" />
</ItemGroup>
</Target>
<!-- Mobile uses a different hosting model, so we don't include the .NET host components. -->
<ItemGroup Condition="'$(TargetsMobile)' != 'true'">
<NativeRuntimeAsset Include="$(DotNetHostBinDir)/$(LibPrefix)hostpolicy$(LibSuffix)" />
<NativeRuntimeAsset Include="$(DotNetHostBinDir)/$(LibPrefix)hostfxr$(LibSuffix)" PackOnly="true" />
</ItemGroup>
<Target Name="AddRuntimeFilesToPackage" DependsOnTargets="ResolveRuntimeFilesFromLocalBuild">
<ItemGroup>
<RuntimeFiles Condition="'%(RuntimeFiles.IsNative)' == 'true'">
<TargetPath>runtimes/$(RuntimeIdentifier)/native</TargetPath>
</RuntimeFiles>
<RuntimeFiles Condition="'%(FileName)' == 'crossgen'">
<TargetPath>tools</TargetPath>
</RuntimeFiles>
<RuntimeFiles Condition="'$(TargetsMobile)' == 'true'"
Include="@(MonoCrossFiles)">
<TargetPath>runtimes/$(RuntimeIdentifier)/native/cross</TargetPath>
</RuntimeFiles>
<RuntimeFiles Condition="'$(TargetsMobile)' == 'true'"
Include="@(MonoIncludeFiles)"
ExcludeFromDataFiles="true">
<TargetPath>runtimes/$(RuntimeIdentifier)/native/include/%(RecursiveDir)</TargetPath>
</RuntimeFiles>
<CoreCLRCrossTargetFiles PackOnly="true" />
<CoreCLRCrossTargetFiles Condition="'%(FileName)' == 'clrjit' or '%(FileName)' == 'libclrjit'">
<TargetPath>runtimes/$(CoreCLRCrossTargetComponentDirName)_$(TargetArchitecture)/native</TargetPath>
</CoreCLRCrossTargetFiles>
<CoreCLRCrossTargetFiles Condition="'%(FileName)' == 'crossgen'">
<TargetPath>tools/$(CoreCLRCrossTargetComponentDirName)_$(TargetArchitecture)</TargetPath>
</CoreCLRCrossTargetFiles>
<CoreCLRCrossTargetFiles Condition="$([System.String]::new('%(FileName)').StartsWith('mscordaccore')) and '$(TargetsWindows)' == 'true'">
<TargetPath>tools/$(CoreCLRCrossTargetComponentDirName)_$(TargetArchitecture)</TargetPath>
</CoreCLRCrossTargetFiles>
<CoreCLRCrossTargetFiles Condition="'%(FileName)%(Extension)' == 'mscordbi.dll' and '$(TargetsWindows)' == 'true'">
<TargetPath>tools/$(CoreCLRCrossTargetComponentDirName)_$(TargetArchitecture)</TargetPath>
</CoreCLRCrossTargetFiles>
<ReferenceCopyLocalPaths Include="@(RuntimeFiles);@(CoreCLRCrossTargetFiles);" />
</ItemGroup>
</Target>
<Target Name="AddFrameworkFilesToPackage" DependsOnTargets="ResolveLibrariesFromLocalBuild">
<ItemGroup>
<ReferenceCopyLocalPaths Include="@(LibrariesRuntimeFiles)"
Condition="'%(LibrariesRuntimeFiles.Extension)' != '.a' or '$(TargetsMobile)' == 'true'">
<TargetPath Condition="'%(LibrariesRuntimeFiles.NativeSubDirectory)' != ''">runtimes/$(RuntimeIdentifier)/native/%(LibrariesRuntimeFiles.NativeSubDirectory)%(RecursiveDir)</TargetPath>
</ReferenceCopyLocalPaths>
</ItemGroup>
</Target>
<PropertyGroup Condition="'$(TargetOS)' == 'windows'">
<_diaSymArch Condition="'$(_hostArch)' != ''">$(_hostArch)</_diaSymArch>
<_diaSymReaderPath>$(PkgMicrosoft_DiaSymReader_Native)/runtimes/win/native/Microsoft.DiaSymReader.Native.$(_diaSymArch).dll</_diaSymReaderPath>
<_diaSymReaderPathIfExists Condition="Exists('$(_diaSymReaderPath)')">$(_diaSymReaderPath)</_diaSymReaderPathIfExists>
</PropertyGroup>
<ItemGroup Condition="'$(_diaSymReaderPathIfExists)' != ''">
<NativeRuntimeAsset Include="$(_diaSymReaderPathIfExists)" />
</ItemGroup>
<Import Project="Sdk.targets" Sdk="Microsoft.NET.Sdk" />
<Import Project="Sdk.targets" Sdk="Microsoft.DotNet.SharedFramework.Sdk" />
<Target Name="ResolveReadyToRunCompilers" DependsOnTargets="ResolveRuntimeFilesFromLocalBuild">
<ItemGroup Condition="'$(RuntimeFlavor)' != 'Mono'">
<_crossTargetJit Include="@(CoreCLRCrossTargetFiles)" Condition="'%(FileName)' == '$(LibPrefix)clrjit' and '%(Extension)' == '$(LibSuffix)'" />
<_clrjit Include="@(RuntimeFiles)" Condition="'%(FileName)' == '$(LibPrefix)clrjit' and '%(Extension)' == '$(LibSuffix)'" />
<_crossTargetCrossgen Include="@(CoreCLRCrossTargetFiles)" Condition="'%(FileName)' == 'crossgen' and '%(Extension)' == '$(ExeSuffix)'" />
<_crossgen Include="@(RuntimeFiles)" Condition="'%(FileName)' == 'crossgen' and '%(Extension)' == '$(ExeSuffix)'" />
</ItemGroup>
<ItemGroup Condition="'@(_crossTargetJit)' != '' and '@(_crossTargetCrossgen)' != ''">
<CrossgenTool Include="@(_crossTargetCrossgen->ClearMetadata())"
JitPath="@(_crossTargetJit)"
DiaSymReader="$(_diaSymReaderPathIfExists)" />
</ItemGroup>
<ItemGroup Condition="'@(_crossTargetJit)' == '' and '@(_crossTargetCrossgen)' == ''">
<CrossgenTool Include="@(_crossgen->ClearMetadata())"
JitPath="@(_clrjit)"
DiaSymReader="$(_diaSymReaderPathIfExists)" />
</ItemGroup>
</Target>
</Project>