The following error may occur in compiling the link with VisualStudio:
LINK : fatal error LNK1123: failure during conversion to COFF: file invalid or corrupt
The following solutions are available online:
1. Disable incremental linking
Project Properties -> Configuration Properties -> Linker (General) -> Enable Incremental Linking -> "No (/INCREMENTAL:NO)"
2. Turn off “Embed Manifest”
But neither method worked for me.
Issue root cause: In a system update or software upgrade, there is more than one version of the Utility: Cvtres.exe
D:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\cvtres.exe
C:\Windows\Microsoft.NET \ Framework \ v4.0.30319 \ cvtres exe code>
code>
code>
Cvtres. exe in VS directory is not in work due to improper cause of . If the Utinity is in front of the path and linker feels the need to convert a.res file to COFF object format,link will fail, showing error: LNK1123
code>
: delete or rename the old Utility cvtres.exe to cvtres.exe_old for VS. Or rearrange the PATH variable.
code>
reference :
http://stackoverflow.com/questions/10888391/error-link-fatal-error-lnk1123-failure-during-conversion-to-coff-file-inval
-------------------
About Error: LNK1123: Failure during conversion to COFF: File invalid or corrupt error solution [Qt] [VS2010]
VS2010 Qt development tools have had to be reinstalled due to a new hard drive. There is no problem with the installation process. After installation, I clicked on an example to test it and it did not work well. Then the error message in the title appeared. I had dealt with it once before, but I forgot it after a long time, so I solved it by another search. This time grow a heart eye, write down, lest later forget again (write blog essay of what not stick to, have to despise oneself).
Let's get started. The prompt indicates that the conversion to the COFF file failed because of an error (VS2010 is installed and there would normally be no file invalid).
Cvtres.exe is the program that does the conversion. The root cause of the above error is the presence of multiple versions of CVtres.exe on the system.
\Windows\Microsoft \Framework\v4.0.30319\cvtres.exe
VS directory version :
C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\BIN\cvtres.exe
if it is a 64-bit system, then there is another one in
c: \Windows\Microsoft t.net \Framework64\v4.0.30319\cvtres.exe
, however, both versions of the Framework and Framework64 are the same, and are generally newer than the version in the VS directory due to system updates.
The solution here is obviously simple, just rename or delete the old version, but I usually do renames, like adding -old.
Another point to make is that when looking for the cvtres.exe program in the system directory, there is an XML file called Cvtres.exe (the blogger does not show the file extension). So don't make a mistake when you look for it.
Well, that's all for this essay. It's not easy to get into the habit of blogging T T, keep up the good work!
Reproduced in: https://www.cnblogs.com/kungfupanda/p/4121059.html
Read More:
- VS2010 error: LINK : fatal error LNK1123: failure during conversion to COFF: file invalid or corrupt
- Link: fatal error lnk1123: failure during conversion to coff: file in
- Visual Studio 2010 compilation error fatal error lnk1123: failed during conversion to coff: solution to invalid or corrupt file
- Error lnk1123: failure during conversion to coff: problem solving
- Link: fatal error LNK1104: cannot open file “debug”/ xx.exe The question of
- About 1 > link: fatal error lnk1168: unable to open… Exe or… DLL for writing
- >Link: fatal error lnk1561 and link: fatal error lnk1168: Solutions
- Problems caused by vs project build order: link: fatal error lnk1181: cannot open input file ‘zoom’_ Ui_ style.lib ‘
- LINK : fatal error LNK1168: cannot open Debug/1.exe for writing
- fatal error LNK1169: one or more multiply defined symbols found
- fatal error LNK2019[UNK]fatalerror LNK1120
- #During OpenGL development, fatal error C1083: can’t open include file: “GL / glut. H”: no such file or directory
- Solutions for failure to start Axure RP (including failure to uninstall or install. Net framework)
- A fatal error C1083 occurred when compiling C + + code under. Net: unable to open the include file: “xuhk”_ Jnihelloworld. H “: solution to no such file or directory error.
- How to Fix Fatal Error lnk1120: 1 unresolved externals
- Error in header file when calling OpenGL to open obj file in vs2013: unable to open include file: “GL / glut. H”: no such file or directories
- LINK : error LNK2001: unresolved external symbol _mainCRTStartup
- Communication link failure when connecting Doris
- Solution of vs unable to open source file and link library file
- fatal error LNK1120: 1 unresolved externals