[CMake] MSVC100?

Philip Lowman philip at yhbt.com
Thu Dec 4 04:00:19 EST 2008


I think this came up on the mailing list recently but I didn't couldn't find
the thread

To prevent the above abomination of a variable name ever being created by
CMake when Microsoft releases version 10 of their wonderful compiler, I
suggest doing away with the whole MSVC60 / MSVC70 / MSVC71 / MSVC80 / MSVC90
thing for future releases and creating a new variable and setting it to the
current major & minor point release version of Microsoft's compiler:

SET(MSVC_DECIMAL_VERSION  9.0)

Yes, I realize that MSVC_VERSION exists, but seriously who wants to do
integer comparison with confusing values like 1310 and 1400 that require a
search engine to fathom to say nothing of the fact that computers seem to
have floating point processors in them these days.

I will happily submit a patch for this (which shouldn't take long to fix)
provided someone with commit rights can tell me what variable name to use.
CMake seems divided on the whole should we use "CMAKE_COMPILER_2005" or
"MSVC80";  "MSVC" vs."CMAKE_COMPILER_IS_GNUCC";  "MINGW" or
"CMAKE_COMPILER_IS_MINGW".  Not to start a flamewar or anything but this is
awefully bizarre and confusing nomenclature.  Is "CMAKE_COMPILER_..." the
path forward or is it obsolete?

Also, CMAKE_COMPILER_2005 seems to be true on VS9/2008 at least with the
NMake generator.  Not sure if this is a documentation bug or a real bug.

-- 
Philip Lowman
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20081204/a82210fd/attachment.htm>


More information about the CMake mailing list