AnyCPU - Simplify support via ModuleInitializer#4063
Open
amaitland wants to merge 2 commits intocefsharp:masterfrom
Open
AnyCPU - Simplify support via ModuleInitializer#4063amaitland wants to merge 2 commits intocefsharp:masterfrom
amaitland wants to merge 2 commits intocefsharp:masterfrom
Conversation
Member
Author
|
This will need more testing before merging. |
|
❌ Build CefSharp 100.0.120-CI4441 failed (commit 663746f22d by @amaitland) |
- Checks if the Assembly.GetEntryAssembly() is MSIL - Change CefSharp.Core.csproj to use LangVersion 9 so we can get the compiler to output the ModuleInitializer - Remove CefSharpPlatformCheck and other CefSharpAnyCpuSupport checks - CefSharp.Common.targets still has CefSharpAnyCpuSupport references for backwards compatibility with those with it set and Prefer32bit The default behaviour for this case is to simply copy the 32bit libs - Calling CefRuntime.SubscribeAnyCpuAssemblyResolver multiple times now will simply Unsubscribe the previous resolver This change should remove the need for users to perform any action when supporting AnyCpu.
0849c5f to
9fc6cab
Compare
|
❌ Build CefSharp 100.0.120-CI4442 failed (commit 44a748edd4 by @amaitland) |
Member
Author
|
On the Some additional extensibility points for the user and an even that'll make it easier to debug when the module initializer has run, possibly the ability to cancel it's execution allowing the user to perform their own action directly.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary:
Now that we use the SDK Style csproj files and target VS2019 we can use a custom attribute
(same as in .Net Core 3.1) to get the compiler to output a ModuleInitializer.
ModuleInitializer can be used to resolve AnyCpu dlls at runtime. Should greatly simplify AnyCpu
support.
Changes:
the ModuleInitializer
The default behaviour for this case is to simply copy the 32bit libs
How Has This Been Tested?
Further testing required.
Types of changes
Checklist:
Reference: