Solution 1:
Originally installed on the machine VS2010 very normal, after installing the VS2012, there are hints
Error LNK1123: Failed during conversion to COFF: invalid or corrupt file, as shown in figure:
The specific reason for this is that the format of the Microsoft link file has changed (the silent Microsoft)
Microsoft Official to give the specific solution is to give VS2010 hit SP1 patch.
Download address is: http://www.microsoft.com/en-us/download/details.aspx?id=23691
Solution 2:
is an embedded inventory issue, so the project and all dependent projects are as follows:
Built-in list, input and output, list tools, project properties, right-click, select [No]
1>link:fatal Error LNK1123: Failed during transition to COFF: invalid or corrupt file
1>cvtres:fatal Error CVT1100: Resource duplication. Type: MANIFEST, Name: 1, Language: 0x0409
This is caused by a log file, which can be
Project \ properties \ Configuration properties \ manifest tools \ input and output \ Embed list: The original is "yes" and changed to "no".
or the
Project \ properties \ configuration properties \ linker \ manifest file \ Generate manifest: The original is "yes" and changed to "no".
I've summed up the solution to this effect:
1: Assume that the nominal is a static library, it may be said that there is no intrinsic resource file in the list, it is possible to change the embed manifest to "no".
2: If you have a resource file already in the list, then changing the embed manifest to "No" is not a good way to dispose of the effect unless you remove the resource files at the same time.
Assertion, to ensure that there is no resource file in the name, and to change the embedded list to "No" may dispose of the effect, but it did lose the role of resource files, no measures, who let him be a bug?
Solution 3:
Compiling an MFC program that supports XP with VS2012 November, 16:31 Posted by Posted in [Channel 8]
Visual Studio 2012 was released for some time and it felt good to use. But recently wrote a small program but encountered a more troublesome thing.
This program is an MFC application written using Visual Studio 2012, which has been compiled and run in the Win7 system, and everything is OK. However, running on an XP or 2003 system will prompt "not a valid Win32 application". At first thought the file was damaged, then copy several times to find the problem remains.
Then search, found that a lot of people mentioned this problem, mainly because of the reasons for VS2012, compiled programs no longer support XP. However, MS officials also mentioned that a patch would be released to resolve the issue. Initially the patch was included in Visual Studio Update 1 CTP 3. The search for this package found no longer available, and it was later discovered that the official version of Visual Studio Update 1 was released at 26th (or more than 1 days ago) and the installation was downloaded.
Following the official instructions, after the installation is successful, open VS2012, on the project properties, there should be configuration Properties-general-the platform toolset appears "Visual Studio (v110 XP)." Unfortunately, this update 1 package is installed online, there is always a package can not be downloaded, install a few times is useless.
But it's hard to re-install a visual Studio 2010, but turning the original project into a 2010 project is too much trouble. Fortunately, when you look at the properties of the project from 2012, Visual Studio (V100) and Visual Studio V90 have already appeared in the platform toolset. So rebuild the project, compile, and then the problem.
The problem is "LINK: fatalerrorLNK1123: failed during transition to COFF : invalid or corrupt file". Continue to search, found that the problem is also very common, the processing method is more consistent, is to continue to set the properties of the project, configuration Properties-inventory tools-input and output-embedded list-No.
According to this method set up after the discovery is still not good, but it seems that other people on the Internet with this method to solve the problem ah, strange. Later, the installation notification of the Visual Studio SP1 patch appeared in the lower right corner of the system. Think of the possibility of using 2010 later, so take the previously downloaded SP1 installation package installed. Then try again, pleasantly surprised to find that the problem actually solved, and finally compiled the MFC program that can run in XP and 2003.
To summarize, install VS 2010 and its SP1, set the embedded list of properties to No, the platform toolset is 2010, regenerate.
In fact, this is a temporary urgency to solve the problem, estimated a few days VS2012 Update 1 network installation is stable, you can directly use the 2012 tool set to support XP and 2003 of the program is compiled.
Solution 4:
This is what Microsoft is all about, and once something goes wrong, you can only choose to reload or even reload the system. I also use this stupid scheme. But the feeling may be related to I previously installed in the D disk VC, it is possible to overwrite the installation caused some files are corrupted. So I first uninstalled the VC, and then the folder D:/program Files/viusaul Studios deleted, before the installation of this directory. Then restart the computer and reinstall it. and re-opened the small project, compiled, passed.
Summary: These methods are collated from the Internet, after I tested, Method 2 will work, but I tested three projects, there is a project is not always, with scenario 1 Download a SP1 package (about 600M), after installation, restart, open vs follow the pop-up box prompts to install other patches, recompile, problem resolution.