[CMake] MSVC71 problems when upgrading to CMake 2.6.2

Luke Kucalaba lkucalaba at dsci.com
Thu Oct 9 16:03:28 EDT 2008


Thanks Brad.  Sorry if I come across as upset or cynical, but I'm really
just frustrated... it's been a long week.  But with your help and Bill's
help I think we are finally ready to move to CMake 2.6.2!  CMake really
is the greatest build system I've ever used, and has a lot of potential
as well.  I just wish it integrated a little easier with MSVC IDE and
external tools like the resource compiler, or at least there was more
documentation about the recommended way to set up a single CMake project
that can be built with a makefile generator or an IDE-based generator
like MSVS with build configurations.  Excellent that this
COMPILE_FLAGS_<CONFIG> is on the list for future capabilities, because I
know at least for us it is a "make-or-break" feature.  I understand
CMake's design principle and conventions, but what I don't understand is
why Microsoft has to be different than everyone else for everything :-)!

I just finished building one of our larger projects using CMake 2.6.2
and NMake, MSVC71, and Codeblocks/Unix generators, and everything looks
good.  This issue can be considered resolved.

Thanks again,
Luke

-----Original Message-----
From: Brad King [mailto:brad.king at kitware.com] 
Sent: Thursday, October 09, 2008 3:48 PM
To: Luke Kucalaba
Cc: cmake at cmake.org
Subject: Re: [CMake] MSVC71 problems when upgrading to CMake 2.6.2

Luke Kucalaba wrote:
> First problem is that you will still have
> build configurations in your MSVC project regardless.  There is no way
> that I know of to disable generation of build configurations in MSVC.

This is just the way the VS IDE works.  A basic CMake design principle
is to follow the conventions of the native build tools for which it is
generating.  If you don't like it, then the IDE is not for you.  Use the
NMake generator instead.

> The second problem I have with this target-based approach is that the
> "set target properties" command does not allow exclusive, direct
> command-line manipulation of the compiler and linker.  There are is no
> COMPILE_FLAGS_DEBUG and COMPILE_FLAGS_RELEASE properties.  It is nice
> that   I see that there ARE properties for LINK_FLAGS_DEBUG and
> LINK_FLAGS_RELEASE though. 

There is a feature request for this:

  http://www.cmake.org/Bug/view.php?id=6493

work is underway but not complete.

-Brad


More information about the CMake mailing list