X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Flink.cpp;h=96089da8b58116ee24d95b9d57171bca04d0cd8c;hb=f1c967215e6b08095bdf07518472beca3067ec37;hp=e2c0f1222a83cb9d7baea296f8fcda4da17c0130;hpb=683301f94f4a3c5b7e2a7f21087f4185b07c4858;p=builder.git diff --git a/source/link.cpp b/source/link.cpp index e2c0f12..96089da 100644 --- a/source/link.cpp +++ b/source/link.cpp @@ -1,7 +1,9 @@ #include +#include "builder.h" #include "component.h" #include "executable.h" #include "link.h" +#include "objectfile.h" #include "package.h" using namespace std; @@ -27,10 +29,12 @@ Link::Link(Builder &b, const Executable &exe, const Component &comp): argv.push_back(exe.get_name()); const list &deps=exe.get_depends(); for(list::const_iterator i=deps.begin(); i!=deps.end(); ++i) - argv.push_back((*i)->get_name()); + if(dynamic_cast(*i)) + argv.push_back((*i)->get_name()); Path::Path epath=exe.get_name(); - Path::mkpath(epath.subpath(0, epath.size()-1), 0755); + if(!builder.get_dry_run()) + Path::mkpath(epath.subpath(0, epath.size()-1), 0755); announce(comp.get_package().get_name(), "LINK", relative(epath, comp.get_package().get_source()).str());