cmGlobalBorlandMakefileGenerator.cxx 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. /*============================================================================
  2. CMake - Cross Platform Makefile Generator
  3. Copyright 2000-2009 Kitware, Inc., Insight Software Consortium
  4. Distributed under the OSI-approved BSD License (the "License");
  5. see accompanying file Copyright.txt for details.
  6. This software is distributed WITHOUT ANY WARRANTY; without even the
  7. implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  8. See the License for more information.
  9. ============================================================================*/
  10. #include "cmGlobalBorlandMakefileGenerator.h"
  11. #include "cmLocalUnixMakefileGenerator3.h"
  12. #include "cmMakefile.h"
  13. #include "cmake.h"
  14. cmGlobalBorlandMakefileGenerator::cmGlobalBorlandMakefileGenerator()
  15. {
  16. this->EmptyRuleHackDepends = "NUL";
  17. this->FindMakeProgramFile = "CMakeBorlandFindMake.cmake";
  18. this->ForceUnixPaths = false;
  19. this->ToolSupportsColor = true;
  20. this->UseLinkScript = false;
  21. }
  22. void cmGlobalBorlandMakefileGenerator
  23. ::EnableLanguage(std::vector<std::string>const& l,
  24. cmMakefile *mf,
  25. bool optional)
  26. {
  27. std::string outdir = this->CMakeInstance->GetStartOutputDirectory();
  28. mf->AddDefinition("BORLAND", "1");
  29. mf->AddDefinition("CMAKE_GENERATOR_CC", "bcc32");
  30. mf->AddDefinition("CMAKE_GENERATOR_CXX", "bcc32");
  31. this->cmGlobalUnixMakefileGenerator3::EnableLanguage(l, mf, optional);
  32. }
  33. ///! Create a local generator appropriate to this Global Generator
  34. cmLocalGenerator *cmGlobalBorlandMakefileGenerator::CreateLocalGenerator()
  35. {
  36. cmLocalUnixMakefileGenerator3* lg = new cmLocalUnixMakefileGenerator3;
  37. lg->SetIncludeDirective("!include");
  38. lg->SetWindowsShell(true);
  39. lg->SetDefineWindowsNULL(true);
  40. lg->SetMakefileVariableSize(32);
  41. lg->SetPassMakeflags(true);
  42. lg->SetGlobalGenerator(this);
  43. lg->SetUnixCD(false);
  44. lg->SetMakeCommandEscapeTargetTwice(true);
  45. lg->SetBorlandMakeCurlyHack(true);
  46. lg->SetNoMultiOutputMultiDepRules(true);
  47. return lg;
  48. }
  49. //----------------------------------------------------------------------------
  50. void cmGlobalBorlandMakefileGenerator
  51. ::GetDocumentation(cmDocumentationEntry& entry)
  52. {
  53. entry.Name = cmGlobalBorlandMakefileGenerator::GetActualName();
  54. entry.Brief = "Generates Borland makefiles.";
  55. }