gluck / il-repack

Open-source alternative to ILMerge
Apache License 2.0
1.16k stars 214 forks source link

BinarySerializer considered unsafe #327

Closed hugener closed 8 months ago

hugener commented 9 months ago

When I build a project that does an IlRepack I get the following error: error : BinaryFormatter serialization and deserialization are disabled within this application. See https://aka.ms/binaryformatter for more information. ...\ILRepack.targets(13,5): error : at System.Runtime.Serialization.Formatters.Binary.BinaryFormatter.Serialize(Stream serializationStream, Object graph) ...\ILRepack.targets(13,5): error : at ILRepacking.Steps.ResourcesRepackStep.GenerateRepackListResource(List`1 repackList) Is there a solution for this?

It's .net 8.0 only: https://learn.microsoft.com/en-us/dotnet/core/compatibility/serialization/8.0/binaryformatter-disabled

PR: https://github.com/gluck/il-repack/pull/328