Skip to content

Commit

Permalink
Fix missing mono jit nupkg runtime library (#47193)
Browse files Browse the repository at this point in the history
Resolve race condition w/ empty Microsoft.NETCore.App.Runtime.Mono.linux-x64

With the original Subsets.props, some packaging targets are called in an AOT-only environment, and are simply missing some files (because in AOT-only, the JIT was not built). These half-empty nupkgs are uploaded during AzDO builds, after the "correct" JIT builds, and overwriting them. Make changes here to avoid replacing good packages with bad - simply do not call those targets in this situation.
  • Loading branch information
directhex authored Jan 20, 2021
1 parent 0f86c45 commit 1390941
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
7 changes: 4 additions & 3 deletions eng/Subsets.props
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,8 @@
<DefaultHostSubsets Condition="'$(RuntimeFlavor)' == 'Mono'"></DefaultHostSubsets>
<DefaultHostSubsets Condition="'$(RuntimeFlavor)' == 'Mono' and '$(TargetsMobile)' != 'true'">host.native</DefaultHostSubsets>

<DefaultPacksSubsets>packs.product+packs.tests</DefaultPacksSubsets>
<DefaultPacksSubsets>packs.product</DefaultPacksSubsets>
<DefaultPacksSubsets Condition="'$(BuildMonoAOTCrossCompilerOnly)' != 'true'">$(DefaultPacksSubsets)+packs.tests</DefaultPacksSubsets>
</PropertyGroup>

<PropertyGroup>
Expand Down Expand Up @@ -280,8 +281,8 @@
<!-- Packs sets -->

<ItemGroup Condition="$(_subset.Contains('+packs.product+'))">
<SharedFrameworkProjectToBuild Include="$(InstallerProjectRoot)pkg\sfx\Microsoft.NETCore.App\Microsoft.NETCore.App.Ref.sfxproj" />
<SharedFrameworkProjectToBuild Include="$(InstallerProjectRoot)pkg\sfx\Microsoft.NETCore.App\Microsoft.NETCore.App.Runtime.sfxproj" />
<SharedFrameworkProjectToBuild Condition="'$(BuildMonoAOTCrossCompilerOnly)' != 'true'" Include="$(InstallerProjectRoot)pkg\sfx\Microsoft.NETCore.App\Microsoft.NETCore.App.Ref.sfxproj" />
<SharedFrameworkProjectToBuild Condition="'$(BuildMonoAOTCrossCompilerOnly)' != 'true'" Include="$(InstallerProjectRoot)pkg\sfx\Microsoft.NETCore.App\Microsoft.NETCore.App.Runtime.sfxproj" />
<SharedFrameworkProjectToBuild Condition="'$(RuntimeFlavor)' != 'Mono'" Include="$(InstallerProjectRoot)pkg\sfx\Microsoft.NETCore.App\Microsoft.NETCore.App.Host.sfxproj" />
<SharedFrameworkProjectToBuild Condition="'$(RuntimeFlavor)' != 'Mono'" Include="$(InstallerProjectRoot)pkg\sfx\Microsoft.NETCore.App\Microsoft.NETCore.App.Crossgen2.sfxproj" />
<SharedFrameworkProjectToBuild Condition="'$(RuntimeFlavor)' != 'Mono'" Include="$(InstallerProjectRoot)pkg\sfx\installers\dotnet-host.proj" />
Expand Down
2 changes: 1 addition & 1 deletion eng/pipelines/runtime-official.yml
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ stages:
- OSX_x64
- Linux_x64
jobParameters:
buildArgs: -s mono+libs+host+packs -c $(_BuildConfig)
buildArgs: -s mono+packs -c $(_BuildConfig)
/p:MonoCrossAOTTargetOS=Android+Browser /p:SkipMonoCrossJitConfigure=true /p:BuildMonoAOTCrossCompilerOnly=true
nameSuffix: CrossAOT_Mono
runtimeVariant: crossaot
Expand Down

0 comments on commit 1390941

Please sign in to comment.