-
Notifications
You must be signed in to change notification settings - Fork 2
Description
Issues
NOTES
- "RID" refers to a unique combination of OS and CPU architecture. See .NET RID Catalog.
File Size
Updates should be lightweight and have as few files as possible.
- HXE.exe from release 2.1.4 is 128 MiB. If it targeted .NET 6 and used EnableCompressionInSingleFile, it would have been closer to 64 MiB which is still large for a console app with two WPF windows.
- Our GUIs rely on WPF. ~20MiB per RID. Windows-only.
- DotNet SingleFile wraps our app and assemblies with SingleFileHost as the entry assembly. ~10MiB per RID. One app per RID.
- Our dependencies include localizations we don't need since we only support English. These localizations add ~20 MiB (uncompressed) to HXE.exe.
WPF is trim-incompatible
Rampant usage of Reflection and dynamic references e.g. getting a type name from a string.
- https://docs.microsoft.com/en-us/dotnet/core/deploying/trimming/incompatibilities#wpf
- Wpf applications can't be published as a trimmed single exe dotnet/runtime#12951
- WPF .exe published using PublishTrimmed fails to launch dotnet/runtime#50689
- Trimming default WPF app breaks it dotnet/sdk#14261
- WPF is not trim-compatible dotnet/wpf#3811
SingleFile
- https://docs.microsoft.com/en-us/dotnet/core/deploying/single-file
- Making a SingleFile app also requires selecting a specific runtime. We have to use the .NET 5+ SingleFile feature since I couldn't get Fody Weavers working after porting the projects to .NET 5+. The SingleFile host adds an additional 10MiB to executable.
- A SingleFile is heavy. A Self-Contained SingleFile is even heavier.
SingleFile + Win7
-
SingleFile is said to not be supported on Windows 7. Does this include Windows 7 SP1?Condition="'$(PublishSingleFile)' == 'true' and $(RuntimeIdentifier.StartsWith('win7-'))"throws Error NETSDK1180 -
Does the DotNet Core 3.1 style of SingleFile work? This extracts the dependencies to a temporary file location instead of loading directly from the main file.The compiler checks don't care. See previous point. -
Single File publishing is not compatible with Windows 7 dotnet/runtime#62453
-
Build a Windows 7 compatible Single-file AppHost dotnet/runtime#13356
-
-
Support Single-file executable in Windows 7 dotnet/runtime#63196
-
[release/6.0.x] Build Single-File for Windows 7 dotnet/sdk#23336
XML Serialization is discouraged in favor of System.Text.Json for trim compatibility
XML serialization depends on Reflection.