diff options
author | Bent Bisballe Nyeng <deva@aasimon.org> | 2021-06-13 18:24:16 +0200 |
---|---|---|
committer | Bent Bisballe Nyeng <deva@aasimon.org> | 2021-06-13 18:24:16 +0200 |
commit | 19195e2bbdcd7a0db8f84732ce54b1c9d07c006c (patch) | |
tree | b974b648ebacd645fbee000575268326f3b7bfbc /task.h | |
parent | f6f5f31067cdee2d7003d8209361ac9e5b6975c5 (diff) |
Make task an abstract class and make CC and LD versions of it.
Diffstat (limited to 'task.h')
-rw-r--r-- | task.h | 30 |
1 files changed, 5 insertions, 25 deletions
@@ -3,33 +3,13 @@ #include <vector> #include <string> -#include <future> -#include <filesystem> - -struct BuildConfiguration; -struct Settings; class Task { public: - Task(const BuildConfiguration& config, - const Settings& settings, - const std::string& source); - - bool dirty(); - - int run(); - int clean(); - - std::vector<std::string> depends() const; - - std::string target() const; - -private: - std::filesystem::path sourceFile; - std::filesystem::path targetFile; - std::filesystem::path depsFile; - - const BuildConfiguration& config; - const Settings& settings; + virtual bool dirty() = 0; + virtual int run() = 0; + virtual int clean() = 0 ; + virtual std::vector<std::string> depends() const = 0; + virtual std::string target() const = 0; }; |