cmake/Source/cmExtraKateGenerator.h

47 lines
1.5 KiB
C
Raw Normal View History

2016-10-30 18:24:19 +01:00
/* Distributed under the OSI-approved BSD 3-Clause License. See accompanying
file Copyright.txt or https://cmake.org/licensing for details. */
2014-08-03 19:52:23 +02:00
#ifndef cmExtraKateGenerator_h
#define cmExtraKateGenerator_h
2017-07-20 19:35:53 +02:00
#include "cmConfigure.h"
2016-10-30 18:24:19 +01:00
2014-08-03 19:52:23 +02:00
#include "cmExternalMakefileProjectGenerator.h"
2016-10-30 18:24:19 +01:00
#include <string>
2014-08-03 19:52:23 +02:00
class cmGeneratedFileStream;
2016-10-30 18:24:19 +01:00
class cmLocalGenerator;
2014-08-03 19:52:23 +02:00
/** \class cmExtraKateGenerator
* \brief Write Kate project files for Makefile or ninja based projects
*/
class cmExtraKateGenerator : public cmExternalMakefileProjectGenerator
{
public:
cmExtraKateGenerator();
2016-10-30 18:24:19 +01:00
static cmExternalMakefileProjectGeneratorFactory* GetFactory();
void Generate() CM_OVERRIDE;
2016-07-09 11:21:54 +02:00
2014-08-03 19:52:23 +02:00
private:
2016-03-13 13:35:51 +01:00
void CreateKateProjectFile(const cmLocalGenerator* lg) const;
void CreateDummyKateProjectFile(const cmLocalGenerator* lg) const;
void WriteTargets(const cmLocalGenerator* lg,
cmGeneratedFileStream& fout) const;
2016-07-09 11:21:54 +02:00
void AppendTarget(cmGeneratedFileStream& fout, const std::string& target,
const std::string& make, const std::string& makeArgs,
const std::string& path, const char* homeOutputDir) const;
2014-08-03 19:52:23 +02:00
2016-03-13 13:35:51 +01:00
std::string GenerateFilesString(const cmLocalGenerator* lg) const;
2014-08-03 19:52:23 +02:00
std::string GetPathBasename(const std::string& path) const;
std::string GenerateProjectName(const std::string& name,
const std::string& type,
const std::string& path) const;
std::string ProjectName;
bool UseNinja;
};
#endif