cmCustomCommandGenerator.h 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. /*============================================================================
  2. CMake - Cross Platform Makefile Generator
  3. Copyright 2000-2010 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. #ifndef cmCustomCommandGenerator_h
  11. #define cmCustomCommandGenerator_h
  12. #include "cmStandardIncludes.h"
  13. class cmCustomCommand;
  14. class cmLocalGenerator;
  15. class cmGeneratorExpression;
  16. class cmCustomCommandGenerator
  17. {
  18. cmCustomCommand const& CC;
  19. std::string Config;
  20. cmLocalGenerator* LG;
  21. bool OldStyle;
  22. bool MakeVars;
  23. cmGeneratorExpression* GE;
  24. mutable bool DependsDone;
  25. mutable std::vector<std::string> Depends;
  26. public:
  27. cmCustomCommandGenerator(cmCustomCommand const& cc,
  28. const std::string& config,
  29. cmLocalGenerator* lg);
  30. ~cmCustomCommandGenerator();
  31. cmCustomCommand const& GetCC() const { return this->CC; }
  32. unsigned int GetNumberOfCommands() const;
  33. std::string GetCommand(unsigned int c) const;
  34. void AppendArguments(unsigned int c, std::string& cmd) const;
  35. const char* GetComment() const;
  36. std::string GetWorkingDirectory() const;
  37. std::vector<std::string> const& GetOutputs() const;
  38. std::vector<std::string> const& GetByproducts() const;
  39. std::vector<std::string> const& GetDepends() const;
  40. };
  41. #endif