[vtkusers] buillding QVTK on 64-bit OS

John Drescher drescherjm at gmail.com
Tue Jun 16 12:38:15 EDT 2009


On Tue, Jun 16, 2009 at 12:33 PM, Lloyd Fenelon<lfenelon at bccrc.ca> wrote:
>
>
> -----Original Message-----
> From: John Drescher [mailto:drescherjm at gmail.com]
> Sent: Monday, June 15, 2009 10:58 AM
> To: Lloyd Fenelon; VTK
> Subject: Re: [vtkusers] buillding QVTK on 64-bit OS
>
>> Did you build qt using nmake? The .sln file for some reason only creates 32 bit libraries.
>>
>> http://www.qtcentre.org/forum/f-installation-and-deployment-5/t-solved-64-bit-compiles-under-visual-studio-2005-21318.html
>>
>> John
>>
>>
>> Thanks John, but I did build Qt-4.5.1 with the 64-bit Command Prompt supplied with the Visual Studio Tools and nmake (configure & nmake & nmake clean)..which should have built a 64-bit library if I am not wrong? Is there an option in the configure.exe to build the Qt 64-bit library?
>>
> No. That should have been enough. Well at least that worked for me.
> Are your paths picking up the correct qt libs/dlls?
>
>
> Hi,
>
> I had a doubt in my Qt installation so I did a fresh install using the VS2005 x64 Command Prompt. I still have the same error when I am building QVTK projects:
>
> QtGui4.lib(QtGui4.dll) : fatal error LNK1112: module machine type 'x64' conflicts with target machine type 'X86'
>
> Environment variables :
> %QTDIR% : C:\Develop\Qt\Qt-4.5.1
> The Qt bin directory is in my PATH : ...;%QTDIR%\bin\;...
> QMAKESPEC is set to win32-msvc2005
>
> I checked with the command line:
> C:\> qmake -v
> QMake version: 2.01a
> Using Qt version 4.5.1 in C:\Develop\Qt\Qt-4.5.1\lib
>
> C:\> echo %QMAKESPEC%
> win32-msvc2005
>
> in VS->Tools->Options->VC++ Directories->Include files : $(QTDIR)\include
> in VS->Tools->Options->VC++ Directories->Library files : $(QTDIR)\lib
>
> for example if I check the linker->additional Dependencies in the Property Pages of the QVTKCxxTests project I've got : C:\Develop\Qt\Qt-4.5.1\lib\QtGui4.lib
> which is the good directory for the Qt library.
> I also have the good Additional include Directory C:\Develop\Qt\Qt-4.5.1\include
>
> Now when I am using just Qt I create a Makefile Project and I can build only if I create a new platform solution x64.
>
> I tried to create a new solution platform x64 for the QVTKCxxTests project and I am having the error:
>
> vtkCommon.lib(vtkFloatingPointExceptions.obj) : fatal error LNK1112: module machine type 'X86' conflicts with target machine type 'x64'
>
> It is like a vicious circle! Does that mean I need VTK library for 64-bit OS ?
> I have looked the flags in CMAKE but I only see the flag VTK_USE_64bit_IDS, does this one could help?
>

To build a 64 bit application all libraries / dlls used must be
compiled for 64 bit.

I did this on my 64 bit XP machine by making a totally new build tree
for the 64 bit builds but keeping a shared source folder.

John



More information about the vtkusers mailing list