Attached is the essential output, Stephen.

Interestingly, the tool chain I had in this shell was msvc2010 (x64).
(As you can see from the call to 'cl')

However, cmake doesn't seem to pick that up and instead picks up my older 2008 
compiler.
Inspecting the qtcmaketest.vcproj file also shows the issue (line 67):

AdditionalOptions=" /STACK:10000000 /machine:X86 /debug"


It seems that the reason is that cmake does not recognize/utilize the msvc2010 
x64 toolchain for some reason.

Jan Arve




> -----Original Message-----
> From: [email protected]
> [mailto:[email protected]]
> On Behalf Of Stephen Kelly
> Sent: 10. april 2013 13:09
> To: [email protected]
> Cc: Sarajärvi Tony; Andreas Holzammer; Patrick Spendrin
> Subject: Re: [Development] CMake tests with 64 bit windows On 
> Wednesday, April 10, 2013 07:30:34 you wrote:
>> Hello,
>> 
>> we encountered some trouble when setting up a new CI machine where we 
>> would run Windows 7 64 bit and compile in 64 bit mode. The CMake 
>> tests fail there.
> 
> Andy/Patrick, have you ever seen something like this before?
> 
>  ClCompile:
>    two.cpp
>    two_automoc.cpp
>  Qt5Core.lib(Qt5Core.dll) : fatal error LNK1112: module machine type 
> 'x64'
> conflicts with target machine type 'X86'
> 
> More logging:
> 
>  http://thread.gmane.org/gmane.comp.lib.qt.devel/10746
> 
> Tony, please download the attached files and execute the build with 
> qmake and cmake (both with nmake and visual studio generators) and 
> post all of the terminal output. Something like this:
> 
>  cd qtcmaketest mkdir qmaketest cd qmaketest  
> C:\path\to\Qt5\bin\qmake.exe .. nmake cd .. mkdir cmake_nmake cd  
> cmake_nmake cmake .. -G "NMake Makefiles" -DCMAKE_VERBOSE_MAKEFILE=1 -  
> DCMAKE_PREFIX_PATH=C:\path\to\Qt5\lib\cmake cmake --build . cd .. cd  
> cmake_vs cmake .. -DCMAKE_VERBOSE_MAKEFILE=1 -DCMAKE_PREFIX_PATH=C:
>  \path\to\Qt5\lib\cmake cmake --build . cd ..
> Thanks,
>
T:\dev\issues\cmake\qtcmaketest> cd .\cmake_nmake
T:\dev\issues\cmake\qtcmaketest\cmake_nmake> cmake .. 
-DCMAKE_VERBOSE_MAKEFILE=1 
-DCMAKE_PREFIX_PATH=T:\dev\qt-5-x64-dev\qtbase\lib\cmake
-- Building for: Visual Studio 9 2008
-- The C compiler identification is MSVC 15.0.30729.1
-- The CXX compiler identification is MSVC 15.0.30729.1
-- Check for working C compiler using: Visual Studio 9 2008
-- Check for working C compiler using: Visual Studio 9 2008 -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler using: Visual Studio 9 2008
-- Check for working CXX compiler using: Visual Studio 9 2008 -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Configuring done
-- Generating done
-- Build files have been written to: T:/dev/issues/cmake/qtcmaketest/cmake_nmake
T:\dev\issues\cmake\qtcmaketest\cmake_nmake> cl
Microsoft (R) C/C++ Optimizing Compiler Version 16.00.30319.01 for x64
Copyright (C) Microsoft Corporation.  All rights reserved.

cl : Command line error D8003 : missing source filename
T:\dev\issues\cmake\qtcmaketest\cmake_nmake> cmake --build
Usage: cmake --build <dir> [options] [-- [native-options]]
Options:
  <dir>          = Project binary directory to be built.
  --target <tgt> = Build <tgt> instead of default targets.
  --config <cfg> = For multi-configuration tools, choose <cfg>.
  --clean-first  = Build target 'clean' first, then build.
                   (To clean only, use --target 'clean'.)
  --use-stderr  =  Don't merge stdout/stderr.
  --             = Pass remaining options to the native tool.
T:\dev\issues\cmake\qtcmaketest\cmake_nmake> cmake --build .'
>>
T:\dev\issues\cmake\qtcmaketest\cmake_nmake> cmake --build .

Microsoft (R) Visual Studio Version 9.0.21022.8.
Copyright (C) Microsoft Corp. All rights reserved.
1>------ Build started: Project: qtcmaketest, Configuration: Debug Win32 ------
1>Compiling...
1>Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 15.00.30729.01 for 
80x86
1>Copyright (C) Microsoft Corporation.  All rights reserved.
1>cl /Od /I "T:\dev\qt-5-x64-dev\qtbase\include" /I 
"T:\dev\qt-5-x64-dev\qtbase\include\QtCore" /I 
"T:\dev\qt-5-x64-dev\qtbase\mkspecs\win32-msvc2010" /D "WIN32" /D "_WINDOWS" /D 
"_DEBUG" /D "QT_CORE_LIB" /D "CMAKE_INTDIR=\"Debug\"" /D "_MBCS" /FD /EHsc 
/RTC1 /MDd /Fo"qtcmaketest.dir\Debug\\" 
/Fd"T:\dev\issues\cmake\qtcmaketest\cmake_nmake\Debug/qtcmaketest.pdb" /W3 /c 
/Zi /TP   /Zm1000
1>   ..\main.cpp
1>main.cpp
1>Compiling manifest to resources...
1>Microsoft (R) Windows (R) Resource Compiler Version 6.1.7600.16385
1>Copyright (C) Microsoft Corporation.  All rights reserved.
1>Linking...
1>Qt5Cored.lib(Qt5Cored.dll) : fatal error LNK1112: module machine type 'x64' 
conflicts with target machine type 'X86'
1>Build log was saved at 
"file://t:\dev\issues\cmake\qtcmaketest\cmake_nmake\qtcmaketest.dir\Debug\BuildLog.htm"
1>qtcmaketest - 1 error(s), 0 warning(s)
========== Build: 0 succeeded, 1 failed, 2 up-to-date, 0 skipped ==========
T:\dev\issues\cmake\qtcmaketest\cmake_nmake> 
_______________________________________________
Development mailing list
[email protected]
http://lists.qt-project.org/mailman/listinfo/development

Reply via email to