From: Mikko Rasa Date: Sun, 31 Oct 2021 15:50:32 +0000 (+0200) Subject: Add logging for some problem situations X-Git-Url: http://git.tdb.fi/?a=commitdiff_plain;h=92d81529ec8f3b84f5471162d0b27914eff7adb5;p=builder.git Add logging for some problem situations --- diff --git a/source/binarypackage.cpp b/source/binarypackage.cpp index 5415f25..aa1aed3 100644 --- a/source/binarypackage.cpp +++ b/source/binarypackage.cpp @@ -76,6 +76,7 @@ void BinaryPackage::do_prepare() if(base_path.empty()) { // TODO report which files were not found + builder.get_logger().log("problems", format("Cannot locate files for %s", name)); problems.push_back("Cannot locate files"); return; } diff --git a/source/target.cpp b/source/target.cpp index cb44b13..9006a57 100644 --- a/source/target.cpp +++ b/source/target.cpp @@ -121,6 +121,7 @@ void Target::prepare() return; if(state==PREPARING) { + builder.get_logger().log("problems", format("Dependency cycle detected at %s", name)); problems.push_back("Dependency cycle detected"); state = BROKEN; return; diff --git a/source/tool.cpp b/source/tool.cpp index f3a2990..496132f 100644 --- a/source/tool.cpp +++ b/source/tool.cpp @@ -64,7 +64,10 @@ void Tool::prepare() { executable = builder.get_vfs().find_binary(command); if(!executable) + { + builder.get_logger().log("problems", format("Can't find executable %s for %s", command, tag)); problems.push_back(format("Can't find executable %s", command)); + } } }