Brad King wrote: > On 09/12/2012 02:33 PM, Rolf Eike Beer wrote: > > Ah, hm. Ok, this is the compiler version variable that I knew it would > > exist but did not know how it was named. So this demonstrates exactly > > what I was talking about: > > > > if (MSVC_VERSION VERSION_GREATER 1400) > > > > Without looking in the docs, which MSVC version am I talking about? > > Always subtract 6 from the "cl" version number to get the IDE version. > This is just a standard VS thing and is not CMake-specific.
I have not said that. But as I did not know until 5 minutes ago someone else scanning a CMake file may also not know. So you always need to add a comment. > > I would > > propose to name it MSVC_IDE_VERSION then, so this would make it clear to > > everyone: > > > > if (MSVC_IDE_VERSION VERSION_GREATER 8.0) > > Starting with VS 2010 the projects support specifying the toolchain > from a different version of VS. Now that ide-compiler-id is done we > can possibly add support for selecting the compiler in the future. > Therefore the IDE version can be associated only with the IDE > generators, and we already have that from the generator name in > CMAKE_GENERATOR. Do a selection of "MSVC >= 9.0" based on the generator string in one line here please: 1. :) Ok, if you don't like the idea, I really don't care about MSVC that much anymore. But I wonder why then another MSVCnn variable is introduced for every new version of that thing. > > And from all what I know the CMAKE_CXX_COMPILER_VERSION variable would > > also > > return 1400 in that case. > > It would be 14.0.$build or so. It's the "cl" tool version. Yes, sure. I just have no MSVC around to check ;) > > (Another variable missing on the Wiki) > > The Wiki pre-dates the variables section of the reference documentation. > Is it really needed anymore? Now it just duplicates information. In that case I think bug 12567 should be fixed, the wiki page should be cleared and provide just a link to the generated documentation. I wonder if the CYGWIN and WIN32 variables should then get a hint that their behavior changed and which policy was introduced for that. Eike --
signature.asc
Description: This is a digitally signed message part.
-- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers