-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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] Support exporting methods from referenced assemblies in a formal way #83396
[NativeAOT] Support exporting methods from referenced assemblies in a formal way #83396
Conversation
Tagging subscribers to this area: @agocke, @MichalStrehovsky, @jkotas Issue DetailsThis PR adds support for exporting methods from referenced assemblies in a more controllable way. The changes include:
NOTE: It is possible that the naming is not ideal and I am open for any suggestions. Fixes #65755
|
src/coreclr/nativeaot/BuildIntegration/Microsoft.NETCore.Native.Publish.targets
Outdated
Show resolved
Hide resolved
src/tests/nativeaot/ExportsFromReferencedAssemblies/NativeHost.cpp
Outdated
Show resolved
Hide resolved
…ad of implicitly doing it in the compiler
src/coreclr/nativeaot/BuildIntegration/Microsoft.NETCore.Native.targets
Outdated
Show resolved
Hide resolved
src/tests/nativeaot/GenerateUnmanagedEntryPoints/GenerateUnmanagedEntryPoints.cpp
Outdated
Show resolved
Hide resolved
…otProvider if it is passed as an input file
src/tests/nativeaot/GenerateUnmanagedEntryPoints/GenerateUnmanagedEntryPoints.cpp
Outdated
Show resolved
Hide resolved
src/coreclr/nativeaot/BuildIntegration/Microsoft.NETCore.Native.targets
Outdated
Show resolved
Hide resolved
src/tests/nativeaot/GenerateUnmanagedEntryPoints/GenerateUnmanagedEntryPoints.csproj
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Thank you!
… of an executable for ELF targeted ports
This PR adds support for exporting methods from referenced assemblies in a more controllable way.
The changes include:
UnmanagedEntryPointsAssembly
- new ItemGroup which can be used to include names of assemblies for which unmanaged entry points have to be exported--generateunmanagedentrypoints
- new ILCompiler switch which can be used to pass the list of assemblies for which methods have to be exported and is populated with items from1.
System.Private.CoreLib
in1.
--export-dynamic
native linker switch in the build, when it is required to dynamically access exported symbols from the main executable targeting linux systems (more information here)Fixes #65755