X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fgnulinker.cpp;h=b726dd5846cb6ed228955adfe3d7a73510d0ff96;hb=edd4771292a2273080fbcbac266c6831834b0b86;hp=dacd54d5b1649e7b08fd7bc0885895df0dbcd3a1;hpb=b29b79ca42fe4285c18b5d348b4eb59010d2c2da;p=builder.git diff --git a/source/gnulinker.cpp b/source/gnulinker.cpp index dacd54d..b726dd5 100644 --- a/source/gnulinker.cpp +++ b/source/gnulinker.cpp @@ -9,7 +9,6 @@ #include "component.h" #include "executable.h" #include "exportdefinitions.h" -#include "externaltask.h" #include "gnucompiler.h" #include "gnulinker.h" #include "importlibrary.h" @@ -31,7 +30,7 @@ GnuLinker::GnuLinker(Builder &b, const Architecture &a): processing_unit = COMPONENT; set_command("gcc", true); - set_run(_run); + set_run_external(_run); } Target *GnuLinker::create_target(const vector &sources, const string &arg) @@ -199,7 +198,7 @@ void GnuLinker::do_prepare(ToolData &tool) const } } -Task *GnuLinker::_run(const Binary &bin) +ExternalTask::Arguments GnuLinker::_run(const Binary &bin, FS::Path &work_dir) { const Tool &tool = *bin.get_tool(); const Builder &builder = tool.get_builder(); @@ -208,8 +207,6 @@ Task *GnuLinker::_run(const Binary &bin) ExternalTask::Arguments argv; argv.push_back(tool.get_executable()->get_path().str()); - FS::Path work_dir = bin.get_component()->get_package().get_source_directory(); - if(const SharedLibrary *shlib = dynamic_cast(&bin)) { argv.push_back("-shared"); @@ -324,5 +321,5 @@ Task *GnuLinker::_run(const Binary &bin) argv.push_back("-Wl,--enable-auto-import"); } - return new ExternalTask(argv, work_dir); + return argv; }