[CMake] Setting up CMake for Windows projects
Rolf Eike Beer
eike at sf-mail.de
Mon Nov 8 16:39:50 EST 2010
Am Montag, 8. November 2010 schrieb Stormwind Developer:
> Greetings,
>
> I am a complete beginner to CMake, so my problem might be trivial.
> Nevertheless I did not find a solution yet.
>
> I am running Windows XP in a virtual machine on a linux host system.
> Having CMake 2.6.4 installed I tried to run CMakeLists.txt from a
> project I downloaded.
>
> My problem is, that CMake fails with message logs like this one:
> Check for working C compiler: E:/Programme/Microsoft Visual Studio
> 10.0/VC/bin/cl.exe
> Check for working C compiler: E:/Programme/Microsoft Visual Studio
> 10.0/VC/bin/cl.exe -- broken
> CMake Error at E:/Programme/CMake
> 2.6/share/cmake-2.6/Modules/CMakeTestCCompiler.cmake:32 (MESSAGE):
> The C compiler "E:/Programme/Microsoft Visual Studio
> 10.0/VC/bin/cl.exe" is
> not able to compile a simple test program.
If you want to build a command line build (i.e. use MSVC only as a compiler,
not as an IDE) you need to go to Start -> Programs -> Microsoft Visual Studio
-> Tools -> x86 command prompt (or x64 if you want a 64 bit binary). From that
shell you can call CMake like this and you will get a NMake makefile for your
project.
If you want to use the MSVC IDE you need to pass "-G "Visual Studio 2010" (or
something similar, it will complain if I'm wrong) to the CMake command line on
the first run. And you need to upgrade to 2.8, preferrably 2.8.3.
Eike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://www.cmake.org/pipermail/cmake/attachments/20101108/2627b812/attachment.pgp>
More information about the CMake
mailing list