-
Notifications
You must be signed in to change notification settings - Fork 4.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
NativeAOT: Custom runtime without AppContext class throw #77054
Comments
We could make that line conditional on IlcSystemModule being empty and maybe that would work? But I'm not very sympathetic to doing all this with |
yes, that would work. I manually remove line and everything was working, so that’s essentially the same.
I’m gladly accept burden of testing this. Seems to be we have only one issue related to this mode in 2-3 years? Having no runtime mode using technically there UEFI environments where bflat probably would not work. I would even have appetite to provide fix and have it land Net 7(maybe not in RTM) but at least in first patches. 🥺🙏 |
I don't know if we have .NET 7 servicing bar somewhere public, but it looks somewhat like this: #72297 (comment). I have a hard time fitting this into any of the bullet points.
|
Previously AppContext switches were set by injecting a method that calls `AppContext.SetSwitch` at startup. Use the configuration blob added in dotnet#86068 instead. This makes startup a tiny bit faster and the outputs a tiny bit smaller. Fixes dotnet#77054.
Description
If you compile application with custom runtime where
System.AppContext
class is not defined, compiler crashEven if I apply suggestion from #63862 (comment) to the csproj file due to this line
runtime/src/coreclr/nativeaot/BuildIntegration/Microsoft.NETCore.Native.targets
Line 230 in e790378
workaround no longer working.
Reproduction Steps
Close code from this PR MichalStrehovsky/SeeSharpSnake#24
Apply #63862 (comment)
Expected behavior
Custom runtimes can be built using NativeAOT
Actual behavior
Currently it is blocked.
Regression?
No response
Known Workarounds
No response
Configuration
No response
Other information
No response
The text was updated successfully, but these errors were encountered: