views:

14

answers:

2

I'm using CUDA(VC++ visual studio 2008sp1) to debug a FEM program. The program can only run on a win32 platform, for the insufficiency of cuda. I think the library files linked are all compiled on the x86 platform, but when I compile it,there is the error message"fatal error LNK1112: module machine type 'x64' conflicts with target machine type 'X86'".I have tried to convert the platform to x64, it cannot work , too. Please tell me ----what is "module machine type" & what is "target machine type"? How can I overcome it? Thank you

A: 

You probably have one .OBJ or .LIB file that's targeted for x64 (that's the module machine type) while you're linking for x86 (that's the target machine type).

Use DUMPBIN /HEADERS on your .OBJ files and check for the machine entry in the FILE HEADER VALUES block.

Patrick
A: 

what is the OS? if it is a windows x64 then you need to make sure that CUDA x64 was installed and thus that VS2008 should compile the project in x64 mode...

CUDA will only install x64 OR x86 in windows

Conor