X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fcomponent.cpp;h=4451a69f662f4074260520f4173eb98ec318dac8;hb=463a3521e27870294455373f9c69279069611975;hp=a5076fb3a71d75fefdc1f88f6ea88a0e71688b20;hpb=a176997a1377cf8260ab362d9df8f975035da0f5;p=builder.git diff --git a/source/component.cpp b/source/component.cpp index a5076fb..4451a69 100644 --- a/source/component.cpp +++ b/source/component.cpp @@ -123,7 +123,7 @@ void Component::create_targets() const for(PathList::const_iterator i=files.begin(); i!=files.end(); ++i) { FileTarget *ft; - if(Target *tgt = builder.get_target(i->str())) + if(Target *tgt = builder.get_target_by_path(*i)) ft = dynamic_cast(tgt); else ft = new File(builder, *i); @@ -141,7 +141,7 @@ void Component::create_targets() const for(PathList::const_iterator i=files.begin(); i!=files.end(); ++i) { FileTarget *ft; - if(Target *tgt = builder.get_target(i->str())) + if(Target *tgt = builder.get_target_by_path(*i)) ft = dynamic_cast(tgt); else ft = new File(builder, pkg, *i); @@ -151,7 +151,7 @@ void Component::create_targets() const else if(type==DATAFILE) { File *source; - if(Target *tgt = builder.get_target(files.front().str())) + if(Target *tgt = builder.get_target_by_path(files.front())) source = dynamic_cast(tgt); else source = new File(builder, pkg, files.front()); @@ -171,7 +171,7 @@ void Component::create_targets() const string ext = FS::extpart(FS::basename(*i)); if(ext==".h") { - FileTarget *hdr = dynamic_cast(builder.get_target(i->str())); + FileTarget *hdr = builder.get_target_by_path(*i); if(!hdr) hdr = new Header(builder, *this, i->str());