Mark System.Security.Cryptography.OpenSsl as unsupported on Windows, fixes #40101...
authorAdam Sitnik <adam.sitnik@gmail.com>
Wed, 5 Aug 2020 16:25:25 +0000 (18:25 +0200)
committerGitHub <noreply@github.com>
Wed, 5 Aug 2020 16:25:25 +0000 (18:25 +0200)
eng/versioning.targets
src/libraries/System.Security.Cryptography.OpenSsl/Directory.Build.props

index f0cbf0e..2a2f10d 100644 (file)
     </AssemblyAttribute>
   </ItemGroup>
 
+  <!-- Adds UnsupportedOSPlatform attribute for requested libraries -->
+  <ItemGroup Condition="'$(UnsupportedOSPlatform)' != '' and '$(IsTestProject)' != 'true'">
+    <AssemblyAttribute Include="System.Runtime.Versioning.UnsupportedOSPlatform">
+        <_Parameter1>$(UnsupportedOSPlatform)</_Parameter1>
+    </AssemblyAttribute>
+  </ItemGroup>
+
   <Target Name="DecideIfWeNeedToIncludeDllSafeSearchPathAttribute"
           Condition="'$(IsDotNetFrameworkProductAssembly)' == 'true' and '$(IsTestProject)' != 'true' and '$(IsTestSupportProject)' != 'true'">
 
index 63f02a0..34e5872 100644 (file)
@@ -2,5 +2,7 @@
   <Import Project="..\Directory.Build.props" />
   <PropertyGroup>
     <StrongNameKeyId>Microsoft</StrongNameKeyId>
+    <IncludePlatformAttributes>true</IncludePlatformAttributes>
+    <UnsupportedOSPlatform>windows</UnsupportedOSPlatform>
   </PropertyGroup>
 </Project>
\ No newline at end of file