I am trying to run the sample code "blend.cpp" on my computer but I get the following error:
"fatal error LNK1112: module machine type 'x64' conflicts with target machine type 'X86'"
I would like to use VC++ 2008 to use CPLEX; I have Windows 7 on my computer (I suppose it is 64-bit operation system); I installed IBM ILOG CPLEX V12.1 for Windows 64 bit English (CZ3VCEN); and I select the following settings for my project:
Additional Include Directories:
Debug Information Format: Disabled
Any help to resolve this problem is greatly appreciated!
NOTICE: developerWorks Community will be offline May 29-30, 2015 while we upgrade to the latest version of IBM Connections. For more information, read our upgrade FAQ.
This topic has been locked.
5 replies Latest Post - 2012-05-06T05:31:36Z by HP31_Longsheng_Sun
Pinned topic Module machine type 'x64' conflicts with target machine type 'X86'
Answered question This question has been answered.
Unanswered question This question has not been answered yet.
Updated on 2012-05-06T05:31:36Z at 2012-05-06T05:31:36Z by HP31_Longsheng_Sun
Laci Ladanyi 120000NHY881 PostsACCEPTED ANSWER
Re: Module machine type 'x64' conflicts with target machine type 'X86'2010-03-02T16:09:52Z in response to rezayasThe linker error definitely indicates that you have a 32/64-bit mismatch. Your cplex is the 64-bit version, so either your whole Windows 7 is 32-bit version or your VC++ is set up to generate 32-bit objects. My guess is the former.
Re: Module machine type 'x64' conflicts with target machine type 'X86'2010-03-02T16:19:18Z in response to Laci LadanyiLaci, thanks for your reply.
I check the system information and system type is "64-bit operating system". So I guess my OS is 64-bit?
But how can I check if the VC++ is set up to generate 32-bit objects?
In the Project Property window I only have Win32 for Platform; do you think that is the problem? Can I change it somehow?
Thanks a lot,
y82li 270003N9PT65 PostsACCEPTED ANSWER
Re: Module machine type 'x64' conflicts with target machine type 'X86'2011-05-23T14:17:57Z in response to rezayasHi,Reza,
I have got same problem. How do you solve this issue. Could you please let me know how do you change the configuration to generate a 64-bit object?
HP31_Longsheng_Sun 270004HP311 PostACCEPTED ANSWER
Re: Module machine type 'x64' conflicts with target machine type 'X86'2012-05-06T05:31:36Z in response to rezayasI also meet this problem about one week ago. As this problem is not answered fully, I think it is great to give an answer to this problem as it took me much time on this and got stuck with my research somehow. If you are using a higher version of visual studio, this is not a problem. However for vs2008, it happens.
The problem is that you have build a win32 application on a 64 bit system. What you need to do is to change the release to x64.
1. You need to use your vs2008 installation to install the x64 compilers and tools.
2.“Build” – “Configuration Manager”, for the active solution platform, click and choose new.
3.choose x64 in the pop up window.
Then you can successfully run the program~