X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fgnucxxcompiler.cpp;h=cadd21f026989df463412668a672b182d188bf5c;hb=19a821ee581f0fe60860627472cc59065247bf13;hp=0601fc29c5f596fbf1a99d1956450ad13ca10abd;hpb=4facd021514ab372c23b1b132d6b4b62baa4efbf;p=builder.git diff --git a/source/gnucxxcompiler.cpp b/source/gnucxxcompiler.cpp index 0601fc2..cadd21f 100644 --- a/source/gnucxxcompiler.cpp +++ b/source/gnucxxcompiler.cpp @@ -1,6 +1,7 @@ #include #include #include +#include #include "builder.h" #include "csourcefile.h" #include "externaltask.h" @@ -19,6 +20,7 @@ GnuCxxCompiler::GnuCxxCompiler(Builder &b): ExternalTask::Arguments argv; argv.push_back(name); argv.push_back("--version"); + builder.get_logger().log("auxcommands", format("Running %s", join(argv.begin(), argv.end()))); ExternalTask task(argv); task.set_stdout(ExternalTask::CAPTURE); task.set_stderr(ExternalTask::IGNORE); @@ -34,8 +36,7 @@ GnuCxxCompiler::GnuCxxCompiler(Builder &b): FS::Path cxx_path = FS::Path("/usr/include/c++")/cxx_ver; if(FS::is_dir(cxx_path)) { - if(builder.get_verbose()>=5) - IO::print("%s version is %s\n", name, cxx_ver); + builder.get_logger().log("tools", format("%s version is %s", name, cxx_ver)); system_path.push_back(cxx_path); break; } @@ -52,3 +53,8 @@ Target *GnuCxxCompiler::create_source(const Component &comp, const FS::Path &pat { return new CSourceFile(builder, comp, path); } + +Target *GnuCxxCompiler::create_source(const FS::Path &path) const +{ + return new CSourceFile(builder, path); +}