Imported Upstream version 2.8.10.2
[platform/upstream/cmake.git] / Modules / CMakeVS10FindMake.cmake
1
2 #=============================================================================
3 # Copyright 2007-2009 Kitware, Inc.
4 #
5 # Distributed under the OSI-approved BSD License (the "License");
6 # see accompanying file Copyright.txt for details.
7 #
8 # This software is distributed WITHOUT ANY WARRANTY; without even the
9 # implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
10 # See the License for more information.
11 #=============================================================================
12 # (To distribute this file outside of CMake, substitute the full
13 #  License text for the above reference.)
14
15 # Look for devenv as a build program.  We need to use this to support
16 # Intel Fortran integration into VS.  MSBuild can not be used for that case
17 # since Intel Fortran uses the older devenv file format.
18 find_program(CMAKE_MAKE_PROGRAM
19   NAMES devenv
20   HINTS
21   [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\10.0\\Setup\\VS;EnvironmentDirectory]
22   [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\10.0\\Setup;Dbghelp_path]
23   "$ENV{ProgramFiles}/Microsoft Visual Studio 10.0/Common7/IDE"
24   "$ENV{ProgramFiles}/Microsoft Visual Studio10.0/Common7/IDE"
25   "$ENV{ProgramFiles}/Microsoft Visual Studio 10/Common7/IDE"
26   "$ENV{ProgramFiles}/Microsoft Visual Studio10/Common7/IDE"
27   "$ENV{ProgramFiles} (x86)/Microsoft Visual Studio 10.0/Common7/IDE"
28   "$ENV{ProgramFiles} (x86)/Microsoft Visual Studio10.0/Common7/IDE"
29   "$ENV{ProgramFiles} (x86)/Microsoft Visual Studio 10/Common7/IDE"
30   "$ENV{ProgramFiles} (x86)/Microsoft Visual Studio10/Common7/IDE"
31   "/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/"
32   "/Program Files/Microsoft Visual Studio 10/Common7/IDE/"
33   )
34
35 # if devenv is not found, then use MSBuild.
36 # it is expected that if devenv is not found, then we are
37 # dealing with Visual Studio Express.  VCExpress has random
38 # failures when being run as a command line build tool which
39 # causes the compiler checks and try-compile stuff to fail. MSbuild
40 # is a better choice for this.  However, VCExpress does not support
41 # cross compiling needed for Win CE.
42 if(NOT CMAKE_CROSSCOMPILING)
43   find_program(CMAKE_MAKE_PROGRAM
44     NAMES MSBuild
45     HINTS
46     [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\10.0\\Setup\\VS;ProductDir]
47     "$ENV{SYSTEMROOT}/Microsoft.NET/Framework/[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\10.0;CLR Version]/"
48     "c:/WINDOWS/Microsoft.NET/Framework/[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\10.0;CLR Version]/"
49     "$ENV{SYSTEMROOT}/Microsoft.NET/Framework/[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VCExpress\\10.0;CLR Version]/")
50 endif()
51
52 mark_as_advanced(CMAKE_MAKE_PROGRAM)
53 set(MSVC10 1)
54 set(MSVC_VERSION 1600)