A DLL wouldn't load on my Mac, so I built pefix (opens in new tab)
I was modding a Unity game on my Mac. The mod shipped as a .NET DLL and wouldn't load: the IL was plain managed code, but the assembly header was stamped for Windows x64, so the runtime refused it. I opened the PE header, flipped the bits that pin it to a platform back to AnyCPU, and it loaded. That became pefix fix. The header turned out to be the easy case. The failures that actually bite are about the folder around the DLL: a dependency that never got copied, two copies of one assembly at ...
Read the original article