1 /*=========================================================================
3 Program: CMake - Cross-Platform Makefile Generator
4 Module: $RCSfile: cmGlobalWatcomWMakeGenerator.cxx,v $
6 Date: $Date: 2007-10-22 16:48:39 $
7 Version: $Revision: 1.14 $
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 "cmGlobalWatcomWMakeGenerator.h"
18 #include "cmLocalUnixMakefileGenerator3.h"
19 #include "cmMakefile.h"
21 cmGlobalWatcomWMakeGenerator::cmGlobalWatcomWMakeGenerator()
23 this->FindMakeProgramFile
= "CMakeFindWMake.cmake";
24 this->ForceUnixPaths
= false;
25 this->ToolSupportsColor
= true;
26 this->NeedSymbolicMark
= true;
27 this->EmptyRuleHackCommand
= "@cd .";
30 void cmGlobalWatcomWMakeGenerator
31 ::EnableLanguage(std::vector
<std::string
>const& l
,
36 mf
->AddDefinition("WATCOM", "1");
37 mf
->AddDefinition("CMAKE_QUOTE_INCLUDE_PATHS", "1");
38 mf
->AddDefinition("CMAKE_MANGLE_OBJECT_FILE_NAMES", "1");
39 mf
->AddDefinition("CMAKE_MAKE_LINE_CONTINUE", "&");
40 mf
->AddDefinition("CMAKE_MAKE_SYMBOLIC_RULE", ".SYMBOLIC");
41 mf
->AddDefinition("CMAKE_NO_QUOTED_OBJECTS", "1");
42 mf
->AddDefinition("CMAKE_GENERATOR_CC", "wcl386");
43 mf
->AddDefinition("CMAKE_GENERATOR_CXX", "wcl386");
44 this->cmGlobalUnixMakefileGenerator3::EnableLanguage(l
, mf
, optional
);
47 ///! Create a local generator appropriate to this Global Generator
48 cmLocalGenerator
*cmGlobalWatcomWMakeGenerator::CreateLocalGenerator()
50 cmLocalUnixMakefileGenerator3
* lg
= new cmLocalUnixMakefileGenerator3
;
51 lg
->SetSilentNoColon(true);
52 lg
->SetDefineWindowsNULL(true);
53 lg
->SetWindowsShell(true);
54 lg
->SetWatcomWMake(true);
55 lg
->SetMakeSilentFlag("-s -h");
56 lg
->SetGlobalGenerator(this);
57 lg
->SetIgnoreLibPrefix(true);
58 lg
->SetPassMakeflags(false);
60 lg
->SetIncludeDirective("!include");
64 //----------------------------------------------------------------------------
65 void cmGlobalWatcomWMakeGenerator
66 ::GetDocumentation(cmDocumentationEntry
& entry
) const
68 entry
.Name
= this->GetName();
69 entry
.Brief
= "Generates Watcom WMake makefiles.";