.NETZ – Compression and Packing for .NET Libraries
From the beginning, the .NET runtime had a decent packaging system based on a collection of assemblies. While far better than loose script files or collections of class files, it is not as convenient as statically linked executables or executable JARs. Vasian Cepa’s .NETZ gives developers the ability to compress .NET assemblies and pack them into a single executable file.
By default .NETZ supports compression using #ZipLib or .NET 2.0’s IO.Compression.DeflateStream. Additional compression providers can be created if necessary. Theoretically new compression providers can also include encryption, but no such providers are included out of the box.
There are some limitations. Localized resource DLLs are not supported in .NET 2.0 projects. Unlike .NET 1.0 and 1.1, the .NET 2.0 version doesn’t trigger the AssemblyResolve and ResourceResolve events needed to dynamically decompress the assemblies. There is however a workaround.
Another limitation of the system is that it doesn’t support native DLLs or DLLs created using managed C++. For the latter, this is caused because “the Managed C++ compiler optimizes the PE file and the IL metadata in ways that are not understood by the .NET generic Assembly loader methods”.