cmCPackDragNDropGenerator.h 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. /*============================================================================
  2. CMake - Cross Platform Makefile Generator
  3. Copyright 2000-2009 Kitware, Inc.
  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 cmCPackDragNDropGenerator_h
  11. #define cmCPackDragNDropGenerator_h
  12. #include "cmCPackGenerator.h"
  13. /** \class cmCPackDragNDropGenerator
  14. * \brief A generator for OSX drag-n-drop installs
  15. */
  16. class cmCPackDragNDropGenerator : public cmCPackGenerator
  17. {
  18. public:
  19. cmCPackTypeMacro(cmCPackDragNDropGenerator, cmCPackGenerator);
  20. cmCPackDragNDropGenerator();
  21. virtual ~cmCPackDragNDropGenerator();
  22. protected:
  23. virtual int InitializeInternal();
  24. virtual const char* GetOutputExtension();
  25. int PackageFiles();
  26. bool CopyFile(cmOStringStream& source, cmOStringStream& target);
  27. bool RunCommand(cmOStringStream& command, std::string* output = 0);
  28. int CreateDMG();
  29. std::string InstallPrefix;
  30. };
  31. #endif