LNK1123: Failure During Conversion to COFF: File Invalid or Corrupt

Issue:

“LNK1123: failure during conversion to COFF: file invalid or corrupt” link error when building a VC++ 2010 project.

Background:

This error can appear after installing Visual Studio 2012 side-by-side (SXS) with Visual Studio 2010 RTM or after installing .Net Framework 4.5 on a machine with Visual Studio 2010.

The issue is caused by a dependency failure of cvtres.exe on msvcr100_clr0400.dll which is shipped with Visual Studio 2010 RTM and eventually updated with a new version when Visual Studio 2012 RTM or .NET Framework 4.5 is installed.

Solution:

To resolve this link error, upgrade Visual Studio 2010 RTM to VS 2010 SP1. Upgrading to VS 2010 SP1 resolves the dependency failure and the VC++ 2010 project builds with no LNK1123 error.

Source: https://support.microsoft.com/en-us/kb/2757355  



Article ID: 746
Last updated: 2019-02-25
Revision: 2
CANape -> Model Based Development -> LNK1123: Failure During Conversion to COFF: File Invalid or Corrupt
https://kb.vector.com/entry/746/