由于某些原因,UWP应用程序在部署到XBox时在Windows 10计算机上运行得非常好,但无法使用标准ZipArchive类使用.zip归档。它似乎与此问题类似:Unzipping throws an "The underlying compression routine could not be loaded correctly",但只发生在XBox上。XBox UWP应用程序中的ZipArchive
System.IO.Compression.ZLibException: The underlying compression routine could not be loaded correctly.
---> System.DllNotFoundException: Unable to load DLL 'clrcompression.dll':
The specified module could not be found. (Exception from HRESULT: 0x8007007E)
at Interop.zlib.inflateInit2_(Byte* stream, Int32 windowBits, Byte* version, Int32 stream_size)
at Interop.zlib.InflateInit2_(ZStream& stream, Int32 windowBits)
at System.IO.Compression.ZLibNative.ZLibStreamHandle.InflateInit2_(Int32 windowBits)
at System.IO.Compression.Inflater.InflateInit(Int32 windowBits)
--- End of inner exception stack trace ---
at System.IO.Compression.Inflater.InflateInit(Int32 windowBits)
at System.IO.Compression.DeflateStream.InitializeInflater(Stream stream, Boolean leaveOpen, Int32 windowBits)
at System.IO.Compression.ZipArchiveEntry.GetDataDecompressor(Stream compressedStreamToRead)
我靶向15063(创建者更新)与Microsoft.NETCore.UniversalWindowsPlatform = 5.4.0
我试图明确地(否则参考是可传递的)参考System.IO.Compression = 4.3。 0和runtime.native.System.IO.Compression = 4.3.0,都没有成功。
此外,我试图强制降级到System.IO.Compression = 4.1.1,但问题并没有消失。
是否有我缺少的Nuget参考?或者包是简单地打破在XBox