You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
222 lines
13 KiB
222 lines
13 KiB
<Project>
|
|
|
|
<Import Project="Sdk.targets" Sdk="Microsoft.DotNet.Arcade.Sdk" />
|
|
|
|
<!--
|
|
Note: Arcade automatically replaces copyrights defined in .props or .csproj files
|
|
by the default Microsoft copyright. To ensure this doesn't happen, the replaced
|
|
copyright is restored in this .targets file using the private variable set in .props.
|
|
Similarly, both delayed and public signing are disabled to override Arcade's defaults.
|
|
-->
|
|
|
|
<PropertyGroup>
|
|
<Copyright>$(_ProjectCopyright)</Copyright>
|
|
<DelaySign>false</DelaySign>
|
|
<PublicSign>false</PublicSign>
|
|
</PropertyGroup>
|
|
|
|
<!--
|
|
Note: the trimming and Native AOT analyzers are only supported on .NET. Since the OpenIddict
|
|
Entity Framework 6.x and Entity Framework Core stores internally use new trimming/AOT-friendly
|
|
TypeDescriptor APIs introduced in .NET 9.0, only the .NET 9.0+ TFMs are marked as AOT-compatible.
|
|
-->
|
|
|
|
<PropertyGroup
|
|
Condition=" $(RepoRelativeProjectDir.Contains('src')) And
|
|
'$(TargetFrameworkIdentifier)' == '.NETCoreApp' And
|
|
$([MSBuild]::VersionGreaterThanOrEquals($(TargetFrameworkVersion), '9.0')) ">
|
|
<IsAotCompatible>true</IsAotCompatible>
|
|
</PropertyGroup>
|
|
|
|
<!--
|
|
Note: .NET Native, .NET Framework and .NET Standard assemblies are not annotated with
|
|
nullable references annotations. To avoid errors on these target frameworks, related
|
|
warnings are disabled by setting <Nullable> to "annotations" instead of "enable".
|
|
-->
|
|
|
|
<PropertyGroup Condition=" '$(TargetFrameworkIdentifier)' == '.NETCore' Or
|
|
'$(TargetFrameworkIdentifier)' == '.NETFramework' Or
|
|
'$(TargetFrameworkIdentifier)' == '.NETStandard' ">
|
|
<Nullable>annotations</Nullable>
|
|
</PropertyGroup>
|
|
|
|
<PropertyGroup Condition=" '$(TargetFrameworkIdentifier)' == '.NETCoreApp' ">
|
|
<SupportedOSPlatformVersion Condition=" '$(TargetPlatformIdentifier)' == 'Android' ">21.0</SupportedOSPlatformVersion>
|
|
<SupportedOSPlatformVersion Condition=" '$(TargetPlatformIdentifier)' == 'iOS' ">12.2</SupportedOSPlatformVersion>
|
|
<SupportedOSPlatformVersion Condition=" '$(TargetPlatformIdentifier)' == 'MacCatalyst' ">15.0</SupportedOSPlatformVersion>
|
|
<SupportedOSPlatformVersion Condition=" '$(TargetPlatformIdentifier)' == 'macOS' ">12.0</SupportedOSPlatformVersion>
|
|
<SupportedOSPlatformVersion Condition=" '$(TargetPlatformIdentifier)' == 'Windows' ">7.0</SupportedOSPlatformVersion>
|
|
</PropertyGroup>
|
|
|
|
<PropertyGroup Condition=" '$(TargetFrameworkIdentifier)' == '.NETFramework' ">
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_NAMED_PIPE_CONSTRUCTOR_WITH_ACL</DefineConstants>
|
|
</PropertyGroup>
|
|
|
|
<PropertyGroup Condition=" '$(TargetFrameworkIdentifier)' == '.NETCoreApp' ">
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_APPLICATION_CONFIGURATION_INITIALIZATION</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_AUTHENTICATION_HANDLER_SELECTION_FALLBACK</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_AUTHORIZATION_MIDDLEWARE</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_BCL_ASYNC_ENUMERABLE</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_BULK_DBSET_OPERATIONS</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_CHUNK_LINQ_EXTENSION</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_DBSET_VALUETASK_FINDASYNC</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_ENDPOINT_ROUTING</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_ENVIRONMENT_PROCESS_PATH</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_HEXADECIMAL_STRING_CONVERSION</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_HTTP_CLIENT_DEFAULT_REQUEST_VERSION</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_HTTP_CLIENT_DEFAULT_REQUEST_VERSION_POLICY</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_HTTP_CLIENT_RESILIENCE</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_INT32_RANDOM_NUMBER_GENERATOR_METHODS</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_MULTIPLE_VALUES_IN_QUERYHELPERS</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_NAMED_PIPE_STATIC_FACTORY_WITH_ACL</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_ONE_SHOT_HASHING_METHODS</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_ONE_SHOT_KEY_DERIVATION_METHODS</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_ONE_SHOT_RANDOM_NUMBER_GENERATOR_METHODS</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_OPERATING_SYSTEM_VERSIONS_COMPARISON</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_PEM_ENCODED_KEY_IMPORT</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_REDIRECTION_ON_SIGN_IN</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_TASK_WAIT_ASYNC</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_TEXT_ELEMENT_ENUMERATOR</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_TIME_PROVIDER</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_VALUETASK_COMPLETED_TASK</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_WINFORMS_TASK_DIALOG</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_ZLIB_COMPRESSION</DefineConstants>
|
|
</PropertyGroup>
|
|
|
|
<PropertyGroup
|
|
Condition=" ('$(TargetFrameworkIdentifier)' == '.NETCoreApp') Or
|
|
('$(TargetFrameworkIdentifier)' == '.NETFramework' And $([MSBuild]::VersionGreaterThanOrEquals($(TargetFrameworkVersion), '4.7.2'))) Or
|
|
('$(TargetFrameworkIdentifier)' == '.NETStandard') ">
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_ECDSA</DefineConstants>
|
|
</PropertyGroup>
|
|
|
|
<PropertyGroup
|
|
Condition=" ('$(TargetFrameworkIdentifier)' == '.NETCoreApp') Or
|
|
('$(TargetFrameworkIdentifier)' == '.NETFramework' And $([MSBuild]::VersionGreaterThanOrEquals($(TargetFrameworkVersion), '4.7.2'))) Or
|
|
('$(TargetFrameworkIdentifier)' == '.NETStandard' And $([MSBuild]::VersionGreaterThanOrEquals($(TargetFrameworkVersion), '2.1'))) ">
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_CERTIFICATE_GENERATION</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_EPHEMERAL_KEY_SETS</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_KEY_DERIVATION_WITH_SPECIFIED_HASH_ALGORITHM</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_RSA_KEY_CREATION_WITH_SPECIFIED_SIZE</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_TOHASHSET_LINQ_EXTENSION</DefineConstants>
|
|
</PropertyGroup>
|
|
|
|
<PropertyGroup
|
|
Condition=" ('$(TargetFrameworkIdentifier)' == '.NETCoreApp') Or
|
|
('$(TargetFrameworkIdentifier)' == '.NETStandard' And $([MSBuild]::VersionGreaterThanOrEquals($(TargetFrameworkVersion), '2.1'))) ">
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_BROTLI_COMPRESSION</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_CURRENT_USER_ONLY_PIPE_OPTION</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_SERVICE_PROVIDER_IN_HTTP_MESSAGE_HANDLER_BUILDER</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_STATIC_RANDOM_NUMBER_GENERATOR_METHODS</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_STREAM_MEMORY_METHODS</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_TIME_CONSTANT_COMPARISONS</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_WEB_INTEGRATION_IN_GENERIC_HOST</DefineConstants>
|
|
</PropertyGroup>
|
|
|
|
<PropertyGroup
|
|
Condition=" '$(TargetFrameworkIdentifier)' == '.NETCoreApp' And $([MSBuild]::VersionGreaterThanOrEquals($(TargetFrameworkVersion), '9.0')) ">
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_CERTIFICATE_LOADER</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_JSON_ELEMENT_DEEP_EQUALS</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_JSON_ELEMENT_PROPERTY_COUNT</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_TYPE_DESCRIPTOR_TYPE_REGISTRATION</DefineConstants>
|
|
</PropertyGroup>
|
|
|
|
<PropertyGroup
|
|
Condition=" '$(TargetFrameworkIdentifier)' == '.NETCoreApp' And $([MSBuild]::VersionGreaterThanOrEquals($(TargetFrameworkVersion), '10.0')) ">
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_ASYNC_LINQ</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_RELAXED_URI_LIMITS</DefineConstants>
|
|
</PropertyGroup>
|
|
|
|
<PropertyGroup
|
|
Condition=" '$(TargetFrameworkIdentifier)' == '.NETCoreApp' And '$(TargetPlatformIdentifier)' == 'Android' ">
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_ANDROID</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_ANDROIDX_BROWSER</DefineConstants>
|
|
</PropertyGroup>
|
|
|
|
<PropertyGroup
|
|
Condition=" '$(TargetFrameworkIdentifier)' == '.NETCoreApp' And ('$(TargetPlatformIdentifier)' == 'iOS' Or
|
|
'$(TargetPlatformIdentifier)' == 'MacCatalyst') ">
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_UIKIT</DefineConstants>
|
|
</PropertyGroup>
|
|
|
|
<PropertyGroup
|
|
Condition=" '$(TargetFrameworkIdentifier)' == '.NETCoreApp' And '$(TargetPlatformIdentifier)' == 'macOS' ">
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_APPKIT</DefineConstants>
|
|
</PropertyGroup>
|
|
|
|
<PropertyGroup
|
|
Condition=" '$(TargetFrameworkIdentifier)' == '.NETCoreApp' And ('$(TargetPlatformIdentifier)' == 'iOS' Or
|
|
'$(TargetPlatformIdentifier)' == 'MacCatalyst' Or
|
|
'$(TargetPlatformIdentifier)' == 'macOS') ">
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_AUTHENTICATION_SERVICES</DefineConstants>
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_FOUNDATION</DefineConstants>
|
|
</PropertyGroup>
|
|
|
|
<PropertyGroup
|
|
Condition=" ('$(TargetFrameworkIdentifier)' == '.NETCore' And '$(TargetPlatformIdentifier)' == 'UAP') Or
|
|
|
|
('$(TargetFrameworkIdentifier)' == '.NETCoreApp' And
|
|
'$(TargetPlatformIdentifier)' == 'Windows' And
|
|
'$(TargetPlatformVersion)' != '' And
|
|
$([MSBuild]::VersionGreaterThanOrEquals($(TargetPlatformVersion), '8.0'))) Or
|
|
|
|
('$(TargetFrameworkIdentifier)' == '.NETFramework') ">
|
|
<DefineConstants>$(DefineConstants);SUPPORTS_WINDOWS_RUNTIME</DefineConstants>
|
|
</PropertyGroup>
|
|
|
|
<!--
|
|
Note: Entity Framework Core 2.x references System.Interactive.Async 3.x, that includes
|
|
its own IAsyncEnumerable. To work around collisions between this type and the new type
|
|
now included in the BCL (System.Runtime), an alias is added to System.Interactive.Async.
|
|
-->
|
|
|
|
<Target Name="AddAssemblyAliasToReactiveAsync" AfterTargets="ResolveAssemblyReferences">
|
|
<ItemGroup>
|
|
<ReferencePath Condition=" '%(FileName)' == 'System.Interactive.Async' ">
|
|
<Aliases>reactive</Aliases>
|
|
</ReferencePath>
|
|
</ItemGroup>
|
|
</Target>
|
|
|
|
<!--
|
|
Note: metapackages don't include any build output. To ensure the TFM-specific folders under
|
|
/lib are preserved, a placeholder file is added for each supported target framework moniker.
|
|
-->
|
|
|
|
<Target Name="AddTfmSpecificPlaceholders" Condition=" '$(IncludeBuildOutput)' != 'true' ">
|
|
<GetNuGetShortFolderName TargetFrameworkMoniker="$(TargetFrameworkMoniker)"
|
|
TargetPlatformMoniker="$(TargetPlatformMoniker)">
|
|
<Output TaskParameter="NuGetShortFolderName" PropertyName="_NuGetShortFolderName" />
|
|
</GetNuGetShortFolderName>
|
|
|
|
<ItemGroup>
|
|
<TfmSpecificPackageFile Include="$(MSBuildThisFileDirectory)eng\_._"
|
|
PackagePath="lib\$(_NuGetShortFolderName)\_._" />
|
|
</ItemGroup>
|
|
</Target>
|
|
|
|
<!--
|
|
Note: Arcade always generates .resx backing files with internal static methods/constants.
|
|
To ensure the OpenIddict resources are public, the default visibility is manually overridden.
|
|
-->
|
|
|
|
<Target Name="OverrideResourcesVisibility" Condition=" @(EmbeddedResourceSGResx) != '' " AfterTargets="_GenerateResxSource">
|
|
<WriteLinesToFile
|
|
File=" %(EmbeddedResourceSGResx.SourceOutputPath) "
|
|
Lines=" $([System.IO.File]::ReadAllText(%(EmbeddedResourceSGResx.SourceOutputPath))
|
|
.Replace('internal const', 'public const')
|
|
.Replace('internal static', 'public static')
|
|
.Replace('static partial class', 'partial class')) "
|
|
Overwrite="true"
|
|
Encoding="Unicode" />
|
|
</Target>
|
|
|
|
<!--
|
|
Note: the built-in _CalculateXbfSupport target cannot be used when building a UWP project using
|
|
the .NET version of MSBuild. To work around this limitation, a fake target is defined here.
|
|
-->
|
|
|
|
<Target Name="_CalculateXbfSupport"
|
|
Condition=" '$(TargetFrameworkIdentifier)' == '.NETCore' And '$(TargetPlatformIdentifier)' == 'UAP' " />
|
|
|
|
</Project>
|
|
|