<Project>
  <PropertyGroup Condition="'$(TargetFramework)' != ''">
    <!-- UseMonoRuntime 仅在 Android 目标启用；当显式指定 Windows RID（win-*）时强制禁用，避免还原阶段解析 Mono.win-x64 runtime pack。 -->
    <UseMonoRuntime Condition="'$(RuntimeIdentifier)' != '' and $([System.String]::Copy($(RuntimeIdentifier)).StartsWith('win-'))">false</UseMonoRuntime>
    <UseMonoRuntime Condition="$([System.String]::Copy($(TargetFramework)).Contains('-android')) and ('$(RuntimeIdentifier)' == '' or $([System.String]::Copy($(RuntimeIdentifier)).StartsWith('win-')) != True)">true</UseMonoRuntime>
    <UseMonoRuntime Condition="$([System.String]::Copy($(TargetFramework)).Contains('-android')) != True">false</UseMonoRuntime>
  </PropertyGroup>
</Project>
