1 /*=========================================================================
3 Program: CMake - Cross-Platform Makefile Generator
4 Module: $RCSfile: cmGlobalNMakeMakefileGenerator.cxx,v $
6 Date: $Date: 2008-01-13 21:36:20 $
7 Version: $Revision: 1.26 $
9 Copyright (c) 2002 Kitware, Inc., Insight Consortium. All rights reserved.
10 See Copyright.txt or http://www.cmake.org/HTML/Copyright.html for details.
12 This software is distributed WITHOUT ANY WARRANTY; without even
13 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
14 PURPOSE. See the above copyright notices for more information.
16 =========================================================================*/
17 #include "cmGlobalNMakeMakefileGenerator.h"
18 #include "cmLocalUnixMakefileGenerator3.h"
19 #include "cmMakefile.h"
21 cmGlobalNMakeMakefileGenerator::cmGlobalNMakeMakefileGenerator()
23 this->FindMakeProgramFile
= "CMakeNMakeFindMake.cmake";
24 this->ForceUnixPaths
= false;
25 this->ToolSupportsColor
= true;
26 this->UseLinkScript
= false;
29 void cmGlobalNMakeMakefileGenerator
30 ::EnableLanguage(std::vector
<std::string
>const& l
,
35 mf
->AddDefinition("CMAKE_GENERATOR_CC", "cl");
36 mf
->AddDefinition("CMAKE_GENERATOR_CXX", "cl");
37 this->cmGlobalUnixMakefileGenerator3::EnableLanguage(l
, mf
, optional
);
40 ///! Create a local generator appropriate to this Global Generator
41 cmLocalGenerator
*cmGlobalNMakeMakefileGenerator::CreateLocalGenerator()
43 cmLocalUnixMakefileGenerator3
* lg
= new cmLocalUnixMakefileGenerator3
;
44 lg
->SetDefineWindowsNULL(true);
45 lg
->SetWindowsShell(true);
46 lg
->SetMakeSilentFlag("/nologo");
47 lg
->SetGlobalGenerator(this);
48 lg
->SetIgnoreLibPrefix(true);
49 lg
->SetPassMakeflags(true);
55 //----------------------------------------------------------------------------
56 void cmGlobalNMakeMakefileGenerator
57 ::GetDocumentation(cmDocumentationEntry
& entry
) const
59 entry
.Name
= this->GetName();
60 entry
.Brief
= "Generates NMake makefiles.";