@@ -139,22 +139,26 @@ if defined RunNativeAot (
139139 Outputs =" $(OutputPath)\nativebuild.proj"
140140 BeforeTargets =" Build" >
141141 <PropertyGroup >
142- <_RootEntryAssemblyLine Condition =" $(CLRTestFullTrimming) != 'true'" >< TrimmerDefaultAction> copyused < /TrimmerDefaultAction> </_RootEntryAssemblyLine >
142+ <_RootEntryAssemblyLine Condition =" $(CLRTestFullTrimming) == 'true'" >< TrimmerDefaultAction> link < /TrimmerDefaultAction> </_RootEntryAssemblyLine >
143143
144144 <_NativeAotBuildProjectFile >
145145 <![CDATA[
146- <Project DefaultTargets="LinkNative" xmlns="http://schemas.microsoft.com/developer/msbuild/2003 ">
146+ <Project Sdk="Microsoft.NET.Sdk" DefaultTargets="LinkNative ">
147147
148148 <PropertyGroup>
149149 <TargetName>$(MSBuildProjectName)</TargetName>
150- <TargetExt>.dll</TargetExt >
150+ <TargetFramework>$(TargetFramework)</TargetFramework >
151151 <OutputType>Exe</OutputType>
152152 <OutputPath>%24(MSBuildProjectDirectory)\</OutputPath>
153153 <IntermediateOutputPath>%24(MSBuildProjectDirectory)\</IntermediateOutputPath>
154154 <TargetArchitecture>$(TargetArchitecture)</TargetArchitecture>
155155 <Optimize>$(Optimize)</Optimize>
156- <DebugSymbols>true</DebugSymbols>
157- <NETCoreSdkVersion>$(NETCoreSdkVersion)</NETCoreSdkVersion>
156+ <SkipResolvePackageAssets>true</SkipResolvePackageAssets>
157+ <SelfContained>true</SelfContained>
158+ <AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
159+ <AppendRuntimeIdentifierToOutputPath>false</AppendRuntimeIdentifierToOutputPath>
160+ <ProduceReferenceAssembly>false</ProduceReferenceAssembly>
161+ <RuntimeIdentifier>$(OutputRid)</RuntimeIdentifier>
158162 $(_RootEntryAssemblyLine)
159163 </PropertyGroup>
160164
@@ -169,9 +173,7 @@ if defined RunNativeAot (
169173 </ItemGroup>
170174
171175 <!-- We don't do anything in the Compile step since the test is already compiled to IL - the AOT compiler hooks up after this -->
172- <Target Name="Compile" />
173-
174- <Target Name="PrepareForILLink" />
176+ <Target Name="CoreCompile" />
175177
176178 <Import Project="%24(IlcPath)\build\Microsoft.NETCore.Native.targets" />
177179
0 commit comments