blob: 8046bee3d320ac4f49872b3b350865f09721abd6 (
plain)
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
|
<Project DefaultTargets="LinkNative" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), dir.props))\dir.props" />
<PropertyGroup>
<OutputType Condition="'$(OutputType)' == ''">Exe</OutputType>
<OutputPath>$(MSBuildProjectDirectory)\bin\$(Configuration)\$(Platform)\</OutputPath>
<IntermediateOutputPath>$(MSBuildProjectDirectory)\obj\$(Configuration)\$(Platform)\</IntermediateOutputPath>
<DebugType Condition="'$(DebugType)' == ''">portable</DebugType>
</PropertyGroup>
<PropertyGroup>
<CopyNuGetImplementations>false</CopyNuGetImplementations>
<GenerateAssemblyInfo>false</GenerateAssemblyInfo>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<TargetFrameworkIdentifier>.NETCoreApp</TargetFrameworkIdentifier>
<TargetFramework>netcoreapp2.0</TargetFramework>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.NETCore.App">
<Version>$(MicrosoftNETCoreAppPackageVersion)</Version>
</PackageReference>
</ItemGroup>
<!-- Reuse restored assets from the repro project -->
<PropertyGroup>
<RestoreOutputPath>$(IntermediateOutputRootPath)\repro</RestoreOutputPath>
</PropertyGroup>
<!--
When building a library as a reference, the returned build outputs include both the
IL assembly produced by CSC and the native obj produced by Ilc. Separate the native
object file here so it isn't passed to CSC, and instead redirect it to be picked up
by the LinkNative target.
-->
<Target Name="RemoveObjFiles" AfterTargets="ResolveProjectReferences" Condition="'$(IlcMultiModule)' == 'true'">
<ItemGroup>
<ObjFiles Include="@(_ResolvedProjectReferencePaths)" Condition="'%(Extension)' == '.obj' or '%(Extension)' == '.bc'" />
<LinkerArg Include="@(_ResolvedProjectReferencePaths)" Condition="'%(Extension)' == '.obj'" />
<IlcReference Include="@(_ResolvedProjectReferencePaths)" Condition="'%(Extension)' == '.dll'" />
<_ResolvedProjectReferencePaths Remove="@(ObjFiles)" />
</ItemGroup>
</Target>
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), dir.targets))\dir.targets" />
<Import Project="$(IlcPath)\build\Microsoft.NETCore.Native.targets" />
<ItemGroup>
<CustomLinkerArg Include="$(AdditionalLinkerFlags)" />
</ItemGroup>
<ItemGroup>
<IlcArg Include="--targetarch=$(Platform)" />
<!-- Broken on wasm: https://github.com/dotnet/corert/issues/5005 -->
<IlcArg Condition="$(NativeCodeGen) != 'wasm'" Include="--stacktracedata" />
</ItemGroup>
</Project>
|