-
-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
AnyCPU - Simplify support via ModuleInitializer #4063
base: master
Are you sure you want to change the base?
Conversation
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) |
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.
|
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: