dotnet / sdk

Core functionality needed to create .NET Core projects, that is shared between Visual Studio and CLI
https://dot.net/core
MIT License
2.64k stars 1.05k forks source link

Support Include3rdPartyDLLForSelfExtract for NativeAoT #39202

Open ALIENQuake opened 5 months ago

ALIENQuake commented 5 months ago

Describe the solution you'd like

I want to achieve a NativeAoT, true single-file Avalonia. Avalonia supports AoT just fine, the problem lies with the 3 additional native DLLs:

av_libglesv2.dll
libHarfBuzzSharp.dll
libSkiaSharp.dll

which are native libraries. When compiling with Include3rdPartyDLLForSelfExtract, the resulting exe would be still AoT but all those extra DLLs would be extracted in the same manner as pre-NET6 IncludeNativeLibrariesForSelfExtract did for clrcompression.dll, clrjit.dll, coreclr.dll, mscordaccore.dll aka "during exe launch, extract those required dlls and load them".

Include any alternative solutions you've considered.

Additional context

The true single-file apps are way, way better when it comes to distribution and auto-updating.

dotnet-issue-labeler[bot] commented 5 months ago

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