cmCPackDebGenerator.h 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  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 cmCPackDebGenerator_h
  11. #define cmCPackDebGenerator_h
  12. #include "cmCPackGenerator.h"
  13. /** \class cmCPackDebGenerator
  14. * \brief A generator for Debian packages
  15. *
  16. */
  17. class cmCPackDebGenerator : public cmCPackGenerator
  18. {
  19. public:
  20. cmCPackTypeMacro(cmCPackDebGenerator, cmCPackGenerator);
  21. /**
  22. * Construct generator
  23. */
  24. cmCPackDebGenerator();
  25. virtual ~cmCPackDebGenerator();
  26. protected:
  27. virtual int InitializeInternal();
  28. /**
  29. * This method factors out the work done in component packaging case.
  30. */
  31. int PackageOnePack(std::string initialToplevel, std::string packageName);
  32. /**
  33. * The method used to package files when component
  34. * install is used. This will create one
  35. * archive for each component group.
  36. */
  37. int PackageComponents(bool ignoreGroup);
  38. /**
  39. * Special case of component install where all
  40. * components will be put in a single installer.
  41. */
  42. int PackageComponentsAllInOne();
  43. virtual int PackageFiles();
  44. virtual const char* GetOutputExtension() { return ".deb"; }
  45. virtual bool SupportsComponentInstallation() const;
  46. virtual std::string GetComponentInstallDirNameSuffix(
  47. const std::string& componentName);
  48. private:
  49. int createDeb();
  50. std::vector<std::string> packageFiles;
  51. };
  52. #endif