]> git.tdb.fi Git - builder.git/blobdiff - source/compilecommandsgenerator.h
Add support for generating compile_commands.json
[builder.git] / source / compilecommandsgenerator.h
diff --git a/source/compilecommandsgenerator.h b/source/compilecommandsgenerator.h
new file mode 100644 (file)
index 0000000..ba74f11
--- /dev/null
@@ -0,0 +1,31 @@
+#ifndef COMPILECOMMANDSGENERATOR_H_
+#define COMPILECOMMANDSGENERATOR_H_
+
+#include "internaltask.h"
+#include "tool.h"
+
+class CompileCommandsJson;
+
+class CompileCommandsGenerator: public Tool
+{
+private:
+       class Worker: public InternalTask::Worker
+       {
+       private:
+               const CompileCommandsJson ⌖
+
+       public:
+               Worker(const CompileCommandsJson &);
+
+       private:
+               virtual void main();
+       };
+
+public:
+       CompileCommandsGenerator(Builder &);
+
+       virtual Target *create_target(const std::list<Target *> &, const std::string &);
+       virtual Task *run(const Target &) const;
+};
+
+#endif