From 28609f436966f731f91e84d10c1d7d0621b4abe8 Mon Sep 17 00:00:00 2001 From: Roland Reichwein Date: Sun, 5 May 2024 12:57:18 +0200 Subject: Tests --- Builder.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'Builder.cpp') diff --git a/Builder.cpp b/Builder.cpp index c59aec8..51ac90f 100644 --- a/Builder.cpp +++ b/Builder.cpp @@ -180,10 +180,12 @@ namespace { } Builder::Builder(const pt::ptree& ptree): + _ptree(ptree), _all_targets{get_all_targets(ptree)}, - _all_objects{get_all_objects(ptree)}, - _dependencies{get_dependencies(ptree)} + _all_objects{get_all_objects(ptree)} { + // intentionally defer creation of _dependencies to build() + // to prevent creation of .d files in clean() } std::vector Builder::dependencies_of(const fs::path& p) const @@ -311,6 +313,7 @@ void Builder::build_filelist() { // build everything according to specified configuration void Builder::build() { + _dependencies = get_dependencies(_ptree); // create build list by depth-first search //std::cout << "Calculating build list..." << std::endl; -- cgit v1.2.3