Fatal error Lnk1112:module machine type ' X86 ' conflicts with Target machine type ' x64 '

Source: Internet
Author: User

Xxxxxx.lib (xxxxxx.obj): Fatal error Lnk1112:module machine type ' X86 ' conflicts with Target machine type ' x64 '



1. First to see if your module is 64-bit , this is generally, how to configure 64-bit project, here do not say;


2. See if the module is linked to a static library or whether the DLL is 64-bit ;

Configuration-->kinker-->general-->additional Library directories Look is linked to the 64-bit directory;

Whether the library in configuration-->kinker-->input-->additional Dependencies is 64 bits;


3. See if your linked libraries are all 64-bit compiled , temporary files, and whether the target files are generated to a 64-bit directory;


4. Look at the static library of your links :

Configuration-->librarian-->general-->additional Dependencies

Configuration-->librarian-->general-->additional Library Directories

Whether there is a dependency on 32-bit content, in fact, the static library does not need to link the static library, I just because the static library to rely on 32-bit, resulting in 64-bit module compilation failure.


5. Finally, try changing this place :

Configuration-->preprocessor-->preprocessor Definitions-->win32 changed to _win64


Summarize:

Xxxxxx.lib (xxxxxx.obj): Fatal error Lnk1112:module machine type ' X86 ' conflicts with Target machine type ' x64 '

This error message tells you that the 64-bit module relies on 32-bit things to make sure that you rely on a library that is 32-bit, and that the library you rely on doesn't contain anything else 32 bits.


Fatal error Lnk1112:module machine type ' X86 ' conflicts with Target machine type ' x64 '

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.