Condition="'$(_AppleSdkLoaded)' != 'true' And $([MSBuild]::VersionEquals($(TargetFrameworkVersion), '7.0')) And '$(TargetPlatformVersion)' != '' And $([MSBuild]::VersionEquals($(TargetPlatformVersion), '16.0'))" />
<ImportProject="Sdk.props"
Sdk="Microsoft.iOS.Sdk.net7.0_16.4"
Condition="'$(_AppleSdkLoaded)' != 'true' And $([MSBuild]::VersionEquals($(TargetFrameworkVersion), '7.0')) And '$(TargetPlatformVersion)' != '' And $([MSBuild]::VersionEquals($(TargetPlatformVersion), '16.4'))" />
<ImportProject="Sdk.props"
Sdk="Microsoft.iOS.Sdk.net8.0_17.0"
Condition="'$(_AppleSdkLoaded)' != 'true' And $([MSBuild]::VersionEquals($(TargetFrameworkVersion), '8.0')) And '$(TargetPlatformVersion)' != '' And $([MSBuild]::VersionEquals($(TargetPlatformVersion), '17.0'))" />
<ImportProject="Sdk.props"
Sdk="Microsoft.iOS.Sdk.net8.0_18.0"
Condition="'$(_AppleSdkLoaded)' != 'true' And $([MSBuild]::VersionEquals($(TargetFrameworkVersion), '8.0')) And '$(TargetPlatformVersion)' != '' And $([MSBuild]::VersionEquals($(TargetPlatformVersion), '18.0'))" />
<!-- Using the default target platform version -->
<ImportProject="Sdk.props"
Sdk="Microsoft.iOS.Sdk.net7.0_16.4"
Condition="'$(_AppleSdkLoaded)' != 'true' And $([MSBuild]::VersionEquals($(TargetFrameworkVersion), '7.0')) And '$(TargetPlatformVersion)' == ''" />
<ImportProject="Sdk.props"
Sdk="Microsoft.iOS.Sdk.net8.0_17.0"
Condition="'$(_AppleSdkLoaded)' != 'true' And $([MSBuild]::VersionEquals($(TargetFrameworkVersion), '8.0')) And '$(TargetPlatformVersion)' == ''" />
<!-- Using a .NET version we no longer support -->
<ImportProject="Sdk-eol.props"
Sdk="Microsoft.iOS.Sdk.net8.0_17.0"
Condition="'$(_AppleSdkLoaded)' != 'true' And $([MSBuild]::VersionLessThan($(TargetFrameworkVersion), '7.0'))" />
<!-- Using a specific, but unsupported, target platform version -->
<ImportProject="Sdk-error.props"
Sdk="Microsoft.iOS.Sdk.net8.0_17.0"
Condition="'$(_AppleSdkLoaded)' != 'true'" />
</ImportGroup>
```
Note 1: Every sdk we load sets the property `_AppleSdkLoaded=true`, this makes
it easy to avoid loading multiple sdks.
Note 2: One complication here is that TargetPlatformVersion might not be set
(if the TargetFramework doesn't contain the OS version), so there's one
condition that accepts an empty TargetPlatformVersion. This corresponds with
the default target platform version.
Note 3: we load the preview sdk (Microsoft.iOS.Sdk.net8.0_18.0) even if
`EnablePreviewFeatures!=true` - we show the error requesting
`EnablePreviewFeatures` to be set from the preview sdk instead (this is to get
an actionable error message). Without this, the user would get this rather
unhelpful error message: `error NETSDK1139: The target platform identifier ios
was not recognized.`
Note 4: we load a special error-handling version of the sdk if we don't
support a TargetPlatformVersion for given TargetFrameworkVersion, and show an
error about unsupported TargetPlatformVersion. Without this, the user would
get this rather unhelpful error message: `error NETSDK1139: The target