Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable Supported attributes from sdk for non browser build, fix related warnings #45504

Merged
merged 3 commits into from
Dec 14, 2020

Conversation

buyaa-n
Copy link
Member

@buyaa-n buyaa-n commented Dec 2, 2020

Related to #44231 and #44257
Enabling Supported attributes from sdk for non browser builds, fix related warnings. We will enable it for browser later with different PR after separating Unsupported on browser files from browser build.

@@ -22,8 +22,8 @@
</AssemblyMetadata>
</ItemGroup>

<!-- Adds SupportedOSPlatform attribute for Windows Specific libraries and Windows targets -->
<ItemGroup Condition="('$(IsWindowsSpecific)' == 'true' or '$(TargetsWindows)' == 'true') and '$(IsTestProject)' != 'true'">
Copy link
Member Author

@buyaa-n buyaa-n Dec 2, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As SupportedOSPlatform("windows") for windows targets will be added by MSBuild we don't need it anymore

<Target Name="RemoveSupportedPlatformAssemblyLevelAttribute"
AfterTargets="GetAssemblyAttributes">
<!-- Removes assembly level attributes for Browser. -->
<Target Name="RemoveSupportedPlatformAssemblyAttributeForBrowser" AfterTargets="GetAssemblyAttributes" Condition="'$(TargetFrameworkSuffix)' == 'Browser'">
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We will remove this rule completely after separating Unsupported on browser APIs from browser build.

@@ -1033,23 +1033,6 @@ public QuotaControl(SecurityIdentifier querySid) : this()
QuerySid = querySid;
}

public SecurityIdentifier QuerySid
{
get => _sid == null ? null : new SecurityIdentifier(_sid, 0);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Separated the section accessing windows only API

@buyaa-n buyaa-n merged commit 6e7fc2f into dotnet:master Dec 14, 2020
@buyaa-n buyaa-n deleted the enable_build_attributes branch December 14, 2020 22:32
@ghost ghost locked as resolved and limited conversation to collaborators Jan 13, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants