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

[release/5.0] Leftover Utf8String defines are causing ILLinker warnings #41680

Merged
merged 1 commit into from
Sep 1, 2020

Conversation

eerhardt
Copy link
Member

@eerhardt eerhardt commented Sep 1, 2020

The CreateRuntimeRootILLinkDescriptorFile task, which generates most of S.P.CoreLib's ILLink.Descriptor file for coreclr, doesn't respect #ifdefs. So even though FEATURE_UTF8STRING is disabled in the release/5.0 branch, it is still generating entries for Char8 and Utf8String. But since these managed types do not exist in the release/5.0 branch, the ILLinker is raising warnings.

To fix this, comment the DEFINE_CLASS entries out of the header file.

Fix #41654

Customer Impact

This fixes #41654. If anyone tries to link a coreclr application (console, asp.net, winforms, etc) they are getting warnings that they cannot fix.

Testing

I verified that linking with the new System.Private.CoreLib is no longer producing warnings by default.

Risk

Low - I commented out code that is already behind a #ifdef that is turned off.

Notes

I chose to go the surgical route of removing these from the .h file instead of the full blown route of removing the all the FEATURE_UTF8STRING code because it is a safer change to make at this point in 5.0.

The CreateRuntimeRootILLinkDescriptorFile task, which generates most of S.P.CoreLib's ILLink.Descriptor file for coreclr, doesn't respect #ifdefs. So even though FEATURE_UTF8STRING is disabled in the release/5.0 branch, it is still generating entries for Char8 and Utf8String. But since these managed types do not exist, the ILLinker is raising warnings.

To fix this, comment the DEFINE_CLASS entries out of the header file.

Fix dotnet#41654
@Dotnet-GitSync-Bot
Copy link
Collaborator

I couldn't figure out the best area label to add to this PR. If you have write-permissions please help me learn by adding exactly one area label.

Copy link
Member

@jeffschwMSFT jeffschwMSFT left a comment

Choose a reason for hiding this comment

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

Approved. Please merge once you we have confidence on ci

@jamshedd jamshedd added the Servicing-approved Approved for servicing release label Sep 1, 2020
@jamshedd
Copy link
Member

jamshedd commented Sep 1, 2020

Approved for RC1

@jamshedd jamshedd added this to the 5.0.0 rc1 milestone Sep 1, 2020
@eerhardt eerhardt merged commit 38017c3 into dotnet:release/5.0 Sep 1, 2020
@eerhardt eerhardt deleted the Fix41654 branch September 1, 2020 21:09
@karelz karelz modified the milestones: 5.0.0 rc1, 5.0.0 Sep 9, 2020
@ghost ghost locked as resolved and limited conversation to collaborators Dec 7, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Servicing-approved Approved for servicing release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants