cmConfigureFileNoAutoconf.h 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. /*=========================================================================
  2. Program: Insight Segmentation & Registration Toolkit
  3. Module: $RCSfile$
  4. Language: C++
  5. Date: $Date$
  6. Version: $Revision$
  7. Copyright (c) 2000 National Library of Medicine
  8. All rights reserved.
  9. See COPYRIGHT.txt for copyright details.
  10. =========================================================================*/
  11. #ifndef cmConfigureFileNoAutoconf_h
  12. #define cmConfigureFileNoAutoconf_h
  13. #include "cmStandardIncludes.h"
  14. #include "cmCommand.h"
  15. class cmConfigureFileNoAutoconf : public cmCommand
  16. {
  17. public:
  18. virtual cmCommand* Clone()
  19. {
  20. return new cmConfigureFileNoAutoconf;
  21. }
  22. /**
  23. * This is called when the command is first encountered in
  24. * the input file.
  25. */
  26. virtual bool Invoke(std::vector<std::string>& args);
  27. /**
  28. * The name of the command as specified in CMakeList.txt.
  29. */
  30. virtual const char* GetName() { return "CONFIGURE_FILE_NOAUTOCONF";}
  31. /**
  32. * Succinct documentation.
  33. */
  34. virtual const char* GetTerseDocumentation()
  35. {
  36. return "Create a header file from an autoconf style header.h.in file.";
  37. }
  38. /**
  39. * Longer documentation.
  40. */
  41. virtual const char* GetFullDocumentation()
  42. {
  43. return
  44. "CONFIGURE_HEADER(InputFile OutputFile)\n"
  45. "The Input and Ouput files have to have full paths.\n"
  46. "They can also use variables like CMAKE_BINARY_DIR,CMAKE_SOURCE_DIR.\n"
  47. "This command is only run if configure was not used. In other\n"
  48. "words it is only run for non UNIX style builds.\n";
  49. }
  50. /**
  51. * Create the header files in this pass. This is so
  52. * all varibles can be expaned.
  53. */
  54. virtual void FinalPass();
  55. private:
  56. std::string m_InputFile;
  57. std::string m_OuputFile;
  58. };
  59. #endif