[CMake] How to set up Cygwin + CMake + GNU Makefiles + cl.exe correctly?

John Doe ufnoise at gmail.com
Mon Jun 9 20:16:17 EDT 2008


I was able to setup the compiler using a file similar to Bill's.
Unfortunately it appears that cygwin cmake is passing the unix paths
to cl.exe on my Windows Vista 64 system.

What command line options for cmake will allow the compiler tests to
pass.  I tried -DWIN32=1 and -DCMAKE_CL_64=1, but neither seems to
work.

Thanks in advance.

Juan

On Fri, May 30, 2008 at 10:38 AM, Bill Hoffman <bill.hoffman at kitware.com> wrote:
> Stefan Buschmann wrote:
>>
>> Hi all!
>>
>> I'm trying to build my project on Windows using "GNU Makefiles" and cl.exe
>> under Cygwin. I'm using CMake-2.6-patch 0 and Microsoft Visual Studio 2008
>> Professional.
>
> Here is my setup:
>
> export CC=cl
> export CXX=cl
>
> export INCLUDE="C:\Program Files\Microsoft Visual Studio
> 9.0\VC\ATLMFC\INCLUDE;C:\Program Files\Microsoft Visual Studio
> 9.0\VC\INCLUDE;C:\Program Files\\Microsoft SDKs\Windows\v6.0A\include;"
>
> export LIB="C:\Program Files\Microsoft Visual Studio
> 9.0\VC\ATLMFC\LIB;C:\Program Files\Microsoft Visual Studio
> 9.0\VC\LIB;C:\Program Files\\Microsoft SDKs\Windows\v6.0A\lib;"
>
> export
> LIBPATH="C:\WINDOWS\Microsoft.NET\Framework\v3.5;C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727;C:\Program
> Files\Microsoft Visual Studio 9.0\VC\ATLMFC\LIB;C:\Program Files\Microsoft
> Visual Studio 9.0\VC\LIB;"
>
> export PATH=/cygdrive/c/Program\ Files/Microsoft\ Visual\ Studio\
> 9.0/Common7/IDE:/cygdrive/c/Program\ Files/Microsoft\ Visual\ Studio\
> 9.0/VC/BIN:/cygdrive/c/Program\ Files/Microsoft\ Visual\ Studio\
> 9.0/Common7/Tools:/cygdrive/c/WINDOWS/Microsoft.NET/Framework/v3.5:/cygdrive/c/WINDOWS/Microsoft.NET/Framework/v2.0.50727:/cygdrive/c/Program\
> Files/Microsoft\ Visual\ Studio\ 9.0/VC/VCPackages:/cygdrive/c/Program\
> Files//Microsoft\
> SDKs/Windows/v6.0A/bin:/cygdrive/c/emacs/emacs-21.3/bin/:${PATH}
>
>
> Works fine.
>
> -Bill
> _______________________________________________
> CMake mailing list
> CMake at cmake.org
> http://www.cmake.org/mailman/listinfo/cmake
>


More information about the CMake mailing list