#pragma once #include #include #include #include #include #include "ProcessRunner.h" class Builder { public: Builder(const boost::property_tree::ptree& ptree); void build(); void clean(); private: std::vector dependencies_of(const std::filesystem::path& p); bool is_outdated(const std::filesystem::path& p); void build_file(const std::filesystem::path& p); void build_list(); void cleanup(); std::filesystem::path _target; std::vector _objects; std::vector _sources; std::unordered_map> _dependencies; ProcessRunner _runner; std::unordered_set _buildlist; // build done std::unordered_set _activelist; // currently building std::unordered_set _donelist; // build done };