-
Notifications
You must be signed in to change notification settings - Fork 5.3k
Clean up Crossgen2 executions in installer after SDK P2 ingestion #49004
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Do we need to wait until the minimum required version of the SDK is P2? When using P1 (which is the current min version), would the sfxproj then fail to build? |
|
@ViktorHofer - yes, the sfxproj would fail to build now as P1 SDK doesn't support |
The March infra rollout bumped the minimum required version of the SDK to 6.0 Preview 1: 3e31241. The target version is currently a nightly preview 2 build, because we needed a newer SDK change in CI (for linker tests). MSBuild respects and checks the minimum required SDK version but doesn't know anything about the target version in global.json as that's something Arcade custom. If you merge this change, a |
|
I recommend to hold this PR off until 4/5 (first Monday of April) when we will update to the next publicly available SDK which I believe will be Preview 2. |
|
OK, I have marked it with the no-merge label; for now I assume this is going to be merged in as part of or after the April infra rollout per your suggestion. |
|
Thanks for your understanding 👍 |
|
Is the preview2 sdk integrated into runtime now, or will that happen with the April rollout. |
|
As @ViktorHofer explained to me, in practice we're already consuming SDK Preview2 in the runtime repo but technically the runtime repo still supports SDK Preview1. For this reason I plan to rebase and merge this in after Viktor completes the April rollout next Monday (or maybe Tuesday considering next Monday is most likely national holiday in Austria just like in Czechia). |
|
The PR is now unblocked as we just updated the SDK to 6.0 Preview 2: #50084. |
90644b5 to
58545ea
Compare
|
I have rebased the change and I plan to merge it in once testing successfully completes as the change has already been reviewed unless anyone objects. |
|
I have rebased the change but now it's hitting a new error I didn't see previously; @jkoritzinsky, could you please take a quick look at the error message and advise me what else needs changing or what most likely broke it as I guess you'll see that off the top of your head? I believe the framework gets compiled successfully, this error happens when we compile the framework for the second time as part of CG2 publishing. Thank you in advance! D:\git\runtime5\.dotnet\sdk\6.0.100-preview.2.21155.3\Sdks\Microsoft.NET.Sdk\targets\Microsoft.NET.Publish.targets(404,5): error : Error: [D:\git\runtime5\src\installer\pkg\sfx\Microsoft.NETCore.App\Microsoft.NETCore.App.Crossgen2.sfxproj] D:\git\runtime5\.dotnet\sdk\6.0.100-preview.2.21155.3\Sdks\Microsoft.NET.Sdk\targets\Microsoft.NET.Publish.targets(404,5): error : An assembly specified in the application dependencies manifest (crossgen2.deps.json) has already been found but with a different file extension: [D:\git\runtime5\src\installer\pkg\sfx\Microsoft.NETCore.App\Microsoft.NETCore.App.Crossgen2.sfxproj] D:\git\runtime5\.dotnet\sdk\6.0.100-preview.2.21155.3\Sdks\Microsoft.NET.Sdk\targets\Microsoft.NET.Publish.targets(404,5): error : package: 'crossgen2', version: '6.0.0-dev' [D:\git\runtime5\src\installer\pkg\sfx\Microsoft.NETCore.App\Microsoft.NETCore.App.Crossgen2.sfxproj] D:\git\runtime5\.dotnet\sdk\6.0.100-preview.2.21155.3\Sdks\Microsoft.NET.Sdk\targets\Microsoft.NET.Publish.targets(404,5): error : path: 'crossgen2.dll' [D:\git\runtime5\src\installer\pkg\sfx\Microsoft.NETCore.App\Microsoft.NETCore.App.Crossgen2.sfxproj] D:\git\runtime5\.dotnet\sdk\6.0.100-preview.2.21155.3\Sdks\Microsoft.NET.Sdk\targets\Microsoft.NET.Publish.targets(404,5): error : previously found assembly: 'D:\git\runtime5\artifacts\bin\coreclr\windows.x64.Release\crossgen2\crossgen2.exe' [D:\git\runtime5\src\installer\pkg\sfx\Microsoft.NETCore.App\Microsoft.NETCore.App.Crossgen2.sfxproj] D:\git\runtime5\.dotnet\sdk\6.0.100-preview.2.21155.3\Sdks\Microsoft.NET.Sdk\targets\Microsoft.NET.Publish.targets(404,5): error : Error: [D:\git\runtime5\src\installer\pkg\sfx\Microsoft.NETCore.App\Microsoft.NETCore.App.Crossgen2.sfxproj] |
In my previous change I missed the fact that, once we run Crossgen2 through "dotnet", we need to pass in the dll, not the exe. That allowed for an additional bit of cleanup in the script. Thanks Tomas
1f9215c to
6d4096e
Compare
Fixes: #48252
/cc @dotnet/crossgen-contrib